r600g: add r600 compile mode to compiler.

some of the ALU instructions are different on r6xx vs r7xx,
separate the alu translation to separate files, and use family
to pick which compile stage to use.
This commit is contained in:
Dave Airlie
2010-07-21 15:39:23 +10:00
committed by Jerome Glisse
parent 9433d0e801
commit 4b2820534e
4 changed files with 106 additions and 13 deletions

View File

@@ -96,6 +96,7 @@ struct r600_shader {
u32 *bcode; /**< bytes code */
enum pipe_format resource_format[160]; /**< format of resource */
struct c_shader cshader;
boolean r6xx_compile;
};
void r600_shader_cleanup(struct r600_shader *rshader);
@@ -122,6 +123,10 @@ int r600_shader_translate_rec(struct r600_shader *rshader, struct c_node *node);
int r700_shader_translate(struct r600_shader *rshader);
int r600_shader_insert_fetch(struct c_shader *shader);
int r6xx_shader_alu_translate(struct r600_shader *rshader,
struct r600_shader_node *rnode,
unsigned *cid);
enum r600_instruction {
INST_ADD = 0,
INST_MUL = 1,