Skip to content

Instantly share code, notes, and snippets.


Maksym Pavlenko mxpv

View GitHub Profile
mxpv / gist:5262043
Created Mar 28, 2013
Git caret and tilde
View gist:5262043
mxpv /
Created Apr 18, 2013
Building Clang
mxpv / Win32.h
Created May 2, 2013
Slim version of windows.h header
View Win32.h
#ifndef SYS_WIN32_H
#define SYS_WIN32_H
// Slim version of windows.h header
#ifndef WIN32_EXTRA_LEAN
mxpv / DialogTemplate.cpp
Last active Dec 17, 2015
Small helper class for generating dynamic dialog templates in memory and handling all alignment stuff. (see
View DialogTemplate.cpp
DialogTemplate::DialogTemplate(const wchar_t * caption, u32 x, u32 y, u32 width, u32 height)
: _size(0)
Header header = { 0 }; = DS_SETFONT | DS_CENTER | WS_POPUP | WS_CAPTION;
header.dlg.dwExtendedStyle = 0;
header.dlg.x = x;
header.dlg.y = y;
mxpv / gist:5879528
Created Jun 27, 2013
How to make sublime text the default editor for git on Windows
View gist:5879528
git config --global core.editor "'c:/program files/sublime text 2/sublime_text.exe' -w"
View gist:07c88d30dae747fdd340
$ ../External/ctags/ctags.exe --append --fields=+ian --c-types=+cefgmnpstuvx --recurse --totals=yes .
1 file, 110 lines (2 kB) scanned in 0.0 seconds (1420 kB/s)
56 tags added to tag file (now 56 tags)
56 tags sorted in 0.00 seconds
View gist:034933deeebb26b62f14
Should pass:
mxpv / benchmark_test.go
Last active Sep 18, 2018
Containerd decompression benchmark
View benchmark_test.go
package compression_test
import (
View gist:171ebdc312499493df9833899433ccda
$ curl
# HELP container_cpu_kernel_nanoseconds The total kernel cpu time
# TYPE container_cpu_kernel_nanoseconds gauge
container_cpu_kernel_nanoseconds{container_id="test120",namespace="default",runtime_class="io.containerd.runtime.v1.linux"} 1e+07
container_cpu_kernel_nanoseconds{container_id="test12345",namespace="default",runtime_class="io.containerd.other.v2"} 1e+07
# HELP container_cpu_throttle_periods_total The total cpu throttle periods
# TYPE container_cpu_throttle_periods_total gauge
container_cpu_throttle_periods_total{container_id="test120",namespace="default",runtime_class="io.containerd.runtime.v1.linux"} 0
container_cpu_throttle_periods_total{container_id="test12345",namespace="default",runtime_class="io.containerd.other.v2"} 0
# HELP container_cpu_throttled_periods_total The total cpu throttled periods