Ignore:
Timestamp:
2018-04-10T18:51:14Z (7 years ago)
Author:
Jiří Zárevúcky <jiri.zarevucky@…>
Branches:
lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
Children:
ad0d1f5
Parents:
20287223
Message:

Remove _gp from sparc linker script.

The global pointer is set by each PIC function individually,
so the value loaded to %l7 here is never used.
Especially if libc is shared library, since then the GOT
of main has a different address than the GOT of the main
executable (if there even is one).

File:
1 edited

Legend:

Unmodified
Added
Removed
  • uspace/lib/c/arch/sparc64/src/thread_entry.S

    r20287223 rae84e38  
    4545        # Propagate the input arguments to the new window.
    4646        #
     47
     48        call __thread_main              ! %o0 contains address of uarg
    4749        mov %i0, %o0
    4850
    49         sethi %hi(_gp), %l7
    50         call __thread_main              ! %o0 contains address of uarg
    51         or %l7, %lo(_gp), %l7
    52 
    5351        ! not reached
Note: See TracChangeset for help on using the changeset viewer.