Closed kgibm closed 1 year ago
@keithc-ca I can take a look at this but before I do, have you seen issues with printf and OMR_PRId64
on Windows before?
Maybe it should have been PRIu64
?
Yes, if we were talking to sprintf()
it should have used OMR_PRIu64
instead of OMR_PRId64
. Here it is ultimately using omrstr_vprintf()
so the format we want is "%llu"
.
Okay, thanks. I'll test this out and open a PR.
omrstr_vprintf()
doesn't handle %I
so that part just disappears.
Okay, thanks. I'll test this out and open a PR.
Any updates to share on that PR?
Any updates to share on that PR?
I got stuck building locally on Windows, but will try again today.
Given the block on building on Windows 11, could I just submit a PR and one of you could spark a Jenkins build and then I could test that?
You don't need a PR, if you have a branch on your fork let me know what it is and I will kick a build with it. You might want to rebase it on the latest.
~Do you need to build on Windows? It's easier to build on Linux if you want to set that up.~ nm, I see this is a Windows problem.
You don't need a PR, if you have a branch on your fork let me know what it is and I will kick a build with it. You might want to rebase it on the latest.
Thanks, please build this branch (rebased on latest): https://github.com/kgibm/openj9/tree/issue17319
Thanks Peter.
Tested the build (with OMR_PRIu64
) but now it just shows:
Approximate time to produce this dump: 64u ms
@keithc-ca Thoughts?
That code should not use any of the OMR_PRIxxx
macros; the format string is interpreted by OMR, not printf
and friends. It should use "%llu"
like line 681.
I notice another part of the code has the same issue; I presume I should update that as well:
#if defined(J9VM_OPT_JITSERVER)
if (NULL != jitConfig) {
if (0 != jitConfig->clientUID) {
_OutputStream.writeCharacters("1CICLIENTID Client UID ");
_OutputStream.writeInteger64(jitConfig->clientUID, "%" OMR_PRIu64);
_OutputStream.writeCharacters("\n");
}
if (0 != jitConfig->serverUID) {
_OutputStream.writeCharacters("1CISERVERID Server UID ");
_OutputStream.writeInteger64(jitConfig->serverUID, "%" OMR_PRIu64);
_OutputStream.writeCharacters("\n");
}
}
#endif /* J9VM_OPT_JITSERVER */
@pshipton Please start a new personal build for https://github.com/kgibm/openj9/tree/issue17319
I notice another part of the code has the same issue; I presume I should update that as well:
Yes, please and thanks.
Java -version output
Summary of problem
On Windows, the new java dump line
1TIDMPDURATION
added by PR #15964 incorrectly returns a constant64d
:javacore.20230502.061258.26772.0001.txt