From fd74085fa50b4197f3799b3128d0d902617051b7 Mon Sep 17 00:00:00 2001 From: TB Schardl Date: Sun, 12 Jan 2025 22:10:25 -0500 Subject: [PATCH] [cilksan] Update llvm.va.start and llvm.va.end hooks for LLVM 19. Add hooks for the erf function. --- cilksan/libhooks.cpp | 33 ++++++++++++++++++++++++++------- 1 file changed, 26 insertions(+), 7 deletions(-) diff --git a/cilksan/libhooks.cpp b/cilksan/libhooks.cpp index d17d8b0..8a5940d 100644 --- a/cilksan/libhooks.cpp +++ b/cilksan/libhooks.cpp @@ -750,10 +750,10 @@ CILKSAN_API void __csan_llvm_trap(const csi_id_t call_id, MAAPs.pop(); } -CILKSAN_API void __csan_llvm_va_start(const csi_id_t call_id, - const csi_id_t func_id, - unsigned MAAP_count, - const call_prop_t prop, va_list ap) { +CILKSAN_API void __csan_llvm_va_start_p0(const csi_id_t call_id, + const csi_id_t func_id, + unsigned MAAP_count, + const call_prop_t prop, va_list ap) { if (!CILKSAN_INITIALIZED) return; @@ -764,9 +764,10 @@ CILKSAN_API void __csan_llvm_va_start(const csi_id_t call_id, MAAPs.pop(); } -CILKSAN_API void __csan_llvm_va_end(const csi_id_t call_id, - const csi_id_t func_id, unsigned MAAP_count, - const call_prop_t prop, va_list ap) { +CILKSAN_API void __csan_llvm_va_end_p0(const csi_id_t call_id, + const csi_id_t func_id, + unsigned MAAP_count, + const call_prop_t prop, va_list ap) { if (!CILKSAN_INITIALIZED) return; @@ -1312,6 +1313,24 @@ CILKSAN_API void __csan_lldiv(const csi_id_t call_id, const csi_id_t func_id, return; } +CILKSAN_API void __csan_erff(const csi_id_t call_id, const csi_id_t func_id, + unsigned MAAP_count, const call_prop_t prop, + float result, float arg) { + return; +} + +CILKSAN_API void __csan_erf(const csi_id_t call_id, const csi_id_t func_id, + unsigned MAAP_count, const call_prop_t prop, + double result, double arg) { + return; +} + +CILKSAN_API void __csan_erfl(const csi_id_t call_id, const csi_id_t func_id, + unsigned MAAP_count, const call_prop_t prop, + long double result, long double arg) { + return; +} + CILKSAN_API void __csan_execl(const csi_id_t call_id, const csi_id_t func_id, unsigned MAAP_count, const call_prop_t prop, int result, const char *filename, const char *arg,