[Bug c/14852] New: gcc ignore the register allocation order REG_ALLOC_ORDER
raja at rrap-software dot com
gcc-bugzilla@gcc.gnu.org
Mon Apr 5 14:39:00 GMT 2004
I am working on porting gcc for adi blackfin processor.
Environment:
````````````
gcc version 3.3.2
Configured with: ./configure --prefix=/home2/raja/bfin_3_FCC
--exec-prefix=/home2/raja/bfin --target=bfin Âenable-languages=c
/home2/raja/bfin/bin/bfin-gcc -c -save-temps -O0 -v xyz.c
This processor has the following registers:
```````````````````````````````````````````````````
Data registers (r0..r7)
Address registers (p0..p5,fp,sp)
Accumulator registers (a0, a1)
Index registers (i0..i3)
Base registers (b0..b3)
Modify register (m0..m3)
and i have defined the register allocation order as bellow.
#define REG_ALLOC_ORDER \
{ REG_R0, REG_R1, REG_R2, REG_R3, REG_R7, REG_R6, REG_R5, REG_R4, \
REG_P2, REG_P1, REG_P0, REG_P5, REG_P4, REG_P3, REG_P6, REG_P7, \
REG_I0, REG_B0, REG_L0, REG_I1, REG_B1, REG_L1, REG_I2, REG_B2, \
REG_L2, REG_I3, REG_B3, REG_L3, REG_M0, REG_M1, REG_M2, REG_M3, \
REG_A0, REG_A1, \
REG_NO, \
}
problem: gcc ignore the above register allocation order.
```````````
Even though the Data registers are not still available for register allocation,
compiler outputs the assembly instruction using Index registers like the following
[FP +-20] = I0;
which is not allowed in this processor.
Please help me how to tell the compiler to use the data register instead of
Index register.
--
Summary: gcc ignore the register allocation order
REG_ALLOC_ORDER
Product: gcc
Version: unknown
Status: UNCONFIRMED
Severity: critical
Priority: P2
Component: c
AssignedTo: unassigned at gcc dot gnu dot org
ReportedBy: raja at rrap-software dot com
CC: gcc-bugs at gcc dot gnu dot org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=14852
More information about the Gcc-bugs
mailing list