| OLD | NEW |
| 1 // Copyright 2010 the V8 project authors. All rights reserved. | 1 // Copyright 2010 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 1159 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1170 // ----------- S t a t e ------------- | 1170 // ----------- S t a t e ------------- |
| 1171 // -- rcx : name | 1171 // -- rcx : name |
| 1172 // -- rsp[0] : return address | 1172 // -- rsp[0] : return address |
| 1173 // -- rsp[8] : receiver | 1173 // -- rsp[8] : receiver |
| 1174 // ----------------------------------- | 1174 // ----------------------------------- |
| 1175 Label miss; | 1175 Label miss; |
| 1176 | 1176 |
| 1177 // Load receiver. | 1177 // Load receiver. |
| 1178 __ movq(rax, Operand(rsp, kPointerSize)); | 1178 __ movq(rax, Operand(rsp, kPointerSize)); |
| 1179 | 1179 |
| 1180 // Chech that receiver is not a smi. |
| 1181 __ JumpIfSmi(rax, &miss); |
| 1182 |
| 1180 // Check the maps of the full prototype chain. Also check that | 1183 // Check the maps of the full prototype chain. Also check that |
| 1181 // global property cells up to (but not including) the last object | 1184 // global property cells up to (but not including) the last object |
| 1182 // in the prototype chain are empty. | 1185 // in the prototype chain are empty. |
| 1183 CheckPrototypes(object, rax, last, rbx, rdx, name, &miss); | 1186 CheckPrototypes(object, rax, last, rbx, rdx, name, &miss); |
| 1184 | 1187 |
| 1185 // If the last object in the prototype chain is a global object, | 1188 // If the last object in the prototype chain is a global object, |
| 1186 // check that the global property cell is empty. | 1189 // check that the global property cell is empty. |
| 1187 if (last->IsGlobalObject()) { | 1190 if (last->IsGlobalObject()) { |
| 1188 Object* cell = GenerateCheckPropertyCell(masm(), | 1191 Object* cell = GenerateCheckPropertyCell(masm(), |
| 1189 GlobalObject::cast(last), | 1192 GlobalObject::cast(last), |
| (...skipping 829 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2019 __ Jump(generic_construct_stub, RelocInfo::CODE_TARGET); | 2022 __ Jump(generic_construct_stub, RelocInfo::CODE_TARGET); |
| 2020 | 2023 |
| 2021 // Return the generated code. | 2024 // Return the generated code. |
| 2022 return GetCode(); | 2025 return GetCode(); |
| 2023 } | 2026 } |
| 2024 | 2027 |
| 2025 | 2028 |
| 2026 #undef __ | 2029 #undef __ |
| 2027 | 2030 |
| 2028 } } // namespace v8::internal | 2031 } } // namespace v8::internal |
| OLD | NEW |