summaryrefslogtreecommitdiffstats
path: root/clang/lib/CodeGen/ABIInfo.h
diff options
context:
space:
mode:
authorPekka Jaaskelainen <pekka.jaaskelainen@tut.fi>2017-06-01 07:18:49 +0000
committerPekka Jaaskelainen <pekka.jaaskelainen@tut.fi>2017-06-01 07:18:49 +0000
commitfc2629a65a05fa05bc5c5bc37cf910c8e41cdac3 (patch)
tree547c65c0be893aa0c5b017335356f00100190fc6 /clang/lib/CodeGen/ABIInfo.h
parentf44122608535702f7e45c268921e7dc6a1898021 (diff)
downloadbcm5719-llvm-fc2629a65a05fa05bc5c5bc37cf910c8e41cdac3.tar.gz
bcm5719-llvm-fc2629a65a05fa05bc5c5bc37cf910c8e41cdac3.zip
[OpenCL] Makes kernels use the SPIR_KERNEL CC by default.
Rationale: OpenCL kernels are called via an explicit runtime API with arguments set with clSetKernelArg(), not as normal sub-functions. Return SPIR_KERNEL by default as the kernel calling convention to ensure the fingerprint is fixed such way that each OpenCL argument gets one matching argument in the produced kernel function argument list to enable feasible implementation of clSetKernelArg() with aggregates etc. In case we would use the default C calling conv here, clSetKernelArg() might break depending on the target-specific conventions; different targets might split structs passed as values to multiple function arguments etc. https://reviews.llvm.org/D33639 llvm-svn: 304389
Diffstat (limited to 'clang/lib/CodeGen/ABIInfo.h')
-rw-r--r--clang/lib/CodeGen/ABIInfo.h1
1 files changed, 0 insertions, 1 deletions
diff --git a/clang/lib/CodeGen/ABIInfo.h b/clang/lib/CodeGen/ABIInfo.h
index c0be60ef53b..e4dce2f2a00 100644
--- a/clang/lib/CodeGen/ABIInfo.h
+++ b/clang/lib/CodeGen/ABIInfo.h
@@ -149,7 +149,6 @@ namespace swiftcall {
return info->supportsSwift();
}
};
-
} // end namespace CodeGen
} // end namespace clang
OpenPOWER on IntegriCloud