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

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

Issue 12784003: MIPS: HInnerAllocatedObject instruction allows hydrogen code to carve up allocated regions into sub… (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/mips/lithium-mips.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 272 matching lines...) Expand 10 before | Expand all | Expand 10 after
283 283
284 void LTypeofIsAndBranch::PrintDataTo(StringStream* stream) { 284 void LTypeofIsAndBranch::PrintDataTo(StringStream* stream) {
285 stream->Add("if typeof "); 285 stream->Add("if typeof ");
286 value()->PrintTo(stream); 286 value()->PrintTo(stream);
287 stream->Add(" == \"%s\" then B%d else B%d", 287 stream->Add(" == \"%s\" then B%d else B%d",
288 *hydrogen()->type_literal()->ToCString(), 288 *hydrogen()->type_literal()->ToCString(),
289 true_block_id(), false_block_id()); 289 true_block_id(), false_block_id());
290 } 290 }
291 291
292 292
293 void LInnerAllocatedObject::PrintDataTo(StringStream* stream) {
294 stream->Add(" = ");
295 base_object()->PrintTo(stream);
296 stream->Add(" + %d", offset());
297 }
298
299
293 void LCallConstantFunction::PrintDataTo(StringStream* stream) { 300 void LCallConstantFunction::PrintDataTo(StringStream* stream) {
294 stream->Add("#%d / ", arity()); 301 stream->Add("#%d / ", arity());
295 } 302 }
296 303
297 304
298 void LUnaryMathOperation::PrintDataTo(StringStream* stream) { 305 void LUnaryMathOperation::PrintDataTo(StringStream* stream) {
299 stream->Add("/%s ", hydrogen()->OpName()); 306 stream->Add("/%s ", hydrogen()->OpName());
300 value()->PrintTo(stream); 307 value()->PrintTo(stream);
301 } 308 }
302 309
(...skipping 706 matching lines...) Expand 10 before | Expand all | Expand 10 after
1009 } 1016 }
1010 1017
1011 1018
1012 LInstruction* LChunkBuilder::DoPushArgument(HPushArgument* instr) { 1019 LInstruction* LChunkBuilder::DoPushArgument(HPushArgument* instr) {
1013 ++argument_count_; 1020 ++argument_count_;
1014 LOperand* argument = Use(instr->argument()); 1021 LOperand* argument = Use(instr->argument());
1015 return new(zone()) LPushArgument(argument); 1022 return new(zone()) LPushArgument(argument);
1016 } 1023 }
1017 1024
1018 1025
1026 LInstruction* LChunkBuilder::DoInnerAllocatedObject(
1027 HInnerAllocatedObject* inner_object) {
1028 LOperand* base_object = UseRegisterAtStart(inner_object->base_object());
1029 LInnerAllocatedObject* result =
1030 new(zone()) LInnerAllocatedObject(base_object);
1031 return DefineAsRegister(result);
1032 }
1033
1034
1019 LInstruction* LChunkBuilder::DoThisFunction(HThisFunction* instr) { 1035 LInstruction* LChunkBuilder::DoThisFunction(HThisFunction* instr) {
1020 return instr->HasNoUses() 1036 return instr->HasNoUses()
1021 ? NULL 1037 ? NULL
1022 : DefineAsRegister(new(zone()) LThisFunction); 1038 : DefineAsRegister(new(zone()) LThisFunction);
1023 } 1039 }
1024 1040
1025 1041
1026 LInstruction* LChunkBuilder::DoContext(HContext* instr) { 1042 LInstruction* LChunkBuilder::DoContext(HContext* instr) {
1027 // If there is a non-return use, the context must be allocated in a register. 1043 // If there is a non-return use, the context must be allocated in a register.
1028 for (HUseIterator it(instr->uses()); !it.Done(); it.Advance()) { 1044 for (HUseIterator it(instr->uses()); !it.Done(); it.Advance()) {
(...skipping 1360 matching lines...) Expand 10 before | Expand all | Expand 10 after
2389 2405
2390 2406
2391 LInstruction* LChunkBuilder::DoLoadFieldByIndex(HLoadFieldByIndex* instr) { 2407 LInstruction* LChunkBuilder::DoLoadFieldByIndex(HLoadFieldByIndex* instr) {
2392 LOperand* object = UseRegister(instr->object()); 2408 LOperand* object = UseRegister(instr->object());
2393 LOperand* index = UseRegister(instr->index()); 2409 LOperand* index = UseRegister(instr->index());
2394 return DefineAsRegister(new(zone()) LLoadFieldByIndex(object, index)); 2410 return DefineAsRegister(new(zone()) LLoadFieldByIndex(object, index));
2395 } 2411 }
2396 2412
2397 2413
2398 } } // namespace v8::internal 2414 } } // namespace v8::internal
OLDNEW
« no previous file with comments | « src/mips/lithium-mips.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698