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 1700 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1711 Handle<String> name, | 1711 Handle<String> name, |
1712 Code::StubType type) { | 1712 Code::StubType type) { |
1713 // ----------- S t a t e ------------- | 1713 // ----------- S t a t e ------------- |
1714 // -- r2 : name | 1714 // -- r2 : name |
1715 // -- lr : return address | 1715 // -- lr : return address |
1716 // -- sp[(argc - n - 1) * 4] : arg[n] (zero-based) | 1716 // -- sp[(argc - n - 1) * 4] : arg[n] (zero-based) |
1717 // -- ... | 1717 // -- ... |
1718 // -- sp[argc * 4] : receiver | 1718 // -- sp[argc * 4] : receiver |
1719 // ----------------------------------- | 1719 // ----------------------------------- |
1720 | 1720 |
1721 // If object is not an array, bail out to regular call. | 1721 // If object is not an array or is observed, bail out to regular call. |
1722 if (!object->IsJSArray() || !cell.is_null()) return Handle<Code>::null(); | 1722 if (!object->IsJSArray() || |
| 1723 !cell.is_null() || |
| 1724 Handle<JSArray>::cast(object)->map()->is_observed()) { |
| 1725 return Handle<Code>::null(); |
| 1726 } |
1723 | 1727 |
1724 Label miss; | 1728 Label miss; |
1725 GenerateNameCheck(name, &miss); | 1729 GenerateNameCheck(name, &miss); |
1726 | 1730 |
1727 Register receiver = r1; | 1731 Register receiver = r1; |
1728 // Get the receiver from the stack | 1732 // Get the receiver from the stack |
1729 const int argc = arguments().immediate(); | 1733 const int argc = arguments().immediate(); |
1730 __ ldr(receiver, MemOperand(sp, argc * kPointerSize)); | 1734 __ ldr(receiver, MemOperand(sp, argc * kPointerSize)); |
1731 | 1735 |
1732 // Check that the receiver isn't a smi. | 1736 // Check that the receiver isn't a smi. |
(...skipping 232 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1965 Handle<String> name, | 1969 Handle<String> name, |
1966 Code::StubType type) { | 1970 Code::StubType type) { |
1967 // ----------- S t a t e ------------- | 1971 // ----------- S t a t e ------------- |
1968 // -- r2 : name | 1972 // -- r2 : name |
1969 // -- lr : return address | 1973 // -- lr : return address |
1970 // -- sp[(argc - n - 1) * 4] : arg[n] (zero-based) | 1974 // -- sp[(argc - n - 1) * 4] : arg[n] (zero-based) |
1971 // -- ... | 1975 // -- ... |
1972 // -- sp[argc * 4] : receiver | 1976 // -- sp[argc * 4] : receiver |
1973 // ----------------------------------- | 1977 // ----------------------------------- |
1974 | 1978 |
1975 // If object is not an array, bail out to regular call. | 1979 // If object is not an array or is observed, bail out to regular call. |
1976 if (!object->IsJSArray() || !cell.is_null()) return Handle<Code>::null(); | 1980 if (!object->IsJSArray() || |
| 1981 !cell.is_null() || |
| 1982 Handle<JSArray>::cast(object)->map()->is_observed()) { |
| 1983 return Handle<Code>::null(); |
| 1984 } |
1977 | 1985 |
1978 Label miss, return_undefined, call_builtin; | 1986 Label miss, return_undefined, call_builtin; |
1979 Register receiver = r1; | 1987 Register receiver = r1; |
1980 Register elements = r3; | 1988 Register elements = r3; |
1981 GenerateNameCheck(name, &miss); | 1989 GenerateNameCheck(name, &miss); |
1982 | 1990 |
1983 // Get the receiver from the stack | 1991 // Get the receiver from the stack |
1984 const int argc = arguments().immediate(); | 1992 const int argc = arguments().immediate(); |
1985 __ ldr(receiver, MemOperand(sp, argc * kPointerSize)); | 1993 __ ldr(receiver, MemOperand(sp, argc * kPointerSize)); |
1986 // Check that the receiver isn't a smi. | 1994 // Check that the receiver isn't a smi. |
(...skipping 1173 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
3160 // ----------------------------------- | 3168 // ----------------------------------- |
3161 TailCallBuiltin(masm, Builtins::kKeyedLoadIC_MissForceGeneric); | 3169 TailCallBuiltin(masm, Builtins::kKeyedLoadIC_MissForceGeneric); |
3162 } | 3170 } |
3163 | 3171 |
3164 | 3172 |
3165 #undef __ | 3173 #undef __ |
3166 | 3174 |
3167 } } // namespace v8::internal | 3175 } } // namespace v8::internal |
3168 | 3176 |
3169 #endif // V8_TARGET_ARCH_ARM | 3177 #endif // V8_TARGET_ARCH_ARM |
OLD | NEW |