forked from Firmware/Firmwares
error exit
Trigger err_exit module to stop the SystemC simualtion if the data check fails
This commit is contained in:
parent
4dbbb73f01
commit
62cdc0c7b9
Binary file not shown.
@ -42,9 +42,12 @@ bool check_results(int addr, int k) {
|
||||
bool result = 0;
|
||||
int step = 500;
|
||||
double *res_base = (double*) (addr);
|
||||
int * error_exit = (int *)0xF0000000;
|
||||
|
||||
for (int i = 0; i < step; i++) {
|
||||
if (!double_equals(res_base[i] * ln2, ref_data.at(k + i))) {
|
||||
printf("XSPN ref %d comparison FAILED\n", k + i);
|
||||
*error_exit = 0x1;
|
||||
result = 1;
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user