Hoogle Search

Within LTS Haskell 22.23 (ghc-9.6.5)

Note that Stackage only displays results for the latest LTS and Nightly snapshot. Learn more.

  1. lazyByteStringHex :: ByteString -> Builder

    bytestring Data.ByteString.Builder

    Encode each byte of a lazy ByteString using its fixed-width hex encoding.

  2. lazyByteStringCopy :: ByteString -> Builder

    bytestring Data.ByteString.Builder.Extra

    Construct a Builder that copies the lazy ByteString.

  3. lazyByteStringInsert :: ByteString -> Builder

    bytestring Data.ByteString.Builder.Extra

    Construct a Builder that inserts all chunks of the lazy ByteString directly.

  4. lazyByteStringThreshold :: Int -> ByteString -> Builder

    bytestring Data.ByteString.Builder.Extra

    Construct a Builder that uses the thresholding strategy of byteStringThreshold for each chunk of the lazy ByteString.

  5. lazyByteString :: ByteString -> Builder

    bytestring Data.ByteString.Builder.Internal

    Create a Builder denoting the same sequence of bytes as a lazy ByteString. The Builder inserts large chunks of the lazy ByteString directly, but copies small ones to ensure that the generated chunks are large on average.

  6. lazyByteStringCopy :: ByteString -> Builder

    bytestring Data.ByteString.Builder.Internal

    Construct a Builder that copies the lazy ByteString.

  7. lazyByteStringInsert :: ByteString -> Builder

    bytestring Data.ByteString.Builder.Internal

    Construct a Builder that inserts all chunks of the lazy ByteString directly.

  8. lazyByteStringThreshold :: Int -> ByteString -> Builder

    bytestring Data.ByteString.Builder.Internal

    Construct a Builder that uses the thresholding strategy of byteStringThreshold for each chunk of the lazy ByteString.

  9. toLazyByteString :: Builder -> ByteString

    bytestring Data.ByteString.Builder

    Execute a Builder and return the generated chunks as a lazy ByteString. The work is performed lazy, i.e., only when a chunk of the lazy ByteString is forced.

  10. toLazyByteStringWith :: AllocationStrategy -> ByteString -> Builder -> ByteString

    bytestring Data.ByteString.Builder.Extra

    Heavy inlining. Execute a Builder with custom execution parameters. This function is inlined despite its heavy code-size to allow fusing with the allocation strategy. For example, the default Builder execution function toLazyByteString is defined as follows.

    {-# NOINLINE toLazyByteString #-}
    toLazyByteString =
    toLazyByteStringWith (safeStrategy smallChunkSize defaultChunkSize) L.empty
    
    where L.empty is the zero-length lazy ByteString. In most cases, the parameters used by toLazyByteString give good performance. A sub-performing case of toLazyByteString is executing short (<128 bytes) Builders. In this case, the allocation overhead for the first 4kb buffer and the trimming cost dominate the cost of executing the Builder. You can avoid this problem using
    toLazyByteStringWith (safeStrategy 128 smallChunkSize) L.empty
    
    This reduces the allocation and trimming overhead, as all generated ByteStrings fit into the first buffer and there is no trimming required, if more than 64 bytes and less than 128 bytes are written.

Page 2 of many | Previous | Next