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

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

Issue 6966041: Add complete ElementKind information directly to Map for objects with elements. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: implement all platforms Created 9 years, 7 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
OLDNEW
1 // Copyright 2011 the V8 project authors. All rights reserved. 1 // Copyright 2011 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 466 matching lines...) Expand 10 before | Expand all | Expand 10 after
477 // Check that the key is a smi. 477 // Check that the key is a smi.
478 __ test(eax, Immediate(kSmiTagMask)); 478 __ test(eax, Immediate(kSmiTagMask));
479 __ j(not_zero, &check_string); 479 __ j(not_zero, &check_string);
480 __ bind(&index_smi); 480 __ bind(&index_smi);
481 // Now the key is known to be a smi. This place is also jumped to from 481 // Now the key is known to be a smi. This place is also jumped to from
482 // where a numeric string is converted to a smi. 482 // where a numeric string is converted to a smi.
483 483
484 GenerateKeyedLoadReceiverCheck( 484 GenerateKeyedLoadReceiverCheck(
485 masm, edx, ecx, Map::kHasIndexedInterceptor, &slow); 485 masm, edx, ecx, Map::kHasIndexedInterceptor, &slow);
486 486
487 // Check the "has fast elements" bit in the receiver's map which is 487 // Check if receiver's map to see if it has fast elements.
Mads Ager (chromium) 2011/05/30 11:14:24 if receiver's -> the receiver's
danno 2011/06/01 22:29:54 Done.
488 // now in ecx. 488 __ CheckFastElements(ecx, &check_number_dictionary);
489 __ test_b(FieldOperand(ecx, Map::kBitField2Offset),
490 1 << Map::kHasFastElements);
491 __ j(zero, &check_number_dictionary);
492 489
493 GenerateFastArrayLoad(masm, 490 GenerateFastArrayLoad(masm,
494 edx, 491 edx,
495 eax, 492 eax,
496 ecx, 493 ecx,
497 eax, 494 eax,
498 NULL, 495 NULL,
499 &slow); 496 &slow);
500 Isolate* isolate = masm->isolate(); 497 Isolate* isolate = masm->isolate();
501 Counters* counters = isolate->counters(); 498 Counters* counters = isolate->counters();
(...skipping 1086 matching lines...) Expand 10 before | Expand all | Expand 10 after
1588 Condition cc = *jmp_address == Assembler::kJncShortOpcode 1585 Condition cc = *jmp_address == Assembler::kJncShortOpcode
1589 ? not_zero 1586 ? not_zero
1590 : zero; 1587 : zero;
1591 *jmp_address = static_cast<byte>(Assembler::kJccShortPrefix | cc); 1588 *jmp_address = static_cast<byte>(Assembler::kJccShortPrefix | cc);
1592 } 1589 }
1593 1590
1594 1591
1595 } } // namespace v8::internal 1592 } } // namespace v8::internal
1596 1593
1597 #endif // V8_TARGET_ARCH_IA32 1594 #endif // V8_TARGET_ARCH_IA32
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698