Changeset 49224 in webkit


Ignore:
Timestamp:
Oct 6, 2009 10:44:47 PM (14 years ago)
Author:
eric@webkit.org
Message:

2009-10-06 Priit Laes <plaes@plaes.org>

Reviewed by Gavin Barraclough.

Linking fails with "relocation R_X86_64_PC32 against symbol
`cti_vm_throw'"
https://bugs.webkit.org/show_bug.cgi?id=28422

  • jit/JITStubs.cpp: Mark cti_vm_throw symbol as PLT-indirect symbol, so it doesn't end up in text segment causing relocation errors on amd64 architecture. Introduced new define SYMBOL_STRING_RELOCATION for such symbols.
Location:
trunk/JavaScriptCore
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/JavaScriptCore/ChangeLog

    r49220 r49224  
     12009-10-06  Priit Laes  <plaes@plaes.org>
     2
     3        Reviewed by Gavin Barraclough.
     4
     5        Linking fails with "relocation R_X86_64_PC32 against symbol
     6        `cti_vm_throw'"
     7        https://bugs.webkit.org/show_bug.cgi?id=28422
     8
     9        * jit/JITStubs.cpp:
     10        Mark cti_vm_throw symbol as PLT-indirect symbol, so it doesn't end up
     11        in text segment causing relocation errors on amd64 architecture.
     12        Introduced new define SYMBOL_STRING_RELOCATION for such symbols.
     13
    1142009-10-06  Oliver Hunt  <oliver@apple.com>
    215
  • trunk/JavaScriptCore/jit/JITStubs.cpp

    r49065 r49224  
    7676#endif
    7777
     78#if PLATFORM(LINUX) && PLATFORM(X86_64)
     79#define SYMBOL_STRING_RELOCATION(name) #name "@plt"
     80#else
     81#define SYMBOL_STRING_RELOCATION(name) SYMBOL_STRING(name)
     82#endif
     83
    7884#if USE(JSVALUE32_64)
    7985
     
    113119    "movl %esp, %ecx" "\n"
    114120#endif
    115     "call " SYMBOL_STRING(cti_vm_throw) "\n"
     121    "call " SYMBOL_STRING_RELOCATION(cti_vm_throw) "\n"
    116122    "addl $0x3c, %esp" "\n"
    117123    "popl %ebx" "\n"
     
    176182SYMBOL_STRING(ctiVMThrowTrampoline) ":" "\n"
    177183    "movq %rsp, %rdi" "\n"
    178     "call " SYMBOL_STRING(cti_vm_throw) "\n"
     184    "call " SYMBOL_STRING_RELOCATION(cti_vm_throw) "\n"
    179185    "addq $0x48, %rsp" "\n"
    180186    "popq %rbx" "\n"
     
    240246SYMBOL_STRING(ctiVMThrowTrampoline) ":" "\n"
    241247    "cpy r0, sp" "\n"
    242     "bl " SYMBOL_STRING(cti_vm_throw) "\n"
     248    "bl " SYMBOL_STRING_RELOCATION(cti_vm_throw) "\n"
    243249    "ldr r6, [sp, #0x2c]" "\n"
    244250    "ldr r5, [sp, #0x28]" "\n"
     
    366372    "movl %esp, %ecx" "\n"
    367373#endif
    368     "call " SYMBOL_STRING(cti_vm_throw) "\n"
     374    "call " SYMBOL_STRING_RELOCATION(cti_vm_throw) "\n"
    369375    "addl $0x1c, %esp" "\n"
    370376    "popl %ebx" "\n"
     
    435441SYMBOL_STRING(ctiVMThrowTrampoline) ":" "\n"
    436442    "movq %rsp, %rdi" "\n"
    437     "call " SYMBOL_STRING(cti_vm_throw) "\n"
     443    "call " SYMBOL_STRING_RELOCATION(cti_vm_throw) "\n"
    438444    "addq $0x78, %rsp" "\n"
    439445    "popq %rbx" "\n"
     
    499505SYMBOL_STRING(ctiVMThrowTrampoline) ":" "\n"
    500506    "cpy r0, sp" "\n"
    501     "bl " SYMBOL_STRING(cti_vm_throw) "\n"
     507    "bl " SYMBOL_STRING_RELOCATION(cti_vm_throw) "\n"
    502508    "ldr r6, [sp, #0x2c]" "\n"
    503509    "ldr r5, [sp, #0x28]" "\n"
     
    555561    "add r8, pc, #4" "\n"
    556562    "str r8, [sp, #-4]!" "\n"
    557     "b " SYMBOL_STRING(cti_vm_throw) "\n"
     563    "b " SYMBOL_STRING_RELOCATION(cti_vm_throw) "\n"
    558564
    559565// Both has the same return sequence
Note: See TracChangeset for help on using the changeset viewer.