ghc-9.12: The GHC API
Safe HaskellNone
LanguageGHC2021

GHC.CmmToAsm.Format

Description

Formats on this architecture A Format is a combination of width and class

TODO: Signed vs unsigned?

TODO: This module is currently shared by all architectures because NCGMonad need to know about it to make a VReg. It would be better to have architecture specific formats, and do the overloading properly. eg SPARC doesn't care about FF80.

Synopsis

Documentation

data Format Source #

Constructors

II8 
II16 
II32 
II64 
FF32 
FF64 
VecFormat 

Fields

Bundled Patterns

pattern IntegerFormat :: Format 

Instances

Instances details
Outputable Format Source # 
Instance details

Defined in GHC.CmmToAsm.Format

Methods

ppr :: Format -> SDoc Source #

Show Format Source # 
Instance details

Defined in GHC.CmmToAsm.Format

Eq Format Source # 
Instance details

Defined in GHC.CmmToAsm.Format

Methods

(==) :: Format -> Format -> Bool #

(/=) :: Format -> Format -> Bool #

Ord Format Source # 
Instance details

Defined in GHC.CmmToAsm.Format

intFormat :: Width -> Format Source #

Get the integer format of this width.

floatFormat :: Width -> Format Source #

Get the float format of this width.

isIntFormat :: Format -> Bool Source #

Check if a format represent an integer value.

isFloatFormat :: Format -> Bool Source #

Check if a format represents a floating point value.

isVecFormat :: Format -> Bool Source #

Check if a format represents a vector

cmmTypeFormat :: CmmType -> Format Source #

Convert a Cmm type to a Format.

formatToWidth :: Format -> Width Source #

Get the Width of a Format.

data VirtualRegWithFormat Source #

A typed virtual register: a virtual register, together with the specific format we are using it at.

data RegWithFormat Source #

A typed register: a register, together with the specific format we are using it at.

Instances

Instances details
Uniquable RegWithFormat Source # 
Instance details

Defined in GHC.CmmToAsm.Format

Outputable RegWithFormat Source # 
Instance details

Defined in GHC.CmmToAsm.Format

Show RegWithFormat Source # 
Instance details

Defined in GHC.CmmToAsm.Format

takeVirtualRegs :: UniqSet RegWithFormat -> UniqSet VirtualReg Source #

Take all the virtual registers from this set.

takeRealRegs :: UniqSet RegWithFormat -> UniqSet RealReg Source #

Take all the real registers from this set.