This is an archive of the discontinued LLVM Phabricator instance.

Revert "[CodeGen] Mark fma as const for Android"
ClosedPublic

Authored by alxu on Jan 6 2022, 9:14 AM.

Details

Summary

This code is intended to give a special exception for platforms which set errno in some math functions but not fma. This does not apply to Android, which does not set errno in any math functions (https://cs.android.com/android/platform/superproject/+/master:bionic/libc/include/math.h;drc=master;l=59). The correct implementation for Android is to set -fno-math-errno by default, which was done in https://reviews.llvm.org/D51068. Therefore, this special exception is no longer needed for Android. Deleting it slightly reduces code complexity, clang executable size, compile time, and test time.

This reverts fbfba29d74748b8fffd2f7cc654fb4c3659c8f67.

Diff Detail

Event Timeline

alxu created this revision.Jan 6 2022, 9:14 AM
alxu requested review of this revision.Jan 6 2022, 9:14 AM
pirama accepted this revision.Jan 6 2022, 10:03 AM
pirama added a subscriber: srhines.

Thanks for the cleanup here.

This revision is now accepted and ready to land.Jan 6 2022, 10:03 AM
alxu added a comment.Jan 7 2022, 7:03 AM

I don't have commit access; can someone commit this for me? Please use author "Alex Xu (Hello71) <alex_y_xu@yahoo.ca>". Thanks!

This revision was automatically updated to reflect the committed changes.