aboutsummaryrefslogtreecommitdiffstats
path: root/tests/realmath
diff options
context:
space:
mode:
authorClifford Wolf <clifford@clifford.at>2014-06-17 12:47:51 +0200
committerClifford Wolf <clifford@clifford.at>2014-06-17 12:47:51 +0200
commit798ff88855a6e9b8eb82a48fb4d39f78807200d9 (patch)
treeddc3fad193c0e43fbc91b95a398e2e7682ff5f9a /tests/realmath
parent88470283c995860c593bae03373a0b26408b0e94 (diff)
downloadyosys-798ff88855a6e9b8eb82a48fb4d39f78807200d9.tar.gz
yosys-798ff88855a6e9b8eb82a48fb4d39f78807200d9.tar.bz2
yosys-798ff88855a6e9b8eb82a48fb4d39f78807200d9.zip
Improved handling of relational op of real values
Diffstat (limited to 'tests/realmath')
-rw-r--r--tests/realmath/generate.py12
1 files changed, 8 insertions, 4 deletions
diff --git a/tests/realmath/generate.py b/tests/realmath/generate.py
index 9e48755c5..53015381e 100644
--- a/tests/realmath/generate.py
+++ b/tests/realmath/generate.py
@@ -43,11 +43,15 @@ for idx in range(100):
with file('temp/uut_%05d.v' % idx, 'w') as f, redirect_stdout(f):
print('module uut_%05d(output [63:0] %s);\n' % (idx, ', '.join(['y%02d' % i for i in range(100)])))
for i in range(30):
- print('localparam p%02d = %s;' % (i, random_expression()))
- # print('localparam%s p%02d = %s;' % (random.choice(['', ' real', ' integer']), i, random_expression()))
+ if idx < 10 or True:
+ print('localparam p%02d = %s;' % (i, random_expression()))
+ else:
+ print('localparam%s p%02d = %s;' % (random.choice(['', ' real', ' integer']), i, random_expression()))
for i in range(30, 60):
- print('localparam p%02d = %s;' % (i, random_expression(maxparam = 30)))
- # print('localparam%s p%02d = %s;' % (random.choice(['', ' real', ' integer']), i, random_expression(maxparam = 30)))
+ if idx < 10 or True:
+ print('localparam p%02d = %s;' % (i, random_expression(maxparam = 30)))
+ else:
+ print('localparam%s p%02d = %s;' % (random.choice(['', ' real', ' integer']), i, random_expression(maxparam = 30)))
for i in range(100):
print('assign y%02d = 65536 * (%s);' % (i, random_expression(maxparam = 60)))
print('endmodule')