Merge remote-tracking branch 'origin/master' into f20

This commit is contained in:
Adam Jackson 2014-04-15 13:36:13 -04:00
commit b2a76586a8
7 changed files with 212 additions and 1056 deletions

6
.gitignore vendored
View file

@ -62,4 +62,8 @@ mesa-20100720.tar.bz2
/mesa-20131206.tar.xz
/mesa-20131220.tar.xz
/mesa-20140206.tar.xz
/mesa-20140312.tar.xz
/mesa-20140208.tar.xz
/mesa-20140222.tar.xz
/mesa-20140225.tar.xz
/mesa-20140301.tar.xz
/mesa-20140305.tar.xz

View file

@ -0,0 +1,34 @@
From 1fb986f3a722e8476af90b5ab512e495f0caf10f Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Kristian=20H=C3=B8gsberg?= <krh@bitplanet.net>
Date: Thu, 6 Mar 2014 16:58:32 -0800
Subject: [PATCH] mesa: Don't optimize out glClear() if drawbuffer size is 0x0
The driver acquires buffer lazily and may not yet have buffers for
a newly current drawable. In that case the drawable size is 0x0 but
we still need to call into the driver and make it fetch buffers and get
the drawable size.
https://bugs.freedesktop.org/show_bug.cgi?id=75797
---
src/mesa/main/clear.c | 5 -----
1 file changed, 5 deletions(-)
diff --git a/src/mesa/main/clear.c b/src/mesa/main/clear.c
index 077c5fc..c3f7474 100644
--- a/src/mesa/main/clear.c
+++ b/src/mesa/main/clear.c
@@ -155,11 +155,6 @@ _mesa_Clear( GLbitfield mask )
return;
}
- if (ctx->DrawBuffer->Width == 0 || ctx->DrawBuffer->Height == 0 ||
- ctx->DrawBuffer->_Xmin >= ctx->DrawBuffer->_Xmax ||
- ctx->DrawBuffer->_Ymin >= ctx->DrawBuffer->_Ymax)
- return;
-
if (ctx->RasterDiscard)
return;
--
1.8.5.3

File diff suppressed because it is too large Load diff

View file

@ -15,11 +15,11 @@ DIRNAME=mesa-$( date +%Y%m%d )
echo REF ${REF:+--reference $REF}
echo DIRNAME $DIRNAME
echo HEAD ${1:-10.0}
echo HEAD ${1:-10.1}
rm -rf $DIRNAME
git clone --depth 1 ${REF:+--reference $REF} --branch 10.0 \
git clone --depth 1 ${REF:+--reference $REF} --branch 10.1 \
git://git.freedesktop.org/git/mesa/mesa $DIRNAME
GIT_DIR=$DIRNAME/.git git archive --format=tar --prefix=$DIRNAME/ ${1:-HEAD} \

View file

@ -7,10 +7,14 @@
%define with_wayland 1
%endif
%ifarch ppc64le
%undefine with_vdpau
%endif
# S390 doesn't have video cards, but we need swrast for xserver's GLX
# llvm (and thus llvmpipe) doesn't actually work on ppc32 or s390
%ifnarch s390 ppc
%ifnarch s390 ppc ppc64le
%define with_llvm 1
%endif
@ -23,9 +27,9 @@
%define with_freedreno 1
%endif
%ifarch s390 s390x
%ifarch s390 s390x ppc64le
%define with_hardware 0
%ifarch s390
%ifarch s390 ppc64le
%define base_drivers swrast
%endif
%else
@ -36,7 +40,7 @@
%define with_vmware 1
%define with_opencl 1
%endif
%ifarch ppc
%ifarch ppc ppc64le
%define platform_drivers ,swrast
%endif
%endif
@ -45,13 +49,13 @@
%define _default_patch_fuzz 2
%define gitdate 20140312
%define gitdate 20140305
#% define snapshot
Summary: Mesa graphics libraries
Name: mesa
Version: 10.0.4
Release: 1.%{gitdate}%{?dist}
Version: 10.1
Release: 5.%{gitdate}%{?dist}
License: MIT
Group: System Environment/Libraries
URL: http://www.mesa3d.org
@ -73,12 +77,14 @@ Patch12: mesa-8.0.1-fix-16bpp.patch
Patch15: mesa-9.2-hardware-float.patch
Patch20: mesa-9.2-evergreen-big-endian.patch
# backport from upstream to allow cogl use copy_sub_buffer
Patch30: 0001-swrast-gallium-classic-add-MESA_copy_sub_buffer-supp.patch
# https://bugs.freedesktop.org/show_bug.cgi?id=75797#c1
Patch21: 0001-mesa-Don-t-optimize-out-glClear-if-drawbuffer-size-i.patch
# https://bugs.freedesktop.org/show_bug.cgi?id=73512
Patch99: 0001-opencl-use-versioned-.so-in-mesa.icd.patch
Patch100: radeonsi-llvm-version-hack.patch
BuildRequires: pkgconfig autoconf automake libtool
%if %{with_hardware}
BuildRequires: kernel-headers
@ -95,6 +101,7 @@ BuildRequires: libXfixes-devel
BuildRequires: libXdamage-devel
BuildRequires: libXi-devel
BuildRequires: libXmu-devel
BuildRequires: libxshmfence-devel
BuildRequires: elfutils
BuildRequires: python
BuildRequires: gettext
@ -102,7 +109,7 @@ BuildRequires: gettext
%if 0%{?with_private_llvm}
BuildRequires: mesa-private-llvm-devel
%else
BuildRequires: llvm-devel >= 3.0
BuildRequires: llvm-devel >= 3.4-5
%if 0%{?with_opencl}
BuildRequires: clang-devel >= 3.0
%endif
@ -327,13 +334,14 @@ grep -q ^/ src/gallium/auxiliary/vl/vl_decoder.c && exit 1
%patch15 -p1 -b .hwfloat
%patch20 -p1 -b .egbe
%patch30 -p1 -b .copy_sub_buffer
%patch21 -p1 -b .clear
%if 0%{?with_opencl}
%patch99 -p1 -b .icd
%endif
%patch100 -p1 -b .radeonsi
%if 0%{with_private_llvm}
sed -i 's/llvm-config/mesa-private-llvm-config-%{__isa_bits}/g' configure.ac
sed -i 's/`$LLVM_CONFIG --version`/&-mesa/' configure.ac
@ -634,8 +642,57 @@ rm -rf $RPM_BUILD_ROOT
%endif
%changelog
* Wed Mar 12 2014 Igor Gnatenko <i.gnatenko.brain@gmail.com> - 10.0.4-1.20140312
- 10.0.4 upstream release
* Wed Mar 26 2014 Adam Jackson <ajax@redhat.com> 10.1-5.20140305
- Initial ppc64le enablement (no hardware drivers or vdpau yet)
* Fri Mar 21 2014 Adam Jackson <ajax@redhat.com> 10.1-4.20140305
- mesa: Don't optimize out glClear if drawbuffer size is 0x0 (fdo #75797)
* Wed Mar 19 2014 Dave Airlie <airlied@redhat.com> 10.1-3.20140305
- rebuild against backported llvm 3.4-5 for radeonsi GL 3.3 support.
* Wed Mar 12 2014 Dave Airlie <airlied@redhat.com> 10.1-2.20140305
- disable r600 llvm compiler (upstream advice)
* Wed Mar 05 2014 Igor Gnatenko <i.gnatenko.brain@gmail.com> - 10.1-1.20140305
- mesa: Bump version to 10.1 (final) (Ian Romanick)
- glx/dri2: fix build failure on HURD (Julien Cristau)
- i965: Validate (and resolve) all the bound textures. (Chris Forbes)
- i965: Widen sampler key bitfields for 32 samplers (Chris Forbes)
* Sat Mar 01 2014 Igor Gnatenko <i.gnatenko.brain@gmail.com> - 10.1-0.rc3.20140301
- 10.1-rc3
* Tue Feb 25 2014 Igor Gnatenko <i.gnatenko.brain@gmail.com> - 10.1-0.rc2.20140225
- really 10.1-rc2
* Sat Feb 22 2014 Igor Gnatenko <i.gnatenko.brain@gmail.com> - 10.1-0.rc2.20140222
- 10.1-rc2
* Sat Feb 08 2014 Adel Gadllah <adel.gadllah@gmail.com> - 10.1-0.rc1.20140208
- 10.1rc1
- Drop upstreamed patches
* Thu Feb 06 2014 Igor Gnatenko <i.gnatenko.brain@gmail.com> - 10.0.3-1.20140206
- 10.0.3 upstream release
* Tue Feb 04 2014 Kyle McMartin <kyle@redhat.com> - 10.0.2-6.20140118
- Fix accidentally inverted logic that meant radeonsi_dri.so went missing
on all architectures instead of just ppc and s390. Sorry!
* Sun Feb 02 2014 Kyle McMartin <kyle@redhat.com> - 10.0.2-5.20140118
- Fix a thinko in previous commit wrt libdrm_nouveau2.
* Sun Feb 02 2014 Kyle McMartin <kyle@redhat.com> - 10.0.2-4.20140118
- Fix up building drivers on AArch64, enable LLVM there.
- Eliminate some F17 cruft from the spec, since we don't support it anymore.
- Conditionalize with_radeonsi on with_llvm instead of ppc,s390 && >F-17.
- Conditionalize libvdpau_radeonsi.so.1* on with_radeonsi instead of simply
with_llvm to fix a build failure on AArch64.
* Sun Jan 19 2014 Igor Gnatenko <i.gnatenko.brain@gmail.com> - 10.0.2-3.20140118
- Enable OpenCL (RHBZ #887628)
- Enable r600 llvm compiler (RHBZ #1055098)
* Wed Mar 12 2014 Dave Airlie <airlied@redhat.com> 10.0.3-2.20140206
- disable r600 llvmcompiler on upstream advice.

View file

@ -0,0 +1,99 @@
diff -up mesa-20140305/src/gallium/drivers/radeonsi/si_descriptors.c.radeonsi mesa-20140305/src/gallium/drivers/radeonsi/si_descriptors.c
--- mesa-20140305/src/gallium/drivers/radeonsi/si_descriptors.c.radeonsi 2014-03-18 04:37:30.009681609 +0000
+++ mesa-20140305/src/gallium/drivers/radeonsi/si_descriptors.c 2014-03-18 04:37:36.751681788 +0000
@@ -151,7 +151,7 @@ static void si_update_descriptors(struct
7 + /* copy */
(4 + desc->element_dw_size) * util_bitcount(desc->dirty_mask) + /* update */
4; /* pointer update */
-#if HAVE_LLVM >= 0x0305
+#if HAVE_LLVM >= 0x0304
if (desc->shader_userdata_reg >= R_00B130_SPI_SHADER_USER_DATA_VS_0 &&
desc->shader_userdata_reg < R_00B230_SPI_SHADER_USER_DATA_GS_0)
desc->atom.num_dw += 4; /* second pointer update */
@@ -176,7 +176,7 @@ static void si_emit_shader_pointer(struc
radeon_emit(cs, va);
radeon_emit(cs, va >> 32);
-#if HAVE_LLVM >= 0x0305
+#if HAVE_LLVM >= 0x0304
if (desc->shader_userdata_reg >= R_00B130_SPI_SHADER_USER_DATA_VS_0 &&
desc->shader_userdata_reg < R_00B230_SPI_SHADER_USER_DATA_GS_0) {
radeon_emit(cs, PKT3(PKT3_SET_SH_REG, 2, 0));
diff -up mesa-20140305/src/gallium/drivers/radeonsi/si_pipe.c.radeonsi mesa-20140305/src/gallium/drivers/radeonsi/si_pipe.c
--- mesa-20140305/src/gallium/drivers/radeonsi/si_pipe.c.radeonsi 2014-03-05 06:59:46.000000000 +0000
+++ mesa-20140305/src/gallium/drivers/radeonsi/si_pipe.c 2014-03-18 04:37:10.090681081 +0000
@@ -269,7 +269,7 @@ static int si_get_param(struct pipe_scre
return 256;
case PIPE_CAP_GLSL_FEATURE_LEVEL:
- return HAVE_LLVM >= 0x0305 ? 330 : 140;
+ return HAVE_LLVM >= 0x0304 ? 330 : 140;
case PIPE_CAP_TEXTURE_BUFFER_OFFSET_ALIGNMENT:
return 1;
@@ -313,7 +313,7 @@ static int si_get_param(struct pipe_scre
case PIPE_CAP_MAX_TEXTURE_ARRAY_LAYERS:
return 16384;
case PIPE_CAP_MAX_COMBINED_SAMPLERS:
- return HAVE_LLVM >= 0x0305 ? 48 : 32;
+ return HAVE_LLVM >= 0x0304 ? 48 : 32;
/* Render targets. */
case PIPE_CAP_MAX_RENDER_TARGETS:
@@ -346,7 +346,7 @@ static int si_get_shader_param(struct pi
case PIPE_SHADER_VERTEX:
break;
case PIPE_SHADER_GEOMETRY:
-#if HAVE_LLVM < 0x0305
+#if HAVE_LLVM < 0x0304
return 0;
#endif
break;
diff -up mesa-20140305/src/gallium/drivers/radeonsi/si_state.c.radeonsi mesa-20140305/src/gallium/drivers/radeonsi/si_state.c
--- mesa-20140305/src/gallium/drivers/radeonsi/si_state.c.radeonsi 2014-03-05 06:59:46.000000000 +0000
+++ mesa-20140305/src/gallium/drivers/radeonsi/si_state.c 2014-03-18 04:37:10.092681081 +0000
@@ -2307,7 +2307,7 @@ static void *si_create_fs_state(struct p
return si_create_shader_state(ctx, state, PIPE_SHADER_FRAGMENT);
}
-#if HAVE_LLVM >= 0x0305
+#if HAVE_LLVM >= 0x0304
static void *si_create_gs_state(struct pipe_context *ctx,
const struct pipe_shader_state *state)
@@ -2337,7 +2337,7 @@ static void si_bind_vs_shader(struct pip
sctx->vs_shader = sel;
}
-#if HAVE_LLVM >= 0x0305
+#if HAVE_LLVM >= 0x0304
static void si_bind_gs_shader(struct pipe_context *ctx, void *state)
{
@@ -2396,7 +2396,7 @@ static void si_delete_vs_shader(struct p
si_delete_shader_selector(ctx, sel);
}
-#if HAVE_LLVM >= 0x0305
+#if HAVE_LLVM >= 0x0304
static void si_delete_gs_shader(struct pipe_context *ctx, void *state)
{
@@ -2890,7 +2890,7 @@ static void si_bind_vs_sampler_states(st
si_set_sampler_states(sctx, pm4, count, states,
&sctx->samplers[PIPE_SHADER_VERTEX],
R_00B130_SPI_SHADER_USER_DATA_VS_0);
-#if HAVE_LLVM >= 0x0305
+#if HAVE_LLVM >= 0x0304
si_set_sampler_states(sctx, pm4, count, states,
&sctx->samplers[PIPE_SHADER_VERTEX],
R_00B330_SPI_SHADER_USER_DATA_ES_0);
@@ -3166,7 +3166,7 @@ void si_init_state_functions(struct si_c
sctx->b.b.bind_fs_state = si_bind_ps_shader;
sctx->b.b.delete_vs_state = si_delete_vs_shader;
sctx->b.b.delete_fs_state = si_delete_ps_shader;
-#if HAVE_LLVM >= 0x0305
+#if HAVE_LLVM >= 0x0304
sctx->b.b.create_gs_state = si_create_gs_state;
sctx->b.b.bind_gs_state = si_bind_gs_shader;
sctx->b.b.delete_gs_state = si_delete_gs_shader;

View file

@ -1 +1 @@
fbd84e27dee95da69a581ffde02cd796 mesa-20140312.tar.xz
242b9395d6b0303ddcd88987a93f5e8c mesa-20140305.tar.xz