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

Side by Side Diff: src/runtime.cc

Issue 10033028: Reland arguments access support for inlined functions (r11109,r11118). (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: fix Kevin's comments Created 8 years, 8 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
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 8108 matching lines...) Expand 10 before | Expand all | Expand 10 after
8119 if (arguments.is_null()) { 8119 if (arguments.is_null()) {
8120 // FunctionGetArguments can't throw an exception, so cast away the 8120 // FunctionGetArguments can't throw an exception, so cast away the
8121 // doubt with an assert. 8121 // doubt with an assert.
8122 arguments = Handle<Object>( 8122 arguments = Handle<Object>(
8123 Accessors::FunctionGetArguments(*function, 8123 Accessors::FunctionGetArguments(*function,
8124 NULL)->ToObjectUnchecked()); 8124 NULL)->ToObjectUnchecked());
8125 ASSERT(*arguments != isolate->heap()->null_value()); 8125 ASSERT(*arguments != isolate->heap()->null_value());
8126 ASSERT(*arguments != isolate->heap()->undefined_value()); 8126 ASSERT(*arguments != isolate->heap()->undefined_value());
8127 } 8127 }
8128 frame->SetExpression(i, *arguments); 8128 frame->SetExpression(i, *arguments);
8129 if (FLAG_trace_deopt) {
8130 PrintF("Materializing arguments object for frame %p - %p: %p ",
8131 reinterpret_cast<void*>(frame->sp()),
8132 reinterpret_cast<void*>(frame->fp()),
8133 reinterpret_cast<void*>(*arguments));
8134 arguments->ShortPrint();
8135 PrintF("\n");
8136 }
8129 } 8137 }
8130 } 8138 }
8131 } 8139 }
8132 8140
8133 8141
8134 RUNTIME_FUNCTION(MaybeObject*, Runtime_NotifyDeoptimized) { 8142 RUNTIME_FUNCTION(MaybeObject*, Runtime_NotifyDeoptimized) {
8135 HandleScope scope(isolate); 8143 HandleScope scope(isolate);
8136 ASSERT(args.length() == 1); 8144 ASSERT(args.length() == 1);
8137 RUNTIME_ASSERT(args[0]->IsSmi()); 8145 RUNTIME_ASSERT(args[0]->IsSmi());
8138 Deoptimizer::BailoutType type = 8146 Deoptimizer::BailoutType type =
(...skipping 5207 matching lines...) Expand 10 before | Expand all | Expand 10 after
13346 // Handle last resort GC and make sure to allow future allocations 13354 // Handle last resort GC and make sure to allow future allocations
13347 // to grow the heap without causing GCs (if possible). 13355 // to grow the heap without causing GCs (if possible).
13348 isolate->counters()->gc_last_resort_from_js()->Increment(); 13356 isolate->counters()->gc_last_resort_from_js()->Increment();
13349 isolate->heap()->CollectAllGarbage(Heap::kNoGCFlags, 13357 isolate->heap()->CollectAllGarbage(Heap::kNoGCFlags,
13350 "Runtime::PerformGC"); 13358 "Runtime::PerformGC");
13351 } 13359 }
13352 } 13360 }
13353 13361
13354 13362
13355 } } // namespace v8::internal 13363 } } // namespace v8::internal
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698