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

Function IsDescriptorArray

source/opt/desc_sroa_util.cpp:59–64  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

57namespace descsroautil {
58
59bool IsDescriptorArray(IRContext* context, Instruction* var) {
60 Instruction* var_type_inst = GetVariableType(context, var);
61 if (var_type_inst == nullptr) return false;
62 return var_type_inst->opcode() == spv::Op::OpTypeArray &&
63 HasDescriptorDecorations(context, var);
64}
65
66bool IsDescriptorStruct(IRContext* context, Instruction* var) {
67 Instruction* var_type_inst = GetVariableType(context, var);

Callers 3

ProcessMethod · 0.85
ProcessMethod · 0.85

Calls 3

GetVariableTypeFunction · 0.85
HasDescriptorDecorationsFunction · 0.85
opcodeMethod · 0.45

Tested by

no test coverage detected