This is an archive of the discontinued LLVM Phabricator instance.

[ARM] Classification Improvements to ARM Sched-Models. NFCI.
ClosedPublic

Authored by javed.absar on Feb 14 2017, 11:34 AM.

Details

Summary

This patch adds missing sched classes for Thumb2 instructions.

This has been missing so far, and as a consequence, machine scheduler models for individual sub-targets have tended to be larger than they needed to be. These patches should help write schedulers better and faster in the future for ARM sub-targets.

Diff Detail

Event Timeline

javed.absar created this revision.Feb 14 2017, 11:34 AM
rovka edited edge metadata.Feb 16 2017, 7:26 AM

Could you also add tests for some of the other instructions, like t2SDIV, t2LDR etc? Or are they already covered elsewhere?

lib/Target/ARM/ARMInstrThumb2.td
983

Instructions defined with this can get either the IIC_iLoad_i or the IIC_iLoad_bh_i itinerary, and they seem to be slightly different (at least for A9). Does this matter in practice?

1069

Same as above.

lib/Target/ARM/ARMScheduleR52.td
166

Shouldn't you also define an alias between WriteLd and R52WriteLd?

Hi Diana:
As recommended in your review comment, I have:
a. extended the tests to cover some more instructions (LDR, STR, DIV).
b. Also, changed the WriteRes to SchedAlias for the cases you pointed out.
c. There is no need I believe to further refine WriteLd/WriteST. I dont think it would add much benefit.
Best Regards
Javed

rovka accepted this revision.Feb 21 2017, 4:23 AM

Thanks, Javed. LGTM.

This revision is now accepted and ready to land.Feb 21 2017, 4:23 AM
This revision was automatically updated to reflect the committed changes.