Define Disassemble only when Effcee is used in fold_test

This commit is contained in:
Pierre Moreau 2018-03-02 22:27:26 +01:00 committed by David Neto
parent a942ff40f5
commit 6cd6e5ebef

View File

@ -36,6 +36,7 @@ using ::testing::Contains;
using namespace spvtools;
using spvtools::opt::analysis::DefUseManager;
#ifdef SPIRV_EFFCEE
std::string Disassemble(const std::string& original, ir::IRContext* context,
uint32_t disassemble_options = 0) {
std::vector<uint32_t> optimized_bin;
@ -50,7 +51,6 @@ std::string Disassemble(const std::string& original, ir::IRContext* context,
return optimized_asm;
}
#ifdef SPIRV_EFFCEE
void Match(const std::string& original, ir::IRContext* context,
uint32_t disassemble_options = 0) {
std::string disassembly = Disassemble(original, context, disassemble_options);