This is an archive of the discontinued LLVM Phabricator instance.

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

Authored by javed.absar on Jan 25 2017, 7:11 AM.

Details

Summary

This is the second one in the series of patches to enable adding of machine sched-models for ARM processors easier and compact. This patch focuses on integer instructions and adds missing sched definitions.

Diff Detail

Repository
rL LLVM

Event Timeline

javed.absar created this revision.Jan 25 2017, 7:11 AM
rengolin edited edge metadata.

Hi Javed,

Awesome work, thanks!

Adding Tim, as you touch some of the Swift stuff.

Does that make some of the scheduler to be "complete"? If so, we should also update:

let CompleteModel = 1;

So that it gets validated from now on.

cheers,
--renato

Hi Renato:
Thanks for the feedback.
We can't set CompleteModel just yet, but we are getting there. We need add missing schedule information some more instructions (notably Thumb2, VLD/VST)

Best Regards
Javed

rovka added inline comments.Jan 27 2017, 1:35 AM
lib/Target/ARM/ARMInstrInfo.td
4079 ↗(On Diff #85749)

I see you're modelling IIC_iMUL16 the same as IIC_iMUL32, but they don't seem to be exactly identical in any of the models (A9, A8, V6). Same for IIC_iMAC16.

test/CodeGen/ARM/misched-int-basic.ll
41 ↗(On Diff #85749)

Can you also add a test for 64-bit mac?

Hi Diana:
I have made the changes you mentioned.
Best Regards
Javed

rovka edited edge metadata.Feb 1 2017, 2:12 AM

Hi Javed,

I'm not sure if it's you or Phab, but I'm only seeing the changes between the first patch and the current one (not between trunk and the current one). You might want to try to upload again with all the changes included.

test/CodeGen/ARM/misched-int-basic.ll
1 ↗(On Diff #86230)

Nitpick: Why this is an IR test and not an MIR test?

49 ↗(On Diff #86230)

This looks a bit contrived, is there any reason why you don't use mul i16 %c, %c to get a smulbb?

javed.absar updated this revision to Diff 86782.Feb 2 2017, 3:57 AM

Hi Diana:
As requested, I have simplified the test (removed the contrived way of generating SMULBB), added test for SMLABB. Also, converted the test to MIR test.
Thanks and Best Regards
Javed

rovka accepted this revision.Feb 2 2017, 4:19 AM

Thanks, Javed. LGTM now.

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