From aead71051ed757e7565d395c858bf8ab8f0b0ff6 Mon Sep 17 00:00:00 2001 From: Chris Wilson Date: Fri, 11 Jan 2013 01:30:43 +0000 Subject: [PATCH] sna: Disable memcpy_to_tiled_x() uploads on 32-bit systems It's far too slow due to the register starved instruction set producing attrocious code and the extra overhead in the kernel for managing memory mappings. Signed-off-by: Chris Wilson --- src/sna/sna_io.c | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/src/sna/sna_io.c b/src/sna/sna_io.c index ec254fc5..8b4c25ef 100644 --- a/src/sna/sna_io.c +++ b/src/sna/sna_io.c @@ -483,6 +483,15 @@ fallback: static bool upload_inplace__tiled(struct kgem *kgem, struct kgem_bo *bo) { +#ifndef __x86_64__ + /* Between a register starved compiler emitting attrocious code + * and the extra overhead in the kernel for managing the tight + * 32-bit address space, unless we have a 64-bit system, + * using memcpy_to_tiled_x() is extremely slow. + */ + return false; +#endif + if (kgem->gen < 050) /* bit17 swizzling :( */ return false;