auto-sync
This commit is contained in:
parent
c17a80040b
commit
555110df43
|
@ -134,6 +134,8 @@ static void testMath(const int count) {
|
||||||
}
|
}
|
||||||
time = currentTimeMillis() - start;
|
time = currentTimeMillis() - start;
|
||||||
if (tempi == 0) {
|
if (tempi == 0) {
|
||||||
|
// 11ms is 1848000 ticks
|
||||||
|
// 18.48 ticks per iteration
|
||||||
// Finished 100000 iterations of uint32_t summation in 11ms
|
// Finished 100000 iterations of uint32_t summation in 11ms
|
||||||
scheduleMsg(logger, "Finished %d iterations of uint32_t summation in %dms", count, time);
|
scheduleMsg(logger, "Finished %d iterations of uint32_t summation in %dms", count, time);
|
||||||
}
|
}
|
||||||
|
@ -181,6 +183,19 @@ static void testMath(const int count) {
|
||||||
scheduleMsg(logger, "Finished %d iterations of float summation in %dms", count, time);
|
scheduleMsg(logger, "Finished %d iterations of float summation in %dms", count, time);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
start = currentTimeMillis();
|
||||||
|
tempf = 1;
|
||||||
|
for (int i = 0; i < count; i++) {
|
||||||
|
tempf += tempf * 130.0f;
|
||||||
|
}
|
||||||
|
time = currentTimeMillis() - start;
|
||||||
|
if (tempf != 0) {
|
||||||
|
// ms = ticks
|
||||||
|
// ticks per iteration
|
||||||
|
// Finished 100000 iterations of float division in ms
|
||||||
|
scheduleMsg(logger, "Finished %d iterations of float multiplication in %dms", count, time);
|
||||||
|
}
|
||||||
|
|
||||||
start = currentTimeMillis();
|
start = currentTimeMillis();
|
||||||
tempf = 1;
|
tempf = 1;
|
||||||
for (int i = 0; i < count; i++) {
|
for (int i = 0; i < count; i++) {
|
||||||
|
@ -188,6 +203,8 @@ static void testMath(const int count) {
|
||||||
}
|
}
|
||||||
time = currentTimeMillis() - start;
|
time = currentTimeMillis() - start;
|
||||||
if (tempf != 0) {
|
if (tempf != 0) {
|
||||||
|
// 65 ms = 10920000 ticks
|
||||||
|
// 109.2 ticks per iteration
|
||||||
// Finished 100000 iterations of float division in 65ms
|
// Finished 100000 iterations of float division in 65ms
|
||||||
scheduleMsg(logger, "Finished %d iterations of float division in %dms", count, time);
|
scheduleMsg(logger, "Finished %d iterations of float division in %dms", count, time);
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue