aboutsummaryrefslogtreecommitdiff
path: root/mesalib/src/mesa
diff options
context:
space:
mode:
Diffstat (limited to 'mesalib/src/mesa')
-rw-r--r--mesalib/src/mesa/Makefile.sources1
-rw-r--r--mesalib/src/mesa/drivers/common/meta_blit.c33
-rw-r--r--mesalib/src/mesa/drivers/common/meta_copy_image.c9
-rw-r--r--mesalib/src/mesa/drivers/dri/common/xmlpool/ca.po129
-rw-r--r--mesalib/src/mesa/drivers/dri/common/xmlpool/de.po118
-rw-r--r--mesalib/src/mesa/drivers/dri/common/xmlpool/es.po122
-rw-r--r--mesalib/src/mesa/drivers/dri/common/xmlpool/fr.po118
-rw-r--r--mesalib/src/mesa/drivers/dri/common/xmlpool/nl.po118
-rw-r--r--mesalib/src/mesa/drivers/dri/common/xmlpool/sv.po118
-rw-r--r--mesalib/src/mesa/main/arrayobj.c2
-rw-r--r--mesalib/src/mesa/main/arrayobj.h26
-rw-r--r--mesalib/src/mesa/main/attrib.c2
-rw-r--r--mesalib/src/mesa/main/compiler.h4
-rw-r--r--mesalib/src/mesa/main/context.c27
-rw-r--r--mesalib/src/mesa/main/debug.c4
-rw-r--r--mesalib/src/mesa/main/dlopen.h19
-rw-r--r--mesalib/src/mesa/main/errors.c8
-rw-r--r--mesalib/src/mesa/main/extensions.c11
-rw-r--r--mesalib/src/mesa/main/fbobject.c60
-rw-r--r--mesalib/src/mesa/main/get_hash_params.py8
-rw-r--r--mesalib/src/mesa/main/imports.c80
-rw-r--r--mesalib/src/mesa/main/imports.h45
-rw-r--r--mesalib/src/mesa/main/macros.h7
-rw-r--r--mesalib/src/mesa/main/mtypes.h20
-rw-r--r--mesalib/src/mesa/main/shaderapi.c10
-rw-r--r--mesalib/src/mesa/main/shaderobj.h7
-rw-r--r--mesalib/src/mesa/main/texcompress_s3tc.c2
-rw-r--r--mesalib/src/mesa/main/varray.c8
-rw-r--r--mesalib/src/mesa/main/version.c16
-rw-r--r--mesalib/src/mesa/main/viewport.c6
-rw-r--r--mesalib/src/mesa/math/m_debug_clip.c2
-rw-r--r--mesalib/src/mesa/math/m_debug_norm.c2
-rw-r--r--mesalib/src/mesa/math/m_debug_xform.c2
-rw-r--r--mesalib/src/mesa/program/ir_to_mesa.cpp14
-rw-r--r--mesalib/src/mesa/program/prog_instruction.c5
-rw-r--r--mesalib/src/mesa/program/prog_parameter.c5
-rw-r--r--mesalib/src/mesa/program/register_allocate.c654
-rw-r--r--mesalib/src/mesa/program/register_allocate.h79
-rw-r--r--mesalib/src/mesa/program/symbol_table.c30
-rw-r--r--mesalib/src/mesa/state_tracker/st_atom_rasterizer.c6
-rw-r--r--mesalib/src/mesa/state_tracker/st_atom_texture.c2
-rw-r--r--mesalib/src/mesa/state_tracker/st_cb_bufferobjects.c8
-rw-r--r--mesalib/src/mesa/state_tracker/st_cb_fbo.c3
-rw-r--r--mesalib/src/mesa/state_tracker/st_context.c2
-rw-r--r--mesalib/src/mesa/state_tracker/st_extensions.c25
-rw-r--r--mesalib/src/mesa/state_tracker/st_extensions.h1
-rw-r--r--mesalib/src/mesa/state_tracker/st_glsl_to_tgsi.cpp19
-rw-r--r--mesalib/src/mesa/state_tracker/st_manager.c2
-rw-r--r--mesalib/src/mesa/state_tracker/st_program.c46
-rw-r--r--mesalib/src/mesa/state_tracker/st_program.h25
-rw-r--r--mesalib/src/mesa/state_tracker/st_texture.c5
-rw-r--r--mesalib/src/mesa/tnl/t_vb_cliptmp.h10
-rw-r--r--mesalib/src/mesa/tnl/t_vertex.c2
-rw-r--r--mesalib/src/mesa/vbo/vbo_exec_api.c2
-rw-r--r--mesalib/src/mesa/vbo/vbo_exec_array.c46
-rw-r--r--mesalib/src/mesa/vbo/vbo_primitive_restart.c4
-rw-r--r--mesalib/src/mesa/x86/assyntax.h6
-rw-r--r--mesalib/src/mesa/x86/common_x86.c10
-rw-r--r--mesalib/src/mesa/x86/read_rgba_span_x86.S4
59 files changed, 715 insertions, 1444 deletions
diff --git a/mesalib/src/mesa/Makefile.sources b/mesalib/src/mesa/Makefile.sources
index 12336c074..475501877 100644
--- a/mesalib/src/mesa/Makefile.sources
+++ b/mesalib/src/mesa/Makefile.sources
@@ -280,7 +280,6 @@ PROGRAM_FILES = \
$(SRCDIR)program/prog_print.c \
$(SRCDIR)program/prog_statevars.c \
$(SRCDIR)program/programopt.c \
- $(SRCDIR)program/register_allocate.c \
$(SRCDIR)program/sampler.cpp \
$(SRCDIR)program/string_to_uint_map.cpp \
$(SRCDIR)program/symbol_table.c \
diff --git a/mesalib/src/mesa/drivers/common/meta_blit.c b/mesalib/src/mesa/drivers/common/meta_blit.c
index fc9848a7a..770bc4178 100644
--- a/mesalib/src/mesa/drivers/common/meta_blit.c
+++ b/mesalib/src/mesa/drivers/common/meta_blit.c
@@ -70,26 +70,28 @@ setup_glsl_msaa_blit_shader(struct gl_context *ctx,
const char *sampler_array_suffix = "";
char *name;
const char *texcoord_type = "vec2";
- const int samples = MAX2(src_rb->NumSamples, 1);
+ int samples;
int shader_offset = 0;
- /* We expect only power of 2 samples in source multisample buffer. */
- assert((samples & (samples - 1)) == 0);
- while (samples >> (shader_offset + 1)) {
- shader_offset++;
- }
- /* Update the assert if we plan to support more than 16X MSAA. */
- assert(shader_offset >= 0 && shader_offset <= 4);
-
if (src_rb) {
+ samples = MAX2(src_rb->NumSamples, 1);
src_datatype = _mesa_get_format_datatype(src_rb->Format);
} else {
/* depth-or-color glCopyTexImage fallback path that passes a NULL rb and
* doesn't handle integer.
*/
+ samples = 1;
src_datatype = GL_UNSIGNED_NORMALIZED;
}
+ /* We expect only power of 2 samples in source multisample buffer. */
+ assert((samples & (samples - 1)) == 0);
+ while (samples >> (shader_offset + 1)) {
+ shader_offset++;
+ }
+ /* Update the assert if we plan to support more than 16X MSAA. */
+ assert(shader_offset >= 0 && shader_offset <= 4);
+
if (ctx->DrawBuffer->Visual.samples > 1) {
/* If you're calling meta_BlitFramebuffer with the destination
* multisampled, this is the only path that will work -- swrast and
@@ -108,8 +110,8 @@ setup_glsl_msaa_blit_shader(struct gl_context *ctx,
switch (target) {
case GL_TEXTURE_2D_MULTISAMPLE:
case GL_TEXTURE_2D_MULTISAMPLE_ARRAY:
- if (src_rb->_BaseFormat == GL_DEPTH_COMPONENT ||
- src_rb->_BaseFormat == GL_DEPTH_STENCIL) {
+ if (src_rb && (src_rb->_BaseFormat == GL_DEPTH_COMPONENT ||
+ src_rb->_BaseFormat == GL_DEPTH_STENCIL)) {
if (dst_is_msaa)
shader_index = BLIT_MSAA_SHADER_2D_MULTISAMPLE_DEPTH_COPY;
else
@@ -624,13 +626,20 @@ _mesa_meta_bind_rb_as_tex_image(struct gl_context *ctx,
GLenum *target)
{
struct gl_texture_image *texImage;
+ GLuint tempTex;
if (rb->NumSamples > 1)
*target = GL_TEXTURE_2D_MULTISAMPLE;
else
*target = GL_TEXTURE_2D;
- _mesa_GenTextures(1, tex);
+ tempTex = 0;
+ _mesa_GenTextures(1, &tempTex);
+ if (tempTex == 0)
+ return false;
+
+ *tex = tempTex;
+
_mesa_BindTexture(*target, *tex);
*texObj = _mesa_lookup_texture(ctx, *tex);
texImage = _mesa_get_tex_image(ctx, *texObj, *target, 0);
diff --git a/mesalib/src/mesa/drivers/common/meta_copy_image.c b/mesalib/src/mesa/drivers/common/meta_copy_image.c
index 0c204b87d..fc0cbaf1b 100644
--- a/mesalib/src/mesa/drivers/common/meta_copy_image.c
+++ b/mesalib/src/mesa/drivers/common/meta_copy_image.c
@@ -63,12 +63,21 @@ make_view(struct gl_context *ctx, struct gl_texture_image *tex_image,
if (!ctx->Driver.TestProxyTexImage(ctx, tex_obj->Target, 0, tex_format,
tex_image->Width, tex_image->Height,
tex_image->Depth, 0)) {
+ _mesa_DeleteTextures(1, view_tex_name);
+ *view_tex_name = 0;
return false;
}
view_tex_obj->Target = tex_obj->Target;
*view_tex_image = _mesa_get_tex_image(ctx, view_tex_obj, tex_obj->Target, 0);
+
+ if (!*view_tex_image) {
+ _mesa_DeleteTextures(1, view_tex_name);
+ *view_tex_name = 0;
+ return false;
+ }
+
_mesa_init_teximage_fields(ctx, *view_tex_image,
tex_image->Width, tex_image->Height,
tex_image->Depth,
diff --git a/mesalib/src/mesa/drivers/dri/common/xmlpool/ca.po b/mesalib/src/mesa/drivers/dri/common/xmlpool/ca.po
index c0cf7f62c..23e9f4211 100644
--- a/mesalib/src/mesa/drivers/dri/common/xmlpool/ca.po
+++ b/mesalib/src/mesa/drivers/dri/common/xmlpool/ca.po
@@ -21,20 +21,19 @@
# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
# FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS
# IN THE SOFTWARE.
-
msgid ""
msgstr ""
"Project-Id-Version: Mesa 10.1.0-devel\n"
"Report-Msgid-Bugs-To: \n"
-"POT-Creation-Date: 2014-01-13 22:30-0700\n"
-"PO-Revision-Date: 2014-01-15 10:37-0700\n"
+"POT-Creation-Date: 2014-09-25 22:29-0600\n"
+"PO-Revision-Date: 2014-09-26 14:43-0700\n"
"Last-Translator: Alex Henrie <alexhenrie24@gmail.com>\n"
"Language-Team: Catalan <ca@li.org>\n"
"Language: ca\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
-"X-Generator: Poedit 1.5.4\n"
+"X-Generator: Poedit 1.6.9\n"
#: t_options.h:56
msgid "Debugging"
@@ -73,8 +72,8 @@ msgstr "Deshabilita la barreja de font dual"
#: t_options.h:95
msgid "Disable backslash-based line continuations in GLSL source"
msgstr ""
-"Deshabilitar les continuacions de línia basades en barra invertida en la "
-"font GLSL"
+"Deshabilita les continuacions de línia basades en barra invertida en la font "
+"GLSL"
#: t_options.h:100
msgid "Disable GL_ARB_shader_bit_encoding"
@@ -87,108 +86,112 @@ msgstr ""
"Força una versió GLSL per defecte en els shaders als quals falta una línia "
"#version explícita"
-#: t_options.h:115
+#: t_options.h:110
+msgid "Allow GLSL #extension directives in the middle of shaders"
+msgstr "Permet les directives #extension GLSL en el mitjà dels shaders"
+
+#: t_options.h:120
msgid "Image Quality"
msgstr "Qualitat d'Imatge"
-#: t_options.h:128
+#: t_options.h:133
msgid "Texture color depth"
msgstr "Profunditat de color de textura"
-#: t_options.h:129
+#: t_options.h:134
msgid "Prefer frame buffer color depth"
msgstr "Prefereix profunditat de color del framebuffer"
-#: t_options.h:130
+#: t_options.h:135
msgid "Prefer 32 bits per texel"
msgstr "Prefereix 32 bits per texel"
-#: t_options.h:131
+#: t_options.h:136
msgid "Prefer 16 bits per texel"
msgstr "Prefereix 16 bits per texel"
-#: t_options.h:132
+#: t_options.h:137
msgid "Force 16 bits per texel"
msgstr "Força 16 bits per texel"
-#: t_options.h:138
+#: t_options.h:143
msgid "Initial maximum value for anisotropic texture filtering"
msgstr "Valor màxim inicial per a la filtració de textura anisòtropa"
-#: t_options.h:143
+#: t_options.h:148
msgid "Forbid negative texture LOD bias"
msgstr ""
"Prohibeix una parcialitat negativa del Nivell de Detalle (LOD) de les "
"textures"
-#: t_options.h:148
+#: t_options.h:153
msgid ""
"Enable S3TC texture compression even if software support is not available"
msgstr ""
-"Habilitar la compressió de textures S3TC encara que el suport de programari "
+"Habilita la compressió de textures S3TC encara que el suport de programari "
"no estigui disponible"
-#: t_options.h:155
+#: t_options.h:160
msgid "Initial color reduction method"
msgstr "Mètode inicial de reducció de color"
-#: t_options.h:156
+#: t_options.h:161
msgid "Round colors"
msgstr "Colors arrodonits"
-#: t_options.h:157
+#: t_options.h:162
msgid "Dither colors"
msgstr "Colors tramats"
-#: t_options.h:165
+#: t_options.h:170
msgid "Color rounding method"
msgstr "Mètode d'arrodoniment de color"
-#: t_options.h:166
+#: t_options.h:171
msgid "Round color components downward"
msgstr "Arrondeix els components de color a baix"
-#: t_options.h:167
+#: t_options.h:172
msgid "Round to nearest color"
msgstr "Arrondeix al color més proper"
-#: t_options.h:176
+#: t_options.h:181
msgid "Color dithering method"
msgstr "Mètode de tramat de color"
-#: t_options.h:177
+#: t_options.h:182
msgid "Horizontal error diffusion"
msgstr "Difusió d'error horitzontal"
-#: t_options.h:178
+#: t_options.h:183
msgid "Horizontal error diffusion, reset error at line start"
msgstr "Difusió d'error horitzontal, reinicia l'error a l'inici de la línia"
-#: t_options.h:179
+#: t_options.h:184
msgid "Ordered 2D color dithering"
msgstr "Tramat de color 2D ordenat"
-#: t_options.h:185
+#: t_options.h:190
msgid "Floating point depth buffer"
msgstr "Buffer de profunditat de punt flotant"
-#: t_options.h:190
+#: t_options.h:195
msgid "A post-processing filter to cel-shade the output"
msgstr "Un filtre de postprocessament per a aplicar cel shading a la sortida"
-#: t_options.h:195
+#: t_options.h:200
msgid "A post-processing filter to remove the red channel"
msgstr "Un filtre de postprocessament per a treure el canal vermell"
-#: t_options.h:200
+#: t_options.h:205
msgid "A post-processing filter to remove the green channel"
msgstr "Un filtre de postprocessament per a treure el canal verd"
-#: t_options.h:205
+#: t_options.h:210
msgid "A post-processing filter to remove the blue channel"
msgstr "Un filtre de postprocessament per a treure el canal blau"
-#: t_options.h:210
+#: t_options.h:215
msgid ""
"Morphological anti-aliasing based on Jimenez\\' MLAA. 0 to disable, 8 for "
"default quality"
@@ -196,7 +199,7 @@ msgstr ""
"Antialiàsing morfològic basat en el MLAA de Jimenez. 0 per deshabilitar, 8 "
"per qualitat per defecte"
-#: t_options.h:215
+#: t_options.h:220
msgid ""
"Morphological anti-aliasing based on Jimenez\\' MLAA. 0 to disable, 8 for "
"default quality. Color version, usable with 2d GL apps"
@@ -205,68 +208,68 @@ msgstr ""
"per qualitat per defecte. Versió en color, utilitzable amb les aplicacions "
"GL 2D"
-#: t_options.h:225
+#: t_options.h:230
msgid "Performance"
msgstr "Rendiment"
-#: t_options.h:233
+#: t_options.h:238
msgid "TCL mode (Transformation, Clipping, Lighting)"
msgstr "Mode TCL (Transformació, Retall, Il·luminació)"
-#: t_options.h:234
+#: t_options.h:239
msgid "Use software TCL pipeline"
msgstr "Utilitza la canonada TCL de programari"
-#: t_options.h:235
+#: t_options.h:240
msgid "Use hardware TCL as first TCL pipeline stage"
msgstr "Utilitza el TCL maquinàri com la primera fase de la canonada TCL"
-#: t_options.h:236
+#: t_options.h:241
msgid "Bypass the TCL pipeline"
msgstr "Passar per alt la canonada TCL"
-#: t_options.h:237
+#: t_options.h:242
msgid ""
"Bypass the TCL pipeline with state-based machine code generated on-the-fly"
msgstr ""
"Passar per alt la canonada TCL amb codi màquina basat en estats, generat "
"sobre la marxa"
-#: t_options.h:246
+#: t_options.h:251
msgid "Method to limit rendering latency"
msgstr "Mètode per a limitar la latència de renderització"
-#: t_options.h:247
+#: t_options.h:252
msgid "Busy waiting for the graphics hardware"
msgstr "Espera activa pel maquinari de gràfics"
-#: t_options.h:248
+#: t_options.h:253
msgid "Sleep for brief intervals while waiting for the graphics hardware"
msgstr "Dormi per intervals breus mentre s'espera al maquinari de gràfics"
-#: t_options.h:249
+#: t_options.h:254
msgid "Let the graphics hardware emit a software interrupt and sleep"
msgstr ""
"Deixa que el maquinari de gràfics emeti una interrupció de programari i dormi"
-#: t_options.h:259
+#: t_options.h:264
msgid "Synchronization with vertical refresh (swap intervals)"
msgstr "Sincronització amb refresc vertical (intervals d'intercanvi)"
-#: t_options.h:260
+#: t_options.h:265
msgid "Never synchronize with vertical refresh, ignore application's choice"
msgstr ""
"Mai sincronitzis amb el refresc vertial, ignora l'elecció de l'aplicació"
-#: t_options.h:261
+#: t_options.h:266
msgid "Initial swap interval 0, obey application's choice"
msgstr "Interval d'intercanvi inicial 0, obeeix l'elecció de l'aplicació"
-#: t_options.h:262
+#: t_options.h:267
msgid "Initial swap interval 1, obey application's choice"
msgstr "Interval d'intercanvi inicial 1, obeeix l'elecció de l'aplicació"
-#: t_options.h:263
+#: t_options.h:268
msgid ""
"Always synchronize with vertical refresh, application chooses the minimum "
"swap interval"
@@ -274,48 +277,56 @@ msgstr ""
"Sempre sincronitza amb el refresc vertical, l'aplicació tria l'interval "
"mínim d'intercanvi"
-#: t_options.h:271
+#: t_options.h:276
msgid "Use HyperZ to boost performance"
msgstr "Utilitza el HyperZ per a augmentar el rendiment"
-#: t_options.h:276
+#: t_options.h:281
msgid "Number of texture units used"
msgstr "Nombre d'unitats de textura utilitzades"
-#: t_options.h:281
+#: t_options.h:286
msgid "Texture filtering quality vs. speed, AKA “brilinear” texture filtering"
msgstr ""
"Qualitat vs. velocitat de filtració de textura, àlies filtració \"brilinear"
"\" de textura"
-#: t_options.h:289
+#: t_options.h:294
msgid "Used types of texture memory"
msgstr "Tipus utilitzats de memòria de textura"
-#: t_options.h:290
+#: t_options.h:295
msgid "All available memory"
msgstr "Tota la memòria disponible"
-#: t_options.h:291
+#: t_options.h:296
msgid "Only card memory (if available)"
msgstr "Només memòria de tarjeta (si està disponible)"
-#: t_options.h:292
+#: t_options.h:297
msgid "Only GART (AGP/PCIE) memory (if available)"
msgstr "Només memòria GART (AGP/PCIE) (si està disponible)"
-#: t_options.h:304
+#: t_options.h:309
msgid "Features that are not hardware-accelerated"
msgstr "Característiques no accelerades per maquinari"
-#: t_options.h:308
+#: t_options.h:313
msgid "Enable extension GL_ARB_vertex_program"
msgstr "Habilita l'extensió GL_ARB_vertex_program"
-#: t_options.h:318
+#: t_options.h:323
msgid "Miscellaneous"
msgstr "Miscel·lània"
-#: t_options.h:322
+#: t_options.h:327
msgid "Create all visuals with a depth buffer"
msgstr "Crea tots els visuals amb buffer de profunditat"
+
+#: t_options.h:337
+msgid "Initialization"
+msgstr "Inicialització"
+
+#: t_options.h:341
+msgid "Define the graphic device to use if possible"
+msgstr "Defineix el dispositiu de gràfics que usar si és possible"
diff --git a/mesalib/src/mesa/drivers/dri/common/xmlpool/de.po b/mesalib/src/mesa/drivers/dri/common/xmlpool/de.po
index fff7e8bef..7b20d00a6 100644
--- a/mesalib/src/mesa/drivers/dri/common/xmlpool/de.po
+++ b/mesalib/src/mesa/drivers/dri/common/xmlpool/de.po
@@ -7,7 +7,7 @@ msgid ""
msgstr ""
"Project-Id-Version: Mesa 6.3\n"
"Report-Msgid-Bugs-To: \n"
-"POT-Creation-Date: 2014-01-13 22:30-0700\n"
+"POT-Creation-Date: 2014-09-25 22:29-0600\n"
"PO-Revision-Date: 2005-04-11 01:34+0200\n"
"Last-Translator: Felix Kuehling <fxkuehl@gmx.de>\n"
"Language-Team: German <de@li.org>\n"
@@ -63,106 +63,110 @@ msgid ""
"Force a default GLSL version for shaders that lack an explicit #version line"
msgstr ""
-#: t_options.h:115
+#: t_options.h:110
+msgid "Allow GLSL #extension directives in the middle of shaders"
+msgstr ""
+
+#: t_options.h:120
msgid "Image Quality"
msgstr "Bildqualität"
-#: t_options.h:128
+#: t_options.h:133
msgid "Texture color depth"
msgstr "Texturfarbtiefe"
-#: t_options.h:129
+#: t_options.h:134
msgid "Prefer frame buffer color depth"
msgstr "Bevorzuge Farbtiefe des Framebuffers"
-#: t_options.h:130
+#: t_options.h:135
msgid "Prefer 32 bits per texel"
msgstr "Bevorzuge 32 bits pro Texel"
-#: t_options.h:131
+#: t_options.h:136
msgid "Prefer 16 bits per texel"
msgstr "Bevorzuge 16 bits pro Texel"
-#: t_options.h:132
+#: t_options.h:137
msgid "Force 16 bits per texel"
msgstr "Erzwinge 16 bits pro Texel"
-#: t_options.h:138
+#: t_options.h:143
msgid "Initial maximum value for anisotropic texture filtering"
msgstr "Initialer Maximalwert für anisotropische Texturfilterung"
-#: t_options.h:143
+#: t_options.h:148
msgid "Forbid negative texture LOD bias"
msgstr "Verbiete negative Textur-Detailgradverschiebung"
-#: t_options.h:148
+#: t_options.h:153
msgid ""
"Enable S3TC texture compression even if software support is not available"
msgstr ""
"Aktiviere S3TC Texturkomprimierung auch wenn die nötige "
"Softwareunterstützung fehlt"
-#: t_options.h:155
+#: t_options.h:160
msgid "Initial color reduction method"
msgstr "Initiale Farbreduktionsmethode"
-#: t_options.h:156
+#: t_options.h:161
msgid "Round colors"
msgstr "Farben runden"
-#: t_options.h:157
+#: t_options.h:162
msgid "Dither colors"
msgstr "Farben rastern"
-#: t_options.h:165
+#: t_options.h:170
msgid "Color rounding method"
msgstr "Farbrundungsmethode"
-#: t_options.h:166
+#: t_options.h:171
msgid "Round color components downward"
msgstr "Farbkomponenten abrunden"
-#: t_options.h:167
+#: t_options.h:172
msgid "Round to nearest color"
msgstr "Zur ähnlichsten Farbe runden"
-#: t_options.h:176
+#: t_options.h:181
msgid "Color dithering method"
msgstr "Farbrasterungsmethode"
-#: t_options.h:177
+#: t_options.h:182
msgid "Horizontal error diffusion"
msgstr "Horizontale Fehlerstreuung"
-#: t_options.h:178
+#: t_options.h:183
msgid "Horizontal error diffusion, reset error at line start"
msgstr "Horizontale Fehlerstreuung, Fehler am Zeilenanfang zurücksetzen"
-#: t_options.h:179
+#: t_options.h:184
msgid "Ordered 2D color dithering"
msgstr "Geordnete 2D Farbrasterung"
-#: t_options.h:185
+#: t_options.h:190
msgid "Floating point depth buffer"
msgstr "Fließkomma z-Puffer"
-#: t_options.h:190
+#: t_options.h:195
msgid "A post-processing filter to cel-shade the output"
msgstr "Nachbearbeitungsfilter für Cell Shading"
-#: t_options.h:195
+#: t_options.h:200
msgid "A post-processing filter to remove the red channel"
msgstr "Nachbearbeitungsfilter zum Entfernen des Rotkanals"
-#: t_options.h:200
+#: t_options.h:205
msgid "A post-processing filter to remove the green channel"
msgstr "Nachbearbeitungsfilter zum Entfernen des Grünkanals"
-#: t_options.h:205
+#: t_options.h:210
msgid "A post-processing filter to remove the blue channel"
msgstr "Nachbearbeitungsfilter zum Entfernen des Blaukanals"
-#: t_options.h:210
+#: t_options.h:215
msgid ""
"Morphological anti-aliasing based on Jimenez\\' MLAA. 0 to disable, 8 for "
"default quality"
@@ -170,7 +174,7 @@ msgstr ""
"Morphologische Kantenglättung (Anti-Aliasing) basierend auf Jimenez' MLAA. 0 "
"für deaktiviert, 8 für Standardqualität"
-#: t_options.h:215
+#: t_options.h:220
msgid ""
"Morphological anti-aliasing based on Jimenez\\' MLAA. 0 to disable, 8 for "
"default quality. Color version, usable with 2d GL apps"
@@ -178,69 +182,69 @@ msgstr ""
"Morphologische Kantenglättung (Anti-Aliasing) basierend auf Jimenez' MLAA. 0 "
"für deaktiviert, 8 für Standardqualität. Farbversion, für 2D-Anwendungen"
-#: t_options.h:225
+#: t_options.h:230
msgid "Performance"
msgstr "Leistung"
-#: t_options.h:233
+#: t_options.h:238
msgid "TCL mode (Transformation, Clipping, Lighting)"
msgstr "TCL-Modus (Transformation, Clipping, Licht)"
-#: t_options.h:234
+#: t_options.h:239
msgid "Use software TCL pipeline"
msgstr "Benutze die Software-TCL-Pipeline"
-#: t_options.h:235
+#: t_options.h:240
msgid "Use hardware TCL as first TCL pipeline stage"
msgstr "Benutze Hardware TCL als erste Stufe der TCL-Pipeline"
-#: t_options.h:236
+#: t_options.h:241
msgid "Bypass the TCL pipeline"
msgstr "Umgehe die TCL-Pipeline"
-#: t_options.h:237
+#: t_options.h:242
msgid ""
"Bypass the TCL pipeline with state-based machine code generated on-the-fly"
msgstr ""
"Umgehe die TCL-Pipeline mit zur Laufzeit erzeugtem, zustandsbasiertem "
"Maschinencode"
-#: t_options.h:246
+#: t_options.h:251
msgid "Method to limit rendering latency"
msgstr "Methode zur Begrenzung der Bildverzögerung"
-#: t_options.h:247
+#: t_options.h:252
msgid "Busy waiting for the graphics hardware"
msgstr "Aktives Warten auf die Grafikhardware"
-#: t_options.h:248
+#: t_options.h:253
msgid "Sleep for brief intervals while waiting for the graphics hardware"
msgstr "Kurze Schlafintervalle beim Warten auf die Grafikhardware"
-#: t_options.h:249
+#: t_options.h:254
msgid "Let the graphics hardware emit a software interrupt and sleep"
msgstr ""
"Die Grafikhardware eine Softwareunterbrechnung erzeugen lassen und schlafen"
-#: t_options.h:259
+#: t_options.h:264
msgid "Synchronization with vertical refresh (swap intervals)"
msgstr "Synchronisation mit der vertikalen Bildwiederholung"
-#: t_options.h:260
+#: t_options.h:265
msgid "Never synchronize with vertical refresh, ignore application's choice"
msgstr ""
"Niemals mit der Bildwiederholung synchronisieren, Anweisungen der Anwendung "
"ignorieren"
-#: t_options.h:261
+#: t_options.h:266
msgid "Initial swap interval 0, obey application's choice"
msgstr "Initiales Bildinterval 0, Anweisungen der Anwendung gehorchen"
-#: t_options.h:262
+#: t_options.h:267
msgid "Initial swap interval 1, obey application's choice"
msgstr "Initiales Bildinterval 1, Anweisungen der Anwendung gehorchen"
-#: t_options.h:263
+#: t_options.h:268
msgid ""
"Always synchronize with vertical refresh, application chooses the minimum "
"swap interval"
@@ -248,52 +252,60 @@ msgstr ""
"Immer mit der Bildwiederholung synchronisieren, Anwendung wählt das minimale "
"Bildintervall"
-#: t_options.h:271
+#: t_options.h:276
msgid "Use HyperZ to boost performance"
msgstr "HyperZ zur Leistungssteigerung verwenden"
-#: t_options.h:276
+#: t_options.h:281
msgid "Number of texture units used"
msgstr "Anzahl der benutzten Textureinheiten"
-#: t_options.h:281
+#: t_options.h:286
msgid "Texture filtering quality vs. speed, AKA “brilinear” texture filtering"
msgstr ""
"Texturfilterqualität versus -geschwindigkeit, auch bekannt als „brilineare“ "
"Texturfilterung"
-#: t_options.h:289
+#: t_options.h:294
msgid "Used types of texture memory"
msgstr "Benutzte Arten von Texturspeicher"
-#: t_options.h:290
+#: t_options.h:295
msgid "All available memory"
msgstr "Aller verfügbarer Speicher"
-#: t_options.h:291
+#: t_options.h:296
msgid "Only card memory (if available)"
msgstr "Nur Grafikspeicher (falls verfügbar)"
-#: t_options.h:292
+#: t_options.h:297
msgid "Only GART (AGP/PCIE) memory (if available)"
msgstr "Nur GART-Speicher (AGP/PCIE) (falls verfügbar)"
-#: t_options.h:304
+#: t_options.h:309
msgid "Features that are not hardware-accelerated"
msgstr "Funktionalität, die nicht hardwarebeschleunigt ist"
-#: t_options.h:308
+#: t_options.h:313
msgid "Enable extension GL_ARB_vertex_program"
msgstr "Erweiterung GL_ARB_vertex_program aktivieren"
-#: t_options.h:318
+#: t_options.h:323
msgid "Miscellaneous"
msgstr ""
-#: t_options.h:322
+#: t_options.h:327
msgid "Create all visuals with a depth buffer"
msgstr ""
+#: t_options.h:337
+msgid "Initialization"
+msgstr ""
+
+#: t_options.h:341
+msgid "Define the graphic device to use if possible"
+msgstr ""
+
#~ msgid "Support larger textures not guaranteed to fit into graphics memory"
#~ msgstr ""
#~ "Unterstütze grosse Texturen die evtl. nicht in den Grafikspeicher passen"
diff --git a/mesalib/src/mesa/drivers/dri/common/xmlpool/es.po b/mesalib/src/mesa/drivers/dri/common/xmlpool/es.po
index 4a6ab91a5..a68c329a5 100644
--- a/mesalib/src/mesa/drivers/dri/common/xmlpool/es.po
+++ b/mesalib/src/mesa/drivers/dri/common/xmlpool/es.po
@@ -9,8 +9,8 @@ msgid ""
msgstr ""
"Project-Id-Version: es\n"
"Report-Msgid-Bugs-To: \n"
-"POT-Creation-Date: 2014-01-13 22:30-0700\n"
-"PO-Revision-Date: 2014-01-15 10:34-0700\n"
+"POT-Creation-Date: 2014-09-25 22:29-0600\n"
+"PO-Revision-Date: 2014-09-26 14:22-0700\n"
"Last-Translator: Alex Henrie <alexhenrie24@gmail.com>\n"
"Language-Team: Spanish <es@li.org>\n"
"Language: es\n"
@@ -18,7 +18,7 @@ msgstr ""
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Plural-Forms: nplurals=2; plural=(n != 1);\n"
-"X-Generator: Poedit 1.5.4\n"
+"X-Generator: Poedit 1.6.9\n"
#: t_options.h:56
msgid "Debugging"
@@ -70,106 +70,110 @@ msgstr ""
"Forzar una versión de GLSL por defecto en los shaders a los cuales les falta "
"una línea #version explícita"
-#: t_options.h:115
+#: t_options.h:110
+msgid "Allow GLSL #extension directives in the middle of shaders"
+msgstr "Permite directivas #extension GLSL en medio de los shaders"
+
+#: t_options.h:120
msgid "Image Quality"
msgstr "Calidad de imagen"
-#: t_options.h:128
+#: t_options.h:133
msgid "Texture color depth"
msgstr "Profundidad de color de textura"
-#: t_options.h:129
+#: t_options.h:134
msgid "Prefer frame buffer color depth"
msgstr "Preferir profundidad de color del framebuffer"
-#: t_options.h:130
+#: t_options.h:135
msgid "Prefer 32 bits per texel"
msgstr "Preferir 32 bits por texel"
-#: t_options.h:131
+#: t_options.h:136
msgid "Prefer 16 bits per texel"
msgstr "Preferir 16 bits por texel"
-#: t_options.h:132
+#: t_options.h:137
msgid "Force 16 bits per texel"
msgstr "Forzar a 16 bits por texel"
-#: t_options.h:138
+#: t_options.h:143
msgid "Initial maximum value for anisotropic texture filtering"
msgstr "Valor máximo inicial para filtrado anisotrópico de textura"
-#: t_options.h:143
+#: t_options.h:148
msgid "Forbid negative texture LOD bias"
msgstr "Prohibir valores negativos de Nivel De Detalle (LOD) de texturas"
-#: t_options.h:148
+#: t_options.h:153
msgid ""
"Enable S3TC texture compression even if software support is not available"
msgstr ""
"Habilitar la compresión de texturas S3TC incluso si el soporte por software "
"no está disponible"
-#: t_options.h:155
+#: t_options.h:160
msgid "Initial color reduction method"
msgstr "Método inicial de reducción de color"
-#: t_options.h:156
+#: t_options.h:161
msgid "Round colors"
msgstr "Colores redondeados"
-#: t_options.h:157
+#: t_options.h:162
msgid "Dither colors"
msgstr "Colores suavizados"
-#: t_options.h:165
+#: t_options.h:170
msgid "Color rounding method"
msgstr "Método de redondeo de colores"
-#: t_options.h:166
+#: t_options.h:171
msgid "Round color components downward"
msgstr "Redondear hacia abajo los componentes de color"
-#: t_options.h:167
+#: t_options.h:172
msgid "Round to nearest color"
msgstr "Redondear al color más cercano"
-#: t_options.h:176
+#: t_options.h:181
msgid "Color dithering method"
msgstr "Método de suavizado de color"
-#: t_options.h:177
+#: t_options.h:182
msgid "Horizontal error diffusion"
msgstr "Difusión de error horizontal"
-#: t_options.h:178
+#: t_options.h:183
msgid "Horizontal error diffusion, reset error at line start"
msgstr "Difusión de error horizontal, reiniciar error al comienzo de línea"
-#: t_options.h:179
+#: t_options.h:184
msgid "Ordered 2D color dithering"
msgstr "Suavizado de color 2D ordenado"
-#: t_options.h:185
+#: t_options.h:190
msgid "Floating point depth buffer"
msgstr "Búfer de profundidad en coma flotante"
-#: t_options.h:190
+#: t_options.h:195
msgid "A post-processing filter to cel-shade the output"
msgstr "Un filtro de postprocesamiento para aplicar cel shading a la salida"
-#: t_options.h:195
+#: t_options.h:200
msgid "A post-processing filter to remove the red channel"
msgstr "Un filtro de postprocesamiento para eliminar el canal rojo"
-#: t_options.h:200
+#: t_options.h:205
msgid "A post-processing filter to remove the green channel"
msgstr "Un filtro de postprocesamiento para eliminar el canal verde"
-#: t_options.h:205
+#: t_options.h:210
msgid "A post-processing filter to remove the blue channel"
msgstr "Un filtro de postprocesamiento para eliminar el canal azul"
-#: t_options.h:210
+#: t_options.h:215
msgid ""
"Morphological anti-aliasing based on Jimenez\\' MLAA. 0 to disable, 8 for "
"default quality"
@@ -177,7 +181,7 @@ msgstr ""
"Antialiasing morfológico basado en el MLAA de Jimenez. 0 para deshabilitar, "
"8 para calidad por defecto"
-#: t_options.h:215
+#: t_options.h:220
msgid ""
"Morphological anti-aliasing based on Jimenez\\' MLAA. 0 to disable, 8 for "
"default quality. Color version, usable with 2d GL apps"
@@ -185,71 +189,71 @@ msgstr ""
"Antialiasing morfológico basado en el MLAA de Jimenez. 0 para deshabilitar, "
"8 para calidad por defecto. Versión en color, usable con aplicaciones GL 2D"
-#: t_options.h:225
+#: t_options.h:230
msgid "Performance"
msgstr "Rendimiento"
-#: t_options.h:233
+#: t_options.h:238
msgid "TCL mode (Transformation, Clipping, Lighting)"
msgstr "Modo TCL (Transformación, Recorte, Iluminación)"
-#: t_options.h:234
+#: t_options.h:239
msgid "Use software TCL pipeline"
msgstr "Usar tubería TCL por software"
-#: t_options.h:235
+#: t_options.h:240
msgid "Use hardware TCL as first TCL pipeline stage"
msgstr "Usar TCL por hardware en la primera fase de la tubería TCL"
-#: t_options.h:236
+#: t_options.h:241
msgid "Bypass the TCL pipeline"
msgstr "Pasar por alto la tubería TCL"
-#: t_options.h:237
+#: t_options.h:242
msgid ""
"Bypass the TCL pipeline with state-based machine code generated on-the-fly"
msgstr ""
"Pasar por alto la tubería TCL con código máquina basado en estados, generado "
"al vuelo"
-#: t_options.h:246
+#: t_options.h:251
msgid "Method to limit rendering latency"
msgstr "Método para limitar la latencia de renderización"
-#: t_options.h:247
+#: t_options.h:252
msgid "Busy waiting for the graphics hardware"
msgstr "Esperar activamente al hardware gráfico"
-#: t_options.h:248
+#: t_options.h:253
msgid "Sleep for brief intervals while waiting for the graphics hardware"
msgstr "Dormir en intervalos cortos mientras se espera al hardware gráfico"
-#: t_options.h:249
+#: t_options.h:254
msgid "Let the graphics hardware emit a software interrupt and sleep"
msgstr ""
"Permitir que el hardware gráfico emita una interrupción de software y duerma"
-#: t_options.h:259
+#: t_options.h:264
msgid "Synchronization with vertical refresh (swap intervals)"
msgstr "Sincronización con el refresco vertical (intervalos de intercambio)"
-#: t_options.h:260
+#: t_options.h:265
msgid "Never synchronize with vertical refresh, ignore application's choice"
msgstr ""
"No sincronizar nunca con el refresco vertical, ignorar la elección de la "
"aplicación"
-#: t_options.h:261
+#: t_options.h:266
msgid "Initial swap interval 0, obey application's choice"
msgstr ""
"Intervalo de intercambio inicial 0, obedecer la elección de la aplicación"
-#: t_options.h:262
+#: t_options.h:267
msgid "Initial swap interval 1, obey application's choice"
msgstr ""
"Intervalo de intercambio inicial 1, obedecer la elección de la aplicación"
-#: t_options.h:263
+#: t_options.h:268
msgid ""
"Always synchronize with vertical refresh, application chooses the minimum "
"swap interval"
@@ -257,48 +261,56 @@ msgstr ""
"Sincronizar siempre con el refresco vertical, la aplicación elige el "
"intervalo de intercambio mínimo"
-#: t_options.h:271
+#: t_options.h:276
msgid "Use HyperZ to boost performance"
msgstr "Usar HyperZ para potenciar rendimiento"
-#: t_options.h:276
+#: t_options.h:281
msgid "Number of texture units used"
msgstr "Número de unidades de textura usadas"
-#: t_options.h:281
+#: t_options.h:286
msgid "Texture filtering quality vs. speed, AKA “brilinear” texture filtering"
msgstr ""
"Calidad de filtrado de textura vs. velocidad, alias filtrado \"brilinear\" "
"de textura"
-#: t_options.h:289
+#: t_options.h:294
msgid "Used types of texture memory"
msgstr "Tipos de memoria de textura usados"
-#: t_options.h:290
+#: t_options.h:295
msgid "All available memory"
msgstr "Toda la memoria disponible"
-#: t_options.h:291
+#: t_options.h:296
msgid "Only card memory (if available)"
msgstr "Solo memoria de tarjeta (si está disponible)"
-#: t_options.h:292
+#: t_options.h:297
msgid "Only GART (AGP/PCIE) memory (if available)"
msgstr "Solo memoria GART (AGP/PCIE) (si está disponible)"
-#: t_options.h:304
+#: t_options.h:309
msgid "Features that are not hardware-accelerated"
msgstr "Características no aceleradas por hardware"
-#: t_options.h:308
+#: t_options.h:313
msgid "Enable extension GL_ARB_vertex_program"
msgstr "Habilitar la extensión GL_ARB_vertex_program"
-#: t_options.h:318
+#: t_options.h:323
msgid "Miscellaneous"
msgstr "Misceláneo"
-#: t_options.h:322
+#: t_options.h:327
msgid "Create all visuals with a depth buffer"
msgstr "Crear todos los visuales con buffer de profundidad"
+
+#: t_options.h:337
+msgid "Initialization"
+msgstr "Inicialización"
+
+#: t_options.h:341
+msgid "Define the graphic device to use if possible"
+msgstr "Define el dispositivo de gráficos que usar si es posible"
diff --git a/mesalib/src/mesa/drivers/dri/common/xmlpool/fr.po b/mesalib/src/mesa/drivers/dri/common/xmlpool/fr.po
index 4a747b355..fa069652c 100644
--- a/mesalib/src/mesa/drivers/dri/common/xmlpool/fr.po
+++ b/mesalib/src/mesa/drivers/dri/common/xmlpool/fr.po
@@ -7,7 +7,7 @@ msgid ""
msgstr ""
"Project-Id-Version: Mesa 6.3\n"
"Report-Msgid-Bugs-To: \n"
-"POT-Creation-Date: 2014-01-13 22:30-0700\n"
+"POT-Creation-Date: 2014-09-25 22:29-0600\n"
"PO-Revision-Date: 2005-04-11 01:34+0200\n"
"Last-Translator: Stephane Marchesin <marchesin@icps.u-strasbg.fr>\n"
"Language-Team: French <fr@li.org>\n"
@@ -62,182 +62,186 @@ msgid ""
"Force a default GLSL version for shaders that lack an explicit #version line"
msgstr ""
-#: t_options.h:115
+#: t_options.h:110
+msgid "Allow GLSL #extension directives in the middle of shaders"
+msgstr ""
+
+#: t_options.h:120
msgid "Image Quality"
msgstr "Qualité d'image"
-#: t_options.h:128
+#: t_options.h:133
msgid "Texture color depth"
msgstr "Profondeur de texture"
-#: t_options.h:129
+#: t_options.h:134
msgid "Prefer frame buffer color depth"
msgstr "Profondeur de couleur"
-#: t_options.h:130
+#: t_options.h:135
msgid "Prefer 32 bits per texel"
msgstr "Préférer 32 bits par texel"
-#: t_options.h:131
+#: t_options.h:136
msgid "Prefer 16 bits per texel"
msgstr "Prérérer 16 bits par texel"
-#: t_options.h:132
+#: t_options.h:137
msgid "Force 16 bits per texel"
msgstr "Forcer 16 bits par texel"
-#: t_options.h:138
+#: t_options.h:143
msgid "Initial maximum value for anisotropic texture filtering"
msgstr "Valeur maximale initiale pour le filtrage anisotropique de texture"
-#: t_options.h:143
+#: t_options.h:148
msgid "Forbid negative texture LOD bias"
msgstr "Interdire le LOD bias negatif"
-#: t_options.h:148
+#: t_options.h:153
msgid ""
"Enable S3TC texture compression even if software support is not available"
msgstr ""
"Activer la compression de texture S3TC même si le support logiciel est absent"
-#: t_options.h:155
+#: t_options.h:160
msgid "Initial color reduction method"
msgstr "Technique de réduction de couleurs"
-#: t_options.h:156
+#: t_options.h:161
msgid "Round colors"
msgstr "Arrondir les valeurs de couleur"
-#: t_options.h:157
+#: t_options.h:162
msgid "Dither colors"
msgstr "Tramer les couleurs"
-#: t_options.h:165
+#: t_options.h:170
msgid "Color rounding method"
msgstr "Méthode d'arrondi des couleurs"
-#: t_options.h:166
+#: t_options.h:171
msgid "Round color components downward"
msgstr "Arrondi à l'inférieur"
-#: t_options.h:167
+#: t_options.h:172
msgid "Round to nearest color"
msgstr "Arrondi au plus proche"
-#: t_options.h:176
+#: t_options.h:181
msgid "Color dithering method"
msgstr "Méthode de tramage"
-#: t_options.h:177
+#: t_options.h:182
msgid "Horizontal error diffusion"
msgstr "Diffusion d'erreur horizontale"
-#: t_options.h:178
+#: t_options.h:183
msgid "Horizontal error diffusion, reset error at line start"
msgstr "Diffusion d'erreur horizontale, réinitialisé pour chaque ligne"
-#: t_options.h:179
+#: t_options.h:184
msgid "Ordered 2D color dithering"
msgstr "Tramage ordonné des couleurs"
-#: t_options.h:185
+#: t_options.h:190
msgid "Floating point depth buffer"
msgstr "Z-buffer en virgule flottante"
-#: t_options.h:190
+#: t_options.h:195
msgid "A post-processing filter to cel-shade the output"
msgstr ""
-#: t_options.h:195
+#: t_options.h:200
msgid "A post-processing filter to remove the red channel"
msgstr ""
-#: t_options.h:200
+#: t_options.h:205
msgid "A post-processing filter to remove the green channel"
msgstr ""
-#: t_options.h:205
+#: t_options.h:210
msgid "A post-processing filter to remove the blue channel"
msgstr ""
-#: t_options.h:210
+#: t_options.h:215
msgid ""
"Morphological anti-aliasing based on Jimenez\\' MLAA. 0 to disable, 8 for "
"default quality"
msgstr ""
-#: t_options.h:215
+#: t_options.h:220
msgid ""
"Morphological anti-aliasing based on Jimenez\\' MLAA. 0 to disable, 8 for "
"default quality. Color version, usable with 2d GL apps"
msgstr ""
-#: t_options.h:225
+#: t_options.h:230
msgid "Performance"
msgstr "Performance"
-#: t_options.h:233
+#: t_options.h:238
msgid "TCL mode (Transformation, Clipping, Lighting)"
msgstr "Mode de TCL (Transformation, Clipping, Eclairage)"
-#: t_options.h:234
+#: t_options.h:239
msgid "Use software TCL pipeline"
msgstr "Utiliser un pipeline TCL logiciel"
-#: t_options.h:235
+#: t_options.h:240
msgid "Use hardware TCL as first TCL pipeline stage"
msgstr "Utiliser le TCL matériel pour le premier niveau de pipeline"
-#: t_options.h:236
+#: t_options.h:241
msgid "Bypass the TCL pipeline"
msgstr "Court-circuiter le pipeline TCL"
-#: t_options.h:237
+#: t_options.h:242
msgid ""
"Bypass the TCL pipeline with state-based machine code generated on-the-fly"
msgstr ""
"Court-circuiter le pipeline TCL par une machine à états qui génère le codede "
"TCL à la volée"
-#: t_options.h:246
+#: t_options.h:251
msgid "Method to limit rendering latency"
msgstr "Méthode d'attente de la carte graphique"
-#: t_options.h:247
+#: t_options.h:252
msgid "Busy waiting for the graphics hardware"
msgstr "Attente active de la carte graphique"
-#: t_options.h:248
+#: t_options.h:253
msgid "Sleep for brief intervals while waiting for the graphics hardware"
msgstr "Attente utilisant usleep()"
-#: t_options.h:249
+#: t_options.h:254
msgid "Let the graphics hardware emit a software interrupt and sleep"
msgstr "Utiliser les interruptions"
-#: t_options.h:259
+#: t_options.h:264
msgid "Synchronization with vertical refresh (swap intervals)"
msgstr "Synchronisation de l'affichage avec le balayage vertical"
-#: t_options.h:260
+#: t_options.h:265
msgid "Never synchronize with vertical refresh, ignore application's choice"
msgstr ""
"Ne jamais synchroniser avec le balayage vertical, ignorer le choix de "
"l'application"
-#: t_options.h:261
+#: t_options.h:266
msgid "Initial swap interval 0, obey application's choice"
msgstr ""
"Ne pas synchroniser avec le balayage vertical par défaut, mais obéir au "
"choix de l'application"
-#: t_options.h:262
+#: t_options.h:267
msgid "Initial swap interval 1, obey application's choice"
msgstr ""
"Synchroniser avec le balayage vertical par défaut, mais obéir au choix de "
"l'application"
-#: t_options.h:263
+#: t_options.h:268
msgid ""
"Always synchronize with vertical refresh, application chooses the minimum "
"swap interval"
@@ -245,51 +249,59 @@ msgstr ""
"Toujours synchroniser avec le balayage vertical, l'application choisit "
"l'intervalle minimal"
-#: t_options.h:271
+#: t_options.h:276
msgid "Use HyperZ to boost performance"
msgstr "Utiliser le HyperZ pour améliorer les performances"
-#: t_options.h:276
+#: t_options.h:281
msgid "Number of texture units used"
msgstr "Nombre d'unités de texture"
-#: t_options.h:281
+#: t_options.h:286
msgid "Texture filtering quality vs. speed, AKA “brilinear” texture filtering"
msgstr ""
"Qualité/performance du filtrage trilinéaire de texture (filtrage brilinéaire)"
-#: t_options.h:289
+#: t_options.h:294
msgid "Used types of texture memory"
msgstr "Types de mémoire de texture"
-#: t_options.h:290
+#: t_options.h:295
msgid "All available memory"
msgstr "Utiliser toute la mémoire disponible"
-#: t_options.h:291
+#: t_options.h:296
msgid "Only card memory (if available)"
msgstr "Utiliser uniquement la mémoire graphique (si disponible)"
-#: t_options.h:292
+#: t_options.h:297
msgid "Only GART (AGP/PCIE) memory (if available)"
msgstr "Utiliser uniquement la mémoire GART (AGP/PCIE) (si disponible)"
-#: t_options.h:304
+#: t_options.h:309
msgid "Features that are not hardware-accelerated"
msgstr "Fonctionnalités ne bénéficiant pas d'une accélération matérielle"
-#: t_options.h:308
+#: t_options.h:313
msgid "Enable extension GL_ARB_vertex_program"
msgstr "Activer l'extension GL_ARB_vertex_program"
-#: t_options.h:318
+#: t_options.h:323
msgid "Miscellaneous"
msgstr ""
-#: t_options.h:322
+#: t_options.h:327
msgid "Create all visuals with a depth buffer"
msgstr ""
+#: t_options.h:337
+msgid "Initialization"
+msgstr ""
+
+#: t_options.h:341
+msgid "Define the graphic device to use if possible"
+msgstr ""
+
#~ msgid ""
#~ "Enable hack to allow larger textures with texture compression on radeon/"
#~ "r200"
diff --git a/mesalib/src/mesa/drivers/dri/common/xmlpool/nl.po b/mesalib/src/mesa/drivers/dri/common/xmlpool/nl.po
index 8dc1f5566..86cb6e96d 100644
--- a/mesalib/src/mesa/drivers/dri/common/xmlpool/nl.po
+++ b/mesalib/src/mesa/drivers/dri/common/xmlpool/nl.po
@@ -7,7 +7,7 @@ msgid ""
msgstr ""
"Project-Id-Version: PACKAGE VERSION\n"
"Report-Msgid-Bugs-To: \n"
-"POT-Creation-Date: 2014-01-13 22:30-0700\n"
+"POT-Creation-Date: 2014-09-25 22:29-0600\n"
"PO-Revision-Date: 2005-04-12 20:09+0200\n"
"Last-Translator: Manfred Stienstra <manfred.stienstra@dwerg.net>\n"
"Language-Team: Dutch <vertaling@nl.linux.org>\n"
@@ -62,182 +62,186 @@ msgid ""
"Force a default GLSL version for shaders that lack an explicit #version line"
msgstr ""
-#: t_options.h:115
+#: t_options.h:110
+msgid "Allow GLSL #extension directives in the middle of shaders"
+msgstr ""
+
+#: t_options.h:120
msgid "Image Quality"
msgstr "Beeldkwaliteit"
-#: t_options.h:128
+#: t_options.h:133
msgid "Texture color depth"
msgstr "Textuurkleurendiepte"
-#: t_options.h:129
+#: t_options.h:134
msgid "Prefer frame buffer color depth"
msgstr "Prefereer kaderbufferkleurdiepte"
-#: t_options.h:130
+#: t_options.h:135
msgid "Prefer 32 bits per texel"
msgstr "Prefereer 32 bits per texel"
-#: t_options.h:131
+#: t_options.h:136
msgid "Prefer 16 bits per texel"
msgstr "Prefereer 16 bits per texel"
-#: t_options.h:132
+#: t_options.h:137
msgid "Force 16 bits per texel"
msgstr "Dwing 16 bits per texel af"
-#: t_options.h:138
+#: t_options.h:143
msgid "Initial maximum value for anisotropic texture filtering"
msgstr "Initïele maximum waarde voor anisotrophische textuur filtering"
-#: t_options.h:143
+#: t_options.h:148
msgid "Forbid negative texture LOD bias"
msgstr "Verbied negatief niveau detailonderscheid (LOD) van texturen"
-#: t_options.h:148
+#: t_options.h:153
msgid ""
"Enable S3TC texture compression even if software support is not available"
msgstr ""
"Schakel S3TC textuurcompressie in, zelfs als softwareondersteuning niet "
"aanwezig is"
-#: t_options.h:155
+#: t_options.h:160
msgid "Initial color reduction method"
msgstr "Initïele kleurreductie methode"
-#: t_options.h:156
+#: t_options.h:161
msgid "Round colors"
msgstr "Rond kleuren af"
-#: t_options.h:157
+#: t_options.h:162
msgid "Dither colors"
msgstr "Rasteriseer kleuren"
-#: t_options.h:165
+#: t_options.h:170
msgid "Color rounding method"
msgstr "Kleurafrondingmethode"
-#: t_options.h:166
+#: t_options.h:171
msgid "Round color components downward"
msgstr "Rond kleurencomponenten af naar beneden"
-#: t_options.h:167
+#: t_options.h:172
msgid "Round to nearest color"
msgstr "Rond af naar dichtsbijzijnde kleur"
-#: t_options.h:176
+#: t_options.h:181
msgid "Color dithering method"
msgstr "Kleurrasteriseringsmethode"
-#: t_options.h:177
+#: t_options.h:182
msgid "Horizontal error diffusion"
msgstr "Horizontale foutdiffusie"
-#: t_options.h:178
+#: t_options.h:183
msgid "Horizontal error diffusion, reset error at line start"
msgstr "Horizontale foutdiffusie, zet fout bij lijnbegin terug"
-#: t_options.h:179
+#: t_options.h:184
msgid "Ordered 2D color dithering"
msgstr "Geordende 2D kleurrasterisering"
-#: t_options.h:185
+#: t_options.h:190
msgid "Floating point depth buffer"
msgstr "Dieptebuffer als commagetal"
-#: t_options.h:190
+#: t_options.h:195
msgid "A post-processing filter to cel-shade the output"
msgstr ""
-#: t_options.h:195
+#: t_options.h:200
msgid "A post-processing filter to remove the red channel"
msgstr ""
-#: t_options.h:200
+#: t_options.h:205
msgid "A post-processing filter to remove the green channel"
msgstr ""
-#: t_options.h:205
+#: t_options.h:210
msgid "A post-processing filter to remove the blue channel"
msgstr ""
-#: t_options.h:210
+#: t_options.h:215
msgid ""
"Morphological anti-aliasing based on Jimenez\\' MLAA. 0 to disable, 8 for "
"default quality"
msgstr ""
-#: t_options.h:215
+#: t_options.h:220
msgid ""
"Morphological anti-aliasing based on Jimenez\\' MLAA. 0 to disable, 8 for "
"default quality. Color version, usable with 2d GL apps"
msgstr ""
-#: t_options.h:225
+#: t_options.h:230
msgid "Performance"
msgstr "Prestatie"
-#: t_options.h:233
+#: t_options.h:238
msgid "TCL mode (Transformation, Clipping, Lighting)"
msgstr "TCL-modus (Transformatie, Clipping, Licht)"
-#: t_options.h:234
+#: t_options.h:239
msgid "Use software TCL pipeline"
msgstr "Gebruik software TCL pijpleiding"
-#: t_options.h:235
+#: t_options.h:240
msgid "Use hardware TCL as first TCL pipeline stage"
msgstr "Gebruik hardware TCL as eerste TCL pijpleiding trap"
-#: t_options.h:236
+#: t_options.h:241
msgid "Bypass the TCL pipeline"
msgstr "Omzeil de TCL pijpleiding"
-#: t_options.h:237
+#: t_options.h:242
msgid ""
"Bypass the TCL pipeline with state-based machine code generated on-the-fly"
msgstr ""
"Omzeil de TCL pijpleiding met staatgebaseerde machinecode die tijdens "
"executie gegenereerd wordt"
-#: t_options.h:246
+#: t_options.h:251
msgid "Method to limit rendering latency"
msgstr "Methode om beeldopbouwvertraging te onderdrukken"
-#: t_options.h:247
+#: t_options.h:252
msgid "Busy waiting for the graphics hardware"
msgstr "Actief wachten voor de grafische hardware"
-#: t_options.h:248
+#: t_options.h:253
msgid "Sleep for brief intervals while waiting for the graphics hardware"
msgstr ""
"Slaap voor korte intervallen tijdens het wachten op de grafische hardware"
-#: t_options.h:249
+#: t_options.h:254
msgid "Let the graphics hardware emit a software interrupt and sleep"
msgstr ""
"Laat de grafische hardware een software onderbreking uitzenden en in slaap "
"vallen"
-#: t_options.h:259
+#: t_options.h:264
msgid "Synchronization with vertical refresh (swap intervals)"
msgstr "Synchronisatie met verticale verversing (interval omwisselen)"
-#: t_options.h:260
+#: t_options.h:265
msgid "Never synchronize with vertical refresh, ignore application's choice"
msgstr ""
"Nooit synchroniseren met verticale verversing, negeer de keuze van de "
"applicatie"
-#: t_options.h:261
+#: t_options.h:266
msgid "Initial swap interval 0, obey application's choice"
msgstr "Initïeel omwisselingsinterval 0, honoreer de keuze van de applicatie"
-#: t_options.h:262
+#: t_options.h:267
msgid "Initial swap interval 1, obey application's choice"
msgstr "Initïeel omwisselingsinterval 1, honoreer de keuze van de applicatie"
-#: t_options.h:263
+#: t_options.h:268
msgid ""
"Always synchronize with vertical refresh, application chooses the minimum "
"swap interval"
@@ -245,52 +249,60 @@ msgstr ""
"Synchroniseer altijd met verticale verversing, de applicatie kiest het "
"minimum omwisselingsinterval"
-#: t_options.h:271
+#: t_options.h:276
msgid "Use HyperZ to boost performance"
msgstr "Gebruik HyperZ om de prestaties te verbeteren"
-#: t_options.h:276
+#: t_options.h:281
msgid "Number of texture units used"
msgstr "Aantal textuureenheden in gebruik"
-#: t_options.h:281
+#: t_options.h:286
msgid "Texture filtering quality vs. speed, AKA “brilinear” texture filtering"
msgstr ""
"Textuurfilterkwaliteit versus -snelheid, ookwel bekend als “brilineaire” "
"textuurfiltering"
-#: t_options.h:289
+#: t_options.h:294
msgid "Used types of texture memory"
msgstr "Gebruikte soorten textuurgeheugen"
-#: t_options.h:290
+#: t_options.h:295
msgid "All available memory"
msgstr "Al het beschikbaar geheugen"
-#: t_options.h:291
+#: t_options.h:296
msgid "Only card memory (if available)"
msgstr "Alleen geheugen op de kaart (als het aanwezig is)"
-#: t_options.h:292
+#: t_options.h:297
msgid "Only GART (AGP/PCIE) memory (if available)"
msgstr "Alleen GART (AGP/PCIE) geheugen (als het aanwezig is)"
-#: t_options.h:304
+#: t_options.h:309
msgid "Features that are not hardware-accelerated"
msgstr "Eigenschappen die niet hardwareversneld zijn"
-#: t_options.h:308
+#: t_options.h:313
msgid "Enable extension GL_ARB_vertex_program"
msgstr "Zet uitbreiding GL_ARB_vertex_program aan"
-#: t_options.h:318
+#: t_options.h:323
msgid "Miscellaneous"
msgstr ""
-#: t_options.h:322
+#: t_options.h:327
msgid "Create all visuals with a depth buffer"
msgstr ""
+#: t_options.h:337
+msgid "Initialization"
+msgstr ""
+
+#: t_options.h:341
+msgid "Define the graphic device to use if possible"
+msgstr ""
+
#~ msgid ""
#~ "Enable hack to allow larger textures with texture compression on radeon/"
#~ "r200"
diff --git a/mesalib/src/mesa/drivers/dri/common/xmlpool/sv.po b/mesalib/src/mesa/drivers/dri/common/xmlpool/sv.po
index 082a22a94..d8d7353f4 100644
--- a/mesalib/src/mesa/drivers/dri/common/xmlpool/sv.po
+++ b/mesalib/src/mesa/drivers/dri/common/xmlpool/sv.po
@@ -7,7 +7,7 @@ msgid ""
msgstr ""
"Project-Id-Version: Mesa DRI\n"
"Report-Msgid-Bugs-To: \n"
-"POT-Creation-Date: 2014-01-13 22:30-0700\n"
+"POT-Creation-Date: 2014-09-25 22:29-0600\n"
"PO-Revision-Date: 2006-09-18 10:56+0100\n"
"Last-Translator: Daniel Nylander <po@danielnylander.se>\n"
"Language-Team: Swedish <tp-sv@listor.tp-sv.se>\n"
@@ -62,174 +62,178 @@ msgid ""
"Force a default GLSL version for shaders that lack an explicit #version line"
msgstr ""
-#: t_options.h:115
+#: t_options.h:110
+msgid "Allow GLSL #extension directives in the middle of shaders"
+msgstr ""
+
+#: t_options.h:120
msgid "Image Quality"
msgstr "Bildkvalitet"
-#: t_options.h:128
+#: t_options.h:133
msgid "Texture color depth"
msgstr "Färgdjup för texturer"
-#: t_options.h:129
+#: t_options.h:134
msgid "Prefer frame buffer color depth"
msgstr "Föredra färgdjupet för framebuffer"
-#: t_options.h:130
+#: t_options.h:135
msgid "Prefer 32 bits per texel"
msgstr "Föredra 32 bitar per texel"
-#: t_options.h:131
+#: t_options.h:136
msgid "Prefer 16 bits per texel"
msgstr "Föredra 16 bitar per texel"
-#: t_options.h:132
+#: t_options.h:137
msgid "Force 16 bits per texel"
msgstr "Tvinga 16 bitar per texel"
-#: t_options.h:138
+#: t_options.h:143
msgid "Initial maximum value for anisotropic texture filtering"
msgstr "Initialt maximalt värde för anisotropisk texturfiltrering"
-#: t_options.h:143
+#: t_options.h:148
msgid "Forbid negative texture LOD bias"
msgstr "Förbjud negativ LOD-kompensation för texturer"
-#: t_options.h:148
+#: t_options.h:153
msgid ""
"Enable S3TC texture compression even if software support is not available"
msgstr "Aktivera S3TC-texturkomprimering även om programvarustöd saknas"
-#: t_options.h:155
+#: t_options.h:160
msgid "Initial color reduction method"
msgstr "Initial färgminskningsmetod"
-#: t_options.h:156
+#: t_options.h:161
msgid "Round colors"
msgstr "Avrunda färger"
-#: t_options.h:157
+#: t_options.h:162
msgid "Dither colors"
msgstr "Utjämna färger"
-#: t_options.h:165
+#: t_options.h:170
msgid "Color rounding method"
msgstr "Färgavrundningsmetod"
-#: t_options.h:166
+#: t_options.h:171
msgid "Round color components downward"
msgstr "Avrunda färdkomponenter nedåt"
-#: t_options.h:167
+#: t_options.h:172
msgid "Round to nearest color"
msgstr "Avrunda till närmsta färg"
-#: t_options.h:176
+#: t_options.h:181
msgid "Color dithering method"
msgstr "Färgutjämningsmetod"
-#: t_options.h:177
+#: t_options.h:182
msgid "Horizontal error diffusion"
msgstr "Horisontell felspridning"
-#: t_options.h:178
+#: t_options.h:183
msgid "Horizontal error diffusion, reset error at line start"
msgstr "Horisontell felspridning, återställ fel vid radbörjan"
-#: t_options.h:179
+#: t_options.h:184
msgid "Ordered 2D color dithering"
msgstr "Ordnad 2D-färgutjämning"
-#: t_options.h:185
+#: t_options.h:190
msgid "Floating point depth buffer"
msgstr "Buffert för flytande punktdjup"
-#: t_options.h:190
+#: t_options.h:195
msgid "A post-processing filter to cel-shade the output"
msgstr ""
-#: t_options.h:195
+#: t_options.h:200
msgid "A post-processing filter to remove the red channel"
msgstr ""
-#: t_options.h:200
+#: t_options.h:205
msgid "A post-processing filter to remove the green channel"
msgstr ""
-#: t_options.h:205
+#: t_options.h:210
msgid "A post-processing filter to remove the blue channel"
msgstr ""
-#: t_options.h:210
+#: t_options.h:215
msgid ""
"Morphological anti-aliasing based on Jimenez\\' MLAA. 0 to disable, 8 for "
"default quality"
msgstr ""
-#: t_options.h:215
+#: t_options.h:220
msgid ""
"Morphological anti-aliasing based on Jimenez\\' MLAA. 0 to disable, 8 for "
"default quality. Color version, usable with 2d GL apps"
msgstr ""
-#: t_options.h:225
+#: t_options.h:230
msgid "Performance"
msgstr "Prestanda"
-#: t_options.h:233
+#: t_options.h:238
msgid "TCL mode (Transformation, Clipping, Lighting)"
msgstr "TCL-läge (Transformation, Clipping, Lighting)"
-#: t_options.h:234
+#: t_options.h:239
msgid "Use software TCL pipeline"
msgstr "Använd programvaru-TCL-rörledning"
-#: t_options.h:235
+#: t_options.h:240
msgid "Use hardware TCL as first TCL pipeline stage"
msgstr "Använd maskinvaru-TCL som första TCL-rörledningssteg"
-#: t_options.h:236
+#: t_options.h:241
msgid "Bypass the TCL pipeline"
msgstr "Kringgå TCL-rörledningen"
-#: t_options.h:237
+#: t_options.h:242
msgid ""
"Bypass the TCL pipeline with state-based machine code generated on-the-fly"
msgstr ""
"Kringgå TCL-rörledningen med tillståndsbaserad maskinkod som direktgenereras"
-#: t_options.h:246
+#: t_options.h:251
msgid "Method to limit rendering latency"
msgstr "Metod för att begränsa renderingslatens"
-#: t_options.h:247
+#: t_options.h:252
msgid "Busy waiting for the graphics hardware"
msgstr "Upptagen med att vänta på grafikhårdvaran"
-#: t_options.h:248
+#: t_options.h:253
msgid "Sleep for brief intervals while waiting for the graphics hardware"
msgstr "Sov i korta intervall under väntan på grafikhårdvaran"
-#: t_options.h:249
+#: t_options.h:254
msgid "Let the graphics hardware emit a software interrupt and sleep"
msgstr "Låt grafikhårdvaran sända ut ett programvaruavbrott och sov"
-#: t_options.h:259
+#: t_options.h:264
msgid "Synchronization with vertical refresh (swap intervals)"
msgstr "Synkronisering med vertikal uppdatering (växlingsintervall)"
-#: t_options.h:260
+#: t_options.h:265
msgid "Never synchronize with vertical refresh, ignore application's choice"
msgstr "Synkronisera aldrig med vertikal uppdatering, ignorera programmets val"
-#: t_options.h:261
+#: t_options.h:266
msgid "Initial swap interval 0, obey application's choice"
msgstr "Initialt växlingsintervall 0, följ programmets val"
-#: t_options.h:262
+#: t_options.h:267
msgid "Initial swap interval 1, obey application's choice"
msgstr "Initialt växlingsintervall 1, följ programmets val"
-#: t_options.h:263
+#: t_options.h:268
msgid ""
"Always synchronize with vertical refresh, application chooses the minimum "
"swap interval"
@@ -237,52 +241,60 @@ msgstr ""
"Synkronisera alltid med vertikal uppdatering, programmet väljer den minsta "
"växlingsintervallen"
-#: t_options.h:271
+#: t_options.h:276
msgid "Use HyperZ to boost performance"
msgstr "Använd HyperZ för att maximera prestandan"
-#: t_options.h:276
+#: t_options.h:281
msgid "Number of texture units used"
msgstr "Antal använda texturenheter"
-#: t_options.h:281
+#: t_options.h:286
msgid "Texture filtering quality vs. speed, AKA “brilinear” texture filtering"
msgstr ""
"Texturfiltreringskvalitet mot hastighet, även kallad \"brilinear\"-"
"texturfiltrering"
-#: t_options.h:289
+#: t_options.h:294
msgid "Used types of texture memory"
msgstr "Använda typer av texturminne"
-#: t_options.h:290
+#: t_options.h:295
msgid "All available memory"
msgstr "Allt tillgängligt minne"
-#: t_options.h:291
+#: t_options.h:296
msgid "Only card memory (if available)"
msgstr "Endast kortminne (om tillgängligt)"
-#: t_options.h:292
+#: t_options.h:297
msgid "Only GART (AGP/PCIE) memory (if available)"
msgstr "Endast GART-minne (AGP/PCIE) (om tillgängligt)"
-#: t_options.h:304
+#: t_options.h:309
msgid "Features that are not hardware-accelerated"
msgstr "Funktioner som inte är hårdvaruaccelererade"
-#: t_options.h:308
+#: t_options.h:313
msgid "Enable extension GL_ARB_vertex_program"
msgstr "Aktivera tillägget GL_ARB_vertex_program"
-#: t_options.h:318
+#: t_options.h:323
msgid "Miscellaneous"
msgstr ""
-#: t_options.h:322
+#: t_options.h:327
msgid "Create all visuals with a depth buffer"
msgstr ""
+#: t_options.h:337
+msgid "Initialization"
+msgstr ""
+
+#: t_options.h:341
+msgid "Define the graphic device to use if possible"
+msgstr ""
+
#~ msgid "Support larger textures not guaranteed to fit into graphics memory"
#~ msgstr ""
#~ "Stöd för större texturer är inte garanterat att passa i grafikminnet"
diff --git a/mesalib/src/mesa/main/arrayobj.c b/mesalib/src/mesa/main/arrayobj.c
index 0d77b112b..6440ea670 100644
--- a/mesalib/src/mesa/main/arrayobj.c
+++ b/mesalib/src/mesa/main/arrayobj.c
@@ -230,7 +230,7 @@ _mesa_initialize_vao(struct gl_context *ctx,
obj->RefCount = 1;
/* Init the individual arrays */
- for (i = 0; i < Elements(obj->_VertexAttrib); i++) {
+ for (i = 0; i < Elements(obj->VertexAttrib); i++) {
switch (i) {
case VERT_ATTRIB_WEIGHT:
init_array(ctx, obj, VERT_ATTRIB_WEIGHT, 1, GL_FLOAT);
diff --git a/mesalib/src/mesa/main/arrayobj.h b/mesalib/src/mesa/main/arrayobj.h
index 1819cd12a..3c1f91835 100644
--- a/mesalib/src/mesa/main/arrayobj.h
+++ b/mesalib/src/mesa/main/arrayobj.h
@@ -78,32 +78,6 @@ extern void
_mesa_update_vao_client_arrays(struct gl_context *ctx,
struct gl_vertex_array_object *vao);
-
-/** Returns the bitmask of all enabled arrays in fixed function mode.
- *
- * In fixed function mode only the traditional fixed function arrays
- * are available.
- */
-static inline GLbitfield64
-_mesa_array_object_get_enabled_ff(const struct gl_vertex_array_object *vao)
-{
- return vao->_Enabled & VERT_BIT_FF_ALL;
-}
-
-/** Returns the bitmask of all enabled arrays in arb/glsl shader mode.
- *
- * In arb/glsl shader mode all the fixed function and the arb/glsl generic
- * arrays are available. Only the first generic array takes
- * precedence over the legacy position array.
- */
-static inline GLbitfield64
-_mesa_array_object_get_enabled_arb(const struct gl_vertex_array_object *vao)
-{
- GLbitfield64 enabled = vao->_Enabled;
- return enabled & ~(VERT_BIT_POS & (enabled >> VERT_ATTRIB_GENERIC0));
-}
-
-
/*
* API functions
*/
diff --git a/mesalib/src/mesa/main/attrib.c b/mesalib/src/mesa/main/attrib.c
index ef98ba7fd..d90e6627f 100644
--- a/mesalib/src/mesa/main/attrib.c
+++ b/mesalib/src/mesa/main/attrib.c
@@ -1449,7 +1449,7 @@ copy_array_object(struct gl_context *ctx,
/* In theory must be the same anyway, but on recreate make sure it matches */
dest->ARBsemantics = src->ARBsemantics;
- for (i = 0; i < Elements(src->_VertexAttrib); i++) {
+ for (i = 0; i < Elements(src->VertexAttrib); i++) {
_mesa_copy_client_array(ctx, &dest->_VertexAttrib[i], &src->_VertexAttrib[i]);
_mesa_copy_vertex_attrib_array(ctx, &dest->VertexAttrib[i], &src->VertexAttrib[i]);
_mesa_copy_vertex_buffer_binding(ctx, &dest->VertexBinding[i], &src->VertexBinding[i]);
diff --git a/mesalib/src/mesa/main/compiler.h b/mesalib/src/mesa/main/compiler.h
index 813bf1905..34671dc7e 100644
--- a/mesalib/src/mesa/main/compiler.h
+++ b/mesalib/src/mesa/main/compiler.h
@@ -150,7 +150,7 @@ extern "C" {
#elif defined(__APPLE__)
#include <CoreFoundation/CFByteOrder.h>
#define CPU_TO_LE32( x ) CFSwapInt32HostToLittle( x )
-#elif (defined(_AIX) || defined(__blrts))
+#elif (defined(_AIX))
static inline GLuint CPU_TO_LE32(GLuint x)
{
return (((x & 0x000000ff) << 24) |
@@ -214,13 +214,11 @@ static inline GLuint CPU_TO_LE32(GLuint x)
/**
* ASSERT macro
*/
-#if !defined(_WIN32_WCE)
#if defined(DEBUG)
# define ASSERT(X) assert(X)
#else
# define ASSERT(X)
#endif
-#endif
/*
diff --git a/mesalib/src/mesa/main/context.c b/mesalib/src/mesa/main/context.c
index 682b9c797..0edd66d6f 100644
--- a/mesalib/src/mesa/main/context.c
+++ b/mesalib/src/mesa/main/context.c
@@ -642,16 +642,14 @@ _mesa_init_constants(struct gl_constants *consts, gl_api api)
consts->MaxGeometryTotalOutputComponents = MAX_GEOMETRY_TOTAL_OUTPUT_COMPONENTS;
/* Shading language version */
- if (api == API_OPENGL_COMPAT || api == API_OPENGL_CORE) {
- consts->GLSLVersion = 120;
- _mesa_override_glsl_version(consts);
- }
- else if (api == API_OPENGLES2) {
- consts->GLSLVersion = 100;
- }
- else if (api == API_OPENGLES) {
- consts->GLSLVersion = 0; /* GLSL not supported */
- }
+ consts->GLSLVersion = 120;
+ _mesa_override_glsl_version(consts);
+
+#ifdef DEBUG
+ consts->GenerateTemporaryNames = true;
+#else
+ consts->GenerateTemporaryNames = false;
+#endif
/* GL_ARB_framebuffer_object */
consts->MaxSamples = 0;
@@ -690,9 +688,6 @@ _mesa_init_constants(struct gl_constants *consts, gl_api api)
/* GL_ARB_robustness */
consts->ResetStrategy = GL_NO_RESET_NOTIFICATION_ARB;
- /* PrimitiveRestart */
- consts->PrimitiveRestartInSoftware = GL_FALSE;
-
/* ES 3.0 or ARB_ES3_compatibility */
consts->MaxElementIndex = 0xffffffffu;
@@ -1098,10 +1093,10 @@ _mesa_initialize_context(struct gl_context *ctx,
ctx->CurrentDispatch = ctx->OutsideBeginEnd;
ctx->FragmentProgram._MaintainTexEnvProgram
- = (_mesa_getenv("MESA_TEX_PROG") != NULL);
+ = (getenv("MESA_TEX_PROG") != NULL);
ctx->VertexProgram._MaintainTnlProgram
- = (_mesa_getenv("MESA_TNL_PROG") != NULL);
+ = (getenv("MESA_TNL_PROG") != NULL);
if (ctx->VertexProgram._MaintainTnlProgram) {
/* this is required... */
ctx->FragmentProgram._MaintainTexEnvProgram = GL_TRUE;
@@ -1545,7 +1540,7 @@ handle_first_current(struct gl_context *ctx)
* first time each context is made current we'll print some useful
* information.
*/
- if (_mesa_getenv("MESA_INFO")) {
+ if (getenv("MESA_INFO")) {
_mesa_print_info(ctx);
}
}
diff --git a/mesalib/src/mesa/main/debug.c b/mesalib/src/mesa/main/debug.c
index a5b40b4b5..089ce8987 100644
--- a/mesalib/src/mesa/main/debug.c
+++ b/mesalib/src/mesa/main/debug.c
@@ -215,8 +215,8 @@ set_debug_flags(const char *str)
void
_mesa_init_debug( struct gl_context *ctx )
{
- set_debug_flags(_mesa_getenv("MESA_DEBUG"));
- set_verbose_flags(_mesa_getenv("MESA_VERBOSE"));
+ set_debug_flags(getenv("MESA_DEBUG"));
+ set_verbose_flags(getenv("MESA_VERBOSE"));
}
diff --git a/mesalib/src/mesa/main/dlopen.h b/mesalib/src/mesa/main/dlopen.h
index 55a56f0d7..1e7784914 100644
--- a/mesalib/src/mesa/main/dlopen.h
+++ b/mesalib/src/mesa/main/dlopen.h
@@ -47,9 +47,7 @@ typedef void (*GenericFunc)(void);
static inline void *
_mesa_dlopen(const char *libname, int flags)
{
-#if defined(__blrts)
- return NULL;
-#elif defined(HAVE_DLOPEN)
+#if defined(HAVE_DLOPEN)
flags = RTLD_LAZY | RTLD_GLOBAL; /* Overriding flags at this time */
return dlopen(libname, flags);
#elif defined(__MINGW32__)
@@ -71,16 +69,7 @@ _mesa_dlsym(void *handle, const char *fname)
void *v;
GenericFunc f;
} u;
-#if defined(__blrts)
- u.v = NULL;
-#elif defined(__DJGPP__)
- /* need '_' prefix on symbol names */
- char fname2[1000];
- fname2[0] = '_';
- strncpy(fname2 + 1, fname, 998);
- fname2[999] = 0;
- u.v = dlsym(handle, fname2);
-#elif defined(HAVE_DLOPEN)
+#if defined(HAVE_DLOPEN)
u.v = dlsym(handle, fname);
#elif defined(__MINGW32__)
u.v = (void *) GetProcAddress(handle, fname);
@@ -96,9 +85,7 @@ _mesa_dlsym(void *handle, const char *fname)
static inline void
_mesa_dlclose(void *handle)
{
-#if defined(__blrts)
- (void) handle;
-#elif defined(HAVE_DLOPEN)
+#if defined(HAVE_DLOPEN)
dlclose(handle);
#elif defined(__MINGW32__)
FreeLibrary(handle);
diff --git a/mesalib/src/mesa/main/errors.c b/mesalib/src/mesa/main/errors.c
index 9cde1e020..25171f0ee 100644
--- a/mesalib/src/mesa/main/errors.c
+++ b/mesalib/src/mesa/main/errors.c
@@ -1170,7 +1170,7 @@ output_if_debug(const char *prefixString, const char *outputString,
/* If MESA_LOG_FILE env var is set, log Mesa errors, warnings,
* etc to the named file. Otherwise, output to stderr.
*/
- const char *logFile = _mesa_getenv("MESA_LOG_FILE");
+ const char *logFile = getenv("MESA_LOG_FILE");
if (logFile)
fout = fopen(logFile, "w");
if (!fout)
@@ -1183,7 +1183,7 @@ output_if_debug(const char *prefixString, const char *outputString,
debug = 1;
#else
/* in release builds, be silent unless MESA_DEBUG is set */
- debug = _mesa_getenv("MESA_DEBUG") != NULL;
+ debug = getenv("MESA_DEBUG") != NULL;
#endif
}
@@ -1194,7 +1194,7 @@ output_if_debug(const char *prefixString, const char *outputString,
fprintf(fout, "\n");
fflush(fout);
-#if defined(_WIN32) && !defined(_WIN32_WCE)
+#if defined(_WIN32)
/* stderr from windows applications without console is not usually
* visible, so communicate with the debugger instead */
{
@@ -1288,7 +1288,7 @@ should_output(struct gl_context *ctx, GLenum error, const char *fmtString)
/* Check debug environment variable only once:
*/
if (debug == -1) {
- const char *debugEnv = _mesa_getenv("MESA_DEBUG");
+ const char *debugEnv = getenv("MESA_DEBUG");
#ifdef DEBUG
if (debugEnv && strstr(debugEnv, "silent"))
diff --git a/mesalib/src/mesa/main/extensions.c b/mesalib/src/mesa/main/extensions.c
index 553c01e34..f0e2f89e4 100644
--- a/mesalib/src/mesa/main/extensions.c
+++ b/mesalib/src/mesa/main/extensions.c
@@ -588,7 +588,7 @@ free_unknown_extensions_strings(void)
void
_mesa_one_time_init_extension_overrides(void)
{
- const char *env_const = _mesa_getenv("MESA_EXTENSION_OVERRIDE");
+ const char *env_const = getenv("MESA_EXTENSION_OVERRIDE");
char *env;
char *ext;
int len;
@@ -609,6 +609,15 @@ _mesa_one_time_init_extension_overrides(void)
/* Copy env_const because strtok() is destructive. */
env = strdup(env_const);
+
+ if (env == NULL || extra_extensions == NULL ||
+ cant_disable_extensions == NULL) {
+ free(env);
+ free(extra_extensions);
+ free(cant_disable_extensions);
+ return;
+ }
+
for (ext = strtok(env, " "); ext != NULL; ext = strtok(NULL, " ")) {
int enable;
bool recognized;
diff --git a/mesalib/src/mesa/main/fbobject.c b/mesalib/src/mesa/main/fbobject.c
index ae3a418cd..8283373a4 100644
--- a/mesalib/src/mesa/main/fbobject.c
+++ b/mesalib/src/mesa/main/fbobject.c
@@ -2303,8 +2303,8 @@ reuse_framebuffer_texture_attachment(struct gl_framebuffer *fb,
/**
- * Common code called by glFramebufferTexture1D/2D/3DEXT() and
- * glFramebufferTextureLayerEXT().
+ * Common code called by glFramebufferTexture1D/2D/3D() and
+ * glFramebufferTextureLayer().
*
* \param textarget is the textarget that was passed to the
* glFramebufferTexture...() function, or 0 if the corresponding function
@@ -2326,14 +2326,14 @@ framebuffer_texture(struct gl_context *ctx, const char *caller, GLenum target,
fb = get_framebuffer_target(ctx, target);
if (!fb) {
_mesa_error(ctx, GL_INVALID_ENUM,
- "glFramebufferTexture%sEXT(target=0x%x)", caller, target);
+ "glFramebufferTexture%s(target=0x%x)", caller, target);
return;
}
/* check framebuffer binding */
if (_mesa_is_winsys_fbo(fb)) {
_mesa_error(ctx, GL_INVALID_OPERATION,
- "glFramebufferTexture%sEXT", caller);
+ "glFramebufferTexture%s", caller);
return;
}
@@ -2397,14 +2397,14 @@ framebuffer_texture(struct gl_context *ctx, const char *caller, GLenum target,
else {
/* can't render to a non-existant texture */
_mesa_error(ctx, GL_INVALID_OPERATION,
- "glFramebufferTexture%sEXT(non existant texture)",
+ "glFramebufferTexture%s(non existant texture)",
caller);
return;
}
if (err) {
_mesa_error(ctx, GL_INVALID_OPERATION,
- "glFramebufferTexture%sEXT(texture target mismatch)",
+ "glFramebufferTexture%s(texture target mismatch)",
caller);
return;
}
@@ -2413,7 +2413,7 @@ framebuffer_texture(struct gl_context *ctx, const char *caller, GLenum target,
const GLint maxSize = 1 << (ctx->Const.Max3DTextureLevels - 1);
if (zoffset < 0 || zoffset >= maxSize) {
_mesa_error(ctx, GL_INVALID_VALUE,
- "glFramebufferTexture%sEXT(zoffset)", caller);
+ "glFramebufferTexture%s(zoffset)", caller);
return;
}
}
@@ -2424,7 +2424,7 @@ framebuffer_texture(struct gl_context *ctx, const char *caller, GLenum target,
if (zoffset < 0 ||
zoffset >= (GLint) ctx->Const.MaxArrayTextureLayers) {
_mesa_error(ctx, GL_INVALID_VALUE,
- "glFramebufferTexture%sEXT(layer)", caller);
+ "glFramebufferTexture%s(layer)", caller);
return;
}
}
@@ -2433,7 +2433,7 @@ framebuffer_texture(struct gl_context *ctx, const char *caller, GLenum target,
if ((level < 0) ||
(level >= _mesa_max_texture_levels(ctx, maxLevelsTarget))) {
_mesa_error(ctx, GL_INVALID_VALUE,
- "glFramebufferTexture%sEXT(level)", caller);
+ "glFramebufferTexture%s(level)", caller);
return;
}
}
@@ -2441,7 +2441,7 @@ framebuffer_texture(struct gl_context *ctx, const char *caller, GLenum target,
att = get_attachment(ctx, fb, attachment);
if (att == NULL) {
_mesa_error(ctx, GL_INVALID_ENUM,
- "glFramebufferTexture%sEXT(attachment)", caller);
+ "glFramebufferTexture%s(attachment)", caller);
return;
}
@@ -2531,7 +2531,7 @@ _mesa_FramebufferTexture1D(GLenum target, GLenum attachment,
if (error) {
_mesa_error(ctx, GL_INVALID_OPERATION,
- "glFramebufferTexture1DEXT(textarget=%s)",
+ "glFramebufferTexture1D(textarget=%s)",
_mesa_lookup_enum_by_nr(textarget));
return;
}
@@ -2582,7 +2582,7 @@ _mesa_FramebufferTexture2D(GLenum target, GLenum attachment,
if (error) {
_mesa_error(ctx, GL_INVALID_OPERATION,
- "glFramebufferTexture2DEXT(textarget=%s)",
+ "glFramebufferTexture2D(textarget=%s)",
_mesa_lookup_enum_by_nr(textarget));
return;
}
@@ -2602,7 +2602,7 @@ _mesa_FramebufferTexture3D(GLenum target, GLenum attachment,
if ((texture != 0) && (textarget != GL_TEXTURE_3D)) {
_mesa_error(ctx, GL_INVALID_OPERATION,
- "glFramebufferTexture3DEXT(textarget)");
+ "glFramebufferTexture3D(textarget)");
return;
}
@@ -2629,7 +2629,7 @@ _mesa_FramebufferTexture(GLenum target, GLenum attachment,
GET_CURRENT_CONTEXT(ctx);
if (_mesa_has_geometry_shaders(ctx)) {
- framebuffer_texture(ctx, "Layer", target, attachment, 0, texture,
+ framebuffer_texture(ctx, "", target, attachment, 0, texture,
level, 0, GL_TRUE);
} else {
_mesa_error(ctx, GL_INVALID_OPERATION,
@@ -2651,26 +2651,26 @@ _mesa_FramebufferRenderbuffer(GLenum target, GLenum attachment,
fb = get_framebuffer_target(ctx, target);
if (!fb) {
_mesa_error(ctx, GL_INVALID_ENUM,
- "glFramebufferRenderbufferEXT(target)");
+ "glFramebufferRenderbuffer(target)");
return;
}
if (renderbufferTarget != GL_RENDERBUFFER_EXT) {
_mesa_error(ctx, GL_INVALID_ENUM,
- "glFramebufferRenderbufferEXT(renderbufferTarget)");
+ "glFramebufferRenderbuffer(renderbufferTarget)");
return;
}
if (_mesa_is_winsys_fbo(fb)) {
/* Can't attach new renderbuffers to a window system framebuffer */
- _mesa_error(ctx, GL_INVALID_OPERATION, "glFramebufferRenderbufferEXT");
+ _mesa_error(ctx, GL_INVALID_OPERATION, "glFramebufferRenderbuffer");
return;
}
att = get_attachment(ctx, fb, attachment);
if (att == NULL) {
_mesa_error(ctx, GL_INVALID_ENUM,
- "glFramebufferRenderbufferEXT(invalid attachment %s)",
+ "glFramebufferRenderbuffer(invalid attachment %s)",
_mesa_lookup_enum_by_nr(attachment));
return;
}
@@ -2679,13 +2679,13 @@ _mesa_FramebufferRenderbuffer(GLenum target, GLenum attachment,
rb = _mesa_lookup_renderbuffer(ctx, renderbuffer);
if (!rb) {
_mesa_error(ctx, GL_INVALID_OPERATION,
- "glFramebufferRenderbufferEXT(non-existant"
+ "glFramebufferRenderbuffer(non-existant"
" renderbuffer %u)", renderbuffer);
return;
}
else if (rb == &DummyRenderbuffer) {
_mesa_error(ctx, GL_INVALID_OPERATION,
- "glFramebufferRenderbufferEXT(renderbuffer %u)",
+ "glFramebufferRenderbuffer(renderbuffer %u)",
renderbuffer);
return;
}
@@ -2701,7 +2701,7 @@ _mesa_FramebufferRenderbuffer(GLenum target, GLenum attachment,
const GLenum baseFormat = _mesa_get_format_base_format(rb->Format);
if (baseFormat != GL_DEPTH_STENCIL) {
_mesa_error(ctx, GL_INVALID_OPERATION,
- "glFramebufferRenderbufferEXT(renderbuffer"
+ "glFramebufferRenderbuffer(renderbuffer"
" is not DEPTH_STENCIL format)");
return;
}
@@ -2734,7 +2734,7 @@ _mesa_GetFramebufferAttachmentParameteriv(GLenum target, GLenum attachment,
buffer = get_framebuffer_target(ctx, target);
if (!buffer) {
_mesa_error(ctx, GL_INVALID_ENUM,
- "glGetFramebufferAttachmentParameterivEXT(target)");
+ "glGetFramebufferAttachmentParameteriv(target)");
return;
}
@@ -2773,7 +2773,7 @@ _mesa_GetFramebufferAttachmentParameteriv(GLenum target, GLenum attachment,
if (att == NULL) {
_mesa_error(ctx, GL_INVALID_ENUM,
- "glGetFramebufferAttachmentParameterivEXT(attachment)");
+ "glGetFramebufferAttachmentParameteriv(attachment)");
return;
}
@@ -2797,7 +2797,7 @@ _mesa_GetFramebufferAttachmentParameteriv(GLenum target, GLenum attachment,
stencilAtt = get_attachment(ctx, buffer, GL_STENCIL_ATTACHMENT);
if (depthAtt->Renderbuffer != stencilAtt->Renderbuffer) {
_mesa_error(ctx, GL_INVALID_OPERATION,
- "glGetFramebufferAttachmentParameterivEXT(DEPTH/STENCIL"
+ "glGetFramebufferAttachmentParameteriv(DEPTH/STENCIL"
" attachments differ)");
return;
}
@@ -2832,7 +2832,7 @@ _mesa_GetFramebufferAttachmentParameteriv(GLenum target, GLenum attachment,
}
else if (att->Type == GL_NONE) {
_mesa_error(ctx, err,
- "glGetFramebufferAttachmentParameterivEXT(pname)");
+ "glGetFramebufferAttachmentParameteriv(pname)");
}
else {
goto invalid_pname_enum;
@@ -2849,7 +2849,7 @@ _mesa_GetFramebufferAttachmentParameteriv(GLenum target, GLenum attachment,
}
else if (att->Type == GL_NONE) {
_mesa_error(ctx, err,
- "glGetFramebufferAttachmentParameterivEXT(pname)");
+ "glGetFramebufferAttachmentParameteriv(pname)");
}
else {
goto invalid_pname_enum;
@@ -2860,7 +2860,7 @@ _mesa_GetFramebufferAttachmentParameteriv(GLenum target, GLenum attachment,
goto invalid_pname_enum;
} else if (att->Type == GL_NONE) {
_mesa_error(ctx, err,
- "glGetFramebufferAttachmentParameterivEXT(pname)");
+ "glGetFramebufferAttachmentParameteriv(pname)");
} else if (att->Type == GL_TEXTURE) {
if (att->Texture && att->Texture->Target == GL_TEXTURE_3D) {
*params = att->Zoffset;
@@ -2881,7 +2881,7 @@ _mesa_GetFramebufferAttachmentParameteriv(GLenum target, GLenum attachment,
}
else if (att->Type == GL_NONE) {
_mesa_error(ctx, err,
- "glGetFramebufferAttachmentParameterivEXT(pname)");
+ "glGetFramebufferAttachmentParameteriv(pname)");
}
else {
if (ctx->Extensions.EXT_framebuffer_sRGB) {
@@ -2904,7 +2904,7 @@ _mesa_GetFramebufferAttachmentParameteriv(GLenum target, GLenum attachment,
}
else if (att->Type == GL_NONE) {
_mesa_error(ctx, err,
- "glGetFramebufferAttachmentParameterivEXT(pname)");
+ "glGetFramebufferAttachmentParameteriv(pname)");
}
else {
mesa_format format = att->Renderbuffer->Format;
@@ -2956,7 +2956,7 @@ _mesa_GetFramebufferAttachmentParameteriv(GLenum target, GLenum attachment,
}
else if (att->Type == GL_NONE) {
_mesa_error(ctx, err,
- "glGetFramebufferAttachmentParameterivEXT(pname)");
+ "glGetFramebufferAttachmentParameteriv(pname)");
}
else if (att->Texture) {
const struct gl_texture_image *texImage =
diff --git a/mesalib/src/mesa/main/get_hash_params.py b/mesalib/src/mesa/main/get_hash_params.py
index aace8a5b5..da3568469 100644
--- a/mesalib/src/mesa/main/get_hash_params.py
+++ b/mesalib/src/mesa/main/get_hash_params.py
@@ -203,10 +203,10 @@ descriptor=[
[ "COLOR_ARRAY_SIZE", "LOC_CUSTOM, TYPE_INT, 0, NO_EXTRA" ],
[ "COLOR_ARRAY_TYPE", "ARRAY_ENUM(VertexAttrib[VERT_ATTRIB_COLOR0].Type), NO_EXTRA" ],
[ "COLOR_ARRAY_STRIDE", "ARRAY_INT(VertexAttrib[VERT_ATTRIB_COLOR0].Stride), NO_EXTRA" ],
- [ "TEXTURE_COORD_ARRAY", "LOC_CUSTOM, TYPE_BOOLEAN, offsetof(struct gl_client_array, Enabled), NO_EXTRA" ],
- [ "TEXTURE_COORD_ARRAY_SIZE", "LOC_CUSTOM, TYPE_INT, offsetof(struct gl_client_array, Size), NO_EXTRA" ],
- [ "TEXTURE_COORD_ARRAY_TYPE", "LOC_CUSTOM, TYPE_ENUM, offsetof(struct gl_client_array, Type), NO_EXTRA" ],
- [ "TEXTURE_COORD_ARRAY_STRIDE", "LOC_CUSTOM, TYPE_INT, offsetof(struct gl_client_array, Stride), NO_EXTRA" ],
+ [ "TEXTURE_COORD_ARRAY", "LOC_CUSTOM, TYPE_BOOLEAN, offsetof(struct gl_vertex_attrib_array, Enabled), NO_EXTRA" ],
+ [ "TEXTURE_COORD_ARRAY_SIZE", "LOC_CUSTOM, TYPE_INT, offsetof(struct gl_vertex_attrib_array, Size), NO_EXTRA" ],
+ [ "TEXTURE_COORD_ARRAY_TYPE", "LOC_CUSTOM, TYPE_ENUM, offsetof(struct gl_vertex_attrib_array, Type), NO_EXTRA" ],
+ [ "TEXTURE_COORD_ARRAY_STRIDE", "LOC_CUSTOM, TYPE_INT, offsetof(struct gl_vertex_attrib_array, Stride), NO_EXTRA" ],
# GL_ARB_multitexture
[ "MAX_TEXTURE_UNITS", "CONTEXT_INT(Const.MaxTextureUnits), NO_EXTRA" ],
diff --git a/mesalib/src/mesa/main/imports.c b/mesalib/src/mesa/main/imports.c
index 4afe156b0..b8c754815 100644
--- a/mesalib/src/mesa/main/imports.c
+++ b/mesalib/src/mesa/main/imports.c
@@ -209,20 +209,6 @@ _mesa_align_realloc(void *oldBuffer, size_t oldSize, size_t newSize,
#endif
}
-
-
-/** Reallocate memory */
-void *
-_mesa_realloc(void *oldBuffer, size_t oldSize, size_t newSize)
-{
- const size_t copySize = (oldSize < newSize) ? oldSize : newSize;
- void *newBuffer = malloc(newSize);
- if (newBuffer && oldBuffer && copySize > 0)
- memcpy(newBuffer, oldBuffer, copySize);
- free(oldBuffer);
- return newBuffer;
-}
-
/*@}*/
@@ -231,7 +217,7 @@ _mesa_realloc(void *oldBuffer, size_t oldSize, size_t newSize)
/*@{*/
-#ifndef __GNUC__
+#ifndef HAVE___BUILTIN_FFS
/**
* Find the first bit set in a word.
*/
@@ -260,8 +246,9 @@ ffs(int i)
}
return bit;
}
+#endif
-
+#ifndef HAVE___BUILTIN_FFSLL
/**
* Find position of first bit set in given value.
* XXX Warning: this function can only be used on 64-bit systems!
@@ -285,11 +272,10 @@ ffsll(long long int val)
return 0;
}
-#endif /* __GNUC__ */
+#endif
-#if !defined(__GNUC__) ||\
- ((__GNUC__ * 100 + __GNUC_MINOR__) < 304) /* Not gcc 3.4 or later */
+#ifndef HAVE___BUILTIN_POPCOUNT
/**
* Return number of bits set in given GLuint.
*/
@@ -302,7 +288,9 @@ _mesa_bitcount(unsigned int n)
}
return bits;
}
+#endif
+#ifndef HAVE___BUILTIN_POPCOUNTLL
/**
* Return number of bits set in given 64-bit uint.
*/
@@ -489,60 +477,6 @@ _mesa_half_to_float(GLhalfARB val)
/**********************************************************************/
-/** \name Sort & Search */
-/*@{*/
-
-/**
- * Wrapper for bsearch().
- */
-void *
-_mesa_bsearch( const void *key, const void *base, size_t nmemb, size_t size,
- int (*compar)(const void *, const void *) )
-{
-#if defined(_WIN32_WCE)
- void *mid;
- int cmp;
- while (nmemb) {
- nmemb >>= 1;
- mid = (char *)base + nmemb * size;
- cmp = (*compar)(key, mid);
- if (cmp == 0)
- return mid;
- if (cmp > 0) {
- base = (char *)mid + size;
- --nmemb;
- }
- }
- return NULL;
-#else
- return bsearch(key, base, nmemb, size, compar);
-#endif
-}
-
-/*@}*/
-
-
-/**********************************************************************/
-/** \name Environment vars */
-/*@{*/
-
-/**
- * Wrapper for getenv().
- */
-char *
-_mesa_getenv( const char *var )
-{
-#if defined(_XBOX) || defined(_WIN32_WCE)
- return NULL;
-#else
- return getenv(var);
-#endif
-}
-
-/*@}*/
-
-
-/**********************************************************************/
/** \name String */
/*@{*/
diff --git a/mesalib/src/mesa/main/imports.h b/mesalib/src/mesa/main/imports.h
index 59fd19c36..436d1651a 100644
--- a/mesalib/src/mesa/main/imports.h
+++ b/mesalib/src/mesa/main/imports.h
@@ -377,8 +377,7 @@ _mesa_is_pow_two(int x)
static inline int32_t
_mesa_next_pow_two_32(uint32_t x)
{
-#if defined(__GNUC__) && \
- ((__GNUC__ * 100 + __GNUC_MINOR__) >= 304) /* gcc 3.4 or later */
+#ifdef HAVE___BUILTIN_CLZ
uint32_t y = (x != 1);
return (1 + y) << ((__builtin_clz(x - y) ^ 31) );
#else
@@ -396,13 +395,10 @@ _mesa_next_pow_two_32(uint32_t x)
static inline int64_t
_mesa_next_pow_two_64(uint64_t x)
{
-#if defined(__GNUC__) && \
- ((__GNUC__ * 100 + __GNUC_MINOR__) >= 304) /* gcc 3.4 or later */
+#ifdef HAVE___BUILTIN_CLZLL
uint64_t y = (x != 1);
- if (sizeof(x) == sizeof(long))
- return (1 + y) << ((__builtin_clzl(x - y) ^ 63));
- else
- return (1 + y) << ((__builtin_clzll(x - y) ^ 63));
+ STATIC_ASSERT(sizeof(x) == sizeof(long long));
+ return (1 + y) << ((__builtin_clzll(x - y) ^ 63));
#else
x--;
x |= x >> 1;
@@ -423,8 +419,7 @@ _mesa_next_pow_two_64(uint64_t x)
static inline GLuint
_mesa_logbase2(GLuint n)
{
-#if defined(__GNUC__) && \
- ((__GNUC__ * 100 + __GNUC_MINOR__) >= 304) /* gcc 3.4 or later */
+#ifdef HAVE___BUILTIN_CLZ
return (31 - __builtin_clz(n | 1));
#else
GLuint pos = 0;
@@ -473,28 +468,33 @@ _mesa_exec_malloc( GLuint size );
extern void
_mesa_exec_free( void *addr );
-extern void *
-_mesa_realloc( void *oldBuffer, size_t oldSize, size_t newSize );
-
#ifndef FFS_DEFINED
#define FFS_DEFINED 1
-#ifdef __GNUC__
+#ifdef HAVE___BUILTIN_FFS
#define ffs __builtin_ffs
-#define ffsll __builtin_ffsll
#else
extern int ffs(int i);
+#endif
+
+#ifdef HAVE___BUILTIN_FFSLL
+#define ffsll __builtin_ffsll
+#else
extern int ffsll(long long int i);
-#endif /*__ GNUC__ */
+#endif
#endif /* FFS_DEFINED */
-#if defined(__GNUC__) && ((__GNUC__ * 100 + __GNUC_MINOR__) >= 304) /* gcc 3.4 or later */
+#ifdef HAVE___BUILTIN_POPCOUNT
#define _mesa_bitcount(i) __builtin_popcount(i)
-#define _mesa_bitcount_64(i) __builtin_popcountll(i)
#else
extern unsigned int
_mesa_bitcount(unsigned int n);
+#endif
+
+#ifdef HAVE___BUILTIN_POPCOUNTLL
+#define _mesa_bitcount_64(i) __builtin_popcountll(i)
+#else
extern unsigned int
_mesa_bitcount_64(uint64_t n);
#endif
@@ -507,7 +507,7 @@ _mesa_bitcount_64(uint64_t n);
static inline unsigned int
_mesa_fls(unsigned int n)
{
-#if defined(__GNUC__) && ((__GNUC__ * 100 + __GNUC_MINOR__) >= 304)
+#ifdef HAVE___BUILTIN_CLZ
return n == 0 ? 0 : 32 - __builtin_clz(n);
#else
unsigned int v = 1;
@@ -537,13 +537,6 @@ _mesa_half_is_negative(GLhalfARB h)
return h & 0x8000;
}
-extern void *
-_mesa_bsearch( const void *key, const void *base, size_t nmemb, size_t size,
- int (*compar)(const void *, const void *) );
-
-extern char *
-_mesa_getenv( const char *var );
-
extern char *
_mesa_strdup( const char *s );
diff --git a/mesalib/src/mesa/main/macros.h b/mesalib/src/mesa/main/macros.h
index 712699f75..cd5f2d6f2 100644
--- a/mesalib/src/mesa/main/macros.h
+++ b/mesalib/src/mesa/main/macros.h
@@ -799,13 +799,6 @@ NORMALIZE_3FV(GLfloat v[3])
}
-/** Is float value negative? */
-static inline GLboolean
-IS_NEGATIVE(float x)
-{
- return signbit(x) != 0;
-}
-
/** Test two floats have opposite signs */
static inline GLboolean
DIFFERENT_SIGNS(GLfloat x, GLfloat y)
diff --git a/mesalib/src/mesa/main/mtypes.h b/mesalib/src/mesa/main/mtypes.h
index 553a21667..dd330eab7 100644
--- a/mesalib/src/mesa/main/mtypes.h
+++ b/mesalib/src/mesa/main/mtypes.h
@@ -3452,7 +3452,7 @@ struct gl_constants
GLuint MaxGeometryOutputVertices;
GLuint MaxGeometryTotalOutputComponents;
- GLuint GLSLVersion; /**< GLSL version supported (ex: 120 = 1.20) */
+ GLuint GLSLVersion; /**< Desktop GLSL version supported (ex: 120 = 1.20) */
/**
* Changes default GLSL extension behavior from "error" to "warn". It's out
@@ -3552,11 +3552,6 @@ struct gl_constants
GLboolean GLSLSkipStrictMaxUniformLimitCheck;
/**
- * Force software support for primitive restart in the VBO module.
- */
- GLboolean PrimitiveRestartInSoftware;
-
- /**
* Always use the GetTransformFeedbackVertexCount() driver hook, rather
* than passing the transform feedback object to the drawing function.
*/
@@ -3576,6 +3571,19 @@ struct gl_constants
*/
GLboolean DisableVaryingPacking;
+ /**
+ * Should meaningful names be generated for compiler temporary variables?
+ *
+ * Generally, it is not useful to have the compiler generate "meaningful"
+ * names for temporary variables that it creates. This can, however, be a
+ * useful debugging aid. In Mesa debug builds or release builds when
+ * MESA_GLSL is set at run-time, meaningful names will be generated.
+ * Drivers can also force names to be generated by setting this field.
+ * For example, the i965 driver may set it when INTEL_DEBUG=vs (to dump
+ * vertex shader assembly) is set at run-time.
+ */
+ bool GenerateTemporaryNames;
+
/*
* Maximum value supported for an index in DrawElements and friends.
*
diff --git a/mesalib/src/mesa/main/shaderapi.c b/mesalib/src/mesa/main/shaderapi.c
index 620cab3cc..3e6f61067 100644
--- a/mesalib/src/mesa/main/shaderapi.c
+++ b/mesalib/src/mesa/main/shaderapi.c
@@ -70,7 +70,7 @@ GLbitfield
_mesa_get_shader_flags(void)
{
GLbitfield flags = 0x0;
- const char *env = _mesa_getenv("MESA_GLSL");
+ const char *env = getenv("MESA_GLSL");
if (env) {
if (strstr(env, "dump_on_error"))
@@ -123,6 +123,9 @@ _mesa_init_shader_state(struct gl_context *ctx)
ctx->Shader.Flags = _mesa_get_shader_flags();
+ if (ctx->Shader.Flags != 0)
+ ctx->Const.GenerateTemporaryNames = true;
+
/* Extended for ARB_separate_shader_objects */
ctx->Shader.RefCount = 1;
mtx_init(&ctx->Shader.Mutex, mtx_plain);
@@ -272,9 +275,8 @@ attach_shader(struct gl_context *ctx, GLuint program, GLuint shader)
/* grow list */
shProg->Shaders = (struct gl_shader **)
- _mesa_realloc(shProg->Shaders,
- n * sizeof(struct gl_shader *),
- (n + 1) * sizeof(struct gl_shader *));
+ realloc(shProg->Shaders,
+ (n + 1) * sizeof(struct gl_shader *));
if (!shProg->Shaders) {
_mesa_error(ctx, GL_OUT_OF_MEMORY, "glAttachShader");
return;
diff --git a/mesalib/src/mesa/main/shaderobj.h b/mesalib/src/mesa/main/shaderobj.h
index fae8be827..d72919c1f 100644
--- a/mesalib/src/mesa/main/shaderobj.h
+++ b/mesalib/src/mesa/main/shaderobj.h
@@ -94,13 +94,6 @@ _mesa_free_shader_program_data(struct gl_context *ctx,
extern void
_mesa_init_shader_object_functions(struct dd_function_table *driver);
-extern void
-_mesa_init_shader_state(struct gl_context *ctx);
-
-extern void
-_mesa_free_shader_state(struct gl_context *ctx);
-
-
static inline gl_shader_stage
_mesa_shader_enum_to_shader_stage(GLenum v)
{
diff --git a/mesalib/src/mesa/main/texcompress_s3tc.c b/mesalib/src/mesa/main/texcompress_s3tc.c
index 5b275efe0..254f84ef7 100644
--- a/mesalib/src/mesa/main/texcompress_s3tc.c
+++ b/mesalib/src/mesa/main/texcompress_s3tc.c
@@ -51,8 +51,6 @@
#define DXTN_LIBNAME "dxtn.dll"
#define RTLD_LAZY 0
#define RTLD_GLOBAL 0
-#elif defined(__DJGPP__)
-#define DXTN_LIBNAME "dxtn.dxe"
#else
#define DXTN_LIBNAME "libtxc_dxtn.so"
#endif
diff --git a/mesalib/src/mesa/main/varray.c b/mesalib/src/mesa/main/varray.c
index ead78649d..09bf52c42 100644
--- a/mesalib/src/mesa/main/varray.c
+++ b/mesalib/src/mesa/main/varray.c
@@ -711,7 +711,7 @@ _mesa_EnableVertexAttribArray(GLuint index)
vao = ctx->Array.VAO;
- ASSERT(VERT_ATTRIB_GENERIC(index) < Elements(vao->_VertexAttrib));
+ ASSERT(VERT_ATTRIB_GENERIC(index) < Elements(vao->VertexAttrib));
if (!vao->VertexAttrib[VERT_ATTRIB_GENERIC(index)].Enabled) {
/* was disabled, now being enabled */
@@ -737,7 +737,7 @@ _mesa_DisableVertexAttribArray(GLuint index)
vao = ctx->Array.VAO;
- ASSERT(VERT_ATTRIB_GENERIC(index) < Elements(vao->_VertexAttrib));
+ ASSERT(VERT_ATTRIB_GENERIC(index) < Elements(vao->VertexAttrib));
if (vao->VertexAttrib[VERT_ATTRIB_GENERIC(index)].Enabled) {
/* was enabled, now being disabled */
@@ -831,7 +831,7 @@ get_current_attrib(struct gl_context *ctx, GLuint index, const char *function)
return NULL;
}
- ASSERT(VERT_ATTRIB_GENERIC(index) < Elements(ctx->Array.VAO->_VertexAttrib));
+ ASSERT(VERT_ATTRIB_GENERIC(index) < Elements(ctx->Array.VAO->VertexAttrib));
FLUSH_CURRENT(ctx, 0);
return ctx->Current.Attrib[VERT_ATTRIB_GENERIC(index)];
@@ -953,7 +953,7 @@ _mesa_GetVertexAttribPointerv(GLuint index, GLenum pname, GLvoid **pointer)
return;
}
- ASSERT(VERT_ATTRIB_GENERIC(index) < Elements(ctx->Array.VAO->_VertexAttrib));
+ ASSERT(VERT_ATTRIB_GENERIC(index) < Elements(ctx->Array.VAO->VertexAttrib));
*pointer = (GLvoid *) ctx->Array.VAO->VertexAttrib[VERT_ATTRIB_GENERIC(index)].Ptr;
}
diff --git a/mesalib/src/mesa/main/version.c b/mesalib/src/mesa/main/version.c
index 4dea530cd..71f70119b 100644
--- a/mesalib/src/mesa/main/version.c
+++ b/mesalib/src/mesa/main/version.c
@@ -57,13 +57,15 @@ check_for_ending(const char *string, const char *ending)
* fwd_context is only valid if version > 0
*/
static void
-get_gl_override(int *version, GLboolean *fwd_context)
+get_gl_override(int *version, GLboolean *fwd_context,
+ GLboolean *compat_context)
{
const char *env_var = "MESA_GL_VERSION_OVERRIDE";
const char *version_str;
int major, minor, n;
static int override_version = -1;
static GLboolean fc_suffix = GL_FALSE;
+ static GLboolean compat_suffix = GL_FALSE;
if (override_version < 0) {
override_version = 0;
@@ -71,6 +73,7 @@ get_gl_override(int *version, GLboolean *fwd_context)
version_str = getenv(env_var);
if (version_str) {
fc_suffix = check_for_ending(version_str, "FC");
+ compat_suffix = check_for_ending(version_str, "COMPAT");
n = sscanf(version_str, "%u.%u", &major, &minor);
if (n != 2) {
@@ -87,6 +90,7 @@ get_gl_override(int *version, GLboolean *fwd_context)
*version = override_version;
*fwd_context = fc_suffix;
+ *compat_context = compat_suffix;
}
/**
@@ -129,16 +133,16 @@ _mesa_override_gl_version_contextless(struct gl_constants *consts,
gl_api *apiOut, GLuint *versionOut)
{
int version;
- GLboolean fwd_context;
+ GLboolean fwd_context, compat_context;
- get_gl_override(&version, &fwd_context);
+ get_gl_override(&version, &fwd_context, &compat_context);
if (version > 0) {
*versionOut = version;
if (version >= 30 && fwd_context) {
*apiOut = API_OPENGL_CORE;
consts->ContextFlags |= GL_CONTEXT_FLAG_FORWARD_COMPATIBLE_BIT;
- } else if (version >= 31) {
+ } else if (version >= 31 && !compat_context) {
*apiOut = API_OPENGL_CORE;
} else {
*apiOut = API_OPENGL_COMPAT;
@@ -166,9 +170,9 @@ int
_mesa_get_gl_version_override(void)
{
int version;
- GLboolean fwd_context;
+ GLboolean fwd_context, compat_context;
- get_gl_override(&version, &fwd_context);
+ get_gl_override(&version, &fwd_context, &compat_context);
return version;
}
diff --git a/mesalib/src/mesa/main/viewport.c b/mesalib/src/mesa/main/viewport.c
index 6545bf68a..222ae307b 100644
--- a/mesalib/src/mesa/main/viewport.c
+++ b/mesalib/src/mesa/main/viewport.c
@@ -58,6 +58,12 @@ set_viewport_no_notify(struct gl_context *ctx, unsigned idx,
ctx->Const.ViewportBounds.Min, ctx->Const.ViewportBounds.Max);
}
+ if (ctx->ViewportArray[idx].X == x &&
+ ctx->ViewportArray[idx].Width == width &&
+ ctx->ViewportArray[idx].Y == y &&
+ ctx->ViewportArray[idx].Height == height)
+ return;
+
ctx->ViewportArray[idx].X = x;
ctx->ViewportArray[idx].Width = width;
ctx->ViewportArray[idx].Y = y;
diff --git a/mesalib/src/mesa/math/m_debug_clip.c b/mesalib/src/mesa/math/m_debug_clip.c
index cd8a90d4d..044768dbd 100644
--- a/mesalib/src/mesa/math/m_debug_clip.c
+++ b/mesalib/src/mesa/math/m_debug_clip.c
@@ -355,7 +355,7 @@ void _math_test_all_cliptest_functions( char *description )
if ( first_time ) {
first_time = 0;
- mesa_profile = _mesa_getenv( "MESA_PROFILE" );
+ mesa_profile = getenv( "MESA_PROFILE" );
}
#ifdef RUN_DEBUG_BENCHMARK
diff --git a/mesalib/src/mesa/math/m_debug_norm.c b/mesalib/src/mesa/math/m_debug_norm.c
index db71ebef0..00e72be54 100644
--- a/mesalib/src/mesa/math/m_debug_norm.c
+++ b/mesalib/src/mesa/math/m_debug_norm.c
@@ -339,7 +339,7 @@ void _math_test_all_normal_transform_functions( char *description )
if ( first_time ) {
first_time = 0;
- mesa_profile = _mesa_getenv( "MESA_PROFILE" );
+ mesa_profile = getenv( "MESA_PROFILE" );
}
#ifdef RUN_DEBUG_BENCHMARK
diff --git a/mesalib/src/mesa/math/m_debug_xform.c b/mesalib/src/mesa/math/m_debug_xform.c
index fbfa9b28a..f56b4cfc7 100644
--- a/mesalib/src/mesa/math/m_debug_xform.c
+++ b/mesalib/src/mesa/math/m_debug_xform.c
@@ -285,7 +285,7 @@ void _math_test_all_transform_functions( char *description )
if ( first_time ) {
first_time = 0;
- mesa_profile = _mesa_getenv( "MESA_PROFILE" );
+ mesa_profile = getenv( "MESA_PROFILE" );
}
#ifdef RUN_DEBUG_BENCHMARK
diff --git a/mesalib/src/mesa/program/ir_to_mesa.cpp b/mesalib/src/mesa/program/ir_to_mesa.cpp
index 293fe34b9..b3e04d7b6 100644
--- a/mesalib/src/mesa/program/ir_to_mesa.cpp
+++ b/mesalib/src/mesa/program/ir_to_mesa.cpp
@@ -682,8 +682,8 @@ ir_to_mesa_visitor::visit(ir_variable *ir)
if (ir->data.mode == ir_var_uniform && strncmp(ir->name, "gl_", 3) == 0) {
unsigned int i;
- const ir_state_slot *const slots = ir->state_slots;
- assert(ir->state_slots != NULL);
+ const ir_state_slot *const slots = ir->get_state_slots();
+ assert(slots != NULL);
/* Check if this statevar's setup in the STATE file exactly
* matches how we'll want to reference it as a
@@ -691,7 +691,7 @@ ir_to_mesa_visitor::visit(ir_variable *ir)
* temporary storage and hope that it'll get copy-propagated
* out.
*/
- for (i = 0; i < ir->num_state_slots; i++) {
+ for (i = 0; i < ir->get_num_state_slots(); i++) {
if (slots[i].swizzle != SWIZZLE_XYZW) {
break;
}
@@ -699,7 +699,7 @@ ir_to_mesa_visitor::visit(ir_variable *ir)
variable_storage *storage;
dst_reg dst;
- if (i == ir->num_state_slots) {
+ if (i == ir->get_num_state_slots()) {
/* We'll set the index later. */
storage = new(mem_ctx) variable_storage(ir, PROGRAM_STATE_VAR, -1);
this->variables.push_tail(storage);
@@ -710,7 +710,7 @@ ir_to_mesa_visitor::visit(ir_variable *ir)
* of the type. However, this had better match the number of state
* elements that we're going to copy into the new temporary.
*/
- assert((int) ir->num_state_slots == type_size(ir->type));
+ assert((int) ir->get_num_state_slots() == type_size(ir->type));
storage = new(mem_ctx) variable_storage(ir, PROGRAM_TEMPORARY,
this->next_temp);
@@ -721,7 +721,7 @@ ir_to_mesa_visitor::visit(ir_variable *ir)
}
- for (unsigned int i = 0; i < ir->num_state_slots; i++) {
+ for (unsigned int i = 0; i < ir->get_num_state_slots(); i++) {
int index = _mesa_add_state_reference(this->prog->Parameters,
(gl_state_index *)slots[i].tokens);
@@ -741,7 +741,7 @@ ir_to_mesa_visitor::visit(ir_variable *ir)
}
if (storage->file == PROGRAM_TEMPORARY &&
- dst.index != storage->index + (int) ir->num_state_slots) {
+ dst.index != storage->index + (int) ir->get_num_state_slots()) {
linker_error(this->shader_program,
"failed to load builtin uniform `%s' "
"(%d/%d regs loaded)\n",
diff --git a/mesalib/src/mesa/program/prog_instruction.c b/mesalib/src/mesa/program/prog_instruction.c
index dc0a5109f..e2eadc36c 100644
--- a/mesalib/src/mesa/program/prog_instruction.c
+++ b/mesalib/src/mesa/program/prog_instruction.c
@@ -90,9 +90,8 @@ _mesa_realloc_instructions(struct prog_instruction *oldInst,
struct prog_instruction *newInst;
newInst = (struct prog_instruction *)
- _mesa_realloc(oldInst,
- numOldInst * sizeof(struct prog_instruction),
- numNewInst * sizeof(struct prog_instruction));
+ realloc(oldInst,
+ numNewInst * sizeof(struct prog_instruction));
return newInst;
}
diff --git a/mesalib/src/mesa/program/prog_parameter.c b/mesalib/src/mesa/program/prog_parameter.c
index f43deba0b..896c6052b 100644
--- a/mesalib/src/mesa/program/prog_parameter.c
+++ b/mesalib/src/mesa/program/prog_parameter.c
@@ -121,9 +121,8 @@ _mesa_add_parameter(struct gl_program_parameter_list *paramList,
/* realloc arrays */
paramList->Parameters = (struct gl_program_parameter *)
- _mesa_realloc(paramList->Parameters,
- oldNum * sizeof(struct gl_program_parameter),
- paramList->Size * sizeof(struct gl_program_parameter));
+ realloc(paramList->Parameters,
+ paramList->Size * sizeof(struct gl_program_parameter));
paramList->ParameterValues = (gl_constant_value (*)[4])
_mesa_align_realloc(paramList->ParameterValues, /* old buf */
diff --git a/mesalib/src/mesa/program/register_allocate.c b/mesalib/src/mesa/program/register_allocate.c
deleted file mode 100644
index 7faf67215..000000000
--- a/mesalib/src/mesa/program/register_allocate.c
+++ /dev/null
@@ -1,654 +0,0 @@
-/*
- * Copyright © 2010 Intel Corporation
- *
- * Permission is hereby granted, free of charge, to any person obtaining a
- * copy of this software and associated documentation files (the "Software"),
- * to deal in the Software without restriction, including without limitation
- * the rights to use, copy, modify, merge, publish, distribute, sublicense,
- * and/or sell copies of the Software, and to permit persons to whom the
- * Software is furnished to do so, subject to the following conditions:
- *
- * The above copyright notice and this permission notice (including the next
- * paragraph) shall be included in all copies or substantial portions of the
- * Software.
- *
- * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
- * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
- * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
- * THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
- * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
- * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS
- * IN THE SOFTWARE.
- *
- * Authors:
- * Eric Anholt <eric@anholt.net>
- *
- */
-
-/** @file register_allocate.c
- *
- * Graph-coloring register allocator.
- *
- * The basic idea of graph coloring is to make a node in a graph for
- * every thing that needs a register (color) number assigned, and make
- * edges in the graph between nodes that interfere (can't be allocated
- * to the same register at the same time).
- *
- * During the "simplify" process, any any node with fewer edges than
- * there are registers means that that edge can get assigned a
- * register regardless of what its neighbors choose, so that node is
- * pushed on a stack and removed (with its edges) from the graph.
- * That likely causes other nodes to become trivially colorable as well.
- *
- * Then during the "select" process, nodes are popped off of that
- * stack, their edges restored, and assigned a color different from
- * their neighbors. Because they were pushed on the stack only when
- * they were trivially colorable, any color chosen won't interfere
- * with the registers to be popped later.
- *
- * The downside to most graph coloring is that real hardware often has
- * limitations, like registers that need to be allocated to a node in
- * pairs, or aligned on some boundary. This implementation follows
- * the paper "Retargetable Graph-Coloring Register Allocation for
- * Irregular Architectures" by Johan Runeson and Sven-Olof Nyström.
- *
- * In this system, there are register classes each containing various
- * registers, and registers may interfere with other registers. For
- * example, one might have a class of base registers, and a class of
- * aligned register pairs that would each interfere with their pair of
- * the base registers. Each node has a register class it needs to be
- * assigned to. Define p(B) to be the size of register class B, and
- * q(B,C) to be the number of registers in B that the worst choice
- * register in C could conflict with. Then, this system replaces the
- * basic graph coloring test of "fewer edges from this node than there
- * are registers" with "For this node of class B, the sum of q(B,C)
- * for each neighbor node of class C is less than pB".
- *
- * A nice feature of the pq test is that q(B,C) can be computed once
- * up front and stored in a 2-dimensional array, so that the cost of
- * coloring a node is constant with the number of registers. We do
- * this during ra_set_finalize().
- */
-
-#include <stdbool.h>
-
-#include "util/ralloc.h"
-#include "main/imports.h"
-#include "main/macros.h"
-#include "main/mtypes.h"
-#include "main/bitset.h"
-#include "register_allocate.h"
-
-#define NO_REG ~0
-
-struct ra_reg {
- BITSET_WORD *conflicts;
- unsigned int *conflict_list;
- unsigned int conflict_list_size;
- unsigned int num_conflicts;
-};
-
-struct ra_regs {
- struct ra_reg *regs;
- unsigned int count;
-
- struct ra_class **classes;
- unsigned int class_count;
-
- bool round_robin;
-};
-
-struct ra_class {
- /**
- * Bitset indicating which registers belong to this class.
- *
- * (If bit N is set, then register N belongs to this class.)
- */
- BITSET_WORD *regs;
-
- /**
- * p(B) in Runeson/Nyström paper.
- *
- * This is "how many regs are in the set."
- */
- unsigned int p;
-
- /**
- * q(B,C) (indexed by C, B is this register class) in
- * Runeson/Nyström paper. This is "how many registers of B could
- * the worst choice register from C conflict with".
- */
- unsigned int *q;
-};
-
-struct ra_node {
- /** @{
- *
- * List of which nodes this node interferes with. This should be
- * symmetric with the other node.
- */
- BITSET_WORD *adjacency;
- unsigned int *adjacency_list;
- unsigned int adjacency_list_size;
- unsigned int adjacency_count;
- /** @} */
-
- unsigned int class;
-
- /* Register, if assigned, or NO_REG. */
- unsigned int reg;
-
- /**
- * Set when the node is in the trivially colorable stack. When
- * set, the adjacency to this node is ignored, to implement the
- * "remove the edge from the graph" in simplification without
- * having to actually modify the adjacency_list.
- */
- bool in_stack;
-
- /**
- * The q total, as defined in the Runeson/Nyström paper, for all the
- * interfering nodes not in the stack.
- */
- unsigned int q_total;
-
- /* For an implementation that needs register spilling, this is the
- * approximate cost of spilling this node.
- */
- float spill_cost;
-};
-
-struct ra_graph {
- struct ra_regs *regs;
- /**
- * the variables that need register allocation.
- */
- struct ra_node *nodes;
- unsigned int count; /**< count of nodes. */
-
- unsigned int *stack;
- unsigned int stack_count;
-};
-
-/**
- * Creates a set of registers for the allocator.
- *
- * mem_ctx is a ralloc context for the allocator. The reg set may be freed
- * using ralloc_free().
- */
-struct ra_regs *
-ra_alloc_reg_set(void *mem_ctx, unsigned int count)
-{
- unsigned int i;
- struct ra_regs *regs;
-
- regs = rzalloc(mem_ctx, struct ra_regs);
- regs->count = count;
- regs->regs = rzalloc_array(regs, struct ra_reg, count);
-
- for (i = 0; i < count; i++) {
- regs->regs[i].conflicts = rzalloc_array(regs->regs, BITSET_WORD,
- BITSET_WORDS(count));
- BITSET_SET(regs->regs[i].conflicts, i);
-
- regs->regs[i].conflict_list = ralloc_array(regs->regs, unsigned int, 4);
- regs->regs[i].conflict_list_size = 4;
- regs->regs[i].conflict_list[0] = i;
- regs->regs[i].num_conflicts = 1;
- }
-
- return regs;
-}
-
-/**
- * The register allocator by default prefers to allocate low register numbers,
- * since it was written for hardware (gen4/5 Intel) that is limited in its
- * multithreadedness by the number of registers used in a given shader.
- *
- * However, for hardware without that restriction, densely packed register
- * allocation can put serious constraints on instruction scheduling. This
- * function tells the allocator to rotate around the registers if possible as
- * it allocates the nodes.
- */
-void
-ra_set_allocate_round_robin(struct ra_regs *regs)
-{
- regs->round_robin = true;
-}
-
-static void
-ra_add_conflict_list(struct ra_regs *regs, unsigned int r1, unsigned int r2)
-{
- struct ra_reg *reg1 = &regs->regs[r1];
-
- if (reg1->conflict_list_size == reg1->num_conflicts) {
- reg1->conflict_list_size *= 2;
- reg1->conflict_list = reralloc(regs->regs, reg1->conflict_list,
- unsigned int, reg1->conflict_list_size);
- }
- reg1->conflict_list[reg1->num_conflicts++] = r2;
- BITSET_SET(reg1->conflicts, r2);
-}
-
-void
-ra_add_reg_conflict(struct ra_regs *regs, unsigned int r1, unsigned int r2)
-{
- if (!BITSET_TEST(regs->regs[r1].conflicts, r2)) {
- ra_add_conflict_list(regs, r1, r2);
- ra_add_conflict_list(regs, r2, r1);
- }
-}
-
-/**
- * Adds a conflict between base_reg and reg, and also between reg and
- * anything that base_reg conflicts with.
- *
- * This can simplify code for setting up multiple register classes
- * which are aggregates of some base hardware registers, compared to
- * explicitly using ra_add_reg_conflict.
- */
-void
-ra_add_transitive_reg_conflict(struct ra_regs *regs,
- unsigned int base_reg, unsigned int reg)
-{
- int i;
-
- ra_add_reg_conflict(regs, reg, base_reg);
-
- for (i = 0; i < regs->regs[base_reg].num_conflicts; i++) {
- ra_add_reg_conflict(regs, reg, regs->regs[base_reg].conflict_list[i]);
- }
-}
-
-unsigned int
-ra_alloc_reg_class(struct ra_regs *regs)
-{
- struct ra_class *class;
-
- regs->classes = reralloc(regs->regs, regs->classes, struct ra_class *,
- regs->class_count + 1);
-
- class = rzalloc(regs, struct ra_class);
- regs->classes[regs->class_count] = class;
-
- class->regs = rzalloc_array(class, BITSET_WORD, BITSET_WORDS(regs->count));
-
- return regs->class_count++;
-}
-
-void
-ra_class_add_reg(struct ra_regs *regs, unsigned int c, unsigned int r)
-{
- struct ra_class *class = regs->classes[c];
-
- BITSET_SET(class->regs, r);
- class->p++;
-}
-
-/**
- * Returns true if the register belongs to the given class.
- */
-static bool
-reg_belongs_to_class(unsigned int r, struct ra_class *c)
-{
- return BITSET_TEST(c->regs, r);
-}
-
-/**
- * Must be called after all conflicts and register classes have been
- * set up and before the register set is used for allocation.
- * To avoid costly q value computation, use the q_values paramater
- * to pass precomputed q values to this function.
- */
-void
-ra_set_finalize(struct ra_regs *regs, unsigned int **q_values)
-{
- unsigned int b, c;
-
- for (b = 0; b < regs->class_count; b++) {
- regs->classes[b]->q = ralloc_array(regs, unsigned int, regs->class_count);
- }
-
- if (q_values) {
- for (b = 0; b < regs->class_count; b++) {
- for (c = 0; c < regs->class_count; c++) {
- regs->classes[b]->q[c] = q_values[b][c];
- }
- }
- return;
- }
-
- /* Compute, for each class B and C, how many regs of B an
- * allocation to C could conflict with.
- */
- for (b = 0; b < regs->class_count; b++) {
- for (c = 0; c < regs->class_count; c++) {
- unsigned int rc;
- int max_conflicts = 0;
-
- for (rc = 0; rc < regs->count; rc++) {
- int conflicts = 0;
- int i;
-
- if (!reg_belongs_to_class(rc, regs->classes[c]))
- continue;
-
- for (i = 0; i < regs->regs[rc].num_conflicts; i++) {
- unsigned int rb = regs->regs[rc].conflict_list[i];
- if (BITSET_TEST(regs->classes[b]->regs, rb))
- conflicts++;
- }
- max_conflicts = MAX2(max_conflicts, conflicts);
- }
- regs->classes[b]->q[c] = max_conflicts;
- }
- }
-}
-
-static void
-ra_add_node_adjacency(struct ra_graph *g, unsigned int n1, unsigned int n2)
-{
- BITSET_SET(g->nodes[n1].adjacency, n2);
-
- if (n1 != n2) {
- int n1_class = g->nodes[n1].class;
- int n2_class = g->nodes[n2].class;
- g->nodes[n1].q_total += g->regs->classes[n1_class]->q[n2_class];
- }
-
- if (g->nodes[n1].adjacency_count >=
- g->nodes[n1].adjacency_list_size) {
- g->nodes[n1].adjacency_list_size *= 2;
- g->nodes[n1].adjacency_list = reralloc(g, g->nodes[n1].adjacency_list,
- unsigned int,
- g->nodes[n1].adjacency_list_size);
- }
-
- g->nodes[n1].adjacency_list[g->nodes[n1].adjacency_count] = n2;
- g->nodes[n1].adjacency_count++;
-}
-
-struct ra_graph *
-ra_alloc_interference_graph(struct ra_regs *regs, unsigned int count)
-{
- struct ra_graph *g;
- unsigned int i;
-
- g = rzalloc(regs, struct ra_graph);
- g->regs = regs;
- g->nodes = rzalloc_array(g, struct ra_node, count);
- g->count = count;
-
- g->stack = rzalloc_array(g, unsigned int, count);
-
- for (i = 0; i < count; i++) {
- int bitset_count = BITSET_WORDS(count);
- g->nodes[i].adjacency = rzalloc_array(g, BITSET_WORD, bitset_count);
-
- g->nodes[i].adjacency_list_size = 4;
- g->nodes[i].adjacency_list =
- ralloc_array(g, unsigned int, g->nodes[i].adjacency_list_size);
- g->nodes[i].adjacency_count = 0;
- g->nodes[i].q_total = 0;
-
- ra_add_node_adjacency(g, i, i);
- g->nodes[i].reg = NO_REG;
- }
-
- return g;
-}
-
-void
-ra_set_node_class(struct ra_graph *g,
- unsigned int n, unsigned int class)
-{
- g->nodes[n].class = class;
-}
-
-void
-ra_add_node_interference(struct ra_graph *g,
- unsigned int n1, unsigned int n2)
-{
- if (!BITSET_TEST(g->nodes[n1].adjacency, n2)) {
- ra_add_node_adjacency(g, n1, n2);
- ra_add_node_adjacency(g, n2, n1);
- }
-}
-
-static bool
-pq_test(struct ra_graph *g, unsigned int n)
-{
- int n_class = g->nodes[n].class;
-
- return g->nodes[n].q_total < g->regs->classes[n_class]->p;
-}
-
-static void
-decrement_q(struct ra_graph *g, unsigned int n)
-{
- unsigned int i;
- int n_class = g->nodes[n].class;
-
- for (i = 0; i < g->nodes[n].adjacency_count; i++) {
- unsigned int n2 = g->nodes[n].adjacency_list[i];
- unsigned int n2_class = g->nodes[n2].class;
-
- if (n != n2 && !g->nodes[n2].in_stack) {
- assert(g->nodes[n2].q_total >= g->regs->classes[n2_class]->q[n_class]);
- g->nodes[n2].q_total -= g->regs->classes[n2_class]->q[n_class];
- }
- }
-}
-
-/**
- * Simplifies the interference graph by pushing all
- * trivially-colorable nodes into a stack of nodes to be colored,
- * removing them from the graph, and rinsing and repeating.
- *
- * If we encounter a case where we can't push any nodes on the stack, then
- * we optimistically choose a node and push it on the stack. We heuristically
- * push the node with the lowest total q value, since it has the fewest
- * neighbors and therefore is most likely to be allocated.
- */
-static void
-ra_simplify(struct ra_graph *g)
-{
- bool progress = true;
- int i;
-
- while (progress) {
- unsigned int best_optimistic_node = ~0;
- unsigned int lowest_q_total = ~0;
-
- progress = false;
-
- for (i = g->count - 1; i >= 0; i--) {
- if (g->nodes[i].in_stack || g->nodes[i].reg != NO_REG)
- continue;
-
- if (pq_test(g, i)) {
- decrement_q(g, i);
- g->stack[g->stack_count] = i;
- g->stack_count++;
- g->nodes[i].in_stack = true;
- progress = true;
- } else {
- unsigned int new_q_total = g->nodes[i].q_total;
- if (new_q_total < lowest_q_total) {
- best_optimistic_node = i;
- lowest_q_total = new_q_total;
- }
- }
- }
-
- if (!progress && best_optimistic_node != ~0) {
- decrement_q(g, best_optimistic_node);
- g->stack[g->stack_count] = best_optimistic_node;
- g->stack_count++;
- g->nodes[best_optimistic_node].in_stack = true;
- progress = true;
- }
- }
-}
-
-/**
- * Pops nodes from the stack back into the graph, coloring them with
- * registers as they go.
- *
- * If all nodes were trivially colorable, then this must succeed. If
- * not (optimistic coloring), then it may return false;
- */
-static bool
-ra_select(struct ra_graph *g)
-{
- int i;
- int start_search_reg = 0;
-
- while (g->stack_count != 0) {
- unsigned int ri;
- unsigned int r = -1;
- int n = g->stack[g->stack_count - 1];
- struct ra_class *c = g->regs->classes[g->nodes[n].class];
-
- /* Find the lowest-numbered reg which is not used by a member
- * of the graph adjacent to us.
- */
- for (ri = 0; ri < g->regs->count; ri++) {
- r = (start_search_reg + ri) % g->regs->count;
- if (!reg_belongs_to_class(r, c))
- continue;
-
- /* Check if any of our neighbors conflict with this register choice. */
- for (i = 0; i < g->nodes[n].adjacency_count; i++) {
- unsigned int n2 = g->nodes[n].adjacency_list[i];
-
- if (!g->nodes[n2].in_stack &&
- BITSET_TEST(g->regs->regs[r].conflicts, g->nodes[n2].reg)) {
- break;
- }
- }
- if (i == g->nodes[n].adjacency_count)
- break;
- }
-
- /* set this to false even if we return here so that
- * ra_get_best_spill_node() considers this node later.
- */
- g->nodes[n].in_stack = false;
-
- if (ri == g->regs->count)
- return false;
-
- g->nodes[n].reg = r;
- g->stack_count--;
-
- if (g->regs->round_robin)
- start_search_reg = r + 1;
- }
-
- return true;
-}
-
-bool
-ra_allocate(struct ra_graph *g)
-{
- ra_simplify(g);
- return ra_select(g);
-}
-
-unsigned int
-ra_get_node_reg(struct ra_graph *g, unsigned int n)
-{
- return g->nodes[n].reg;
-}
-
-/**
- * Forces a node to a specific register. This can be used to avoid
- * creating a register class containing one node when handling data
- * that must live in a fixed location and is known to not conflict
- * with other forced register assignment (as is common with shader
- * input data). These nodes do not end up in the stack during
- * ra_simplify(), and thus at ra_select() time it is as if they were
- * the first popped off the stack and assigned their fixed locations.
- * Nodes that use this function do not need to be assigned a register
- * class.
- *
- * Must be called before ra_simplify().
- */
-void
-ra_set_node_reg(struct ra_graph *g, unsigned int n, unsigned int reg)
-{
- g->nodes[n].reg = reg;
- g->nodes[n].in_stack = false;
-}
-
-static float
-ra_get_spill_benefit(struct ra_graph *g, unsigned int n)
-{
- int j;
- float benefit = 0;
- int n_class = g->nodes[n].class;
-
- /* Define the benefit of eliminating an interference between n, n2
- * through spilling as q(C, B) / p(C). This is similar to the
- * "count number of edges" approach of traditional graph coloring,
- * but takes classes into account.
- */
- for (j = 0; j < g->nodes[n].adjacency_count; j++) {
- unsigned int n2 = g->nodes[n].adjacency_list[j];
- if (n != n2) {
- unsigned int n2_class = g->nodes[n2].class;
- benefit += ((float)g->regs->classes[n_class]->q[n2_class] /
- g->regs->classes[n_class]->p);
- }
- }
-
- return benefit;
-}
-
-/**
- * Returns a node number to be spilled according to the cost/benefit using
- * the pq test, or -1 if there are no spillable nodes.
- */
-int
-ra_get_best_spill_node(struct ra_graph *g)
-{
- unsigned int best_node = -1;
- float best_benefit = 0.0;
- unsigned int n;
-
- /* Consider any nodes that we colored successfully or the node we failed to
- * color for spilling. When we failed to color a node in ra_select(), we
- * only considered these nodes, so spilling any other ones would not result
- * in us making progress.
- */
- for (n = 0; n < g->count; n++) {
- float cost = g->nodes[n].spill_cost;
- float benefit;
-
- if (cost <= 0.0)
- continue;
-
- if (g->nodes[n].in_stack)
- continue;
-
- benefit = ra_get_spill_benefit(g, n);
-
- if (benefit / cost > best_benefit) {
- best_benefit = benefit / cost;
- best_node = n;
- }
- }
-
- return best_node;
-}
-
-/**
- * Only nodes with a spill cost set (cost != 0.0) will be considered
- * for register spilling.
- */
-void
-ra_set_node_spill_cost(struct ra_graph *g, unsigned int n, float cost)
-{
- g->nodes[n].spill_cost = cost;
-}
diff --git a/mesalib/src/mesa/program/register_allocate.h b/mesalib/src/mesa/program/register_allocate.h
deleted file mode 100644
index dc6874495..000000000
--- a/mesalib/src/mesa/program/register_allocate.h
+++ /dev/null
@@ -1,79 +0,0 @@
-/*
- * Copyright © 2010 Intel Corporation
- *
- * Permission is hereby granted, free of charge, to any person obtaining a
- * copy of this software and associated documentation files (the "Software"),
- * to deal in the Software without restriction, including without limitation
- * the rights to use, copy, modify, merge, publish, distribute, sublicense,
- * and/or sell copies of the Software, and to permit persons to whom the
- * Software is furnished to do so, subject to the following conditions:
- *
- * The above copyright notice and this permission notice (including the next
- * paragraph) shall be included in all copies or substantial portions of the
- * Software.
- *
- * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
- * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
- * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
- * THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
- * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
- * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS
- * IN THE SOFTWARE.
- *
- * Authors:
- * Eric Anholt <eric@anholt.net>
- *
- */
-
-#include <stdbool.h>
-
-struct ra_class;
-struct ra_regs;
-
-/* @{
- * Register set setup.
- *
- * This should be done once at backend initializaion, as
- * ra_set_finalize is O(r^2*c^2). The registers may be virtual
- * registers, such as aligned register pairs that conflict with the
- * two real registers from which they are composed.
- */
-struct ra_regs *ra_alloc_reg_set(void *mem_ctx, unsigned int count);
-void ra_set_allocate_round_robin(struct ra_regs *regs);
-unsigned int ra_alloc_reg_class(struct ra_regs *regs);
-void ra_add_reg_conflict(struct ra_regs *regs,
- unsigned int r1, unsigned int r2);
-void ra_add_transitive_reg_conflict(struct ra_regs *regs,
- unsigned int base_reg, unsigned int reg);
-void ra_class_add_reg(struct ra_regs *regs, unsigned int c, unsigned int reg);
-void ra_set_num_conflicts(struct ra_regs *regs, unsigned int class_a,
- unsigned int class_b, unsigned int num_conflicts);
-void ra_set_finalize(struct ra_regs *regs, unsigned int **conflicts);
-/** @} */
-
-/** @{ Interference graph setup.
- *
- * Each interference graph node is a virtual variable in the IL. It
- * is up to the user to ra_set_node_class() for the virtual variable,
- * and compute live ranges and ra_node_interfere() between conflicting
- * live ranges. Note that an interference *must not* be added between
- * two nodes if their classes haven't been assigned yet. The user
- * should set the class of each node before building the interference
- * graph.
- */
-struct ra_graph *ra_alloc_interference_graph(struct ra_regs *regs,
- unsigned int count);
-void ra_set_node_class(struct ra_graph *g, unsigned int n, unsigned int c);
-void ra_add_node_interference(struct ra_graph *g,
- unsigned int n1, unsigned int n2);
-/** @} */
-
-/** @{ Graph-coloring register allocation */
-bool ra_allocate(struct ra_graph *g);
-
-unsigned int ra_get_node_reg(struct ra_graph *g, unsigned int n);
-void ra_set_node_reg(struct ra_graph * g, unsigned int n, unsigned int reg);
-void ra_set_node_spill_cost(struct ra_graph *g, unsigned int n, float cost);
-int ra_get_best_spill_node(struct ra_graph *g);
-/** @} */
-
diff --git a/mesalib/src/mesa/program/symbol_table.c b/mesalib/src/mesa/program/symbol_table.c
index 9462978ee..5b2274593 100644
--- a/mesalib/src/mesa/program/symbol_table.c
+++ b/mesalib/src/mesa/program/symbol_table.c
@@ -172,6 +172,11 @@ _mesa_symbol_table_push_scope(struct _mesa_symbol_table *table)
{
struct scope_level *const scope = calloc(1, sizeof(*scope));
+ if (scope == NULL) {
+ _mesa_error_no_memory(__func__);
+ return;
+ }
+
scope->next = table->current_scope;
table->current_scope = scope;
table->depth++;
@@ -254,7 +259,17 @@ _mesa_symbol_table_add_symbol(struct _mesa_symbol_table *table,
if (hdr == NULL) {
hdr = calloc(1, sizeof(*hdr));
+ if (hdr == NULL) {
+ _mesa_error_no_memory(__func__);
+ return -1;
+ }
+
hdr->name = strdup(name);
+ if (hdr->name == NULL) {
+ free(hdr);
+ _mesa_error_no_memory(__func__);
+ return -1;
+ }
hash_table_insert(table->ht, hdr, hdr->name);
hdr->next = table->hdr;
@@ -276,6 +291,11 @@ _mesa_symbol_table_add_symbol(struct _mesa_symbol_table *table,
return -1;
sym = calloc(1, sizeof(*sym));
+ if (sym == NULL) {
+ _mesa_error_no_memory(__func__);
+ return -1;
+ }
+
sym->next_with_same_name = hdr->symbols;
sym->next_with_same_scope = table->current_scope->symbols;
sym->hdr = hdr;
@@ -311,6 +331,11 @@ _mesa_symbol_table_add_global_symbol(struct _mesa_symbol_table *table,
if (hdr == NULL) {
hdr = calloc(1, sizeof(*hdr));
+ if (hdr == NULL) {
+ _mesa_error_no_memory(__func__);
+ return -1;
+ }
+
hdr->name = strdup(name);
hash_table_insert(table->ht, hdr, hdr->name);
@@ -340,6 +365,11 @@ _mesa_symbol_table_add_global_symbol(struct _mesa_symbol_table *table,
}
sym = calloc(1, sizeof(*sym));
+ if (sym == NULL) {
+ _mesa_error_no_memory(__func__);
+ return -1;
+ }
+
sym->next_with_same_scope = top_scope->symbols;
sym->hdr = hdr;
sym->name_space = name_space;
diff --git a/mesalib/src/mesa/state_tracker/st_atom_rasterizer.c b/mesalib/src/mesa/state_tracker/st_atom_rasterizer.c
index 2bad64334..a2285383e 100644
--- a/mesalib/src/mesa/state_tracker/st_atom_rasterizer.c
+++ b/mesalib/src/mesa/state_tracker/st_atom_rasterizer.c
@@ -33,6 +33,7 @@
#include "main/macros.h"
#include "st_context.h"
#include "st_atom.h"
+#include "st_program.h"
#include "pipe/p_context.h"
#include "pipe/p_defines.h"
#include "cso_cache/cso_context.h"
@@ -171,9 +172,10 @@ static void update_raster_state( struct st_context *st )
raster->sprite_coord_enable |= 1 << i;
}
}
- if (fragProg->Base.InputsRead & VARYING_BIT_PNTC) {
+ if (!st->needs_texcoord_semantic &&
+ fragProg->Base.InputsRead & VARYING_BIT_PNTC) {
raster->sprite_coord_enable |=
- 1 << (VARYING_SLOT_PNTC - VARYING_SLOT_TEX0);
+ 1 << st_get_generic_varying_index(st, VARYING_SLOT_PNTC);
}
raster->point_quad_rasterization = 1;
diff --git a/mesalib/src/mesa/state_tracker/st_atom_texture.c b/mesalib/src/mesa/state_tracker/st_atom_texture.c
index ed9a44429..19072ae2f 100644
--- a/mesalib/src/mesa/state_tracker/st_atom_texture.c
+++ b/mesalib/src/mesa/state_tracker/st_atom_texture.c
@@ -223,7 +223,7 @@ static unsigned last_level(struct st_texture_object *stObj)
static unsigned last_layer(struct st_texture_object *stObj)
{
- if (stObj->base.Immutable)
+ if (stObj->base.Immutable && stObj->pt->array_size > 1)
return MIN2(stObj->base.MinLayer + stObj->base.NumLayers - 1,
stObj->pt->array_size - 1);
return stObj->pt->array_size - 1;
diff --git a/mesalib/src/mesa/state_tracker/st_cb_bufferobjects.c b/mesalib/src/mesa/state_tracker/st_cb_bufferobjects.c
index e0cb979f2..d53602c8b 100644
--- a/mesalib/src/mesa/state_tracker/st_cb_bufferobjects.c
+++ b/mesalib/src/mesa/state_tracker/st_cb_bufferobjects.c
@@ -246,21 +246,23 @@ st_bufferobj_data(struct gl_context *ctx,
/* BufferData */
switch (usage) {
case GL_STATIC_DRAW:
- case GL_STATIC_READ:
case GL_STATIC_COPY:
default:
pipe_usage = PIPE_USAGE_DEFAULT;
break;
case GL_DYNAMIC_DRAW:
- case GL_DYNAMIC_READ:
case GL_DYNAMIC_COPY:
pipe_usage = PIPE_USAGE_DYNAMIC;
break;
case GL_STREAM_DRAW:
- case GL_STREAM_READ:
case GL_STREAM_COPY:
pipe_usage = PIPE_USAGE_STREAM;
break;
+ case GL_STATIC_READ:
+ case GL_DYNAMIC_READ:
+ case GL_STREAM_READ:
+ pipe_usage = PIPE_USAGE_STAGING;
+ break;
}
}
diff --git a/mesalib/src/mesa/state_tracker/st_cb_fbo.c b/mesalib/src/mesa/state_tracker/st_cb_fbo.c
index 470ab278b..7b6a444e6 100644
--- a/mesalib/src/mesa/state_tracker/st_cb_fbo.c
+++ b/mesalib/src/mesa/state_tracker/st_cb_fbo.c
@@ -451,7 +451,8 @@ st_update_renderbuffer_surface(struct st_context *st,
}
/* Adjust for texture views */
- if (strb->is_rtt) {
+ if (strb->is_rtt && resource->array_size > 1 &&
+ strb->Base.TexImage->TexObject->Immutable) {
struct gl_texture_object *tex = strb->Base.TexImage->TexObject;
first_layer += tex->MinLayer;
if (!strb->rtt_layered)
diff --git a/mesalib/src/mesa/state_tracker/st_context.c b/mesalib/src/mesa/state_tracker/st_context.c
index 768a66790..17235132e 100644
--- a/mesalib/src/mesa/state_tracker/st_context.c
+++ b/mesalib/src/mesa/state_tracker/st_context.c
@@ -242,7 +242,7 @@ st_create_context_priv( struct gl_context *ctx, struct pipe_context *pipe,
/* GL limits and extensions */
st_init_limits(st->pipe->screen, &ctx->Const, &ctx->Extensions);
- st_init_extensions(st->pipe->screen, ctx->API, &ctx->Const,
+ st_init_extensions(st->pipe->screen, &ctx->Const,
&ctx->Extensions, &st->options, ctx->Mesa_DXTn);
/* Enable shader-based fallbacks for ARB_color_buffer_float if needed. */
diff --git a/mesalib/src/mesa/state_tracker/st_extensions.c b/mesalib/src/mesa/state_tracker/st_extensions.c
index c7bc0ca50..5dd827800 100644
--- a/mesalib/src/mesa/state_tracker/st_extensions.c
+++ b/mesalib/src/mesa/state_tracker/st_extensions.c
@@ -407,7 +407,6 @@ get_max_samples_for_formats(struct pipe_screen *screen,
* Some fine tuning may still be needed.
*/
void st_init_extensions(struct pipe_screen *screen,
- gl_api api,
struct gl_constants *consts,
struct gl_extensions *extensions,
struct st_config_options *options,
@@ -715,9 +714,8 @@ void st_init_extensions(struct pipe_screen *screen,
#endif
}
- extensions->NV_primitive_restart = GL_TRUE;
- if (!screen->get_param(screen, PIPE_CAP_PRIMITIVE_RESTART)) {
- consts->PrimitiveRestartInSoftware = GL_TRUE;
+ if (screen->get_param(screen, PIPE_CAP_PRIMITIVE_RESTART)) {
+ extensions->NV_primitive_restart = GL_TRUE;
}
/* ARB_color_buffer_float. */
@@ -844,17 +842,16 @@ void st_init_extensions(struct pipe_screen *screen,
consts->DisableVaryingPacking = GL_TRUE;
}
- if (api == API_OPENGL_CORE) {
- consts->MaxViewports = screen->get_param(screen, PIPE_CAP_MAX_VIEWPORTS);
- if (consts->MaxViewports >= 16) {
- consts->ViewportBounds.Min = -16384.0;
- consts->ViewportBounds.Max = 16384.0;
- extensions->ARB_viewport_array = GL_TRUE;
- extensions->ARB_fragment_layer_viewport = GL_TRUE;
- if (extensions->AMD_vertex_shader_layer)
- extensions->AMD_vertex_shader_viewport_index = GL_TRUE;
- }
+ consts->MaxViewports = screen->get_param(screen, PIPE_CAP_MAX_VIEWPORTS);
+ if (consts->MaxViewports >= 16) {
+ consts->ViewportBounds.Min = -16384.0;
+ consts->ViewportBounds.Max = 16384.0;
+ extensions->ARB_viewport_array = GL_TRUE;
+ extensions->ARB_fragment_layer_viewport = GL_TRUE;
+ if (extensions->AMD_vertex_shader_layer)
+ extensions->AMD_vertex_shader_viewport_index = GL_TRUE;
}
+
if (consts->MaxProgramTextureGatherComponents > 0)
extensions->ARB_texture_gather = GL_TRUE;
diff --git a/mesalib/src/mesa/state_tracker/st_extensions.h b/mesalib/src/mesa/state_tracker/st_extensions.h
index 8d2724d67..faff11fd5 100644
--- a/mesalib/src/mesa/state_tracker/st_extensions.h
+++ b/mesalib/src/mesa/state_tracker/st_extensions.h
@@ -38,7 +38,6 @@ extern void st_init_limits(struct pipe_screen *screen,
struct gl_extensions *extensions);
extern void st_init_extensions(struct pipe_screen *screen,
- gl_api api,
struct gl_constants *consts,
struct gl_extensions *extensions,
struct st_config_options *options,
diff --git a/mesalib/src/mesa/state_tracker/st_glsl_to_tgsi.cpp b/mesalib/src/mesa/state_tracker/st_glsl_to_tgsi.cpp
index b338a9836..a0da9f635 100644
--- a/mesalib/src/mesa/state_tracker/st_glsl_to_tgsi.cpp
+++ b/mesalib/src/mesa/state_tracker/st_glsl_to_tgsi.cpp
@@ -1072,8 +1072,8 @@ glsl_to_tgsi_visitor::visit(ir_variable *ir)
if (ir->data.mode == ir_var_uniform && strncmp(ir->name, "gl_", 3) == 0) {
unsigned int i;
- const ir_state_slot *const slots = ir->state_slots;
- assert(ir->state_slots != NULL);
+ const ir_state_slot *const slots = ir->get_state_slots();
+ assert(slots != NULL);
/* Check if this statevar's setup in the STATE file exactly
* matches how we'll want to reference it as a
@@ -1081,7 +1081,7 @@ glsl_to_tgsi_visitor::visit(ir_variable *ir)
* temporary storage and hope that it'll get copy-propagated
* out.
*/
- for (i = 0; i < ir->num_state_slots; i++) {
+ for (i = 0; i < ir->get_num_state_slots(); i++) {
if (slots[i].swizzle != SWIZZLE_XYZW) {
break;
}
@@ -1089,7 +1089,7 @@ glsl_to_tgsi_visitor::visit(ir_variable *ir)
variable_storage *storage;
st_dst_reg dst;
- if (i == ir->num_state_slots) {
+ if (i == ir->get_num_state_slots()) {
/* We'll set the index later. */
storage = new(mem_ctx) variable_storage(ir, PROGRAM_STATE_VAR, -1);
this->variables.push_tail(storage);
@@ -1100,7 +1100,7 @@ glsl_to_tgsi_visitor::visit(ir_variable *ir)
* of the type. However, this had better match the number of state
* elements that we're going to copy into the new temporary.
*/
- assert((int) ir->num_state_slots == type_size(ir->type));
+ assert((int) ir->get_num_state_slots() == type_size(ir->type));
dst = st_dst_reg(get_temp(ir->type));
@@ -1110,7 +1110,7 @@ glsl_to_tgsi_visitor::visit(ir_variable *ir)
}
- for (unsigned int i = 0; i < ir->num_state_slots; i++) {
+ for (unsigned int i = 0; i < ir->get_num_state_slots(); i++) {
int index = _mesa_add_state_reference(this->prog->Parameters,
(gl_state_index *)slots[i].tokens);
@@ -1135,7 +1135,7 @@ glsl_to_tgsi_visitor::visit(ir_variable *ir)
}
if (storage->file == PROGRAM_TEMPORARY &&
- dst.index != storage->index + (int) ir->num_state_slots) {
+ dst.index != storage->index + (int) ir->get_num_state_slots()) {
fail_link(this->shader_program,
"failed to load builtin uniform `%s' (%d/%d regs loaded)\n",
ir->name, dst.index - storage->index,
@@ -2617,10 +2617,7 @@ glsl_to_tgsi_visitor::visit(ir_constant *ir)
case GLSL_TYPE_BOOL:
gl_type = native_integers ? GL_BOOL : GL_FLOAT;
for (i = 0; i < ir->type->vector_elements; i++) {
- if (native_integers)
- values[i].u = ir->value.b[i] ? ~0 : 0;
- else
- values[i].f = ir->value.b[i];
+ values[i].u = ir->value.b[i] ? ctx->Const.UniformBooleanTrue : 0;
}
break;
default:
diff --git a/mesalib/src/mesa/state_tracker/st_manager.c b/mesalib/src/mesa/state_tracker/st_manager.c
index 7bc33268e..df6de737f 100644
--- a/mesalib/src/mesa/state_tracker/st_manager.c
+++ b/mesalib/src/mesa/state_tracker/st_manager.c
@@ -928,7 +928,7 @@ static unsigned get_version(struct pipe_screen *screen,
_mesa_init_extensions(&extensions);
st_init_limits(screen, &consts, &extensions);
- st_init_extensions(screen, api, &consts, &extensions, options, GL_TRUE);
+ st_init_extensions(screen, &consts, &extensions, options, GL_TRUE);
return _mesa_get_version(&extensions, &consts, api);
}
diff --git a/mesalib/src/mesa/state_tracker/st_program.c b/mesalib/src/mesa/state_tracker/st_program.c
index fbf8930cb..926086bf8 100644
--- a/mesalib/src/mesa/state_tracker/st_program.c
+++ b/mesalib/src/mesa/state_tracker/st_program.c
@@ -275,17 +275,18 @@ st_prepare_vertex_program(struct gl_context *ctx,
case VARYING_SLOT_TEX5:
case VARYING_SLOT_TEX6:
case VARYING_SLOT_TEX7:
- stvp->output_semantic_name[slot] = st->needs_texcoord_semantic ?
- TGSI_SEMANTIC_TEXCOORD : TGSI_SEMANTIC_GENERIC;
- stvp->output_semantic_index[slot] = attr - VARYING_SLOT_TEX0;
- break;
-
+ if (st->needs_texcoord_semantic) {
+ stvp->output_semantic_name[slot] = TGSI_SEMANTIC_TEXCOORD;
+ stvp->output_semantic_index[slot] = attr - VARYING_SLOT_TEX0;
+ break;
+ }
+ /* fall through */
case VARYING_SLOT_VAR0:
default:
assert(attr < VARYING_SLOT_MAX);
stvp->output_semantic_name[slot] = TGSI_SEMANTIC_GENERIC;
- stvp->output_semantic_index[slot] = st->needs_texcoord_semantic ?
- (attr - VARYING_SLOT_VAR0) : (attr - VARYING_SLOT_TEX0);
+ stvp->output_semantic_index[slot] =
+ st_get_generic_varying_index(st, attr);
break;
}
}
@@ -655,9 +656,8 @@ st_translate_fragment_program(struct st_context *st,
* the user varyings on VAR0. Otherwise, we use TEX0 as base index.
*/
assert(attr >= VARYING_SLOT_TEX0);
- input_semantic_index[slot] = st->needs_texcoord_semantic ?
- (attr - VARYING_SLOT_VAR0) : (attr - VARYING_SLOT_TEX0);
input_semantic_name[slot] = TGSI_SEMANTIC_GENERIC;
+ input_semantic_index[slot] = st_get_generic_varying_index(st, attr);
if (attr == VARYING_SLOT_PNTC)
interpMode[slot] = TGSI_INTERPOLATE_LINEAR;
else
@@ -974,16 +974,18 @@ st_translate_geometry_program(struct st_context *st,
case VARYING_SLOT_TEX5:
case VARYING_SLOT_TEX6:
case VARYING_SLOT_TEX7:
- stgp->input_semantic_name[slot] = st->needs_texcoord_semantic ?
- TGSI_SEMANTIC_TEXCOORD : TGSI_SEMANTIC_GENERIC;
- stgp->input_semantic_index[slot] = (attr - VARYING_SLOT_TEX0);
- break;
+ if (st->needs_texcoord_semantic) {
+ stgp->input_semantic_name[slot] = TGSI_SEMANTIC_TEXCOORD;
+ stgp->input_semantic_index[slot] = attr - VARYING_SLOT_TEX0;
+ break;
+ }
+ /* fall through */
case VARYING_SLOT_VAR0:
default:
assert(attr >= VARYING_SLOT_VAR0 && attr < VARYING_SLOT_MAX);
stgp->input_semantic_name[slot] = TGSI_SEMANTIC_GENERIC;
- stgp->input_semantic_index[slot] = st->needs_texcoord_semantic ?
- (attr - VARYING_SLOT_VAR0) : (attr - VARYING_SLOT_TEX0);
+ stgp->input_semantic_index[slot] =
+ st_get_generic_varying_index(st, attr);
break;
}
}
@@ -1069,17 +1071,19 @@ st_translate_geometry_program(struct st_context *st,
case VARYING_SLOT_TEX5:
case VARYING_SLOT_TEX6:
case VARYING_SLOT_TEX7:
- gs_output_semantic_name[slot] = st->needs_texcoord_semantic ?
- TGSI_SEMANTIC_TEXCOORD : TGSI_SEMANTIC_GENERIC;
- gs_output_semantic_index[slot] = (attr - VARYING_SLOT_TEX0);
- break;
+ if (st->needs_texcoord_semantic) {
+ gs_output_semantic_name[slot] = TGSI_SEMANTIC_TEXCOORD;
+ gs_output_semantic_index[slot] = attr - VARYING_SLOT_TEX0;
+ break;
+ }
+ /* fall through */
case VARYING_SLOT_VAR0:
default:
assert(slot < Elements(gs_output_semantic_name));
assert(attr >= VARYING_SLOT_VAR0);
gs_output_semantic_name[slot] = TGSI_SEMANTIC_GENERIC;
- gs_output_semantic_index[slot] = st->needs_texcoord_semantic ?
- (attr - VARYING_SLOT_VAR0) : (attr - VARYING_SLOT_TEX0);
+ gs_output_semantic_index[slot] =
+ st_get_generic_varying_index(st, attr);
break;
}
}
diff --git a/mesalib/src/mesa/state_tracker/st_program.h b/mesalib/src/mesa/state_tracker/st_program.h
index 9a5b6a847..cf1b40a55 100644
--- a/mesalib/src/mesa/state_tracker/st_program.h
+++ b/mesalib/src/mesa/state_tracker/st_program.h
@@ -270,6 +270,31 @@ st_reference_fragprog(struct st_context *st,
(struct gl_program *) prog);
}
+/**
+ * This defines mapping from Mesa VARYING_SLOTs to TGSI GENERIC slots.
+ */
+static INLINE unsigned
+st_get_generic_varying_index(struct st_context *st, GLuint attr)
+{
+ if (attr >= VARYING_SLOT_VAR0) {
+ if (st->needs_texcoord_semantic)
+ return attr - VARYING_SLOT_VAR0;
+ else
+ return 9 + (attr - VARYING_SLOT_VAR0);
+ }
+ if (attr == VARYING_SLOT_PNTC) {
+ assert(!st->needs_texcoord_semantic);
+ return 8;
+ }
+ if (attr >= VARYING_SLOT_TEX0 && attr <= VARYING_SLOT_TEX7) {
+ assert(!st->needs_texcoord_semantic);
+ return attr - VARYING_SLOT_TEX0;
+ }
+
+ assert(0);
+ return 0;
+}
+
extern struct st_vp_variant *
st_get_vp_variant(struct st_context *st,
diff --git a/mesalib/src/mesa/state_tracker/st_texture.c b/mesalib/src/mesa/state_tracker/st_texture.c
index c84aa4566..5996b7d1b 100644
--- a/mesalib/src/mesa/state_tracker/st_texture.c
+++ b/mesalib/src/mesa/state_tracker/st_texture.c
@@ -88,7 +88,7 @@ st_texture_create(struct st_context *st,
pt.width0 = width0;
pt.height0 = height0;
pt.depth0 = depth0;
- pt.array_size = (target == PIPE_TEXTURE_CUBE ? 6 : layers);
+ pt.array_size = layers;
pt.usage = PIPE_USAGE_DEFAULT;
pt.bind = bind;
pt.flags = 0;
@@ -263,7 +263,8 @@ st_texture_image_map(struct st_context *st, struct st_texture_image *stImage,
if (stObj->base.Immutable) {
level += stObj->base.MinLevel;
z += stObj->base.MinLayer;
- d = MIN2(d, stObj->base.NumLayers);
+ if (stObj->pt->array_size > 1)
+ d = MIN2(d, stObj->base.NumLayers);
}
z += stImage->base.Face;
diff --git a/mesalib/src/mesa/tnl/t_vb_cliptmp.h b/mesalib/src/mesa/tnl/t_vb_cliptmp.h
index 83de16d76..7dafb83cf 100644
--- a/mesalib/src/mesa/tnl/t_vb_cliptmp.h
+++ b/mesalib/src/mesa/tnl/t_vb_cliptmp.h
@@ -41,12 +41,12 @@ do { \
GLuint idx = inlist[i]; \
GLfloat dp = CLIP_DOTPROD(idx, A, B, C, D ); \
\
- if (!IS_NEGATIVE(dpPrev)) { \
+ if (dpPrev >= 0.0f) { \
outlist[outcount++] = idxPrev; \
} \
\
if (DIFFERENT_SIGNS(dp, dpPrev)) { \
- if (IS_NEGATIVE(dp)) { \
+ if (dp < 0.0f) { \
/* Going out of bounds. Avoid division by zero as we \
* know dp != dpPrev from DIFFERENT_SIGNS, above. \
*/ \
@@ -85,15 +85,15 @@ do { \
if (mask & PLANE_BIT) { \
const GLfloat dp0 = CLIP_DOTPROD( v0, A, B, C, D ); \
const GLfloat dp1 = CLIP_DOTPROD( v1, A, B, C, D ); \
- const GLboolean neg_dp0 = IS_NEGATIVE(dp0); \
- const GLboolean neg_dp1 = IS_NEGATIVE(dp1); \
+ const GLboolean neg_dp0 = dp0 < 0.0f; \
+ const GLboolean neg_dp1 = dp1 < 0.0f; \
\
/* For regular clipping, we know from the clipmask that one \
* (or both) of these must be negative (otherwise we wouldn't \
* be here). \
* For userclip, there is only a single bit for all active \
* planes, so we can end up here when there is nothing to do, \
- * hence the second IS_NEGATIVE() test: \
+ * hence the second < 0.0f test: \
*/ \
if (neg_dp0 && neg_dp1) \
return; /* both vertices outside clip plane: discard */ \
diff --git a/mesalib/src/mesa/tnl/t_vertex.c b/mesalib/src/mesa/tnl/t_vertex.c
index 421bae2b8..90b97a092 100644
--- a/mesalib/src/mesa/tnl/t_vertex.c
+++ b/mesalib/src/mesa/tnl/t_vertex.c
@@ -543,7 +543,7 @@ void _tnl_init_vertices( struct gl_context *ctx,
vtx->codegen_emit = NULL;
#ifdef USE_SSE_ASM
- if (!_mesa_getenv("MESA_NO_CODEGEN"))
+ if (!getenv("MESA_NO_CODEGEN"))
vtx->codegen_emit = _tnl_generate_sse_emit;
#endif
}
diff --git a/mesalib/src/mesa/vbo/vbo_exec_api.c b/mesalib/src/mesa/vbo/vbo_exec_api.c
index 74aec127c..2871100ae 100644
--- a/mesalib/src/mesa/vbo/vbo_exec_api.c
+++ b/mesalib/src/mesa/vbo/vbo_exec_api.c
@@ -1067,7 +1067,7 @@ void vbo_exec_vtx_init( struct vbo_exec_context *exec )
struct gl_client_array *array;
array = &arrays[VERT_ATTRIB_FF(i)];
array->BufferObj = NULL;
- _mesa_reference_buffer_object(ctx, &arrays->BufferObj,
+ _mesa_reference_buffer_object(ctx, &array->BufferObj,
vbo->currval[VBO_ATTRIB_POS+i].BufferObj);
}
diff --git a/mesalib/src/mesa/vbo/vbo_exec_array.c b/mesalib/src/mesa/vbo/vbo_exec_array.c
index 111321bd7..045dbb506 100644
--- a/mesalib/src/mesa/vbo/vbo_exec_array.c
+++ b/mesalib/src/mesa/vbo/vbo_exec_array.c
@@ -562,38 +562,6 @@ vbo_bind_arrays(struct gl_context *ctx)
}
}
-
-/**
- * Handle a draw case that potentially has primitive restart enabled.
- *
- * If primitive restart is enabled, and PrimitiveRestartInSoftware is
- * set, then vbo_sw_primitive_restart is used to handle the primitive
- * restart case in software.
- */
-static void
-vbo_handle_primitive_restart(struct gl_context *ctx,
- const struct _mesa_prim *prim,
- GLuint nr_prims,
- const struct _mesa_index_buffer *ib,
- GLboolean index_bounds_valid,
- GLuint min_index,
- GLuint max_index)
-{
- struct vbo_context *vbo = vbo_context(ctx);
-
- if (ctx->Const.PrimitiveRestartInSoftware &&
- ctx->Array._PrimitiveRestart &&
- (ib != NULL)) {
- /* Handle primitive restart in software */
- vbo_sw_primitive_restart(ctx, prim, nr_prims, ib, NULL);
- } else {
- /* Call driver directly for draw_prims */
- vbo->draw_prims(ctx, prim, nr_prims, ib,
- index_bounds_valid, min_index, max_index, NULL, NULL);
- }
-}
-
-
/**
* Helper function called by the other DrawArrays() functions below.
* This is where we handle primitive restart for drawing non-indexed
@@ -1011,8 +979,8 @@ vbo_validated_drawrangeelements(struct gl_context *ctx, GLenum mode,
*/
check_buffers_are_unmapped(exec->array.inputs);
- vbo_handle_primitive_restart(ctx, prim, 1, &ib,
- index_bounds_valid, start, end);
+ vbo->draw_prims(ctx, prim, 1, &ib,
+ index_bounds_valid, start, end, NULL, NULL);
if (MESA_DEBUG_FLAGS & DEBUG_ALWAYS_FLUSH) {
_mesa_flush(ctx);
@@ -1372,8 +1340,8 @@ vbo_validated_multidrawelements(struct gl_context *ctx, GLenum mode,
}
check_buffers_are_unmapped(exec->array.inputs);
- vbo_handle_primitive_restart(ctx, prim, primcount, &ib,
- GL_FALSE, ~0, ~0);
+ vbo->draw_prims(ctx, prim, primcount, &ib,
+ false, ~0, ~0, NULL, NULL);
} else {
/* render one prim at a time */
for (i = 0; i < primcount; i++) {
@@ -1401,8 +1369,8 @@ vbo_validated_multidrawelements(struct gl_context *ctx, GLenum mode,
prim[0].basevertex = 0;
check_buffers_are_unmapped(exec->array.inputs);
- vbo_handle_primitive_restart(ctx, prim, 1, &ib,
- GL_FALSE, ~0, ~0);
+ vbo->draw_prims(ctx, prim, 1, &ib,
+ false, ~0, ~0, NULL, NULL);
}
}
@@ -1464,8 +1432,6 @@ vbo_draw_transform_feedback(struct gl_context *ctx, GLenum mode,
if (ctx->Driver.GetTransformFeedbackVertexCount &&
(ctx->Const.AlwaysUseGetTransformFeedbackVertexCount ||
- (ctx->Const.PrimitiveRestartInSoftware &&
- ctx->Array._PrimitiveRestart) ||
!vbo_all_varyings_in_vbos(exec->array.inputs))) {
GLsizei n = ctx->Driver.GetTransformFeedbackVertexCount(ctx, obj, stream);
vbo_draw_arrays(ctx, mode, 0, n, numInstances, 0);
diff --git a/mesalib/src/mesa/vbo/vbo_primitive_restart.c b/mesalib/src/mesa/vbo/vbo_primitive_restart.c
index 25c89669c..562dedcd5 100644
--- a/mesalib/src/mesa/vbo/vbo_primitive_restart.c
+++ b/mesalib/src/mesa/vbo/vbo_primitive_restart.c
@@ -41,8 +41,8 @@
/*
* Notes on primitive restart:
- * The code below is used when the driver does not support primitive
- * restart itself. (ctx->Const.PrimitiveRestartInSoftware == GL_TRUE)
+ * The code below is used when the driver does not fully support primitive
+ * restart (for example, if it only does restart index of ~0).
*
* We map the index buffer, find the restart indexes, unmap
* the index buffer then draw the sub-primitives delineated by the restarts.
diff --git a/mesalib/src/mesa/x86/assyntax.h b/mesalib/src/mesa/x86/assyntax.h
index fa7d92ea5..67867bda4 100644
--- a/mesalib/src/mesa/x86/assyntax.h
+++ b/mesalib/src/mesa/x86/assyntax.h
@@ -255,7 +255,7 @@
#endif /* ACK_ASSEMBLER */
-#if defined(__QNX__) || defined(Lynx) || (defined(SYSV) || defined(SVR4)) && !defined(ACK_ASSEMBLER) || defined(__ELF__) || defined(__GNU__) || defined(__GNUC__) && !defined(__DJGPP__) && !defined(__MINGW32__)
+#if defined(__QNX__) || defined(Lynx) || (defined(SYSV) || defined(SVR4)) && !defined(ACK_ASSEMBLER) || defined(__ELF__) || defined(__GNU__) || defined(__GNUC__) && !defined(__MINGW32__)
#define GLNAME(a) a
#else
#define GLNAME(a) CONCAT(_,a)
@@ -1727,9 +1727,9 @@
* If we build with gcc's -fvisibility=hidden flag, we'll need to change
* the symbol visibility mode to 'default'.
*/
-#if defined(GNU_ASSEMBLER) && !defined(__DJGPP__) && !defined(__MINGW32__) && !defined(__APPLE__)
+#if defined(GNU_ASSEMBLER) && !defined(__MINGW32__) && !defined(__APPLE__)
# define HIDDEN(x) .hidden x
-#elif defined(__GNUC__) && !defined(__DJGPP__) && !defined(__MINGW32__) && !defined(__APPLE__)
+#elif defined(__GNUC__) && !defined(__MINGW32__) && !defined(__APPLE__)
# pragma GCC visibility push(default)
# define HIDDEN(x) .hidden x
#else
diff --git a/mesalib/src/mesa/x86/common_x86.c b/mesalib/src/mesa/x86/common_x86.c
index 2a936a473..25f5c40e2 100644
--- a/mesalib/src/mesa/x86/common_x86.c
+++ b/mesalib/src/mesa/x86/common_x86.c
@@ -224,7 +224,7 @@ _mesa_get_x86_features(void)
#ifdef USE_X86_ASM
_mesa_x86_cpu_features = 0x0;
- if (_mesa_getenv( "MESA_NO_ASM")) {
+ if (getenv( "MESA_NO_ASM")) {
return;
}
@@ -307,7 +307,7 @@ _mesa_get_x86_features(void)
#ifdef USE_MMX_ASM
if ( cpu_has_mmx ) {
- if ( _mesa_getenv( "MESA_NO_MMX" ) == 0 ) {
+ if ( getenv( "MESA_NO_MMX" ) == 0 ) {
if (detection_debug)
_mesa_debug(NULL, "MMX cpu detected.\n");
} else {
@@ -318,7 +318,7 @@ _mesa_get_x86_features(void)
#ifdef USE_3DNOW_ASM
if ( cpu_has_3dnow ) {
- if ( _mesa_getenv( "MESA_NO_3DNOW" ) == 0 ) {
+ if ( getenv( "MESA_NO_3DNOW" ) == 0 ) {
if (detection_debug)
_mesa_debug(NULL, "3DNow! cpu detected.\n");
} else {
@@ -329,10 +329,10 @@ _mesa_get_x86_features(void)
#ifdef USE_SSE_ASM
if ( cpu_has_xmm ) {
- if ( _mesa_getenv( "MESA_NO_SSE" ) == 0 ) {
+ if ( getenv( "MESA_NO_SSE" ) == 0 ) {
if (detection_debug)
_mesa_debug(NULL, "SSE cpu detected.\n");
- if ( _mesa_getenv( "MESA_FORCE_SSE" ) == 0 ) {
+ if ( getenv( "MESA_FORCE_SSE" ) == 0 ) {
_mesa_check_os_sse_support();
}
} else {
diff --git a/mesalib/src/mesa/x86/read_rgba_span_x86.S b/mesalib/src/mesa/x86/read_rgba_span_x86.S
index 817729973..5def1f859 100644
--- a/mesalib/src/mesa/x86/read_rgba_span_x86.S
+++ b/mesalib/src/mesa/x86/read_rgba_span_x86.S
@@ -31,7 +31,7 @@
*/
.file "read_rgba_span_x86.S"
-#if !defined(__DJGPP__) && !defined(__MINGW32__) && !defined(__APPLE__) /* this one cries for assyntax.h */
+#if !defined(__MINGW32__) && !defined(__APPLE__) /* this one cries for assyntax.h */
/* Kevin F. Quinn 2nd July 2006
* Replaced data segment constants with text-segment instructions.
*/
@@ -671,7 +671,7 @@ _generic_read_RGBA_span_RGB565_MMX:
emms
#endif
ret
-#endif /* !defined(__DJGPP__) && !defined(__MINGW32__) && !defined(__APPLE__) */
+#endif /* !defined(__MINGW32__) && !defined(__APPLE__) */
#if defined (__ELF__) && defined (__linux__)
.section .note.GNU-stack,"",%progbits