This is an archive of the discontinued LLVM Phabricator instance.

[X86] Add WriteCRC32 scheduler class
ClosedPublic

Authored by RKSimon on Mar 19 2018, 1:16 PM.

Details

Summary

Currently CRC32 instructions use the WriteFAdd class, this patch splits them off into their own.

At the moment WriteCRC32 is mostly just a duplicate of WriteFAdd but it can now be tweaked on a target by target basis.

SandyBridge is interesting as its custom memory latencies don't often match the +4 cy in SBWriteResPair - I can add a 'memory latency' optional argument to SBWriteResPair to make it easier to remedy these cases if people want?

Diff Detail

Repository
rL LLVM

Event Timeline

RKSimon created this revision.Mar 19 2018, 1:16 PM

Do any instructions on Sandybridge have a Custom load latency of 4? Looks like the most basic instruction like ADD32rr vs ADD32rm has a difference of 5 cycles.

Do any instructions on Sandybridge have a Custom load latency of 4? Looks like the most basic instruction like ADD32rr vs ADD32rm has a difference of 5 cycles.

You're right - +5 is probably the best option - I'll see what happens if I alter the default.

This revision is now accepted and ready to land.Mar 26 2018, 12:40 PM
This revision was automatically updated to reflect the committed changes.