Skip to content

Conversation

@rnjtranjan
Copy link
Collaborator

No description provided.

@rnjtranjan rnjtranjan force-pushed the issue_1031_intersectBySorted branch from 4c27243 to 1e31162 Compare January 19, 2022 15:31
@harendra-kumar harendra-kumar force-pushed the issue_1031_intersectBySorted branch from 1e31162 to a5b9133 Compare February 10, 2022 08:49
@rnjtranjan rnjtranjan force-pushed the issue_1031_intersectBySorted branch from a5b9133 to 5998634 Compare February 10, 2022 09:54
@harendra-kumar
Copy link
Member

Please rebase on master and add a benchmark.

@harendra-kumar harendra-kumar force-pushed the issue_1031_intersectBySorted branch from 050bcbb to ec20f5f Compare February 10, 2022 11:56
@rnjtranjan rnjtranjan force-pushed the issue_1031_unionBySorted branch from 3b29249 to ccf34a2 Compare February 10, 2022 12:24
@rnjtranjan rnjtranjan changed the base branch from issue_1031_intersectBySorted to master February 10, 2022 12:25
@harendra-kumar
Copy link
Member

Can you rebase it against master, there are two things to do in this PR currently:

  1. It includes the intersectBySorted change, this change has been included in master, it has to be dropped while rebasing
  2. A benchmark should be added, so that we can check the performance and fix

@rnjtranjan rnjtranjan force-pushed the issue_1031_unionBySorted branch from ccf34a2 to 7162f6a Compare March 6, 2022 09:54
@harendra-kumar
Copy link
Member

Benchmarks are failing with:

All.Unicode.Stream/o-1-space.decode-encode.encodeUtf8 . parseMany parseCharUtf8 (1/10):   +RTS -T -K36K -M16M    -RTS      
Using small input file: benchmark-tmp/in-10MB.txt
Using big input file: benchmark-tmp/in-100MB.txt
Using output file: benchmark-tmp/out.txt
All
  Unicode.Stream/o-1-space
    decode-encode
      encodeUtf8 . parseMany parseCharUtf8 (1/10): FAIL
        Exception: Streamly.Internal.Data.Stream.parseCharUtf8WithD:Not enough input
        CallStack (from HasCallStack):
          error, called at src/Streamly/Internal/Unicode/Stream.hs:498:17 in streamly-0.8.2-inplace:Streamly.Internal.Unicode.Stream

1 out of 1 tests failed (0.20s)
Error: Benchmark execution failed.
Error: Benchmark execution failed.
Error: Process completed with exit code 1.

@rnjtranjan
Copy link
Collaborator Author

Not sure why the benchmark is failing, in my local env I re-ran without any issue:
kaveri:~/composewell/issue_1031_Jan0522/streamly  (issue_1031_unionBySorted)$ (nix:streamly) cabal run bench:Unicode.Stream
Up to date
Using small input file: benchmark-tmp/in-10MB.txt
Using big input file: benchmark-tmp/in-100MB.txt
Using output file: benchmark-tmp/out.txt
All
Unicode.Stream/o-1-space
ungroup-group
unlines . splitOnSuffix ([Word8]) (1/10): OK (1.74s)
560 ms ± 11 ms
interposeSuffix . splitOnSuffix (Array Word8) (1/10): OK (1.95s)
628 ms ± 3.2 ms
UnicodeArr.unlines . UnicodeArr.lines (Array Char) (1/10): OK (2.07s)
666 ms ± 4.5 ms
interposeSuffix . wordsBy ([Word8]) (1/10): OK (1.25s)
393 ms ± 2.8 ms
unwords . wordsBy ([Char]) (1/10): OK (1.64s)
525 ms ± 4.2 ms
UnicodeArr.unwords . UnicodeArr.words (Array Char) (1/10): OK (1.63s)
530 ms ± 7.0 ms
decode-encode/toChunks
encodeUtf8' . decodeUtf8Arrays (1/10): OK (2.48s)
786 ms ± 3.4 ms
decode-encode
encodeLatin1' . decodeLatin1: OK (9.84s)
3.073 s ± 9.2 ms
encodeLatin1 . decodeLatin1: OK (10.01s)
3.082 s ± 15 ms
encodeUtf8 . parseMany parseCharUtf8 (1/10): OK (3.78s)
1.228 s ± 13 ms
encodeUtf8 . decodeUtf8 (1/10): OK (3.37s)
1.060 s ± 4.3 ms

All 11 tests passed (39.90s)

@harendra-kumar harendra-kumar marked this pull request as draft July 5, 2023 17:28
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants