[PATCH] D137029: [test][InstCombine] Add a test case for volatile memcpy forwarding in InstCombine, which is currently optimized incorrectly.
Patrick Walton via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Sun Oct 30 02:39:00 PDT 2022
This revision was automatically updated to reflect the committed changes.
Closed by commit rG8357ff6f3d6d: [test][InstCombine] Add a test case for volatile memcpy forwarding in… (authored by pcwalton).
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D137029/new/
https://reviews.llvm.org/D137029
Files:
llvm/test/Transforms/InstCombine/memcpy-from-global.ll
Index: llvm/test/Transforms/InstCombine/memcpy-from-global.ll
===================================================================
--- llvm/test/Transforms/InstCombine/memcpy-from-global.ll
+++ llvm/test/Transforms/InstCombine/memcpy-from-global.ll
@@ -366,4 +366,16 @@
ret void
}
+; FIXME: Test that we incorrectly elide a volatile memcpy.
+define void @volatile_memcpy() {
+; CHECK-LABEL: @volatile_memcpy(
+; CHECK-NEXT: call void @bar(ptr nonnull @H) #[[ATTR3]]
+; CHECK-NEXT: ret void
+;
+ %A = alloca %U, align 16
+ call void @llvm.memcpy.p0.p0.i64(ptr align 4 %A, ptr align 4 @H, i64 20, i1 true)
+ call void @bar(ptr %A) readonly
+ ret void
+}
+
attributes #0 = { null_pointer_is_valid }
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D137029.471823.patch
Type: text/x-patch
Size: 712 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20221030/30d3f17a/attachment.bin>
More information about the llvm-commits
mailing list