summaryrefslogtreecommitdiff
Commit message (Collapse)AuthorAgeFilesLines
* glsl: move/simplify error checking for 'return' statementsglsl-continue-returnBrian Paul2009-06-261-22/+14
|
* glsl: overhaul 'return' statement handlingBrian Paul2009-06-263-215/+212
| | | | | | | A new node type (SLANG_OPER_RETURN_INLINED) is used to denote 'return' statements inside inlined functions which need special handling. All glean glsl1 tests pass for EmitContReturn=FALSE and TRUE.
* glsl: predicate assignments according to __returnFlagBrian Paul2009-06-251-4/+29
| | | | Fixes glean "function with early return (3)" case (when EmitContReturn=FALSE).
* glsl: added slang_variable::is_global fieldBrian Paul2009-06-251-0/+1
|
* glsl: silence a problem warningBrian Paul2009-06-251-1/+2
|
* glsl: code refactoring for return statementsBrian Paul2009-06-251-70/+88
|
* glsl: fix assorted regressions related to early-return-removalBrian Paul2009-06-252-14/+35
|
* glsl: comments, field reorderingBrian Paul2009-06-251-1/+4
|
* glsl: rework loop nesting codeBrian Paul2009-06-252-41/+87
|
* glsl: remove test for loop unrolling when we hit conditional cont/breakBrian Paul2009-06-251-4/+0
| | | | | This is no longer needed since we added the new _slang_loop_contains_continue_or_break() function/test.
* glsl: checkpoint: predicate __retVal = expr with __returnFlagBrian Paul2009-06-241-26/+60
| | | | The glean "function with early return (1)" test passes now.
* glsl: use new helper functions in _slang_gen_logical_and/or()Brian Paul2009-06-241-15/+9
|
* glsl: add commentsBrian Paul2009-06-241-0/+3
|
* glsl: checkpoint: replace 'return' with __returnFlag=true;Brian Paul2009-06-241-7/+68
| | | | Needed for "remove early returns" transformation.
* glsl: fix up scoping for parent/children in slang_operation_copy()Brian Paul2009-06-241-0/+9
| | | | This will need more testing, but no regressions seen so far.
* glsl: fix uninitialized var in _slang_gen_for_without_continue()Brian Paul2009-06-241-1/+1
|
* glsl: added slang_operation_free_children()Brian Paul2009-06-242-0/+17
|
* glsl: added slang_oper_num_children() helperBrian Paul2009-06-241-0/+7
|
* glsl: check-point: declare _returnFlagBrian Paul2009-06-241-0/+33
|
* glsl: added slang_operation_insert_child()Brian Paul2009-06-232-0/+23
|
* glsl: use slang_generate_declaration() to consolidate some codeBrian Paul2009-06-231-31/+37
|
* glsl: remove obsolete commentBrian Paul2009-06-231-3/+0
|
* st/mesa: query PIPE_CAP_TGSI_CONT_SUPPORTEDBrian Paul2009-06-231-0/+5
|
* gallium: added PIPE_CAP_TGSI_CONT_SUPPORTED queryBrian Paul2009-06-234-0/+7
| | | | | Does the driver support TGSI_OPCODE_CONT? If not, the GLSL compiler will generate code such that 'continue' statements are converted into 'breaks'.
* glsl: implement _slang_gen_while_without_continue()Brian Paul2009-06-231-82/+115
|
* glsl: fix a bug involving 'continue' in 'for' loopsBrian Paul2009-06-232-23/+44
| | | | | | | | Need to execute the for loop's increment code before we continue. Add a slang_assemble_ctx::CurLoopOper field to keep track of the containing loop and avoid the "cont if true" path in this situation. Plus, assorted clean-ups.
* glsl: added slang_oper_child_const()Brian Paul2009-06-231-0/+8
|
* glsl: use _slang_loop_contains_continue_or_break() to check for unrollingBrian Paul2009-06-231-5/+36
| | | | The previous test failed for nested loops.
* glsl: use new _slang_loop_contains_continue() helper functionBrian Paul2009-06-181-5/+126
|
* glsl: implement continue->break translation for do-while loopsBrian Paul2009-06-181-15/+219
|
* glsl: added slang_operation_literal_int/bool() helper functionsBrian Paul2009-06-181-0/+26
|
* glsl: don't allocate 0-length children array in slang_operation_copy()Brian Paul2009-06-181-6/+7
|
* glsl: remove debug code, misc clean-upBrian Paul2009-06-181-5/+0
|
* glsl: implement continue->break transformation for for-loopsBrian Paul2009-06-181-3/+167
|
* glsl: added slang_operation_add_children() and slang_oper_child() helpersBrian Paul2009-06-182-0/+25
|
* glsl: added slang_assemble_ctx::EmitContReturn field, initBrian Paul2009-06-182-0/+4
|
* demos: improve argv parsing in fslight.cBrian Paul2009-06-181-2/+6
|
* glsl: don't unroll loops containing continue/breakBrian Paul2009-06-171-0/+6
| | | | Just search the AST in _slang_can_unroll_for_loop().
* Revert "slang: if/else/break & if/else/continue work for unrolled loops"Brian Paul2009-06-172-38/+7
| | | | | | | | | | | We should just check if the loop contains a continue/break in the _slang_can_unroll_for_loop() test function... This reverts commit 989856bde47d699d7e18798df4013fbf962e1d4b. Conflicts: src/mesa/shader/slang/slang_codegen.h
* glsl: Added gl_shader_state::EmitContReturn fieldBrian Paul2009-06-172-0/+2
| | | | | | | This is the start of a glsl-continue-return feature branch to support a GLSL code generator option for 'continue' and 'return' statements. Some targets don't support CONT or RET statements so we'll need to try to generate code that does not use them...
* glsl: call _mesa_postprocess_program(), disabledBrian Paul2009-06-171-0/+8
|
* mesa: silence warningBrian Paul2009-06-171-0/+2
|
* mesa: added _mesa_postprocess_program() to aid shader debuggingBrian Paul2009-06-172-0/+60
|
* radeon: Flush command buffer on viewport changeJerome Glisse2009-06-171-0/+1
| | | | | | We flush the command buffer so we don't emit mixed state (with new and previous buffer size) command buffer, this is especialy affecting zbuffer states.
* r300: don't emit vap index offset on r5xx hw when using csJerome Glisse2009-06-171-1/+1
| | | | | | | vap index offset is programmed to 0 by the kernel, it would add work to kernel checker to allow userspace programming of this so it's now disallowed with CS on KMS.
* GLX: attempt to fix glean makeCurrent test cases.Dave Airlie2009-06-172-2/+6
| | | | | | | | | | | Two parts to this: One we don't keep pointers to possibly freed memory anymore once we unbind the drawables from the context. Brian I need to figure out what the comment you made there, can we get a glean/piglit test so we can fix it properly? If the new gc is the same as the oldGC, we call the unbind even though we just bound it in that function. doh.
* radeon: fix warnings in wrapper with libdrmDave Airlie2009-06-171-15/+15
|
* Merge branch 'mesa_7_5_branch'Brian Paul2009-06-1626-105/+215
|\ | | | | | | | | | | Conflicts: src/mesa/main/api_validate.c
| * i965: fix bugs in projective texture coordinatesBrian Paul2009-06-165-20/+54
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | For the TXP instruction we check if the texcoord is really a 4-component atttibute which requires the divide by W step. This check involved the projtex_mask field. However, the projtex_mask field was being miscalculated because of some confusion between vertex program outputs and fragment program inputs. 1. Rework the size_masks calculation so we correctly set bits corresponding to fragment program input attributes. 2. Rename projtex_mask to proj_attrib_mask since we're interested in more than just texcoords (generic varying vars too). 3. Simply the indexing of the size_masks and proj_attrib_mask fields. 4. The tracker::active[] array was mis-dimensioned. Use MAX_PROGRAM_TEMPS instead of a magic number. 5. Update comments, add new assertions. With these changes the Lightsmark demo/benchmark renders correctly, until we eventually hit a GPU lockup...
| * softpipe: fix out of bounds quad rasterization bugBrian Paul2009-06-161-3/+6
| | | | | | | | | | | | | | | | For some triangles we can generate quads which lie just outside the surface bounds. Just check the quad's mask before trying to emit/process the quad. Fixes failed assertion in Lightsmark.