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

Unified Diff: tracing/tracing/model/global_memory_dump.html

Issue 1744563002: [memory-infra] Move 'infos' field from Attribute to MemoryAllocatorDump (Closed) Base URL: git@github.com:catapult-project/catapult.git@master
Patch Set: Address Primiano's comment Created 4 years, 10 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « tracing/tracing/model/attribute_test.html ('k') | tracing/tracing/model/global_memory_dump_test.html » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tracing/tracing/model/global_memory_dump.html
diff --git a/tracing/tracing/model/global_memory_dump.html b/tracing/tracing/model/global_memory_dump.html
index 089514e25d095451788056f402625fda9c0aff8c..c4480956d39810e487e4add7b45113465e1d39fc 100644
--- a/tracing/tracing/model/global_memory_dump.html
+++ b/tracing/tracing/model/global_memory_dump.html
@@ -36,11 +36,11 @@ tr.exportTo('tr.model', function() {
tr.model.MemoryAllocatorDump.EFFECTIVE_SIZE_ATTRIBUTE_NAME;
// Size attribute info types.
- var SizeAttributeInfoType = tr.model.SizeAttributeInfoType;
+ var MemoryAllocatorDumpInfoType = tr.model.MemoryAllocatorDumpInfoType;
var PROVIDED_SIZE_LESS_THAN_AGGREGATED_CHILDREN =
- SizeAttributeInfoType.PROVIDED_SIZE_LESS_THAN_AGGREGATED_CHILDREN;
+ MemoryAllocatorDumpInfoType.PROVIDED_SIZE_LESS_THAN_AGGREGATED_CHILDREN;
var PROVIDED_SIZE_LESS_THAN_LARGEST_OWNER =
- SizeAttributeInfoType.PROVIDED_SIZE_LESS_THAN_LARGEST_OWNER;
+ MemoryAllocatorDumpInfoType.PROVIDED_SIZE_LESS_THAN_LARGEST_OWNER;
// TODO(petrcermak): Move this to tracing/base/iteration_helpers.html.
function inPlaceFilter(array, predicate, opt_this) {
@@ -220,7 +220,6 @@ tr.exportTo('tr.model', function() {
var sizeAttribute = dump.getValidSizeAttributeOrUndefined(
SIZE_ATTRIBUTE_NAME, this.model);
var size = 0;
- var infos = [];
var checkDependencySizeIsConsistent = function() { /* no-op */ };
if (sizeAttribute !== undefined) {
size = sizeAttribute.value;
@@ -237,7 +236,7 @@ tr.exportTo('tr.model', function() {
') is less than ' + dependencyName + ' (' +
tr.v.Unit.byName.sizeInBytes.format(dependencySize) + ').'
});
- infos.push({
+ dump.infos.push({
type: dependencyInfoType,
providedSize: size,
dependencySize: dependencySize
@@ -323,9 +322,8 @@ tr.exportTo('tr.model', function() {
// together and/or its largest owner.
size = Math.max(size, aggregatedChildrenSize, largestOwnerSize);
- var sizeAttribute = new tr.model.ScalarAttribute('bytes', size);
- sizeAttribute.infos = infos;
- dump.attributes[SIZE_ATTRIBUTE_NAME] = sizeAttribute;
+ dump.attributes[SIZE_ATTRIBUTE_NAME] =
+ new tr.model.ScalarAttribute('bytes', size);
// Add a virtual child to make up for extra size of the dump with
// respect to its children (if applicable).
@@ -728,7 +726,7 @@ tr.exportTo('tr.model', function() {
// allocator dumps.
return;
}
- processAllocatorDump.attributes[attrName] = attr.cloneWithInfos();
+ processAllocatorDump.attributes[attrName] = attr;
});
});
// Recursively propagate attributes from all child memory allocator dumps.
« no previous file with comments | « tracing/tracing/model/attribute_test.html ('k') | tracing/tracing/model/global_memory_dump_test.html » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698