Skip to content

Instantly share code, notes, and snippets.

@parsa
Last active March 23, 2020 19:35
Show Gist options
  • Save parsa/df4509a7d94898fdb9013f4889895632 to your computer and use it in GitHub Desktop.
Save parsa/df4509a7d94898fdb9013f4889895632 to your computer and use it in GitHub Desktop.

HPX performance counter line filter

^/[^{]+\{[^}]+\}/([^,]+,)*[^,]+$

Matches:

/objectname{full_instancename}/countername@parameters[,whatever[,whatever]...]

Generic counter name

/([^{]+)\{locality#(\d+)/([^}]+)\}/([^@]+)(?:@(.+))?

Generic counter name with thread pool support

/([^{]+)\{locality#(\d+)/(?:(?:(pool#[^/]+/[^#]+)#(\d+))|([^}]+))\}/([^@]+)(?:@(.+))?

Generic counter name with thread pool support - named

/(?P<object>[^{]+)\{locality#(?P<locality>\d+)/(?:(?:(?P<instance1>pool#[^/]+/[^#]+)#(?P<thread_id>\d+))|(?P<instance2>[^}]+))\}/(?P<counter>[^@]+)(?:@(?P<params>.+))?

Matches:

/octotiger{locality#0/total}/subgrid_leaves,2,3602.438779,[s],32428
/octotiger{locality#1/total}/subgrid_leaves,2,3602.428582,[s],34118
/octotiger{locality#2/total}/subgrid_leaves,2,3602.430246,[s],33918
/octotiger{locality#3/total}/subgrid_leaves,2,3602.431576,[s],34443
/octotiger{locality#4/total}/subgrid_leaves,2,3602.436175,[s],33173
/threads{locality#59/total/total}/count/cumulative,44,154828.198473,[s],2.3065e+09
/threads{locality#60/total/total}/count/cumulative,44,154828.221342,[s],2.24724e+09
/threads{locality#61/total/total}/count/cumulative,44,154828.184221,[s],2.28135e+09
/threads{locality#62/total/total}/count/cumulative,44,154828.221351,[s],2.20491e+09
/threads{locality#63/total/total}/count/cumulative,44,154828.216028,[s],2.05324e+09
/threads{locality#0/pool#default/worker-thread#0}/count/cumulative,44,154828.257432,[s],1.14378e+08
/threads{locality#0/pool#default/worker-thread#1}/count/cumulative,44,154828.260203,[s],1.05219e+08
/threads{locality#0/pool#default/worker-thread#2}/count/cumulative,44,154828.262954,[s],1.04616e+08
/threads{locality#0/pool#default/worker-thread#3}/count/cumulative,44,154828.262962,[s],1.04786e+08
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment