This is an archive of the discontinued LLVM Phabricator instance.

[X86][FPEnv] Lowering of {get,set,reset}_fpenv
ClosedPublic

Authored by sepavloff on Jun 15 2020, 3:13 AM.

Details

Summary

The change implements lowering of get_fpenv, set_fpenv and
reset_fpenv.

Diff Detail

Event Timeline

sepavloff created this revision.Jun 15 2020, 3:13 AM
Herald added a project: Restricted Project. · View Herald Transcript
sepavloff updated this revision to Diff 270701.Jun 15 2020, 3:20 AM

Fixed formatting issues

craig.topper added inline comments.Jun 15 2020, 12:21 PM
llvm/lib/Target/X86/X86SelectionDAGInfo.cpp
390 ↗(On Diff #270701)

Windows defaults to 53 bit precision.

sepavloff updated this revision to Diff 272365.Jun 22 2020, 2:59 AM

Updated patch after update of dependency

sepavloff marked 2 inline comments as done.Jun 22 2020, 3:02 AM
sepavloff added inline comments.
llvm/lib/Target/X86/X86SelectionDAGInfo.cpp
390 ↗(On Diff #270701)

Fixed.

kpn added a subscriber: kpn.Jun 23 2020, 12:34 PM
sepavloff marked an inline comment as done.

Updated patch

  • Remove changes related to fix for mayLoad/mayStore properties, the relevant changes are already in master,
  • Removed lowering of ISD::GET_FPENV and friends. This operation is useless as lowering of FPEnv intrinsics is made when constructing DAG.
lebedev.ri resigned from this revision.Aug 12 2020, 2:36 PM

Intrinsics now do not use pointers

sepavloff updated this revision to Diff 523062.May 17 2023, 8:35 AM

Update after update of dependency

Herald added a project: Restricted Project. · View Herald TranscriptMay 17 2023, 8:35 AM
Herald added a subscriber: StephenFan. · View Herald Transcript
sepavloff updated this revision to Diff 537457.Jul 5 2023, 12:05 PM

Rebase and ping

pengfei added inline comments.Jul 10 2023, 10:51 PM
llvm/lib/Target/X86/X86ISelLowering.cpp
30120

Maybe check for hasX87 too?

30124

hasSSE1?

30156

Maybe pass Subtarget from caller instead?

llvm/lib/Target/X86/X86ISelLowering.h
837

Add a suffix m

840

ditto.

llvm/lib/Target/X86/X86InstrFPStack.td
427–428

Need to add Predicates = [HasX87] if change to I.

434–435

ditto.

Fix the patch according to reviewer's comments

pengfei accepted this revision.Jul 13 2023, 11:48 PM

LGTM.

llvm/lib/Target/X86/X86ISelLowering.cpp
34442–34444

Maybe use upper L to match with other functions here.

This revision is now accepted and ready to land.Jul 13 2023, 11:48 PM

Thanks!

llvm/lib/Target/X86/X86ISelLowering.cpp
34442–34444

No problem.

This revision was landed with ongoing or failed builds.Jul 14 2023, 8:12 AM
This revision was automatically updated to reflect the committed changes.