@@ -83,15 +83,17 @@ static void run_batch(struct measuresuite *ms, struct function_tuple *fct,
83
83
84
84
int (* func )(uint64_t * out , ...) = fct -> code ;
85
85
assert (func != NULL );
86
- DEBUG ("Function to evaluate is not NULL. Running with a batch size of %d\n" ,
87
- batch_size );
86
+ DEBUG ("Function to evaluate is not NULL (%p). Running with a batch size of "
87
+ "%lu" ,
88
+ func , batch_size );
88
89
89
90
while (batch_size > 0 ) {
90
91
func (arg0 , arg1 , arg2 , arg3 , arg4 , arg5 );
91
92
batch_size -- ;
92
93
}
93
94
94
95
* count = stop_timer (ms , start_time );
96
+ DEBUG ("Done. Ran for %lu cycles.\n" , count );
95
97
}
96
98
97
99
int run_measurement (struct measuresuite * ms ) {
@@ -105,14 +107,14 @@ int run_measurement(struct measuresuite *ms) {
105
107
// START MEASUREMENT
106
108
uint64_t start_time = current_timestamp ();
107
109
108
- DEBUG ("Evaluating %d batches %d \n" , ms -> num_batches );
110
+ DEBUG ("Evaluating %lu batches\n" , ms -> num_batches );
109
111
for (size_t batch_i = 0 ; batch_i < ms -> num_batches ; batch_i ++ ) {
110
112
111
113
if (randomize (ms ) != 0 || shuffle_permutations (ms ) != 0 ) {
112
114
return 1 ;
113
115
}
114
116
115
- DEBUG ("Evaluating %d function %d \n" , ms -> num_functions );
117
+ DEBUG ("Evaluating %lu functions \n" , ms -> num_functions );
116
118
// for as many functions as we need to measure
117
119
for (size_t func_i = 0 ; func_i < ms -> num_functions ; func_i ++ ) {
118
120
@@ -121,7 +123,7 @@ int run_measurement(struct measuresuite *ms) {
121
123
struct function_tuple * fct = & ms -> functions [function_index ];
122
124
123
125
// measure
124
- DEBUG ("Run batch for function %d \n" , batch_i );
126
+ DEBUG ("Run batch %lu for function %lu \n" , batch_i , function_index );
125
127
run_batch (ms , fct , & fct -> cycle_results [batch_i ]);
126
128
}
127
129
@@ -134,7 +136,7 @@ int run_measurement(struct measuresuite *ms) {
134
136
struct function_tuple * prev = & ms -> functions [func_i - 1 ];
135
137
136
138
// check
137
- DEBUG ("Checking correctness for function %d and previous\n" , func_i );
139
+ DEBUG ("Checking correctness for function %lu and previous\n" , func_i );
138
140
if (check (ms -> arg_width * ms -> num_arg_out , fct -> arithmetic_results ,
139
141
prev -> arithmetic_results )) {
140
142
check_result = func_i ;
0 commit comments