Home | History | Annotate | Download | only in chromium-trace

Lines Matching refs:Samples

86 get guid(){return this.guid_},compareTo:function(b){return c.compare(this,b)},toJSON:function(){for(var b={},a=Object.keys(this),f=0;f<a.length;f++){var c=a[f];"function"!=typeof this[c]&&(b[c]="parent"==c?this[c].guid:this[c])}return b},addSample:function(b,a,f,c){if(this.samples_.length&&f<this.samples_[this.samples_.length-1].start)throw Error("Samples must be added in increasing timestamp order.");var d=tracing.getStringColorId(a);b=new tracing.model.Sample(b,a,d,f,c?c:{});this.samples_.push(b);
87 return b},get samples(){return this.samples_},name:void 0,shiftTimestampsForward:function(a){b.prototype.shiftTimestampsForward.call(this,a);if(this.cpuSlices)for(var f=0;f<this.cpuSlices.length;f++)this.cpuSlices[f].start+=a;if(this.samples_.length)for(f=0;f<this.samples_.length;f++)this.samples_[f].start+=a;this.kernelSlices.shiftTimestampsForward(a);this.asyncSlices.shiftTimestampsForward(a)},get isEmpty(){return this.slices.length||this.openSliceCount||this.cpuSlices&&this.cpuSlices.length||this.kernelSlices.length||
91 base.exportTo("tracing.model",function(){function d(c,a,b,f){this.guid_=tracing.GUID.allocate();this.parent=c;this.id=a;this.category=b||"";this.name=f;this.seriesNames=[];this.seriesColors=[];this.timestamps=[];this.samples=[];this.bounds=new base.Range}d.prototype={__proto__:Object.prototype,get guid(){return this.guid_},toJSON:function(){for(var c={},a=Object.keys(this),b=0;b<a.length;b++){var f=a[b];"function"!=typeof this[f]&&(c[f]="parent"==f?this[f].guid:this[f])}return c},get numSeries(){return this.seriesNames.length},
92 get numSamples(){return this.timestamps.length},getSampleValue:function(c,a){return this.samples[c*this.numSeries+a]},getSampleStatistics:function(c){c.sort();for(var a=this.numSeries,b=[],f=0;f<a;++f){for(var e=0,g=Number.MAX_VALUE,d=-Number.MAX_VALUE,h=0;h<c.length;h++)var k=c[h],e=e+this.getSampleValue(k,f),g=Math.min(this.getSampleValue(k,f),g),d=Math.max(this.getSampleValue(k,f),d);e/=c.length;h=this.getSampleValue(c[0],f);k=this.getSampleValue(c[c.length-1],f);b.push({min:g,max:d,avg:e,start:h,
93 end:k})}return b},shiftTimestampsForward:function(c){for(var a=0;a<this.timestamps.length;a++)this.timestamps[a]+=c},updateBounds:function(){if(this.seriesNames.length!=this.seriesColors.length)throw Error("seriesNames.length must match seriesColors.length");if(this.numSeries*this.numSamples!=this.samples.length)throw Error("samples.length must be a multiple of numSamples.");this.totals=[];this.maxTotal=0;this.bounds.reset();if(0!=this.samples.length){this.bounds.addValue(this.timestamps[0]);this.bounds.addValue(this.timestamps[this.timestamps.length-
94 1]);for(var c=this.numSeries,a=-Infinity,b=0;b<this.timestamps.length;b++){for(var f=0,e=0;e<c;e++)f+=this.samples[b*c+e],this.totals.push(f);f>a&&(a=f)}this.maxTotal=a}}};d.compare=function(c,a){var b=c.parent.compareTo(a);if(0!=b)return b;b=c.name.localeCompare(a.name);return 0==b?c.tid-a.tid:b};return{Counter:d}});"use strict";base.require("range");base.require("guid");base.require("model.thread");base.require("model.counter");
128 c.decorateHit=function(a){a.thread=this.thread_};c.group=this.thread_;this.addTrack_(c);this.thread_.samples.length&&(c=new tracing.tracks.SliceTrack,c.group=this.thread_,c.slices=this.thread_.samples,c.decorateHit=function(a){a.thread=this.thread_},this.addTrack_(c));this.updateVisibility_()}this.addControlButtonElements_(4<=this.tracks_.length)},updateVisibility_:function(){if(this.categoryFilter.matchThread(this.thread)){for(var c=!1,a=0;a<this.tracks_.length;++a){var b=this.tracks_[a];if(b.visible&&
170 1;w.frequency=1E3*u/k;v=0;for(k=1;k<p.slices.length;k++)x=w.frequency-1E3/(p.slices[k].start-p.slices[k-1].start),v+=x*x;w.frequency_stddev=Math.sqrt(v/(u-1))}b.appendDataRow(h,q,r,p.slices.length,w)}b.appendDataRow(h,"*Totals",d,e.length);b.appendSpacingRow(h);b.appendSummaryRowTime(h,"Selection start",l);b.appendSummaryRowTime(h,"Selection extent",t-l)}if(1==c.length){var h=c[0],e=h.counter,y=h.sampleIndex,c=[];for(k=0;k<e.numSeries;++k)c.push(e.samples[e.numSeries*y+k]);h=b.appendTable("analysis-counter-table",
199 c.id+"]":c.name;a=this.model_.getOrCreateProcess(c.pid).getOrCreateCounter(c.cat,a);if(0==a.numSeries){for(var b in c.args)a.seriesNames.push(b),a.seriesColors.push(tracing.getStringColorId(a.name+"."+b));if(0==a.numSeries){this.model_.importErrors.push("Expected counter "+c.name+" to have at least one argument to use as a value.");delete a.parent.counters[a.name];return}}a.timestamps.push(c.ts/1E3);for(var f=0;f<a.numSeries;f++)b=a.seriesNames[f],void 0===c.args[b]?a.samples.push(0):a.samples.push(c.args[b])},
208 f=1E9*f/c/1048576;b=1E9*b/c/1048576;c=this.model_.getOrCreateProcess(0).getOrCreateCounter(null,"bus "+a+" read");0==c.numSeries&&(c.seriesNames.push("value"),c.seriesColors.push(tracing.getStringColorId(c.name+".value")));c.timestamps.push(e);c.samples.push(f);c=this.model_.getOrCreateProcess(0).getOrCreateCounter(null,"bus "+a+" write");0==c.numSeries&&(c.seriesNames.push("value"),c.seriesColors.push(tracing.getStringColorId(c.name+".value")));c.timestamps.push(e);c.samples.push(b);return!0}};c.registerSubtype(d);
211 a.seriesColors.push(tracing.getStringColorId(a.name+".value")));a.timestamps.push(e);a.samples.push(b);return!0}};c.registerSubtype(d);return{ClockParser:d}});base.require("importer.linux_perf.parser");
225 a?this.exynosFlipOpenSlice(e,b):this.exynosFlipCloseSlice(e,{pipe:b});return!0},exynosBusfreqSample:function(a,b,c){a=this.importer.getOrCreateCpuState(0).cpu.getOrCreateCounter("",a);0==a.numSeries&&(a.seriesNames.push("frequency"),a.seriesColors.push(tracing.getStringColorId(a.name+".frequency")));a.timestamps.push(b);a.samples.push(c)},busfreqTargetIntEvent:function(a,b,c,e,d){a=/frequency=(\d+)/.exec(d.details);if(!a)return!1;this.exynosBusfreqSample("INT Frequency",e,parseInt(a[1]));return!0},
263 dvfsSample:function(a,b,c,e){e=parseInt(e);a=this.model_.getOrCreateProcess(0).getOrCreateCounter("DVFS",a);0==a.numSeries&&(a.seriesNames.push(b),a.seriesColors.push(tracing.getStringColorId(a.name)));a.timestamps.push(c);a.samples.push(e)},dvfsEventEvent:function(a,b,c,e,d){a=/utilization=(\d+)/.exec(d.details);if(!a)return!1;this.dvfsSample("DVFS Utilization","utilization",e,a[1]);return!0},dvfsSetClockEvent:function(a,b,c,e,d){a=/frequency=(\d+)/.exec(d.details);if(!a)return!1;this.dvfsSample("DVFS Frequency",
264 "frequency",e,a[1]);return!0},dvfsSetVoltageEvent:function(a,b,c,e,d){a=/voltage=(\d+)/.exec(d.details);if(!a)return!1;this.dvfsSample("DVFS Voltage","voltage",e,a[1]);return!0},hwcSample:function(a,b,c,e,d){d=/val=(\d+)/.exec(d.details);if(!d)return!1;d=parseInt(d[1]);a=this.model_.getOrCreateProcess(0).getOrCreateCounter(a,b);0==a.numSeries&&(a.seriesNames.push(c),a.seriesColors.push(tracing.getStringColorId(a.name)));a.timestamps.push(e);a.samples.push(d);return!0},jmSample:function(a,b,c,e){return this.hwcSample("mali:jm",
273 c,e){b=this.importer.getOrCreateCpuState(b);"1"!=c?this.importer.importError("Don't understand power_start events of type "+c):(c=b.cpu.getOrCreateCounter("","C-State"),0==c.numSeries&&(c.seriesNames.push("state"),c.seriesColors.push(tracing.getStringColorId(c.name+".state"))),c.timestamps.push(a),c.samples.push(e))},cpuIdleSlice:function(a,b,c){b=this.importer.getOrCreateCpuState(b).cpu.getOrCreateCounter("","C-State");0==b.numSeries&&(b.seriesNames.push("state"),b.seriesColors.push(tracing.getStringColorId(b.name)));
274 4294967295!=c?b.samples.push(c):b.samples.push(0);b.timestamps.push(a)},cpuFrequencySlice:function(a,b,c){b=this.importer.getOrCreateCpuState(b).cpu.getOrCreateCounter("","Clock Frequency");0==b.numSeries&&(b.seriesNames.push("state"),b.seriesColors.push(tracing.getStringColorId(b.name+".state")));b.timestamps.push(a);b.samples.push(c)},powerStartEvent:function(a,b,c,e,d){a=/type=(\d+) state=(\d) cpu_id=(\d)+/.exec(d.details);if(!a)return!1;b=parseInt(a[3]);c=parseInt(a[2]);this.cpuStateSlice(e,b,
285 l.endSlice(g);a=c(a[3]);for(h in a)void 0!==g.args[h]&&this.model_.importErrors.push("Both the B and E events of "+g.title+"provided values for argument "+h+". The value of the E event will be used."),g.args[h]=a[h];break;case "C":d=parseInt(a[1]);j=a[2];e=parseInt(a[3]);h=a[4];a=this.model_.getOrCreateProcess(d).getOrCreateCounter(h,j);0==a.numSeries&&(a.seriesNames.push("value"),a.seriesColors.push(tracing.getStringColorId(a.name+".value")));a.timestamps.push(g);a.samples.push(e);break;default:return!1}return!0}};