OLD | NEW |
1 // Copyright 2013 the V8 project authors. All rights reserved. | 1 // Copyright 2013 the V8 project authors. All rights reserved. |
2 // Redistribution and use in source and binary forms, with or without | 2 // Redistribution and use in source and binary forms, with or without |
3 // modification, are permitted provided that the following conditions are | 3 // modification, are permitted provided that the following conditions are |
4 // met: | 4 // met: |
5 // | 5 // |
6 // * Redistributions of source code must retain the above copyright | 6 // * Redistributions of source code must retain the above copyright |
7 // notice, this list of conditions and the following disclaimer. | 7 // notice, this list of conditions and the following disclaimer. |
8 // * Redistributions in binary form must reproduce the above | 8 // * Redistributions in binary form must reproduce the above |
9 // copyright notice, this list of conditions and the following | 9 // copyright notice, this list of conditions and the following |
10 // disclaimer in the documentation and/or other materials provided | 10 // disclaimer in the documentation and/or other materials provided |
(...skipping 44 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
55 update_current_site(*scope_site); | 55 update_current_site(*scope_site); |
56 } | 56 } |
57 ASSERT(!scope_site.is_null()); | 57 ASSERT(!scope_site.is_null()); |
58 return scope_site; | 58 return scope_site; |
59 } | 59 } |
60 | 60 |
61 | 61 |
62 void AllocationSiteCreationContext::ExitScope( | 62 void AllocationSiteCreationContext::ExitScope( |
63 Handle<AllocationSite> scope_site, | 63 Handle<AllocationSite> scope_site, |
64 Handle<JSObject> object) { | 64 Handle<JSObject> object) { |
65 if (!object.is_null() && !object->IsFailure()) { | 65 if (!object.is_null()) { |
66 bool top_level = !scope_site.is_null() && | 66 bool top_level = !scope_site.is_null() && |
67 top().is_identical_to(scope_site); | 67 top().is_identical_to(scope_site); |
68 | 68 |
69 scope_site->set_transition_info(*object); | 69 scope_site->set_transition_info(*object); |
70 if (FLAG_trace_creation_allocation_sites) { | 70 if (FLAG_trace_creation_allocation_sites) { |
71 if (top_level) { | 71 if (top_level) { |
72 PrintF("*** Setting AllocationSite %p transition_info %p\n", | 72 PrintF("*** Setting AllocationSite %p transition_info %p\n", |
73 static_cast<void*>(*scope_site), | 73 static_cast<void*>(*scope_site), |
74 static_cast<void*>(*object)); | 74 static_cast<void*>(*object)); |
75 } else { | 75 } else { |
(...skipping 17 matching lines...) Expand all Loading... |
93 object->IsJSArray() ? "JSArray" : "JSObject", | 93 object->IsJSArray() ? "JSArray" : "JSObject", |
94 static_cast<void*>(*object)); | 94 static_cast<void*>(*object)); |
95 } | 95 } |
96 return true; | 96 return true; |
97 } | 97 } |
98 } | 98 } |
99 return false; | 99 return false; |
100 } | 100 } |
101 | 101 |
102 } } // namespace v8::internal | 102 } } // namespace v8::internal |
OLD | NEW |