Moves the responsibility of opening the trace file into TraceDump::new, so that it doesn't need to be repeated at every call site.
This commit adds the `--profiler-trace-path` flag. When combined with `-p` to enable profiling, it dumps a profile as a self-contained HTML file to the given path. The profile visualizes the traced operations as a gant-chart style timeline.