diff options
author | Jerome Glisse <jglisse@redhat.com> | 2010-06-05 13:16:50 +0200 |
---|---|---|
committer | Jerome Glisse <jglisse@redhat.com> | 2010-06-05 17:13:25 +0200 |
commit | 0db388eedd5a537e783faaa1ba1a1d101d20e647 (patch) | |
tree | fc4ffbd99032104fc67cc5546b5a13366b52290d /src/gallium/drivers/r600/r600_compiler_dump.c | |
parent | 7643f45b107c9b4e6cf57711909791beaaf79ba2 (diff) |
r600g: split instruction into scalar
Split instruction into scalar in core compiler this simplify
the way we translate the instruction in latter stage.
Signed-off-by: Jerome Glisse <jglisse@redhat.com>
Diffstat (limited to 'src/gallium/drivers/r600/r600_compiler_dump.c')
-rw-r--r-- | src/gallium/drivers/r600/r600_compiler_dump.c | 33 |
1 files changed, 15 insertions, 18 deletions
diff --git a/src/gallium/drivers/r600/r600_compiler_dump.c b/src/gallium/drivers/r600/r600_compiler_dump.c index 9df6a38598..485032088c 100644 --- a/src/gallium/drivers/r600/r600_compiler_dump.c +++ b/src/gallium/drivers/r600/r600_compiler_dump.c @@ -229,28 +229,25 @@ static void pindent(unsigned indent) static void c_node_dump(struct c_node *node, unsigned indent) { struct c_instruction *i; - unsigned j; + unsigned j, k; pindent(indent); fprintf(stderr, "# node %s\n", c_get_name(c_opcode_str, node->opcode)); c_list_for_each(i, &node->insts) { - pindent(indent); fprintf(stderr, "%s", c_get_name(c_opcode_str, i->opcode)); - fprintf(stderr, " %s[%d][%s%s%s%s]", - c_get_name(c_file_str, i->output.vector->file), - i->output.vector->id, - c_get_name(c_file_swz, i->output.swizzle[0]), - c_get_name(c_file_swz, i->output.swizzle[1]), - c_get_name(c_file_swz, i->output.swizzle[2]), - c_get_name(c_file_swz, i->output.swizzle[3])); - for (j = 0; j < i->ninput; j++) { - fprintf(stderr, " %s[%d][%s%s%s%s]", - c_get_name(c_file_str, i->input[j].vector->file), - i->input[j].vector->id, - c_get_name(c_file_swz, i->input[j].swizzle[0]), - c_get_name(c_file_swz, i->input[j].swizzle[1]), - c_get_name(c_file_swz, i->input[j].swizzle[2]), - c_get_name(c_file_swz, i->input[j].swizzle[3])); + for (k = 0; k < i->nop; k++) { + pindent(indent); + fprintf(stderr, "%s", c_get_name(c_opcode_str, i->op[k].opcode)); + fprintf(stderr, " %s[%d][%s]", + c_get_name(c_file_str, i->op[k].output.vector->file), + i->op[k].output.vector->id, + c_get_name(c_file_swz, i->op[k].output.swizzle)); + for (j = 0; j < i->op[k].ninput; j++) { + fprintf(stderr, " %s[%d][%s]", + c_get_name(c_file_str, i->op[k].input[j].vector->file), + i->op[k].input[j].vector->id, + c_get_name(c_file_swz, i->op[k].input[j].swizzle)); + } + fprintf(stderr, ";\n"); } - fprintf(stderr, ";\n"); } } |