MCPcopy Create free account
hub / github.com/KhronosGroup/SPIRV-Tools / CollectChildren

Function CollectChildren

source/opt/loop_fusion.cpp:29–36  ·  view source on GitHub ↗

Append all the loops nested in |loop| to |loops|.

Source from the content-addressed store, hash-verified

27
28// Append all the loops nested in |loop| to |loops|.
29void CollectChildren(Loop* loop, std::vector<const Loop*>* loops) {
30 for (auto child : *loop) {
31 loops->push_back(child);
32 if (child->NumImmediateChildren() != 0) {
33 CollectChildren(child, loops);
34 }
35 }
36}
37
38// Return the set of locations accessed by |stores| and |loads|.
39std::set<Instruction*> GetLocationsAccessed(

Callers 1

IsLegalMethod · 0.85

Calls 2

NumImmediateChildrenMethod · 0.80
push_backMethod · 0.45

Tested by

no test coverage detected