Skip to content

8299254: Support dealing with standard assert macro #2842

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
wants to merge 2 commits into from

Conversation

vieiro
Copy link
Contributor

@vieiro vieiro commented Jul 9, 2024

Backport of JDK-8299254 that solves the clash between OpenJDK's and standard lib's assert macro when building with XCode 14/clang 14 on GHA macos-13.

Clean changes:

make/hotspot/lib/JvmFlags.gmk
src/hotspot/share/utilities/vmassert_reinstall.hpp
src/hotspot/share/utilities/vmassert_uninstall.hpp
test/hotspot/gtest/gc/shared/test_memset_with_concurrent_readers.cpp

Conflicts solved in:

test/hotspot/gtest/jfr/test_networkUtilization.cpp
test/hotspot/gtest/unittest.hpp

Not included:

test/hotspot/gtest/code/test_codestrings.cpp
test/hotspot/gtest/gc/shenandoah/test_shenandoahNumberSeq.cpp

in test/hotspot/gtest/unittest.hpp I've removed some lines to avoid including "gmock/gmock.h" that was introduced in JDK-8222414 and has not been backported to 11.

The macos-13 will continue to fail after this PR, the next errors to solve on macos-13 (under investigation) are:

  • Missing sprintf in test/hotspot/jtreg/vmTestbase/nsk/share/native/nsk_tools.cpp
In file included from /Users/runner/work/jdk11u-dev/jdk11u-dev/test/hotspot/jtreg/vmTestbase/nsk/aod/VirtualMachine/VirtualMachine07/libVirtualMachine07agent02.cpp:26:
/Users/runner/work/jdk11u-dev/jdk11u-dev/test/hotspot/jtreg/vmTestbase/nsk/share/native/nsk_tools.cpp:282:13: error: 'sprintf' is deprecated: This function is provided for compatibility reasons only.  Due to security concerns inherent in the design of sprintf(3), it is highly recommended that you use snprintf(3) instead. [-Werror,-Wdeprecated-declarations]
            sprintf(buf, " %02X", b);
  • Flag -Wdeprecated-non-prototype should be removed when compiling awt_ImagingLib.c:
* For target support_native_java.desktop_libawt_awt_ImagingLib.o:
/Users/runner/work/jdk11u-dev/jdk11u-dev/src/java.desktop/share/native/libawt/awt/medialib/awt_ImagingLib.c:430:43: error: passing arguments to a function without a prototype is deprecated in all versions of C and is not supported in C2x [-Werror,-Wdeprecated-non-prototype]
    if ((*sMlibFns[MLIB_CONVKERNCVT].fptr)(kdata, &scale, dkern, w, h,

Progress

  • Change must be properly reviewed (1 review required, with at least 1 Reviewer)
  • Change must not contain extraneous whitespace
  • Commit message must refer to an issue
  • JDK-8299254 needs maintainer approval

Integration blocker

 ⚠️ Dependency #2836 must be integrated first

Issue

  • JDK-8299254: Support dealing with standard assert macro (Enhancement - P4)

Reviewers

Reviewing

Using git

Checkout this PR locally:
$ git fetch https://git.openjdk.org/jdk11u-dev.git pull/2842/head:pull/2842
$ git checkout pull/2842

Update a local copy of the PR:
$ git checkout pull/2842
$ git pull https://git.openjdk.org/jdk11u-dev.git pull/2842/head

Using Skara CLI tools

Checkout this PR locally:
$ git pr checkout 2842

View PR using the GUI difftool:
$ git pr show -t 2842

Using diff file

Download this PR as a diff file:
https://git.openjdk.org/jdk11u-dev/pull/2842.diff

Webrev

Link to Webrev Comment

@bridgekeeper
Copy link

bridgekeeper bot commented Jul 9, 2024

👋 Welcome back vieiro! A progress list of the required criteria for merging this PR into pr/2836 will be added to the body of your pull request. There are additional pull request commands available for use with this pull request.

@openjdk
Copy link

openjdk bot commented Jul 9, 2024

❗ This change is not yet ready to be integrated.
See the Progress checklist in the description for automated requirements.

@openjdk openjdk bot changed the title Backport 3e2314d08218dc8a4f4fc61bd4e1d5e58a0129c7 8299254: Support dealing with standard assert macro Jul 9, 2024
@openjdk
Copy link

openjdk bot commented Jul 9, 2024

This backport pull request has now been updated with issue from the original commit.

@openjdk openjdk bot added backport rfr Pull request is ready for review labels Jul 9, 2024
@mlbridge
Copy link

mlbridge bot commented Jul 9, 2024

Webrevs

@bridgekeeper
Copy link

bridgekeeper bot commented Aug 14, 2024

@vieiro This pull request has been inactive for more than 4 weeks and will be automatically closed if another 4 weeks passes without any activity. To avoid this, simply add a new comment to the pull request. Feel free to ask for assistance if you need help with progressing this pull request towards integration!

@vieiro
Copy link
Contributor Author

vieiro commented Sep 5, 2024

Parent pull requests have been closed without review, so there's no point in continuing just with this PR.

@vieiro vieiro closed this Sep 5, 2024
@vieiro vieiro deleted the backports/JDK-8299254 branch September 5, 2024 08:19
@vieiro vieiro restored the backports/JDK-8299254 branch September 10, 2024 18:14
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
backport rfr Pull request is ready for review
Development

Successfully merging this pull request may close these issues.

2 participants