OLD | NEW |
1 // Copyright 2012 the V8 project authors. All rights reserved. | 1 // Copyright 2012 the V8 project authors. All rights reserved. |
2 // Redistribution and use in source and binary forms, with or without | 2 // Redistribution and use in source and binary forms, with or without |
3 // modification, are permitted provided that the following conditions are | 3 // modification, are permitted provided that the following conditions are |
4 // met: | 4 // met: |
5 // | 5 // |
6 // * Redistributions of source code must retain the above copyright | 6 // * Redistributions of source code must retain the above copyright |
7 // notice, this list of conditions and the following disclaimer. | 7 // notice, this list of conditions and the following disclaimer. |
8 // * Redistributions in binary form must reproduce the above | 8 // * Redistributions in binary form must reproduce the above |
9 // copyright notice, this list of conditions and the following | 9 // copyright notice, this list of conditions and the following |
10 // disclaimer in the documentation and/or other materials provided | 10 // disclaimer in the documentation and/or other materials provided |
(...skipping 118 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
129 inline Code* StackFrame::LookupCode() const { | 129 inline Code* StackFrame::LookupCode() const { |
130 return GetContainingCode(isolate(), pc()); | 130 return GetContainingCode(isolate(), pc()); |
131 } | 131 } |
132 | 132 |
133 | 133 |
134 inline Code* StackFrame::GetContainingCode(Isolate* isolate, Address pc) { | 134 inline Code* StackFrame::GetContainingCode(Isolate* isolate, Address pc) { |
135 return isolate->inner_pointer_to_code_cache()->GetCacheEntry(pc)->code; | 135 return isolate->inner_pointer_to_code_cache()->GetCacheEntry(pc)->code; |
136 } | 136 } |
137 | 137 |
138 | 138 |
| 139 inline Address* StackFrame::ResolveReturnAddressLocation(Address* pc_address) { |
| 140 if (return_address_location_resolver_ == NULL) { |
| 141 return pc_address; |
| 142 } else { |
| 143 return reinterpret_cast<Address*>( |
| 144 return_address_location_resolver_( |
| 145 reinterpret_cast<uintptr_t>(pc_address))); |
| 146 } |
| 147 } |
| 148 |
| 149 |
139 inline EntryFrame::EntryFrame(StackFrameIteratorBase* iterator) | 150 inline EntryFrame::EntryFrame(StackFrameIteratorBase* iterator) |
140 : StackFrame(iterator) { | 151 : StackFrame(iterator) { |
141 } | 152 } |
142 | 153 |
143 | 154 |
144 inline EntryConstructFrame::EntryConstructFrame( | 155 inline EntryConstructFrame::EntryConstructFrame( |
145 StackFrameIteratorBase* iterator) | 156 StackFrameIteratorBase* iterator) |
146 : EntryFrame(iterator) { | 157 : EntryFrame(iterator) { |
147 } | 158 } |
148 | 159 |
(...skipping 179 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
328 inline JavaScriptFrame* SafeStackFrameIterator::frame() const { | 339 inline JavaScriptFrame* SafeStackFrameIterator::frame() const { |
329 ASSERT(!done()); | 340 ASSERT(!done()); |
330 ASSERT(frame_->is_java_script()); | 341 ASSERT(frame_->is_java_script()); |
331 return static_cast<JavaScriptFrame*>(frame_); | 342 return static_cast<JavaScriptFrame*>(frame_); |
332 } | 343 } |
333 | 344 |
334 | 345 |
335 } } // namespace v8::internal | 346 } } // namespace v8::internal |
336 | 347 |
337 #endif // V8_FRAMES_INL_H_ | 348 #endif // V8_FRAMES_INL_H_ |
OLD | NEW |