This allows compiling libc++, even when the C library doesn't support floating point math.

# Details

- Reviewers
ldionne - Group Reviewers
Restricted Project - Commits
- rG650da4a690f9: [libc++][math.h] Use builtins for all the functions

# Diff Detail

- Repository
- rG LLVM Github Monorepo

### Event Timeline

Looks good but you're hitting the same problem I did with AIX.

I suspect that __builtin_ldexpl is the one that's causing the trouble but haven't been able to prove it. @xingxue did give me access to an AIX machine but unfortunately it's under such heavy load already that it's not really usable. The path I took was to not use long double builtins on AIX ¯\_(ツ)_/¯

LGTM but please ping me if you need major changes to make the CI pass.

libcxx/include/math.h | ||
---|---|---|

711 |

libcxx/include/math.h | ||
---|---|---|

711 | The issue is that AIX implements math functions |

libcxx/include/math.h | ||
---|---|---|

1058–1059 | We also define |

libcxx/include/math.h | ||
---|---|---|

1058–1059 | Per discussion just now, the |

libcxx/include/math.h | ||
---|---|---|

1348–1350 | I know this is not the main purpose of this patch, but this doesn't help us if we want to support systems where e.g. |

libcxx/include/math.h | ||
---|---|---|

1348–1350 | I'm planning to add |

libcxx/include/math.h | ||
---|---|---|

711 | Nice, thanks! |