This is an archive of the discontinued LLVM Phabricator instance.

[SystemZ][z/OS] Fix f32 variadic argument assertion
AcceptedPublic

Authored by mubarizafzal on Feb 15 2022, 11:16 AM.

Details

Summary

The tablegen lines that specify the XPLINK64 calling convention for promoting an f32 vararg to an f64 are effectively overwritten by the following tablegen line which bitcast an f64 vararg to an i64 (so that it can be used in the GPRs) . It becomes a bitcast from f32 to i64. Since we don't handle a bitcast for f32s this caused an assertion.

We fix this by simplifying the tablegen lines to explicity show this behaviour, and allow the f32 in the bitcast case by first promoting it to an f64.

Diff Detail

Event Timeline

mubarizafzal created this revision.Feb 15 2022, 11:16 AM
mubarizafzal requested review of this revision.Feb 15 2022, 11:16 AM
Herald added a project: Restricted Project. · View Herald TranscriptFeb 15 2022, 11:16 AM

Allow f32 in bitcast case and add test

uweigand accepted this revision.Feb 15 2022, 12:29 PM

LGTM, thanks!

This revision is now accepted and ready to land.Feb 15 2022, 12:29 PM

clang-format

thakis added a subscriber: thakis.Feb 15 2022, 7:33 PM

Looks like this landed in ea0676f97d734196b15da7553cd407e6a36cef2d

Please include a line like "Differential Revision: D119868" in your commit message, so that it's easy to find the review from the commit.

I wanted to find it to let you know that this seems to break tests, but it looks like you're on top of this already (D119906) :)