RFR: 8321688: Build on linux with GCC 7.5.0 fails after 8319577
Guoxiong Li
gli at openjdk.org
Sun Dec 17 13:28:36 UTC 2023
On Fri, 15 Dec 2023 08:48:59 GMT, Kim Barrett <kbarrett at openjdk.org> wrote:
>> Hi all,
>>
>> This patch fixes the building failure introduced by [JDK-8319577](https://bugs.openjdk.org/browse/JDK-8319577) in old GCC version (linux & GCC 7.5.0 locally).
>>
>> Thanks for the review.
>>
>> Best Regards,
>> -- Guoxiong
>
> The files being proposed for change are cloned copies of a 3rd-party library.
> We may want to take updates from that library in the future. Having local
> modifications makes that more difficult.
>
> Also, this library uses C++17. GCC support for C++17 was experimental until
> GCC 9. As such, it shouldn't be entirely surprising if an earlier version of
> GCC might run into problems with it.
>
> We've been discussing switching to using C++17 JDK-wide for some time, and I
> think that may happen soon. At that point the minimum supported version of
> GCC will be changed to at least GCC 9.
>
> So I think the answer here is that building this lbrary with GCC 7.5 is not
> supported and a newer version should be used. So the change should be here:
> https://github.com/openjdk/jdk/blob/b31454e36234091c3827c3b4d07f62345cb0cee4/src/java.base/linux/native/libsimdsort/simdsort-support.hpp#L34-L37
> to require a later GCC version. That way, if building with an older version of
> GCC then the code in the library won't be built and the library won't be used
> by the JDK (because the relevant symbols won't be found).
>
> But GCC 7.5 will probably not be supported for building the JDK for much longer.
@kimbarrett Thanks for the guide. I updated the code just now. All the `release`, `fastdebug` and `slowdebug` builds succeeded locally with GCC7.5.
-------------
PR Comment: https://git.openjdk.org/jdk/pull/17047#issuecomment-1859172217
More information about the core-libs-dev
mailing list