| 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 92 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 103 #define ShiftRight_ srw | 103 #define ShiftRight_ srw |
| 104 #define ShiftRightArith sraw | 104 #define ShiftRightArith sraw |
| 105 #define Mul mullw | 105 #define Mul mullw |
| 106 #define Div divw | 106 #define Div divw |
| 107 #endif | 107 #endif |
| 108 | 108 |
| 109 | 109 |
| 110 // MacroAssembler implements a collection of frequently used macros. | 110 // MacroAssembler implements a collection of frequently used macros. |
| 111 class MacroAssembler : public Assembler { | 111 class MacroAssembler : public Assembler { |
| 112 public: | 112 public: |
| 113 // The isolate parameter can be NULL if the macro assembler should | |
| 114 // not use isolate-dependent functionality. In this case, it's the | |
| 115 // responsibility of the caller to never invoke such function on the | |
| 116 // macro assembler. | |
| 117 MacroAssembler(Isolate* isolate, void* buffer, int size, | 113 MacroAssembler(Isolate* isolate, void* buffer, int size, |
| 118 CodeObjectRequired create_code_object); | 114 CodeObjectRequired create_code_object); |
| 119 | 115 |
| 120 | 116 |
| 121 // Returns the size of a call in instructions. Note, the value returned is | 117 // Returns the size of a call in instructions. Note, the value returned is |
| 122 // only valid as long as no entries are added to the constant pool between | 118 // only valid as long as no entries are added to the constant pool between |
| 123 // checking the call size and emitting the actual call. | 119 // checking the call size and emitting the actual call. |
| 124 static int CallSize(Register target); | 120 static int CallSize(Register target); |
| 125 int CallSize(Address target, RelocInfo::Mode rmode, Condition cond = al); | 121 int CallSize(Address target, RelocInfo::Mode rmode, Condition cond = al); |
| 126 static int CallSizeNotPredictableCodeSize(Address target, | 122 static int CallSizeNotPredictableCodeSize(Address target, |
| (...skipping 1456 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1583 #define ACCESS_MASM(masm) \ | 1579 #define ACCESS_MASM(masm) \ |
| 1584 masm->stop(__FILE_LINE__); \ | 1580 masm->stop(__FILE_LINE__); \ |
| 1585 masm-> | 1581 masm-> |
| 1586 #else | 1582 #else |
| 1587 #define ACCESS_MASM(masm) masm-> | 1583 #define ACCESS_MASM(masm) masm-> |
| 1588 #endif | 1584 #endif |
| 1589 } // namespace internal | 1585 } // namespace internal |
| 1590 } // namespace v8 | 1586 } // namespace v8 |
| 1591 | 1587 |
| 1592 #endif // V8_PPC_MACRO_ASSEMBLER_PPC_H_ | 1588 #endif // V8_PPC_MACRO_ASSEMBLER_PPC_H_ |
| OLD | NEW |