bal instruction in gcc 3.x

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



We are facing a problem when U-boot is compiled with gcc 3.x

U-boot  uses the following instruction in one of the files.

bal jump_to_symbol

This code gets compiled without any problem with gcc2. However, if I
compile the code
with gcc3, it exits with the error "Cannot branch to unknown symbol".

What should we do to circumvent this problem ?

I replaced 

bal jump_to_symbol 

by

la t9, jump_to_symbol
jalr t9

Then code gets compiled properly without any problem. Please let me
know, whether this
is correct way of fixing the problem. I am newbie to MIPS assembly
language. Why this
change is required with gcc 3.x compiler ?


TIA,
--kishore


[Index of Archives]     [Linux MIPS Home]     [LKML Archive]     [Linux ARM Kernel]     [Linux ARM]     [Linux]     [Git]     [Yosemite News]     [Linux SCSI]     [Linux Hams]

  Powered by Linux