llc: assertion fails in bitreader.cpp

Hi all,

I've used the llvmgcc to compile a quite simple bit of c-code:

short addtest(short a, short b)
{
return a+b;
}

When I'm feeding llc (llvm-2.1-version) with the resulting bytecode, it fails with this error:

llc: BitcodeReader.cpp:1040: bool llvm::BitcodeReader::ParseModule(const std::string&): Assertion `Func->getFunctionType()->getParamAttrs() == getParamAttrs(Record[4])' failed.

Has anyone ever experienced something similar?

Thanks in advance!

Matthias

When I'm feeding llc (llvm-2.1-version) with the resulting bytecode, it fails with this error:

It sounds like the version of llvm-gcc doesn't match the version of llc.
What does the llvm assembler look like (i.e. what llvm-dis gives for the
bitcode)?

D.