loader/aarch64: attempt to avoid text relocations in the unknown code
authorDave Airlie <airlied@redhat.com>
Mon, 13 Dec 2021 04:48:31 +0000 (23:48 -0500)
committerCharles Giessen <46324611+charles-lunarg@users.noreply.github.com>
Wed, 15 Dec 2021 02:21:01 +0000 (19:21 -0700)
loader/unknown_ext_chain_gas_aarch64.S

index 1e065007da34d0385acae215f6e4d1258bce9e2a..96d7ba0a04f21bcd40953c7d36811ce8b8e987a8 100644 (file)
@@ -50,7 +50,8 @@ terminError\num:
     mov     x0, x11                             // Vulkan instance pointer (first arg)
     mov     x1, VK_DEBUG_REPORT_ERROR_BIT_EXT   // The error logging bit (second arg)
     mov     x2, #0                              // Zero (third arg)
-    ldr     x3, =termin_error_string            // The error string (fourth arg)
+    adrp    x9, termin_error_string
+    add     x3, x9, #:lo12:termin_error_string  // The error string (fourth arg)
     ldr     x4, [x11, x10]                      // The function name (fifth arg)
     bl      loader_log                          // Log the error message before we crash
     mov     x0, #0