[llvm] r268991 - [WebAssembly] Disable 128-bit shift libcalls

Derek Schuff via llvm-commits llvm-commits at lists.llvm.org
Mon May 9 17:14:07 PDT 2016


Author: dschuff
Date: Mon May  9 19:14:07 2016
New Revision: 268991

URL: http://llvm.org/viewvc/llvm-project?rev=268991&view=rev
Log:
[WebAssembly] Disable 128-bit shift libcalls

Currently the signature of the functions
i128(i128, i32) aka void(i32, i64, i64, i32) doesn't match the signature
of the call emitted by the default lowering, void(i32, i64, i64).

Modified:
    llvm/trunk/lib/Target/WebAssembly/WebAssemblyISelLowering.cpp

Modified: llvm/trunk/lib/Target/WebAssembly/WebAssemblyISelLowering.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Target/WebAssembly/WebAssemblyISelLowering.cpp?rev=268991&r1=268990&r2=268991&view=diff
==============================================================================
--- llvm/trunk/lib/Target/WebAssembly/WebAssemblyISelLowering.cpp (original)
+++ llvm/trunk/lib/Target/WebAssembly/WebAssemblyISelLowering.cpp Mon May  9 19:14:07 2016
@@ -135,6 +135,13 @@ WebAssemblyTargetLowering::WebAssemblyTa
 
   // Trap lowers to wasm unreachable
   setOperationAction(ISD::TRAP, MVT::Other, Legal);
+
+  // Disable 128-bit shift libcalls. Currently the signature of the functions
+  // i128(i128, i32) aka void(i32, i64, i64, i32) doesn't match the signature
+  // of the call emitted by the default lowering, void(i32, i64, i64).
+  setLibcallName(RTLIB::SRL_I128, nullptr);
+  setLibcallName(RTLIB::SRA_I128, nullptr);
+  setLibcallName(RTLIB::SHL_I128, nullptr);
 }
 
 FastISel *WebAssemblyTargetLowering::createFastISel(




More information about the llvm-commits mailing list