| Name | Description |
|---|---|
example | Example code demonstrating the Folly logging library. |
fmt | The {fmt} formatting library namespace. |
folly | include or backport: * std::invoke * std::invoke_result * std::invoke_result_t * std::is_invocable * std::is_invocable_v * std::is_invocable_r * std::is_invocable_r_v * std::is_nothrow_invocable * std::is_nothrow_invocable_v * std::is_nothrow_invocable_r * std::is_nothrow_invocable_r_v |
ranges | The range-v3 library namespace. |
std | Standard library specializations of std::hash for Folly and standard types. |
| Name | Description |
|---|---|
DynamicRingQueueTestHelper | Test helper granting access to DynamicRingQueue internals. |
io_uring_cqe | A completion queue entry (CQE) from the liburing C API. |
io_uring_sqe | A submission queue entry (SQE) from the liburing C API. |
open_how | Linux openat2 syscall options structure. |
r_debug | The dynamic linker's debug rendezvous structure. |
| Name | Description |
|---|---|
folly_port_struct_timezone | Portable alias for the system struct timezone. |
| Name | Description |
|---|---|
BENCHMARK | Introduces a benchmark function. Use with either one or two arguments. The first is the name of the benchmark. Use something descriptive, such as insertVectorBegin. The second argument may be missing, or could be a symbolic counter. The counter dictates how many internal iteration the benchmark does. Example: |
BENCHMARK_COUNTERS | Allow users to record customized counter during benchmarking, there will be one extra column showing in the output result for each counter |
BENCHMARK_COUNTERS_NAMED_PARAM | Like BENCHMARK_NAMED_PARAM, but passes a UserCounters& parameter to the benchmark function for recording custom counters. |
BENCHMARK_COUNTERS_PARAM | Like BENCHMARK_PARAM, but passes a UserCounters& parameter. |
BENCHMARK_DRAW_LINE | Draws a line of dashes. |
BENCHMARK_DRAW_TEXT | Prints arbitrary text. |
BENCHMARK_IMPL | Introduces a benchmark function. Used internally, see BENCHMARK and friends below. |
BENCHMARK_MULTI | Like BENCHMARK above, but allows the user to return the actual number of iterations executed in the function body. This can be useful if the benchmark function doesn't know upfront how many iterations it's going to run or if it runs through a certain number of test cases, e.g.: |
BENCHMARK_MULTI_IMPL | Introduces a benchmark function with support for returning the actual number of iterations. Used internally, see BENCHMARK_MULTI and friends below. |
BENCHMARK_NAMED_PARAM_MULTI | Same as BENCHMARK_NAMED_PARAM, but allows one to return the actual number of iterations that have been run. |
BENCHMARK_PARAM | Defines a benchmark that passes a parameter to another one. This is common for benchmarks that need a "problem size" in addition to "number of iterations". Consider: |
BENCHMARK_PARAM_MULTI | Same as BENCHMARK_PARAM, but allows one to return the actual number of iterations that have been run. |
BENCHMARK_RELATIVE | Just like BENCHMARK, but prints the time relative to a baseline. The baseline is the most recent BENCHMARK() seen in the current scope. Example: |
BENCHMARK_RELATIVE_MULTI | Same as BENCHMARK_RELATIVE, but allows one to return the actual number of iterations that have been run. |
BENCHMARK_RELATIVE_NAMED_PARAM | A combination of BENCHMARK_RELATIVE and BENCHMARK_NAMED_PARAM. |
BENCHMARK_RELATIVE_NAMED_PARAM_MULTI | Same as BENCHMARK_RELATIVE_NAMED_PARAM, but allows one to return the actual number of iterations that have been run. |
BENCHMARK_RELATIVE_PARAM | A combination of BENCHMARK_RELATIVE and BENCHMARK_PARAM. |
BENCHMARK_RELATIVE_PARAM_MULTI | Same as BENCHMARK_RELATIVE_PARAM, but allows one to return the actual number of iterations that have been run. |
BENCHMARK_SUSPEND | Allows execution of code that doesn't count toward the benchmark's time budget. Example: |
CHECK_THROW | If cond is not true, raise an exception of type E. E must have a ctor that works with const char* (a description of the failure). |
EXPECT_PCRE_MATCH | Easy PCRE regex matching. Note that pattern must match the ENTIRE target, so use .* at the start and end of the pattern, as appropriate. See http://regex101.com/ for a PCRE simulator. |
FB_ARG_1 | Helper macro that extracts the first argument out of a list of any number of arguments. |
FB_LOG | Log a message to the specified logger. |
FB_LOGF | Log a message to the specified logger, using a fmt::format() string. |
FB_LOGF_RAW | FB_LOGF_RAW() is similar to FB_LOG_RAW(), but formats the log arguments using fmt::format(). |
FB_LOG_EVERY_MS | Issues a LOG(severity) no more often than every milliseconds. Example: |
FB_LOG_IMPL | Helper macro for implementing FB_LOG() and FB_LOGF(). |
FB_LOG_RAW | FB_LOG_RAW() can be used by callers that want to pass in the log level as a variable, and/or who want to explicitly specify the filename and line number. |
FB_LOG_RAW_IMPL | Helper macro for implementing FB_LOG_RAW() and FB_LOGF_RAW(). |
FB_NOT_NULL_MK_OP | Comparison: - Forwards to underlying PtrT. - Works when one of the operands is not not_null. - Works when one of the operands is nullptr. |
FB_ONE_OR_NONE | FB_ONE_OR_NONE(hello, world) expands to hello and FB_ONE_OR_NONE(hello) expands to nothing. This macro is used to insert or eliminate text based on the presence of another argument. |
FB_SINGLE_ARG | Helper macro that provides a way to pass argument with commas in it to some other macro whose syntax doesn't allow using extra parentheses. Example: |
FB_VA_GLUE | Concatenate two preprocessor tokens by juxtaposition, forcing an extra expansion pass. |
FOLLY_ASSUME_FBVECTOR_COMPATIBLE | The FOLLY_ASSUME_FBVECTOR_COMPATIBLE* macros below encode the assumption that the type is relocatable per IsRelocatable above. Many types can be assumed to satisfy this condition, but it is the responsibility of the user to state that assumption. User-defined classes will not be optimized for use with fbvector (see FBVector.h) unless they state that assumption. |
FOLLY_ASSUME_RELOCATABLE | Use this macro ONLY inside namespace folly. When using it with a regular type, use it like this: |
FOLLY_ASSUME_UNREACHABLE | Inform the compiler that the statement is not reachable at runtime, and disable compiler warnings. |
FOLLY_COMPRESSION_HAS_CONTEXT_POOL_SINGLETONS | Added here so users of folly can figure out whether the header folly/compression/CompressionContextPoolSingletons.h is present, and therefore whether it can be included. |
FOLLY_CREATE_FREE_INVOKER | * FOLLY_CREATE_FREE_INVOKER |
FOLLY_CREATE_FREE_INVOKER_SUITE | * FOLLY_CREATE_FREE_INVOKER_SUITE |
FOLLY_CREATE_MEMBER_ACCESSOR | * FOLLY_CREATE_MEMBER_ACCESSOR |
FOLLY_CREATE_MEMBER_ACCESSOR_SUITE | * FOLLY_CREATE_MEMBER_ACCESSOR_SUITE |
FOLLY_CREATE_MEMBER_INVOKER | * FOLLY_CREATE_MEMBER_INVOKER |
FOLLY_CREATE_MEMBER_INVOKER_SUITE | * FOLLY_CREATE_MEMBER_INVOKER_SUITE |
FOLLY_CREATE_QUAL_INVOKER | * FOLLY_CREATE_QUAL_INVOKER |
FOLLY_CREATE_QUAL_INVOKER_SUITE | * FOLLY_CREATE_QUAL_INVOKER_SUITE |
FOLLY_CREATE_STATIC_MEMBER_INVOKER | * FOLLY_CREATE_STATIC_MEMBER_INVOKER |
FOLLY_CREATE_STATIC_MEMBER_INVOKER_SUITE | * FOLLY_CREATE_STATIC_MEMBER_INVOKER_SUITE |
FOLLY_DECLARE_REUSED | FOLLY_DECLARE_REUSED |
FOLLY_DETAIL_LITE_TUPLE_ADJUST_WARNINGS | Any file constructing lite_tuple should contain this after #includes: FOLLY_PUSH_WARNINGS FOLLY_DETAIL_LITE_TUPLE_ADJUST_WARNINGS Followed by FOLLY_POP_WARNING at the bottom. The reason is that -Wmissing-braces otherwise breaks deduction guides, and makes aggregate initialization a real headache to use: lite_tuple::tuple t{1, 2, 3}; // before :) lite_tuple::tuple<int> t{{{1}, {2}, {3}}}; // after :'( |
FOLLY_EXHAUSTIVE_SWITCH | C++ switch-case statements enable writing conditional statements that are checked for exhaustiveness by the compiler. However, C++ compilers don't enforce exhaustiveness very well. These macros enable you to explicitly opt into truly exhaustive switch-cases, that are useful for scenarios where you may want to deal with enums that are inputs, rather than internal invariants. |
FOLLY_EXPECT_JSON_EQ | GTest predicate asserting two JSON strings are equal documents. |
FOLLY_EXPECT_JSON_NEAR | GTest predicate asserting two JSON strings are equal within a tolerance. |
FOLLY_EXPECT_JSON_WITH_NESTED_JSON_EQ | GTest predicate asserting two JSON strings are equal, comparing one level of nested JSON-in-string. |
FOLLY_FOR_EACH_THIS_OVERLOAD_IN_CLASS_BODY_DELEGATE | FOLLY_FOR_EACH_THIS_OVERLOAD_IN_CLASS_BODY_DELEGATE |
FOLLY_IGNORE | Helper macro that just ignores its parameters. |
FOLLY_INIT_LOGGING_CONFIG | A helper macro to set the default logging configuration in a program. |
FOLLY_INVOKE_MEMBER | * FOLLY_INVOKE_MEMBER |
FOLLY_INVOKE_QUAL | * FOLLY_INVOKE_QUAL |
FOLLY_LIKELY | Treat the condition as likely. |
FOLLY_PP_FOR_EACH | FOLLY_PP_FOR_EACH |
FOLLY_PP_STRINGIZE | Use FOLLY_PP_STRINGIZE(x) when you'd want to do what #x does inside another macro expansion. |
FOLLY_PP_STRINGIZE_MACRO | Use FOLLY_PP_STRINGIZE_MACRO(x) when you want the string representation of a non-string c++ preprocessing macro value, ex FOLLY_PP_STRINGIZE_MACRO(LINE). |
FOLLY_SEMICOLON | Helper macro that just ignores its parameters and inserts a semicolon. |
FOLLY_SETTING | Accesses a defined setting. Rationale for the macro: 1) Searchability, all settings access is done via FOLLY_SETTING(...) 2) Prevents omitting trailing () by accident, which could lead to bugs like auto value = *FOLLY_SETTING_project_name;, which compiles but dereferences the function pointer instead of the setting itself. |
FOLLY_SETTING_DECLARE | Declares a setting that's defined elsewhere. |
FOLLY_SETTING_DEFINE | Defines a setting. |
FOLLY_SETTING_REGISTER | Registers a setting without defining an Accessor. This should rarely be used directly and most use cases will want FOLLY_SETTING_DEFINE instead. |
FOLLY_UNLIKELY | Treat the condition as unlikely. |
SCOPE_EXIT | Capture code that shall be run when the current scope exits. |
SCOPE_FAIL | Capture code to run if the scope exits with an exception. |
SCOPE_SUCCESS | Capture code to run if the scope exits without an exception. |
SO_SET_NAMESPACE | Sets a specific tcp personality Available only on kernels 3.2 and greater |
SYNCHRONIZED | NOTE: This API is deprecated. Use lock(), wlock(), rlock() or the withLock functions instead. In the future it will be marked with a deprecation attribute to emit build-time warnings, and then it will be removed entirely. |
SYNCHRONIZED_CONST | NOTE: This API is deprecated. Use lock(), wlock(), rlock() or the withLock functions instead. In the future it will be marked with a deprecation attribute to emit build-time warnings, and then it will be removed entirely. |
SYNCHRONIZED_DUAL | NOTE: This API is deprecated. Use lock(), wlock(), rlock() or the withLock functions instead. In the future it will be marked with a deprecation attribute to emit build-time warnings, and then it will be removed entirely. |
SYNCHRONIZED_VAR | Disambiguate the name var by concatenating the line number of the original point of expansion. This avoids shadowing warnings for nested SYNCHRONIZEDs. The name is consistent if used multiple times within another macro. Only for internal use. |
XCHECK | Assert that a condition is true. |
XCHECK_EQ | Assert a comparison relationship between two arguments. |
XDCHECK | Assert that a condition is true in debug builds only. |
XDCHECK_EQ | Assert a comparison relationship between two arguments in debug builds. |
XLOGF | Log a message to this file's default log category, using a format string. |
XLOGF_EVERY_MS | Similar to XLOGF(...) except only log a message every |
XLOGF_EVERY_MS_IF | Similar to XLOGF(...) except only log a message every |
XLOGF_EVERY_MS_OR | Similar to XLOGF(...) except log a message if the specified condition predicate evaluates to true or every |
XLOGF_EVERY_N | Similar to XLOGF(...) except only log a message every |
XLOGF_EVERY_N_IF | Similar to XLOGF(...) except only log a message every |
XLOGF_EVERY_N_OR | Similar to XLOGF(...) except it logs a message if the condition predicate evaluates to true or approximately every |
XLOGF_FIRST_N | Similar to XLOGF(...) except only log a message the first n times, exactly. |
XLOGF_IF | Log a message using a format string if and only if the specified condition predicate evaluates to true. Note that the condition is only evaluated if the log-level check passes. |
XLOG_ACTUAL_IMPL | Helper macro used to implement XLOG() and XLOGF() |
XLOG_EVERY_MS | Similar to XLOG(...) except only log a message every |
XLOG_EVERY_MS_IF | Similar to XLOG(...) except only log a message every |
XLOG_EVERY_MS_OR | Similar to XLOG(...) except log a message if the specified condition predicate evaluates to true or every |
XLOG_EVERY_N | Similar to XLOG(...) except only log a message every |
XLOG_EVERY_N_EXACT | Similar to XLOG(...) except only log a message every |
XLOG_EVERY_N_IF | Similar to XLOG(...) except only log a message every |
XLOG_EVERY_N_OR | Similar to XLOG(...) except it logs a message if the condition predicate evaluates to true or approximately every |
XLOG_EVERY_N_THREAD | Similar to XLOG(...) except only log a message every |
XLOG_FIRST_N | Similar to XLOG(...) except only log a message the first n times, exactly. |
XLOG_GET_CATEGORY | Get a pointer to the LogCategory that will be used by XLOG() statements in this file. |
XLOG_GET_CATEGORY_NAME | Get the name of the log category that will be used by XLOG() statements in this file. |
XLOG_IF | Log a message if and only if the specified condition predicate evaluates to true. Note that the condition is only evaluated if the log-level check passes. |
XLOG_IS_ON | Check if an XLOG() statement with the given log level would be enabled. |
XLOG_IS_ON_IMPL | Expects a fully qualified LogLevel enum value. |
XLOG_IS_ON_IMPL_HELPER | Helper macro to implement of XLOG_IS_ON() |
XLOG_N_PER_MS | Similar to XLOG(...) except only log at most |
_FE_ANON | Forms a local variable name from "FOR_EACH_", x, and LINE. |
Example code demonstrating the Folly logging library.
| Name | Description |
|---|---|
ExampleObject | Example object that logs to the folly.logging.example.lib category. |
The {fmt} formatting library namespace.
| Name | Description |
|---|---|
formatter<folly::StringPiece> | {fmt} formatter specialization for folly::StringPiece. |
formatter</* implementation-defined */> | Formats an errc_format_as tag for use with fmt. |
formatter<folly::error_or_stopped> | fmt::format support for folly::error_or_stopped. |
formatter<folly::exception_wrapper> | Formatter specialization that formats an exception_wrapper via what(). |
formatter<folly::fbstring> | {fmt} formatter specialization that formats fbstring as a string view. |
formatter<folly::rich_error_base::fmt_all_codes_t> | fmt::format support that renders all codes of a rich error. |
formatter<folly::rich_error_base> | fmt::format support for rich_error_base and derived classes. |
formatter<folly::rich_exception_ptr> | Formats a rich_exception_ptr for use with fmt. |
formatter<T> | fmt::format support for any type convertible to rich_error_base*. |
formatter<folly::rich_ptr_to_underlying_error<Ex>> | fmt::format support for the pointer-like returned by get_exception<Ex>(). |
formatter<folly::reproducible_accumulator<ftype, Fold>> | fmt formatter specialization for reproducible_accumulator. |
formatter<folly::basic_cstring_view<Char, Traits>, Char> | Formatter specialization for basic_cstring_view, reusing string_view formatting. |
include or backport: * std::invoke * std::invoke_result * std::invoke_result_t * std::is_invocable * std::is_invocable_v * std::is_invocable_r * std::is_invocable_r_v * std::is_nothrow_invocable * std::is_nothrow_invocable_v * std::is_nothrow_invocable_r * std::is_nothrow_invocable_r_v
| Name | Description |
|---|---|
array_detail | Implementation helpers for make_array and make_array_with. |
async_tracing | Implementation details. |
bind | READ ME: The docs for this library are in Bind.md. |
bititerator_detail | Implementation details for BitIterator. |
bser | BSER binary serialization for dynamic values. |
bskip_detail | Internal implementation details for ConcurrentBSkipList. |
channels | Sender/receiver channel primitives for asynchronous value streams. |
chrono | Time-related wrappers and clock utilities. |
compression | Compression and decompression codecs over IOBufs. |
coro | Coroutine primitives and combinators. |
crypto | Cryptographic hashing primitives. |
detail_tag_invoke_fn | Implementation details of the tag_invoke customization-point machinery. |
dptr_detail | Implementation details. |
dynamic_detail | Implementation details for dynamic. |
dynamicconverter_detail | Implementation details for DynamicConverter and DynamicConstructor. |
exception_tracer | Facilities for capturing and stacking exception stack traces. |
expected_detail | Implementation details for folly::Expected. |
experimental | Namespace for experimental Folly components. |
ext | Extension namespace for library authors, a public analog of folly::detail. |
external | Vendored third-party code adapted for use in Folly. |
f14 | Implementation details for the F14 hash table family. |
fallback | A fallback implementation used when the standard trait is unavailable. |
fbstring_detail | Implementation details for fbstring. |
fibers | Lightweight cooperative userspace threads (fibers) and related primitives. |
fileops | Portable wrappers and imports for file-descriptor operations. |
fileutil_detail | Implementation details. |
find_fixed_detail | Implementation details for folly::findFixed. |
for_each_detail | The user should return loop_break and loop_continue if they want to iterate in such a way that they can preemptively stop the loop and break out when certain conditions are met. |
format_value | Utilities for all format value specializations. |
fs | Portable filesystem imports selecting the available <filesystem> backend. |
futures | Futures-based asynchronous programming primitives. |
gen | Lazy sequence generators and pipeline operators. |
gflags | Minimal stand-in for the gflags namespace when gflags is unavailable. |
hash | Hashing algorithms and helpers. |
invoke_detail | Implementation details of the folly invocation traits. |
io | Cursor and queue utilities for reading and writing IOBuf chains. |
json | JSON parsing and serialization utilities. |
jsonschema | JSON Schema (draft v4) validation utilities. |
libcpp_detail | Implementation details for libc++ bitset support. |
logging | Folly's logging library. |
memory | Memory management utilities. |
moveonly_ | Internal namespace hosting the copy/move control base types. |
netops | Cross-platform socket operation wrappers. |
numbers | numbers |
observer | Folly's observer library. |
observer_detail | Implementation details. |
padded | Utilities for storing data aligned on block (possibly cache-line) boundaries, with optional padding. |
pmr | Aliases that use a polymorphic allocator. |
poly | Interfaces and helpers for the Poly type-erasure utility. |
portability | Portability shims for platform-specific system interfaces. |
recordio_helpers | Low-level helpers exposing the RecordIO record format. |
replaceable_detail | Implementation details for Replaceable; not part of the public API. |
settings | Runtime configuration settings framework. |
shared_mutex_detail | Implementation details for SharedMutex; not part of the public API. |
simd | SIMD algorithms and utilities. |
small_vector_policy | Policies that customize the behavior of folly::small_vector. |
ssl | SSL and TLS helpers built on OpenSSL. |
stable_radix_sort_detail | Implementation details for the stable radix sort. |
stable_radix_sort_keys | Stable LSD (Least Significant Digit) Radix Sort |
symbolizer | Stack trace capture and symbolization utilities. |
test | Testing utilities. |
threadlocal_detail | Implementation details. |
traits_detail | There is a bug in libstdc++, libc++, and MSVC's STL that causes it to ignore unused template parameter arguments in template aliases and does not cause substitution failures. This defect has been recorded here: http://open-std.org/JTC1/SC22/WG21/docs/cwg_defects.html#1558. |
traits_detail_IsEqualityComparable | Implementation namespace for the IsEqualityComparable trait. |
traits_detail_IsLessThanComparable | Implementation namespace for the IsLessThanComparable trait. |
| Name | Description |
|---|---|
AccessModeStrict | Tag selecting strict access mode for thread-local storage. |
AccessSpreader | AccessSpreader arranges access to a striped data structure in such a way that concurrently executing threads are likely to be accessing different stripes. It does NOT guarantee uncontended access. Your underlying algorithm must be thread-safe without spreading, this is merely an optimization. AccessSpreader::current(n) is typically much faster than a cache miss (12 nanos on my dev box, tested fast in both 2.6 and 3.2 kernels). |
AlignedSysAllocator | AlignedSysAllocator |
AllocatorHasDefaultObjectConstruct | AllocatorHasDefaultObjectConstruct |
AllocatorHasDefaultObjectDestroy | AllocatorHasDefaultObjectDestroy |
AllocatorHasTrivialDeallocate | AllocatorHasTrivialDeallocate |
AnnotatedLockGuard | A scoped lock for any capability-annotated mutex. |
AnnotatedMutex | A std::mutex wrapper carrying the capability("mutex") attribute. |
ApplyInvoke | Callable that invokes a function with the elements of a tuple as arguments. |
Arena | Arena that allocates memory in blocks and frees it all at destruction. |
ArenaAllocatorTraits | Simple arena: allocate memory which gets freed when the arena gets destroyed. |
AsciiCaseInsensitive | Check if two ascii characters are case insensitive equal. The difference between the lower/upper case characters are the 6-th bit. We also check they are alpha chars, in case of xor = 32. |
AsciiCaseSensitive | Case-sensitive equality comparator for ASCII characters. |
AsyncBase | Generic C++ interface around Linux IO(io_submit, io_uring) |
AsyncBaseOp | An AsyncBaseOp represents a pending operation. You may set a notification callback or you may use this class's methods directly. |
AsyncBaseQueue | Wrapper around AsyncBase that allows you to schedule more requests than the AsyncBase's object capacity. Other requests are queued and processed in a FIFO order. |
AsyncDetachFdCallback | Receives the result of detaching a file descriptor from a socket. |
AsyncFdSocket | Intended for use with Unix sockets. Unlike regular AsyncSocket: - Can send FDs via writeChainWithFds using socket ancillary data (see man cmsg). - Whenever handling regular reads, concurrently attempts to receive FDs included in incoming ancillary data. Groups of received FDs are enqueued to be retrieved via popNextReceivedFds. - The "read ancillary data" and "sendmsg params" callbacks are built-in are NOT customizable. |
AsyncFdSocketSequenceRoundtripTest_WithDataSize_Test | Test fixture friendship declaration generated by the GTest macro. |
AsyncFileWriter | An implementation of folly::AsyncLogWriter that writes log messages into a file. |
AsyncIO | C++ interface around Linux Async IO. |
AsyncIOOp | A pending operation backed by the Linux io_submit interface. |
AsyncIoUringSocket | |
AsyncIoUringSocketFactory | Creates AsyncIoUringSocket instances and reports io_uring support. |
AsyncLogWriter | An abstract LogWriter implementation that provides functionality for asynchronous IO operations. Users can subclass this class and provide their own IO operation implementation by overriding performIO method. This class will automatically manage incoming log messages and call the method in appropriate time. |
AsyncPipeReader | Read from a pipe in an async manner. |
AsyncPipeWriter | Write to a pipe in an async manner. |
AsyncReader | Interface for the read side of an asynchronous transport. |
AsyncSSLSocket | A class for performing asynchronous I/O on an SSL connection. |
AsyncSSLSocketConnector | Connector that drives the SSL handshake for an AsyncSSLSocket. |
AsyncServerSocket | AsyncServerSocket is a listening socket that asynchronously informs a callback whenever a new connection has been accepted. |
AsyncSignalHandler | A handler to receive notification about POSIX signals. |
AsyncSocket | An asynchronous socket. |
AsyncSocketBase | Base interface for asynchronous sockets bound to an event base. |
AsyncSocketException | Exception thrown by folly asynchronous socket operations. |
AsyncSocketObserverContainer | Container of observers attached to an AsyncSocket. |
AsyncSocketObserverInterface | Observer of socket events. |
AsyncSocketTransport | Abstract asynchronous transport backed by a socket. |
AsyncStackFrame | Represents a frame in an async stack trace. |
AsyncStackRoot | A stack-root represents the context of an event loop that is running some asynchronous work. The current async operation that is being executed by the event loop (if any) is pointed to by the 'topFrame'. |
AsyncTimeout | AsyncTimeout is used to asynchronously wait for a timeout to occur. |
AsyncTransport | AsyncTransport defines an asynchronous API for bidirectional streaming I/O. |
AsyncTransportCertificate | Generic interface applications may implement to convey self or peer certificate related information. |
AsyncUDPServerSocket | UDP server socket |
AsyncUDPSocket | UDP socket |
AsyncWriter | Interface for the write side of an asynchronous transport. |
AtFork | AtFork |
AtForkList | AtForkList |
AtomicCoreCachedSharedPtr | This class creates core-local caches for a given shared_ptr, to mitigate contention when acquiring/releasing it. |
AtomicHashArray | Fixed-size, lock-free hash array and building block for AtomicHashMap. |
AtomicHashArrayLinearProbeFcn | Linear probing strategy for AtomicHashArray. |
AtomicHashArrayQuadraticProbeFcn | Quadratic probing strategy for AtomicHashArray. |
AtomicHashMap | Lock-free, growable hash map built on top of AtomicHashArray. |
AtomicHashMapFullError | Thrown when insertion fails due to running out of space for submaps. |
AtomicIntrusiveLinkedList | A lock-free intrusive single-linked list. |
AtomicIntrusiveLinkedListHook | A very simple atomic single-linked list primitive. |
AtomicLinkedList | A very simple atomic single-linked list primitive. |
AtomicNotificationQueue | A producer-consumer queue for passing tasks to consumer thread. |
AtomicReadMostlyMainPtr | An atomically-swappable owner of a ReadMostlyMainPtr. |
AtomicStruct | AtomicStruct<T> work like C++ atomics, but can be used on any POD type <= 8 bytes. |
AtomicUnorderedInsertMap | You're probably reading this because you are looking for an AtomicUnorderedMap<K,V> that is fully general, highly concurrent (for reads, writes, and iteration), and makes no performance compromises. We haven't figured that one out yet. What you will find here is a hash table implementation that sacrifices generality so that it can give you all of the other things. |
AutoTimer | Automatically times a block of code, printing a specified log message on destruction or whenever the log() method is called. For example: |
BadExpectedAccess | An exception type thrown by Expected on catastrophic logic errors, i.e., when the caller tries to access the value within an Expected but when the Expected instead contains an error. |
BadFormatArg | Exception thrown when a format argument string is invalid. |
BadPolyAccess | Exception type that is thrown on invalid access of an empty Poly object. |
BadPolyCast | Exception type that is thrown when attempting to extract from a Poly a value of the wrong type. |
BaseFormatterImpl | Formatter class. |
BasicDynamicTokenBucket | Thread-safe (atomic) token bucket implementation. |
BasicFixedString | A class for holding up to N characters of type Char that is amenable to constexpr string manipulation. It is guaranteed to not perform any dynamic allocation. |
BasicTokenBucket | Specialization of BasicDynamicTokenBucket with a fixed token generation rate and a fixed maximum burst size. |
Baton | A Baton allows a thread to block once and be awoken. Captures a single handoff, and during its lifecycle (from construction/reset to destruction/reset) a baton must either be post()ed and wait()ed exactly once each, or not at all. |
BenchmarkSuspender | Supporting type for BENCHMARK_SUSPEND defined below. |
BitIterator | Fast bit iteration facility. |
Bits | Wrapper class with static methods for various bit-level operations, treating an array of T as an array of bits (in little-endian order). (T is either an unsigned integral type or Unaligned<X>, where X is an unsigned integral type) |
BlockingQueue | Abstract interface for a queue that can block callers until items are available. |
BlockingQueueAddResult | Result of adding an item to a BlockingQueue. |
BucketedTimeSeries | This class represents a bucketed time series which keeps track of values added in the recent past, and merges these values together into a fixed number of buckets to keep a lid on memory use if the number of values added is very large. |
CPUThreadPoolExecutor | A Thread pool for CPU bound tasks. |
CacheLocality | Holds cache sharing topology for the current system. |
CallbackAsyncSignalHandler | Derived template class that allows forwarding of a callback to be invoked in the overridden signalReceived(). |
CalledProcessError | Exception thrown by *Checked methods of Subprocess. |
CancellationCallback | A CancellationCallback object registers the callback with the specified CancellationToken such that the callback will be executed if the corresponding CancellationSource object has the requestCancellation() method called on it. |
CancellationSource | A CancellationSource object provides the ability to request cancellation of operations that an associated CancellationToken was passed to. |
CancellationToken | A CancellationToken is an object that can be passed into an function or operation that allows the caller to later request that the operation be cancelled. |
CertificateIdentityVerifier | CertificateIdentityVerifier implementations are used during TLS handshakes to extract and verify end-entity certificate identities. |
CertificateIdentityVerifierException | Base of exception hierarchy for CertificateIdentityVerifier failure reasons. |
Cleanup | Base class for structured async cleanup. |
Codel | CoDel (controlled delay) is an active queue management algorithm from networking for battling bufferbloat. |
ConcurrentBSkipDefaultPolicy | The default configuration policy for ConcurrentBSkipList. |
ConcurrentBSkipList | Concurrent B-skip-list container; declared here for friend declarations. |
ConcurrentBitSet | An atomic bitset of fixed size (specified at compile time). |
ConcurrentHashMap | Implementations of high-performance Concurrent Hashmaps that support erase and update. |
ConcurrentLazy | Thread-safe, delayed initialization of a value computed once at first access. |
ConcurrentSkipList | A concurrent, sorted, unique-key associative container. |
ConstructorCallbackList | A mixin that fires registered callbacks each time a class constructor runs. |
ConversionError | Exception thrown when a conversion fails, carrying a ConversionCode. |
ConversionErrorBase | Base class for exceptions thrown by folly conversion routines. |
CoreAllocator | An C++ allocator adapter for coreMalloc/Free. The allocator is stateless, to avoid increasing the footprint of the container that uses it, so the stripe needs to be passed out of band: allocate() can only be called while there is an active CoreAllocatorGuard. deallocate() can instead be called at any point. |
CoreAllocatorGuard | Scope guard that binds CoreAllocator allocations to a stripe. |
CoreCachedSharedPtr | This class creates core-local caches for a given shared_ptr, to mitigate contention when acquiring/releasing it. |
CoreCachedWeakPtr | Core-local cache of weak pointers to a shared object. |
CpuId | Identification of an Intel CPU. Supports CPUID feature flags (EAX=1) and extended features (EAX=7, ECX=0). Values from http://www.intel.com/content/www/us/en/processors/processor-identification-cpuid-instruction-note.html |
CustomLogFormatter | A LogFormatter implementation that produces messages in a format specified using a config. |
CxxAllocatorAdaptor | CxxAllocatorAdaptor |
CxxHugePageAllocator | STL compatible huge page allocator, for use with STL-style containers. |
CxxIoUringAllocator | An STL-compatible allocator backed by the io_uring arena. |
DCheckRequestContextRestoredGuard | Debug-only guard that checks the context is unchanged across a scope. |
DeadlockDetector | Interface for an object that watches an executor for deadlocks. |
DeadlockDetectorFactory | Factory that creates DeadlockDetector instances for executors. |
DecoratedAsyncTransportWrapper | Convenience class so that AsyncTransport can be decorated without having to redefine every single method. |
DefaultAlign | An alignment policy that carries a runtime alignment value. |
DefaultKeepAliveExecutor | An Executor accepts units of work with add(), which should be threadsafe. |
DefaultWeightFn | DynamicBoundedQueue supports: - Dynamic memory usage that grows and shrink in proportion to the number of elements in the queue. - Adjustable capacity that helps throttle pathological cases of producer-consumer imbalance that may lead to excessive memory usage. - The adjustable capacity can also help prevent deadlock by allowing users to temporarily increase capacity substantially to guarantee accommodating producer requests that cannot wait. - SPSC, SPMC, MPSC, MPMC variants. - Blocking and spinning-only variants. - Inter-operable non-waiting, timed until, timed for, and waiting variants of producer and consumer operations. - Optional variable element weights. |
DelayedDestruction | DelayedDestruction is a helper class to ensure objects are not deleted while they still have functions executing in a higher stack frame. |
DelayedDestructionBase | DelayedDestructionBase is a helper class to ensure objects are not deleted while they still have functions executing in a higher stack frame. |
DelayedInit | DelayedInit -- thread-safe delayed initialization of a value. There are two important differences between Lazy and DelayedInit: 1. DelayedInit does not store the factory function inline. 2. DelayedInit is thread-safe. |
DerivedNodeTraits | Node traits for types that derive from IntrusiveHeapNode. |
DestructorCheck | DestructorCheck is a helper class that helps to detect if a tracked object was deleted. This is useful for objects that request callbacks from other components. |
DetachFdState | |
DigestBuilder | Stat digests, such as TDigest, can be expensive to merge. It is faster to buffer writes and merge them in larger chunks. DigestBuilder buffers writes to improve performance. |
DiscriminatedPtr | Discriminated pointer. |
DrivableExecutor | An executor that can be driven forward via its drive() method. |
DynamicBoundedQueue | A bounded, FIFO, multi-producer multi-consumer queue with adjustable capacity and dynamic memory usage. |
DynamicConstructor | Each specialization of DynamicConstructor has the function 'static dynamic construct(const C&);' |
DynamicConverter | Each specialization of DynamicConverter has the function 'static T convert(const dynamic&);' |
DynamicParser | A small DSL for losslessly parsing a folly::dynamic into another representation while recording any parts that cause errors. |
DynamicParserLogicError | When DynamicParser is used incorrectly, it will throw this exception instead of reporting an error via releaseErrors(). It is unsafe to call any parser methods after catching a LogicError. |
DynamicParserParseError | With DynamicParser::OnError::THROW, reports the first error. It is forbidden to call releaseErrors() if you catch this. |
DynamicRingQueue | A ring buffer queue backed by a power-of-two sized array that grows on overflow. Not thread-safe. |
EDFThreadPoolExecutor | DEPRECATED: use folly::StripedEDFThreadPoolExecutor directly. This wrapper exists only for legacy callers. |
ElfHwCaps | Identification of hardware capabilities via the ELF auxiliary vector. |
EnablePrimaryFromThis | EnablePrimaryFromThis provides an object with appropriate access to the functionality of the PrimaryPtr holding this. |
Endian | Converts integral and floating point values between native, big-endian, and little-endian byte orders. |
EpollBackend | |
EventBase | An event loop that drives asynchronous I/O and timers. |
EventBaseAtomicNotificationQueue | Lock-free notification queue of tasks consumed by a single consumer. |
EventBaseBackendBase | Abstract base for the backend that drives an EventBase loop. |
EventBaseEvent | Wrapper around a libevent event owned by an EventBase backend. |
EventBaseLocal | Storage for data tied to the lifetime of an EventBase. |
EventBaseManager | Manager for per-thread EventBase objects. This class will find or create a EventBase for the current thread, associated with thread-specific storage for that thread. Although a typical application will generally only have one EventBaseManager, there is no restriction on multiple instances; the EventBases belong to one instance are isolated from those of another. |
EventBaseObserver | Observer interface that samples EventBase loop activity. |
EventBaseThread | Owns an EventBase running on its own thread. |
EventBaseThreadTimekeeper | A Timekeeper that schedules timeouts on an externally supplied EventBase. |
EventCount | Event count: a condition variable for lock free algorithms. |
EventHandler | The EventHandler class is used to asynchronously wait for events on a file descriptor. |
EventUtil | low-level libevent utility functions |
EvictingCacheMap | A general purpose LRU evicting cache designed to support constant time set/get/insert/erase ops. The only required configuration parameter is the maxSize, which is the maximum number of entries held by the cache, which is also dynamically changeable. Insertion will evict (and destroy with ~TKey and ~TValue) existing entries in LRU order as needed to keep number of entries less than maxSize. When automatic eviction is triggered, the minimum number of evictions is clearSize, which is configurable with a default of 1. If a callback is specified with setPruneHook, it is invoked for each eviction. However, the prune hook cannot manage object lifetimes because it is not invoked on erase nor cache destruction. |
ExecutionObserver | Observes the execution of a task. Multiple execution observers can be chained together. As a caveat, execution observers should not remove themselves from the list of observers during execution |
ExecutionObserverScopeGuard | Notifies a list of execution observers around a scoped task execution. |
Executor | Schedules and runs asynchronous work. |
ExecutorBlockingContext | Records whether blocking is forbidden while an executor is running work. |
ExecutorBlockingGuard | Scoped guard that pushes an executor blocking context for its lifetime. |
ExecutorBlockingList | A node in the thread-local stack of executor blocking contexts. |
ExecutorKeepAlive | ExecutorKeepAlive is a safe pointer to an Executor. |
ExecutorWithPriority | Wraps an executor so that submitted tasks run at a chosen priority. |
Expected | Forward declarations |
F14FastMap | F14 hash map that selects a value or vector layout based on entry size. |
F14FastSet | F14 hash set that selects a value or vector layout based on element size. |
F14HashToken | An opaque token holding the precomputed hash of a key. |
F14HashedKey | A key paired with its precomputed F14 hash token for faster lookups. |
F14NodeMap | F14 hash map that stores each entry in a separately allocated node. |
F14NodeSet | F14 hash set that stores each element in a separately allocated node. |
F14TableStats | Diagnostic statistics describing the internal state of an F14 table. |
F14ValueMap | F14 hash map that stores entries inline in the main array. |
F14ValueSet | F14 hash set that stores elements inline in the main array. |
F14ValueSetTester | Test-only accessor granting inspection of F14ValueSet internals. |
F14VectorMap | F14 hash map that keeps entries in a dense, index-addressable vector. |
F14VectorSet | F14 hash set that keeps elements in a dense, index-addressable vector. |
FallbackGetcpu | A class that lazily binds a unique (for each implementation of Atom) identifier to a thread. This is a fallback mechanism for the access spreader if __vdso_getcpu can't be loaded |
FiberIOExecutor | An IOExecutor that executes funcs under mapped fiber context |
File | A File represents an open file. |
FileHandlerFactory | FileHandlerFactory is a LogHandlerFactory that constructs log handlers that write to a file. |
FileWriterFactory | A helper class for creating an AsyncFileWriter or ImmediateFileWriter based on log handler options settings. |
Fingerprint | Compute the Rabin fingerprint. |
FixedAlign | An alignment policy that carries a compile-time alignment value. |
FixedCapacityRingQueue | A simple fixed-capacity ring buffer queue backed by a power-of-two sized array. Not thread-safe. |
FlatCombining | - A simple interface that requires minimal extra code by the user. To use this interface efficiently the user-provided functions must be copyable to folly::Function without dynamic allocation. If this is impossible or inconvenient, the user is encouraged to use the custom interface described below. - A custom interface that supports custom combining and custom request structure, either for the sake of smart combining or for efficiently supporting operations that are not be copyable to folly::Function without dynamic allocation. - Both synchronous and asynchronous operations. - Request records with and without thread-caching. - Combining with and without a dedicated combiner thread. |
FlatCombiningPriorityQueue | Thread-safe priority queue based on flat combining. If the constructor parameter maxSize is greater than 0 (default = 0), then the queue is bounded. This template provides blocking, non-blocking, and timed variants of each of push(), pop(), and peek() operations. The empty() and size() functions are inherently non-blocking. |
FormatArg | Parsed format argument. |
FormatKeyNotFoundException | Exception class thrown when a format key is not found in the given associative container keyed by strings. We inherit std::out_of_range for compatibility with callers that expect exception to be thrown directly by std::map or std::unordered_map. |
FormatValue | Customization point for formatting a value of type T. |
Formatter | Binds a format string to its arguments for deferred formatting. |
Function | A polymorphic, move-only wrapper for any callable of a given signature. |
FunctionRef | A reference wrapper for callable objects |
FunctionScheduler | Schedules any number of functions to run at various intervals. E.g., |
FutureExecutor | Executor wrapper that adds future-returning task submission. |
FutureSplitter | FutureSplitter provides a `getFuture()' method which can be called multiple times, returning a new Future each time. These futures are completed when the original Future passed to the FutureSplitter constructor is completed, and are completed on the same executor (if any) and at the same priority as the original Future. Calls to `getFuture()' after that time return a completed Future. |
FutureSplitterInvalid | Exception thrown when a FutureSplitter holds no Future. |
GenerationalCacheMap | A concurrent, bounded, approximately-LRU cache with lock-free lookups. |
GetThreadIdCollector | Interface for executors that provide a WorkerProvider to collect thread ids. |
Getcpu | Knows how to derive a function pointer to the VDSO implementation of getcpu(2), if available |
GlobalCPUExecutorCounters | Load counters for the global immutable CPU executor. |
GlogStyleFormatter | A LogFormatter implementation that produces messages in a format similar to that produced by the Google logging library. |
GoogleLogger | The default AutoTimer logger, which writes timing messages via glog. |
GroupVarint | Group varint encoder/decoder for 32- or 64-bit integers. |
GroupVarintDecoder | Simplify use of GroupVarint* for the case where the last group in the input may be incomplete (but the exact size of the input is known). Allows for extracting values one at a time. |
GroupVarintEncoder | Simplify use of GroupVarint* for the case where data is available one entry at a time (instead of one group at a time). Handles buffering and an incomplete last chunk. |
HHWheelTimerBase | Hashed Hierarchical Wheel Timer |
Hash | Generic variadic hasher that dispatches to folly::hasher for each argument. |
HashingThreadId | Assigns thread ids by hashing the platform thread identifier. |
HazptrLockFreeLIFO | A lock-free LIFO stack that reclaims popped nodes with hazard pointers. |
HazptrSWMRSet | Set implemented as an ordered singly-linked list. |
HazptrWideCAS | Wide CAS. |
HeapTimekeeper | A Timekeeper with a dedicated thread that manages the timeouts using a heap. Timeouts can be scheduled with microsecond resolution, though in practice the accuracy depends on the OS scheduler's ability to wake up the worker thread in a timely fashion. |
HeterogeneousAccessEqualTo | Equality comparator that enables heterogeneous lookup for key type T. |
HeterogeneousAccessHash | Hasher that enables heterogeneous lookup for key type T. |
HeterogeneousPreHashCompatible | Trait that is true when two hashers agree on prehash values. |
Histogram | A basic histogram class. |
HugePageSize | A supported huge page size and its mount point. |
IOBuf | IOBuf manages heap-allocated byte buffers. |
IOBufCompare | Ordering for IOBuf objects. Compares data in the entire chain. |
IOBufEqualTo | Equality predicate for IOBuf objects. Compares data in the entire chain. |
IOBufGreater | Greater predicate for IOBuf objects. Compares data in the entire chain. |
IOBufGreaterEqual | At-least predicate for IOBuf objects. Compares data in the entire chain. |
IOBufHash | Hasher for IOBuf objects. Hashes the entire chain using SpookyHashV2. |
IOBufIovecBuilder | IOBufIovecBuilder exists to help allocate and fill IOBuf chains using iovec-based scatter/gather APIs. |
IOBufLess | Less predicate for IOBuf objects. Compares data in the entire chain. |
IOBufLessEqual | At-most predicate for IOBuf objects. Compares data in the entire chain. |
IOBufNotEqualTo | Inequality predicate for IOBuf objects. Compares data in the entire chain. |
IOBufQueue | An IOBufQueue encapsulates a chain of IOBufs and provides convenience functions to append data to the back of the chain and remove data from the front. |
IOExecutor | An executor backed by an I/O event loop. |
IOObjectCache | Caches objects of type T that are bound to an EventBase from the global IOExecutor. |
IOThreadPoolDeadlockDetectorObserver | Observer that attaches a deadlock detector to each event base of an IO thread pool. |
IOThreadPoolExecutor | A Thread Pool for IO bound tasks |
IOThreadPoolExecutorBase | Base interface for executors that run tasks on IO threads with EventBases. |
IPAddress | A representation of an IP address (IPv4 or IPv6). |
IPAddressFormatException | Exception that is thrown when dealing with invalid IP addresses. A subclass of std::runtime_error |
IPAddressV4 | A representation of an IPv4 address. |
IPAddressV6 | A representation of an IPv6 address. |
Ignore | A type that is implicitly constructible from and assignable by anything. |
ImmediateFileWriter | A LogWriter implementation that immediately writes to a file descriptor when it is invoked. |
ImmutableRequestData | ImmutableRequestData is a folly::RequestData that holds an immutable value. It is thread-safe (a requirement of RequestData) because it is immutable. |
ImplicitSynchronized [deprecated] | Deprecated subclass of Synchronized that provides implicit locking via operator->. This is intended to ease migration while preventing accidental use of operator-> in new code. |
ImplicitlyWeightedEvictingCacheMap | A variant of EvictingCacheMap that assigns weights to entries and evicts entries in LRU order to ensure the total weight of all entries stays below some set maximum. ImplicitlyWeighted means this variant derives the weights from the key-values using a chosen function. TWeightFn must be a type implementing size_t operator()(const TKey&, const Tvalue&) |
Indestructible | Wraps an inline object that is never destructed, for Meyers singletons. |
IndexedMemPool | Instances of IndexedMemPool dynamically allocate and then pool their element type (T), returning 4-byte integer indices that can be passed to the pool's operator[]method to access or obtain pointers to the actual elements. The memory backing items returned from the pool will always be readable, even if items have been returned to the pool. These two features are useful for lock-free algorithms. The indexing behavior makes it easy to build tagged pointer-like-things, since a large number of elements can be managed using fewer bits than a full pointer. The access-after-free behavior makes it safe to read from T-s even after they have been recycled, since it is guaranteed that the memory won't have been returned to the OS and unmapped (the algorithm must still use a mechanism to validate that the read was correct, but it doesn't have to worry about page faults), and if the elements use internal sequence numbers it can be guaranteed that there won't be an ABA match due to the element being overwritten with a different type that has the same bit pattern. |
IndexedMemPoolTraits | A Traits type that controls the object lifecycle strategy of an IndexedMemPool. |
Init | RAII object constructed at the beginning of main() and destructed implicitly at the end of main(). |
InitOptions | Options controlling folly initialization. |
InitThreadFactory | A thread factory that runs setup and teardown callbacks around each thread. |
InlineExecutor | When work is "queued", execute it immediately inline. Usually when you think you want this, you actually want a QueuedImmediateExecutor. |
InlineLikeExecutor | Base class for executors that run queued work inline. |
IntrusiveHeap | IntrusiveHeap implements a skew heap with intrusive pointers to provide O(log(n)) operations on any node in the heap with no separately allocated node type. |
IntrusiveHeapNode | Base class for items to be inserted into IntrusiveHeap<..., Tag> storing pointers for internal use. |
IntrusiveHeapTest | Test fixture granted access to node internals. |
InvalidAddressFamilyException | Exception that is thrown when an IP Address is not of the family expected (ie, expected a V4 but is a V6). A subclass of IPAddressFormatException. |
IoSqeBase | Base class for an io_uring submission queue entry managed by Folly. |
IoUringArena | A memory arena registered with the kernel for io_uring operations. |
IoUringBackend | The io_uring-based EventBase backend. |
IoUringBufferProvider | |
IoUringConnectCallback | Receives notifications about the outcome of an io_uring connect operation. |
IoUringConnectHandle | Performs an asynchronous connect over an io_uring-backed socket. |
IoUringDynamicProvidedBufferRing | |
IoUringDynamicProvidedBufferRingTestHelper | |
IoUringFdRegistrationRecord | Tracks a file descriptor registered with an io_uring ring. |
IoUringOp | A pending operation backed by the Linux io_uring interface. |
IoUringOptions | |
IoUringProvidedBufferRing | |
IoUringProvidedBufferRingTestHelper | |
IoUringRecvCallback | Receives notifications about the progress of an io_uring receive operation. |
IoUringRecvHandle | Manages inbound receives over an io_uring-backed socket. |
IoUringSendCallback | Receives notifications about the progress of an io_uring send operation. |
IoUringSendHandle | Manages a single outbound send over an io_uring-backed socket. |
IoUringZeroCopyBufferPool | |
IoUringZeroCopyBufferPoolImpl | |
IoUringZeroCopyBufferPoolTestHelper | |
IsAvalanchingHasher | Trait: true when hasher Hasher avalanches input entropy across every bit of the hash of key Key. |
IsConvertible | Trait detecting whether a type can be a split() output field. |
IsRelocatable | A trait describing whether a value of type T can be relocated with memcpy. |
IsSomeString | Trait that identifies string-like types such as std::string and fbstring. |
IsZeroInitializable | A trait describing whether value-initialization equals zero-filling memory. |
JemallocHugePageAllocator | An allocator which uses Jemalloc to create a dedicated huge page arena, backed by 2MB huge pages (on linux x86-64). |
JemallocNodumpAllocator | An allocator which uses Jemalloc to create an dedicated arena to allocate memory from. The only special property set on the allocated memory is that the memory is not dump-able. |
LLCAccessSpreader | Similar to AccessSpreader, but it has exactly one stripe for each last-level cache that is accessible by the current process. |
Latch | Example: |
LeakySingleton | A singleton whose instance is intentionally never destroyed. |
LegacyStatsClock | A helper clock type to helper older code using BucketedTimeSeries with std::chrono::seconds transition to properly using clock types and time_point objects. |
LifoSemImpl | Concrete LIFO semaphore parameterized by its baton and atomic types. |
LifoSemMPMCQueue | A blocking multi-producer, multi-consumer queue backed by a LIFO semaphore. |
LockFreeRingBuffer | LockFreeRingBuffer<T> is a fixed-size, concurrent ring buffer with the following semantics: |
LockedPtr | A LockedPtr keeps a Synchronized<T> object locked for the duration of LockedPtr's existence. |
LockedPtrBase | Base class that owns the lock held by a LockedPtr. |
LogCategory | LogCategory stores all of the logging configuration for a specific log category. |
LogCategoryConfig | Configuration for a LogCategory |
LogConfig | Configuration describing log categories and handlers. |
LogConfigParseError | Exception thrown when a log configuration string cannot be parsed. |
LogFormatter | LogFormatter defines the interface for serializing a LogMessage object into a buffer to be given to a LogWriter. |
LogHandler | Consumes and processes log messages. |
LogHandlerConfig | Configuration for a LogHandler |
LogHandlerFactory | Interface for factories that construct log handlers from config options. |
LogMessage | LogMessage represents a single message to be logged. |
LogName | The LogName class contains utility functions for processing log category names. It primarily handles canonicalization of names. |
LogStream | A std::ostream implementation for use by the logging macros. |
LogStreamBuffer | A std::streambuf implementation for use by LogStream |
LogStreamProcessor | LogStreamProcessor receives a LogStream and logs it. |
LogStreamVoidify | LogStreamVoidify() is a helper class used in the FB_LOG() and XLOG() macros. |
LogWriter | Writes serialized log messages to an output. |
Logger | Logger is the class you will use to specify the log category when logging messages with FB_LOG(). |
LoggerDB | LoggerDB stores the set of LogCategory objects. |
MPMCPipeline | A multi-producer, multi-consumer pipeline of processing stages. |
MPMCPipelineStage | Describes a pipeline stage carrying element type T with amplification Amp. |
MPMCQueue | MPMCQueue<T> is a high-performance bounded concurrent queue that supports multiple producers, multiple consumers, and optional blocking. The queue has a fixed capacity, for which all memory will be allocated up front. The bulk of the work of enqueuing and dequeuing can be performed in parallel. |
MacAddress | A 48-bit ethernet MAC address. |
MallctlMibCallCache | Caches the resolved MIB for a mallctl command that neither reads nor writes a value, for repeated fast invocation. |
MallctlMibReadCache | Caches the resolved MIB for a mallctl command that reads a value, for repeated fast invocation. |
MallctlMibReadWriteCache | Caches the resolved MIB for a mallctl command that writes a value and reads the previous one, for repeated fast invocation. |
MallctlMibWriteCache | Caches the resolved MIB for a mallctl command that writes a value, for repeated fast invocation. |
ManualExecutor | A ManualExecutor only does work when you turn the crank, by calling run() or indirectly with makeProgress() or waitFor(). |
ManualTimekeeper | Manually controlled Timekeeper for unit testing. |
MaybeManagedPtr | MaybeManagedPtr stores either a raw pointer or a shared_ptr. It provides normal pointer operations on the underlying raw pointer/shared_ptr. |
MemberNodeTraits | Node traits for types that hold an IntrusiveHeapNode member. |
MemoryMapping | Maps files in memory (read-only). |
MicroLockBase | A tiny one-byte spinlock with a configurable spin and yield budget. |
MicroLockCore | Base class holding the lock byte and the bit-packing helpers shared by every MicroLock specialization. |
MicroSpinLock | A really, really small spinlock for fine-grained locking of lots of teeny-tiny data. |
MoveWrapper | C++11 closures don't support move-in capture. Nor does std::bind. facepalm. |
MultiLevelTimeSeries | This class represents a timeseries which keeps several levels of data granularity (similar in principle to the loads reported by the UNIX 'uptime' command). It uses several instances (one per level) of BucketedTimeSeries as the underlying storage. |
MultiSlidingWindowQuantileEstimator | Equivalent to (but more efficient than) a SimpleQuantileEstimator plus one SlidingWindowQuantileEstimator for each requested window. |
MutableAtom | MutableAtom is a tiny wrapper that gives you the option of atomically updating values inserted into an AtomicUnorderedInsertMap<K, MutableAtom<V>>. This relies on AtomicUnorderedInsertMap's guarantee that it doesn't move values. |
MutableData | MutableData is a tiny wrapper that gives you the option of using an external concurrency control mechanism to updating values inserted into an AtomicUnorderedInsertMap. |
MuxIOThreadPoolExecutor | NOTE: This is highly experimental. Do not use. |
NamedThreadFactory | A ThreadFactory that names each thread it creates. |
NativeSemaphore | A thin wrapper over the platform's native counting semaphore. |
NestedCommandLineApp | App that uses a nested command line, of the form: |
NestedCommandLineParseResult | Result of parsing a nested command line. |
NetworkSocket | NetworkSocket is just a very thin wrapper around either a file descriptor or a SOCKET depending on platform, along with a couple of helper methods for explicitly converting to/from file descriptors, even on Windows. |
None | Tag type used to construct an empty Optional, akin to std::nullopt_t. |
NotificationQueue | Queue used to deliver messages to an EventBase thread. |
ObserverContainer | Policy-based implementation of ObserverContainerBase. |
ObserverContainerBase | Base ObserverContainer and definition of Observers. |
ObserverContainerBasePolicyDefault | Policy for ObserverContainerBase. |
ObserverContainerStore | Policy-based implementation of ObserverContainerStoreBase. |
ObserverContainerStoreBase | Interface for store of pointers to observers. |
ObserverContainerStorePolicyDefault | Policy for ObserverContainerStore. |
OpenSSLTicketHandler | Handler for OpenSSL session tickets. |
OpenSSLTransportCertificate | Generic interface applications may implement to convey self or peer certificate related information. |
OperationCancelled | IMPORTANT: folly-internal, do NOT use this in new user code. Instead: |
Optional | Optional is superseded by std::optional. Now that the C++ has a standardized implementation, Optional exists primarily for backward compatibility. |
OptionalEmptyException | Exception thrown when unwrapping the value of an empty Optional. |
PackedSyncPtr | An 8-byte pointer with an integrated spin lock and 15-bit integer. |
ParkingLot | A portable, futex-like waiter registry keyed by address. |
PasswordInFile | Password collector that reads a passphrase from a file on construction. |
PicoSpinLock | Spin lock on a single bit in an integral type. You can use this with 16, 32, or 64-bit integral types. |
Poly | Poly is a class template that makes it relatively easy to define a type-erasing polymorphic object wrapper. |
PolyExtends | Used in the definition of a Poly interface to say that the current interface is an extension of a set of zero or more interfaces. |
PolyMembers | A list of member pointers describing a Poly interface. |
PolySelf_ | Helper that computes the self type of a Poly interface node. |
PredefinedQuantiles | Predefined sets of quantiles for use with QuantileHistogram. |
PrimaryPtr | PrimaryPtr should be used to achieve deterministic destruction of objects with shared ownership. Once an object is managed by a PrimaryPtr, shared_ptrs can be obtained pointing to that object. However destroying those shared_ptrs will never call the object destructor inline. To destroy the object, join() method must be called on PrimaryPtr or the task returned from cleanup() must be completed, which will wait for all shared_ptrs to be released and then call the object destructor on the caller supplied execution context. |
PrimaryPtrRef | PrimaryPtrRef is a non-owning reference to the pointer. PrimaryPtr::join() and the PrimaryPtr::cleanup() work do NOT wait for outstanding PrimaryPtrRef objects to be released. |
PriorityLifoSemMPMCQueue | A blocking queue with priority levels backed by per-priority MPMC queues and a LIFO semaphore. |
PriorityThreadFactory | A ThreadFactory that sets nice values for each thread. The main use case for this class is if there are multiple CPUThreadPoolExecutors in a single process, or between multiple processes, where some should have a higher priority than the others. |
PriorityUnboundedBlockingQueue | A blocking queue with a fixed number of priority levels. |
PriorityUnboundedQueueSet | PriorityUnboundedQueueSet |
ProcessReturnCode | Class to wrap a process return code. |
ProducerConsumerQueue | A single-producer, single-consumer, lock-free bounded queue. |
ProgramExit | Exception that commands may throw to force the program to exit cleanly with a given exit code. NestedCommandLineApp::run() catches this and makes run() print the given message on stderr (followed by a newline, unless empty; the message is only allowed when exiting with a non-zero status), and return the exit code. (Other exceptions will propagate out of run()) |
QuantileEstimates | Summary statistics and quantile estimates produced by a QuantileEstimator. |
QuantileHistogram [deprecated] | A histogram that tracks the locations of a fixed set of quantiles. |
QueueFullException | Exception thrown when adding to a full queue that uses THROW behavior. |
QueueInfo | Aggregates the worker thread ids per queue name along with their keep-alives. |
QueueObserver | Observes enqueue and dequeue events on a queue. |
QueueObserverFactory | Factory that creates QueueObserver instances for a queue. |
QueuedImmediateExecutor | Runs inline like InlineExecutor, but with a queue so that any tasks added to this executor by one of its own callbacks will be queued instead of executed inline (nested). This is usually better behavior than Inline. |
RWSpinLock | A simple, small (4-bytes), but unfair rwlock. Use it when you want a nice writer and don't expect a lot of write/read contention, or when you need small rwlocks since you are creating a large number of them. |
Random | Provides static random number generation utilities. |
Range | A lightweight, non-owning view over a range of elements. |
ReadMostlyMainPtr | Owning pointer that gives cheap, lock-free reads to shared objects. |
ReadMostlyMainPtrDeleter | This can be used to destroy multiple ReadMostlyMainPtrs at once. |
ReadMostlySharedPtr | Shared reader handle to a read-mostly managed object. |
ReadMostlyWeakPtr | Non-owning weak reference to a read-mostly managed object. |
ReadSqe | |
RecordIOReader | Class to read from a RecordIO file. Will skip invalid records. |
RecordIOWriter | Class to write a stream of RecordIO records to a file. |
RegexMatchCache | RegexMatchCache |
RegexMatchCacheDynamicBitset | RegexMatchCacheDynamicBitset |
RegexMatchCacheIndexedVector | RegexMatchCacheIndexedVector |
RegexMatchCacheKey | RegexMatchCacheKey |
RegexMatchCacheKeyAndView | RegexMatchCacheKeyAndView |
RelaxedConcurrentPriorityQueue | A fast, scalable, relaxed concurrent priority queue. |
Replaceable | Wraps a T that can be replaced in place without allocation or indirection. |
RequestContext | Per-request context associated with an enqueued item. |
RequestContextSaverScopeGuard | RequestContextSaverScopeGuard allows to replace the current context without switching back to original context, while ensuring that the original context is restored on guard destruction. |
RequestContextScopeGuard | Note: you probably want to use ShallowCopyRequestContextScopeGuard This resets all other RequestData for the duration of the scope! |
RequestData | Base class for data that follows an async request through a process. |
RequestEventBase | Sets and retrieves the EventBase associated with a request via RequestContext. |
RequestToken | A token used to fetch data from a RequestContext. |
SSLAcceptRunner | Run SSL_accept via a runner |
SSLContext | Wrap OpenSSL SSL_CTX into a class. |
SSLException | Exception describing an SSL error and its underlying OpenSSL code. |
STTimerFDTimeoutManager | A TimeoutManager backed by a TimerFD that tracks a single timeout. |
SaturatingSemaphore | SaturatingSemaphore is a flag that allows concurrent posting by multiple posters and concurrent non-destructive waiting by multiple waiters. |
ScheduledExecutor | An executor that supports timed scheduling. Like RxScheduler. |
ScopedEventBaseThread | Helper that runs an EventBase loop on a dedicated std::thread. |
ScopedUnlocker | This class temporarily unlocks a LockedPtr in a scoped manner. |
SequencedExecutor | An executor that sequences tasks whose submissions were sequenced. |
SequentialThreadId | Assigns thread ids from a monotonically increasing counter. |
SerializedExecutor | A sequenced executor that never runs its tasks concurrently. |
ShallowCopyRequestContextScopeGuard | This guard maintains all the RequestData pointers of the parent. This allows to overwrite a specific RequestData pointer for the scope's duration, without breaking others. |
SharedMutexImpl | A small, fast, scalable reader-writer lock. |
SharedMutexPolicyDefault | Default tuning and feature policy for SharedMutexImpl. |
SharedMutexToken | Records where a shared lock was recorded so it can be released quickly. |
SharedPromise | SharedPromise provides the same interface as Promise, but you can extract multiple Futures from it, i.e. you can call getFuture() as many times as you'd like. When the SharedPromise is fulfilled, all of the Futures are completed. Calls to getFuture() after the SharedPromise is fulfilled return a completed Future. If you find yourself constructing collections of Promises and fulfilling them simultaneously with the same value, consider this utility instead. Likewise, if you find yourself in need of setting multiple callbacks on the same Future (which is indefinitely unsupported), consider refactoring to use SharedPromise to "split" the Future. |
ShutdownSemError | The exception thrown when wait()ing on an isShutdown() LifoSem |
ShutdownSocketSet | Set of sockets that allows immediate, take-no-prisoners abort. |
SimpleAsyncIO | SimpleAsyncIO is a wrapper around AsyncIO intended to hide all the details. |
SimpleQuantileEstimator | A QuantileEstimator that buffers writes for 1 second. |
SingleWriterFixedHashMap | SingleWriterFixedHashMap: |
Singleton | Singleton allows for simple access to registering and instantiating singletons. Create instances of this class in the global scope of type Singleton<T> to register your singleton for later access via Singleton<T>::try_get(). |
SingletonRelaxedCountable | A CRTP base class that keeps a global count of instances of a type. |
SingletonRelaxedCountableAccess | Provides access to the running instance count of a countable type. |
SingletonRelaxedCounter | A singleton-per-tag relaxed counter. |
SingletonThreadLocal | SingletonThreadLocal |
SingletonVault | SingletonVault - a library to manage the creation and destruction of interdependent singletons. |
SlidingWindowQuantileEstimator | A QuantileEstimator that keeps values for nWindows * windowDuration (see constructor). Values are buffered for windowDuration. |
SocketAddress | Provides a unified interface for socket addresses. |
SocketFds | Represents an ordered collection of file descriptors. This union type either contains: - FDs to be sent on a socket -- with shared ownership, since the sender may still need them, OR - FDs just received, with sole ownership. |
SocketOptionKey | Uniquely identifies a handle to a socket option value. Each combination of level and option name corresponds to one socket option value. |
SocketOptionValue | Variant container for socket option values: integer or string. Implicit ctor/compares with int for backward compatibility. |
SoftRealTimeExecutor | Executor that performs priority-based scheduling with a deadline assigned to each task. |
SparseByteSet | * SparseByteSet |
SpinLock | A small, non-recursive spin lock with a standard lock interface. |
SpinLockArray | Array of spinlocks where each one is padded to prevent false sharing. Useful for shard-based locking implementations in environments where contention is unlikely. |
SplitOptions | SplitOptions |
StandardLogHandler | StandardLogHandler is a LogHandler implementation that uses a LogFormatter class to serialize the LogMessage into a string, and then gives it to a LogWriter object. |
StandardLogHandlerFactory | StandardLogHandlerFactory contains helper methods for LogHandlerFactory implementations that create StandardLogHandler objects. |
StaticConst | A template for defining ODR-usable constexpr instances, free of ODR and init-order problems. |
StrandContext | Shared serialising queue used by StrandExecutors to run at most one task at a time. |
StrandExecutor | Executor that serialises work while delegating execution to a parent executor, sharing a StrandContext to serialise across executors. |
StreamHandlerFactory | StreamHandlerFactory is a LogHandlerFactory that constructs log handlers that write to stdout or stderr. |
StreamingStats | Robust and efficient online computation of statistics, using Welford's method for variance. https://en.wikipedia.org/wiki/Algorithms_for_calculating_variance#Welford's_online_algorithm |
StrictConjunction | A logical conjunction of traits that evaluates all sub-conditions eagerly. |
StrictDisjunction | A logical disjunction of traits that evaluates all sub-conditions eagerly. |
StripedEDFThreadPoolExecutor | An approximate implementation of an Earliest Deadline First executor. |
StripedPriorityUnboundedBlockingQueue | A BlockingQueue sharded by LLC cache. Compared to the default PriorityUnboundedBlockingQueue, this can reduce contention on systems with a large number of LLC caches, at the cost of unfairness and work conservation; see the StripedThrottledLifoSem documentation for a detailed explanation. |
StripedThrottledLifoSem | A striped version of ThrottledLifoSem. |
StripedThrottledLifoSemBalancer | Background balancer that periodically corrects stripe imbalances. |
Subprocess | Subprocess. |
SubprocessError | Base exception thrown by the Subprocess methods. |
SubprocessSpawnError | Exception thrown if the subprocess cannot be started. |
SubstringConversionCode | Error type for trySplitTo(), below. |
Synchronized | folly::Synchronized pairs a datum with a mutex. The datum can only be reached through a LockedPtr, typically acquired via .rlock() or .wlock(); the mutex is held for the lifetime of the LockedPtr. |
SynchronizedBase | SynchronizedBase is a helper parent class for Synchronized<T>. |
SynchronizedPtr | A Synchronized variant that protects a pointed-to object. |
SynchronizedPtrLockedElement | Holds a lock together with access to the element it protects. |
SysAllocator | SysAllocator |
SysArena | Arena that uses the system allocator (malloc / free) |
SysBufferDeleter | Deleter that releases memory with std::free. |
TDigest | TDigests are a biased quantile estimator designed to estimate the values of the quantiles of streaming data with high accuracy and low memory, particularly for quantiles at the tails (p0.1, p1, p99, p99.9). See https://github.com/tdunning/t-digest/blob/master/docs/t-digest-paper/histo.pdf for an explanation of what the purpose of TDigests is, and how they work. |
TLRefCount | A reference counter that keeps per-thread counts to avoid contention. |
TcpInfo | Abstraction layer for capturing current TCP and congestion control state. |
TcpInfoDispatcher | Dispatcher that enables calls to TcpInfo to be intercepted for tests. |
TcpInfoDispatcherContainer | Container for folly::TcpInfoDispatcher. |
ThreadCachedArena | Thread-caching arena: allocate memory which gets freed when the arena gets destroyed. |
ThreadCachedInt | A thread-safe counter that caches increments in thread-local storage. |
ThreadFactory | Interface for creating threads used by executors. |
ThreadIdWorkerProvider | WorkerProvider backed by an explicitly maintained set of thread ids. |
ThreadLocal | Thread-local storage for a value of type T. |
ThreadLocalPRNG | A PRNG with one instance per thread. This PRNG uses a mersenne twister random number generator and is seeded from /dev/urandom. It should not be used for anything which requires security, only for statistical randomness. |
ThreadLocalPtr | Thread-local owning pointer to a value of type T. |
ThreadPoolExecutor | Base class for implementing threadpool based executors. |
ThreadPoolListHook | A hook for tracking which threads belong to which thread pools. This is used only by a gdb extension to aid in debugging. You won't be able to see any useful information from within C++ code. |
ThreadWheelTimekeeper | The default Timekeeper implementation which uses a HHWheelTimer on an EventBase in a dedicated thread. Users needn't deal with this directly, it is used by default by Future methods that work with timeouts. |
ThreadedExecutor | * ThreadedExecutor |
ThreadedRepeatingFunctionRunner | For each function fn you add to this object, fn will be run in a loop in its own thread, with the thread sleeping between invocations of fn for the duration returned by fn's previous run. |
ThrottledLifoSem | ThrottledLifoSem is a semaphore that can wait up to a configurable wakeUpInterval before waking up a sleeping waiter. This gives an opportunity to new waiters to consume the posted values, avoiding the overhead of waking up a thread when the already active threads can consume values fast enough, effectively allowing to batch the work. The semaphore is "throttled" because sleeping waiters can be awoken at most once every wakeUpInterval. |
TimedDrivableExecutor | A DrivableExecutor can be driven via its drive() method or its driveUntil() that drives until some time point. |
TimekeeperScheduledExecutor | This class turns a Executor into a ScheduledExecutor. |
TimekeeperScheduledExecutorNoTimekeeper | Exception thrown when no timekeeper is available for scheduling. |
TimeoutManager | Base interface to be implemented by all classes expecting to manage timeouts. AsyncTimeout will use implementations of this interface to schedule/cancel timeouts. |
TimeoutQueue | A queue of scheduled timeout events keyed by expiration time. |
TimerFD | |
TimerFDTimeoutManager | Manages many timeouts on a single TimerFD. |
TimeseriesHistogram | TimeseriesHistogram tracks data distributions as they change over time. |
TokenBucketPolicyDefault | Default policy for the token bucket templates, selecting the alignment, atomic type, clock, and concurrency behavior. |
TokenBucketStorage | Thread-safe (atomic) token bucket primitive. |
TransparentStringEqualTo | Equality comparator for strings of CharT supporting transparent lookup. |
TransparentStringHash | Hasher for strings of CharT supporting transparent lookup. |
Try | A wrapper that contains either an instance of T, an exception, or nothing. |
TryException | Exception type thrown by Try when it is used incorrectly. |
TupleHasher | Recursively hashes tuple elements, combining them into a single hash. |
TypeError | Exception thrown when a dynamic is accessed as the wrong type. |
TypedIOBuf | Wrapper class to handle a IOBuf as a typed buffer (to a standard layout class). |
UTF8StringPiece | A view over a UTF-8 string that iterates it as UTF-32 code points. |
Unaligned | Representation of an unaligned value of a POD type. |
UnalignedNoASan | An Unaligned<T> variant whose loads and stores can have address sanitizer disabled on demand. |
UnboundedBlockingQueue | A blocking queue with unbounded capacity. |
UnboundedQueue | UnboundedQueue supports a variety of options for unbounded dynamically expanding an shrinking queues, including variations of: - Single vs. multiple producers - Single vs. multiple consumers - Blocking vs. spin-waiting - Non-waiting, timed, and waiting consumer operations. Producer operations never wait or fail (unless out-of-memory). |
Unexpected | Unexpected - a helper type used to disambiguate the construction of Expected objects in the error state. |
Unit | In functional programming, the degenerate case is often called "unit". In C++, "void" is often the best analogue. However, because of the syntactic special-casing required for void, it is frequently a liability for template metaprogramming. So, instead of writing specializations to handle cases like SomeContainer<void>, a library author may instead rule that out and simply have library users use SomeContainer<Unit>. Contained values may be ignored. Much easier. |
Uri | Class representing a URI. |
UserMetric | A single user-defined benchmark metric holding a value and its kind. |
UsingUninitializedTry | Exception thrown when an uninitialized Try is accessed. |
VirtualEventBase | Light-weight view onto an existing EventBase. |
VirtualExecutor | VirtualExecutor implements a light-weight view onto existing Executor. |
WTCallback | Callback object for HHWheelTimer that fulfills a future on timeout. |
WaitOptions | WaitOptions |
WeightedEvictingCacheMap | A variant of EvictingCacheMap that tracks weights for entries and evicts entries in LRU order to ensure the total weight of all entries stays below some set maximum. Weights are stored as a size_t with each entry. |
WorkerProvider | WorkerProvider is a simple interface that can be used to collect information about worker threads that are pulling work from a given queue. |
WriteCallbackWithState | Wrapper class for WriteCallback that includes a boolean variable to track whether the write has already started or not |
WriteChainAsyncTransportWrapper | Helper class that redirects write() and writev() calls to writeChain(). |
WriteFileAtomicOptions | Options controlling the behavior of writeFileAtomic(). |
WriteSqe | |
XlogCategoryInfo | Per-XLOG()-statement storage for the resolved log category. |
XlogFileScopeInfo | File-scope cache of the log level and category shared by a .cpp file. |
XlogLevelInfo | A file-static XlogLevelInfo and XlogCategoryInfo object is declared for each XLOG() statement. |
adopt_lock_state_t | Tag type indicating that a lock transition should adopt existing lock state. |
aligned | A wrapper that stores a value of type T with at least the given alignment. |
allocator_delete | allocator_delete |
annotate_ignore_thread_sanitizer_guard | Scoped guard that suppresses ThreadSanitizer reports within its lifetime. |
any_badge | For cases when multiple badge holders need to call a function we can use folly::any_badge over each individual holder allowed. We allow subsets of badges to lift into supersets: folly::any_badge lifts into folly::any_badge. |
asymmetric_thread_fence_traits | Traits providing the asymmetric fence callables for an atomic template. |
atomic_grow_array | atomic_grow_array |
atomic_grow_array_policy_default | atomic_grow_array_policy_default |
atomic_ref | A reference wrapper offering atomic operations on a non-atomic object. |
atomic_shared_ptr | Atomic wrapper around std::shared_ptr providing lock-free style operations. |
atomic_thread_fence_traits | Trait giving the thread-fence function for an atomic template. |
atomic_value_type | Trait giving the effective value type of an atomic-like type. |
badge | Badge pattern allows us to abstract over friend classes and make friend feature more scoped. Using this simple technique we can specify a badge tag on specific functions we want to gate for particular caller contexts (badge holders). Badge can only be constructed by the specified badge holder binding the tagged functions to that call site. |
base64_decode_error | Exception thrown when base64 decoding fails. |
base64_decode_result | Result of a low-level base64 decode operation. |
basic_cstring_view | cstring_view |
basic_fbstring | This is the basic_string replacement. For conformity, basic_fbstring takes the same template parameters, plus the last one which is the core. |
basic_once_flag | The flag template to be used with call_once. Parameterizable by the mutex type and atomic template. The mutex type is required to mimic std::mutex and the atomic type is required to mimic std::atomic. |
c_array | A container for C arrays, for returning non-zero-sized C arrays from constexpr functions. |
cacheline_align_t | An empty type aligned to cacheline_align_v. |
cli_apply_args_files_error | Exception thrown by the simple cli_apply_args_files overload. |
cli_apply_args_files_options | Options controlling args-file expansion. |
cli_apply_args_files_receiver | Callback interface receiving events while expanding args-files. |
coded_rich_error | Start with the user docs in docs/rich_error_code.md. |
compact_once_flag | An alternative flag that can be used with call_once that uses only 1 byte. Uses a 3-state std::atomic<uint8_t> with wait/notify for synchronization. |
compare_equal_to | Comparison predicate that is true when the underlying comparator C reports the two operands as equal. |
compare_greater | Comparison predicate that is true when the underlying comparator C reports the left operand as greater than the right operand. |
compare_greater_equal | Comparison predicate that is true when the underlying comparator C reports the left operand as greater than or equal to the right operand. |
compare_less | Comparison predicate that is true when the underlying comparator C reports the left operand as less than the right operand. |
compare_less_equal | Comparison predicate that is true when the underlying comparator C reports the left operand as less than or equal to the right operand. |
compare_not_equal_to | Comparison predicate that is true when the underlying comparator C reports the two operands as not equal. |
const_dynamic_view | /////////////////////////////////////////////////////////////////// |
constexpr_iterated_squares_desc | constexpr_iterated_squares_desc |
custom_stop_watch | Calculates the duration of time intervals. Prefer this over directly using monotonic clocks. It is very lightweight and provides convenient facilities to avoid common pitfalls. |
default_null_handler | Default policy handling null-pointer violations for not_null. |
drop_unit | Maps a type to itself, and maps Unit back to void. |
dummy_fbstring_core | Dummy fbstring core that uses an actual std::string. This doesn't make any sense - it's just for testing purposes. |
dynamic | Forward declaration of folly::dynamic used for serializing results. |
dynamic_view | A mutable view of a dynamic that can extract values without copying. |
emplace_args | Argument tuple for variadic emplace/constructor calls. Stores arguments by (decayed) value. Restores original argument types with reference qualifiers and adornments at unpack time to emulate perfect forwarding. |
empty_try_as_error_t | Empty-Try policy type that maps the empty state to an error result. |
empty_try_with | Empty-Try policy that produces a result by invoking a callable. |
epoll_event | |
error_or_stopped | Holds an error (std::exception_ptr) or a "stopped"/cancellation state. |
exception_shared_string | An immutable refcounted string suitable for use in an exception. |
exception_wrapper | Throwing exceptions can be a convenient way to handle errors. Storing exceptions in an exception_ptr makes it easy to handle exceptions in a different thread or at a later time. exception_ptr can also be used in a very generic result/exception wrapper. |
factory_constructor_t | Tag type selecting the factory constructor of Indestructible. |
fbstring_core | This is the core of the string. The code should work on 32- and 64-bit and both big- and little-endian architectures with any Char size. |
fbvector | Forward declaration of the fbvector container. |
floating_point_integral_constant | floating_point_integral_constant |
fmt_vformat_mangle_format_string_fn | fmt_vformat_mangle_format_string_fn fmt_vformat_mangle_format_string |
format_string_for_each_named_arg_fn | Callable that invokes a function for each named argument in a format string. |
function_like_value | Transports the cvref-qualifications of Src onto the function type Dst. |
function_remove_cvref | Yields the function type F stripped of its cvref-qualifications. |
function_traits | Discovers every fact of a function type S as types or constexpr values. |
get_exception_tag_t | get_exception_tag_t |
get_rich_error_code_fn | Retrieves the rich error code associated with an error. |
guaranteed_not_null_provider | Base that grants trusted subclasses a token to bypass null checks. |
hash_counter_engine | hash_counter_engine |
hasher | Primary template for folly's per-type hasher; specialized for supported key types. |
hazptr_array | hazptr_array |
hazptr_deleter | hazptr_deleter |
hazptr_domain | hazptr_domain |
hazptr_holder | hazptr_holder |
hazptr_local | Grants hazptr_local access to the thread cache internals. |
hazptr_obj | hazptr_obj |
hazptr_obj_base | hazptr_obj_base |
hazptr_obj_base_linked | hazptr_obj_base_linked |
hazptr_obj_cohort | hazptr_obj_cohort |
hazptr_obj_linked | hazptr_obj_linked |
hazptr_obj_list | hazptr_obj_list |
hazptr_obj_retired_list | hazptr_obj_retired_list |
hazptr_rec | hazptr_rec |
hazptr_root | hazptr_root |
hazptr_tc | hazptr_tc: |
hazptr_tc_entry | hazptr_tc_entry |
hazptr_tc_tls_tag | Tag type identifying the hazard pointer thread cache's thread-local singleton. |
heap_vector_map | A heap_vector_map based on heap layout. |
heap_vector_set | heap_vector_set is a specialization of heap_vector_container |
hybrid_lock | A lock-holder type which holds shared locks for shared mutex types or exclusive locks otherwise. |
hybrid_lock_base | A lock-holder base which holds shared locks for shared mutex types or exclusive locks otherwise. |
hybrid_lock_guard | For shared mutex types, effectively shared_lock_guard; otherwise, effectively unique_lock_guard. |
immortal_rich_error_t | A rich error whose storage has static (immortal) lifetime. |
index_iterator | index_iterator |
indirect | indirect |
inheriting_coded_rich_error | inheriting_coded_rich_error |
initlist_construct_t | Initializer lists are a powerful compile time syntax introduced in C++11 but due to their often conflicting syntax they are not used by APIs for construction. |
invoke_first_match | Composite invoker delegating to the first invoker matching the call. |
invoke_member_wrapper_fn | Wraps a callable made via FOLLY_INVOKE_MEMBER so it is recognizable. |
invoke_traits | Traits container mimicking the C++17 invocation traits for invoker I. |
io_uring | |
io_uring_buf | |
io_uring_buf_ring | |
io_uring_cqe | |
io_uring_zcrx_cqe | |
isTry | Trait that detects whether a type is a Try. |
is_allocator | A trait type to test whether a type is an allocator. |
is_arithmetic | A trait type that is true when T is an arithmetic type. |
is_bounded_array | A type to check if a given type is a bounded array. |
is_complete | is_complete is_complete_v |
is_constexpr_default_constructible | A type which determines whether the type parameter is constexpr default-constructible. |
is_detected | A trait type to test whether a metafunction succeeds in substitution. |
is_heap_vector_map | Trait that reports whether T is an instantiation of heap_vector_map. |
is_heap_vector_set | Trait that reports whether T is an instantiation of heap_vector_set. |
is_instantiation_of | A type to check if a given type is an instantiation of a class template. |
is_integral | A trait type that is true when T is an integral type. |
is_invocable | Trait testing whether F is invocable with A...; mimics std::is_invocable. |
is_invocable_r | Trait testing whether the result of invoking F is convertible to R; mimics std::is_invocable_r. |
is_non_bool_integral | A trait type that is true when Int is integral but not bool. |
is_nothrow_invocable | Trait testing whether F is nothrow-invocable with A...; mimics std::is_nothrow_invocable. |
is_nothrow_invocable_r | Trait testing the nothrow invocation of F with result convertible to R; mimics std::is_nothrow_invocable_r. |
is_nothrow_tag_invocable | Trait testing whether the tag_invoke CPO is nothrow-invocable. |
is_result | Type trait to test if a type is a result. |
is_signed | A trait type that is true when T is a signed type. |
is_small_sorted_vector_map | Trait that detects a small_sorted_vector_map specialization. |
is_small_sorted_vector_set | Trait that detects a small_sorted_vector_set specialization. |
is_small_vector | Trait that detects whether a type is a folly::small_vector. |
is_sorted_vector_map | Trait that detects a sorted_vector_map specialization. |
is_sorted_vector_set | Trait that detects a sorted_vector_set specialization. |
is_tag_invocable | Trait testing whether the tag_invoke CPO can be invoked with Tag and Args. |
is_transparent | A trait type to test whether a type follows the is-transparent protocol. |
is_unbounded_array | A type to check if a given type is an unbounded array. |
is_unsigned | A trait type that is true when T is an unsigned type. |
json_patch | A parsed JSON Patch document, as described in RFC 6902 "JSON Patch". |
json_pointer | A parsed JSON Pointer, as described in RFC 6901 "JSON Pointer". |
kahan_accumulator | Kahan (Kahan-Babushka-Neumaier) compensated summation accumulator. |
lift_unit | Maps a type to itself, and maps void to Unit. |
like | A trait to replace the cvref category of Dst with that of Src. |
literal_c_str | literal_c_str |
literal_string | literal_string |
make_signed | A trait that yields the signed integer type corresponding to T. |
make_unsigned | A trait that yields the unsigned integer type corresponding to T. |
manual_safe_callable_t | A callable wrapper that manually asserts the safe_alias level S. |
manual_safe_ref_t | A reference wrapper that manually asserts the safe_alias level S. |
manual_safe_val_t | A value wrapper that manually asserts the safe_alias level S. |
max_align_t | A type aligned at least as strictly as the most-aligned fundamental type. |
member_pointer_traits | member_pointer_traits |
nestable_coded_rich_error | nestable_coded_rich_error |
nonesuch | nonesuch |
not_null | not_null specializable class. |
not_null_base | not_null_base, the common interface for all not_null subclasses. - Implicitly constructs and casts just like a PtrT. - Has unwrap() function to access the underlying PtrT. |
or_unwind | Awaitable that unwinds a result on the error path, holding a reference. |
or_unwind_owning | Awaitable that unwinds an owned result on the error path. |
order_preserving_reinsertion_view_fn | Extension point yielding an order-preserving reinsertion view of a container. |
order_preserving_reinsertion_view_or_default_fn | Extension point returning a reinsertion view or the argument itself. |
partial_ordering | mimic: std::partial_ordering, c++20 (partial) |
propagate_const | A const-propagating wrapper around a pointer-like type. |
rcu_domain | Defines an RCU domain that scopes readers and updaters together. |
rcu_obj_base | Base class giving derived objects preallocated RCU retirement storage. |
reentrant_allocator | A reentrant mmap-based allocator. |
reentrant_allocator_options | Configuration options for reentrant_allocator. |
relaxed_atomic | Like std::atomic, but without the std::memory_order parameters on any member function. |
remove_cvref | A type trait to remove all const volatile and reference qualifiers on a type T |
reproducible_accumulator | Reproducible floating-point accumulator via binned floating-point arithmetic. |
reproducible_accumulator | Reproducible floating-point accumulator via binned floating-point arithmetic. |
result | A value, an error (std::exception_ptr), or a "stopped"/cancellation state. |
rich_error | A rich error carrying a user-defined base type and a formatted message. |
rich_error_base | Base class for exceptions that carry a queryable rich error code. |
rich_error_bases_and_own_codes | Aggregates a rich error's base types with the codes it owns. |
rich_error_code | Maps an error-code enum onto the rich-error machinery. |
rich_error_code_query | Query object used to retrieve the rich error code from an exception. |
rich_exception_ptr | rich_exception_ptr is an analog of exception_wrapper or std::exception_ptr, with some extra efficiency optimizations, and integration with rich_error / epitaph. It was designed to support rich-error features in result.h. |
rich_msg | A message that can automatically capture source locations. |
rich_ptr_to_underlying_error | Quacks like Ex*, but shows an epitaph stack when formatted. |
rvalue_reference_wrapper | Class template that wraps a reference to an rvalue. Similar to std::reference_wrapper but with three important differences: |
safe_alias_of | Primary trait template that measures the safe_alias level of a type. |
safe_alias_of_pack | Computes the safe_alias level of a composite type. |
shared_from_this_ptr | shared_from_this_ptr |
shared_lock_base | A lock-holder base which holds shared locks, usable with any shared mutex. |
shared_lock_guard | A lock-guard which holds shared locks, usable with any shared mutex type. |
small_heap_vector_map | Specialize heap_vector_map to integral key type and std::less comparaison. small_heap_map achieve a very fast find for small map < 200 elements. |
small_vector | Forward declaration of the small_vector container. |
sorted_equivalent_t | Tag type indicating a container is sorted but not necessarily unique. |
sorted_unique_t | Tag type indicating a container is sorted and unique. |
sorted_vector_map | A sorted_vector_map is similar to a sorted_vector_set but stores <key,value> pairs instead of single elements. |
sorted_vector_set | A sorted_vector_set is a container similar to std::set<>, but implemented as a sorted array with std::vector<>. |
splitmix64_engine | splitmix64_engine |
static_function_deleter | static_function_deleter |
stopped_result_t | Tag type signaling that a work-tree was stopped (aka cancelled). |
strong | strong<T, Tag> - prevent accidental mixing of semantically different uses of the same underlying type. Known as "newtype" in some languages. C++20. Default-construction value-initializes T, even if it's a primitive type. |
strong_derefable | strong_derefable<T, Tag> - a strong type with pointer-like dereference operators. Inherits all functionality from strong and adds operator* and operator-> for convenient access to the underlying value. Usage: |
tag_invoke_result | Holds the result type of a valid tag_invoke call, or is empty otherwise. |
tag_t | tag_t tag |
tape | A container adapter that builds a version of vector<vector> on top of a random access underlying container. |
thread_cached_synchronized | A synchronized value with a per-thread cache for accelerated reads. |
to_ascii_alphabet | Alphabet mapping a digit value to its ASCII character, lower- or upper-case. |
to_floating_point_convertible | Holds an integral value for conversion to a floating-point target type. |
to_integral_convertible | Holds a floating-point value for conversion to an integral target type. |
to_narrow_convertible | Holds an integral value for possibly-narrowing conversion to a target type. |
transparent | Adapter that marks a type as transparent for heterogeneous lookup. |
uint_division_result | uint_division_result |
uint_divisor | uint_divisor |
unicode_code_point_utf8 | A UTF-8 encoding of a single Unicode code point. |
unicode_error | Exception thrown when Unicode decoding or encoding fails. |
unique_hash_key | unique_hash_key |
unique_hash_key_with | unique_hash_key_with |
unique_lock_base | A lock-holder base which holds exclusive locks, usable with any mutex type. |
unique_lock_guard_base | A lock-guard which holds exclusive locks, usable with any mutex type. |
unsafe_default_initialized_cv | Convertible to any default-constructible type, yielding a default-initialized value on conversion. |
unsafe_for_async_usage | Convenience base or member that tags a type as unsafe for async usage. |
unsafe_for_async_usage_if | Conditionally tags a type as unsafe for async usage. |
upgrade_lock | A lock-holder type which holds upgrade locks, usable with any upgrade mutex. |
upgrade_lock_base | A lock-holder base which holds upgrade locks, usable with any upgrade mutex. |
value_only_result | A result-like type that always holds a value (never error or stopped). |
variadic_constant_of_fn | variadic_constant_of variadic_constant_of_fn |
vtag_t | vtag_t vtag |
x86_cpuid_cache_info | Decoded x86 cpuid cache descriptor for one cache level. |
x86_cpuid_vendor_name | Vendor identification string as returned by the cpuid instruction. |
xoshiro256pp | xoshiro256++ pseudo-random number generator. |
| Name | Description |
|---|---|
ArenaAllocator | Standard-conforming allocator that draws memory from an Arena. |
AsyncIOQueue | A queue of operations backed by an AsyncIO context. |
AsyncSocketObserverContainerBaseT | Base observer-container type for AsyncSocket observers. |
AsyncTransportWrapper | Alias kept for backward compatibility with older transport wrapper names. |
AtomicUnorderedInsertMap64 | AtomicUnorderedInsertMap64 is just a type alias that makes it easier to select a 64 bit slot index type. Use this if you need a capacity bigger than 2^30 (about a billion). This increases memory overheads, obviously. |
BaseFormatter | Alias for BaseFormatterImpl with an index sequence built from Args. |
ByteArray16 | Specialization for std::array for IPv6 addresses |
ByteArray4 | Specialization of std::array for IPv4 addresses |
ByteRange | A read-only view over a sequence of bytes. |
CIDRNetwork | Pair of IPAddress, netmask |
CIDRNetworkV4 | Pair of IPAddressV4, netmask |
CIDRNetworkV6 | Pair of IPAddressV6, netmask |
Cob | Callback type for functions scheduled on an executor. |
ConcurrentBSkipInlineMap | A concurrent sorted map with payloads stored inline in the leaves. |
ConcurrentBSkipMap | A concurrent sorted map with separately stored payloads. |
ConcurrentBSkipSet | A concurrent sorted set built on ConcurrentBSkipList. |
ConcurrentHashMapSIMD | SIMD-backed ConcurrentHashMap based on F14ValueMap. |
CountedIntrusiveList | An intrusive list with const-time size() method. |
DMPMCQueue | DMPMCQueue |
DMPSCQueue | DMPSCQueue |
DSPMCQueue | DSPMCQueue |
DSPSCQueue | DSPSCQueue |
DefaultRefCount | Default reference-count type used by the read-mostly smart pointers. |
DefaultVectorType | Alias for the default vector type used by xoshiro256pp. |
DelayedDestructionUniquePtr | Unique pointer that destroys a DelayedDestruction object via destroy(). |
DistributedMutex | The default distributed mutex, ready to use without template arguments. |
Duration | folly::Duration is an alias for the best resolution we offer/work with. However, it is not intended to be used for client code - you should use a descriptive std::chrono::duration type instead. e.g. do not write this: |
DynamicTokenBucket | Dynamic token bucket with an adjustable rate and burst size using the default policy. |
ExpectedErrorType | Alias for an Expected type's associated error_type |
ExpectedValueType | Alias for an Expected type's associated value_type |
FallbackArenaAllocator | Arena allocator that falls back to std::allocator when the arena is exhausted. |
FallbackGetcpuType | The FallbackGetcpu specialization selected for the current platform. |
FallbackSysArenaAllocator | SysArena allocator that falls back to std::allocator when exhausted. |
FixedString | A fixed-capacity string of char with capacity for N characters. |
Func | A move-only callable holding a unit of work with no arguments or result. |
GetDeadlockDetectorFactoryInstance | Function type that returns the deadlock detector factory instance. |
GroupVarint32 | GroupVarint codec for 32-bit values. |
GroupVarint32Decoder | GroupVarint decoder for 32-bit values. |
GroupVarint64 | GroupVarint codec for 64-bit values. |
GroupVarint64Decoder | GroupVarint decoder for 64-bit values. |
HHWheelTimer | A hashed hierarchical wheel timer with millisecond resolution. |
HHWheelTimerHighRes | A hashed hierarchical wheel timer with microsecond resolution. |
HighResDuration | A higher-resolution duration alias used where microsecond precision is needed. |
HugePageSizeVec | Vector of (huge_page_size, mount_point), sorted by huge_page_size. mount_point might be empty if no hugetlbfs file system is mounted for that size. |
IOBufFactory | Callable that creates an IOBuf with the requested capacity. |
Identity | Type of the identity function object. |
Ignored | An alias for Ignore that accepts and ignores any type arguments. |
IndexedMemPoolTraitsEagerRecycle | IndexedMemPool traits that implements the eager lifecycle strategy. In this strategy elements are constructed when they are allocated from the pool and destroyed when recycled. |
IndexedMemPoolTraitsLazyRecycle | IndexedMemPool traits that implements the lazy lifecycle strategy. In this strategy elements are default-constructed the first time they are allocated, and destroyed when the pool itself is destroyed. |
IntrusiveList | An intrusive list. |
IntrusiveListHook | An auto-unlink intrusive list hook. |
IsOneOf | A trait to test whether T is one of the types T1, T2, ..., Tn. |
LaggingQueueInfoFunc | Callable that returns information about lagging queues. |
LifoSem | LifoSem is a semaphore that wakes its waiters in a manner intended to maximize performance rather than fairness. It should be preferred to a mutex+condvar or POSIX sem_t solution when all of the waiters are equivalent. It is faster than a condvar or sem_t, and it has a shutdown state that might save you a lot of complexity when it comes time to shut down your work pipelines. LifoSem is larger than sem_t, but that is only because it uses padding and alignment to avoid false sharing. |
MSLGuard | /////////////////////////////////////////////////////////////////// |
MakeQueueObserverFactory | Function type that builds a QueueObserverFactory. |
MallctlMibExchangeCache | Caches the resolved MIB for a mallctl command that exchanges a value of a single type. |
MeteredExecutor | Executor that meters how many tasks it feeds into a wrapped executor. |
MicroLock | Default MicroLock specialization with the standard spin and yield budget. |
MutableByteRange | A mutable view over a sequence of bytes. |
MutableStringPiece | A mutable view over a sequence of char. |
PolyDecay | When used in conjunction with PolySelf, controls how to construct Poly types related to the one currently being instantiated. |
PolySelf | Within the definition of interface I, PolySelf<Base> is an alias for the instance of Poly that is currently being instantiated. It is one of: Poly<J>, Poly<J&&>, Poly<J&>, or Poly<J const&>; where J is either I or some interface that extends I. |
PriorityUMPMCQueueSet | Priority queue set with multi-producer, multi-consumer queues. |
PriorityUMPSCQueueSet | Priority queue set with multi-producer, single-consumer queues. |
PriorityUSPMCQueueSet | Priority queue set with single-producer, multi-consumer queues. |
PriorityUSPSCQueueSet | Priority queue set with single-producer, single-consumer queues. |
QuadraticProbingAtomicHashMap | An AtomicHashMap alias that uses quadratic probing. |
RegexMatchCacheKeyBase | The base hash-key type underlying RegexMatchCacheKey. |
RequestDataItem | A token/data pair used to populate a RequestContext. |
ResolveNapiIdCallback | |
SPSerialExecutor | Single-producer version of SmallExecutor. It is the responsibility of the caller to guarantee that calls to add() are externally serialized, but it can be slightly faster. |
SSLContextPtr | Shared-ownership pointer to an SSLContext. |
SafeIntrusiveList | A safe intrusive list. |
SafeIntrusiveListHook | A safe-link intrusive list hook. |
SerialExecutor | Executor that runs added tasks serially and in order on a parent executor. |
SharedMutex | Default SharedMutex; an alias for the write-priority variant. |
SharedMutexReadPriority | SharedMutex variant that gives priority to readers. |
SharedMutexSuppressTSAN | SharedMutex variant that suppresses ThreadSanitizer rwlock annotations. |
SharedMutexTracked | SharedMutex variant that tracks the id of the owning thread. |
SharedMutexWritePriority | SharedMutex variant that gives priority to writers. |
SocketCmsgMap | Maps socket option keys to integer control-message values. |
SocketNontrivialCmsgMap | Maps socket option keys to string control-message values. |
SocketOptionMap | Maps socket option keys to their values. |
SrcPortForQueueIdCallback | |
StringPiece | A read-only view over a sequence of char. |
SysArenaAllocator | Standard-conforming allocator backed by a SysArena. |
SysBufferUniquePtr | A unique_ptr owning a std::malloc-allocated buffer freed with std::free. |
ThreadCachedArenaAllocator | Standard-conforming allocator backed by a ThreadCachedArena. |
TokenBucket | Token bucket with a fixed rate and burst size using the default policy. |
UMPMCQueue | Unbounded multi-producer, multi-consumer queue. |
UMPSCQueue | Unbounded multi-producer, single-consumer queue. |
USPMCQueue | Unbounded single-producer, multi-consumer queue. |
USPSCQueue | Unbounded single-producer, single-consumer queue. |
UserCounters | Maps user-defined counter names to their metric values. |
_t | * _t |
aligned_hazptr_holder | Type used by hazptr_array and hazptr_local. |
aligned_storage_for_t | An uninitialized storage type suitable for holding an object of type T. |
aligned_storage_t | An uninitialized storage type of the given length and alignment. |
apply_result | Mimic the invoke suite of traits for tuple based apply invocation |
apply_result_t | The result type of applying F to the elements of Tuple. |
atomic_value_type_t | The effective value type of an atomic-like type. |
back_emplace_iterator | Behaves just like std::back_insert_iterator except that it calls emplace_back() instead of insert(). Uses perfect forwarding. |
cacheline_aligned | An aligned wrapper for T using at least cache-line alignment. |
coarse_stop_watch | A type alias for custom_stop_watch that uses a coarse monotonic clock as the time source. Refer to the documentation of custom_stop_watch for full documentation. |
conditional_t | conditional_t |
copy_cvref_t | copy_cvref_t |
cpo_t | Type of a customization-point object, deduced from its tag value. |
cstring_view | A null-terminated string view over char. |
detected_or | detected_or |
detected_or_t | detected_or_t |
detected_t | detected_t |
drop_unit_t | Alias for the type produced by drop_unit. |
emplace_iterator | Behaves just like std::insert_iterator except that it calls emplace() instead of insert(). Uses perfect forwarding. |
enable_hasher_helper | A helper for defining partial specializations of a hasher class that rely on other partial specializations of that hasher class being usable. |
enable_std_hash_helper | A helper for defining partial specializations of a hasher class that rely on other partial specializations of that hasher class being usable. |
erased_unique_ptr | erased_unique_ptr |
errc_rich_error | The rich-error counterpart to std::system_error, coding a std::errc. |
fbstring | A basic_fbstring specialized for char, the common string type. |
fmt_vformat_mangle_format_string_options | Options type for fmt_vformat_mangle_format_string. |
format_string_for_each_named_arg_options | Options type for format_string_for_each_named_arg. |
front_emplace_iterator | Behaves just like std::front_insert_iterator except that it calls emplace_front() instead of insert(). Uses perfect forwarding. |
function_arguments_element_t | The type of the argument at index Idx of the given function type. |
function_arguments_size_t | The argument-list size of the given function type, as an integral_constant. |
function_like_value_t | The function type formed by transporting the cvref of Src onto Dst. |
function_remove_cvref_t | The function type F with its cvref-qualifications removed. |
function_result_t | The result type of the given function type. |
hazard_pointer | hazard_pointer class name consistent with standard proposal |
hazard_pointer_domain | hazard_pointer_domain class name consistent with standard proposal |
hazard_pointer_obj_base | hazard_pointer_obj_base class template name consistent with standard proposal |
hint_emplace_iterator | Behaves just like std::insert_iterator except that it calls emplace_hint() instead of insert(). Uses perfect forwarding. |
index_constant | An alias for a std::integral_constant of type std::size_t. |
index_sequence_for_tuple | Helper to generate an index sequence from a tuple like type |
int128_t | A signed 128-bit integer type, where the compiler supports one. |
int_bits_lg_t | An alias for the signed integer type with 2^lg_bits bits. |
int_bits_t | An alias for the signed integer type with the given number of bits. |
invoke_result | Holds the result type of invoking F with A...; mimics std::invoke_result. |
is_applicable | Trait testing whether F is invocable with the elements of Tuple. |
is_applicable_r | Trait testing whether applying F to Tuple yields a result convertible to R. |
is_cleanup | Trait constant that is true when T models the async cleanup concept. |
is_enable_master_from_this | Trait that reports whether T publicly derives from EnablePrimaryFromThis. |
is_hashable | Checks that the given hasher template's specialization for the given type is usable with the standard library containters, for example std::unordered_set<T, Hasher<T>>. |
is_hasher_usable | Checks the requirements that the Hasher class must satisfy in order to be used with the standard library containers, for example std::unordered_set<T, Hasher>. |
is_nothrow_applicable | Trait testing whether F is nothrow-invocable with the elements of Tuple. |
is_nothrow_applicable_r | Trait testing the nothrow application of F to Tuple with result convertible to R. |
is_nothrow_tag_invocable_r | Trait testing whether a nothrow tag_invoke yields a result convertible to R. |
is_replaceable | Trait that is true if T is an instantiation of Replaceable. |
is_tag_invocable_r | Trait testing whether a tag_invoke call yields a result convertible to R. |
iterator_category_t | Extracts iterator_category from an iterator. |
iterator_key_type_t | Extracts a key type from an iterator, leverages the knowledge that key/value containers usually use std::pair<const K, V> as a value_type. |
iterator_mapped_type_t | Extracts a mapped type from an iterator. |
iterator_reference_t | Extracts reference from an iterator (C++20 iter_reference_t backported) |
iterator_value_type_t | Extracts a value type from an iterator. |
libevent_fd_t | Portable type of a libevent event file descriptor. |
lift_unit_t | Alias for the type produced by lift_unit. |
like_t | like like_t |
make_signed_t | An alias for the signed integer type corresponding to T. |
make_unsigned_t | An alias for the unsigned integer type corresponding to T. |
member_pointer_member_t | member_pointer_member_t |
member_pointer_object_t | member_pointer_object_t |
monotonic_clock | Monotonic clock used as the default time source for stop watches. |
non_value_result | Backwards-compatible alias for error_or_stopped. |
once_flag | The flag type to be used with call_once. |
register_pass_t | register_pass_t |
relaxed_atomic_bool | A relaxed_atomic over bool. |
relaxed_atomic_char | A relaxed_atomic over char. |
relaxed_atomic_char16_t | A relaxed_atomic over char16_t. |
relaxed_atomic_char32_t | A relaxed_atomic over char32_t. |
relaxed_atomic_int | A relaxed_atomic over int. |
relaxed_atomic_int16_t | A relaxed_atomic over std::int16_t. |
relaxed_atomic_int32_t | A relaxed_atomic over std::int32_t. |
relaxed_atomic_int64_t | A relaxed_atomic over std::int64_t. |
relaxed_atomic_int8_t | A relaxed_atomic over std::int8_t. |
relaxed_atomic_int_fast16_t | A relaxed_atomic over std::int_fast16_t. |
relaxed_atomic_int_fast32_t | A relaxed_atomic over std::int_fast32_t. |
relaxed_atomic_int_fast64_t | A relaxed_atomic over std::int_fast64_t. |
relaxed_atomic_int_fast8_t | A relaxed_atomic over std::int_fast8_t. |
relaxed_atomic_int_least16_t | A relaxed_atomic over std::int_least16_t. |
relaxed_atomic_int_least32_t | A relaxed_atomic over std::int_least32_t. |
relaxed_atomic_int_least64_t | A relaxed_atomic over std::int_least64_t. |
relaxed_atomic_int_least8_t | A relaxed_atomic over std::int_least8_t. |
relaxed_atomic_intmax_t | A relaxed_atomic over std::intmax_t. |
relaxed_atomic_intptr_t | A relaxed_atomic over std::intptr_t. |
relaxed_atomic_llong | A relaxed_atomic over long long. |
relaxed_atomic_long | A relaxed_atomic over long. |
relaxed_atomic_ptrdiff_t | A relaxed_atomic over std::ptrdiff_t. |
relaxed_atomic_schar | A relaxed_atomic over signed char. |
relaxed_atomic_short | A relaxed_atomic over short. |
relaxed_atomic_size_t | A relaxed_atomic over std::size_t. |
relaxed_atomic_uchar | A relaxed_atomic over unsigned char. |
relaxed_atomic_uint | A relaxed_atomic over unsigned int. |
relaxed_atomic_uint16_t | A relaxed_atomic over std::uint16_t. |
relaxed_atomic_uint32_t | A relaxed_atomic over std::uint32_t. |
relaxed_atomic_uint64_t | A relaxed_atomic over std::uint64_t. |
relaxed_atomic_uint8_t | A relaxed_atomic over std::uint8_t. |
relaxed_atomic_uint_fast16_t | A relaxed_atomic over std::uint_fast16_t. |
relaxed_atomic_uint_fast32_t | A relaxed_atomic over std::uint_fast32_t. |
relaxed_atomic_uint_fast64_t | A relaxed_atomic over std::uint_fast64_t. |
relaxed_atomic_uint_fast8_t | A relaxed_atomic over std::uint_fast8_t. |
relaxed_atomic_uint_least16_t | A relaxed_atomic over std::uint_least16_t. |
relaxed_atomic_uint_least32_t | A relaxed_atomic over std::uint_least32_t. |
relaxed_atomic_uint_least64_t | A relaxed_atomic over std::uint_least64_t. |
relaxed_atomic_uint_least8_t | A relaxed_atomic over std::uint_least8_t. |
relaxed_atomic_uintmax_t | A relaxed_atomic over std::uintmax_t. |
relaxed_atomic_uintptr_t | A relaxed_atomic over std::uintptr_t. |
relaxed_atomic_ullong | A relaxed_atomic over unsigned long long. |
relaxed_atomic_ulong | A relaxed_atomic over unsigned long. |
relaxed_atomic_ushort | A relaxed_atomic over unsigned short. |
relaxed_atomic_wchar_t | A relaxed_atomic over wchar_t. |
remove_cvref_t | An alias for the type T with all cv and reference qualifiers removed. |
rich_error_hints | Alias for rich error types to declare fast exception-lookup hints. |
safe_alias_constant | An std::integral_constant holding the given safe_alias level. |
small_sorted_vector_map | A sorted_vector_map backed by a small_vector with inline capacity N. |
small_sorted_vector_set | A sorted_vector_set backed by a small_vector with inline capacity N. |
source_location | Portable alias for the standard source_location type. |
stop_watch | A type alias for custom_stop_watch that uses a monotonic clock as the time source. Refer to the documentation of custom_stop_watch for full documentation. |
string_tape | string_tape - a common usecase. |
to_ascii_alphabet_lower | Digit alphabet producing lowercase letters. |
to_ascii_alphabet_upper | Digit alphabet producing uppercase letters. |
type_list_concat_t | type_list_concat_t |
type_list_element_t | type_list_element_t |
type_list_find_t | type_list_find_t |
type_list_size_t | type_list_size_t |
type_pack_element_t | In the type pack Ts..., the Ith element. |
type_pack_find_t | type_pack_find_t |
type_pack_size_t | type_pack_size_t |
type_t | A type alias for the first template type argument. |
uint128_t | An unsigned 128-bit integer type, where the compiler supports one. |
uint_bits_lg_t | An alias for the unsigned integer type with 2^lg_bits bits. |
uint_bits_t | An alias for the unsigned integer type with the given number of bits. |
unexpected_t | Function-reference type used as the unexpected disambiguation tag. |
unique_hash_key_strong_sha256 | unique_hash_key_strong_sha256 |
unique_lock_guard | Alias to std::lock_guard. |
value_list_concat_t | value_list_concat_t |
value_list_element_type_t | value_list_element_type_t |
value_list_size_t | value_list_size_t |
value_pack_element_type_t | value_pack_element_type_t |
value_pack_size_t | value_pack_size_t |
vector_bool | Convenience alias to use instead of std::vector<bool> to avoid infamous std::vector<bool> specialization. |
void_t | A type alias for void that depends on the given template arguments. |
xoshiro256pp_32 | xoshiro256++ generator producing 32-bit results. |
xoshiro256pp_64 | xoshiro256++ generator producing 64-bit results. |
| Name | Description |
|---|---|
AcquireMallocatedString | Defines a special acquisition method for constructing fbstring objects. AcquireMallocatedString means that the user passes a pointer to a malloc-allocated string that the fbstring object will take into custody. |
AtomicNotificationQueueTaskStatus | Consumer::operator() can optionally return AtomicNotificationQueueTaskStatus to indicate if the provided task should be considered consumed or discarded. Discarded tasks are not counted towards maxReadAtOnce_. |
BSkipInsertOutcome | Detailed result of an insertion into a ConcurrentBSkipList. |
CIDRNetworkError | Wraps errors from parsing IP/MASK string |
ConversionCode | Error codes describing why a string-to-value conversion failed. |
DecodeVarintError | Error reported when a varint cannot be decoded. |
GoogleLoggerStyle | Output style for the default glog-based AutoTimer logger. |
IPAddressFormatError | Error codes for non-throwing interface of IPAddress family of functions. |
KeyReadPolicy | Selects how Skipper reads a key slot under concurrent writes. |
LeafStoragePolicy | Selects how leaf key/payload data is laid out in memory. |
LogLevel | Log level values. |
MacAddressFormatError | Error codes reported when parsing or constructing a MacAddress fails. |
ParkResult | The outcome of a park operation. |
PrettyType | Unit families understood by prettyPrint and prettyToDouble. |
ProcessPhase | Process phases |
QueueBehaviorIfFull | Behavior of a queue when an item is added while the queue is full. |
SSLError | Categories of SSL failure reported by SSLException. |
SyncType | Whether an atomic write syncs to storage to guarantee ordering. |
TLPDestructionMode | Selects which threads' thread-local instances are destroyed. |
UnparkControl | Controls whether a wait node is retained and whether unparking continues. |
UriEscapeMode | overloadbrief URI-escape a string. |
UriFormatError | Error codes for parsing issues. Used by tryFromString() |
UuidParseCode | Result code returned by UUID parsing functions. |
WriteFlags | Flags given by the application for write* calls. |
annotate_rwlock_level | The lock mode reported to ThreadSanitizer rwlock annotations. |
cli_apply_args_files_errc | Error codes reported by args-file expansion. |
ordering | Three-way comparison result: less-than, equal, or greater-than. |
safe_alias | A hierarchy of memory-safety levels for a type, from least to most safe. |
x86_cpuid_vendor | Recognized x86 CPU vendors. |
| Name | Description |
|---|---|
PrintTo | Printer for GTest. |
__folly_memcpy | Folly's tuned memcpy entry point (C linkage inside the folly namespace). |
__folly_memset | Set the first count bytes of the block pointed to by dest to ch. |
accurate_sum | accurate_sum overloads |
acquireLocked | Acquire locks for multiple Synchronized<T> objects, in a deadlock-safe manner. |
acquireLockedPair | A version of acquireLocked() that returns a std::pair rather than a std::tuple, which is easier to use in many places. |
activateAsyncStackFrame | Activate the specified AsyncStackFrame on the specified AsyncStackRoot, setting it as the current 'topFrame'. |
activateSuspendedLeaf | Push a dummy "leaf" frame into the stack to annotate the stack as "suspended". |
addBenchmark | Adds a benchmark. Usually not called directly but instead through the macro BENCHMARK defined below. The lambda function involved can have one of the following forms: * take zero parameters, and the benchmark calls it repeatedly * take exactly one parameter of type unsigned, and the benchmark uses it with counter semantics (iteration occurs inside the function). * 2 versions of the above cases but also accept UserCounters& as as their first parameter. |
align_ceil | align_ceil overloads |
align_floor | align_floor overloads |
alignedForwardMemcpy | A special case of memcpy() that always copies memory forwards. (libc's memcpy() is allowed to copy memory backwards, and will do so when using SSSE3 instructions). |
aligned_free | Free memory previously obtained from aligned_malloc. |
aligned_malloc | Allocate size bytes aligned to align, returning null on failure. |
allocateOverAligned | Allocate storage for n values through alloc, honoring over-alignment. |
allocate_not_null_shared | Creates a not_null_shared_ptr using an allocator, like std::allocate_shared. |
allocate_sys_buffer | Allocate a size-byte buffer with std::malloc, throwing on failure. |
allocate_unique | allocate_unique, like std::allocate_shared but for std::unique_ptr |
allocationBytesForOverAligned | Return the number of bytes allocateOverAligned requests for n values. |
appendCodePointToUtf8 | Encode a single Unicode code point into a UTF-8 byte sequence. |
applySocketOptions | Applies the given socket options to a socket at the given position. |
apply_visitor | apply_visitor overloads |
asm_volatile_memory | Emits a compiler barrier preventing reordering of memory accesses. |
asm_volatile_pause | Emits a CPU pause/yield hint suitable for spin-wait loops. |
assume | assume(cond) informs the compiler that cond can be assumed true. If cond is not true at runtime the behavior is undefined. |
assume_unreachable [noreturn] | assume_unreachable() informs the compiler that the statement is not reachable at runtime. It is undefined behavior if the statement is actually reached. |
asymmetric_thread_fence_heavy | Issue a heavyweight asymmetric thread fence. |
asymmetric_thread_fence_light | Issue a lightweight asymmetric thread fence. |
async | Run a callable asynchronously on the global CPU executor. |
atomic_compare_exchange_strong_explicit | Compare-exchange (strong) that works around a TSAN bug in the standard library version. |
atomic_compare_exchange_weak_explicit | Compare-exchange (weak) that works around a TSAN bug in the standard library version. |
attach | attach overloads |
available_concurrency | available_concurrency |
back_emplacer | Convenience function to construct a folly::back_emplace_iterator, analogous to std::back_inserter(). |
backslashify | backslashify overloads |
base64Decode | base64Decode overloads |
base64DecodeRuntime | base64DecodeRuntime overloads |
base64DecodedSize | base64DecodedSize overloads |
base64Encode | base64Encode overloads |
base64EncodeRuntime | Encode a byte range to standard base64 at runtime. |
base64EncodedSize | Compute the encoded size for standard base64. |
base64PHPStrictDecode | base64PHPStrictDecode overloads |
base64PHPStrictDecodeRequiredOutputSize | base64PHPStrictDecodeRequiredOutputSize overloads |
base64URLDecode | base64URLDecode overloads |
base64URLDecodeRuntime | base64URLDecodeRuntime overloads |
base64URLDecodedSize | base64URLDecodedSize overloads |
base64URLEncode | base64URLEncode overloads |
base64URLEncodeRuntime | Encode a byte range to URL-safe base64 at runtime. |
base64URLEncodedSize | Compute the encoded size for URL-safe base64. |
benchmarkResultsFromDynamic | Deserialize benchmark results from a dynamic value. |
benchmarkResultsToDynamic | Serialize benchmark results into a dynamic value. |
bitReverse | Reverse the order of the bits in n. |
bm_llc_evict | Evict cache lines by writing to a large block of memory. |
bm_llc_size | Calculates the size of the LLC (Last Level Cache, typically L3 on x86-64). |
cEscape | cEscape overloads |
cUnescape | cUnescape overloads |
call_once | call_once overloads |
canNallocx | Return whether nallocx() is supported by the current allocator. |
canSdallocx | Return whether sdallocx() is supported by the current allocator. |
canSetCurrentThreadName | This returns true if the current platform supports setting the name of the current thread. |
canSetOtherThreadName | This returns true if the current platform supports setting the name of threads other than the one currently executing. |
cancellation_token_merge | Merge the given tokens into a single CancellationToken. |
catch_exception | catch_exception overloads |
checkAsyncStackFrameIsActive | Perform some consistency checks on the specified AsyncStackFrame, assuming that it is the currently active AsyncStackFrame. |
checkFopenError | Checks the return value from a fopen-style function (non-null FILE* on success, null on error) and throws on error. |
checkFopenErrorExplicit | Checks the return value from a fopen-style function and throws using an explicit saved errno. |
checkKernelError | Checks a Linux kernel-style return code (>= 0 on success, negative error number on error) and throws on error. |
checkPosixError | Checks a POSIX return code (0 on success, error number on error) and throws on error. |
checkUnixError | Checks a traditional Unix return code (-1 and sets errno on error) and throws on error. |
checkUnixErrorExplicit | Checks a traditional Unix return code (-1 on error) and throws using an explicit saved errno. |
checkedAlignedMalloc | Allocate size bytes aligned to align, throwing std::bad_alloc on failure. |
checkedArrayMalloc | Allocate uninitialized storage for n instances of T, suitably aligned for T. |
checkedCalloc | Trivial wrapper around calloc that check for allocation failure and throw std::bad_alloc in that case. |
checkedMalloc | Trivial wrapper around malloc that check for allocation failure and throw std::bad_alloc in that case. |
checkedRealloc | Trivial wrapper around realloc that check for allocation failure and throw std::bad_alloc in that case. |
checked_add | checked_add overloads |
checked_div | Divide two integers, reporting division by zero. |
checked_mod | Compute the remainder of integer division, reporting division by zero. |
checked_mul | Multiply two unsigned integers, reporting overflow instead of wrapping. |
checked_muladd | Compute base * mul + add for unsigned integers, reporting overflow. |
clear_n_least_significant_bits | Clear the n least significant bits of x, leaving the others unchanged. |
clear_n_most_significant_bits | Clear the n most significant bits of x, leaving the others unchanged. |
cli_apply_args_files | cli_apply_args_files overloads |
cli_args_strings_to_c_strings | Converts a list of strings into a null-pointer-terminated array of C strings borrowing the storage of the input strings. |
closeNoInt | closeNoInt overloads |
codePointToUtf8 | Encodes a single Unicode code point as a UTF-8 string. |
compactResize | Resize a vector and shrink its capacity to fit. |
compareDynamicWithNestedJson | Like compareJson, but with dynamic instances. |
compareDynamicWithTolerance | Like compareJsonWithTolerance, but operates directly on the dynamics. |
compareJson | Compares two JSON strings and returns whether they represent the same document (thus ignoring things like object ordering or multiple representations of the same number). |
compareJsonWithNestedJson | Like compareJson, but if strNestingDepth > 0 then contained strings that are valid JSON will be compared using compareJsonWithNestedJson(str1, str2, strNestingDepth - 1). |
compareJsonWithTolerance | Like compareJson, but allows for the given tolerance when comparing numbers. |
compiler_may_unsafely_assume | Permits the compiler to assume the truth of the provided expression. |
compiler_may_unsafely_assume_separate_storage | Permits the compiler to assume the two pointers address separate storage. |
compiler_may_unsafely_assume_unreachable [noreturn] | Permits the compiler to assume that this statement cannot be reached. |
compiler_must_not_elide | Marks t as used so its computation is not elided. |
compiler_must_not_predict | Marks t as unpredictable so the compiler cannot optimize on its value. |
concurrent_lazy | Creates a ConcurrentLazy with a type deduced from the callable. |
constCastFunction | constCastFunction overloads |
const_pointer_cast | const_pointer_cast overloads |
const_span_cast | Casts in to a span of U over the same memory using const_cast. |
constexprLoadUnaligned | Read an unaligned value of type T and return it. Constexpr, but not optimized. Accepts inputs either of char-array types or char-backed enum-array types. |
constexprPartialLoadUnaligned | Read an unaligned value of type T and return it. Constexpr, but not optimized. Accepts inputs either of char-array types or char-backed enum-array types. |
constexpr_abs | Compute the absolute value of a number. |
constexpr_add_overflow_clamped | Add two values, clamping to the type's range on overflow. |
constexpr_ceil | constexpr_ceil |
constexpr_clamp | constexpr_clamp overloads |
constexpr_clamp_cast | constexpr_clamp_cast overloads |
constexpr_exp | constexpr_exp overloads |
constexpr_find_first_set | constexpr_find_first_set |
constexpr_find_last_set | constexpr_find_last_set |
constexpr_floor | constexpr_floor |
constexpr_isnan | Test whether a value is NaN. |
constexpr_log | constexpr_log |
constexpr_log2 | Compute the integer base-2 logarithm of a value. |
constexpr_log2_ceil | Compute the ceiling of the integer base-2 logarithm of a value. |
constexpr_max | Return the maximum of the given values. |
constexpr_min | Return the minimum of the given values. |
constexpr_mult | constexpr_mult |
constexpr_pow | constexpr_pow overloads |
constexpr_round | constexpr_round |
constexpr_strcmp | Compares two null-terminated strings at compile time. |
constexpr_strlen | Computes the length of a null-terminated string at compile time. |
constexpr_sub_overflow_clamped | Subtract two values, clamping to the type's range on overflow. |
constexpr_trunc | constexpr_trunc overloads |
contains | This function checks whether container contains given key. Use container specific .contains() implementation if available, otherwise uses .find() implementation. |
convertTo | Return a well-typed representation of a dynamic. |
copy | copy |
copy_through_shared_ptr | copy_through_shared_ptr |
copy_through_unique_ptr | copy_through_unique_ptr |
copy_to_erased_unique_ptr | copy_to_erased_unique_ptr |
copy_to_shared_ptr | copy_to_shared_ptr |
copy_to_unique_ptr | copy_to_unique_ptr |
coreFree | Frees memory allocated with coreMalloc(). |
coreMalloc | An allocator that can be used with AccessSpreader to allocate core-local memory. |
crange | crange overloads |
crc32 | Compute the CRC-32 checksum of a buffer, using a hardware-accelerated implementation if available or a portable software implementation as a default. |
crc32_combine | Given two checksums, combine them in to one checksum. |
crc32_type | Compute the CRC-32 checksum of a buffer, using a hardware-accelerated implementation if available or a portable software implementation as a default. |
crc32c | Compute the CRC-32C checksum of a buffer, using a hardware-accelerated implementation if available or a portable software implementation as a default. |
crc32c_combine | Combine two CRC-32C checksums into one, like crc32_combine() but using the CRC-32C polynomial. |
crc32c_combine_seed | crc32c_combine_seed is the same as crc32c_combine. Unlike crc32c_combine that only works for crc32c computed using a starting checksum 0U, this method works for any starting checksum that is an uint32_t. |
current_exception | current_exception |
current_exception_wrapper | A convenience shorthand for exception_wrapper(current_exception()). |
deactivateAsyncStackFrame | Deactivate the specified AsyncStackFrame, clearing the current 'topFrame'. |
deactivateSuspendedLeaf | Pop the dummy "leaf" frame off the stack to annotate the stack as having resumed. |
deallocateOverAligned | Free storage for n values obtained from allocateOverAligned. |
decodeVarint | Decode a value from a given buffer, advances data past the returned value. Throws on error. |
decodeZigZag | Reverse the ZigZag encoding produced by encodeZigZag. |
default_hazptr_domain | Access the process-wide default hazard pointer domain. |
defaulted | Wraps c so missing-key lookups return v instead of throwing. |
demangle | demangle overloads |
demangle_build_has_cxxabi | Report whether demangling was built with cxxabi support. |
demangle_build_has_liberty | Report whether demangling was built with libiberty support. |
didInsert | Returns whether an outcome represents a fresh insert or a revive. |
divCeil | Returns num/denom, rounded toward positive infinity. Put another way, returns the smallest integral value that is greater than or equal to the exact (not rounded) fraction num/denom. |
divFloor | Returns num/denom, rounded toward negative infinity. Put another way, returns the largest integral value that is less than or equal to the exact (not rounded) fraction num/denom. |
divRoundAway | Returns num/denom, rounded away from zero. If num and denom are non-zero and have different signs (so the unrounded fraction num/denom is negative), returns divFloor, otherwise returns divCeil. If T is an unsigned type then this is always equal to divCeil. |
divTrunc | Returns num/denom, rounded toward zero. If num and denom are non-zero and have different signs (so the unrounded fraction num/denom is negative), returns divCeil, otherwise returns divFloor. If T is an unsigned type then this is always equal to divFloor. |
doNotOptimizeAway | Ensure that a value is computed even after optimization. |
down_cast | down_cast overloads |
down_heap | down_heap overloads |
dup2NoInt | Duplicates a file descriptor onto another, retrying on EINTR. |
dupNoInt | Duplicates a file descriptor, retrying on EINTR. |
dynamic_pointer_cast | dynamic_pointer_cast overloads |
emplacer | Convenience function to construct a folly::emplace_iterator, analogous to std::inserter(). |
empty_erased_unique_ptr | empty_erased_unique_ptr |
enable_hazptr_thread_pool_executor | Route hazard pointer reclamation through the global CPU thread pool executor. |
encodeVarint | Encode a value in the given buffer, returning the number of bytes used for encoding. buf must have enough space to represent the value (at least kMaxVarintLength64 bytes to encode arbitrary 64-bit values) |
encodeVarintSize | Determine the number of bytes needed to represent "val". 32-bit values need at most 5 bytes. 64-bit values need at most 10 bytes. |
encodeZigZag | ZigZag encoding that maps signed integers with a small absolute value to unsigned integers with a small (positive) values. Without this, encoding negative values using Varint would use up 9 or 10 bytes. |
ensureCleanupAfterTask | Composes a task with an async cleanup that always runs after it. |
enumerate | Adapts a range so a range-based for loop can also observe the iteration index. |
epitaph | epitaph overloads |
erase | erase overloads |
erase_if | erase_if overloads |
errnoStr | Pretty print an errno. |
errorCategoryForErrnoDomain | Returns the most appropriate error category for errno-domain codes on the current platform. |
estimateSpaceNeeded | estimateSpaceNeeded overloads |
exceptionStr | exceptionStr overloads |
exception_ptr_access | Whether exception-ptr object inspection is supported on this platform. |
exception_ptr_get_object | exception_ptr_get_object overloads |
exception_ptr_get_object_hint | exception_ptr_get_object_hint overloads |
exception_ptr_get_type | Returns the true runtime type info of the exception as stored. |
exception_ptr_try_get_object_exact_fast | exception_ptr_try_get_object_exact_fast |
exception_ptr_unique | Returns whether the stored exception is uniquely referenced. |
exception_ptr_use_count | Returns the reference count of the stored exception. |
exchange | Replaces the state of a PrimaryPtr with a new value and returns the old one. |
exchangeCurrentAsyncStackRoot | Exchange the current thread's active AsyncStackRoot with the specified AsyncStackRoot pointer, returning the old AsyncStackRoot pointer. |
extractFirstSet | extractFirstSet |
fdatasyncNoInt | Synchronizes a file's data to storage, retrying on EINTR. |
fetch | Utility method to help access elements of a sequence with one uniform interface. |
findFirstSet | findFirstSet overloads |
findFixed | Linear search for a value in a range whose size is known at compile time. |
findLastSet | findLastSet |
fingerprint128 | Compute the 128-bit Rabin fingerprint of a string. Return the 64 most significant bits in *msb, and the 64 least significant bits in *lsb. |
fingerprint64 | Return the 64-bit Rabin fingerprint of a string. |
fingerprint96 | Compute the 96-bit Rabin fingerprint of a string. Return the 64 most significant bits in *msb, and the 32 least significant bits in *lsb. |
flockNoInt | Applies an advisory lock, retrying on EINTR. |
fmap_shared_ptr_aliasing | fmap_shared_ptr_aliasing overloads |
fmt_make_format_args_from_map | Builds a dynamic format-args store from the key/value pairs in map. |
fmt_vformat_mangle_name | fmt_vformat_mangle_name overloads |
for_each | folly::for_each is a generalized iteration algorithm. Example: |
format | format overloads |
forward_like | Forwards a value with the value category of another type. |
forward_tuple | Get a tuple of references from the passed tuple, forwarding will be applied on the individual types of the tuple based on the value category of the passed tuple |
front_emplacer | Convenience function to construct a folly::front_emplace_iterator, analogous to std::front_inserter(). |
fsyncNoInt | Synchronizes a file's state to storage, retrying on EINTR. |
ftruncateNoInt | Truncates a file by descriptor, retrying on EINTR. |
getAsyncStackTraceFromInitialFrame | Given an initial AsyncStackFrame, this will write addresses with the return addresses of the frames in this async stack trace, up to maxAddresses written. This assumes addresses has maxAddresses allocated space available. |
getBaseLoggingConfig | folly::getBaseLoggingConfig() allows individual executables to easily customize their default logging configuration. |
getCPUExecutor [deprecated] | methodset Deprecated |
getCurrentAsyncStackRoot | Get access to the current thread's top-most AsyncStackRoot. |
getCurrentThreadID | Get a process-specific identifier for the current thread. |
getCurrentThreadName | Equivalent to getThreadName(std::this_thread::get_id()); |
getDetachedRootAsyncStackFrame | Get a pointer to a special frame that can be used as the root-frame for a chain of AsyncStackFrame that does not chain onto a normal call-stack. |
getEventBase [deprecated] | methodset Deprecated |
getExecutorBlockingContext | Returns the current thread's executor blocking context, if any is active. |
getGlobalCPUExecutor | methodset Executors |
getGlobalCPUExecutorCounters | methodset Executors |
getGlobalCPUExecutorWeakRef | methodset Executors |
getGlobalIOExecutor | methodset Executors |
getHugePageSize | Return the mount point for the requested huge page size. 0 = use smallest available. Returns nullptr if the requested huge page size is not available. |
getHugePageSizeForDevice | Return the huge page size for a device. returns nullptr if device does not refer to a huge page filesystem. |
getHugePageSizes | Get list of supported huge page sizes and their mount points, if hugetlbfs file systems are mounted for those sizes. |
getIOExecutor [deprecated] | methodset Deprecated |
getJEMallocMallctlArenasAll | Return value of MALLCTL_ARENAS_ALL defined in jemalloc's header. |
getKeepAliveToken | getKeepAliveToken overloads |
getOSThreadID | Get the operating-system level thread ID for the current thread. |
getRefOrDefault | getRefOrDefault overloads |
getTCMallocNumericProperty | Gets the named property. |
getTerminateCancellationToken | Returns a CancellationToken that can be used to schedule callbacks. The CancellationToken is cancelled when any of SIGTERM and SIGINT signal is received. |
getThreadName | Get the name of the given thread, or nothing if an error occurs or the functionality is not available. |
getUnsafeMutableGlobalCPUExecutor | methodset Executors |
getUnsafeMutableGlobalEventBase | methodset Executors |
getUnsafeMutableGlobalIOExecutor | methodset Executors |
getWeakRef | Returns a weak keep-alive to executor that does not extend its lifetime. |
getXlogCategoryNameForFile | Get the default XLOG() category name for the given filename. |
get_bit_at | Read the bit at position idx from an array of unsigned integers. |
get_cached_pid | Calls getpid() and returns the returned value, with a thread-safe cache in front. The cache is updated in the child after fork(). |
get_deadlock_detector_factory_instance | Weak hook resolving to the deadlock detector factory instance getter. |
get_default | get_default overloads |
get_deleter | Getters |
get_emplace_arg | get_emplace_arg overloads |
get_exception | get_exception overloads |
get_mutable_exception | get_mutable_exception overloads |
get_optional | get_optional overloads |
get_or_throw | get_or_throw overloads |
get_pointer | get_pointer overloads |
get_process_phase | Get the current process phase. |
get_ptr | get_ptr overloads |
get_ptr2 | Same as get_ptr but for find variants that search for two keys at once. |
get_ref_default | get_ref_default overloads |
get_rich_error | get_rich_error overloads |
get_underlying | get_underlying overloads |
getline | getline overloads |
globalJemallocNodumpAllocator | JemallocNodumpAllocator singleton. |
goodMallocSize | Simple wrapper around nallocx |
greater_than | Safely compares whether lhs is greater than the compile-time constant rhs. |
grow_capacity_by | Grows c to accommodate n additional elements with geometric growth. |
hardware_timestamp | Returns a hardware timestamp counter value. |
hardware_timestamp_measurement_start | hardware_timestamp_measurement_start hardware_timestamp_measurement_stop |
hardware_timestamp_measurement_stop | Ends precise measurement of a region of code and returns a timestamp. |
hasSpaceOrCntrlSymbols | Returns if string contains std::isspace or std::iscntrl characters. |
hash_value | hash_value overloads |
hazard_pointer_clean_up | Reclaim all retired objects in a domain that are no longer protected. |
hazard_pointer_default_domain | Access the process-wide default hazard pointer domain. |
hazptr_cleanup | Reclaim all retired objects in a domain that are no longer protected. |
hazptr_domain_push_retired | Push a list of retired objects into a domain for later reclamation. |
hazptr_retire | Retire an object so it is reclaimed once no hazard pointer protects it. |
hazptr_tc_evict | hazptr_tc_evict -- Used only for benchmarking |
hazptr_tc_tls | Access the thread-local hazard pointer cache. |
hazptr_use_executor | Report whether hazard pointer reclamation may use an executor. |
hexDump | hexDump overloads |
hex_decode_digit | hex_decode_digit |
hex_decode_digit_flavor_aarch64 | hex_decode_digit_flavor_aarch64 |
hex_decode_digit_flavor_x86_64 | hex_decode_digit_flavor_x86_64 |
hex_decode_digit_raw | hex_decode_digit_raw |
hex_decode_digit_raw_flavor_aarch64 | hex_decode_digit_raw_flavor_aarch64 |
hex_decode_digit_raw_flavor_x86_64 | hex_decode_digit_raw_flavor_x86_64 |
hex_decode_digit_table | hex_decode_digit_table |
hex_decoded_digit_is_valid | hex_decoded_digit_is_valid |
hex_is_digit | hex_is_digit |
hex_is_digit_flavor_aarch64 | hex_is_digit_flavor_aarch64 |
hex_is_digit_flavor_x86_64 | hex_is_digit_flavor_x86_64 |
hex_is_digit_table | hex_is_digit_table |
hexlify | hexlify overloads |
hint_emplacer | Convenience function to construct a folly::hint_emplace_iterator, analogous to std::inserter(). |
humanify | humanify overloads |
identity | Returns the argument unchanged. |
init [deprecated] | Initializes folly (deprecated non-RAII form). |
initLogging | initLogging overloads |
initLoggingOrDie | initLoggingOrDie overloads |
initializeLoggerDB | initializeLoggerDB() will be called to configure the main LoggerDB singleton the first time that LoggerDB::get() is called. |
invocable_to | Wraps the invocable for lazy conversion to its result type. |
invoke_cold | invoke_cold overloads |
invoke_noreturn_cold [noreturn] | invoke_noreturn_cold |
irange | irange overloads |
isLogLevelFatal | Returns true if and only if a LogLevel is fatal. |
isPowTwo | Return true if and only if v is a power of two. |
isSet | Tests whether all flags of b are set in a. |
isSuspendedLeafActive | Returns whether the given leaf frame is currently an active suspended leaf. |
is_constant_evaluated_or | Reports whether evaluation occurs in a constant context, with a default. |
is_negative | Determines whether a value is negative, the same as x < 0. |
is_non_negative | Determines whether a value is non-negative, the same as x >= 0. |
is_non_positive | Determines whether a value is non-positive, the same as x <= 0. |
is_positive | Determines whether a value is positive, the same as x > 0. |
join | join overloads |
kahan_sum | kahan_sum overloads |
lazy | Creates a lazy value whose initialization is deferred until first use. |
less_than | Safely compares whether lhs is less than the compile-time constant rhs. |
linux_syscall_openat2 | linux_syscall_openat2 |
loadUnaligned | Read an unaligned value of type T and return it. |
lock | lock overloads |
logConfigToDynamic | logConfigToDynamic overloads |
logDisabledHelper | logDisabledHelper overloads |
logLevelToString | Get a human-readable string representing the LogLevel. |
ltrim | Specify characters to ltrim. |
ltrimWhitespace | Remove leading whitespace. |
makeAutoTimer | Creates an AutoTimer with deduced logger and clock types. |
makeBitIterator | Helper function, so you can write auto bi = makeBitIterator(container.begin()); |
makeConversionError | Custom Error Translation |
makeDelayedDestructionUniquePtr | Creates a DelayedDestructionUniquePtr owning a new object. |
makeDismissedGuard | Create a scope guard in the dismissed state. |
makeExpected | For constructing an Expected object from a value, with the specified Error type. Usage is as follows: |
makeFixedString | ** ** ** ** ** ** ** ** ** ** ** ** ** ** ** ** ** ** ** ** ** ** ** ** ** Construct a BasicFixedString object from a null-terminated array of characters. The capacity and size of the string will be equal to one less than the size of the array. |
makeGuard | Create a scope guard. |
makeMoveWrapper | Make a MoveWrapper from the argument. Because the name "makeMoveWrapper" is already quite transparent in its intent, this will work for lvalues as if you had wrapped them in std::move. |
makeSystemError | makeSystemError overloads |
makeSystemErrorExplicit | makeSystemErrorExplicit overloads |
makeTryWith | makeTryWith overloads |
makeTryWithNoUnwrap | makeTryWithNoUnwrap overloads |
makeUnexpected | For constructing an Unexpected object from an error code. Unexpected objects are implicitly convertible to Expected object in the error state. Usage is as follows: |
makeUnpredictable | Hide a value from the optimizer so it cannot shape the following code. |
make_array | Constructs a std::array with the given argument list. |
make_array_with | Generates a std::array<..., Size> with elements m(i) for i in [0, Size).] |
make_atomic_ref | Build an atomic_ref referring to the given object. |
make_coded_rich_error | make_coded_rich_error overloads |
make_dynamic_view | make_dynamic_view overloads |
make_emplace_args | Pack arguments in a tuple for assignment to a folly::emplace_iterator, folly::front_emplace_iterator, or folly::back_emplace_iterator. The iterator's operator= will unpack the tuple and pass the unpacked arguments to the container's emplace function, which in turn forwards the arguments to the (multi-argument) constructor of the target class. |
make_erased_unique | make_erased_unique |
make_error_code | Builds a std::error_code from an args-file expansion error code. |
make_exception_ptr_with | make_exception_ptr_with overloads |
make_exception_wrapper | Builds an exception_wrapper wrapping a newly constructed exception. |
make_hazard_pointer | make_hazard_pointer overloads |
make_hazard_pointer_array | make_hazard_pointer_array overloads |
make_inheriting_coded_rich_error | make_inheriting_coded_rich_error overloads |
make_nestable_coded_rich_error | make_nestable_coded_rich_error overloads |
make_not_null_shared | Creates a not_null_shared_ptr, like std::make_shared. |
make_not_null_unique | Creates a not_null_unique_ptr, like std::make_unique. |
make_optional | make_optional overloads |
make_replaceable | make_replaceable overloads |
make_std_seed_seq | Constructs a std::seed_seq from the given seed value. |
mallctlCall | Invokes a mallctl command that neither reads nor writes a value. |
mallctlRead | Reads a value from jemalloc through the named mallctl command. |
mallctlReadWrite | Writes a value and reads the previous one through the named mallctl command. |
mallctlWrite | Writes a value to jemalloc through the named mallctl command. |
manual_safe_callable | Wraps a callable, asserting the given safety level; see manual_safe_callable_t. |
manual_safe_ref | Wraps a reference, asserting the given safety level; see manual_safe_ref_t. |
manual_safe_val | Wraps a value, asserting the given safety level; see manual_safe_val_t. |
manual_safe_with | Wraps the result of fn, asserting the given safety level. |
match_empty_function_protocol | match_empty_function_protocol overloads |
memory_order_load | The load part of a possibly-composite memory order. |
memory_order_store | The store part of a possibly-composite memory order. |
memrchr | memrchr overloads |
merge | merge overloads |
midpoint | midpoint overloads |
mlock2wrapper | mlock2 is Linux-only and exists since Linux 4.4 On Linux pre-4.4 and other platforms fail with ENOSYS. glibc added the mlock2 wrapper in 2.27 https://lists.gnu.org/archive/html/info-gnu/2018-02/msg00000.html |
mmapFileCopy | Copy a file using mmap(). Overwrites dest. |
n_least_significant_bits | Return a value of type T with the n least significant bits set. |
n_most_significant_bits | Return a value of type T with the n most significant bits set. |
nextPowTwo | Return the smallest power of two that is greater than or equal to v. |
object_from_member | object_from_member overloads |
openNoInt | Convenience wrappers around some commonly used system calls. The *NoInt wrappers retry on EINTR. The *Full wrappers retry on EINTR and also loop until all data is written. Note that *Full wrappers weaken the thread semantics of underlying system calls. |
operator co_await | Coawait operators |
operator""_csv | User-defined literal building a cstring_view from a string literal. |
operator""_fs | ** ** ** ** ** ** ** ** ** ** ** ** ** ** ** ** ** ** ** ** ** ** ** ** ** * User-defined literals for creating FixedString objects from string literals on the compilers that support it. |
operator""_fs128 | Creates a FixedString<128> from a string literal. |
operator""_fs16 | Creates a FixedString<16> from a string literal. |
operator""_fs32 | Creates a FixedString<32> from a string literal. |
operator""_fs4 | Creates a FixedString<4> from a string literal. |
operator""_fs64 | Creates a FixedString<64> from a string literal. |
operator""_fs8 | Creates a FixedString<8> from a string literal. |
operator""_lit | User-defined literal yielding the literal string value. |
operator""_litv | User-defined literal yielding a value tag of the literal string. |
operator""_shellify | Creates a shell command formatter from a string literal. |
operator""_sp | operator""_sp overloads |
operator""_uzic | operator""_uzic |
operator% | Modulus operators |
operator%= | operator%= |
operator& | Bitwise conjunction operators |
operator&= | Intersects a with b in place. |
operator* | Multiplies two dynamics. |
operator+ | Addition operators |
operator+= | Add an integer to a LogLevel in place, capping at LogLevel::MAX_LEVEL. |
operator- | Subtraction operators |
operator-= | Subtract an integer from a LogLevel in place. |
operator/ | Division operators |
operator/= | operator/= |
operator>> | Right shift operators |
operator^ | Bitwise-XORs two dynamics. |
operator_delete | operator_delete overloads |
operator_new | operator_new overloads |
operator| | Bitwise disjunction operators |
operator|= | Unions b into a in place. |
operator~ | Computes the complement of a flag set. |
or_unwind_epitaph | or_unwind_epitaph overloads |
overload | Combine multiple Cases in one function object |
parseJson | Parse a json blob out of a range and produce a dynamic representing it. |
parseJson5 [deprecated] | Parse an experimental json5 blob and produce a dynamic representing it. |
parseJsonWithMetadata | parseJsonWithMetadata overloads |
parseLogConfig | Parse a log configuration string. |
parseLogConfigDynamic | Parse a folly::dynamic object. |
parseLogConfigJson | Parse a JSON configuration string. |
parseNestedCommandLine | parseNestedCommandLine overloads |
parseTo | parseTo overloads |
partialLoadUnaligned | Read l bytes into the low bits of a value of an unsigned integral type T, where l < sizeof(T). |
poly_call | ///////////////////////////////////////////////////////////////////////////// |
poly_cast | poly_cast overloads |
poly_empty | ///////////////////////////////////////////////////////////////////////////// |
poly_move | ///////////////////////////////////////////////////////////////////////////// |
poly_type | ///////////////////////////////////////////////////////////////////////////// |
popAsyncStackFrameCallee | Pop the 'callee' frame off the stack, restoring the parent frame as the current frame. |
popcount | popcount |
preadFull | Like readFull but reads at a given offset. |
preadNoInt | Reads from a file descriptor at an offset, retrying on EINTR. |
preadv | Reads into multiple buffers from a file at a given offset. |
preadvFull | Like readvFull but scatter-reads at a given offset. |
preadvNoInt | Scatter-reads from a file descriptor at an offset, retrying on EINTR. |
prettyPrint | Pretty printer for numbers with units. |
prettyToDouble | prettyToDouble overloads |
pretty_name | Returns a statically-allocated C string containing the pretty name of T. |
printResultComparison | Print a comparison between two sets of benchmark results. |
processLocalUniqueId | Generates a 64-bit id that is unique within the process. The returned ids should not be persisted or passed to other processes, and there are no ordering guarantees. |
pushAsyncStackFrameCallerCallee | Push the 'callee' frame onto the current thread's async stack, deactivating the 'caller' frame and setting up the 'caller' to be the parent-frame of the 'callee'. |
pwriteFull | Like writeFull but writes at a given offset. |
pwriteNoInt | Writes to a file descriptor at an offset, retrying on EINTR. |
pwritev | Writes multiple buffers to a file at a given offset. |
pwritevFull | Like writevFull but gather-writes at a given offset. |
pwritevNoInt | Gather-writes to a file descriptor at an offset, retrying on EINTR. |
qfind | qfind overloads |
qfind_first_of | qfind_first_of overloads |
randomNumberSeed | Return a good seed for a random number generator. |
range | range overloads |
rcu_barrier | Waits for all in-flight deleters in the domain to complete. |
rcu_default_domain | Returns the process-wide default RCU domain. |
rcu_retire | Retires a pointer, invoking its deleter after a grace period. |
rcu_synchronize | Waits for all pre-existing RCU readers in the domain to complete. |
readFile | readFile overloads |
readFull | Wrapper around read() (and pread()) that, in addition to retrying on EINTR, will loop until all data is read. |
readNoInt | Reads from a file descriptor, retrying on EINTR. |
readvFull | Like readFull but scatter-reads into multiple buffers. |
readvNoInt | Scatter-reads from a file descriptor, retrying on EINTR. |
reinterpret_function_cast | reinterpret_function_cast overloads |
reinterpret_pointer_cast | reinterpret_pointer_cast overloads |
reinterpret_span_cast | Casts in to a span of U over the same memory using reinterpret_cast. |
relinquish | relinquish overloads |
reserve_if_available | Reserves space for n elements when C provides a reserve() member. |
reset_once | reset_once overloads |
result_catch_all | Wraps the return value from the lambda fn in a result, putting any thrown exception into its "error" state. |
result_to_try | Converts a result<T> to a Try<T>. |
resumeCoroutineWithNewAsyncStackRoot | resumeCoroutineWithNewAsyncStackRoot overloads |
rethrow_current_exception [noreturn] | rethrow_current_exception |
rfind | Finds the last occurrence of needle in haystack. The result is the offset reported to the beginning of haystack, or string::npos if needle wasn't found. |
rlock | Make a shared locking helper for a const object. |
rref | rref overloads |
rtrim | Specify characters to rtrim. |
rtrimWhitespace | Remove trailing whitespace. |
runBenchmarks | Runs all benchmarks defined. Usually put in main(). |
runBenchmarksOnFlag | Runs all benchmarks defined if and only if the --benchmark flag has been passed to the program. Usually put in main(). |
seed_seq_generate | Fills the destination buffer with data generated from the seed sequence. |
select64 | Returns the position of the k-th 1 in the 64-bit word x. k is 0-based, so k=0 returns the position of the first 1. |
setCPUExecutor [deprecated] | methodset Deprecated |
setCPUExecutorToGlobalCPUExecutor [deprecated] | methodset Deprecated |
setIOExecutor [deprecated] | methodset Deprecated |
setKeepAliveObjTraceHooks | Install (or, with all-null arguments, remove) the keep-alive object tracing hooks. |
setThreadName | setThreadName overloads |
setUnsafeMutableGlobalCPUExecutor | methodset Executors |
setUnsafeMutableGlobalCPUExecutorToGlobalCPUExecutor | methodset Executors |
setUnsafeMutableGlobalIOExecutor | methodset Executors |
set_n_least_significant_bits | Set the n least significant bits of x, leaving the others unchanged. |
set_n_most_significant_bits | Set the n most significant bits of x, leaving the others unchanged. |
set_once | set_once overloads |
set_process_phases | Start Regular phase and register handler to set Exit phase. To be called exactly once in each program that uses Folly. Ideally, it is to be called from folly::init(), which in turn is to be called by every program that uses Folly. |
setupIoUringBufferPoolSharing | setupIoUringBufferPoolSharing overloads |
sformat | sformat overloads |
shellQuote | Quotes an argument to make it suitable for use as shell command arguments. |
shellify [deprecated] | Create argument array for Subprocess() for a process running in a shell. |
shutdownNoInt | Shuts down a socket, retrying on EINTR. |
sizedAlignedFree | Free a buffer previously returned by checkedAlignedMalloc. |
sizedArrayFree | Free a buffer previously returned by checkedArrayMalloc<T>. |
sizedFree | Frees's memory using sdallocx if possible |
skipWhitespace | DEPRECATED: Use ltrimWhitespace instead |
smartRealloc | Reallocs if there is less slack in the buffer, else performs malloc-copy-free. |
sourceLocationToString | Formats a source location as "file:line [function]". |
split | split overloads |
splitFuture | Convenience function, allowing us to exploit template argument deduction to improve readability. |
splitTo | split, to an output iterator |
splitmix64 | splitmix64 |
stable_radix_sort | stable_radix_sort overloads |
stable_radix_sort_descending | stable_radix_sort_descending overloads |
stack_epitaph | stack_epitaph overloads |
static_pointer_cast | static_pointer_cast overloads |
static_span_cast | Casts in to a span of U over the same memory using static_cast. |
std_bitset_find_first | Return the index of the first set bit in a bitset, or bitset.size() if none. |
std_bitset_find_next | Return the index of the first set bit in a bitset after the given index, or bitset.size() if none. |
storeUnaligned | Write an unaligned value of type T. |
strictNextPowTwo | Return the smallest power of two that is strictly greater than v. |
strictPrevPowTwo | Return the largest power of two that is strictly less than v. |
stringAppendf | Append printf-style output to string. |
stringPrintf | stringPrintf overloads |
stringToLogLevel | Construct a LogLevel from a string name. |
stringVAppendf | Append va_list printf-style output to string. |
stringVPrintf | stringVPrintf overloads |
stripLeftMargin | De-indent a string. |
strlcpy | Copy a C string, size-bounded and always null-terminated (mimics BSD strlcpy). |
swap | swap overloads |
sweepSuspendedLeafFrames | Apply fn on all suspended leaf frames. Note: Avoid performing async work within fn as it may cause deadlocks. |
synchronized | Acquire locks for multiple Synchronized<> objects, in a deadlock-safe manner. |
tag_invoke | tag_invoke overloads |
terminate_with [noreturn] | terminate_with |
terminate_with_fmt_format [noreturn] | Formats a message with fmt and terminates with an exception built from it. |
test_once | test_once overloads |
throwSystemError [noreturn] | Throws a std::system_error from the current errno and components of a string. |
throwSystemErrorExplicit [noreturn] | throwSystemErrorExplicit overloads |
throw_exception [noreturn] | throw_exception |
throw_exception_fmt_format [noreturn] | Formats a message with fmt and throws an exception constructed from it. |
to | to overloads |
toAppend | toAppend overloads |
toAppendDelim | toAppendDelim overloads |
toAppendDelimFit | toAppendDelimFit overloads |
toAppendFit | toAppendFit overloads |
toDelim | toDelim overloads |
toDynamic | Turn an arbitrary type into a dynamic. |
toJson | Serialize a dynamic into a json string. |
toLowerAscii | toLowerAscii overloads |
toPrettyJson | Serialize a dynamic into a json string with indentation. Note that the keys of all objects will be sorted. |
toStdString | toStdString overloads |
toUpperAscii | toUpperAscii overloads |
to_ascii_decimal | to_ascii_decimal overloads |
to_ascii_lower | to_ascii_lower overloads |
to_ascii_size | Number of digits in the base-Base representation of v. |
to_ascii_size_decimal | Number of decimal digits in v; alias of to_ascii_size<10>. |
to_ascii_upper | to_ascii_upper overloads |
to_ascii_with | to_ascii_with overloads |
to_bool | Constructs a boolean from the argument. |
to_erased_unique_ptr | to_erased_unique_ptr |
to_floating_point | Wraps the argument for floating-point conversion. |
to_integral | Wraps the argument for integral conversion. |
to_narrow | Wraps the argument for narrowing conversion. |
to_ordering | Convert a signed comparison value into the matching ordering. |
to_shared_ptr | to_shared_ptr |
to_shared_ptr_aliasing | to_shared_ptr_aliasing overloads |
to_shared_ptr_non_owning | to_shared_ptr_non_owning |
to_signed | Converts the argument to the corresponding signed type. |
to_underlying | Converts an enum value to its underlying type. |
to_unsigned | Converts the argument to the corresponding unsigned type. |
to_weak_ptr | to_weak_ptr |
to_weak_ptr_aliasing | to_weak_ptr_aliasing |
transition_lock | Atomically transitions from the from-lock to the to-lock, waiting unboundedly for the transition to become available. |
transition_to_shared_lock | transition_to_shared_lock overloads |
transition_to_unique_lock | Eventually and atomically upgrades an upgrade lock to an exclusive lock. |
transition_to_upgrade_lock | Immediately and atomically downgrades an exclusive lock to an upgrade lock. |
trim | Specify characters to trim. |
trimWhitespace | Remove leading and trailing whitespace. |
truncateNoInt | Truncates a file by path, retrying on EINTR. |
tryAssign | Try to move the value/exception from another Try object. |
tryDecodeVarint | A variant of decodeVarint() that does not throw on error. Useful in contexts where only part of a serialized varint may be attempted to be decoded, e.g., when a serialized varint arrives on the boundary of a network packet. |
tryEmplace | tryEmplace overloads |
tryEmplaceWith | tryEmplaceWith overloads |
tryGetCurrentAsyncStackRoot | Get access to the current thread's top-most AsyncStackRoot. |
tryGetShutdownSocketSet | Returns the process-global shutdown socket set, if one has been installed. |
tryGetShutdownSocketSetFast | Returns the process-global shutdown socket set using a read-mostly pointer. |
trySplitTo | Try to split a string into a fixed number of fields by delimiter, using folly::tryTo<> for conversions. types by delimiter. - On success, all output values will be initialized and the 'Unit{}' value is returned. Arguments are assigned in reverse order. - On failure, the first failing 'ConversionCode' is returned with its associated substring in a 'SubstringConversionCode'. - String splitting is performed prior to each conversion; field values will not contain the delimiter. - All custom error codes are mapped to ConversionCode::CUSTOM. |
tryTo | tryTo overloads |
tryUriUnescape | tryUriUnescape overloads |
try_and_catch | try_and_catch is a convenience for try {} catch(...) {}` that returns an exception_wrapper with the thrown exception, if any. |
try_call_once | try_call_once overloads |
try_to_result | try_to_result overloads |
try_transition_lock | Attempts an atomic transition from the from-lock to the to-lock, without waiting if the transition is not immediately available. |
try_transition_lock_for | Attempts an atomic transition from the from-lock to the to-lock, waiting up to the given timeout for the transition to become available. |
try_transition_lock_until | Attempts an atomic transition from the from-lock to the to-lock, waiting up to the given deadline for the transition to become available. |
try_transition_to_unique_lock | try_transition_to_unique_lock overloads |
try_transition_to_unique_lock_for | try_transition_to_unique_lock_for overloads |
try_transition_to_unique_lock_until | try_transition_to_unique_lock_until overloads |
try_transition_to_upgrade_lock | Immediately attempts to atomically upgrade a shared lock to an upgrade lock. |
try_transition_to_upgrade_lock_for | Attempts, up to a timeout, to atomically upgrade a shared lock to an upgrade lock. |
try_transition_to_upgrade_lock_until | Attempts, up to a deadline, to atomically upgrade a shared lock to an upgrade lock. |
type_info_of | type_info_of overloads |
ulock | Make an upgrade locking helper. |
unSet | Clears the flags of b from a. |
uncaught_exceptions | uncaught_exceptions |
uncurry | Wraps a function taking N arguments into a function which accepts a tuple of N arguments. Note: This function will also accept an std::pair if N == 2. |
unexpected | Disambiguation tag for constructing an Expected in the error state. |
unhexlify | unhexlify overloads |
unicode_code_point_from_utf16_surrogate_pair | Combines a UTF-16 surrogate pair into a single code point. |
unicode_code_point_to_utf8 | Encodes a single Unicode code point into a UTF-8 byte sequence. |
unique_hash_key_algo_strong_sha256 | Hash the input items with SHA256, returning a Size-byte digest. |
unsafe_unscoped_init | Initializes folly without an RAII scope guard. |
unwrapTryTuple | Unwrap a tuple of Try values into a tuple of values. |
uriEscape | uriEscape overloads |
uriUnescape | uriUnescape overloads |
usingJEMalloc | Determines whether the process is using jemalloc. |
usingTCMalloc | Determines whether the process is using tcmalloc. |
utf16_code_unit_is_bmp | Returns whether a UTF-16 code unit lies in the Basic Multilingual Plane. |
utf16_code_unit_is_high_surrogate | Returns whether a UTF-16 code unit is a high surrogate. |
utf16_code_unit_is_low_surrogate | Returns whether a UTF-16 code unit is a low surrogate. |
utf8ToCodePoint | Decode a single Unicode code point from UTF-8 byte sequence. |
uuid_parse | uuid_parse overloads |
uuid_parse_buffer_to_buffer | Parses a 36-byte UUID string into a 16-byte buffer. |
valid_align_value | Returns whether the given alignment value is valid. |
validateSocketOptions | Returns the subset of options that apply to the given family and position. |
variadic_noop | Does nothing regardless of the arguments passed. |
variant_match | variant_match overloads |
wlock | wlock overloads |
writeFile | writeFile overloads |
writeFileAtomic | writeFileAtomic overloads |
writeFileAtomicNoThrow | writeFileAtomicNoThrow overloads |
writeFull | Similar to readFull and preadFull above, wrappers around write() and pwrite() that loop until all data is written. |
writeNoInt | Writes to a file descriptor, retrying on EINTR. |
writevFull | Like writeFull but gather-writes from multiple buffers. |
writevNoInt | Gather-writes to a file descriptor, retrying on EINTR. |
x86_cpuid | x86_cpuid |
x86_cpuid_get_cache_info | Returns cache info for the cache with the given id for the given vendor. |
x86_cpuid_get_llc_cache_info | x86_cpuid_get_llc_cache_info overloads |
x86_cpuid_get_vendor | Detects the CPU vendor via the cpuid instruction. |
x86_cpuid_max | Returns the maximum supported cpuid leaf for the given leaf group. |
xlogIsDirSeparator | Tests whether a character is a directory separator. |
xlogStripFilename | Strip directory prefixes from a filename before using it in XLOG macros. |
operator<< | Left shift operators |
operator== | Equality operators |
operator!= | Inequality operators |
operator< | Less-than operators |
operator<= | Less-than-or-equal operators |
operator> | Greater-than operators |
operator>= | Greater-than-or-equal operators |
operator<=> | Three-way comparison operators |
| Name | Description |
|---|---|
adopt_lock_state | Tag value indicating that a lock transition should adopt existing lock state. |
always_false | always_false |
atomic_fetch_flip | Customization point object that flips a bit and returns its previous value. |
atomic_fetch_modify | Customization point object that atomically transforms an atomic value. |
atomic_fetch_reset | Customization point object that resets a bit and returns its previous value. |
atomic_fetch_set | Customization point object that sets a bit and returns its previous value. |
atomic_notify_all | Wakes all threads waiting on the atomic, like futex wake with max count. |
atomic_notify_one | Wakes one thread waiting on the atomic, like futex wake with count 1. |
atomic_wait | Blocks until the atomic changes from an expected value, like futex wait. |
atomic_wait_until | Blocks until the atomic changes or a deadline passes, returning cv_status. |
available_concurrency_max_env | The environment variable name used to cap available_concurrency(). |
cacheline_align_v | A value corresponding to hardware_constructive_interference_size but which may be used with alignas, since hardware_constructive_interference_size may be too large on some platforms to be used with alignas. |
constexpr_iterated_squares_desc_2_v | constexpr_iterated_squares_desc_2_v |
constexpr_iterated_squares_desc_size_v | constexpr_iterated_squares_desc_size_v |
constexpr_iterated_squares_desc_v | constexpr_iterated_squares_desc_v |
default_domain | Global default domain defined in Hazptr.cpp |
demangle_max_symbol_size | Maximum symbol size that demangling will attempt, or 0 for no limit. |
emptySocketOptionMap | An empty socket option map. |
empty_try_as_error | The empty-Try-as-error policy value. |
factory_constructor | Tag value selecting the factory constructor of Indestructible. |
fmt_vformat_mangle_format_string | Callable that mangles the content of vformat format-strings. |
format_string_for_each_named_arg | Callable object enumerating the named arguments of a format string. |
function_arguments_size_v | The number of arguments in the given function type. |
function_is_nothrow_v | True precisely when the given function type is marked noexcept. |
function_is_variadic_v | True precisely when the given function type is C-style variadic. |
hardware_constructive_interference_size | The cache line size for true sharing, from the standard library. |
hardware_destructive_interference_size | The minimum spacing to avoid false sharing, from the standard library. |
has_extended_alignment | has_extended_alignment |
hex_alphabet_lower | hex_alphabet_lower |
hex_alphabet_table | hex_alphabet_table |
hex_alphabet_upper | hex_alphabet_upper |
initlist_construct | Tag value used to disambiguate initializer-list construction. |
is_allocator_v | is_allocator_v is_allocator |
is_applicable_r_v | True if applying F to the elements of Tuple yields a result convertible to R. |
is_applicable_v | True if F is invocable with the elements of Tuple. |
is_arithmetic_v | A trait variable that is true when T is an arithmetic type. |
is_bounded_array_v | is_bounded_array_v is_bounded_array |
is_bounded_array_v | A specialization of is_bounded_array_v for bounded array types. |
is_cleanup_v | True when T models the async cleanup concept (has a conforming cleanup()). |
is_complete_v | See is_complete. |
is_constexpr_default_constructible_v | is_constexpr_default_constructible_v is_constexpr_default_constructible |
is_contiguous_range_v | True when R is a contiguous range. |
is_coro_aware_mutex_v | Whether a type declares a folly_coro_aware_mutex nested typedef. |
is_detected_v | A trait variable to test whether a metafunction succeeds in substitution. |
is_enable_master_from_this_v | True if T publicly derives from EnablePrimaryFromThis. |
is_hashable_v | Checks that the given hasher template's specialization for the given type is usable with the standard library containters, for example std::unordered_set<T, Hasher<T>>. |
is_hasher_usable_v | Checks the requirements that the Hasher class must satisfy in order to be used with the standard library containers, for example std::unordered_set<T, Hasher>. |
is_heap_vector_map_v | True if T is an instantiation of heap_vector_map. |
is_heap_vector_set_v | True if T is an instantiation of heap_vector_set. |
is_instantiation_of_v | is_instantiation_of_v is_instantiation_of instantiated_from uncvref_instantiated_from |
is_instantiation_of_v | A specialization of is_instantiation_of_v for matching instantiations. |
is_integral_v | A trait variable that is true when T is an integral type. |
is_invocable_r_v | True if invoking F yields a result convertible to R; mimics std::is_invocable_r_v. |
is_invocable_v | True if F is invocable with A...; mimics std::is_invocable_v. |
is_non_bool_integral_v | is_non_bool_integral_v |
is_nothrow_applicable_r_v | True if the nothrow application of F to Tuple yields a result convertible to R. |
is_nothrow_applicable_v | True if F is nothrow-invocable with the elements of Tuple. |
is_nothrow_invocable_r_v | True if a nothrow invocation of F yields a result convertible to R; mimics std::is_nothrow_invocable_r_v. |
is_nothrow_invocable_v | True if F is nothrow-invocable with A...; mimics std::is_nothrow_invocable_v. |
is_nothrow_tag_invocable_r_v | True if a nothrow tag_invoke call yields a result convertible to R. |
is_nothrow_tag_invocable_v | True if the tag_invoke CPO is nothrow-invocable with Tag and Args. |
is_one_of_v | A trait variable that is true when T is one of the types Ts. |
is_register_pass_v | is_register_pass_v |
is_register_pass_v | Whether an lvalue reference may be passed in a register; always true. |
is_register_pass_v | Whether an rvalue reference may be passed in a register; always true. |
is_signed_v | A trait variable that is true when T is a signed type. |
is_small_sorted_vector_map_v | True if T is a sorted_vector_map backed by a small_vector. |
is_small_sorted_vector_set_v | True if T is a sorted_vector_set backed by a small_vector. |
is_small_vector_v | true if T is a specialization of folly::small_vector. |
is_sorted_vector_map_v | True if T is a sorted_vector_map specialization. |
is_sorted_vector_set_v | True if T is a sorted_vector_set specialization. |
is_tag_invocable_r_v | True if a tag_invoke call yields a result convertible to R. |
is_tag_invocable_v | True if the tag_invoke CPO can be invoked with Tag and Args. |
is_transparent_v | is_transparent_v is_transparent |
is_unbounded_array_v | is_unbounded_array_v is_unbounded_array |
is_unbounded_array_v | A specialization of is_unbounded_array_v for unbounded array types. |
is_unsigned_v | A trait variable that is true when T is an unsigned type. |
is_vector_bool_reference_v | True when T is the proxy reference type of a std::vector<bool>. |
is_vector_bool_reference_v | Specialization recognizing the libc++ std::vector<bool> bit reference. |
iterator_category_matches_v | Whether an iterator's category matches Category (std::input_iterator_tag, std::output_iterator_tag, etc). Defined for non-iterator types as well. |
iterator_has_known_distance_v | Whether std::distance over a pair of iterators is reasonably known to give the distance without advancing the iterators or copies of them. |
iterator_has_known_distance_v | Specialization for a matching iterator and sentinel type. |
kClangVerMajor | The Clang major version, or zero when not compiling with Clang. |
kCoreCachedSharedPtrDefaultMaxSlots | Default maximum number of core-local slots used by the cached pointers. |
kCpplibVer | The Dinkumware cpplib version, or zero when not using cpplib. |
kDefaultLogLevel | The default log level used when none is specified. |
kGlibcxxAssertions | True when libstdc++ assertions are enabled. |
kGlibcxxVer | The libstdc++ release version, or zero when not using libstdc++. |
kGnuc | The GCC major version, or zero when not compiling with GCC. |
kHasExceptions | True when the current build supports C++ exceptions. |
kHasRtti | True when run-time type information (RTTI) is enabled for this build. |
kHasUnalignedAccess | True when the target platform supports unaligned loads and stores. |
kHasWeakSymbols | True when the toolchain supports weak symbols. |
kIntegerDivisionGivesRemainder | True if integer division on this platform yields a remainder, i.e. the hardware division instruction produces both quotient and remainder. |
kIovMax | Maximum number of iovec buffers accepted by a scatter/gather call. |
kIsAndroid | True when the target operating system is Android. |
kIsApple | True when the target operating system is an Apple platform. |
kIsAppleIOS | True when the target Apple platform is iOS. |
kIsAppleMacOS | True when the target Apple platform is macOS. |
kIsAppleTVOS | True when the target Apple platform is tvOS. |
kIsAppleWatchOS | True when the target Apple platform is watchOS. |
kIsArchAArch64 | True when targeting the 64-bit ARM (AArch64) architecture. |
kIsArchAmd64 | True when targeting the 64-bit x86 (amd64) architecture. |
kIsArchArm | True when targeting the 32-bit ARM architecture. |
kIsArchPPC64 | True when targeting the 64-bit PowerPC architecture. |
kIsArchRISCV64 | True when targeting the 64-bit RISC-V architecture. |
kIsArchS390X | True when targeting the 64-bit IBM Z (s390x) architecture. |
kIsArchWasm | True when targeting WebAssembly. |
kIsArchWasm32 | True when targeting 32-bit WebAssembly. |
kIsArchWasm64 | True when targeting 64-bit WebAssembly. |
kIsArchX86 | True when targeting the 32-bit x86 architecture. |
kIsBigEndian | True when the target platform is big-endian. |
kIsClang | True when compiling with Clang. |
kIsDebug | True when the current build is a debug build. |
kIsFreeBSD | True when the target operating system is FreeBSD. |
kIsGlibcxx | True when the standard library is GNU libstdc++. |
kIsLibcpp | True when the standard library is LLVM libc++. |
kIsLibrarySanitizeAddress | True when folly itself was compiled with AddressSanitizer enabled. |
kIsLibstdcpp | True when the standard library is GNU libstdc++. |
kIsLinux | True when the target operating system is non-mobile Linux. |
kIsLinuxActual | True when the target operating system is Linux, mobile included. |
kIsLittleEndian | True when the target platform is little-endian. |
kIsMobile | True when targeting a mobile platform. |
kIsObjC | True when the current translation unit is compiled as Objective-C. |
kIsOptimize | True when the current build is optimized. |
kIsOptimizeSize | True when the current build is optimized for size. |
kIsSanitize | True when the current build uses any sanitizer. |
kIsSanitizeAddress | True when the current build uses AddressSanitizer. |
kIsSanitizeDataflow | True when the current build uses DataFlowSanitizer. |
kIsSanitizeThread | True when the current build uses ThreadSanitizer. |
kIsWindows | True when the target operating system is Windows. |
kLoggingEnvVarName | Environment variable name that controls folly logging configuration. |
kLoggingMinLevel | The compile-time minimum log level below which XLOG() statements compile out. |
kMaxVarintLength32 | Maximum length (in bytes) of the varint encoding of a 32-bit value. |
kMaxVarintLength64 | Maximum length (in bytes) of the varint encoding of a 64-bit value. |
kMicrosoftAbiVer | The Microsoft ABI version, or zero when not targeting the Microsoft ABI. |
kMinFatalLogLevel | The lowest log level considered fatal for the current build. |
kMinValidAddress | The lowest address that may be a valid mapped pointer on this platform. |
kMscVer | The MSVC compiler version, or zero when not compiling with MSVC. |
kWordSize | Number of bits in a machine word used by the bitset scanning routines. |
kWriteFlagsForTimestamping | Write flags that are related to timestamping. |
lenient_safe_alias_of_v | The safe_alias level of T, defaulting unannotated types to maybe_value. |
loop_break | Return value that tells for_each to stop iterating. |
loop_continue | Return value that tells for_each to continue iterating. |
match_safely_invocable_as_protocol_v | True if F matches the safely-invocable-as protocol for signature Sig. |
match_static_lambda_protocol_v | True if type F matches the static-lambda protocol (empty and trivially copyable). |
max_align_v | max_align_v is the alignment of max_align_t. |
none | Constant tag used to clear or construct an empty Optional. |
npos | The sentinel value returned by search functions when no match is found. |
range_has_known_distance_v | Whether std::distance over the begin and end iterators is reasonably known to give the distance without advancing the iterators or copies of them. |
rcu_default_domain_ | The pointer to the process-wide default RCU domain. |
register_pass_max_size | register_pass_max_size |
require_sizeof | require_sizeof |
resizeWithoutInitialization | Resizes a container without initializing newly added elements. |
sig | Pseudo-function template handy for disambiguating function overloads. |
sorted_equivalent | Tag value indicating a container is sorted but not necessarily unique. |
sorted_unique | Tag value indicating a container is sorted and unique. |
stopped_result | The stopped/cancellation signal value. |
strict_safe_alias_of_v | The safe_alias level of T, defaulting unannotated types to unsafe. |
tag | A generic type-list value. |
to_ascii_size_max | Maximum buffer size to hold the base-Base ASCII form of any value of unsigned type Int. |
to_ascii_size_max_decimal | Maximum buffer size for the decimal ASCII form of Int; alias of to_ascii_size_max<10>. |
type_list_find_v | type_list_find_v |
type_list_size_v | type_list_size_v |
type_pack_find_v | type_pack_find_v |
type_pack_size_v | type_pack_size_v |
unique_hash_key_algo_size_v | Digest size in bytes produced by the given hash algorithm object. |
unit | The single value of type Unit. |
unsafe_default_initialized | Object yielding a default-initialized value on conversion. |
value_list_element_v | value_list_element_v |
value_list_size_v | value_list_size_v |
value_pack_element_v | value_pack_element_type_t |
value_pack_size_v | value_pack_size_v |
variadic_constant_of | An invocable object that ignores its arguments and returns a constant. |
vtag | A generic value-list value. |
x86_cpuid_vendor_names | Vendor identification strings indexed by x86_cpuid_vendor. |
| Name | Description |
|---|---|
FollyFindFixedSupportedType | Concept for types supported by folly::findFixed: fixed-width integers and enums with such an underlying type. |
IsOptionalLike | Concept matching types with optional-like semantics (has_value/value), such as std::optional, folly::Optional, and Thrift optional fields. |
instantiated_from | A concept satisfied when T is an instantiation of the class template Templ. |
is_strong | Satisfied when T derives from strong instantiated with its own tag. |
passable_to | passable_to |
uncvref_instantiated_from | Like instantiated_from, but after stripping cvref qualifiers from T. |
uncvref_same_as | Concept to check that a type is same as a given type, when stripping qualifiers and refernces. Especially useful for perfect forwarding of a specific type. |
vector_bool_reference | Concept satisfied by the proxy reference type of a std::vector<bool>. |
| Name | Description |
|---|---|
FlagSaver | Imported gflags::FlagSaver. |
IsEqualityComparable | A trait to test whether values of T and U can be compared with operator==. |
IsLessThanComparable | A trait to test whether values of T and U can be compared with operator<. |
MoveOnly | Base that disallows copy but allows move in derived types. |
NonCopyableNonMovable | Base that disallows both copy and move in derived types. |
apply | /////////////////////////////////////////////////////////////////// |
decay_t | Like std::decay_t but possibly faster to compile. |
dynamic_extent | Sentinel extent value marking a span whose size is known only at runtime. |
invoke_result_t | The result type of invoking F with A...; mimics std::invoke_result_t. |
is_nothrow_convertible | A trait type that is true when one type is nothrow-convertible to another. |
is_nothrow_convertible_v | A trait variable that is true when one type is nothrow-convertible to another. |
nextafter | Most platforms hopefully provide std::nextafter, std::remainder. |
remainder | Imported std::remainder. |
shared_lock | Alias to std::shared_lock. |
tag_invoke_result_t | The result type of invoking the tag_invoke CPO with Tag and Args. |
unique_lock | Alias to std::unique_lock. |
Implementation helpers for make_array and make_array_with.
| Name | Description |
|---|---|
return_type_helper | Resolves the element type of the array produced by make_array. |
| Name | Description |
|---|---|
is_ref_wrapper | Trait that is true when T is a std::reference_wrapper. |
not_ref_wrapper | Trait that is true when the decayed T is not a std::reference_wrapper. |
return_type | The std::array type make_array returns for the given element types. |
| Name | Description |
|---|---|
make_array_with_ | Builds a std::array by invoking make for each index in the sequence. |
Implementation details.
| Name | Description |
|---|---|
DiscardHasDeferred | Whether a discarded SemiFuture carried a deferred executor. |
| Name | Description |
|---|---|
logBlockingOperation | Trace hook invoked for a blocking operation. |
logFutureVia | Trace hook invoked when a Future is rescheduled onto an executor. |
logGetGlobalCPUExecutor | Trace hook invoked when the global CPU executor is retrieved. |
logGetGlobalIOExecutor | Trace hook invoked when the global IO executor is retrieved. |
logGetImmutableCPUExecutor | Trace hook invoked when the immutable CPU executor is retrieved. |
logGetImmutableIOExecutor | Trace hook invoked when the immutable IO executor is retrieved. |
logSemiFutureDiscard | Trace hook invoked when a SemiFuture is discarded. |
logSemiFutureVia | Trace hook invoked when a SemiFuture is rescheduled onto an executor. |
logSetGlobalCPUExecutor | Trace hook invoked when the global CPU executor is set. |
logSetGlobalCPUExecutorToImmutable | Trace hook invoked when the global CPU executor is set to the immutable one. |
logSetGlobalIOExecutor | Trace hook invoked when the global IO executor is set. |
READ ME: The docs for this library are in Bind.md.
| Name | Description |
|---|---|
ext | Implements standard storage semantics for folly::bind. This is used (with some additional constraints & tweaks) by async_closure captures. It can also be used for other single-use data structurs -- this makes it easy to simultaneously define the types for, and construct, tuples, named tuples, structs, etc. Some examples of this are given in Bind.md. |
| Name | Description |
|---|---|
args | The primitive for representing lists of bound args. |
capture | bind::capture() and bind::capture_indirect() work much like other folly::bind modifiers. However, since they're primarily intended for async_closure arguments, you will practically only use them: - alone, for non-co_cleanup arguments; - with bind::in_place() or bind::in_place_with(), for co_cleanup arguments; - with constant(), for either. |
capture_const_ref | Sugar for capture{const_ref{...}}, capturing a const reference. |
capture_indirect | Binds an async-closure capture whose pointer-like value is dereferenced once to expose the underlying object. |
capture_mut_ref | Sugar for capture{mut_ref{...}}, capturing a mutable reference. |
const_ref | Binding modifier that binds a const reference to each argument. |
constant | Binding modifier that makes each argument const. |
copy | Binding modifier that passes its arguments as decay-copied prvalues. |
id_type | The "identifier tag -> storage type" signature for a named binding. |
move | Binding modifier that passes its arguments as rvalue references. |
mut | Binding modifier that keeps each argument mutable. |
mut_ref | Binding modifier that binds a mutable reference to each argument. |
self_id_type | The self-reference "identifier tag -> storage type" binding signature. |
| Name | Description |
|---|---|
capture_in_place | Bind an in-place-constructed capture of type T. |
capture_in_place_with | Bind an in-place-constructed capture built by a factory function. |
in_place | Binds in-place construction of T from the given arguments. |
in_place_with | Binds in-place construction via a maker callable plus the given arguments. |
operator""_id | User-defined literal building a bind::id<Str> from "x"_id. |
| Name | Description |
|---|---|
id | The identifier for the compile-time string Str; also spelled "x"_id. |
self_id | A special identifier tag that works just like "x"_id. |
Implements standard storage semantics for folly::bind. This is used (with some additional constraints & tweaks) by async_closure captures. It can also be used for other single-use data structurs -- this makes it easy to simultaneously define the types for, and construct, tuples, named tuples, structs, etc. Some examples of this are given in Bind.md.
| Name | Description |
|---|---|
bind_info_t | The binding flags for a bound argument. |
bind_to_storage_policy | Policy that maps a binding to the storage type used to hold its value. |
binding_t | Metadata for a single bound argument: its binding type plus binding flags. |
id_arg | A bound-args list tagged with the identifier string Str. |
identifier | A binding identifier tag, such as "x"_id or the self-reference tag. |
like_args | Base class for any type modeling a list of bound args with modifiers. |
merge_update_args | Concatenates several like_args lists, mapping each bind_info_t through BindInfoFn. |
named_bind_info_t | A bind_info_t extended with a compile-time identifier Tag. |
no_tag_t | Placeholder tag meaning a binding carries no name tag. |
self_id_arg | A bound-args list tagged with the self-reference identifier. |
self_id_t | Tag type marking the self-reference identifier. |
unsafe_move_args | Tag and factory for unsafely moving the contents of a like_args list. |
| Name | Description |
|---|---|
deduce_args_t | Deduces the stored binding type for a value passed to args and friends. |
| Name | Description |
|---|---|
category_t | Category flag controlling how a bound argument is passed or stored. |
constness_t | Constness flag applied to a bound argument. |
| Name | Description |
|---|---|
bind_as_argument | Forward a bound storage reference as the argument implied by its bind-info category. |
| Name | Description |
|---|---|
named_bind_info_tag_v | The name tag of a binding, or no_tag_t when the binding is unnamed. |
named_bind_info_tag_v | Specialization extracting the tag from a named binding info. |
| Name | Description |
|---|---|
is_binding_t_type_in_place | True when the binding type BT denotes in-place construction (a value type). |
Implementation details for BitIterator.
| Name | Description |
|---|---|
BitIteratorBase | Provides the boost::iterator_adaptor base type used by BitIterator. |
BitReference | Reference to a bit. |
BSER binary serialization for dynamic values.
| Name | Description |
|---|---|
BserDecodeError | Exception thrown when BSER-encoded input cannot be decoded. |
bser_deserialization_options | Options controlling how a BSER stream is deserialized. |
serialization_opts | Options controlling how a dynamic value is serialized to BSER. |
| Name | Description |
|---|---|
BserType | Type tags used in the BSER wire format. |
| Name | Description |
|---|---|
decodePduLength | Determine how much data is needed to fully decode a BSER pdu. |
parseBser | parseBser overloads |
toBser | Serialize a dynamic value to a BSER-encoded string. |
toBserIOBuf | Serialize a dynamic value to a BSER-encoded IOBuf. |
| Name | Description |
|---|---|
kMagic | The two-byte magic prefix that identifies a BSER stream. |
Internal implementation details for ConcurrentBSkipList.
| Name | Description |
|---|---|
detail_hw_atomic | Detects whether a type qualifies as a hardware-atomic key/payload type. |
| Name | Description |
|---|---|
AdaptiveReadGuard | RAII read guard that starts optimistic and escalates to the shared lock when a writer is in flight. |
AtomicSlot | Lock-free read slot for hardware-atomic T. |
BSkipAllocator | Node allocator wrapper that rebinds a byte allocator per node type. |
BSkipNode | Common base of leaf and internal nodes: next pointer, seqlock, and mutex. |
BSkipNodeInternal | Internal (routing) node holding separator keys and child pointers. |
BSkipNodeLeaf | Leaf node holding sorted keys, optional payloads, and tombstone bits. |
BSkipTuning | Tuning knobs separated from InternalTraits so they can be adjusted without touching the Traits template parameter set. |
InlineLeafRecord | Interleaved {key, payload} record for inline (AoS) leaf storage. |
InternalTraits | Derived compile-time traits for a ConcurrentBSkipList instantiation. |
LeafStorage | Leaf key/payload storage policy dispatcher. |
Seqlock | Seqlock used to bracket OLC reader/writer access to a node's fields. |
| Name | Description |
|---|---|
BSkipTestHook | Function-pointer type for a BSkipList test hook. |
Empty | Zero-size payload slot for [[no_unique_address]]in void-payload templates. |
KeyStorage | Picks the leaf-slot storage type for a key/value type T. |
PayloadStorage | Same as KeyStorage but Empty when there's no payload at all. |
| Name | Description |
|---|---|
BSkipTestHookEvent | Test-hook event points fired along the concurrent read/split paths. |
InsertSemantics | How an insertion treats an existing live exact-match key. |
| Name | Description |
|---|---|
findFirstGreaterLinear | Finds the first slot in [begin, end) whose key sorts after target.] |
invokeBSkipTestHook | Fires the global BSkipList test hook (no-op unless test hooks are built). |
loadValidated | Reads a slot optimistically, then validates the read. |
setBSkipTestHook | Installs the global BSkipList test hook (no-op unless test hooks are built). |
| Name | Description |
|---|---|
kDefaultReadPolicy | Default key-read policy for T: RelaxedAtomic if hardware-atomic, else Locked. |
kIsHardwareAtomic | True when T is a hardware-atomic (lock-free, trivially copyable) type. |
Detects whether a type qualifies as a hardware-atomic key/payload type.
| Name | Description |
|---|---|
Check | Satisfied when T is trivially copyable and always lock-free as an atomic. |
Sender/receiver channel primitives for asynchronous value streams.
| Name | Description |
|---|---|
Channel | A channel is a sender and receiver pair that allows one component to send values to another. A sender and receiver pair is similar to an AsyncPipe and AsyncGenerator pair. However, unlike AsyncPipe/AsyncGenerator, senders and receivers can be used by memory-efficient higher level transformation abstractions. |
ChannelCallbackHandle | A callback handle for a consumption operation on a channel. The consumption operation will be cancelled when this handle is destroyed. |
ChannelCallbackHandleList | A list of channel callback handles. When consumeChannelWithCallback is invoked with a list, a cancellation handle is automatically added to the list for the consumption operation. Similarly, when a consumption operation is completed, the handle is automatically removed from the lists. |
FanoutChannel | A fanout channel allows fanning out updates from a single input receiver to multiple output receivers. |
FanoutSender | A FanoutSender allows fanning out updates to multiple output receivers. Values can be written as with a normal Sender. When there is only one output receiver, the memory used by a FanoutSender (and the corresponding output receiver) is the same as the memory used by a normal channel. |
MaxConcurrentRateLimiter | A rate limiter that caps the number of concurrently running operations. |
MergeChannel | A merge channel allows one to merge multiple receivers into a single output receiver. The set of receivers being merged can be changed at runtime. Each receiver is added with a key that can be used to remove the receiver at a later point. |
MergeChannelEvent | An event emitted by a merge channel, tagged with the source receiver key. |
MergeChannelReceiverAdded | Event signaling that a receiver was added to the merge channel. |
MergeChannelReceiverClosed | Event signaling that a merged receiver closed. |
MergeChannelReceiverRemoved | Event signaling that a receiver was removed from the merge channel. |
NoContext | Empty context used by FanoutChannel when no context is needed. |
OnClosedException | An OnClosedException passed to a transform or multiplex callback indicates that the input channel was closed. An OnClosedException can also be thrown by a transform or multiplex callback, which will close the output channel. |
RateLimiter | A rate-limiter used by the channels framework to limit the number of in-flight requests. |
Receiver | A receiver that receives values sent by a sender. There are several ways that a receiver can be consumed: |
ReinitializeException | A ReinitializeException thrown by a transform callback indicates that the resumable transform needs to be re-initialized. |
Sender | A sender sends values to be consumed by a receiver. |
| Name | Description |
|---|---|
consumeChannelWithCallback | This function takes a Receiver, and consumes updates from that receiver with a callback. |
createFanoutChannel | Creates a new fanout channel that fans out updates from an input receiver. |
createMergeChannel | Creates a new merge channel. |
merge | Merge takes a list of receivers, and returns a new receiver that receives all updates from all input receivers. If any input receiver closes with an exception, the exception is forwarded and the channel is closed. If any input receiver closes without an exception, the channel continues to merge values from the other input receivers until all input receivers are closed. |
resumableTransform | resumableTransform overloads |
transform | transform overloads |
Time-related wrappers and clock utilities.
| Name | Description |
|---|---|
Clock | Clock interface. |
ClockImpl | Implementation of ClockInterface for given std::chrono ClockType. |
clock_traits | Detects and re-exports per-clock traits. |
coarse_steady_clock | A coarse-resolution steady clock backed by CLOCK_MONOTONIC_COARSE. |
coarse_system_clock | A coarse-resolution system clock backed by CLOCK_REALTIME_COARSE. |
steady_clock_spec | Spec tag shared by all steady clocks with the same epoch and tick rate. |
system_clock_spec | Spec tag shared by all system clocks with the same epoch and tick rate. |
| Name | Description |
|---|---|
SteadyClock | Clock interface backed by std::chrono::steady_clock. |
SteadyClockImpl | Clock implementation backed by std::chrono::steady_clock. |
SystemClock | Clock interface backed by std::chrono::system_clock. |
SystemClockImpl | Clock implementation backed by std::chrono::system_clock. |
| Name | Description |
|---|---|
clock_gettime | Pointer to a clock_gettime-style function returning the time of a clock via a timespec. |
clock_gettime_ns | Pointer to a function returning the time of a clock in nanoseconds. |
| Name | Description |
|---|---|
abs | Re-export of std::chrono::abs. |
ceil | Re-export of std::chrono::ceil. |
floor | Re-export of std::chrono::floor. |
round | Re-export of std::chrono::round. |
Compression and decompression codecs over IOBufs.
| Name | Description |
|---|---|
contexts | Process-wide singleton ZSTD compression context pools. |
instructions | CPU instruction-set backends for Elias-Fano bit operations. |
| Name | Description |
|---|---|
BitVectorCompressedListBase | Non-owning view over a bit-vector-encoded list and its sub-sections. |
BitVectorEncoder | Encodes a strictly increasing sequence of unsigned integers as a bit vector. |
BitVectorReader | Forward/random-access reader over a bit-vector-encoded integer sequence. |
Codec | Base class for a compression/decompression codec. |
CompressionContextPool | This implementation is slow under contention. Except under uncontended scenarios, you shouldn't use it directly. You likely want to use the CompressionCoreLocalContextPool instead, which, behind the fast cache slots, is backed by this implementation. |
CompressionContextPoolDefaultCallback | Default no-op callback invoked periodically by CompressionContextPool. |
CompressionCoreLocalContextPool | This class is intended to reduce contention on reserving a compression context and improve cache locality (but maybe not hotness) of the contexts it manages. |
CompressionCoreLocalContextPoolBase | Non-templated base class which allows for generic interaction with context pool instances. |
EliasFanoCompressedListBase | Non-owning view over an Elias-Fano-encoded list and its sub-sections. |
EliasFanoEncoder | Encodes a sorted sequence of unsigned integers using Elias-Fano coding. |
EliasFanoReader | Forward/random-access reader over an Elias-Fano-encoded, non-decreasing sequence of integers produced by EliasFanoEncoder. |
StreamCodec | Base class for a codec that also supports a stateful streaming API. |
| Name | Description |
|---|---|
BitVectorCompressedList | Read-only bit-vector compressed list. |
EliasFanoCompressedList | Read-only Elias-Fano compressed list. |
MutableBitVectorCompressedList | Mutable bit-vector compressed list. |
MutableEliasFanoCompressedList | Mutable Elias-Fano compressed list. |
| Name | Description |
|---|---|
CodecType | Identifies a compression algorithm. |
| Name | Description |
|---|---|
copyCompressedList | Returns a deep copy of a compressed list, owning a freshly allocated buffer. |
getAutoUncompressionCodec | Returns a codec that can uncompress any of the given codec types as well as {LZ4_FRAME, ZSTD, ZLIB, GZIP, LZMA2, BZIP2}. Appends each default codec to customCodecs in order, so long as a codec with the same type() isn't already present in customCodecs or as the terminalCodec. When uncompress() is called, each codec's canUncompress() is called in the order that they are given. Appended default codecs are checked last. uncompress() is called on the first codec whose canUncompress() returns true. |
getCodec | Return a codec for the given type. Throws on error. The level is a non-negative codec-dependent integer indicating the level of compression desired, or one of the following constants: |
getStreamCodec | Return a codec for the given type. Throws on error. The level is a non-negative codec-dependent integer indicating the level of compression desired, or one of the following constants: |
hasCodec | Check if a specified codec is supported. |
hasStreamCodec | Check if a specified codec is supported and supports streaming. |
zstdConvertLevel | Convert a folly abstract compression level (COMPRESSION_LEVEL_FASTEST, COMPRESSION_LEVEL_DEFAULT, COMPRESSION_LEVEL_BEST) to a raw ZSTD compression level (1-22). Passes through raw levels in [1, ZSTD_maxCLevel()] unchanged. Throws std::invalid_argument for out-of-range levels. |
| Name | Description |
|---|---|
COMPRESSION_CONTEXT_POOL_CALLBACK_INTERVAL | Number of pool checkouts between successive callback invocations. |
COMPRESSION_LEVEL_BEST | Abstract level selecting the best compression. |
COMPRESSION_LEVEL_DEFAULT | Abstract level selecting the codec's default compression. |
COMPRESSION_LEVEL_FASTEST | Abstract level selecting the fastest compression. |
kCacheLineSize | Size in bytes of a cache line, used to size prefetches. |
kLowerTrailingBytes | Trailing bytes that must be readable past the end of the lower bit sequence, required by loadUnaligned<uint64_t> reads in the lower accessor. |
kUpperTrailingBytes | Trailing bytes that must be readable past the end of the upper bit sequence, required by loadUnaligned<uint64_t> reads in the upper accessor. |
Process-wide singleton ZSTD compression context pools.
CPU instruction-set backends for Elias-Fano bit operations.
| Name | Description |
|---|---|
Default | Portable bit-operation backend using compiler builtins. |
Haswell | |
Nehalem |
| Name | Description |
|---|---|
Type | Selects an instruction-set backend at runtime. |
| Name | Description |
|---|---|
detect | Detects the best supported instruction-set backend for this CPU. |
dispatch | dispatch overloads |
Coroutine primitives and combinators.
| Name | Description |
|---|---|
ext | Tools for library authors who are building new co_cleanup types. |
| Name | Description |
|---|---|
impl | Alias for the standard namespace providing coroutine support. |
| Name | Description |
|---|---|
AsyncGenerator | The AsyncGenerator class represents a sequence of asynchronously produced values where the values are produced by a coroutine. |
AsyncObject | Base class for objects whose lifetime is managed by an async_closure. |
AsyncObjectNonSlotPtr | Owning pointer to an AsyncObject that does not live in a scope slot. |
AsyncObjectTag | Tag type identifying an async object owned by an async_closure. |
AsyncPipe | An AsyncGenerator with a write end |
AsyncScope | Starts and later joins a dynamic, unbounded set of concurrent tasks. |
AsyncScopeSlotObject | An AsyncObject stored in a slot of an async scope. |
AsyncStackTraceAwaitable | Awaitable that yields the current async stack trace. |
AutoCleanup | The user can use AutoCleanup to wrap arguments passed to a CleanableAsyncGenerator. When the coroutine promise of CleanableAsyncGenerator is created it will automatically attach co_scope_exit task that performs async cleanup for all the arguments wrapped in AutoCleanup. This allows to ensure cleanup of the arguments even when next() of the CleanableAsyncGenerator is never co_awaited. |
BackgroundTask | A task that runs detached in the background; forward-declared here. |
Baton | A baton is a synchronisation primitive for coroutines that allows a coroutine to co_await the baton and suspend until the baton is posted by some thread via a call to .post(). |
BoundedAsyncPipe | Bounded variant of AsyncPipe which buffers a fixed number of writes before blocking new attempts to write until the buffer is drained. |
BoundedQueue | A coroutine version of bounded queue with given capacity. Both enqueue and dequeue are async awaitable. |
CancellableAsyncScope | A cancellable version of AsyncScope. Work added to this scope will be provided a cancellation token for cancelling during join. |
ConnectCallback | Handles the connect operation for an AsyncSocketTransport. |
ExtendedCoroutineHandle | Extended coroutine_handle<void> assuming the handle is a pointer. |
ExtendedCoroutinePromiseCrtp | CRTP base letting a promise expose a more efficient error-resumption path. |
Future | The awaitable read side of a promise/future contract. |
Generator | A synchronous coroutine generator that lazily yields a sequence of values. |
Mutex | A mutex that can be locked asynchronously using 'co_await'. |
PollFuture | A Rust-style pollable adaptor over a Task or SemiFuture. |
PollStream | A Rust-style pollable adaptor over an AsyncGenerator stream. |
Promise | The write side of a promise/future contract used to fulfill a Future. |
ReadCallback | Handles data reads for an AsyncTransport. |
SerialQueueRunner | SerialQueueRunner |
ServerSocket | A coroutine server socket that accepts connections on the same event base as the underlying socket itself. |
SharedLock | This type mirrors the interface of std::shared_lock as much as possible. |
SharedMutexFair | The folly::coro::SharedMutexFair class provides a thread synchronisation primitive that allows a coroutine to asynchronously acquire a lock on the mutex. |
SharedPromise | SharedPromise is a simple wrapper around folly::coro::Promise and folly::coro::Future that allows for fetching cancellable and awaitable futures from a single promise. |
SmallUnboundedQueue | Low-memory unbounded multi-producer/consumer queue with lower throughput. |
StackAwareViaIfAsyncAwaitable | Async-stack-aware awaitable that reschedules onto an executor. |
StackAwareViaIfAsyncAwaiter | Async-stack-aware awaiter that reschedules its inner awaiter onto an executor. |
Synchronized | This class is an adaptation of the folly::Synchronized class but is designed to work with coro-compatible mutexes like coro::SharedMutexFair instead. |
Task | Represents an allocated, but not-started coroutine, which is not yet been bound to an executor. |
TaskWithExecutor | Represents an allocated but not yet started coroutine that has already been bound to an executor. |
TaskWithExecutorWrapperCrtp | CRTP base implementing the shared behavior of task-with-executor wrappers. |
TaskWrapperCrtp | CRTP base implementing the shared behavior of task wrappers. |
Transport | Coroutine transport backed by an AsyncTransport socket. |
TransportCallbackBase | Common base for all transport callbacks. |
TransportIf | Abstract interface for a coroutine-based socket transport. |
UnboundedQueue | Wrapper around folly::UnboundedQueue that supports async dequeue. |
UpgradeLock | An upgradable lock guard held over a coroutine-aware mutex. |
ViaIfAsyncAwaitable | Awaitable that reschedules its inner awaitable onto an executor. |
ViaIfAsyncAwaiter | Awaiter that reschedules its inner awaiter onto an executor. |
WriteCallback | Handles data writes for an AsyncTransport. |
after_cleanup_capture | Capture wrapper marked after_cleanup_ to bar refs from outliving cleanup. |
after_cleanup_capture | Capture wrapper marked after_cleanup_ to bar refs from outliving cleanup. |
after_cleanup_capture_heap | Heap-backed after_cleanup_capture for cleanup-free in-place arguments. |
after_cleanup_capture_indirect | Pointer-holding after_cleanup_capture with reach-through dereference sugar. |
async_closure_config | Learn more about coro/safe tools by browsing docs/. Start with README.md and AsyncClosure.md. Here's a tl;dr for AsyncClosure.h. |
async_closure_private_t | Tag type used by async_closure to trigger cleanup of captures that have an co_cleanup(async_closure_private_t) overload. |
await_result | Metafunction yielding the result type of co_awaiting an Awaitable. |
awaiter_type | awaiter_type<Awaitable> |
capture | Lifetime-safe wrapper owning a captured value or reference for coroutines. |
capture | Lifetime-safe wrapper owning a captured value or reference for coroutines. |
capture_heap | Heap-backed capture letting cleanup-free closures take in-place arguments. |
capture_indirect | Capture over a pointer, adding sugar so */-> reach through one level. |
co_cleanup_capture | Capture of a cleanup arg, whose refs downgrade dependents to after-cleanup. |
co_cleanup_capture | Capture of a cleanup arg, whose refs downgrade dependents to after-cleanup. |
co_cleanup_fn | A customization point that allows to provide an async cleanup function for a type. folly::coro::AutoCleanup uses co_cleanup_fn as the default cleanup function, so it is enough to define co_cleanup for a type to be able to use it with AutoCleanup. |
co_error | Wraps an exception to be thrown from a coroutine via co_yield. |
co_invoke_fn | Function object that invokes a callable and awaits its coroutine result. |
co_result | Wraps a Try or result to be yielded from a coroutine as its completion. |
co_result | Wraps a Try or result to be yielded from a coroutine as its completion. |
co_safe_point_t | A semi-awaitable type which, when awaited in an async coroutine supporting safe-points, causes a safe-point to be reached. |
co_stopped_may_throw_t | Tag type that converts to a co_error carrying OperationCancelled. |
is_auto_cleanup | Trait detecting whether T is an AutoCleanup wrapper. |
is_awaitable | is_awaitable<T>::value is_awaitable_v<T> |
is_awaiter | is_awaiter<T>::value is_awaiter_v<T> |
is_semi_awaitable | Trait detecting whether T is a semi-awaitable. |
now_task | An immovable Task<T> that must be co_awaited in the expression that created it. |
now_task_with_executor | The executor-bound, immovable counterpart of now_task awaited in place. |
on_stopped_and_error_t | Primary policy struct: specify behavior for stopped (cancellation) and error. Use via the variable templates below, not directly. |
ready_awaitable | An awaitable that is immediately ready and yields a stored value on resume. |
remove_reference_wrapper | A type trait to unwrap a std::reference_wrapper<T> to a type T |
restricted_co_cleanup_capture | Restricted view on a co_cleanup_capture ref that avoids the safety downgrade by only accepting maybe_value args. |
restricted_co_cleanup_capture | Restricted view on a co_cleanup_capture ref that avoids the safety downgrade by only accepting maybe_value args. |
safe_async_scope_context_proxy | Proxy granting safe access to an async scope's context. |
safe_task | Why is SafeTask.h useful? |
safe_task_with_executor | A safe_task that has been bound to an executor and is ready to run. |
value_or_fatal | value_or_fatal<Task<T>, Policy> wraps a task to guarantee value-only completion. |
variant_awaitable | An awaitable backed by one of several possible underlying awaitables. |
will_fatal_t | Tag for "terminate on this completion". |
| Name | Description |
|---|---|
CleanableAsyncGenerator | An AsyncGenerator that requires cleanup() to be called before destruction. |
NowTask | Backwards-compatibility alias for now_task. |
NowTaskWithExecutor | Backwards-compatibility alias for now_task_with_executor. |
SharedMutex | The default SharedMutex is SharedMutexFair. |
auto_safe_task | Coros declared as safe_task<Safety, T> will satisfy the strong constraints above, or fail with a compile error. |
await_result_t | Alias for the result type of co_awaiting an Awaitable. |
awaiter_type_t | await_result<Awaitable> |
capture_ref_conversion_t | Given a cvref-qualified capture type, what capture reference type is it convertible to? The input value category affects the output reference type exactly as you'd expect for types NOT wrapped by capture. But, additionally, this knows to pick the correct wrapper: - co_cleanup_capture inputs become co_cleanup_capture<SomeRef> - after_cleanup_ref_* inputs become after_cleanup_capture<SomeRef> - everything else becomes just capture<SomeRef> |
closure_task | A safe_task meant to be the inner coro wrapped in an async_closure. |
co_cleanup_safe_task | A safe_task that can be added to safe_async_scope, and may run during closure cleanup. Its content must therefore be co_cleanup_safe_ref-safe. |
co_current_cancellation_token_t | Placeholder type awaited to obtain the current coroutine's cancellation token. |
co_current_executor_t | Placeholder type awaited to obtain the current coroutine's executor. |
co_reschedule_on_current_executor_t | Placeholder type awaited to reschedule the current coroutine onto its executor. |
member_task | A safe_task for non-static member coroutines on stateful classes. |
remove_reference_wrapper_t | Alias for the unwrapped type of remove_reference_wrapper. |
semi_await_result_t | The result type of co_awaiting a semi-awaitable T. |
semi_await_try_result_t | The result type of co_awaiting the Try wrapper of a semi-awaitable T. |
value_only_awaitable_t | True for awaitables that only complete with value (not stopped or error) |
value_task | A safe_task whose args and return type follow value semantics. |
| Name | Description |
|---|---|
accumulate | accumulate overloads |
async_closure | Creates a lifetime-safe async closure task from bound args and a coroutine. |
async_now_closure | Creates an immediately-awaited async closure returning a now_task. |
blocking_wait | blocking_wait overloads |
co_awaitTry | co_awaitTry overloads |
co_nothrow | Cheaply propagate exceptions from awaitable to the calling coroutine, bypassing the expensive throw/catch stack unwinding mechanism. |
co_scope_exit | Creates a scope-exit coroutine running action with the captured state. |
co_transition_lock | Async version of the folly::transition_lock TODO: add more transition policies beyond just from upgrade to exclusive |
co_viaIfAsync | co_viaIfAsync overloads |
co_withCancellation | co_withCancellation overloads |
co_withExecutor | co_withExecutor overloads |
collectAll | Concurrently await multiple awaitables and complete with a tuple of results. |
collectAllRange | collectAllRange overloads |
collectAllTry | Concurrently await multiple awaitables and complete with a tuple of Try results. |
collectAllTryRange | collectAllTryRange overloads |
collectAllTryWindowed | collectAllTryWindowed overloads |
collectAllWindowed | collectAllWindowed overloads |
collectAny | Concurrently await awaitables and complete with the first result and index. |
collectAnyNoDiscard | Concurrently await awaitables and return every result once one finishes. |
collectAnyNoDiscardRange | collectAnyNoDiscardRange overloads |
collectAnyRange | collectAnyRange overloads |
collectAnyWithoutException | Concurrently await awaitables, returning the first success or last error. |
collectAnyWithoutExceptionRange | collectAnyWithoutExceptionRange overloads |
concat | Concatenate the values from multiple streams into a single stream such that each stream is exhausted before the next one begins. |
detachOnCancel | detachOnCancel is used to handle operations that are hard to be cancelled. A typical use case is: The caller starts a task with timeout (in this case, 1 sec timeout). The task itself launches a long running job and the job doesn't handle cancellation (sleep_for in this example). The caller has timeout and the cancellation is propagated to the task. The detachOnCancel detects the cancellation and return immediately. However, the background task still runs until the thread join. |
detect_promise_return_object_eager_conversion | Returns whether the compiler converts a coroutine promise return object eagerly. |
filter | Filters a stream, yielding only values that satisfy the predicate. |
get_awaiter | get_awaiter overloads |
makeErrorTask | Make a Task that will trivially yield an Exception. |
makeFuture | makeFuture overloads |
makePromiseContract | makePromiseContract can help you migrating your non-coroutine code base to coroutine. If your code already uses Future/SemiFuture, you don't need this tool. A common use case is with async callback functions. In the example, we can pass a callback function into the legacy code sleepAndNotify and sleepAndNotify sets the promise on completion. Consider to use detachOnCancel with this makePromiseContract to handle long running (longer than your timeout) tasks that don't handle cancellation properly. |
makeResultTask | Make a Task out of a Try. |
makeTask | makeTask overloads |
makeUnorderedAsyncGenerator | makeUnorderedAsyncGenerator overloads |
makeUnorderedTryAsyncGenerator | makeUnorderedTryAsyncGenerator overloads |
make_error_now_task | Make a now_task that will trivially yield an exception. |
make_now_task | make_now_task overloads |
merge | Merges a stream of input streams into a single interleaved output stream. |
retryN | retryN overloads |
retryWhen | Execute a given asynchronous operation returned by func(), retrying it on failure, if desired, after awaiting retryDelay(error). |
retryWithExponentialBackoff | retryWithExponentialBackoff overloads |
scheduleAutoCleanupIfNeeded | Schedules async cleanup for any AutoCleanup arguments on the coroutine. |
sleep | Return a task that, when awaited, will sleep for the specified duration. |
sleepReturnEarlyOnCancel | Return a task that, when awaited, will sleep for the specified duration. |
swap | Swaps the state of two generators. |
tag_invoke | tag_invoke overloads |
timed_wait | Awaits awaitable, giving up after duration elapses. |
timeout | Returns a Task that, when started, starts a timer of duration 'timeoutDuration' and awaits the passed SemiAwaitable. |
timeoutNoDiscard | Returns a Task that, when started, starts a timer of duration 'timeoutDuration' and awaits the passed SemiAwaitable (operation). |
toFuture | Converts the given SemiAwaitable to a Future, starting it on the Executor. |
toSemiFuture | Converts the given SemiAwaitable to a SemiFuture (without starting it). |
toTask | toTask overloads |
toTaskInterruptOnCancel | toTaskInterruptOnCancel overloads |
to_now_task | to_now_task overloads |
value_or_error | When awaited, returns a result<T> in a value or an error state, but never has_stopped() (aka OperationCancelled). If awaitable reports as "stopped", the awaiting coroutine will be promptly torn down, **without throwing**, and its parent will in turn receive a "stopped" completion. |
value_or_error_or_stopped | When awaited, returns result<T> just like value_or_error(), but also captures "stopped" completions, so you must test for has_stopped(). |
| Name | Description |
|---|---|
co_cancelled [deprecated] | Deprecated alias for co_stopped_may_throw. |
co_current_async_stack_trace | Awaitable yielding the current async stack trace when co_awaited. |
co_current_cancellation_token | Placeholder value awaited to obtain the current coroutine's cancellation token. |
co_current_executor | Special placeholder object that can be 'co_await'ed from within a Task<T> or an AsyncGenerator<T> to obtain the current folly::Executor associated with the current coroutine. |
co_reschedule_on_current_executor | A SemiAwaitable object that allows you to reschedule the current coroutine onto the currently associated executor. |
co_safe_point | A semi-awaitable value that causes a safe-point to be reached when awaited. |
co_stopped_may_throw | Tag that, when thrown via co_yield, cancels the awaiting coroutine. |
is_auto_cleanup_v | True when T is an AutoCleanup wrapper. |
is_awaitable_async_stack_aware_v | True if the awaitable customizes the co_withAsyncStack CPO. |
is_awaitable_v | True if T satisfies the awaitable interface. |
is_awaiter_v | True if T satisfies the awaiter interface. |
is_semi_awaitable_v | True if T is a semi-awaitable. |
on_stopped | Convenience: stopped returns V, error terminates (fatal). |
on_stopped_and_error | Policy that returns Stopped on cancellation and Error on error. |
on_stopped_void | Convenience for void tasks: stopped returns unit, error terminates. |
value_only_awaitable_v | True if T only completes with a value (not stopped or error). |
will_fatal | Policy value selecting termination on a stopped or error completion. |
| Name | Description |
|---|---|
coroutine_handle | Re-exports the standard coroutine handle type. |
coroutine_traits | Re-exports the standard coroutine traits template. |
noop_coroutine | Re-exports the standard no-op coroutine factory. |
noop_coroutine_handle | Re-exports the standard no-op coroutine handle type. |
noop_coroutine_promise | Re-exports the standard no-op coroutine promise type. |
suspend_always | Re-exports the standard always-suspend awaitable. |
suspend_never | Re-exports the standard never-suspend awaitable. |
Tools for library authors who are building new co_cleanup types.
| Name | Description |
|---|---|
capture_proxy_tag | Passkey used with capture_proxy methods. |
| Name | Description |
|---|---|
capture_proxy_kind | Selects which reference or pointer form a capture_proxy() returns. |
| Name | Description |
|---|---|
const_or_not | Satisfied when T is U or const U, matching both U& and const U&. |
Cryptographic hashing primitives.
| Name | Description |
|---|---|
Blake2xb | An implementation of the BLAKE2x XOF (extendable output function) hash function using BLAKE2b as the underlying hash. This hash function can produce cryptographic hashes of arbitrary length (between 1 and 2^32 - 2 bytes) from inputs of arbitrary size. Like BLAKE2b, it can be keyed, and can accept optional salt and personlization parameters. |
LtHash | Templated homomorphic hash, using LtHash (lattice-based crypto). Template parameters: B = element size in bits, N = number of elements. |
| Name | Description |
|---|---|
LtHash16_1024 | Fastest and smallest LtHash specialization, with over 200 bits of security. |
LtHash20_1008 | Higher-security LtHash specialization; slower and larger than LtHash16_1024. |
LtHash32_1024 | Higher-security LtHash specialization; slower and larger than LtHash16_1024. |
| Name | Description |
|---|---|
operator+ | Addition operators |
operator- | Subtraction operators |
Implementation details of the tag_invoke customization-point machinery.
| Name | Description |
|---|---|
defer | Defers instantiation of T<Args...> to its member type alias. |
empty | Empty placeholder type used when no result type is available. |
tag_invoke_fn | Function object dispatching to an ADL tag_invoke call. |
| Name | Description |
|---|---|
tag_invoke_result_t | The result type of tag_invoke(Tag, Args...). |
| Name | Description |
|---|---|
tag_invoke | Poison-pill declaration ensuring ADL lookup of tag_invoke. |
try_tag_invoke | try_tag_invoke overloads |
Implementation details.
| Name | Description |
|---|---|
ApplyConstVisitor | Dispatches a visitor to a const pointer whose type is selected at runtime. |
ApplyVisitor | Dispatches a visitor to a pointer whose type is selected at runtime. |
ConstVisitorResult | Determine the result type of applying a visitor of type V on const pointers of all types in Types..., asserting that the type is the same for all types in Types... |
VisitorResult | Determine the result type of applying a visitor of type V on pointers of all types in Types..., asserting that the type is the same for all types in Types... |
Implementation details for dynamic.
| Name | Description |
|---|---|
detect_construct_string | Detects whether a std::string can be constructed from a T's data() and size(). |
Implementation details for DynamicConverter and DynamicConstructor.
| Name | Description |
|---|---|
Dereferencer | Converts a dynamic iterator's value into a cached, well-typed value. |
Transformer | An iterator adaptor that dereferences to a converted value of type T::value_type. |
iterator_class_is_container | Trait determining whether a class with an iterator behaves as a container. |
| Name | Description |
|---|---|
class_is_container | True when a class type is a container. |
detect_like_optional | Detects whether a type is constructible from its own value_type. |
detect_like_pointer | Detects whether a type is dereferenceable and contextually convertible to bool. |
detect_member_type_iterator | Detects a nested iterator member type. |
detect_member_type_key_type | Detects a nested key_type member type. |
detect_member_type_mapped_type | Detects a nested mapped_type member type. |
detect_member_type_value_type | Detects a nested value_type member type. |
is_associative | True when a type is an associative container with a key_type. |
is_container | True when a type is a container class. |
is_like_pointer | True when a type behaves like a pointer but is not a string literal. |
is_map | True when a type is a map-like container with a mapped_type. |
is_optional | True when a type behaves like an optional value. |
is_range | True when a type is a range with both value_type and iterator. |
| Name | Description |
|---|---|
conversionIterator | Build a converting iterator over a dynamic iterator. |
Facilities for capturing and stacking exception stack traces.
| Name | Description |
|---|---|
ExceptionInfo | Information about a captured exception and its stack trace. |
StackTrace | A captured stack trace as a fixed-capacity array of return addresses. |
StackTraceStack | An intrusive stack of captured stack traces. |
| Name | Description |
|---|---|
CxaBeginCatchSig | Signature of a callback invoked when a catch block begins via __cxa_begin_catch. |
CxaEndCatchSig | Signature of a callback invoked when a catch block ends via __cxa_end_catch. |
CxaRethrowSig | Signature of a callback invoked when an exception is rethrown via __cxa_rethrow. |
CxaThrowSig | Signature of a callback invoked when an exception is thrown via __cxa_throw. |
RethrowExceptionSig | Signature of a callback invoked when an exception is rethrown via std::rethrow_exception. |
| Name | Description |
|---|---|
registerCxaBeginCatchCallback | Register a callback invoked on each __cxa_begin_catch. |
registerCxaEndCatchCallback | Register a callback invoked on each __cxa_end_catch. |
registerCxaRethrowCallback | Register a callback invoked on each __cxa_rethrow. |
registerCxaThrowCallback | Register a callback invoked on each __cxa_throw. |
registerRethrowExceptionCallback | Register a callback invoked on each std::rethrow_exception. |
unregisterCxaBeginCatchCallback | Unregister a previously registered __cxa_begin_catch callback. |
unregisterCxaEndCatchCallback | Unregister a previously registered __cxa_end_catch callback. |
unregisterCxaRethrowCallback | Unregister a previously registered __cxa_rethrow callback. |
unregisterCxaThrowCallback | Unregister a previously registered __cxa_throw callback. |
unregisterRethrowExceptionCallback | Unregister a previously registered std::rethrow_exception callback. |
| Name | Description |
|---|---|
kMaxFrames | Maximum number of frames captured in a single stack trace. |
Implementation details for folly::Expected.
| Name | Description |
|---|---|
expected_detail_ExpectedHelper | Implementation details for the ExpectedHelper continuation machinery. |
| Name | Description |
|---|---|
CopyAssignable | Mixin that adds a copy assignment which delegates to the derived assign. |
CopyConstructible | Mixin that adds a copy constructor which delegates to the derived assign. |
EmptyTag | Tag type selecting the empty-state constructor. |
ErrorTag | Tag type selecting the error-state constructor. |
ExpectedAwaitable | Awaitable that unwraps an Expected inside a coroutine. |
ExpectedStorage | Storage backing an Expected, holding either a value or an error. |
ExpectedUnion | Raw union of a value and an error with a discriminator. |
MoveAssignable | Mixin that adds a move assignment which delegates to the derived assign. |
MoveConstructible | Mixin that adds a move constructor which delegates to the derived assign. |
Promise | Selects the appropriate coroutine promise for a value and error type. |
PromiseBase | Shared base of the Expected coroutine promise types. |
PromiseReturn | Coroutine return object that materializes an Expected from a promise. |
PromiseReturnsValue | Coroutine promise for coroutines that produce a value. |
PromiseReturnsVoid | Coroutine promise for coroutines with no meaningful return value. |
UnexpectedAwaitable | Awaitable that short-circuits a coroutine with an unexpected error. |
UnexpectedTag | Tag type used to disambiguate error-state construction of Expected. |
ValueTag | Tag type selecting the value-state constructor. |
| Name | Description |
|---|---|
IsConvertible | True when From can both construct and assign to To. |
IsCopyable | True when T is both copy constructible and copy assignable. |
IsMovable | True when T is both move constructible and move assignable. |
IsNothrowCopyable | True when T is nothrow copy constructible and nothrow copy assignable. |
IsNothrowMovable | True when T is nothrow move constructible and nothrow move assignable. |
StrictAllOf | True when Trait holds for every type in Ts. |
| Name | Description |
|---|---|
StorageType | Storage strategy chosen for an Expected's value and error. |
Which | Discriminator for which alternative an Expected currently holds. |
| Name | Description |
|---|---|
doEmplaceAssign | doEmplaceAssign overloads |
getStorageType | Selects the storage strategy for a given value and error type. |
| Name | Description |
|---|---|
ReturnsVoid | True when a coroutine over Value behaves as if it returns void. |
| Name | Description |
|---|---|
ExpectedHelper | Introduces ExpectedHelper into the expected_detail namespace. |
Implementation details for the ExpectedHelper continuation machinery.
| Name | Description |
|---|---|
ExpectedHelper | Static helpers implementing the Expected continuation operations. |
| Name | Description |
|---|---|
operator, | Comma operator that lets Expected::then handle lambdas returning void. |
Namespace for experimental Folly components.
| Name | Description |
|---|---|
EnvironmentState | Class to model the process environment in idiomatic C++ |
MalformedEnvironment | Exception thrown when the process environment cannot be modeled. |
Extension namespace for library authors, a public analog of folly::detail.
| Name | Description |
|---|---|
curried_unsafe_mover_private_t | Passkey that gates the reconstruction ctor used by curried_unsafe_mover_t. |
curried_unsafe_mover_t | Mover returned from unsafe_mover on typical must-use-immediately types. |
default_unsafe_mover_t | Default impl of must_use_immediately_unsafe_mover for movable types. |
format_string_and_location | ext::format_string_and_location |
must_use_immediately_crtp | CRTP base that makes a derived type must-use-immediately and immovable. |
must_use_immediately_private_t | Passkey for the static unsafe_mover members of must-use-immediately types. |
wrap_must_use_immediately_t | Wrap a movable Inner type to make it must-use-immediately and immovable. |
| Name | Description |
|---|---|
must_use_immediately_t | Trait giving T's must-use-immediately tag, or std::false_type if none. |
test_find_resource_t | Signature of a function that resolves a test resource path by name. |
| Name | Description |
|---|---|
curried_unsafe_mover_from_bases_and_members | Build a curried_unsafe_mover_t from a type's bases and member pointers. |
must_use_immediately_unsafe_mover | Obtain a mover that destructively moves t out of a must-use-immediately type, so it can be reconstituted later via the mover's operator(). |
| Name | Description |
|---|---|
must_use_immediately_v | true when T is a must-use-immediately type. |
test_find_resource | Overridable hook used by tests to locate resource files. |
| Name | Description |
|---|---|
must_use_immediately | Satisfied when T is a must-use-immediately type. |
Vendored third-party code adapted for use in Folly.
| Name | Description |
|---|---|
farmhash | FarmHash family of hash and fingerprint functions. |
rapidhash_detail | Implementation details of the rapidhash hashing algorithm. |
| Name | Description |
|---|---|
rapidhash | rapidhash general purpose hash function. |
rapidhashMicro | rapidhashMicro hash function. |
rapidhashMicro_with_seed | rapidhashMicro seeded hash function. |
rapidhashNano | rapidhashNano hash function. |
rapidhashNano_with_seed | rapidhashNano seeded hash function. |
rapidhash_with_seed | rapidhash seeded hash function. |
FarmHash family of hash and fingerprint functions.
| Name | Description |
|---|---|
farmhashcc | FarmHash "cc" variant, derived from CityHash. |
farmhashmk | FarmHash "mk" variant. |
farmhashna | FarmHash "na" variant. |
farmhashnt | FarmHash "nt" variant. |
farmhashsa | FarmHash "sa" variant. |
farmhashsu | FarmHash "su" variant. |
farmhashte | FarmHash "te" variant. |
farmhashuo | FarmHash "uo" variant. |
farmhashxo | FarmHash "xo" variant. |
test | / internal variants |
| Name | Description |
|---|---|
uint128_t | Unsigned 128-bit integer type used for 128-bit hashes. |
| Name | Description |
|---|---|
Fingerprint | Fingerprint overloads |
Fingerprint128 | Fingerprint128 overloads |
Fingerprint32 | Fingerprint32 overloads |
Fingerprint64 | Fingerprint64 overloads |
Hash | Hash overloads |
Hash128 | Hash128 overloads |
Hash128WithSeed | Hash128WithSeed overloads |
Hash128to64 | Hashes 128 input bits down to 64 bits of output. |
Hash32 | Hash32 overloads |
Hash32WithSeed | Hash32WithSeed overloads |
Hash64 | Hash64 overloads |
Hash64WithSeed | Hash64WithSeed overloads |
Hash64WithSeeds | Hash64WithSeeds overloads |
Uint128 | Builds a 128-bit value from its low and high 64-bit halves. |
Uint128High64 | Returns the high 64 bits of a 128-bit value. |
Uint128Low64 | Returns the low 64 bits of a 128-bit value. |
FarmHash "cc" variant, derived from CityHash.
| Name | Description |
|---|---|
CityHash128WithSeed | Hashes a byte array to a 128-bit value using CityHash, mixing in a 128-bit seed. |
Fingerprint128 | Fingerprints a byte array to a 128-bit value. |
Fingerprint32 | Fingerprints a byte array to a 32-bit value. |
Fingerprint64 | Fingerprints a byte array to a 64-bit value. |
Hash | Hashes a byte array to a size_t value. |
Hash128 | Hashes a byte array to a 128-bit value. |
Hash128WithSeed | Hashes a byte array to a 128-bit value, mixing in a 128-bit seed. |
Hash32 | Hashes a byte array to a 32-bit value. |
Hash32WithSeed | Hashes a byte array to a 32-bit value, mixing in a 32-bit seed. |
Hash64 | Hashes a byte array to a 64-bit value. |
Hash64WithSeed | Hashes a byte array to a 64-bit value, mixing in a 64-bit seed. |
Hash64WithSeeds | Hashes a byte array to a 64-bit value, mixing in two 64-bit seeds. |
FarmHash "mk" variant.
| Name | Description |
|---|---|
Hash32 | Hashes a byte array to a 32-bit value. |
Hash32WithSeed | Hashes a byte array to a 32-bit value, mixing in a 32-bit seed. |
FarmHash "na" variant.
| Name | Description |
|---|---|
Hash64 | Hashes a byte array to a 64-bit value. |
Hash64WithSeed | Hashes a byte array to a 64-bit value, mixing in a 64-bit seed. |
Hash64WithSeeds | Hashes a byte array to a 64-bit value, mixing in two 64-bit seeds. |
FarmHash "nt" variant.
| Name | Description |
|---|---|
Hash32 | Hashes a byte array to a 32-bit value. |
Hash32WithSeed | Hashes a byte array to a 32-bit value, mixing in a 32-bit seed. |
FarmHash "sa" variant.
| Name | Description |
|---|---|
Hash32 | Hashes a byte array to a 32-bit value. |
Hash32WithSeed | Hashes a byte array to a 32-bit value, mixing in a 32-bit seed. |
FarmHash "su" variant.
| Name | Description |
|---|---|
Hash32 | Hashes a byte array to a 32-bit value. |
Hash32WithSeed | Hashes a byte array to a 32-bit value, mixing in a 32-bit seed. |
FarmHash "te" variant.
| Name | Description |
|---|---|
Hash64 | Hashes a byte array to a 64-bit value. |
Hash64WithSeed | Hashes a byte array to a 64-bit value, mixing in a 64-bit seed. |
Hash64WithSeeds | Hashes a byte array to a 64-bit value, mixing in two 64-bit seeds. |
FarmHash "uo" variant.
| Name | Description |
|---|---|
Hash64 | Hashes a byte array to a 64-bit value. |
Hash64WithSeed | Hashes a byte array to a 64-bit value, mixing in a 64-bit seed. |
FarmHash "xo" variant.
| Name | Description |
|---|---|
Hash64 | Hashes a byte array to a 64-bit value. |
Hash64WithSeed | Hashes a byte array to a 64-bit value, mixing in a 64-bit seed. |
Hash64WithSeeds | Hashes a byte array to a 64-bit value, mixing in two 64-bit seeds. |
/ internal variants
| Name | Description |
|---|---|
returnZeroIfMisconfigured | When set, hash functions return zero if the build is misconfigured. |
Implementation details of the rapidhash hashing algorithm.
| Name | Description |
|---|---|
rapidhashMicro_internal | rapidhashMicro main function. |
rapidhashNano_internal | rapidhashNano main function. |
rapidhash_internal | rapidhash main function. |
rapidhash_mix | Multiply and xor mix function. |
rapidhash_mum | 64*64 -> 128-bit multiply function. |
rapidhash_read32 | Reads a 32-bit value from an unaligned buffer. |
rapidhash_read64 | Reads a 64-bit value from an unaligned buffer. |
| Name | Description |
|---|---|
rapidhash_secret | Default secret parameters used to alter the hash result. |
Implementation details for the F14 hash table family.
| Name | Description |
|---|---|
test | Test-only helpers for F14 containers. |
| Name | Description |
|---|---|
DefaultAlloc | Default allocator for F14 container elements of type T. |
DefaultHasher | Default hasher for F14 containers keyed on T. |
DefaultKeyEqual | Default key-equality comparator for F14 containers keyed on T. |
Test-only helpers for F14 containers.
| Name | Description |
|---|---|
disableInsertOrderRandomization | Disables the randomized insertion ordering used in sanitizer and debug builds. |
A fallback implementation used when the standard trait is unavailable.
| Name | Description |
|---|---|
is_nothrow_convertible | A trait type that is true when From is nothrow-convertible to To. |
| Name | Description |
|---|---|
is_nothrow_convertible_v | A trait variable that is true when From is nothrow-convertible to To. |
Implementation details for fbstring.
| Name | Description |
|---|---|
copy_n | Copies n elements from an input range to an output range. |
podCopy | Copies a range of POD elements to a non-overlapping destination. |
podFill | Fills a range of POD elements with a given value. |
podMove | Moves a range of POD elements to a possibly overlapping destination. |
Lightweight cooperative userspace threads (fibers) and related primitives.
| Name | Description |
|---|---|
async | Async/await-style API for running fiber tasks. |
| Name | Description |
|---|---|
ABDCommitNotCalledException | An exception class that gets set on the promise for dispatched tokens, when the AtomicBatchDispatcher was destroyed before commit was called on it. |
ABDTokenNotDispatchedException | An exception class that gets set on the promise for dispatched tokens, when one or more other tokens in the batch were destroyed before dispatch was called on them. Only here so that the caller can distinguish the real failure cause rather than these subsequently thrown exceptions. |
ABDUsageException | An exception class that gets thrown when the AtomicBatchDispatcher is used incorrectly. This is indicative of a bug in the user code. Examples are, multiple dispatch calls on the same token, trying to get more tokens from the dispatcher after commit has been called, etc. |
AtomicBatchDispatcher | AtomicBatchDispatcher should be used if you want to process fiber tasks in parallel, but require to synchronize them at some point. The canonical example is to create a database transaction dispatch round. This API notably enforces that all tasks in the batch have reached the synchronization point before the user provided dispatch function is called with all the inputs provided in one function call. It also provides a guarantee that the inputs in the vector of inputs passed to the user provided dispatch function will be in the same order as the order in which the token for the job was issued. |
BatchDispatcher | BatchDispatcher is useful for batching values while doing I/O. For example, if you are launching multiple tasks which take a single id and each task fetches from database, you can use BatchDispatcher to batch those ids and do a single query requesting all those ids. |
BatchSemaphore | Fiber-compatible batch semaphore with ability to perform batch token increment/decrement. Will safely block fibers that wait when no tokens are available and wake fibers when signalled. |
Baton | Primitive which allows one to put current Fiber to sleep and wake it from another Fiber/thread. |
EventBaseLoopController | A LoopController that drives a FiberManager loop from a folly EventBase. |
ExecutorBasedLoopController | Interface for LoopController with publicly acessible executor |
ExecutorLoopController | A fiber loop controller that works for arbitrary folly::Executor |
ExecutorTimeoutManager | A TimeoutManager that schedules timeouts on a folly::Executor. |
Fiber | Fiber object used by FiberManager to execute tasks. |
FiberImpl | Low-level fiber wrapper over Boost.Context that switches execution contexts. |
FiberManager | Single-threaded task execution engine. |
FirstArgOf | Trait that yields the type of the first argument of a callable F. |
GuardPageAllocator | Stack allocator that protects an extra memory page after the end of the stack. Will only add extra memory pages up to a certain number of allocations to avoid creating too many memory maps for the process. |
LoopController | Interface driving the loop that runs a FiberManager's ready fibers. |
Semaphore | Fiber-compatible semaphore. Will safely block fibers that wait when no tokens are available and wake fibers when signalled. |
SemaphoreBase | Fiber-compatible semaphore base. Will safely block fibers that wait when no tokens are available and wake fibers when signalled. |
SimpleLoopController | A LoopController that drives a FiberManager loop inline, mainly for tests. |
StackCacheEntry | Caches fiber stacks with guard pages for reuse across allocations. |
TaskIterator | Traverses tasks scheduled by addTasks in the order they complete. |
TaskOptions | Options controlling how a fiber task is executed. |
TimedMutex | Like mutex but allows timed_lock in addition to lock and try_lock. |
TimedRWMutexImpl | A readers-writer lock which allows multiple readers to hold the lock simultaneously or only one writer. |
| Name | Description |
|---|---|
GenericBaton | Alias for the fiber-compatible Baton synchronization primitive. |
TimedRWMutex | A timed readers-writer mutex, defaulting to reader priority. |
TimedRWMutexReadPriority | A reader-preferred timed readers-writer mutex. |
TimedRWMutexWritePriority | A writer-preferred timed readers-writer mutex. |
once_flag | Fiber-compatible once flag backed by a TimedMutex. |
| Name | Description |
|---|---|
addTasks | addTasks overloads |
collectAll | collectAll overloads |
collectAny | collectAny overloads |
collectN | collectN overloads |
createAtomicBatchDispatcher | Creates an AtomicBatchDispatcher that uses the given dispatch function. |
forEach | Schedules several tasks and blocks until all of them are completed. In the process of their successful completion given callback would be called for each of them with the index of the task and the result it returned (if not void). If any of these n tasks throws an exception, this exception will be re-thrown, but only when all tasks are complete. If several tasks throw exceptions one of them will be re-thrown. Callback won't be called for tasks that throw exception. |
getFiberManagerT | Returns the fiber manager keyed by the local type Local for evb. |
installGuardPageSignalHandler | Unconditionally install the SIGSEGV handler that detects fiber stack overflow. Can be useful if the handler has been overridden by some other code overriding the SIGSEGV handler |
Async/await-style API for running fiber tasks.
| Name | Description |
|---|---|
Async | Asynchronous fiber result wrapper |
async_inner_type | Trait that extracts the inner value type wrapped by an Async type. |
await_fn | Callable type that awaits an Async wrapper via tag_invoke. |
| Name | Description |
|---|---|
async_inner_type_t | Inner value type wrapped by the Async type T. |
async_invocable_inner_type | Maps the Async result of invoking F with Args... to its inner value type. |
async_invocable_inner_type_t | Inner value type produced by invoking F with Args... and unwrapping the resulting Async. |
| Name | Description |
|---|---|
addFiber | Schedule an async-annotated functor to run on a fiber manager. |
addFiberFuture | Schedule an async-annotated functor to run on a fiber manager. Returns a Future for the result. |
addFiberRemote | Schedule an async-annotated functor to run on a remote thread's fiber manager. |
addFiberRemoteFuture | Schedule an async-annotated functor to run on a remote thread's fiber manager. Returns a future for the result. |
awaitTry | Await an async-annotated functor, capturing its result or exception in a Try. |
baton_try_wait_for | Async tagged wrapper that waits on a baton for a bounded duration. |
baton_try_wait_until | Async tagged wrapper that waits on a baton until a deadline. |
baton_wait | Async tagged wrapper that blocks on a baton until it is posted. |
collectAll | collectAll overloads |
executeOnFiberAndWait | executeOnFiberAndWait overloads |
executeOnNewFiber | Run an async-annotated functor on a new fiber, blocking the current fiber. |
executeOnRemoteFiber | Run an async-annotated functor on a new fiber on remote thread, blocking the current fiber. |
executeOnRemoteFiberAndWait | Run an async-annotated functor func, to completion on a remote fiber manager, blocking the current thread. |
executeWithNewRoot | Executes F with a new async-stack-root, making it possible to stitch stacks across async hops. |
fromTry | Convert a Try into an Async result, rethrowing any stored exception. |
futureWait | futureWait overloads |
init_await | init_await overloads |
promiseWait | Async annotated wrapper around fibers::await |
runInMainContextWithTracing | Connects the execution of synchronous function F (on the main thread context) to the calling fiber |
tag_invoke | tag_invoke overloads |
taskWait | taskWait overloads |
| Name | Description |
|---|---|
is_async_v | True when T is an instantiation of the Async wrapper. |
Portable wrappers and imports for file-descriptor operations.
| Name | Description |
|---|---|
close | Imported global close. |
open | Imported global open. |
pipe | Imported global pipe. |
read | Imported global read. |
write | Imported global write. |
Implementation details.
| Name | Description |
|---|---|
getTemporaryFilePathString | Returns a string compatible for mkstemp(). |
incr | incr overloads |
wrapFull | Wrap call to read/pread/write/pwrite(fd, buf, count, offset?) to retry on incomplete reads / writes. The variadic argument magic is there to support an additional argument (offset) for pread / pwrite; see the incr() functions above which do nothing if the offset is not present and increment it if it is. |
wrapNoInt | Wrap call to f(args) in loop to retry on EINTR. |
wrapvFull | Retry reading/writing iovec objects. |
Implementation details for folly::findFixed.
| Name | Description |
|---|---|
find16ByteReg | |
find16bytes | Searches 16 bytes for a value using a SIMD register. |
find2Overlaping | Searches a fixed-size range using two overlapping SIMD registers. |
find32bytes | Searches 32 bytes for a value using a SIMD register. |
find8bytes | Searches 8 bytes for a value using a SIMD register. |
findFixedConstexpr | Searches a range for a value with a constexpr-friendly scalar loop. |
findFixedDispatch | Dispatches a fixed-size search to the best strategy for the range size. |
findFixedLetTheCompilerDoIt | Searches a fixed-size range with a plain scalar loop the compiler can unroll. |
findSplitFirstRegister | Searches a fixed-size range by splitting off a leading SIMD register. |
firstTrue | Returns the index of the first set element in a SIMD comparison register. |
| Name |
|---|
kMaxSimdRegister |
The user should return loop_break and loop_continue if they want to iterate in such a way that they can preemptively stop the loop and break out when certain conditions are met.
| Name | Description |
|---|---|
LoopControl | Signals whether a for_each callback wants to stop or keep iterating. |
Utilities for all format value specializations.
| Name | Description |
|---|---|
formatFormatter | Format a Formatter object recursively. Behaves just like formatString(fmt.str(), arg, cb); but avoids creating a temporary string if possible. |
formatNumber | Format a number in "val"; the first prefixLen characters form the prefix (sign, "0x" base prefix, etc) which must be left-aligned if the alignment is Align::PAD_AFTER_SIGN. Treats Align::DEFAULT as Align::LEFT. Ignores arg.precision, as that has a different meaning for numbers (not "maximum field width") |
formatString | Format a string in "val", obeying appropriate alignment, padding, width, and precision. Treats Align::DEFAULT as Align::LEFT, and Align::PAD_AFTER_SIGN as Align::RIGHT; use formatNumber for number-specific formatting. |
Portable filesystem imports selecting the available <filesystem> backend.
| Name | Description |
|---|---|
std_fs | Alias for the selected standard filesystem namespace. |
| Name | Description |
|---|---|
unique_path_fn | Function object that generates a unique path from a model. |
| Name | Description |
|---|---|
std_fs_unique_path_fn | Callable type that generates a unique path from a model. |
| Name | Description |
|---|---|
which_enum | Identifies which standard filesystem implementation is in use. |
| Name | Description |
|---|---|
canonical_parent | Canonicalize the parent path, leaving the filename (last component) unchanged. You may use this before creating a file instead of boost::filesystem::canonical, which requires that the entire path exists. |
executable_path | Get the path to the current executable. |
lexically_normal | Returns the lexically normal form of the given path. |
remove_prefix | If "path" starts with "prefix", return "path" with "prefix" removed. Otherwise, throw filesystem_error. |
starts_with | Check whether "path" starts with "prefix". That is, if prefix has n path elements, then the first n elements of path must be the same as prefix. |
| Name | Description |
|---|---|
std_fs_unique_path | Callable that generates a unique path from a model. |
which | The filesystem implementation selected at compile time. |
| Name | Description |
|---|---|
absolute | Imported std::filesystem::absolute. |
canonical | Imported std::filesystem::canonical. |
copy | Imported std::filesystem::copy. |
copy_file | Imported std::filesystem::copy_file. |
copy_options | Imported std::filesystem::copy_options. |
copy_symlink | Imported std::filesystem::copy_symlink. |
create_directories | Imported std::filesystem::create_directories. |
create_directory | Imported std::filesystem::create_directory. |
create_directory_symlink | Imported std::filesystem::create_directory_symlink. |
create_hard_link | Imported std::filesystem::create_hard_link. |
create_symlink | Imported std::filesystem::create_symlink. |
current_path | Imported std::filesystem::current_path. |
directory_entry | Imported std::filesystem::directory_entry. |
directory_iterator | Imported std::filesystem::directory_iterator. |
directory_options | Imported std::filesystem::directory_options. |
equivalent | Imported std::filesystem::equivalent. |
exists | Imported std::filesystem::exists. |
file_size | Imported std::filesystem::file_size. |
file_status | Imported std::filesystem::file_status. |
file_time_type | Imported std::filesystem::file_time_type. |
file_type | Imported std::filesystem::file_type. |
filesystem_error | Imported std::filesystem::filesystem_error. |
hard_link_count | Imported std::filesystem::hard_link_count. |
is_block_file | Imported std::filesystem::is_block_file. |
is_character_file | Imported std::filesystem::is_character_file. |
is_directory | Imported std::filesystem::is_directory. |
is_empty | Imported std::filesystem::is_empty. |
is_fifo | Imported std::filesystem::is_fifo. |
is_other | Imported std::filesystem::is_other. |
is_regular_file | Imported std::filesystem::is_regular_file. |
is_socket | Imported std::filesystem::is_socket. |
is_symlink | Imported std::filesystem::is_symlink. |
last_write_time | Imported std::filesystem::last_write_time. |
path | Imported std::filesystem::path. |
perm_options | Imported std::filesystem::perm_options. |
permissions | Imported std::filesystem::permissions. |
perms | Imported std::filesystem::perms. |
proximate | Imported std::filesystem::proximate. |
read_symlink | Imported std::filesystem::read_symlink. |
recursive_directory_iterator | Imported std::filesystem::recursive_directory_iterator. |
relative | Imported std::filesystem::relative. |
remove | Imported std::filesystem::remove. |
remove_all | Imported std::filesystem::remove_all. |
rename | Imported std::filesystem::rename. |
resize_file | Imported std::filesystem::resize_file. |
space | Imported std::filesystem::space. |
space_info | Imported std::filesystem::space_info. |
status | Imported std::filesystem::status. |
status_known | Imported std::filesystem::status_known. |
symlink_status | Imported std::filesystem::symlink_status. |
temp_directory_path | Imported std::filesystem::temp_directory_path. |
u8path | Imported std::filesystem::u8path. |
weakly_canonical | Imported std::filesystem::weakly_canonical. |
Futures-based asynchronous programming primitives.
| Name | Description |
|---|---|
Barrier | A folly::Future-istic Barrier synchronization primitive. |
| Name | Description |
|---|---|
retrying | Retries a future-factory according to a policy, returning a SemiFuture. |
retryingPolicyBasic | Builds a retry policy that retries until a maximum number of attempts. |
retryingPolicyCappedJitteredExponentialBackoff | retryingPolicyCappedJitteredExponentialBackoff overloads |
retryingUnsafe | retrying and retryingUnsafe |
Lazy sequence generators and pipeline operators.
| Name | Description |
|---|---|
Cast | Function object that constructs a Dest from a value. |
ConstMemberFunction | Function object that calls a const member function of a class. |
ExprIsConst | These exist because MSVC has problems with expression SFINAE in templates assignment and comparisons don't work properly without being pulled out of the template declaration |
ExprIsMutable | SFINAE helper exposing whether Constness selects the mutable overload. |
Field | Function object that accesses a data member of a class. |
GenImpl | CRTP base for sequence generators that yield Value. |
Get | Function object that extracts the nth element of a tuple-like value. |
Greater | Function object that compares two values with operator>. |
Group | Groups the values of a sequence by a computed key. |
Less | Function object that compares two values with operator<. |
MemberFunction | Function object that calls a non-const member function of a class. |
MixedNewlines | EOL terms ("r", "n", or "rn"). |
Move | Function object that casts its argument to an rvalue reference. |
Negate | Class and helper function for negating a boolean Predicate |
Operator | CRTP base for pipeline operators applied to generators. |
StreamSplitter | Outputs exactly the same bytes as the input stream, in different chunks. A chunk boundary occurs after each delimiter, or, if maxLength is non-zero, after maxLength bytes, whichever comes first. Your callback can return false to stop consuming the stream at any time. |
To | Function object that converts values to Dest via folly::to. |
TryTo | Function object that converts values to Dest, returning an Expected. |
VirtualGen | Polymorphic wrapper |
VirtualGenMoveOnly | Move-only polymorphic wrapper for a generator yielding Value. |
| Name | Description |
|---|---|
MemberType | Selects the const or non-const overload of a member accessor. |
| Name | Description |
|---|---|
all | all() - For determining whether all values in a sequence satisfy a predicate. |
any | any() - For determining if any value in a sequence satisfies a predicate. |
appendTo | Appends each value of a sequence to an existing collection. |
as | as overloads |
assert_type | Asserts at compile time that the sequence yields the given value type. |
byLine | Generates the lines of an input stream, one std::string at a time. |
chunked | chunked overloads |
contains | Determines whether a sequence contains a given value. |
distinctBy | Keeps only the first value for each distinct selected key. |
eachAs | Constructs a Dest from each value. |
eachTo | Calls folly::to on each value, converting it to Dest. |
eachToPair | eachToPair overloads |
eachToTuple | eachToTuple overloads |
eachTryTo | Calls folly::tryTo on each value, mapping to an Expected of Dest. |
empty | Produces an empty sequence of the given value type. |
field | Extracts a data member from each value. |
filter | Keeps only values that satisfy the predicate. |
foldl | Left-folds a sequence into a single value from an initial seed. |
from | from overloads |
fromConst | Produces a sequence referencing the elements of a const container. |
fromCopy | Produces a sequence holding copies of the elements of a container. |
fromFile | fromFile overloads |
generator | Wraps a source callable as a generator yielding Value. |
get | Extracts the nth element of each tuple-like value. |
groupBy | Groups all values by their selected key. |
groupByAdjacent | Groups consecutive values that share the same selected key. |
guard | Wraps a pipeline so exceptions of a given type are passed to a handler. |
interleave | Interleaves values from the source pipeline with those from source2. |
just | Produces a sequence containing a single value. |
lines | Split by EOL ("r", "n", or "rn"). |
map | Applies a function to each value, yielding the results. |
mapOp | mapOp - Given a generator of generators, maps the application of the given operator on to each inner gen. Especially useful in aggregating nested data structures: |
mapped | Applies a function to each value, yielding the results. |
maxBy | Finds the value with the maximum selected key. |
member | member overloads |
minBy | Finds the value with the minimum selected key. |
negate | Creates a predicate that negates the result of pred. |
orderBy | Orders values by their selected key using the given comparer. |
orderByDescending | Orders values in descending order of their selected key. |
parallel | parallel - A parallelization operator. |
pmap | Run pred in parallel in nThreads. Results are returned in the same order in which they were retrieved from the source generator (similar to map). |
range | range overloads |
reduce | Reduces a sequence to a single value using a binary reducer. |
resplit | Split the output from a generator into StringPiece "lines" delimited by the given delimiter. Delimters are NOT included in the output. |
seq | seq overloads |
split | split overloads |
streamSplitter | Creates a StreamSplitter, deducing the callback type. |
sub | sub - For sub-summarization of a sequence. |
takeWhile | Yields values while the predicate holds, then stops. |
toFile | toFile overloads |
unsplit | unsplit overloads |
until | Yields values until the predicate holds, then stops. |
unwrapOr | Unwraps an optional-like value, using a fallback when it is empty. |
visit | Applies a visitor to each value, passing values through unchanged. |
Minimal stand-in for the gflags namespace when gflags is unavailable.
| Name | Description |
|---|---|
FlagSaver | No-op replacement for the gflags command-line flag saver. |
| Name | Description |
|---|---|
SetCommandLineOption | Stub that ignores an attempt to set a command-line flag. |
Hashing algorithms and helpers.
| Name | Description |
|---|---|
farmhash | FarmHash hashing and fingerprinting functions imported from the bundled external implementation. |
| Name | Description |
|---|---|
SpookyHashV1 | SpookyHash V1: a 128-bit noncryptographic hash function by Bob Jenkins. |
SpookyHashV2 | SpookyHash V2: a 128-bit noncryptographic hash function by Bob Jenkins. |
StdHasher | Hasher that forwards to std::hash for each key type. |
| Name | Description |
|---|---|
commutative_hash_128_to_64 | Order-independent reduction of two 64-bit hashes into one. |
commutative_hash_combine | Combine hashes of multiple items, order-independently. |
commutative_hash_combine_generic | Combine hashes of multiple items, order-independently. |
commutative_hash_combine_range | Create a hash from multiple hashable objects, order-independently. |
commutative_hash_combine_range_generic | Create a hash from multiple hashable objects, order-independently. |
commutative_hash_combine_value_generic | Hash a value, and combine it with a seed. Commutative. |
fnv32 | Alias for fnv32_BROKEN. |
fnv32_BROKEN | fnv32_BROKEN overloads |
fnv32_FIXED | fnv32_FIXED overloads |
fnv32_append_byte | Alias for fnv32_append_byte_BROKEN. |
fnv32_append_byte_BROKEN | Append byte to FNV hash. |
fnv32_append_byte_FIXED | Append byte to FNV hash. |
fnv32_buf | fnv32_buf overloads |
fnv32_buf_BROKEN | fnv32_buf_BROKEN overloads |
fnv32_buf_FIXED | fnv32_buf_FIXED overloads |
fnv64 | Alias for fnv64_BROKEN. |
fnv64_BROKEN | fnv64_BROKEN overloads |
fnv64_FIXED | fnv64_FIXED overloads |
fnv64_append_byte | Alias for fnv64_append_byte_BROKEN. |
fnv64_append_byte_BROKEN | Append a byte to FNV hash. |
fnv64_append_byte_FIXED | Append a byte to FNV hash. |
fnv64_buf | fnv64_buf overloads |
fnv64_buf_BROKEN | fnv64_buf_BROKEN overloads |
fnv64_buf_FIXED | fnv64_buf_FIXED overloads |
fnva32 | FNVA hash of a string. |
fnva32_append_byte | Append a byte to FNVA hash. |
fnva32_buf | fnva32_buf overloads |
fnva64 | FNVA hash of a string. |
fnva64_append_byte | Append a byte to FNVA hash. |
fnva64_buf | fnva64_buf overloads |
hash_128_to_64 | Reduce two 64-bit hashes into one. |
hash_combine | Combine hashes of multiple items, order-dependently. |
hash_combine_generic | hash_combine_generic overloads |
hash_range | Combine hashes of items in the range [first, last), order-dependently.] |
hsieh_hash32 | hsieh hash a c-str. |
hsieh_hash32_buf | hsieh hash a void* byte-range. |
hsieh_hash32_buf_constexpr | hsieh hash a byte-range. |
hsieh_hash32_str | hsieh hash a string. |
jenkins_rev_mix32 | Robert Jenkins' reversible 32 bit mix hash function. |
jenkins_rev_unmix32 | Inverse of jenkins_rev_mix32. |
lowbias_mix32 | Low-bias 32 bit mix function. |
lowbias_unmix32 | Inverse of lowbias_mix32. |
moremur_mix64 | Pelle Evensen's moremur 64 bit mix function. |
moremur_unmix64 | Inverse of moremur_mix64. |
murmurHash64 | Implementation of MurmurHash2 hashing algorithm for 64-bit platforms. |
stdCompatibleHash | Hash a string view compatibly with std::hash, using a faster murmur-based hash where available. |
twang_32from64 | Thomas Wang downscaling hash function. |
twang_mix64 | Thomas Wang 64 bit mix hash function. |
twang_unmix64 | Inverse of twang_mix64. |
| Name | Description |
|---|---|
fnv32_hash_start | FNV-1 32-bit offset-basis seed, the starting value for 32-bit FNV hashing. |
fnv64_hash_start | FNV-1 64-bit offset-basis seed, the starting value for 64-bit FNV hashing. |
fnva32_hash_start | FNV-1a 32-bit offset-basis seed, the starting value for 32-bit FNV-1a hashing. |
fnva64_hash_start | FNV-1a 64-bit offset-basis seed, the starting value for 64-bit FNV-1a hashing. |
| Name | Description |
|---|---|
rapidhash | Hash a byte buffer with rapidhash, uint64_t rapidhash(const char* key, size_t len). |
rapidhashMicro | Hash a byte buffer with the rapidhashMicro variant, uint64_t rapidhashMicro(const char* key, size_t len). |
rapidhashMicro_with_seed | Hash a byte buffer with rapidhashMicro and an explicit seed, uint64_t rapidhashMicro_with_seed(const char* key, size_t len, uint64_t seed). |
rapidhashNano | Hash a byte buffer with the rapidhashNano variant, uint64_t rapidhashNano(const char* key, size_t len). |
rapidhashNano_with_seed | Hash a byte buffer with rapidhashNano and an explicit seed, uint64_t rapidhashNano_with_seed(const char* key, size_t len, uint64_t seed). |
rapidhash_with_seed | Hash a byte buffer with rapidhash and an explicit seed, uint64_t rapidhash_with_seed(const char* key, size_t len, uint64_t seed). |
FarmHash hashing and fingerprinting functions imported from the bundled external implementation.
| Name | Description |
|---|---|
Fingerprint32 | Fingerprint a byte buffer to a stable 32-bit value, uint32_t Fingerprint32(char const*, std::size_t). |
Fingerprint64 | Fingerprint a byte buffer to a stable 64-bit value, uint64_t Fingerprint64(char const*, std::size_t). |
Hash | Hash a byte buffer to a std::size_t, std::size_t Hash(char const*, std::size_t). |
Hash32 | Hash a byte buffer to a 32-bit value, uint32_t Hash32(char const*, std::size_t). |
Hash64 | Hash a byte buffer to a 64-bit value, uint64_t Hash64(char const*, std::size_t). |
Implementation details of the folly invocation traits.
| Name | Description |
|---|---|
conv_r_ | Tests return-type convertibility, specialized on whether the target is void. |
invoke_result | Holds the result type of invoking F with A..., or is empty if ill-formed. |
ok_one_ | Quoted metafunction enforcing that a type is complete, cv-void, or unbounded-array. |
traits | Invocation traits for a callable type F. |
traits_member_ptr | Invocation traits for a pointer-to-member P, via std::mem_fn. |
| Name | Description |
|---|---|
invoke_result_t | The result type of invoking F with A.... |
is_nothrow | Bool constant that is true when invoking P with A... is noexcept. |
ok_ | Yields T when every A... is complete, cv-void, or unbounded-array. |
| Name | Description |
|---|---|
conv_r_v_ | True if FR converts to R, honoring the noexcept requirement NX. |
is_invocable_r_v | True if invoking F with A... yields a result convertible to R. |
is_invocable_r_v | Specialization testing return-type convertibility when the invocation is well-formed. |
is_invocable_v | True if F is invocable with A.... |
is_invocable_v | Specialization yielding true when the invocation is well-formed. |
is_nothrow_invocable_r_v | True if a nothrow invocation of F yields a result convertible to R. |
is_nothrow_invocable_r_v | Specialization testing nothrow invocation and return convertibility when well-formed. |
is_nothrow_invocable_v | True if F is nothrow-invocable with A.... |
is_nothrow_invocable_v | Specialization yielding the nothrow result when the invocation is well-formed. |
Cursor and queue utilities for reading and writing IOBuf chains.
| Name | Description |
|---|---|
Appender | Append to the end of a buffer chain, growing the chain (by allocating new buffers) in increments of at least growth bytes every time. Won't grow (and push() and ensure() will throw) if growth == 0. |
Cursor | Read-only cursor over an IOBuf chain. |
CursorBase | Base class implementing the shared cursor logic over an IOBuf chain. |
QueueAppender | Appender that writes to the end of an IOBufQueue. |
RWCursor | Read-write cursor over an IOBuf chain. |
ThinCursor | A register-pass facade for a Cursor over an IOBuf chain. |
Writable | Mixin providing write operations for cursor types. |
| Name | Description |
|---|---|
RWPrivateCursor | Read-write cursor that assumes private access to the IOBuf chain. |
RWUnshareCursor | Read-write cursor that unshares (copy-on-write) buffers before writing. |
| Name | Description |
|---|---|
CloneOwnership | Whether a clone may point at buffers that IOBuf does not own. |
CursorAccess | Selects whether a read-write cursor unshares buffers before writing. |
JSON parsing and serialization utilities.
| Name | Description |
|---|---|
parse_error | Error thrown when deserializing json (i.e. converting a string into json). |
parse_location | Source location of a parsed value (may be extended in the future to include offset, column, etc.). |
parse_metadata | Parse metadata describing where a value's key and value appear in the source text. |
parse_range | Source range of a parsed value (may be extended in the future to include an end location). |
print_error | Error thrown when serializing json (i.e. converting json into a string). |
serialization_opts | Options controlling how a dynamic is serialized to and parsed from JSON. |
| Name | Description |
|---|---|
metadata_map | Maps each parsed dynamic to its parse metadata. |
| Name | Description |
|---|---|
FloatFormat | Specifies how to format floating-point values in serialized JSON output. |
| Name | Description |
|---|---|
buildExtraAsciiToEscapeBitmap | Create bitmap for serialization_opts.extra_ascii_to_escape_bitmap. |
escapeString | Escape a string so that it is legal to print it in JSON text. |
serialize | Serialize dynamic to json-string, with options. |
stripComments | Strip all C99-like comments (i.e. // and / * ... * /) |
JSON Schema (draft v4) validation utilities.
| Name | Description |
|---|---|
Validator | Interface for a schema validator. |
| Name | Description |
|---|---|
makeSchemaValidator | Makes a validator for schemas. You should probably check your schema with this before you use makeValidator(). |
makeValidator | Make a validator that can be used to check various json. Thread-safe. |
Implementation details for libc++ bitset support.
| Name | Description |
|---|---|
std_bit_reference_layout | Memory layout mirroring libc++'s std::__bit_reference. |
| Name | Description |
|---|---|
get_underlying_data_region | Return the content of the 64-bit word, given an index. |
std_bitset_find_next | Return the index of the first set bit in a bitset at or after an index. |
Folly's logging library.
| Name | Description |
|---|---|
BridgeFromGoogleLogging | Class to bridge GLOG to folly logging. |
IntervalRateLimiter | Rate limiter allowing up to N events per fixed window of M milliseconds. |
| Name | Description |
|---|---|
appendRawObjectInfo | Append raw information about an object to a string. |
appendToString | appendToString overloads |
objectToString | Convert an arbitrary object to a string for logging purposes. |
Memory management utilities.
| Name | Description |
|---|---|
makeIOBufArenaFactory | Builds an IOBuf factory backed by the given singleton allocator. |
| Name | Description |
|---|---|
IOBufSingletonAllocator | Requirements for a singleton allocator usable with an IOBuf arena factory. |
Internal namespace hosting the copy/move control base types.
| Name | Description |
|---|---|
Default | Empty base that permits both copy and move. |
MoveOnly | Disallow copy but not move in derived types. This is essentially boost::noncopyable (the implementation is almost identical), except: 1) It doesn't delete move constructor and move assignment. 2) It has public methods, enabling aggregate initialization. |
NonCopyableNonMovable | Disallow copy and move for derived types. This is essentially boost::noncopyable (the implementation is almost identical), except it has public methods, enabling aggregate initialization. |
| Name | Description |
|---|---|
EnableCopyMove | Base type selecting copy/move capabilities from the given flags. |
Cross-platform socket operation wrappers.
| Name | Description |
|---|---|
Dispatcher | Dispatcher for netops:: calls. |
DispatcherContainer | Container for netops::Dispatcher. |
Msgheader | A msghdr/WSAMSG struct wrapper for cross-platform use. |
PollDescriptor | Poll descriptor is intended to be byte-for-byte identical to pollfd, except that it is typed as containing a NetworkSocket for sane interactions. |
sock_txtime | |
tcp_zerocopy_receive | |
xdp_umem_reg | |
xsk_tx_metadata |
| Name |
|---|
timestamping_flags |
tstamp_flags |
txtime_flags |
| Name | Description |
|---|---|
accept | Accepts a connection on a listening socket. |
bind | Binds a socket to a local address. |
close | Closes a socket. |
connect | Connects a socket to a remote address. |
getpeername | Retrieves the address of the connected peer. |
getsockname | Retrieves the local address bound to a socket. |
getsockopt | Retrieves a socket option. |
inet_aton | Converts an IPv4 dotted-decimal string to a network address. |
listen | Marks a socket as accepting connections. |
poll | Waits for events on a set of poll descriptors. |
recv | Receives data from a connected socket. |
recvfrom | Receives data and records the source address. |
recvmmsg | Receives multiple messages in a single call. |
recvmsg | Receives a message, including ancillary data. |
send | Sends data on a connected socket. |
sendmmsg | Sends multiple messages in a single call. |
sendmsg | Sends a message, including ancillary data. |
sendto | Sends data to a specific destination address. |
set_socket_blocking | Puts a socket into blocking mode. |
set_socket_close_on_exec | Sets the close-on-exec flag on a socket. |
set_socket_non_blocking | Puts a socket into non-blocking mode. |
setsockopt | Sets a socket option. |
shutdown | Shuts down part or all of a full-duplex connection. |
socket | Creates a socket. |
socketpair | Creates a connected pair of sockets. |
Folly's observer library.
| Name | Description |
|---|---|
AtomicObserver | An AtomicObserver provides read-optimized caching for an Observer using std::atomic. Reading only requires atomic loads unless the cached value is stale. If the cache needs to be refreshed, a mutex is used to synchronize the update. This avoids creating a shared_ptr for every read. |
CallbackHandle | Owns a callback subscription to an Observer. |
CoreCachedObserver | A read-optimized observer that caches an observer's snapshot with core-local sharing. |
HazptrObserver | HazptrObserver implements a read-optimized Observer which caches an Observer's snapshot and protects access to it using hazptrs. The cached snapshot is kept up to date using a callback which fires when the original observer changes. This implementation incurs an additional allocation on updates making it less suitable for write-heavy workloads. |
ObservableTraits | Default traits describing how to read from and subscribe to an observable. |
Observer | Observer - a library which lets you create objects which track updates of their dependencies and get re-computed when any of the dependencies changes. |
ObserverCreator | Creates an Observer from an observable using the given traits. |
ObserverTraits | Maps a value type to the observer type used to cache it. |
ReadMostlyAtomicObserver | A ReadMostlyAtomicObserver guarantees that reading is exactly one relaxed atomic load and a read from a thread local bool. Like AtomicObserver, the value is cached using std::atomic. However, there is no version check when reading which means that the cached value may be out-of-date with the Observer value. The cached value will be updated asynchronously in a background thread. |
ReadMostlyTLObserver | A TLObserver that optimizes for getting a shared_ptr-like pointer to data. |
SimpleObservable | An observable whose value is set manually and read through an Observer. |
Snapshot | A stable view of an observed value at a point in time. |
TLObserver | A TLObserver provides read-optimized caching for an Observer using thread-local storage. This avoids creating a shared_ptr for every read. |
| Name | Description |
|---|---|
ObserverT | Alias for the observer type selected by ObserverTraits. |
| Name | Description |
|---|---|
makeAtomicObserver | makeAtomicObserver overloads |
makeCoreCachedObserver | makeCoreCachedObserver overloads |
makeHazptrObserver | makeHazptrObserver overloads |
makeObserver | makeObserver overloads |
makeReadMostlyAtomicObserver | makeReadMostlyAtomicObserver overloads |
makeReadMostlyTLObserver | makeReadMostlyTLObserver overloads |
makeStaticObserver | makeStaticObserver overloads |
makeTLObserver | makeTLObserver overloads |
makeValueObserver | makeValueObserver overloads |
unwrap | unwrap overloads |
unwrapValue | unwrapValue overloads |
withJitter | The returned Observer will proxy updates from the input observer but will delay the propagation of each update by some duration between 0 ms and lag + jitter. In addition, if an update arrives while no preceding jittered updates are still in flight, then the delay applied to the latest update will be a uniformly random duration between lag - jitter and lag + jitter. |
Implementation details.
| Name | Description |
|---|---|
Core | Core stores the current version of the object held by Observer. It also keeps all dependencies and dependents of the Observer. |
GraphCycleDetector | Tracks directed edges and rejects any that would introduce a cycle. |
NonObserver | Yields the decayed type unless T is an Observer, in which case it is empty. |
NonSharedPtr | Yields the decayed type unless T is a shared_ptr, in which case it is empty. |
Unwrap | Removes an Observer wrapper from a type, if present. |
UnwrapObserver | Extracts the value type from an Observer; empty for other types. |
UnwrapSharedPtr | Extracts the element type from a shared_ptr; empty for other types. |
| Name | Description |
|---|---|
ResultOf | The result of invoking F, with any shared_ptr or Observer wrapper removed. |
ResultOfNoObserverUnwrap | The result of invoking F, with any shared_ptr wrapper removed. |
ResultOfUnwrapObserver | The Observer value type produced by invoking F. |
ResultOfUnwrapSharedPtr | The shared_ptr element type produced by invoking F. |
Utilities for storing data aligned on block (possibly cache-line) boundaries, with optional padding.
| Name | Description |
|---|---|
Adaptor | Adaptor around a STL sequence container. |
Iterator | Wrapper around iterators to Node to return iterators to the underlying node elements. |
Node | A Node is a fixed-size container of as many objects of type T as would fit in a region of memory of size NS. The last NS % sizeof(T) bytes are ignored and uninitialized. |
| Name | Description |
|---|---|
begin | begin overloads |
cbegin | Given a container to Node, return iterators to the first element in the first Node / one past the last element in the last Node. Note that the last node is assumed to be full; if that's not the case, subtract from end() as appropriate. |
cend | Returns a const element iterator one past the last element in the last Node. |
end | end overloads |
Aliases that use a polymorphic allocator.
| Name | Description |
|---|---|
F14FastMap | F14FastMap specialized to use a std::pmr polymorphic allocator. |
F14FastSet | F14FastSet specialized to use a std::pmr polymorphic allocator. |
F14NodeMap | F14NodeMap specialized to use a std::pmr polymorphic allocator. |
F14NodeSet | F14NodeSet specialized to use a std::pmr polymorphic allocator. |
F14ValueMap | F14ValueMap specialized to use a std::pmr polymorphic allocator. |
F14ValueSet | F14ValueSet specialized to use a std::pmr polymorphic allocator. |
F14VectorMap | F14VectorMap specialized to use a std::pmr polymorphic allocator. |
F14VectorSet | F14VectorSet specialized to use a std::pmr polymorphic allocator. |
heap_vector_map | A heap_vector_map that uses a polymorphic allocator. |
heap_vector_set | A heap_vector_set that uses a polymorphic allocator. |
sorted_vector_map | A sorted_vector_map that uses a polymorphic allocator. |
sorted_vector_set | A sorted_vector_set that uses a polymorphic allocator. |
vector_bool | Alias for vector_bool using a polymorphic allocator. |
Interfaces and helpers for the Poly type-erasure utility.
| Name | Description |
|---|---|
IBooleanTestable | A Poly interface that can be used to make Poly objects contextually convertible to bool (true if and only if non-empty). It also gives Poly objects a unary logical negation operator. |
IEqualityComparable | A Poly interface for types that are equality comparable. |
IMoveOnly | A Poly interface for types that are move-only. |
INullablePointer | A Poly interface that can be used to make Poly objects initializable from nullptr (to create an empty Poly) and equality comparable to nullptr (to test for emptiness). |
IRegular | A Poly interface for types that are copyable, movable, and equality comparable. |
ISemiRegular | A Poly interface for types that are copyable and movable. |
IStrictlyOrderable | A Poly interface for types that are strictly orderable. |
| Name | Description |
|---|---|
operator== | Tests whether a Poly object is empty. |
operator!= | Tests whether a Poly object is non-empty. |
Portability shims for platform-specific system interfaces.
| Name | Description |
|---|---|
sockets | Portable wrappers and imports for BSD socket functions. |
stdlib | Portable wrappers and imports for C standard library routines. |
| Name | Description |
|---|---|
internal_dirname | Returns the directory portion of a path, without modifying the input. |
Portable wrappers and imports for BSD socket functions.
| Name | Description |
|---|---|
accept | Imported global accept. |
bind | Imported global bind. |
connect | Imported global connect. |
getpeername | Imported global getpeername. |
getsockname | Imported global getsockname. |
getsockopt | Imported global getsockopt. |
inet_ntop | Imported global inet_ntop. |
listen | Imported global listen. |
poll | Imported global poll. |
recv | Imported global recv. |
recvfrom | Imported global recvfrom. |
send | Imported global send. |
sendmsg | Imported global sendmsg. |
sendto | Imported global sendto. |
setsockopt | Imported global setsockopt. |
shutdown | Imported global shutdown. |
socket | Imported global socket. |
Portable wrappers and imports for C standard library routines.
Low-level helpers exposing the RecordIO record format.
| Name | Description |
|---|---|
RecordInfo | A record and the file id it was written with. |
| Name | Description |
|---|---|
findRecord | findRecord overloads |
headerSize | Header size. |
prependHeader | Write a header in the buffer. We will prepend the header to the front of the chain. Do not write the buffer if empty (we don't allow empty records). Returns the total length, including header (0 if empty) (same as buf->computeChainDataLength(), but likely faster) |
validateRecord | Check if there is a valid record at the beginning of range. This validates both record header and data and Returns the record data (not the header) if the record is valid, ByteRange() otherwise. |
validateRecordData | Check if there Record Data is valid (to be used after validating the header separately) Returns the record data (not the header) if the record data is valid, ByteRange() otherwise. |
validateRecordHeader | Check if the Record Header is valid at the beginning of range. Useful to check the validity of the header before building the entire record in IOBuf. If the record is from storage device (e.g. flash) then, it is better to make sure that the header is valid before reading the data from the storage device. Returns true if valid, false otherwise. |
Implementation details for Replaceable; not part of the public API.
| Name | Description |
|---|---|
copy_assignment_mixin | Mixin supplying the copy-assignment operator for Replaceable<T> that matches the corresponding properties of T. |
copy_ctor_mixin | Mixin supplying the copy constructor for Replaceable<T> that matches the copy-constructibility of T. |
default_and_move_ctor_mixin | Mixin supplying default and move constructors for Replaceable<T> that match the corresponding properties of T. |
dtor_mixin | Mixin supplying a destructor for Replaceable<T> that matches the destructibility of T. |
is_constructible_from_replaceable | Trait that is true if T is constructible from any Replaceable<T> reference. |
is_convertible_from_replaceable | Trait that is true if any Replaceable<T> reference is convertible to T. |
move_assignment_mixin | Mixin supplying the move-assignment operator for Replaceable<T> that matches the corresponding properties of T. |
Runtime configuration settings framework.
| Name | Description |
|---|---|
CommandLineParser | Parses command line arguments into folly::settings. |
FrozenSettingProjects | An immutable snapshot of the set of frozen setting projects. |
ISettingsAccessorProxy | Interface for applying string-based setting changes to a snapshot. |
SettingMetadata | Static information about the setting definition |
SettingValueAndMetadata | Type containing the string representation of a setting as well as the static metadata associated with it. Used as the "source" in setting conversion. |
SettingsAccessorProxy | This class is a proxy for working with folly::settings represented as strings. It can apply changes to these folly::settings via snapshot provided by user. Changes are not going to be published by this class, it is callers resposibility to commit/publish cahnges from snapshot into global state. |
Snapshot | Captures the current state of all setting values and allows updating multiple settings at once, with verification and rollback. |
| Name | Description |
|---|---|
SetResult | Result of a setting update operation: Unit on success or a SetErrorCode. |
| Name | Description |
|---|---|
ArgParsingResult | Outcome of parsing command line arguments. |
CommandLine | Indicates whether a setting accepts overrides from the command line. |
Mutability | Indicates whether a setting can change after initialization. |
SetErrorCode | Error codes for a failed setting update. |
| Name | Description |
|---|---|
convertTo | Like parseTo in folly/Conv.h, but the "source" is SettingValueAndMetadata instead of a StringPiece. Defaults to folly::tryTo<T>(StringPiece) but can be overridden using ADL for user defined types. |
freezeImmutables | Freezes immutable settings - preventing subsequent mutation attempts. It's up to the caller to call this function after settings have been initialized. |
frozenSettingProjects | Returns a snapshot of the current set of frozen setting projects. |
getAllSettingsMeta | Returns the metadata for all registered settings in the process. |
getDefaultValue | Returns the default value of a setting by name, if it exists and has type T. |
getObserver | Gets a folly::observer::Observer<T> for a given setting. For example: folly::settings::getObserver(FOLLY_SETTING(project, retention)) |
getSettingsMeta | Returns the metadata for a setting by name, if it exists. |
immutablesFrozen | Reports whether immutable settings for a project have been frozen. |
parseCommandLineArguments | Main function to parse arguments folly::settings. This function parses command line arguments into folly::settings. It moves all positional, --help, not recognized flags and their values to the end of the argv array. It stops parsing arguments after '--' is encoutered. |
printHelpIfNeeded | Outputs help message into stderr. May terminate program if error was encoutered during arguments parsing or exit is requested by caller. |
to | Converts a setting value and metadata to type T, throwing on error. |
toString | Returns the string representation of a set error code. |
tryTo | Conversion functions for converting a SettingValueAndMetadata to a setting type T. Implementation is similar to folly/Conv and allows for customization using the convertTo function above. |
| Name | Description |
|---|---|
kHelpFlag | Name of the command line flag that requests the help message. |
Implementation details for SharedMutex; not part of the public API.
| Name | Description |
|---|---|
NopOwnershipTracker | Ownership tracker that records nothing. |
PolicySuppressTSAN | Policy that suppresses ThreadSanitizer rwlock annotations. |
PolicyTracked | Policy that enables tracking the id of the thread holding the lock. |
ThreadIdOwnershipTracker | Ownership tracker that records the id of the owning thread. |
| Name | Description |
|---|---|
annotationGuard | Returns a guard that gives permission for the current thread to annotate, and adjust the annotation bits in, the SharedMutex at ptr. |
getCurrentThreadInvoluntaryContextSwitchCount | Returns the number of involuntary context switches for the current thread. |
getMaxDeferredReaders | Returns the current maximum number of deferred readers. |
getMaxDeferredReadersSlow | Computes and caches the current maximum number of deferred readers. |
throwDeadlockWouldOccur [noreturn] | Throws a system error indicating a deadlock would occur. |
throwOperationNotPermitted [noreturn] | Throws a system error indicating the operation is not permitted. |
| Name | Description |
|---|---|
kMaxDeferredReadersAllocated | Upper bound on the number of deferred reader slots that may be allocated. |
SIMD algorithms and utilities.
| Name | Description |
|---|---|
composite_finder_first_of | composite_finder |
ignore_extrema | ignore(_none/_extrema) |
ignore_none | Tag type indicating that the whole register is used. |
| Name | Description |
|---|---|
azmatch_vector_finder_first_not_of | The SIMD azmatch-based find-first-not-of finder specialized for char. |
azmatch_vector_finder_first_of | The SIMD azmatch-based find-first-of finder specialized for char. |
basic_azmatch_vector_finder_first_not_of | Alias for the SIMD azmatch-based find-first-not-of finder. |
basic_azmatch_vector_finder_first_of | Alias for the SIMD azmatch-based find-first-of finder. |
basic_default_scalar_finder_first_not_of | Alias for the default scalar find-first-not-of finder. |
basic_default_scalar_finder_first_of | Alias for the default scalar find-first-of finder. |
basic_default_vector_finder_first_not_of | Alias for the SIMD-accelerated default find-first-not-of finder. |
basic_default_vector_finder_first_of | Alias for the SIMD-accelerated default find-first-of finder. |
basic_ltindex_scalar_finder_first_not_of | Alias for the lookup-table-indexed scalar find-first-not-of finder. |
basic_ltindex_scalar_finder_first_of | Alias for the lookup-table-indexed scalar find-first-of finder. |
basic_ltsparse_scalar_finder_first_not_of | Alias for the sparse lookup-table scalar find-first-not-of finder. |
basic_ltsparse_scalar_finder_first_of | Alias for the sparse lookup-table scalar find-first-of finder. |
basic_rngfind_vector_finder_first_of | Find-first-of finder that wraps folly::Range::find_first_of. |
basic_shuffle_vector_finder_first_not_of | Alias for the SIMD shuffle-based find-first-not-of finder. |
basic_shuffle_vector_finder_first_of | Alias for the SIMD shuffle-based find-first-of finder. |
basic_stdfind_scalar_finder_first_of | Alias for the std::find_first_of based scalar find-first-of finder. |
default_scalar_finder_first_not_of | The default scalar find-first-not-of finder specialized for char. |
default_scalar_finder_first_of | The default scalar find-first-of finder specialized for char. |
default_vector_finder_first_not_of | The SIMD-accelerated default find-first-not-of finder specialized for char. |
default_vector_finder_first_of | The SIMD-accelerated default find-first-of finder specialized for char. |
ltindex_scalar_finder_first_not_of | The lookup-table-indexed scalar find-first-not-of finder specialized for char. |
ltindex_scalar_finder_first_of | The lookup-table-indexed scalar find-first-of finder specialized for char. |
ltsparse_scalar_finder_first_not_of | The sparse lookup-table scalar find-first-not-of finder specialized for char. |
ltsparse_scalar_finder_first_of | The sparse lookup-table scalar find-first-of finder specialized for char. |
rngfind_vector_finder_first_of | Range-based find-first-of finder specialized for char. |
shuffle_vector_finder_first_not_of | The SIMD shuffle-based find-first-not-of finder specialized for char. |
shuffle_vector_finder_first_of | The SIMD shuffle-based find-first-of finder specialized for char. |
stdfind_scalar_finder_first_of | The std::find_first_of based scalar find-first-of finder specialized for char. |
| Name | Description |
|---|---|
contains | Returns whether the range contains the given value. |
movemask | movemask overloads |
Policies that customize the behavior of folly::small_vector.
| Name | Description |
|---|---|
merge | Combines several small_vector policies into a single policy. |
policy_in_situ_only | Policy selecting whether a small_vector may only store elements in situ. |
policy_size_type | Policy selecting the size_type used by a small_vector. |
SSL and TLS helpers built on OpenSSL.
| Name | Description |
|---|---|
ssl_options_detail | Implementation details for the SSL options helpers. |
| Name | Description |
|---|---|
BasicTransportCertificate | In-memory transport certificate holding an identity and an optional X509. |
ClientHelloInfo | Parsed fields extracted from a TLS ClientHello message. |
DnsName | A DNS name subjectAltName entry. |
OpenSSLCertUtils | Utilities for inspecting and encoding X509 certificates. |
OpenSSLHash | OpenSSL-backed message digest and HMAC helpers. |
OpenSSLKeyUtils | Utilities for reading and encoding private keys with OpenSSL. |
OpenSSLUtils | Helpers wrapping low-level OpenSSL certificate, BIO, and session operations. |
PasswordCollector | Collects passwords used to decrypt private keys. |
SSLOptions2021 | SSLOptions2021 contains options that any new client or server from 2021 onwards should be using. |
SSLOptionsCompatibility | Recommended SSL options that stay compatible with older peers. |
SSLServerOptionsCompatibility | SSLServerOptionsCompatibility contains algorithms that are not recommended for modern servers, but are included to maintain comaptibility with very old clients. |
SSLSession | An abstraction for SSL sessions. |
SSLSessionManager | A class that manages one SSL session. |
UriName | A URI subjectAltName entry. |
| Name | Description |
|---|---|
BioDeleterFb | Deleter that frees a single BIO via BIO_free_fb. |
BioUniquePtrFb | Owning unique_ptr alias for a single BIO freed via BIO_free_fb. |
EvpPkeySharedPtr | Shared-ownership pointer to an EVP_PKEY object. |
GeneralName | A subjectAltName entry: a DNS name, a URI, or an IP address. |
SSLCommonOptions | Default option set for clients and general use. |
SSLServerOptions | Default option set for servers. |
X509VerifyParam | Owning unique_ptr alias for an X509_VERIFY_PARAM object. |
X509VerifyParamDeleter | Deleter that frees an X509_VERIFY_PARAM object. |
| Name | Description |
|---|---|
HashAlgorithm | TLS signature-scheme hash algorithm codes (IANA tls-parameters). |
NameType | TLS server-name entry type. |
SignatureAlgorithm | TLS signature-scheme signature algorithm codes (IANA tls-parameters). |
TLSExtension | TLS extension type codes, per the IANA tls-extensiontype-values registry. |
| Name | Description |
|---|---|
BIO_free_fb | Frees a single BIO, asserting that the underlying BIO_free succeeds. |
setCipherSuites | setCipherSuites overloads |
setGroups | Set the groups of ctx to that in TSSLOptions, and print any runtime error it catches. |
setSignatureAlgorithms | Set the signature algorithm list of ctx to that in TSSLOptions, and print any runtime errors it catche. |
operator<< | Writes a password collector's description to an output stream. |
Implementation details for the SSL options helpers.
| Name | Description |
|---|---|
logDfatal | Logs an exception at DFATAL severity. |
Implementation details for the stable radix sort.
| Name | Description |
|---|---|
DefaultProjection | Default projection that handles common types. |
TransformingProjection | Projection wrapper that applies type-appropriate transformation. |
| Name | Description |
|---|---|
extractRadixDigit | Extract the radix digit at the given pass index from a key. Pass 0 extracts the least significant digit. |
insertionSort | Stable insertion sort for small inputs. O(n^2) but fast for small n due to low overhead. |
stableRadixSort | Wrapper that handles buffer allocation and fallback to std::stable_sort. |
stableRadixSortImpl | Core LSD radix sort implementation with alternating buffers. |
| Name | Description |
|---|---|
kRadixBits | Number of bits processed per radix pass. |
kRadixBuckets | Number of counting-sort buckets per pass (2^kRadixBits). |
kRadixMask | Mask selecting the low kRadixBits of a digit. |
kRadixPasses | Number of radix passes needed to sort a key of the given type. |
kRadixSortThreshold | Size threshold below which we fall back to insertion sort. |
Stable LSD (Least Significant Digit) Radix Sort
| Name | Description |
|---|---|
FloatKey | FloatKey - Converts IEEE 754 floats/doubles to sortable unsigned integers. |
IdentityKey | IdentityKey - Returns the value unchanged (for unsigned integers). |
IntegralKey | IntegralKey - Handles signed/unsigned integers for radix sort. |
Stack trace capture and symbolization utilities.
| Name | Description |
|---|---|
AddressFormatter | Format one address in the way it's usually printed by SymbolizePrinter. Async-signal-safe. |
ElfFile | A memory-mapped ELF object file. |
FDSymbolizePrinter | Print a list of symbolized addresses to a file descriptor. Ignores errors. Async-signal-safe. |
FILESymbolizePrinter | Print a list of symbolized addresses to a FILE*. Ignores errors. Not reentrant. Do not use from signal handling code. |
FrameArray | A fixed-capacity array of captured addresses and their symbolized frames. |
LineReader | Async-signal-safe line reader. |
LocationInfo | Contains location info like file name, line number, etc. |
OStreamSymbolizePrinter | Print a list of symbolized addresses to a stream. Not reentrant. Do not use from signal handling code. |
Path | Represent a file path as a collection of three parts (base directory, subdirectory, and file). |
SafeStackTracePrinter | Use this class to print a stack trace from a signal handler, or other place where you shouldn't allocate memory on the heap, and fsync()ing your file descriptor is more important than performance. |
StringSymbolizePrinter | Print a list of symbolized addresses to a std::string. Not reentrant. Do not use from signal handling code. |
SymbolCacheBase | A cache of symbolized frames, keyed by instruction address. |
SymbolizePrinter | Print a list of symbolized addresses. Base class. |
SymbolizedFrame | Frame information: symbol name and location. |
| Name | Description |
|---|---|
CachedSymbolizedFrames | Symbolized frames for a single address: the stacked inline calls, if any, followed by the non-inlined call. Most addresses have no inlined frames, so optimize for the single-entry case. |
SignalCallback | Add a callback to be run when receiving a fatal signal. They will also be called by LOG(FATAL) and abort() (as those raise SIGABRT internally). |
| Name | Description |
|---|---|
LocationInfoMode | How aggressively to resolve source location information. |
| Name | Description |
|---|---|
addFatalSignalCallback | Register a callback to be run when a fatal signal is received. |
fatalSignalReceived | True if a fatal signal was received (i.e. the process is crashing). |
getAsyncStackTraceSafe | getAsyncStackTraceSafe overloads |
getAsyncStackTraceStr | Async stack trace as a string; empty when symbolization is unavailable. |
getSharedSymbolCache | The process-wide cache for mode. |
getStackTrace | getStackTrace overloads |
getStackTraceHeap | getStackTraceHeap overloads |
getStackTraceSafe | getStackTraceSafe overloads |
getStackTraceStr | getStackTraceStr overloads |
getSuspendedStackTraces | Async stack traces for suspended coroutines; empty when unavailable. |
installFatalSignalCallbacks | Install the fatal signal callbacks; fatal signals will call these callbacks in the order in which they were added. |
installFatalSignalHandler | Install handler for fatal signals. The list of signals being handled is in SignalHandler.cpp. |
makeGenerationalSymbolCache | A cache of roughly capacity entries, backed by a folly::GenerationalCacheMap: lookups are lock-free, and an address that stops appearing in stack traces is eventually evicted in favour of one that does. |
makeLruSymbolCache | An LRU cache of capacity entries, backed by a Synchronized EvictingCacheMap. |
makeNullSymbolCache | A cache that stores nothing. |
operator<< | Write a Path to an output stream. |
| Name | Description |
|---|---|
kAllFatalSignals | Bitmask of all fatal signals handled by the symbolizer signal handler. |
Testing utilities.
| Name | Description |
|---|---|
CaptureFD | Temporarily capture a file descriptor by redirecting it into a file. You can consume its entire output thus far via read(), incrementally via readIncremental(), or via callback using chunk_cob. Great for testing logging (see also glog*Pattern()). |
ChangeToTempDir | Changes into a temporary directory, and deletes it with all its contents upon destruction, also changing back to the original working directory. |
EnvVarSaver | RAII class allowing scoped changes to the process environment. The environment state at the time of its construction is restored at the time of its destruction. |
TemporaryDirectory | Temporary directory. |
TemporaryFile | Temporary file. |
| Name | Description |
|---|---|
find_resource | Finds the file path of a resource which was built alongside a test binary. |
glogErrOrWarnPattern | PCRE pattern matching a glog error-level or warning-level log line. |
glogErrorPattern | Use these patterns together with CaptureFD and EXPECT_PCRE_MATCH() to test for the presence (or absence) of log lines at a particular level: |
glogWarningPattern | PCRE pattern matching a glog warning-level log line. |
msvcSuppressAbortOnInvalidParams | Invokes a function while suppressing the Windows CRT abort on invalid parameters. |
Implementation details.
| Name | Description |
|---|---|
ElementWrapper | POD wrapper around an element (a void*) and an associated deleter. This must be POD, as we memset() it to 0 and memcpy() it around. |
FakeUniqueInstance | No-op stand-in for UniqueInstance used when the tag is void. |
SharedPtrDeleter | Deleter that owns a shared_ptr and disposes it on thread-local destruction. |
StaticMeta | Held in a singleton to track our global instances. We have one of these per "Tag", by default one for the whole system (Tag=void). |
StaticMetaBase | Non-templated base holding the shared thread-local bookkeeping state. |
ThreadEntry | Per-thread entry. Each thread using a StaticMeta object has one. This is written from the owning thread only (under the lock), read from the owning thread (no lock necessary), and read from other threads (under the lock). |
ThreadEntryList | Intrusive list of ThreadEntry objects for a single thread. |
ThreadEntrySet | ThreadEntrySet is used to track all ThreadEntry that have a valid ElementWrapper for a particular TL id. The class provides no internal locking and caller must ensure safety of any access. |
| Name | Description |
|---|---|
ElementDisposeInfo | Cache the ptr + deleter info in ThreadEntrySet too. This allows accessAllThreads() to get to the per thread ptr without holding the StaticMeta's lock_. Eventually, the deleter info will be moved to the ThreadEntrySet alone, leaving only the ptr in the ElementWrapper. For now, the ElementDisposeInfo tracked in ThreadEntrySet is the same as ElementWrapper. |
| Name | Description |
|---|---|
kEntryIDInvalid | Sentinel entry id representing an unallocated thread-local slot. |
There is a bug in libstdc++, libc++, and MSVC's STL that causes it to ignore unused template parameter arguments in template aliases and does not cause substitution failures. This defect has been recorded here: http://open-std.org/JTC1/SC22/WG21/docs/cwg_defects.html#1558.
| Name | Description |
|---|---|
type_pack_element_indexed_type | A helper pairing an index with the type at that position. |
type_pack_element_set | A helper collecting a type pack as a set of indexed types. |
type_pack_element_test | A helper that recovers the type stored at a given index. |
type_t_ | A helper that exposes its first type argument, ignoring the rest. |
uint_bits_t_ | A helper mapping a bit width to the unsigned integer type of that width. |
value_list_traits_ | A helper exposing the size and elements of a value list. |
value_pack_constant | A helper wrapping a single value as a type carrying that value. |
| Name | Description |
|---|---|
type_pack_element_fallback | A fallback implementation of type_pack_element_t without the builtin. |
type_pack_element_set_t | An alias building the indexed-type set for the pack T. |
| Name | Description |
|---|---|
type_list_element_ | Deduces the type identity of the Ith element of a type list. |
type_list_size_ | Deduces the size of a type list. |
Implementation namespace for the IsEqualityComparable trait.
| Name | Description |
|---|---|
IsEqualityComparable | A trait to test whether values of T and U can be compared with operator==. |
| Name | Description |
|---|---|
operator== | A fallback operator used to detect the absence of a real operator==. |
Implementation namespace for the IsLessThanComparable trait.
| Name | Description |
|---|---|
IsLessThanComparable | A trait to test whether values of T and U can be compared with operator<. |
| Name | Description |
|---|---|
operator< | A fallback operator used to detect the absence of a real operator<. |
The range-v3 library namespace.
| Name | Description |
|---|---|
enable_view | Trait template that marks a type as a range-v3 view. |
enable_view | Marks folly::Range as satisfying the range-v3 view concept. |
Standard library specializations of std::hash for Folly and standard types.
| Name | Description |
|---|---|
pmr | Standard library namespace. |
| Name | Description |
|---|---|
coroutine_traits<folly::coro::safe_task<ArgSafety, T>, Args...> | Coroutine traits selecting the promise type for a safe_task coroutine. |
equal_to<folly::propagate_const<Pointer>> | std::equal_to specialization for folly::propagate_const. |
greater<folly::propagate_const<Pointer>> | std::greater specialization for folly::propagate_const. |
greater_equal<folly::propagate_const<Pointer>> | std::greater_equal specialization for folly::propagate_const. |
hash<folly::IPAddress> | Hash support for folly::IPAddress. |
hash<folly::IPAddressV4> | Hash support for folly::IPAddressV4. |
hash<folly::IPAddressV6> | Hash specialization enabling IPAddressV6 as a key in unordered containers. |
hash<folly::MacAddress> | Specialization of std::hash for folly::MacAddress. |
hash<folly::NetworkSocket> | Hash specialization for folly::NetworkSocket. |
hash<folly::RegexMatchCacheKey> | std::hash specialization for folly::RegexMatchCacheKey. |
hash<folly::RequestToken> | Hash specialization for folly::RequestToken. |
hash<folly::SocketAddress> | Specialization of std::hash for folly::SocketAddress. |
hash<folly::AsyncSocket::WriteRequestTag> | Hash specialization for AsyncSocket::WriteRequestTag. |
hash<folly::dynamic> | Standard library hash specialization for folly::dynamic. |
hash<T> | Hash support so strong types can be keys in unordered containers. |
hash<folly::enable_std_hash_helper<folly::Optional<T>, remove_const_t<T>>> | Hash specialization enabling folly::Optional in unordered containers. |
hash<folly::propagate_const<Pointer>> | std::hash specialization for folly::propagate_const. |
hash<std::tuple<Ts...>> | std::hash specialization for std::tuple. |
hash<folly::unique_hash_key<Size>> | std::hash specialization for folly::unique_hash_key. |
hash<folly::unique_hash_key_with<Algo>> | std::hash specialization for folly::unique_hash_key_with. |
hash<folly::basic_cstring_view<Char, Traits>> | Hash specialization for basic_cstring_view, matching string_view hashing. |
hash<folly::indirect<T, Alloc>> | Hash specialization for folly::indirect. |
hash<folly::not_null<PtrT, NullHandlerT>> | Hashing: - Forwards to underlying PtrT. |
hash<std::pair<T1, T2>> | std::hash specialization for std::pair. |
hash<folly::small_vector<T, M, P>> | Hash specialization for folly::small_vector. |
is_error_code_enum | Marks folly::cli_apply_args_files_errc as an error-code enum. |
less<folly::propagate_const<Pointer>> | std::less specialization for folly::propagate_const. |
less_equal<folly::propagate_const<Pointer>> | std::less_equal specialization for folly::propagate_const. |
not_equal_to<folly::propagate_const<Pointer>> | std::not_equal_to specialization for folly::propagate_const. |
shared_lock<folly::SharedMutexImpl<ReaderPriority, Tag_, Atom, Policy>> | std::shared_lock specialization for folly::SharedMutexImpl. |
tuple_element<I, /* implementation-defined */> | Type of the I-th element of a lite_tuple. |
tuple_size | Number of elements in a lite_tuple. |
Standard library namespace.
| Name | Description |
|---|---|
memory_resource | Abstract interface for polymorphic memory resources. |