[Mesa-dev] [PATCH 4/4] radeonsi: use SDMA for uploading data through const_uploader

Axel Davy davyaxel0 at gmail.com
Thu Feb 7 19:47:46 UTC 2019


On 07/02/2019 02:22, Marek Olšák wrote:
>   
> +	bool use_sdma_upload = sscreen->info.has_dedicated_vram && sctx->dma_cs && debug_get_bool_option("SDMA", true);
> +	sctx->b.const_uploader = u_upload_create(&sctx->b, 256 * 1024,
> +						 0, PIPE_USAGE_DEFAULT,
> +						 SI_RESOURCE_FLAG_32BIT |
> +						 (use_sdma_upload ?
> +							  SI_RESOURCE_FLAG_UPLOAD_FLUSH_EXPLICIT_VIA_SDMA :
> +							  (sscreen->cpdma_prefetch_writes_memory ?
> +								   0 : SI_RESOURCE_FLAG_READ_ONLY)));
> +	if (!sctx->b.const_uploader)
> +		goto fail;
> +
> +	if (use_sdma_upload)
> +		u_upload_enable_flush_explicit(sctx->b.const_uploader);
> +


I see that APU are not affected by the change.

Are they affected by the issue this patch aims to fix though ? If so, 
wouldn't it make sense to switch to PIPE_USAGE_STREAM for APUs ?


Axel



More information about the mesa-dev mailing list