Commit 4bf22cc
authored
[SYCL] Fix host-to-host copy during copyback (#1692)
Copyback is performed unconditionally during buffer destruction, so
it's possible for it to perform a copy from and to the same host
pointer. This patch adds a check for this scenario so that we don't rely
on undefined behaviour of std::memcpy.
Signed-off-by: Sergey Semenov <sergey.semenov@intel.com>1 parent ad575b5 commit 4bf22cc
1 file changed
+6
-4
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
358 | 358 | | |
359 | 359 | | |
360 | 360 | | |
361 | | - | |
362 | | - | |
| 361 | + | |
| 362 | + | |
| 363 | + | |
| 364 | + | |
| 365 | + | |
363 | 366 | | |
364 | 367 | | |
365 | 368 | | |
366 | | - | |
367 | | - | |
| 369 | + | |
368 | 370 | | |
369 | 371 | | |
370 | 372 | | |
| |||
0 commit comments