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

Side by Side Diff: src/heap.h

Issue 1695007: Moving more code to lookup an item from the native cache into code generator. (Closed)
Patch Set: Next round of Lasse's comments Created 10 years, 7 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
« no previous file with comments | « no previous file | src/ia32/codegen-ia32.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 961 matching lines...) Expand 10 before | Expand all | Expand 10 after
972 ExternalStringTableUpdaterCallback updater_func); 972 ExternalStringTableUpdaterCallback updater_func);
973 973
974 // Helper function that governs the promotion policy from new space to 974 // Helper function that governs the promotion policy from new space to
975 // old. If the object's old address lies below the new space's age 975 // old. If the object's old address lies below the new space's age
976 // mark or if we've already filled the bottom 1/16th of the to space, 976 // mark or if we've already filled the bottom 1/16th of the to space,
977 // we try to promote this object. 977 // we try to promote this object.
978 static inline bool ShouldBePromoted(Address old_address, int object_size); 978 static inline bool ShouldBePromoted(Address old_address, int object_size);
979 979
980 static int MaxObjectSizeInNewSpace() { return kMaxObjectSizeInNewSpace; } 980 static int MaxObjectSizeInNewSpace() { return kMaxObjectSizeInNewSpace; }
981 981
982 static void ClearJSFunctionResultCaches();
983
982 private: 984 private:
983 static int reserved_semispace_size_; 985 static int reserved_semispace_size_;
984 static int max_semispace_size_; 986 static int max_semispace_size_;
985 static int initial_semispace_size_; 987 static int initial_semispace_size_;
986 static int max_old_generation_size_; 988 static int max_old_generation_size_;
987 static size_t code_range_size_; 989 static size_t code_range_size_;
988 990
989 // For keeping track of how much data has survived 991 // For keeping track of how much data has survived
990 // scavenge since last new space expansion. 992 // scavenge since last new space expansion.
991 static int survived_since_last_expansion_; 993 static int survived_since_last_expansion_;
(...skipping 194 matching lines...) Expand 10 before | Expand all | Expand 10 after
1186 set_instanceof_cache_function(the_hole_value()); 1188 set_instanceof_cache_function(the_hole_value());
1187 } 1189 }
1188 1190
1189 // Helper function used by CopyObject to copy a source object to an 1191 // Helper function used by CopyObject to copy a source object to an
1190 // allocated target object and update the forwarding pointer in the source 1192 // allocated target object and update the forwarding pointer in the source
1191 // object. Returns the target object. 1193 // object. Returns the target object.
1192 static inline HeapObject* MigrateObject(HeapObject* source, 1194 static inline HeapObject* MigrateObject(HeapObject* source,
1193 HeapObject* target, 1195 HeapObject* target,
1194 int size); 1196 int size);
1195 1197
1196 static void ClearJSFunctionResultCaches();
1197
1198 #if defined(DEBUG) || defined(ENABLE_LOGGING_AND_PROFILING) 1198 #if defined(DEBUG) || defined(ENABLE_LOGGING_AND_PROFILING)
1199 // Record the copy of an object in the NewSpace's statistics. 1199 // Record the copy of an object in the NewSpace's statistics.
1200 static void RecordCopiedObject(HeapObject* obj); 1200 static void RecordCopiedObject(HeapObject* obj);
1201 1201
1202 // Record statistics before and after garbage collection. 1202 // Record statistics before and after garbage collection.
1203 static void ReportStatisticsBeforeGC(); 1203 static void ReportStatisticsBeforeGC();
1204 static void ReportStatisticsAfterGC(); 1204 static void ReportStatisticsAfterGC();
1205 #endif 1205 #endif
1206 1206
1207 // Rebuild remembered set in an old space. 1207 // Rebuild remembered set in an old space.
(...skipping 627 matching lines...) Expand 10 before | Expand all | Expand 10 after
1835 1835
1836 // To speed up scavenge collections new space string are kept 1836 // To speed up scavenge collections new space string are kept
1837 // separate from old space strings. 1837 // separate from old space strings.
1838 static List<Object*> new_space_strings_; 1838 static List<Object*> new_space_strings_;
1839 static List<Object*> old_space_strings_; 1839 static List<Object*> old_space_strings_;
1840 }; 1840 };
1841 1841
1842 } } // namespace v8::internal 1842 } } // namespace v8::internal
1843 1843
1844 #endif // V8_HEAP_H_ 1844 #endif // V8_HEAP_H_
OLDNEW
« no previous file with comments | « no previous file | src/ia32/codegen-ia32.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698