@@ -134,11 +134,6 @@ source-repository head
134 type: git
134 type: git
135 location: https://github.com/composewell/streamly
135 location: https://github.com/composewell/streamly
138− description: Benchmark build
142flag inspection
137flag inspection
143 description: Enable inspection testing
138 description: Enable inspection testing
144 manual: True
139 manual: True
@@ -257,6 +252,7 @@ common exe-options
257common bench-options
252common bench-options
258 import: compile-options, optimization-options
253 import: compile-options, optimization-options
259 ghc-options: -with-rtsopts "-T"
254 ghc-options: -with-rtsopts "-T"
255+ build-depends: mtl >= 2.2 && < 3
261-------------------------------------------------------------------------------
257-------------------------------------------------------------------------------
262-- Library
258-- Library
@@ -354,12 +350,6 @@ library
354 , Streamly.Internal.Network.Socket
350 , Streamly.Internal.Network.Socket
355 , Streamly.Internal.Network.Inet.TCP
351 , Streamly.Internal.Network.Inet.TCP
359− Streamly.Internal.Benchmark.FileIO.Array
360− , Streamly.Internal.Benchmark.FileIO.Stream
361− , Streamly.Internal.Benchmark.Prelude
363 build-depends: base >= 4.8 && < 5
353 build-depends: base >= 4.8 && < 5
364 , ghc-prim >= 0.2 && < 0.6
354 , ghc-prim >= 0.2 && < 0.6
365 , deepseq >= 1.4.1 && < 1.5
355 , deepseq >= 1.4.1 && < 1.5
@@ -379,10 +369,6 @@ library
379 , transformers >= 0.4 && < 0.6
369 , transformers >= 0.4 && < 0.6
380 , transformers-base >= 0.4 && < 0.5
370 , transformers-base >= 0.4 && < 0.5
383− build-depends: template-haskell >= 2.14 && < 2.16
384− , inspection-testing >= 0.4 && < 0.5
386 if !impl(ghcjs)
372 if !impl(ghcjs)
387 build-depends:
373 build-depends:
388 network >= 2.6 && < 4
374 network >= 2.6 && < 4
@@ -571,61 +557,64 @@ test-suite parallel-loops
572benchmark linear
558benchmark linear
573 import: bench-options
559 import: bench-options
560+ other-modules: Streamly.Benchmark.Prelude
574 type: exitcode-stdio-1.0
561 type: exitcode-stdio-1.0
575 hs-source-dirs: benchmark
562 hs-source-dirs: benchmark
576 main-is: Linear.hs
563 main-is: Linear.hs
577− if flag(benchmark)
564+ buildable: True
578− buildable: True
565+ build-depends:
567+ , base >= 4.8 && < 5
568+ , deepseq >= 1.4.1 && < 1.5
569+ , random >= 1.0 && < 2.0
570+ , gauge >= 0.2.4 && < 0.3
579 build-depends:
572 build-depends:
580− streamly
573+ transformers >= 0.4 && < 0.6
581− , base >= 4.8 && < 5
574+ if flag(inspection)
582− , deepseq >= 1.4.1 && < 1.5
583− , random >= 1.0 && < 2.0
584− , gauge >= 0.2.4 && < 0.3
586− build-depends:
575+ build-depends: template-haskell >= 2.14 && < 2.16
587− transformers >= 0.4 && < 0.6
576+ , inspection-testing >= 0.4 && < 0.5
591benchmark linear-async
578benchmark linear-async
592 import: bench-options
579 import: bench-options
580+ other-modules: Streamly.Benchmark.Prelude
593 cpp-options: -DLINEAR_ASYNC
581 cpp-options: -DLINEAR_ASYNC
594 type: exitcode-stdio-1.0
582 type: exitcode-stdio-1.0
595 hs-source-dirs: benchmark
583 hs-source-dirs: benchmark
596 main-is: LinearAsync.hs
584 main-is: LinearAsync.hs
597− if flag(benchmark)
585+ buildable: True
598− buildable: True
586+ build-depends:
588+ , base >= 4.8 && < 5
589+ , deepseq >= 1.4.1 && < 1.5
590+ , random >= 1.0 && < 2.0
591+ , gauge >= 0.2.4 && < 0.3
599 build-depends:
593 build-depends:
600− streamly
594+ transformers >= 0.4 && < 0.6
601− , base >= 4.8 && < 5
595+ if flag(inspection)
602− , deepseq >= 1.4.1 && < 1.5
603− , random >= 1.0 && < 2.0
604− , gauge >= 0.2.4 && < 0.3
606− build-depends:
596+ build-depends: template-haskell >= 2.14 && < 2.16
607− transformers >= 0.4 && < 0.6
597+ , inspection-testing >= 0.4 && < 0.5
611benchmark linear-rate
599benchmark linear-rate
612 import: bench-options
600 import: bench-options
601+ other-modules: Streamly.Benchmark.Prelude
613 type: exitcode-stdio-1.0
602 type: exitcode-stdio-1.0
614 hs-source-dirs: benchmark
603 hs-source-dirs: benchmark
615 main-is: LinearRate.hs
604 main-is: LinearRate.hs
616− if flag(benchmark)
605+ buildable: True
617− buildable: True
606+ build-depends:
608+ , base >= 4.8 && < 5
609+ , deepseq >= 1.4.1 && < 1.5
610+ , random >= 1.0 && < 2.0
611+ , gauge >= 0.2.4 && < 0.3
618 build-depends:
613 build-depends:
619− streamly
614+ transformers >= 0.4 && < 0.6
620− , base >= 4.8 && < 5
615+ if flag(inspection)
621− , deepseq >= 1.4.1 && < 1.5
622− , random >= 1.0 && < 2.0
623− , gauge >= 0.2.4 && < 0.3
625− build-depends:
616+ build-depends: template-haskell >= 2.14 && < 2.16
626− transformers >= 0.4 && < 0.6
617+ , inspection-testing >= 0.4 && < 0.5
630benchmark nested
619benchmark nested
631 import: bench-options
620 import: bench-options
@@ -709,22 +698,24 @@ benchmark array
710benchmark fileio
699benchmark fileio
711 import: bench-options
700 import: bench-options
701+ other-modules: Streamly.Benchmark.FileIO.Array
702+ , Streamly.Benchmark.FileIO.Stream
712 type: exitcode-stdio-1.0
703 type: exitcode-stdio-1.0
713 -- A value of 400 works better for some benchmarks, however, it takes
704 -- A value of 400 works better for some benchmarks, however, it takes
714 -- extraordinary amount of time to compile with that.
705 -- extraordinary amount of time to compile with that.
715 -- ghc-options: -funfolding-use-threshold=150
706 -- ghc-options: -funfolding-use-threshold=150
716 hs-source-dirs: benchmark
707 hs-source-dirs: benchmark
717 main-is: FileIO.hs
708 main-is: FileIO.hs
719− buildable: True
709+ buildable: True
720− build-depends:
710+ build-depends:
721− streamly
711+ streamly
722− , base >= 4.8 && < 5
712+ , base >= 4.8 && < 5
723− , gauge >= 0.2.4 && < 0.3
713+ , gauge >= 0.2.4 && < 0.3
724− , typed-process >= 0.2.3 && < 0.3
714+ , typed-process >= 0.2.3 && < 0.3
725− , deepseq >= 1.4.1 && < 1.5
715+ , deepseq >= 1.4.1 && < 1.5
726− else
716+ if flag(inspection)
727− buildable: False
717+ build-depends: template-haskell >= 2.14 && < 2.16
718+ , inspection-testing >= 0.4 && < 0.5
729benchmark concurrent
720benchmark concurrent
730 import: bench-options
721 import: bench-options
@@ -750,7 +741,8 @@ benchmark concurrent
750benchmark base
741benchmark base
751 import: bench-options
742 import: bench-options
752 type: exitcode-stdio-1.0
743 type: exitcode-stdio-1.0
753− include-dirs: src/Streamly/Internal/Data/Time
744+ include-dirs: src/Streamly/Internal/Data/Time
754 if os(windows)
746 if os(windows)
755 c-sources: src/Streamly/Internal/Data/Time/Windows.c
747 c-sources: src/Streamly/Internal/Data/Time/Windows.c
756 if os(darwin)
748 if os(darwin)
@@ -805,7 +797,8 @@ benchmark base
805executable nano-bench
797executable nano-bench
806 import: bench-options
798 import: bench-options
807 hs-source-dirs: benchmark, src
799 hs-source-dirs: benchmark, src
808− include-dirs: src/Streamly/Internal/Data/Time
800+ include-dirs: src/Streamly/Internal/Data/Time
809 if os(windows)
802 if os(windows)
810 c-sources: src/Streamly/Internal/Data/Time/Windows.c
803 c-sources: src/Streamly/Internal/Data/Time/Windows.c
811 if os(darwin)
804 if os(darwin)