From 4ddd3dec2d0b232d48646ca89b16591b3026aa5c Mon Sep 17 00:00:00 2001 From: SendaoYan Date: Wed, 20 Nov 2024 01:36:56 +0000 Subject: [PATCH] 8344356: Aarch64: implement -XX:+VerifyActivationFrameSize Reviewed-by: aph --- src/hotspot/cpu/aarch64/interp_masm_aarch64.cpp | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/src/hotspot/cpu/aarch64/interp_masm_aarch64.cpp b/src/hotspot/cpu/aarch64/interp_masm_aarch64.cpp index b892489af70..836caa86cb0 100644 --- a/src/hotspot/cpu/aarch64/interp_masm_aarch64.cpp +++ b/src/hotspot/cpu/aarch64/interp_masm_aarch64.cpp @@ -393,7 +393,13 @@ void InterpreterMacroAssembler::dispatch_base(TosState state, bool verifyoop, bool generate_poll) { if (VerifyActivationFrameSize) { - Unimplemented(); + Label L; + sub(rscratch2, rfp, esp); + int min_frame_size = (frame::link_offset - frame::interpreter_frame_initial_sp_offset) * wordSize; + subs(rscratch2, rscratch2, min_frame_size); + br(Assembler::GE, L); + stop("broken stack frame"); + bind(L); } if (verifyoop) { interp_verify_oop(r0, state);