Skip to content

Instantly share code, notes, and snippets.

@jamesob
jamesob / mergeset_7_to_8.diff
Created May 29, 2019 18:20
diff <(git diff --no-color 76e2cded47..703b1819) <(git diff --no-color c7cfd20a77..955c782eb7)
35c35
< index 0000000000..36188f8471
---
> index 0000000000..c82ecaea8c
38c38
< @@ -0,0 +1,144 @@
---
> @@ -0,0 +1,158 @@
58a59
> + settings.command_line_options["name"].push_back("val2");
@jamesob
jamesob / 0a.recreate.md
Created April 3, 2019 15:02
15141.sdaftuar.rewrite_dos_interface_be: daf23bf -> daf674e

To recreate:

git remote add jamesob https://github.com/jamesob/bitcoin.git
git fetch jamesob

# Base branch:
# d5dbb45bdf - Merge #15314: [Doc] update release notes for changes up to cb35f1d (8 weeks ago)
#
git diff d5dbb45bdf jamesob:ackr/15141.1.sdaftuar.rewrite_dos_interface_be &gt; 1.daf23bf-base.diff
@jamesob
jamesob / test.perf.1-test.perf.2.diff
Created January 2, 2019 19:07
$ git diff test.perf.1..test.perf.2
diff --git a/doc/developer-notes.md b/doc/developer-notes.md
index a6df17ddd..a952eeed7 100644
--- a/doc/developer-notes.md
+++ b/doc/developer-notes.md
@@ -257,6 +257,48 @@ make cov
# A coverage report will now be accessible at `./test_bitcoin.coverage/index.html`.
```
+### Performance profiling with perf
+
@jamesob
jamesob / 01-results.md
Created August 21, 2018 13:35
bitcoinperf: asynclog

2018-05-asynclog vs. master (absolute)

name iterations 2018-05-asynclog master
build.make.5.clang.mem-usage 1 645988.00 612340.0
ibd.local.200000.dbcache=2048 4 197.81 206.9
ibd.local.200000.dbcache=2048.mem-usage 4 864743.00 858984.0
gitclone 1 7.89
build.make.5.clang 1 292.50 296.7
@jamesob
jamesob / 01-results.md
Created August 20, 2018 21:16
threadnames-rebased benchmarking

master vs. threadnames-rebased (absolute)

name iterations master threadnames-rebased
ibd.local.200000.dbcache=2048.mem-usage 4 861795.00 864879.0
gitclone 1 7.64
ibd.local.200000.dbcache=2048 4 205.79 208.7
build.make.5.clang 1 296.87 298.7
build.make.5.clang.mem-usage 1 611652.00 611932.0
@jamesob
jamesob / threadnames2.15.16.diff
Created July 12, 2018 14:29
diff -uw <(git diff master..threadnames2.15) <(git diff master..threadnames2.16)
--- /proc/self/fd/12 2018-07-12 10:27:34.977243847 -0400
+++ /proc/self/fd/13 2018-07-12 10:27:34.981243902 -0400
@@ -94,7 +94,7 @@
// Parameters
//
diff --git a/src/httpserver.cpp b/src/httpserver.cpp
-index bd08b04..1355071 100644
+index bd08b04..229ff86 100644
--- a/src/httpserver.cpp
+++ b/src/httpserver.cpp
@jamesob
jamesob / diff.patch
Created June 22, 2018 20:40
git diff threadnames2.13..18928a194fa351e07eb808eaea01792ceb1d2093
diff --git a/src/threadutil.cpp b/src/threadutil.cpp
index 0630eff..c558c50 100644
--- a/src/threadutil.cpp
+++ b/src/threadutil.cpp
@@ -50,10 +50,9 @@ std::string thread_util::GetInternalName() {
* Set the in-memory internal name for this thread. Does not affect the process
* name.
*/
-static bool SetInternalName(const std::string& name)
+static void SetInternalName(const std::string& name)
[Fri 22 15:51] james/src/bitcoin atmp-p2p-refactor* btc
$ git show-ref atmp-p2p-refactor
2567ef43f3efd99ed08a5eb841251ed9111732d3 refs/heads/atmp-p2p-refactor
2567ef43f3efd99ed08a5eb841251ed9111732d3 refs/remotes/skeees/atmp-p2p-refactor
[Fri 22 15:51] james/src/bitcoin atmp-p2p-refactor* btc
$ git lg | head -n 4
* 2567ef4 - (HEAD -> atmp-p2p-refactor, tag: skeees-atmp-p2p-refactor.1, skeees/atmp-p2p-refactor) [refactor, move-only-ish] Refactor mempool accept/reject logic (2 hours ago)
@jamesob
jamesob / threadnames2.7-8.patch
Created June 13, 2018 19:38
diff -uw <(git diff master..threadnames2.7) <(git diff master..threadnames2.8)
--- /proc/self/fd/15 2018-06-13 15:37:25.517994103 -0400
+++ /proc/self/fd/16 2018-06-13 15:37:25.509994021 -0400
@@ -1,8 +1,8 @@
diff --git a/configure.ac b/configure.ac
-index af60b28..5306f60 100644
+index af60b28..0f9815e 100644
--- a/configure.ac
+++ b/configure.ac
-@@ -759,8 +759,21 @@ AC_LINK_IFELSE([AC_LANG_SOURCE([
+@@ -759,8 +759,23 @@ AC_LINK_IFELSE([AC_LANG_SOURCE([
@jamesob
jamesob / threadnames2.5.6.patch
Created May 8, 2018 17:00
git diff threadnames2.5..threadnames2.6
diff --git a/src/threadutil.cpp b/src/threadutil.cpp
index 6ad720c..29bae65 100644
--- a/src/threadutil.cpp
+++ b/src/threadutil.cpp
@@ -12,8 +12,9 @@
#include <threadutil.h>
/*
- * TODO: using thread_local changes the abi in ways that may not play nice
- * when the c++ stdlib is linked dynamically. Disable it until thorough