Skip to content

[Downstream change][TargetParser] Parse Amazon Linux triple and handle RuntimeLibcalls #286

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 1 commit into
base: release/arm-software/20.x
Choose a base branch
from

Conversation

MacDue
Copy link
Contributor

@MacDue MacDue commented Apr 16, 2025

This parses the "aarch64-amazon-linux" triple and updates RuntimeLibcalls to mark the sincos* functions as available on Amazon Linux. This allows these functions to be vectorized on Amazon Linux.

Downstream change: #87

@MacDue
Copy link
Contributor Author

MacDue commented Apr 16, 2025

I believe this patch may be the correct fix for upstream too (but I've not made a PR there yet as this fix won't be backported to the LLVM 20 release upstream, so is less time sensitive there).

@kiranchandramohan
Copy link
Contributor

Is this different in spirit from llvm/llvm-project#109263 ? Is it only in the driver that new triples are not allowed? Is it safe to add in llvm.

Will be good to have this reviewed upstream also.

@MacDue
Copy link
Contributor Author

MacDue commented Apr 16, 2025

Is this different in spirit from llvm/llvm-project#109263 ? Is it only in the driver that new triples are not allowed? Is it safe to add in llvm.

Will be good to have this reviewed upstream also.

AFAIK this is not the same as llvm/llvm-project#109263, which IIUC is modifying the clang driver to find a GNU install located at a path which contains a aarch64-amazon-linux triple automatically. This patch just parses the triple and updates the RuntimeLibcalls to acknowledge that Amazon Linux has an implementation of sincos.

pawosm-arm
pawosm-arm previously approved these changes Apr 17, 2025
@MacDue
Copy link
Contributor Author

MacDue commented Apr 17, 2025

Will be good to have this reviewed upstream also.

Created an upstream version of this PR: llvm/llvm-project#136114

This parses the "aarch64-amazon-linux" triple and updates
RuntimeLibcalls to mark the sincos* functions as available on Amazon
Linux. This allows these functions to be vectorized on Amazon Linux.
@kiranchandramohan
Copy link
Contributor

Thanks @MacDue for this work. We are going for the ATfL 20 release without this fix. For ATfL and LLVM 21 we will decide on an appropriate fix after discussing with AWS.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants