r297224 - [coroutines] update coro_end builtin to match llvm
Gor Nishanov via cfe-commits
cfe-commits at lists.llvm.org
Tue Mar 7 13:01:08 PST 2017
Author: gornishanov
Date: Tue Mar 7 15:01:08 2017
New Revision: 297224
URL: http://llvm.org/viewvc/llvm-project?rev=297224&view=rev
Log:
[coroutines] update coro_end builtin to match llvm
Summary: llvm.coro.end intrinsic now returns bool. Updating clang to match it.
Reviewers: GorNishanov, rsmith
Reviewed By: rsmith
Subscribers: mehdi_amini, cfe-commits, EricWF
Differential Revision: https://reviews.llvm.org/D30711
Modified:
cfe/trunk/include/clang/Basic/Builtins.def
cfe/trunk/test/CodeGenCoroutines/coro-builtins.c
Modified: cfe/trunk/include/clang/Basic/Builtins.def
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/include/clang/Basic/Builtins.def?rev=297224&r1=297223&r2=297224&view=diff
==============================================================================
--- cfe/trunk/include/clang/Basic/Builtins.def (original)
+++ cfe/trunk/include/clang/Basic/Builtins.def Tue Mar 7 15:01:08 2017
@@ -1365,7 +1365,7 @@ BUILTIN(__builtin_coro_free, "v*v*", "n"
BUILTIN(__builtin_coro_id, "v*Iiv*v*v*", "n")
BUILTIN(__builtin_coro_alloc, "b", "n")
BUILTIN(__builtin_coro_begin, "v*v*", "n")
-BUILTIN(__builtin_coro_end, "vv*Ib", "n")
+BUILTIN(__builtin_coro_end, "bv*Ib", "n")
BUILTIN(__builtin_coro_suspend, "cIb", "n")
BUILTIN(__builtin_coro_param, "bv*v*", "n")
// OpenCL v2.0 s6.13.16, s9.17.3.5 - Pipe functions.
Modified: cfe/trunk/test/CodeGenCoroutines/coro-builtins.c
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/test/CodeGenCoroutines/coro-builtins.c?rev=297224&r1=297223&r2=297224&view=diff
==============================================================================
--- cfe/trunk/test/CodeGenCoroutines/coro-builtins.c (original)
+++ cfe/trunk/test/CodeGenCoroutines/coro-builtins.c Tue Mar 7 15:01:08 2017
@@ -43,7 +43,7 @@ void f(int n) {
__builtin_coro_free(__builtin_coro_frame());
// CHECK-NEXT: %[[FRAME6:.+]] = call i8* @llvm.coro.frame()
- // CHECK-NEXT: call void @llvm.coro.end(i8* %[[FRAME6]], i1 false)
+ // CHECK-NEXT: call i1 @llvm.coro.end(i8* %[[FRAME6]], i1 false)
__builtin_coro_end(__builtin_coro_frame(), 0);
// CHECK-NEXT: call i8 @llvm.coro.suspend(token none, i1 true)
More information about the cfe-commits
mailing list