summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJames Xiong <[email protected]>2019-10-14 10:05:46 +0200
committerMichel Dänzer <[email protected]>2019-10-14 10:05:46 +0200
commit4f963b03a1015c87813a7215bae20e8ba2e088a2 (patch)
tree516173aad38e6958ad817f6ff6c2f8396729ef4f
parenta65e29ccb261f3c127c49e73d0da92124234668f (diff)
gallium: rename PIPE_CAP_MAX_FRAMES_IN_FLIGHT to PIPE_CAP_THROTTLE
v2: [ Michel Dänzer ] * Update src/gallium/docs/source/screen.rst accordingly Signed-off-by: James Xiong <[email protected]> Reviewed-by: Michel Dänzer <[email protected]> # v1 Reviewed-by: Marek Olšák <[email protected]> # v1
-rw-r--r--src/gallium/auxiliary/util/u_screen.c2
-rw-r--r--src/gallium/docs/source/screen.rst3
-rw-r--r--src/gallium/drivers/iris/iris_screen.c2
-rw-r--r--src/gallium/drivers/nouveau/nv50/nv50_screen.c2
-rw-r--r--src/gallium/drivers/nouveau/nvc0/nvc0_screen.c2
-rw-r--r--src/gallium/include/pipe/p_defines.h2
-rw-r--r--src/gallium/state_trackers/dri/dri2.c3
7 files changed, 7 insertions, 9 deletions
diff --git a/src/gallium/auxiliary/util/u_screen.c b/src/gallium/auxiliary/util/u_screen.c
index bf5b9daad7e..6faf6d75e76 100644
--- a/src/gallium/auxiliary/util/u_screen.c
+++ b/src/gallium/auxiliary/util/u_screen.c
@@ -371,7 +371,7 @@ u_pipe_screen_get_param_defaults(struct pipe_screen *pscreen,
case PIPE_CAP_COMPUTE_SHADER_DERIVATIVES:
return 0;
- case PIPE_CAP_MAX_FRAMES_IN_FLIGHT:
+ case PIPE_CAP_THROTTLE:
return 1;
case PIPE_CAP_TEXTURE_SHADOW_LOD:
diff --git a/src/gallium/docs/source/screen.rst b/src/gallium/docs/source/screen.rst
index 1c402b03391..4bb805f39e2 100644
--- a/src/gallium/docs/source/screen.rst
+++ b/src/gallium/docs/source/screen.rst
@@ -526,8 +526,7 @@ The integer capabilities:
A driver might rely on the input mapping that was defined with the original
GLSL code.
* ``PIPE_CAP_IMAGE_LOAD_FORMATTED``: True if a format for image loads does not need to be specified in the shader IR
-* ``PIPE_CAP_MAX_FRAMES_IN_FLIGHT``: Maximum number of frames that state
- trackers should allow to be in flight before throttling pipe_context
+* ``PIPE_CAP_THROTTLE``: Whether or not state trackers should throttle pipe_context
execution. 0 = throttling is disabled.
* ``PIPE_CAP_DMABUF``: Whether Linux DMABUF handles are supported by
resource_from_handle and resource_get_handle.
diff --git a/src/gallium/drivers/iris/iris_screen.c b/src/gallium/drivers/iris/iris_screen.c
index 83e88410b8f..63159405a16 100644
--- a/src/gallium/drivers/iris/iris_screen.c
+++ b/src/gallium/drivers/iris/iris_screen.c
@@ -311,7 +311,7 @@ iris_get_param(struct pipe_screen *pscreen, enum pipe_cap param)
* illegal snoop <-> snoop transfers.
*/
return devinfo->has_llc;
- case PIPE_CAP_MAX_FRAMES_IN_FLIGHT:
+ case PIPE_CAP_THROTTLE:
return screen->driconf.disable_throttling ? 0 : 1;
case PIPE_CAP_CONTEXT_PRIORITY_MASK:
diff --git a/src/gallium/drivers/nouveau/nv50/nv50_screen.c b/src/gallium/drivers/nouveau/nv50/nv50_screen.c
index 41327858fd0..062de628079 100644
--- a/src/gallium/drivers/nouveau/nv50/nv50_screen.c
+++ b/src/gallium/drivers/nouveau/nv50/nv50_screen.c
@@ -356,7 +356,7 @@ nv50_screen_get_param(struct pipe_screen *pscreen, enum pipe_cap param)
/* caps where we want the default value */
case PIPE_CAP_DMABUF:
case PIPE_CAP_ESSL_FEATURE_LEVEL:
- case PIPE_CAP_MAX_FRAMES_IN_FLIGHT:
+ case PIPE_CAP_THROTTLE:
return u_pipe_screen_get_param_defaults(pscreen, param);
}
}
diff --git a/src/gallium/drivers/nouveau/nvc0/nvc0_screen.c b/src/gallium/drivers/nouveau/nvc0/nvc0_screen.c
index a5b8659d321..bbb0784190a 100644
--- a/src/gallium/drivers/nouveau/nvc0/nvc0_screen.c
+++ b/src/gallium/drivers/nouveau/nvc0/nvc0_screen.c
@@ -391,7 +391,7 @@ nvc0_screen_get_param(struct pipe_screen *pscreen, enum pipe_cap param)
/* caps where we want the default value */
case PIPE_CAP_DMABUF:
case PIPE_CAP_ESSL_FEATURE_LEVEL:
- case PIPE_CAP_MAX_FRAMES_IN_FLIGHT:
+ case PIPE_CAP_THROTTLE:
return u_pipe_screen_get_param_defaults(pscreen, param);
}
}
diff --git a/src/gallium/include/pipe/p_defines.h b/src/gallium/include/pipe/p_defines.h
index 6657271cbf6..bf6825a65d1 100644
--- a/src/gallium/include/pipe/p_defines.h
+++ b/src/gallium/include/pipe/p_defines.h
@@ -885,7 +885,7 @@ enum pipe_cap
PIPE_CAP_COMPUTE_SHADER_DERIVATIVES,
PIPE_CAP_TGSI_SKIP_SHRINK_IO_ARRAYS,
PIPE_CAP_IMAGE_LOAD_FORMATTED,
- PIPE_CAP_MAX_FRAMES_IN_FLIGHT,
+ PIPE_CAP_THROTTLE,
PIPE_CAP_DMABUF,
PIPE_CAP_PREFER_COMPUTE_FOR_MULTIMEDIA,
PIPE_CAP_FRAGMENT_SHADER_INTERLOCK,
diff --git a/src/gallium/state_trackers/dri/dri2.c b/src/gallium/state_trackers/dri/dri2.c
index 6acfc6aa977..960065ffa23 100644
--- a/src/gallium/state_trackers/dri/dri2.c
+++ b/src/gallium/state_trackers/dri/dri2.c
@@ -2057,8 +2057,7 @@ dri2_init_screen(__DRIscreen * sPriv)
if (!pscreen)
goto release_pipe;
- screen->throttle =
- pscreen->get_param(pscreen, PIPE_CAP_MAX_FRAMES_IN_FLIGHT) > 0;
+ screen->throttle = pscreen->get_param(pscreen, PIPE_CAP_THROTTLE);
if (pscreen->resource_create_with_modifiers)
dri2ImageExtension.createImageWithModifiers =