From 4d73ab0bbcdbefb4bbd46c3aaf000539446544e6 Mon Sep 17 00:00:00 2001 From: YAMAMOTO Takashi Date: Thu, 1 May 2025 08:54:52 +0900 Subject: [PATCH] aot_resolve_object_relocation_group: adapt to LLVM 19 cf. https://github.com/llvm/llvm-project/pull/95031 https://github.com/llvm/llvm-project/pull/89693 --- core/iwasm/compilation/aot_emit_aot_file.c | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/core/iwasm/compilation/aot_emit_aot_file.c b/core/iwasm/compilation/aot_emit_aot_file.c index 5a7ba9e74..097727d13 100644 --- a/core/iwasm/compilation/aot_emit_aot_file.c +++ b/core/iwasm/compilation/aot_emit_aot_file.c @@ -4011,6 +4011,15 @@ aot_resolve_object_relocation_group(AOTObjectData *obj_data, #if LLVM_VERSION_MAJOR >= 16 /* cf. https://reviews.llvm.org/D123264 */ || str_starts_with(relocation->symbol_name, ".Lpcrel_hi") +#endif +#if LLVM_VERSION_MAJOR >= 19 + /* cf. + * https://github.com/llvm/llvm-project/pull/95031 + * https://github.com/llvm/llvm-project/pull/89693 + * + * note: the trailing space in ".L0 " is intentional. */ + || !strcmp(relocation->symbol_name, "") + || !strcmp(relocation->symbol_name, ".L0 ") #endif )) { /* change relocation->relocation_addend and