Skip to content

Bytestring break failing rewrite to breakByte and failing to eliminate boxing/unboxing

Tyson Whitehead gives a detailed description of the problem here.

Key points:

  • Program fails to rewrite ByteString.break (== x) chunk to ByteString.breakByte x chunk
  • Missed unboxing opportunity (which led to 34gb additional allocations, which is why he noticed it)

I can reproduce the problem on OSX and Windows with GHC 7.10.3. Haven't tested Linux.

I repost it here to make sure it doesn't go unnoticed.

Edited by Alex Biehl
To upload designs, you'll need to enable LFS and have an admin enable hashed storage. More information