diff options
Diffstat (limited to 'src/cpu/x86/vm/frame_x86.cpp')
-rw-r--r-- | src/cpu/x86/vm/frame_x86.cpp | 20 |
1 files changed, 19 insertions, 1 deletions
diff --git a/src/cpu/x86/vm/frame_x86.cpp b/src/cpu/x86/vm/frame_x86.cpp index 5d4da6260..94166ea0f 100644 --- a/src/cpu/x86/vm/frame_x86.cpp +++ b/src/cpu/x86/vm/frame_x86.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2011, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2012, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -675,3 +675,21 @@ intptr_t *frame::initial_deoptimization_info() { // used to reset the saved FP return fp(); } + +intptr_t* frame::real_fp() const { + if (_cb != NULL) { + // use the frame size if valid + int size = _cb->frame_size(); + if ((size > 0) && + (! is_ricochet_frame())) { + // Work-around: ricochet explicitly excluded because frame size is not + // constant for the ricochet blob but its frame_size could not, for + // some reasons, be declared as <= 0. This potentially confusing + // size declaration should be fixed as another CR. + return unextended_sp() + size; + } + } + // else rely on fp() + assert(! is_compiled_frame(), "unknown compiled frame size"); + return fp(); +} |