Mesa (refs/tags/good-3): nouveau: use BO_VRAM on USAGE_DYNAMIC

Emil Velikov evelikov at kemper.freedesktop.org
Mon Sep 1 00:17:34 UTC 2014


Module: Mesa
Branch: refs/tags/good-3
Commit: 7cec56ae838f29156f1d3931792d69ec679a7264
URL:    http://cgit.freedesktop.org/mesa/mesa/commit/?id=7cec56ae838f29156f1d3931792d69ec679a7264

Author: Emil Velikov <emil.l.velikov at gmail.com>
Date:   Thu Jun 13 01:28:53 2013 +0100

nouveau: use BO_VRAM on USAGE_DYNAMIC

Signed-off-by: Emil Velikov <emil.l.velikov at gmail.com>

---

 src/gallium/drivers/nouveau/nouveau_buffer.c |    5 +++++
 1 file changed, 5 insertions(+)

diff --git a/src/gallium/drivers/nouveau/nouveau_buffer.c b/src/gallium/drivers/nouveau/nouveau_buffer.c
index 8502269..0741b9b 100644
--- a/src/gallium/drivers/nouveau/nouveau_buffer.c
+++ b/src/gallium/drivers/nouveau/nouveau_buffer.c
@@ -435,6 +435,11 @@ nouveau_buffer_create(struct pipe_screen *pscreen,
          buffer->domain = NOUVEAU_BO_VRAM;
          break;
       case PIPE_USAGE_DYNAMIC:
+         /* For most apps, we'd have to do staging transfers to avoid sync
+          * with this usage, and GART -> GART copies would be suboptimal.
+          */
+         buffer->domain = NOUVEAU_BO_VRAM;
+         break;
       case PIPE_USAGE_STAGING:
       case PIPE_USAGE_STREAM:
          buffer->domain = NOUVEAU_BO_GART;




More information about the mesa-commit mailing list