On 04/11/2016 11:25, Julian Brown wrote: > > The change to arm_cpu_memory_rw_debug for BE32 is also interesting. > > gdb documentation says > > > > The stub need not use any particular size or alignment when > > gathering data from memory for the response; even if ADDR is > > word-aligned and LENGTH is a multiple of the word size, the stub > > is free to use byte accesses, or not. > > > > while your change means that gdb actually wants you to do byte > > accesses. > > The splitting-into-bytes is just an implementation convenience -- the > simplest way I could see of handling the low-order address bit reversal > without breaking abstractions more or shuffling lots of code around. > I'm not sure if GDB was actually requesting sub-word access sizes.
Right, the question is what GDB actually wants. I don't really understand how BE32 is compatible with "the stub need not use any particular size or alignment", unless GDB takes care of tweaking the address on its end (and possibly taking care of always reading full words when len>4?!?). Also, it would not depend on SCTLR.B, but rather on the CFGEND property and on CFGEND being tied to SCTLR.B. Thanks, Paolo