Help needed in output relocations

Rishi Raj rishiraj45035@gmail.com
Wed Oct 18 14:33:46 GMT 2023


Hello,
I have almost completed the output of relocation entries. The only thing
that remains is to output the corresponding symbols in .symtab. In my
current design, I store the info about relocation entry and the symbol
name. However, the problem I am facing with this approach is that many
relocation entries will have the same name, so we will need a hash table
with the key as symbol name and value as symbol index in symtab. It would
be really helpful if you could point out the relevant docs or help me
figure out how to use the hash table in GCC.
Another approach is, as we have only 4-5 unique relocation symbol names. We
can output just those and store their .symtab index somewhere.

--
Rishi


More information about the Gcc mailing list