OLD | NEW |
1 // Copyright 2014 the V8 project authors. All rights reserved. | 1 // Copyright 2014 the V8 project authors. All rights reserved. |
2 // | 2 // |
3 // Use of this source code is governed by a BSD-style license that can be | 3 // Use of this source code is governed by a BSD-style license that can be |
4 // found in the LICENSE file. | 4 // found in the LICENSE file. |
5 | 5 |
6 #include "src/crankshaft/s390/lithium-codegen-s390.h" | 6 #include "src/crankshaft/s390/lithium-codegen-s390.h" |
7 | 7 |
8 #include "src/base/bits.h" | 8 #include "src/base/bits.h" |
9 #include "src/code-factory.h" | 9 #include "src/code-factory.h" |
10 #include "src/code-stubs.h" | 10 #include "src/code-stubs.h" |
(...skipping 90 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
101 // lr: Caller's pc. | 101 // lr: Caller's pc. |
102 // ip: Our own function entry (required by the prologue) | 102 // ip: Our own function entry (required by the prologue) |
103 } | 103 } |
104 | 104 |
105 int prologue_offset = masm_->pc_offset(); | 105 int prologue_offset = masm_->pc_offset(); |
106 | 106 |
107 if (prologue_offset) { | 107 if (prologue_offset) { |
108 // Prologue logic requires its starting address in ip and the | 108 // Prologue logic requires its starting address in ip and the |
109 // corresponding offset from the function entry. Need to add | 109 // corresponding offset from the function entry. Need to add |
110 // 4 bytes for the size of AHI/AGHI that AddP expands into. | 110 // 4 bytes for the size of AHI/AGHI that AddP expands into. |
111 __ AddP(ip, ip, Operand(prologue_offset + sizeof(FourByteInstr))); | 111 prologue_offset += sizeof(FourByteInstr); |
| 112 __ AddP(ip, ip, Operand(prologue_offset)); |
112 } | 113 } |
113 info()->set_prologue_offset(prologue_offset); | 114 info()->set_prologue_offset(prologue_offset); |
114 if (NeedsEagerFrame()) { | 115 if (NeedsEagerFrame()) { |
115 if (info()->IsStub()) { | 116 if (info()->IsStub()) { |
116 __ StubPrologue(StackFrame::STUB, ip, prologue_offset); | 117 __ StubPrologue(StackFrame::STUB, ip, prologue_offset); |
117 } else { | 118 } else { |
118 __ Prologue(info()->GeneratePreagedPrologue(), ip, prologue_offset); | 119 __ Prologue(info()->GeneratePreagedPrologue(), ip, prologue_offset); |
119 } | 120 } |
120 frame_is_built_ = true; | 121 frame_is_built_ = true; |
121 } | 122 } |
(...skipping 5541 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
5663 } | 5664 } |
5664 | 5665 |
5665 void LCodeGen::DoStoreFrameContext(LStoreFrameContext* instr) { | 5666 void LCodeGen::DoStoreFrameContext(LStoreFrameContext* instr) { |
5666 Register context = ToRegister(instr->context()); | 5667 Register context = ToRegister(instr->context()); |
5667 __ StoreP(context, MemOperand(fp, StandardFrameConstants::kContextOffset)); | 5668 __ StoreP(context, MemOperand(fp, StandardFrameConstants::kContextOffset)); |
5668 } | 5669 } |
5669 | 5670 |
5670 #undef __ | 5671 #undef __ |
5671 } // namespace internal | 5672 } // namespace internal |
5672 } // namespace v8 | 5673 } // namespace v8 |
OLD | NEW |