OLD | NEW |
1 // Copyright 2012 the V8 project authors. All rights reserved.7 | 1 // Copyright 2012 the V8 project authors. All rights reserved.7 |
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 1633 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1644 } | 1644 } |
1645 | 1645 |
1646 | 1646 |
1647 void LCodeGen::DoConstantT(LConstantT* instr) { | 1647 void LCodeGen::DoConstantT(LConstantT* instr) { |
1648 Handle<Object> object = instr->value(isolate()); | 1648 Handle<Object> object = instr->value(isolate()); |
1649 AllowDeferredHandleDereference smi_check; | 1649 AllowDeferredHandleDereference smi_check; |
1650 __ li(ToRegister(instr->result()), object); | 1650 __ li(ToRegister(instr->result()), object); |
1651 } | 1651 } |
1652 | 1652 |
1653 | 1653 |
1654 void LCodeGen::DoMapEnumLength(LMapEnumLength* instr) { | |
1655 Register result = ToRegister(instr->result()); | |
1656 Register map = ToRegister(instr->value()); | |
1657 __ EnumLength(result, map); | |
1658 } | |
1659 | |
1660 | |
1661 MemOperand LCodeGen::BuildSeqStringOperand(Register string, | 1654 MemOperand LCodeGen::BuildSeqStringOperand(Register string, |
1662 LOperand* index, | 1655 LOperand* index, |
1663 String::Encoding encoding) { | 1656 String::Encoding encoding) { |
1664 if (index->IsConstantOperand()) { | 1657 if (index->IsConstantOperand()) { |
1665 int offset = ToInteger32(LConstantOperand::cast(index)); | 1658 int offset = ToInteger32(LConstantOperand::cast(index)); |
1666 if (encoding == String::TWO_BYTE_ENCODING) { | 1659 if (encoding == String::TWO_BYTE_ENCODING) { |
1667 offset *= kUC16Size; | 1660 offset *= kUC16Size; |
1668 } | 1661 } |
1669 STATIC_ASSERT(kCharSize == 1); | 1662 STATIC_ASSERT(kCharSize == 1); |
1670 return FieldMemOperand(string, SeqString::kHeaderSize + offset); | 1663 return FieldMemOperand(string, SeqString::kHeaderSize + offset); |
(...skipping 3931 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
5602 __ Push(at, ToRegister(instr->function())); | 5595 __ Push(at, ToRegister(instr->function())); |
5603 CallRuntime(Runtime::kPushBlockContext, instr); | 5596 CallRuntime(Runtime::kPushBlockContext, instr); |
5604 RecordSafepoint(Safepoint::kNoLazyDeopt); | 5597 RecordSafepoint(Safepoint::kNoLazyDeopt); |
5605 } | 5598 } |
5606 | 5599 |
5607 | 5600 |
5608 #undef __ | 5601 #undef __ |
5609 | 5602 |
5610 } // namespace internal | 5603 } // namespace internal |
5611 } // namespace v8 | 5604 } // namespace v8 |
OLD | NEW |