summaryrefslogtreecommitdiffstats
path: root/all_pairs
diff options
context:
space:
mode:
Diffstat (limited to 'all_pairs')
-rw-r--r--all_pairs/source/epic/epic.c25
-rw-r--r--all_pairs/source/rijndael_enc/rijndael_enc.c24
2 files changed, 30 insertions, 19 deletions
diff --git a/all_pairs/source/epic/epic.c b/all_pairs/source/epic/epic.c
index a1e344c..ed08040 100644
--- a/all_pairs/source/epic/epic.c
+++ b/all_pairs/source/epic/epic.c
@@ -598,7 +598,7 @@ void epic_main( void );
598 Declaration of global variables 598 Declaration of global variables
599*/ 599*/
600 600
601float epic_filtertemp[FILTER_SIZE]; 601float epic_filtertemp[FILTER_SIZE*2]; // *2 to work around memory corruption issue
602float epic_hi_imagetemp[X_SIZE * Y_SIZE / 2]; 602float epic_hi_imagetemp[X_SIZE * Y_SIZE / 2];
603float epic_lo_imagetemp[X_SIZE * Y_SIZE / 2]; 603float epic_lo_imagetemp[X_SIZE * Y_SIZE / 2];
604 604
@@ -1129,13 +1129,18 @@ int epic_return(){
1129 1129
1130int main( int argc, char **argv ) 1130int main( int argc, char **argv )
1131{ 1131{
1132 SET_UP 1132 int exit_code = -1;
1133 for (jobsComplete=0; jobsComplete<maxJobs; jobsComplete++){ 1133 SET_UP
1134 START_LOOP 1134 for (jobsComplete=0; jobsComplete<maxJobs; jobsComplete++){
1135 epic_init(); 1135 START_LOOP
1136 epic_main(); 1136 epic_init();
1137 STOP_LOOP 1137 epic_main();
1138 } 1138 // This checks the checksum is as expected.
1139 WRITE_TO_FILE 1139 // This is `&` as only the first job will match
1140 return epic_return(); 1140 // (image state persists between jobs).
1141 exit_code &= epic_return();
1142 STOP_LOOP
1143 }
1144 WRITE_TO_FILE
1145 return exit_code;
1141} 1146}
diff --git a/all_pairs/source/rijndael_enc/rijndael_enc.c b/all_pairs/source/rijndael_enc/rijndael_enc.c
index 6c85eee..21d7e67 100644
--- a/all_pairs/source/rijndael_enc/rijndael_enc.c
+++ b/all_pairs/source/rijndael_enc/rijndael_enc.c
@@ -68,6 +68,7 @@ void rijndael_enc_init( void )
68 rijndael_enc_fin.data = rijndael_enc_data; 68 rijndael_enc_fin.data = rijndael_enc_data;
69 rijndael_enc_fin.size = 31369; 69 rijndael_enc_fin.size = 31369;
70 rijndael_enc_fin.cur_pos = 0; 70 rijndael_enc_fin.cur_pos = 0;
71 rijndael_enc_checksum = 0;
71 72
72 unsigned i; 73 unsigned i;
73 volatile int x = 0; 74 volatile int x = 0;
@@ -225,14 +226,19 @@ void _Pragma( "entrypoint" ) rijndael_enc_main( void )
225 226
226int main( int argc, char** argv ) 227int main( int argc, char** argv )
227{ 228{
228 SET_UP 229 int exit_code = -1;
229 for (jobsComplete=0; jobsComplete<maxJobs; jobsComplete++){ 230 SET_UP
230 START_LOOP 231 for (jobsComplete=0; jobsComplete<maxJobs; jobsComplete++){
231 rijndael_enc_init(); 232 START_LOOP
232 rijndael_enc_main(); 233 rijndael_enc_init();
233 STOP_LOOP 234 rijndael_enc_main();
234 } 235 // This checks the checksum is as expected.
235 WRITE_TO_FILE 236 // This is `&` as only the first job will match
236 return ( rijndael_enc_return() ); 237 // (PRNG state persists between jobs).
238 exit_code &= rijndael_enc_return();
239 STOP_LOOP
240 }
241 WRITE_TO_FILE
242 return ( exit_code );
237} 243}
238 244