[TSAN][Darwin] x86_64 specific tests requiring weak symbols

Additional tests requiring weak symbol attribute work around for macOS 12.0

Differential Revision: https://reviews.llvm.org/D131119
This commit is contained in:
Blue Gaston 2022-08-03 15:09:50 -07:00
parent 71ebcd3348
commit 42c15ca630
2 changed files with 10 additions and 2 deletions

View File

@ -2,7 +2,11 @@
#include "java.h"
#include <memory.h>
extern "C" __attribute__((disable_sanitizer_instrumentation)) void
#if (__APPLE__)
__attribute__((weak)) // Required for dyld macOS 12.0+
#endif
__attribute__((disable_sanitizer_instrumentation))
extern "C" void
__tsan_symbolize_external_ex(jptr pc,
void (*add_frame)(void *, const char *,
const char *, int, int),

View File

@ -2,7 +2,11 @@
#include "java.h"
#include <memory.h>
extern "C" __attribute__((disable_sanitizer_instrumentation)) bool
#if (__APPLE__)
__attribute__((weak)) // Required for dyld macOS 12.0+
#endif
__attribute__((disable_sanitizer_instrumentation))
extern "C" bool
__tsan_symbolize_external(jptr pc, char *func_buf, jptr func_siz,
char *file_buf, jptr file_siz, int *line, int *col) {
if (pc == (1234 | kExternalPCBit)) {