This is the mail archive of the gcc@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

RE: Modeling predicate registers with more than one bit


Hi, sorry for the delay of this reply but just returned from paternity leave.

> -----Original Message-----
> From: Hans-Peter Nilsson [mailto:hp@bitrange.com]
> Sent: 05 March 2013 01:45
> To: Paulo Matos
> Cc: gcc@gcc.gnu.org
> Subject: Re: Modeling predicate registers with more than one bit
> 
> Except for CCmodes being dependent on source-modes, I'd sneak
> peeks at PowerPC.
> 

What do you mean by source modes?

> > If not, is there any way to currently
> > (as of HEAD) model this in GCC?
> 
> IIUC, this sounds simply like having multiple separate
> condition-code registers, just with a size-dependent CCmodes
> twist; for each type of comparison where there'd be a separate
> CCmode variant, you also need separate CCmodes for each source
> mode M, all separated in cbranchM4 and cstoreM4.
> 


I am not sure CC_MODE can solve the problem but I am not entirely experienced with using different CC_MODEs, the first thing that comes to mind is, how do you set the size of a CCmode?
A predicate register in our backend can be set as if it had different sizes. So, even though the register has 8 bits. It's possible to have just 1 bit set, 2 bit sets, 4 bit sets of 8 bits sets depending if a comparison is of mode BI, QI, SI or DI.

I might have to use proper registers like SH does (following Oleg suggestion).

Thanks,

Paulo Matos

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]