<feed xmlns='http://www.w3.org/2005/Atom'>
<title>gf-core.git/src/compiler/GF/System, branch master</title>
<subtitle>Unnamed repository; edit this file 'description' to name the repository.
</subtitle>
<id>https://git.adelon.net/gf-core.git/atom?h=master</id>
<link rel='self' href='https://git.adelon.net/gf-core.git/atom?h=master'/>
<link rel='alternate' type='text/html' href='https://git.adelon.net/gf-core.git/'/>
<updated>2019-05-15T10:05:38+00:00</updated>
<entry>
<title>Eliminate the dependency on time-compat</title>
<updated>2019-05-15T10:05:38+00:00</updated>
<author>
<name>Thomas Hallgren</name>
<email>th-github@altocumulus.org</email>
</author>
<published>2019-05-15T10:05:38+00:00</published>
<link rel='alternate' type='text/html' href='https://git.adelon.net/gf-core.git/commit/?id=86066d4b12d61e999740bf6a3a09b6547697ee13'/>
<id>urn:sha1:86066d4b12d61e999740bf6a3a09b6547697ee13</id>
<content type='text'>
It was only needed for compatibility with directory&lt;1.2, but
directory&gt;=1.2 has been shipped with ghc since ghc-7.6.

Note: time-compat-1.9.* (the current version) is a completely different
package, that does not provide the needed function toUTCTime, which
was provided in time-compat-0.1.*.
</content>
</entry>
<entry>
<title>Bump version requirements to base&gt;=4.6, Cabal&gt;=1.20</title>
<updated>2017-08-18T09:55:44+00:00</updated>
<author>
<name>Thomas Hallgren</name>
<email>th-github@altocumulus.org</email>
</author>
<published>2017-08-18T09:55:44+00:00</published>
<link rel='alternate' type='text/html' href='https://git.adelon.net/gf-core.git/commit/?id=0a0eaa01bcbe9574bb86a6470ca5139fbd32a9d3'/>
<id>urn:sha1:0a0eaa01bcbe9574bb86a6470ca5139fbd32a9d3</id>
<content type='text'>
Cabal&gt;=1.20 allows control over parallelism when compiling grammars from
Setup.hs and WebSetup.hs.

base&gt;=4.6 allows conditional compilation with CPP to be eliminated from
a few modules.

base-4.6 corresponds to GHC 7.6.3, which is what you get in
Debian 8 (aka jessie, aka oldstable) from 2015.
</content>
</entry>
<entry>
<title>Remove debug output introduced in previous patch</title>
<updated>2015-09-11T14:46:31+00:00</updated>
<author>
<name>hallgren</name>
<email>hallgren@chalmers.se</email>
</author>
<published>2015-09-11T14:46:31+00:00</published>
<link rel='alternate' type='text/html' href='https://git.adelon.net/gf-core.git/commit/?id=bde7347045ae510f66c135aba6862ff81a75419b'/>
<id>urn:sha1:bde7347045ae510f66c135aba6862ff81a75419b</id>
<content type='text'>
Oops.
</content>
</entry>
<entry>
<title>Parallel compilation: "gf -make -j" and "gf -make -j=n" now work as expected</title>
<updated>2015-09-11T14:18:01+00:00</updated>
<author>
<name>hallgren</name>
<email>hallgren@chalmers.se</email>
</author>
<published>2015-09-11T14:18:01+00:00</published>
<link rel='alternate' type='text/html' href='https://git.adelon.net/gf-core.git/commit/?id=9556cf453f6c1499a2907acd72d7b11211387b0d'/>
<id>urn:sha1:9556cf453f6c1499a2907acd72d7b11211387b0d</id>
<content type='text'>
  * "gf -make -j=n" uses n parallel threads.
  * "gf -make -j" adapts to the number of processors in the system.

This mimics how "cabal build -j" and "ghc --make -j" works.

Support for this is implemented in the new module GF.System.Concurrency and
it depends on the function Control.Concurrent.setNumCapabilities, which is
only available in GHC&gt;=7.6 (base&gt;=4.6). GF can still be compiled with
GHC&lt;7.6, but then you have to use +RTS -N -RTS to take advantage of
multicore processors.

To detect the number of processors in the system, the code depends on a
foreign import of a C function in the GHC run-time system.
</content>
</entry>
<entry>
<title>Documentation improvements and cleanup relating to the IOE monad</title>
<updated>2014-11-10T16:20:01+00:00</updated>
<author>
<name>hallgren</name>
<email>hallgren@chalmers.se</email>
</author>
<published>2014-11-10T16:20:01+00:00</published>
<link rel='alternate' type='text/html' href='https://git.adelon.net/gf-core.git/commit/?id=c707575bd7751ac3b03371edba478e37d3488448'/>
<id>urn:sha1:c707575bd7751ac3b03371edba478e37d3488448</id>
<content type='text'>
Renamed appIOE to tryIOE (it is analogous to 'try' in the standard libraries).
Removed unused IOE operations &amp; documented the remaining ones.
Removed/simplified superfluous uses of IOE operations.
</content>
</entry>
<entry>
<title>Some work to improve the structure of the haddock documenation</title>
<updated>2014-11-10T15:23:02+00:00</updated>
<author>
<name>hallgren</name>
<email>hallgren@chalmers.se</email>
</author>
<published>2014-11-10T15:23:02+00:00</published>
<link rel='alternate' type='text/html' href='https://git.adelon.net/gf-core.git/commit/?id=33571ba44f2a42502722a3b025b448efe1f0ab88'/>
<id>urn:sha1:33571ba44f2a42502722a3b025b448efe1f0ab88</id>
<content type='text'>
</content>
</entry>
<entry>
<title>Use terminfo to highlight warnings and errors in blue and red</title>
<updated>2014-10-28T19:04:48+00:00</updated>
<author>
<name>hallgren</name>
<email>hallgren@chalmers.se</email>
</author>
<published>2014-10-28T19:04:48+00:00</published>
<link rel='alternate' type='text/html' href='https://git.adelon.net/gf-core.git/commit/?id=0519493ca936c8e555cfdf9178195418e342ff05'/>
<id>urn:sha1:0519493ca936c8e555cfdf9178195418e342ff05</id>
<content type='text'>
This replaces the hardwired ANSI escape codes that were accidentally included
in a previous patch.

This adds a dependency on terminfo, but this should be unproblematic, since
haskeline already depends on the same underlying C library.

The color highlighting is omitted on Windows.
</content>
</entry>
<entry>
<title>More haddock documentation improvements</title>
<updated>2014-10-16T14:03:57+00:00</updated>
<author>
<name>hallgren</name>
<email>hallgren@chalmers.se</email>
</author>
<published>2014-10-16T14:03:57+00:00</published>
<link rel='alternate' type='text/html' href='https://git.adelon.net/gf-core.git/commit/?id=c924491289259fa8a5a259ed97f2d9e817e3338c'/>
<id>urn:sha1:c924491289259fa8a5a259ed97f2d9e817e3338c</id>
<content type='text'>
</content>
</entry>
<entry>
<title>(1) Refactor concurrency, (2) write to .gfo.tmp then rename to .gfo</title>
<updated>2014-09-08T15:43:20+00:00</updated>
<author>
<name>hallgren</name>
<email>hallgren@chalmers.se</email>
</author>
<published>2014-09-08T15:43:20+00:00</published>
<link rel='alternate' type='text/html' href='https://git.adelon.net/gf-core.git/commit/?id=4eb6b55e980fda9c4d260820f5a6d38dde3d0991'/>
<id>urn:sha1:4eb6b55e980fda9c4d260820f5a6d38dde3d0991</id>
<content type='text'>
(1) introduces the module GF.Infra.Concurreny with lifted concurrency
    operators (to reduce uses of liftIO) and some additional concurrency
    utilities, e.g. a function for sequential logging that is used in
    both GF.CompileInParallel and GFServer.
(2) avoids leaving broken .gfo files behind if compilation is aborted.
</content>
</entry>
<entry>
<title>Experimental: parallel batch compilation of grammars</title>
<updated>2014-08-25T09:56:00+00:00</updated>
<author>
<name>hallgren</name>
<email>hallgren@chalmers.se</email>
</author>
<published>2014-08-25T09:56:00+00:00</published>
<link rel='alternate' type='text/html' href='https://git.adelon.net/gf-core.git/commit/?id=d84c5ef1715c3e4aed4098ee9c847e2dcc86cba4'/>
<id>urn:sha1:d84c5ef1715c3e4aed4098ee9c847e2dcc86cba4</id>
<content type='text'>
On my laptop these changes speed up the full build of the RGL and example
grammars with 'cabal build' from ~95s to ~43s and the zero build from ~18s
to ~5s.

The main change is the introduction of the module GF.CompileInParallel that
replaces GF.Compile and the function GF.Compile.ReadFiles.getAllFiles. At
present, it is activated with the new -j flag, and it is only used when
combined with --make or --batch. In addition, to get parallel computations,
you need to add GHC run-time flags, e.g., +RTS -N -A20M -RTS, to the command
line.

The Setup.hs script has been modified to pass the appropriate flags to GF
for parallel compilation when compiling the RGL and example grammars, but you
need a recent version of Cabal for this to work (probably &gt;=1.20).

Some additonal refactoring were made during this work. A new monad is used to
avoid warnings/error messages from different modules to be intertwined when
compiling in parallel, so some functios that were hardiwred to the IO or IOE
monads have been lifted to work in arbitrary monads that are instances in
the appropriate classes.


</content>
</entry>
</feed>
