[llvm-dev] Specify cycles in the instruction stage at compile time

Rail Shafigulin via llvm-dev llvm-dev at lists.llvm.org
Thu Dec 31 14:00:14 PST 2015


I'm trying to figure out if it is possible to specify number of cycles for
a given instruction stage (instruction stages are used in conjunction with
itineraries) at compile time. When I say compile time, I mean code
compilation for my target.

Currently to specify for a given instruction stage a value has to be
hardcoded. Take a look at the InstrStage definition below. The cycles
parameter is the one I'm talking about.

class InstrStage<int cycles, list<FuncUnit> units,
                 int timeinc = -1,
                 ReservationKind kind = Required> {
  int Cycles          = cycles;       // length of stage in machine cycles
  list<FuncUnit> Units = units;       // choice of functional units
  int TimeInc         = timeinc;      // cycles till start of next stage
  int Kind            = kind.Value;   // kind of FU reservation
}

Does anybody know if it is possible to specify the cycles parameter
dynamically, say through a compiler option. I'm trying  to explore what
happens to the schedule when number of cycles for various instructions is
varied. If I could specify cycles value dynamically, without llvm
recompilation it would significantly simplify (as well as reduce time) my
exploration.

Any help is appreciated.

-- 
Rail Shafigulin
Software Engineer
Esencia Technologies
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20151231/0ab2653f/attachment.html>


More information about the llvm-dev mailing list