ceecc846dd67

Add a benchrunner
[view raw] [browse files]
author Steve Losh <steve@stevelosh.com>
date Mon, 02 May 2016 17:55:07 +0000
parents d8d6647dd9fb
children 1fea3b65a964
branches/tags (none)
files Makefile examples/bench.lisp examples/ggp.lisp

Changes

--- a/Makefile	Mon May 02 16:44:29 2016 +0000
+++ b/Makefile	Mon May 02 17:55:07 2016 +0000
@@ -1,4 +1,4 @@
-.PHONY: test pubdocs
+.PHONY: test pubdocs bench
 
 sourcefiles = $(shell ffind --full-path --dir src --literal .lisp)
 docfiles = $(shell ls docs/*.markdown)
@@ -24,3 +24,5 @@
 	hg -R ~/src/sjl.bitbucket.org commit -Am 'bones: Update site.'
 	hg -R ~/src/sjl.bitbucket.org push
 
+bench:
+	sbcl-rlwrap --noinform --load examples/bench.lisp  --eval '(quit)'
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/examples/bench.lisp	Mon May 02 17:55:07 2016 +0000
@@ -0,0 +1,14 @@
+(declaim (optimize (speed 3) (safety 1) (debug 0)))
+
+(ql:quickload 'bones)
+
+(load "examples/ggp-paip.lisp")
+(load "examples/ggp.lisp")
+
+(in-package :bones.paip)
+(format t "PAIP ------------------------------~%")
+(time (dfs))
+
+(in-package :bones.wam)
+(format t "WAM -------------------------------~%")
+(time (dfs))
--- a/examples/ggp.lisp	Mon May 02 16:44:29 2016 +0000
+++ b/examples/ggp.lisp	Mon May 02 17:55:07 2016 +0000
@@ -1,7 +1,7 @@
 (in-package #:bones.wam)
 
-(declaim (optimize (speed 1) (safety 3) (debug 1)))
-; (declaim (optimize (speed 3) (safety 1) (debug 0)))
+; (declaim (optimize (speed 1) (safety 3) (debug 1)))
+(declaim (optimize (speed 3) (safety 1) (debug 0)))
 
 (defparameter *d* (make-database))