RFR: 8296469: Instrument VMError::report with reentrant iteration step for register and stack printing [v9]
David Holmes
dholmes at openjdk.org
Tue Mar 7 01:19:29 UTC 2023
The message from this sender included one or more files
which could not be scanned for virus detection; do not
open these files unless you are certain of the sender's intent.
----------------------------------------------------------------------
On Mon, 6 Mar 2023 15:00:31 GMT, Erik Österlund <eosterlund at openjdk.org> wrote:
>> Axel Boldt-Christmas has updated the pull request with a new target base due to a merge or a rebase. The pull request now contains 15 commits:
>>
>> - Merge remote-tracking branch 'upstream_jdk/master' into vmerror_report_register_stack_reentrant
>> - Add test
>> - Fix and strengthen print_stack_location
>> - Missed variable rename
>> - Copyright
>> - Rework logic and use continuation state for reattempts
>> - Merge remote-tracking branch 'upstream_jdk/master' into vmerror_report_register_stack_reentrant
>> - Restructure os::print_register_info interface
>> - Code syle and line length
>> - Merge Fix
>> - ... and 5 more: https://git.openjdk.org/jdk/compare/2009dc2b...2e12b4a5
>
> src/hotspot/share/utilities/vmError.cpp line 175:
>
>> 173: static bool check_stack_headroom(Thread* thread,
>> 174: size_t headroom) {
>> 175: static const address stack_top = thread != nullptr
>
> We typically call "stack_top "stack_base", and "stack_bottom" we call "stack_end".
There is existing code in this file that uses this naming:
STEP_IF("printing stack bounds", _verbose)
st->print("Stack: ");
address stack_top;
size_t stack_size;
if (_thread) {
stack_top = _thread->stack_base();
stack_size = _thread->stack_size();
} else {
stack_top = os::current_stack_base();
stack_size = os::current_stack_size();
}
address stack_bottom = stack_top - stack_size;
st->print("[" PTR_FORMAT "," PTR_FORMAT "]", p2i(stack_bottom), p2i(stack_top));
-------------
PR: https://git.openjdk.org/jdk/pull/11017
More information about the hotspot-dev
mailing list