diff options
author | Mike Frysinger <vapier@gentoo.org> | 2021-06-15 20:20:11 -0400 |
---|---|---|
committer | Mike Frysinger <vapier@gentoo.org> | 2021-06-16 01:03:54 -0400 |
commit | 430456e34753ac705a047c886eb4f73cf2906dfc (patch) | |
tree | 0c46e6372c85dd346f9a3bd25f7885eac1669335 /sim/ppc/psim.c | |
parent | dae666c968ac9f053dc5dfe1a6ceaf333a8ca94d (diff) | |
download | gdb-430456e34753ac705a047c886eb4f73cf2906dfc.zip gdb-430456e34753ac705a047c886eb4f73cf2906dfc.tar.gz gdb-430456e34753ac705a047c886eb4f73cf2906dfc.tar.bz2 |
sim: ppc: drop host endian configure option
The --enable-sim-hostendian flag was purely so people had an escape route
for when cross-compiling. This is because historically, AC_C_BIGENDIAN
did not work in those cases. That was fixed a while ago though, so we can
require that macro everywhere now and simplify a good bit of code.
This was done for all the other ports years ago, so catch ppc up.
Diffstat (limited to 'sim/ppc/psim.c')
-rw-r--r-- | sim/ppc/psim.c | 13 |
1 files changed, 2 insertions, 11 deletions
diff --git a/sim/ppc/psim.c b/sim/ppc/psim.c index 70c02f7..0c3f5a1 100644 --- a/sim/ppc/psim.c +++ b/sim/ppc/psim.c @@ -64,7 +64,6 @@ struct _psim { int current_target_byte_order; -int current_host_byte_order; int current_environment; int current_alignment; int current_floating_point; @@ -456,14 +455,6 @@ psim_create(const char *file_name, if (CURRENT_TARGET_BYTE_ORDER != current_target_byte_order) error("target and configured byte order conflict\n"); - /* fill in the missing HOST BYTE ORDER information */ - current_host_byte_order = (current_host_byte_order = 1, - (*(char*)(¤t_host_byte_order) - ? LITTLE_ENDIAN - : BIG_ENDIAN)); - if (CURRENT_HOST_BYTE_ORDER != current_host_byte_order) - error("host and configured byte order conflict\n"); - /* fill in the missing OEA/VEA information */ env = tree_find_string_property(root, "/openprom/options/env"); current_environment = ((strcmp(env, "user") == 0 @@ -917,7 +908,7 @@ psim_read_register(psim *system, break; #ifdef WITH_ALTIVEC case 16: - if (CURRENT_HOST_BYTE_ORDER != CURRENT_TARGET_BYTE_ORDER) + if (HOST_BYTE_ORDER != CURRENT_TARGET_BYTE_ORDER) { union { vreg v; unsigned_8 d[2]; } h, t; memcpy(&h.v/*dest*/, cooked_buf/*src*/, description.size); @@ -996,7 +987,7 @@ psim_write_register(psim *system, break; #ifdef WITH_ALTIVEC case 16: - if (CURRENT_HOST_BYTE_ORDER != CURRENT_TARGET_BYTE_ORDER) + if (HOST_BYTE_ORDER != CURRENT_TARGET_BYTE_ORDER) { union { vreg v; unsigned_8 d[2]; } h, t; memcpy(&t.v/*dest*/, buf/*src*/, description.size); |