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

Side by Side Diff: src/x64/full-codegen-x64.cc

Issue 11412007: Removed a bunch of GetExistingThreadLocal calls by threading the Isolate. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Addressed feedback Created 8 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 | « src/variables.h ('k') | 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 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 101 matching lines...) Expand 10 before | Expand all | Expand 10 after
112 // o rbp: our caller's frame pointer 112 // o rbp: our caller's frame pointer
113 // o rsp: stack pointer (pointing to return address) 113 // o rsp: stack pointer (pointing to return address)
114 // 114 //
115 // The function builds a JS frame. Please see JavaScriptFrameConstants in 115 // The function builds a JS frame. Please see JavaScriptFrameConstants in
116 // frames-x64.h for its layout. 116 // frames-x64.h for its layout.
117 void FullCodeGenerator::Generate() { 117 void FullCodeGenerator::Generate() {
118 CompilationInfo* info = info_; 118 CompilationInfo* info = info_;
119 handler_table_ = 119 handler_table_ =
120 isolate()->factory()->NewFixedArray(function()->handler_count(), TENURED); 120 isolate()->factory()->NewFixedArray(function()->handler_count(), TENURED);
121 profiling_counter_ = isolate()->factory()->NewJSGlobalPropertyCell( 121 profiling_counter_ = isolate()->factory()->NewJSGlobalPropertyCell(
122 Handle<Smi>(Smi::FromInt(FLAG_interrupt_budget))); 122 Handle<Smi>(Smi::FromInt(FLAG_interrupt_budget), isolate()));
123 SetFunctionPosition(function()); 123 SetFunctionPosition(function());
124 Comment cmnt(masm_, "[ function compiled by full code generator"); 124 Comment cmnt(masm_, "[ function compiled by full code generator");
125 125
126 ProfileEntryHookStub::MaybeCallEntryHook(masm_); 126 ProfileEntryHookStub::MaybeCallEntryHook(masm_);
127 127
128 #ifdef DEBUG 128 #ifdef DEBUG
129 if (strlen(FLAG_stop_at) > 0 && 129 if (strlen(FLAG_stop_at) > 0 &&
130 info->function()->name()->IsEqualTo(CStrVector(FLAG_stop_at))) { 130 info->function()->name()->IsEqualTo(CStrVector(FLAG_stop_at))) {
131 __ int3(); 131 __ int3();
132 } 132 }
(...skipping 2164 matching lines...) Expand 10 before | Expand all | Expand 10 after
2297 // We want to verify that RecordJSReturnSite gets called on all paths 2297 // We want to verify that RecordJSReturnSite gets called on all paths
2298 // through this function. Avoid early returns. 2298 // through this function. Avoid early returns.
2299 expr->return_is_recorded_ = false; 2299 expr->return_is_recorded_ = false;
2300 #endif 2300 #endif
2301 2301
2302 Comment cmnt(masm_, "[ Call"); 2302 Comment cmnt(masm_, "[ Call");
2303 Expression* callee = expr->expression(); 2303 Expression* callee = expr->expression();
2304 VariableProxy* proxy = callee->AsVariableProxy(); 2304 VariableProxy* proxy = callee->AsVariableProxy();
2305 Property* property = callee->AsProperty(); 2305 Property* property = callee->AsProperty();
2306 2306
2307 if (proxy != NULL && proxy->var()->is_possibly_eval()) { 2307 if (proxy != NULL && proxy->var()->is_possibly_eval(isolate())) {
2308 // In a call to eval, we first call %ResolvePossiblyDirectEval to 2308 // In a call to eval, we first call %ResolvePossiblyDirectEval to
2309 // resolve the function we need to call and the receiver of the call. 2309 // resolve the function we need to call and the receiver of the call.
2310 // Then we call the resolved function using the given arguments. 2310 // Then we call the resolved function using the given arguments.
2311 ZoneList<Expression*>* args = expr->arguments(); 2311 ZoneList<Expression*>* args = expr->arguments();
2312 int arg_count = args->length(); 2312 int arg_count = args->length();
2313 { PreservePositionScope pos_scope(masm()->positions_recorder()); 2313 { PreservePositionScope pos_scope(masm()->positions_recorder());
2314 VisitForStackValue(callee); 2314 VisitForStackValue(callee);
2315 __ PushRoot(Heap::kUndefinedValueRootIndex); // Reserved receiver slot. 2315 __ PushRoot(Heap::kUndefinedValueRootIndex); // Reserved receiver slot.
2316 2316
2317 // Push the arguments. 2317 // Push the arguments.
(...skipping 2174 matching lines...) Expand 10 before | Expand all | Expand 10 after
4492 *context_length = 0; 4492 *context_length = 0;
4493 return previous_; 4493 return previous_;
4494 } 4494 }
4495 4495
4496 4496
4497 #undef __ 4497 #undef __
4498 4498
4499 } } // namespace v8::internal 4499 } } // namespace v8::internal
4500 4500
4501 #endif // V8_TARGET_ARCH_X64 4501 #endif // V8_TARGET_ARCH_X64
OLDNEW
« no previous file with comments | « src/variables.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698