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

Side by Side Diff: src/ic-inl.h

Issue 12319144: Avoid TLS accesses in Object::Lookup and Object::GetPrototype. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Simplified Object::GetPrototype a bit Created 7 years, 9 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/ic.cc ('k') | src/isolate.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 2012 the V8 project authors. All rights reserved. 1 // Copyright 2012 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 111 matching lines...) Expand 10 before | Expand all | Expand 10 after
122 if (holder != object && 122 if (holder != object &&
123 !object->HasFastProperties() && 123 !object->HasFastProperties() &&
124 !object->IsJSGlobalProxy() && 124 !object->IsJSGlobalProxy() &&
125 !object->IsJSGlobalObject()) { 125 !object->IsJSGlobalObject()) {
126 return PROTOTYPE_MAP; 126 return PROTOTYPE_MAP;
127 } 127 }
128 return OWN_MAP; 128 return OWN_MAP;
129 } 129 }
130 130
131 131
132 JSObject* IC::GetCodeCacheHolder(Object* object, InlineCacheHolderFlag holder) { 132 JSObject* IC::GetCodeCacheHolder(Isolate* isolate,
133 Object* map_owner = (holder == OWN_MAP ? object : object->GetPrototype()); 133 Object* object,
134 InlineCacheHolderFlag holder) {
135 Object* map_owner =
136 holder == OWN_MAP ? object : object->GetPrototype(isolate);
134 ASSERT(map_owner->IsJSObject()); 137 ASSERT(map_owner->IsJSObject());
135 return JSObject::cast(map_owner); 138 return JSObject::cast(map_owner);
136 } 139 }
137 140
138 141
139 } } // namespace v8::internal 142 } } // namespace v8::internal
140 143
141 #endif // V8_IC_INL_H_ 144 #endif // V8_IC_INL_H_
OLDNEW
« no previous file with comments | « src/ic.cc ('k') | src/isolate.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698