changed marshaller to generate tests as serialization format. Added helper for building traces making generated code much more readable. Missing is proper handling of thread ids