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

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

Issue 7122003: Make x64 to use the RecordWrite stub. This is a step towards getting (Closed) Base URL: http://v8.googlecode.com/svn/branches/experimental/gc/
Patch Set: '' 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/x64/full-codegen-x64.cc ('k') | src/x64/lithium-codegen-x64.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 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 786 matching lines...) Expand 10 before | Expand all | Expand 10 after
797 // rcx: index 797 // rcx: index
798 Label non_smi_value; 798 Label non_smi_value;
799 __ movq(FieldOperand(rbx, rcx, times_pointer_size, FixedArray::kHeaderSize), 799 __ movq(FieldOperand(rbx, rcx, times_pointer_size, FixedArray::kHeaderSize),
800 rax); 800 rax);
801 __ JumpIfNotSmi(rax, &non_smi_value, Label::kNear); 801 __ JumpIfNotSmi(rax, &non_smi_value, Label::kNear);
802 __ ret(0); 802 __ ret(0);
803 __ bind(&non_smi_value); 803 __ bind(&non_smi_value);
804 // Slow case that needs to retain rcx for use by RecordWrite. 804 // Slow case that needs to retain rcx for use by RecordWrite.
805 // Update write barrier for the elements array address. 805 // Update write barrier for the elements array address.
806 __ movq(rdx, rax); 806 __ movq(rdx, rax);
807 __ RecordWriteNonSmi(rbx, 0, rdx, rcx, kDontSaveFPRegs); 807 __ lea(rcx,
808 FieldOperand(rbx, rcx, times_pointer_size, FixedArray::kHeaderSize));
809 __ RecordWrite(
810 rbx, rcx, rdx, kDontSaveFPRegs, EMIT_REMEMBERED_SET, OMIT_SMI_CHECK);
808 __ ret(0); 811 __ ret(0);
809 } 812 }
810 813
811 814
812 // The generated code does not accept smi keys. 815 // The generated code does not accept smi keys.
813 // The generated code falls through if both probes miss. 816 // The generated code falls through if both probes miss.
814 static void GenerateMonomorphicCacheProbe(MacroAssembler* masm, 817 static void GenerateMonomorphicCacheProbe(MacroAssembler* masm,
815 int argc, 818 int argc,
816 Code::Kind kind, 819 Code::Kind kind,
817 Code::ExtraICState extra_ic_state) { 820 Code::ExtraICState extra_ic_state) {
(...skipping 781 matching lines...) Expand 10 before | Expand all | Expand 10 after
1599 Condition cc = *jmp_address == Assembler::kJncShortOpcode 1602 Condition cc = *jmp_address == Assembler::kJncShortOpcode
1600 ? not_zero 1603 ? not_zero
1601 : zero; 1604 : zero;
1602 *jmp_address = static_cast<byte>(Assembler::kJccShortPrefix | cc); 1605 *jmp_address = static_cast<byte>(Assembler::kJccShortPrefix | cc);
1603 } 1606 }
1604 1607
1605 1608
1606 } } // namespace v8::internal 1609 } } // namespace v8::internal
1607 1610
1608 #endif // V8_TARGET_ARCH_X64 1611 #endif // V8_TARGET_ARCH_X64
OLDNEW
« no previous file with comments | « src/x64/full-codegen-x64.cc ('k') | src/x64/lithium-codegen-x64.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698