Tuesday, December 29, 2009

Freecell Solver 2.38.0 was Released

Freecell Solver version 2.38.0 has been released. It is available in the form of a source tarball from the download page.

This is a minor release which makes sure one can build Freecell Solver outside the source distribution (e.g: mkdir build ; cd build ; cmake ..) without AsciiDoc, adds a --pysolfc (or an -F for short) flag to make_pysol_freecell_board.py and fixes one of the help displays.

Friday, November 27, 2009

Freecell Solver 2.36.0 was Released

Freecell Solver version 2.36.0 has been released. It is available in the form of a source tarball from the download page.

The main highlight of this release is that the plaintext documentation that was part of the source distribution were converted to AsciiDoc, a lightweight markup language that allows the plaintext and human-readable sources to be converted to HTML, to DocBook/XML, to PDF and to other formats. As a result, they are now also available online in HTML formats.

Furthermore, the process for getting the test suite and benchmarking process up and running were considerably simplified, thanks to the input received by Dimitri Leca (Pythack).

Finally, there are some other more minor improvements. This release has been delayed quite a bit due to some neglect on the part of the main maintainer, but we hope you find what's new satisfying enough. Happy solving!

Thursday, July 23, 2009

Screencast of Freecell Solver in Action

Yesterday, I spent some time on preparing a screencast of PySolFC auto-solving a deal of Freecell using Freecell Solver . Here's an embedded player:

I remember the first time I saw KDE's KPatience automatically solving a deal of Freecell, while using Freecell Solver as its back-end. Seeing the cards move on their own was very cool, and brought me a lot of joy. Now that PySolFC has built-in support for Freecell Solver, I was able to use it to prepare the screencast. I hope you'll enjoy seeing this screencast, and would be interested in trying out PySolFC and Freecell Solver.

I'm going to blog about how I prepared the screencast on my tech blog, which may prove instructive to other people wanting to prepare screencasts on Linux. This was the first video I ever prepared and producing it proved to be a pleasant experience, even though some tasks did not work right away.

Saturday, July 11, 2009

Freecell Solver 2.34.0 was Released

Freecell Solver version 2.34.0 has been released. It is available in the form of a source tarball from the download page.

Back in the abandoned 2.10.x branch a programmer called Michael Mann contributed a new Simple Simon move function that allowed it to solve more games. In 2.34.0 this move function was restored, and made optional. We now have a theme called "the-last-mohican" (or "tlm" for short), after the movie "The Last of the Mohicans" by a different Michael Mann, which I have watched and enjoyed, that is capable of solving over 90% of the first 5,000 PySol Simple Simon deals. (Incidentally "The Last Mohican" is the direct translation of the book and movie's name in Hebrew). The solutions of the solver were verified to be correct using Games-Solitaire-Verify.

Working on this theme uncovered a bug in the solver where the --next-instance flag was removed by accident, and it is now fixed.

Aside from that, there's now an improved atomic moves theme - "toons-for-twenty-somethings", which can solve all of MS Freecell's 32,000 deals. It is still much slower than the meta-moves-based theme.

There are also some other more minor changes, which can be found at the NEWS file in the distribution.

Friday, June 26, 2009

Maintenance Freecell Solver 2.32.1 Release

Hot on the heels of Freecell Solver 2.32.0, there's now a 2.32.1 maintenance release available from the download page. This release fixes several important build bugs, especially on Windows, but also on UNIXes.

Please test it to see if any other problems remain.

Wednesday, June 24, 2009

Freecell Solver 2.32.0 was Released

Freecell Solver version 2.32.0 has been released. It is available in the form of a source tarball from the download page.

This version features a large code cleanup which also resulted in a substantial speed boost. The code cleanup was guided by a script that was written to list all occurrences of identifiers with the same name, in order to find uncommon identifiers.

There were several bug-fixes done to the CMake-based build system, and there's now support for Google's tcmalloc and hidden internal identifiers in the DLL/shared-library. The inline keyword for defining inline functions is now supported on more compilers and more functions or macros have been converted to inline functions.

We hope you enjoy this release.

Sunday, June 7, 2009

Freecell Solver 2.30.0 was Released

Freecell Solver version 2.30.0 has been released. It is available in the form of a source tarball from the download page.

This release adds the run-time presets "gooey-unknown-thing", "sand-stone" and "slick-rock" that aim to minimise the average lengths of the resultant solutions. (as opposed to minimising the time it takes to solve). It also adds support for using any of the tree implementation supplied by libavl version 2 for both the positions storage and the stacks storage.

There's a bug fix in the fc-pro range solver for a bug that caused the Freecell Pro compatible moves to be mis-calculated. Moreover, the code has experienced a substantial re-organisation and the Makefiles for the different compiler were merged into one (which was later fixed).

There are also new compile-time options to exclude various functionality that may not be needed.

Download it while its hot!

Friday, May 29, 2009

Adventures in Compiling

I've generally been using GCC (= The GNU Compiler Collection) exclusively for compiling Freecell Solver under Linux for its constant development. For a time, I used to compile the Windows binaries using Microsoft Visual C ("cl.exe") and a really hideous batch file I wrote for the purpose (so it would work on the Technion's computers). Lately, however, I've switched to compiling using MinGW on Windows, which is gcc based.

A few weeks ago, I decided to try out other compilers and see what they had to offer. I downloaded the proprietary icc (Intel's C Compiler), which is gcc-compatible and has a Linux trial version. It was a huge download and ended up occupying a lot of space on the hard-disk. At first, I could not get it to emit working code, but after messing a little with my makefiles, I was successful. It is about the same speed as gcc for compiling my ANSI C program (maybe a bit slower), and generates somewhat faster code.

.

icc kept emitting many of the so-called "remarks" which I eventually took upon myself to eliminate. This improved the quality of my code. But it worked properly with these many remarks being emitted. After installing icc, msec (the Mandriva security mechanism) complained about world-writable files in the icc installation, so I reported it on the Intel forum.

The next compiler I tried was tcc, the Tiny/Turbo C Compiler. The version in the Mandriva repositories was old and did not yield a working binary, and so I tried upgrading to version 0.9.24 and then to the git version, but none of them worked either. I reported this attempt to the tcc mailing list.

I also tried icc's -fast flag, which is supposed to make the output faster, but it actually made the binaries slower (much slower than even gcc).

However, later on, after cleaning up my makefile, tcc produced perfectly working binaries. I don't know what the problem was, but it was solved. (I reported that in a reply). Compiling with tcc is much faster than with gcc, but the resulting code is much slower than gcc's, and occupies more space on the disk.

The next compiler was TenDRA. Now the homepage a 403 (and still does) and so I went on Freenode and asked. I eventually did:

$ svn co http://svn.tendra.org/trunk/

Only to discover that http://svn.tendra.org/trunk/tendra/INSTALL is empty except for a reference to the Trac web-site (which was also off-line). So I needed to use the guidance of the people from Freenode's #tendra to build it.

In the process, I had to install bmake, because that's the only make that would compile TenDRA. The ./configure in the standard distribution failed to work here, but I was able to find an .src.rpm which compiled and installed fine. The TenDRA boot process also complained about one of my system's header which had a list or enum with a trailing comma, and I had to manually fix the code.

But I was able to build TenDRA and install it, and it was able to compile a working program. Before it did, though, I had to fix many compilation errors it reported, as TenDRA is stricter than gcc. It also didn't recognise my use of strdup, and I had to specify -Ysystem for it to work (the previous -Y's I tried did not work properly). But then it worked.

TenDRA generated larger and slower executables than gcc but it worked.

I failed to get lcc (which isn't strictly open source ) and pcc (which is open source ) to either compile or produce working code. Seems like neither of them are ready for prime time - at least not here on Mandriva Linux Cooker.

So after a lot of frustration, my experiments with different compilers were mostly successful. As a result, my code is more strict, and better tested. So I guess it was worth it.

Sunday, May 17, 2009

Freecell Solver 2.28.0 was Released

Freecell Solver version 2.28.0 has been released. It is available in the form of a source tarball from the download page.

This version contains several significant optimisations. Now the "freecell-only" preset can solve the first 32,000 Microsoft Freecell deals at 286 deals per second with gcc, and 301 deals per seconds with Intel's icc. (on a Pentium 4 2.4GHz computer). There are many other internal cleanups, build system tweaks, and new makefiles to build using some alternative C compilers.

The source archives from now on will be distributed as tar.bz2 instead of tar.gz which gives better compression, and a faster download.

Monday, April 27, 2009

Freecell Solver 2.26.0 was Released

Freecell Solver version 2.26.0 has been released It is available in the form of a source tarball from the download page.

This version contains several significant optimisations (up to the point where the "freecell-only" preset can solve the first 32,000 Microsoft Freecell deals in 200 deals per second.), and improvements to the build system (including the elimination of compiler warnings). Finally, the test suite now builds correctly inside the source distribution.

We have more ideas for optimisations and other enhancements, and this is just an intermediate release (but one which should be perfectly usable).

Saturday, April 18, 2009

Freecell Solver 2.24.0 was Released

Freecell Solver version 2.24.0 was released today. It is available in a source archive from the download page. Windows command-line binaries should be available momentarily.

This version contains some fixes to crashes and memory leaks when using the -opt with a range of boards (or otherwise when a solver instance is recycled), a new "freecell-solver-fc-pro-range-solve" executable (built by default, but not installed), which runs a range of deals using the solver and outputs the number of FCS moves, the number of FC-Pro moves, and the FC-Pro moves in standard notation.

For developers, this release also contains a build type for profiling, many cleanups to the code, and a makefile to generate LLVM bitcode.

Tuesday, March 31, 2009

Freecell Solver 2.22.0 was Released, Now Under the MIT/X11 License

Freecell Solver version 2.22.0 is now available for download from the download page. This release converts from Public Domain "licensing" which is problematic for source code to the more explicit and less controversial MIT/X11 License. (Some source files that had been originated by other parties are still under the public domain).

Also in this release is some fixes to the build system (in part thanks to a contribution by Risko Gergely), including the ability to prepare a static library.

Happy solving, and enjoy April Fool's Day Tomorrow.

Thursday, March 26, 2009

Freecell Solver 2.20.0 was Released, along with a Windows Installer

Freecell Solver version 2.20.0 is now available for download from the download page. The big news is that executables for Microsoft Windows (x86) are now available for it, for the first time since the early 2.8.x releases. And this time, they come in the form of an interactive "Next→Next→Finish" installer based on the Nullsoft Scriptable Install System (NSIS).

Also in this release are a fix to a crash when using the range solver with the "-opt" flag (and other similar scenarios), a more comprehensive NEWS file and some other fixes.

Saturday, March 21, 2009

Freecell Solver 2.18.0 Was Released

As previously announced on the fc-solve-discuss mailing list, version 2.18.0 of Freecell Solver is now available for download as a source tarball from the download page.

Here are some highlights of the new release:

  1. Added the FCS_FREECELL_ONLY compile-time flag to hard-code the settings for Freecell and thus allow a faster run-time. When applied, it improves the speed of the solver from 140 deals / second to 164 deals / second.
  2. Fixed using libredblack for states and stacks storage, and also added a libJudy-based backend for them.
  3. Added the -Wall (= turn "all" warnings on) by default for gcc in the CMake build.
  4. Updated the "TODO" file in the distribution which was heavily out-of-date.
  5. Documented the "What's new" of some previous releases in the "NEWS" file.
  6. Got rid of the Hard-DFS scan, which was no longer useful. It is still accepted as an argument, but is now using the Soft-DFS routines instead.
  7. Many internal refactorings, cleanups, tweaks and fine-tunings.

Thursday, March 19, 2009

Welcome to the fc-solve Blog

Welcome to fc-solve.blogspot.com. This will serve as the future blog and news-feed for Freecell Solver and related news, like general Freecell research, automated solving of other Card solitaire variants, and solving or playing other puzzles, riddles and games.

Freecell Solver started from a program I wrote (first in Perl and then re-implemented in ANSI C) to see if some ideas I had for solving Freecell would work. It performed well enough that I created a web page for it on my Technion's homesite, named it "Freecell Solver" and announced it on Freshmeat. Since then, due to the constant feedback I received from people who tried to use it, it was greatly enhanced and expanded.

One of the things I invested the most time in was the online resources for support and information. The web-site started from one page, and then had two pages, and now has at least ten different pages, all with a different purpose. I also started a mailing list at YahooGroups to discuss the program and related programs, and it proved to be very active and lively.

Another thing that I set up were release-news that were present on the front page of the site and the old news page. A few days ago, I thought to myself: "If I'm maintaining these news items, why not create a web feed out of them?" And if we're going to have a web-feed - why not have a blog, with comments and the whole enchilada?

So this is the next step in communicating about Freecell Solver and related matters - a weblog. It's also my excuse to play with Blogger.com, and see how it fares in comparison to other web-journal services I know. (Like my friend once said "You gotta move or you stone.").

So if you've got something to say, say it here in a comment. And remember: if you're not in it for fun - I'm out of here!