From 3eb557778376bcbbc6f25da88ffbaa269607254c Mon Sep 17 00:00:00 2001 From: Marek Olšák Date: Fri, 16 Jul 2010 12:53:40 +0200 Subject: r300g: do not make copies of constant buffers, emit them directly --- src/gallium/winsys/radeon/drm/radeon_r300.c | 11 +---------- src/gallium/winsys/radeon/drm/radeon_winsys.h | 2 -- 2 files changed, 1 insertion(+), 12 deletions(-) (limited to 'src/gallium/winsys/radeon/drm') diff --git a/src/gallium/winsys/radeon/drm/radeon_r300.c b/src/gallium/winsys/radeon/drm/radeon_r300.c index 4e89c070831..effa27f5c72 100644 --- a/src/gallium/winsys/radeon/drm/radeon_r300.c +++ b/src/gallium/winsys/radeon/drm/radeon_r300.c @@ -83,9 +83,7 @@ radeon_r300_winsys_buffer_create(struct r300_winsys_screen *rws, desc.usage = get_pb_usage_from_create_flags(bind, usage, domain); /* Assign a buffer manager. */ - if (bind & PIPE_BIND_CONSTANT_BUFFER) - provider = ws->mman; - else if (bind & (PIPE_BIND_VERTEX_BUFFER | PIPE_BIND_INDEX_BUFFER)) + if (bind & (PIPE_BIND_VERTEX_BUFFER | PIPE_BIND_INDEX_BUFFER)) provider = ws->cman; else provider = ws->kman; @@ -251,7 +249,6 @@ static void radeon_winsys_destroy(struct r300_winsys_screen *rws) ws->cman->destroy(ws->cman); ws->kman->destroy(ws->kman); - ws->mman->destroy(ws->mman); radeon_bo_manager_gem_dtor(ws->bom); radeon_cs_manager_gem_dtor(ws->csm); @@ -273,10 +270,6 @@ boolean radeon_setup_winsys(int fd, struct radeon_libdrm_winsys* ws) if (!ws->cman) goto fail; - ws->mman = pb_malloc_bufmgr_create(); - if (!ws->mman) - goto fail; - ws->base.destroy = radeon_winsys_destroy; ws->base.get_value = radeon_get_value; @@ -312,8 +305,6 @@ fail: ws->cman->destroy(ws->cman); if (ws->kman) ws->kman->destroy(ws->kman); - if (ws->mman) - ws->mman->destroy(ws->mman); return FALSE; } diff --git a/src/gallium/winsys/radeon/drm/radeon_winsys.h b/src/gallium/winsys/radeon/drm/radeon_winsys.h index 9a25e7679c9..533b7b2e2d2 100644 --- a/src/gallium/winsys/radeon/drm/radeon_winsys.h +++ b/src/gallium/winsys/radeon/drm/radeon_winsys.h @@ -40,8 +40,6 @@ struct radeon_libdrm_winsys { struct pb_manager *cman; - struct pb_manager *mman; - /* PCI ID */ uint32_t pci_id; -- cgit v1.2.3