This is the mail archive of the mailing list for the GDB project.

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [PATCH] sim: microblaze: target endianess recognition fix

On 05/30/2017 05:50 AM, Andrea Corallo via gdb-patches wrote:
seams the microblaze simulator is missing endianness conversions running on small endian machine.
This small patch does the job for me.
I hope all is ok, is my first contribution so please forgive me in case I'm missing something.


2017-05-30  Andrea Corallo  <>
* interp.c: (target_big_endian): target endianess recognition fix.
sim/microblaze/interp.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/sim/microblaze/interp.c b/sim/microblaze/interp.c
index e619cf8..75fc98b 100644
--- a/sim/microblaze/interp.c
+++ b/sim/microblaze/interp.c
@@ -31,7 +31,7 @@

#include "microblaze-dis.h"

-#define target_big_endian (CURRENT_TARGET_BYTE_ORDER == BIG_ENDIAN)
+#define target_big_endian (CURRENT_TARGET_BYTE_ORDER == BFD_ENDIAN_BIG)

static unsigned long
microblaze_extract_unsigned_integer (unsigned char *addr, int len)

OK to apply.  If you don't have write privileges, let me know.

Michael Eager
1960 Park Blvd., Palo Alto, CA 94306  650-325-8077

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]