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_ARM64_LITHIUM_ARM64_H_ | 5 #ifndef V8_ARM64_LITHIUM_ARM64_H_ |
6 #define V8_ARM64_LITHIUM_ARM64_H_ | 6 #define V8_ARM64_LITHIUM_ARM64_H_ |
7 | 7 |
8 #include "hydrogen.h" | 8 #include "hydrogen.h" |
9 #include "lithium-allocator.h" | 9 #include "lithium-allocator.h" |
10 #include "lithium.h" | 10 #include "lithium.h" |
(...skipping 2368 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2379 return is_external() || is_fixed_typed_array(); | 2379 return is_external() || is_fixed_typed_array(); |
2380 } | 2380 } |
2381 LOperand* elements() { return this->inputs_[0]; } | 2381 LOperand* elements() { return this->inputs_[0]; } |
2382 LOperand* key() { return this->inputs_[1]; } | 2382 LOperand* key() { return this->inputs_[1]; } |
2383 LOperand* value() { return this->inputs_[2]; } | 2383 LOperand* value() { return this->inputs_[2]; } |
2384 ElementsKind elements_kind() const { | 2384 ElementsKind elements_kind() const { |
2385 return this->hydrogen()->elements_kind(); | 2385 return this->hydrogen()->elements_kind(); |
2386 } | 2386 } |
2387 | 2387 |
2388 bool NeedsCanonicalization() { | 2388 bool NeedsCanonicalization() { |
| 2389 if (hydrogen()->value()->IsAdd() || hydrogen()->value()->IsSub() || |
| 2390 hydrogen()->value()->IsMul() || hydrogen()->value()->IsDiv()) { |
| 2391 return false; |
| 2392 } |
2389 return this->hydrogen()->NeedsCanonicalization(); | 2393 return this->hydrogen()->NeedsCanonicalization(); |
2390 } | 2394 } |
2391 uint32_t additional_index() const { return this->hydrogen()->index_offset(); } | 2395 uint32_t additional_index() const { return this->hydrogen()->index_offset(); } |
2392 | 2396 |
2393 void PrintDataTo(StringStream* stream) V8_OVERRIDE { | 2397 void PrintDataTo(StringStream* stream) V8_OVERRIDE { |
2394 this->elements()->PrintTo(stream); | 2398 this->elements()->PrintTo(stream); |
2395 stream->Add("["); | 2399 stream->Add("["); |
2396 this->key()->PrintTo(stream); | 2400 this->key()->PrintTo(stream); |
2397 if (this->hydrogen()->IsDehoisted()) { | 2401 if (this->hydrogen()->IsDehoisted()) { |
2398 stream->Add(" + %d] <-", this->additional_index()); | 2402 stream->Add(" + %d] <-", this->additional_index()); |
(...skipping 693 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
3092 | 3096 |
3093 DISALLOW_COPY_AND_ASSIGN(LChunkBuilder); | 3097 DISALLOW_COPY_AND_ASSIGN(LChunkBuilder); |
3094 }; | 3098 }; |
3095 | 3099 |
3096 #undef DECLARE_HYDROGEN_ACCESSOR | 3100 #undef DECLARE_HYDROGEN_ACCESSOR |
3097 #undef DECLARE_CONCRETE_INSTRUCTION | 3101 #undef DECLARE_CONCRETE_INSTRUCTION |
3098 | 3102 |
3099 } } // namespace v8::internal | 3103 } } // namespace v8::internal |
3100 | 3104 |
3101 #endif // V8_ARM64_LITHIUM_ARM64_H_ | 3105 #endif // V8_ARM64_LITHIUM_ARM64_H_ |
OLD | NEW |