More flattening IRState.
Small test suite fixes.
Bug 61 - LTO: internal compiler error: in build_dtype