Skip to content

Conversation

oscardssmith
Copy link
Member

Testing has revealed that some old windows machines without fma were using broken emulated versions for Float32. This adds a test.

@oscardssmith oscardssmith added bugfix This change fixes an existing bug maths Mathematical functions labels Nov 4, 2021
@oscardssmith
Copy link
Member Author

This is kind of a regression from #42783 but only in the sense that we added a test that correctly found out that old machines were already doing the wrong thing.

@ViralBShah
Copy link
Member

ViralBShah commented Nov 4, 2021

The old machine case we found here was a win64 ivybridge which does not have hardware fma, and the system libm is not quite doing the right thing.

The issue was actually discovered in #42299 (comment)

@ViralBShah ViralBShah added the system:windows Affects only Windows label Nov 4, 2021
@oscardssmith
Copy link
Member Author

@JeffBezanson can we please get fma multiversioning so I don't have to figure out why this doesn't work?

@ViralBShah
Copy link
Member

The CI machines are AMD Epycs. Might that be a different case?

@oscardssmith
Copy link
Member Author

If they are Epyc, than they have FMA which would imply that my emulated version is wrong which doesn't make any sense, because then the failures should happen on other platforms.

@ViralBShah
Copy link
Member

And the tests are passing on epyc with Linux and win32. Is something off with llvm on win64?

@oscardssmith
Copy link
Member Author

It really shouldn't be able to do anything for LLVM to mess up. It should just be using the processor instruction...

@ViralBShah
Copy link
Member

Isn't it possible that if this is running in some kind of a VM, that the VM is not exhibiting a slightly different target processor? I mean we've seen these issues when running in VMs before. Perhaps @staticfloat may know more.

@oscardssmith
Copy link
Member Author

Closing as this test can't do anything until we have fma multiversioning.

@maleadt maleadt mentioned this pull request Nov 15, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bugfix This change fixes an existing bug maths Mathematical functions system:windows Affects only Windows
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants