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

Method NestingDepth

source/opt/struct_cfg_analysis.cpp:130–141  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

128}
129
130uint32_t StructuredCFGAnalysis::NestingDepth(uint32_t bb_id) {
131 uint32_t result = 0;
132
133 // Find the merge block of the current merge construct as long as the block is
134 // inside a merge construct, exiting one for each iteration.
135 for (uint32_t merge_block_id = MergeBlock(bb_id); merge_block_id != 0;
136 merge_block_id = MergeBlock(merge_block_id)) {
137 result++;
138 }
139
140 return result;
141}
142
143uint32_t StructuredCFGAnalysis::LoopMergeBlock(uint32_t bb_id) {
144 uint32_t header_id = ContainingLoop(bb_id);

Callers 2

operator()Method · 0.80
TEST_FFunction · 0.80

Calls

no outgoing calls

Tested by 1

TEST_FFunction · 0.64