Usage of vector pgmath symbols in Flang

Hi,

Are vector pgmath symbols called directly in Flang? Are they directly used in the Flang libraries?

As far as I understand it is scalar pgmath symbols that are always generated by Flang and these are then converted to vector symbols by veclib in LLVM.

Thanks,
Kiran

IMPORTANT NOTICE: The contents of this email and any attachments are confidential and may also be privileged. If you are not the intended recipient, please notify the sender immediately and do not disclose the contents to any other person, use it for any purpose, or store or copy the information in any medium. Thank you.

Hi Kiran,

Vector pgmath routines are present in the Flang libraries, however the Flang front end only generates scalar pgmath calls.

The LLVM vectorizer has been modified to recognize scalar pgmath calls and generate appropriate vector calls. Here’s the PR that introduced this change if you’re interested:
https://github.com/flang-compiler/llvm/pull/43/files

Regards,
Varun Jayathirtha

Hello Varun,

Thanks for confirming that flang generates only calls to scalar routines and these are later converted to vector calls by changes in LLVM.

When you say vector routines are present in the Flang libraries, I am assuming that you meant to say the vector routines are present in the libpgmath library. My other question was whether there are calls to vector pgmath routines in libflang/libflangrti.

–Kiran

IMPORTANT NOTICE: The contents of this email and any attachments are confidential and may also be privileged. If you are not the intended recipient, please notify the sender immediately and do not disclose the contents to any other person, use it for any purpose, or store or copy the information in any medium. Thank you.

Hello Kiran,

I misunderstood your second question. Yes I meant to say vector routines are present in the libpgmath library.

There are no vector pgmath routine calls in libflang/libflangrti.

Regards,
Varun Jayathirtha