[PATCH] D23244: [Driver] Enable CFI for WebAssembly

Derek Schuff via cfe-commits cfe-commits at lists.llvm.org
Mon Aug 8 14:22:16 PDT 2016


This revision was automatically updated to reflect the committed changes.
Closed by commit rL278051: [Driver] Enable CFI for WebAssembly (authored by dschuff).

Changed prior to commit:
  https://reviews.llvm.org/D23244?vs=67090&id=67226#toc

Repository:
  rL LLVM

https://reviews.llvm.org/D23244

Files:
  cfe/trunk/lib/Driver/ToolChain.cpp

Index: cfe/trunk/lib/Driver/ToolChain.cpp
===================================================================
--- cfe/trunk/lib/Driver/ToolChain.cpp
+++ cfe/trunk/lib/Driver/ToolChain.cpp
@@ -697,7 +697,9 @@
   SanitizerMask Res = (Undefined & ~Vptr & ~Function) | (CFI & ~CFIICall) |
                       CFICastStrict | UnsignedIntegerOverflow | LocalBounds;
   if (getTriple().getArch() == llvm::Triple::x86 ||
-      getTriple().getArch() == llvm::Triple::x86_64)
+      getTriple().getArch() == llvm::Triple::x86_64 ||
+      getTriple().getArch() == llvm::Triple::wasm32 ||
+      getTriple().getArch() == llvm::Triple::wasm64)
     Res |= CFIICall;
   return Res;
 }


-------------- next part --------------
A non-text attachment was scrubbed...
Name: D23244.67226.patch
Type: text/x-patch
Size: 676 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20160808/b69eb659/attachment.bin>


More information about the cfe-commits mailing list