llvm / llvm-project

The LLVM Project is a collection of modular and reusable compiler and toolchain technologies.
http://llvm.org
Other
27.86k stars 11.48k forks source link

P0226R1: Mathematical Special Functions for C++17 #99939

Open cjdb opened 1 month ago

cjdb commented 1 month ago

Link: https://wg21.link/p0226r1

Subtasks:

llvmbot commented 1 month ago

@llvm/issue-subscribers-c-17

Author: Christopher Di Bella (cjdb)

h-vetinari commented 1 month ago

There were several attempts at this (not claiming that the list below is exhaustive):

The last one is interesting for just using boost outright (like STL does), but that's in limbo with the LLVM board(?) around license questions. There was also this plan in some libc++ meeting notes from last year given in #72055 (there are probably several issues).

ldionne commented 1 month ago

There actually has been progress on the LLVM Board side of things since then. We would be ready to make an official request for using Boost as a back-end to the Board, the framework should be in place to treat this request now. CC @llvm-beanz

mordante commented 1 month ago

@PaulXiCao is working on this. The first function will be shipped in libc++ 19 :-)

PaulXiCao commented 1 month ago

Including Boost.Math sounds like a really great approach! I was told the licensing topic is too complex for a short-term solution which is why I started implementing them on my own.

I started out from the above linked, abandoned mr (from legacy Phabricator). The first function that got merged just recently was std::hermite (this mr for reference). I started work on std::legendre, std::assoc_legendre, and std::laguerre some time ago. I planned to continue now that std::hermite got merged.

On the other hand, it might be more reasonable to wait for a final decision on the usage of Boost.Math?