Skip to content

Commit

Permalink
Suppress function UBSan on macOS
Browse files Browse the repository at this point in the history
"-fsanitize=function" is designed to catch when calling a function
through a pointer of the wrong type (much like "-fsanitize=cfi-*call",
but a completely different mechanism). However, this is currently known
to have issues on macOS [0].

[0] llvm/llvm-project#109074

Change-Id: I66f51d8190f6105f852676a8faaf694e7f0dbcca
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/903958
Reviewed-by: Kaylee Lubick <kjlubick@google.com>
  • Loading branch information
Ben Wagner committed Sep 27, 2024
1 parent 627608c commit 39dfe36
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions gn/skia/BUILD.gn
Original file line number Diff line number Diff line change
Expand Up @@ -366,6 +366,10 @@ config("default") {
"-fno-sanitize-recover=$sanitizers",
"-fsanitize-blacklist=$_suppressions",
]
if (is_mac) {
# https://github.com/llvm/llvm-project/issues/109074
cflags += [ "-fno-sanitize=function" ]
}

if (is_win) {
cflags += [
Expand Down

0 comments on commit 39dfe36

Please sign in to comment.