[PATCH] D121419: [WPD] Extend checking mode to support fallback to indirect call
Teresa Johnson via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Thu Mar 10 15:15:09 PST 2022
tejohnson created this revision.
tejohnson added reviewers: luna, davidxl.
Herald added subscribers: ormris, steven_wu, hiraditya, Prazek.
Herald added a project: All.
tejohnson requested review of this revision.
Herald added a project: LLVM.
Extend -wholeprogramdevirt-check to support both the existing
trapping mode on an incorrect devirtualization, as well as a new
mode to fallback to an indirect call on a mismatch. The new mode is
The new mode is useful in cases where we want to enable
devirtualization but cannot fully guarantee whole program visibility
(e.g in the case where LTO has been disabled for a small set of objects
that could potentially override virtual methods without having a symbol
reference to anything in the base class including the vtable).
Repository:
rG LLVM Github Monorepo
https://reviews.llvm.org/D121419
Files:
llvm/include/llvm/Transforms/Utils/CallPromotionUtils.h
llvm/lib/Transforms/IPO/WholeProgramDevirt.cpp
llvm/lib/Transforms/Utils/CallPromotionUtils.cpp
llvm/test/ThinLTO/X86/devirt_check.ll
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D121419.414510.patch
Type: text/x-patch
Size: 9377 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20220310/bdc9bd31/attachment.bin>
More information about the llvm-commits
mailing list