diff options
-rw-r--r-- | include/llvm/Support/TargetRegistry.h | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/include/llvm/Support/TargetRegistry.h b/include/llvm/Support/TargetRegistry.h index b06676d4d2..9658cded73 100644 --- a/include/llvm/Support/TargetRegistry.h +++ b/include/llvm/Support/TargetRegistry.h @@ -711,8 +711,14 @@ namespace llvm { /// @param Fn - A function to construct an MCInstPrinter for the target. static void RegisterMCInstPrinter(Target &T, Target::MCInstPrinterCtorTy Fn) { + // @LOCALMOD-BEGIN + // Prune out the .s printer for the sandboxed translator, + // by preventing an InstPrinter from being used at all. + #if !defined(__native_client__) if (!T.MCInstPrinterCtorFn) T.MCInstPrinterCtorFn = Fn; + #endif + // @LOCALMOD-END } /// RegisterMCCodeEmitter - Register a MCCodeEmitter implementation for the |