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

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

Issue 348039: Add comparison operations to the fast compiler. (Closed) Base URL: http://v8.googlecode.com/svn/branches/bleeding_edge/
Patch Set: '' Created 11 years, 1 month 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/ia32/fast-codegen-ia32.cc ('k') | src/x64/fast-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 2009 the V8 project authors. All rights reserved. 1 // Copyright 2009 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 6562 matching lines...) Expand 10 before | Expand all | Expand 10 after
6573 __ bind(&loop); 6573 __ bind(&loop);
6574 __ cmpq(rcx, rbx); 6574 __ cmpq(rcx, rbx);
6575 __ j(equal, &is_instance); 6575 __ j(equal, &is_instance);
6576 __ cmpq(rcx, kScratchRegister); 6576 __ cmpq(rcx, kScratchRegister);
6577 __ j(equal, &is_not_instance); 6577 __ j(equal, &is_not_instance);
6578 __ movq(rcx, FieldOperand(rcx, HeapObject::kMapOffset)); 6578 __ movq(rcx, FieldOperand(rcx, HeapObject::kMapOffset));
6579 __ movq(rcx, FieldOperand(rcx, Map::kPrototypeOffset)); 6579 __ movq(rcx, FieldOperand(rcx, Map::kPrototypeOffset));
6580 __ jmp(&loop); 6580 __ jmp(&loop);
6581 6581
6582 __ bind(&is_instance); 6582 __ bind(&is_instance);
6583 __ xor_(rax, rax); 6583 __ xorl(rax, rax);
6584 __ ret(2 * kPointerSize); 6584 __ ret(2 * kPointerSize);
6585 6585
6586 __ bind(&is_not_instance); 6586 __ bind(&is_not_instance);
6587 __ Move(rax, Smi::FromInt(1)); 6587 __ movl(rax, Immediate(1));
6588 __ ret(2 * kPointerSize); 6588 __ ret(2 * kPointerSize);
6589 6589
6590 // Slow-case: Go through the JavaScript implementation. 6590 // Slow-case: Go through the JavaScript implementation.
6591 __ bind(&slow); 6591 __ bind(&slow);
6592 __ InvokeBuiltin(Builtins::INSTANCE_OF, JUMP_FUNCTION); 6592 __ InvokeBuiltin(Builtins::INSTANCE_OF, JUMP_FUNCTION);
6593 } 6593 }
6594 6594
6595 6595
6596 void ArgumentsAccessStub::GenerateNewObject(MacroAssembler* masm) { 6596 void ArgumentsAccessStub::GenerateNewObject(MacroAssembler* masm) {
6597 // The displacement is used for skipping the return address and the 6597 // The displacement is used for skipping the return address and the
(...skipping 1254 matching lines...) Expand 10 before | Expand all | Expand 10 after
7852 masm.GetCode(&desc); 7852 masm.GetCode(&desc);
7853 // Call the function from C++. 7853 // Call the function from C++.
7854 return FUNCTION_CAST<ModuloFunction>(buffer); 7854 return FUNCTION_CAST<ModuloFunction>(buffer);
7855 } 7855 }
7856 7856
7857 #endif 7857 #endif
7858 7858
7859 #undef __ 7859 #undef __
7860 7860
7861 } } // namespace v8::internal 7861 } } // namespace v8::internal
OLDNEW
« no previous file with comments | « src/ia32/fast-codegen-ia32.cc ('k') | src/x64/fast-codegen-x64.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698