This is the mail archive of the
mailing list for the GDB project.
Re: Bug in i386_process_record?
> From: Hui Zhu <email@example.com>
> Date: Mon, 24 Aug 2009 08:00:29 +0800
> Cc: firstname.lastname@example.org
> #rep stos %eax,%es:(%edi)
> $edi + 0 = 0x8049660 blob1
> $edi + $es != 0x8049660 blob1
Well, of course! %es:(%edi) does _not_ mean $es+$edi, it means that
$edi is used to address the section whose segment descriptor's index
(a.k.a. selector) is in $es. That is, in your case, 0x7b is the
selector that identifies the segment descriptor of the section where
blob1 is stored (.bss, if my rusty memory doesn't deceive me).
Am I missing something? If not, what was this example supposed to