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 #include "src/crankshaft/hydrogen.h" | 5 #include "src/crankshaft/hydrogen.h" |
6 | 6 |
7 #include <memory> | 7 #include <memory> |
8 #include <sstream> | 8 #include <sstream> |
9 | 9 |
10 #include "src/allocation-site-scopes.h" | 10 #include "src/allocation-site-scopes.h" |
(...skipping 5436 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
5447 Handle<Object> value(fast_elements->get(i), isolate); | 5447 Handle<Object> value(fast_elements->get(i), isolate); |
5448 if (value->IsJSObject()) { | 5448 if (value->IsJSObject()) { |
5449 Handle<JSObject> value_object = Handle<JSObject>::cast(value); | 5449 Handle<JSObject> value_object = Handle<JSObject>::cast(value); |
5450 if (!IsFastLiteral(value_object, | 5450 if (!IsFastLiteral(value_object, |
5451 max_depth - 1, | 5451 max_depth - 1, |
5452 max_properties)) { | 5452 max_properties)) { |
5453 return false; | 5453 return false; |
5454 } | 5454 } |
5455 } | 5455 } |
5456 } | 5456 } |
5457 } else if (!boilerplate->HasFastDoubleElements()) { | 5457 } else if (boilerplate->HasFastDoubleElements()) { |
| 5458 if (elements->Size() > kMaxRegularHeapObjectSize) return false; |
| 5459 } else { |
5458 return false; | 5460 return false; |
5459 } | 5461 } |
5460 } | 5462 } |
5461 | 5463 |
5462 Handle<FixedArray> properties(boilerplate->properties()); | 5464 Handle<FixedArray> properties(boilerplate->properties()); |
5463 if (properties->length() > 0) { | 5465 if (properties->length() > 0) { |
5464 return false; | 5466 return false; |
5465 } else { | 5467 } else { |
5466 Handle<DescriptorArray> descriptors( | 5468 Handle<DescriptorArray> descriptors( |
5467 boilerplate->map()->instance_descriptors()); | 5469 boilerplate->map()->instance_descriptors()); |
(...skipping 7568 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
13036 isolate()->GetHTracer()->TraceHydrogen(name(), graph_); | 13038 isolate()->GetHTracer()->TraceHydrogen(name(), graph_); |
13037 } | 13039 } |
13038 | 13040 |
13039 #ifdef DEBUG | 13041 #ifdef DEBUG |
13040 graph_->Verify(false); // No full verify. | 13042 graph_->Verify(false); // No full verify. |
13041 #endif | 13043 #endif |
13042 } | 13044 } |
13043 | 13045 |
13044 } // namespace internal | 13046 } // namespace internal |
13045 } // namespace v8 | 13047 } // namespace v8 |
OLD | NEW |