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

--disable-warnings-as-errors does not work for HotSpot build

    Details

    • Subcomponent:
    • Resolved In Build:
      b107

      Backports

        Description

        Passing --disable-warnings-as-errors to configure not works in jdk9/hs-rt repo on Linux-x64 OS. Running following configure&build command give compilation error:
         sh ./configure --disable-warnings-as-errors --enable-native-coverage --enable-debug
        make all
        ...
        /home/dmitry/work/bugs/disable_warnings_as_errors/jdk9-hs-rt/hotspot/src/share/vm/gc/shared/genCollectedHeap.cpp: In function ‘ScratchBlock* removeSmallestScratch(ScratchBlock**)’:
        /home/dmitry/work/bugs/disable_warnings_as_errors/jdk9-hs-rt/hotspot/src/share/vm/gc/shared/genCollectedHeap.cpp:1032:33: error: ‘smallest_ptr’ may be used uninitialized in this function [-Werror=maybe-uninitialized]
           *smallest_ptr = smallest->next;
                                         ^
        cc1plus: all warnings being treated as errors
        make[8]: *** [genCollectedHeap.o] Error 1
        ...

        The issue reproducible with --enable-native-coverage flag to configure.

          Attachments

            Issue Links

              Activity

                People

                • Assignee:
                  iignatyev Igor Ignatyev
                  Reporter:
                  ddmitriev Dmitry Dmitriev
                • Votes:
                  0 Vote for this issue
                  Watchers:
                  9 Start watching this issue

                  Dates

                  • Created:
                    Updated:
                    Resolved: