Commit Graph

2103 Commits

Author SHA1 Message Date
pranaysashank
d8a2bba2e6 Add construction tests.
- Add constructWithYield, yieldM, repeat, repeatM, enumerate,
enumerateTo, fromList, fromListM, zipAsyncApplicative.
2020-12-06 13:57:20 +00:00
pranaysashank
57f43838a5 Add tests for cons, consM, .:, |:. 2020-12-06 13:57:20 +00:00
Anurag Hooda
287e9edbf8 Add cabal.project file 2020-12-06 12:46:52 +05:30
Harendra Kumar
a187768fac
Merge pull request #795 from composewell/terminatin-folds-2
Enhance the fold type to capture terminating folds
2020-12-06 10:52:15 +05:30
Harendra Kumar
e36bfcfff7 Move/reorg some code, use base ver instead of GHC 2020-12-02 10:01:31 +00:00
Harendra Kumar
9ed417b65c Add FileSystem.Event testsuite to hie cradle 2020-12-02 07:39:05 +00:00
Ranjeet Ranjan
4823ea8ed9 Fix 8.02 build issue 2020-12-02 07:39:05 +00:00
Ranjeet Ranjan
fe33167ea6 Fix Windows build issues 2020-12-02 07:39:05 +00:00
Harendra Kumar
48e9b1ad89 Refactor test driver 2020-12-02 07:39:05 +00:00
Harendra Kumar
583149c1ed Refactor to move events along with the test
That way its easier to understand what the test is doing, at one place.
2020-12-02 07:39:05 +00:00
Harendra Kumar
e085852068 Move fs ops to test description table
* factor out the common "dispatch" part.
2020-12-02 07:39:05 +00:00
Harendra Kumar
bb4b378bab Factor out common code from event handlers 2020-12-02 07:39:05 +00:00
Ranjeet Ranjan
5ead27a1c4 Refactor to common dispatch function for FSops 2020-12-02 07:39:05 +00:00
Ranjeet Ranjan
d21c0b7f22 Factor out duplicate code to common function 2020-12-02 07:39:05 +00:00
Ranjeet Ranjan
ce2426d175 Fix CI build issues
Fix Semigroup import for GHC 8.2.2 and Windows build issues.
2020-12-02 07:39:05 +00:00
Harendra Kumar
b85002bddb Simplify the implementation
* Do not use a seperate traversal of dirs, instead just call addToWatch
  recursively.
* Keep rel path of subdir in the map instead of keeping absolute path
* Keep the same default for recursive watch on Windows/Linux
* Use watchTreesWith to implement watchPathsWith using recursive flag

Refactor, add some todos for test code
2020-12-02 07:39:05 +00:00
Ranjeet Ranjan
f00008b321 Add recursive directory tree events in Linux 2020-12-02 07:39:05 +00:00
Harendra Kumar
8625ea5c3c Enable inspection tests for interposeSuffix bench 2020-12-02 11:53:04 +05:30
adithyaov
94c2c6a340 Add fusion-plugin to streamly-benchmarks in cabal.project.ci
This affects the inspection testing CI
2020-12-02 04:03:39 +05:30
Harendra Kumar
bf152c89bc Use explicit state types instead of Maybe
So that we can easily identify the constructors in the core.
2020-12-02 02:21:29 +05:30
Harendra Kumar
6d16a0cdc8 Add Fuse annotations to improve benchmarks
Improves the following benchmarks:

FileSystem.Handle/o-1-space/copy/toChunks/group-ungroup/AS.interposeSuffix . AS.splitOnSuffix
FileSystem.Handle/o-1-space/copy/toChunks/decodeEncodeUtf8Lenient (1/10)
FileSystem.Handle/o-1-space/copy/read/SS.encodeUtf8 . SS.decodeUtf8Lax (1/10)
2020-12-02 02:21:29 +05:30
Harendra Kumar
8358095df1 Use NOINLINE on some benchmarks
These benchmarks degraded because of the terminating folds change
because INLINing was causing loop fusion to break.
2020-12-02 02:21:29 +05:30
adithyaov
0bf8b542ac Add multiple benchmarks to Fold 2020-12-02 02:21:29 +05:30
Harendra Kumar
170cc10baf Modify the memory RTS options for Prelude.Parallel 2020-12-02 02:21:29 +05:30
adithyaov
9d62b7bde0 Add a code example to unzipWith & unzipWithM 2020-12-02 02:21:29 +05:30
adithyaov
0032f35e96 Rename: ltakeWhile -> takeSepBy & drainWhile -> drainSepBy 2020-12-02 02:21:29 +05:30
adithyaov
8f7c0ddd1e Modify the current Fold type to handle terminating Folds
This commit also includes:
- Changing all other modules accordingly.
- Adding additional helper functions to make life easy
- Using strict types as fold's intermediate result
- Respecting line length of 80 in most cases
2020-12-02 02:21:29 +05:30
Harendra Kumar
d6e7c28c12 Support branch specific builds using git-cabal 2020-11-30 20:53:25 +05:30
Harendra Kumar
c216af0b09 Break Benchmark.Prelude.Serial into smaller modules
This module took a lot of time and 4GB RAM to compile. Its now broken
into smaller module that can be compiled in less than 512 MB RAM.

The memory limits are set based on a 3-pass fusion-plugin.
2020-11-30 06:51:00 +00:00
adithyaov
cfa7fe08ed Fix and run grouping benchmarks in Prelude.Serial 2020-11-29 09:14:56 +05:30
Harendra Kumar
cd3ce3e503 Fix formatting and docs
* Use let clauses to break bigger expressions
* Use `even` as predicate
2020-11-26 17:11:47 +05:30
Ranjeet Ranjan
60d13da0d6 add mapMaybe combinator in Fold
Add benchmarking and test case for mapMaybe combinator of Data.Fold

Fix review comments
2020-11-26 17:11:47 +05:30
Harendra Kumar
9444e3e0b9 Use watchTreesWith to implement watchPathsWith 2020-11-26 09:29:50 +05:30
Harendra Kumar
585b825d78 Remove references to path encoding
There is no specific encoding of path required, it is a contract between
the user and the file system, we are just a broker in the middle.
2020-11-26 09:29:50 +05:30
Harendra Kumar
0bd72c52e3 Update documentation of stripPrefix 2020-11-26 09:29:50 +05:30
Harendra Kumar
0c570febdd Add scripts to generate hscope db and tags 2020-11-26 09:27:44 +05:30
adithyaov
d09f1ad9b9 Add benchmarks for mkAsync 2020-11-25 22:56:47 +05:30
adithyaov
75b4329cfe Add benchmarks for (|&) & (|&.) 2020-11-25 22:56:47 +05:30
adithyaov
7fd5ab1bee Add benchmarks for scan and postscan 2020-11-25 22:56:47 +05:30
adithyaov
3a3f8e7400 Add benchmarks for wAsync and parallel 2020-11-25 22:56:47 +05:30
adithyaov
06b230f27a Add benchmarks for S.concatFoldableWith and S.concatForFoldableWith 2020-11-25 22:56:47 +05:30
adithyaov
c7b7c2a423 Add benchmarks for a few functions in FileSystem.Handle
Benchmarks added:
- write . read
  - write
  - read
- writeWithBufferOf . readWithBufferOf
  - readWithBufferOf
  - writeWithBufferOf
- fromBytes . readWithBufferOf
  - readWithBufferOf
- write . readChunks (Commented)
  - readChunks
- write . writeChunks (Commented)
  - writeChunks
2020-11-25 22:56:47 +05:30
adithyaov
7bb8512da5 Add benchmarks for FH.encodeLatin1
Rename copyStreamLatin1 to copyStreamLatin1'

copyStreamLatin1' benchmarks FH.encodeLatin1'
copyStreamLatin1 benchmarks FH.encodeLatin1
2020-11-25 22:56:47 +05:30
adithyaov
c5b4838d10 Add benchmarks for minRate, maxRate & constRate (bench:Prelude.Rate) 2020-11-25 22:56:47 +05:30
adithyaov
af872ae7ad Make structural changes to bench:Prelude.Rate 2020-11-25 22:56:47 +05:30
adithyaov
1a728e2d16 Clean bench:Prelude.Rate
Abstract over avgRate and change label values in bench groups
2020-11-25 22:56:47 +05:30
adithyaov
8477487b33 Add multiple micro-benchmarks
* bench:FileSystem.Handle
- splitWithSuffix

* bench:Prelude.Serial
- findM
- scanl1M'
- concatMapM
2020-11-25 22:56:47 +05:30
adithyaov
053a38c6a1 Fix naming in benchmarks
* bench:Prelude.Serial
- foldrMToStream -> foldrToStream
- scan -> scanl'

* bench:Prelude.ZipSerial
- zip -> zipWith
- zipM -> zipWithM

* bench:Prelude.ZipAsync
- zipAsync -> zipAsyncWith
- zipAsyncM -> zipAsyncWithM
2020-11-25 22:56:47 +05:30
Harendra Kumar
f10c944b55 Use benchmark and fusion-plugin deps by default 2020-11-24 09:51:56 +05:30
pranaysashank
f72dcaf493 Add names to jobs in Circle CI. 2020-11-18 16:34:36 +05:30