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

Side by Side Diff: src/runtime.cc

Issue 12475016: Maintain API compatibility with older versions of V8. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 7 years, 9 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/profile-generator-inl.h ('k') | test/cctest/test-cpu-profiler.cc » ('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 2213 matching lines...) Expand 10 before | Expand all | Expand 10 after
2224 Handle<FixedArray> literals = 2224 Handle<FixedArray> literals =
2225 isolate->factory()->NewFixedArray(number_of_literals, TENURED); 2225 isolate->factory()->NewFixedArray(number_of_literals, TENURED);
2226 if (number_of_literals > 0) { 2226 if (number_of_literals > 0) {
2227 literals->set(JSFunction::kLiteralNativeContextIndex, 2227 literals->set(JSFunction::kLiteralNativeContextIndex,
2228 context->native_context()); 2228 context->native_context());
2229 } 2229 }
2230 target->set_context(*context); 2230 target->set_context(*context);
2231 target->set_literals(*literals); 2231 target->set_literals(*literals);
2232 2232
2233 if (isolate->logger()->is_logging_code_events() || 2233 if (isolate->logger()->is_logging_code_events() ||
2234 isolate->cpu_profiler()->is_profiling()) { 2234 CpuProfiler::is_profiling(isolate)) {
2235 isolate->logger()->LogExistingFunction( 2235 isolate->logger()->LogExistingFunction(
2236 source_shared, Handle<Code>(source_shared->code())); 2236 source_shared, Handle<Code>(source_shared->code()));
2237 } 2237 }
2238 2238
2239 return *target; 2239 return *target;
2240 } 2240 }
2241 2241
2242 2242
2243 RUNTIME_FUNCTION(MaybeObject*, Runtime_SetExpectedNumberOfProperties) { 2243 RUNTIME_FUNCTION(MaybeObject*, Runtime_SetExpectedNumberOfProperties) {
2244 HandleScope scope(isolate); 2244 HandleScope scope(isolate);
(...skipping 10741 matching lines...) Expand 10 before | Expand all | Expand 10 after
12986 // Handle last resort GC and make sure to allow future allocations 12986 // Handle last resort GC and make sure to allow future allocations
12987 // to grow the heap without causing GCs (if possible). 12987 // to grow the heap without causing GCs (if possible).
12988 isolate->counters()->gc_last_resort_from_js()->Increment(); 12988 isolate->counters()->gc_last_resort_from_js()->Increment();
12989 isolate->heap()->CollectAllGarbage(Heap::kNoGCFlags, 12989 isolate->heap()->CollectAllGarbage(Heap::kNoGCFlags,
12990 "Runtime::PerformGC"); 12990 "Runtime::PerformGC");
12991 } 12991 }
12992 } 12992 }
12993 12993
12994 12994
12995 } } // namespace v8::internal 12995 } } // namespace v8::internal
OLDNEW
« no previous file with comments | « src/profile-generator-inl.h ('k') | test/cctest/test-cpu-profiler.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698