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: Committed: CRIS IRA_COVER_CLASSES definition


Hans-Peter Nilsson wrote:
CRIS v32 (a CRIS variant) has a register named ACR (a singleton
class ACR_REGS) used as the destination in some three-operand
instructions variants for common operations such as additions.
Except for that and the inability to be postincremented, it's
otherwise like a general register.  Guessing that it'd be
beneficial to express the difference through a separate cover
class, I thought it'd work to #define IRA_COVER_CLASSES \
 { ACR_REGS, GENNONACR_REGS, SPECIAL_REGS, LIM_REG_CLASSES }
but that caused a build error for revision 140670:

I don't think it is wise to use ACR_REGS class as a part of IRA_COVER_CLASSES because it is very like to GENERAL_REGS and it is a singleton class. You second description of IRA_COVER_CLASSES which was committed is the right one.
/home/hp/combv/cris-regobj/./gcc/xgcc -B/home/hp/combv/cris-regobj/./gcc/ -nostdinc -B/home/hp/combv/cris-regobj/cris-elf/newlib/ -isystem /home/hp/combv/cris-regobj/cris-elf/newlib/targ-include -isystem /home/hp/combv/combined/newlib/libc/include -B/home/hp/combv/cris-regobj/cris-elf/libgloss/cris -L/home/hp/combv/cris-regobj/cris-elf/libgloss/libnosys -L/home/hp/combv/combined/libgloss/cris -B/tmp/reg-cris/cris-elf/bin/ -B/tmp/reg-cris/cris-elf/lib/ -isystem /tmp/reg-cris/cris-elf/include -isystem /tmp/reg-cris/cris-elf/sys-include -L/home/hp/combv/cris-regobj/./ld -g -O2 -march=v32 -mbest-lib-options -O2 -g -O2 -DIN_GCC -DCROSS_DIRECTORY_STRUCTURE -W -Wall -Wwrite-strings -Wstrict-prototypes -Wmissing-prototypes -Wcast-qual -Wold-style-definition -isystem ./include -g -DIN_LIBGCC2 -D__GCC_FLOAT_NOT_NEEDED -Dinhibit_libc -I. -I. -I../../.././gcc -I/home/hp/combv/combined/libgcc -I/home/hp/combv/combined/libgcc/. -I/home/hp/combv/combined/libgcc/../gcc -I/home/hp/combv/combined/libgcc/../include -DHAVE_CC_TLS -o _muldi3.o -MT _muldi3.o -MD -MP -MF _muldi3.dep -DL_muldi3 -c /home/hp/combv/combined/libgcc/../gcc/libgcc2.c \

/home/hp/combv/combined/libgcc/../gcc/libgcc2.c: In function '__muldi3':
/home/hp/combv/combined/libgcc/../gcc/libgcc2.c:566: internal compiler error: in process_bb_node_lives, at ira-lives.c:613

Vlad, any hints? Should I make a PR for this?
It is an assert checking that register pressure after processing only hard-regs available for allocation and living at BB end is not bigger than # of available register classes. I've never seen that this assert failed. It would be interesting for me to look at that. Could you send me preprocessed libgcc2.c file. I'd look at this and we will decide should we make a PR.

Anyway, the following definition causes no regressions cross to
cris-elf, crisv32-elf, cris-linux and crisv32-linux so it's at
least usable as a stop-gap to cover the imminent IRA flag day.
I haven't checked code quality at all.

The (trivial) MMIX update is also in the works, but I saw a
regression failure there (gcc.c-torture/execute/20040709-1.c
execution, -O2) that I have to look closer at (before I rule out
a port bug and blame IRA).

Committed.

Thanks.



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