OLD | NEW |
1 // Copyright 2013 the V8 project authors. All rights reserved. | 1 // Copyright 2013 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_COMPILER_CODE_GENERATOR_IMPL_H_ | 5 #ifndef V8_COMPILER_CODE_GENERATOR_IMPL_H_ |
6 #define V8_COMPILER_CODE_GENERATOR_IMPL_H_ | 6 #define V8_COMPILER_CODE_GENERATOR_IMPL_H_ |
7 | 7 |
8 #include "src/code-stubs.h" | 8 #include "src/code-stubs.h" |
9 #include "src/compiler/code-generator.h" | 9 #include "src/compiler/code-generator.h" |
10 #include "src/compiler/instruction.h" | 10 #include "src/compiler/instruction.h" |
(...skipping 49 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
60 } | 60 } |
61 | 61 |
62 int8_t InputInt8(size_t index) { | 62 int8_t InputInt8(size_t index) { |
63 return static_cast<int8_t>(InputInt32(index)); | 63 return static_cast<int8_t>(InputInt32(index)); |
64 } | 64 } |
65 | 65 |
66 int16_t InputInt16(size_t index) { | 66 int16_t InputInt16(size_t index) { |
67 return static_cast<int16_t>(InputInt32(index)); | 67 return static_cast<int16_t>(InputInt32(index)); |
68 } | 68 } |
69 | 69 |
| 70 uint8_t InputInt3(size_t index) { |
| 71 return static_cast<uint8_t>(InputInt32(index) & 0x7); |
| 72 } |
| 73 |
| 74 uint8_t InputInt4(size_t index) { |
| 75 return static_cast<uint8_t>(InputInt32(index) & 0xF); |
| 76 } |
| 77 |
70 uint8_t InputInt5(size_t index) { | 78 uint8_t InputInt5(size_t index) { |
71 return static_cast<uint8_t>(InputInt32(index) & 0x1F); | 79 return static_cast<uint8_t>(InputInt32(index) & 0x1F); |
72 } | 80 } |
73 | 81 |
74 uint8_t InputInt6(size_t index) { | 82 uint8_t InputInt6(size_t index) { |
75 return static_cast<uint8_t>(InputInt32(index) & 0x3F); | 83 return static_cast<uint8_t>(InputInt32(index) & 0x3F); |
76 } | 84 } |
77 | 85 |
78 ExternalReference InputExternalReference(size_t index) { | 86 ExternalReference InputExternalReference(size_t index) { |
79 return ToExternalReference(instr_->InputAt(index)); | 87 return ToExternalReference(instr_->InputAt(index)); |
(...skipping 133 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
213 #if V8_TARGET_ARCH_ARM64 || V8_TARGET_ARCH_ARM | 221 #if V8_TARGET_ARCH_ARM64 || V8_TARGET_ARCH_ARM |
214 masm->CheckConstPool(true, false); | 222 masm->CheckConstPool(true, false); |
215 #endif | 223 #endif |
216 } | 224 } |
217 | 225 |
218 } // namespace compiler | 226 } // namespace compiler |
219 } // namespace internal | 227 } // namespace internal |
220 } // namespace v8 | 228 } // namespace v8 |
221 | 229 |
222 #endif // V8_COMPILER_CODE_GENERATOR_IMPL_H | 230 #endif // V8_COMPILER_CODE_GENERATOR_IMPL_H |
OLD | NEW |