streamly icon indicating copy to clipboard operation
streamly copied to clipboard

Benchmarks requiring -fspec-constr-recursive=16

Open harendra-kumar opened this issue 1 month ago • 0 comments

Some folding/grouping benchmarks (consumer loop) benchmarks are significantly improved by using -fspec-constr-recursive=16. Maybe some more intelligent optimizations can be done in general for these cases so that we do avoid bloating code and using too much memory and time during compilation.

Utf8 decoding:

splitOnSeqUtf8 :: String -> Handle -> IO Int
unicode encode/decode, especially decode

Grouping/Parser/fold/split:

    , (SpaceO_1, benchIOSink value "many" many)
    , (SpaceO_1, benchIOSink value "some" some)
    , (HeapO_n, benchIOSink value "takeEQ" $ takeEQ value)
    , (SpaceO_1, benchIOSink value "takeWhileP" $ takeWhileP value)
    , (SpaceO_1, benchIOSink value "wordBy" $ wordBy value)
    , (SpaceO_1, benchIOSink value "groupByRolling" groupByRolling)
    , mkBench "takeEndBySeq KR abcdefghi" env $ \inh _ ->
    , mkBenchSmall "interpose . splitOn" env $ \inh outh ->
     foldMany/groupsOf/ChunksOf

Some of the benchmarks performing an operation multiple times:

         "dropWhile-false" (dropWhileFalse value 4)
        , benchIOSink value "tee" (transformTeeMapM 4)
          benchIOSink value "intersperse" (intersperse value 4)

harendra-kumar avatar Dec 04 '25 13:12 harendra-kumar