From 2ddca33686c08e1833c0d82a420fb2b27cde4e37 Mon Sep 17 00:00:00 2001 From: Yong He Date: Thu, 17 Sep 2020 16:46:23 -0700 Subject: Initial attempt to enable CUDA dynamic dispatch codegen (#1549) * Front-load cuda module loading to fill in RTTI pointers. * Enable dynamic dispatch codegen for CUDA. --- source/slang/slang-emit-c-like.cpp | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) (limited to 'source/slang/slang-emit-c-like.cpp') diff --git a/source/slang/slang-emit-c-like.cpp b/source/slang/slang-emit-c-like.cpp index 8ef18242a..f234b0be6 100644 --- a/source/slang/slang-emit-c-like.cpp +++ b/source/slang/slang-emit-c-like.cpp @@ -3837,7 +3837,6 @@ void CLikeSourceEmitter::ensureGlobalInst(ComputeEmitActionsContext* ctx, IRInst // Skip certain instructions that don't affect output. switch(inst->op) { - case kIROp_InterfaceRequirementEntry: case kIROp_Generic: return; @@ -3877,6 +3876,16 @@ void CLikeSourceEmitter::ensureGlobalInst(ComputeEmitActionsContext* ctx, IRInst } ctx->mapInstToLevel[inst] = requiredLevel; + + // Skip instructions that don't correspond to an independent entity in output. + switch (inst->op) + { + case kIROp_InterfaceRequirementEntry: + return; + + default: + break; + } ctx->actions->add(action); } -- cgit v1.2.3