|
Related Topics:
| Score Surface for 94nop - Hi, some anonymous person (still called for ;-) is so kind to provide access to a pile of I have suggested to calculate one score surface for standard settings. It takes roughly 1000 times the time of one surface to..
Bug in pMARS - Hi, either I don't know how EQUs work or I have found a bug in the parser of pMARS. So far I cound pin it down to: ;name test ;assert CORESIZE == 800 v3 EQU 3 * (3 / 2 + 1) + 3 v4 EQU (CORESIZE - v3) dat.f v3, v4 With the..
KOTH.ORG: Status - ICWS Experimental 94 03/06/06 - Weekly Status on 03/06/06 -=- is up! Meetings held in #corewars -=- Tons of new features on pages -=- *FAQ* page located at: Current Status of the KOTH.ORG ICWS 94..
KOTH.ORG: Status - MultiWarrior 94 03/06/06 - Weekly Status on 03/06/06 -=- is up! Meetings held in #corewars -=- Tons of new features on pages -=- *FAQ* page located at: Current Status of the KOTH.ORG 94 CoreWar..
KOTH.ORG: Status - 94 No Pspace 03/06/06 - Weekly Status on 03/06/06 -=- is up! Meetings held in #corewars -=- Tons of new features on pages -=- *FAQ* page located at: Current Status of the KOTH.ORG 94 No Pspace CoreWar Hill:..
|
|
|
Next: Concept: FixedV2 (with very simple reviver ! ;) :..
|
| Author |
Message |
External

Since: May 25, 2006 Posts: 295
|
(Msg. 1) Posted: Fri Dec 21, 2007 10:38 am
Post subject: Concept: DoubleTroubleV1 ( Alternating programs, to detect dead programs and reviving them ) Archived from groups: rec>games>corewar (more info?)
|
|
|
;redcode
;name DoubleTroubleV1
;author SkybuckFlying
;strategy alternates programs to detect dead programs and revives the dead
programs.
;version 1
;date 21 december 2007
; Let's alternate between programs, this assures that programs are
functioning and gives insight into if the program is intact or dead.
; Works splendedly, program1 keeps reviving program2, while program2 is
d.e.a.d
; Now only thing to do is to incorporate a fixer and the program will be on
their way again ! =D
mov #1, Program1Run
mov #1, Program2Run
spl Program1Begin
spl Program2Begin
dat #0, #0
Program1Begin
jmz 0, Program1Run
nop 1
nop 2
nop 3
nop 4
nop 5
nop 6
mov.ab #0, Program1Run
; we are done running signal the other program to run
mov.ab #1, Program2Run
; reset wait time
mov.ab #9, Program1Wait
; wait for the other program to complete
Program1Wait djn 0, #9
; check if it completed, if it did ok simply run us.
jmz Program1Begin, Program2Run
; else revive program 2
spl Program2Begin
; program 2 might be dead so run ourselfs
mov.ab #1, Program1Run
jmp Program1Begin
Program1Run dat $0, $0
Program1End
Program2Begin
jmz 0, Program2Run
nop 1
nop 2
; nop 3
dat 3 ; pretend program 2 died.
nop 4
nop 5
nop 6
mov.ab #0, Program2Run
; we are done running signal the other program to run
mov.ab #1, Program1Run
; reset wait time
mov.ab #9, Program2Wait
; wait for the other program to complete
Program2Wait djn 0, #9
; check if it completed, if it did ok simply run us.
jmz Program2Begin, Program1Run
; else revive program 1
spl Program1Begin
; program 1 might be dead so run ourselfs
mov.ab #1, Program2Run
jmp Program2Begin
Program2Run dat $0, $0
Program2End >> Stay informed about: Concept: DoubleTroubleV1 ( Alternating programs, to detect.. |
|
| Back to top |
|
 |  |
External

Since: May 25, 2006 Posts: 295
|
(Msg. 2) Posted: Fri Dec 21, 2007 10:46 am
Post subject: Re: Concept: DoubleTroubleV1 ( Alternating programs, to detect dead programs and reviving them ) [Login to view extended thread Info.] Archived from groups: per prev. post (more info?)
|
|
|
|
|
| Back to top |
|
 |  |
|