diff options
author | Hans-Peter Nilsson <hp@axis.com> | 2005-05-12 23:36:46 +0000 |
---|---|---|
committer | Hans-Peter Nilsson <hp@gcc.gnu.org> | 2005-05-12 23:36:46 +0000 |
commit | 2239ced8316c6cd2b3598e7e4dbeaa751479dba8 (patch) | |
tree | 13bb25304aabeb8eb7b62117bb560210f57e41a7 | |
parent | a930a4efe71a7e8d3fa0279efb3952f482f61927 (diff) | |
download | gcc-2239ced8316c6cd2b3598e7e4dbeaa751479dba8.zip gcc-2239ced8316c6cd2b3598e7e4dbeaa751479dba8.tar.gz gcc-2239ced8316c6cd2b3598e7e4dbeaa751479dba8.tar.bz2 |
cris.c (cris_print_operand): Use operand_subword and HOST_WIDE_INT_PRINT_DEC for output...
* config/cris/cris.c (cris_print_operand) <case 'H'; case
CONST_INT>: Use operand_subword and HOST_WIDE_INT_PRINT_DEC for
output; don't have special case for HOST_BITS_PER_WIDE_INT == 32.
From-SVN: r99635
-rw-r--r-- | gcc/ChangeLog | 6 | ||||
-rw-r--r-- | gcc/config/cris/cris.c | 9 |
2 files changed, 10 insertions, 5 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog index f88fbf4..aec423e 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,9 @@ +2005-05-13 Hans-Peter Nilsson <hp@axis.com> + + * config/cris/cris.c (cris_print_operand) <case 'H'; case + CONST_INT>: Use operand_subword and HOST_WIDE_INT_PRINT_DEC for + output; don't have special case for HOST_BITS_PER_WIDE_INT == 32. + 2005-05-13 Jan Hubicka <jh@suse.cz> * basic-block.h (FOR_ALL_BB_FN): New macro. diff --git a/gcc/config/cris/cris.c b/gcc/config/cris/cris.c index 19d250c..f9a7d1e 100644 --- a/gcc/config/cris/cris.c +++ b/gcc/config/cris/cris.c @@ -845,11 +845,10 @@ cris_print_operand (FILE *file, rtx x, int code) switch (GET_CODE (operand)) { case CONST_INT: - if (HOST_BITS_PER_WIDE_INT == 32) - /* Sign-extension from a normal int to a long long. */ - fprintf (file, INTVAL (operand) < 0 ? "-1" : "0"); - else - fprintf (file, "0x%x", (unsigned int)(INTVAL (x) >> 31 >> 1)); + /* If we're having 64-bit HOST_WIDE_INTs, the whole (DImode) + value is kept here, and so may be other than 0 or -1. */ + fprintf (file, HOST_WIDE_INT_PRINT_DEC, + INTVAL (operand_subword (operand, 1, 0, DImode))); return; case CONST_DOUBLE: |