JDK-8200297 : Build failures after JDK-8198691 (CodeHeap State Analytics)
  • Type: Bug
  • Component: hotspot
  • Sub-Component: compiler
  • Affected Version: 11
  • Priority: P1
  • Status: Closed
  • Resolution: Fixed
  • Submitted: 2018-03-27
  • Updated: 2020-09-01
  • Resolved: 2018-03-28
The Version table provides details related to the release that this issue/RFE will be addressed.

Unresolved : Release in which this issue/RFE will be addressed.
Resolved: Release in which this issue/RFE has been resolved.
Fixed : Release in which this issue/RFE has been fixed. The release containing this fix may be available for download as an Early Access Release or a General Availability Release.

To download the current JDK release, click here.
JDK 11
11 b10Fixed
Related Reports
Relates :  
Description
x86_32:

pool/buildbot/slaves/sobornost/jdkX-hs/build/src/hotspot/share/code/codeHeapState.cpp: In static member function 'static void CodeHeapState::print_usedSpace(outputStream*, CodeHeap*)':
/pool/buildbot/slaves/sobornost/jdkX-hs/build/src/hotspot/share/code/codeHeapState.cpp:1242:45: error: format '%ld' expects argument of type 'long int', but argument 3 has type 'unsigned int' [-Werror=format=]
           ast->print("(%4ldK)", total_size/K);
                                             ^
/pool/buildbot/slaves/sobornost/jdkX-hs/build/src/hotspot/share/code/codeHeapState.cpp:1260:71: error: format '%ld' expects argument of type 'long int', but argument 3 has type 'unsigned int' [-Werror=format=]
           ast->print("(%4ldK)", (TopSizeArray[i].len<<log2_seg_size)/K);
                                                                       ^
/pool/buildbot/slaves/sobornost/jdkX-hs/build/src/hotspot/share/code/codeHeapState.cpp:1315:21: error: format '%ld' expects argument of type 'long int', but argument 3 has type 'unsigned int' [-Werror=format=]
                     );
                     ^
/pool/buildbot/slaves/sobornost/jdkX-hs/build/src/hotspot/share/code/codeHeapState.cpp:1315:21: error: format '%ld' expects argument of type 'long int', but argument 4 has type 'unsigned int' [-Werror=format=]
/pool/buildbot/slaves/sobornost/jdkX-hs/build/src/hotspot/share/code/codeHeapState.cpp:1320:21: error: format '%ld' expects argument of type 'long int', but argument 3 has type 'unsigned int' [-Werror=format=]
                     );
                     ^
/pool/buildbot/slaves/sobornost/jdkX-hs/build/src/hotspot/share/code/codeHeapState.cpp:1320:21: error: format '%ld' expects argument of type 'long int', but argument 4 has type 'unsigned int' [-Werror=format=]
/pool/buildbot/slaves/sobornost/jdkX-hs/build/src/hotspot/share/code/codeHeapState.cpp:1354:21: error: format '%ld' expects argument of type 'long int', but argument 3 has type 'unsigned int' [-Werror=format=]
                     );
                     ^
/pool/buildbot/slaves/sobornost/jdkX-hs/build/src/hotspot/share/code/codeHeapState.cpp:1354:21: error: format '%ld' expects argument of type 'long int', but argument 4 has type 'unsigned int' [-Werror=format=]
/pool/buildbot/slaves/sobornost/jdkX-hs/build/src/hotspot/share/code/codeHeapState.cpp:1359:21: error: format '%ld' expects argument of type 'long int', but argument 3 has type 'unsigned int' [-Werror=format=]
                     );
                     ^
/pool/buildbot/slaves/sobornost/jdkX-hs/build/src/hotspot/share/code/codeHeapState.cpp:1359:21: error: format '%ld' expects argument of type 'long int', but argument 4 has type 'unsigned int' [-Werror=format=]
/pool/buildbot/slaves/sobornost/jdkX-hs/build/src/hotspot/share/code/codeHeapState.cpp: In static member function 'static void CodeHeapState::print_names(outputStream*, CodeHeap*)':
/pool/buildbot/slaves/sobornost/jdkX-hs/build/src/hotspot/share/code/codeHeapState.cpp:2119:45: error: format '%ld' expects argument of type 'long int', but argument 3 has type 'unsigned int' [-Werror=format=]
           ast->print("(%4ldK)", total_size/K);
                                             ^
Comments
32-bit x86 Linux is not supported by Oracle and is not part of submit-hs testing. Only RedHat (I don't know about SAP) testing on it and sends bugs to us. I would say it is not integration blocker for Oracle but for Community since their build is broken.
27-03-2018

Okay, I posted a fix for review (Lutz is out of commission, he got sick). But I have to ask, is linux x86 still an officially supported build platform? If yes, why does it not get tested as part of submit-hs? If no, how can this be P1 "integration blocker"?
27-03-2018

total_iterations is "unsigned long" (which is wrong in itself) so it need an unsigned format specifier. The others need a cast - though we should avoid "unsigned long" (actually it is 'long' we should avoid There is also a %p which should be either PTR_FORMAT or INTPTR_FORMAT with the value cast using p2i()
27-03-2018

ILW = Build fails, on 32-bit x86, no workaround = HMH = P1
27-03-2018

Should probably change those from %ld to PTR32_FORMAT_W(...), or something.
27-03-2018