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

Side by Side Diff: src/x64/lithium-x64.cc

Issue 9838059: Rollback of r11118, r11109 in trunk branch. (Closed) Base URL: https://v8.googlecode.com/svn/trunk
Patch Set: Created 8 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/x64/lithium-x64.h ('k') | test/mjsunit/compiler/inline-arguments.js » ('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 1053 matching lines...) Expand 10 before | Expand all | Expand 10 after
1064 return new(zone()) LCmpMapAndBranch(value); 1064 return new(zone()) LCmpMapAndBranch(value);
1065 } 1065 }
1066 1066
1067 1067
1068 LInstruction* LChunkBuilder::DoArgumentsLength(HArgumentsLength* length) { 1068 LInstruction* LChunkBuilder::DoArgumentsLength(HArgumentsLength* length) {
1069 return DefineAsRegister(new(zone()) LArgumentsLength(Use(length->value()))); 1069 return DefineAsRegister(new(zone()) LArgumentsLength(Use(length->value())));
1070 } 1070 }
1071 1071
1072 1072
1073 LInstruction* LChunkBuilder::DoArgumentsElements(HArgumentsElements* elems) { 1073 LInstruction* LChunkBuilder::DoArgumentsElements(HArgumentsElements* elems) {
1074 return DefineAsRegister(new(zone()) LArgumentsElements( 1074 return DefineAsRegister(new(zone()) LArgumentsElements);
1075 current_block_->last_environment()->outer() != NULL));
1076 } 1075 }
1077 1076
1078 1077
1079 LInstruction* LChunkBuilder::DoInstanceOf(HInstanceOf* instr) { 1078 LInstruction* LChunkBuilder::DoInstanceOf(HInstanceOf* instr) {
1080 LOperand* left = UseFixed(instr->left(), rax); 1079 LOperand* left = UseFixed(instr->left(), rax);
1081 LOperand* right = UseFixed(instr->right(), rdx); 1080 LOperand* right = UseFixed(instr->right(), rdx);
1082 LInstanceOf* result = new(zone()) LInstanceOf(left, right); 1081 LInstanceOf* result = new(zone()) LInstanceOf(left, right);
1083 return MarkAsCall(DefineFixed(result, rax), instr); 1082 return MarkAsCall(DefineFixed(result, rax), instr);
1084 } 1083 }
1085 1084
(...skipping 1178 matching lines...) Expand 10 before | Expand all | Expand 10 after
2264 2263
2265 LInstruction* LChunkBuilder::DoEnterInlined(HEnterInlined* instr) { 2264 LInstruction* LChunkBuilder::DoEnterInlined(HEnterInlined* instr) {
2266 HEnvironment* outer = current_block_->last_environment(); 2265 HEnvironment* outer = current_block_->last_environment();
2267 HConstant* undefined = graph()->GetConstantUndefined(); 2266 HConstant* undefined = graph()->GetConstantUndefined();
2268 HEnvironment* inner = outer->CopyForInlining(instr->closure(), 2267 HEnvironment* inner = outer->CopyForInlining(instr->closure(),
2269 instr->arguments_count(), 2268 instr->arguments_count(),
2270 instr->function(), 2269 instr->function(),
2271 undefined, 2270 undefined,
2272 instr->call_kind(), 2271 instr->call_kind(),
2273 instr->is_construct()); 2272 instr->is_construct());
2274 if (instr->materializes_arguments()) {
2275 inner->Bind(instr->arguments(), graph()->GetArgumentsObject());
2276 }
2277 current_block_->UpdateEnvironment(inner); 2273 current_block_->UpdateEnvironment(inner);
2278 chunk_->AddInlinedClosure(instr->closure()); 2274 chunk_->AddInlinedClosure(instr->closure());
2279 return NULL; 2275 return NULL;
2280 } 2276 }
2281 2277
2282 2278
2283 LInstruction* LChunkBuilder::DoLeaveInlined(HLeaveInlined* instr) { 2279 LInstruction* LChunkBuilder::DoLeaveInlined(HLeaveInlined* instr) {
2284 LInstruction* pop = NULL;
2285
2286 HEnvironment* env = current_block_->last_environment();
2287
2288 if (instr->arguments_pushed()) {
2289 int argument_count = env->arguments_environment()->parameter_count();
2290 pop = new(zone()) LPop(argument_count);
2291 argument_count_ -= argument_count;
2292 }
2293
2294 HEnvironment* outer = current_block_->last_environment()-> 2280 HEnvironment* outer = current_block_->last_environment()->
2295 DiscardInlined(false); 2281 DiscardInlined(false);
2296 current_block_->UpdateEnvironment(outer); 2282 current_block_->UpdateEnvironment(outer);
2297 2283 return NULL;
2298 return pop;
2299 } 2284 }
2300 2285
2301 2286
2302 LInstruction* LChunkBuilder::DoIn(HIn* instr) { 2287 LInstruction* LChunkBuilder::DoIn(HIn* instr) {
2303 LOperand* key = UseOrConstantAtStart(instr->key()); 2288 LOperand* key = UseOrConstantAtStart(instr->key());
2304 LOperand* object = UseOrConstantAtStart(instr->object()); 2289 LOperand* object = UseOrConstantAtStart(instr->object());
2305 LIn* result = new(zone()) LIn(key, object); 2290 LIn* result = new(zone()) LIn(key, object);
2306 return MarkAsCall(DefineFixed(result, rax), instr); 2291 return MarkAsCall(DefineFixed(result, rax), instr);
2307 } 2292 }
2308 2293
(...skipping 22 matching lines...) Expand all
2331 LInstruction* LChunkBuilder::DoLoadFieldByIndex(HLoadFieldByIndex* instr) { 2316 LInstruction* LChunkBuilder::DoLoadFieldByIndex(HLoadFieldByIndex* instr) {
2332 LOperand* object = UseRegister(instr->object()); 2317 LOperand* object = UseRegister(instr->object());
2333 LOperand* index = UseTempRegister(instr->index()); 2318 LOperand* index = UseTempRegister(instr->index());
2334 return DefineSameAsFirst(new(zone()) LLoadFieldByIndex(object, index)); 2319 return DefineSameAsFirst(new(zone()) LLoadFieldByIndex(object, index));
2335 } 2320 }
2336 2321
2337 2322
2338 } } // namespace v8::internal 2323 } } // namespace v8::internal
2339 2324
2340 #endif // V8_TARGET_ARCH_X64 2325 #endif // V8_TARGET_ARCH_X64
OLDNEW
« no previous file with comments | « src/x64/lithium-x64.h ('k') | test/mjsunit/compiler/inline-arguments.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698