Commit Graph

1842 Commits

Author SHA1 Message Date
Harendra Kumar
c590e9105e Update documentation of sliceSepBy 2020-07-16 23:32:17 +05:30
Harendra Kumar
81339c8f8b Fix comments 2020-07-13 23:58:02 +05:30
pranaysashank
03f05ed340 Fix a bug in ParserK.yield. 2020-07-13 18:05:00 +05:30
Ahmed Zaheer Dadarkar
9d653d06d3 Updated type signature of concatMapWith to remove explicit forall.
- Do the same with `bindWith`, `concatMapBy`, `concatMapIterateWith`,
  `concatMapTreeWith`.
- `concatMapLoopWith`,`concatMapTreeYieldLeavesWith` are not updated
  in the same way as they necessarily need the combining function to be
  polymorphic.
- Update Changelog to reflect this change.
2020-07-13 18:05:00 +05:30
pranaysashank
4933d37ed7 Upgrade packcheck.
- Remove 32 bit builds from the matrix. See #514.
2020-07-13 17:59:44 +05:30
pranaysashank
f38b672e44 Add tests for take, takeEQ, takeGE with n <= 0.
- Delete `lookAheadFail` test because the test doesn't make sense
  i.e. It doesn't have to fail when the stream length exceeds n in `take
  n`.
2020-07-11 18:20:32 +05:30
pranaysashank
30823452a4 Fix take, takeEQ, takeGE, sliceSepByMax.
- `take`, `takeEQ`, `takeGE` now work when the count is <0.
- `sliceSepByMax` behaviour is now more in line with what the
  documentaton says in `Streamly.Internal.Data.Parser`.
2020-07-11 18:20:32 +05:30
Sanchayan Maity
1100c23999 Clean up hlint warnings
Signed-off-by: Sanchayan Maity <maitysanchayan@gmail.com>
2020-07-11 17:53:59 +05:30
pranaysashank
9148fb7308 Add benchmark to list of packages to build in stack.yaml. 2020-07-10 20:45:57 +05:30
pranaysashank
51127df924 Add test for MonadFail instance of Parser. 2020-07-10 19:57:57 +05:30
pranaysashank
e0a95b59ca Add MonadFail instance for Parser. 2020-07-10 19:57:57 +05:30
Harendra Kumar
095513166d Enable TypeFamilies extension with NoMonoLocalBinds
MonoLocalBinds enabled by TypeFamilies causes performance regressions
see #567, however we can enable TypeFamilies without it.
2020-07-09 18:40:34 +05:30
Harendra Kumar
09f2fa7cb4 Add the ability to select fields to report 2020-07-09 17:40:27 +05:30
Harendra Kumar
37bcdcd34d Add FileSystem.Handle benchmark, use --time-limit 0
In the quick mode we anyway use --include-first-iter, we should not be running
many iterations, one iteration is enough, anyway allocations do not change
across iterations. We can use this for super quick comparison of benchmarks.
2020-07-09 17:40:27 +05:30
Harendra Kumar
89b9e233ba Fix inspection tests 2020-07-09 17:40:27 +05:30
Harendra Kumar
bc6b4eed32 Reduce compile time mem util in Handle benchmarks
* Split into two modules
* Remove unnecessary INLINE pragmas
2020-07-09 17:40:27 +05:30
Harendra Kumar
0f38d1da22 Add notes on inlining and INLINE phases 2020-07-09 16:10:24 +05:30
Harendra Kumar
0d586750a7 Add INLINE phase annotations on some functions 2020-07-09 16:10:24 +05:30
Harendra Kumar
53504dba3c Use smaller input files for longer benchmarks 2020-07-09 16:10:01 +05:30
Harendra Kumar
3d033ae915 Reorganize, move the FileIO benchmarks
Now they are in FileSystem.Handle module corresponding to the source module
with the same name. Also, now we have them arranged based on space complexity
so that we can apply RTS memory restrictions when running.

Also, now longer benchmarks use a shorter file.
2020-07-08 03:10:09 +05:30
Harendra Kumar
fa1bce3951 Add guidelines about performance analysis 2020-07-07 17:05:01 +05:30
Harendra Kumar
ea79e0f9b7 Add "allocated" and "bytesCopied" fields
"allocated" is much more stable for regression comparisons as it stays the same
whereas "time" varies based on various factors like cpu frequency, other things
running on the computer, context switches etc.

bytesCopied is a measure of long lived data being retained across GCs, which is
also a good measure of performance.
2020-07-07 16:23:06 +05:30
pranaysashank
745265e0f5 Use default-extensions for tests. 2020-07-07 15:18:21 +05:30
Harendra Kumar
287c3a3dc5 Make minor cosmetic review changes for #571 2020-07-07 14:17:44 +05:30
pranaysashank
202f674462 Change the signature of foldlM' to use a monadic seed.
- Also change usages of foldlM' in tests and benchmarks.
2020-07-07 14:17:44 +05:30
Harendra Kumar
a18f1b57b2 Add more details to the documentation of parallel 2020-07-06 16:47:24 +05:30
Joseph Koshy
fda21a9f7d Rework the installation guide.
- Use an informal register.
- Use the active voice.
- Make the guide accessible to people new to Haskell.
- Add a section suggesting a few next steps.
2020-07-06 10:47:01 +05:30
Harendra Kumar
72b6a6db06 Merge pull request #574 from shlok:seedless-unfold 2020-07-03 16:10:43 +05:30
Shlok Datye
9225c35d6b Add tests for unfold and unfold0 2020-07-03 15:57:33 +05:30
Shlok Datye
6cc0e92d76 Add unfold0 2020-07-03 15:57:33 +05:30
Harendra Kumar
98514244f6 Add guidelines about breaking changes 2020-07-03 00:56:09 +05:30
Harendra Kumar
7229844f32 Increase stack size for transformer benchmarks 2020-07-03 00:24:58 +05:30
Harendra Kumar
3818db8355 Increase stack limit for StreamK/toList benchmark 2020-07-02 18:16:33 +05:30
adithyaov
8178cf650b Minor haddock change to hide internal (XXX) comment 2020-07-02 18:13:11 +05:30
pranaysashank
bb12399558 Remove per file extensions from rest of the library modules. 2020-07-01 17:29:21 +05:30
Harendra Kumar
1367bd647d Disallow some language extensions from default use
* UndecidableInstances -- Don't want to use unless indicated
* TypeFamilies         -- Causes large regressions and improvements
* UnboxedTuples        -- interferes with (#.)
2020-07-01 17:29:21 +05:30
Pranay Sashank
6190f1bd02 Use default-extensions inplace of extensions on each file. 2020-07-01 17:29:16 +05:30
Harendra Kumar
48b2f08067 Add config-clock.h to extra-source-files 2020-06-29 02:09:21 +05:30
Harendra Kumar
68cfc3f9be Reduce usage of -Wno-orphans 2020-06-28 22:55:15 +05:30
adithyaov
70fb992171 Fix primitive version bounds for when primitive is >= 0.7.1
Fix duplicate NFData instance
2020-06-28 01:56:49 +05:30
Harendra Kumar
6bf8b4abd9 Rename the parser Step constructors
Yield => Partial
Skip => Continue
Stop => Done

The new names are hopefully more intuitive. They also decouple the names from
the corresponding stream constructors so that there is no confusion about
mixing the two intuitions.

fixes #559
2020-06-24 21:07:08 +05:30
Harendra Kumar
60d322812b Combine Yield and YieldB constructors
Yield 0: now means a partial result is available
Yield n: means a partial result is available, and we need to backtrack by n
elements.
2020-06-24 21:06:56 +05:30
Harendra Kumar
55d49bd50c Optimize Functor/Applicative/Monad etc for serial
Some of the benchmarks were order of magnitude off due to missing INLINE for
type class operations. Now, all of them are in reasonable limits. Benchmarks
affected for serial streams:

* Functor, Applicative, Monad, transformers

We need to do a similar exercise for other types of streams and for
folds/parsers as well.
2020-06-23 13:41:41 +05:30
Harendra Kumar
b4cef11d19 Add iterative benchmarks for Functor/transformers
* Also factor out the existing iteration utilities and use the same everywhere
2020-06-23 13:01:25 +05:30
Harendra Kumar
1a331cb402 Add more benchmarks for applicative/monad
Separate the applicative and monad benchmark groups
Complete benchmarks for all type class operations
2020-06-21 15:15:55 +05:30
Harendra Kumar
1cccb00101 Use foldrSShared instead of foldrS for Async
Because of not sharing the SVar foldrS performs poorly for Async streams and
has quadratic complexity.
2020-06-21 11:28:59 +05:30
Harendra Kumar
c0bd11de4b Elaborate concatMap, async benchmarks
* Add 3 interesting cases for each concatMap case
* For mapM, map concurrently on a serial stream so that we measure the
  concurrency overhead of mapM only and not both concurrent generation + mapM
* For Async streams add some benchmarks involving the `async` combinator.
* Add a benchmark for `foldrS`
2020-06-21 11:28:59 +05:30
Harendra Kumar
acf31cef50 Import from transformers instead of mtl
Just so that we know where all we are actually using mtl.
2020-06-20 18:56:03 +05:30
Joseph Koshy
f80a75fcc7 Minor: add hyperlinks to a few packages. 2020-06-17 14:21:13 +05:30
Shruti_Umat
7eab2aff7c nested-if indentation fix 2020-06-11 18:21:30 +05:30