66 assert(top_zero_frame() == NULL, "junk on stack after Java call"); |
66 assert(top_zero_frame() == NULL, "junk on stack after Java call"); |
67 } |
67 } |
68 |
68 |
69 public: |
69 public: |
70 void set_last_Java_frame() { |
70 void set_last_Java_frame() { |
71 set_last_Java_frame(top_zero_frame()); |
71 set_last_Java_frame(top_zero_frame(), zero_stack()->sp()); |
72 } |
72 } |
73 void reset_last_Java_frame() { |
73 void reset_last_Java_frame() { |
74 set_last_Java_frame(NULL); |
74 frame_anchor()->zap(); |
75 } |
75 } |
76 void set_last_Java_frame(ZeroFrame* frame) { |
76 void set_last_Java_frame(ZeroFrame* fp, intptr_t* sp) { |
77 frame_anchor()->set_last_Java_sp((intptr_t *) frame); |
77 frame_anchor()->set(sp, NULL, fp); |
|
78 } |
|
79 |
|
80 public: |
|
81 ZeroFrame* last_Java_fp() { |
|
82 return frame_anchor()->last_Java_fp(); |
78 } |
83 } |
79 |
84 |
80 private: |
85 private: |
81 frame pd_last_frame() { |
86 frame pd_last_frame() { |
82 assert(has_last_Java_frame(), "must have last_Java_sp() when suspended"); |
87 assert(has_last_Java_frame(), "must have last_Java_sp() when suspended"); |
83 return frame(last_Java_sp(), zero_stack()->sp()); |
88 return frame(last_Java_fp(), last_Java_sp()); |
84 } |
89 } |
85 |
90 |
86 public: |
91 public: |
87 // Check for pending suspend requests and pending asynchronous |
92 // Check for pending suspend requests and pending asynchronous |
88 // exceptions. There are separate accessors for these, but |
93 // exceptions. There are separate accessors for these, but |