[PATCH] D79865: [AArch64] Don't promote constants with float ConstantExpr.
Florian Hahn via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Wed May 13 14:10:09 PDT 2020
fhahn marked an inline comment as done.
fhahn added inline comments.
================
Comment at: llvm/lib/Target/AArch64/AArch64PromoteConstant.cpp:578
// require some code expansion.
if (!Cst || isa<GlobalValue>(Cst) || isa<ConstantExpr>(Cst))
continue;
----------------
efriedma wrote:
> I would rather extend the check here to make it recursive: in addition to restricting ConstantExprs, restrict ConstantAggregates that contain a ConstantExpr or GlobalValue. Or just call Constant::needsRelocation().
Done, I've changed containsFloatConstantExpr to containsOnlyConstantData which traverses ConstantAggregates.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D79865/new/
https://reviews.llvm.org/D79865
More information about the llvm-commits
mailing list