Fix function attribute LLVM API usage

AFAICT, we don't need the index attributes so just use
Function::addFnAttr() API directly.

Signed-off-by: Pekka Enberg <penberg@iki.fi>