diff options
author | Chia-I Wu <[email protected]> | 2019-07-16 16:48:03 -0700 |
---|---|---|
committer | Chia-I Wu <[email protected]> | 2019-07-19 18:04:42 -0700 |
commit | d31d25f634abe787552eba8526db9f901a257d9c (patch) | |
tree | 7773fb61f8064cad9763c8ed228f6197f5d1f67f /CleanSpec.mk | |
parent | 324c20304e82fc1e36cd0d293653bf1533edc854 (diff) |
virgl: fix a sync issue in virgl_buffer_transfer_extend
In virgl_buffer_transfer_extend, when no flush is needed, it tries
to extend a previously queued transfer instead if it can find one.
Comparing to virgl_resource_transfer_prepare, it fails to check if
the resource is busy.
The existence of a previously queued transfer normally implies that
the resource is not busy, maybe except for when the transfer is
PIPE_TRANSFER_UNSYNCHRONIZED. Rather than burdening us with a
lengthy comment, and potential concerns over breaking it as the
transfer code evolves, this commit makes the valid_buffer_range
check the only condition to take the fast path.
In real world, we hit the fast path almost only because of the
valid_buffer_range check. In micro benchmarks, the condition should
always be true, otherwise the benchmarks are not very representative
of meaningful workloads. I think this fix is justified.
The recent change to PIPE_TRANSFER_MAP_DIRECTLY usage disables the
fast path. This commit re-enables it as well.
Signed-off-by: Chia-I Wu <[email protected]>
Reviewed-by: Gurchetan Singh <[email protected]>
Diffstat (limited to 'CleanSpec.mk')
0 files changed, 0 insertions, 0 deletions