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

Side by Side Diff: src/arm/ic-arm.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: review feedback Created 9 years, 6 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/arm/full-codegen-arm.cc ('k') | src/arm/macro-assembler-arm.h » ('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 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 926 matching lines...) Expand 10 before | Expand all | Expand 10 after
937 937
938 // Check that the key is a smi. 938 // Check that the key is a smi.
939 __ JumpIfNotSmi(key, &check_string); 939 __ JumpIfNotSmi(key, &check_string);
940 __ bind(&index_smi); 940 __ bind(&index_smi);
941 // Now the key is known to be a smi. This place is also jumped to from below 941 // Now the key is known to be a smi. This place is also jumped to from below
942 // where a numeric string is converted to a smi. 942 // where a numeric string is converted to a smi.
943 943
944 GenerateKeyedLoadReceiverCheck( 944 GenerateKeyedLoadReceiverCheck(
945 masm, receiver, r2, r3, Map::kHasIndexedInterceptor, &slow); 945 masm, receiver, r2, r3, Map::kHasIndexedInterceptor, &slow);
946 946
947 // Check the "has fast elements" bit in the receiver's map which is 947 // Check the receiver's map to see if it has fast elements.
948 // now in r2. 948 __ CheckFastElements(r2, r3, &check_number_dictionary);
949 __ ldrb(r3, FieldMemOperand(r2, Map::kBitField2Offset));
950 __ tst(r3, Operand(1 << Map::kHasFastElements));
951 __ b(eq, &check_number_dictionary);
952 949
953 GenerateFastArrayLoad( 950 GenerateFastArrayLoad(
954 masm, receiver, key, r4, r3, r2, r0, NULL, &slow); 951 masm, receiver, key, r4, r3, r2, r0, NULL, &slow);
955 __ IncrementCounter(isolate->counters()->keyed_load_generic_smi(), 1, r2, r3); 952 __ IncrementCounter(isolate->counters()->keyed_load_generic_smi(), 1, r2, r3);
956 __ Ret(); 953 __ Ret();
957 954
958 __ bind(&check_number_dictionary); 955 __ bind(&check_number_dictionary);
959 __ ldr(r4, FieldMemOperand(receiver, JSObject::kElementsOffset)); 956 __ ldr(r4, FieldMemOperand(receiver, JSObject::kElementsOffset));
960 __ ldr(r3, FieldMemOperand(r4, JSObject::kMapOffset)); 957 __ ldr(r3, FieldMemOperand(r4, JSObject::kMapOffset));
961 958
(...skipping 596 matching lines...) Expand 10 before | Expand all | Expand 10 after
1558 Register reg = Assembler::GetRn(instr_at_patch); 1555 Register reg = Assembler::GetRn(instr_at_patch);
1559 patcher.masm()->tst(reg, Operand(kSmiTagMask)); 1556 patcher.masm()->tst(reg, Operand(kSmiTagMask));
1560 patcher.EmitCondition(eq); 1557 patcher.EmitCondition(eq);
1561 } 1558 }
1562 } 1559 }
1563 1560
1564 1561
1565 } } // namespace v8::internal 1562 } } // namespace v8::internal
1566 1563
1567 #endif // V8_TARGET_ARCH_ARM 1564 #endif // V8_TARGET_ARCH_ARM
OLDNEW
« no previous file with comments | « src/arm/full-codegen-arm.cc ('k') | src/arm/macro-assembler-arm.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698