Skip to content
This repository has been archived by the owner on Nov 4, 2024. It is now read-only.

Commit

Permalink
Merge pull request #104 from Sowmya3062/dev
Browse files Browse the repository at this point in the history
Fixes in rv64im.cgf and csr_comb.py
  • Loading branch information
neelgala authored Jan 30, 2024
2 parents 9c61d2d + 4ec38df commit 4996382
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 6 deletions.
5 changes: 3 additions & 2 deletions riscv_ctg/csr_comb.py
Original file line number Diff line number Diff line change
Expand Up @@ -413,8 +413,9 @@ def write_test(self, fprefix, cgf_node, usage_str, cov_label, instr_dict):

case_str = ''.join([case_template.safe_substitute(xlen = self.xlen, num = i, cov_label = cov_label) for i, cond in enumerate(cgf_node.get('config', []))])
test_str = part_template.safe_substitute(case_str = case_str, code = '\n'.join(code))

with open(fprefix + '_csr-comb.S', 'w') as fp:
fname = fprefix + '_csr-comb.S'
logger.debug("Writing Test to %s", str(fname))
with open(fname, 'w') as fp:
fp.write(usage_str + csr_comb_test_template.safe_substitute(
isa = self.base_isa.upper(), # how to get the extensions?
test = test_str,
Expand Down
8 changes: 4 additions & 4 deletions sample_cgfs/rv64im.cgf
Original file line number Diff line number Diff line change
Expand Up @@ -91,7 +91,7 @@ div:
op_comb:
<<: *rfmt_op_comb
val_comb:
<<: [*base_rs1val_sgn , *base_rs2val_sgn , *rfmt_val_comb_sgn]
<<: [*base_rs1val_sgn , *base_rs2val_sgn , *rfmt_val_comb_sgn, *div_corner_case]
abstract_comb:
'sp_dataset(xlen)': 0
<<: [*rs1val_walking, *rs2val_walking]
Expand Down Expand Up @@ -129,7 +129,7 @@ rem:
op_comb:
<<: *rfmt_op_comb
val_comb:
<<: [*base_rs1val_sgn , *base_rs2val_sgn , *rfmt_val_comb_sgn]
<<: [*base_rs1val_sgn , *base_rs2val_sgn , *rfmt_val_comb_sgn, *div_corner_case]
abstract_comb:
'sp_dataset(xlen)': 0
<<: [*rs1val_walking, *rs2val_walking]
Expand Down Expand Up @@ -186,7 +186,7 @@ divw:
op_comb:
<<: *rfmt_op_comb
val_comb:
<<: [*base_rs1val_sgn , *base_rs2val_sgn , *rfmt_val_comb_sgn]
<<: [*base_rs1val_sgn , *base_rs2val_sgn , *rfmt_val_comb_sgn, *div_corner_case]
abstract_comb:
'sp_dataset(xlen)': 0
<<: [*rs1val_walking, *rs2val_walking]
Expand Down Expand Up @@ -224,7 +224,7 @@ remw:
op_comb:
<<: *rfmt_op_comb
val_comb:
<<: [*base_rs1val_sgn , *base_rs2val_sgn , *rfmt_val_comb_sgn]
<<: [*base_rs1val_sgn , *base_rs2val_sgn , *rfmt_val_comb_sgn, *div_corner_case]
abstract_comb:
'sp_dataset(xlen)': 0
<<: [*rs1val_walking, *rs2val_walking]
Expand Down

0 comments on commit 4996382

Please sign in to comment.