a problem in modifying md file

Cui Huimin cuihm97@mails.tsinghua.edu.cn
Wed Nov 6 02:45:00 GMT 2002


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 




More information about the Gcc-help mailing list