This is the mail archive of the binutils@sourceware.org mailing list for the binutils 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: --target=v850-unknown-elf, linker problem


Hi,

> To my untrained eye, this looks a little like a bug. In
> v850/lib1funcs.asm, .L_return_interrupt should IMHO be in the
> .call_table_text section, not .text. (Would you like to try making the
> change? It's still line 1459 in 3.4.4) We might be able to sneak in a
> fix before the experts arrive with more sage advice. ;-)

great, thanks for that hint, i just uncommented the ".text" in
line 1459 in lib1funcs.asm (for gcc-3.4.4).  Now the code links
fine.

I wonder now how to proceed, do i need to report this stuff officially
somewhere?  I also got no answer to my mail from saturday morning,
subject line "-mwarn-signed-overflow".  I had to do that change to
make gcc-3.4.4 compile.


Best regards,
Torsten.


>
> That said, using v850e-gcc 3.3, I found the easiest way to make all the
> callt pain go away was to turn off compiler optimisation. (Although I
> only have a fortnight's experience with the v850, so far it seems that
> v850e-gcc 3.3 defaults to conventional push/pop sequences, in lieu of
> the callt size optimisation. So there is no .call_table_data to
> complicate initial attempts to get things to compile, if optimisation is
> turned off. Version 3.4.4 may do the same.)
>
> Adding your source lines to my first chunk of test code generated what was
> expected:
>
> 00402000 <_irq_nmi>:
>   402000:   5c 1a          add   -4, sp
>   402002:   63 ef 01 00    st.w  r29, 0[sp]
>   402006:   03 e8          mov   sp, r29
>   402008:   1d 18          mov   r29, sp
>   40200a:   23 ef 01 00    ld.w  0[sp],r29
>   40200e:   44 1a          add   4, sp
>   402010:   7f 00          jmp   [lp]
>
> (And no errors. :-)
>
> > When i don't use -mv850e, but use -mv850, all works fine.
>
>    IIUC that's because mv850 doesn't have the callt instruction, so the
> problematic optimisation is not invoked.
>
>    I still don't fully grok the callt stuff either, so best of luck.
>
> hth,
> Erik


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