Clean up bitcode generation, including 3.4 fixes
Make OSL work with LLVM 3.4