Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-8043293

SAFESEH linker option should not be specified on 64 bit Windows for Java6

    Details

    • Subcomponent:
    • Resolved In Build:
      b01
    • CPU:
      x86_64
    • OS:
      windows
    • Verification:
      Verified

      Backports

        Description

        Linker with /SAFESEH makes sure all linked modules are compatible with the safe exception handling feature.
        If any module is not compatible then the linker returns with an error, otherwise the linker produces
        a table with image's safe exception handlers.
        /SAFESEH is only valid when linking for x86 targets.
        If specified on 64 bit systems then it the option is ignored.
        http://msdn.microsoft.com/en-us/library/9a89h429.aspx

        However there are problems with /SAFESEH option
        exclusively on Visual Studio 2003 (compiler used to build Java6):

        Problem 1.
        Compiler with specified /ZI option (enable Edit and Continue debug info)
        produces object modules not compatible with the safe exception handling feature.
        If /Zi option (enable debugging information) is specified then everything is fine - the object module is compatible
        with the safe exception handling feature.

        Problem 2.
        On AMD64 platform /SAFESEH doesn't get ignored and
        linker returns an error:
        link.exe /out:sawindbg.dll /DLL sawindbg.obj dbgeng.lib /manifest bufferoverflowU.lib /SAFESEH /nologo /subsystem:console /map /debug /machine:AMD64
        LINK : fatal error LNK1246: '/SAFESEH' not compatible with 'AMD64' target machine; link without '/SAFESEH'

        Problem (1.) has been fixed with
        https://bugs.openjdk.java.net/browse/JDK-8037898

        Problem (2.) is a subject of this bug.

          Attachments

            Issue Links

              Activity

                People

                • Assignee:
                  miroslawzn Miroslaw Niemiec (Inactive)
                  Reporter:
                  miroslawzn Miroslaw Niemiec (Inactive)
                • Votes:
                  0 Vote for this issue
                  Watchers:
                  4 Start watching this issue

                  Dates

                  • Created:
                    Updated:
                    Resolved: