summaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
authorJonathan Gray <jsg@cvs.openbsd.org>2020-08-26 05:30:35 +0000
committerJonathan Gray <jsg@cvs.openbsd.org>2020-08-26 05:30:35 +0000
commit875c9b16ee75c400fd67041ccd43ae03896463be (patch)
tree0108b1fa9109a8f1e8d42e3892deba41ac716f98 /lib
parentcc096ef1dad1117242d788f05ce046e5a38b5004 (diff)
Import Mesa 20.1.6
Diffstat (limited to 'lib')
-rw-r--r--lib/mesa/src/mesa/state_tracker/st_cb_perfquery.c6
-rw-r--r--lib/mesa/src/panfrost/include/panfrost-quirks.h54
-rw-r--r--lib/mesa/src/util/tests/vector/vector_test.cpp2
3 files changed, 11 insertions, 51 deletions
diff --git a/lib/mesa/src/mesa/state_tracker/st_cb_perfquery.c b/lib/mesa/src/mesa/state_tracker/st_cb_perfquery.c
index 5117bb60f..1bafc272c 100644
--- a/lib/mesa/src/mesa/state_tracker/st_cb_perfquery.c
+++ b/lib/mesa/src/mesa/state_tracker/st_cb_perfquery.c
@@ -184,7 +184,7 @@ st_IsPerfQueryReady(struct gl_context *ctx, struct gl_perf_query_object *o)
return pipe->is_intel_perf_query_ready(pipe, (struct pipe_query *)o);
}
-static bool
+static void
st_GetPerfQueryData(struct gl_context *ctx,
struct gl_perf_query_object *o,
GLsizei data_size,
@@ -200,8 +200,8 @@ st_GetPerfQueryData(struct gl_context *ctx,
*/
assert(o->Ready);
- return pipe->get_intel_perf_query_data(pipe, (struct pipe_query *)o,
- data_size, data, bytes_written);
+ pipe->get_intel_perf_query_data(pipe, (struct pipe_query *)o, data_size, data,
+ bytes_written);
}
static struct gl_perf_query_object *
diff --git a/lib/mesa/src/panfrost/include/panfrost-quirks.h b/lib/mesa/src/panfrost/include/panfrost-quirks.h
index cede8254d..c8d631cd4 100644
--- a/lib/mesa/src/panfrost/include/panfrost-quirks.h
+++ b/lib/mesa/src/panfrost/include/panfrost-quirks.h
@@ -45,77 +45,37 @@
#define MIDGARD_BROKEN_FP16 (1 << 2)
/* What it says on the tin */
-#define HAS_SWIZZLES (1 << 4)
-
-/* bit 5 unused */
-
-/* Whether this GPU lacks support for any typed stores in blend shader,
- * requiring packing instead */
-#define MIDGARD_NO_TYPED_BLEND_STORES (1 << 6)
-
-/* Whether this GPU lacks support for any typed loads, requiring packing */
-#define MIDGARD_NO_TYPED_BLEND_LOADS (1 << 7)
-
-/* Lack support for colour pack/unpack opcodes */
-#define NO_BLEND_PACKS (1 << 8)
-
-/* Has some missing formats for typed loads */
-#define MIDGARD_MISSING_LOADS (1 << 9)
-
-/* Lack support for AFBC */
-#define MIDGARD_NO_AFBC (1 << 10)
-
-/* Does this GPU support anisotropic filtering? */
-#define HAS_ANISOTROPIC (1 << 11)
-
-#define NO_TILE_ENABLE_MAP (1 << 12)
+#define IS_BIFROST (1 << 3)
/* Quirk collections common to particular uarchs */
-#define MIDGARD_QUIRKS (MIDGARD_BROKEN_FP16 | HAS_SWIZZLES \
- | MIDGARD_NO_TYPED_BLEND_STORES \
- | MIDGARD_MISSING_LOADS)
+#define MIDGARD_QUIRKS (MIDGARD_BROKEN_FP16)
-#define BIFROST_QUIRKS NO_BLEND_PACKS
+#define BIFROST_QUIRKS (IS_BIFROST)
static inline unsigned
-panfrost_get_quirks(unsigned gpu_id, unsigned gpu_revision)
+panfrost_get_quirks(unsigned gpu_id)
{
switch (gpu_id) {
case 0x600:
case 0x620:
- return MIDGARD_QUIRKS | MIDGARD_SFBD
- | MIDGARD_NO_TYPED_BLEND_LOADS
- | NO_BLEND_PACKS | MIDGARD_NO_AFBC
- | NO_TILE_ENABLE_MAP;
+ return MIDGARD_QUIRKS | MIDGARD_SFBD;
case 0x720:
- return MIDGARD_QUIRKS | MIDGARD_SFBD | MIDGARD_NO_HIER_TILING
- | MIDGARD_NO_AFBC | NO_TILE_ENABLE_MAP;
+ return MIDGARD_QUIRKS | MIDGARD_SFBD | MIDGARD_NO_HIER_TILING;
case 0x820:
case 0x830:
return MIDGARD_QUIRKS | MIDGARD_NO_HIER_TILING;
case 0x750:
- return MIDGARD_QUIRKS;
-
case 0x860:
case 0x880:
return MIDGARD_QUIRKS;
- case 0x6000: /* G71 */
- return BIFROST_QUIRKS | HAS_SWIZZLES;
-
- case 0x6221: /* G72 */
- /* Anisotropic filtering is supported from r0p3 onwards */
- return BIFROST_QUIRKS | HAS_SWIZZLES
- | (gpu_revision >= 0x30 ? HAS_ANISOTROPIC : 0);
-
case 0x7093: /* G31 */
case 0x7212: /* G52 */
- case 0x7402: /* G52r1 */
- return BIFROST_QUIRKS | HAS_ANISOTROPIC;
+ return BIFROST_QUIRKS;
default:
unreachable("Unknown Panfrost GPU ID");
diff --git a/lib/mesa/src/util/tests/vector/vector_test.cpp b/lib/mesa/src/util/tests/vector/vector_test.cpp
index e68124a1e..aa7ca2bbf 100644
--- a/lib/mesa/src/util/tests/vector/vector_test.cpp
+++ b/lib/mesa/src/util/tests/vector/vector_test.cpp
@@ -30,7 +30,7 @@ static void test(uint32_t size_in_elements, uint32_t elements_to_walk, uint32_t
uint32_t add_counter = 0;
uint32_t remove_counter = 0;
- ASSERT_TRUE(u_vector_init(&vector, size_in_elements, sizeof(uint64_t)));
+ ASSERT_TRUE(u_vector_init(&vector, sizeof(uint64_t), sizeof(uint64_t) * size_in_elements));
// Override the head and tail so we can quickly test rollover
vector.head = vector.tail = start;