diff options
Diffstat (limited to 'source/slang/slang-emit-c-like.cpp')
| -rw-r--r-- | source/slang/slang-emit-c-like.cpp | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/source/slang/slang-emit-c-like.cpp b/source/slang/slang-emit-c-like.cpp index 66ee12ca6..7ce2c7900 100644 --- a/source/slang/slang-emit-c-like.cpp +++ b/source/slang/slang-emit-c-like.cpp @@ -2566,10 +2566,15 @@ void CLikeSourceEmitter::defaultEmitInstExpr(IRInst* inst, const EmitOpInfo& inO emitOperand(inst->getOperand(1), rightSide(outerPrec, prec)); break; } + + case kIROp_ImageSubscript: + // We should have legalized ImageSubscript before emit for metal targets + if (isMetalTarget(this->getTargetReq())) + getSink()->diagnose(inst, Diagnostics::unimplemented, "kIROp_ImageSubscript is unimplemented for Metal, expected legalization beforehand"); + [[fallthrough]]; case kIROp_GetElement: case kIROp_MeshOutputRef: case kIROp_GetElementPtr: - case kIROp_ImageSubscript: // HACK: deal with translation of GLSL geometry shader input arrays. if(auto decoration = inst->getOperand(0)->findDecoration<IRGLSLOuterArrayDecoration>()) { |
