blob: 74666c1ee63f8ff8f1841d8130161a8bcc569f5d (
plain)
1
2
3
4
5
6
7
8
9
10
11
|
-- This test-case tickled a bug where an optimization pass incorrectly
-- reloaded a stack slot before the slot was initialized. It was a bit
-- tricky to reproduce, and I don't really know why this particular
-- harness was necessary.
-- Miscompiled code must be in another module, otherwise problem doesn't
-- show up.
import Cgrun067A (miscompiledFn)
import Foreign.C.String
main = withCString "foobar" $ \p -> print =<< miscompiledFn p
|