HomePhabricator

[MCA] Introduce class LSUnitBase and let LSUnit derive from it.
Audit Requireddd0d9e01eeaa

Authored by andreadb on May 23 2019, 6:42 AM.

Description

[MCA] Introduce class LSUnitBase and let LSUnit derive from it.

Class LSUnitBase provides a abstract interface for all the concrete LS units in
llvm-mca.

Methods exposed by the public abstract LSUnitBase interface are:

  • Status isAvailable(const InstRef&);
  • void dispatch(const InstRef &);
  • const InstRef &isReady(const InstRef &);

LSUnitBase standardises the API, but not the data structures internally used by
LS units. This allows for more flexibility.
Previously, only method isReady() was declared virtual by class LSUnit.
Also, derived classes had to inherit all the internal data members of LSUnit.

No functional change intended.

llvm-svn: 361496

Details

Auditors
grosbach
Committed
andreadbMay 23 2019, 6:42 AM
Parents
rG46806749ac3a: [X86] Regenerate LZCNT tests on x86/x32/x64 targets
Branches
Unknown
Tags
Unknown