This is the mail archive of the
gcc-help@gcc.gnu.org
mailing list for the GCC project.
a problem in modifying md file
- From: "Cui Huimin" <cuihm97 at mails dot tsinghua dot edu dot cn>
- To: gcc-help at gcc dot gnu dot org
- Date: Wed, 06 Nov 2002 18:43:08 +0800
- Subject: a problem in modifying md file
- Reply-to: "Cui Huimin" <cuihm97 at mails dot tsinghua dot edu dot cn>
Hi,
I met a problem in using GCC.I've tried to make a cross-compiler for an
architecture which is similiar with 4kc.But some parameters should be modified,I
followed the docs to modified the mips.md file,for example,I modified the
following items and so on:
(define_function_unit "memory" 1 0
(and (eq_attr "type" "load")
(eq_attr "cpu" "r4kc"))
3 0)
(define_function_unit "memory" 1 0
(and (eq_attr "type" "store")
(eq_attr "cpu" "r4kc"))
3 0)
but this modification does not work,My execution is
mipsel-linux-ecoff-gcc -msoft-float -Dmain=main2 -Wall -c -S name.c -o name.s -EL
But it's output is like this:
...
sw $0,0($fp)
lw $2,0($fp)
bne $2,$0,$L2
li $2,1 # 0x1
sw $2,0($fp)
...
it looks that it doesn't work at all,I have to add "nop" in mips.c,but this idea
makes the optimization more difficult.Do I need to modify any else files?Thanks
for your answer.
With Best Wishes.
Yours,
Jessica Cui