Only print legalization warning if optimizer disabled
This commit is contained in:
parent
7be36647fc
commit
fb03a55e0f
16 changed files with 21 additions and 21 deletions
|
|
@ -54,12 +54,12 @@ namespace spv {
|
|||
#endif
|
||||
}
|
||||
|
||||
#ifdef ENABLE_OPT
|
||||
#if ENABLE_OPT
|
||||
#include "spirv-tools/optimizer.hpp"
|
||||
#include "message.h"
|
||||
#endif
|
||||
|
||||
#ifdef ENABLE_OPT
|
||||
#if ENABLE_OPT
|
||||
using namespace spvtools;
|
||||
#endif
|
||||
|
||||
|
|
@ -6757,7 +6757,7 @@ void GlslangToSpv(const glslang::TIntermediate& intermediate, std::vector<unsign
|
|||
it.finishSpv();
|
||||
it.dumpSpv(spirv);
|
||||
|
||||
#ifdef ENABLE_OPT
|
||||
#if ENABLE_OPT
|
||||
// If from HLSL, run spirv-opt to "legalize" the SPIR-V for Vulkan
|
||||
// eg. forward and remove memory writes of opaque types.
|
||||
if ((intermediate.getSource() == EShSourceHlsl ||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue