[LLVMdev] Function Parameter Requirements?

Jon Sargeant delta17 at cox.net
Sun Mar 30 13:53:33 PDT 2008

I'm trying to find the requirements for function parameters in the 
documentation.  The assembler rejects 'i32({i32,i32})' with the error 
'Function arguments must be value types!' so I'm guessing that each 
parameter type must be a first-class type.  The assembler also rejects 
'{i32,i32}(i32)' with the error 'LLVM Functions cannot return 
aggregates'.  This error seems to contradict the documentation which 
states 'The return type of a function type is a scalar type or a void 
type or a struct type'.

Finally, I suggest defining these additional terms in the 
type-classification section:
- value type
- scalar type
- aggregate type

Best Regards,

More information about the llvm-dev mailing list