ServerBench.cpp calls syscall(SYS_perf_event_open, ...) at line 356, but it only includes <unistd.h> and not <sys/syscall.h>. On systems/glibc versions where unistd.h does not pull in the SYS_* constants, the build fails with:
ServerBench.cpp:356:19: error: ‘SYS_perf_event_open’ was not declared in this scope
Location:ServerBench.cpp:356 (and the surrounding #includes at lines 1–24).
Expected behavior:server_bench compiles on any platform that provides perf_event_open. Actual behavior:server_bench fails to compile because the SYS_perf_event_open macro is missing.
Impact: The server_bench executable cannot be built in environments where <unistd.h> does not transitively define SYS_perf_event_open (e.g. the current CI/container toolchain).
Suggested fix: Add #include <sys/syscall.h> near the other system headers at the top of ServerBench.cpp.
`ServerBench.cpp` calls `syscall(SYS_perf_event_open, ...)` at line 356, but it only includes `<unistd.h>` and not `<sys/syscall.h>`. On systems/glibc versions where `unistd.h` does not pull in the `SYS_*` constants, the build fails with:
```
ServerBench.cpp:356:19: error: ‘SYS_perf_event_open’ was not declared in this scope
```
**Location:** `ServerBench.cpp:356` (and the surrounding `#include`s at lines 1–24).
**Expected behavior:** `server_bench` compiles on any platform that provides `perf_event_open`.
**Actual behavior:** `server_bench` fails to compile because the `SYS_perf_event_open` macro is missing.
**Impact:** The `server_bench` executable cannot be built in environments where `<unistd.h>` does not transitively define `SYS_perf_event_open` (e.g. the current CI/container toolchain).
**Suggested fix:** Add `#include <sys/syscall.h>` near the other system headers at the top of `ServerBench.cpp`.
weaselbot
was assigned by andrew2026-06-19 01:20:57 +00:00
Fix pushed to weaselbot/conflict-set@weaselbot/issue-41 and opened as PR weaselbot/conflict-set#2.
ServerBench.cpp now includes <sys/syscall.h>, which provides SYS_perf_event_open on toolchains where <unistd.h> does not transitively define it. I verified the server_bench target builds successfully with this change.
Note: upstream weaselab/conflict-set appears to have pull requests disabled (the API and web UI return 404 on the pulls endpoint), so the PR was created against the fork instead.
Fix pushed to `weaselbot/conflict-set@weaselbot/issue-41` and opened as PR weaselbot/conflict-set#2.
`ServerBench.cpp` now includes `<sys/syscall.h>`, which provides `SYS_perf_event_open` on toolchains where `<unistd.h>` does not transitively define it. I verified the `server_bench` target builds successfully with this change.
Note: upstream `weaselab/conflict-set` appears to have pull requests disabled (the API and web UI return 404 on the pulls endpoint), so the PR was created against the fork instead.
Added #include <sys/syscall.h> to ServerBench.cpp so SYS_perf_event_open is available on toolchains where unistd.h does not define it transitively.
Verified that the server_bench target builds successfully.
Opened upstream PR #44 with the fix.
- Added `#include <sys/syscall.h>` to `ServerBench.cpp` so `SYS_perf_event_open` is available on toolchains where `unistd.h` does not define it transitively.
- Verified that the `server_bench` target builds successfully.
weaselbot
was unassigned by andrew2026-06-19 17:11:02 +00:00
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.
ServerBench.cppcallssyscall(SYS_perf_event_open, ...)at line 356, but it only includes<unistd.h>and not<sys/syscall.h>. On systems/glibc versions whereunistd.hdoes not pull in theSYS_*constants, the build fails with:Location:
ServerBench.cpp:356(and the surrounding#includes at lines 1–24).Expected behavior:
server_benchcompiles on any platform that providesperf_event_open.Actual behavior:
server_benchfails to compile because theSYS_perf_event_openmacro is missing.Impact: The
server_benchexecutable cannot be built in environments where<unistd.h>does not transitively defineSYS_perf_event_open(e.g. the current CI/container toolchain).Suggested fix: Add
#include <sys/syscall.h>near the other system headers at the top ofServerBench.cpp.Fix pushed to
weaselbot/conflict-set@weaselbot/issue-41and opened as PR weaselbot/conflict-set#2.ServerBench.cppnow includes<sys/syscall.h>, which providesSYS_perf_event_openon toolchains where<unistd.h>does not transitively define it. I verified theserver_benchtarget builds successfully with this change.Note: upstream
weaselab/conflict-setappears to have pull requests disabled (the API and web UI return 404 on the pulls endpoint), so the PR was created against the fork instead.Pull requests should be enabled now
Opened upstream PR #44 with the fix.
#include <sys/syscall.h>toServerBench.cppsoSYS_perf_event_openis available on toolchains whereunistd.hdoes not define it transitively.server_benchtarget builds successfully.