From news-rocq.inria.fr!univ-lyon1.fr!jussieu.fr!math.ohio-state.edu!howland.reston.ans.net!vixen.cso.uiuc.edu!news.uoregon.edu!premier3.premier.net!uunet!in1.uu.net!news2.new-york.net!news.stormking.com!morrell@math.utah.edu Wed Sep 13 10:48:47 1995 Article: 2297 of rec.games.corewar Path: news-rocq.inria.fr!univ-lyon1.fr!jussieu.fr!math.ohio-state.edu!howland.reston.ans.net!vixen.cso.uiuc.edu!news.uoregon.edu!premier3.premier.net!uunet!in1.uu.net!news2.new-york.net!news.stormking.com!morrell@math.utah.edu From: "Steven C. Morrell" Newsgroups: rec.games.corewar Subject: PGP Date: 13 Sep 1995 00:02:44 -0400 Organization: Storm King Ind. Inc. Lines: 85 Sender: server@news.stormking.com Distribution: world Message-ID: Reply-To: morrell@math.utah.edu NNTP-Posting-Host: valhalla.stormking.com Originator: corewar-l@stormking.com Okay, here is PGP. My philosophy with Porch Swing and Withershins Thrice is, "If you can't beat 'em, join 'em. And then beat 'em." So the strategy is: - Boot away and leave a decoy behind - One-shot scan at 89% of c. - Multipass core-clear with a STP run thrown in. Scanning at >80% c is not actually as tough as you might think. P. Kline unwound the scanning loop in Taking Names to 80% c. I just unwound it a little more. The STP.f instruction is a little misleading, but since there are no illegal instructions, why not? Actually, this was written before I realized that P-space just holds numbers between 0 and CORESIZE-1, and not instructions or operand-pairs. Pity the programmer who wants to store instructions in P-space (for more reasons than this)! The .f operand is converted to the closest thing that makes sense, which is .b so the STP.f # stores the B-value into where it points to points to. Or something like that. Since the core-clear modifies the B-field of the bomb it is carpeting with, the core is colored to provide a reasonable sweep through P-space with just one STP instruction, despite all the indirection. Plus, the values of munged P-space are somewhat unpredictable, so that the enemy has a tough time testing whether his P-space was hit. The code could be polished a little more, but it runs. As usual, it plays worst against Agony II. To fix that, I wrote sdrawkcaB as a more conservative version of PGP that scanned backwards, core-cleared backwards, and DJN'ed foreward. Nice, but the enemy tends to fall off the SPL carpet onto more useful instructions. ;redcode-94 verbose ;name PGP ;author Steven Morrell ;strategy Encrypt P-space for added security. ;kill PGP org boot offset equ 500 stream equ 250 step equ 12 first equ (20+step) flag equ 167 ; stp equ nop ;uncomment to make this run when VERSION<80 x mov p,p+offset ;Sloppy!!! (Just used as pointer) boot mov }x,>x for 16 mov }x,>x rof jmp scan+offset p dat first,first+step dat last-p,p stp.i #last-p,}p spl #last-p,}p-20 d spl #step*-2,#step*-2 ;Also sloppy loop sub d,p scan sne *p,@p sub d,p sne *p,@p sub d,p sne *p,@p sub d,p sne *p,@p djn.f loop,