New underscore system and WebKit

  • rubenvb

    rubenvb - 2010-05-13


    Another user reported this to me:
    the sezero_20100505_exp build needs a patch for webkit that has to do with underscoring symbol names:

    namespace JSC {
    -#if OS(DARWIN) || OS(WINDOWS)
    +#if OS(DARWIN) || (OS(WINDOWS) && !CPU(X86_64))
     #define SYMBOL_STRING(name) "_" #name
     #define SYMBOL_STRING(name) #name

    I feel this is awkward and it influences the MSVC compile as well. Is it a good fix or not? He also reported that an old mingw64 build would not be able to build WebKit then. Should I report this as a webkit bug or is there something wrong on mingw-w64 end? Thanks

  • Doug Semler

    Doug Semler - 2010-05-13

    gcc defines __USER_LABEL_PREFIX__, which is set to either _ or empty based on whether underscoring is enabled.  Perhaps that could be used???

  • Ozkan Sezer

    Ozkan Sezer - 2010-05-13

    M$VC doesn't add '_' to syms for x64, either. Your change seems reasonable at first look, although if you want a gcc-specific way, __USER_LABEL_PREFIX__ should be the way to go as Doug suggested.

  • rubenvb

    rubenvb - 2010-05-13

    All right. Will forward this to Webkit devs.

    PS: They are in the process of fixing their JIT for Windows x64 (different calling conventions and stack allocation stuff… don't know much about that myself)


Log in to post a comment.

Get latest updates about Open Source Projects, Conferences and News.

Sign up for the SourceForge newsletter:

JavaScript is required for this form.

No, thanks