MCPcopy Create free account
hub / github.com/AliveToolkit/alive2 / returns_local

Function returns_local

tools/transform.cpp:791–798  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

789}
790
791static bool returns_local(const Value &v) {
792 // no alias fns return local block
793 if (auto call = dynamic_cast<const FnCall*>(&v))
794 return call->hasAttribute(FnAttrs::NoAlias) ||
795 call->getAttributes().isAlloc();
796
797 return dynamic_cast<const Alloc*>(&v);
798}
799
800static Value *get_base_ptr(Value *ptr) {
801 vector<Value*> todo = { ptr };

Callers 4

may_be_nonlocalFunction · 0.85
execMethod · 0.85
optimize_ptrcmpFunction · 0.85

Calls 2

isAllocMethod · 0.80
hasAttributeMethod · 0.45

Tested by

no test coverage detected