|
|
1.1 ! root 1: 1 00000000 LL0: ! 2: 2 00000000 .data ! 3: 3 00000a58 * .text ! 4: 4 00000000 .align 1 ! 5: 5 00000000 .globl _cosf ! 6: 6 00000000 _cosf: ! 7: 7 00022A78 0000 .word L215 ! 8: 8 00022A7A # #include "fpp_defs.h" ! 9: 9 00022A7A # ! 10: 10 00022A7A # ! 11: 11 00022A7A # ! 12: 12 00022A7A # /*************************************************************************** ! 13: 13 00022A7A # * ! 14: 14 00022A7A # * COSF - SINGLE PRECISION FLOATING POINT COSF FUNCTION TEST ! 15: 15 00022A7A # * ! 16: 16 00022A7A # * COSF TEST MONITOR ! 17: 17 00022A7A # * ! 18: 18 00022A7A # *****************************************************************************/ ! 19: 19 00022A7A # cosf() ! 20: 20 00022A7A # { ! 21: 21 00022A7A 11 48 jbr L217 ! 22: 22 00022A7C L218: ! 23: 23 00022A7C # asm(".globl _cosf_t"); ! 24: 24 00022A7C .globl _cosf_t ! 25: 25 00022A7C # asm("_cosf_t:"); /* entry address */ ! 26: 26 00022A7C _cosf_t: ! 27: 27 00022A7C # if( ( cycle == 1 ) && ( prt_hdrs ) ) /* print headers on 1st pass */ ! 28: 28 00022A7C 1d effffffff6 01 cmpl _cycle,$1 ! 29: 29 00022A83 21 15 jneq L219 ! 30: 30 00022A85 5d efffffffed tstl _prt_hdrs ! 31: 31 00022A8B 31 0d jeql L219 ! 32: 32 00022A8D # { ! 33: 33 00022A8D # writes(" COSF"); ! 34: 34 00022A8D .data 1 ! 35: 35 00000a58 * L221: ! 36: 36 00000a58 * 20434F534600 .ascii " COSF\0" ! 37: 37 00000a5e * .text ! 38: 38 00022A8D dd 8f00000a58 pushl $L221 ! 39: 39 00022A93 fe 08 efffffffde callf $8,_writes ! 40: 40 00022A9A # } ! 41: 41 00022A9A # cosf_1(); /* test square root w/ delay */ ! 42: 42 00022A9A L219: ! 43: 43 00022A9A fe 04 ef00000025 callf $4,_cosf_1 ! 44: 44 00022AA1 # cosf_2(); /* test square root */ ! 45: 45 00022AA1 fe 04 ef00000190 callf $4,_cosf_2 ! 46: 46 00022AA8 # cosf_3(); /* register corruption */ ! 47: 47 00022AA8 fe 04 ef000002e9 callf $4,_cosf_3 ! 48: 48 00022AAF # /* cosf_4(); /* test the PSL */ ! 49: 49 00022AAF # cosf_5(); /* pipelined entry */ ! 50: 50 00022AAF fe 04 ef0000067c callf $4,_cosf_5 ! 51: 51 00022AB6 # cosf_6(); /* pipelined exit */ ! 52: 52 00022AB6 fe 04 ef000007d1 callf $4,_cosf_6 ! 53: 53 00022ABD # asm("jmp *return"); /* return to the test monitor */ ! 54: 54 00022ABD 71 ffffffffb5 jmp *return ! 55: 55 00022AC3 # } ! 56: 56 00022AC3 40 ret#2 ! 57: 57 00022AC4 .set L215,0x0 ! 58: 58 00022AC4 L217: ! 59: 59 00022AC4 11 b6 jbr L218 ! 60: 60 00022AC6 .data ! 61: 61 00000a58 * .text ! 62: 62 00022AC6 .align 1 ! 63: 63 00022AC6 .globl _cosf_1 ! 64: 64 00022AC6 _cosf_1: ! 65: 65 00022AC6 0000 .word L227 ! 66: 66 00022AC8 # ! 67: 67 00022AC8 # /*************************************************************************** ! 68: 68 00022AC8 # * ! 69: 69 00022AC8 # * SUBTEST 1 - COSF FUNCTION ! 70: 70 00022AC8 # * ! 71: 71 00022AC8 # ***************************************************************************/ ! 72: 72 00022AC8 # cosf_1() ! 73: 73 00022AC8 # { ! 74: 74 00022AC8 13 016a jbr L229 ! 75: 75 00022ACB L230: ! 76: 76 00022ACB # #define DELAY 20 /* wait 40 ticks between COSF and STF */ ! 77: 77 00022ACB # force_loop = FALSE; /* clear the LOOP flag */ ! 78: 78 00022ACB 4d efffffffa7 clrl _force_loop ! 79: 79 00022AD1 # subtest = 1; ! 80: 80 00022AD1 0d 01 efffffffa0 movl $1,_subtest ! 81: 81 00022AD8 # index = 0; ! 82: 82 00022AD8 4d efffffff9a clrl _index ! 83: 83 00022ADE # do ! 84: 84 00022ADE L233: ! 85: 85 00022ADE # { ! 86: 86 00022ADE # sgl_ld_acc = cosf_1_data[index].ld; /* get the operand */ ! 87: 87 00022ADE 0d efffffff94 50 movl _index,r0 ! 88: 88 00022AE5 48 03 50 50 shll $3,r0,r0 ! 89: 89 00022AE9 0d e000000000 efffffff84 movl _cosf_1_data(r0),_sgl_ld_acc ! 90: 90 00022AF4 # sgl_expected = cosf_1_data[index].exp; /* get expected results */ ! 91: 91 00022AF4 0d efffffff7e 50 movl _index,r0 ! 92: 92 00022AFB 48 03 50 50 shll $3,r0,r0 ! 93: 93 00022AFF 0d e000000004 efffffff6e movl _cosf_1_data+4(r0),_sgl_expected ! 94: 94 00022B0A # sgl_dummy1 = DELAY; ! 95: 95 00022B0A 0d 14 efffffff67 movl $20,_sgl_dummy1 ! 96: 96 00022B11 # /* ! 97: 97 00022B11 # * If LOOP ON ERROR is set, this is the loop for this subtest. ! 98: 98 00022B11 # * The force loop flag is set after the first error. ! 99: 99 00022B11 # */ ! 100: 100 00022B11 # asm("_cosf_1_lp1:"); ! 101: 101 00022B11 _cosf_1_lp1: ! 102: 102 00022B11 # asm("movl _sgl_ld_acc,r4"); /* set the data to load */ ! 103: 103 00022B11 0d efffffff61 54 movl _sgl_ld_acc,r4 ! 104: 104 00022B18 # asm("ldf r4"); /* load the accumulator */ ! 105: 105 00022B18 06 54 ldf r4 ! 106: 106 00022B1A # asm("movl _sgl_dummy1,r0"); /* get the delay factor */ ! 107: 107 00022B1A 0d efffffff58 50 movl _sgl_dummy1,r0 ! 108: 108 00022B21 # asm("cosf"); /* get ACC.'s cosine */ ! 109: 109 00022B21 15 cosf ! 110: 110 00022B22 # asm("1:"); ! 111: 111 00022B22 1: ! 112: 112 00022B22 # asm("decl r0"); /* delay to let the COSF */ ! 113: 113 00022B22 7d 50 decl r0 ! 114: 114 00022B24 # asm("bgtr 1b"); /* instruction finish */ ! 115: 115 00022B24 41 fc bgtr 1b ! 116: 116 00022B26 # asm("stf r5"); /* store the result */ ! 117: 117 00022B26 26 55 stf r5 ! 118: 118 00022B28 # if( force_loop ) ! 119: 119 00022B28 5d efffffff4a tstl _force_loop ! 120: 120 00022B2E 31 02 jeql L234 ! 121: 121 00022B30 # asm("brb _cosf_1_lp1");; /* loop on the error */ ! 122: 122 00022B30 11 df brb _cosf_1_lp1 ! 123: 123 00022B32 L234: ! 124: 124 00022B32 # /* ! 125: 125 00022B32 # * end error loop ! 126: 126 00022B32 # */ ! 127: 127 00022B32 # asm("movl r5,_sgl_st_acc"); /* save the result */ ! 128: 128 00022B32 0d 55 efffffff3f movl r5,_sgl_st_acc ! 129: 129 00022B39 # if( sgl_st_acc != sgl_expected ) /* COMPARE the values */ ! 130: 130 00022B39 1d efffffff39 efffffff34 cmpl _sgl_st_acc,_sgl_expected ! 131: 131 00022B44 21 03 13 00d2 jeql L235 ! 132: 132 00022B49 # { ! 133: 133 00022B49 # errcnt++; /* bump the error count */ ! 134: 134 00022B49 6d efffffff29 incl _errcnt ! 135: 135 00022B4F # if ( prt_error ) { ! 136: 136 00022B4F 5d efffffff23 tstl _prt_error ! 137: 137 00022B55 21 03 13 009b jeql L236 ! 138: 138 00022B5A # writes(" \n"); /* start a new print line */ ! 139: 139 00022B5A .data 1 ! 140: 140 00000a5e * L237: ! 141: 141 00000a5e * 200A00 .ascii " \12\0" ! 142: 142 00000a61 * .text ! 143: 143 00022B5A dd 8f00000a5e pushl $L237 ! 144: 144 00022B60 fe 08 efffffff11 callf $8,_writes ! 145: 145 00022B67 # writes("cycle: "); ! 146: 146 00022B67 .data 1 ! 147: 147 00000a61 * L238: ! 148: 148 00000a61 * 6379636C653A2000 .ascii "cycle: \0" ! 149: 149 00000a69 * .text ! 150: 150 00022B67 dd 8f00000a61 pushl $L238 ! 151: 151 00022B6D fe 08 efffffff04 callf $8,_writes ! 152: 152 00022B74 # writed( cycle ); ! 153: 153 00022B74 dd effffffefe pushl _cycle ! 154: 154 00022B7A fe 08 effffffef7 callf $8,_writed ! 155: 155 00022B81 # writes(" COSF test "); ! 156: 156 00022B81 .data 1 ! 157: 157 00000a69 * L240: ! 158: 158 00000a69 * 202020434F534620746573742 .ascii " COSF test \0" ! 159: 000 ! 160: 159 00000a77 * .text ! 161: 160 00022B81 dd 8f00000a69 pushl $L240 ! 162: 161 00022B87 fe 08 effffffeea callf $8,_writes ! 163: 162 00022B8E # writed( test_no ); ! 164: 163 00022B8E dd effffffee4 pushl _test_no ! 165: 164 00022B94 fe 08 effffffedd callf $8,_writed ! 166: 165 00022B9B # writes(", subtest 1 (delayed store) - BAD FINAL ACC\n"); ! 167: 166 00022B9B .data 1 ! 168: 167 00000a77 * L241: ! 169: 168 00000a77 * 2C20737562746573742031202 .ascii ", subtest 1 (delayed store) - BAD FINAL ACC\12\0" ! 170: 864656C617965642073746F72 ! 171: 6529202D204241442046494E4 ! 172: 14C204143430A00 ! 173: 169 00000aa4 * .text ! 174: 170 00022B9B dd 8f00000a77 pushl $L241 ! 175: 171 00022BA1 fe 08 effffffed0 callf $8,_writes ! 176: 172 00022BA8 # print_cosf_data(); ! 177: 173 00022BA8 fe 04 ef0000083b callf $4,_print_cosf_data ! 178: 174 00022BAF # writes(", data index = "); ! 179: 175 00022BAF .data 1 ! 180: 176 00000aa4 * L243: ! 181: 177 00000aa4 * 2C20206461746120696E64657 .ascii ", data index = \0" ! 182: 8203D2000 ! 183: 178 00000ab5 * .text ! 184: 179 00022BAF dd 8f00000aa4 pushl $L243 ! 185: 180 00022BB5 fe 08 effffffebc callf $8,_writes ! 186: 181 00022BBC # writed( index ); ! 187: 182 00022BBC dd effffffeb6 pushl _index ! 188: 183 00022BC2 fe 08 effffffeaf callf $8,_writed ! 189: 184 00022BC9 # writec('\n'); ! 190: 185 00022BC9 dd 0a pushl $10 ! 191: 186 00022BCB fe 08 effffffea6 callf $8,_writec ! 192: 187 00022BD2 # writes(" Acc expected = "); ! 193: 188 00022BD2 .data 1 ! 194: 189 00000ab5 * L245: ! 195: 190 00000ab5 * 2020202020202020202020202 .ascii " Acc expected = \0" ! 196: 0202020202020202020416363 ! 197: 206578706563746564203D200 ! 198: 0 ! 199: 191 00000adb * .text ! 200: 192 00022BD2 dd 8f00000ab5 pushl $L245 ! 201: 193 00022BD8 fe 08 effffffe99 callf $8,_writes ! 202: 194 00022BDF # write32h( sgl_expected ); ! 203: 195 00022BDF dd effffffe93 pushl _sgl_expected ! 204: 196 00022BE5 fe 08 effffffe8c callf $8,_write32h ! 205: 197 00022BEC # writec('\n'); ! 206: 198 00022BEC dd 0a pushl $10 ! 207: 199 00022BEE fe 08 effffffe83 callf $8,_writec ! 208: 200 00022BF5 # } ! 209: 201 00022BF5 # if ( halt_flg ) /* halt on error? */ ! 210: 202 00022BF5 L236: ! 211: 203 00022BF5 5d effffffe7d tstl _halt_flg ! 212: 204 00022BFB 31 09 jeql L247 ! 213: 205 00022BFD # cosf_er_halt( BAD_ACC_HLT ); ! 214: 206 00022BFD dd 01 pushl $1 ! 215: 207 00022BFF fe 08 ef00000820 callf $8,_cosf_er_halt ! 216: 208 00022C06 # if ( loop_on_err ) ! 217: 209 00022C06 L247: ! 218: 210 00022C06 5d effffffe6c tstl _loop_on_err ! 219: 211 00022C0C 31 0d jeql L249 ! 220: 212 00022C0E # { ! 221: 213 00022C0E # force_loop = TRUE; /* set the force loop flag */ ! 222: 214 00022C0E 0d 01 effffffe63 movl $1,_force_loop ! 223: 215 00022C15 # asm("jmp _cosf_1_lp1"); /* and loop */ ! 224: 216 00022C15 71 effffffef6 jmp _cosf_1_lp1 ! 225: 217 00022C1B # } ! 226: 218 00022C1B # } /* end of compare error */ ! 227: 219 00022C1B L249: ! 228: 220 00022C1B # } while( index++ < max_cosf_1_index ); ! 229: 221 00022C1B L235: ! 230: 222 00022C1B L232: ! 231: 223 00022C1B 0d effffffe57 50 movl _index,r0 ! 232: 224 00022C22 6d effffffe50 incl _index ! 233: 225 00022C28 1d 50 effffffe49 cmpl r0,_max_cosf_1_index ! 234: 226 00022C2F 81 03 13 feaa jlss L233 ! 235: 227 00022C34 L231: ! 236: 228 00022C34 # } /* end of subtest 1 */ ! 237: 229 00022C34 40 ret#2 ! 238: 230 00022C35 .set L227,0x0 ! 239: 231 00022C35 L229: ! 240: 232 00022C35 13 fe93 jbr L230 ! 241: 233 00022C38 .data ! 242: 234 00000a58 * .text ! 243: 235 00022C38 .align 1 ! 244: 236 00022C38 .globl _cosf_2 ! 245: 237 00022C38 _cosf_2: ! 246: 238 00022C38 0000 .word L250 ! 247: 239 00022C3A # ! 248: 240 00022C3A # ! 249: 241 00022C3A # ! 250: 242 00022C3A # /*************************************************************************** ! 251: 243 00022C3A # * ! 252: 244 00022C3A # * SUBTEST 2 - COSF FUNCTION ! 253: 245 00022C3A # * ! 254: 246 00022C3A # ***************************************************************************/ ! 255: 247 00022C3A # cosf_2() ! 256: 248 00022C3A # { ! 257: 249 00022C3A 13 0158 jbr L252 ! 258: 250 00022C3D L253: ! 259: 251 00022C3D # force_loop = FALSE; /* clear the LOOP flag */ ! 260: 252 00022C3D 4d effffffe35 clrl _force_loop ! 261: 253 00022C43 # subtest = 2; ! 262: 254 00022C43 0d 02 effffffe2e movl $2,_subtest ! 263: 255 00022C4A # index = 0; ! 264: 256 00022C4A 4d effffffe28 clrl _index ! 265: 257 00022C50 # do ! 266: 258 00022C50 L256: ! 267: 259 00022C50 # { ! 268: 260 00022C50 # sgl_ld_acc = cosf_1_data[index].ld; /* get the operand */ ! 269: 261 00022C50 0d effffffe22 50 movl _index,r0 ! 270: 262 00022C57 48 03 50 50 shll $3,r0,r0 ! 271: 263 00022C5B 0d e000000000 effffffe12 movl _cosf_1_data(r0),_sgl_ld_acc ! 272: 264 00022C66 # sgl_expected = cosf_1_data[index].exp; /* get expected results */ ! 273: 265 00022C66 0d effffffe0c 50 movl _index,r0 ! 274: 266 00022C6D 48 03 50 50 shll $3,r0,r0 ! 275: 267 00022C71 0d e000000004 effffffdfc movl _cosf_1_data+4(r0),_sgl_expected ! 276: 268 00022C7C # /* ! 277: 269 00022C7C # * If LOOP ON ERROR is set, this is the loop for this subtest. ! 278: 270 00022C7C # * The force loop flag is set after the first error. ! 279: 271 00022C7C # */ ! 280: 272 00022C7C # asm("_cosf_2_lp1:"); ! 281: 273 00022C7C _cosf_2_lp1: ! 282: 274 00022C7C # asm("movl _sgl_ld_acc,r4"); /* set the data to load */ ! 283: 275 00022C7C 0d effffffdf6 54 movl _sgl_ld_acc,r4 ! 284: 276 00022C83 # asm("ldf r4"); /* load the accumulator */ ! 285: 277 00022C83 06 54 ldf r4 ! 286: 278 00022C85 # asm("cosf"); /* get ACC.'s cosine */ ! 287: 279 00022C85 15 cosf ! 288: 280 00022C86 # asm("stf r5"); /* store the result */ ! 289: 281 00022C86 26 55 stf r5 ! 290: 282 00022C88 # if( force_loop ) ! 291: 283 00022C88 5d effffffdea tstl _force_loop ! 292: 284 00022C8E 31 02 jeql L257 ! 293: 285 00022C90 # asm("brb _cosf_2_lp1");; /* loop on the error */ ! 294: 286 00022C90 11 ea brb _cosf_2_lp1 ! 295: 287 00022C92 L257: ! 296: 288 00022C92 # /* ! 297: 289 00022C92 # * end error loop ! 298: 290 00022C92 # */ ! 299: 291 00022C92 # asm("movl r5,_sgl_st_acc"); /* save the result */ ! 300: 292 00022C92 0d 55 effffffddf movl r5,_sgl_st_acc ! 301: 293 00022C99 # if( sgl_st_acc != sgl_expected ) /* COMPARE the values */ ! 302: 294 00022C99 1d effffffdd9 effffffdd4 cmpl _sgl_st_acc,_sgl_expected ! 303: 295 00022CA4 21 03 13 00d2 jeql L258 ! 304: 296 00022CA9 # { ! 305: 297 00022CA9 # errcnt++; /* bump the error count */ ! 306: 298 00022CA9 6d effffffdc9 incl _errcnt ! 307: 299 00022CAF # if ( prt_error ) { ! 308: 300 00022CAF 5d effffffdc3 tstl _prt_error ! 309: 301 00022CB5 21 03 13 009b jeql L259 ! 310: 302 00022CBA # writes(" \n"); /* start a new print line */ ! 311: 303 00022CBA .data 1 ! 312: 304 00000adb * L260: ! 313: 305 00000adb * 200A00 .ascii " \12\0" ! 314: 306 00000ade * .text ! 315: 307 00022CBA dd 8f00000adb pushl $L260 ! 316: 308 00022CC0 fe 08 effffffdb1 callf $8,_writes ! 317: 309 00022CC7 # writes("cycle: "); ! 318: 310 00022CC7 .data 1 ! 319: 311 00000ade * L261: ! 320: 312 00000ade * 6379636C653A2000 .ascii "cycle: \0" ! 321: 313 00000ae6 * .text ! 322: 314 00022CC7 dd 8f00000ade pushl $L261 ! 323: 315 00022CCD fe 08 effffffda4 callf $8,_writes ! 324: 316 00022CD4 # writed( cycle ); ! 325: 317 00022CD4 dd effffffd9e pushl _cycle ! 326: 318 00022CDA fe 08 effffffd97 callf $8,_writed ! 327: 319 00022CE1 # writes(" COSF test "); ! 328: 320 00022CE1 .data 1 ! 329: 321 00000ae6 * L262: ! 330: 322 00000ae6 * 202020434F534620746573742 .ascii " COSF test \0" ! 331: 000 ! 332: 323 00000af4 * .text ! 333: 324 00022CE1 dd 8f00000ae6 pushl $L262 ! 334: 325 00022CE7 fe 08 effffffd8a callf $8,_writes ! 335: 326 00022CEE # writed( test_no ); ! 336: 327 00022CEE dd effffffd84 pushl _test_no ! 337: 328 00022CF4 fe 08 effffffd7d callf $8,_writed ! 338: 329 00022CFB # writes(", subtest 2 (immediate store) - BAD FINAL ACC\n"); ! 339: 330 00022CFB .data 1 ! 340: 331 00000af4 * L263: ! 341: 332 00000af4 * 2C20737562746573742032202 .ascii ", subtest 2 (immediate store) - BAD FINAL ACC\12\0" ! 342: 8696D6D656469617465207374 ! 343: 6F726529202D2042414420464 ! 344: 94E414C204143430A00 ! 345: 333 00000b23 * .text ! 346: 334 00022CFB dd 8f00000af4 pushl $L263 ! 347: 335 00022D01 fe 08 effffffd70 callf $8,_writes ! 348: 336 00022D08 # print_cosf_data(); ! 349: 337 00022D08 fe 04 ef000006db callf $4,_print_cosf_data ! 350: 338 00022D0F # writes(", data index = "); ! 351: 339 00022D0F .data 1 ! 352: 340 00000b23 * L264: ! 353: 341 00000b23 * 2C20206461746120696E64657 .ascii ", data index = \0" ! 354: 8203D2000 ! 355: 342 00000b34 * .text ! 356: 343 00022D0F dd 8f00000b23 pushl $L264 ! 357: 344 00022D15 fe 08 effffffd5c callf $8,_writes ! 358: 345 00022D1C # writed( index ); ! 359: 346 00022D1C dd effffffd56 pushl _index ! 360: 347 00022D22 fe 08 effffffd4f callf $8,_writed ! 361: 348 00022D29 # writec('\n'); ! 362: 349 00022D29 dd 0a pushl $10 ! 363: 350 00022D2B fe 08 effffffd46 callf $8,_writec ! 364: 351 00022D32 # writes(" Acc expected = "); ! 365: 352 00022D32 .data 1 ! 366: 353 00000b34 * L265: ! 367: 354 00000b34 * 2020202020202020202020202 .ascii " Acc expected = \0" ! 368: 0202020202020202020416363 ! 369: 206578706563746564203D200 ! 370: 0 ! 371: 355 00000b5a * .text ! 372: 356 00022D32 dd 8f00000b34 pushl $L265 ! 373: 357 00022D38 fe 08 effffffd39 callf $8,_writes ! 374: 358 00022D3F # write32h( sgl_expected ); ! 375: 359 00022D3F dd effffffd33 pushl _sgl_expected ! 376: 360 00022D45 fe 08 effffffd2c callf $8,_write32h ! 377: 361 00022D4C # writec('\n'); ! 378: 362 00022D4C dd 0a pushl $10 ! 379: 363 00022D4E fe 08 effffffd23 callf $8,_writec ! 380: 364 00022D55 # } ! 381: 365 00022D55 # if ( halt_flg ) /* halt on error? */ ! 382: 366 00022D55 L259: ! 383: 367 00022D55 5d effffffd1d tstl _halt_flg ! 384: 368 00022D5B 31 09 jeql L266 ! 385: 369 00022D5D # cosf_er_halt( BAD_ACC_HLT ); ! 386: 370 00022D5D dd 01 pushl $1 ! 387: 371 00022D5F fe 08 ef000006c0 callf $8,_cosf_er_halt ! 388: 372 00022D66 # if ( loop_on_err ) ! 389: 373 00022D66 L266: ! 390: 374 00022D66 5d effffffd0c tstl _loop_on_err ! 391: 375 00022D6C 31 0d jeql L267 ! 392: 376 00022D6E # { ! 393: 377 00022D6E # force_loop = TRUE; /* set the force loop flag */ ! 394: 378 00022D6E 0d 01 effffffd03 movl $1,_force_loop ! 395: 379 00022D75 # asm("jmp _cosf_2_lp1"); /* and loop */ ! 396: 380 00022D75 71 efffffff01 jmp _cosf_2_lp1 ! 397: 381 00022D7B # } ! 398: 382 00022D7B # } /* end of compare error */ ! 399: 383 00022D7B L267: ! 400: 384 00022D7B # } while( index++ < max_cosf_1_index ); ! 401: 385 00022D7B L258: ! 402: 386 00022D7B L255: ! 403: 387 00022D7B 0d effffffcf7 50 movl _index,r0 ! 404: 388 00022D82 6d effffffcf0 incl _index ! 405: 389 00022D88 1d 50 effffffce9 cmpl r0,_max_cosf_1_index ! 406: 390 00022D8F 81 03 13 febc jlss L256 ! 407: 391 00022D94 L254: ! 408: 392 00022D94 # } /* end of subtest 2 */ ! 409: 393 00022D94 40 ret#2 ! 410: 394 00022D95 .set L250,0x0 ! 411: 395 00022D95 L252: ! 412: 396 00022D95 13 fea5 jbr L253 ! 413: 397 00022D98 .data ! 414: 398 00000a58 * .text ! 415: 399 00022D98 .align 1 ! 416: 400 00022D98 .globl _cosf_3 ! 417: 401 00022D98 _cosf_3: ! 418: 402 00022D98 0000 .word L268 ! 419: 403 00022D9A # ! 420: 404 00022D9A # ! 421: 405 00022D9A # ! 422: 406 00022D9A # /*************************************************************************** ! 423: 407 00022D9A # * ! 424: 408 00022D9A # * SUBTEST 3 - REGISTER INTEGRITY WITH THE COSF FUNCTION ! 425: 409 00022D9A # * ! 426: 410 00022D9A # ***************************************************************************/ ! 427: 411 00022D9A # cosf_3() ! 428: 412 00022D9A # { ! 429: 413 00022D9A 13 01e1 jbr L270 ! 430: 414 00022D9D L271: ! 431: 415 00022D9D # fill_reg_buf( load_regs ); /* set reg values to load */ ! 432: 416 00022D9D dd 8f00000000 pushl $_load_regs ! 433: 417 00022DA3 fe 08 effffffcce callf $8,_fill_reg_buf ! 434: 418 00022DAA # force_loop = FALSE; /* clear the LOOP flag */ ! 435: 419 00022DAA 4d effffffcc8 clrl _force_loop ! 436: 420 00022DB0 # subtest = 3; ! 437: 421 00022DB0 0d 03 effffffcc1 movl $3,_subtest ! 438: 422 00022DB7 # index = 0; ! 439: 423 00022DB7 4d effffffcbb clrl _index ! 440: 424 00022DBD # do ! 441: 425 00022DBD L275: ! 442: 426 00022DBD # { ! 443: 427 00022DBD # sgl_ld_acc = cosf_1_data[index].ld; /* get the operand */ ! 444: 428 00022DBD 0d effffffcb5 50 movl _index,r0 ! 445: 429 00022DC4 48 03 50 50 shll $3,r0,r0 ! 446: 430 00022DC8 0d e000000000 effffffca5 movl _cosf_1_data(r0),_sgl_ld_acc ! 447: 431 00022DD3 # sgl_expected = cosf_1_data[index].exp; /* get expected results */ ! 448: 432 00022DD3 0d effffffc9f 50 movl _index,r0 ! 449: 433 00022DDA 48 03 50 50 shll $3,r0,r0 ! 450: 434 00022DDE 0d e000000004 effffffc8f movl _cosf_1_data+4(r0),_sgl_expected ! 451: 435 00022DE9 # /* ! 452: 436 00022DE9 # * If LOOP ON ERROR is set, this is the loop for this subtest. ! 453: 437 00022DE9 # * The force loop flag is set after the first error. ! 454: 438 00022DE9 # */ ! 455: 439 00022DE9 # asm("_cosf_3_lp1:"); ! 456: 440 00022DE9 _cosf_3_lp1: ! 457: 441 00022DE9 # asm("loadr $0x1fff,_load_regs"); /* load regs 0 - 12 */ ! 458: 442 00022DE9 ab 891fff effffffc86 loadr $0x1fff,_load_regs ! 459: 443 00022DF2 # asm("ldf _sgl_ld_acc"); /* load the accumulator */ ! 460: 444 00022DF2 06 effffffc80 ldf _sgl_ld_acc ! 461: 445 00022DF8 # asm("cosf"); /* get ACC.'s cosf */ ! 462: 446 00022DF8 15 cosf ! 463: 447 00022DF9 # asm("stf _sgl_st_acc"); /* store the result */ ! 464: 448 00022DF9 26 effffffc79 stf _sgl_st_acc ! 465: 449 00022DFF # asm("storer $0x1fff,_store_regs"); /* store regs 0 - 12 */ ! 466: 450 00022DFF bb 891fff effffffc70 storer $0x1fff,_store_regs ! 467: 451 00022E08 # if( force_loop ) ! 468: 452 00022E08 5d effffffc6a tstl _force_loop ! 469: 453 00022E0E 31 02 jeql L276 ! 470: 454 00022E10 # asm("brb _cosf_3_lp1");; /* loop on the error */ ! 471: 455 00022E10 11 d7 brb _cosf_3_lp1 ! 472: 456 00022E12 L276: ! 473: 457 00022E12 # /* ! 474: 458 00022E12 # * end error loop ! 475: 459 00022E12 # */ ! 476: 460 00022E12 # reg_no = 0; ! 477: 461 00022E12 4d effffffc60 clrl _reg_no ! 478: 462 00022E18 # regs_ok = TRUE; ! 479: 463 00022E18 0d 01 effffffc59 movl $1,_regs_ok ! 480: 464 00022E1F # while( (reg_no < 13) && (regs_ok) ) /* check 1st 12 regs */ ! 481: 465 00022E1F L277: ! 482: 466 00022E1F 1d effffffc53 0d cmpl _reg_no,$13 ! 483: 467 00022E26 81 35 jgeq L278 ! 484: 468 00022E28 5d effffffc4a tstl _regs_ok ! 485: 469 00022E2E 31 2d jeql L278 ! 486: 470 00022E30 # if( store_regs[ reg_no ] == load_regs[ reg_no ] ) ! 487: 471 00022E30 0d effffffc42 50 movl _reg_no,r0 ! 488: 472 00022E37 0d effffffc3b 51 movl _reg_no,r1 ! 489: 473 00022E3E 1d 40effffffc33 cmpl _store_regs[r0],_load_regs[r1] ! 490: 41effffffc2d ! 491: 474 00022E4B 21 08 jneq L279 ! 492: 475 00022E4D # reg_no++; ! 493: 476 00022E4D 6d effffffc25 incl _reg_no ! 494: 477 00022E53 # else ! 495: 478 00022E53 11 06 jbr L280 ! 496: 479 00022E55 L279: ! 497: 480 00022E55 # regs_ok = FALSE; ! 498: 481 00022E55 4d effffffc1d clrl _regs_ok ! 499: 482 00022E5B L280: ! 500: 483 00022E5B 11 c2 jbr L277 ! 501: 484 00022E5D L278: ! 502: 485 00022E5D # if( !regs_ok ) ! 503: 486 00022E5D 5d effffffc15 tstl _regs_ok ! 504: 487 00022E63 31 03 13 00fc jneq L281 ! 505: 488 00022E68 # { ! 506: 489 00022E68 # errcnt++; /* bump the error count */ ! 507: 490 00022E68 6d effffffc0a incl _errcnt ! 508: 491 00022E6E # if ( prt_error ) { ! 509: 492 00022E6E 5d effffffc04 tstl _prt_error ! 510: 493 00022E74 21 03 13 00eb jeql L282 ! 511: 494 00022E79 # writes(" \n"); /* start a new print line */ ! 512: 495 00022E79 .data 1 ! 513: 496 00000b5a * L283: ! 514: 497 00000b5a * 200A00 .ascii " \12\0" ! 515: 498 00000b5d * .text ! 516: 499 00022E79 dd 8f00000b5a pushl $L283 ! 517: 500 00022E7F fe 08 effffffbf2 callf $8,_writes ! 518: 501 00022E86 # writes("cycle: "); ! 519: 502 00022E86 .data 1 ! 520: 503 00000b5d * L284: ! 521: 504 00000b5d * 6379636C653A2000 .ascii "cycle: \0" ! 522: 505 00000b65 * .text ! 523: 506 00022E86 dd 8f00000b5d pushl $L284 ! 524: 507 00022E8C fe 08 effffffbe5 callf $8,_writes ! 525: 508 00022E93 # writed( cycle ); ! 526: 509 00022E93 dd effffffbdf pushl _cycle ! 527: 510 00022E99 fe 08 effffffbd8 callf $8,_writed ! 528: 511 00022EA0 # writes(" COSF test "); ! 529: 512 00022EA0 .data 1 ! 530: 513 00000b65 * L285: ! 531: 514 00000b65 * 202020434F534620746573742 .ascii " COSF test \0" ! 532: 000 ! 533: 515 00000b73 * .text ! 534: 516 00022EA0 dd 8f00000b65 pushl $L285 ! 535: 517 00022EA6 fe 08 effffffbcb callf $8,_writes ! 536: 518 00022EAD # writed( test_no ); ! 537: 519 00022EAD dd effffffbc5 pushl _test_no ! 538: 520 00022EB3 fe 08 effffffbbe callf $8,_writed ! 539: 521 00022EBA # writes(", subtest 3 - A REGISTER WAS MODIFIED\n"); { ! 540: 522 00022EBA .data 1 ! 541: 523 00000b73 * L286: ! 542: 524 00000b73 * 2C20737562746573742033202 .ascii ", subtest 3 - A REGISTER WAS MODIFIED\12\0" ! 543: D204120524547495354455220 ! 544: 574153204D4F4449464945440 ! 545: A00 ! 546: 525 00000b9a * .text ! 547: 526 00022EBA dd 8f00000b73 pushl $L286 ! 548: 527 00022EC0 fe 08 effffffbb1 callf $8,_writes ! 549: 528 00022EC7 # print_cosf_data(); ! 550: 529 00022EC7 fe 04 ef0000051c callf $4,_print_cosf_data ! 551: 530 00022ECE # writec('\n'); ! 552: 531 00022ECE dd 0a pushl $10 ! 553: 532 00022ED0 fe 08 effffffba1 callf $8,_writec ! 554: 533 00022ED7 # writes("register "); ! 555: 534 00022ED7 .data 1 ! 556: 535 00000b9a * L287: ! 557: 536 00000b9a * 72656769737465722000 .ascii "register \0" ! 558: 537 00000ba4 * .text ! 559: 538 00022ED7 dd 8f00000b9a pushl $L287 ! 560: 539 00022EDD fe 08 effffffb94 callf $8,_writes ! 561: 540 00022EE4 # writed( reg_no ); ! 562: 541 00022EE4 dd effffffb8e pushl _reg_no ! 563: 542 00022EEA fe 08 effffffb87 callf $8,_writed ! 564: 543 00022EF1 # writes(" = "); ! 565: 544 00022EF1 .data 1 ! 566: 545 00000ba4 * L288: ! 567: 546 00000ba4 * 203D2000 .ascii " = \0" ! 568: 547 00000ba8 * .text ! 569: 548 00022EF1 dd 8f00000ba4 pushl $L288 ! 570: 549 00022EF7 fe 08 effffffb7a callf $8,_writes ! 571: 550 00022EFE # write32h( load_regs[reg_no] ); ! 572: 551 00022EFE 0d effffffb74 50 movl _reg_no,r0 ! 573: 552 00022F05 dd 40effffffb6c pushl _load_regs[r0] ! 574: 553 00022F0C fe 08 effffffb65 callf $8,_write32h ! 575: 554 00022F13 # writes(", should be = "); ! 576: 555 00022F13 .data 1 ! 577: 556 00000ba8 * L289: ! 578: 557 00000ba8 * 2C202073686F756C642062652 .ascii ", should be = \0" ! 579: 03D2000 ! 580: 558 00000bb8 * .text ! 581: 559 00022F13 dd 8f00000ba8 pushl $L289 ! 582: 560 00022F19 fe 08 effffffb58 callf $8,_writes ! 583: 561 00022F20 # write32h( store_regs[reg_no] ); ! 584: 562 00022F20 0d effffffb52 50 movl _reg_no,r0 ! 585: 563 00022F27 dd 40effffffb4a pushl _store_regs[r0] ! 586: 564 00022F2E fe 08 effffffb43 callf $8,_write32h ! 587: 565 00022F35 # writec('\n'); ! 588: 566 00022F35 dd 0a pushl $10 ! 589: 567 00022F37 fe 08 effffffb3a callf $8,_writec ! 590: 568 00022F3E # } ! 591: 569 00022F3E # if ( halt_flg ) /* halt on error? */ ! 592: 570 00022F3E 5d effffffb34 tstl _halt_flg ! 593: 571 00022F44 31 09 jeql L290 ! 594: 572 00022F46 # cosf_er_halt( BAD_REG_HLT ); ! 595: 573 00022F46 dd 02 pushl $2 ! 596: 574 00022F48 fe 08 ef000004d7 callf $8,_cosf_er_halt ! 597: 575 00022F4F # if ( loop_on_err ) ! 598: 576 00022F4F L290: ! 599: 577 00022F4F 5d effffffb23 tstl _loop_on_err ! 600: 578 00022F55 31 0d jeql L291 ! 601: 579 00022F57 # { ! 602: 580 00022F57 # force_loop = TRUE; /* get the force loop flag */ ! 603: 581 00022F57 0d 01 effffffb1a movl $1,_force_loop ! 604: 582 00022F5E # asm("jmp _cosf_3_lp1"); /* and loop */ ! 605: 583 00022F5E 71 effffffe85 jmp _cosf_3_lp1 ! 606: 584 00022F64 # } ! 607: 585 00022F64 # } /* end of compare error */ ! 608: 586 00022F64 L291: ! 609: 587 00022F64 # } /* end of while loop */ ! 610: 588 00022F64 L282: ! 611: 589 00022F64 # } while( index++ < max_cosf_1_index ); ! 612: 590 00022F64 L281: ! 613: 591 00022F64 L274: ! 614: 592 00022F64 0d effffffb0e 50 movl _index,r0 ! 615: 593 00022F6B 6d effffffb07 incl _index ! 616: 594 00022F71 1d 50 effffffb00 cmpl r0,_max_cosf_1_index ! 617: 595 00022F78 81 03 13 fe40 jlss L275 ! 618: 596 00022F7D L273: ! 619: 597 00022F7D # } /* end of subtest 3 */ ! 620: 598 00022F7D 40 ret#2 ! 621: 599 00022F7E .set L268,0x0 ! 622: 600 00022F7E L270: ! 623: 601 00022F7E 13 fe1c jbr L271 ! 624: 602 00022F81 .data ! 625: 603 00000a58 * .text ! 626: 604 00022F81 00 .align 1 ! 627: 605 00022F82 .globl _cosf_4 ! 628: 606 00022F82 _cosf_4: ! 629: 607 00022F82 0000 .word L293 ! 630: 608 00022F84 # ! 631: 609 00022F84 # ! 632: 610 00022F84 # ! 633: 611 00022F84 # /************************************************************************ ! 634: 612 00022F84 # * ! 635: 613 00022F84 # * SUBTEST 4 - Check for PSL corruption ! 636: 614 00022F84 # * ! 637: 615 00022F84 # ************************************************************************/ ! 638: 616 00022F84 # cosf_4() ! 639: 617 00022F84 # { ! 640: 618 00022F84 13 01a8 jbr L295 ! 641: 619 00022F87 L296: ! 642: 620 00022F87 # force_loop = FALSE; /* clear force_loop flg */ ! 643: 621 00022F87 4d effffffaeb clrl _force_loop ! 644: 622 00022F8D # subtest = 4; ! 645: 623 00022F8D 0d 04 effffffae4 movl $4,_subtest ! 646: 624 00022F94 # fill_reg_buf( load_regs ); /* get patterns for regs */ ! 647: 625 00022F94 dd 8f00000000 pushl $_load_regs ! 648: 626 00022F9A fe 08 effffffad7 callf $8,_fill_reg_buf ! 649: 627 00022FA1 # for( index = 0; index < 3; index++ ) { ! 650: 628 00022FA1 4d effffffad1 clrl _index ! 651: 629 00022FA7 L299: ! 652: 630 00022FA7 1d effffffacb 03 cmpl _index,$3 ! 653: 631 00022FAE 91 03 13 017b jgeq L298 ! 654: 632 00022FB3 # sgl_ld_acc = cosf_1_data[index].ld; /* get operand 1 */ ! 655: 633 00022FB3 0d effffffabf 50 movl _index,r0 ! 656: 634 00022FBA 48 03 50 50 shll $3,r0,r0 ! 657: 635 00022FBE 0d e000000000 effffffaaf movl _cosf_1_data(r0),_sgl_ld_acc ! 658: 636 00022FC9 # sgl_expected = cosf_1_data[index].exp; /* get expected */ ! 659: 637 00022FC9 0d effffffaa9 50 movl _index,r0 ! 660: 638 00022FD0 48 03 50 50 shll $3,r0,r0 ! 661: 639 00022FD4 0d e000000004 effffffa99 movl _cosf_1_data+4(r0),_sgl_expected ! 662: 640 00022FDF # sgl_dummy1 = status_array[index]; /* status = +, -, 0 */ ! 663: 641 00022FDF 0d effffffa93 50 movl _index,r0 ! 664: 642 00022FE6 0d 40effffffa8b movl _status_array[r0],_sgl_dummy1 ! 665: effffffa86 ! 666: 643 00022FF2 # /* ! 667: 644 00022FF2 # * If LOOP ON ERROR is set, this is the loop for this subtest. ! 668: 645 00022FF2 # * The force loop flag is set after the first error. ! 669: 646 00022FF2 # */ ! 670: 647 00022FF2 # asm("_cosf_4_lp1:"); ! 671: 648 00022FF2 _cosf_4_lp1: ! 672: 649 00022FF2 # asm("ldf _sgl_ld_acc"); /* LOAD the accumulator */ ! 673: 650 00022FF2 06 effffffa80 ldf _sgl_ld_acc ! 674: 651 00022FF8 # asm("nop"); ! 675: 652 00022FF8 10 nop ! 676: 653 00022FF9 # asm("tstl _sgl_dummy1"); /* set the PSL status */ ! 677: 654 00022FF9 5d effffffa79 tstl _sgl_dummy1 ! 678: 655 00022FFF # asm("movpsl _init_psl"); /* save the initial PSL */ ! 679: 656 00022FFF cd effffffa73 movpsl _init_psl ! 680: 657 00023005 # asm("cosf"); /* do the cosf */ ! 681: 658 00023005 15 cosf ! 682: 659 00023006 # asm("nop"); ! 683: 660 00023006 10 nop ! 684: 661 00023007 # asm("movpsl _psl_val"); /* save the final PSL */ ! 685: 662 00023007 cd effffffa6b movpsl _psl_val ! 686: 663 0002300D # asm("stf _sgl_st_acc"); /* save the accumulator */ ! 687: 664 0002300D 26 effffffa65 stf _sgl_st_acc ! 688: 665 00023013 # if( force_loop ) ! 689: 666 00023013 5d effffffa5f tstl _force_loop ! 690: 667 00023019 31 02 jeql L300 ! 691: 668 0002301B # asm("brb _cosf_4_lp1");; /* loop on the error */ ! 692: 669 0002301B 11 d5 brb _cosf_4_lp1 ! 693: 670 0002301D L300: ! 694: 671 0002301D # /* ! 695: 672 0002301D # * Now compare the final PSL to the initial PSL -they should be the same ! 696: 673 0002301D # */ ! 697: 674 0002301D # exp_psl = init_psl; ! 698: 675 0002301D 0d effffffa55 effffffa50 movl _init_psl,_exp_psl ! 699: 676 00023028 # if( psl_val != exp_psl ) { ! 700: 677 00023028 1d effffffa4a effffffa45 cmpl _psl_val,_exp_psl ! 701: 678 00023033 21 03 13 00ed jeql L301 ! 702: 679 00023038 # errcnt++; /* bump the error count */ ! 703: 680 00023038 6d effffffa3a incl _errcnt ! 704: 681 0002303E # if( prt_error ) { ! 705: 682 0002303E 5d effffffa34 tstl _prt_error ! 706: 683 00023044 21 03 13 00b9 jeql L302 ! 707: 684 00023049 # writes(" \n"); /* start a new print line */ ! 708: 685 00023049 .data 1 ! 709: 686 00000bb8 * L303: ! 710: 687 00000bb8 * 200A00 .ascii " \12\0" ! 711: 688 00000bbb * .text ! 712: 689 00023049 dd 8f00000bb8 pushl $L303 ! 713: 690 0002304F fe 08 effffffa22 callf $8,_writes ! 714: 691 00023056 # writes("cycle: "); ! 715: 692 00023056 .data 1 ! 716: 693 00000bbb * L304: ! 717: 694 00000bbb * 6379636C653A2000 .ascii "cycle: \0" ! 718: 695 00000bc3 * .text ! 719: 696 00023056 dd 8f00000bbb pushl $L304 ! 720: 697 0002305C fe 08 effffffa15 callf $8,_writes ! 721: 698 00023063 # writed( cycle ); ! 722: 699 00023063 dd effffffa0f pushl _cycle ! 723: 700 00023069 fe 08 effffffa08 callf $8,_writed ! 724: 701 00023070 # writes(" COSF test "); ! 725: 702 00023070 .data 1 ! 726: 703 00000bc3 * L305: ! 727: 704 00000bc3 * 202020434F534620746573742 .ascii " COSF test \0" ! 728: 000 ! 729: 705 00000bd1 * .text ! 730: 706 00023070 dd 8f00000bc3 pushl $L305 ! 731: 707 00023076 fe 08 effffff9fb callf $8,_writes ! 732: 708 0002307D # writed( test_no ); ! 733: 709 0002307D dd effffff9f5 pushl _test_no ! 734: 710 00023083 fe 08 effffff9ee callf $8,_writed ! 735: 711 0002308A # writes(", subtest 4 - INCORRECT FINAL PSL\n"); ! 736: 712 0002308A .data 1 ! 737: 713 00000bd1 * L306: ! 738: 714 00000bd1 * 2C20737562746573742034202 .ascii ", subtest 4 - INCORRECT FINAL PSL\12\0" ! 739: D20494E434F52524543542046 ! 740: 494E414C2050534C0A00 ! 741: 715 00000bf4 * .text ! 742: 716 0002308A dd 8f00000bd1 pushl $L306 ! 743: 717 00023090 fe 08 effffff9e1 callf $8,_writes ! 744: 718 00023097 # print_cosf_data(); /* print the operands */ ! 745: 719 00023097 fe 04 ef0000034c callf $4,_print_cosf_data ! 746: 720 0002309E # writec('\n'); ! 747: 721 0002309E dd 0a pushl $10 ! 748: 722 000230A0 fe 08 effffff9d1 callf $8,_writec ! 749: 723 000230A7 # writes("initial PSL = "); ! 750: 724 000230A7 .data 1 ! 751: 725 00000bf4 * L307: ! 752: 726 00000bf4 * 696E697469616C2050534C203 .ascii "initial PSL = \0" ! 753: D2000 ! 754: 727 00000c03 * .text ! 755: 728 000230A7 dd 8f00000bf4 pushl $L307 ! 756: 729 000230AD fe 08 effffff9c4 callf $8,_writes ! 757: 730 000230B4 # write32h( init_psl ); ! 758: 731 000230B4 dd effffff9be pushl _init_psl ! 759: 732 000230BA fe 08 effffff9b7 callf $8,_write32h ! 760: 733 000230C1 # writes(", final PSL = "); ! 761: 734 000230C1 .data 1 ! 762: 735 00000c03 * L308: ! 763: 736 00000c03 * 2C202066696E616C2050534C2 .ascii ", final PSL = \0" ! 764: 03D2000 ! 765: 737 00000c13 * .text ! 766: 738 000230C1 dd 8f00000c03 pushl $L308 ! 767: 739 000230C7 fe 08 effffff9aa callf $8,_writes ! 768: 740 000230CE # write32h( psl_val ); ! 769: 741 000230CE dd effffff9a4 pushl _psl_val ! 770: 742 000230D4 fe 08 effffff99d callf $8,_write32h ! 771: 743 000230DB # writes(", expected PSL = "); ! 772: 744 000230DB .data 1 ! 773: 745 00000c13 * L309: ! 774: 746 00000c13 * 2C20206578706563746564205 .ascii ", expected PSL = \0" ! 775: 0534C203D2000 ! 776: 747 00000c26 * .text ! 777: 748 000230DB dd 8f00000c13 pushl $L309 ! 778: 749 000230E1 fe 08 effffff990 callf $8,_writes ! 779: 750 000230E8 # write32h( exp_psl ); ! 780: 751 000230E8 dd effffff98a pushl _exp_psl ! 781: 752 000230EE fe 08 effffff983 callf $8,_write32h ! 782: 753 000230F5 # writes("\n"); ! 783: 754 000230F5 .data 1 ! 784: 755 00000c26 * L310: ! 785: 756 00000c26 * 0A00 .ascii "\12\0" ! 786: 757 00000c28 * .text ! 787: 758 000230F5 dd 8f00000c26 pushl $L310 ! 788: 759 000230FB fe 08 effffff976 callf $8,_writes ! 789: 760 00023102 # } ! 790: 761 00023102 # if( halt_flg ) ! 791: 762 00023102 L302: ! 792: 763 00023102 5d effffff970 tstl _halt_flg ! 793: 764 00023108 31 09 jeql L311 ! 794: 765 0002310A # cosf_er_halt( BAD_PSL_HLT ); /* halt on the error */ ! 795: 766 0002310A dd 03 pushl $3 ! 796: 767 0002310C fe 08 ef00000313 callf $8,_cosf_er_halt ! 797: 768 00023113 # if( loop_on_err ) { ! 798: 769 00023113 L311: ! 799: 770 00023113 5d effffff95f tstl _loop_on_err ! 800: 771 00023119 31 0a jeql L312 ! 801: 772 0002311B # force_loop = TRUE; /* set the force loop flag */ ! 802: 773 0002311B 0d 01 effffff956 movl $1,_force_loop ! 803: 774 00023122 # asm("brw _cosf_4_lp1");; /* and loop on the error */ ! 804: 775 00023122 13 fecd brw _cosf_4_lp1 ! 805: 776 00023125 # } /* end of loop on error */ ! 806: 777 00023125 # } /* end of PSL corruption error */ ! 807: 778 00023125 L312: ! 808: 779 00023125 # } /* end of WHILE loop */ ! 809: 780 00023125 L301: ! 810: 781 00023125 L297: ! 811: 782 00023125 6d effffff94d incl _index ! 812: 783 0002312B 13 fe79 jbr L299 ! 813: 784 0002312E L298: ! 814: 785 0002312E # } /* end of subtest 4 */ ! 815: 786 0002312E 40 ret#2 ! 816: 787 0002312F .set L293,0x0 ! 817: 788 0002312F L295: ! 818: 789 0002312F 13 fe55 jbr L296 ! 819: 790 00023132 .data ! 820: 791 00000a58 * .text ! 821: 792 00023132 .align 1 ! 822: 793 00023132 .globl _cosf_5 ! 823: 794 00023132 _cosf_5: ! 824: 795 00023132 0000 .word L313 ! 825: 796 00023134 # ! 826: 797 00023134 # ! 827: 798 00023134 # ! 828: 799 00023134 # /************************************************************************ ! 829: 800 00023134 # * ! 830: 801 00023134 # * SUBTEST 5 - pipelined entry test ! 831: 802 00023134 # * ! 832: 803 00023134 # ************************************************************************/ ! 833: 804 00023134 # cosf_5() ! 834: 805 00023134 # { ! 835: 806 00023134 13 0154 jbr L315 ! 836: 807 00023137 L316: ! 837: 808 00023137 # force_loop = FALSE; ! 838: 809 00023137 4d effffff93b clrl _force_loop ! 839: 810 0002313D # subtest = 8; ! 840: 811 0002313D 0d 08 effffff934 movl $8,_subtest ! 841: 812 00023144 # for( index = 0; index < max_cosf_1_index; index++ ) { ! 842: 813 00023144 4d effffff92e clrl _index ! 843: 814 0002314A L319: ! 844: 815 0002314A 1d effffff928 effffff923 cmpl _index,_max_cosf_1_index ! 845: 816 00023155 91 03 13 0130 jgeq L318 ! 846: 817 0002315A # sgl_ld_acc = cosf_1_data[index].ld; /* get operand 1 */ ! 847: 818 0002315A 0d effffff918 50 movl _index,r0 ! 848: 819 00023161 48 03 50 50 shll $3,r0,r0 ! 849: 820 00023165 0d e000000000 effffff908 movl _cosf_1_data(r0),_sgl_ld_acc ! 850: 821 00023170 # sgl_expected = cosf_1_data[index].exp; /* get expected result */ ! 851: 822 00023170 0d effffff902 50 movl _index,r0 ! 852: 823 00023177 48 03 50 50 shll $3,r0,r0 ! 853: 824 0002317B 0d e000000004 effffff8f2 movl _cosf_1_data+4(r0),_sgl_expected ! 854: 825 00023186 # /* ! 855: 826 00023186 # * If LOOP ON ERROR is set, this is the loop for this subtest. ! 856: 827 00023186 # * The force loop flag is set after the first error. ! 857: 828 00023186 # */ ! 858: 829 00023186 # asm("_cosf_5_lp1:"); ! 859: 830 00023186 _cosf_5_lp1: ! 860: 831 00023186 # asm("movl $0,r0"); /* clear r0 */ ! 861: 832 00023186 0d 00 50 movl $0,r0 ! 862: 833 00023189 # asm("ldf r0"); /* load the Acc. with 0.0 */ ! 863: 834 00023189 06 50 ldf r0 ! 864: 835 0002318B # asm("addf _sgl_ld_acc"); /* add the 1st operand */ ! 865: 836 0002318B c6 effffff8e7 addf _sgl_ld_acc ! 866: 837 00023191 # asm("cosf"); /* get the cosf */ ! 867: 838 00023191 15 cosf ! 868: 839 00023192 # asm("stf _sgl_st_acc"); /* store the result */ ! 869: 840 00023192 26 effffff8e0 stf _sgl_st_acc ! 870: 841 00023198 # if( force_loop ) ! 871: 842 00023198 5d effffff8da tstl _force_loop ! 872: 843 0002319E 31 02 jeql L320 ! 873: 844 000231A0 # asm("brb _cosf_5_lp1");; /* loop on the error */ ! 874: 845 000231A0 11 e4 brb _cosf_5_lp1 ! 875: 846 000231A2 L320: ! 876: 847 000231A2 # /* ! 877: 848 000231A2 # * end error loop - test the results ! 878: 849 000231A2 # */ ! 879: 850 000231A2 # if( sgl_st_acc != sgl_expected ) { /* COMPARE the values */ ! 880: 851 000231A2 1d effffff8d0 effffff8cb cmpl _sgl_st_acc,_sgl_expected ! 881: 852 000231AD 21 03 13 00cf jeql L321 ! 882: 853 000231B2 # errcnt++; /* bump the error count */ ! 883: 854 000231B2 6d effffff8c0 incl _errcnt ! 884: 855 000231B8 # if( prt_error ) { ! 885: 856 000231B8 5d effffff8ba tstl _prt_error ! 886: 857 000231BE 21 03 13 009b jeql L322 ! 887: 858 000231C3 # writes(" \n"); /* start a new print line */ ! 888: 859 000231C3 .data 1 ! 889: 860 00000c28 * L323: ! 890: 861 00000c28 * 200A00 .ascii " \12\0" ! 891: 862 00000c2b * .text ! 892: 863 000231C3 dd 8f00000c28 pushl $L323 ! 893: 864 000231C9 fe 08 effffff8a8 callf $8,_writes ! 894: 865 000231D0 # writes("cycle: "); ! 895: 866 000231D0 .data 1 ! 896: 867 00000c2b * L324: ! 897: 868 00000c2b * 6379636C653A2000 .ascii "cycle: \0" ! 898: 869 00000c33 * .text ! 899: 870 000231D0 dd 8f00000c2b pushl $L324 ! 900: 871 000231D6 fe 08 effffff89b callf $8,_writes ! 901: 872 000231DD # writed( cycle ); ! 902: 873 000231DD dd effffff895 pushl _cycle ! 903: 874 000231E3 fe 08 effffff88e callf $8,_writed ! 904: 875 000231EA # writes(" COSF test "); ! 905: 876 000231EA .data 1 ! 906: 877 00000c33 * L325: ! 907: 878 00000c33 * 202020434F534620746573742 .ascii " COSF test \0" ! 908: 000 ! 909: 879 00000c41 * .text ! 910: 880 000231EA dd 8f00000c33 pushl $L325 ! 911: 881 000231F0 fe 08 effffff881 callf $8,_writes ! 912: 882 000231F7 # writed( test_no ); ! 913: 883 000231F7 dd effffff87b pushl _test_no ! 914: 884 000231FD fe 08 effffff874 callf $8,_writed ! 915: 885 00023204 # writes(", subtest 5 (Piped Entry) - BAD FINAL ACC\n"); ! 916: 886 00023204 .data 1 ! 917: 887 00000c41 * L326: ! 918: 888 00000c41 * 2C20737562746573742035202 .ascii ", subtest 5 (Piped Entry) - BAD FINAL ACC\12\0" ! 919: 8506970656420456E74727929 ! 920: 202D204241442046494E414C2 ! 921: 04143430A00 ! 922: 889 00000c6c * .text ! 923: 890 00023204 dd 8f00000c41 pushl $L326 ! 924: 891 0002320A fe 08 effffff867 callf $8,_writes ! 925: 892 00023211 # print_cosf_data(); ! 926: 893 00023211 fe 04 ef000001d2 callf $4,_print_cosf_data ! 927: 894 00023218 # writes(", data index = "); ! 928: 895 00023218 .data 1 ! 929: 896 00000c6c * L327: ! 930: 897 00000c6c * 2C20206461746120696E64657 .ascii ", data index = \0" ! 931: 8203D2000 ! 932: 898 00000c7d * .text ! 933: 899 00023218 dd 8f00000c6c pushl $L327 ! 934: 900 0002321E fe 08 effffff853 callf $8,_writes ! 935: 901 00023225 # writed( index ); ! 936: 902 00023225 dd effffff84d pushl _index ! 937: 903 0002322B fe 08 effffff846 callf $8,_writed ! 938: 904 00023232 # writec('\n'); ! 939: 905 00023232 dd 0a pushl $10 ! 940: 906 00023234 fe 08 effffff83d callf $8,_writec ! 941: 907 0002323B # writes(" Acc expected = "); ! 942: 908 0002323B .data 1 ! 943: 909 00000c7d * L328: ! 944: 910 00000c7d * 2020202020202020202020202 .ascii " Acc expected = \0" ! 945: 0202020202020202020416363 ! 946: 206578706563746564203D200 ! 947: 0 ! 948: 911 00000ca3 * .text ! 949: 912 0002323B dd 8f00000c7d pushl $L328 ! 950: 913 00023241 fe 08 effffff830 callf $8,_writes ! 951: 914 00023248 # write32h( sgl_expected ); ! 952: 915 00023248 dd effffff82a pushl _sgl_expected ! 953: 916 0002324E fe 08 effffff823 callf $8,_write32h ! 954: 917 00023255 # writec('\n'); ! 955: 918 00023255 dd 0a pushl $10 ! 956: 919 00023257 fe 08 effffff81a callf $8,_writec ! 957: 920 0002325E # } ! 958: 921 0002325E # if( halt_flg ) ! 959: 922 0002325E L322: ! 960: 923 0002325E 5d effffff814 tstl _halt_flg ! 961: 924 00023264 31 09 jeql L329 ! 962: 925 00023266 # cosf_er_halt( BAD_ACC_HLT ); /* halt on the error */ ! 963: 926 00023266 dd 01 pushl $1 ! 964: 927 00023268 fe 08 ef000001b7 callf $8,_cosf_er_halt ! 965: 928 0002326F # if( loop_on_err ) { ! 966: 929 0002326F L329: ! 967: 930 0002326F 5d effffff803 tstl _loop_on_err ! 968: 931 00023275 31 0a jeql L330 ! 969: 932 00023277 # force_loop = TRUE; /* set the force loop flag */ ! 970: 933 00023277 0d 01 effffff7fa movl $1,_force_loop ! 971: 934 0002327E # asm("brw _cosf_5_lp1");; /* and loop on the error */ ! 972: 935 0002327E 13 ff05 brw _cosf_5_lp1 ! 973: 936 00023281 # } /* end of loop on error */ ! 974: 937 00023281 # } /* end of compare error */ ! 975: 938 00023281 L330: ! 976: 939 00023281 # } /* end of WHILE loop */ ! 977: 940 00023281 L321: ! 978: 941 00023281 L317: ! 979: 942 00023281 6d effffff7f1 incl _index ! 980: 943 00023287 13 fec0 jbr L319 ! 981: 944 0002328A L318: ! 982: 945 0002328A # } /* end of subtest 5 */ ! 983: 946 0002328A 40 ret#2 ! 984: 947 0002328B .set L313,0x0 ! 985: 948 0002328B L315: ! 986: 949 0002328B 13 fea9 jbr L316 ! 987: 950 0002328E .data ! 988: 951 00000a58 * .text ! 989: 952 0002328E .align 1 ! 990: 953 0002328E .globl _cosf_6 ! 991: 954 0002328E _cosf_6: ! 992: 955 0002328E 0000 .word L331 ! 993: 956 00023290 # ! 994: 957 00023290 # ! 995: 958 00023290 # ! 996: 959 00023290 # /************************************************************************ ! 997: 960 00023290 # * ! 998: 961 00023290 # * SUBTEST 6 - pipelined exit test ! 999: 962 00023290 # * ! 1000: 963 00023290 # ************************************************************************/ ! 1001: 964 00023290 # cosf_6() ! 1002: 965 00023290 # { ! 1003: 966 00023290 13 0154 jbr L333 ! 1004: 967 00023293 L334: ! 1005: 968 00023293 # force_loop = FALSE; ! 1006: 969 00023293 4d effffff7df clrl _force_loop ! 1007: 970 00023299 # subtest = 8; ! 1008: 971 00023299 0d 08 effffff7d8 movl $8,_subtest ! 1009: 972 000232A0 # for( index = 0; index < max_cosf_1_index; index++ ) { ! 1010: 973 000232A0 4d effffff7d2 clrl _index ! 1011: 974 000232A6 L337: ! 1012: 975 000232A6 1d effffff7cc effffff7c7 cmpl _index,_max_cosf_1_index ! 1013: 976 000232B1 91 03 13 0130 jgeq L336 ! 1014: 977 000232B6 # sgl_ld_acc = cosf_1_data[index].ld; /* get operand 1 */ ! 1015: 978 000232B6 0d effffff7bc 50 movl _index,r0 ! 1016: 979 000232BD 48 03 50 50 shll $3,r0,r0 ! 1017: 980 000232C1 0d e000000000 effffff7ac movl _cosf_1_data(r0),_sgl_ld_acc ! 1018: 981 000232CC # sgl_expected = cosf_1_data[index].exp; /* get expected result */ ! 1019: 982 000232CC 0d effffff7a6 50 movl _index,r0 ! 1020: 983 000232D3 48 03 50 50 shll $3,r0,r0 ! 1021: 984 000232D7 0d e000000004 effffff796 movl _cosf_1_data+4(r0),_sgl_expected ! 1022: 985 000232E2 # /* ! 1023: 986 000232E2 # * If LOOP ON ERROR is set, this is the loop for this subtest. ! 1024: 987 000232E2 # * The force loop flag is set after the first error. ! 1025: 988 000232E2 # */ ! 1026: 989 000232E2 # asm("_cosf_6_lp1:"); ! 1027: 990 000232E2 _cosf_6_lp1: ! 1028: 991 000232E2 # asm("movl $0,r0"); /* clear r0 */ ! 1029: 992 000232E2 0d 00 50 movl $0,r0 ! 1030: 993 000232E5 # asm("ldf _sgl_ld_acc"); /* load the Acc. */ ! 1031: 994 000232E5 06 effffff78d ldf _sgl_ld_acc ! 1032: 995 000232EB # asm("cosf"); /* get the cosf */ ! 1033: 996 000232EB 15 cosf ! 1034: 997 000232EC # asm("addf r0"); /* add a zero to the acc */ ! 1035: 998 000232EC c6 50 addf r0 ! 1036: 999 000232EE # asm("stf _sgl_st_acc"); /* store the result */ ! 1037: 1000 000232EE 26 effffff784 stf _sgl_st_acc ! 1038: 1001 000232F4 # if( force_loop ) ! 1039: 1002 000232F4 5d effffff77e tstl _force_loop ! 1040: 1003 000232FA 31 02 jeql L338 ! 1041: 1004 000232FC # asm("brb _cosf_6_lp1");; /* loop on the error */ ! 1042: 1005 000232FC 11 e4 brb _cosf_6_lp1 ! 1043: 1006 000232FE L338: ! 1044: 1007 000232FE # /* ! 1045: 1008 000232FE # * end error loop - test the results ! 1046: 1009 000232FE # */ ! 1047: 1010 000232FE # if( sgl_st_acc != sgl_expected ) { /* COMPARE the values */ ! 1048: 1011 000232FE 1d effffff774 effffff76f cmpl _sgl_st_acc,_sgl_expected ! 1049: 1012 00023309 21 03 13 00cf jeql L339 ! 1050: 1013 0002330E # errcnt++; /* bump the error count */ ! 1051: 1014 0002330E 6d effffff764 incl _errcnt ! 1052: 1015 00023314 # if( prt_error ) { ! 1053: 1016 00023314 5d effffff75e tstl _prt_error ! 1054: 1017 0002331A 21 03 13 009b jeql L340 ! 1055: 1018 0002331F # writes(" \n"); /* start a new print line */ ! 1056: 1019 0002331F .data 1 ! 1057: 1020 00000ca3 * L341: ! 1058: 1021 00000ca3 * 200A00 .ascii " \12\0" ! 1059: 1022 00000ca6 * .text ! 1060: 1023 0002331F dd 8f00000ca3 pushl $L341 ! 1061: 1024 00023325 fe 08 effffff74c callf $8,_writes ! 1062: 1025 0002332C # writes("cycle: "); ! 1063: 1026 0002332C .data 1 ! 1064: 1027 00000ca6 * L342: ! 1065: 1028 00000ca6 * 6379636C653A2000 .ascii "cycle: \0" ! 1066: 1029 00000cae * .text ! 1067: 1030 0002332C dd 8f00000ca6 pushl $L342 ! 1068: 1031 00023332 fe 08 effffff73f callf $8,_writes ! 1069: 1032 00023339 # writed( cycle ); ! 1070: 1033 00023339 dd effffff739 pushl _cycle ! 1071: 1034 0002333F fe 08 effffff732 callf $8,_writed ! 1072: 1035 00023346 # writes(" COSF test "); ! 1073: 1036 00023346 .data 1 ! 1074: 1037 00000cae * L343: ! 1075: 1038 00000cae * 202020434F534620746573742 .ascii " COSF test \0" ! 1076: 000 ! 1077: 1039 00000cbc * .text ! 1078: 1040 00023346 dd 8f00000cae pushl $L343 ! 1079: 1041 0002334C fe 08 effffff725 callf $8,_writes ! 1080: 1042 00023353 # writed( test_no ); ! 1081: 1043 00023353 dd effffff71f pushl _test_no ! 1082: 1044 00023359 fe 08 effffff718 callf $8,_writed ! 1083: 1045 00023360 # writes(", subtest 6 (Piped Exit) - BAD FINAL ACC\n"); ! 1084: 1046 00023360 .data 1 ! 1085: 1047 00000cbc * L344: ! 1086: 1048 00000cbc * 2C20737562746573742036202 .ascii ", subtest 6 (Piped Exit) - BAD FINAL ACC\12\0" ! 1087: 8506970656420457869742920 ! 1088: 2D204241442046494E414C204 ! 1089: 143430A00 ! 1090: 1049 00000ce6 * .text ! 1091: 1050 00023360 dd 8f00000cbc pushl $L344 ! 1092: 1051 00023366 fe 08 effffff70b callf $8,_writes ! 1093: 1052 0002336D # print_cosf_data(); ! 1094: 1053 0002336D fe 04 ef00000076 callf $4,_print_cosf_data ! 1095: 1054 00023374 # writes(", data index = "); ! 1096: 1055 00023374 .data 1 ! 1097: 1056 00000ce6 * L345: ! 1098: 1057 00000ce6 * 2C20206461746120696E64657 .ascii ", data index = \0" ! 1099: 8203D2000 ! 1100: 1058 00000cf7 * .text ! 1101: 1059 00023374 dd 8f00000ce6 pushl $L345 ! 1102: 1060 0002337A fe 08 effffff6f7 callf $8,_writes ! 1103: 1061 00023381 # writed( index ); ! 1104: 1062 00023381 dd effffff6f1 pushl _index ! 1105: 1063 00023387 fe 08 effffff6ea callf $8,_writed ! 1106: 1064 0002338E # writec('\n'); ! 1107: 1065 0002338E dd 0a pushl $10 ! 1108: 1066 00023390 fe 08 effffff6e1 callf $8,_writec ! 1109: 1067 00023397 # writes(" Acc expected = "); ! 1110: 1068 00023397 .data 1 ! 1111: 1069 00000cf7 * L346: ! 1112: 1070 00000cf7 * 2020202020202020202020202 .ascii " Acc expected = \0" ! 1113: 0202020202020202020416363 ! 1114: 206578706563746564203D200 ! 1115: 0 ! 1116: 1071 00000d1d * .text ! 1117: 1072 00023397 dd 8f00000cf7 pushl $L346 ! 1118: 1073 0002339D fe 08 effffff6d4 callf $8,_writes ! 1119: 1074 000233A4 # write32h( sgl_expected ); ! 1120: 1075 000233A4 dd effffff6ce pushl _sgl_expected ! 1121: 1076 000233AA fe 08 effffff6c7 callf $8,_write32h ! 1122: 1077 000233B1 # writec('\n'); ! 1123: 1078 000233B1 dd 0a pushl $10 ! 1124: 1079 000233B3 fe 08 effffff6be callf $8,_writec ! 1125: 1080 000233BA # } ! 1126: 1081 000233BA # if( halt_flg ) ! 1127: 1082 000233BA L340: ! 1128: 1083 000233BA 5d effffff6b8 tstl _halt_flg ! 1129: 1084 000233C0 31 09 jeql L347 ! 1130: 1085 000233C2 # cosf_er_halt( BAD_ACC_HLT ); /* halt on the error */ ! 1131: 1086 000233C2 dd 01 pushl $1 ! 1132: 1087 000233C4 fe 08 ef0000005b callf $8,_cosf_er_halt ! 1133: 1088 000233CB # if( loop_on_err ) { ! 1134: 1089 000233CB L347: ! 1135: 1090 000233CB 5d effffff6a7 tstl _loop_on_err ! 1136: 1091 000233D1 31 0a jeql L348 ! 1137: 1092 000233D3 # force_loop = TRUE; /* set the force loop flag */ ! 1138: 1093 000233D3 0d 01 effffff69e movl $1,_force_loop ! 1139: 1094 000233DA # asm("brw _cosf_6_lp1");; /* and loop on the error */ ! 1140: 1095 000233DA 13 ff05 brw _cosf_6_lp1 ! 1141: 1096 000233DD # } /* end of loop on error */ ! 1142: 1097 000233DD # } /* end of compare error */ ! 1143: 1098 000233DD L348: ! 1144: 1099 000233DD # } /* end of WHILE loop */ ! 1145: 1100 000233DD L339: ! 1146: 1101 000233DD L335: ! 1147: 1102 000233DD 6d effffff695 incl _index ! 1148: 1103 000233E3 13 fec0 jbr L337 ! 1149: 1104 000233E6 L336: ! 1150: 1105 000233E6 # } /* end of subtest 6 */ ! 1151: 1106 000233E6 40 ret#2 ! 1152: 1107 000233E7 .set L331,0x0 ! 1153: 1108 000233E7 L333: ! 1154: 1109 000233E7 13 fea9 jbr L334 ! 1155: 1110 000233EA .data ! 1156: 1111 00000a58 * .text ! 1157: 1112 000233EA .align 1 ! 1158: 1113 000233EA .globl _print_cosf_data ! 1159: 1114 000233EA _print_cosf_data: ! 1160: 1115 000233EA 0000 .word L349 ! 1161: 1116 000233EC # ! 1162: 1117 000233EC # ! 1163: 1118 000233EC # /************************************************************************** ! 1164: 1119 000233EC # * ! 1165: 1120 000233EC # * PRINT THE DATA AND STORE RESULTS ! 1166: 1121 000233EC # * ! 1167: 1122 000233EC # * initial Acc = xxxxxxxx, stored = xxxxxxxx, data index = xx ! 1168: 1123 000233EC # * Acc expected = xxxxxxxx ! 1169: 1124 000233EC # **************************************************************************/ ! 1170: 1125 000233EC # print_cosf_data() ! 1171: 1126 000233EC # { ! 1172: 1127 000233EC 11 35 jbr L351 ! 1173: 1128 000233EE L352: ! 1174: 1129 000233EE # writes("initial Acc = "); ! 1175: 1130 000233EE .data 1 ! 1176: 1131 00000d1d * L353: ! 1177: 1132 00000d1d * 696E697469616C20416363203 .ascii "initial Acc = \0" ! 1178: D2000 ! 1179: 1133 00000d2c * .text ! 1180: 1134 000233EE dd 8f00000d1d pushl $L353 ! 1181: 1135 000233F4 fe 08 effffff67d callf $8,_writes ! 1182: 1136 000233FB # write32h( sgl_ld_acc ); ! 1183: 1137 000233FB dd effffff677 pushl _sgl_ld_acc ! 1184: 1138 00023401 fe 08 effffff670 callf $8,_write32h ! 1185: 1139 00023408 # writes(", final Acc = "); ! 1186: 1140 00023408 .data 1 ! 1187: 1141 00000d2c * L354: ! 1188: 1142 00000d2c * 2C202066696E616C204163632 .ascii ", final Acc = \0" ! 1189: 03D2000 ! 1190: 1143 00000d3c * .text ! 1191: 1144 00023408 dd 8f00000d2c pushl $L354 ! 1192: 1145 0002340E fe 08 effffff663 callf $8,_writes ! 1193: 1146 00023415 # write32h( sgl_st_acc ); ! 1194: 1147 00023415 dd effffff65d pushl _sgl_st_acc ! 1195: 1148 0002341B fe 08 effffff656 callf $8,_write32h ! 1196: 1149 00023422 # } ! 1197: 1150 00023422 40 ret#2 ! 1198: 1151 00023423 .set L349,0x0 ! 1199: 1152 00023423 L351: ! 1200: 1153 00023423 11 c9 jbr L352 ! 1201: 1154 00023425 .data ! 1202: 1155 00000a58 * .text ! 1203: 1156 00023425 00 .align 1 ! 1204: 1157 00023426 .globl _cosf_er_halt ! 1205: 1158 00023426 _cosf_er_halt: ! 1206: 1159 00023426 0000 .word L355 ! 1207: 1160 00023428 # ! 1208: 1161 00023428 # ! 1209: 1162 00023428 # ! 1210: 1163 00023428 # /************************************************************************** ! 1211: 1164 00023428 # * ! 1212: 1165 00023428 # * HALT ON ERROR ROUTINE ! 1213: 1166 00023428 # * ! 1214: 1167 00023428 # **************************************************************************/ ! 1215: 1168 00023428 # cosf_er_halt( halt_code ) ! 1216: 1169 00023428 # int halt_code; ! 1217: 1170 00023428 # { ! 1218: 1171 00023428 13 00a0 jbr L357 ! 1219: 1172 0002342B L358: ! 1220: 1173 0002342B # sgl_dummy1 = halt_code; /* get the error type */ ! 1221: 1174 0002342B 0d ad04 effffff645 movl 4(fp),_sgl_dummy1 ! 1222: 1175 00023433 # asm("movl _test_no,r0"); /* r0 = test number */ ! 1223: 1176 00023433 0d effffff63f 50 movl _test_no,r0 ! 1224: 1177 0002343A # asm("movl _subtest,r1"); /* r1 = subtest number */ ! 1225: 1178 0002343A 0d effffff638 51 movl _subtest,r1 ! 1226: 1179 00023441 # asm("movl _sgl_dummy1,r2"); /* r2 = error code */ ! 1227: 1180 00023441 0d effffff631 52 movl _sgl_dummy1,r2 ! 1228: 1181 00023448 # asm("movl _cycle,r3"); /* r3 = cycle count */ ! 1229: 1182 00023448 0d effffff62a 53 movl _cycle,r3 ! 1230: 1183 0002344F # asm("movl _sgl_ld_acc,r4"); /* r4 = initial data */ ! 1231: 1184 0002344F 0d effffff623 54 movl _sgl_ld_acc,r4 ! 1232: 1185 00023456 # asm("movl _sgl_st_acc,r5"); /* r5 = data stored */ ! 1233: 1186 00023456 0d effffff61c 55 movl _sgl_st_acc,r5 ! 1234: 1187 0002345D # asm("movl _sgl_expected,r6"); /* r6 = data expected */ ! 1235: 1188 0002345D 0d effffff615 56 movl _sgl_expected,r6 ! 1236: 1189 00023464 # asm("movl _index,r7"); /* r7 = data index */ ! 1237: 1190 00023464 0d effffff60e 57 movl _index,r7 ! 1238: 1191 0002346B # if( halt_code == BAD_REG_HLT ) { ! 1239: 1192 0002346B 1d ad04 02 cmpl 4(fp),$2 ! 1240: 1193 0002346F 21 3d jneq L359 ! 1241: 1194 00023471 # sgl_dummy1 = load_regs[index2]; ! 1242: 1195 00023471 0d effffff601 50 movl _index2,r0 ! 1243: 1196 00023478 0d 40effffff5f9 movl _load_regs[r0],_sgl_dummy1 ! 1244: effffff5f4 ! 1245: 1197 00023484 # sgl_dummy2 = store_regs[index2]; ! 1246: 1198 00023484 0d effffff5ee 50 movl _index2,r0 ! 1247: 1199 0002348B 0d 40effffff5e6 movl _store_regs[r0],_sgl_dummy2 ! 1248: effffff5e1 ! 1249: 1200 00023497 # asm("movl _index2,r6"); /* r6 = bad register # */ ! 1250: 1201 00023497 0d effffff5db 56 movl _index2,r6 ! 1251: 1202 0002349E # asm("movl _sgl_dummy2,r7"); /* r7 = actual value */ ! 1252: 1203 0002349E 0d effffff5d4 57 movl _sgl_dummy2,r7 ! 1253: 1204 000234A5 # asm("movl _sgl_dummy1,r8"); /* r8 = expected value */ ! 1254: 1205 000234A5 0d effffff5cd 58 movl _sgl_dummy1,r8 ! 1255: 1206 000234AC # } else ! 1256: 1207 000234AC 11 1b jbr L360 ! 1257: 1208 000234AE L359: ! 1258: 1209 000234AE # if( halt_code == BAD_PSL_HLT ) { ! 1259: 1210 000234AE 1d ad04 03 cmpl 4(fp),$3 ! 1260: 1211 000234B2 21 15 jneq L361 ! 1261: 1212 000234B4 # asm("movl _init_psl,r6"); /* r6 = initial PSL */ ! 1262: 1213 000234B4 0d effffff5be 56 movl _init_psl,r6 ! 1263: 1214 000234BB # asm("movl _psl_val,r7"); /* r7 = final PSL */ ! 1264: 1215 000234BB 0d effffff5b7 57 movl _psl_val,r7 ! 1265: 1216 000234C2 # asm("movl _exp_psl,r8"); /* r8 = expected PSL */ ! 1266: 1217 000234C2 0d effffff5b0 58 movl _exp_psl,r8 ! 1267: 1218 000234C9 # }; ! 1268: 1219 000234C9 L361: ! 1269: 1220 000234C9 L360: ! 1270: 1221 000234C9 # asm("halt"); /* HALT ... */ ! 1271: 1222 000234C9 00 halt ! 1272: 1223 000234CA # } ! 1273: 1224 000234CA 40 ret#2 ! 1274: 1225 000234CB .set L355,0x0 ! 1275: 1226 000234CB L357: ! 1276: 1227 000234CB 13 ff5d jbr L358 ! 1277: 1228 000234CE .data ! 1278: 1228 00045F46 .data
This archive runs on limited infrastructure. Preserving old code on modern bandwidth. Automated agents are requested to crawl responsibly.