| 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 4110 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 4121 | 4121 |
| 4122 void LCodeGen::DoCheckMap(LCheckMap* instr) { | 4122 void LCodeGen::DoCheckMap(LCheckMap* instr) { |
| 4123 LOperand* input = instr->InputAt(0); | 4123 LOperand* input = instr->InputAt(0); |
| 4124 ASSERT(input->IsRegister()); | 4124 ASSERT(input->IsRegister()); |
| 4125 Register reg = ToRegister(input); | 4125 Register reg = ToRegister(input); |
| 4126 Handle<Map> map = instr->hydrogen()->map(); | 4126 Handle<Map> map = instr->hydrogen()->map(); |
| 4127 DoCheckMapCommon(reg, map, instr->hydrogen()->mode(), instr->environment()); | 4127 DoCheckMapCommon(reg, map, instr->hydrogen()->mode(), instr->environment()); |
| 4128 } | 4128 } |
| 4129 | 4129 |
| 4130 | 4130 |
| 4131 void LCodeGen::DoCheckMapSet(LCheckMapSet* instr) { |
| 4132 LOperand* input = instr->InputAt(0); |
| 4133 ASSERT(input->IsRegister()); |
| 4134 Register reg = ToRegister(input); |
| 4135 |
| 4136 Label success; |
| 4137 SmallMapList* map_set = instr->hydrogen()->map_set(); |
| 4138 for (int i = 0; i < map_set->length() - 1; i++) { |
| 4139 Handle<Map> map = map_set->at(i); |
| 4140 __ CompareMap(reg, map, &success, REQUIRE_EXACT_MAP); |
| 4141 __ j(equal, &success); |
| 4142 } |
| 4143 Handle<Map> map = map_set->last(); |
| 4144 DoCheckMapCommon(reg, map, REQUIRE_EXACT_MAP, instr->environment()); |
| 4145 __ bind(&success); |
| 4146 } |
| 4147 |
| 4148 |
| 4131 void LCodeGen::DoClampDToUint8(LClampDToUint8* instr) { | 4149 void LCodeGen::DoClampDToUint8(LClampDToUint8* instr) { |
| 4132 XMMRegister value_reg = ToDoubleRegister(instr->unclamped()); | 4150 XMMRegister value_reg = ToDoubleRegister(instr->unclamped()); |
| 4133 Register result_reg = ToRegister(instr->result()); | 4151 Register result_reg = ToRegister(instr->result()); |
| 4134 __ ClampDoubleToUint8(value_reg, xmm0, result_reg); | 4152 __ ClampDoubleToUint8(value_reg, xmm0, result_reg); |
| 4135 } | 4153 } |
| 4136 | 4154 |
| 4137 | 4155 |
| 4138 void LCodeGen::DoClampIToUint8(LClampIToUint8* instr) { | 4156 void LCodeGen::DoClampIToUint8(LClampIToUint8* instr) { |
| 4139 ASSERT(instr->unclamped()->Equals(instr->result())); | 4157 ASSERT(instr->unclamped()->Equals(instr->result())); |
| 4140 Register value_reg = ToRegister(instr->result()); | 4158 Register value_reg = ToRegister(instr->result()); |
| (...skipping 760 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 4901 FixedArray::kHeaderSize - kPointerSize)); | 4919 FixedArray::kHeaderSize - kPointerSize)); |
| 4902 __ bind(&done); | 4920 __ bind(&done); |
| 4903 } | 4921 } |
| 4904 | 4922 |
| 4905 | 4923 |
| 4906 #undef __ | 4924 #undef __ |
| 4907 | 4925 |
| 4908 } } // namespace v8::internal | 4926 } } // namespace v8::internal |
| 4909 | 4927 |
| 4910 #endif // V8_TARGET_ARCH_IA32 | 4928 #endif // V8_TARGET_ARCH_IA32 |
| OLD | NEW |