gallium: add shader cap for dldexp/dfracexp support
authorIlia Mirkin <imirkin@alum.mit.edu>
Fri, 25 Jul 2014 21:48:01 +0000 (17:48 -0400)
committerIlia Mirkin <imirkin@alum.mit.edu>
Fri, 20 Feb 2015 00:32:52 +0000 (19:32 -0500)
Signed-off-by: Ilia Mirkin <imirkin@alum.mit.edu>
Reviewed-by: Dave Airlie <airlied@redhat.com>
src/gallium/auxiliary/gallivm/lp_bld_limits.h
src/gallium/auxiliary/tgsi/tgsi_exec.h
src/gallium/docs/source/screen.rst
src/gallium/drivers/nouveau/nvc0/nvc0_screen.c
src/gallium/drivers/r600/r600_pipe.c
src/gallium/drivers/radeonsi/si_pipe.c
src/gallium/drivers/svga/svga_screen.c
src/gallium/include/pipe/p_defines.h

index 1af720504a1b86690108ebbd14ea445dff673641..296236006bc1c79172e89122b987dce4cc4c2c75 100644 (file)
@@ -128,6 +128,7 @@ gallivm_get_shader_param(enum pipe_shader_cap param)
       return 1;
    case PIPE_SHADER_CAP_DOUBLES:
    case PIPE_SHADER_CAP_TGSI_DROUND_SUPPORTED:
+   case PIPE_SHADER_CAP_TGSI_DFRACEXP_DLDEXP_SUPPORTED:
       return 0;
    }
    /* if we get here, we missed a shader cap above (and should have seen
index 02ee4c726c04ec3ffdb03f85edef627469b2f767..609c81b1d472516feb3cb2acd6fc67c9da0890c9 100644 (file)
@@ -456,6 +456,7 @@ tgsi_exec_get_shader_param(enum pipe_shader_cap param)
    case PIPE_SHADER_CAP_TGSI_SQRT_SUPPORTED:
       return 1;
    case PIPE_SHADER_CAP_DOUBLES:
+   case PIPE_SHADER_CAP_TGSI_DFRACEXP_DLDEXP_SUPPORTED:
       return 1;
    case PIPE_SHADER_CAP_TGSI_DROUND_SUPPORTED:
       return 0;
index 0cb5425bc8534a991f01b32fb4734582b97a5dff..e0fd1a2dbac391f01de55ff65a0ed7da0f89d47c 100644 (file)
@@ -334,6 +334,8 @@ to be 0.
   operations are supported.
 * ``PIPE_SHADER_CAP_TGSI_DROUND_SUPPORTED``: Whether double precision rounding
   is supported. If it is, DTRUNC/DCEIL/DFLR/DROUND opcodes may be used.
+* ``PIPE_SHADER_CAP_TGSI_DFRACEXP_DLDEXP_SUPPORTED``: Whether DFRACEXP and
+  DLDEXP are supported.
 
 
 .. _pipe_compute_cap:
index 868491ce34a036b51855a2b93f50f094d833938f..8546ac8e5c09e1fdb0497e9d36959f54e476217a 100644 (file)
@@ -294,6 +294,8 @@ nvc0_screen_get_shader_param(struct pipe_screen *pscreen, unsigned shader,
       return 0;
    case PIPE_SHADER_CAP_TGSI_DROUND_SUPPORTED:
       return 0;
+   case PIPE_SHADER_CAP_TGSI_DFRACEXP_DLDEXP_SUPPORTED:
+      return 0;
    case PIPE_SHADER_CAP_MAX_TEXTURE_SAMPLERS:
       return 16; /* would be 32 in linked (OpenGL-style) mode */
    case PIPE_SHADER_CAP_MAX_SAMPLER_VIEWS:
index 447513b5981b66abbd2a5168246799ece3e7d201..06dca25924ae508ac0c500af6534d0c06cc06128 100644 (file)
@@ -490,6 +490,7 @@ static int r600_get_shader_param(struct pipe_screen* pscreen, unsigned shader, e
        case PIPE_SHADER_CAP_DOUBLES:
                return 0;
        case PIPE_SHADER_CAP_TGSI_DROUND_SUPPORTED:
+       case PIPE_SHADER_CAP_TGSI_DFRACEXP_DLDEXP_SUPPORTED:
                return 0;
        }
        return 0;
index 4c720458842da5fdc26934bf6ef25f59413b78f9..f8fd3fa767e29fec9518addb163442c107f25efa 100644 (file)
@@ -424,6 +424,7 @@ static int si_get_shader_param(struct pipe_screen* pscreen, unsigned shader, enu
                return PIPE_SHADER_IR_TGSI;
        case PIPE_SHADER_CAP_DOUBLES:
        case PIPE_SHADER_CAP_TGSI_DROUND_SUPPORTED:
+       case PIPE_SHADER_CAP_TGSI_DFRACEXP_DLDEXP_SUPPORTED:
                return 0;
        }
        return 0;
index a951792ef694c449dbe965f3ebba5f1bd75116fe..2f2ee2ac3d7af6b4576d603fa7652b99c00f9e8a 100644 (file)
@@ -374,6 +374,7 @@ static int svga_get_shader_param(struct pipe_screen *screen, unsigned shader, en
          return PIPE_SHADER_IR_TGSI;
       case PIPE_SHADER_CAP_DOUBLES:
       case PIPE_SHADER_CAP_TGSI_DROUND_SUPPORTED:
+      case PIPE_SHADER_CAP_TGSI_DFRACEXP_DLDEXP_SUPPORTED
          return 0;
       }
       /* If we get here, we failed to handle a cap above */
index 685e37cefcb19fc244e12514748cd19d86850cfe..ae173b3c2affb9ef117aad63ed5bd79543066216 100644 (file)
@@ -637,6 +637,7 @@ enum pipe_shader_cap
    PIPE_SHADER_CAP_MAX_SAMPLER_VIEWS,
    PIPE_SHADER_CAP_DOUBLES,
    PIPE_SHADER_CAP_TGSI_DROUND_SUPPORTED, /* all rounding modes */
+   PIPE_SHADER_CAP_TGSI_DFRACEXP_DLDEXP_SUPPORTED,
 };
 
 /**