Commit 37a74c7
authored
[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.1 parent 0c541bd commit 37a74c7
1 file changed
+4
-0
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
72 | 72 | | |
73 | 73 | | |
74 | 74 | | |
| 75 | + | |
| 76 | + | |
| 77 | + | |
| 78 | + | |
75 | 79 | | |
76 | 80 | | |
77 | 81 | | |
| |||
0 commit comments