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

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

Issue 150663005: Optimize redundant HCompareMap instructions with known successors. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 6 years, 10 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/ia32/lithium-ia32.cc ('k') | src/x64/lithium-x64.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 927 matching lines...) Expand 10 before | Expand all | Expand 10 after
938 ToBooleanStub::Types expected = instr->expected_input_types(); 938 ToBooleanStub::Types expected = instr->expected_input_types();
939 if (rep.IsTagged() && !type.IsSmi() && !type.IsBoolean() && 939 if (rep.IsTagged() && !type.IsSmi() && !type.IsBoolean() &&
940 !expected.IsGeneric()) { 940 !expected.IsGeneric()) {
941 return AssignEnvironment(result); 941 return AssignEnvironment(result);
942 } 942 }
943 return result; 943 return result;
944 } 944 }
945 945
946 946
947 LInstruction* LChunkBuilder::DoCompareMap(HCompareMap* instr) { 947 LInstruction* LChunkBuilder::DoCompareMap(HCompareMap* instr) {
948 LInstruction* goto_instr = CheckElideControlInstruction(instr);
949 if (goto_instr != NULL) return goto_instr;
950
948 ASSERT(instr->value()->representation().IsTagged()); 951 ASSERT(instr->value()->representation().IsTagged());
949 LOperand* value = UseRegisterAtStart(instr->value()); 952 LOperand* value = UseRegisterAtStart(instr->value());
950 LOperand* temp = TempRegister(); 953 LOperand* temp = TempRegister();
951 return new(zone()) LCmpMapAndBranch(value, temp); 954 return new(zone()) LCmpMapAndBranch(value, temp);
952 } 955 }
953 956
954 957
955 LInstruction* LChunkBuilder::DoArgumentsLength(HArgumentsLength* length) { 958 LInstruction* LChunkBuilder::DoArgumentsLength(HArgumentsLength* length) {
956 info()->MarkAsRequiresFrame(); 959 info()->MarkAsRequiresFrame();
957 return DefineAsRegister( 960 return DefineAsRegister(
(...skipping 1438 matching lines...) Expand 10 before | Expand all | Expand 10 after
2396 2399
2397 2400
2398 LInstruction* LChunkBuilder::DoLoadFieldByIndex(HLoadFieldByIndex* instr) { 2401 LInstruction* LChunkBuilder::DoLoadFieldByIndex(HLoadFieldByIndex* instr) {
2399 LOperand* object = UseRegister(instr->object()); 2402 LOperand* object = UseRegister(instr->object());
2400 LOperand* index = UseRegister(instr->index()); 2403 LOperand* index = UseRegister(instr->index());
2401 return DefineAsRegister(new(zone()) LLoadFieldByIndex(object, index)); 2404 return DefineAsRegister(new(zone()) LLoadFieldByIndex(object, index));
2402 } 2405 }
2403 2406
2404 2407
2405 } } // namespace v8::internal 2408 } } // namespace v8::internal
OLDNEW
« no previous file with comments | « src/ia32/lithium-ia32.cc ('k') | src/x64/lithium-x64.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698