I\'ve been making rather poor attempts at the PRIME1 problem on SPOJ. I discovered using that using ByteString really helped performance for reading in the problem text
Note that performance isn't the main difference between ByteString and String. The former is for binary data while the latter is for Unicode text. If you have binary data, use ByteString, if you have Unicode text, use the Text type from the text package.