[PATCH] D136929: [Statepoint] Use default attributes for some GC intrinsics

Nikita Popov via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue Nov 8 00:32:37 PST 2022


This revision was automatically updated to reflect the committed changes.
Closed by commit rG3ddf56fd37b8: [Statepoint] Use default attributes for some GC intrinsics (authored by nikic).

Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D136929/new/

https://reviews.llvm.org/D136929

Files:
  llvm/include/llvm/IR/Intrinsics.td
  llvm/test/Transforms/RewriteStatepointsForGC/statepoint-attrs.ll


Index: llvm/test/Transforms/RewriteStatepointsForGC/statepoint-attrs.ll
===================================================================
--- llvm/test/Transforms/RewriteStatepointsForGC/statepoint-attrs.ll
+++ llvm/test/Transforms/RewriteStatepointsForGC/statepoint-attrs.ll
@@ -20,6 +20,6 @@
 
 attributes #1 = { norecurse noimplicitfloat }
 ;.
-; CHECK: attributes #[[ATTR0:[0-9]+]] = { nounwind memory(none) }
+; CHECK: attributes #[[ATTR0:[0-9]+]] = { nocallback nofree nosync nounwind willreturn memory(none) }
 ; CHECK: attributes #[[ATTR1]] = { noimplicitfloat norecurse }
 ;.
Index: llvm/include/llvm/IR/Intrinsics.td
===================================================================
--- llvm/include/llvm/IR/Intrinsics.td
+++ llvm/include/llvm/IR/Intrinsics.td
@@ -1256,21 +1256,20 @@
                                 ImmArg<ArgIndex<1>>, ImmArg<ArgIndex<3>>,
                                 ImmArg<ArgIndex<4>>]>;
 
-def int_experimental_gc_result   : Intrinsic<[llvm_any_ty], [llvm_token_ty],
-                                             [IntrNoMem]>;
-def int_experimental_gc_relocate : Intrinsic<[llvm_any_ty],
-                                             [llvm_token_ty, llvm_i32_ty,
-                                              llvm_i32_ty],
-                                             [IntrNoMem, ImmArg<ArgIndex<1>>,
-                                              ImmArg<ArgIndex<2>>]>;
-
-def int_experimental_gc_get_pointer_base : Intrinsic<[llvm_anyptr_ty],
-                 [llvm_anyptr_ty], [IntrNoMem, IntrWillReturn,
-                 ReadNone<ArgIndex<0>>, NoCapture<ArgIndex<0>>]>;
-
-def int_experimental_gc_get_pointer_offset : Intrinsic<[llvm_i64_ty],
-                 [llvm_anyptr_ty], [IntrNoMem, IntrWillReturn,
-                 ReadNone<ArgIndex<0>>, NoCapture<ArgIndex<0>>]>;
+def int_experimental_gc_result : DefaultAttrsIntrinsic<
+    [llvm_any_ty], [llvm_token_ty], [IntrNoMem]>;
+
+def int_experimental_gc_relocate : DefaultAttrsIntrinsic<
+    [llvm_any_ty], [llvm_token_ty, llvm_i32_ty, llvm_i32_ty],
+    [IntrNoMem, ImmArg<ArgIndex<1>>, ImmArg<ArgIndex<2>>]>;
+
+def int_experimental_gc_get_pointer_base : DefaultAttrsIntrinsic<
+    [llvm_anyptr_ty], [llvm_anyptr_ty],
+    [IntrNoMem, IntrWillReturn, ReadNone<ArgIndex<0>>, NoCapture<ArgIndex<0>>]>;
+
+def int_experimental_gc_get_pointer_offset : DefaultAttrsIntrinsic<
+    [llvm_i64_ty], [llvm_anyptr_ty],
+    [IntrNoMem, IntrWillReturn, ReadNone<ArgIndex<0>>, NoCapture<ArgIndex<0>>]>;
 
 //===------------------------ Coroutine Intrinsics ---------------===//
 // These are documented in docs/Coroutines.rst


-------------- next part --------------
A non-text attachment was scrubbed...
Name: D136929.473899.patch
Type: text/x-patch
Size: 2624 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20221108/00217b93/attachment.bin>


More information about the llvm-commits mailing list