Re: [Mesa-dev] [PATCH 18/21] glsl: Write a new built-in function module.

2013-09-09 Thread Matt Turner
On Wed, Sep 4, 2013 at 3:22 PM, Kenneth Graunke kenn...@whitecape.org wrote: +static bool +texture_query_lod(const _mesa_glsl_parse_state *state) +{ + return state-target == fragment_shader + (state-is_version(400, 0) || state-ARB_texture_query_lod_enable); +} Reminder about the

Re: [Mesa-dev] [PATCH 18/21] glsl: Write a new built-in function module.

2013-09-09 Thread Kenneth Graunke
On 09/09/2013 10:39 AM, Matt Turner wrote: On Wed, Sep 4, 2013 at 3:22 PM, Kenneth Graunke kenn...@whitecape.org wrote: +static bool +texture_query_lod(const _mesa_glsl_parse_state *state) +{ + return state-target == fragment_shader + (state-is_version(400, 0) ||

Re: [Mesa-dev] [PATCH 18/21] glsl: Write a new built-in function module.

2013-09-08 Thread Paul Berry
On 4 September 2013 15:22, Kenneth Graunke kenn...@whitecape.org wrote: This creates a new replacement for the existing built-in function code. The new module lives in builtin_functions.cpp (not builtin_function.cpp) and exists in parallel with the existing system. It isn't used yet. The

Re: [Mesa-dev] [PATCH 18/21] glsl: Write a new built-in function module.

2013-09-08 Thread Kenneth Graunke
On 09/08/2013 09:57 AM, Paul Berry wrote: On 4 September 2013 15:22, Kenneth Graunke kenn...@whitecape.org mailto:kenn...@whitecape.org wrote: This creates a new replacement for the existing built-in function code. The new module lives in builtin_functions.cpp (not

Re: [Mesa-dev] [PATCH 18/21] glsl: Write a new built-in function module.

2013-09-05 Thread Pohjolainen, Topi
On Wed, Sep 04, 2013 at 03:22:41PM -0700, Kenneth Graunke wrote: This creates a new replacement for the existing built-in function code. The new module lives in builtin_functions.cpp (not builtin_function.cpp) and exists in parallel with the existing system. It isn't used yet. The new

Re: [Mesa-dev] [PATCH 18/21] glsl: Write a new built-in function module.

2013-09-05 Thread Pohjolainen, Topi
On Wed, Sep 04, 2013 at 03:22:41PM -0700, Kenneth Graunke wrote: This creates a new replacement for the existing built-in function code. The new module lives in builtin_functions.cpp (not builtin_function.cpp) and exists in parallel with the existing system. It isn't used yet. The new

Re: [Mesa-dev] [PATCH 18/21] glsl: Write a new built-in function module.

2013-09-05 Thread Pohjolainen, Topi
On Thu, Sep 05, 2013 at 02:27:04PM +0300, Pohjolainen, Topi wrote: On Wed, Sep 04, 2013 at 03:22:41PM -0700, Kenneth Graunke wrote: This creates a new replacement for the existing built-in function code. The new module lives in builtin_functions.cpp (not builtin_function.cpp) and exists in

Re: [Mesa-dev] [PATCH 18/21] glsl: Write a new built-in function module.

2013-09-05 Thread Kenneth Graunke
On 09/05/2013 04:20 AM, Pohjolainen, Topi wrote: On Wed, Sep 04, 2013 at 03:22:41PM -0700, Kenneth Graunke wrote: [snip] +/** + * builtin_builder: A singleton object representing the core of the built-in + * function module. + * + * It has code to generate + * It generates IR for every

Re: [Mesa-dev] [PATCH 18/21] glsl: Write a new built-in function module.

2013-09-04 Thread Erik Faye-Lund
On Thu, Sep 5, 2013 at 12:22 AM, Kenneth Graunke kenn...@whitecape.org wrote: +#define B0(X) ir_function_signature *_##X(); +#define B1(X) ir_function_signature *_##X(const glsl_type *); +#define B2(X) ir_function_signature *_##X(const glsl_type *, const glsl_type *); +#define B3(X)

Re: [Mesa-dev] [PATCH 18/21] glsl: Write a new built-in function module.

2013-09-04 Thread Kenneth Graunke
On 09/04/2013 04:36 PM, Erik Faye-Lund wrote: On Thu, Sep 5, 2013 at 12:22 AM, Kenneth Graunke kenn...@whitecape.org wrote: +#define B0(X) ir_function_signature *_##X(); +#define B1(X) ir_function_signature *_##X(const glsl_type *); +#define B2(X) ir_function_signature *_##X(const glsl_type *,