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

Side by Side Diff: src/ia32/full-codegen-ia32.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/hydrogen.cc ('k') | src/ic.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 101 matching lines...) Expand 10 before | Expand all | Expand 10 after
112 // o ebp: our caller's frame pointer 112 // o ebp: our caller's frame pointer
113 // o esp: stack pointer (pointing to return address) 113 // o esp: 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-ia32.h for its layout. 116 // frames-ia32.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 2189 matching lines...) Expand 10 before | Expand all | Expand 10 after
2322 // We want to verify that RecordJSReturnSite gets called on all paths 2322 // We want to verify that RecordJSReturnSite gets called on all paths
2323 // through this function. Avoid early returns. 2323 // through this function. Avoid early returns.
2324 expr->return_is_recorded_ = false; 2324 expr->return_is_recorded_ = false;
2325 #endif 2325 #endif
2326 2326
2327 Comment cmnt(masm_, "[ Call"); 2327 Comment cmnt(masm_, "[ Call");
2328 Expression* callee = expr->expression(); 2328 Expression* callee = expr->expression();
2329 VariableProxy* proxy = callee->AsVariableProxy(); 2329 VariableProxy* proxy = callee->AsVariableProxy();
2330 Property* property = callee->AsProperty(); 2330 Property* property = callee->AsProperty();
2331 2331
2332 if (proxy != NULL && proxy->var()->is_possibly_eval()) { 2332 if (proxy != NULL && proxy->var()->is_possibly_eval(isolate())) {
2333 // In a call to eval, we first call %ResolvePossiblyDirectEval to 2333 // In a call to eval, we first call %ResolvePossiblyDirectEval to
2334 // resolve the function we need to call and the receiver of the call. 2334 // resolve the function we need to call and the receiver of the call.
2335 // Then we call the resolved function using the given arguments. 2335 // Then we call the resolved function using the given arguments.
2336 ZoneList<Expression*>* args = expr->arguments(); 2336 ZoneList<Expression*>* args = expr->arguments();
2337 int arg_count = args->length(); 2337 int arg_count = args->length();
2338 { PreservePositionScope pos_scope(masm()->positions_recorder()); 2338 { PreservePositionScope pos_scope(masm()->positions_recorder());
2339 VisitForStackValue(callee); 2339 VisitForStackValue(callee);
2340 // Reserved receiver slot. 2340 // Reserved receiver slot.
2341 __ push(Immediate(isolate()->factory()->undefined_value())); 2341 __ push(Immediate(isolate()->factory()->undefined_value()));
2342 // Push the arguments. 2342 // Push the arguments.
(...skipping 2155 matching lines...) Expand 10 before | Expand all | Expand 10 after
4498 *stack_depth = 0; 4498 *stack_depth = 0;
4499 *context_length = 0; 4499 *context_length = 0;
4500 return previous_; 4500 return previous_;
4501 } 4501 }
4502 4502
4503 #undef __ 4503 #undef __
4504 4504
4505 } } // namespace v8::internal 4505 } } // namespace v8::internal
4506 4506
4507 #endif // V8_TARGET_ARCH_IA32 4507 #endif // V8_TARGET_ARCH_IA32
OLDNEW
« no previous file with comments | « src/hydrogen.cc ('k') | src/ic.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698