The ddpi_elf_get_csect_addrs operation queries
the CSECT addresses for the ELF object and extracts the high and low addresses.
Description
ddpi_elf_get_csect_addrs function
helps to select and load a CU when there are multiple CUs from which to choose.
Prototype
int ddpi_elf_get_csect_addrs(
Ddpi_Elf d_elf,
Dwarf_Addr* ret_low_addr,
Dwarf_Addr* ret_high_addr,
Ddpi_Error* error);
Parameters
- d_elf
- Input. This accepts a Ddpi_Elf object.
- ret_low_addr
- Output. This returns the lowest known address in CSECT (the first byte
of the object). (Dwarf_Addr)-1 is not an acceptable value
address.
- ret_high_addr
- Output. This returns the highest known address in CSECT (the last byte
of the object). (Dwarf_Addr)-1 is not an acceptable value
address.
Note: ret_low_addr and ret_high_addr are
not guaranteed to enclose all control blocks. They are guaranteed to enclose
all executable code for the given CU if they are set to a value that is not
-1.
- error
- See The libddpi error parameter.
Return values
- DW_DLV_OK
- Returned upon successful return of the high and low addresses.
- DW_DLV_NO_ENTRY
- Never returned.
- DW_DLV_ERROR
- This value is returned if:
- elf is NULL.
- The Ddpi_Access or Ddpi_Info object associated with elf is
NULL.