This is the mail archive of the gcc@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]

Problem with branch delay slot


Hi,

I'm currently trying to retarget the gcc backend to a VLIW architecture
developed in my workgroup.
This architecture has a branch delay slot, so i tried the following
(according to http://gcc.gnu.org/onlinedocs/gccint/Delay-Slots.html):

(define_attr "type" "branch,other" (const_string "other"))

(define_delay (eq_attr "type" "branch")
[(eq_attr "type" "other") (nil) (nil)]
)

(define_insn "call"
[(call (match_operand:QI 0 "memory_operand" "")
(match_operand:SI 1 "const_int_operand" ""))]
""
"c7 brl %0"
[(set_attr "type" "branch")]
)

Unfortunately, the delay slot seems not to be used by the compiler. Even
worse, there are no nops being emitted, which results in wrong asm code.

Did I misunderstand something?

Thanks for your help,
Jan


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