diff options
Diffstat (limited to 'source/slang/emit.cpp')
| -rw-r--r-- | source/slang/emit.cpp | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/source/slang/emit.cpp b/source/slang/emit.cpp index 189c1c4bd..fa090121f 100644 --- a/source/slang/emit.cpp +++ b/source/slang/emit.cpp @@ -3,6 +3,7 @@ #include "ir-insts.h" #include "ir-ssa.h" +#include "ir-validate.h" #include "legalize-types.h" #include "lower-to-ir.h" #include "mangle.h" @@ -8200,6 +8201,7 @@ String emitEntryPoint( typeLegalizationContext.session = entryPoint->compileRequest->mSession; IRModule* irModule = getIRModule(irSpecializationState); + auto compileRequest = translationUnit->compileRequest; typeLegalizationContext.irModule = irModule; @@ -8208,6 +8210,8 @@ String emitEntryPoint( entryPoint, &sharedContext.extensionUsageTracker); + validateIRModuleIfEnabled(compileRequest, irModule); + // If the user specified the flag that they want us to dump // IR, then do it here, for the target-specific, but // un-specialized IR. @@ -8254,6 +8258,7 @@ String emitEntryPoint( // so that we can work with the individual fields). constructSSA(irModule); + validateIRModuleIfEnabled(compileRequest, irModule); // After all of the required optimization and legalization // passes have been performed, we can emit target code from |
