-
Bug
-
Resolution: Fixed
-
P4
-
24, 25
-
b05
-
riscv
-
linux
Issue | Fix Version | Assignee | Priority | Status | Resolution | Resolved In Build |
---|---|---|---|---|---|---|
JDK-8347479 | 24.0.1 | Fei Yang | P4 | Resolved | Fixed | b02 |
Following two tests fail with debug build on linux-riscv64 platform:
TEST: compiler/sharedstubs/SharedStubToInterpTest.java
TEST: compiler/sharedstubs/SharedTrampolineTest.java
A bit about the change history. https://bugs.openjdk.org/browse/JDK-8293011 shared stubs to interpreter for static calls.
And https://bugs.openjdk.org/browse/JDK-8293770 reused runtime call trampolines.
So we have `static constexpr bool supports_shared_stubs() { return true; }` in file src/hotspot/cpu/riscv/codeBuffer_riscv.hpp.
And both cases are handled in `CodeBuffer::pd_finalize_stubs` in file src/hotspot/cpu/riscv/codeBuffer_riscv.cpp.
```
bool CodeBuffer::pd_finalize_stubs() {
return emit_shared_stubs_to_interp<MacroAssembler>(this, _shared_stub_to_interp_requests)
&& emit_shared_trampolines(this, _shared_trampoline_requests);
}
```
Then https://bugs.openjdk.org/browse/JDK-8332689 turned off uses of trampolines for far calls and changed this function into:
`static bool supports_shared_stubs() { return UseTrampolines; }`. This will cause the two test failures as option `UseTrampolines`
is off by default. Further, https://bugs.openjdk.org/browse/JDK-8343430 removed old trampoline call and option `UseTrampolines`.
So now we have `static bool supports_shared_stubs() { return false; }` and a simplified `CodeBuffer::pd_finalize_stubs`.
```
bool CodeBuffer::pd_finalize_stubs() {
return emit_shared_stubs_to_interp<MacroAssembler>(this, _shared_stub_to_interp_requests);
}
```
ButJDK-8332689 should only make the runtime call trampolines reuse feature depend on option `UseTrampolines`. It should not
affect the use of shared stubs to interpreter for static calls.
TEST: compiler/sharedstubs/SharedStubToInterpTest.java
TEST: compiler/sharedstubs/SharedTrampolineTest.java
A bit about the change history. https://bugs.openjdk.org/browse/JDK-8293011 shared stubs to interpreter for static calls.
And https://bugs.openjdk.org/browse/JDK-8293770 reused runtime call trampolines.
So we have `static constexpr bool supports_shared_stubs() { return true; }` in file src/hotspot/cpu/riscv/codeBuffer_riscv.hpp.
And both cases are handled in `CodeBuffer::pd_finalize_stubs` in file src/hotspot/cpu/riscv/codeBuffer_riscv.cpp.
```
bool CodeBuffer::pd_finalize_stubs() {
return emit_shared_stubs_to_interp<MacroAssembler>(this, _shared_stub_to_interp_requests)
&& emit_shared_trampolines(this, _shared_trampoline_requests);
}
```
Then https://bugs.openjdk.org/browse/JDK-8332689 turned off uses of trampolines for far calls and changed this function into:
`static bool supports_shared_stubs() { return UseTrampolines; }`. This will cause the two test failures as option `UseTrampolines`
is off by default. Further, https://bugs.openjdk.org/browse/JDK-8343430 removed old trampoline call and option `UseTrampolines`.
So now we have `static bool supports_shared_stubs() { return false; }` and a simplified `CodeBuffer::pd_finalize_stubs`.
```
bool CodeBuffer::pd_finalize_stubs() {
return emit_shared_stubs_to_interp<MacroAssembler>(this, _shared_stub_to_interp_requests);
}
```
But
affect the use of shared stubs to interpreter for static calls.
- backported by
-
JDK-8347479 RISC-V: compiler/sharedstubs tests fail after JDK-8332689
-
- Resolved
-
- relates to
-
JDK-8332689 RISC-V: Use load instead of trampolines
-
- Resolved
-
- links to
-
Commit(master) openjdk/jdk24u/e9109e8c
-
Commit(master) openjdk/jdk/3f7052ed
-
Review(jdk24) openjdk/jdk/22945
-
Review(master) openjdk/jdk24u/15
-
Review(master) openjdk/jdk/22888
(2 links to)