This is an archive of the discontinued LLVM Phabricator instance.

[AArch64][GlobalISel] Add support for FCONSTANT of FP128 type
ClosedPublic

Authored by Asif on Jan 11 2021, 11:10 AM.

Details

Summary

Add support for G_FCONSTANT of FP128 (Quadruple precision) type.
It replaces the constant by emitting a load with a constant pool entry.

Diff Detail

Event Timeline

Asif created this revision.Jan 11 2021, 11:10 AM
Asif requested review of this revision.Jan 11 2021, 11:10 AM
Herald added a project: Restricted Project. · View Herald TranscriptJan 11 2021, 11:10 AM
Asif added a reviewer: dsanders.
arsenm added inline comments.Jan 11 2021, 11:16 AM
llvm/lib/Target/AArch64/GISel/AArch64InstructionSelector.cpp
2318–2321

Why not just fix this?

2321

You can do isExactlyValue directly on getFPImm

Asif added inline comments.Jan 12 2021, 5:28 AM
llvm/lib/Target/AArch64/GISel/AArch64InstructionSelector.cpp
2318–2321

I haven't worked with the tablegen before. Please point to the source files so I can look into it and fix it.

arsenm added inline comments.Jan 12 2021, 11:10 AM
llvm/lib/Target/AArch64/GISel/AArch64InstructionSelector.cpp
2318–2321

I think the way this is working differs from the DAG entirely. I think the DAG is emitting constant pool loads earlier and not directly selecting them

aemerson accepted this revision.Jan 12 2021, 12:13 PM

LGTM with the getFPImm nit fixed.

This revision is now accepted and ready to land.Jan 12 2021, 12:13 PM
Asif updated this revision to Diff 316392.Jan 13 2021, 7:27 AM