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: subreg_regno_offset


"David S. Miller" wrote:

> For example, note that when we are creating SUBREG expressions it
> would be easy to compute the register offset and store it in the
> SUBREG itself.

You can't always do that when creating a SUBREG expression, you have to
wait for it to be the SUBREG of a hard register.  And since REGs are
shared, you'd have to go over all SUBREGs (how?) after each call to
alter_reg.  Moreover, you'd still have to get the offset right in
the first place.

> 	          Then SUBREG_REGNO_OFFSET and SUBREG_REGNO could be
> just as cheap as SUBREG_REG.

But at the expense of extra memory use.

-- 
--------------------------
SuperH
2430 Aztec West / Almondsbury / BRISTOL / BS32 4AQ
T:+44 1454 462330


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