| 22 | namespace { |
| 23 | |
| 24 | spv_result_t ValidateConstantBool(ValidationState_t& _, |
| 25 | const Instruction* inst) { |
| 26 | auto type = _.FindDef(inst->type_id()); |
| 27 | if (!type || type->opcode() != spv::Op::OpTypeBool) { |
| 28 | return _.diag(SPV_ERROR_INVALID_ID, inst) |
| 29 | << "Op" << spvOpcodeString(inst->opcode()) << " Result Type <id> " |
| 30 | << _.getIdName(inst->type_id()) << " is not a boolean type."; |
| 31 | } |
| 32 | |
| 33 | return SPV_SUCCESS; |
| 34 | } |
| 35 | |
| 36 | bool isCompositeType(const Instruction* inst) { |
| 37 | bool is_tensor = inst->opcode() == spv::Op::OpTypeTensorARM; |
no test coverage detected