diff --git a/Source/DSPSpy/tests/if_test.ds b/Source/DSPSpy/tests/if_test.ds index 4f1eca1e6a..8260518423 100644 --- a/Source/DSPSpy/tests/if_test.ds +++ b/Source/DSPSpy/tests/if_test.ds @@ -7,55 +7,88 @@ lri $SR, #0x0001 ifs lri $IX0, #0x1337 -call send_back +call send_back ; 1 ifns lri $IX0, #0x1338 -call send_back +call send_back ; 2 lri $IX0, #0x0000 lri $SR, #0x0002 ifs lri $IX0, #0x1337 -call send_back +call send_back ; 3 ifns lri $IX0, #0x1338 -call send_back +call send_back ; 4 lri $IX0, #0x0000 lri $SR, #0x0004 ifs lri $IX0, #0x1337 -call send_back +call send_back ; 5 ifns lri $IX0, #0x1338 -call send_back +call send_back ; 6 lri $IX0, #0x0000 lri $SR, #0x0008 ifs lri $IX0, #0x1337 -call send_back +call send_back ; 7 ifns lri $IX0, #0x1338 -call send_back +call send_back ; 8 lri $IX0, #0x0000 lri $SR, #0x000a ifs lri $IX0, #0x1337 -call send_back +call send_back ; 9 ifns lri $IX0, #0x1338 -call send_back +call send_back ; 10 + +lri $IX0, #0x0000 +lri $SR, #0x0010 + +ifs +lri $IX0, #0x1337 +call send_back ; 11 + +ifns +lri $IX0, #0x1338 +call send_back ; 12 + +lri $IX0, #0x0000 +lri $SR, #0x0020 + +ifs +lri $IX0, #0x1337 +call send_back ; 13 + +ifns +lri $IX0, #0x1338 +call send_back ; 14 + +lri $IX0, #0x0000 +lri $SR, #0x0040 + +ifs +lri $IX0, #0x1337 +call send_back ; 15 + +ifns +lri $IX0, #0x1338 +call send_back ; 16 ; We're done, DO NOT DELETE THIS LINE jmp end_of_test diff --git a/Source/DSPSpy/tests/if_test2.ds b/Source/DSPSpy/tests/if_test2.ds index a548c6f64e..a4041e4c10 100644 --- a/Source/DSPSpy/tests/if_test2.ds +++ b/Source/DSPSpy/tests/if_test2.ds @@ -6,55 +6,88 @@ lri $SR, #0x0001 ifg lri $IX0, #0x1337 -call send_back +call send_back ; 1 ifle lri $IX0, #0x1338 -call send_back +call send_back ; 2 lri $IX0, #0x0000 - lri $SR, #0x0002 +lri $SR, #0x0002 ifg lri $IX0, #0x1337 -call send_back +call send_back ; 3 ifle lri $IX0, #0x1338 -call send_back +call send_back ; 4 lri $IX0, #0x0000 lri $SR, #0x0004 ifg lri $IX0, #0x1337 -call send_back +call send_back ; 5 ifle lri $IX0, #0x1338 -call send_back +call send_back ; 6 lri $IX0, #0x0000 lri $SR, #0x0008 ifg lri $IX0, #0x1337 - call send_back +call send_back ; 7 ifle lri $IX0, #0x1338 -call send_back +call send_back ; 8 lri $IX0, #0x0000 lri $SR, #0x000a ifg lri $IX0, #0x1337 -call send_back +call send_back ; 9 ifle lri $IX0, #0x1338 -call send_back +call send_back ; 10 + +lri $IX0, #0x0000 +lri $SR, #0x0010 + +ifg +lri $IX0, #0x1337 +call send_back ; 11 + +ifle +lri $IX0, #0x1338 +call send_back ; 12 + +lri $IX0, #0x0000 +lri $SR, #0x0020 + +ifg +lri $IX0, #0x1337 +call send_back ; 13 + +ifle +lri $IX0, #0x1338 +call send_back ; 14 + +lri $IX0, #0x0000 +lri $SR, #0x0040 + +ifg +lri $IX0, #0x1337 +call send_back ; 15 + +ifle +lri $IX0, #0x1338 +call send_back ; 16 ; We're done, DO NOT DELETE THIS LINE jmp end_of_test diff --git a/Source/DSPSpy/tests/if_test3.ds b/Source/DSPSpy/tests/if_test3.ds index 95f10080cd..a2c844dded 100644 --- a/Source/DSPSpy/tests/if_test3.ds +++ b/Source/DSPSpy/tests/if_test3.ds @@ -6,55 +6,88 @@ lri $SR, #0x0001 ifl lri $IX0, #0x1337 -call send_back +call send_back ; 1 ifge lri $IX0, #0x1338 -call send_back +call send_back ; 2 lri $IX0, #0x0000 lri $SR, #0x0002 ifl lri $IX0, #0x1337 -call send_back +call send_back ; 3 ifge lri $IX0, #0x1338 -call send_back +call send_back ; 4 lri $IX0, #0x0000 lri $SR, #0x0004 ifl lri $IX0, #0x1337 -call send_back +call send_back ; 5 ifge lri $IX0, #0x1338 -call send_back +call send_back ; 6 lri $IX0, #0x0000 lri $SR, #0x0008 ifl lri $IX0, #0x1337 -call send_back +call send_back ; 7 ifge lri $IX0, #0x1338 -call send_back +call send_back ; 8 lri $IX0, #0x0000 lri $SR, #0x000a ifl lri $IX0, #0x1337 -call send_back +call send_back ; 9 ifge lri $IX0, #0x1338 -call send_back +call send_back ; 10 + +lri $IX0, #0x0000 +lri $SR, #0x0010 + +ifl +lri $IX0, #0x1337 +call send_back ; 11 + +ifge +lri $IX0, #0x1338 +call send_back ; 12 + +lri $IX0, #0x0000 +lri $SR, #0x0020 + +ifl +lri $IX0, #0x1337 +call send_back ; 13 + +ifge +lri $IX0, #0x1338 +call send_back ; 14 + +lri $IX0, #0x0000 +lri $SR, #0x0040 + +ifl +lri $IX0, #0x1337 +call send_back ; 15 + +ifge +lri $IX0, #0x1338 +call send_back ; 16 ; We're done, DO NOT DELETE THIS LINE jmp end_of_test diff --git a/Source/DSPSpy/tests/if_test4.ds b/Source/DSPSpy/tests/if_test4.ds new file mode 100644 index 0000000000..c23f169ce1 --- /dev/null +++ b/Source/DSPSpy/tests/if_test4.ds @@ -0,0 +1,93 @@ +; This test checks the effect of various SR flags over ifz and ifnz +include "dsp_base.inc" + +lri $IX0, #0x0000 +lri $SR, #0x0001 + +ifz +lri $IX0, #0x1337 +call send_back ; 1 + +ifnz +lri $IX0, #0x1338 +call send_back ; 2 + +lri $IX0, #0x0000 +lri $SR, #0x0002 + +ifz +lri $IX0, #0x1337 +call send_back ; 3 + +ifnz +lri $IX0, #0x1338 +call send_back ; 4 + +lri $IX0, #0x0000 +lri $SR, #0x0004 + +ifz +lri $IX0, #0x1337 +call send_back ; 5 + +ifnz +lri $IX0, #0x1338 +call send_back ; 6 + +lri $IX0, #0x0000 +lri $SR, #0x0008 + +ifz +lri $IX0, #0x1337 +call send_back ; 7 + +ifnz +lri $IX0, #0x1338 +call send_back ; 8 + +lri $IX0, #0x0000 +lri $SR, #0x000a + +ifz +lri $IX0, #0x1337 +call send_back ; 9 + +ifnz +lri $IX0, #0x1338 +call send_back ; 10 + +lri $IX0, #0x0000 +lri $SR, #0x0010 + +ifz +lri $IX0, #0x1337 +call send_back ; 11 + +ifnz +lri $IX0, #0x1338 +call send_back ; 12 + +lri $IX0, #0x0000 +lri $SR, #0x0020 + +ifz +lri $IX0, #0x1337 +call send_back ; 13 + +ifnz +lri $IX0, #0x1338 +call send_back ; 14 + +lri $IX0, #0x0000 +lri $SR, #0x0040 + +ifz +lri $IX0, #0x1337 +call send_back ; 15 + +ifnz +lri $IX0, #0x1338 +call send_back ; 16 + +; We're done, DO NOT DELETE THIS LINE +jmp end_of_test diff --git a/Source/DSPSpy/tests/if_test5.ds b/Source/DSPSpy/tests/if_test5.ds new file mode 100644 index 0000000000..7cfcffc842 --- /dev/null +++ b/Source/DSPSpy/tests/if_test5.ds @@ -0,0 +1,93 @@ +; This test checks the effect of various SR flags over iflz and ifnlz +include "dsp_base.inc" + +lri $IX0, #0x0000 +lri $SR, #0x0001 + +iflz +lri $IX0, #0x1337 +call send_back ; 1 + +ifnlz +lri $IX0, #0x1338 +call send_back ; 2 + +lri $IX0, #0x0000 +lri $SR, #0x0002 + +iflz +lri $IX0, #0x1337 +call send_back ; 3 + +ifnlz +lri $IX0, #0x1338 +call send_back ; 4 + +lri $IX0, #0x0000 +lri $SR, #0x0004 + +iflz +lri $IX0, #0x1337 +call send_back ; 5 + +ifnlz +lri $IX0, #0x1338 +call send_back ; 6 + +lri $IX0, #0x0000 +lri $SR, #0x0008 + +iflz +lri $IX0, #0x1337 +call send_back ; 7 + +ifnlz +lri $IX0, #0x1338 +call send_back ; 8 + +lri $IX0, #0x0000 +lri $SR, #0x000a + +iflz +lri $IX0, #0x1337 +call send_back ; 9 + +ifnlz +lri $IX0, #0x1338 +call send_back ; 10 + +lri $IX0, #0x0000 +lri $SR, #0x0010 + +iflz +lri $IX0, #0x1337 +call send_back ; 11 + +ifnlz +lri $IX0, #0x1338 +call send_back ; 12 + +lri $IX0, #0x0000 +lri $SR, #0x0020 + +iflz +lri $IX0, #0x1337 +call send_back ; 13 + +ifnlz +lri $IX0, #0x1338 +call send_back ; 14 + +lri $IX0, #0x0000 +lri $SR, #0x0040 + +iflz +lri $IX0, #0x1337 +call send_back ; 15 + +ifnlz +lri $IX0, #0x1338 +call send_back ; 16 + +; We're done, DO NOT DELETE THIS LINE +jmp end_of_test