This is the mail archive of the gcc-patches@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: [Installed] Patch to handling of floats in sh constant pools


If TARGET_SHCOMPACT, and we have a sequence of constants like this:

        A: SFmode
        B: DFmode
        C: SFmode
        D: SFmode

> sh.c:dump_table() will realise that B needs a word of padding
> and will try to find a later constant to plug the gap.  In this
> case it picks C, so the final constant order is: A C B D.

B needs a word of padding only if TARGET_FMOVD is true, *and* there
has been an odd number of words since the last 64 bit (or larger)
alignment.

> The code also doesn't check for DImode constants, which need
> the same sort of alignment as DFmode ones.

No, DImode constants need only 32 bit alignment in SHcompact local
constant pools, because they are actually loaded as two SImode
entities.



-- 
--------------------------
SuperH (UK) Ltd.
2410 Aztec West / Almondsbury / BRISTOL / BS32 4QX
T:+44 1454 465658


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