comparison src/cpu/zero/vm/frame_zero.hpp @ 1505:0c5b3cf3c1f5

6939182: Zero JNI handles fix Summary: Zero will exit with an error when invoked with -Xcheck:jni. Reviewed-by: twisti, kamg Contributed-by: Gary Benson <gbenson@redhat.com>
author twisti
date Fri, 30 Apr 2010 04:27:25 -0700
parents 8e7adf982378
children 6cfbdb113e52
comparison
equal deleted inserted replaced
1504:ae8f909e5fc7 1505:0c5b3cf3c1f5
1 /* 1 /*
2 * Copyright 2003-2007 Sun Microsystems, Inc. All Rights Reserved. 2 * Copyright 2003-2007 Sun Microsystems, Inc. All Rights Reserved.
3 * Copyright 2007, 2008, 2009 Red Hat, Inc. 3 * Copyright 2007, 2008, 2009, 2010 Red Hat, Inc.
4 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
5 * 5 *
6 * This code is free software; you can redistribute it and/or modify it 6 * This code is free software; you can redistribute it and/or modify it
7 * under the terms of the GNU General Public License version 2 only, as 7 * under the terms of the GNU General Public License version 2 only, as
8 * published by the Free Software Foundation. 8 * published by the Free Software Foundation.
30 pc_return_offset = 0 30 pc_return_offset = 0
31 }; 31 };
32 32
33 // Constructor 33 // Constructor
34 public: 34 public:
35 frame(intptr_t* sp, intptr_t* fp); 35 frame(ZeroFrame* zeroframe, intptr_t* sp);
36 36
37 // The sp of a Zero frame is the address of the highest word in
38 // that frame. We keep track of the lowest address too, so the
39 // boundaries of the frame are available for debug printing.
40 private: 37 private:
41 intptr_t* _fp; 38 ZeroFrame* _zeroframe;
42 39
43 public: 40 public:
41 const ZeroFrame *zeroframe() const {
42 return _zeroframe;
43 }
44
44 intptr_t* fp() const { 45 intptr_t* fp() const {
45 return _fp; 46 return (intptr_t *) zeroframe();
46 } 47 }
47 48
48 #ifdef CC_INTERP 49 #ifdef CC_INTERP
49 inline interpreterState get_interpreterState() const; 50 inline interpreterState get_interpreterState() const;
50 #endif // CC_INTERP 51 #endif // CC_INTERP
51 52
52 public: 53 public:
53 const ZeroFrame *zeroframe() const {
54 return (ZeroFrame *) sp();
55 }
56
57 const EntryFrame *zero_entryframe() const { 54 const EntryFrame *zero_entryframe() const {
58 return zeroframe()->as_entry_frame(); 55 return zeroframe()->as_entry_frame();
59 } 56 }
60 const InterpreterFrame *zero_interpreterframe() const { 57 const InterpreterFrame *zero_interpreterframe() const {
61 return zeroframe()->as_interpreter_frame(); 58 return zeroframe()->as_interpreter_frame();