Commit 68612784 authored by Leszek Swirski's avatar Leszek Swirski Committed by Commit Bot

[build] Suppress UBSan alignment checks in pointer compression

It is a design decision of pointer compression to allow unaligned pointers,
so disable this check in UBSan.

Bug: v8:7703
Change-Id: I3fab34e77ad755cdef3cd385a3615e3d0e350c16
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/1523346
Commit-Queue: Leszek Swirski <leszeks@chromium.org>
Commit-Queue: Michael Achenbach <machenbach@chromium.org>
Auto-Submit: Leszek Swirski <leszeks@chromium.org>
Reviewed-by: 's avatarMichael Achenbach <machenbach@chromium.org>
Cr-Commit-Position: refs/heads/master@{#60235}
parent ba6f813c
......@@ -667,6 +667,11 @@ config("toolchain") {
# Chromium uses a hand-picked subset of UBSan coverage. We want everything.
if (is_ubsan) {
cflags += [ "-fsanitize=undefined" ]
if (v8_enable_pointer_compression) {
# ... except alignment checks when using pointer compression, as it can
# lead to unaligned pointer accesses.
cflags += [ "-fno-sanitize=alignment" ]
}
}
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment