Overloading intrinsic with pointer to pointer

Hi,

I've noticed that if I try to overload an intrinsic with a pointer to
pointer my call to Intrinsic::getDeclaration, for example with an i8**
type. Ultimately, this is because Intrinsic::getName
(lib/VMCore/Function.cpp#338) only removes one level of indirection
from the passed pointer type, so calls getEVTString on a pointer type
resulting an in Invalid EVT assertion (lib/VMCore/ValueTypes.cpp#97).

Is there a problem with what I'm trying to do which isn't immediately
obvious to me, or is this an LLVM bug/deficiency?

Thank you,

Alex

This should say "my call to Intrinsic::getDeclaration results in an
assertion error".

Apologies, I have a bad habit of rewording posts just before sending
and breaking them...