Add the CRE enginee for HSW+

This is also for media encoding like VME, which can do
the operation of check & refinement.

Signed-off-by: Zhao Yakui <yakui.zhao@intel.com>
This commit is contained in:
Zhao Yakui 2012-10-22 16:13:51 -04:00 committed by Damien Lespiau
parent 495c4e14e7
commit 93f2a4fc93
4 changed files with 25 additions and 2 deletions

View File

@ -730,6 +730,7 @@
#define BRW_MESSAGE_TARGET_VME 8
#define BRW_MESSAGE_TARGET_DP_CC 9 /* data port constant cache */
#define BRW_MESSAGE_TARGET_DP_DC 10 /* data port data cache */
#define BRW_MESSAGE_TARGET_CRE 0x0d /* check & refinement enginee */
#define BRW_SAMPLER_RETURN_FORMAT_FLOAT32 0
#define BRW_SAMPLER_RETURN_FORMAT_UINT32 2

View File

@ -1550,7 +1550,13 @@ struct brw_instruction
GLuint pad0:4;
GLuint header_present:1;
} vme_gen6;
struct {
GLuint binding_table_index:8;
GLuint pad0:5;
GLuint message_type:2;
GLuint pad1:4;
GLuint header_present:1;
} cre_gen75;
struct {
GLuint pad:19;
GLuint header_present:1;

View File

@ -154,7 +154,7 @@ void set_direct_src_operand(struct src_operand *src, struct direct_reg *reg,
%token <integer> CALL RET
%token <integer> BRD BRC
%token NULL_TOKEN MATH SAMPLER GATEWAY READ WRITE URB THREAD_SPAWNER VME DATA_PORT
%token NULL_TOKEN MATH SAMPLER GATEWAY READ WRITE URB THREAD_SPAWNER VME DATA_PORT CRE
%token MSGLEN RETURNLEN
%token <integer> ALLOCATE USED COMPLETE TRANSPOSE INTERLEAVE
@ -1428,6 +1428,21 @@ msgtarget: NULL_TOKEN
YYERROR;
}
}
| CRE LPAREN INTEGER COMMA INTEGER RPAREN
{
if (gen_level < 75) {
fprintf (stderr, "Below Gen7.5 donesn't have CRE function\n");
YYERROR;
}
$$.bits3.generic.msg_target =
BRW_MESSAGE_TARGET_CRE;
$$.bits2.send_gen5.sfid =
BRW_MESSAGE_TARGET_CRE;
$$.bits3.cre_gen75.binding_table_index = $3;
$$.bits3.cre_gen75.message_type = $5;
$$.bits3.generic_gen5.header_present = 1;
}
| DATA_PORT LPAREN INTEGER COMMA INTEGER COMMA INTEGER COMMA
INTEGER COMMA INTEGER COMMA INTEGER RPAREN

View File

@ -153,6 +153,7 @@ yylval.integer = BRW_CHANNEL_W;
"urb" { return URB; }
"thread_spawner" { return THREAD_SPAWNER; }
"vme" { return VME; }
"cre" { return CRE; }
"data_port" { return DATA_PORT; }
"allocate" { return ALLOCATE; }