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

Optimized build fails with "undefined reference to 'test_memset_with_concurrent_readers()'"

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Duplicate
    • Icon: P3 P3
    • 9
    • 9
    • hotspot
    • None
    • gc

      The optimized build fails with:

      internalVMTests.o: In function `InternalVMTests::run()':
      /oracle/full_jdk_build/hotspot/src/share/vm/utilities/internalVMTests.cpp:127: undefined reference to `test_memset_with_concurrent_readers()'
      collect2: error: ld returned 1 exit status

      JDK-8131330 removed the NOT_DEBUG_RETURN declaration for the unit test 'test_memset_with_concurrent_readers()'. To be available in the optimized build, it should be guarded by ASSERT:

      diff -r 5fefcbeda616 src/share/vm/gc/shared/memset_with_concurrent_readers.cpp
      --- a/src/share/vm/gc/shared/memset_with_concurrent_readers.cpp Fri Feb 12 16:12:15 2016 -0800
      +++ b/src/share/vm/gc/shared/memset_with_concurrent_readers.cpp Wed Feb 17 16:03:04 2016 +0100
      @@ -34,7 +34,7 @@
       #if INCLUDE_ALL_GCS
       
       // Unit test
      -#ifdef ASSERT
      +#ifndef PRODUCT
       
       static unsigned line_byte(const char* line, size_t i) {
         return unsigned(line[i]) & 0xFF;

            thartmann Tobias Hartmann
            thartmann Tobias Hartmann
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              Resolved: