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

Side by Side Diff: include/v8-profiler.h

Issue 22852024: Track JS allocations as they arrive with no affection on performance when tracking is switched off (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Make separate API for JS allocations recording, add example of checking JS allocations recording in… Created 7 years, 3 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 | « no previous file | src/api.cc » ('j') | src/assembler.cc » ('J')
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2010 the V8 project authors. All rights reserved. 1 // Copyright 2010 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 465 matching lines...) Expand 10 before | Expand all | Expand 10 after
476 static const uint16_t kPersistentHandleNoClassId = 0; 476 static const uint16_t kPersistentHandleNoClassId = 0;
477 477
478 /** Returns memory used for profiler internal data and snapshots. */ 478 /** Returns memory used for profiler internal data and snapshots. */
479 size_t GetProfilerMemorySize(); 479 size_t GetProfilerMemorySize();
480 480
481 /** 481 /**
482 * Sets a RetainedObjectInfo for an object group (see V8::SetObjectGroupId). 482 * Sets a RetainedObjectInfo for an object group (see V8::SetObjectGroupId).
483 */ 483 */
484 void SetRetainedObjectInfo(UniqueId id, RetainedObjectInfo* info); 484 void SetRetainedObjectInfo(UniqueId id, RetainedObjectInfo* info);
485 485
486 /**
487 * Starts recording JS allocations immediately as they arrive
488 * and tracking of heap objects population statistics.
489 */
490 void StartRecordingHeapAllocations();
491
492 /**
493 * Stops recording JS allocations and tracking of heap objects
494 * population statistics, cleans all collected heap objects
495 * population statistics data.
496 */
497 void StopRecordingHeapAllocations();
498
499
486 private: 500 private:
487 HeapProfiler(); 501 HeapProfiler();
488 ~HeapProfiler(); 502 ~HeapProfiler();
489 HeapProfiler(const HeapProfiler&); 503 HeapProfiler(const HeapProfiler&);
490 HeapProfiler& operator=(const HeapProfiler&); 504 HeapProfiler& operator=(const HeapProfiler&);
491 }; 505 };
492 506
493 507
494 /** 508 /**
495 * Interface for providing information about embedder's objects 509 * Interface for providing information about embedder's objects
(...skipping 79 matching lines...) Expand 10 before | Expand all | Expand 10 after
575 uint32_t index; // Index of the time interval that was changed. 589 uint32_t index; // Index of the time interval that was changed.
576 uint32_t count; // New value of count field for the interval with this index. 590 uint32_t count; // New value of count field for the interval with this index.
577 uint32_t size; // New value of size field for the interval with this index. 591 uint32_t size; // New value of size field for the interval with this index.
578 }; 592 };
579 593
580 594
581 } // namespace v8 595 } // namespace v8
582 596
583 597
584 #endif // V8_V8_PROFILER_H_ 598 #endif // V8_V8_PROFILER_H_
OLDNEW
« no previous file with comments | « no previous file | src/api.cc » ('j') | src/assembler.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698