Skip to content
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

Dev/bench runtime #122

Merged
merged 47 commits into from
Jul 11, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
47 commits
Select commit Hold shift + click to select a range
3d8cb07
adding linux and barrelfish comparison benchmarks
achreto Jun 19, 2024
feab849
lib/velosisynth: adding more options for program generation
achreto Jul 4, 2024
49626c6
lib/velosisynth: adding notin of 'complex' queries
achreto Jul 4, 2024
9dc29a3
lib/velosiast: adding code that checks the expression for range checks
achreto Jul 4, 2024
ff74f80
update benches
achreto Jul 4, 2024
e0a8761
update assoc segment descriptin
achreto Jul 4, 2024
05b6c91
lib/velosisynth: using some more stability in the queries
achreto Jul 5, 2024
29fa52c
lib/velosisynth: implement query retries in the smt solver
achreto Jul 5, 2024
34b4b03
lib/velosisynth: resubmit query when result ins unknown
achreto Jul 5, 2024
b4a2b4d
lib/velosisynth: use BV logic for orders
achreto Jul 5, 2024
9c8d73c
lib/velosisynth: debug print query plan
achreto Jul 5, 2024
c959039
lib/smtlib2: bump version
achreto Jul 5, 2024
c33a832
lib/velosisynth: use supplied buffer for formatting smtlib
achreto Jul 5, 2024
6302162
lib/velosiast: applying formatter
achreto Jul 5, 2024
a06a140
lib/velosisynth: apply formatter
achreto Jul 5, 2024
6af856c
lib/velosisynth: updating program builder
achreto Jul 5, 2024
26e1942
udpateing benchmark configurations
achreto Jul 5, 2024
b4c4849
updating some specifications
achreto Jul 5, 2024
07bee38
lib/velosiraptor-parser: bump version
achreto Jul 8, 2024
ba12ef4
addin build directory to gitignore
achreto Jul 8, 2024
1432965
update rust-toolchain to 1.79
achreto Jul 8, 2024
1b7a43a
benches; improve output and checking for dirtyness
achreto Jul 8, 2024
56d9e5d
update build.rs
achreto Jul 8, 2024
c6be96e
fixing latex print
achreto Jul 8, 2024
08ea060
fixing some warnings in the codebase
achreto Jul 8, 2024
6a10124
bench: reduce the output
achreto Jul 8, 2024
4951574
bench: adding progress indicators
achreto Jul 8, 2024
e5ec7ae
benchmarks: all with progress bars and other things
achreto Jul 8, 2024
db97834
bench: fix table header
achreto Jul 8, 2024
c4831a9
updating some descriptions of generated code
achreto Jul 9, 2024
a44da00
program builder update
achreto Jul 9, 2024
f7928aa
update workflows to use self-hosted runner
achreto Jul 9, 2024
63aae16
github workflow: don't use sudo on the self-hosted machine
achreto Jul 9, 2024
10c40b4
lib/crustal: bumping submodule version
achreto Jul 9, 2024
1ae662d
applying clippy suggestions
achreto Jul 9, 2024
41b9297
lib/z3: bump library version
achreto Jul 9, 2024
e21c775
lib/velosisynth: some fixes in the z3 worker
achreto Jul 10, 2024
a78eb46
lib/velosiast: adding method to check if its a literal with name
achreto Jul 10, 2024
0380f35
tests: fix clippy warnings
achreto Jul 10, 2024
d2cea9b
make the mpu example compile
achreto Jul 10, 2024
ab2b416
lib/velosisynth: some temporary changes
achreto Jul 10, 2024
d611b4c
increase timeout
achreto Jul 10, 2024
41f4aec
lib/velosisynth: add constraint to symvar to be >1
achreto Jul 10, 2024
2f1bb33
lib/velosisynth: retry queries with lower priority
achreto Jul 10, 2024
a28b9e9
lib/velosisynth: some updates with programm generation
achreto Jul 10, 2024
4214da8
benches: adding the MPU to the opt table
achreto Jul 11, 2024
11eb661
don't have the bench.1.build in the cargo.toml
achreto Jul 11, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 3 additions & 2 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,10 +4,11 @@ on:
- main
pull_request:


name: Build
jobs:
dev_build:
runs-on: ubuntu-latest
runs-on: self-hosted
steps:
- uses: actions/checkout@v3
with:
Expand All @@ -21,7 +22,7 @@ jobs:
command: build
args:
release_build:
runs-on: ubuntu-latest
runs-on: self-hosted
steps:
- uses: actions/checkout@v3
with:
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/clippy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ on:
name: Clippy
jobs:
clippy_check:
runs-on: ubuntu-latest
runs-on: self-hosted
steps:
- uses: actions/checkout@v3
with:
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/format.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ on:
name: Format
jobs:
format:
runs-on: ubuntu-latest
runs-on: self-hosted
steps:
- uses: actions/checkout@v3
with:
Expand Down
8 changes: 4 additions & 4 deletions .github/workflows/tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,11 +8,11 @@ name: Unit Tests (root)
jobs:
compile_and_test:
name: "tests"
runs-on: ubuntu-latest
runs-on: self-hosted
steps:
- name: Prepare
run: |
sudo apt-get install z3
# - name: Prepare
# run: |
# sudo apt-get install z3
- uses: actions/checkout@v3
with:
submodules: recursive
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/unit-ast.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ on:
name: Unit Tests (libvelosiast)
jobs:
compile_and_test:
runs-on: ubuntu-latest
runs-on: self-hosted
name: "libvelosiast"
steps:
- uses: actions/checkout@v3
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/unit-synth.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ name: Unit Tests (libvelosisynth)
jobs:
compile_and_test:
name: "libvelosisynth"
runs-on: ubuntu-latest
runs-on: self-hosted
steps:
- uses: actions/checkout@v3
with:
Expand Down
2 changes: 1 addition & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -18,4 +18,4 @@ targetdir
# Velosiraptor output directory
outlogs
out
logs
logs
19 changes: 15 additions & 4 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -23,12 +23,13 @@ members = [
,"lib/velosicodegen"
,"lib/velosihwgen/"
,"lib/velosicomposition"
,"lib/z3/z3-sys"
]

# ,"lib/z3/z3-sys"

[dependencies]
# argument parsing
clap = { version = "4.3.5", features = [ "derive" ] }
clap = { version = "4.5.8", features = [ "derive" ] }

# for colorful output
colored = "2"
Expand All @@ -41,20 +42,26 @@ velosihwgen = { path = "lib/velosihwgen" }

# logging and errors
log = { version = "0.4.19", features = ["max_level_trace", "release_max_level_warn"] }
simplelog = { version = "^0.12.0", features = ["paris"] }
simplelog = { version = "^0.12.2", features = ["paris"] }

# dependencies for testing
[dev-dependencies]
strip-ansi-escapes = "0.1.1"
rexpect = "0.5"
velosiparser = { path = "lib/velosiraptor-parser" }
velosicomposition = {path = "lib/velosicomposition" }
chrono = "0.4.38"
indicatif = "0.17.8"

[build-dependencies]
vergen = { version = "8.3.1", features = ["build", "git", "gitcl", "si"] }
anyhow = "1.0.86"


# enable optimizations for the tests
[profile.test]
opt-level = 3


# benchmarking

[[bench]]
Expand All @@ -63,4 +70,8 @@ harness = false

[[bench]]
name = "opt"
harness = false

[[bench]]
name = "runtime"
harness = false
54 changes: 0 additions & 54 deletions benches/opt/bench.rs
Original file line number Diff line number Diff line change
@@ -1,58 +1,4 @@
pub const NUM_WORKERS: usize = 14;
pub const ITERATIONS: usize = 100;

pub struct Stats {
pub min: u128,
pub med: u128,
pub avg: u128,
pub max: u128,
pub var: u128,
pub std: u128,
pub num: usize,
}

impl From<&[u128]> for Stats {
fn from(stats: &[u128]) -> Self {
let mut data = stats.to_vec();

if data.is_empty() {
return Self {
min: 0,
med: 0,
avg: 0,
max: 0,
var: 0,
std: 0,
num: 0,
};
}

data.sort();

let sum = data.iter().sum::<u128>() as u128;
let num = data.len();
let avg = sum / num as u128;

let var = data.iter().map(|x| (x - avg) * (x - avg)).sum::<u128>() as u128 / num as u128;
let std = (var as f64).sqrt() as u128;
Self {
min: *data.first().unwrap(),
med: data[num / 2],
avg,
max: *data.last().unwrap(),
var,
std,
num,
}
}
}

impl From<&[usize]> for Stats {
fn from(stats: &[usize]) -> Self {
let data: Vec<u128> = stats.iter().map(|x| *x as u128).collect();
Stats::from(data.as_slice())
}
}

pub struct BenchResults {
pub tag: String,
Expand Down
Loading
Loading