OLD | NEW |
1 // Copyright 2011 the V8 project authors. All rights reserved. | 1 // Copyright 2011 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 1765 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1776 LCheckMap* result = new LCheckMap(value); | 1776 LCheckMap* result = new LCheckMap(value); |
1777 return AssignEnvironment(result); | 1777 return AssignEnvironment(result); |
1778 } | 1778 } |
1779 | 1779 |
1780 | 1780 |
1781 LInstruction* LChunkBuilder::DoClampToUint8(HClampToUint8* instr) { | 1781 LInstruction* LChunkBuilder::DoClampToUint8(HClampToUint8* instr) { |
1782 HValue* value = instr->value(); | 1782 HValue* value = instr->value(); |
1783 Representation input_rep = value->representation(); | 1783 Representation input_rep = value->representation(); |
1784 if (input_rep.IsDouble()) { | 1784 if (input_rep.IsDouble()) { |
1785 LOperand* reg = UseRegister(value); | 1785 LOperand* reg = UseRegister(value); |
1786 return DefineAsRegister(new LClampDoubleToUint8(reg)); | 1786 return DefineAsRegister(new LClampDToUint8(reg)); |
1787 } else if (input_rep.IsInteger32()) { | 1787 } else if (input_rep.IsInteger32()) { |
1788 LOperand* reg = UseFixed(value, eax); | 1788 LOperand* reg = UseFixed(value, eax); |
1789 return DefineFixed(new LClampIToUint8(reg), eax); | 1789 return DefineFixed(new LClampIToUint8(reg), eax); |
1790 } else { | 1790 } else { |
1791 ASSERT(input_rep.IsTagged()); | 1791 ASSERT(input_rep.IsTagged()); |
1792 LOperand* reg = UseFixed(value, eax); | 1792 LOperand* reg = UseFixed(value, eax); |
1793 // Register allocator doesn't (yet) support allocation of double | 1793 // Register allocator doesn't (yet) support allocation of double |
1794 // temps. Reserve xmm1 explicitly. | 1794 // temps. Reserve xmm1 explicitly. |
1795 LOperand* temp = FixedTemp(xmm1); | 1795 LOperand* temp = FixedTemp(xmm1); |
1796 LClampTaggedToUint8* result = new LClampTaggedToUint8(reg, temp); | 1796 LClampTToUint8* result = new LClampTToUint8(reg, temp); |
1797 return AssignEnvironment(DefineFixed(result, eax)); | 1797 return AssignEnvironment(DefineFixed(result, eax)); |
1798 } | 1798 } |
1799 } | 1799 } |
1800 | 1800 |
1801 | 1801 |
1802 LInstruction* LChunkBuilder::DoReturn(HReturn* instr) { | 1802 LInstruction* LChunkBuilder::DoReturn(HReturn* instr) { |
1803 return new LReturn(UseFixed(instr->value(), eax)); | 1803 return new LReturn(UseFixed(instr->value(), eax)); |
1804 } | 1804 } |
1805 | 1805 |
1806 | 1806 |
(...skipping 451 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2258 LOperand* key = UseOrConstantAtStart(instr->key()); | 2258 LOperand* key = UseOrConstantAtStart(instr->key()); |
2259 LOperand* object = UseOrConstantAtStart(instr->object()); | 2259 LOperand* object = UseOrConstantAtStart(instr->object()); |
2260 LIn* result = new LIn(key, object); | 2260 LIn* result = new LIn(key, object); |
2261 return MarkAsCall(DefineFixed(result, eax), instr); | 2261 return MarkAsCall(DefineFixed(result, eax), instr); |
2262 } | 2262 } |
2263 | 2263 |
2264 | 2264 |
2265 } } // namespace v8::internal | 2265 } } // namespace v8::internal |
2266 | 2266 |
2267 #endif // V8_TARGET_ARCH_IA32 | 2267 #endif // V8_TARGET_ARCH_IA32 |
OLD | NEW |