bug-gnu-utils
[Top][All Lists]
Advanced

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

ld -relax on SH coff


From: Schirmer, Hartmut
Subject: ld -relax on SH coff
Date: Mon, 15 Oct 2001 15:49:58 +0200

Hi,

-relax doesn't work well on Hitachi SH

A.) Offset added multiple times

    In my linker script I define an external jump table
    SECTIONS
    {
    /*** DRAM ***/
    [...]
    .jumptable (NOLOAD):
        {
            . = . + 0x0010;
            * (.jptable)
        } >dram_jmp =0x0000
    [...]
    }

    After I disabled sh_relax_section() in bfd/coff-sh.c
    I checked the size of .jumptable in the map file:
      normal:      0xc10
      with -relax: 0xc20

   This worked after shifting the dram_jmp by 0x0010


B.) Software crashes

    The resulting image runs quite well. Sadly it crashes
    with an 'illegale opcode' cpu exception in at least on
    source file.

    I disabled parts of sh_relax_section():
     - the mov.l alignment code   -> still crashes
     - delete after jsr-bsr relax -> code works

    Looks like sh_relax_delete_bytes() mixed up something.

    I have no chance to debug the target, sorry.

Hartmut

---------------------------------------
innovative systems GmbH
harman OEM Group
Hartmut Schirmer
Software Development Department
fon +49 (0) 40 - 300 67 - 850
fax +49 (0) 40 - 300 67 - 969
e-mail: address@hidden



reply via email to

[Prev in Thread] Current Thread [Next in Thread]