i965: Rewrite disassembly annotation code
authorMatt Turner <mattst88@gmail.com>
Thu, 16 Nov 2017 01:08:42 +0000 (17:08 -0800)
committerMatt Turner <mattst88@gmail.com>
Fri, 17 Nov 2017 20:14:38 +0000 (12:14 -0800)
commit4f82b17287194ca7d10816f6cfe4712a3e0a03fc
tree7e2bb056e5c389643e9338e4359e5aae9ab49f92
parentf80e97346b0da9fab3d60b46bdcf0a0d702f97c9
i965: Rewrite disassembly annotation code

The old code used an array to store each "instruction group" (the new,
better name than the old overloaded "annotation"), and required a
memmove() to shift elements over in the array when we needed to split a
group so that we could add an error message. This was confusing and
difficult to get right, not the least of which was  because the array
has a tail sentinel not included in .ann_count.

Instead use a linked list, a data structure made for efficient
insertion.

Acked-by: Samuel Iglesias Gonsálvez <siglesias@igalia.com>
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
src/intel/compiler/brw_compile_clip.c
src/intel/compiler/brw_eu.h
src/intel/compiler/brw_eu_compact.c
src/intel/compiler/brw_eu_validate.c
src/intel/compiler/brw_fs_generator.cpp
src/intel/compiler/brw_vec4_generator.cpp
src/intel/compiler/intel_asm_annotation.c
src/intel/compiler/intel_asm_annotation.h
src/intel/compiler/test_eu_validate.cpp
src/intel/tools/disasm.c
src/mesa/drivers/dri/i965/brw_ff_gs.c