Discussion:
[edk2] __executable_start
Narinder Dhillon
2015-08-09 21:20:47 UTC
Permalink
Hi All,

I am building a UEFI image for ARMv7 Cortex A7 SoC. While debugging, I
looked at the objdump of my 'dll' files and notice that entry point offset
is around 0x8000.

Looking at DxeCore.map file I noticed below statement.
Any idea where this 0x8000 offset might be coming from ?

Thanx.

0x0000000000008000 PROVIDE
(__executable_start, 0x8000)
0x0000000000008094 . = (0x8000 +
SIZEOF_HEADERS)
Ard Biesheuvel
2015-08-10 04:16:52 UTC
Permalink
Post by Narinder Dhillon
Hi All,
I am building a UEFI image for ARMv7 Cortex A7 SoC. While debugging, I
looked at the objdump of my 'dll' files and notice that entry point offset
is around 0x8000.
Looking at DxeCore.map file I noticed below statement.
Any idea where this 0x8000 offset might be coming from ?
Thanx.
0x0000000000008000 PROVIDE
(__executable_start, 0x8000)
0x0000000000008094 . = (0x8000 +
SIZEOF_HEADERS)
This is from the builtin linker script that GNU ld uses if you don't
specify one on the command line.

Is this a problem?
--
Ard.

------------------------------------------------------------------------------
Narinder Dhillon
2015-08-10 14:50:19 UTC
Permalink
Not sure if this a problem, yet. Some other architectures don't seem to
have this offset. Perhaps they have a linker script, will check.
Thanx.
Post by Narinder Dhillon
Post by Narinder Dhillon
Hi All,
I am building a UEFI image for ARMv7 Cortex A7 SoC. While debugging, I
looked at the objdump of my 'dll' files and notice that entry point
offset
Post by Narinder Dhillon
is around 0x8000.
Looking at DxeCore.map file I noticed below statement.
Any idea where this 0x8000 offset might be coming from ?
Thanx.
0x0000000000008000 PROVIDE
(__executable_start, 0x8000)
0x0000000000008094 . = (0x8000 +
SIZEOF_HEADERS)
This is from the builtin linker script that GNU ld uses if you don't
specify one on the command line.
Is this a problem?
--
Ard.
Andrew Fish
2015-08-10 16:22:23 UTC
Permalink
Not sure if this a problem, yet. Some other architectures don't seem to have this offset. Perhaps they have a linker script, will check.
Most things are liked at zero, well zero relative to a PE/COFF header. So if the tools produce an ELF image they need to adjust for the PE/COFF header.
When an FV is constructed the SEC, and PEIMs (PE/COFF or TE (shortened PE/COFF header)) are relocated to the correct address in the Flash Device (FD). When modules are loaded into memory they are relocated to their executable address. So in general things are never linked to their executable address.

Thanks,

Andrew Fish
Thanx.
Post by Narinder Dhillon
Hi All,
I am building a UEFI image for ARMv7 Cortex A7 SoC. While debugging, I
looked at the objdump of my 'dll' files and notice that entry point offset
is around 0x8000.
Looking at DxeCore.map file I noticed below statement.
Any idea where this 0x8000 offset might be coming from ?
Thanx.
0x0000000000008000 PROVIDE
(__executable_start, 0x8000)
0x0000000000008094 . = (0x8000 +
SIZEOF_HEADERS)
This is from the builtin linker script that GNU ld uses if you don't
specify one on the command line.
Is this a problem?
--
Ard.
------------------------------------------------------------------------------
_______________________________________________
edk2-devel mailing list
https://lists.sourceforge.net/lists/listinfo/edk2-devel
Continue reading on narkive:
Loading...