diff options
author | ebotcazou <ebotcazou@138bc75d-0d04-0410-961f-82ee72b054a4> | 2010-06-29 09:24:34 +0000 |
---|---|---|
committer | ebotcazou <ebotcazou@138bc75d-0d04-0410-961f-82ee72b054a4> | 2010-06-29 09:24:34 +0000 |
commit | b4b21cd0a5c705f3ed3d47c129866ced3d677071 (patch) | |
tree | a099fe4257b48370bc3e7cbd10d363d74ea4eb12 /gcc/testsuite/gcc.target/i386/extract-6.c | |
parent | 01badd6da78d507b5b8d9447e6ca8e562e583926 (diff) | |
download | gcc-b4b21cd0a5c705f3ed3d47c129866ced3d677071.tar.gz |
PR rtl-optimization/44659
* combine.c (make_compound_operation) <SUBREG>: Do not return the
result of force_to_mode if it partially re-expanded the compound.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@161523 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/testsuite/gcc.target/i386/extract-6.c')
-rw-r--r-- | gcc/testsuite/gcc.target/i386/extract-6.c | 23 |
1 files changed, 23 insertions, 0 deletions
diff --git a/gcc/testsuite/gcc.target/i386/extract-6.c b/gcc/testsuite/gcc.target/i386/extract-6.c new file mode 100644 index 00000000000..1440ec3be35 --- /dev/null +++ b/gcc/testsuite/gcc.target/i386/extract-6.c @@ -0,0 +1,23 @@ +/* { dg-do compile } */ +/* { dg-options "-O2 -mtune=generic" } */ + +typedef struct +{ + unsigned int c1:8; + unsigned int c2:8; + unsigned int c3:8; + unsigned int c4:8; + +} foo_t; + +int +#ifndef __x86_64__ +__attribute__((regparm(3))) +#endif +foo (foo_t x) +{ + return x.c2 > 4; +} + +/* { dg-final { scan-assembler-times "cmp\[b\]?\[^\\n\]*%\[a-z0-9\]+h" 1 } } */ +/* { dg-final { scan-assembler-not "cmp\[b\]?\[^\\n\]*%\[a-z0-9\]+l" } } */ |