summaryrefslogtreecommitdiffstats
path: root/src/mesa/shader/slang
Commit message (Collapse)AuthorAgeFilesLines
* Implement true CAL/RET subroutines. Some optimizations, clean-ups coming...Brian2007-03-272-19/+162
|
* added _slang_label_new_unique()Brian2007-03-272-0/+24
|
* Checkpoint: implementing true CAL/RET instructions for subroutine calls.Brian2007-03-264-13/+92
| | | | | | Also, found/fixed a code generation regression: the emit_swizzle() function was always returning NULL. This caused emit_move() to miss its chance at peephole optimization.
* Get rid of IR_JUMP and related code.Brian2007-03-263-25/+2
|
* Get rid of SLANG_OPER_GOTO, start rewrite of 'return' handling.Brian2007-03-264-56/+65
|
* remove debug abort() callsBrian2007-03-264-14/+10
|
* Additional error checking for 'return' statements.Brian2007-03-263-9/+58
|
* undo some debugging hacksBrian2007-03-261-2/+2
|
* dead code elimination for constant-valued if/then/elseBrian2007-03-261-0/+13
|
* Fix a few issues with computing storage sizes with respect to swizzles.Brian2007-03-262-42/+29
|
* remove incorrect assertionsBrian2007-03-261-2/+0
|
* disable printing shader program debug infopost-merge-glsl-compiler-1Brian2007-03-261-4/+4
|
* disable free() until other issues can be fixed...Brian2007-03-261-0/+2
|
* fix mem leakBrian2007-03-241-7/+3
|
* disable free(var->aux) -- can lead to segfaultBrian2007-03-241-0/+2
|
* fix mem leakBrian2007-03-241-0/+3
|
* fix some mem leaksBrian2007-03-241-6/+9
|
* fix mistake in _slang_free_ir()Brian2007-03-241-1/+1
|
* Properly free the slang_ir_node->Store data (use ref counting).Brian2007-03-242-12/+46
|
* move some code into new slang_ir.c fileBrian2007-03-243-334/+29
|
* IR utility functionsBrian2007-03-241-0/+354
|
* Fix issues related to the 'continue' statement.Brian2007-03-233-52/+126
| | | | | | | | IR_LOOP now has two children: the body code, and the tail code. Tail code is the "i++" part of a for-loop, or the expression at the end of a "do {} while(expr);" loop. "continue" translates into: "execute tail code; CONT;" Also, the test for infinite do/while loops was incorrect.
* Add the ability to generate programs that doesn't use condition codes.Brian2007-03-231-37/+86
| | | | | | | ctx->Shader.EmitCondCodes determines if we use condition codes. If not, IF statement uses first operand's X component as the condition. Added OPCODE_BRK0, OPCODE_BRK1, OPCODE_CONT0, OPCODE_CONT1 to handle the common cases of conditional break/continue.
* minor tweaksBrian2007-03-231-2/+2
|
* updated commentBrian2007-03-231-1/+1
|
* Overhaul emit_compare() function.Brian2007-03-223-36/+143
| | | | | | | | Previously, comparing vec2, vec3, vec4 was broken. Added IR_EQUAL, IR_NOTEQUAL nodes/operators to compute boolean equality/inequality vs. IR_SEQUAL/IR_SNEQUAL which work component-wise. Use IR_EQUAL/IR_NOTEQUAL for the == and != operators. To compute vec4 equality, use SNE, DP4, SEQ instruction sequence.
* First pass at implementing structure compares.Brian2007-03-221-9/+28
| | | | | Need to improve this. There may be holes in a structure so we can't just blindly compare the full 4-float registers.
* In _mesa_add_unnamed_constant() and _mesa_lookup_parameter_constant() allow ↵Brian2007-03-221-2/+2
| | | | | | | | swizzleOut==NULL. There are times when we don't want to allow swizzling when searching for or adding vector constants. Passing NULL for swizzleOut disables swizzling. This fixes a constant/swizzle bug in link_uniform_vars().
* Support for user-defined structures.Brian2007-03-213-23/+119
| | | | struct == and != operators not finished yet. Struct assignment works though.
* disable apparently unused codeBrian2007-03-212-0/+4
|
* indentBrian2007-03-211-107/+111
|
* s/Tranpose/Transpose/Brian2007-03-141-4/+4
|
* continue prev check-in: save ptr to slang_function for SLANG_OPER_CALLBrian2007-03-141-5/+13
|
* After we've found the slang_function ptr for a SLANG_OPER_CALL node, save ↵Brian2007-03-142-62/+76
| | | | | | | | the ptr in the node for reuse. This can save a tremendous amount of time when resolving types in complex expressions. One particular shader was taking several minutes to compile but now compiles almost instantaneoulsy.
* make _slang_typeof_function() staticBrian2007-03-142-40/+28
|
* remove old assertionBrian2007-03-141-1/+0
|
* Check for, simplify vec2/3/4(x). Only do call adapting for constructors.Brian2007-03-131-3/+25
|
* improve literal printingBrian2007-03-131-8/+13
|
* disable some debug outputBrian2007-03-131-1/+1
|
* better error msg for undefined function, disable some debug outputBrian2007-03-131-6/+9
|
* get rid of float_multiply, float_add, float_divideBrian2007-03-133-6/+3
|
* Shuffle some code around in the emit_tex() and emit_move() instructions.Brian2007-03-131-9/+16
| | | | | | | Note that the inst ptr returned by new_instruction() may become invalid after calling emit_() since the emit functions may allocate new instructions which is done vial realloc(). Also, add some new assertions to try to catch this kind of bug.
* Implement GL_ARB_texture_rectangle supportBrian2007-03-1211-44/+141
| | | | | This includes the sampler2DRect and sampler2DRectShadow types and the texture2DRect(), texture2DRectProj(), etc. built-in functions.
* Add array bounds checking, fix memleaks, add null ptr checks.Brian2007-03-121-4/+29
|
* add NULL ptr checkBrian2007-03-111-6/+9
|
* Implement support for GL_ARB_draw_buffers with GL_MAX_DRAW_BUFFERS > 1.Brian2007-03-111-0/+1
| | | | | | GL_MAX_DRAW_BUFFERS is currently 4. Added gl_FragData[] output for fragment programs. In _swrast_write_rgba_span() loop over the color outputs/renderbuffers.
* Implement gl_FrontFacing for fragment shaders.Brian2007-03-101-24/+36
| | | | | | For the time being, we put the gl_FrontFacing value in the FOGC.Y input register. Combining FOGC and FrontFacing in one register is a bit of a hack and may need to be changed someday.
* add NULL ptr check in emit_cond()Brian2007-03-101-2/+6
|
* use gl_ModelViewProjectionMatrixTranspose in ftransform()Brian2007-03-092-71/+71
|
* add NULL ptr checkBrian2007-03-091-0/+2
|