Re: [Mesa-dev] [PATCH] glx: Create proper server dependency for GLX_EXT_create_context_es2_profile

2015-04-15 Thread Jose Fonseca
subtle interactions between GLX and X server. Acked-by: Jose Fonseca ___ mesa-dev mailing list mesa-dev@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/mesa-dev

Re: [Mesa-dev] [PATCH 4/9] prog; add weak _mesa_error_no_memory() symbol and add it to libglsl_util

2015-04-15 Thread Jose Fonseca
On 15/04/15 20:38, Brian Paul wrote: On 04/15/2015 11:56 AM, Emil Velikov wrote: On 15 April 2015 at 18:33, Matt Turner wrote: On Wed, Apr 15, 2015 at 7:08 AM, Emil Velikov wrote: Rather than forcing everyone to provide their own definition of the symbol provide a common weak one, which anyo

Re: [Mesa-dev] [PATCH 2/5] tgsi: also dump label for TGSI_OPCODE_BGNSUB opcode

2015-04-14 Thread Jose Fonseca
On 14/04/15 17:56, Brian Paul wrote: So we can see the label associated with subroutines. --- src/gallium/auxiliary/tgsi/tgsi_dump.c | 1 + 1 file changed, 1 insertion(+) diff --git a/src/gallium/auxiliary/tgsi/tgsi_dump.c b/src/gallium/auxiliary/tgsi/tgsi_dump.c index 7ae4049..13d6769 10064

Re: [Mesa-dev] [PATCH 1/5] st/mesa: also emit labels for TGSI_OPCODE_BGNSUB

2015-04-14 Thread Jose Fonseca
On 14/04/15 17:56, Brian Paul wrote: Subroutines need labels so they can be identied by CAL instructions. --- src/mesa/state_tracker/st_glsl_to_tgsi.cpp | 19 +-- 1 file changed, 13 insertions(+), 6 deletions(-) diff --git a/src/mesa/state_tracker/st_glsl_to_tgsi.cpp b/src/me

[Mesa-dev] [PATCH 2/2] st/wgl: Couple of fixes to opengl32.dll's wglCreateContext/wglDeleteContext dispatch.

2015-04-14 Thread Jose Fonseca
- Use GetModuleHandle instead of LoadLibrary to avoid incrementing the opengl32.dll reference count (otherwise the opengl32.dll will linger in memory forever.) - Ensure we use our fake wglCreateContext/wglDeleteContext when using Mesa as a drop-in replacement for opengl32.dll Untested. Jus

[Mesa-dev] [PATCH 1/2] mesa: Enable _mesa_dlopen on MSVC too.

2015-04-14 Thread Jose Fonseca
As pointed out by Shervin Sharifi. --- src/mesa/main/dlopen.h | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/mesa/main/dlopen.h b/src/mesa/main/dlopen.h index 1e77849..4d20ff2 100644 --- a/src/mesa/main/dlopen.h +++ b/src/mesa/main/dlopen.h @@ -50,7 +50,7 @@ _mesa_dl

Re: [Mesa-dev] Building Mesa for Windows using Visual Studio

2015-04-14 Thread Jose Fonseca
On 14/04/15 13:41, Emil Velikov wrote: Hi Shervin, On 14 April 2015 at 00:22, Shervin Sharifi wrote: Hi, I tried to use Mesa (compiled with MSVC) to run OpenGL ES content on Windows . I ran into a few problems. I don't know if this is the right way of reporting issues, but thought peop

Re: [Mesa-dev] [PATCH] glx: Allow to create any OpenGL ES version.

2015-04-14 Thread Jose Fonseca
On 13/04/15 22:59, Ian Romanick wrote: On 04/10/2015 03:36 PM, Jose Fonseca wrote: From: José Fonseca The latest version of GLX_EXT_create_context_es2_profile states: "If the version requested is a valid and supported OpenGL-ES version, and the GLX_CONTEXT_ES_PROFILE_BIT_EXT bit i

[Mesa-dev] [PATCH] glx: Allow to create any OpenGL ES version.

2015-04-10 Thread Jose Fonseca
From: José Fonseca The latest version of GLX_EXT_create_context_es2_profile states: "If the version requested is a valid and supported OpenGL-ES version, and the GLX_CONTEXT_ES_PROFILE_BIT_EXT bit is set in the GLX_CONTEXT_PROFILE_MASK_ARB attribute (see below), then the context returned

Re: [Mesa-dev] [PATCH 3/3] glx: Allow to create any OpenGL ES version.

2015-04-10 Thread Jose Fonseca
On 12/11/14 18:16, Daniel Stone wrote: Hi, On 12 November 2014 12:37, mailto:jfons...@vmware.com>> wrote: @@ -544,9 +544,22 @@ dri2_convert_glx_attribs(unsigned num_attribs, const uint32_t *attribs, case GLX_CONTEXT_COMPATIBILITY_PROFILE_BIT_ARB: *api = __DRI_A

Re: [Mesa-dev] Problem with LLVM on Windows with MSVC

2015-04-10 Thread Jose Fonseca
I suspect that when you built LLVM, you built with the Debug build type instead of Release. That's why you need LLVM_USE_CRT_DEBUG= instead of LLVM_USE_CRT_RELEASE=. But I don't recommend you use a Debug LLVM build, it can be much slower. To be safe, I could update the instructions to menti

Re: [Mesa-dev] Problem with LLVM on Windows with MSVC

2015-04-09 Thread Jose Fonseca
Please read http://mesa3d.org/llvmpipe.html , "Requirements" sections. It's explained there how to tell which runtime to use when building LLVM. That said, you probably want to pass build=release to scons command. As SCons defaults to debug build. scons build=release ... Jose On 09/04/1

Re: [Mesa-dev] [PATCH] scons: add target gallium-osmesa

2015-04-08 Thread Jose Fonseca
Besides the issue Emil mentioned, one minor request: lets call the target just "osmesa". As we don't plan to have any other "osmesa" target. Jose On 08/04/15 18:18, Emil Velikov wrote: Hi Olivier Thanks for the patch ! Adding Jose to the Cc list as I believe he'll have some input on the to

Re: [Mesa-dev] [PATCH 1/2] gallivm: don't use control flow when doing indirect constant buffer lookups

2015-04-08 Thread Jose Fonseca
Series looks good to me. Just a few suggestions inline. On 04/04/15 15:50, srol...@vmware.com wrote: From: Roland Scheidegger llvm goes crazy when doing that, using way more memory and time, though there's probably more to it - this points to a very much similar issue as fixed in 8a9f5ecdb11

Re: [Mesa-dev] [PATCH 4/4] autoconf, scons: Move fallback HAVE_* definitions to headers.

2015-04-07 Thread Jose Fonseca
On 07/04/15 17:16, Matt Turner wrote: On Tue, Apr 7, 2015 at 5:14 AM, Jose Fonseca wrote: Sorry for the delay. I've been away during the Easter. On 02/04/15 19:02, Matt Turner wrote: On Thu, Apr 2, 2015 at 7:32 AM, Jose Fonseca wrote: These were being defined in SCons, but it&

Re: [Mesa-dev] [PATCH 4/4] autoconf, scons: Move fallback HAVE_* definitions to headers.

2015-04-07 Thread Jose Fonseca
On 07/04/15 15:01, Emil Velikov wrote: On 7 April 2015 at 13:14, Jose Fonseca wrote: Sorry for the delay. I've been away during the Easter. On 02/04/15 19:02, Matt Turner wrote: On Thu, Apr 2, 2015 at 7:32 AM, Jose Fonseca wrote: These were being defined in SCons, but it's not

Re: [Mesa-dev] [PATCH 4/4] autoconf, scons: Move fallback HAVE_* definitions to headers.

2015-04-07 Thread Jose Fonseca
Sorry for the delay. I've been away during the Easter. On 02/04/15 19:02, Matt Turner wrote: On Thu, Apr 2, 2015 at 7:32 AM, Jose Fonseca wrote: These were being defined in SCons, but it's not practical -- we actually need to include Gallium headers from external source trees, with

[Mesa-dev] [PATCH 1/4] mesa: Remove pointless USE_EXTERNAL_DXTN_LIB macro.

2015-04-02 Thread Jose Fonseca
I'm not sure what was the original intention, but currently USE_EXTERNAL_DXTN_LIB always ends up defined, one way or another. --- configure.ac | 2 +- src/mesa/main/texcompress_s3tc.c | 8 2 files changed, 1 insertion(+), 9 deletions(-) diff --git a/configure.ac b/con

[Mesa-dev] [PATCH 3/4] glx: Include util/macros.h instead of redefining PRINTFLIKE.

2015-04-02 Thread Jose Fonseca
--- src/glx/dri_common.h | 7 +-- 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/src/glx/dri_common.h b/src/glx/dri_common.h index 5cd150a..947d331 100644 --- a/src/glx/dri_common.h +++ b/src/glx/dri_common.h @@ -39,12 +39,7 @@ #include #include #include "loader.h" - -#if (_

[Mesa-dev] [PATCH 4/4] autoconf, scons: Move fallback HAVE_* definitions to headers.

2015-04-02 Thread Jose Fonseca
These were being defined in SCons, but it's not practical -- we actually need to include Gallium headers from external source trees, with completely disjoint build infrastructure, and it's unsustainable to replicate the HAVE_xxx checks or even hard-coded defines across everywhere. No actual change

[Mesa-dev] [PATCH 2/4] util/ralloc: Fix `extern "C"` usage.

2015-04-02 Thread Jose Fonseca
--- src/util/ralloc.h | 8 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/util/ralloc.h b/src/util/ralloc.h index f088a36..857b1f9 100644 --- a/src/util/ralloc.h +++ b/src/util/ralloc.h @@ -46,16 +46,16 @@ #ifndef RALLOC_H #define RALLOC_H -#ifdef __cplusplus -exter

Re: [Mesa-dev] Mesa (master): gallium: Add tgsi_to_nir to get a nir_shader for a TGSI shader.

2015-04-01 Thread Jose Fonseca
On 01/04/15 20:25, Brian Paul wrote: On 04/01/2015 01:15 PM, Jose Fonseca wrote: On 01/04/15 19:49, Brian Paul wrote: On 04/01/2015 12:02 PM, Eric Anholt wrote: Module: Mesa Branch: master Commit: 783ad697d25e754ab719ab6c715969c35dbe867b URL: https://urldefense.proofpoint.com/v2/url?u=http

Re: [Mesa-dev] Mesa (master): gallium: Add tgsi_to_nir to get a nir_shader for a TGSI shader.

2015-04-01 Thread Jose Fonseca
On 01/04/15 19:49, Brian Paul wrote: On 04/01/2015 12:02 PM, Eric Anholt wrote: Module: Mesa Branch: master Commit: 783ad697d25e754ab719ab6c715969c35dbe867b URL: https://urldefense.proofpoint.com/v2/url?u=http-3A__cgit.freedesktop.org_mesa_mesa_commit_-3Fid-3D783ad697d25e754ab719ab6c715969c35dbe

Re: [Mesa-dev] [PATCH] gallivm: Fix build against LLVM 3.7 SVN r233648

2015-03-31 Thread Jose Fonseca
ot; << Triple.c_str() << "\n"; Out.flush(); Reviewed-by: Jose Fonseca ___ mesa-dev mailing list mesa-dev@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/mesa-dev

Re: [Mesa-dev] [PATCH] gallivm: simplify sampler interface

2015-03-30 Thread Jose Fonseca
e[texture_index].texture_state, &sampler->dynamic_state.static_state[sampler_index].sampler_state, &sampler->dynamic_state.base, - type, - is_fetch, - texture_index, -

Re: [Mesa-dev] [PATCH 3/3] llvmpipe: enable ARB_texture_gather

2015-03-30 Thread Jose Fonseca
On 30/03/15 01:12, srol...@vmware.com wrote: From: Roland Scheidegger Just announce support for 4 components. While here also increase the max/min texel offsets (the limit is completely artificial, was chosen because that's what other hardware did, however there's other drivers using larger lim

Re: [Mesa-dev] [PATCH] osmesa: don't try to bundle osmesa.def SConscript

2015-03-30 Thread Jose Fonseca
On 29/03/15 00:56, Emil Velikov wrote: Both of which were removed with commit 69db422218b(scons: Don't build osmesa.) Cc: Jose Fonseca Signed-off-by: Emil Velikov --- src/mesa/drivers/osmesa/Makefile.am | 2 -- 1 file changed, 2 deletions(-) diff --git a/src/mesa/drivers/o

Re: [Mesa-dev] [PATCH] llvmpipe: simplify address calculation for 4x4 blocks

2015-03-27 Thread Jose Fonseca
Reviewed-by: Jose Fonseca On 27/03/15 15:53, srol...@vmware.com wrote: From: Roland Scheidegger These functions looked quite complicated, even though what they actually did was trivial (ever since we dropped swizzled rendering). Also drop lookup of format block per bytes done for each block

Re: [Mesa-dev] [PATCH] docs: note that classic osmesa/libEGL no longer builds with scons

2015-03-27 Thread Jose Fonseca
. +Removed the classic osmesa from the Windows SCons build. Thanks. Reviewed-by: Jose Fonseca ___ mesa-dev mailing list mesa-dev@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/mesa-dev

Re: [Mesa-dev] [PATCH] gallivm: use llvm function calls for texturing instead of inlining

2015-03-26 Thread Jose Fonseca
On 25/03/15 19:03, srol...@vmware.com wrote: From: Roland Scheidegger There are issues with inlining everything, most notably llvm will use much more memory (and be slower) when compiling. Ideally we'd probably use functions for shader functions too but texture sampling usually is responsible f

Re: [Mesa-dev] [PATCH 1/2] gallivm: pass jit_context pointer through to sampling

2015-03-26 Thread Jose Fonseca
p_llvm_sampler_soa_create(const struct lp_sampler_static_state *static_state) { struct lp_llvm_sampler_soa *sampler; @@ -331,7 +334,6 @@ lp_llvm_sampler_soa_create(const struct lp_sampler_static_state *static_state, sampler->dynamic_state.base.border_color = lp_llvm_sampler_bord

Re: [Mesa-dev] [PATCH 4/8] scons: Don't build osmesa.

2015-03-26 Thread Jose Fonseca
On 26/03/15 16:36, Emil Velikov wrote: On 25/03/15 19:58, Jose Fonseca wrote: On 25/03/15 19:35, Emil Velikov wrote: On 25/03/15 15:21, Jose Fonseca wrote: On 25/03/15 14:53, Emil Velikov wrote: On 24 March 2015 at 21:16, Jose Fonseca wrote: There doesn't seem much interest on osme

Re: [Mesa-dev] [PATCH 4/8] scons: Don't build osmesa.

2015-03-25 Thread Jose Fonseca
On 25/03/15 19:35, Emil Velikov wrote: On 25/03/15 15:21, Jose Fonseca wrote: On 25/03/15 14:53, Emil Velikov wrote: On 24 March 2015 at 21:16, Jose Fonseca wrote: There doesn't seem much interest on osmesa on Windows, particularly classic osmesa. If there is indeed interest in osme

Re: [Mesa-dev] [PATCH 4/8] scons: Don't build osmesa.

2015-03-25 Thread Jose Fonseca
On 25/03/15 14:53, Emil Velikov wrote: On 24 March 2015 at 21:16, Jose Fonseca wrote: There doesn't seem much interest on osmesa on Windows, particularly classic osmesa. If there is indeed interest in osmesa on Windows, we should instead integrate src/gallium/targets/osmesa into

Re: [Mesa-dev] Building Mesa for Windows using Visual Studio

2015-03-25 Thread Jose Fonseca
See http://www.mesa3d.org/install.html or docs/install.html from Mesa tree. If you want to build with llvmpipe support, you'll also need to read and follow http://www.mesa3d.org/llvmpipe.html I'm also experimenting on automated Windows builds with AppVeyor. You can see the build log

[Mesa-dev] [PATCH 3/8] scons: Don't build loader on Windows.

2015-03-24 Thread Jose Fonseca
EGL was the last user. --- src/SConscript | 3 ++- src/loader/Makefile.am | 1 - 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/SConscript b/src/SConscript index 40b7fc1..b0578e8 100644 --- a/src/SConscript +++ b/src/SConscript @@ -12,7 +12,8 @@ if env['hostonly']:

[Mesa-dev] [PATCH 8/8] util/u_atomic: Ignore warnings interlocked accesses.

2015-03-24 Thread Jose Fonseca
These are due how we implemented the atomic tests, not the atomic implementation itself. It's also difficult to refactor the code to avoid the warnings due to the use of macros -- the code would be quite hairy. --- src/util/u_atomic_test.c | 5 + 1 file changed, 5 insertions(+) diff --git a/

[Mesa-dev] [PATCH 7/8] scons: Disable MSVC warnings about inconsistent function annotation.

2015-03-24 Thread Jose Fonseca
Somehow, merely including any of the *intrin.h headers causes dozens of this warnings (when compiling pretty much every source file). MSVC does not always complain the same -- so it's possible we're doing something weird --, but silence these warnings in the meanwhile. --- scons/gallium.py | 1 +

[Mesa-dev] [PATCH 6/8] mesa: Avoid MSVC C6334 warning in /analyze mode.

2015-03-24 Thread Jose Fonseca
MSVC's implementation of signbit(x) uses sizeof(x) with expressions to dispatch to an internal function based on the argument's type (float, double, etc), but that raises a flag with MSVC's own static analyzer, and because this is an inline function in a header it causes substantial warning spam. -

[Mesa-dev] [PATCH 5/8] c99_math: Don't reimplement lrint and friends on MSVC 2013.

2015-03-24 Thread Jose Fonseca
MSVC 2013 declares these functions, both for C and C++ source files. This was caught with MSVC in analyze mode. --- include/c99_math.h | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/include/c99_math.h b/include/c99_math.h index 5b01d53..ee0dd10 100644 --- a/include/c99_math

[Mesa-dev] [PATCH 4/8] scons: Don't build osmesa.

2015-03-24 Thread Jose Fonseca
There doesn't seem much interest on osmesa on Windows, particularly classic osmesa. If there is indeed interest in osmesa on Windows, we should instead integrate src/gallium/targets/osmesa into SCons. --- src/mesa/drivers/SConscript| 2 -- src/mesa/drivers/osmesa/SConscript | 39 ---

[Mesa-dev] [PATCH 2/8] scons: Don't build egl on Windows.

2015-03-24 Thread Jose Fonseca
Useless, as there are no drivers for it. --- src/SConscript | 2 +- src/egl/main/Makefile.am | 1 - src/egl/main/SConscript | 11 +-- 3 files changed, 2 insertions(+), 12 deletions(-) diff --git a/src/SConscript b/src/SConscript index 188ab08..40b7fc1 100644 --- a/src/SConscr

[Mesa-dev] [PATCH 1/8] scons: Fix git_sha1.h generation fallback.

2015-03-24 Thread Jose Fonseca
I didn't meant to remove the 'if not os.path.exists(filename)' statement. --- src/mesa/SConscript | 7 --- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/src/mesa/SConscript b/src/mesa/SConscript index a563fd2..5b80a21 100644 --- a/src/mesa/SConscript +++ b/src/mesa/SConscript @

Re: [Mesa-dev] [PATCH 2/2] st/egl: don't ship the dri2, c link at the tarball

2015-03-24 Thread Jose Fonseca
zeaZbdIqVLprmZCM2zzE&m=kbkQvZ91MLwWiICIjaqFjJvTbTcid8jb6N_JvWRj5RU&s=0lsus4gaJqwWUadyxbcfiCq529HufHm5uSHMHUmqj7s&e= Cc: mesa-sta...@lists.freedesktop.org Cc: Brian Paul Cc: Jose Fonseca Cc: Alexander von Gluck IV Signed-off-by: Emil Velikov --- Alexander this and the previous patch things should g

Re: [Mesa-dev] [PATCH 09/15] scons: Prefer winflexbison, and use --wincompat when available.

2015-03-20 Thread Jose Fonseca
On 20/03/15 14:36, Brian Paul wrote: On 03/20/2015 07:59 AM, Jose Fonseca wrote: This avoids MSVC the warning warning C4013: 'isatty' undefined; assuming extern returning int with certain versions of flex. --- scons/gallium.py | 39 --- 1 fi

Re: [Mesa-dev] [PATCH 14/15] scons: Silence conversion from 'size_t' to 'type', possible loss of data on MSVC.

2015-03-20 Thread Jose Fonseca
On 20/03/15 14:36, Brian Paul wrote: On 03/20/2015 07:59 AM, Jose Fonseca wrote: Most cases seem harmless, though that might not always be the case. Maybe one day we can get gcc to complain about these and fix them throughout the code, but until then let's silence them. --- scons/galli

[Mesa-dev] [PATCH 11/15] scons: Match some of LLVM warning options.

2015-03-20 Thread Jose Fonseca
--- scons/llvm.py | 5 + 1 file changed, 5 insertions(+) diff --git a/scons/llvm.py b/scons/llvm.py index d145de8..be7df9f 100644 --- a/scons/llvm.py +++ b/scons/llvm.py @@ -132,6 +132,11 @@ def generate(env): # Some of the LLVM C headers use the inline keyword without

[Mesa-dev] [PATCH 15/15] gallivm: Silence unused variable warnings on release builds.

2015-03-20 Thread Jose Fonseca
--- src/gallium/auxiliary/gallivm/lp_bld_arit.c| 2 ++ src/gallium/auxiliary/gallivm/lp_bld_bitarit.c | 2 ++ 2 files changed, 4 insertions(+) diff --git a/src/gallium/auxiliary/gallivm/lp_bld_arit.c b/src/gallium/auxiliary/gallivm/lp_bld_arit.c index 0d4eaea..3ee1646 100644 --- a/src/galliu

[Mesa-dev] [PATCH 13/15] scons: Ensure inttypes.h is always pre-included on MSVC.

2015-03-20 Thread Jose Fonseca
It's a bit hackish couldn't find another solution. See code comment for details. The warning is useful, so universally disabling doesn't sound a good idea. Fixes warning C4005: 'xxx' : macro redefinition --- scons/gallium.py | 7 +++ 1 file changed, 7 insertions(+) diff --git a/scons/

[Mesa-dev] [PATCH 10/15] scons: Cleanup flex/bison settings specification.

2015-03-20 Thread Jose Fonseca
--- src/glsl/SConscript | 20 src/mesa/SConscript | 2 +- 2 files changed, 13 insertions(+), 9 deletions(-) diff --git a/src/glsl/SConscript b/src/glsl/SConscript index 26de455..284b375 100644 --- a/src/glsl/SConscript +++ b/src/glsl/SConscript @@ -24,22 +24,26 @@ env.Prepen

[Mesa-dev] [PATCH 14/15] scons: Silence conversion from 'size_t' to 'type', possible loss of data on MSVC.

2015-03-20 Thread Jose Fonseca
Most cases seem harmless, though that might not always be the case. Maybe one day we can get gcc to complain about these and fix them throughout the code, but until then let's silence them. --- scons/gallium.py | 1 + 1 file changed, 1 insertion(+) diff --git a/scons/gallium.py b/scons/gallium.p

[Mesa-dev] [PATCH 12/15] scons: Silence MSVC C4351 warning.

2015-03-20 Thread Jose Fonseca
It warns about change in MSVC behavior -- array initialisation used to be non-standard, but is standard now, assuming I understand correctly http://en.cppreference.com/w/cpp/language/zero_initialization . --- scons/gallium.py | 1 + 1 file changed, 1 insertion(+) diff --git a/scons/gallium.py b/s

[Mesa-dev] [PATCH 03/15] st/vdpau: Avoid constness cast warnings.

2015-03-20 Thread Jose Fonseca
Fixes MSVC warning C4090: '=' : different 'const' qualifiers --- src/mesa/state_tracker/st_vdpau.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/mesa/state_tracker/st_vdpau.c b/src/mesa/state_tracker/st_vdpau.c index 6ccaf3e..63af119 100644 --- a/src/mesa/state_tracke

[Mesa-dev] [PATCH 04/15] include: Ensure float.h is included for DBL_MAX.

2015-03-20 Thread Jose Fonseca
I didn't actually hit the issue in practice, but just happen to notice while looking at the code. --- include/c99_math.h | 1 + 1 file changed, 1 insertion(+) diff --git a/include/c99_math.h b/include/c99_math.h index bd35d1b..5b01d53 100644 --- a/include/c99_math.h +++ b/include/c99_math.h @@ -7

[Mesa-dev] [PATCH 09/15] scons: Prefer winflexbison, and use --wincompat when available.

2015-03-20 Thread Jose Fonseca
This avoids MSVC the warning warning C4013: 'isatty' undefined; assuming extern returning int with certain versions of flex. --- scons/gallium.py | 39 --- 1 file changed, 32 insertions(+), 7 deletions(-) diff --git a/scons/gallium.py b/scons/gallium.py ind

[Mesa-dev] [PATCH 05/15] configure: Bail out with MinGW targets.

2015-03-20 Thread Jose Fonseca
We only support native Windows builds with SCons. Tested with: ./configure --host=i686-w64-mingw32 --- configure.ac | 25 + 1 file changed, 13 insertions(+), 12 deletions(-) diff --git a/configure.ac b/configure.ac index 8c90b41..daed769 100644 --- a/configure.ac +++ b

[Mesa-dev] [PATCH 02/15] glsl: Disable MSVC switch warning on a per-file basis.

2015-03-20 Thread Jose Fonseca
This addresses ...\glsl_parser.cpp(...) : warning C4065: switch statement contains 'default' but no 'case' labels This is on code generated by bison, which we have little control. It seems useful to have this warning otherwise enabled. --- src/glsl/glsl_parser.yy | 4 1 file changed, 4

[Mesa-dev] [PATCH 08/15] scons: Define YY_USE_CONST on MSVC.

2015-03-20 Thread Jose Fonseca
This prevents the MSVC from warning C4090: 'function' : different 'const' qualifiers when compiling flex generated lexers. --- scons/gallium.py | 8 1 file changed, 8 insertions(+) diff --git a/scons/gallium.py b/scons/gallium.py index 2b11526..9924f1e 100755 --- a/scons/gallium.py +

[Mesa-dev] [PATCH 01/15] glsl: Avoid GLboolean vs bool arithmetic MSVC warnings.

2015-03-20 Thread Jose Fonseca
Note that GLboolean is an alias for unsigned char, which lacks the implicit true/false semantics that C++/C99 bool have. Reviewed-by: Brian Paul v2: Change gl_shader::IsES and gl_shader_program::IsES to be bool as recommended by Ian Romanick. --- src/glsl/linker.cpp| 5 +++-- src/mesa/main/

[Mesa-dev] [PATCH 06/15] scons: Ensure git_sha1.h's directory exists.

2015-03-20 Thread Jose Fonseca
--- src/mesa/SConscript | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/mesa/SConscript b/src/mesa/SConscript index cc5d242..72d9811 100644 --- a/src/mesa/SConscript +++ b/src/mesa/SConscript @@ -130,7 +130,9 @@ def write_git_sha1_h_file(filename): (commit, foo)

[Mesa-dev] [PATCH 07/15] scons: Tell MSVC STL library to not use exceptions.

2015-03-20 Thread Jose Fonseca
MSVC defaults to no exceptions unless /EH option is passed (which we don't), while MSVC's STL defaults to use exceptions unless _HAS_EXCEPTIONS=0 is defined, which we didn't. This fixes warning C4530: C++ exception handler used, but unwind semantics are not enabled. Specify /EHsc --- scons/g

Re: [Mesa-dev] [PATCH] gallivm: removes unused 'builder' variable

2015-03-19 Thread Jose Fonseca
assert(lp_check_value(type, a)); Reviewed-by: Jose Fonseca ___ mesa-dev mailing list mesa-dev@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/mesa-dev

Re: [Mesa-dev] [PATCH] glsl: Use INFINITY instead of std::numeric_limits::infinity().

2015-03-19 Thread Jose Fonseca
ts is actually the "C++ way" of doing this, but given we have a mixture of C99 in Mesa, using INFIFITY everywhere is equally fine. Either way, there should be no problems for MSVC. Reviewed-by: Jose Fonseca ___ mesa-dev mailing list mesa-dev@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/mesa-dev

[Mesa-dev] [PATCH 3/6] gallivm: Use INFINITY directly.

2015-03-18 Thread Jose Fonseca
Already done below. --- src/gallium/auxiliary/gallivm/lp_bld_arit.c | 9 + 1 file changed, 1 insertion(+), 8 deletions(-) diff --git a/src/gallium/auxiliary/gallivm/lp_bld_arit.c b/src/gallium/auxiliary/gallivm/lp_bld_arit.c index cd05f11..0d4eaea 100644 --- a/src/gallium/auxiliary/galli

[Mesa-dev] [PATCH 5/6] scons: Don't link program_lexer.l/y twice.

2015-03-18 Thread Jose Fonseca
program/lex.yy.c and program/program_parse.tab.c is already included in the PROGRAM_FILES variable. We still need to specify the dependency relationship though. --- src/mesa/SConscript | 11 +++ 1 file changed, 3 insertions(+), 8 deletions(-) diff --git a/src/mesa/SConscript b/src/mesa/S

[Mesa-dev] [PATCH 2/6] scons: Silence MSVC warnings about overflows in constant arithmetic.

2015-03-18 Thread Jose Fonseca
These get triggered even when using the standard C99 INFINITY/NAN constants. --- scons/gallium.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/scons/gallium.py b/scons/gallium.py index 9d53848..b4018e7 100755 --- a/scons/gallium.py +++ b/scons/gallium.py @@ -495,8 +495,10 @@ def generate(

[Mesa-dev] [PATCH 6/6] swrast: Use BITFIELD64_BIT for arrayAttribs.

2015-03-18 Thread Jose Fonseca
As VARYING_SLOT_MAX can be bigger than 32. I'll probably stop building swrast with MSVC in the near future, but this seems a real bug regardless. --- src/mesa/swrast/s_span.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/mesa/swrast/s_span.c b/src/mesa/swrast/s_span.c in

[Mesa-dev] [PATCH 4/6] glsl: Avoid GLboolean vs bool arithmetic MSVC warnings.

2015-03-18 Thread Jose Fonseca
Note that GLboolean is an alias for unsigned char, which lacks the implicit true/false semantics that C++/C99 bool have. --- src/glsl/linker.cpp | 7 --- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/src/glsl/linker.cpp b/src/glsl/linker.cpp index 0c44677..1abcb32 100644 --- a/

[Mesa-dev] [PATCH 1/6] scons: Disable MSVC signed/unsigned mismatch warnings.

2015-03-18 Thread Jose Fonseca
From: José Fonseca By default gcc ignores the issue, and as result code that mixes signed/unsigned is so widespread through the code base that it ends up being little more than noise, potentially obscuring more pertinent warnings. Maybe one day we enable the corresponding gcc warnings and cleanu

Re: [Mesa-dev] [RFC PATCH 0/7] Prune stale components, take 2

2015-03-18 Thread Jose Fonseca
On 14/03/15 22:36, Emil Velikov wrote: Hi all, As a follow up to Jose's initial series dropping st/{egl,vega} and others here is the next round of cleanups, Namely this series - removes st/gbm, winsys/sw/{wayland,fbdev}, all of which no longer used by anyone, - cleans up libEGL (and config

Re: [Mesa-dev] [PATCH 1/4] mapi: add new _glapi_new_nop_table() and _glapi_set_nop_handler()

2015-03-18 Thread Jose Fonseca
2d6ef0..a1af40c 100644 --- a/src/mapi/table.h +++ b/src/mapi/table.h @@ -41,6 +41,14 @@ struct mapi_table; extern const mapi_func table_noop_array[]; + +typedef void (*nop_handler_proc)(const char *name); + + +void +table_set_noop_handler(nop_handler_proc func); + + /** * Get the no-op dispatch table. */ The series looks good to me AFAICT. Reviewed-by: Jose Fonseca ___ mesa-dev mailing list mesa-dev@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/mesa-dev

Re: [Mesa-dev] [PATCH] SConstruct: Fix PEP 8 issues.

2015-03-18 Thread Jose Fonseca
Hi Vinson, I have mixed feelings about this. I don't really agree with all things mandated with PEP 8. Comments inline. On 17/03/15 06:15, Vinson Lee wrote: Signed-off-by: Vinson Lee --- SConstruct | 66 -- 1 file changed, 34 in

Re: [Mesa-dev] [PATCH] gallivm: abort properly when running out of buffer space in lp_disassembly

2015-03-16 Thread Jose Fonseca
* Print GDB command, useful to verify output. */ - if (0) { _debug_printf("disassemble %p %p\n", bytes, bytes + pc); } - Out << "\n"; - Out.flush(); - return pc; } Looks good to me too. Reviewed-by: Jose Fonseca

Re: [Mesa-dev] [PATCH] util: convert slab macros to inline functions

2015-03-13 Thread Jose Fonseca
On 13/03/15 13:58, Brian Paul wrote: On 03/13/2015 07:52 AM, Jose Fonseca wrote: On 12/03/15 23:08, Brian Paul wrote: On 03/12/2015 05:03 PM, Matt Turner wrote: On Thu, Mar 12, 2015 at 2:54 PM, Brian Paul wrote: --- src/gallium/auxiliary/util/u_slab.h | 13 +++-- 1 file changed

Re: [Mesa-dev] [PATCH] gallivm: (trivial) Fix typo in comment introduced by 70dc8a

2015-03-13 Thread Jose Fonseca
On 13/03/15 00:50, Alexandre Demers wrote: Fix typo in comment introduced by 70dc8a Signed-off-by: Alexandre Demers --- src/gallium/auxiliary/gallivm/lp_bld_misc.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/gallium/auxiliary/gallivm/lp_bld_misc.cpp b/src/galli

Re: [Mesa-dev] [PATCH] util: convert slab macros to inline functions

2015-03-13 Thread Jose Fonseca
On 12/03/15 23:08, Brian Paul wrote: On 03/12/2015 05:03 PM, Matt Turner wrote: On Thu, Mar 12, 2015 at 2:54 PM, Brian Paul wrote: --- src/gallium/auxiliary/util/u_slab.h | 13 +++-- 1 file changed, 11 insertions(+), 2 deletions(-) diff --git a/src/gallium/auxiliary/util/u_slab.h b

Re: [Mesa-dev] nesa-10.4.4: gallivm/lp_bld_misc.cpp:503:38: error: no viable conversion from 'ShaderMemoryManager *' to 'std::unique_ptr'

2015-03-12 Thread Jose Fonseca
On 12/03/15 18:07, Sedat Dilek wrote: On Fri, Mar 6, 2015 at 8:06 PM, Emil Velikov wrote: On 4 March 2015 at 18:07, Roland Scheidegger wrote: Am 04.03.2015 um 12:38 schrieb Jose Fonseca: On 04/03/15 02:00, Emil Velikov wrote: On 27 February 2015 at 23:28, Sedat Dilek wrote: On Mon, Feb 9

Re: [Mesa-dev] [PATCH] mesa: move fpclassify work-arounds into c99_math.h

2015-03-12 Thread Jose Fonseca
-return FP_NAN; -} -} - -#else - -enum {FP_NAN, FP_INFINITE, FP_ZERO, FP_SUBNORMAL, FP_NORMAL} -fpclassify(double x) -{ - /* XXX do something better someday */ - return FP_NORMAL; -} - -#endif GLbitfield GLAPIENTRY _mesa_QueryMatrixxOES

Re: [Mesa-dev] [PATCH 1/6] c11: add c11 compatibility wrapper around stdlib.h

2015-03-12 Thread Jose Fonseca
On 12/03/15 00:07, Emil Velikov wrote: On 9 March 2015 at 11:54, Jose Fonseca wrote: On 07/03/15 19:38, Emil Velikov wrote: On 07/03/15 07:23, Jose Fonseca wrote: ... we still didn't eliminate the use of non-portable _MTX_INITIALIZER_NP from Mesa tree gave me pause. The only way

Re: [Mesa-dev] Statically linking libstdc++ and libgcc

2015-03-12 Thread Jose Fonseca
On 11/03/15 16:01, Francisco Jerez wrote: Vivek Dasmohapatra writes: Hi - Hi, As you probably already know, there can only be one version of libstdc++.so in your runtime link chain That's a common misconception, in principle several versions of libstdc++.so with different DT_SONAME (i.e.

Re: [Mesa-dev] [PATCH 5/6] mesa: replace _ASMAPI with __cdecl

2015-03-11 Thread Jose Fonseca
On 11/03/15 16:52, Brian Paul wrote: On 03/11/2015 08:21 AM, Jose Fonseca wrote: On 11/03/15 14:07, Brian Paul wrote: On 03/11/2015 01:29 AM, Jose Fonseca wrote: I don't know the story about this _ASMAPI macro, but __cdecl is also the default calling convention for WIN32:

Re: [Mesa-dev] [PATCH 1/4] mesa: move fpclassify work-arounds into c99_math.h

2015-03-11 Thread Jose Fonseca
On 11/03/15 15:48, Brian Paul wrote: On 03/11/2015 08:20 AM, Brian Paul wrote: On 03/11/2015 01:23 AM, Jose Fonseca wrote: On 11/03/15 01:41, Brian Paul wrote: --- include/c99_math.h | 52 + src/mesa/main/querymatrix.c | 51

Re: [Mesa-dev] [PATCH 5/6] mesa: replace _ASMAPI with __cdecl

2015-03-11 Thread Jose Fonseca
On 11/03/15 14:07, Brian Paul wrote: On 03/11/2015 01:29 AM, Jose Fonseca wrote: I don't know the story about this _ASMAPI macro, but __cdecl is also the default calling convention for WIN32: https://msdn.microsoft.com/en-us/library/zkwh89ks.aspx Yeah, I had read that too actually

Re: [Mesa-dev] [PATCH 5/6] mesa: replace _ASMAPI with __cdecl

2015-03-11 Thread Jose Fonseca
I don't know the story about this _ASMAPI macro, but __cdecl is also the default calling convention for WIN32: https://msdn.microsoft.com/en-us/library/zkwh89ks.aspx so it's redundant to add it. (The other common calling convention -- __stdcall/APIENTRY/etc -- is the one that must always be

Re: [Mesa-dev] [PATCH 1/4] mesa: move fpclassify work-arounds into c99_math.h

2015-03-11 Thread Jose Fonseca
On 11/03/15 01:41, Brian Paul wrote: --- include/c99_math.h | 52 + src/mesa/main/querymatrix.c | 51 +--- 2 files changed, 53 insertions(+), 50 deletions(-) diff --git a/include/c99_math.h b/include

Re: [Mesa-dev] [PATCH 2/2] mesa: use strdup() instead of _mesa_strdup()

2015-03-11 Thread Jose Fonseca
*) strdup((char *) prog->String); clone->Format = prog->Format; clone->Instructions = _mesa_alloc_instructions(prog->NumInstructions); if (!clone->Instructions) { Series is Reviewed-by: Jose Fonseca ___ mesa-dev mailing list mesa-dev@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/mesa-dev

Re: [Mesa-dev] [PATCH 1/6] c11: add c11 compatibility wrapper around stdlib.h

2015-03-09 Thread Jose Fonseca
On 07/03/15 19:38, Emil Velikov wrote: On 07/03/15 07:23, Jose Fonseca wrote: ... we still didn't eliminate the use of non-portable _MTX_INITIALIZER_NP from Mesa tree gave me pause. The only way I can think about resolving this, is to use call_once() to initialize the mutex, Yes, I

Re: [Mesa-dev] [PATCH 1/6] c11: add c11 compatibility wrapper around stdlib.h

2015-03-06 Thread Jose Fonseca
On 07/03/15 07:23, Jose Fonseca wrote: On 06/03/15 18:26, Brian Paul wrote: On Fri, Mar 6, 2015 at 9:32 AM, Emil Velikov mailto:emil.l.veli...@gmail.com>> wrote: Used for aligned_alloc and other C11 functions missing from the header. Signed-off-by: Emil Velikov mailto:emil.

Re: [Mesa-dev] [PATCH 1/6] c11: add c11 compatibility wrapper around stdlib.h

2015-03-06 Thread Jose Fonseca
On 06/03/15 18:26, Brian Paul wrote: On Fri, Mar 6, 2015 at 9:32 AM, Emil Velikov mailto:emil.l.veli...@gmail.com>> wrote: Used for aligned_alloc and other C11 functions missing from the header. Signed-off-by: Emil Velikov mailto:emil.l.veli...@gmail.com>> --- include/c11_stdl

Re: [Mesa-dev] [PATCH, v2 2/2] r300g: Fix build, invalid extern "C" around header inclusion.

2015-03-06 Thread Jose Fonseca
uot;C" +#endif + #endif Series looks good to me too. Thanks. Reviewed-by: Jose Fonseca ___ mesa-dev mailing list mesa-dev@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/mesa-dev

Re: [Mesa-dev] [PATCH 1/2] util: rework _MSC_VER >= 1200 checks

2015-03-06 Thread Jose Fonseca
On 06/03/15 14:26, Brian Paul wrote: On 03/06/2015 05:34 AM, Emil Velikov wrote: Replace the _MSC_VER >= 1200 with defined (_MSC_VER) and compact if/else statements. We require MSVC 2008 or later with commit 46110c5d564. Signed-off-by: Emil Velikov --- src/util/macros.h | 8 +++- 1 file

Re: [Mesa-dev] [PATCH] Fix invalid extern "C" around header inclusion.

2015-03-06 Thread Jose Fonseca
On 06/03/15 00:11, Mark Janes wrote: Matt Turner writes: On Thu, Mar 5, 2015 at 4:54 AM, Jose Fonseca wrote: Thanks for doing this. It looks great. Reviewed-by: Jose Fonseca Feel free to push my patch or I'll push it after you push this one. Thanks José. I've just

Re: [Mesa-dev] [PATCH] Fix invalid extern "C" around header inclusion.

2015-03-05 Thread Jose Fonseca
Thanks for doing this. It looks great. Reviewed-by: Jose Fonseca Feel free to push my patch or I'll push it after you push this one. Jose On 05/03/15 00:37, Mark Janes wrote: System headers may contain C++ declarations, which cannot be given C linkage. For this reason, in

Re: [Mesa-dev] [PATCH 12/12] osmesa: include stdio.h

2015-03-05 Thread Jose Fonseca
/osmesa.c @@ -33,6 +33,7 @@ */ +#include #include "main/glheader.h" #include "GL/osmesa.h" #include "main/api_exec.h" Series is Reviewed-by: Jose Fonseca Jose ___ mesa-dev mailing list mesa-

Re: [Mesa-dev] [PATCH 7/7] mapi: remove u_thread.h

2015-03-05 Thread Jose Fonseca
t_table; #endif } diff --git a/src/mapi/u_execmem.c b/src/mapi/u_execmem.c index ad6427b..89d5c1d 100644 --- a/src/mapi/u_execmem.c +++ b/src/mapi/u_execmem.c @@ -33,7 +33,7 @@ #include "c99_compat.h" -#include "u_thread.h" +#include "c11/threads.h" #include "u_execmem.h" Nice cleanup. Series is Reviewed-by: Jose Fonseca Jose ___ mesa-dev mailing list mesa-dev@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/mesa-dev

Re: [Mesa-dev] [PATCH] mapi: fix build after 8aa9191878a5608fc6e4e8c72bea1d25cd821dec

2015-03-04 Thread Jose Fonseca
Reviewed-by: Jose Fonseca On 04/03/15 17:49, Mark Janes wrote: Due to recent #include changes, `make check` fails on glx-test. The target requires a standard include path to find util/macros.h. --- src/glx/tests/Makefile.am | 1 + 1 file changed, 1 insertion(+) diff --git a/src/glx/tests

[Mesa-dev] [PATCH 3/4] svga: Set MSVC2013 compat flags.

2015-03-04 Thread Jose Fonseca
--- src/gallium/drivers/svga/Makefile.am | 3 ++- src/gallium/drivers/svga/SConscript | 2 ++ 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/src/gallium/drivers/svga/Makefile.am b/src/gallium/drivers/svga/Makefile.am index 50d44cf..e0a8cad 100644 --- a/src/gallium/drivers/svga/Mak

[Mesa-dev] [PATCH 2/4] softpipe, trace: Set MSVC 2008 compat flags.

2015-03-04 Thread Jose Fonseca
Although we don't deploy these, we need to use them for debugging. --- src/gallium/drivers/softpipe/Makefile.am | 3 ++- src/gallium/drivers/softpipe/SConscript | 1 + src/gallium/drivers/trace/Makefile.am| 3 ++- src/gallium/drivers/trace/SConscript | 2 ++ 4 files changed, 7 insertions(

Re: [Mesa-dev] [PATCH 7/7] mapi: remove u_compiler.h

2015-03-04 Thread Jose Fonseca
/u_thread.h @@ -44,7 +44,7 @@ #include #include -#include "u_compiler.h" +#include "c99_compat.h" #include "c11/threads.h" Series looks good to me. Reviewed-by: Jose Fonseca ___ mesa-dev mailing list mesa-dev@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/mesa-dev

[Mesa-dev] [PATCH 1/4] scons: Use -Werror MSVC compatibility flags per-directory.

2015-03-04 Thread Jose Fonseca
Matching what we already do with autotools builds. --- scons/gallium.py| 27 --- src/egl/main/SConscript | 2 ++ src/gallium/auxiliary/SConscript| 4 src/gallium/drivers/llvmpipe/SConscript | 2 ++ src/glsl/SConscript

<    4   5   6   7   8   9   10   11   12   13   >