From 0b05fe33c82ee301c134f5b9a87a596aa47121c8 Mon Sep 17 00:00:00 2001 From: Yong He Date: Thu, 10 Nov 2022 14:19:20 -0800 Subject: Fix inlining pass. (#2506) * Fix inlining pass. * Add more check against corner cases. * Revise comments. * Fixes. * Fix premake script. * Fixes. Co-authored-by: Yong He --- premake5.lua | 14 +++++++++++++- 1 file changed, 13 insertions(+), 1 deletion(-) (limited to 'premake5.lua') diff --git a/premake5.lua b/premake5.lua index dd16a170c..f5a86126e 100644 --- a/premake5.lua +++ b/premake5.lua @@ -189,6 +189,13 @@ newoption { default = "true", allowed = { { "true", "True"}, { "false", "False" } } } + newoption { + trigger = "full-debug-validation", + description = "(Optional) If true will enable full IR validation in debug build. (SLOW!)", + value = "bool", + default = "false", + allowed = { { "true", "True"}, { "false", "False" } } + } buildLocation = _OPTIONS["build-location"] executeBinary = (_OPTIONS["execute-binary"] == "true") @@ -203,7 +210,8 @@ newoption { skipSourceGeneration = (_OPTIONS["skip-source-generation"] == "true") deployLLVM = (_OPTIONS["deploy-slang-llvm"] == "true") deployGLSLang = (_OPTIONS["deploy-slang-glslang"] == "true") - + fullDebugValidation = (_OPTIONS["full-debug-validation"] == "true") + -- If stdlib embedding is enabled, disable stdlib source embedding by default disableStdlibSource = enableEmbedStdLib @@ -1346,6 +1354,10 @@ tool "slangd" if disableStdlibSource then defines { "SLANG_DISABLE_STDLIB_SOURCE" } end + + if fullDebugValidation then + defines { "SLANG_ENABLE_FULL_IR_VALIDATION" } + end if enableEmbedStdLib then -- We only have this dependency if we are embedding stdlib -- cgit v1.2.3