17279d663e984ae8a243f56c010f175fee9ffccb3Michal Krol/**************************************************************************
27279d663e984ae8a243f56c010f175fee9ffccb3Michal Krol *
35ded4ffc506eb051b151d3e8b1e71b13576e951aMichal Krol * Copyright 2007-2008 Tungsten Graphics, Inc., Cedar Park, Texas.
47279d663e984ae8a243f56c010f175fee9ffccb3Michal Krol * All Rights Reserved.
57279d663e984ae8a243f56c010f175fee9ffccb3Michal Krol *
67279d663e984ae8a243f56c010f175fee9ffccb3Michal Krol * Permission is hereby granted, free of charge, to any person obtaining a
77279d663e984ae8a243f56c010f175fee9ffccb3Michal Krol * copy of this software and associated documentation files (the
87279d663e984ae8a243f56c010f175fee9ffccb3Michal Krol * "Software"), to deal in the Software without restriction, including
97279d663e984ae8a243f56c010f175fee9ffccb3Michal Krol * without limitation the rights to use, copy, modify, merge, publish,
107279d663e984ae8a243f56c010f175fee9ffccb3Michal Krol * distribute, sub license, and/or sell copies of the Software, and to
117279d663e984ae8a243f56c010f175fee9ffccb3Michal Krol * permit persons to whom the Software is furnished to do so, subject to
127279d663e984ae8a243f56c010f175fee9ffccb3Michal Krol * the following conditions:
137279d663e984ae8a243f56c010f175fee9ffccb3Michal Krol *
147279d663e984ae8a243f56c010f175fee9ffccb3Michal Krol * The above copyright notice and this permission notice (including the
157279d663e984ae8a243f56c010f175fee9ffccb3Michal Krol * next paragraph) shall be included in all copies or substantial portions
167279d663e984ae8a243f56c010f175fee9ffccb3Michal Krol * of the Software.
177279d663e984ae8a243f56c010f175fee9ffccb3Michal Krol *
187279d663e984ae8a243f56c010f175fee9ffccb3Michal Krol * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
197279d663e984ae8a243f56c010f175fee9ffccb3Michal Krol * OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
207279d663e984ae8a243f56c010f175fee9ffccb3Michal Krol * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT.
217279d663e984ae8a243f56c010f175fee9ffccb3Michal Krol * IN NO EVENT SHALL TUNGSTEN GRAPHICS AND/OR ITS SUPPLIERS BE LIABLE FOR
227279d663e984ae8a243f56c010f175fee9ffccb3Michal Krol * ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
237279d663e984ae8a243f56c010f175fee9ffccb3Michal Krol * TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
247279d663e984ae8a243f56c010f175fee9ffccb3Michal Krol * SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
257279d663e984ae8a243f56c010f175fee9ffccb3Michal Krol *
267279d663e984ae8a243f56c010f175fee9ffccb3Michal Krol **************************************************************************/
277279d663e984ae8a243f56c010f175fee9ffccb3Michal Krol
287279d663e984ae8a243f56c010f175fee9ffccb3Michal Krol#ifndef TGSI_DUMP_H
29ffe58739da9eee2e99682747cc8f26e412c87430michal#define TGSI_DUMP_H
30ffe58739da9eee2e99682747cc8f26e412c87430michal
310b9b8694d9c3295436561331f03f0d59effe26c4Vinson Lee#include "pipe/p_compiler.h"
3292209314df4f12e8b47336a25ba14cb6b9a23df2Marek Olšák#include "pipe/p_defines.h"
335ded4ffc506eb051b151d3e8b1e71b13576e951aMichal Krol#include "pipe/p_shader_tokens.h"
345ded4ffc506eb051b151d3e8b1e71b13576e951aMichal Krol
35ffe58739da9eee2e99682747cc8f26e412c87430michal#if defined __cplusplus
36ffe58739da9eee2e99682747cc8f26e412c87430michalextern "C" {
379a8a5d7c2fe7f32c8d15bc0a77f86e1f2f995ffeJosé Fonseca#endif
38ffe58739da9eee2e99682747cc8f26e412c87430michal
39ffe58739da9eee2e99682747cc8f26e412c87430michalvoid
40673489fa5cde4ce8d49918f20f007201a17bc45eJosé Fonsecatgsi_dump_str(
41673489fa5cde4ce8d49918f20f007201a17bc45eJosé Fonseca   const struct tgsi_token *tokens,
42673489fa5cde4ce8d49918f20f007201a17bc45eJosé Fonseca   uint flags,
43673489fa5cde4ce8d49918f20f007201a17bc45eJosé Fonseca   char *str,
44673489fa5cde4ce8d49918f20f007201a17bc45eJosé Fonseca   size_t size);
45673489fa5cde4ce8d49918f20f007201a17bc45eJosé Fonseca
46673489fa5cde4ce8d49918f20f007201a17bc45eJosé Fonsecavoid
47ffe58739da9eee2e99682747cc8f26e412c87430michaltgsi_dump(
4815c902455fe1b4572e614bf30912d92fe9c7bb28Michal Krol   const struct tgsi_token *tokens,
4915c902455fe1b4572e614bf30912d92fe9c7bb28Michal Krol   uint flags );
506cdcebe8017b56e2f823dd3f6d805e55056f7e9bMichal
51adaaa29218f1babad874f50681ca971fdd3b8a40Keith Whitwellstruct tgsi_full_immediate;
52adaaa29218f1babad874f50681ca971fdd3b8a40Keith Whitwellstruct tgsi_full_instruction;
53adaaa29218f1babad874f50681ca971fdd3b8a40Keith Whitwellstruct tgsi_full_declaration;
543ff688ea299581e60caf5d6e1a464f68c717fe83Zack Rusinstruct tgsi_full_property;
55adaaa29218f1babad874f50681ca971fdd3b8a40Keith Whitwell
56adaaa29218f1babad874f50681ca971fdd3b8a40Keith Whitwellvoid
57adaaa29218f1babad874f50681ca971fdd3b8a40Keith Whitwelltgsi_dump_immediate(
58adaaa29218f1babad874f50681ca971fdd3b8a40Keith Whitwell   const struct tgsi_full_immediate *imm );
59adaaa29218f1babad874f50681ca971fdd3b8a40Keith Whitwell
60adaaa29218f1babad874f50681ca971fdd3b8a40Keith Whitwellvoid
61adaaa29218f1babad874f50681ca971fdd3b8a40Keith Whitwelltgsi_dump_instruction(
625ded4ffc506eb051b151d3e8b1e71b13576e951aMichal Krol   const struct tgsi_full_instruction *inst,
635ded4ffc506eb051b151d3e8b1e71b13576e951aMichal Krol   uint instno );
64adaaa29218f1babad874f50681ca971fdd3b8a40Keith Whitwell
65adaaa29218f1babad874f50681ca971fdd3b8a40Keith Whitwellvoid
66adaaa29218f1babad874f50681ca971fdd3b8a40Keith Whitwelltgsi_dump_declaration(
675ded4ffc506eb051b151d3e8b1e71b13576e951aMichal Krol   const struct tgsi_full_declaration *decl );
68adaaa29218f1babad874f50681ca971fdd3b8a40Keith Whitwell
693ff688ea299581e60caf5d6e1a464f68c717fe83Zack Rusinvoid
703ff688ea299581e60caf5d6e1a464f68c717fe83Zack Rusintgsi_dump_property(
713ff688ea299581e60caf5d6e1a464f68c717fe83Zack Rusin   const struct tgsi_full_property *prop );
723ff688ea299581e60caf5d6e1a464f68c717fe83Zack Rusin
73ffe58739da9eee2e99682747cc8f26e412c87430michal#if defined __cplusplus
749a8a5d7c2fe7f32c8d15bc0a77f86e1f2f995ffeJosé Fonseca}
759a8a5d7c2fe7f32c8d15bc0a77f86e1f2f995ffeJosé Fonseca#endif
76ffe58739da9eee2e99682747cc8f26e412c87430michal
779a8a5d7c2fe7f32c8d15bc0a77f86e1f2f995ffeJosé Fonseca#endif /* TGSI_DUMP_H */
78