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

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

Issue 23697002: Implement proper map checks of captured objects. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Addressed comments by Toon Verwaest. Created 7 years, 3 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/mips/lithium-mips.cc ('k') | src/x64/lithium-x64.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 2013 the V8 project authors. All rights reserved. 1 // Copyright 2013 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 4871 matching lines...) Expand 10 before | Expand all | Expand 10 after
4882 __ movzxbl(kScratchRegister, 4882 __ movzxbl(kScratchRegister,
4883 FieldOperand(kScratchRegister, Map::kInstanceTypeOffset)); 4883 FieldOperand(kScratchRegister, Map::kInstanceTypeOffset));
4884 __ andb(kScratchRegister, Immediate(mask)); 4884 __ andb(kScratchRegister, Immediate(mask));
4885 __ cmpb(kScratchRegister, Immediate(tag)); 4885 __ cmpb(kScratchRegister, Immediate(tag));
4886 DeoptimizeIf(not_equal, instr->environment()); 4886 DeoptimizeIf(not_equal, instr->environment());
4887 } 4887 }
4888 } 4888 }
4889 } 4889 }
4890 4890
4891 4891
4892 void LCodeGen::DoCheckFunction(LCheckFunction* instr) { 4892 void LCodeGen::DoCheckValue(LCheckValue* instr) {
4893 Register reg = ToRegister(instr->value()); 4893 Register reg = ToRegister(instr->value());
4894 Handle<JSFunction> target = instr->hydrogen()->target(); 4894 Handle<HeapObject> object = instr->hydrogen()->object();
4895 __ CmpHeapObject(reg, target); 4895 __ CmpHeapObject(reg, object);
4896 DeoptimizeIf(not_equal, instr->environment()); 4896 DeoptimizeIf(not_equal, instr->environment());
4897 } 4897 }
4898 4898
4899 4899
4900 void LCodeGen::DoDeferredInstanceMigration(LCheckMaps* instr, Register object) { 4900 void LCodeGen::DoDeferredInstanceMigration(LCheckMaps* instr, Register object) {
4901 { 4901 {
4902 PushSafepointRegistersScope scope(this); 4902 PushSafepointRegistersScope scope(this);
4903 __ push(object); 4903 __ push(object);
4904 CallRuntimeFromDeferred(Runtime::kMigrateInstance, 1, instr); 4904 CallRuntimeFromDeferred(Runtime::kMigrateInstance, 1, instr);
4905 __ testq(rax, Immediate(kSmiTagMask)); 4905 __ testq(rax, Immediate(kSmiTagMask));
(...skipping 617 matching lines...) Expand 10 before | Expand all | Expand 10 after
5523 FixedArray::kHeaderSize - kPointerSize)); 5523 FixedArray::kHeaderSize - kPointerSize));
5524 __ bind(&done); 5524 __ bind(&done);
5525 } 5525 }
5526 5526
5527 5527
5528 #undef __ 5528 #undef __
5529 5529
5530 } } // namespace v8::internal 5530 } } // namespace v8::internal
5531 5531
5532 #endif // V8_TARGET_ARCH_X64 5532 #endif // V8_TARGET_ARCH_X64
OLDNEW
« no previous file with comments | « src/mips/lithium-mips.cc ('k') | src/x64/lithium-x64.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698