diff options
author | Luca Barbieri <[email protected]> | 2010-08-15 07:37:31 +0200 |
---|---|---|
committer | Luca Barbieri <[email protected]> | 2010-08-16 17:13:17 +0200 |
commit | f201217c1d87919572a3b1cf7de94f580f20e5f0 (patch) | |
tree | 1b53305a5ade7b6c75cdbb335f3ab84f3bb1f05e /src/gallium/auxiliary/draw/draw_llvm.c | |
parent | c2da8e77023325f46dde2009def2947b1a687c7b (diff) |
draw_llvm: fix segfaults on non-SSE2 CPUs where it is disabled (v2)
Changes in v2:
- Change function name
Currently draw_llvm refuses to create itself on non-SSE2 CPUs due to
an alleged LLVM bug.
However, this is implemented improperly, because other parts of draw
still attempt to access draw->llvm, resulting in segfaults.
Instead, put the check in debug_get_option_draw_use_llvm, check that
before calling draw_llvm_create, and then check whether draw->llvm is
non-null everywhere else.
Diffstat (limited to 'src/gallium/auxiliary/draw/draw_llvm.c')
-rw-r--r-- | src/gallium/auxiliary/draw/draw_llvm.c | 7 |
1 files changed, 0 insertions, 7 deletions
diff --git a/src/gallium/auxiliary/draw/draw_llvm.c b/src/gallium/auxiliary/draw/draw_llvm.c index 8d53601d195..58d3e345e5f 100644 --- a/src/gallium/auxiliary/draw/draw_llvm.c +++ b/src/gallium/auxiliary/draw/draw_llvm.c @@ -210,13 +210,6 @@ draw_llvm_create(struct draw_context *draw) { struct draw_llvm *llvm; -#ifdef PIPE_ARCH_X86 - util_cpu_detect(); - /* require SSE2 due to LLVM PR6960. */ - if (!util_cpu_caps.has_sse2) - return NULL; -#endif - llvm = CALLOC_STRUCT( draw_llvm ); if (!llvm) return NULL; |