mesa: Changes to 'master'

Brian Paul brianp at
Tue Jul 1 10:47:15 PDT 2008

The branch, master has been updated
        Commits at:

Summary of changes:
 src/mesa/shader/slang/slang_codegen.c |  128 +++++++++++++++++++++++++++------
 src/mesa/shader/slang/slang_ir.c      |    8 ++-
 2 files changed, 110 insertions(+), 26 deletions(-)

       via  32a5c4033665d51277c733318ac0461e5f85ad09 (commit)
       via  b2247c7d29667047cd34180826a8966675f8be3a (commit)
      from  011b0e51e47e52ad9e29b31b3b4de1a5b77b3768 (commit)

- Commits -----------------------------------------------
commit 32a5c4033665d51277c733318ac0461e5f85ad09
Author: Brian Paul <brian.paul at>
Date:   Tue Jul 1 11:41:21 2008 -0600

    mesa: better function inlining in the presence of 'return' statements
    Before, the presence of a 'return' statement always prevented inlining
    a function.  This was because we didn't want to accidentally return from
    the _calling_ function.  We still need the semantic of 'return' when inlining
    but we can't always use unconditional branches/jumps (GPUs don't always
    support arbitrary branching).
    Now, we allow inlining functions w/ return if the return is the last
    statement in the function.  This fixes the common case of a function
    that returns a value, such as:
    vec4 square(const in vec4 x)
       return x * x;
    which effectively compiles into:
    vec4 square(const in vec4 x)
       __retVal = x * x;
    The 'return' can be no-op'd now and we can inline the function.

commit b2247c7d29667047cd34180826a8966675f8be3a
Author: Brian Paul <brian.paul at>
Date:   Tue Jul 1 11:41:02 2008 -0600

    mesa: add/fix some IrInfo entries for debugging purposes


More information about the mesa-commit mailing list