HomeFreeBSD

Apply fix for clang incorrectly optimizing part of dns/bind916

Description

Apply fix for clang incorrectly optimizing part of dns/bind916

Merge commit e5a8af7a90c6 from llvm git (by Gulfem Savrun Yeniceri):

[Passes] Fix relative lookup table converter pass

This patch fixes the relative table converter pass for the lookup table
accesses that are resulted in an instruction sequence, where gep is not
immediately followed by a load, such as gep being hoisted outside the loop
or another instruction is inserted in between them. The fix inserts the
call to load.relative.instrinsic in the original place of load instead of gep.
Issue is reported by FreeBSD via https://bugs.freebsd.org/259921.

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

PR: 259921
Reported by: O. Hartmann <freebsd@walstatt-de.de>
MFC after: 3 days

(cherry picked from commit 5a925e4644665b9a7a5cdd664764fb0a4d1c5797)

Details

Provenance
dimAuthored on Dec 15 2021, 7:56 PM
Parents
rG9a24e9e07e67: Revert clang change that breaks CTF on aarch64
Branches
Unknown
Tags
Unknown