diff options
author | Artem Belevich <tra@google.com> | 2017-07-20 21:16:03 +0000 |
---|---|---|
committer | Artem Belevich <tra@google.com> | 2017-07-20 21:16:03 +0000 |
commit | 09833a858ca7bbe9fb4ce31c8082e08cc3dd8625 (patch) | |
tree | 03026f9b62124cb8a598b7b57298fb79c4dc1cd0 /lib/Basic/Targets.cpp | |
parent | a51c0d82773ec07e4fbdb88d88b408b6eef1f8e1 (diff) |
[NVPTX] Add lowering of i128 params.
The patch adds support of i128 params lowering. The changes are quite trivial to
support i128 as a "special case" of integer type. With this patch, we lower i128
params the same way as aggregates of size 16 bytes: .param .b8 _ [16].
Currently, NVPTX can't deal with the 128 bit integers:
* in some cases because of failed assertions like
ValVTs.size() == OutVals.size() && "Bad return value decomposition"
* in other cases emitting PTX with .i128 or .u128 types (which are not valid [1])
[1] http://docs.nvidia.com/cuda/parallel-thread-execution/index.html#fundamental-types
Differential Revision: https://reviews.llvm.org/D34555
Patch by: Denys Zariaiev (denys.zariaiev@gmail.com)
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@308675 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Basic/Targets.cpp')
-rw-r--r-- | lib/Basic/Targets.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/Basic/Targets.cpp b/lib/Basic/Targets.cpp index 8a5c47b340..01137b66b3 100644 --- a/lib/Basic/Targets.cpp +++ b/lib/Basic/Targets.cpp @@ -1833,9 +1833,9 @@ public: GPU = CudaArch::SM_20; if (TargetPointerWidth == 32) - resetDataLayout("e-p:32:32-i64:64-v16:16-v32:32-n16:32:64"); + resetDataLayout("e-p:32:32-i64:64-i128:128-v16:16-v32:32-n16:32:64"); else - resetDataLayout("e-i64:64-v16:16-v32:32-n16:32:64"); + resetDataLayout("e-i64:64-i128:128-v16:16-v32:32-n16:32:64"); // If possible, get a TargetInfo for our host triple, so we can match its // types. |