Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(22)

Unified Diff: src/IceCompiler.cpp

Issue 1856323004: Subzero. Fixes Browser Build (Closed) Base URL: https://chromium.googlesource.com/native_client/pnacl-subzero.git@master
Patch Set: Removes Wasm translator from browser build Created 4 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « Makefile ('k') | src/WasmTranslator.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/IceCompiler.cpp
diff --git a/src/IceCompiler.cpp b/src/IceCompiler.cpp
index 6a853d0e5028f9ca36b3371678f9a9a73748036e..13545c7a0837836f23fdd82c11bed08713ea90e2 100644
--- a/src/IceCompiler.cpp
+++ b/src/IceCompiler.cpp
@@ -92,11 +92,15 @@ void Compiler::run(const Ice::ClFlags &Flags, GlobalContext &Ctx,
Translator.reset(PTranslator.release());
} else if (WasmBuildOnRead) {
if (BuildDefs::wasm()) {
+#if !ALLOW_WASM
Jim Stichnoth 2016/04/05 13:10:41 I'm surprised this is necessary, because of BuildD
John 2016/04/05 13:14:08 the if(constexpr) guard is "weaker" than an #if. T
Jim Stichnoth 2016/04/05 13:18:38 Oh, right, I forgot about the fact that this code
+ assert(false && "wasm not allowed");
+#else
std::unique_ptr<WasmTranslator> WTranslator(new WasmTranslator(&Ctx));
WTranslator->translate(IRFilename, std::move(InputStream));
Translator.reset(WTranslator.release());
+#endif // !ALLOW_WASM
} else {
Ctx.getStrError() << "WASM support not enabled\n";
Ctx.getErrorStatus()->assign(EC_Args);
« no previous file with comments | « Makefile ('k') | src/WasmTranslator.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698