[compiler-rt][hwasan] Call __hwasan_library_loaded via
authorLeonard Chan <leonardchan@google.com>
Tue, 8 Nov 2022 23:11:26 +0000 (23:11 +0000)
committerLeonard Chan <leonardchan@google.com>
Wed, 9 Nov 2022 19:49:08 +0000 (19:49 +0000)
__sanitizer_library_loaded on Fuchsia

Differential Revision: https://reviews.llvm.org/D133806

compiler-rt/lib/hwasan/hwasan_fuchsia.cpp

index 967c796..858fac0 100644 (file)
@@ -224,6 +224,10 @@ void __sanitizer_thread_exit_hook(void *hook, thrd_t self) {
   __hwasan::ThreadExitHook(hook, self);
 }
 
+void __sanitizer_module_loaded(const struct dl_phdr_info *info, size_t) {
+  __hwasan_library_loaded(info->dlpi_addr, info->dlpi_phdr, info->dlpi_phnum);
+}
+
 }  // extern "C"
 
 #endif  // SANITIZER_FUCHSIA