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: byte word and int(32) safe memory access?

On Fri, Aug 22, 2008 at 03:16:48PM +0200, Robin den Hertog wrote:
> the documentation and code of gdb lead me to believe the only time you
> read memory larger than a byte at once is for speed optimization.
> but you're saying that is i request an address with the length at  2
> bytes it will always be read in ONE read action ($m40,2#xx)?
> or
> does it depend on the address size?
> "even if addr is word-aligned and length is a multiple of the word
> size, the stub is free to use byte accesses"
> I figured that meant even $m00004040,4#xx and any length above that
> (but still dividable by 4) you would still be unsure how it is read.
> changing the stub could still mean that as soon as you connect a
> different fpga (to the same cpu) you have to rewrite your stub ?.

In practice GDB will never do byte accesses if you ask for a word.
What your stub does with them is up to the stub.  But you're in
control of the stub, presumably?

Daniel Jacobowitz

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