};
}
CyclicBarrier entryBarrier = new CyclicBarrier(2);
CyclicBarrier exitBarrier = new CyclicBarrier(3);
new BarrierThread(new Runnable() {
@Override
public void run() {
for (int i = 0; i < iterTimes; i++) {
fsm1.fire(FSMEvent.ToA, 10);
fsm1.fire(FSMEvent.ToB, 10);
fsm1.fire(FSMEvent.ToC, 10);
fsm1.fire(FSMEvent.ToD, 10);
}
}
}, "Performance-Test-Thread-1", entryBarrier, exitBarrier).start();
new BarrierThread(new Runnable() {
@Override
public void run() {
for (int i = 0; i < iterTimes; i++) {
fsm2.fire(FSMEvent.ToA, 10);
fsm2.fire(FSMEvent.ToB, 10);