summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authoraoliva <aoliva@138bc75d-0d04-0410-961f-82ee72b054a4>2001-04-20 09:36:34 +0000
committeraoliva <aoliva@138bc75d-0d04-0410-961f-82ee72b054a4>2001-04-20 09:36:34 +0000
commit86565fe7cc17850befa9d37ab13f701722e488d9 (patch)
tree0856314f6255a283348590436e4d4d414a5450da
parent46b021de99dc2e4a8d95a59ae3c279f9ca4a91fc (diff)
downloadppe42-gcc-86565fe7cc17850befa9d37ab13f701722e488d9.tar.gz
ppe42-gcc-86565fe7cc17850befa9d37ab13f701722e488d9.zip
* config/i386/i386.c (ix86_expand_int_movcc,
ix86_expand_strlensi_unroll_1): Sign-extend CONST_INTs. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@41454 138bc75d-0d04-0410-961f-82ee72b054a4
-rw-r--r--gcc/ChangeLog5
-rw-r--r--gcc/config/i386/i386.c10
2 files changed, 12 insertions, 3 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog
index 03ec2b87bb8..9a3e3127135 100644
--- a/gcc/ChangeLog
+++ b/gcc/ChangeLog
@@ -1,3 +1,8 @@
+2001-04-20 Alexandre Oliva <aoliva@redhat.com>
+
+ * config/i386/i386.c (ix86_expand_int_movcc,
+ ix86_expand_strlensi_unroll_1): Sign-extend CONST_INTs.
+
2001-04-20 Geoff Keating <geoffk@redhat.com>
* config/rs6000/rs6000.md (ctrsi_internal1, ctrsi_internal2,
diff --git a/gcc/config/i386/i386.c b/gcc/config/i386/i386.c
index e6e76fe279e..163b36e5f4d 100644
--- a/gcc/config/i386/i386.c
+++ b/gcc/config/i386/i386.c
@@ -6316,7 +6316,8 @@ ix86_expand_int_movcc (operands)
*
* Size 8 - 11.
*/
- emit_insn (gen_andsi3 (out, out, GEN_INT (cf - ct)));
+ emit_insn (gen_andsi3 (out, out, GEN_INT (trunc_int_for_mode
+ (cf - ct, SImode))));
if (ct)
emit_insn (gen_addsi3 (out, out, GEN_INT (ct)));
}
@@ -6473,7 +6474,8 @@ ix86_expand_int_movcc (operands)
ix86_compare_op1, VOIDmode, 0, 1);
emit_insn (gen_addsi3 (out, out, constm1_rtx));
- emit_insn (gen_andsi3 (out, out, GEN_INT (cf-ct)));
+ emit_insn (gen_andsi3 (out, out, GEN_INT (trunc_int_for_mode
+ (cf - ct, SImode))));
if (ct != 0)
emit_insn (gen_addsi3 (out, out, GEN_INT (ct)));
if (out != operands[0])
@@ -7886,7 +7888,9 @@ ix86_expand_strlensi_unroll_1 (out, align_rtx)
emit_insn (gen_addsi3 (tmpreg, scratch, GEN_INT (-0x01010101)));
emit_insn (gen_one_cmplsi2 (scratch, scratch));
emit_insn (gen_andsi3 (tmpreg, tmpreg, scratch));
- emit_insn (gen_andsi3 (tmpreg, tmpreg, GEN_INT (0x80808080)));
+ emit_insn (gen_andsi3 (tmpreg, tmpreg,
+ GEN_INT (trunc_int_for_mode
+ (0x80808080, SImode))));
emit_cmp_and_jump_insns (tmpreg, const0_rtx, EQ, 0,
SImode, 1, 0, align_4_label);
OpenPOWER on IntegriCloud