This is an archive of the discontinued LLVM Phabricator instance.

[Flang] Lower atan, sinh, cosh intrinsics
ClosedPublic

Authored by kiranchandramohan on Mar 22 2022, 3:16 PM.

Details

Summary

The intrinsic computes the tan and hyperbolic sin, cosine values. By
default they are lowered to runtime calls to the math library. Not all
types are supported currently. The generic and llvm lowering does not
lower floating point types with kind greater than 8, the llvm lowering
does not support the complex types.

Note: tanh is not present in fir-dev hence ignoring for now. We can add
support after upstreaming is complete. sin and cos will come in separate
patches since they have llvm intrinsic lowering.

This is part of the upstreaming effort from the fir-dev branch in [1].
[1] https://github.com/flang-compiler/f18-llvm-project

Co-authored-by: Eric Schweitz <eschweitz@nvidia.com>
Co-authored-by: William Moses <gh@wsmoses.com>

Diff Detail

Event Timeline

Herald added projects: Restricted Project, Restricted Project. · View Herald Transcript
Herald added a subscriber: mehdi_amini. · View Herald Transcript
kiranchandramohan requested review of this revision.Mar 22 2022, 3:16 PM
PeteSteinfeld accepted this revision.Mar 22 2022, 6:09 PM

All builds and tests correctly and looks good.

This revision is now accepted and ready to land.Mar 22 2022, 6:09 PM
This revision was automatically updated to reflect the committed changes.