libmvec in gcc to have vector math in fortran
Szabolcs Nagy
szabolcs.nagy@arm.com
Tue Apr 10 11:35:00 GMT 2018
On 10/04/18 11:14, Janne Blomqvist wrote:
> As I mentioned previously in that thread you linked to, the fortran frontend never generates a direct call to libm sin(), or for that matter
> ZGVbN2v_sin(). Instead it generates a "call" to __builtin_sin(). And similarly for other libm functions that have gcc builtins. The middle-end
> optimizers are then free to do whatever optimizations they like on that __builtin_sin call, such as constant folding, and at least as far as the
> fortran frontend is concerned, vectorizing if -mveclibabi= or such is in effect.
the generated builtin call is not the issue (same happens in c),
the knowledge about libc declarations is.
the middle-end has no idea what functions can be vectorized,
only the libc knows it and declares this in c headers.
this is the problem i'm trying to solve.
More information about the Gcc
mailing list