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

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

Issue 2983001: Revert revisions 5041 and 5042 introducing virtual scavenge... (Closed) Base URL: http://v8.googlecode.com/svn/branches/bleeding_edge/
Patch Set: Created 10 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/objects.cc ('k') | src/serialize.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 2006-2008 the V8 project authors. All rights reserved. 1 // Copyright 2006-2008 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 2042 matching lines...) Expand 10 before | Expand all | Expand 10 after
2053 return ptr[index]; 2053 return ptr[index];
2054 } 2054 }
2055 2055
2056 2056
2057 void ExternalFloatArray::set(int index, float value) { 2057 void ExternalFloatArray::set(int index, float value) {
2058 ASSERT((index >= 0) && (index < this->length())); 2058 ASSERT((index >= 0) && (index < this->length()));
2059 float* ptr = static_cast<float*>(external_pointer()); 2059 float* ptr = static_cast<float*>(external_pointer());
2060 ptr[index] = value; 2060 ptr[index] = value;
2061 } 2061 }
2062 2062
2063 inline Scavenger Map::scavenger() {
2064 Scavenger callback = reinterpret_cast<Scavenger>(
2065 READ_INTPTR_FIELD(this, kIterateBodyCallbackOffset));
2066
2067 ASSERT(callback == Heap::GetScavenger(instance_type(),
2068 instance_size()));
2069
2070 return callback;
2071 }
2072
2073 inline void Map::set_scavenger(Scavenger callback) {
2074 ASSERT(!reinterpret_cast<Object*>(
2075 reinterpret_cast<intptr_t>(callback))->IsHeapObject());
2076 WRITE_INTPTR_FIELD(this,
2077 kIterateBodyCallbackOffset,
2078 reinterpret_cast<intptr_t>(callback));
2079 }
2080 2063
2081 int Map::instance_size() { 2064 int Map::instance_size() {
2082 return READ_BYTE_FIELD(this, kInstanceSizeOffset) << kPointerSizeLog2; 2065 return READ_BYTE_FIELD(this, kInstanceSizeOffset) << kPointerSizeLog2;
2083 } 2066 }
2084 2067
2085 2068
2086 int Map::inobject_properties() { 2069 int Map::inobject_properties() {
2087 return READ_BYTE_FIELD(this, kInObjectPropertiesOffset); 2070 return READ_BYTE_FIELD(this, kInObjectPropertiesOffset);
2088 } 2071 }
2089 2072
(...skipping 1229 matching lines...) Expand 10 before | Expand all | Expand 10 after
3319 #undef WRITE_INT_FIELD 3302 #undef WRITE_INT_FIELD
3320 #undef READ_SHORT_FIELD 3303 #undef READ_SHORT_FIELD
3321 #undef WRITE_SHORT_FIELD 3304 #undef WRITE_SHORT_FIELD
3322 #undef READ_BYTE_FIELD 3305 #undef READ_BYTE_FIELD
3323 #undef WRITE_BYTE_FIELD 3306 #undef WRITE_BYTE_FIELD
3324 3307
3325 3308
3326 } } // namespace v8::internal 3309 } } // namespace v8::internal
3327 3310
3328 #endif // V8_OBJECTS_INL_H_ 3311 #endif // V8_OBJECTS_INL_H_
OLDNEW
« no previous file with comments | « src/objects.cc ('k') | src/serialize.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698