Commit graph

38161 commits

Author SHA1 Message Date
Vinson Lee
deffeba172 gallivm: Include missing header in lp_bld_sample.h.
Include p_format.h for enum pipe_format symbol.
2010-08-24 23:53:26 -07:00
Vinson Lee
72ae834fa1 gallivm: Include missing header in lp_bld_pack.h.
Include p_compiler.h for boolean symbol.
2010-08-24 23:50:45 -07:00
Vinson Lee
0ae6b30c14 r300/compiler: Silence uninitialized variable warning.
The variable loops would be used uninitialized if it ever processed a
RC_OPCODE_ENDLOOP case first.

This patch initalizes the loops variable to NULL and adds an assert at
the RC_OPCODE_ENDLOOP case that loops isn't NULL.

Silence the following GCC warning.
r3xx_vertprog.c: In function 'translate_vertex_program':
r3xx_vertprog.c:469: warning: 'loops' may be used uninitialized in this function
2010-08-24 23:04:20 -07:00
Vinson Lee
19f9340e67 r300g: Add missing comma in SConscript.
This is a follow-on patch to commit
574ba4b5f5.

Fixes r300g SCons build.
2010-08-24 22:28:21 -07:00
Marek Olšák
879a730231 r300g: fix gl_PointCoord
Is this hackish or is this the correct way to use point_quad_rasterization?
Copied from nvfx.
2010-08-25 04:57:11 +02:00
Vinson Lee
3a97ec7f48 r600: Include missing header in evergreen_render.c.
Fixes the following GCC warning.
evergreen_render.c: In function 'evergreenTryDrawPrims':
evergreen_render.c:836: error: implicit declaration of function 'evergreenSetupFragmentProgram'
2010-08-24 19:08:47 -07:00
Vinson Lee
8cf7eaf3ff r600: Remove unused variable.
Silences the following GCC warning.
evergreen_state.c: In function 'evergreenSetBlendState':
evergreen_state.c:341: warning: unused variable 'id'
2010-08-24 19:04:19 -07:00
Vinson Lee
e96b311037 i965: Fix printf format warnings on 32-bit builds. 2010-08-24 18:51:56 -07:00
Vinson Lee
3db9d4b253 r600: Remove unused variable.
Fixes the following GCC warning.
r600_emit.c In function 'r600AllocShaderConsts':
r600_emit.c:59: warning: unused variable 'out'
2010-08-24 18:32:51 -07:00
Vinson Lee
67925c6cd6 r600: Remove spaces between backslash and newline.
Fixes the following GCC warnings.
r600_cmdbuf.h:201: warning: backslash and newline separated by space
r600_cmdbuf.h:202: warning: backslash and newline separated by space
2010-08-24 18:20:26 -07:00
Marek Olšák
0a21938de9 r300g: eliminate unused constants in FS 2010-08-25 02:44:29 +02:00
Marek Olšák
abae06ac85 r300g: eliminate unused constants in VS 2010-08-25 02:44:29 +02:00
Marek Olšák
62eb9eda1d r300g: clean up some mess in set_constant_buffer 2010-08-25 02:44:29 +02:00
Marek Olšák
2eeaf773fd r300g: fix indentation 2010-08-25 02:44:28 +02:00
Marek Olšák
574ba4b5f5 r300/compiler: implement elimination of unused constants
Wine likes to create a *lot* of constants, exceeding the size of the constant
file in hw.
2010-08-25 02:44:28 +02:00
Marek Olšák
4b9b2a3cdc r300/compiler: terminate vertex shader compilation immediately after an error
Also rename "compiler" to "c".
2010-08-25 02:44:28 +02:00
Marek Olšák
1802007ee9 r300/compiler: fail to compile if we hit hw limits or an unimplemented feature
i.e. relative addressing (mainly FS), saturate modifiers, exceeding
the maximum number of constants.
2010-08-25 02:44:28 +02:00
Marek Olšák
6c88f84bdd r300/compiler: handle indexable temporaries correctly in deadcode elimination 2010-08-25 02:44:28 +02:00
Marek Olšák
3aee8c3b1d r300/compiler: disable register allocation for indexable temporaries in VS
If there is relative addressing of temporaries, we cannot change register
indices, so skip register allocation entirely. To utilize register allocation
at least partially, we need separate indexable and non-indexable register
files in both TGSI and Mesa IR.
2010-08-25 02:44:28 +02:00
Marek Olšák
cb925970ee r300g: reset the index bias to 0 at the end of CS 2010-08-25 02:44:28 +02:00
Marek Olšák
5755d1d6a7 ir_to_mesa: set IndirectRegisterFiles
This fixes relative addressing of temporaries (and maybe others)
in all gallium drivers.

Acked on irc by Eric Anholt.
2010-08-25 02:44:28 +02:00
Vinson Lee
57e66ed9b1 nvfx: Initialize variables on error path. 2010-08-24 17:40:50 -07:00
Eric Anholt
2f5bf20e44 glsl: Set up uniform initializers by walking the shaders after linking.
Previously, uniform initializers were handled by ir_to_mesa as it made
its Parameters list.  However, uniform values are global to all
shaders, and the value set in one Parameters list wasn't propagated to
the other gl_program->Parameters lists.  By going back through the
general Mesa uniform handling, we make sure that all gl_programs get
updated values, and also successfully separate uniform initializer
handling from ir_to_mesa gl_program generation.

Fixes:
glsl-uniform-initializer-5.
2010-08-24 16:37:02 -07:00
Eric Anholt
7de4d8fe11 glsl: Don't dead-code eliminate a uniform initializer.
Partial fix for glsl-uniform-initializer-5.
2010-08-24 16:37:02 -07:00
Dave Airlie
37f0654fa5 r300g: rename radeong_dri.so to r300_dri.so
acked on irc by Corbin + Marek.
2010-08-25 06:10:01 +10:00
Brian Paul
ad58f0d9e0 make: Use C++ compiler to link stdc++ library.
glxinfo and glxgears run on swrast and softpipe without undefined symbol
errors.
2010-08-24 12:18:09 -07:00
Vinson Lee
d3772eab2d configs: Remove -lstdc++ from default.
This patch undoes commit 9b7480cd95.

A follow-on patch will provide the proper fix.
2010-08-24 12:14:14 -07:00
Henri Verbeet
547e867558 r600g: Add support for PIPE_FORMAT_R32_FLOAT. 2010-08-24 20:52:21 +02:00
Ian Romanick
0eb2026c87 prog_execute: Implement OPCODE_TXL
Fixes bugzilla #29628
2010-08-24 10:27:14 -07:00
Brian Paul
81137623e5 glsl2: rename local variable_entry class
With MSVC it seems that this class and its constructor is colliding
with the one in ir_variable_refcount.cpp.  Rename the class here to
avoid the collision.

This is a bit of a hack.  Can the two variable_entry classes be merged
and shared?
2010-08-24 10:21:27 -06:00
Brian Paul
2eb8b2d3bb glsl2: move constructor into .cpp file to work around compiler bug
Fixes fd.o bug 29770

The refcount==0 assertion only failed on some systems.  One example
being 32-bit Linux with gcc 4.4.4.
2010-08-24 10:01:44 -06:00
Brian Paul
f3ec111b0a docs: updated info about GLSL compiler
Ian or Eric should review this and add/edit as needed.
2010-08-24 09:02:08 -06:00
Brian Paul
484dde2d63 docs: list the new GLSL compiler 2010-08-24 09:01:54 -06:00
Brian Paul
f82163b012 mesa: added isblank() for MSVC 2010-08-24 08:04:37 -06:00
Brian Paul
d902eb59d5 mesa: remove non-existant files from tarball list 2010-08-24 07:51:52 -06:00
Vinson Lee
c8b26c63fd glsl: Add assert to check variable_entry referenced_count after construction.
A variable_entry after construction should have its referenced_count
member set to 0. However, occassionally this isn't the case and
entry->referenced_count has been observed to be a garbage value. This
leads to crashes of several tests in the Piglit test suite.

This patch adds an assert to check that a variable_entry instance has
its referenced_count member initialized to 0 after construction.
2010-08-24 01:16:46 -07:00
Vinson Lee
b018ea19a3 nvfx: Remove unnecessary headers. 2010-08-23 23:58:57 -07:00
Dave Airlie
f122dba59a glsl: make 'make clean' work properly.
this has make clean remove all the objects.
2010-08-24 16:10:28 +10:00
Vinson Lee
e5df3cc286 glsl: Silence unused variable warning.
The variable is used but only in the body of an assert.
2010-08-23 22:27:49 -07:00
Vinson Lee
b48f20dab8 r300g: Remove unused variable.
Fixes this GCC warning.
r300_render.c: In function 'r300_draw_flush_vbuf':
r300_render.c:988: warning: unused variable 'r300_render'
2010-08-23 22:15:24 -07:00
Chia-I Wu
1288d5c392 st/egl: Fix r300/r600 support in KMS backend.
When the kernel driver name is radeon, ask the loader for r300 or r600
depending on the PCI ID.
2010-08-24 11:50:37 +08:00
Chia-I Wu
65741c596f targets/egl: Check against drm_driver_descriptor::name.
drm_driver_descriptor::driver_name is defined to be the name of the
kernel module.  We should check against drm_driver_descriptor::name
instead of drm_driver_descriptor::driver_name.
2010-08-24 11:50:36 +08:00
Benjamin Franzke
0ba1643658 targets/egl: add pipe_r600
KNOWN ISSUE: eglShowScreenSurfaceMESA in st/egl/kms fails
but st/egl/x11 works
2010-08-24 11:50:36 +08:00
Benjamin Franzke
ce7016e882 targets/egl: rename pipe_radeon to pipe_r300
st/egl/x11/x11_screen.c requests a driver named r300 not radeon

KNOWN ISSUE: breaks st/egl/kms/
	st/egl/kms requests a pipe named "radeon"
	that will not be found now

	so why not leaving pipe_radeon there?
	that was possible as long we have only r300g.
	now there is also r600g for which st/egl/kms also
	requests a pipe named "radeon"
	(possible solution in later commit)
2010-08-24 11:50:36 +08:00
Chia-I Wu
9dd95b46c8 mesa: Remove extraneous semicolon. 2010-08-24 11:49:55 +08:00
Chia-I Wu
d473543069 st/dri: Remove unnecessary main/mtype.h. 2010-08-24 11:36:52 +08:00
Chia-I Wu
59e6e76542 st/wgl: Include main/core.h.
Make st/wgl include only main/core.h from core mesa.
2010-08-24 11:36:48 +08:00
Chia-I Wu
40fd4323b4 st/glx: Include main/core.h.
Make st/glx include only main/core.h from core mesa.
2010-08-24 11:28:12 +08:00
Chia-I Wu
bfd7c9ac22 glsl: Include main/core.h.
Make glsl include only main/core.h from core mesa.
2010-08-24 11:27:29 +08:00
Chia-I Wu
f90b5936d0 mesa: Add core.h.
core.h is the public header of core mesa.  GLX, WGL, and GLSL are
supposed to include this header file.  It should be noted that headers
included by core.h must not perform feature tests (#if FEATURE_xxx).
Otherwise, we cannot, for example, mix a FEATURE_ES2 libmesagallium.a
with a FEATURE_GL libglsl.a.
2010-08-24 11:00:29 +08:00