packages/binary.git
7 years agoBump version to 0.5.1.1 ghc-7.6 binary-0.5.1.1-release ghc-7.6.1-release ghc-7.6.2-release ghc-7.6.3-release
Paolo Capriotti [Tue, 10 Jul 2012 09:53:14 +0000 (10:53 +0100)] 
Bump version to 0.5.1.1

7 years agoUpdate .gitignore.
Paolo Capriotti [Tue, 6 Mar 2012 11:04:01 +0000 (11:04 +0000)] 
Update .gitignore.

7 years agoFix conditional LANGUAGE pragma by adding CPP.
Lennart Kolmodin [Thu, 12 Jan 2012 12:53:55 +0000 (16:53 +0400)] 
Fix conditional LANGUAGE pragma by adding CPP.

7 years agoUpdate my email.
Lennart Kolmodin [Sun, 18 Dec 2011 20:00:25 +0000 (00:00 +0400)] 
Update my email.

7 years agoFix conditional pragma to work with 6.12
David Terei [Tue, 9 Aug 2011 18:02:01 +0000 (11:02 -0700)] 
Fix conditional pragma to work with 6.12

7 years agoUse Safe Haskell when GHC >= 7.2
David Terei [Thu, 28 Jul 2011 18:29:21 +0000 (11:29 -0700)] 
Use Safe Haskell when GHC >= 7.2

8 years agoHave builder generate a lazy ByteString directly ghc-7.2 ghc-7.2.1-release ghc-7.2.2-release
Johan Tibell [Thu, 26 May 2011 08:30:38 +0000 (10:30 +0200)] 
Have builder generate a lazy ByteString directly

This improves performance with up to 10% on some benchmarks
(e.g. [Word8]).

8 years agoDrop support for GHC 6.6
Johan Tibell [Wed, 25 May 2011 11:31:01 +0000 (13:31 +0200)] 
Drop support for GHC 6.6

8 years agoInline toLazyByteString
Johan Tibell [Wed, 25 May 2011 10:25:55 +0000 (12:25 +0200)] 
Inline toLazyByteString

This improves the builder benchmarks that append ByteStrings:

Before:

benchmarking small ByteString
mean: 408.5667 ns, lb 408.1052 ns, ub 409.0075 ns, ci 0.950

benchmarking large ByteString
mean: 421.9131 ns, lb 421.3679 ns, ub 422.3981 ns, ci 0.950

benchmarking length-prefixed ByteString
mean: 13.16978 us, lb 13.16518 us, ub 13.17453 us, ci 0.950

After:

benchmarking small ByteString
mean: 374.0590 ns, lb 373.7738 ns, ub 374.3208 ns, ci 0.950

benchmarking large ByteString
mean: 387.2076 ns, lb 386.8554 ns, ub 387.5302 ns, ci 0.950

benchmarking length-prefixed ByteString
mean: 11.62633 us, lb 11.61974 us, ub 11.64948 us, ci 0.950

8 years agoRemove dead code
Johan Tibell [Wed, 25 May 2011 07:57:17 +0000 (09:57 +0200)] 
Remove dead code

8 years agoWhitespace cleanup
Johan Tibell [Wed, 25 May 2011 07:55:41 +0000 (09:55 +0200)] 
Whitespace cleanup

8 years agoRenamed D.B.Builder.Common to D.B.Builder.Base
Johan Tibell [Wed, 25 May 2011 07:30:51 +0000 (09:30 +0200)] 
Renamed D.B.Builder.Common to D.B.Builder.Base

8 years agoKeep all builder code in one place
Johan Tibell [Wed, 25 May 2011 07:27:36 +0000 (09:27 +0200)] 
Keep all builder code in one place

D.B.Builder and D.B.Builder.Internal simply re-export functions from
the D.B.Builder.Common module.

8 years agoMake it easier to set GHC flags in benchmark
Johan Tibell [Mon, 2 May 2011 20:49:12 +0000 (22:49 +0200)] 
Make it easier to set GHC flags in benchmark

8 years agoAdd missing BangPatterns pragma
Johan Tibell [Mon, 2 May 2011 20:48:36 +0000 (22:48 +0200)] 
Add missing BangPatterns pragma

8 years agoMerge branch 'master' of github.com:kolmodin/binary
Johan Tibell [Mon, 2 May 2011 20:08:33 +0000 (22:08 +0200)] 
Merge branch 'master' of github.com:kolmodin/binary

8 years agoFix bug where rewrite rules could cause incorrect output
Johan Tibell [Mon, 2 May 2011 15:21:42 +0000 (17:21 +0200)] 
Fix bug where rewrite rules could cause incorrect output

Closes #8

8 years agoAdd putCharUtf8
Johan Tibell [Mon, 2 May 2011 13:39:32 +0000 (15:39 +0200)] 
Add putCharUtf8

The implementation is based on the text package by Bryan O'Sullivan.

8 years agoAdd benchmark for writing small length-prefixed ByteStrings
Johan Tibell [Thu, 31 Mar 2011 12:30:39 +0000 (14:30 +0200)] 
Add benchmark for writing small length-prefixed ByteStrings

8 years agoAdd low-level combinator writeAtMost
Johan Tibell [Thu, 31 Mar 2011 11:29:19 +0000 (13:29 +0200)] 
Add low-level combinator writeAtMost

writeAtMost allows for more static bounds check merging using rules,
at the risk of wasting some buffer space.

8 years agoExpose semi-public internals
Johan Tibell [Thu, 31 Mar 2011 11:15:26 +0000 (13:15 +0200)] 
Expose semi-public internals

This allows users to write efficient builders, without modifying the
library.

Some code had to be moved around so that writeN could be exposed
without exposing any other internals.

8 years agoConvert some Put monad benchmarks into Builder benchmarks
Johan Tibell [Thu, 31 Mar 2011 08:44:58 +0000 (10:44 +0200)] 
Convert some Put monad benchmarks into Builder benchmarks

This lets us remove any potential overhead added by Put.

As a side benefit Criterion makes sure our benchmarks are robust.

8 years agoRemoved unused import
Johan Tibell [Thu, 31 Mar 2011 07:35:04 +0000 (09:35 +0200)] 
Removed unused import

8 years agoForce bench data before running benchmarks
Johan Tibell [Wed, 30 Mar 2011 17:35:26 +0000 (19:35 +0200)] 
Force bench data before running benchmarks

8 years agoAdd benchmark for strict ByteStrings
Johan Tibell [Wed, 30 Mar 2011 14:45:09 +0000 (16:45 +0200)] 
Add benchmark for strict ByteStrings

8 years agoIgnore more generated files
Johan Tibell [Wed, 30 Mar 2011 13:37:58 +0000 (15:37 +0200)] 
Ignore more generated files

8 years agoReplace writeNbytes by writeN and a cast
Johan Tibell [Wed, 30 Mar 2011 11:04:45 +0000 (13:04 +0200)] 
Replace writeNbytes by writeN and a cast

This makes the rewrite rules fire for host order writes as well.

8 years agoRemove HeapUse benchmark as it no longer works
Johan Tibell [Wed, 30 Mar 2011 13:32:10 +0000 (15:32 +0200)] 
Remove HeapUse benchmark as it no longer works

8 years agoCleaned up benchmark Makefile
Johan Tibell [Wed, 30 Mar 2011 13:29:31 +0000 (15:29 +0200)] 
Cleaned up benchmark Makefile

8 years agoRemove no longer used benchmark and code
Johan Tibell [Wed, 30 Mar 2011 13:27:27 +0000 (15:27 +0200)] 
Remove no longer used benchmark and code

8 years agoMove benchmarks to a dedicated directory
Johan Tibell [Wed, 30 Mar 2011 13:25:34 +0000 (15:25 +0200)] 
Move benchmarks to a dedicated directory

Made minor tweaks to make everything compile.

8 years agoAdd benchmark that directly exercises D.B.Builder
Johan Tibell [Wed, 30 Mar 2011 12:24:39 +0000 (14:24 +0200)] 
Add benchmark that directly exercises D.B.Builder

8 years agoIn benchmarks, use GHC to compile C sources
Antoine Latter [Wed, 30 Mar 2011 00:21:39 +0000 (19:21 -0500)] 
In benchmarks, use GHC to compile C sources

8 years agoAdd rewrite rules to merge bound checks on GHC 7 and later
Johan Tibell [Thu, 10 Mar 2011 14:31:46 +0000 (22:31 +0800)] 
Add rewrite rules to merge bound checks on GHC 7 and later

This change merges the bounds check in straight-line code like

    singleton 1 `mappend` (singleton 2 `mappend` singleton 3)

where the bounds are statically known.

This gives a 90% improvement when writing bytes in chunks.

Before:

    100MB of Word8 in chunks of 16 (Host endian): 68.5 MB/s write

After:

    100MB of Word8 in chunks of 16 (Host endian): 129.9 MB/s write

8 years agoBuilder: only use lazy I/O where necessary
Johan Tibell [Sat, 26 Feb 2011 23:17:14 +0000 (07:17 +0800)] 
Builder: only use lazy I/O where necessary

Each ByteString chunk must be built in one go and therefore we don't
need to be lazy in every write.  Lazy I/O is only needed to delay the
construction of the remaining ByteString chunks.

This also improves performance a bit:

Before
======

Binary (de)serialisation benchmarks:
100MB of Word8  in chunks of 16 (Host endian):   53.9 MB/s write
100MB of Word16 in chunks of 16 (Host endian):  104.8 MB/s write
100MB of Word32 in chunks of 16 (Host endian):  213.1 MB/s write
100MB of Word64 in chunks of 16 (Host endian):  131.5 MB/s write

After
=====

Binary (de)serialisation benchmarks:
100MB of Word8  in chunks of 16 (Host endian):   70.1 MB/s write
100MB of Word16 in chunks of 16 (Host endian):  144.2 MB/s write
100MB of Word32 in chunks of 16 (Host endian):  281.3 MB/s write
100MB of Word64 in chunks of 16 (Host endian):  146.8 MB/s write

8 years agoExplictly list needed language features
Johan Tibell [Sat, 26 Feb 2011 22:57:44 +0000 (06:57 +0800)] 
Explictly list needed language features

8 years agoAdded a .gitignore
Johan Tibell [Sat, 26 Feb 2011 00:45:04 +0000 (08:45 +0800)] 
Added a .gitignore

8 years agoInline mconcat
Johan Tibell [Fri, 25 Feb 2011 23:04:12 +0000 (15:04 -0800)] 
Inline mconcat

This results in better core and corresponding speed-ups.

8 years agoHelp the GHC 7.0.2 arity analyser
Johan Tibell [Fri, 25 Feb 2011 23:00:34 +0000 (15:00 -0800)] 
Help the GHC 7.0.2 arity analyser

By defining 'empty' as

    empty = Builder (\ k b -> k b)

instead of as

    empty = Builder id

the GHC arity analyser can figure out the arity of loops like this one

    fromWord8s [] = mempty
    fromWord8s (x:xs) = singleton x `mappend` fromWord8s xs

Before it would allocate and apply a closure for fromWord8s each time around the
loop instead of making a tail call.

8 years agoUpdate my email address
Lennart Kolmodin [Sat, 20 Nov 2010 15:21:18 +0000 (16:21 +0100)] 
Update my email address

8 years agoRemove deprecated -fglasgow-exts in favour of language extension flags
simonpj [Tue, 10 Aug 2010 16:25:07 +0000 (18:25 +0200)] 
Remove deprecated -fglasgow-exts in favour of language extension flags

8 years agoRemove unproductive UNPACK pragma
simonpj [Fri, 30 Jul 2010 12:30:14 +0000 (14:30 +0200)] 
Remove unproductive UNPACK pragma

8 years agoAdd type signature on local binding
simonpj [Fri, 30 Jul 2010 12:29:36 +0000 (14:29 +0200)] 
Add type signature on local binding

9 years agoSome tweaks to the testsuite
Don Stewart [Wed, 16 Sep 2009 17:44:04 +0000 (19:44 +0200)] 
Some tweaks to the testsuite

10 years agotweaks
Don Stewart [Mon, 23 Feb 2009 18:12:07 +0000 (19:12 +0100)] 
tweaks

9 years agoBump minor version: no API changes or semantic changes
Don Stewart [Wed, 16 Sep 2009 17:44:14 +0000 (19:44 +0200)] 
Bump minor version: no API changes or semantic changes

9 years agoMake Get a strict state monad, using unboxed tuples for speed
Simon Marlow [Tue, 15 Sep 2009 20:28:30 +0000 (22:28 +0200)] 
Make Get a strict state monad, using unboxed tuples for speed

Contrary to comments in the code, the bind operator for Get was lazy.
Making it strict and using unboxed tuples for the return type improves
performance for me.

One possible concern is whether the lazy Get monad is being relied on
to avoid stack overflow, but looking at the fix that was needed
recently for replicateM I'm presuming that this is not an issue.

10 years agominor bump
Don Stewart [Sat, 7 Mar 2009 23:57:33 +0000 (00:57 +0100)] 
minor bump

10 years agoFix laziness issue in getMany
Spencer Janssen [Sat, 7 Mar 2009 23:54:26 +0000 (00:54 +0100)] 
Fix laziness issue in getMany

10 years agoDocument getMany
Spencer Janssen [Sat, 7 Mar 2009 23:15:17 +0000 (00:15 +0100)] 
Document getMany

10 years agoReplace all instances of replicateM
Spencer Janssen [Sat, 7 Mar 2009 22:58:49 +0000 (23:58 +0100)] 
Replace all instances of replicateM

replicateM will cause a stack overflow when getting very large lists.  We
introduce getMany, which tail-recursively gets many elements and reverses them
at the end.  Compatibility with old versions is maintained.

10 years agoExpose Builder/Put relationship, courtesy Ross
Don Stewart [Thu, 12 Feb 2009 17:47:34 +0000 (18:47 +0100)] 
Expose Builder/Put relationship, courtesy Ross

10 years agoImproved instance for Sequence
Paulo Tanimoto [Sun, 8 Feb 2009 03:20:55 +0000 (04:20 +0100)] 
Improved instance for Sequence

The current implementation of put and get for Sequence merely converts it to (from) a list.  This misses the fact that we can get the length of a Sequence in O(1).  I wrote this patch with help from Ross Paterson, but I take responsibility for any omission.

10 years agoTim Newsham's runPutM patch
Don Stewart [Sun, 8 Feb 2009 17:58:25 +0000 (18:58 +0100)] 
Tim Newsham's runPutM patch

10 years agoBump in fork
Don Stewart [Sun, 8 Feb 2009 17:58:16 +0000 (18:58 +0100)] 
Bump in fork

10 years agoDisable explicit inlining in Get.hs, GHC is smarter than we are.
Don Stewart [Sat, 8 Nov 2008 23:10:59 +0000 (00:10 +0100)] 
Disable explicit inlining in Get.hs, GHC is smarter than we are.

10 years agonow Map/Set.size is used instead of List.length in 'put'
kr.angelov [Wed, 5 Nov 2008 20:00:03 +0000 (21:00 +0100)] 
now Map/Set.size is used instead of List.length in 'put'

10 years agolower the required bytestring version
Don Stewart [Thu, 28 Aug 2008 05:13:15 +0000 (07:13 +0200)] 
lower the required bytestring version

10 years agoCan't upload to hackage due to ghc < 6.5 flagggs
Don Stewart [Mon, 25 Aug 2008 21:05:44 +0000 (23:05 +0200)] 
Can't upload to hackage due to ghc < 6.5 flagggs

10 years agoWHNF the tail of a bytestring on decodeFile, will close the resource
Don Stewart [Mon, 25 Aug 2008 21:01:09 +0000 (23:01 +0200)] 
WHNF the tail of a bytestring on decodeFile, will close the resource

11 years agomore typos
Don Stewart [Fri, 18 Jul 2008 21:55:29 +0000 (23:55 +0200)] 
more typos

11 years agotypo
Don Stewart [Fri, 18 Jul 2008 18:45:05 +0000 (20:45 +0200)] 
typo

11 years agotestimonial
Don Stewart [Mon, 14 Jul 2008 18:37:31 +0000 (20:37 +0200)] 
testimonial

11 years agosome more inlining
Don Stewart [Fri, 9 May 2008 23:55:55 +0000 (01:55 +0200)] 
some more inlining

11 years agomore inlining
Don Stewart [Fri, 9 May 2008 21:58:37 +0000 (23:58 +0200)] 
more inlining

11 years agoUse snd-strict pair for PutM state
Don Stewart [Fri, 9 May 2008 21:58:09 +0000 (23:58 +0200)] 
Use snd-strict pair for PutM state

11 years agoMinor updates to HCAR
Lennart Kolmodin [Fri, 9 May 2008 21:08:01 +0000 (23:08 +0200)] 
Minor updates to HCAR

11 years agoMore attention to inlining of primitives
Don Stewart [Fri, 9 May 2008 18:51:22 +0000 (20:51 +0200)] 
More attention to inlining of primitives

11 years agoPay a bit more attention to inlining Put
Don Stewart [Fri, 9 May 2008 18:50:58 +0000 (20:50 +0200)] 
Pay a bit more attention to inlining Put

11 years agocrank up flags
Don Stewart [Fri, 9 May 2008 18:50:48 +0000 (20:50 +0200)] 
crank up flags

11 years agoUpdates to the HCAR
Lennart Kolmodin [Thu, 8 May 2008 22:42:47 +0000 (00:42 +0200)] 
Updates to the HCAR
Editing existing text to make it up to date

11 years agoUpdate links in HCAR entry
Lennart Kolmodin [Mon, 5 May 2008 17:40:53 +0000 (19:40 +0200)] 
Update links in HCAR entry

11 years agoLast HCAR entry from 2007-12
Lennart Kolmodin [Mon, 5 May 2008 16:59:31 +0000 (18:59 +0200)] 
Last HCAR entry from 2007-12

11 years ago-fallow-undecidable-instances really is a ghc option, not a cpp option
Duncan Coutts [Tue, 22 Apr 2008 08:48:19 +0000 (10:48 +0200)] 
-fallow-undecidable-instances really is a ghc option, not a cpp option

11 years agoindex.html
Don Stewart [Mon, 21 Apr 2008 23:12:11 +0000 (01:12 +0200)] 
index.html

11 years agobuild tests with -fhpc
Don Stewart [Mon, 21 Apr 2008 23:10:18 +0000 (01:10 +0200)] 
build tests with -fhpc

11 years ago+FlexibleContexts
Don Stewart [Mon, 21 Apr 2008 23:10:06 +0000 (01:10 +0200)] 
+FlexibleContexts

11 years agotypos, spotted by Jim Teisher
Don Stewart [Thu, 17 Apr 2008 15:24:34 +0000 (17:24 +0200)] 
typos, spotted by Jim Teisher

11 years agobump version
Don Stewart [Thu, 14 Feb 2008 21:59:20 +0000 (22:59 +0100)] 
bump version

11 years agoupdate docs
Don Stewart [Mon, 7 Jan 2008 23:24:25 +0000 (00:24 +0100)] 
update docs

11 years agoUse cpp-options rather than ghc-options where necessary
Spencer Janssen [Sat, 22 Dec 2007 05:51:18 +0000 (06:51 +0100)] 
Use cpp-options rather than ghc-options where necessary

11 years agoClean up Seq serialization
Spencer Janssen [Sat, 15 Dec 2007 08:23:19 +0000 (09:23 +0100)] 
Clean up Seq serialization

11 years agoAdd Applicative instances for PutM and Get
Spencer Janssen [Sat, 15 Dec 2007 05:06:20 +0000 (06:06 +0100)] 
Add Applicative instances for PutM and Get

11 years agopoint to in-tree homepage
Don Stewart [Wed, 28 Nov 2007 18:56:41 +0000 (19:56 +0100)] 
point to in-tree homepage

11 years agoupdate index.html
Don Stewart [Wed, 28 Nov 2007 18:56:01 +0000 (19:56 +0100)] 
update index.html

11 years agoadd homepage
Don Stewart [Wed, 28 Nov 2007 18:34:05 +0000 (19:34 +0100)] 
add homepage

11 years agoBump version to 0.4.1
Lennart Kolmodin [Sun, 21 Oct 2007 15:09:42 +0000 (17:09 +0200)] 
Bump version to 0.4.1

11 years agoFix compability with GHC < 6.8 on 32bit CPUs
Lennart Kolmodin [Sat, 20 Oct 2007 17:19:43 +0000 (19:19 +0200)] 
Fix compability with GHC < 6.8 on 32bit CPUs

11 years agoPortability fixes for ghc-6.4.2, ghc-6.6.1
Duncan Coutts [Tue, 16 Oct 2007 23:36:34 +0000 (01:36 +0200)] 
Portability fixes for ghc-6.4.2, ghc-6.6.1
Only tested on x86-64 with ghc-6.4.2 and ghc-6.6.1, not on ordinart 32bit x86

11 years agoand only explicitly import uncheckedShiftRL64# when < 64 bits
Don Stewart [Mon, 15 Oct 2007 17:39:46 +0000 (19:39 +0200)] 
and only explicitly import uncheckedShiftRL64# when < 64 bits

11 years agoImport missing function on 32bit
Lennart Kolmodin [Mon, 15 Oct 2007 05:14:10 +0000 (07:14 +0200)] 
Import missing function on 32bit

11 years agoFix typo in .cabal
Lennart Kolmodin [Sun, 14 Oct 2007 16:47:56 +0000 (18:47 +0200)] 
Fix typo in .cabal

11 years agocomment out ffi imports -- we can take them from GHC.Word now
Don Stewart [Fri, 12 Oct 2007 19:01:10 +0000 (21:01 +0200)] 
comment out ffi imports -- we can take them from GHC.Word now

11 years agoreplace calls to stg_ to hs_
Don Stewart [Thu, 11 Oct 2007 00:18:52 +0000 (02:18 +0200)] 
replace calls to stg_ to hs_

11 years agotested with 6.8 only
Don Stewart [Sat, 6 Oct 2007 15:10:56 +0000 (17:10 +0200)] 
tested with 6.8 only

11 years agomore text
Don Stewart [Sat, 6 Oct 2007 15:07:16 +0000 (17:07 +0200)] 
more text

11 years agobinary 0.4
Don Stewart [Sat, 6 Oct 2007 15:04:49 +0000 (17:04 +0200)] 
binary 0.4

11 years agoremove -Werror, interacts with -fhpc
Don Stewart [Sat, 6 Oct 2007 13:54:39 +0000 (15:54 +0200)] 
remove -Werror, interacts with -fhpc

11 years agoadd parallel driver
Don Stewart [Sat, 6 Oct 2007 13:54:05 +0000 (15:54 +0200)] 
add parallel driver

11 years agocrank em
Don Stewart [Sat, 6 Oct 2007 10:26:34 +0000 (12:26 +0200)] 
crank em