aboutsummaryrefslogtreecommitdiff
path: root/gcc/testsuite/gcc.target/i386/pr92080-17.c
diff options
context:
space:
mode:
Diffstat (limited to 'gcc/testsuite/gcc.target/i386/pr92080-17.c')
-rw-r--r--gcc/testsuite/gcc.target/i386/pr92080-17.c40
1 files changed, 40 insertions, 0 deletions
diff --git a/gcc/testsuite/gcc.target/i386/pr92080-17.c b/gcc/testsuite/gcc.target/i386/pr92080-17.c
new file mode 100644
index 0000000..c1d5f42
--- /dev/null
+++ b/gcc/testsuite/gcc.target/i386/pr92080-17.c
@@ -0,0 +1,40 @@
+/* { dg-do compile } */
+/* { dg-options "-O2 -march=x86-64-v3 -fasynchronous-unwind-tables -fdwarf2-cfi-asm" } */
+/* Keep labels and directives ('.cfi_startproc', '.cfi_endproc'). */
+/* { dg-final { check-function-bodies "**" "" "" { target { ! ia32 } } {^\t?\.} } } */
+
+/*
+**foo:
+**.LFB0:
+** .cfi_startproc
+** vpbroadcastw cost\(%rip\), %xmm0
+** vmovq %xmm0, cost1\(%rip\)
+** vmovdqu %xmm0, cost2\(%rip\)
+** ret
+**...
+*/
+
+extern struct {
+ short cost[4];
+} cost1;
+extern struct {
+ short cost[8];
+} cost2;
+extern int cost;
+
+void
+foo (void)
+{
+ cost1.cost[0] = cost;
+ cost1.cost[1] = cost;
+ cost1.cost[2] = cost;
+ cost1.cost[3] = cost;
+ cost2.cost[0] = cost;
+ cost2.cost[1] = cost;
+ cost2.cost[2] = cost;
+ cost2.cost[3] = cost;
+ cost2.cost[4] = cost;
+ cost2.cost[5] = cost;
+ cost2.cost[6] = cost;
+ cost2.cost[7] = cost;
+}