This is an archive of the discontinued LLVM Phabricator instance.

[FuncSpec] Prevent assertion failure when no store value is found
ClosedPublic

Authored by jpenix-quic on Feb 6 2023, 7:36 PM.

Details

Summary

If the only user of the Alloca argument provided to getPromotableAlloca()
is the same as the Call argument, StoreValue is never set and results
in an assertion failure that isa<> was used on a nullptr when passed into
getCandidateConstant().

This was originally seen when trying to build SPEC 2006 416.gamess using
flang with lto enabled.

Diff Detail

Event Timeline

jpenix-quic created this revision.Feb 6 2023, 7:36 PM
jpenix-quic requested review of this revision.Feb 6 2023, 7:36 PM
Herald added a project: Restricted Project. · View Herald TranscriptFeb 6 2023, 7:36 PM
ChuanqiXu accepted this revision.Feb 6 2023, 7:42 PM
This revision is now accepted and ready to land.Feb 6 2023, 7:42 PM