Chromium Code Reviews| Index: src/compiler/frame.cc |
| diff --git a/src/compiler/frame.cc b/src/compiler/frame.cc |
| index fd080c8def8ffed2f7cbeaecc78d6fbbf70c9e05..e3c3e996f03dab5c6f59adc674e30700bbc0c5f7 100644 |
| --- a/src/compiler/frame.cc |
| +++ b/src/compiler/frame.cc |
| @@ -44,16 +44,13 @@ void FrameAccessState::SetFrameAccessToDefault() { |
| FrameOffset FrameAccessState::GetFrameOffset(int spill_slot) const { |
| - const int offset = |
| - (StandardFrameConstants::kFixedSlotCountAboveFp - spill_slot - 1) * |
| - kPointerSize; |
| + const int frame_offset = FrameSlotToFPOffset(spill_slot); |
| if (access_frame_with_fp()) { |
| DCHECK(frame()->needs_frame()); |
| - return FrameOffset::FromFramePointer(offset); |
| + return FrameOffset::FromFramePointer(frame_offset); |
| } else { |
| // No frame. Retrieve all parameters relative to stack pointer. |
| - int sp_offset = |
| - offset + ((frame()->GetSpToFpSlotCount() + sp_delta()) * kPointerSize); |
| + int sp_offset = frame_offset + GetSpToFpOffset(); |
|
Jarin
2016/03/11 06:19:18
Tiny nit: why FrameSlotToFPOffset has capital P in
|
| return FrameOffset::FromStackPointer(sp_offset); |
| } |
| } |