summaryrefslogtreecommitdiffstats
path: root/src/freedreno/ir3
diff options
context:
space:
mode:
authorRob Clark <[email protected]>2018-11-30 08:29:51 -0500
committerRob Clark <[email protected]>2018-12-13 15:51:01 -0500
commit4cd016b5d6a8f3baeea8850deeb528d5febf4784 (patch)
tree47bf18bb1f67cd9c27e500549c6743649a17a8d7 /src/freedreno/ir3
parent7ef722861b691ce99be3827ed05f8c0ddf2cd66e (diff)
freedreno: debug GEM obj names
With a recent enough kernel, set debug names for GEM BOs, which will show up in $debugfs/gem Signed-off-by: Rob Clark <[email protected]>
Diffstat (limited to 'src/freedreno/ir3')
-rw-r--r--src/freedreno/ir3/ir3_shader.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/freedreno/ir3/ir3_shader.c b/src/freedreno/ir3/ir3_shader.c
index 74d92e13962..51c7b75ea38 100644
--- a/src/freedreno/ir3/ir3_shader.c
+++ b/src/freedreno/ir3/ir3_shader.c
@@ -126,6 +126,7 @@ static void
assemble_variant(struct ir3_shader_variant *v)
{
struct ir3_compiler *compiler = v->shader->compiler;
+ struct shader_info *info = &v->shader->nir->info;
uint32_t gpu_id = compiler->gpu_id;
uint32_t sz, *bin;
@@ -134,7 +135,8 @@ assemble_variant(struct ir3_shader_variant *v)
v->bo = fd_bo_new(compiler->dev, sz,
DRM_FREEDRENO_GEM_CACHE_WCOMBINE |
- DRM_FREEDRENO_GEM_TYPE_KMEM);
+ DRM_FREEDRENO_GEM_TYPE_KMEM,
+ "%s:%s", ir3_shader_stage(v->shader), info->name);
memcpy(fd_bo_map(v->bo), bin, sz);