diff options
author | Jim Kingdon <jkingdon@engr.sgi.com> | 1991-04-29 05:27:04 +0000 |
---|---|---|
committer | Jim Kingdon <jkingdon@engr.sgi.com> | 1991-04-29 05:27:04 +0000 |
commit | 122ad9abf278d8b86f00d33ff6c1c2e450d4ffc3 (patch) | |
tree | 124d4f1459660d8e78aedef7c0d503c0119ea7ac /gdb/values.c | |
parent | 5d98a45f63af922fd05cb62ea4092fa4bf223b04 (diff) | |
download | gdb-122ad9abf278d8b86f00d33ff6c1c2e450d4ffc3.zip gdb-122ad9abf278d8b86f00d33ff6c1c2e450d4ffc3.tar.gz gdb-122ad9abf278d8b86f00d33ff6c1c2e450d4ffc3.tar.bz2 |
* param-no-tm.h: Make BITS_BIG_ENDIAN defined to 0/1, not defined
or not defined. Don't define it based on TARGET_BYTE_ORDER if
it's already defined (in the tm.h file).
mips-opcode.h (BIT_FIELDS_*),
values.c (modify_field, unpack_field_as_long):
Use #if BITS_BIG_ENDIAN not #ifdef BITS_BIG_ENDIAN.
Diffstat (limited to 'gdb/values.c')
-rw-r--r-- | gdb/values.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/gdb/values.c b/gdb/values.c index e4578a0..2981265 100644 --- a/gdb/values.c +++ b/gdb/values.c @@ -1277,7 +1277,7 @@ unpack_field_as_long (type, valaddr, fieldno) SWAP_TARGET_AND_HOST (&val, sizeof val); /* Extracting bits depends on endianness of the machine. */ -#ifdef BITS_BIG_ENDIAN +#if BITS_BIG_ENDIAN val = val >> (sizeof val * 8 - bitpos % 8 - bitsize); #else val = val >> (bitpos % 8); @@ -1309,7 +1309,7 @@ modify_field (addr, fieldval, bitpos, bitsize) SWAP_TARGET_AND_HOST (&oword, sizeof oword); /* To host format */ /* Shifting for bit field depends on endianness of the target machine. */ -#ifdef BITS_BIG_ENDIAN +#if BITS_BIG_ENDIAN bitpos = sizeof (oword) * 8 - bitpos - bitsize; #endif |