This is an archive of the discontinued LLVM Phabricator instance.

[SelectionDAG] Add Opc_CheckPatternPredicate2 to support targets with more than 256 predicates.
ClosedPublic

Authored by craig.topper on Aug 5 2023, 1:23 PM.

Details

Summary

This is an alternative to D156967 where I suggested the author
could use a VBR type.

This patch takes inspirations from Opc_EmitRegister2 that is used
for two byte registers.

I'm assuming 1 or 2 byte predicates should be enough so we don't
need the fully generality of VBR.

This avoids impacting the table size on targets that have more than
128 predicates already like X86.

Diff Detail

Event Timeline

craig.topper created this revision.Aug 5 2023, 1:23 PM
Herald added a project: Restricted Project. · View Herald TranscriptAug 5 2023, 1:23 PM
craig.topper requested review of this revision.Aug 5 2023, 1:23 PM
Herald added a project: Restricted Project. · View Herald TranscriptAug 5 2023, 1:23 PM
bogner accepted this revision.Aug 5 2023, 1:38 PM

Yeah this is probably better - if we end up with a target with over 65k predicates we can revisit ;)

This revision is now accepted and ready to land.Aug 5 2023, 1:38 PM
This revision was landed with ongoing or failed builds.Aug 5 2023, 5:22 PM
This revision was automatically updated to reflect the committed changes.