Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(533)

Side by Side Diff: src/objects.cc

Issue 73123002: Fix GCMole warning (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: whitespace Created 7 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 12213 matching lines...) Expand 10 before | Expand all | Expand 10 after
12224 object->ValidateElements(); 12224 object->ValidateElements();
12225 return value; 12225 return value;
12226 } 12226 }
12227 // Change elements kind from Smi-only to generic FAST if necessary. 12227 // Change elements kind from Smi-only to generic FAST if necessary.
12228 if (object->HasFastSmiElements() && !value->IsSmi()) { 12228 if (object->HasFastSmiElements() && !value->IsSmi()) {
12229 ElementsKind kind = object->HasFastHoleyElements() 12229 ElementsKind kind = object->HasFastHoleyElements()
12230 ? FAST_HOLEY_ELEMENTS 12230 ? FAST_HOLEY_ELEMENTS
12231 : FAST_ELEMENTS; 12231 : FAST_ELEMENTS;
12232 12232
12233 UpdateAllocationSite(object, kind); 12233 UpdateAllocationSite(object, kind);
12234 object->set_map(*GetElementsTransitionMap(object, kind)); 12234 Handle<Map> new_map = GetElementsTransitionMap(object, kind);
12235 object->set_map(*new_map);
12235 ASSERT(IsFastObjectElementsKind(object->GetElementsKind())); 12236 ASSERT(IsFastObjectElementsKind(object->GetElementsKind()));
12236 } 12237 }
12237 // Increase backing store capacity if that's been decided previously. 12238 // Increase backing store capacity if that's been decided previously.
12238 if (new_capacity != capacity) { 12239 if (new_capacity != capacity) {
12239 SetFastElementsCapacitySmiMode smi_mode = 12240 SetFastElementsCapacitySmiMode smi_mode =
12240 value->IsSmi() && object->HasFastSmiElements() 12241 value->IsSmi() && object->HasFastSmiElements()
12241 ? kAllowSmiElements 12242 ? kAllowSmiElements
12242 : kDontAllowSmiElements; 12243 : kDontAllowSmiElements;
12243 Handle<FixedArray> new_elements = 12244 Handle<FixedArray> new_elements =
12244 SetFastElementsCapacityAndLength(object, new_capacity, array_length, 12245 SetFastElementsCapacityAndLength(object, new_capacity, array_length,
(...skipping 4398 matching lines...) Expand 10 before | Expand all | Expand 10 after
16643 #define ERROR_MESSAGES_TEXTS(C, T) T, 16644 #define ERROR_MESSAGES_TEXTS(C, T) T,
16644 static const char* error_messages_[] = { 16645 static const char* error_messages_[] = {
16645 ERROR_MESSAGES_LIST(ERROR_MESSAGES_TEXTS) 16646 ERROR_MESSAGES_LIST(ERROR_MESSAGES_TEXTS)
16646 }; 16647 };
16647 #undef ERROR_MESSAGES_TEXTS 16648 #undef ERROR_MESSAGES_TEXTS
16648 return error_messages_[reason]; 16649 return error_messages_[reason];
16649 } 16650 }
16650 16651
16651 16652
16652 } } // namespace v8::internal 16653 } } // namespace v8::internal
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698