[llvm] ff6b074 - [NFC] Added testcase for PR25725
Dávid Bolvanský via llvm-commits
llvm-commits at lists.llvm.org
Fri Sep 17 06:49:02 PDT 2021
Author: Dávid Bolvanský
Date: 2021-09-17T15:48:55+02:00
New Revision: ff6b074674f063295c4aadda394feb032449d86e
URL: https://github.com/llvm/llvm-project/commit/ff6b074674f063295c4aadda394feb032449d86e
DIFF: https://github.com/llvm/llvm-project/commit/ff6b074674f063295c4aadda394feb032449d86e.diff
LOG: [NFC] Added testcase for PR25725
Added:
llvm/test/CodeGen/X86/pr25725.ll
Modified:
Removed:
################################################################################
diff --git a/llvm/test/CodeGen/X86/pr25725.ll b/llvm/test/CodeGen/X86/pr25725.ll
new file mode 100644
index 0000000000000..1b5100c866120
--- /dev/null
+++ b/llvm/test/CodeGen/X86/pr25725.ll
@@ -0,0 +1,35 @@
+; NOTE: Assertions have been autogenerated by utils/update_llc_test_checks.py
+
+; RUN: llc < %s -mtriple=x86_64-pc-linux | FileCheck %s --check-prefix=X64
+; RUN: llc < %s -mtriple=i386-pc-linux | FileCheck %s --check-prefix=X86
+
+%struct.s = type { [100 x i32] }
+
+define void @f(%struct.s* nocapture %s) #0 {
+; X64-LABEL: f:
+; X64: # %bb.0: # %entry
+; X64-NEXT: xorps %xmm0, %xmm0
+; X64-NEXT: movups %xmm0, 48(%rdi)
+; X64-NEXT: movups %xmm0, 32(%rdi)
+; X64-NEXT: movups %xmm0, 16(%rdi)
+; X64-NEXT: movups %xmm0, (%rdi)
+; X64-NEXT: retq
+;
+; X86-LABEL: f:
+; X86: # %bb.0: # %entry
+; X86-NEXT: movl {{[0-9]+}}(%esp), %eax
+; X86-NEXT: xorps %xmm0, %xmm0
+; X86-NEXT: movups %xmm0, 48(%eax)
+; X86-NEXT: movups %xmm0, 32(%eax)
+; X86-NEXT: movups %xmm0, 16(%eax)
+; X86-NEXT: movups %xmm0, (%eax)
+; X86-NEXT: retl
+entry:
+ %s5 = bitcast %struct.s* %s to i8*
+ call void @llvm.memset.p0i8.i32(i8* noundef nonnull align 4 dereferenceable(64) %s5, i8 0, i32 64, i1 false)
+ ret void
+}
+
+declare void @llvm.memset.p0i8.i32(i8* nocapture writeonly, i8, i32, i1 immarg)
+
+attributes #0 = { "target-features"="+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
More information about the llvm-commits
mailing list