InstrStage, Interpretation of getUnits()

Here is the code for InstrStage::getUnits()

/// \brief Returns the choice of FUs.
unsigned getUnits() const { return Units_; }

This method returns an integer. How does one interpret it? As far as I see it it should tell me what resources are used by a given stage but I can’t figure out what a return value means. Would anyone care to help?

Thanks,

Hi Rail,

This is a bitfield, each bit represents one functional unit. Unit 0 would be the LSB (1 << 0), unit 1 one bit above LSB (1 << 1), and so on until unit N (1 << N). For example a return value of 9 means that units 0 and 3 are used.

Cheers,
Pierre-Andre