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

Side by Side Diff: src/runtime.cc

Issue 11035053: Rollback trunk to bleeding_edge revision 12525 (Closed) Base URL: https://v8.googlecode.com/svn/trunk
Patch Set: Created 8 years, 2 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/runtime.h ('k') | src/spaces.h » ('j') | no next file with comments »
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 5014 matching lines...) Expand 10 before | Expand all | Expand 10 after
5025 5025
5026 RUNTIME_FUNCTION(MaybeObject*, Runtime_ToFastProperties) { 5026 RUNTIME_FUNCTION(MaybeObject*, Runtime_ToFastProperties) {
5027 ASSERT(args.length() == 1); 5027 ASSERT(args.length() == 1);
5028 Object* object = args[0]; 5028 Object* object = args[0];
5029 return (object->IsJSObject() && !object->IsGlobalObject()) 5029 return (object->IsJSObject() && !object->IsGlobalObject())
5030 ? JSObject::cast(object)->TransformToFastProperties(0) 5030 ? JSObject::cast(object)->TransformToFastProperties(0)
5031 : object; 5031 : object;
5032 } 5032 }
5033 5033
5034 5034
5035 RUNTIME_FUNCTION(MaybeObject*, Runtime_ToSlowProperties) {
5036 ASSERT(args.length() == 1);
5037 Object* obj = args[0];
5038 return (obj->IsJSObject() && !obj->IsJSGlobalProxy())
5039 ? JSObject::cast(obj)->NormalizeProperties(CLEAR_INOBJECT_PROPERTIES, 0)
5040 : obj;
5041 }
5042
5043
5035 RUNTIME_FUNCTION(MaybeObject*, Runtime_ToBool) { 5044 RUNTIME_FUNCTION(MaybeObject*, Runtime_ToBool) {
5036 NoHandleAllocation ha; 5045 NoHandleAllocation ha;
5037 ASSERT(args.length() == 1); 5046 ASSERT(args.length() == 1);
5038 5047
5039 return args[0]->ToBoolean(); 5048 return args[0]->ToBoolean();
5040 } 5049 }
5041 5050
5042 5051
5043 // Returns the type string of a value; see ECMA-262, 11.4.3 (p 47). 5052 // Returns the type string of a value; see ECMA-262, 11.4.3 (p 47).
5044 // Possible optimizations: put the type string into the oddballs. 5053 // Possible optimizations: put the type string into the oddballs.
(...skipping 8234 matching lines...) Expand 10 before | Expand all | Expand 10 after
13279 // Handle last resort GC and make sure to allow future allocations 13288 // Handle last resort GC and make sure to allow future allocations
13280 // to grow the heap without causing GCs (if possible). 13289 // to grow the heap without causing GCs (if possible).
13281 isolate->counters()->gc_last_resort_from_js()->Increment(); 13290 isolate->counters()->gc_last_resort_from_js()->Increment();
13282 isolate->heap()->CollectAllGarbage(Heap::kNoGCFlags, 13291 isolate->heap()->CollectAllGarbage(Heap::kNoGCFlags,
13283 "Runtime::PerformGC"); 13292 "Runtime::PerformGC");
13284 } 13293 }
13285 } 13294 }
13286 13295
13287 13296
13288 } } // namespace v8::internal 13297 } } // namespace v8::internal
OLDNEW
« no previous file with comments | « src/runtime.h ('k') | src/spaces.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698