summaryrefslogtreecommitdiffstats
path: root/llvm/lib
diff options
context:
space:
mode:
authorDan Gohman <dan433584@gmail.com>2015-12-04 18:27:03 +0000
committerDan Gohman <dan433584@gmail.com>2015-12-04 18:27:03 +0000
commit1ce2b1afd61e05fdbe2c8190f0524ffb3769f152 (patch)
treee5bfc5650e864f308f85f25d7540d41aa014f8c6 /llvm/lib
parent8e7facbd4efb3d8e571d29ecbcb1a5ffa3a71e3f (diff)
downloadbcm5719-llvm-1ce2b1afd61e05fdbe2c8190f0524ffb3769f152.tar.gz
bcm5719-llvm-1ce2b1afd61e05fdbe2c8190f0524ffb3769f152.zip
[WebAssembly] Add several more calling conventions to the supported list.
llvm-svn: 254741
Diffstat (limited to 'llvm/lib')
-rw-r--r--llvm/lib/Target/WebAssembly/WebAssemblyISelLowering.cpp9
1 files changed, 7 insertions, 2 deletions
diff --git a/llvm/lib/Target/WebAssembly/WebAssemblyISelLowering.cpp b/llvm/lib/Target/WebAssembly/WebAssemblyISelLowering.cpp
index b651855eea7..a7eba561113 100644
--- a/llvm/lib/Target/WebAssembly/WebAssemblyISelLowering.cpp
+++ b/llvm/lib/Target/WebAssembly/WebAssemblyISelLowering.cpp
@@ -260,9 +260,14 @@ static void fail(SDLoc DL, SelectionDAG &DAG, const char *msg) {
// Test whether the given calling convention is supported.
static bool CallingConvSupported(CallingConv::ID CallConv) {
// We currently support the language-independent target-independent
- // conventions.
+ // conventions. We don't yet have a way to annotate calls with properties like
+ // "cold", and we don't have any call-clobbered registers, so these are mostly
+ // all handled the same.
return CallConv == CallingConv::C || CallConv == CallingConv::Fast ||
- CallConv == CallingConv::Cold;
+ CallConv == CallingConv::Cold ||
+ CallConv == CallingConv::PreserveMost ||
+ CallConv == CallingConv::PreserveAll ||
+ CallConv == CallingConv::CXX_FAST_TLS;
}
SDValue
OpenPOWER on IntegriCloud