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 1945 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1956 } | 1956 } |
1957 } | 1957 } |
1958 } | 1958 } |
1959 UNREACHABLE(); | 1959 UNREACHABLE(); |
1960 return NULL; | 1960 return NULL; |
1961 } | 1961 } |
1962 | 1962 |
1963 | 1963 |
1964 LInstruction* LChunkBuilder::DoCheckHeapObject(HCheckHeapObject* instr) { | 1964 LInstruction* LChunkBuilder::DoCheckHeapObject(HCheckHeapObject* instr) { |
1965 LOperand* value = UseRegisterAtStart(instr->value()); | 1965 LOperand* value = UseRegisterAtStart(instr->value()); |
1966 LInstruction* result = new(zone()) LCheckNonSmi(value); | 1966 return AssignEnvironment(new(zone()) LCheckNonSmi(value)); |
1967 if (!instr->value()->IsHeapObject()) result = AssignEnvironment(result); | |
1968 return result; | |
1969 } | 1967 } |
1970 | 1968 |
1971 | 1969 |
1972 LInstruction* LChunkBuilder::DoCheckSmi(HCheckSmi* instr) { | 1970 LInstruction* LChunkBuilder::DoCheckSmi(HCheckSmi* instr) { |
1973 LOperand* value = UseRegisterAtStart(instr->value()); | 1971 LOperand* value = UseRegisterAtStart(instr->value()); |
1974 return AssignEnvironment(new(zone()) LCheckSmi(value)); | 1972 return AssignEnvironment(new(zone()) LCheckSmi(value)); |
1975 } | 1973 } |
1976 | 1974 |
1977 | 1975 |
1978 LInstruction* LChunkBuilder::DoCheckInstanceType(HCheckInstanceType* instr) { | 1976 LInstruction* LChunkBuilder::DoCheckInstanceType(HCheckInstanceType* instr) { |
(...skipping 592 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2571 | 2569 |
2572 LInstruction* LChunkBuilder::DoLoadFieldByIndex(HLoadFieldByIndex* instr) { | 2570 LInstruction* LChunkBuilder::DoLoadFieldByIndex(HLoadFieldByIndex* instr) { |
2573 LOperand* object = UseRegister(instr->object()); | 2571 LOperand* object = UseRegister(instr->object()); |
2574 LOperand* index = UseRegister(instr->index()); | 2572 LOperand* index = UseRegister(instr->index()); |
2575 LLoadFieldByIndex* load = new(zone()) LLoadFieldByIndex(object, index); | 2573 LLoadFieldByIndex* load = new(zone()) LLoadFieldByIndex(object, index); |
2576 LInstruction* result = DefineSameAsFirst(load); | 2574 LInstruction* result = DefineSameAsFirst(load); |
2577 return AssignPointerMap(result); | 2575 return AssignPointerMap(result); |
2578 } | 2576 } |
2579 | 2577 |
2580 } } // namespace v8::internal | 2578 } } // namespace v8::internal |
OLD | NEW |