| 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 265 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 276 JSFunction::cast(masm->isolate()->native_context()->get(index))); | 276 JSFunction::cast(masm->isolate()->native_context()->get(index))); |
| 277 // Check we're still in the same context. | 277 // Check we're still in the same context. |
| 278 Register scratch = prototype; | 278 Register scratch = prototype; |
| 279 const int offset = Context::SlotOffset(Context::GLOBAL_OBJECT_INDEX); | 279 const int offset = Context::SlotOffset(Context::GLOBAL_OBJECT_INDEX); |
| 280 __ mov(scratch, Operand(esi, offset)); | 280 __ mov(scratch, Operand(esi, offset)); |
| 281 __ mov(scratch, FieldOperand(scratch, GlobalObject::kNativeContextOffset)); | 281 __ mov(scratch, FieldOperand(scratch, GlobalObject::kNativeContextOffset)); |
| 282 __ cmp(Operand(scratch, Context::SlotOffset(index)), function); | 282 __ cmp(Operand(scratch, Context::SlotOffset(index)), function); |
| 283 __ j(not_equal, miss); | 283 __ j(not_equal, miss); |
| 284 | 284 |
| 285 // Load its initial map. The global functions all have initial maps. | 285 // Load its initial map. The global functions all have initial maps. |
| 286 __ Set(prototype, Immediate(Handle<Map>(function->initial_map()))); | 286 __ Move(prototype, Immediate(Handle<Map>(function->initial_map()))); |
| 287 // Load the prototype from the initial map. | 287 // Load the prototype from the initial map. |
| 288 __ mov(prototype, FieldOperand(prototype, Map::kPrototypeOffset)); | 288 __ mov(prototype, FieldOperand(prototype, Map::kPrototypeOffset)); |
| 289 } | 289 } |
| 290 | 290 |
| 291 | 291 |
| 292 void StubCompiler::GenerateLoadArrayLength(MacroAssembler* masm, | 292 void StubCompiler::GenerateLoadArrayLength(MacroAssembler* masm, |
| 293 Register receiver, | 293 Register receiver, |
| 294 Register scratch, | 294 Register scratch, |
| 295 Label* miss_label) { | 295 Label* miss_label) { |
| 296 // Check that the receiver isn't a smi. | 296 // Check that the receiver isn't a smi. |
| (...skipping 1238 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1535 // ----------------------------------- | 1535 // ----------------------------------- |
| 1536 TailCallBuiltin(masm, Builtins::kKeyedLoadIC_Miss); | 1536 TailCallBuiltin(masm, Builtins::kKeyedLoadIC_Miss); |
| 1537 } | 1537 } |
| 1538 | 1538 |
| 1539 | 1539 |
| 1540 #undef __ | 1540 #undef __ |
| 1541 | 1541 |
| 1542 } } // namespace v8::internal | 1542 } } // namespace v8::internal |
| 1543 | 1543 |
| 1544 #endif // V8_TARGET_ARCH_IA32 | 1544 #endif // V8_TARGET_ARCH_IA32 |
| OLD | NEW |