Skip to content

Commit

Permalink
A workign configuration.
Browse files Browse the repository at this point in the history
Signed-off-by: Gerd Zellweger <mail@gerdzellweger.com>
  • Loading branch information
gz committed Nov 20, 2023
1 parent ec595d2 commit 1a56277
Show file tree
Hide file tree
Showing 4 changed files with 11 additions and 5 deletions.
2 changes: 2 additions & 0 deletions kernel/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -103,6 +103,8 @@ rackscale = ["rpc"]
gdb = []
# Use to enable 4kiB only in kernel - useful for memcached, similar benchmarks
pages-4k = []
# dynrep benchmarking
dynrep = []

#
# The following features are used for testing *only* and should not be enabled
Expand Down
3 changes: 2 additions & 1 deletion kernel/src/arch/x86_64/irq.rs
Original file line number Diff line number Diff line change
Expand Up @@ -528,7 +528,8 @@ unsafe fn timer_handler(_a: &ExceptionArguments) {
nrproc::NrProcess::<Ring3Process>::synchronize(pid);
}

if *crate::environment::MT_ID == 0 {
#[cfg(feature = "dynrep")]
if *crate::environment::MT_ID == 4 {
use crate::arch::process::current_pid;
let pid = current_pid().expect("dont have a pid?");

Expand Down
7 changes: 5 additions & 2 deletions kernel/tests/s11_rackscale_benchmarks.rs
Original file line number Diff line number Diff line change
Expand Up @@ -671,6 +671,7 @@ fn s11_rackscale_memcached_dynrep_benchmark_internal() {
.user_feature("rkapps:memcached-bench")
.set_rackscale(true)
.kernel_feature("pages-4k")
.kernel_feature("dynrep")
.release()
.build();

Expand Down Expand Up @@ -776,17 +777,19 @@ fn s11_rackscale_memcached_dynrep_benchmark_internal() {
let r = csv_file.write("\n".as_bytes());
assert!(r.is_ok());

println!("> {}", output);

Ok(())
}

let config = if is_smoke {
MemcachedInternalConfig {
num_queries: 100_000,
num_queries: 100_000_000,
mem_size: 16,
}
} else {
MemcachedInternalConfig {
num_queries: 1_000_000, // TODO(rackscale): should be 100_000_000,
num_queries: 100_000_000, // TODO(rackscale): should be 100_000_000,
mem_size: 16, // TODO(rackscale): should be 32_000,
}
};
Expand Down
4 changes: 2 additions & 2 deletions usr/rkapps/build.rs
Original file line number Diff line number Diff line change
Expand Up @@ -138,11 +138,11 @@ fn main() {
.unwrap();

println!(
"CHECKOUT be303d8bfc2c40d63704848bb3acd9e075dd61e4 {:?}",
"CHECKOUT 1f36e49a3c5fc529cd80278a1bd73b9941c813e6 {:?}",
out_dir
);
Command::new("git")
.args(&["checkout", "be303d8bfc2c40d63704848bb3acd9e075dd61e4"])
.args(&["checkout", "1f36e49a3c5fc529cd80278a1bd73b9941c813e6"])
.current_dir(&Path::new(&out_dir))
.status()
.unwrap();
Expand Down

0 comments on commit 1a56277

Please sign in to comment.