aboutsummaryrefslogtreecommitdiff
path: root/target/hexagon/idef-parser/idef-parser.lex
diff options
context:
space:
mode:
authorTaylor Simpson <tsimpson@quicinc.com>2023-03-06 18:58:27 -0800
committerTaylor Simpson <tsimpson@quicinc.com>2023-03-06 20:47:12 -0800
commit7b84fd04bda9aab5735cdf359c2c8e39f0a31713 (patch)
tree5e4ea7fcaaa70395ccdd45f575b7c5621dc01616 /target/hexagon/idef-parser/idef-parser.lex
parente28b77a6b46bfec17ffb1f9764713b2c97418fb3 (diff)
downloadqemu-7b84fd04bda9aab5735cdf359c2c8e39f0a31713.zip
qemu-7b84fd04bda9aab5735cdf359c2c8e39f0a31713.tar.gz
qemu-7b84fd04bda9aab5735cdf359c2c8e39f0a31713.tar.bz2
Hexagon (target/hexagon) Reduce manipulation of slot_cancelled
We only need to track slot for predicated stores and predicated HVX instructions. Add arguments to the probe helper functions to indicate if the slot is predicated. Here is a simple example of the differences in the TCG code generated: IN: 0x00400094: 0xf900c102 { if (P0) R2 = and(R0,R1) } BEFORE ---- 00400094 mov_i32 slot_cancelled,$0x0 mov_i32 new_r2,r2 and_i32 tmp0,p0,$0x1 brcond_i32 tmp0,$0x0,eq,$L1 and_i32 tmp0,r0,r1 mov_i32 new_r2,tmp0 br $L2 set_label $L1 or_i32 slot_cancelled,slot_cancelled,$0x8 set_label $L2 mov_i32 r2,new_r2 AFTER ---- 00400094 mov_i32 new_r2,r2 and_i32 tmp0,p0,$0x1 brcond_i32 tmp0,$0x0,eq,$L1 and_i32 tmp0,r0,r1 mov_i32 new_r2,tmp0 br $L2 set_label $L1 set_label $L2 mov_i32 r2,new_r2 Signed-off-by: Taylor Simpson <tsimpson@quicinc.com> Reviewed-by: Anton Johansson <anjo@rev.ng> Message-Id: <20230307025828.1612809-14-tsimpson@quicinc.com>
Diffstat (limited to 'target/hexagon/idef-parser/idef-parser.lex')
-rw-r--r--target/hexagon/idef-parser/idef-parser.lex4
1 files changed, 2 insertions, 2 deletions
diff --git a/target/hexagon/idef-parser/idef-parser.lex b/target/hexagon/idef-parser/idef-parser.lex
index 2658d9f..5eb8ac5 100644
--- a/target/hexagon/idef-parser/idef-parser.lex
+++ b/target/hexagon/idef-parser/idef-parser.lex
@@ -5,7 +5,7 @@
%{
/*
- * Copyright(c) 2019-2022 rev.ng Labs Srl. All Rights Reserved.
+ * Copyright(c) 2019-2023 rev.ng Labs Srl. All Rights Reserved.
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
@@ -312,7 +312,7 @@ STRING_LIT \"(\\.|[^"\\])*\"
"fREAD_PC()" { return PC; }
"USR.LPCFG" { return LPCFG; }
"LOAD_CANCEL(EA)" { return LOAD_CANCEL; }
-"STORE_CANCEL(EA)" |
+"STORE_CANCEL(EA)" { return STORE_CANCEL; }
"CANCEL" { return CANCEL; }
"N"{LOWER_ID}"N" { yylval->rvalue.type = REGISTER_ARG;
yylval->rvalue.reg.type = DOTNEW;