aboutsummaryrefslogtreecommitdiffstats
path: root/src/mesa/shader/slang/slang_compile.c
Commit message (Collapse)AuthorAgeFilesLines
* mesa: Handle FEATURE_es2_glsl differences at runtime tooKristian Høgsberg2010-05-241-8/+17
| | | | | | | Now that we can support different APIs at runtime, we need to check the context for the API we're currently providing as well. https://bugs.freedesktop.org/show_bug.cgi?id=28194
* Replace _mesa_strtod with _mesa_strtof.Marcin Baczyński2010-03-151-2/+2
| | | | Reviewed-by: Ian Romanick <[email protected]>
* glsl: implement support for GL_EXT_texture_arrayBrian Paul2010-02-251-11/+33
| | | | | | | | GL_EXT_texture_array is different from the existing GL_MESA_texture_array support in that the former is only supported for GLSL, not fixed-function. The shadow compare versions of the sampler functions haven't been tested yet. The non-shadow versions have been tested with a new piglit test.
* Replace _mesa_malloc, _mesa_calloc and _mesa_free with plain libc versionsKristian Høgsberg2010-02-191-1/+1
|
* Remove _mesa_strncmp in favor of plain strncmp.Kenneth Graunke2010-02-191-1/+1
|
* Remove _mesa_strcmp in favor of plain strcmp.Kenneth Graunke2010-02-191-2/+1
|
* Remove _mesa_strlen in favor of plain strlen.Kenneth Graunke2010-02-191-5/+5
|
* mesa: Fix compiler warningsKarl Schultz2010-02-131-1/+1
| | | | | Add explicit casts, fix constant types, fix variable types. Fixes about 340 warnings in MSFT Visual Studio.
* glsl: implement layout qualifiersBrian Paul2010-02-131-19/+110
| | | | | | | | | | | | | For GL_ARB_fragment_coord_conventions. This only applies to gl_FragCoord and controls pixel center origin and pixel center integer. For example: layout (origin_upper_left, pixel_center_integer) varying vec4 gl_FragCoord; This features introduces the idea of re-declaring variables with a changed type. This may also apply to arrays in some cases but that's not implemented at this time.
* Simplify GLSL extension mechanism.Michal Krol2010-02-101-2/+2
| | | | | Since extension name and extension name string are the same, collapse them into one name.
* glsl: GLSL extensions have the GL_ prefixBrian Paul2010-02-101-2/+2
| | | | | | | | | Both the #extension directive name and the preprocessor symbol start with the GL_ prefix. For example: ... New glean/glsl1 tests have been added to test the #extension feature.
* Merge branch 'mesa_7_7_branch'Brian Paul2010-01-221-3/+0
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: src/gallium/auxiliary/draw/draw_context.c src/gallium/auxiliary/draw/draw_pt_fetch_shade_pipeline.c src/gallium/auxiliary/pipebuffer/Makefile src/gallium/auxiliary/pipebuffer/SConscript src/gallium/auxiliary/pipebuffer/pb_buffer_fenced.c src/gallium/auxiliary/tgsi/tgsi_scan.c src/gallium/drivers/i915/i915_surface.c src/gallium/drivers/i915/i915_texture.c src/gallium/drivers/llvmpipe/lp_setup.c src/gallium/drivers/llvmpipe/lp_tex_sample_c.c src/gallium/drivers/llvmpipe/lp_texture.c src/gallium/drivers/softpipe/sp_prim_vbuf.c src/gallium/state_trackers/xorg/xorg_dri2.c src/gallium/winsys/drm/intel/gem/intel_drm_api.c src/gallium/winsys/drm/nouveau/drm/nouveau_drm_api.c src/gallium/winsys/drm/radeon/core/radeon_drm.c src/gallium/winsys/drm/vmware/core/vmw_screen_dri.c src/mesa/state_tracker/st_cb_clear.c
| * glsl: Remove unnecessary headers from slang_compile.c.Vinson Lee2010-01-161-3/+0
| |
* | Merge branch 'mesa_7_7_branch'Brian Paul2009-12-311-0/+3
|\| | | | | | | | | | | | | | | Conflicts: configs/darwin src/gallium/auxiliary/util/u_clear.h src/gallium/state_trackers/xorg/xorg_exa_tgsi.c src/mesa/drivers/dri/i965/brw_draw_upload.c
| * glsl: added uniform initializer checkBrian Paul2009-12-291-0/+3
| | | | | | | | | | | | | | | | | | GLSL 1.10 disallows initializers for uniforms but GLSL 1.20 and later allows them. This patch uses the #version directive to allow/disallow uniform initializers. This addresses bug 25807, but piglit also needs to be fixed to specify the GLSL version in the shader.
* | glsl: assorted clean-ups in slang_compile.cBrian Paul2009-12-211-36/+9
| |
* | Merge branch 'mesa_7_7_branch'Brian Paul2009-12-211-11/+13
|\| | | | | | | | | | | Conflicts: src/mesa/main/version.h src/mesa/state_tracker/st_atom_shader.c
| * Merge branch 'mesa_7_6_branch' into mesa_7_7_branchBrian Paul2009-12-211-11/+13
| |\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: configure.ac progs/demos/morph3d.c progs/demos/textures.c progs/glsl/shtest.c progs/glsl/texaaline.c progs/tests/packedpixels.c progs/xdemos/corender.c src/mesa/main/version.h
| | * glsl: clear out shader code before compilingBrian Paul2009-12-181-11/+13
| | | | | | | | | | | | | | | | | | | | | When we start compiling a shader, first free the existing gl_program. This (mostly) fixes the piglit glsl-reload-source test. Without this change, we were actually appending the new GPU code onto the previous program.
* | | slang: Update after glsl cl interface changes.Michal Krol2009-12-201-77/+0
| | |
* | | slang: Update after glsl pp changes.Michal Krol2009-12-201-22/+11
| | |
* | | Merge branch 'master' into glsl-pp-rework-2Michal Krol2009-12-121-0/+10
|\| | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: progs/perf/drawoverhead.c progs/perf/teximage.c progs/perf/vbo.c progs/perf/vertexrate.c src/mesa/shader/slang/library/slang_common_builtin_gc.h
| * | mesa: added nopfrag/nopvert options for MESA_GLSLBrian Paul2009-09-291-0/+10
| |/ | | | | | | | | These options can be used to force vertex/fragment shaders to be no-op shaders (actually, simple pass-through shaders). For debug/test purposes.
* | slang: Predefine ES symbols for FEATURE_es2_glsl.Michal Krol2009-12-101-0/+9
| |
* | slang: Explicitly enable ARB_draw_buffers and ARB_texture_rectangle.Michal Krol2009-12-101-0/+7
| | | | | | | | They are no longer built into the glsl preprocessor.
* | slang: Fix order of parameters to sl_pp_tokenise().Michal Krol2009-11-231-1/+1
| |
* | slang: No need to purify source text for tokeniser.Michal Krol2009-11-211-12/+2
| |
* | slang: Report syntax parser errors.Michal Krol2009-11-131-5/+10
| |
* | slang: Get rid of the old syntax file and utilities.Michal Krol2009-11-131-4/+0
| |
* | slang: Plug in the new syntax parser.Michal Krol2009-11-131-57/+58
| |
* | slang: Update for glsl/pp interface changes.Michal Krol2009-11-101-2/+4
| |
* | slang: Differentiate between uints and floats.Michal Krol2009-09-221-1/+2
| |
* | slang: Use glsl pp public interface.Michal Krol2009-09-181-18/+16
| |
* | slang: Propagate error messages from preprocessor.Michal Krol2009-09-161-0/+5
| |
* | slang: Invoke the preprocessor from withing the slang compiler.Michal Krol2009-09-161-9/+122
| | | | | | | | This allows us to validate the shader version number.
* | slang: Correctly parse numbers from the new preprocessor.Michal Krol2009-09-081-34/+119
| |
* | slang: Remove the old preprocessor.Michal Krol2009-09-081-17/+3
|/
* glsl: added slang_assemble_ctx::EmitContReturn field, initBrian Paul2009-06-261-0/+3
|
* Avoid a segfault in shader compilationRobert Ellison2009-04-271-0/+6
| | | | | | | | | | If a shader reaches an out-of-memory condition while adding a new function (reallocating the function list), a segfault will occur during cleanup (because the num_functions field is non-zero, but the functions pointer is NULL). This fixes that segfault by zeroing out the num_functions field if reallocation fails.
* glsl: don't optimize program if MESA_GLSL=noptBrian Paul2009-04-071-1/+2
|
* glsl: implement compiling/linking of separate compilation unitsBrian Paul2009-04-011-0/+2
| | | | | | | | | A shader program may consist of multiple shaders (source code units). If we find there are unresolved functions after compiling the unit that defines main(), we'll concatenate all the respective vertex or fragment shaders then recompile. This isn't foolproof but should work in most cases.
* slang: initialize the contextAlan Hourihane2009-03-191-2/+3
|
* glsl: change GLSL #pragma initializationBrian Paul2009-03-191-1/+3
| | | | | | Initialize the shader's pragma settings before calling the compiler. Added pragma "Ignore" fields to allow overriding the #pragma directives found in shader source code.
* glsl: call the program optimizerBrian Paul2009-03-061-0/+5
| | | | This still needs more testing bug glean and Mesa GLSL tests seem OK.
* glsl: silence some uninit var warningsBrian Paul2009-02-161-1/+1
|
* glsl: new MESA_GLSL env var for GLSL debugging featuresBrian Paul2009-02-061-3/+3
| | | | | | Replaces the VERBOSE_GLSL, VERBOSE_GLSL_DUMP flags which only worked in debug builds. MESA_GLSL will work both in debug and non-debug builds. Also add facility to dump glUniform() calls to stdout.
* Revert "mesa: meaningless whitespace change to see if git's working (ignore)"Brian Paul2009-02-061-15/+3
| | | | | | This reverts commit b2e779988eeb595187933fe2122d86f8ccfe059c. I didn't mean to push this stuff yet. I'm having a bad git day...
* mesa: meaningless whitespace change to see if git's working (ignore)Brian Paul2009-02-061-3/+15
|
* glsl: call _mesa_write_shader_to_file(). Debug-only, disabledBrian Paul2009-01-221-0/+4
|
* glsl: set shader->CompileStatus in _slang_compile()Brian Paul2009-01-221-0/+2
|