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

Side by Side Diff: src/objects.h

Issue 40003002: Add support for tracking NotExectuted/ExecutedOnceCodeAge's when --track_gc_object_stats flag is se… (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 7 years, 1 month 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
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 5286 matching lines...) Expand 10 before | Expand all | Expand 10 after
5297 5297
5298 BailoutId TranslatePcOffsetToAstId(uint32_t pc_offset); 5298 BailoutId TranslatePcOffsetToAstId(uint32_t pc_offset);
5299 5299
5300 #define DECLARE_CODE_AGE_ENUM(X) k##X##CodeAge, 5300 #define DECLARE_CODE_AGE_ENUM(X) k##X##CodeAge,
5301 enum Age { 5301 enum Age {
5302 kNotExecutedCodeAge = -2, 5302 kNotExecutedCodeAge = -2,
5303 kExecutedOnceCodeAge = -1, 5303 kExecutedOnceCodeAge = -1,
5304 kNoAgeCodeAge = 0, 5304 kNoAgeCodeAge = 0,
5305 CODE_AGE_LIST(DECLARE_CODE_AGE_ENUM) 5305 CODE_AGE_LIST(DECLARE_CODE_AGE_ENUM)
5306 kAfterLastCodeAge, 5306 kAfterLastCodeAge,
5307 kFirstCodeAge = kNotExecutedCodeAge,
5307 kLastCodeAge = kAfterLastCodeAge - 1, 5308 kLastCodeAge = kAfterLastCodeAge - 1,
5308 kCodeAgeCount = kAfterLastCodeAge - 1, 5309 kCodeAgeCount = kAfterLastCodeAge - kNotExecutedCodeAge - 1,
5309 kIsOldCodeAge = kSexagenarianCodeAge, 5310 kIsOldCodeAge = kSexagenarianCodeAge,
5310 kPreAgedCodeAge = kIsOldCodeAge - 1 5311 kPreAgedCodeAge = kIsOldCodeAge - 1
5311 }; 5312 };
5312 #undef DECLARE_CODE_AGE_ENUM 5313 #undef DECLARE_CODE_AGE_ENUM
5313 5314
5314 // Code aging. Indicates how many full GCs this code has survived without 5315 // Code aging. Indicates how many full GCs this code has survived without
5315 // being entered through the prologue. Used to determine when it is 5316 // being entered through the prologue. Used to determine when it is
5316 // relatively safe to flush this code object and replace it with the lazy 5317 // relatively safe to flush this code object and replace it with the lazy
5317 // compilation stub. 5318 // compilation stub.
5318 static void MakeCodeAgeSequenceYoung(byte* sequence, Isolate* isolate); 5319 static void MakeCodeAgeSequenceYoung(byte* sequence, Isolate* isolate);
5319 static void MarkCodeAsExecuted(byte* sequence, Isolate* isolate); 5320 static void MarkCodeAsExecuted(byte* sequence, Isolate* isolate);
5320 void MakeOlder(MarkingParity); 5321 void MakeOlder(MarkingParity);
5321 static bool IsYoungSequence(byte* sequence); 5322 static bool IsYoungSequence(byte* sequence);
5322 bool IsOld(); 5323 bool IsOld();
5323 Age GetAge(); 5324 Age GetAge();
5325 // Gets the raw code age, including psuedo code-age values such as
5326 // kNotExecutedCodeAge and kExecutedOnceCodeAge.
5327 Age GetRawAge();
5324 static inline Code* GetPreAgedCodeAgeStub(Isolate* isolate) { 5328 static inline Code* GetPreAgedCodeAgeStub(Isolate* isolate) {
5325 return GetCodeAgeStub(isolate, kNotExecutedCodeAge, NO_MARKING_PARITY); 5329 return GetCodeAgeStub(isolate, kNotExecutedCodeAge, NO_MARKING_PARITY);
5326 } 5330 }
5327 5331
5328 void PrintDeoptLocation(int bailout_id); 5332 void PrintDeoptLocation(int bailout_id);
5329 bool CanDeoptAt(Address pc); 5333 bool CanDeoptAt(Address pc);
5330 5334
5331 #ifdef VERIFY_HEAP 5335 #ifdef VERIFY_HEAP
5332 void VerifyEmbeddedObjectsDependency(); 5336 void VerifyEmbeddedObjectsDependency();
5333 #endif 5337 #endif
(...skipping 5093 matching lines...) Expand 10 before | Expand all | Expand 10 after
10427 } else { 10431 } else {
10428 value &= ~(1 << bit_position); 10432 value &= ~(1 << bit_position);
10429 } 10433 }
10430 return value; 10434 return value;
10431 } 10435 }
10432 }; 10436 };
10433 10437
10434 } } // namespace v8::internal 10438 } } // namespace v8::internal
10435 10439
10436 #endif // V8_OBJECTS_H_ 10440 #endif // V8_OBJECTS_H_
OLDNEW
« no previous file with comments | « src/mark-compact.cc ('k') | src/objects.cc » ('j') | src/objects.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698