MCPcopy Create free account
hub / github.com/Samsung/UTopia / updateArgFlow

Method updateArgFlow

lib/propanalysis/ArrayAnalyzer.cpp:415–440  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

413}
414
415bool ArrayAnalyzer::updateArgFlow(Argument &A) {
416 if (!Report->has(A))
417 return false;
418
419 auto &AF = getOrCreateArgFlow(A);
420
421 auto Value = Report->get(A);
422 if (Value == ArrayAnalysisReport::NO_ARRAY)
423 AF.setIsArray(false);
424 else
425 AF.setIsArray(true);
426
427 if (Value >= 0) {
428 auto *F = AF.getLLVMArg().getParent();
429 if (!F)
430 return true;
431
432 auto *ResultArg = F->getArg(Report->get(A));
433 if (!ResultArg)
434 return true;
435
436 AF.setSizeArg(*ResultArg);
437 }
438 updateFieldFlow(AF);
439 return true;
440}
441
442void ArrayAnalyzer::updateFieldFlow(ArgFlow &AF, std::vector<int> Indices) {
443 auto &A = AF.getLLVMArg();

Callers

nothing calls this directly

Calls 5

setIsArrayMethod · 0.80
getArgMethod · 0.80
setSizeArgMethod · 0.80
hasMethod · 0.45
getMethod · 0.45

Tested by

no test coverage detected