Open Quuxplusone opened 8 years ago
Attached x86-intrinsics.csv
(121737 bytes, application/vnd.ms-excel): ```
List of C intrinsics that are lowered to llvm.x86.* LLVM IR intrinsics
Nice! I think it'd be useful to split the 'Can lower to IR' into several
subtypes:
1 - replace with generic IR in headers
2 - replace with generic IR in clang frontend
3 - replace with generic llvm intrinsic
4 - available as x86 ISD opcode
It should be noted that there are ops that need extra handling:
e.g NAN handling for maxps is different from llvm.maxnum
e.g out of range shift values for PSRA/PSRL/PSLL etc.
This is great. To paraphrase a blurb from https://reviews.llvm.org/D24815 about
the general steps for converting these:
1. Prepare the backend (DAG) to handle the expected new IR patterns and add
tests for those.
2. Auto-upgrade the IR, remove deprecated handling of the old IR intrinsics,
and change/remove existing tests.
3. Update clang to not produce the deprecated intrinsics.
If someone is actively working on these, it would be great to have an annotated
list that shows what is underway at any given time so we don't have any
duplicated effort. Or just open a specific bug report for an intrinsic, assign
it to an engineer, and link that report to this master list?
x86-intrinsics.csv
(121737 bytes, application/vnd.ms-excel)