RFR: JDK-8308288: Fix xlc17 clang warnings in shared code
Martin Doerr
mdoerr at openjdk.org
Thu May 25 18:21:58 UTC 2023
On Thu, 25 May 2023 15:04:32 GMT, Kim Barrett <kbarrett at openjdk.org> wrote:
>> When using the new xlc17 compiler (based on a recent clang) to build OpenJDk on AIX , we run into various "warnings as errors".
>> Some of those are in shared codebase and could be addressed by small adjustments.
>> A lot of those changes are in hotspot, some might be somewhere else in the OpenJDK C/C++ code.
>
> src/hotspot/share/utilities/globalDefinitions_xlc.hpp line 47:
>
>> 45: #undef malloc
>> 46: extern void *malloc(size_t) asm("vec_malloc");
>> 47: #endif
>
> Wow! And I don't mean that in a good way. I'm not questioning whether this is correct, just commenting
> on how crazy it seems that such a thing might be needed.
The crazy thing is that `malloc` is defined! That means all places where we use the term malloc are getting replaced without such a workaround. (E.g. for log tags.)
-------------
PR Review Comment: https://git.openjdk.org/jdk/pull/14146#discussion_r1205867287
More information about the build-dev
mailing list