Skip to content

Commit 1d6b778

Browse files
author
Derek Hower
committed
Merge remote-tracking branch 'origin/main' into cpp_hart
2 parents 581ab14 + 89b27e7 commit 1d6b778

28 files changed

+722
-105
lines changed

Rakefile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ def cfg_arch_for(config_name)
4141
end
4242
end
4343

44-
file "#{$root}/.stamps/dev_gems" do |t|
44+
file "#{$root}/.stamps/dev_gems" => ["#{$root}/.stamps"] do |t|
4545
sh "bundle exec yard config --gem-install-yri"
4646
sh "bundle exec yard gem"
4747
FileUtils.touch t.name

arch/inst/Zcmp/cm.mva01s.yaml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,10 @@ description: |
1010
definedBy:
1111
anyOf:
1212
- Zcmp
13+
excludedBy:
14+
anyOf:
15+
- allOf: [C, D]
16+
- Zcd
1317
assembly: r1s, r2s
1418
encoding:
1519
match: 101011---11---10

arch/inst/Zcmp/cm.mvsa01.yaml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,10 @@ description: |
1212
definedBy:
1313
anyOf:
1414
- Zcmp
15+
excludedBy:
16+
anyOf:
17+
- allOf: [C, D]
18+
- Zcd
1519
assembly: r1s, r2s
1620
encoding:
1721
match: 101011---01---10

arch/inst/Zcmp/cm.pop.yaml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,10 @@ description: |
1717
definedBy:
1818
anyOf:
1919
- Zcmp
20+
excludedBy:
21+
anyOf:
22+
- allOf: [C, D]
23+
- Zcd
2024
assembly: reg_list, stack_adj
2125
encoding:
2226
match: 10111010------10

arch/inst/Zcmp/cm.popret.yaml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,10 @@ description: |
1717
definedBy:
1818
anyOf:
1919
- Zcmp
20+
excludedBy:
21+
anyOf:
22+
- allOf: [C, D]
23+
- Zcd
2024
assembly: reg_list, stack_adj
2125
encoding:
2226
match: 10111110------10

arch/inst/Zcmp/cm.popretz.yaml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,10 @@ description: |
1717
definedBy:
1818
anyOf:
1919
- Zcmp
20+
excludedBy:
21+
anyOf:
22+
- allOf: [C, D]
23+
- Zcd
2024
assembly: reg_list, stack_adj
2125
encoding:
2226
match: 10111100------10

arch/inst/Zcmp/cm.push.yaml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,10 @@ description: |
1818
definedBy:
1919
anyOf:
2020
- Zcmp
21+
excludedBy:
22+
anyOf:
23+
- allOf: [C, D]
24+
- Zcd
2125
assembly: reg_list, -stack_adj
2226
encoding:
2327
match: 10111000------10

cfgs/qc_iu/arch_overlay/csr/Xqci/qc_flags.yaml

Lines changed: 0 additions & 81 deletions
This file was deleted.
Lines changed: 100 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,100 @@
1+
# yaml-language-server: $schema=../../../../schemas/ext_schema.json
2+
3+
$schema: ext_schema.json#
4+
kind: extension
5+
name: Xqccmp
6+
long_name: 16-bit Push/Pop instructions and double-moves
7+
type: unprivileged
8+
versions:
9+
- version: "0.1.0"
10+
state: development
11+
ratification_date: null
12+
contributors:
13+
- name: Albert Yosher
14+
company: Qualcomm Technologies, Inc.
15+
16+
- name: Derek Hower
17+
company: Qualcomm Technologies, Inc.
18+
19+
- name: Ana Pazos
20+
company: Qualcomm Technologies, Inc.
21+
22+
- name: James Ball
23+
company: Qualcomm Technologies, Inc.
24+
25+
requires:
26+
name: Zca
27+
version: ">= 1.0.0"
28+
description: |
29+
The Xqccmp extension is a set of instructions which may be executed as a series of existing 32-bit RISC-V instructions.
30+
31+
This extension reuses some encodings from _c.fsdsp_. Therefore it is _incompatible_ with <<Zcd>>,
32+
which is included when C and D extensions are both present.
33+
34+
NOTE: Xqccmp is primarily targeted at embedded class CPUs due to implementation complexity. Additionally, it is not compatible with architecture class profiles.
35+
36+
The Xqccmp extension depends on the <<Zca>> extension.
37+
38+
The Xqccmp extension using same encodings as Zcmp extension for similar instructions, with 2 major differences:
39+
40+
* Order of load and store of registers is opposite to Zcmp order, but compliant with SW ABI
41+
* Xqccmp on top of Zcmp instructions defines qc.cm.pushfp instruction to manage frame pointer
42+
43+
The PUSH/POP assembly syntax uses several variables, the meaning of which are:
44+
45+
* _reg_list_ is a list containing 1 to 13 registers (ra and 0 to 12 s registers)
46+
** valid values: {ra}, {ra, s0}, {ra, s0-s1}, {ra, s0-s2}, ..., {ra, s0-s8}, {ra, s0-s9}, {ra, s0-s11}
47+
** note that {ra, s0-s10} is _not_ valid, giving 12 lists not 13 for better encoding
48+
* _stack_adj_ is the total size of the stack frame.
49+
** valid values vary with register list length and the specific encoding, see the instruction pages for details.
50+
51+
[%header,cols="^1,^1,4,8"]
52+
|===
53+
|RV32
54+
|RV64
55+
|Mnemonic
56+
|Instruction
57+
58+
|yes
59+
|yes
60+
|qc.cm.push _{reg_list}, -stack_adj_
61+
|<<#insns-qc_cm_push>>
62+
63+
|yes
64+
|yes
65+
|qc.cm.pushfp _{reg_list}, -stack_adj_
66+
|<<#insns-qc_cm_pushfp>>
67+
68+
|yes
69+
|yes
70+
|qc.cm.pop _{reg_list}, stack_adj_
71+
|<<#insns-qc_cm_pop>>
72+
73+
|yes
74+
|yes
75+
|qc.cm.popret _{reg_list}, stack_adj_
76+
|<<#insns-qc_cm_popret>>
77+
78+
|yes
79+
|yes
80+
|qc.cm.popretz _{reg_list}, stack_adj_
81+
|<<#insns-qc_cm_popretz>>
82+
83+
|yes
84+
|yes
85+
|qc.cm.mva01s _rs1', rs2'_
86+
|<<#insns-qc_cm_mva01s>>
87+
88+
|yes
89+
|yes
90+
|qc.cm.mvsa01 _r1s', r2s'_
91+
|<<#insns-qc_cm_mvsa01>>
92+
93+
|===
94+
95+
doc_license:
96+
name: Creative Commons Attribution 4.0 International License
97+
url: https://creativecommons.org/licenses/by/4.0/
98+
company:
99+
name: Qualcomm Technologies, Inc.
100+
url: https://qualcomm.com

cfgs/qc_iu/arch_overlay/ext/Xqci.yaml

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -149,8 +149,13 @@ versions:
149149
changes:
150150
- Fix encoding of qc.c.extu instruction
151151
- Fix encoding of qc.swmi instruction
152+
- Fix decoding of qc.pputci instruction
153+
- Fix decoding of qc.delay instruction (state that immediate cannot be 0)
152154
- Rename qc.slasat -> qc.shlsat
153155
- Rename qc.sllsat -> qc.shlusat
156+
- Add requirement to include Zca extension for Xqcisim since it has 16-bit instructions
157+
- Add requirement to include Zca extension for Xqcisync since it has 16-bit instructions
158+
- Remove qc.flags CSR
154159
implies:
155160
- [Xqcia, "0.4.0"]
156161
- [Xqciac, "0.2.0"]
@@ -159,14 +164,16 @@ versions:
159164
- [Xqcicli, "0.2.0"]
160165
- [Xqcicm, "0.2.0"]
161166
- [Xqcics, "0.2.0"]
162-
- [Xqcicsr, "0.2.0"]
167+
- [Xqcicsr, "0.3.0"]
163168
- [Xqciint, "0.2.0"]
164169
- [Xqcilb, "0.2.0"]
165170
- [Xqcili, "0.2.0"]
166171
- [Xqcilia, "0.2.0"]
167172
- [Xqcilo, "0.2.0"]
168173
- [Xqcilsm, "0.4.0"]
174+
- [Xqcisim, "0.2.0"]
169175
- [Xqcisls, "0.2.0"]
176+
- [Xqcisync, "0.2.0"]
170177
requires:
171178
name: Zca
172179
version: ">= 1.0.0"

0 commit comments

Comments
 (0)