RFR: 8300002: Performance regression caused by non-inlined hot methods due to post call noop instructions [v3]

Sergey Kuksenko skuksenko at openjdk.org
Tue Jan 17 17:56:21 UTC 2023


On Mon, 16 Jan 2023 18:47:12 GMT, Igor Veresov <iveresov at openjdk.org> wrote:

>> src/hotspot/share/asm/assembler.hpp line 248:
>> 
>>> 246:   class InlineSkippedInstructionsCounter: public StackObj {
>>> 247:    private:
>>> 248:     AbstractAssembler* _assm;
>> 
>> May be you should record `_assm->_code_section` instead and directly call `_code_section->register_skipped(_start)` instead of adding `AbstractAssembler:: register_skipped(size)`. With `CodeSection` code:
>> 
>>    register_skipped(address start) {
>>       _skipped_instructions_size += (_end - start);
>>    }
>
> Or may be it should be done in the destructor of `InlineSkippedInstructionsCounter`? Would be IMO cleaner.

I could do it as you wish. Please, tell me which variant is preferable for you.
PS But personally, I don't like putting actions inside destructors due to implicitness/non-visibility.

-------------

PR: https://git.openjdk.org/jdk/pull/11958


More information about the hotspot-dev mailing list