From f145fac4afd9586470a3337fe49279ad4a289b33 Mon Sep 17 00:00:00 2001 From: jakub Date: Mon, 10 May 2010 18:28:03 +0000 Subject: PR debug/44028 * haifa-sched.c (schedule_insn): When clearing INSN_VAR_LOCATION_LOC, clear also INSN_REG_USE_LIST. * gcc.dg/pr44028.c: New test. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@159240 138bc75d-0d04-0410-961f-82ee72b054a4 --- gcc/testsuite/gcc.dg/pr44028.c | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) create mode 100644 gcc/testsuite/gcc.dg/pr44028.c (limited to 'gcc/testsuite/gcc.dg/pr44028.c') diff --git a/gcc/testsuite/gcc.dg/pr44028.c b/gcc/testsuite/gcc.dg/pr44028.c new file mode 100644 index 00000000000..33452172bd7 --- /dev/null +++ b/gcc/testsuite/gcc.dg/pr44028.c @@ -0,0 +1,22 @@ +/* PR debug/44028 */ +/* { dg-do compile } */ +/* { dg-options "-O3 -fcompare-debug" } */ +/* { dg-options "-O3 -fsched-pressure -fschedule-insns -fcompare-debug" { target i?86-*-* x86_64-*-* } } */ + +struct S { int val[16]; }; + +static inline int +bar (struct S x) +{ + long double pc = 0; + int i; + for (i = 0; i < 16; i++) + pc += x.val[i]; + return pc; +} + +int +foo (struct S x) +{ + return bar (x); +} -- cgit v1.2.1