Commit 9801f493 authored by Scott Bauer's avatar Scott Bauer
Browse files

Fixed a few things


Signed-off-by: default avatarScott Bauer <sbauer@node0.xcap-ipc.xcap.emulab.net>
parent 220de0e3
obj-m := test.o
CFLAGS_test.o = -DDEBUG -DDEBUG_MWAIT_RETRY -DDEBUG_BOUNDS_CHECK -DTIMING -g -Wall
CFLAGS_betaModule2.o = -DDEBUG -DDEBUG_MWAIT_RETRY -DDEBUG_BOUNDS_CHECK -DTIMING -g -Wall
CFLAGS_ring-channel.o = -DDEBUG -DDEBUG_MWAIT_RETRY -DDEBUG_BOUNDS_CHECK -DTIMING -g -Wall
#CFLAGS_test.o = -DDEBUG -DDEBUG_MWAIT_RETRY -DTIMING -g -Wall
#CFLAGS_betaModule2.o = -DDEBUG -DDEBUG_MWAIT_RETRY -DTIMING -g -Wall
#CFLAGS_ring-channel.o = -DDEBUG -DDEBUG_MWAIT_RETRY -DTIMING -g -Wall
#CFLAGS_test.o = -O2
#CFLAGS_betaModule2.o = -O2
#CFLAGS_ring-channel.o = -O2
CFLAGS_test.o = -O2 -DTIMING
CFLAGS_betaModule2.o = -O2 -DTIMING
CFLAGS_ring-channel.o = -O2
test-objs := ./ring-chan/ring-channel.o ./betaModule2.o
......
obj-m := betaModule1.o
CFLAGS_betaModule1.o = -DDEBUG -DDEBUG_MWAIT_RETRY -DDEBUG_BOUNDS_CHECK -DTIMING -g -Wall
CFLAGS_betaModule.o = -DDEBUG -DDEBUG_MWAIT_RETRY -DDEBUG_BOUNDS_CHECK -DTIMING -g -Wall
CFLAGS_ring-channel.o = -DDEBUG -DDEBUG_MWAIT_RETRY -DDEBUG_BOUNDS_CHECK -DTIMING -g -Wall
#CFLAGS_betaModule1.o = -DDEBUG -DDEBUG_MWAIT_RETRY -DTIMING -g -Wall
#CFLAGS_betaModule.o = -DDEBUG -DDEBUG_MWAIT_RETRY -DTIMING -g -Wall
#CFLAGS_ring-channel.o = -DDEBUG -DDEBUG_MWAIT_RETRY -DTIMING -g -Wall
#CFLAGS_betaModule1.o = -O2
#CFLAGS_betaModule.o = -O2
#CFLAGS_ring-channel.o = -O2
CFLAGS_betaModule1.o = -O2 -DTIMING
CFLAGS_betaModule.o = -O2 -DTIMING
CFLAGS_ring-channel.o = -O2
betaModule1-objs := ./ring-chan/ring-channel.o ./betaModule.o
......
......@@ -434,13 +434,24 @@ static long beta_return_mem(struct ipc_container *container,
static void dump_time(void)
{
int i;
unsigned long long counter = 0;
u64 min;
u64 max;
if (timekeeper == NULL) {
pr_err("Time keeper was null, ret");
return;
}
for (i = 0; i < NUM_LOOPS; i++)
pr_err("CPU %d RTT %lu\n", CPU_NUM, timekeeper[i]);
min = timekeeper[0];
max = min;
for (i = 0; i < NUM_LOOPS; i++) {
counter+= timekeeper[i];
if(timekeeper[i] > max)
max = timekeeper[i];
if(timekeeper[i] < min)
min = timekeeper[i];
}
pr_err("TIME STATS MIN %u, MAX %u, AVG %u\n", min, max, counter/NUM_LOOPS);
}
......
......@@ -154,10 +154,10 @@ int main(int argc, char **argv)
/* PROBBALY KERNEL PANICKING HARD BY NOW OR STALLED 2 CPUS*/
printf_v("[*] THREADS UNPARKED, SLEEPING FOR 2 SEC \n");
sleep(60);
sleep(10);
print_stats(beta1);
sleep(3);
print_stats(beta2);
// sleep(3);
// print_stats(beta2);
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment