An SHT_LLVM_LTO section contains LLVM bitcode. An SHT_LLVM_ADDRSIG
section contains ULEB128 integers referring to the symbol table
indexes of address-significant symbols. This patch just recognizes the
SHT constants but doesn't handle the section contents.
* libebl/eblsectiontypename.c (ebl_section_type_name):
Recognize SHT_LLVM_ADDRSIG and SHT_LLVM_LTO.
Signed-off-by: Mark Wielaard <[email protected]>
---
libebl/eblsectiontypename.c | 16 ++++++++++++++++
1 file changed, 16 insertions(+)
diff --git a/libebl/eblsectiontypename.c b/libebl/eblsectiontypename.c
index ade25d4a5701..5b64a1e29646 100644
--- a/libebl/eblsectiontypename.c
+++ b/libebl/eblsectiontypename.c
@@ -102,6 +102,22 @@ ebl_section_type_name (Ebl *ebl, int section, char *buf,
size_t len)
res = "GNU_ATTRIBUTES";
break;
+ /* A few LLVM additions. */
+
+#ifndef SHT_LLVM_ADDRSIG
+#define SHT_LLVM_ADDRSIG 0x6fff4c03
+#endif
+ case SHT_LLVM_ADDRSIG:
+ res = "LLVM_ADDRSIG";
+ break;
+
+#ifndef SHT_LLVM_LTO
+#define SHT_LLVM_LTO 0x6fff4c0c
+#endif
+ case SHT_LLVM_LTO:
+ res = "LLVM_LTO";
+ break;
+
default:
/* Handle OS-specific section names. */
if (section >= SHT_LOOS && section <= SHT_HIOS)
--
2.52.0