Source Code

001196,000001: # Copyright 2004 Ronald S. Burkey <info@sandroid.org> 001197,000002: # 001198,000003: # This file is part of yaAGC. 001199,000004: 001200,000005: # yaAGC is free software; you can redistribute it and/or modify 001201,000006: # it under the terms of the GNU General Public License as published by 001202,000007: # the Free Software Foundation; either version 2 of the License, or 001203,000008: # (at your option) any later version. 001204,000009: 001205,000010: # yaAGC is distributed in the hope that it will be useful, 001206,000011: # but WITHOUT ANY WARRANTY; without even the implied warranty of 001207,000012: # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 001208,000013: # GNU General Public License for more details. 001209,000014: 001210,000015: # You should have received a copy of the GNU General Public License 001211,000016: # along with yaAGC; if not, write to the Free Software 001212,000017: # Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 001213,000018: 001214,000019: # Filename: ValidateTS.agc 001215,000020: # Purpose: This is the part of the Validation program that validates 001216,000021: # just the TS instruction. 001217,000022: # Mod history: 07/05/04 RSB. Began. 001218,000023: 001219,000024: 5360 24061 INCR ERRNUM 001220,000025: 001221,000026: # I think that the "normal" uses of TS have been 001222,000027: # adequately check by the previous tests, since data has 001223,000028: # been saved and compared for correctness. In other words, 001224,000029: # we know that it correctly saves data. That leaves 001225,000030: # only weird cases like overflow behavior and +-0 to check. 001226,000031: 001227,000032: # +0. 001228,000033: 5361 24062 INCR ERRSUB # 1 001229,000034: 5362 30007 CA ZEROES 001230,000035: 5363 54001 TS L 001231,000036: 5364 10001 CCS L 001232,000037: 5365 15505 TCF VTSERROR 001233,000038: 5366 15371 TCF TS1 001234,000039: 5367 15370 NOOP 001235,000040: 5370 15505 TCF VTSERROR 001236,000041: 5371 TS1 001237,000042: 001238,000043: # -0. 001239,000044: 5371 24062 INCR ERRSUB # 2 001240,000045: 5372 37423 CA NEGZERO 001241,000046: 5373 54001 TS L 001242,000047: 5374 10001 CCS L 001243,000048: 5375 15376 NOOP 001244,000049: 5376 15377 NOOP 001245,000050: 5377 15505 TCF VTSERROR 001246,000051: 001247,000052: # +Overflow 001248,000053: 5400 24062 INCR ERRSUB # 3 001249,000054: 5401 37443 CA MAXP 001250,000055: 5402 67435 AD TEN 001251,000056: 5403 54001 TS L # Should be 9. 001252,000057: 5404 15505 TCF VTSERROR # No overflow. 001253,000058: 5405 24062 INCR ERRSUB # 4 001254,000059: 5406 67424 AD NEGONE # A should have been +1. 001255,000060: 5407 00006 EXTEND 001256,000061: 5410 15412 BZF TS2 001257,000062: 5411 15505 TCF VTSERROR 001258,000063: 5412 24062 TS2 INCR ERRSUB # 5 001259,000064: 5413 37434 CA NINE 001260,000065: 5414 00006 EXTEND 001261,000066: 5415 60001 SU L 001262,000067: 5416 00006 EXTEND 001263,000068: 5417 15505 BZF VTSERROR # L contains overflow. 001264,000069: 5420 30001 CA L 001265,000070: 5421 54063 TS TEMPI 001266,000071: 5422 15423 NOOP 001267,000072: 5423 37434 CA NINE 001268,000073: 5424 00006 EXTEND 001269,000074: 5425 60063 SU TEMPI # ... but TEMPI does not. 001270,000075: 5426 00006 EXTEND 001271,000076: 5427 15431 BZF +2 001272,000077: 5430 15505 TCF VTSERROR 001273,000078: 001274,000079: 5431 TS3 001275,000080: 001276,000081: # -Overflow 001277,000082: 5431 24062 INCR ERRSUB # 6 001278,000083: 5432 37435 CA TEN 001279,000084: 5433 54001 TS L 001280,000085: 5434 37447 CA MAXN 001281,000086: 5435 00006 EXTEND 001282,000087: 5436 60001 SU L 001283,000088: 5437 54001 TS L # Should be -9. 001284,000089: 5440 15505 TCF VTSERROR # No overflow. 001285,000090: 5441 24062 INCR ERRSUB # 7 001286,000091: 5442 67430 AD ONE # A should have been -1. 001287,000092: 5443 00006 EXTEND 001288,000093: 5444 15446 BZF TS4A 001289,000094: 5445 15505 TCF VTSERROR 001290,000095: 5446 24062 TS4A INCR ERRSUB # 10 octal 001291,000096: 5447 37434 CA NINE 001292,000097: 5450 60001 AD L 001293,000098: 5451 00006 EXTEND 001294,000099: 5452 15505 BZF VTSERROR # L contains overflow. 001295,000100: 5453 30001 CA L 001296,000101: 5454 54063 TS TEMPI 001297,000102: 5455 15456 NOOP 001298,000103: 5456 37434 CA NINE 001299,000104: 5457 60063 AD TEMPI 001300,000105: 5460 00006 EXTEND 001301,000106: 5461 15463 BZF +2 # ... but TEMPI does not. 001302,000107: 5462 15505 TCF VTSERROR 001303,000108: 001304,000109: 5463 TS4 001305,000110: 001306,000111: # No overflow 001307,000112: 5463 24062 INCR ERRSUB # 11 001308,000113: 5464 37433 CA FIVE 001309,000114: 5465 40000 COM 001310,000115: 5466 54001 TS L # -5 001311,000116: 5467 15471 TCF TS5A # No overflow. 001312,000117: 5470 15505 TCF VTSERROR # Overflow. 001313,000118: 5471 24062 TS5A INCR ERRSUB # 12 001314,000119: 5472 67433 AD FIVE # A should have been -5. 001315,000120: 5473 00006 EXTEND 001316,000121: 5474 15476 BZF TS5 001317,000122: 5475 15505 TCF VTSERROR 001318,000123: 5476 24062 TS5 INCR ERRSUB # 13 001319,000124: 5477 37433 CA FIVE 001320,000125: 5500 60001 AD L 001321,000126: 5501 00006 EXTEND 001322,000127: 5502 15504 BZF TS6 001323,000128: 5503 15505 TCF VTSERROR 001324,000129: 5504 TS6 001325,000130: 001326,000131: 5504 15506 TCF +2 001327,000132: 5505 07240 VTSERROR TC ERRORDSP 001328,000133: 5506 30007 CA ZEROES 001329,000134: 5507 54062 TS ERRSUB 001330,000135: End of include-file ValidateTS.agc. Parent file is Validation.agc