DPC++ daily 2022-11-01
Pre-release
Pre-release
·
141027 commits
to sycl
since this release
[SYCL] Fix sycl-prof JSON output (#7128)
This patch fixes a problem related to the JSON output. Every element of
`"traceEvents"` has a comma appended, this is a problem in the case of
the last element, e.g.,
```
{
"traceEvents": [
...
{"name": "piTearDown", ... , "ts": "16..81"}, <-- here is
],
"displayTimeUnit":"ns"
}
```
This comma prevents the display of the JSON output in
`chrome://tracing/` or [speedscope](https://www.speedscope.app/) due to
its invalid format. This patch solves the problem by adding an empty
element before finalizing the JSON output.