vcdWriter - refactored to only output a timestamp when values changed