Support abs as a primitive operation on floating point numbers.

Authored by idontgetoutmuch on Feb 2 2017, 10:28 AM.


Test Plan

See testsuite/tests/numeric/should_run/T13212.hs

idontgetoutmuch retitled this revision from to compiler: fix trac issue #13212.
idontgetoutmuch updated this object.
idontgetoutmuch edited the test plan for this revision. (Show Details)
idontgetoutmuch added reviewers: rwbarton, carter.
idontgetoutmuch updated the Trac tickets for this revision.
mpickering requested changes to this revision.Feb 2 2017, 10:43 AM
mpickering added a reviewer: mpickering.
mpickering added a subscriber: mpickering.
mpickering added inline comments.

You need to modify the all.T file in this directory to get the test to actually run.

This revision now requires changes to proceed.Feb 2 2017, 10:43 AM
mpickering retitled this revision from compiler: fix trac issue #13212 to Support abs as a primitive operation on floating point numbers..Feb 2 2017, 10:44 AM
mpickering updated this object.
mpickering edited edge metadata.
carter edited edge metadata.Feb 2 2017, 11:21 AM

looks like in some cases this change *could* be a regression, or at least its not clear that its a win to make it a foreign call vs doing the suitable bitwise and masking as Reid and I have discussed


this should be fabsf if we're actually just calling the C code ...

But... as Reid and I have discussed... theres better straight up bit fiddling code in many cases


for sparc are we just calling c codes? (as with ppc?)


as reid and I discussed, you probably dont want to change it to be using the c calls at this point... we actually want the bit wise and masking appraoch


same here ... should be the bitwise and mask


i dont think we want it to be a foreign call ... at least on most tier 1 architectures...


foreign call again ..

carter requested changes to this revision.Feb 2 2017, 11:21 AM
carter edited edge metadata.
idontgetoutmuch abandoned this revision.Mar 3 2017, 1:34 AM
idontgetoutmuch marked 2 inline comments as done.