r300/compiler: Add a more efficient version of rc_find_free_temporary()
[mesa.git] / src / mesa / drivers / dri / r300 / compiler / radeon_compiler_util.h
1 #include "radeon_program_constants.h"
2
3 #ifndef RADEON_PROGRAM_UTIL_H
4 #define RADEON_PROGRAM_UTIL_H
5
6 struct rc_instruction;
7 struct rc_src_register;
8
9 unsigned int rc_swizzle_to_writemask(unsigned int swz);
10
11 unsigned int rc_src_reads_dst_mask(
12 rc_register_file src_file,
13 unsigned int src_idx,
14 unsigned int src_swz,
15 rc_register_file dst_file,
16 unsigned int dst_idx,
17 unsigned int dst_mask);
18
19 unsigned int rc_source_type_swz(unsigned int swizzle, unsigned int channels);
20
21 unsigned int rc_source_type_mask(unsigned int mask);
22
23 unsigned int rc_inst_can_use_presub(
24 struct rc_instruction * inst,
25 rc_presubtract_op presub_op,
26 unsigned int presub_writemask,
27 struct rc_src_register replace_reg,
28 struct rc_src_register presub_src0,
29 struct rc_src_register presub_src1);
30
31 #endif /* RADEON_PROGRAM_UTIL_H */