mirror of
https://github.com/nosqlbench/nosqlbench.git
synced 2025-02-25 18:55:28 -06:00
minor fixes
This commit is contained in:
@@ -64,7 +64,7 @@ public class AtomicInput implements Input, ActivityDefObserver, Gauge<Long>, NBL
|
||||
this.activityDef = activityDef;
|
||||
onActivityDefUpdate(activityDef);
|
||||
ActivityMetrics.gauge(this, "input_cycles_first", new NBFunctionGauge(this, () -> (double)this.cycles_min.get()));
|
||||
ActivityMetrics.gauge(this, "input_cycles_last", new NBFunctionGauge(this, () -> (double)this.cycles_min.get()));
|
||||
ActivityMetrics.gauge(this, "input_cycles_last", new NBFunctionGauge(this, () -> (double)this.cycles_max.get()));
|
||||
ActivityMetrics.gauge(this, "input_cycle", new NBFunctionGauge(this, () -> (double)this.cycle_value.get()));
|
||||
ActivityMetrics.gauge(this, "input_cycles_total", new NBFunctionGauge(this, this::getTotalCycles));
|
||||
ActivityMetrics.gauge(this, "input_recycles_first", new NBFunctionGauge(this, () -> (double)this.recycles_min.get()));
|
||||
|
||||
@@ -51,7 +51,7 @@ public class LongTreeTracker {
|
||||
|
||||
/**
|
||||
* Apply an index value between 0 and 31 inclusive. Return the accumulator.
|
||||
* If all 32 slots of this tracker have been isCycleCompleted, the returned value will
|
||||
* If all 32 slots of this tracker have been completed, the returned value will
|
||||
* have LSB bit 2 set.
|
||||
* @param index a long value between 0 and 31 to mark as complete
|
||||
* @param image the long value which serves as the starting state of the bit field
|
||||
@@ -62,19 +62,14 @@ public class LongTreeTracker {
|
||||
|
||||
while (position > 0) {
|
||||
long applybt = 1L << position;
|
||||
// System.out.println("applybt:\n" + diagString(applybt));
|
||||
// System.out.print("image:\n" + this);
|
||||
image |= applybt;
|
||||
long comask = applybt | (applybt & eens) >> 1 | (applybt & odds) << 1;
|
||||
// System.out.println("comask:\n" + diagString(comask));
|
||||
if ((comask & image) != comask) {
|
||||
long co_mask = applybt | (applybt & eens) >> 1 | (applybt & odds) << 1;
|
||||
if ((co_mask & image) != co_mask) {
|
||||
break;
|
||||
}
|
||||
position >>= 1;
|
||||
}
|
||||
// System.out.println("image:\n" + this);
|
||||
// TODO Fix this test
|
||||
return image;
|
||||
return image;
|
||||
}
|
||||
|
||||
public long setCompleted(long index) {
|
||||
|
||||
@@ -57,4 +57,10 @@ public class Colors {
|
||||
public static String ANSI_BrightWhiteBG = (char) 27 + "[107m";
|
||||
|
||||
public static String ANSI_Reset = (char) 27 + "[39;49m";
|
||||
|
||||
public static String ANSI_CURSOR_LEFT = (char) 27 + "[1D";
|
||||
|
||||
public static String ANSI_CURSOR_LEFT(int distance) {
|
||||
return (char) 27 + "[" + distance + "D";
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user