Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(141)

Side by Side Diff: src/ia32/ic-ia32.cc

Issue 3587002: Backport r5553 "Do not invoke indexed interceptor getters for negative indice... (Closed) Base URL: http://v8.googlecode.com/svn/branches/2.1/
Patch Set: Created 10 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « src/globals.h ('k') | src/stub-cache.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2006-2008 the V8 project authors. All rights reserved. 1 // Copyright 2006-2008 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 676 matching lines...) Expand 10 before | Expand all | Expand 10 after
687 // -- eax : key 687 // -- eax : key
688 // -- edx : receiver 688 // -- edx : receiver
689 // -- esp[0] : return address 689 // -- esp[0] : return address
690 // ----------------------------------- 690 // -----------------------------------
691 Label slow; 691 Label slow;
692 692
693 // Check that the receiver isn't a smi. 693 // Check that the receiver isn't a smi.
694 __ test(edx, Immediate(kSmiTagMask)); 694 __ test(edx, Immediate(kSmiTagMask));
695 __ j(zero, &slow, not_taken); 695 __ j(zero, &slow, not_taken);
696 696
697 // Check that the key is a smi. 697 // Check that the key is an array index, that is Uint32.
698 __ test(eax, Immediate(kSmiTagMask)); 698 __ test(eax, Immediate(kSmiTagMask | kSmiSignMask));
699 __ j(not_zero, &slow, not_taken); 699 __ j(not_zero, &slow, not_taken);
700 700
701 // Get the map of the receiver. 701 // Get the map of the receiver.
702 __ mov(ecx, FieldOperand(edx, HeapObject::kMapOffset)); 702 __ mov(ecx, FieldOperand(edx, HeapObject::kMapOffset));
703 703
704 // Check that it has indexed interceptor and access checks 704 // Check that it has indexed interceptor and access checks
705 // are not enabled for this object. 705 // are not enabled for this object.
706 __ movzx_b(ecx, FieldOperand(ecx, Map::kBitFieldOffset)); 706 __ movzx_b(ecx, FieldOperand(ecx, Map::kBitFieldOffset));
707 __ and_(Operand(ecx), Immediate(kSlowCaseBitFieldMask)); 707 __ and_(Operand(ecx), Immediate(kSlowCaseBitFieldMask));
708 __ cmp(Operand(ecx), Immediate(1 << Map::kHasIndexedInterceptor)); 708 __ cmp(Operand(ecx), Immediate(1 << Map::kHasIndexedInterceptor));
(...skipping 896 matching lines...) Expand 10 before | Expand all | Expand 10 after
1605 1605
1606 // Do tail-call to runtime routine. 1606 // Do tail-call to runtime routine.
1607 ExternalReference ref = ExternalReference(IC_Utility(kKeyedStoreIC_Miss)); 1607 ExternalReference ref = ExternalReference(IC_Utility(kKeyedStoreIC_Miss));
1608 __ TailCallExternalReference(ref, 3, 1); 1608 __ TailCallExternalReference(ref, 3, 1);
1609 } 1609 }
1610 1610
1611 #undef __ 1611 #undef __
1612 1612
1613 1613
1614 } } // namespace v8::internal 1614 } } // namespace v8::internal
OLDNEW
« no previous file with comments | « src/globals.h ('k') | src/stub-cache.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698