| OLD | NEW |
| 1 // Copyright 2015 the V8 project authors. All rights reserved. | 1 // Copyright 2015 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 #include <ostream> | 5 #include <ostream> |
| 6 | 6 |
| 7 #include "src/accessors.h" | 7 #include "src/accessors.h" |
| 8 #include "src/compilation-dependencies.h" | 8 #include "src/compilation-dependencies.h" |
| 9 #include "src/compiler/access-info.h" | 9 #include "src/compiler/access-info.h" |
| 10 #include "src/compiler/type-cache.h" | 10 #include "src/compiler/type-cache.h" |
| (...skipping 332 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 343 return true; | 343 return true; |
| 344 } else { | 344 } else { |
| 345 DCHECK_EQ(kAccessor, details.kind()); | 345 DCHECK_EQ(kAccessor, details.kind()); |
| 346 // TODO(turbofan): Add support for general accessors? | 346 // TODO(turbofan): Add support for general accessors? |
| 347 return false; | 347 return false; |
| 348 } | 348 } |
| 349 | 349 |
| 350 } else { | 350 } else { |
| 351 DCHECK_EQ(kDescriptor, details.location()); | 351 DCHECK_EQ(kDescriptor, details.location()); |
| 352 if (details.kind() == kData) { | 352 if (details.kind() == kData) { |
| 353 DCHECK(!FLAG_track_constant_fields); |
| 353 *access_info = PropertyAccessInfo::DataConstant( | 354 *access_info = PropertyAccessInfo::DataConstant( |
| 354 MapList{receiver_map}, | 355 MapList{receiver_map}, |
| 355 handle(descriptors->GetValue(number), isolate()), holder); | 356 handle(descriptors->GetValue(number), isolate()), holder); |
| 356 return true; | 357 return true; |
| 357 } else { | 358 } else { |
| 358 DCHECK_EQ(kAccessor, details.kind()); | 359 DCHECK_EQ(kAccessor, details.kind()); |
| 359 Handle<Object> accessors(descriptors->GetValue(number), isolate()); | 360 Handle<Object> accessors(descriptors->GetValue(number), isolate()); |
| 360 if (!accessors->IsAccessorPair()) return false; | 361 if (!accessors->IsAccessorPair()) return false; |
| 361 Handle<Object> accessor( | 362 Handle<Object> accessor( |
| 362 access_mode == AccessMode::kLoad | 363 access_mode == AccessMode::kLoad |
| (...skipping 206 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 569 } | 570 } |
| 570 return false; | 571 return false; |
| 571 } | 572 } |
| 572 | 573 |
| 573 | 574 |
| 574 Factory* AccessInfoFactory::factory() const { return isolate()->factory(); } | 575 Factory* AccessInfoFactory::factory() const { return isolate()->factory(); } |
| 575 | 576 |
| 576 } // namespace compiler | 577 } // namespace compiler |
| 577 } // namespace internal | 578 } // namespace internal |
| 578 } // namespace v8 | 579 } // namespace v8 |
| OLD | NEW |