Skip to content

Commit

Permalink
Working server client code with throughputs
Browse files Browse the repository at this point in the history
  • Loading branch information
sharathvemula committed Feb 1, 2023
1 parent 2c96011 commit debbb52
Show file tree
Hide file tree
Showing 26 changed files with 57,335 additions and 41 deletions.
10 changes: 6 additions & 4 deletions waffleClient/benchmark/src/proxy_benchmark.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -91,25 +91,25 @@ void run_benchmark(int run_time, bool stats, std::vector<int> &latencies, int cl
ops = client.num_requests_satisfied();
}
uint64_t start, end;
std::cout << "Entering proxy_benchmark.cpp line " << __LINE__ << std::endl;
//std::cout << "Entering proxy_benchmark.cpp line " << __LINE__ << std::endl;
auto ticks_per_ns = static_cast<double>(rdtscuhz()) / 1000;
auto s = std::chrono::high_resolution_clock::now();
auto e = std::chrono::high_resolution_clock::now();
int elapsed = 0;
std::vector<std::string> results;
int i = 0;
while (elapsed < run_time*1000000) {
std::cout << "Entering proxy_benchmark.cpp line " << __LINE__ << "i = " << i << std::endl;
//std::cout << "Entering proxy_benchmark.cpp line " << __LINE__ << "i = " << i << std::endl;
if (stats) {
rdtscll(start);
}
auto keys_values_pair = trace[i];
if (keys_values_pair.second.empty()){
std::cout << "Entering proxy_benchmark.cpp line " << __LINE__ << std::endl;
//std::cout << "Entering proxy_benchmark.cpp line " << __LINE__ << std::endl;
client.get_batch(keys_values_pair.first);
}
else {
std::cout << "Entering proxy_benchmark.cpp line " << __LINE__ << std::endl;
//std::cout << "Entering proxy_benchmark.cpp line " << __LINE__ << std::endl;
client.put_batch(keys_values_pair.first, keys_values_pair.second);
}
if (stats) {
Expand Down Expand Up @@ -165,6 +165,8 @@ void client(int idx, int client_batch_size, int object_size, trace_vector &trace
line.append("Xput: " + std::to_string(indiv_xput) + "\n");
out << line;
xput += indiv_xput;
std::cout << "indiv_xput is: " << indiv_xput << std::endl;
std::cout << "xput is: " << xput << std::endl;
std::cout << "Beginning cooldown" << std::endl;
cooldown(latencies, client_batch_size, object_size, trace, indiv_xput, client);

Expand Down
Binary file modified waffleClient/bin/proxy_benchmark
Binary file not shown.
Binary file modified waffleClient/bin/proxy_server
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
4 changes: 4 additions & 0 deletions waffleClient/data/MonJan3015:31/1
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
1798723382
2047266175
2048025716
Xput: 0
4 changes: 4 additions & 0 deletions waffleClient/data/MonJan3015:36/1
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
1797887446
2048036054
2047981439
Xput: 0
4 changes: 4 additions & 0 deletions waffleClient/data/MonJan3015:38/1
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
1798691835
2047215497
2047995562
Xput: 0
4 changes: 4 additions & 0 deletions waffleClient/data/MonJan3015:42/1
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
1797871202
2048008715
2047989369
Xput: 0
4 changes: 4 additions & 0 deletions waffleClient/data/MonJan3015:45/1
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
1797884047
2047990240
2047982465
Xput: 0
6 changes: 6 additions & 0 deletions waffleClient/data/TueJan3117:51/1
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
8098
1797793409
68732
2047806452
2047885064
Xput: 0
Loading

0 comments on commit debbb52

Please sign in to comment.