window.FLATTENED={};window.FLATTENED_RAW_SCRIPTS={};window.FLATTENED.base=!0;window.FLATTENED["tracing.color_scheme"]=!0;window.FLATTENED["tracing.importer.linux_perf.parser"]=!0;window.FLATTENED["base.guid"]=!0;window.FLATTENED["tracing.trace_model.counter_series"]=!0;window.FLATTENED["tracing.importer.linux_perf.android_parser"]=!0;window.FLATTENED["tracing.importer.linux_perf.bus_parser"]=!0;window.FLATTENED["tracing.importer.linux_perf.clock_parser"]=!0; window.FLATTENED["tracing.importer.linux_perf.cpufreq_parser"]=!0;window.FLATTENED["tracing.importer.linux_perf.disk_parser"]=!0;window.FLATTENED["tracing.importer.linux_perf.drm_parser"]=!0;window.FLATTENED["tracing.importer.linux_perf.exynos_parser"]=!0;window.FLATTENED["tracing.importer.linux_perf.gesture_parser"]=!0;window.FLATTENED["tracing.importer.linux_perf.i915_parser"]=!0;window.FLATTENED["tracing.importer.linux_perf.irq_parser"]=!0; window.FLATTENED["tracing.importer.linux_perf.kfunc_parser"]=!0;window.FLATTENED["tracing.importer.linux_perf.mali_parser"]=!0;window.FLATTENED["tracing.importer.linux_perf.memreclaim_parser"]=!0;window.FLATTENED["tracing.importer.linux_perf.power_parser"]=!0;window.FLATTENED["tracing.importer.linux_perf.sched_parser"]=!0;window.FLATTENED["tracing.importer.linux_perf.sync_parser"]=!0;window.FLATTENED["tracing.importer.linux_perf.workqueue_parser"]=!0;window.FLATTENED["base.event_target"]=!0; window.FLATTENED["base.events"]=!0;window.FLATTENED["base.range"]=!0;window.FLATTENED["tracing.filter"]=!0;window.FLATTENED["tracing.trace_model.counter"]=!0;window.FLATTENED["tracing.trace_model.trace_model_event"]=!0;window.FLATTENED["tracing.trace_model.slice"]=!0;window.FLATTENED["tracing.trace_model.cpu"]=!0;window.FLATTENED["base.sorted_array_utils"]=!0;window.FLATTENED["base.iteration_helpers"]=!0;window.FLATTENED["base.utils"]=!0;window.FLATTENED["tracing.trace_model.object_snapshot"]=!0; window.FLATTENED["tracing.trace_model.object_instance"]=!0;window.FLATTENED["tracing.trace_model.time_to_object_instance_map"]=!0;window.FLATTENED["tracing.trace_model.object_collection"]=!0;window.FLATTENED["tracing.trace_model.async_slice"]=!0;window.FLATTENED["tracing.trace_model.async_slice_group"]=!0;window.FLATTENED["tracing.trace_model.sample"]=!0;window.FLATTENED["tracing.trace_model.slice_group"]=!0;window.FLATTENED["tracing.trace_model.thread"]=!0;window.FLATTENED["base.settings"]=!0; window.FLATTENED["tracing.trace_model_settings"]=!0;window.FLATTENED["tracing.trace_model.process_base"]=!0;window.FLATTENED["tracing.trace_model.kernel"]=!0;window.FLATTENED["tracing.trace_model.process"]=!0;window.FLATTENED["tracing.trace_model"]=!0;window.FLATTENED["tracing.importer.linux_perf_importer"]=!0;window.FLATTENED_RAW_SCRIPTS["../third_party/gl-matrix/src/gl-matrix/common.js"]=!0;window.FLATTENED_RAW_SCRIPTS["../third_party/gl-matrix/src/gl-matrix/mat2d.js"]=!0; window.FLATTENED_RAW_SCRIPTS["../third_party/gl-matrix/src/gl-matrix/mat4.js"]=!0;window.FLATTENED_RAW_SCRIPTS["../third_party/gl-matrix/src/gl-matrix/vec2.js"]=!0;window.FLATTENED_RAW_SCRIPTS["../third_party/gl-matrix/src/gl-matrix/vec3.js"]=!0;window.FLATTENED_RAW_SCRIPTS["../third_party/gl-matrix/src/gl-matrix/vec4.js"]=!0;window.FLATTENED["base.gl_matrix"]=!0;window.FLATTENED["base.quad"]=!0;window.FLATTENED["tracing.trace_model.instant_event"]=!0; window.FLATTENED["tracing.importer.trace_event_importer"]=!0;window.FLATTENED["tracing.importer.v8.splaytree"]=!0;window.FLATTENED["tracing.importer.v8.codemap"]=!0;window.FLATTENED["tracing.importer.v8.log_reader"]=!0;window.FLATTENED["tracing.importer.v8_log_importer"]=!0;window.FLATTENED["tracing.importer"]=!0;window.FLATTENED["tracing.analysis.util"]=!0;window.FLATTENED["tracing.selection"]=!0;window.FLATTENED.ui=!0;window.FLATTENED["tracing.analysis.analysis_link"]=!0; window.FLATTENED["tracing.analysis.generic_object_view"]=!0;window.FLATTENED["tracing.analysis.analysis_results"]=!0;window.FLATTENED["tracing.analysis.analyze_counters"]=!0;window.FLATTENED["tracing.analysis.analyze_slices"]=!0;window.FLATTENED["tracing.analysis.analyze_selection"]=!0;window.FLATTENED["tracing.analysis.object_instance_view"]=!0;window.FLATTENED["tracing.analysis.object_snapshot_view"]=!0;window.FLATTENED["tracing.analysis.default_object_view"]=!0; window.FLATTENED["tracing.analysis.slice_view"]=!0;window.FLATTENED["tracing.analysis.analysis_view"]=!0;window.FLATTENED["base.properties"]=!0;window.FLATTENED["ui.overlay"]=!0;window.FLATTENED["tracing.category_filter_dialog"]=!0;window.FLATTENED["tracing.mouse_mode_constants"]=!0;window.FLATTENED["tracing.timeline_viewport"]=!0;window.FLATTENED["base.raf"]=!0;window.FLATTENED["ui.container_that_decorates_its_children"]=!0;window.FLATTENED["tracing.tracks.track"]=!0; window.FLATTENED["tracing.tracks.drawing_container"]=!0;window.FLATTENED["tracing.constants"]=!0;window.FLATTENED["tracing.tracks.heading_track"]=!0;window.FLATTENED["tracing.tracks.ruler_track"]=!0;window.FLATTENED["base.measuring_stick"]=!0;window.FLATTENED["tracing.tracks.container_track"]=!0;window.FLATTENED["tracing.fast_rect_renderer"]=!0;window.FLATTENED["tracing.tracks.slice_track"]=!0;window.FLATTENED["tracing.tracks.cpu_track"]=!0; window.FLATTENED["tracing.tracks.object_instance_track"]=!0;window.FLATTENED["tcmalloc.heap_instance_track"]=!0;window.FLATTENED["tracing.tracks.counter_track"]=!0;window.FLATTENED["tracing.tracks.spacing_track"]=!0;window.FLATTENED["tracing.tracks.slice_group_track"]=!0;window.FLATTENED["tracing.tracks.async_slice_group_track"]=!0;window.FLATTENED["tracing.tracks.thread_track"]=!0;window.FLATTENED["ui.dom_helpers"]=!0;window.FLATTENED["tracing.tracks.process_track_base"]=!0; window.FLATTENED["tracing.tracks.kernel_track"]=!0;window.FLATTENED["tracing.tracks.process_track"]=!0;window.FLATTENED["tracing.tracks.trace_model_track"]=!0;window.FLATTENED["ui.mouse_mode_selector"]=!0;window.FLATTENED["tracing.timeline_track_view"]=!0;window.FLATTENED["tracing.find_control"]=!0;window.FLATTENED["ui.drag_handle"]=!0;window.FLATTENED["tracing.timeline_view"]=!0;window.FLATTENED["tracing.standalone_timeline_view"]=!0; var templateData_=window.atob("PCEtLQpDb3B5cmlnaHQgKGMpIDIwMTMgVGhlIENocm9taXVtIEF1dGhvcnMuIEFsbCByaWdodHMgcmVzZXJ2ZWQuClVzZSBvZiB0aGlzIHNvdXJjZSBjb2RlIGlzIGdvdmVybmVkIGJ5IGEgQlNELXN0eWxlIGxpY2Vuc2UgdGhhdCBjYW4gYmUKZm91bmQgaW4gdGhlIExJQ0VOU0UgZmlsZS4KLS0+Cgo8dGVtcGxhdGUgaWQ9InJlY29yZC1zZWxlY3Rpb24tZGlhbG9nLXRlbXBsYXRlIj4KICA8ZGl2IGNsYXNzPSJyZWNvcmQtc2VsZWN0aW9uLWRpYWxvZyI+CiAgICA8Zm9ybT4KICAgICAgPHRhYmxlPgogICAgICAgIDx0cj4KICAgICAgICAgIDx0ZCBjbGFzcz0iZGVmYXVsdC1lbmFibGVkLWNhdGVnb3JpZXMiPgogICAgICAgICAgICA8ZGl2PlJlY29yZCZuYnNwO0NhdGVnb3JpZXM8L2Rpdj4KICAgICAgICAgICAgPGRpdiBjbGFzcz0iZ3JvdXAtc2VsZWN0b3JzIj4KICAgICAgICAgICAgICBTZWxlY3QKICAgICAgICAgICAgICA8YnV0dG9uIGNsYXNzPSJhbGwtYnRuIj5BbGw8L2J1dHRvbj4KICAgICAgICAgICAgICA8YnV0dG9uIGNsYXNzPSJub25lLWJ0biI+Tm9uZTwvYnV0dG9uPgogICAgICAgICAgICA8L2Rpdj4KICAgICAgICAgICAgPGRpdiBjbGFzcz0iY2F0ZWdvcmllcyI+PC9kaXY+CiAgICAgICAgICA8L3RkPgogICAgICAgICAgPHRkIGNsYXNzPSJkZWZhdWx0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N0b3ItdGVtcGxhdGUiPgogIDxkaXYgY2xhc3M9ImRyYWctaGFuZGxlIj48L2Rpdj4KICA8ZGl2IGNsYXNzPSJidXR0b25zIj4KICAgIDxkaXYgY2xhc3M9InBhbi1zY2FuLW1vZGUtYnV0dG9uIHRvb2wtYnV0dG9uIj48L2Rpdj4KICAgIDxkaXYgY2xhc3M9InNlbGVjdGlvbi1tb2RlLWJ1dHRvbiB0b29sLWJ1dHRvbiI+PC9kaXY+CiAgICA8ZGl2IGNsYXNzPSJ6b29tLW1vZGUtYnV0dG9uIHRvb2wtYnV0dG9uIj48L2Rpdj4KICA8L2Rpdj4KPC90ZW1wbGF0ZT4K"),templateElem_= document.createElement("div");for(templateElem_.innerHTML=templateData_;templateElem_.hasChildNodes();)document.head.appendChild(templateElem_.removeChild(templateElem_.firstChild));"use strict";var global=this; this.base=function(){function d(a){"/"==a[a.length-1]&&(a=a.substring(0,a.length-1));l=a}function b(a,c){n[a]||(n[a]=[]);for(var e=n[a],f=!1,b=0;b\w+), write=(\w+=>\w+)/.exec(g.details);if(!c)return!1;e=c[1];this.i915GemObjectSlice(b,a,e,{obj:e,read:c[2],write:c[3]});return!0},gemObjectPreadWriteEvent:function(a,c,e,b,g){g=/obj=(\w+), offset=(\d+), len=(\d+)/.exec(g.details);if(!g)return!1;c=g[1];e=parseInt(g[2]);g=parseInt(g[3]);this.i915GemObjectSlice(b,a,c,{obj:c,offset:e,len:g});return!0},gemObjectFaultEvent:function(a,c,e,b,g){g=/obj=(\w+), (\w+) index=(\d+)/.exec(g.details); if(!g)return!1;c=g[1];e=g[2];g=parseInt(g[3]);this.i915GemObjectSlice(b,a,c,{obj:c,type:e,index:g});return!0},gemObjectDestroyEvent:function(a,c,e,b,g){c=/obj=(\w+)/.exec(g.details);if(!c)return!1;c=c[1];this.i915GemObjectSlice(b,a,c,{obj:c});return!0},gemRingDispatchEvent:function(a,c,e,b,g){g=/dev=(\d+), ring=(\d+), seqno=(\d+)/.exec(g.details);if(!g)return!1;c=parseInt(g[1]);e=parseInt(g[2]);g=parseInt(g[3]);this.i915GemRingSlice(b,a,c,e,{dev:c,ring:e,seqno:g});return!0},gemRingFlushEvent:function(a, c,e,b,g){c=/dev=(\d+), ring=(\w+), invalidate=(\w+), flush=(\w+)/.exec(g.details);if(!c)return!1;e=parseInt(c[1]);g=parseInt(c[2]);this.i915GemRingSlice(b,a,e,g,{dev:e,ring:g,invalidate:c[3],flush:c[4]});return!0},gemRequestEvent:function(a,c,e,b,g){g=/dev=(\d+), ring=(\d+), seqno=(\d+)/.exec(g.details);if(!g)return!1;c=parseInt(g[1]);e=parseInt(g[2]);g=parseInt(g[3]);this.i915GemRingSlice(b,a,c,e,{dev:c,ring:e,seqno:g});return!0},gemRingWaitEvent:function(a,c,e,b,g){e=/dev=(\d+), ring=(\d+)/.exec(g.details); if(!e)return!1;c=parseInt(e[1]);e=parseInt(e[2]);this.i915GemRingSlice(b,a,c,e,{dev:c,ring:e});return!0},regRWEvent:function(a,c,e,b,g){a=/(\w+) reg=(\w+), len=(\d+), val=(\(\w+, \w+\))/.exec(g.details);if(!a)return!1;c=a[1];e=a[2];this.i915RegSlice(b,c,e,{rw:c,reg:e,len:a[3],data:a[3]});return!0},flipEvent:function(a,c,e,b,g){e=/plane=(\d+), obj=(\w+)/.exec(g.details);if(!e)return!1;c=parseInt(e[1]);e=e[2];"i915_flip_request"==a?this.i915FlipOpenSlice(b,e,c):this.i915FlipCloseSlice(b,{obj:e,plane:c}); return!0}};b.registerSubtype(d);return{I915Parser:d}});"use strict";base.require("tracing.importer.linux_perf.parser"); base.exportTo("tracing.importer.linux_perf",function(){function d(a){b.call(this,a);a.registerEventHandler("irq_handler_entry",d.prototype.irqHandlerEntryEvent.bind(this));a.registerEventHandler("irq_handler_exit",d.prototype.irqHandlerExitEvent.bind(this));a.registerEventHandler("softirq_raise",d.prototype.softirqRaiseEvent.bind(this));a.registerEventHandler("softirq_entry",d.prototype.softirqEntryEvent.bind(this));a.registerEventHandler("softirq_exit",d.prototype.softirqExitEvent.bind(this))}var b= tracing.importer.linux_perf.Parser,a=/irq=(\d+) name=(.+)/,c=/irq=(\d+) ret=(.+)/,e=/vec=(\d+) \[action=(.+)\]/;d.prototype={__proto__:b.prototype,irqHandlerEntryEvent:function(c,e,b,d,l){c=a.exec(l.details);if(!c)return!1;parseInt(c[1]);c=c[2];e=this.importer.getOrCreatePseudoThread("irqs cpu "+e);e.lastEntryTs=d;e.irqName=c;return!0},irqHandlerExitEvent:function(a,e,b,d,l){a=c.exec(l.details);if(!a)return!1;parseInt(a[1]);b=a[2];e=this.importer.getOrCreatePseudoThread("irqs cpu "+e);void 0!==e.lastEntryTs&& (d-=e.lastEntryTs,d=new tracing.trace_model.Slice("",e.irqName,tracing.getStringColorId(a[1]),e.lastEntryTs,{ret:b},d),e.thread.sliceGroup.pushSlice(d));e.lastEntryTs=void 0;e.irqName=void 0;return!0},softirqRaiseEvent:function(a,c,e,b,d){return!0},softirqEntryEvent:function(a,c,b,d,l){if(!e.exec(l.details))return!1;this.importer.getOrCreatePseudoThread("softirq cpu "+c).lastEntryTs=d;return!0},softirqExitEvent:function(a,c,b,d,l){a=e.exec(l.details);if(!a)return!1;b=parseInt(a[1]);l=a[2];c=this.importer.getOrCreatePseudoThread("softirq cpu "+ c);void 0!==c.lastEntryTs&&(d-=c.lastEntryTs,d=new tracing.trace_model.Slice("",l,tracing.getStringColorId(a[1]),c.lastEntryTs,{vec:b},d),c.thread.sliceGroup.pushSlice(d));c.lastEntryTs=void 0;return!0}};b.registerSubtype(d);return{IrqParser:d}});"use strict";base.require("tracing.importer.linux_perf.parser"); base.exportTo("tracing.importer.linux_perf",function(){function d(a){b.call(this,a);a.registerEventHandler("graph_ent",d.prototype.traceKernelFuncEnterEvent.bind(this));a.registerEventHandler("graph_ret",d.prototype.traceKernelFuncReturnEvent.bind(this));this.model_=a.model_;this.ppids_={}}var b=tracing.importer.linux_perf.Parser,a=/func=(.+)/;d.prototype={__proto__:b.prototype,traceKernelFuncEnterEvent:function(c,e,b,g,h){c=a.exec(h.details);if(!c||void 0===h.tgid)return!1;e=parseInt(h.tgid);c=c[1]; b=this.model_.getOrCreateProcess(e).getOrCreateThread(b);b.name=h.threadName;h=b.kernelSliceGroup;if(!h.isTimestampValidForBeginOrEnd(g))return this.model_.importErrors.push("Timestamps are moving backward."),!1;h.beginSlice(null,c,g,{});return!0},traceKernelFuncReturnEvent:function(a,e,b,g,h){if(void 0===h.tgid)return!1;a=parseInt(h.tgid);b=this.model_.getOrCreateProcess(a).getOrCreateThread(b);b.name=h.threadName;h=b.kernelSliceGroup;if(!h.isTimestampValidForBeginOrEnd(g))return this.model_.importErrors.push("Timestamps are moving backward."), !1;0c;c++){var e="JS"+c,f="mali_hwc_"+e;this.addJMCounter(f+"_JOBS",e+" Jobs");this.addJMCounter(f+"_TASKS",e+" Tasks");this.addJMCycles(f+"_ACTIVE",e+" Active");this.addJMCycles(f+"_WAIT_READ",e+" Wait Read");this.addJMCycles(f+"_WAIT_ISSUE",e+" Wait Issue");this.addJMCycles(f+"_WAIT_DEPEND",e+" Wait Depend");this.addJMCycles(f+"_WAIT_FINISH",e+" Wait Finish")}this.addTilerCounter("mali_hwc_TRIANGLES","Triangles");this.addTilerCounter("mali_hwc_QUADS", "Quads");this.addTilerCounter("mali_hwc_POLYGONS","Polygons");this.addTilerCounter("mali_hwc_POINTS","Points");this.addTilerCounter("mali_hwc_LINES","Lines");this.addTilerCounter("mali_hwc_VCACHE_HIT","VCache Hit");this.addTilerCounter("mali_hwc_VCACHE_MISS","VCache Miss");this.addTilerCounter("mali_hwc_FRONT_FACING","Front Facing");this.addTilerCounter("mali_hwc_BACK_FACING","Back Facing");this.addTilerCounter("mali_hwc_PRIM_VISIBLE","Prim Visible");this.addTilerCounter("mali_hwc_PRIM_CULLED","Prim Culled"); this.addTilerCounter("mali_hwc_PRIM_CLIPPED","Prim Clipped");this.addTilerCounter("mali_hwc_WRBUF_HIT","Wrbuf Hit");this.addTilerCounter("mali_hwc_WRBUF_MISS","Wrbuf Miss");this.addTilerCounter("mali_hwc_WRBUF_LINE","Wrbuf Line");this.addTilerCounter("mali_hwc_WRBUF_PARTIAL","Wrbuf Partial");this.addTilerCounter("mali_hwc_WRBUF_STALL","Wrbuf Stall");this.addTilerCycles("mali_hwc_ACTIVE","Tiler Active");this.addTilerCycles("mali_hwc_INDEX_WAIT","Index Wait");this.addTilerCycles("mali_hwc_INDEX_RANGE_WAIT", "Index Range Wait");this.addTilerCycles("mali_hwc_VERTEX_WAIT","Vertex Wait");this.addTilerCycles("mali_hwc_PCACHE_WAIT","Pcache Wait");this.addTilerCycles("mali_hwc_WRBUF_WAIT","Wrbuf Wait");this.addTilerCycles("mali_hwc_BUS_READ","Bus Read");this.addTilerCycles("mali_hwc_BUS_WRITE","Bus Write");this.addTilerCycles("mali_hwc_TILER_UTLB_STALL","Tiler UTLB Stall");this.addTilerCycles("mali_hwc_TILER_UTLB_HIT","Tiler UTLB Hit");this.addFragCycles("mali_hwc_FRAG_ACTIVE","Active");this.addFragCounter("mali_hwc_FRAG_PRIMATIVES", "Primitives");this.addFragCounter("mali_hwc_FRAG_PRIMATIVES_DROPPED","Primitives Dropped");this.addFragCycles("mali_hwc_FRAG_CYCLE_DESC","Descriptor Processing");this.addFragCycles("mali_hwc_FRAG_CYCLES_PLR","PLR Processing??");this.addFragCycles("mali_hwc_FRAG_CYCLES_VERT","Vertex Processing");this.addFragCycles("mali_hwc_FRAG_CYCLES_TRISETUP","Triangle Setup");this.addFragCycles("mali_hwc_FRAG_CYCLES_RAST","Rasterization???");this.addFragCounter("mali_hwc_FRAG_THREADS","Threads");this.addFragCounter("mali_hwc_FRAG_DUMMY_THREADS", "Dummy Threads");this.addFragCounter("mali_hwc_FRAG_QUADS_RAST","Quads Rast");this.addFragCounter("mali_hwc_FRAG_QUADS_EZS_TEST","Quads EZS Test");this.addFragCounter("mali_hwc_FRAG_QUADS_EZS_KILLED","Quads EZS Killed");this.addFragCounter("mali_hwc_FRAG_QUADS_LZS_TEST","Quads LZS Test");this.addFragCounter("mali_hwc_FRAG_QUADS_LZS_KILLED","Quads LZS Killed");this.addFragCycles("mali_hwc_FRAG_CYCLE_NO_TILE","No Tiles");this.addFragCounter("mali_hwc_FRAG_NUM_TILES","Tiles");this.addFragCounter("mali_hwc_FRAG_TRANS_ELIM", "Transactions Eliminated");this.addComputeCycles("mali_hwc_COMPUTE_ACTIVE","Active");this.addComputeCounter("mali_hwc_COMPUTE_TASKS","Tasks");this.addComputeCounter("mali_hwc_COMPUTE_THREADS","Threads Started");this.addComputeCycles("mali_hwc_COMPUTE_CYCLES_DESC","Waiting for Descriptors");this.addTripipeCycles("mali_hwc_TRIPIPE_ACTIVE","Active");this.addArithCounter("mali_hwc_ARITH_WORDS","Instructions (/Pipes)");this.addArithCycles("mali_hwc_ARITH_CYCLES_REG","Reg scheduling stalls (/Pipes)");this.addArithCycles("mali_hwc_ARITH_CYCLES_L0", "L0 cache miss stalls (/Pipes)");this.addArithCounter("mali_hwc_ARITH_FRAG_DEPEND","Frag dep check failures (/Pipes)");this.addLSCounter("mali_hwc_LS_WORDS","Instruction Words Completed");this.addLSCounter("mali_hwc_LS_ISSUES","Full Pipeline Issues");this.addLSCounter("mali_hwc_LS_RESTARTS","Restarts (unpairable insts)");this.addLSCounter("mali_hwc_LS_REISSUES_MISS","Pipeline reissue (cache miss/uTLB)");this.addLSCounter("mali_hwc_LS_REISSUES_VD","Pipeline reissue (varying data)");this.addLSCounter("mali_hwc_LS_REISSUE_ATTRIB_MISS", "Pipeline reissue (attribute cache miss)");this.addLSCounter("mali_hwc_LS_REISSUE_NO_WB","Writeback not used");this.addTexCounter("mali_hwc_TEX_WORDS","Words");this.addTexCounter("mali_hwc_TEX_BUBBLES","Bubbles");this.addTexCounter("mali_hwc_TEX_WORDS_L0","Words L0");this.addTexCounter("mali_hwc_TEX_WORDS_DESC","Words Desc");this.addTexCounter("mali_hwc_TEX_THREADS","Threads");this.addTexCounter("mali_hwc_TEX_RECIRC_FMISS","Recirc due to Full Miss");this.addTexCounter("mali_hwc_TEX_RECIRC_DESC","Recirc due to Desc Miss"); this.addTexCounter("mali_hwc_TEX_RECIRC_MULTI","Recirc due to Multipass");this.addTexCounter("mali_hwc_TEX_RECIRC_PMISS","Recirc due to Partial Cache Miss");this.addTexCounter("mali_hwc_TEX_RECIRC_CONF","Recirc due to Cache Conflict");this.addLSCCounter("mali_hwc_LSC_READ_HITS","Read Hits");this.addLSCCounter("mali_hwc_LSC_READ_MISSES","Read Misses");this.addLSCCounter("mali_hwc_LSC_WRITE_HITS","Write Hits");this.addLSCCounter("mali_hwc_LSC_WRITE_MISSES","Write Misses");this.addLSCCounter("mali_hwc_LSC_ATOMIC_HITS", "Atomic Hits");this.addLSCCounter("mali_hwc_LSC_ATOMIC_MISSES","Atomic Misses");this.addLSCCounter("mali_hwc_LSC_LINE_FETCHES","Line Fetches");this.addLSCCounter("mali_hwc_LSC_DIRTY_LINE","Dirty Lines");this.addLSCCounter("mali_hwc_LSC_SNOOPS","Snoops");this.addAXICounter("mali_hwc_AXI_TLB_STALL","Address channel stall");this.addAXICounter("mali_hwc_AXI_TLB_MISS","Cache Miss");this.addAXICounter("mali_hwc_AXI_TLB_TRANSACTION","Transactions");this.addAXICounter("mali_hwc_LS_TLB_MISS","LS Cache Miss"); this.addAXICounter("mali_hwc_LS_TLB_HIT","LS Cache Hit");this.addAXICounter("mali_hwc_AXI_BEATS_READ","Read Beats");this.addAXICounter("mali_hwc_AXI_BEATS_WRITE","Write Beats");this.addMMUCounter("mali_hwc_MMU_TABLE_WALK","Page Table Walks");this.addMMUCounter("mali_hwc_MMU_REPLAY_MISS","Cache Miss from Replay Buffer");this.addMMUCounter("mali_hwc_MMU_REPLAY_FULL","Replay Buffer Full");this.addMMUCounter("mali_hwc_MMU_NEW_MISS","Cache Miss on New Request");this.addMMUCounter("mali_hwc_MMU_HIT","Cache Hit"); this.addMMUCycles("mali_hwc_UTLB_STALL","UTLB Stalled");this.addMMUCycles("mali_hwc_UTLB_REPLAY_MISS","UTLB Replay Miss");this.addMMUCycles("mali_hwc_UTLB_REPLAY_FULL","UTLB Replay Full");this.addMMUCycles("mali_hwc_UTLB_NEW_MISS","UTLB New Miss");this.addMMUCycles("mali_hwc_UTLB_HIT","UTLB Hit");this.addL2Counter("mali_hwc_L2_READ_BEATS","Read Beats");this.addL2Counter("mali_hwc_L2_WRITE_BEATS","Write Beats");this.addL2Counter("mali_hwc_L2_ANY_LOOKUP","Any Lookup");this.addL2Counter("mali_hwc_L2_READ_LOOKUP", "Read Lookup");this.addL2Counter("mali_hwc_L2_SREAD_LOOKUP","Shareable Read Lookup");this.addL2Counter("mali_hwc_L2_READ_REPLAY","Read Replayed");this.addL2Counter("mali_hwc_L2_READ_SNOOP","Read Snoop");this.addL2Counter("mali_hwc_L2_READ_HIT","Read Cache Hit");this.addL2Counter("mali_hwc_L2_CLEAN_MISS","CleanUnique Miss");this.addL2Counter("mali_hwc_L2_WRITE_LOOKUP","Write Lookup");this.addL2Counter("mali_hwc_L2_SWRITE_LOOKUP","Shareable Write Lookup");this.addL2Counter("mali_hwc_L2_WRITE_REPLAY", "Write Replayed");this.addL2Counter("mali_hwc_L2_WRITE_SNOOP","Write Snoop");this.addL2Counter("mali_hwc_L2_WRITE_HIT","Write Cache Hit");this.addL2Counter("mali_hwc_L2_EXT_READ_FULL","ExtRD with BIU Full");this.addL2Counter("mali_hwc_L2_EXT_READ_HALF","ExtRD with BIU >1/2 Full");this.addL2Counter("mali_hwc_L2_EXT_WRITE_FULL","ExtWR with BIU Full");this.addL2Counter("mali_hwc_L2_EXT_WRITE_HALF","ExtWR with BIU >1/2 Full");this.addL2Counter("mali_hwc_L2_EXT_READ","External Read (ExtRD)");this.addL2Counter("mali_hwc_L2_EXT_READ_LINE", "ExtRD (linefill)");this.addL2Counter("mali_hwc_L2_EXT_WRITE","External Write (ExtWR)");this.addL2Counter("mali_hwc_L2_EXT_WRITE_LINE","ExtWR (linefill)");this.addL2Counter("mali_hwc_L2_EXT_WRITE_SMALL","ExtWR (burst size <64B)");this.addL2Counter("mali_hwc_L2_EXT_BARRIER","External Barrier");this.addL2Counter("mali_hwc_L2_EXT_AR_STALL","Address Read stalls");this.addL2Counter("mali_hwc_L2_EXT_R_BUF_FULL","Response Buffer full stalls");this.addL2Counter("mali_hwc_L2_EXT_RD_BUF_FULL","Read Data Buffer full stalls"); this.addL2Counter("mali_hwc_L2_EXT_R_RAW","RAW hazard stalls");this.addL2Counter("mali_hwc_L2_EXT_W_STALL","Write Data stalls");this.addL2Counter("mali_hwc_L2_EXT_W_BUF_FULL","Write Data Buffer full");this.addL2Counter("mali_hwc_L2_EXT_R_W_HAZARD","WAW or WAR hazard stalls");this.addL2Counter("mali_hwc_L2_TAG_HAZARD","Tag hazard replays");this.addL2Cycles("mali_hwc_L2_SNOOP_FULL","Snoop buffer full");this.addL2Cycles("mali_hwc_L2_REPLAY_FULL","Replay buffer full");a.registerEventHandler("tracing_mark_write:mali_driver", d.prototype.maliDDKEvent.bind(this));this.model_=a.model_}var b=tracing.importer.linux_perf.Parser;d.prototype={__proto__:b.prototype,maliDDKOpenSlice:function(a,c,e,b,g){a=this.importer.model_.getOrCreateProcess(a).getOrCreateThread(c);b=/^([\w\d_]*)(?:\(\))?:?\s*(.*)$/.exec(b);a.sliceGroup.beginSlice("gpu-driver",b[1],e,{args:b[2],blockinfo:g})},maliDDKCloseSlice:function(a,c,e,b,g){a=this.importer.model_.getOrCreateProcess(a).getOrCreateThread(c);a.sliceGroup.openSliceCount&&a.sliceGroup.endSlice(e)}, autoDetectLineRE:function(a){var c=/^\s*\(([\w\-]*)\)\s*(\w+):\s*([\w\\\/\.\-]*@\d*):?\s*(.*)$/;if(c.test(a))return c;c=/^s*()(\w+):\s*([\w\\\/.\-]*):?\s*(.*)$/;return c.test(a)?c:null},lineRE:null,maliDDKEvent:function(a,c,e,b,g){if(null==this.lineRE&&(this.lineRE=this.autoDetectLineRE(g.details),null==this.lineRE))return!1;a=this.lineRE.exec(g.details);c=""===a[1]?"mali":a[1];switch(a[2]){case "cros_trace_print_enter":this.maliDDKOpenSlice(e,c,b,a[4],a[3]);break;case "cros_trace_print_exit":this.maliDDKCloseSlice(e, c,b,[],a[3])}return!0},dvfsSample:function(a,c,e,b){var g=parseInt(b);a=this.model_.getOrCreateProcess(0).getOrCreateCounter("DVFS",a);0===a.numSeries&&a.addSeries(new tracing.trace_model.CounterSeries(c,tracing.getStringColorId(a.name)));a.series.forEach(function(a){a.addSample(e,g)})},dvfsEventEvent:function(a,c,e,b,g){a=/utilization=(\d+)/.exec(g.details);if(!a)return!1;this.dvfsSample("DVFS Utilization","utilization",b,a[1]);return!0},dvfsSetClockEvent:function(a,c,e,b,g){a=/frequency=(\d+)/.exec(g.details); if(!a)return!1;this.dvfsSample("DVFS Frequency","frequency",b,a[1]);return!0},dvfsSetVoltageEvent:function(a,c,e,b,g){a=/voltage=(\d+)/.exec(g.details);if(!a)return!1;this.dvfsSample("DVFS Voltage","voltage",b,a[1]);return!0},hwcSample:function(a,c,e,b,g){g=/val=(\d+)/.exec(g.details);if(!g)return!1;var h=parseInt(g[1]);a=this.model_.getOrCreateProcess(0).getOrCreateCounter(a,c);0===a.numSeries&&a.addSeries(new tracing.trace_model.CounterSeries(e,tracing.getStringColorId(a.name)));a.series.forEach(function(a){a.addSample(b, h)});return!0},jmSample:function(a,c,e,b){return this.hwcSample("mali:jm","JM: "+a,c,e,b)},addJMCounter:function(a,c){this.importer.registerEventHandler(a,function(a,b,g,h,d){return this.jmSample(c,"count",h,d)}.bind(this))},addJMCycles:function(a,c){this.importer.registerEventHandler(a,function(a,b,g,h,d){return this.jmSample(c,"cycles",h,d)}.bind(this))},tilerSample:function(a,c,e,b){return this.hwcSample("mali:tiler","Tiler: "+a,c,e,b)},addTilerCounter:function(a,c){this.importer.registerEventHandler(a, function(a,b,g,h,d){return this.tilerSample(c,"count",h,d)}.bind(this))},addTilerCycles:function(a,c){this.importer.registerEventHandler(a,function(a,b,g,h,d){return this.tilerSample(c,"cycles",h,d)}.bind(this))},fragSample:function(a,c,e,b){return this.hwcSample("mali:fragment","Fragment: "+a,c,e,b)},addFragCounter:function(a,c){this.importer.registerEventHandler(a,function(a,b,g,h,d){return this.fragSample(c,"count",h,d)}.bind(this))},addFragCycles:function(a,c){this.importer.registerEventHandler(a, function(a,b,g,h,d){return this.fragSample(c,"cycles",h,d)}.bind(this))},computeSample:function(a,c,e,b){return this.hwcSample("mali:compute","Compute: "+a,c,e,b)},addComputeCounter:function(a,c){this.importer.registerEventHandler(a,function(a,b,g,h,d){return this.computeSample(c,"count",h,d)}.bind(this))},addComputeCycles:function(a,c){this.importer.registerEventHandler(a,function(a,b,g,h,d){return this.computeSample(c,"cycles",h,d)}.bind(this))},addTripipeCycles:function(a,c){this.importer.registerEventHandler(a, function(a,b,g,h,d){return this.hwcSample("mali:shader","Tripipe: "+c,"cycles",h,d)}.bind(this))},arithSample:function(a,c,e,b){return this.hwcSample("mali:arith","Arith: "+a,c,e,b)},addArithCounter:function(a,c){this.importer.registerEventHandler(a,function(a,b,g,h,d){return this.arithSample(c,"count",h,d)}.bind(this))},addArithCycles:function(a,c){this.importer.registerEventHandler(a,function(a,b,g,h,d){return this.arithSample(c,"cycles",h,d)}.bind(this))},addLSCounter:function(a,c){this.importer.registerEventHandler(a, function(a,b,g,h,d){return this.hwcSample("mali:ls","LS: "+c,"count",h,d)}.bind(this))},textureSample:function(a,c,e,b){return this.hwcSample("mali:texture","Texture: "+a,c,e,b)},addTexCounter:function(a,c){this.importer.registerEventHandler(a,function(a,b,g,h,d){return this.textureSample(c,"count",h,d)}.bind(this))},addLSCCounter:function(a,c){this.importer.registerEventHandler(a,function(a,b,g,h,d){return this.hwcSample("mali:lsc","LSC: "+c,"count",h,d)}.bind(this))},addAXICounter:function(a,c){this.importer.registerEventHandler(a, function(a,b,g,h,d){return this.hwcSample("mali:axi","AXI: "+c,"count",h,d)}.bind(this))},mmuSample:function(a,c,e,b){return this.hwcSample("mali:mmu","MMU: "+a,c,e,b)},addMMUCounter:function(a,c){this.importer.registerEventHandler(a,function(a,b,g,h,d){return this.mmuSample(c,"count",h,d)}.bind(this))},addMMUCycles:function(a,c){this.importer.registerEventHandler(a,function(a,b,g,h,d){return this.mmuSample(c,"cycles",h,d)}.bind(this))},l2Sample:function(a,c,e,b){return this.hwcSample("mali:l2","L2: "+ a,c,e,b)},addL2Counter:function(a,c){this.importer.registerEventHandler(a,function(a,b,g,h,d){return this.l2Sample(c,"count",h,d)}.bind(this))},addL2Cycles:function(a,c){this.importer.registerEventHandler(a,function(a,b,g,h,d){return this.l2Sample(c,"cycles",h,d)}.bind(this))}};b.registerSubtype(d);return{MaliParser:d}});"use strict";base.require("tracing.importer.linux_perf.parser"); base.exportTo("tracing.importer.linux_perf",function(){function d(a){b.call(this,a);a.registerEventHandler("mm_vmscan_kswapd_wake",d.prototype.kswapdWake.bind(this));a.registerEventHandler("mm_vmscan_kswapd_sleep",d.prototype.kswapdSleep.bind(this));a.registerEventHandler("mm_vmscan_direct_reclaim_begin",d.prototype.reclaimBegin.bind(this));a.registerEventHandler("mm_vmscan_direct_reclaim_end",d.prototype.reclaimEnd.bind(this))}var b=tracing.importer.linux_perf.Parser,a=/nid=(\d+) order=(\d+)/,c= /order=(\d+) may_writepage=\d+ gfp_flags=(.+)/,e=/nr_reclaimed=(\d+)/;d.prototype={__proto__:b.prototype,openAsyncSlice:function(a,c,b,e,d,m){b=this.importer.getOrCreateKernelThread(c+":"+b,e);a=new tracing.trace_model.AsyncSlice(c,m,tracing.getStringColorId(m),a);a.startThread=b.thread;b.openAsyncSlices||(b.openAsyncSlices={});b.openAsyncSlices[d]=a},closeAsyncSlice:function(a,c,b,e,d,m){b=this.importer.getOrCreateKernelThread(c+":"+b,e);b.openAsyncSlices&&(e=b.openAsyncSlices[d])&&(e.duration=a- e.start,e.args=m,e.endThread=b.thread,e.subSlices=[new tracing.trace_model.Slice(c,e.title,e.colorId,e.start,e.args,e.duration)],b.thread.asyncSliceGroup.push(e),delete b.openAsyncSlices[d])},kswapdWake:function(c,e,b,d,l){c=a.exec(l.details);if(!c)return!1;parseInt(c[1]);c=parseInt(c[2]);b=this.importer.getOrCreateKernelThread("kswapd: "+l.threadName,b,b);b.openSliceTS?c>b.order&&(b.order=c):(b.openSliceTS=d,b.order=c);return!0},kswapdSleep:function(a,c,b,e,d){a=this.importer.getOrCreateKernelThread("kswapd: "+ d.threadName,b,b);a.openSliceTS&&(e=new tracing.trace_model.Slice("",d.threadName,tracing.getStringColorId(d.threadName),a.openSliceTS,{order:a.order},e-a.openSliceTS),a.thread.sliceGroup.pushSlice(e));a.openSliceTS=void 0;a.order=void 0;return!0},reclaimBegin:function(a,b,e,d,l){b=c.exec(l.details);if(!b)return!1;a=parseInt(b[1]);b=b[2];e=this.importer.getOrCreateKernelThread("direct reclaim: "+l.threadName,e,e);e.openSliceTS=d;e.order=a;e.gfp=b;return!0},reclaimEnd:function(a,c,b,d,l){a=e.exec(l.details); if(!a)return!1;a=parseInt(a[1]);b=this.importer.getOrCreateKernelThread("direct reclaim: "+l.threadName,b,b);void 0!==b.openSliceTS&&(d=new tracing.trace_model.Slice("","direct reclaim",tracing.getStringColorId(l.threadName),b.openSliceTS,{order:b.order,gfp:b.gfp,nr_reclaimed:a},d-b.openSliceTS),b.thread.sliceGroup.pushSlice(d));b.openSliceTS=void 0;b.order=void 0;b.gfp=void 0;return!0}};b.registerSubtype(d);return{MemReclaimParser:d}});"use strict";base.require("tracing.importer.linux_perf.parser"); base.require("tracing.trace_model.counter_series"); base.exportTo("tracing.importer.linux_perf",function(){function d(a){b.call(this,a);a.registerEventHandler("power_start",d.prototype.powerStartEvent.bind(this));a.registerEventHandler("power_frequency",d.prototype.powerFrequencyEvent.bind(this));a.registerEventHandler("cpu_frequency",d.prototype.cpuFrequencyEvent.bind(this));a.registerEventHandler("cpu_idle",d.prototype.cpuIdleEvent.bind(this))}var b=tracing.importer.linux_perf.Parser;d.prototype={__proto__:b.prototype,cpuStateSlice:function(a,c, b,f){c=this.importer.getOrCreateCpuState(c);"1"!=b?this.importer.importError("Don't understand power_start events of type "+b):(b=c.cpu.getOrCreateCounter("","C-State"),0===b.numSeries&&b.addSeries(new tracing.trace_model.CounterSeries("state",tracing.getStringColorId(b.name+".state"))),b.series.forEach(function(c){c.addSample(a,f)}))},cpuIdleSlice:function(a,c,b){c=this.importer.getOrCreateCpuState(c).cpu.getOrCreateCounter("","C-State");0===c.numSeries&&c.addSeries(new tracing.trace_model.CounterSeries("state", tracing.getStringColorId(c.name)));var f=4294967295!=b?b+1:0;c.series.forEach(function(c){c.addSample(a,f)})},cpuFrequencySlice:function(a,c,b){c=this.importer.getOrCreateCpuState(c).cpu.getOrCreateCounter("","Clock Frequency");0===c.numSeries&&c.addSeries(new tracing.trace_model.CounterSeries("state",tracing.getStringColorId(c.name+".state")));c.series.forEach(function(c){c.addSample(a,b)})},powerStartEvent:function(a,c,b,f,g){a=/type=(\d+) state=(\d) cpu_id=(\d)+/.exec(g.details);if(!a)return!1; c=parseInt(a[3]);b=parseInt(a[2]);this.cpuStateSlice(f,c,a[1],b);return!0},powerFrequencyEvent:function(a,c,b,f,g){c=/type=(\d+) state=(\d+) cpu_id=(\d)+/.exec(g.details);if(!c)return!1;a=parseInt(c[3]);c=parseInt(c[2]);this.cpuFrequencySlice(f,a,c);return!0},cpuFrequencyEvent:function(a,c,b,f,g){c=/state=(\d+) cpu_id=(\d)+/.exec(g.details);if(!c)return!1;a=parseInt(c[2]);c=parseInt(c[1]);this.cpuFrequencySlice(f,a,c);return!0},cpuIdleEvent:function(a,c,b,f,g){c=/state=(\d+) cpu_id=(\d)+/.exec(g.details); if(!c)return!1;a=parseInt(c[2]);c=parseInt(c[1]);this.cpuIdleSlice(f,a,c);return!0}};b.registerSubtype(d);return{PowerParser:d}});"use strict";base.require("tracing.importer.linux_perf.parser"); base.exportTo("tracing.importer.linux_perf",function(){function d(a){b.call(this,a);a.registerEventHandler("sched_switch",d.prototype.schedSwitchEvent.bind(this));a.registerEventHandler("sched_wakeup",d.prototype.schedWakeupEvent.bind(this))}var b=tracing.importer.linux_perf.Parser,a={},c=/prev_comm=(.+) prev_pid=(\d+) prev_prio=(\d+) prev_state=(\S\+?|\S\|\S) ==> next_comm=(.+) next_pid=(\d+) next_prio=(\d+)/;a.schedSwitchRE=c;var e=/comm=(.+) pid=(\d+) prio=(\d+) success=(\d+) target_cpu=(\d+)/; a.schedWakeupRE=e;d.prototype={__proto__:b.prototype,schedSwitchEvent:function(a,b,e,d,l){var m=c.exec(l.details);if(!m)return!1;a=m[4];e=m[5];l=parseInt(m[6]);m=parseInt(m[7]);this.importer.getOrCreateCpuState(b).switchRunningLinuxPid(this.importer,a,d,l,e,m);return!0},schedWakeupEvent:function(a,c,b,d,l){l=e.exec(l.details);if(!l)return!1;a=b;c=l[1];b=parseInt(l[2]);l=parseInt(l[3]);this.importer.markPidRunnable(d,b,c,l,a);return!0}};b.registerSubtype(d);return{SchedParser:d,_SchedParserTestExports:a}}); "use strict";base.require("tracing.importer.linux_perf.parser"); base.exportTo("tracing.importer.linux_perf",function(){function d(a){b.call(this,a);a.registerEventHandler("sync_timeline",d.prototype.timelineEvent.bind(this));a.registerEventHandler("sync_wait",d.prototype.syncWaitEvent.bind(this));a.registerEventHandler("sync_pt",d.prototype.syncPtEvent.bind(this));this.model_=a.model_}var b=tracing.importer.linux_perf.Parser,a=/name=(\S+) value=(\S*)/,c=/(\S+) name=(\S+) state=(\d+)/,e=/name=(\S+) value=(\S*)/;d.prototype={__proto__:b.prototype,timelineEvent:function(c, b,e,d,l){c=a.exec(l.details);if(!c)return!1;b=this.importer.getOrCreatePseudoThread(c[1]);void 0!==b.lastActiveTs&&(e=d-b.lastActiveTs,l=b.lastActiveValue,void 0==l&&(l=" "),e=new tracing.trace_model.Slice("",l,tracing.getStringColorId(l),b.lastActiveTs,{},e),b.thread.sliceGroup.pushSlice(e));b.lastActiveTs=d;b.lastActiveValue=c[2];return!0},syncWaitEvent:function(a,b,e,d,l){a=c.exec(l.details);if(!a||void 0===l.tgid)return!1;b=parseInt(l.tgid);e=this.model_.getOrCreateProcess(b).getOrCreateThread(e); e.name=l.threadName;l=e.kernelSliceGroup;if(!l.isTimestampValidForBeginOrEnd(d))return this.model_.importErrors.push("Timestamps are moving backward."),!1;e='fence_wait("'+a[2]+'")';if("begin"==a[1])l.beginSlice(null,e,d,{"Start state":a[3]});else if("end"==a[1])0b.indexOf(c)&&b.push(c)}else this.listeners_[a]=[c]},removeEventListener:function(a,c){if(this.listeners_&&a in this.listeners_){var b=this.listeners_[a],f=b.indexOf(c);0<=f&&(1==b.length?delete this.listeners_[a]:b.splice(f,1))}},dispatchEvent:function(a){if(!this.listeners_)return!0;var c=this;a.__defineGetter__("target", function(){return c});a.preventDefault=function(){this.returnValue=!1};var b=a.type,f=0;if(b in this.listeners_)for(var b=this.listeners_[b].concat(),g=0,d;d=b[g];g++)f=d.handleEvent?f|!1===d.handleEvent.call(d,a):f|!1===d.call(this,a);return!f&&a.returnValue},hasEventListener:function(a){return void 0!==this.listeners_[a]}};var b={decorate:function(a){for(var c in b)if("decorate"!=c){var e=b[c];"function"===typeof e&&(a[c]=e)}a.listenerCounts_={}},addEventListener:function(a,c,b){this.__proto__.addEventListener.call(this, a,c,b);void 0===this.listenerCounts_[a]&&(this.listenerCounts_[a]=0);this.listenerCounts_[a]++},removeEventListener:function(a,c,b){this.__proto__.removeEventListener.call(this,a,c,b);this.listenerCounts_[a]--},hasEventListener:function(a){return 0k?f=d+1:(0g)){var k=d(a,c,f);if(-1!=k&&(0=f&&h(a[k-1]),k!=a.length))for(b=a.length;k=g);k++)h(a[k])}}return{findLowIndexInSortedArray:d,findLowIndexInSortedIntervals:function(a,c,b,f){var g=d(a,c,f);return 0==g?f>=c(a[0])&&f=c(a[g])&&f=c(a[g-1])&&f=c(a[g-1])&&f"]}:{message:d.message,stack:d.stack?d.stack:[""]}},instantiateTemplate:function(d){return document.querySelector(d).content.cloneNode(!0)},stackTrace:function(){var d= Error().stack+"",d=d.split("\n");return d.slice(2)}}});"use strict"; base.exportTo("tracing.trace_model",function(){function d(b,a,c){this.objectInstance=b;this.ts=a;this.args=c;this.selected=!1}d.prototype={__proto__:Object.prototype,preInitialize:function(){},initialize:function(){}};d.nameToConstructorMap_={};d.register=function(b,a){if(d.nameToConstructorMap_[b])throw Error("Constructor already registerd for "+b);d.nameToConstructorMap_[b]=a};d.unregister=function(b){delete d.nameToConstructorMap_[b]};d.getConstructor=function(b){return d.nameToConstructorMap_[b]? d.nameToConstructorMap_[b]:d};return{ObjectSnapshot:d}});"use strict";base.require("base.range");base.require("base.sorted_array_utils");base.require("tracing.trace_model.object_snapshot"); base.exportTo("tracing.trace_model",function(){function d(b,a,c,e,f){this.parent=b;this.id=a;this.category=c;this.name=e;this.creationTs=f;this.creationTsWasExplicit=!1;this.deletionTs=Number.MAX_VALUE;this.selected=this.deletionTsWasExplicit=!1;this.colorId=0;this.bounds=new base.Range;this.snapshots=[];this.hasImplicitSnapshots=!1}d.prototype={__proto__:Object.prototype,get typeName(){return this.name},addSnapshot:function(b,a){if(b= instance.creationTs"); if(b>=this.deletionTs)throw Error("Snapshots cannot be added after an objects deletion timestamp.");var c;if(0b))throw Error("Instance cannot be deleted at ts="+b+". A snapshot exists that is older.");this.deletionTs=b;this.deletionTsWasExplicit=!0},preInitialize:function(){for(var b=0;b this.deletionTs)throw Error("ts must be within lifetime of this instance");var a=this.snapshots;b=base.findLowIndexInSortedIntervals(a,function(a){return a.ts},function(c,b){return b==a.length-1?a[b].objectInstance.deletionTs:a[b+1].ts-a[b].ts},b);return 0>b?this.snapshots[0]:b>=this.snapshots.length?this.snapshots[this.snapshots.length-1]:this.snapshots[b]},updateBounds:function(){this.bounds.reset();this.bounds.addValue(this.creationTs);this.deletionTs!=Number.MAX_VALUE?this.bounds.addValue(this.deletionTs): 0f){f=this.instances[0];if(c>f.deletionTs||f.creationTsWasExplicit)throw Error("At the provided timestamp, no instance was still alive"); if(0!=f.snapshots.length)throw Error("Cannot shift creationTs forward, snapshots have been added. First snap was at ts="+f.snapshots[0].ts+" and creationTs was "+f.creationTs);f.creationTs=c}else if(f>=this.instances.length)if(f=this.instances[this.instances.length-1],c>=f.deletionTs)f=this.createObjectInstanceFunction_(this.parent,this.id,b,a,c),this.instances.push(f);else{for(var g,f=this.instances.length-1;0<=f;f--){b=this.instances[f];if(c>=b.deletionTs)break;0==b.creationTsWasExplicit&&0==b.snapshots.length&& (g=f)}if(void 0===g)throw Error("Cannot add snapshot. No instance was alive that was mutable.");f=this.instances[g];f.creationTs=c}else f=this.instances[f];return f.addSnapshot(c,e)},get lastInstance(){return 0==this.instances.length?void 0:this.instances[this.instances.length-1]},idWasDeleted:function(b,a,c){0==this.instances.length&&this.instances.push(this.createObjectInstanceFunction_(this.parent,this.id,b,a,c));var e=this.instances[this.instances.length-1];if(cb?this.instances[0].creationTsWasExplicit?void 0:this.instances[0]:b>=this.instances.length?void 0:this.instances[b]}}; return{TimeToObjectInstanceMap:d}});"use strict";base.require("base.utils");base.require("base.range");base.require("base.sorted_array_utils");base.require("tracing.trace_model.object_instance");base.require("tracing.trace_model.time_to_object_instance_map"); base.exportTo("tracing.trace_model",function(){function d(b){this.parent=b;this.bounds=new base.Range;this.instanceMapsById_={};this.instancesByTypeName_={};this.createObjectInstance_=this.createObjectInstance_.bind(this)}d.prototype={__proto__:Object.prototype,createObjectInstance_:function(b,a,c,e,f){b=new (tracing.trace_model.ObjectInstance.getConstructor(e))(b,a,c,e,f);a=b.typeName;c=this.instancesByTypeName_[a];c||(c=[],this.instancesByTypeName_[a]=c);c.push(b);return b},getOrCreateInstanceMap_:function(b){var a= this.instanceMapsById_[b];if(a)return a;a=new tracing.trace_model.TimeToObjectInstanceMap(this.createObjectInstance_,this.parent,b);return this.instanceMapsById_[b]=a},idWasCreated:function(b,a,c,e){return this.getOrCreateInstanceMap_(b).idWasCreated(a,c,e)},addSnapshot:function(b,a,c,e,f){b=this.getOrCreateInstanceMap_(b,a,c,e).addSnapshot(a,c,e,f);if(b.objectInstance.category!=a)throw Error("Added snapshot with different category than when it was created");if(b.objectInstance.name!=c)throw Error("Added snapshot with different name than when it was created"); return b},idWasDeleted:function(b,a,c,e){if(b=this.getOrCreateInstanceMap_(b,a,c,e).idWasDeleted(a,c,e)){if(b.category!=a)throw Error("Deleting an object with a different category than when it was created");if(b.name!=c)throw Error("Deleting an object with a different name than when it was created");}},autoDeleteObjects:function(b){base.iterItems(this.instanceMapsById_,function(a,c){var e=c.lastInstance;e.deletionTs==Number.MAX_VALUE&&(c.idWasDeleted(e.category,e.name,b),e.deletionTsWasExplicit=!1)})}, getObjectInstanceAt:function(b,a){var c=this.instanceMapsById_[b];return c?c.getInstanceAt(a):void 0},getSnapshotAt:function(b,a){var c=this.getObjectInstanceAt(b,a);return c?c.getSnapshotAt(a):void 0},iterObjectInstances:function(b,a){a=a||this;base.iterItems(this.instanceMapsById_,function(c,e){e.instances.forEach(b,a)})},getAllObjectInstances:function(){var b=[];this.iterObjectInstances(function(a){b.push(a)});return b},getAllInstancesNamed:function(b){return this.instancesByTypeName_[b]},getAllInstancesByTypeName:function(){return this.instancesByTypeName_}, preInitializeAllObjects:function(){this.iterObjectInstances(function(b){b.preInitialize()})},initializeAllObjects:function(){this.iterObjectInstances(function(b){b.initialize()})},initializeInstances:function(){this.iterObjectInstances(function(b){b.initialize()})},updateBounds:function(){this.bounds.reset();this.iterObjectInstances(function(b){b.updateBounds();this.bounds.addRange(b.bounds)},this)},shiftTimestampsForward:function(b){this.iterObjectInstances(function(a){a.shiftTimestampsForward(b)})}, addCategoriesToDict:function(b){this.iterObjectInstances(function(a){b[a.category]=!0})},toJSON:function(){return{}}};return{ObjectCollection:d}});"use strict";base.require("tracing.trace_model.slice"); base.exportTo("tracing.trace_model",function(){function d(b,a,c,e,f){tracing.trace_model.Slice.apply(this,arguments)}d.prototype={__proto__:tracing.trace_model.Slice.prototype,toJSON:function(){for(var b={},a=Object.keys(this),c=0;c=this.openPartialSlices_[this.openPartialSlices_.length-1].start:!0},get openSliceCount(){return this.openPartialSlices_.length},get mostRecentlyOpenedPartialSlice(){return this.openPartialSlices_.length?this.openPartialSlices_[this.openPartialSlices_.length- 1]:void 0},endSlice:function(a){if(!this.openSliceCount)throw Error("endSlice called without an open slice");var c=this.openPartialSlices_[this.openSliceCount-1];this.openPartialSlices_.splice(this.openSliceCount-1,1);if(ab?(n(c),l.pop()):m.pop()}};0<=h||0<=k;){var q=f[h],s=g[k];void 0===q||void 0!==s&&q.end/.test(a))return f;var d=a.split("\n"),g=1;if(!b(/^