Mesa (main): panfrost: Shrink pan_draw_mode return type

GitLab Mirror gitlab-mirror at kemper.freedesktop.org
Tue Jun 1 19:26:48 UTC 2021


Module: Mesa
Branch: main
Commit: 344db85bd538768a0985e9941b2e45f5c202b907
URL:    http://cgit.freedesktop.org/mesa/mesa/commit/?id=344db85bd538768a0985e9941b2e45f5c202b907

Author: Alyssa Rosenzweig <alyssa at collabora.com>
Date:   Thu May 20 13:11:02 2021 -0400

panfrost: Shrink pan_draw_mode return type

Let gcc emit ldrb instead of ldr for the table. Found by perf, but total
waste of time >_>

Signed-off-by: Alyssa Rosenzweig <alyssa at collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11074>

---

 src/gallium/drivers/panfrost/pan_context.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/gallium/drivers/panfrost/pan_context.c b/src/gallium/drivers/panfrost/pan_context.c
index b638e8d23c6..6fb085e1842 100644
--- a/src/gallium/drivers/panfrost/pan_context.c
+++ b/src/gallium/drivers/panfrost/pan_context.c
@@ -131,7 +131,7 @@ panfrost_set_frontend_noop(struct pipe_context *pipe, bool enable)
 
 #define DEFINE_CASE(c) case PIPE_PRIM_##c: return MALI_DRAW_MODE_##c;
 
-static int
+static uint8_t
 pan_draw_mode(enum pipe_prim_type mode)
 {
         switch (mode) {



More information about the mesa-commit mailing list