-
-
Notifications
You must be signed in to change notification settings - Fork 194
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Change C++ logging library to spdlog
or glog
#3195
Comments
glog is also worth considering. It would be less disruptive as the syntax is the same as what we have in loguru. |
I support the change but am also interested in glog. Both glog and spdlog are available in vcpkg, homebrew, Debian, RedHat, conda (feedstock) and Spack, so no issues there. glog (unlike spdlog) has a Windows/Visual Studio CI job on Github Actions. It is also a drop in replacement for loguru. We are not logging heavily in tight loops so performance differences are not hugely important for us. @chrisrichardson and I have nearly finished the Windows build and have identified loguru as producing strange linking (!) errors when compiling the Python headers. I'm sure this can be fixed, but perhaps the energy is better spent switching quickly to something more modern. |
spdlog
spdlog
or glog
I've updated the title to add glog to spdlog. |
https://github.com/FEniCS/dolfinx/tree/chris/glog - seems an easy drop-in. |
On further testing, I think spdlog is a better choice: |
Switched to spdlog in #3216 |
Some time ago we adopted loguru for C++ logging. At the time we considered several options (see #3). The history is a bit hard to follow, but we did have a PR for using spdlog (#311), but eventually adopted loguru (#417).
A consideration at the time was a reluctance to introduce a substantial dependency that was not widely packaged. loguru is light and we included the source in the DOFLINx tree.
In the meantime,
Should we switch from loguru to spdlog or glog?
@jhale, @chrisrichardson
The text was updated successfully, but these errors were encountered: