diff options
author | Nicolai Hähnle <nicolai.haehnle@amd.com> | 2016-08-10 18:05:13 +0200 |
---|---|---|
committer | Nicolai Hähnle <nicolai.haehnle@amd.com> | 2016-08-17 12:11:21 +0200 |
commit | 67c0f077a2198b8337a74a1027242b406a6bc571 (patch) | |
tree | 5a077045d7c9c3ca6da4afbbb82bee7049a9666d /src/gallium/auxiliary/tgsi/tgsi_scan.h | |
parent | 2ec3a3e1517c50583cd959584c1bea8d04d75c40 (diff) | |
download | external_mesa3d-67c0f077a2198b8337a74a1027242b406a6bc571.zip external_mesa3d-67c0f077a2198b8337a74a1027242b406a6bc571.tar.gz external_mesa3d-67c0f077a2198b8337a74a1027242b406a6bc571.tar.bz2 |
tgsi/scan: add tgsi_scan_arrays
Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Diffstat (limited to 'src/gallium/auxiliary/tgsi/tgsi_scan.h')
-rw-r--r-- | src/gallium/auxiliary/tgsi/tgsi_scan.h | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/src/gallium/auxiliary/tgsi/tgsi_scan.h b/src/gallium/auxiliary/tgsi/tgsi_scan.h index f7eefa4..30d0146 100644 --- a/src/gallium/auxiliary/tgsi/tgsi_scan.h +++ b/src/gallium/auxiliary/tgsi/tgsi_scan.h @@ -149,10 +149,27 @@ struct tgsi_shader_info unsigned max_depth; }; +struct tgsi_array_info +{ + /** Whether an array with this ID was declared. */ + bool declared; + + /** The OR of all writemasks used to write to this array. */ + ubyte writemask; + + /** The range with which the array was declared. */ + struct tgsi_declaration_range range; +}; + extern void tgsi_scan_shader(const struct tgsi_token *tokens, struct tgsi_shader_info *info); +void +tgsi_scan_arrays(const struct tgsi_token *tokens, + unsigned file, + unsigned max_array_id, + struct tgsi_array_info *arrays); extern boolean tgsi_is_passthrough_shader(const struct tgsi_token *tokens); |