OLD | NEW |
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 Loading... |
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 Loading... |
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 |
OLD | NEW |