This is an archive of the discontinued LLVM Phabricator instance.

[LegalizeTypes] Use getVectorElementCount to avoid crash of scalable vector.
ClosedPublic

Authored by jacquesguan on Sep 27 2022, 1:43 AM.

Diff Detail

Event Timeline

jacquesguan created this revision.Sep 27 2022, 1:43 AM
Herald added a project: Restricted Project. · View Herald TranscriptSep 27 2022, 1:43 AM
jacquesguan requested review of this revision.Sep 27 2022, 1:43 AM
Herald added a project: Restricted Project. · View Herald TranscriptSep 27 2022, 1:43 AM

test cases?

RKSimon added inline comments.Sep 27 2022, 2:33 AM
llvm/lib/CodeGen/SelectionDAG/LegalizeTypesGeneric.cpp
211

auto -> ElementCount

Address comment.

test cases?

Done.

llvm/lib/CodeGen/SelectionDAG/LegalizeTypesGeneric.cpp
211

Done.

RKSimon accepted this revision.Sep 28 2022, 2:22 AM

LGTM

This revision is now accepted and ready to land.Sep 28 2022, 2:22 AM