In gdb I'm a bix perplexed as to why sometimes it prints bytes left-to-right and sometimes right-to-left. Here is an example where no instruction has been run in between:
>>> x/4b $rbp-4
0x7fffffffe43c: 0x04 0x00 0x03 0x16
>>> x/2h $rbp-4
0x7fffffffe43c: 0x0004 0x1603
Why is this done in gdb? I would think it would always print them as:
04 00 03 16