Mercurial > hg > truffle
diff src/cpu/x86/vm/frame_x86.cpp @ 4852:6d00795f99a1
Merge
author | dsamersoff |
---|---|
date | Wed, 25 Jan 2012 15:03:42 -0800 |
parents | eaa9557116a2 |
children | 82e5a84b7436 |
line wrap: on
line diff
--- a/src/cpu/x86/vm/frame_x86.cpp Wed Jan 25 21:10:08 2012 +0400 +++ b/src/cpu/x86/vm/frame_x86.cpp Wed Jan 25 15:03:42 2012 -0800 @@ -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 @@ // 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(); +}