Skip to content

Commit 115ff2b

Browse files
committed
minor fixes
1 parent 896c593 commit 115ff2b

File tree

5 files changed

+308
-177
lines changed

5 files changed

+308
-177
lines changed

ci/regression.sh.in

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -363,8 +363,8 @@ scope()
363363
{
364364
echo "begin scope tests..."
365365

366-
SCOPE_DEPTH=256 ./ci/blackbox.sh --driver=opae --app=demo --args="-n1" --scope
367-
SCOPE_DEPTH=256 ./ci/blackbox.sh --driver=xrt --app=demo --args="-n1" --scope
366+
SCOPE_DEPTH=128 ./ci/blackbox.sh --driver=opae --app=demo --args="-n1" --scope
367+
SCOPE_DEPTH=128 ./ci/blackbox.sh --driver=xrt --app=demo --args="-n1" --scope
368368

369369
echo "debugging scope done!"
370370
}
@@ -385,7 +385,7 @@ synthesis()
385385
echo "begin synthesis tests..."
386386

387387
PREFIX=build_base make -C hw/syn/yosys clean
388-
PREFIX=build_base CONFIGS="-DDPI_DISABLE -DEXT_F_DISABLE" make -C hw/syn/yosys synthesis
388+
PREFIX=build_base CONFIGS="-DDPI_DISABLE -DEXT_F_DISABLE -DNUM_WARPS=2 -DNUM_THREADS=2" make -C hw/syn/yosys synthesis
389389

390390
echo "synthesis tests done!"
391391
}

perf/cache/cache_perf.log

Lines changed: 0 additions & 3 deletions
This file was deleted.

perf/cache/run.sh

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -10,17 +10,17 @@ sgemm()
1010
{
1111
echo "begin cache tests"
1212

13-
CONFIGS="-DICACHE_NUM_WAYS=2" ./ci/blackbox.sh --driver=rtlsim --app=sgemm --args="-n64" --perf=1 | grep 'PERF' > ./perf/cache/cache_perf.log
14-
echo -e "\n**************************************\n" >> ./perf/cache/cache_perf.log
15-
CONFIGS="-DDCACHE_NUM_WAYS=2" ./ci/blackbox.sh --driver=rtlsim --app=sgemm --args="-n64" --perf=1 | grep 'PERF' >> ./perf/cache/cache_perf.log
16-
echo -e "\n**************************************\n" >> ./perf/cache/cache_perf.log
17-
CONFIGS="-DICACHE_NUM_WAYS=4" ./ci/blackbox.sh --driver=rtlsim --app=sgemm --args="-n64" --perf=1 | grep 'PERF' >> ./perf/cache/cache_perf.log
18-
echo -e "\n**************************************\n" >> ./perf/cache/cache_perf.log
19-
CONFIGS="-DDCACHE_NUM_WAYS=4" ./ci/blackbox.sh --driver=rtlsim --app=sgemm --args="-n64" --perf=1 | grep 'PERF' >> ./perf/cache/cache_perf.log
20-
echo -e "\n**************************************\n" >> ./perf/cache/cache_perf.log
21-
CONFIGS="-DICACHE_NUM_WAYS=8" ./ci/blackbox.sh --driver=rtlsim --app=sgemm --args="-n64" --perf=1 | grep 'PERF' >> ./perf/cache/cache_perf.log
22-
echo -e "\n**************************************\n" >> ./perf/cache/cache_perf.log
23-
CONFIGS="-DDCACHE_NUM_WAYS=8" ./ci/blackbox.sh --driver=rtlsim --app=sgemm --args="-n64" --perf=1 | grep 'PERF' >> ./perf/cache/cache_perf.log
13+
CONFIGS="-DICACHE_NUM_WAYS=2" ./ci/blackbox.sh --driver=rtlsim --app=sgemm --args="-n64" --perf=1 | grep 'PERF' > cache_perf.log
14+
echo -e "\n**************************************\n" >> cache_perf.log
15+
CONFIGS="-DDCACHE_NUM_WAYS=2" ./ci/blackbox.sh --driver=rtlsim --app=sgemm --args="-n64" --perf=1 | grep 'PERF' >> cache_perf.log
16+
echo -e "\n**************************************\n" >> cache_perf.log
17+
CONFIGS="-DICACHE_NUM_WAYS=4" ./ci/blackbox.sh --driver=rtlsim --app=sgemm --args="-n64" --perf=1 | grep 'PERF' >> cache_perf.log
18+
echo -e "\n**************************************\n" >> cache_perf.log
19+
CONFIGS="-DDCACHE_NUM_WAYS=4" ./ci/blackbox.sh --driver=rtlsim --app=sgemm --args="-n64" --perf=1 | grep 'PERF' >> cache_perf.log
20+
echo -e "\n**************************************\n" >> cache_perf.log
21+
CONFIGS="-DICACHE_NUM_WAYS=8" ./ci/blackbox.sh --driver=rtlsim --app=sgemm --args="-n64" --perf=1 | grep 'PERF' >> cache_perf.log
22+
echo -e "\n**************************************\n" >> cache_perf.log
23+
CONFIGS="-DDCACHE_NUM_WAYS=8" ./ci/blackbox.sh --driver=rtlsim --app=sgemm --args="-n64" --perf=1 | grep 'PERF' >> cache_perf.log
2424

2525
echo "cache tests done!"
2626
}
@@ -36,6 +36,6 @@ case $1 in
3636
-h | --help ) usage
3737
;;
3838
* ) sgemm
39-
;;
39+
;;
4040
esac
4141
shift

sim/common/softfloat_ext.cpp

Lines changed: 12 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -148,10 +148,9 @@ static inline uint64_t rsqrte7(uint64_t val, int e, int s, bool sub) {
148148
59, 58, 57, 56, 56, 55, 54, 53};
149149

150150
if (sub) {
151-
while (extract64(sig, s - 1, 1) == 0) {
152-
exp--;
153-
sig <<= 1;
154-
}
151+
while (extract64(sig, s - 1, 1) == 0)
152+
exp--, sig <<= 1;
153+
155154
sig = (sig << 1) & make_mask64(0, s);
156155
}
157156

@@ -358,9 +357,9 @@ float16_t f16_recip7(float16_t in) {
358357
[[fallthrough]];
359358
default: // +- normal
360359
uA.ui = recip7(uA.ui, 5, 10, softfloat_roundingMode, sub, &round_abnormal);
361-
if (round_abnormal)
362-
softfloat_exceptionFlags |=
363-
softfloat_flag_inexact | softfloat_flag_overflow;
360+
if (round_abnormal) {
361+
softfloat_exceptionFlags |= softfloat_flag_inexact | softfloat_flag_overflow;
362+
}
364363
break;
365364
}
366365

@@ -401,9 +400,9 @@ float32_t f32_recip7(float32_t in) {
401400
[[fallthrough]];
402401
default: // +- normal
403402
uA.ui = recip7(uA.ui, 8, 23, softfloat_roundingMode, sub, &round_abnormal);
404-
if (round_abnormal)
405-
softfloat_exceptionFlags |=
406-
softfloat_flag_inexact | softfloat_flag_overflow;
403+
if (round_abnormal) {
404+
softfloat_exceptionFlags |= softfloat_flag_inexact | softfloat_flag_overflow;
405+
}
407406
break;
408407
}
409408

@@ -444,9 +443,9 @@ float64_t f64_recip7(float64_t in) {
444443
[[fallthrough]];
445444
default: // +- normal
446445
uA.ui = recip7(uA.ui, 11, 52, softfloat_roundingMode, sub, &round_abnormal);
447-
if (round_abnormal)
448-
softfloat_exceptionFlags |=
449-
softfloat_flag_inexact | softfloat_flag_overflow;
446+
if (round_abnormal) {
447+
softfloat_exceptionFlags |= softfloat_flag_inexact | softfloat_flag_overflow;
448+
}
450449
break;
451450
}
452451

0 commit comments

Comments
 (0)