Sargon 1978 - Bringing it back to life

Discussion of chess software programming and technical issues.

Moderators: bob, hgm, Harvey Williamson

Forum rules
This textbox is used to restore diagrams posted with the [d] tag before the upgrade.
Bill Forster
Posts: 29
Joined: Mon Sep 21, 2015 5:47 am
Location: New Zealand
Contact:

Sargon 1978 - Bringing it back to life

Post by Bill Forster » Wed May 20, 2020 1:35 am

My Covid-19 lockdown project has been porting the Z80 assembly language version of Sargon that Dan and Kathe Spracklen presented in their 1978 book into Intel x86 assembly language and packaging the whole thing as a UCI chess engine. If you are interested I have refined the whole thing into a rather polished project (I think) and published the results on Github https://github.com/billforsternz/retro-sargon where you can read all about it, in as much detail as you could ever want.

RubiChess
Posts: 169
Joined: Fri Mar 30, 2018 5:20 am

Re: Sargon 1978 - Bringing it back to life

Post by RubiChess » Wed May 20, 2020 4:56 am

Sargon II running on a Commodore VIC20 (coming on a cartridge) was my personal entrance to computer technology in 1982. Retro rules!! :-)

I will definitely have a look.

User avatar
Rebel
Posts: 5157
Joined: Thu Aug 18, 2011 10:04 am

Re: Sargon 1978 - Bringing it back to life

Post by Rebel » Wed May 20, 2020 6:19 am

Bill Forster wrote:
Wed May 20, 2020 1:35 am
My Covid-19 lockdown project has been porting the Z80 assembly language version of Sargon that Dan and Kathe Spracklen presented in their 1978 book into Intel x86 assembly language and packaging the whole thing as a UCI chess engine. If you are interested I have refined the whole thing into a rather polished project (I think) and published the results on Github https://github.com/billforsternz/retro-sargon where you can read all about it, in as much detail as you could ever want.
Hillarious.

I still have the book as well.
90% of coding is debugging, the other 10% is writing bugs.

jdart
Posts: 3924
Joined: Fri Mar 10, 2006 4:23 am
Location: http://www.arasanchess.org

Re: Sargon 1978 - Bringing it back to life

Post by jdart » Wed May 20, 2020 1:54 pm

Back around that time I did a lot of Z80 assembly programming, although not chess. I wrote a complete word processor in assembly.

User avatar
Steve Maughan
Posts: 1074
Joined: Wed Mar 08, 2006 7:28 pm
Location: Florida, USA
Contact:

Re: Sargon 1978 - Bringing it back to life

Post by Steve Maughan » Wed May 20, 2020 6:34 pm

Great project Bill! Keep us posted. I'd love to test it out when the time is right.

Steve
http://www.chessprogramming.net - Maverick Chess Engine

supersharp77
Posts: 867
Joined: Sat Jul 05, 2014 5:54 am
Location: Southwest USA

Re: Sargon 1978 - Bringing it back to life

Post by supersharp77 » Wed May 20, 2020 7:04 pm

Excellent Idea/Concept!.....How strong will it be? Can we make it Stronger/Deeper? Thx AR :D :wink:

Vinvin
Posts: 4556
Joined: Thu Mar 09, 2006 8:40 am
Full name: Vincent Lejeune

Re: Sargon 1978 - Bringing it back to life

Post by Vinvin » Wed May 20, 2020 8:03 pm

Thanks for this gift !
No easy to beat in a blitz game !

User avatar
silentshark
Posts: 270
Joined: Sat Mar 27, 2010 6:15 pm
Contact:

Re: Sargon 1978 - Bringing it back to life

Post by silentshark » Wed May 20, 2020 9:22 pm

What a fab thing to do!

I sometimes think it would be interesting if we had access to versions of some of these classic progams in something like C, and could see what a few modern techniques would do to playing strength.

So something like Sargon 3 with null move and LMR and LMP. How would that play on modern hardware?

Bill Forster
Posts: 29
Joined: Mon Sep 21, 2015 5:47 am
Location: New Zealand
Contact:

Re: Sargon 1978 - Bringing it back to life

Post by Bill Forster » Wed May 20, 2020 11:14 pm

supersharp77 wrote:
Wed May 20, 2020 7:04 pm
Excellent Idea/Concept!.....How strong will it be? Can we make it Stronger/Deeper? Thx AR :D :wink:
I cover these questions extensively on the Github project page. Have a read, I tried hard to make it interesting and entertaining.

Bill Forster
Posts: 29
Joined: Mon Sep 21, 2015 5:47 am
Location: New Zealand
Contact:

Re: Sargon 1978 - Bringing it back to life

Post by Bill Forster » Wed May 20, 2020 11:18 pm

Rebel wrote:
Wed May 20, 2020 6:19 am
Hillarious.
Oh dear, I was going for Hillary ("Because it's there!", "We knocked the bastard off!") but I get Hilarious :D
Rebel wrote:
Wed May 20, 2020 6:19 am
I still have the book as well.
My project adds quite a lot of value to the book. For a start a byproduct of the project is the code in proper Z80 assembly language https://github.com/billforsternz/retro- ... on-z80.asm, rather than the weird TDL mnemonics. More importantly, although the book's code is well and fully commented, it's very much one comment per line stuff, and it's hard to discern how the code really works. Of course when I ported it, it didn't just spring to life, it had to be convinced! I was wading around in the muck, in the dark, trying to work out which way was up. When I finally succeeded I decided to turn my lemons into lemonade by preserving the insights I gained as much as possible. In particular, I made executable documentation - a kind of window into the code, in which Sargon draws little ascii art diagrams of the minimax and alpha-beta algorithms as they do their work. You can observe as you step through with a debugger or just capture everything in this single file https://github.com/billforsternz/retro- ... output.txt and study it after the fact. I was amazed how alpha-beta is implemented in a few lines of assembly, when I wrote a toy engine alpha-beta tied me up in knots. I suspect it's only a subset of full alpha-beta actually, not really my strength, perhaps you could take a look and let me know?

Post Reply