News for hackers. Stuff that matters.

joaquintides

Re: on Wednesday April 01, 2026 @07:47AM (#47599578)
Abstract: Many people hate math, some programmers do too. We hold that this hate stems from a reductionist view of mathematics as merely rule application: number crunching, equation solving and the like. But programming is more akin to mathematical creation, and writing a well designed, neat program can be as exhilarating as devising a new little math theory. In this talk we'll investigate how the mathematical mind approaches the world, and how developing a mathematical inclination can help you be a better C++ programmer. Presentation: https://github.com/joaquintides/usingstdcpp2026
Re: on Thursday March 12, 2026 @04:20AM (#47347904)
Vinnie Falco, creator of Boost.Beast, shares the origin story behind two new coroutine-based networking libraries, Corosio and Capy. While designing Beast2 as a C++11 networking library, Falco repeatedly sought design advice from Peter Dimov, who had one persistent answer: just use coroutines. Determined to prove him wrong, Falco set out to learn coroutines, implement his own task type, and benchmark it against ASIO.

The results surprised him. Initial benchmarks confirmed his suspicion that coroutines performed poorly, but after applying optimizations like a recycling allocator, performance improved dramatically. Under more realistic, higher-abstraction scenarios, coroutines actually beat ASIO - because composed operations built from nested operation states accumulate costly move constructions and memory copies as structs grow, while a coroutine handle remains just a pointer. What began as a mission to discredit coroutines became the foundation for two new libraries.

https://github.com/cppalliance/corosio https://github.com/cppalliance/capy

Re:Match Block Size to CPU / Cache with Boost.DynamicBitset on Monday November 24, 2025 @02:48PM (#46038387)
Levers that matter: Backend: std::vector (default) or boost::container::small_vector for small buffer optimization and fewer heap hits. Block: choose an unsigned type that matches your CPU/cache tradeoffs (e.g., 64-bit on x64). Maintainability: API stays the same—operator&, |, ^, shifts, resize/shrink_to_fit. Add reserve for predictable growth.
Re:Boost.Decimal Has Been Accepted on Monday November 10, 2025 @02:48PM (#45880076)
Boost.Decimal by Matt Borland and Chris Kormanyos has been accepted! Implementation of IEEE 754 and ISO/IEC DTR 24733 Decimal Floating Point numbers. Thanks to Review Manager John Maddock.

Repo: https://github.com/cppalliance/decimal

Docs: https://develop.decimal.cpp.al/decimal/overview.html

Re: on Tuesday July 15, 2025 @07:52AM (#44570189)
Abstract: Push and pull are the two main paradigms when it comes to data processing. In this talk, we'll discuss both approaches from an abstract point of view, compare them for expressivity and efficiency, review some prominent C++ examples and propose a push-based approach that outperforms C++ ranges, sometimes by a wide margin. We end the talk by discussing how coroutines blur the boundaries between push and pull and what it would take for them to be a compelling option for high-performance data processing.

Presentation and associated material:

https://github.com/joaquintides/usingstdcpp2025

Re:The Two Factions of C++ on Tuesday November 26, 2024 @05:58PM (#42251054)
Iteration has been improved since, and now we’re beating Abseil on iteration plus erasure:

https://github.com/boostorg/boost_unordered_benchmarks/tree/...

Re: on Thursday June 06, 2024 @01:30PM (#40600121)
Unlike regular hash functions, so-called perfect hash functions guarantee that no collisions ever happen, that is, every two distinct keys map to different hash values, which allows for the construction of hash tables with strict O(1) performance. This seemingly impossible feat comes with the tradeoff that the set of elements must be known in advance prior to table initialization. In this talk we'll review the basics of perfect hashing theory, explain some of the most common algorithms found in the literature, review some C++ perfect hashing libraries and learn how perfect hashing can be used to improve the efficiency of our programs.

Video: https://youtu.be/yOo6GnbKzp8

Presentation: https://github.com/joaquintides/usingstdcpp2024/raw/main/Per...

Repo: https://github.com/joaquintides/usingstdcpp2024

Re: on Monday May 22, 2023 @01:10PM (#36033996)
Boost 1.81 (Dec 2022) released boost::unordered_flat_map, a hashmap (unordered associative container in C++ parlance) that relies on open addressing and SIMD techniques to provide extremely high performance. In this talk, Joaquín will invite you to look under boost::unordered_flat_map's hood with him and learn about this container's data structure, its key design elements and how it compares with other top-performance C++ hashmaps both in theory and in practice. The talk finishes with a teaser on concurrent hashmaps arriving as part of your Boost update later this year.
Re:Boost:Unordered_flat_map on Sunday November 20, 2022 @07:05AM (#33680290)
Complexity is still O(n) because sizes grow exponentially, so the cost of amortizing rehashes over the number of inserted elements is a constant. Here's a theoretical analysis of this: https://www.cs.cornell.edu/courses/cs3110/2011sp/Lectures/le...

Older »