[LLVMdev] Other Intrinsics?
sabre at nondot.org
Tue Nov 27 11:31:02 PST 2007
On Tue, 27 Nov 2007, Jon Sargeant wrote:
> > Intrinsics get added on demand. Generally there has to be a good reason
> > to add them. llvm.sin was implemented (for example) to allow generation
> > of code that uses vector sin operations.
> What is the criteria for adding an intrinsic or a built-in operation?
> For example, could the 'frem' instruction be an intrinsic? Could you
> remove it from LLVM entirely and make it an external function? What
> distinguishes 'frem' from 'sin', 'pow', 'atan2', etc.?
Historically, intrinsics could not be overloaded, but instructions could.
However, intrinsics got more powerful, so this is no longer true. There
is now very little distinction.
More information about the llvm-dev