Skip to content

Commit 86b26a5

Browse files
committed
RISC-V: Expose sew and lmul to mp_seq.py command line
Signed-Off-By: Patrick O'Neill <[email protected]>
1 parent b7c04f3 commit 86b26a5

File tree

1 file changed

+26
-0
lines changed

1 file changed

+26
-0
lines changed

targets/generic/tools/mp_seq.py

Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -157,6 +157,8 @@ def _generic_policy_wrapper(all_arguments: Tuple[List[InstructionType], str,
157157
extra_arguments['dependency_distance'] = kwargs['dependency_distance']
158158
extra_arguments['force_switch'] = kwargs['force_switch']
159159
extra_arguments['endless'] = kwargs['endless']
160+
extra_arguments["lmul"] = kwargs["lmul"]
161+
extra_arguments["sew"] = kwargs["sew"]
160162

161163
if wrapper.outputname(outputfile) != outputfile:
162164
print_error(
@@ -205,6 +207,9 @@ def main():
205207
groupname = "SEQ arguments"
206208
cmdline.add_group(groupname,
207209
"Command arguments related to Sequence generation")
210+
riscv_groupname = "RISC-V specific options"
211+
cmdline.add_group(riscv_groupname,
212+
"Command arguments only valid for the RISC-V target")
208213

209214
cmdline.add_option("seq-output-dir",
210215
"D",
@@ -214,6 +219,27 @@ def main():
214219
opt_type=existing_dir,
215220
required=True)
216221

222+
223+
cmdline.add_option(
224+
"lmul",
225+
"lmul",
226+
1,
227+
"lmul for vector insns (only valid for RISCV backend)",
228+
group=riscv_groupname,
229+
opt_type=int_type(1, 8),
230+
required=False,
231+
)
232+
233+
cmdline.add_option(
234+
"sew",
235+
"sew",
236+
32,
237+
"Selected element width for vector insns (only valid for RISCV backend)",
238+
group=riscv_groupname,
239+
opt_type=int_type(8, 64),
240+
required=False,
241+
)
242+
217243
cmdline.add_option(
218244
"instruction-slots",
219245
"is",

0 commit comments

Comments
 (0)