1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2024-11-23 03:02:36 +01:00

[HWASan] Add sizeof(global) in report even if symbols missing.

Summary: Refactor the current global header iteration to be callback-based, and add a feature that reports the size of the global variable during reporting. This allows binaries without symbols to still report the size of the global variable, which is always available in the HWASan globals PT_NOTE metadata.

Reviewers: eugenis, pcc

Reviewed By: pcc

Subscribers: mgorny, llvm-commits, #sanitizers

Tags: #sanitizers, #llvm

Differential Revision: https://reviews.llvm.org/D80599
This commit is contained in:
Mitch Phillips 2020-06-09 11:57:24 -07:00
parent d22f339338
commit bdf48658a5
2 changed files with 6 additions and 3 deletions

View File

@ -2,11 +2,12 @@ import("//llvm/utils/gn/build/libs/pthread/enable.gni")
config("pthread_config") {
visibility = [ ":pthread" ]
ldflags = [ "-pthread" ]
libs = [ "pthread" ]
}
group("pthread") {
if (llvm_enable_threads && current_os != "win") {
all_dependent_configs = [ ":pthread_config" ]
# On Android, bionic has built-in support for pthreads.
if (llvm_enable_threads && current_os != "win" && current_os != "android") {
public_configs = [ ":pthread_config" ]
}
}

View File

@ -43,6 +43,8 @@ source_set("sources") {
"hwasan_dynamic_shadow.h",
"hwasan_exceptions.cpp",
"hwasan_flags.h",
"hwasan_globals.cpp",
"hwasan_globals.h",
"hwasan_interceptors.cpp",
"hwasan_interceptors_vfork.S",
"hwasan_interface_internal.h",