On Tue, 1 Aug 2023 08:10:10 GMT, David Holmes <dhol...@openjdk.org> wrote:
>> Julian Waters has updated the pull request with a new target base due to a >> merge or a rebase. The incremental webrev excludes the unrelated changes >> brought in by the merge/rebase. The pull request contains 22 additional >> commits since the last revision: >> >> - Mismatched declaration in D3DGlyphCache.cpp >> - Fields in awt_TextComponent.cpp >> - reinterpret_cast needed in AccessBridgeJavaEntryPoints.cpp >> - Qualifiers in awt_PrintDialog.h should be removed >> - Likewise for awt_DnDDT.cpp >> - awt_ole.h include order issue in awt_DnDDS.cpp >> - Revert awt_ole.h >> - Earlier fix in awt_ole.h was not complete >> - Merge branch 'openjdk:master' into patch-10 >> - Likewise for awt_Frame.cpp >> - ... and 12 more: https://git.openjdk.org/jdk/compare/6432a4e7...51230f3d > > src/hotspot/os/windows/symbolengine.cpp line 114: > >> 112: _capacity = (int)(sizeof(_fallback_buffer) / sizeof(T)); >> 113: } >> 114: _p[0] = (T) '\0'; > > I find this use of `'\0'` quite suspicious in itself, but it is consistent > with the use of `'X'` in `imprint_sentinel()`. I'm unclear what types are > possible for `T` in this code. There are currently only 2 possible types of HMODULE and char/uint8_t for T at the moment. Weirdly enough only line 126 errors out without the cast while line 114, despite having the same problem, doesn't, but I added the cast to both lines for consistency. If someone else knows why I could probably deal with this code in a better way besides just casting it to T (which I also am reluctant to do) > src/hotspot/share/memory/allocation.cpp line 114: > >> 112: // >> 113: >> 114: void* AnyObj::operator new(size_t size, Arena *arena) { > > Please remind us what the issue is with `throw()` as this is a change to > shared code and it looks very inconsistent to remove it only for this one > definition of `operator new`. Hi David, this throw was removed for this method's declaration in the corresponding hpp file in an earlier commit [8305590: Remove nothrow exception specifications from operator new](https://github.com/openjdk/jdk/commit/0f51e6326373ff7d4a4d9a0e3a2788401f73405d), but the Author forgot to remove the throw() from the definition as well (the error can be viewed in the GHA for the earlier versions of this PR). I believe gcc only errors on this in C++17 mode (for some weird reason) and not our current C++14 mode, which is why it gets a pass on other platforms ------------- PR Review Comment: https://git.openjdk.org/jdk/pull/15096#discussion_r1280269818 PR Review Comment: https://git.openjdk.org/jdk/pull/15096#discussion_r1280267058