RFR: 8292647: javac/lambda/T8031967.java fails with StackOverflowError when use -XX:TieredStopAtLevel=3 on aarch64 and LoongArch [v3]

SUN Guoyun duke at openjdk.org
Fri Feb 10 09:57:53 UTC 2023


On Wed, 8 Feb 2023 09:21:30 GMT, SUN Guoyun <duke at openjdk.org> wrote:

>> make images run-test TEST=tools/javac/lambda/T8031967.java will fails with StackOverflowError when I use args JTREG="VM_OPTIONS=-XX:TieredStopAtLevel=3" on aarch64 and LoongArch. So the stack size `-Xss10m` needs to be increased to improve the robustness of the testcase.
>
> SUN Guoyun 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 three additional commits since the last revision:
> 
>  - Merge branch 'openjdk:master' into 8292647
>  - 8292647: javac/lambda/T8031967.java fails with StackOverflowError when use -XX:TieredStopAtLevel=3 on aarch64 and LoongArch
>  - 8292647: javac/lambda/T8031967.java fails with StackOverflowError when use -XX:TieredStopAtLevel=3 on aarch64 and LoongArch

And I found the above difference comes from the different ways in which framesize is calculated.
<pre><code class="cpp">
// src/hotspot/cpu/aarch64/c1_LIRAssembler_aarch64.cpp

int LIR_Assembler::initial_frame_size_in_bytes() const {                        
  return in_bytes(frame_map()->framesize_in_bytes());                           
}
</code></pre>

<pre><code class="cpp">
// src/hotspot/cpu/x86/c1_LIRAssembler_x86.cpp

int LIR_Assembler::initial_frame_size_in_bytes() const {                        
  return (frame_map()->framesize() - (2*VMRegImpl::slots_per_word))  * VMRegImpl::stack_slot_size;
}  
</code></pre>

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

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


More information about the compiler-dev mailing list