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

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

Issue 159266: Add inline caching for keyed loads and stores. Remove extra parentheses from... (Closed) Base URL: http://v8.googlecode.com/svn/branches/bleeding_edge/
Patch Set: '' Created 11 years, 5 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/builtins-x64.cc ('k') | src/x64/disasm-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 3361 matching lines...) Expand 10 before | Expand all | Expand 10 after
3372 frame_->Spill(obj.reg()); 3372 frame_->Spill(obj.reg());
3373 3373
3374 // If the object is a smi, we return null. 3374 // If the object is a smi, we return null.
3375 __ testl(obj.reg(), Immediate(kSmiTagMask)); 3375 __ testl(obj.reg(), Immediate(kSmiTagMask));
3376 null.Branch(zero); 3376 null.Branch(zero);
3377 3377
3378 // Check that the object is a JS object but take special care of JS 3378 // Check that the object is a JS object but take special care of JS
3379 // functions to make sure they have 'Function' as their class. 3379 // functions to make sure they have 'Function' as their class.
3380 3380
3381 __ CmpObjectType(obj.reg(), FIRST_JS_OBJECT_TYPE, obj.reg()); 3381 __ CmpObjectType(obj.reg(), FIRST_JS_OBJECT_TYPE, obj.reg());
3382 null.Branch(less); 3382 null.Branch(below);
3383 3383
3384 // As long as JS_FUNCTION_TYPE is the last instance type and it is 3384 // As long as JS_FUNCTION_TYPE is the last instance type and it is
3385 // right after LAST_JS_OBJECT_TYPE, we can avoid checking for 3385 // right after LAST_JS_OBJECT_TYPE, we can avoid checking for
3386 // LAST_JS_OBJECT_TYPE. 3386 // LAST_JS_OBJECT_TYPE.
3387 ASSERT(LAST_TYPE == JS_FUNCTION_TYPE); 3387 ASSERT(LAST_TYPE == JS_FUNCTION_TYPE);
3388 ASSERT(JS_FUNCTION_TYPE == LAST_JS_OBJECT_TYPE + 1); 3388 ASSERT(JS_FUNCTION_TYPE == LAST_JS_OBJECT_TYPE + 1);
3389 __ CmpInstanceType(obj.reg(), JS_FUNCTION_TYPE); 3389 __ CmpInstanceType(obj.reg(), JS_FUNCTION_TYPE);
3390 function.Branch(equal); 3390 function.Branch(equal);
3391 3391
3392 // Check if the constructor in the map is a function. 3392 // Check if the constructor in the map is a function.
(...skipping 3549 matching lines...) Expand 10 before | Expand all | Expand 10 after
6942 int CompareStub::MinorKey() { 6942 int CompareStub::MinorKey() {
6943 // Encode the two parameters in a unique 16 bit value. 6943 // Encode the two parameters in a unique 16 bit value.
6944 ASSERT(static_cast<unsigned>(cc_) < (1 << 15)); 6944 ASSERT(static_cast<unsigned>(cc_) < (1 << 15));
6945 return (static_cast<unsigned>(cc_) << 1) | (strict_ ? 1 : 0); 6945 return (static_cast<unsigned>(cc_) << 1) | (strict_ ? 1 : 0);
6946 } 6946 }
6947 6947
6948 6948
6949 #undef __ 6949 #undef __
6950 6950
6951 } } // namespace v8::internal 6951 } } // namespace v8::internal
OLDNEW
« no previous file with comments | « src/x64/builtins-x64.cc ('k') | src/x64/disasm-x64.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698