[PATCH] D69496: Attributor: Move list of opcodes

Matt Arsenault via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue Nov 15 22:55:35 PST 2022


arsenm updated this revision to Diff 475691.
arsenm added a comment.
Herald added a reviewer: sstefan1.
Herald added subscribers: ormris, okura, kuter.
Herald added a project: All.

Rebase. checkForAllCallLikeInstructions seems to have a subset for some reason


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

https://reviews.llvm.org/D69496

Files:
  llvm/lib/Transforms/IPO/AttributorAttributes.cpp


Index: llvm/lib/Transforms/IPO/AttributorAttributes.cpp
===================================================================
--- llvm/lib/Transforms/IPO/AttributorAttributes.cpp
+++ llvm/lib/Transforms/IPO/AttributorAttributes.cpp
@@ -101,6 +101,13 @@
 
 STATISTIC(NumAAs, "Number of abstract attributes created");
 
+
+static const unsigned CallLikeOpcodes[] = {
+  Instruction::Call, Instruction::Invoke,
+  Instruction::CatchSwitch, Instruction::Resume,
+  Instruction::CleanupRet, Instruction::CallBr
+};
+
 // Some helper macros to deal with statistics tracking.
 //
 // Usage:
@@ -1633,7 +1640,7 @@
     };
 
     bool UsedAssumedInformation = false;
-    if (!A.checkForAllInstructions(CheckForNoUnwind, *this, Opcodes,
+    if (!A.checkForAllInstructions(CheckForNoUnwind, *this, CallLikeOpcodes,
                                    UsedAssumedInformation))
       return indicatePessimisticFixpoint();
 


-------------- next part --------------
A non-text attachment was scrubbed...
Name: D69496.475691.patch
Type: text/x-patch
Size: 912 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20221116/ad413248/attachment.bin>


More information about the llvm-commits mailing list