From 203b5d7a5014d7f140345567e065cbf57b57b819 Mon Sep 17 00:00:00 2001 From: jsmall-nvidia Date: Thu, 3 Nov 2022 11:48:43 -0400 Subject: Disable HLSL2021 by default (#2488) * #include an absolute path didn't work - because paths were taken to always be relative. * Disable SER tests and enabling HLSL2021 by default. --- source/compiler-core/slang-dxc-compiler.cpp | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'source') diff --git a/source/compiler-core/slang-dxc-compiler.cpp b/source/compiler-core/slang-dxc-compiler.cpp index 2856a77ab..26245df9c 100644 --- a/source/compiler-core/slang-dxc-compiler.cpp +++ b/source/compiler-core/slang-dxc-compiler.cpp @@ -517,6 +517,10 @@ SlangResult DXCDownstreamCompiler::compile(const CompileOptions& options, IArtif searchDirectories.searchDirectories.add(asString(includePath)); } + // TODO(JS): + // We don't want to enable HLSL2021 on DXC by default even if it's available because it has + // changes that break things. Such as with operator ?:. So for now we disable. +#if 0 // TODO(JS): Enable in a better way perhaps? { // Strictly speaking the HLSL2021 was available in 1.6.2112, in preview @@ -532,6 +536,7 @@ SlangResult DXCDownstreamCompiler::compile(const CompileOptions& options, IArtif args.add(L"2021"); } } +#endif String sourcePath = ArtifactUtil::findPath(sourceArtifact); OSString wideSourcePath = sourcePath.toWString(); -- cgit v1.2.3