Skip to content

Commit 3e9e38a

Browse files
committed
Undo incorrect "fix" for old linux headers.
I have used #if defined(...) to check for enum values, which is... simply incorrect and not possible. Removing this check again. If compilation does not work, define the macro ANKERL_NANOBENCH_DISABLE_PERF_COUNTERS.
1 parent 2d6158a commit 3e9e38a

File tree

10 files changed

+11
-14
lines changed

10 files changed

+11
-14
lines changed

docs/CODE_OF_CONDUCT.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -68,7 +68,7 @@
6868

6969

7070
<div class="version">
71-
v4.3.4
71+
v4.3.5
7272
</div>
7373

7474

docs/comparison.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -69,7 +69,7 @@
6969

7070

7171
<div class="version">
72-
v4.3.4
72+
v4.3.5
7373
</div>
7474

7575

docs/genindex.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -67,7 +67,7 @@
6767

6868

6969
<div class="version">
70-
v4.3.4
70+
v4.3.5
7171
</div>
7272

7373

docs/index.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -68,7 +68,7 @@
6868

6969

7070
<div class="version">
71-
v4.3.4
71+
v4.3.5
7272
</div>
7373

7474

docs/license.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -69,7 +69,7 @@
6969

7070

7171
<div class="version">
72-
v4.3.4
72+
v4.3.5
7373
</div>
7474

7575

docs/reference.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -69,7 +69,7 @@
6969

7070

7171
<div class="version">
72-
v4.3.4
72+
v4.3.5
7373
</div>
7474

7575

docs/search.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -70,7 +70,7 @@
7070

7171

7272
<div class="version">
73-
v4.3.4
73+
v4.3.5
7474
</div>
7575

7676

docs/tutorial.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -69,7 +69,7 @@
6969

7070

7171
<div class="version">
72-
v4.3.4
72+
v4.3.5
7373
</div>
7474

7575

src/docs/conf.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@
2222
project = 'nanobench'
2323
copyright = '2019-2021 Martin Ankerl <[email protected]>'
2424
author = 'Martin Ankerl'
25-
version = 'v4.3.4'
25+
version = 'v4.3.5'
2626

2727
# -- General configuration ---------------------------------------------------
2828

src/include/nanobench.h

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@
3333
// see https://semver.org/
3434
#define ANKERL_NANOBENCH_VERSION_MAJOR 4 // incompatible API changes
3535
#define ANKERL_NANOBENCH_VERSION_MINOR 3 // backwards-compatible changes
36-
#define ANKERL_NANOBENCH_VERSION_PATCH 4 // backwards-compatible bug fixes
36+
#define ANKERL_NANOBENCH_VERSION_PATCH 5 // backwards-compatible bug fixes
3737

3838
///////////////////////////////////////////////////////////////////////////////////////////////////
3939
// public facing api - as minimal as possible
@@ -88,10 +88,7 @@
8888
} while (0)
8989
#endif
9090

91-
#if defined(__linux__) && defined(PERF_EVENT_IOC_ID) && defined(PERF_COUNT_HW_REF_CPU_CYCLES) && defined(PERF_FLAG_FD_CLOEXEC) && \
92-
!defined(ANKERL_NANOBENCH_DISABLE_PERF_COUNTERS)
93-
// only enable perf counters on kernel 3.14 which seems to have all the necessary defines. The three PERF_... defines are not in
94-
// kernel 2.6.32 (all others are).
91+
#if defined(__linux__) && !defined(ANKERL_NANOBENCH_DISABLE_PERF_COUNTERS)
9592
# define ANKERL_NANOBENCH_PRIVATE_PERF_COUNTERS() 1
9693
#else
9794
# define ANKERL_NANOBENCH_PRIVATE_PERF_COUNTERS() 0

0 commit comments

Comments
 (0)