-
Notifications
You must be signed in to change notification settings - Fork 1.6k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix for missing cycles column and more #2588
base: master
Are you sure you want to change the base?
Fix for missing cycles column and more #2588
Conversation
#include "seastar/coroutine/maybe_yield.hh" | ||
#include "seastar/util/later.hh" | ||
#include <seastar/core/coroutine.hh> | ||
#include <seastar/testing/perf_tests.hh> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
<> includes please.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@tchaikov could we enforce it? By using -isystem include
instead of -Iinclude
, though it would take me several weeks to figure out how to do it with cmake.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actually it wouldn't help.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
sorry this is how clangd auto-adds headers, let me see if I can configure it to understand the seastar way
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
fixed in push
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Seems like this is not currently configurable though there has been a fair amount of effort to make it configurable, see:
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
By using -isystem include
FWIW using -isystem
would actually fix clangd
auto-add behavior to use <>
instead. However, I believe it comes with downsides, e.g., some/all warnings are not reported in -isystem
headers?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Agree that not reporting errors would make it worse.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
After poking the LLVM bear it looks like this will be available in a future clangd version: llvm/llvm-project#67749 (comment)
/* | ||
* This file is open source software, licensed to you under the terms | ||
* of the Apache License, Version 2.0 (the "License"). See the NOTICE file | ||
* distributed with this work for additional information regarding copyright |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
These are benchmarks which just test minimal version of the various
PERF_TEST flavors, with mostly empty test bodies. It is intended to
test the overhead of the test framework, so that changes can be made
without any large regressions. There are a lot of cases because
internally the main perf test loop has different flavors depending
on async or not, returning an iteration count or not, etc.
Please enrich the changelog with sample output.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Good idea, sample out here (from after the coroutine change):
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks like you forgot to add it to the cover letter.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It has been added it to the cover letter now.
bf6880e
to
759efe1
Compare
Sample output of perf_tests_perf:
|
These are benchmarks which just test minimal version of the various PERF_TEST flavors, with mostly empty test bodies. It is intended to test the overhead of the test framework, so that changes can be made without any large regressions. There are a lot of cases because internally the main perf test loop has different flavors depending on async or not, returning an iteration count or not, etc.
Simplify and coroutinize main loop. This reduces the duplicated portion in the main loop which handles the 4 compile-time cases of {void returning, size_t returning} x {sync, async} test case methods. We duplicate only as much as need to keep the main loop efficient but try to share the remainder. We can also remove a lot of boilerplate which is no longer needed in C++. This fixes scylladb#2587 because the underlying bug there was a change in one of the duplicated sections but not the other. Performance should be similar after this change: any benchmark that does substantial work won't see a change. Very short benchmarks are sensitive to the work in the main loop and this is slightly better in some cases and slightly worse in others. This was evaluated with perf_tests_perf benchmark in this series. We delegate the choice of whether to yield in the benchmark not to the code under test (in the future returning case). Fixes scylladb#2587.
759efe1
to
ff20df3
Compare
Actually the output above shows the cycles column is missing from the Here's the non-md output corresponding to the above:
|
The unrelated fix for the entirely missing cycles column (not simply zero) in perf tests is over there: #2590 |
In this series:
Example results for
perf_test_perf
after the fix: