Skip to content

Instantly share code, notes, and snippets.

0 998 ip=55836432d798
558363b379b0 crc32_iscsi_00 30 ip=9a9
7f13cf2dd511 #### 1 ip=ffffffffffffffff
7f13d367e730 _ZN8tcmalloc15CentralFreeList17FetchFromOneSpansEiPPvS2_ 1 ip=2f
7f13cf2dd811 #### 1 ip=ffffffffffffffff
7f13d367f620 _ZN8tcmalloc8PageHeap10AllocLargeEm 1 ip=87
7f13cf2ddaf1 #### 1 ip=ffffffffffffffff
5583633195e0 _ZN4ceph6buffer4list5clearEv 1 ip=17
7f13cf2e1701 #### 1 ip=ffffffffffffffff
558363969b60 _ZN11EventCenter14process_eventsEiPNSt6chrono8durationImSt5ratioILl1ELl1000000000EEEE 1 ip=569
@aclamk
aclamk / gist:9d8900b82181cb14f47b1fca03fd88ed
Created January 15, 2018 15:32
Sample wallclock from 4K write
This file has been truncated, but you can view the full file.
Thread: 21319 (ceph-osd) - 19934 samples, time suspended=1385ms
+ 100.00% _start
+ 100.00% __libc_start_main
+ 100.00% main
+ 100.00% AsyncMessenger::wait()
+ 100.00% pthread_cond_wait
Thread: 21320 (log) - 19934 samples, time suspended=1362ms
@aclamk
aclamk / gdbpmp.rw-4k-a
Created January 17, 2018 14:53
Libunwind & gdb wallclocks
Thread: 1 (ceph-osd) - 218 samples
+ 100.00% main
+ 100.00% AsyncMessenger::wait
+ 100.00% Wait
+ 100.00% pthread_cond_wait@@GLIBC_2.3.2
Thread: 2 (signal_handler) - 218 samples
@aclamk
aclamk / ffsll.cpp
Created June 26, 2018 11:22
Test ffsll
#include <assert.h>
#include <inttypes.h>
#include <stddef.h>
#include <stdlib.h>
#include <stdio.h>
typedef uint64_t slot_t;
static constexpr size_t bits_per_slot = sizeof(slot_t) * 8;
static inline ssize_t count_0s_gcc(slot_t slot_val, size_t start_pos)
@aclamk
aclamk / speed and page-fault comparison.txt
Last active September 7, 2018 11:43
log-entry-stack
** REFERENCE **
Note: Google Test filter = Log.Multithread*
[==========] Running 5 tests from 1 test case.
[----------] Global test environment set-up.
[----------] 5 tests from Log
[ RUN ] Log.Multithread
[ OK ] Log.Multithread (1176 ms)
[ RUN ] Log.Multithread_4_4K_10000
[ OK ] Log.Multithread_4_4K_10000 (978 ms)
Encode when all fields are encoded to bytestream
[ RUN ] BufferList.encode_bench
[ OK ] BufferList.encode_bench (251 ms)
[ RUN ] BufferList.encode_bench_x
[ OK ] BufferList.encode_bench_x (31 ms)
Encode when one of fields is bufferlist and its data is not copied
@aclamk
aclamk / gist:49c42c72d9be6cb4f64fa7ad63572cc1
Last active October 30, 2018 14:33
Radek encode rework
Reference:
[
{
"name": "void OSDMap::encode(ceph::bufferlist&, uint64_t) const",
"count": 8,
"time": "0.001130",
"one": "0.000141"
},
{
"name": "void object_info_t::encode(ceph::bufferlist&, uint64_t) const",
@aclamk
aclamk / gist:dc23ab9631879abffd4e5adcea69abd0
Created November 6, 2018 15:34
4M write converted to 64k blobs
"rbd_data.293a2176813d67.0000000000000688",
"device": {
"0xc0af0000": "0x4000",
"0xc0af4000": "0x10000",
"0xc0b04000": "0x10000",
"0xc0b14000": "0x10000",
"0xc0b24000": "0x10000",
"0xc0b34000": "0x10000",
"0xc0b44000": "0x10000",
"0xc0b54000": "0x10000",
#if BLI_OLD
unsigned off; // in bl
list_iter_t p;
unsigned p_off; // in *p
#endif
#if BLI_NEW
mutable const char* current;
mutable const char* limit;
list_iter_t pp;
mutable unsigned off_anchor;
prefix_cf:
1) there exists default table for k-v
2) there exist additional tables with fixed prefixes
3) for additional table name is same as prefix
4) writes and reads do refer additional table, if prefix matches
5) prefixed iterator accesses either default or prefixed table
6) wholespace iterator accesses default_cf
7*) need uniform iterator for both prefixed and default