Hacker GitHub

← All repos

abseil/abseil-cpp

View on GitHub ↗ ★ 18,182 C++

Abseil Common Libraries (C++)

63 mentions on Hacker News by 46 people: 3 stories, 60 comments · first 2017-09-26 · latest 2026-09-12

Mentions per year 63 mentions · busiest year 2023 (11)
20082026
  1. …packages in 2009[2], which was a lot back then. In 2026, Maven Central hosts over 3 million. [1]: https://github.com/abseil/abseil-cpp [2]: https://mvnrepository.com/repos/central
  2. ▲ 1
    Abseil Common Libraries (C++)
    story by tosh · 2026-05-17 · 0 comments
  3. …is absl’s linear approximation of gettime from cycle counters, which I thought is a neat trick: https://github.com/abseil/abseil-cpp/blob/351086314d46e73d43...
    comment by rockwotj · 2026-04-27 · in The fastest Linux timestamps
  4. …to happen at run time, or "DCHECK" for checks that will be compiled away when NDEBUG is defined. https://github.com/abseil/abseil-cpp/blob/0093ac6cac892086a6... https://github.com/abseil/abseil-cpp/blob/0093ac6cac892086a6...
    comment by omoikane · 2026-03-28 · in C++26: A User-Friednly assert() macro
  5. https://github.com/abseil/abseil-cpp/blob/master/absl/contai... mentions that b-tree maps hold multiple values per node, which makes them more cache-friendly than the red-black trees used in std::map. You use either container when you want…
  6. …What's some of the "preprocessor magic" that makes this[1] more ergonomic to use? [1]: https://github.com/abseil/abseil-cpp/blob/master/absl/status...
    comment by moogly · 2026-01-05 · in Monads in C# (Part 2): Result
  7. …[1]. I.e. exactly what Rust's standard library `HashMap` is, also the one being tested here. [1] https://github.com/abseil/abseil-cpp/blob/23b9b75217721040f5...
  8. Looks similar to absl::NoDestructor https://github.com/abseil/abseil-cpp/blob/master/absl/base/n... Which is basically the only usage of std::launder I have seen
    comment by rockwotj · 2025-07-19 · in C++: Zero-cost static initialization
  9. …`#pragma once` https://github.com/gabime/spdlog/blob/v1.x/include/spdlog/as... - `absl`: `#ifndef` https://github.com/abseil/abseil-cpp/blob/master/absl/base/a... - `zpp_bits`: `#ifndef` https://github.com/eyalz800/zpp_bits/blob/main/zpp_bi…
  10. A way to do the same thing that is less gross: https://github.com/abseil/abseil-cpp/blob/master/absl/cleanu...
  11. …type, and is what is used inside Google's C++ codebases (where exceptions are mostly forbidden) https://github.com/abseil/abseil-cpp/blob/master/absl/status...
    comment by cmrdporcupine · 2025-05-06 · in Matt Godbolt sold me on Rust by showing me C++
  12. …abseil [2] come to mind, but it's not exactly what I envision. 1: https://github.com/ETLCPP/etl 2: https://github.com/abseil/abseil-cpp
  13. …(std::mutex, absl::base_internal::SpinLock) which might be useful to get an approximate baseline. https://github.com/abseil/abseil-cpp/blob/master/absl/synchr...
    comment by vitus · 2024-10-02 · in The Fastest Mutexes
  14. …time I've heard of nsync, but Mike Burrows also wrote Google's production mutex implementation at https://github.com/abseil/abseil-cpp/blob/master/absl/synchr... I'm curious why this mutex implementation is absent from the author's…
    comment by kccqzy · 2024-10-02 · in The Fastest Mutexes
  15. Their justification is here https://github.com/abseil/abseil-cpp/issues/720 However, I personally disagree with them since I think it's really important to have _some_ basic reproducibility for things like reproducing the results of a…
  16. …in std::) Incremental: It does not provide a complete C++ Standard Library implementation." Abseil: https://github.com/abseil/abseil-cpp "Abseil is an open-source collection of C++ library code designed to augment the C++ standard library.…
  17. …cache line bouncing?) [1] https://github.com/rust-lang/rust/blob/master/library/alloc/... [2] https://github.com/abseil/abseil-cpp/blob/74f8c1eae915f90724... [3] https://github.com/abseil/abseil-cpp/blob/74f8c1eae915f90724...
  18. …but there are also many corners of the codebase with, um, looser standards for code quality). [0] https://github.com/abseil/abseil-cpp/blob/bde089f/absl/time/...
  19. I've started using abseil null/no null https://www.google.com/url?sa=t&source=web&rct=j&opi=8997844... We have a linter that will try to catch cases where you didn't null check but the field is nullable
    comment by 8n4vidtmkvmk · 2023-12-02 · in Is Ada safer than Rust?
  20. Yeah, it's nice! And Abseil does it, IFF you use LLVM libc++. https://github.com/abseil/abseil-cpp/blob/master/absl/string... The standard adopted it as resize_and_overwrite. Which I think is a little clunky.
  21. What about something like https://github.com/abseil/abseil-cpp/blob/master/absl/string... ? ASCII lowercase can be something like auto is_upper= (x > '@') & (x < '['); return is_upper ? x+32 : x; Which boils down to add, add, cmp, cmov on…
  22. …but the C++ version also comes with good microbenchmark coverage. https://github.com/google/btree https://github.com/abseil/abseil-cpp/blob/master/absl/contai...
  23. …comments): https://news.ycombinator.com/item?id=36228125 Deepmind's commit to abseil: https://github.com/abseil/abseil-cpp/commit/74eee2aff683cc7d... I'm curious if any of the mimicry work has been upstreamed. I don't see any mentions in…
  24. An implementation of call_once that accommodates callbacks that throw: https://github.com/abseil/abseil-cpp/blob/master/absl/base/c...
  25. …set for GPT-4, which was frozen sometime in March 2023. [1] https://reviews.llvm.org/D118029 [2] https://github.com/abseil/abseil-cpp/commit/74eee2aff683cc7d...
  26. …see hashing optimizations as well https://www.deepmind.com/blog/alphadev-discovers-faster-sort... , https://github.com/abseil/abseil-cpp/commit/74eee2aff683cc7d... I was one of the members who reviewed expertly what has been done both in…
  27. And for the hashing patch this is the commit to Abseil: https://github.com/abseil/abseil-cpp/commit/74eee2aff683cc7d...
  28. …be auto in this example (which becomes string_view). StripAsciiWhitespace takes a string_view here: https://github.com/abseil/abseil-cpp/blob/master/absl/string... The garbage comes from AsciiStrToUpper returning a new std::string which…
    comment by hot_gril · 2023-02-28 · in Will Carbon Replace C++?
  29. ▲ 3
    AlphaZero finds faster hash functions
    story by symmetrical · 2023-02-07 · 0 comments
  30. …on the heuristics and degrees of freedom around read/write ownership, so they did it like this: https://github.com/abseil/abseil-cpp/blob/master/absl/synchr... which is quite a bit better commented/legible. If anyone reading this can do…
  31. …-- this forces it to use buckets with linked lists under the hood. Try absl::flat_hash_set ( https://github.com/abseil/abseil-cpp/blob/master/absl/contai... ) and see how it goes.
    comment by bbqbbqbbq · 2022-08-09 · in A quick and practical “MSI” hash table
  32. …at least as far back as 2013. https://chromium.googlesource.com/chromium/src/base/+/master... https://github.com/abseil/abseil-cpp/blob/master/absl/string... https://github.com/steinwurf/boost/commits/master/boost/util... All of this is…
  33. …Side note, I was reading some Abseil code last night that did some funky bit twiddling on ARM: https://github.com/abseil/abseil-cpp/blob/master/absl/hash/i... Off the top of my head, isn’t it about 200ns [edit, not ms] to query, bus, and…
  34. I was referring to https://github.com/abseil/abseil-cpp/blob/master/absl/base/i...
    comment by asdfasgasdgasdg · 2021-11-07 · in A Close Look at a Spinlock
  35. …too does std::function for that matter). That's the big win for things like absl's inlined_vector https://github.com/abseil/abseil-cpp/blob/master/absl/contai... It's an ABI break to add small-size optimizations to std::vector at this…
  36. Probably not, since --flagfile accepts a list of filenames :-) https://github.com/abseil/abseil-cpp/blob/1ae9b71c474628d60e...
    comment by yegle · 2021-10-06 · in Moving Google toward the mainline
  37. …of it is just mundane details. Some of it leaks out in ABSL, for example some boring trivia is at: https://github.com/abseil/abseil-cpp/blob/master/absl/base/i... They also have for years had major patches to TCP which Linux refuses to…
    comment by jeffbee · 2021-10-06 · in Moving Google toward the mainline
  38. …default. Sadly, nothing like that is included in the standard, so won't be a lingua-franca. [1]: < https://github.com/abseil/abseil-cpp/blob/master/absl/contai... >
    comment by yakubin · 2021-09-05 · in Fast Rust Builds
  39. …internal space for N and if needed it reallocates. Brilliant if you can arrive at a reasonable N. https://github.com/abseil/abseil-cpp/blob/master/absl/contai...
  40. For a real battle-tested combination of spinlock and futex, see https://github.com/abseil/abseil-cpp/blob/master/absl/synchr...
  41. …an open-source implementation of a string-like sequence as a tree of chunks, consider absl::Cord. https://github.com/abseil/abseil-cpp/blob/master/absl/string... Do read the caveats in the header comments before using it in lieu of…
  42. I suggest looking at some of Google's open sourced projects. - Abseil: https://github.com/abseil/abseil-cpp https://cs.opensource.google/abseil - Tensorflow: https://github.com/tensorflow/tensorflow/tree/master/tensorf...…
    comment by kartayyar · 2020-10-28 · in Ask HN: Good C++ code bases to read?
  43. …that uses some modern C++ features but not the kitchen sink. Example you could start right here: https://github.com/abseil/abseil-cpp/blob/master/absl/string... LevelDB is good reading, too.
    comment by jeffbee · 2020-10-28 · in Ask HN: Good C++ code bases to read?
  44. I'm rather proud of Abseil's implementation: https://github.com/abseil/abseil-cpp/blob/887d0eee6bab358472... As I recall another colleague wrote the original version (I do not remember who.) I bitbashed and optimized it, and added the…
  45. …absl::from_chars, with some included benchmarks and results at the bottom of the benchmark code. https://github.com/abseil/abseil-cpp/blob/master/absl/string... ETA: I adapted the benchmark in the blog to use absl::from_chars and it's more…
  46. …https://www.agner.org/optimize/vectorclass.pdf [3] https://www.youtube.com/watch?v=ncHmEUmJZf4 [4] https://github.com/abseil/abseil-cpp [5] https://github.com/questdb/questdb/blob/master/core/src/main... [6]…
  47. …Abseil library contains an open source C++ implementation of a similar structure called a Cord: https://github.com/abseil/abseil-cpp/blob/master/absl/string...
    comment by klipt · 2020-06-08 · in Pain Points of Haskell
  48. …as part of Abseil [1] and Rust stdlib [2]. [0] https://www.youtube.com/watch?v=ncHmEUmJZf4 [1] https://github.com/abseil/abseil-cpp [2] https://github.com/rust-lang/hashbrown
    comment by vthriller · 2020-03-02 · in When Bloom filters don't bloom
  49. …_ok_ but even there things like absl::InlinedVector are worth a strong consideration instead ( https://github.com/abseil/abseil-cpp/blob/master/absl/contai... ). Or boost's small_vector ( https://www.boost.org/doc/libs/1_60_0/doc/html/boost…
  50. …dissatisfaction with how this turns out when people don't go as deep as the authors of Fibers did. https://github.com/abseil/abseil-cpp/issues/5