diff options
author | Martin Liska <mliska@suse.cz> | 2020-03-19 16:55:59 +0100 |
---|---|---|
committer | Martin Liska <mliska@suse.cz> | 2020-03-19 16:55:59 +0100 |
commit | f5389e17e4b8cfd4877082b46d31d1db3341a0aa (patch) | |
tree | 0d9f790cfd0c52d89203644ec1d80c7ae61626ac /include | |
parent | 02f7334ac93f53ed06d881beb611e88be36dc56a (diff) | |
download | gcc-f5389e17e4b8cfd4877082b46d31d1db3341a0aa.zip gcc-f5389e17e4b8cfd4877082b46d31d1db3341a0aa.tar.gz gcc-f5389e17e4b8cfd4877082b46d31d1db3341a0aa.tar.bz2 |
Update include/plugin-api.h.
* plugin-api.h (struct ld_plugin_symbol): Split
int def into 4 char fields.
(enum ld_plugin_symbol_type): New.
(enum ld_plugin_symbol_section_kind): New.
(enum ld_plugin_tag): Add LDPT_ADD_SYMBOLS_V2.
Diffstat (limited to 'include')
-rw-r--r-- | include/ChangeLog | 8 | ||||
-rw-r--r-- | include/plugin-api.h | 32 |
2 files changed, 38 insertions, 2 deletions
diff --git a/include/ChangeLog b/include/ChangeLog index 3f9382d..8c79e73 100644 --- a/include/ChangeLog +++ b/include/ChangeLog @@ -1,3 +1,11 @@ +2020-03-19 Martin Liska <mliska@suse.cz> + + * plugin-api.h (struct ld_plugin_symbol): Split + int def into 4 char fields. + (enum ld_plugin_symbol_type): New. + (enum ld_plugin_symbol_section_kind): New. + (enum ld_plugin_tag): Add LDPT_ADD_SYMBOLS_V2. + 2020-02-05 Andrew Burgess <andrew.burgess@embecosm.com> * hashtab.h (htab_remove_elt): Make a parameter const. diff --git a/include/plugin-api.h b/include/plugin-api.h index 09e1202..f0f9667 100644 --- a/include/plugin-api.h +++ b/include/plugin-api.h @@ -87,7 +87,19 @@ struct ld_plugin_symbol { char *name; char *version; - int def; + /* This is for compatibility with older ABIs. The older ABI defined + only 'def' field. */ +#ifdef __BIG_ENDIAN__ + char unused; + char section_kind; + char symbol_type; + char def; +#else + char def; + char symbol_type; + char section_kind; + char unused; +#endif int visibility; uint64_t size; char *comdat_key; @@ -123,6 +135,21 @@ enum ld_plugin_symbol_visibility LDPV_HIDDEN }; +/* The type of the symbol. */ + +enum ld_plugin_symbol_type +{ + LDST_UNKNOWN, + LDST_FUNCTION, + LDST_VARIABLE, +}; + +enum ld_plugin_symbol_section_kind +{ + LDSSK_DEFAULT, + LDSSK_BSS +}; + /* How a symbol is resolved. */ enum ld_plugin_symbol_resolution @@ -431,7 +458,8 @@ enum ld_plugin_tag LDPT_GET_INPUT_SECTION_ALIGNMENT = 29, LDPT_GET_INPUT_SECTION_SIZE = 30, LDPT_REGISTER_NEW_INPUT_HOOK = 31, - LDPT_GET_WRAP_SYMBOLS = 32 + LDPT_GET_WRAP_SYMBOLS = 32, + LDPT_ADD_SYMBOLS_V2 = 33 }; /* The plugin transfer vector. */ |