OLD | NEW |
1 // Copyright 2014 the V8 project authors. All rights reserved. | 1 // Copyright 2014 the V8 project authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #ifndef V8_PPC_MACRO_ASSEMBLER_PPC_H_ | 5 #ifndef V8_PPC_MACRO_ASSEMBLER_PPC_H_ |
6 #define V8_PPC_MACRO_ASSEMBLER_PPC_H_ | 6 #define V8_PPC_MACRO_ASSEMBLER_PPC_H_ |
7 | 7 |
8 #include "src/assembler.h" | 8 #include "src/assembler.h" |
9 #include "src/bailout-reason.h" | 9 #include "src/bailout-reason.h" |
10 #include "src/frames.h" | 10 #include "src/frames.h" |
(...skipping 109 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
120 void Call(Register target); | 120 void Call(Register target); |
121 void CallJSEntry(Register target); | 121 void CallJSEntry(Register target); |
122 void Call(Address target, RelocInfo::Mode rmode, Condition cond = al); | 122 void Call(Address target, RelocInfo::Mode rmode, Condition cond = al); |
123 int CallSize(Handle<Code> code, | 123 int CallSize(Handle<Code> code, |
124 RelocInfo::Mode rmode = RelocInfo::CODE_TARGET, | 124 RelocInfo::Mode rmode = RelocInfo::CODE_TARGET, |
125 TypeFeedbackId ast_id = TypeFeedbackId::None(), | 125 TypeFeedbackId ast_id = TypeFeedbackId::None(), |
126 Condition cond = al); | 126 Condition cond = al); |
127 void Call(Handle<Code> code, RelocInfo::Mode rmode = RelocInfo::CODE_TARGET, | 127 void Call(Handle<Code> code, RelocInfo::Mode rmode = RelocInfo::CODE_TARGET, |
128 TypeFeedbackId ast_id = TypeFeedbackId::None(), | 128 TypeFeedbackId ast_id = TypeFeedbackId::None(), |
129 Condition cond = al); | 129 Condition cond = al); |
130 void Ret(Condition cond = al); | 130 void Ret() { blr(); } |
| 131 void Ret(Condition cond, CRegister cr = cr7) { bclr(cond, cr); } |
131 | 132 |
132 // Emit code to discard a non-negative number of pointer-sized elements | 133 // Emit code to discard a non-negative number of pointer-sized elements |
133 // from the stack, clobbering only the sp register. | 134 // from the stack, clobbering only the sp register. |
134 void Drop(int count, Condition cond = al); | 135 void Drop(int count); |
135 | 136 |
136 void Ret(int drop, Condition cond = al); | 137 void Ret(int drop) { |
| 138 Drop(drop); |
| 139 blr(); |
| 140 } |
137 | 141 |
138 void Call(Label* target); | 142 void Call(Label* target); |
139 | 143 |
140 // Emit call to the code we are currently generating. | 144 // Emit call to the code we are currently generating. |
141 void CallSelf() { | 145 void CallSelf() { |
142 Handle<Code> self(reinterpret_cast<Code**>(CodeObject().location())); | 146 Handle<Code> self(reinterpret_cast<Code**>(CodeObject().location())); |
143 Call(self, RelocInfo::CODE_TARGET); | 147 Call(self, RelocInfo::CODE_TARGET); |
144 } | 148 } |
145 | 149 |
146 // Register move. May do nothing if the registers are identical. | 150 // Register move. May do nothing if the registers are identical. |
(...skipping 1419 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1566 #define ACCESS_MASM(masm) \ | 1570 #define ACCESS_MASM(masm) \ |
1567 masm->stop(__FILE_LINE__); \ | 1571 masm->stop(__FILE_LINE__); \ |
1568 masm-> | 1572 masm-> |
1569 #else | 1573 #else |
1570 #define ACCESS_MASM(masm) masm-> | 1574 #define ACCESS_MASM(masm) masm-> |
1571 #endif | 1575 #endif |
1572 } | 1576 } |
1573 } // namespace v8::internal | 1577 } // namespace v8::internal |
1574 | 1578 |
1575 #endif // V8_PPC_MACRO_ASSEMBLER_PPC_H_ | 1579 #endif // V8_PPC_MACRO_ASSEMBLER_PPC_H_ |
OLD | NEW |