Create runtime_files directory for some benchmarks
authorMichal Terepeta <michal.terepeta@gmail.com>
Thu, 4 May 2017 12:47:03 +0000 (08:47 -0400)
committerBen Gamari <ben@smart-cactus.org>
Thu, 4 May 2017 12:48:05 +0000 (08:48 -0400)
Summary:
This creates `runtime_files` subdirectory for benchmarks that need
some files at runtime. This make it clear what files are actually
needed to run the benchmarks and makes it much easier to support
building/running them out of separate build directory.

This affects the following benchmarks:
- real/anna
- real/cacheprof
- real/fluid
- real/hidden
- real/maillist
- real/prolog
- real/scs
- spectral/expert
- spectral/mate
- spectral/para
- spectral/treejoin

Signed-off-by: Michal Terepeta <michal.terepeta@gmail.com>
Test Plan: build & run

Reviewers: bgamari

Reviewed By: bgamari

Subscribers: snowleopard

Differential Revision: https://phabricator.haskell.org/D3411

52 files changed:
.gitignore
real/anna/Main.hs
real/anna/runtime_files/anna_table [moved from real/anna/anna_table with 100% similarity]
real/cacheprof/Main.hs
real/cacheprof/runtime_files/cacheprof_hooks2_x86.s [moved from real/cacheprof/cacheprof_hooks2_x86.s with 100% similarity]
real/fluid/fluid.stdin
real/fluid/runtime_files/chan8.dat [moved from real/fluid/chan8.dat with 100% similarity]
real/hidden/Makefile
real/hidden/runtime_files/bookcase.plate [moved from real/hidden/objects/bookcase.plate with 100% similarity]
real/hidden/runtime_files/cube.plate [moved from real/hidden/objects/cube.plate with 100% similarity]
real/hidden/runtime_files/four.plate [moved from real/hidden/objects/four.plate with 100% similarity]
real/hidden/runtime_files/horse.plate [moved from real/hidden/objects/horse.plate with 100% similarity]
real/hidden/runtime_files/houses.plate [moved from real/hidden/objects/houses.plate with 100% similarity]
real/hidden/runtime_files/pyramid.plate [moved from real/hidden/objects/pyramid.plate with 100% similarity]
real/hidden/runtime_files/rad.plate [moved from real/hidden/objects/rad.plate with 100% similarity]
real/hidden/runtime_files/table.plate [moved from real/hidden/objects/table.plate with 100% similarity]
real/maillist/maillist.stdin
real/maillist/maillist.stdout
real/maillist/runtime_files/addresses [moved from real/maillist/addresses with 100% similarity]
real/prolog/Main.hs
real/prolog/prolog.stdout
real/prolog/runtime_files/stdlib [moved from real/prolog/stdlib with 100% similarity]
real/scs/Makefile
real/scs/runtime_files/inverter.in [moved from real/scs/inverter.in with 100% similarity]
spectral/expert/Main.hs
spectral/expert/runtime_files/animals [moved from spectral/expert/animals with 100% similarity]
spectral/mate/Makefile
spectral/mate/mate.stdout
spectral/mate/runtime_files/ellerman.prob [moved from spectral/mate/ellerman.prob with 100% similarity]
spectral/mate/runtime_files/ellerman.soln [moved from spectral/mate/ellerman.soln with 100% similarity]
spectral/mate/runtime_files/fridlizius.prob [moved from spectral/mate/fridlizius.prob with 100% similarity]
spectral/mate/runtime_files/fridlizius.soln [moved from spectral/mate/fridlizius.soln with 100% similarity]
spectral/mate/runtime_files/heathcote3.prob [moved from spectral/mate/heathcote3.prob with 100% similarity]
spectral/mate/runtime_files/heathcote3.soln [moved from spectral/mate/heathcote3.soln with 100% similarity]
spectral/mate/runtime_files/holzhausen.prob [moved from spectral/mate/holzhausen.prob with 100% similarity]
spectral/mate/runtime_files/holzhausen.soln [moved from spectral/mate/holzhausen.soln with 100% similarity]
spectral/mate/runtime_files/kidson.prob [moved from spectral/mate/kidson.prob with 100% similarity]
spectral/mate/runtime_files/kohtz.prob [moved from spectral/mate/kohtz.prob with 100% similarity]
spectral/mate/runtime_files/kohtz.soln [moved from spectral/mate/kohtz.soln with 100% similarity]
spectral/mate/runtime_files/marin.prob [moved from spectral/mate/marin.prob with 100% similarity]
spectral/mate/runtime_files/marin.soln [moved from spectral/mate/marin.soln with 100% similarity]
spectral/mate/runtime_files/shinkman.prob [moved from spectral/mate/shinkman.prob with 100% similarity]
spectral/mate/runtime_files/shinkman.soln [moved from spectral/mate/shinkman.soln with 100% similarity]
spectral/mate/runtime_files/simple.prob [moved from spectral/mate/simple.prob with 100% similarity]
spectral/mate/runtime_files/simple.soln [moved from spectral/mate/simple.soln with 100% similarity]
spectral/mate/runtime_files/wurzburg.prob [moved from spectral/mate/wurzburg.prob with 100% similarity]
spectral/mate/runtime_files/wurzburg.soln [moved from spectral/mate/wurzburg.soln with 100% similarity]
spectral/para/Makefile
spectral/para/runtime_files/input-data [moved from spectral/para/input-data with 100% similarity]
spectral/treejoin/Makefile
spectral/treejoin/runtime_files/27000.1 [moved from spectral/treejoin/27000.1 with 100% similarity]
spectral/treejoin/runtime_files/27000.2 [moved from spectral/treejoin/27000.2 with 100% similarity]

index 9fcfe34..24e76f2 100644 (file)
@@ -41,7 +41,7 @@ real/hidden/hidden
 real/hpg/hpg
 real/infer/infer
 real/lift/lift
-real/maillist/addresses.tex
+real/maillist/runtime_files/addresses.tex
 real/maillist/maillist
 real/mkhprog/mkhprog
 real/parser/parser
index 92d9d89..e9136c1 100644 (file)
@@ -158,7 +158,7 @@ main :: IO ()
 main = do
     raw_args <- getArgs
     let cmd_line_args = maGetFlags raw_args
-    tableStr <- readFile ("anna_table")
+    tableStr <- readFile ("runtime_files/anna_table")
     file_contents <- getContents
     let table = rtReadTable tableStr
     putStr (maStrictAn table cmd_line_args file_contents)
index 7964034..313d115 100644 (file)
@@ -1439,8 +1439,8 @@ main = seq stderr (       -- avoid bug in ghc-4.04
           f   <- getContents
           aux <- case prof_level of
                   0 -> return ""
-                  1 -> readFile "cacheprof_hooks1_x86.s"
-                  2 -> readFile "cacheprof_hooks2_x86.s"
+                  1 -> readFile "runtime_files/cacheprof_hooks1_x86.s"
+                  2 -> readFile "runtime_files/cacheprof_hooks2_x86.s"
 
           out <- doFile prof_level args f
           putStr out
index a5bba1b..8960431 100644 (file)
@@ -32,7 +32,7 @@ POINTS p ...
 1 2 3
 FILENAMES:
 DUMP     RESTART   VELVEC    PRESSURE  PATTERN   INPUT
-chan.dmp  chan.rst  chan.vec  chan.pre  chan.pat  chan8.dat 
+chan.dmp  chan.rst  chan.vec  chan.pre  chan.pat  runtime_files/chan8.dat 
 TEMPERTURE
 chan.tpr  
 ********************************************************************************
index 15cdef8..43f66d8 100644 (file)
@@ -2,7 +2,7 @@ TOP = ../..
 include $(TOP)/mk/boilerplate.mk
 
 SRC_RUNTEST_OPTS += +RTS -K1m -RTS
-PROG_ARGS = objects/four.plate
+PROG_ARGS = runtime_files/four.plate
 
 include $(TOP)/mk/target.mk
 
index d96f8fb..5a793bd 100644 (file)
@@ -1 +1 @@
-addresses
+runtime_files/addresses
index 5aa7244..b21a52d 100644 (file)
@@ -4,7 +4,7 @@ Welcome to the LaTex Mailing List Generator.
 (Please type Cntrl-D at file prompt to exit.)
 
 File to be converted: 
-Conversion completed; file addresses.tex written.
+Conversion completed; file runtime_files/addresses.tex written.
 
 File to be converted: 
 Goodbye!
index d98d217..4c8c84e 100644 (file)
@@ -55,7 +55,7 @@ main              = --echo False abort
                       interpreter clauses
 
 stdlib           :: String
-stdlib            = "stdlib"
+stdlib            = "runtime_files/stdlib"
 
 interpreter      :: [Clause] -> IO ()
 interpreter lib   = getContents >>= \ is ->
index 55714e8..c2379b7 100644 (file)
@@ -1,6 +1,6 @@
 Mini Prolog Version 1.5 (stack based)
 
-Reading stdlib........done
+Reading runtime_files/stdlib........done
 > ??
 append(nil,X,X).
 append(cons(X,Y),Z,cons(X,W)):==append(Y,Z,W).
index 163a005..88045e7 100644 (file)
@@ -1,6 +1,6 @@
 TOP = ../..
 include $(TOP)/mk/boilerplate.mk
-PROG_ARGS = inverter 345 10n 4u 1
+PROG_ARGS = runtime_files/inverter 345 10n 4u 1
 include $(TOP)/mk/target.mk
 
 
index 5b45193..b34e0e6 100644 (file)
@@ -35,7 +35,7 @@ main = do
     args <- getArgs
     case args of
       [filename] -> getData filename
-      []        -> getData "animals"
+      []        -> getData "runtime_files/animals"
       _                 -> hPutStr stderr ("Usage: " ++ prog ++ " datafile\n")
 
 getData filename = do
index 798ed44..aaf9895 100644 (file)
@@ -1,7 +1,11 @@
 TOP = ../..
 include $(TOP)/mk/boilerplate.mk
 
-PROG_ARGS = holzhausen.prob
+# It's necessary to specify those manually so that the current make-based system
+# compiles them in the right order.
+# TODO(michalt): This should go away once we move to the Shake-based system.
+HS_SRCS = Board.hs Move.hs Problem.hs Solution.hs Main.hs
+PROG_ARGS = runtime_files/holzhausen.prob
 
 #      Other problems
 # ellerman.prob heathcote3.prob kidson.prob marin.prob \
index 1188334..d55ea00 100644 (file)
@@ -1,5 +1,5 @@
 
-File: holzhausen.prob
+File: runtime_files/holzhausen.prob
  - - - - R - - K
  - - - - - - - b
  - b - - N - q -
index c5b5505..5914e56 100644 (file)
@@ -1,7 +1,7 @@
 TOP = ../..
 include $(TOP)/mk/boilerplate.mk
 
-PROG_ARGS = input-data
+PROG_ARGS = runtime_files/input-data
 
 include $(TOP)/mk/target.mk
 
index 159e26d..0566d83 100644 (file)
@@ -3,7 +3,7 @@ include $(TOP)/mk/boilerplate.mk
 
 # Arguments to test program
 SRC_RUNTEST_OPTS += +RTS -K3m -H24m -RTS
-PROG_ARGS = 27000.1 27000.2
+PROG_ARGS = runtime_files/27000.1 runtime_files/27000.2
 
 include $(TOP)/mk/target.mk