fix and optim for compareTrace