RFR(T): 8233530: gcc 5.4 build warning -Wc++14-compat after JDK-8233359

David Holmes david.holmes at oracle.com
Wed Nov 6 01:44:58 UTC 2019


On 6/11/2019 11:38 am, Kim Barrett wrote:
>> On Nov 5, 2019, at 2:06 AM, Thomas Stüfe <thomas.stuefe at gmail.com> wrote:
>>
>> Hi all,
>>
>> may I please have reviews for this small build fix:
>>
>> Issue: https://bugs.openjdk.java.net/browse/JDK-8233530
>> Webrev: http://cr.openjdk.java.net/~stuefe/webrevs/8233530-wc14-compat/webrev.00/webrev/
>> Prior discussion: https://mail.openjdk.java.net/pipermail/hotspot-runtime-dev/2019-November/036726.html
>>
>> Thank you,
>>
>> Thomas
> 
> The "#ifdef __GNUG__" should not be needed or used.
> 
> There are a dozen existing uses of PRAGMA_DIAG_PUSH.
> 
> While there aren't currently any other direct uses of
> PRAGMA_DISABLE_GCC_WARNING, there are indirect uses via other
> PRAGMA_DISABLE_xxx macros.
> 
> None of those have __GNUX__ protections (for any X).

Well AFAICS they reside in a gcc specific file: 
compilerWarnings_gcc.hpp. But we also take steps in compilerWarnings.hpp 
to accommodate their use in source code when other compilers are used.

#ifndef PRAGMA_DISABLE_GCC_WARNING
#define PRAGMA_DISABLE_GCC_WARNING(name)
#endif

so I agree we should not need any guard to make this gcc only - unless 
we really do want to control the version.

David
-----


>> On Nov 5, 2019, at 10:22 AM, Lindenmaier, Goetz <goetz.lindenmaier at sap.com> wrote:
>> […] Do we still support gcc 4?
>> This change might not be working on gcc 4. PRAGMA_DIAG_PUSH is defined
>> empty for gcc < 4.6.  (I think this does not matter.)
> 
> gcc < 4.6 doesn’t matter.
> 
> Minimum supported gcc version according to make/autoconf/toolchains.mk is 4.8.
> (I’m not sure I actually believe that :)
> 
> gcc7.3 is the earliest version listed for jdk13 here:
> https://wiki.openjdk.java.net/display/Build/Supported+Build+Platforms
> (Though there’s no mention here of the BellSoft 32bit linux port, which I possibly
> mis-remember as using gcc4.9.)
> 


More information about the hotspot-runtime-dev mailing list