From: Nicolai Hähnle Date: Mon, 29 Apr 2019 13:59:22 +0000 (+0200) Subject: radeonsi: fix line splitting in si_shader_dump_assembly X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=3bde69e789ca75d6b5dc9afc48dcb1675714769c;p=mesa.git radeonsi: fix line splitting in si_shader_dump_assembly Compute the count since the start of the current line instead of the count since the start of the the disassembly. Reviewed-by: Marek Olšák --- diff --git a/src/gallium/drivers/radeonsi/si_shader.c b/src/gallium/drivers/radeonsi/si_shader.c index ed2db3d0042..f4e522dd7c1 100644 --- a/src/gallium/drivers/radeonsi/si_shader.c +++ b/src/gallium/drivers/radeonsi/si_shader.c @@ -5259,7 +5259,7 @@ static void si_shader_dump_disassembly(struct si_screen *screen, int count = nbytes - line; const char *nl = memchr(disasm + line, '\n', nbytes - line); if (nl) - count = nl - disasm; + count = nl - (disasm + line); if (count) { pipe_debug_message(debug, SHADER_INFO,