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 1888 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1899 | 1899 |
1900 | 1900 |
1901 LInstruction* LChunkBuilder::DoSeqStringGetChar(HSeqStringGetChar* instr) { | 1901 LInstruction* LChunkBuilder::DoSeqStringGetChar(HSeqStringGetChar* instr) { |
1902 LOperand* string = UseRegisterAtStart(instr->string()); | 1902 LOperand* string = UseRegisterAtStart(instr->string()); |
1903 LOperand* index = UseRegisterOrConstantAtStart(instr->index()); | 1903 LOperand* index = UseRegisterOrConstantAtStart(instr->index()); |
1904 return DefineAsRegister(new(zone()) LSeqStringGetChar(string, index)); | 1904 return DefineAsRegister(new(zone()) LSeqStringGetChar(string, index)); |
1905 } | 1905 } |
1906 | 1906 |
1907 | 1907 |
1908 LInstruction* LChunkBuilder::DoSeqStringSetChar(HSeqStringSetChar* instr) { | 1908 LInstruction* LChunkBuilder::DoSeqStringSetChar(HSeqStringSetChar* instr) { |
1909 LOperand* string = UseRegister(instr->string()); | 1909 LOperand* string = UseRegisterAtStart(instr->string()); |
1910 LOperand* index = UseRegisterOrConstant(instr->index()); | 1910 LOperand* index = FLAG_debug_code |
1911 LOperand* value = UseRegister(instr->value()); | 1911 ? UseRegisterAtStart(instr->index()) |
1912 return new(zone()) LSeqStringSetChar(string, index, value); | 1912 : UseRegisterOrConstantAtStart(instr->index()); |
| 1913 LOperand* value = UseRegisterAtStart(instr->value()); |
| 1914 LOperand* context = FLAG_debug_code ? UseFixed(instr->context(), cp) : NULL; |
| 1915 return new(zone()) LSeqStringSetChar(context, string, index, value); |
1913 } | 1916 } |
1914 | 1917 |
1915 | 1918 |
1916 LInstruction* LChunkBuilder::DoBoundsCheck(HBoundsCheck* instr) { | 1919 LInstruction* LChunkBuilder::DoBoundsCheck(HBoundsCheck* instr) { |
1917 LOperand* value = UseRegisterOrConstantAtStart(instr->index()); | 1920 LOperand* value = UseRegisterOrConstantAtStart(instr->index()); |
1918 LOperand* length = UseRegister(instr->length()); | 1921 LOperand* length = UseRegister(instr->length()); |
1919 return AssignEnvironment(new(zone()) LBoundsCheck(value, length)); | 1922 return AssignEnvironment(new(zone()) LBoundsCheck(value, length)); |
1920 } | 1923 } |
1921 | 1924 |
1922 | 1925 |
(...skipping 764 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2687 | 2690 |
2688 | 2691 |
2689 LInstruction* LChunkBuilder::DoLoadFieldByIndex(HLoadFieldByIndex* instr) { | 2692 LInstruction* LChunkBuilder::DoLoadFieldByIndex(HLoadFieldByIndex* instr) { |
2690 LOperand* object = UseRegister(instr->object()); | 2693 LOperand* object = UseRegister(instr->object()); |
2691 LOperand* index = UseRegister(instr->index()); | 2694 LOperand* index = UseRegister(instr->index()); |
2692 return DefineAsRegister(new(zone()) LLoadFieldByIndex(object, index)); | 2695 return DefineAsRegister(new(zone()) LLoadFieldByIndex(object, index)); |
2693 } | 2696 } |
2694 | 2697 |
2695 | 2698 |
2696 } } // namespace v8::internal | 2699 } } // namespace v8::internal |
OLD | NEW |