[PATCH] D103975: [Attributor] Set floating point loads and stores as nofree in AANoFreeFloating
Joseph Huber via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Wed Jun 9 10:13:47 PDT 2021
jhuber6 created this revision.
jhuber6 added reviewers: jdoerfert, sstefan1.
Herald added subscribers: ormris, okura, kuter, uenoku, hiraditya.
Herald added a reviewer: uenoku.
Herald added a reviewer: homerdin.
jhuber6 requested review of this revision.
Herald added a reviewer: baziotis.
Herald added subscribers: llvm-commits, bbn.
Herald added a project: LLVM.
The current implementation of `AANoFreeFloating` will incorrectly list floating
point loads and stores as may-free. This prevents other attributor instances
like HeapToStack from pushing some allocations to the stack.
Repository:
rG LLVM Github Monorepo
https://reviews.llvm.org/D103975
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
@@ -1499,7 +1499,8 @@
Follow = true;
return true;
}
- if (isa<ReturnInst>(UserI))
+ if (isa<LoadInst>(UserI) || isa<StoreInst>(UserI) ||
+ isa<ReturnInst>(UserI))
return true;
// Unknown user.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D103975.350938.patch
Type: text/x-patch
Size: 485 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20210609/c69e8696/attachment.bin>
More information about the llvm-commits
mailing list