haskell-base64-bytestring: downgraded default version to 0.1.0.3

Michael Snoyman reports that version 0.1.1.0 has serious performance issues:

> import Data.ByteString.Base64
> import Data.ByteString.Char8 (pack)
> import Criterion.Main
>
> main :: IO ()
> main = defaultMain
>    [ bench "encode" $ whnf encode $ pack "qwerty"
>    ]

On version 0.1.0.3, this takes 229.4312 ns. On 0.1.1.0, it takes 3.556598 ms.
It looks like the problem is coming from the recent addition of URL encoding
(f1916d8a86).

svn path=/nixpkgs/trunk/; revision=32632
This commit is contained in:
Peter Simons 2012-02-27 20:27:41 +00:00
parent 9a42b0b52b
commit 9e371a98c2
3 changed files with 20 additions and 1 deletions

View File

@ -0,0 +1,17 @@
{ cabal }:
cabal.mkDerivation (self: {
pname = "base64-bytestring";
version = "0.1.0.3";
sha256 = "0d4j8b1d8z9qr1y446bfkj764xgilk8gw2frj0wn0717y8knvmx3";
meta = {
homepage = "https://github.com/bos/base64-bytestring";
description = "Fast base64 encoding and deconding for ByteStrings";
license = self.stdenv.lib.licenses.bsd3;
platforms = self.ghc.meta.platforms;
maintainers = [
self.stdenv.lib.maintainers.andres
self.stdenv.lib.maintainers.simons
];
};
})

View File

@ -456,7 +456,9 @@ let result = let callPackage = x : y : modifyPrio (newScope result.final x y);
base64String = callPackage ../development/libraries/haskell/base64-string {};
base64Bytestring = callPackage ../development/libraries/haskell/base64-bytestring {};
base64Bytestring_0_1_0_3 = callPackage ../development/libraries/haskell/base64-bytestring/0.1.0.3.nix {};
base64Bytestring_0_1_1_0 = callPackage ../development/libraries/haskell/base64-bytestring/0.1.1.0.nix {};
base64Bytestring = self.base64Bytestring_0_1_0_3; # Version 0.1.1.0 has serious performance issues.
baseUnicodeSymbols = callPackage ../development/libraries/haskell/base-unicode-symbols {};