Re: call instruction question

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Wed, Jan 9, 2013 at 10:19 AM, horseriver <horserivers@xxxxxxxxx> wrote:
>
> here is the disassembly code ,
>
>  629:   0f 84 0e 01 00 00       je     73d <acpi_ec_add+0x125>
>  62f:   68 d0 00 00 00          push   $0xd0
>  634:   ff 35 10 00 00 00       pushl  0x10
>  63a:   e8 fc ff ff ff          call   63b <acpi_ec_add+0x23>
>  63f:   89 c3                   mov    %eax,%ebx
>  641:   5f                      pop    %edi
>  642:   58                      pop    %eax
>  643:   b8 f4 ff ff ff          mov    $0xfffffff4,%eax
>
>
>  look at the code at 63a address :
>
>                    63a:   e8 fc ff ff ff          call   63b <acpi_ec_add+0x23>
>
>  e8 is a CALL instruction , but , obviously , 63b is not a subroutin address ,so how does this "call 63b " generate?
>
>  amd what does it do ?

You are looking at an object file, not an executable.  There is a
relocation associated with that address.  The linker will use the
relocation to fill in the final address when you link the object file
into an executable.

If you are using "objdump -d" to get the above disassembly, use
"objdump -dr" to also see the relocation information.

Ian


[Index of Archives]     [Linux C Programming]     [Linux Kernel]     [eCos]     [Fedora Development]     [Fedora Announce]     [Autoconf]     [The DWARVES Debugging Tools]     [Yosemite Campsites]     [Yosemite News]     [Linux GCC]

  Powered by Linux