Commit 8ce79f5
committed
IVDescriptors: cut wasteful FAnyOf checking (NFC)
Checking RecurKind::FAnyOf in isRecurrenceDescriptor() is wasted work
when it already checks RecurKind::IAnyOf. Affect a minor adjustment to
the code to facilitate skipping the RecurKind::FAnyOf check, and strip
the check. The patch has the side-effect of rewriting some flaky code,
which would match an ICmp having the reduction phi as an operand with
IAnyOf, and due to NumCmpSelectPatternInst != 1 (the select redux is
also matched), it would have to rely on failing to match an FCmp with
FAnyOf, setting NumCmpSelectPatternInst = 1, and successfully
vectorizing an IAnyOf pattern with the incorrect debug output. There is
a test for this already in select-cmp.ll:
select_i32_from_icmp_same_inputs.1 parent 4e8eabd commit 8ce79f5
1 file changed
+6
-15
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
415 | 415 | | |
416 | 416 | | |
417 | 417 | | |
418 | | - | |
419 | | - | |
420 | | - | |
421 | | - | |
422 | | - | |
423 | | - | |
| 418 | + | |
| 419 | + | |
| 420 | + | |
424 | 421 | | |
425 | 422 | | |
426 | 423 | | |
| |||
500 | 497 | | |
501 | 498 | | |
502 | 499 | | |
503 | | - | |
| 500 | + | |
504 | 501 | | |
505 | 502 | | |
506 | 503 | | |
| |||
889 | 886 | | |
890 | 887 | | |
891 | 888 | | |
892 | | - | |
893 | | - | |
| 889 | + | |
| 890 | + | |
894 | 891 | | |
895 | 892 | | |
896 | 893 | | |
| |||
913 | 910 | | |
914 | 911 | | |
915 | 912 | | |
916 | | - | |
917 | | - | |
918 | | - | |
919 | | - | |
920 | | - | |
921 | | - | |
922 | 913 | | |
923 | 914 | | |
924 | 915 | | |
| |||
0 commit comments