|
1 | 1 | /* |
2 | | - * Copyright (c) 2001, 2025, Oracle and/or its affiliates. All rights reserved. |
| 2 | + * Copyright (c) 2001, 2026, Oracle and/or its affiliates. All rights reserved. |
3 | 3 | * Copyright (c) 2015, 2019, Red Hat Inc. |
4 | 4 | * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. |
5 | 5 | * |
@@ -206,6 +206,11 @@ public String toString() { |
206 | 206 | public Address getSP() { return raw_sp; } |
207 | 207 | public Address getID() { return raw_sp; } |
208 | 208 |
|
| 209 | + @Override |
| 210 | + public void setSP(Address newSP) { |
| 211 | + raw_sp = newSP; |
| 212 | + } |
| 213 | + |
209 | 214 | // FIXME: not implemented yet |
210 | 215 | public boolean isSignalHandlerFrameDbg() { return false; } |
211 | 216 | public int getSignalNumberDbg() { return 0; } |
@@ -360,16 +365,6 @@ private void updateMapWithSavedLink(RegisterMap map, Address savedFPAddr) { |
360 | 365 | map.setLocation(fp, savedFPAddr); |
361 | 366 | } |
362 | 367 |
|
363 | | - private Frame senderForContinuationStub(AARCH64RegisterMap map, CodeBlob cb) { |
364 | | - var contEntry = map.getThread().getContEntry(); |
365 | | - |
366 | | - Address senderSP = contEntry.getEntrySP(); |
367 | | - Address senderPC = contEntry.getEntryPC(); |
368 | | - Address senderFP = contEntry.getEntryFP(); |
369 | | - |
370 | | - return new AARCH64Frame(senderSP, senderFP, senderPC); |
371 | | - } |
372 | | - |
373 | 368 | private Frame senderForCompiledFrame(AARCH64RegisterMap map, CodeBlob cb) { |
374 | 369 | if (DEBUG) { |
375 | 370 | System.out.println("senderForCompiledFrame"); |
@@ -416,6 +411,22 @@ private Frame senderForCompiledFrame(AARCH64RegisterMap map, CodeBlob cb) { |
416 | 411 | updateMapWithSavedLink(map, savedFPAddr); |
417 | 412 | } |
418 | 413 |
|
| 414 | + if (Continuation.isReturnBarrierEntry(senderPC)) { |
| 415 | + // We assume WalkContinuation is "WalkContinuation::skip". |
| 416 | + // It is same with c'tor arguments of RegisterMap in frame::next_frame(). |
| 417 | + // |
| 418 | + // HotSpot code in cpu/aarch64/frame_aarch64.inline.hpp: |
| 419 | + // |
| 420 | + // if (Continuation::is_return_barrier_entry(sender_pc)) { |
| 421 | + // if (map->walk_cont()) { // about to walk into an h-stack |
| 422 | + // return Continuation::top_frame(*this, map); |
| 423 | + // } else { |
| 424 | + // return Continuation::continuation_bottom_sender(map->thread(), *this, l_sender_sp); |
| 425 | + // } |
| 426 | + // } |
| 427 | + return Continuation.continuationBottomSender(map.getThread(), this, senderSP); |
| 428 | + } |
| 429 | + |
419 | 430 | return new AARCH64Frame(senderSP, savedFPAddr.getAddressAt(0), senderPC); |
420 | 431 | } |
421 | 432 |
|
|
0 commit comments