[Mesa-dev] [PATCH] i965: Document inconsistent units the URB size is represented in.
Francisco Jerez
currojerez at riseup.net
Wed Nov 25 06:31:53 PST 2015
src/mesa/drivers/dri/i965/brw_context.h | 8 +++++++-
src/mesa/drivers/dri/i965/brw_device_info.h | 5 +++++
2 files changed, 12 insertions(+), 1 deletion(-)
diff --git a/src/mesa/drivers/dri/i965/brw_context.h b/src/mesa/drivers/dri/i965/brw_context.h
index ee3b6a3..30e5c48 100644
--- a/src/mesa/drivers/dri/i965/brw_context.h
+++ b/src/mesa/drivers/dri/i965/brw_context.h
@@ -1000,7 +1000,13 @@ struct brw_context
GLuint clip_start;
GLuint sf_start;
GLuint cs_start;
- GLuint size; /* Hardware URB size, in KB. */
+ /**
+ * URB size in the current configuration. The units this is expressed
+ * in are somewhat inconsistent, see brw_device_info::urb::size.
+ *
+ * FINISHME: Represent the URB size consistently in KB on all platforms.
+ */
+ GLuint size;
/* True if the most recently sent _3DSTATE_URB message allocated
* URB space for the GS.
diff --git a/src/mesa/drivers/dri/i965/brw_device_info.h b/src/mesa/drivers/dri/i965/brw_device_info.h
index 8d3af62..324c074 100644
--- a/src/mesa/drivers/dri/i965/brw_device_info.h
+++ b/src/mesa/drivers/dri/i965/brw_device_info.h
@@ -81,6 +81,11 @@ struct brw_device_info
unsigned max_cs_threads;
struct {
+ /**
+ * Hardware default URB size. The units this is expressed in are
+ * somewhat inconsistent: 512b units on Gen4-5, KB on Gen6-7, and KB
+ * times the slice count on Gen8+.
+ */
unsigned size;
unsigned min_vs_entries;
unsigned max_vs_entries;
--
2.5.1
More information about the mesa-dev
mailing list