abseil-cpp
Abseil Common Libraries (C++)
Google's open-source C++17 utility libraries: Swiss-table hash maps, absl::Status, time, flags, logging, and concurrency helpers that supplement the standard library.
Abseil is an open-source collection of C++ utility libraries released by Google. C++ is a powerful but lower-level programming language that doesn't include as many ready-made tools as higher-level languages. Abseil fills that gap by providing common building blocks that Google has used and battle-tested internally at massive scale.
The library is compliant with C++17 and is designed to supplement — not replace — the C++ standard library. Some components provide things missing from the standard; others offer alternatives Google found more practical for its specific needs.
Abseil is organized into focused sub-libraries, each handling a distinct area: Strings for text manipulation; Containers including highly optimized "Swiss table" hash maps; Status for standardized error handling using an absl::Status type; Time for working with absolute times, durations, and time zones; Synchronization for concurrency tools like mutexes (locks that prevent multiple threads from conflicting); Flags for command-line argument parsing; and Logging with LOG and CHECK macros. The library also includes hashing, memory management, debugging, and CRC checksums (for detecting data corruption).
Abseil can be added to a C++ project using either the Bazel or CMake build systems. It is licensed under Apache 2.0.
You would use Abseil in a C++ project where you want well-tested, production-grade utilities without reinventing common patterns — particularly in large codebases where consistent error handling, logging, and data structures matter.
Where it fits
- Adopt absl::Status as a standard error type across a large C++ codebase
- Replace std::unordered_map with Abseil's faster Swiss-table hash maps
- Parse command-line flags with absl::flags instead of hand-rolled parsing
- Add absl logging macros LOG and CHECK to a service for production debugging