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

Side by Side Diff: src/heap.cc

Issue 154283002: V8 Microtask Queue & API (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: cr comments Created 6 years, 10 months 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 | « src/heap.h ('k') | src/isolate.h » ('j') | src/v8.cc » ('J')
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2012 the V8 project authors. All rights reserved. 1 // Copyright 2012 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 3251 matching lines...) Expand 10 before | Expand all | Expand 10 after
3262 3262
3263 // Allocate object to hold object observation state. 3263 // Allocate object to hold object observation state.
3264 { MaybeObject* maybe_obj = AllocateMap(JS_OBJECT_TYPE, JSObject::kHeaderSize); 3264 { MaybeObject* maybe_obj = AllocateMap(JS_OBJECT_TYPE, JSObject::kHeaderSize);
3265 if (!maybe_obj->ToObject(&obj)) return false; 3265 if (!maybe_obj->ToObject(&obj)) return false;
3266 } 3266 }
3267 { MaybeObject* maybe_obj = AllocateJSObjectFromMap(Map::cast(obj)); 3267 { MaybeObject* maybe_obj = AllocateJSObjectFromMap(Map::cast(obj));
3268 if (!maybe_obj->ToObject(&obj)) return false; 3268 if (!maybe_obj->ToObject(&obj)) return false;
3269 } 3269 }
3270 set_observation_state(JSObject::cast(obj)); 3270 set_observation_state(JSObject::cast(obj));
3271 3271
3272 // Allocate object to hold object microtask state.
3273 { MaybeObject* maybe_obj = AllocateMap(JS_OBJECT_TYPE, JSObject::kHeaderSize);
3274 if (!maybe_obj->ToObject(&obj)) return false;
3275 }
3276 { MaybeObject* maybe_obj = AllocateJSObjectFromMap(Map::cast(obj));
3277 if (!maybe_obj->ToObject(&obj)) return false;
3278 }
3279 set_microtask_state(JSObject::cast(obj));
3280
3272 { MaybeObject* maybe_obj = AllocateSymbol(); 3281 { MaybeObject* maybe_obj = AllocateSymbol();
3273 if (!maybe_obj->ToObject(&obj)) return false; 3282 if (!maybe_obj->ToObject(&obj)) return false;
3274 } 3283 }
3275 Symbol::cast(obj)->set_is_private(true); 3284 Symbol::cast(obj)->set_is_private(true);
3276 set_frozen_symbol(Symbol::cast(obj)); 3285 set_frozen_symbol(Symbol::cast(obj));
3277 3286
3278 { MaybeObject* maybe_obj = AllocateSymbol(); 3287 { MaybeObject* maybe_obj = AllocateSymbol();
3279 if (!maybe_obj->ToObject(&obj)) return false; 3288 if (!maybe_obj->ToObject(&obj)) return false;
3280 } 3289 }
3281 Symbol::cast(obj)->set_is_private(true); 3290 Symbol::cast(obj)->set_is_private(true);
(...skipping 4420 matching lines...) Expand 10 before | Expand all | Expand 10 after
7702 static_cast<int>(object_sizes_last_time_[index])); 7711 static_cast<int>(object_sizes_last_time_[index]));
7703 CODE_AGE_LIST_COMPLETE(ADJUST_LAST_TIME_OBJECT_COUNT) 7712 CODE_AGE_LIST_COMPLETE(ADJUST_LAST_TIME_OBJECT_COUNT)
7704 #undef ADJUST_LAST_TIME_OBJECT_COUNT 7713 #undef ADJUST_LAST_TIME_OBJECT_COUNT
7705 7714
7706 OS::MemCopy(object_counts_last_time_, object_counts_, sizeof(object_counts_)); 7715 OS::MemCopy(object_counts_last_time_, object_counts_, sizeof(object_counts_));
7707 OS::MemCopy(object_sizes_last_time_, object_sizes_, sizeof(object_sizes_)); 7716 OS::MemCopy(object_sizes_last_time_, object_sizes_, sizeof(object_sizes_));
7708 ClearObjectStats(); 7717 ClearObjectStats();
7709 } 7718 }
7710 7719
7711 } } // namespace v8::internal 7720 } } // namespace v8::internal
OLDNEW
« no previous file with comments | « src/heap.h ('k') | src/isolate.h » ('j') | src/v8.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698