On Mon, 22 Jul 2024 16:45:06 GMT, Andrew Haley <a...@openjdk.org> wrote:

>> src/hotspot/cpu/x86/macroAssembler_x86.cpp line 4810:
>> 
>>> 4808:                                                          Label* 
>>> L_success,
>>> 4809:                                                          Label* 
>>> L_failure) {
>>> 4810:   // NB! Callers may assume that, when temp2_reg is a valid register,
>> 
>> Oh, that's a subtle point... Can we make it more evident at call sites?
>
> Done. I think the only code that still depends on it is the C2 pattern that 
> uses check_klass_subtype_slow_path_linear in x86_32.ad and x86_64.ad.

Thanks. I revisited the code and now it seems like `temp2_reg_was_valid` 
duplicates `set_cond_codes` parameter in the original implementation. Am I 
missing something important here? Otherwise, why can't we rely on 
`set_cond_codes` flag instead?

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

PR Review Comment: https://git.openjdk.org/jdk/pull/19989#discussion_r1688579798

Reply via email to