HomePhabricator

[asan] Restore dead-code-elimination optimization for Fuchsia

Description

[asan] Restore dead-code-elimination optimization for Fuchsia

Summary:
r310244 fixed a bug introduced by r309914 for non-Fuchsia builds.
In doing so it also reversed the intended effect of the change for
Fuchsia builds, which was to allow all the AllocateFromLocalPool
code and its variables to be optimized away entirely.

This change restores that optimization for Fuchsia builds, but
doesn't have the original change's bug because the comparison
arithmetic now takes into account the size of the elements.

Submitted on behalf of Roland McGrath.

Reviewers: vitalybuka, alekseyshl

Reviewed By: alekseyshl

Subscribers: llvm-commits, kubamracek

Tags: #sanitizers

Differential Revision: https://reviews.llvm.org/D36430

Details

Committed
vitalybukaAug 7 2017, 6:01 PM
Reviewer
alekseyshl
Differential Revision
D36430: [asan] Restore dead-code-elimination optimization for Fuchsia
Branches
Unknown
Tags
Unknown