summaryrefslogtreecommitdiff
path: root/absl/base/internal/spinlock.h
Commit message (Collapse)AuthorAge
* Export of internal Abseil changesGravatar Abseil Team2021-01-19
| | | | | | | | | | | -- 874f906d2b90d4c74b0edeac52811efc10323422 by Todd Lipcon <tlipcon@google.com>: Internal change PiperOrigin-RevId: 352140672 GitOrigin-RevId: 874f906d2b90d4c74b0edeac52811efc10323422 Change-Id: I151299caff75d404309f059dd0e5971f5a71655d
* Export of internal Abseil changesGravatar Abseil Team2020-12-01
| | | | | | | | | | | | | | | | | | | | | -- 7b6a68aa92dcc7247236d1a1813914e035383bf8 by Abseil Team <absl-team@google.com>: Use atomic exchange to mark completion in absl::once_flag This prevents a potential for a missed wakeup if one thread marks itself as a waiter while another thread is completing the invocation. PiperOrigin-RevId: 344946791 -- ddff21d1dde08d1368d8be5fca81b154e78be2fc by Abseil Team <absl-team@google.com>: Add missing string_view include. This is currently used transitively through the cord header. PiperOrigin-RevId: 344845266 GitOrigin-RevId: 7b6a68aa92dcc7247236d1a1813914e035383bf8 Change-Id: Ia24e98a1df832fc4cb491d888fdf21182b5954f4
* Export of internal Abseil changesGravatar Abseil Team2020-06-30
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | -- 739f9fb80212c21c015fec473e9e29803a156ef9 by Derek Mauro <dmauro@google.com>: Define FlagStateInterface::~FlagStateInterface() in the translation unit in which it is actually declared Fixes #717 PiperOrigin-RevId: 319083605 -- 913ef1f23113268b22d636d3ae3b992862efdb1a by Derek Mauro <dmauro@google.com>: Fix ABSL_LOCK_RETURNED statement PiperOrigin-RevId: 319078667 -- a43b1413da1770d638147c73e7e1693cfaf869c7 by Derek Mauro <dmauro@google.com>: Fix redeclaration ‘absl::Cord::InlineRep::kMaxInline’, which differs in ‘constexpr’ Fixes #725 PiperOrigin-RevId: 319060910 -- 1ad7d491a80f6c9de78a6fc20f09b7765d224503 by Abseil Team <absl-team@google.com>: Make absl SpinLock trivially destructible when possible PiperOrigin-RevId: 319049456 -- 659ecad3578dfa669854a82279fa590002bdb37f by Derek Mauro <dmauro@google.com>: Remove the static initialization of global variables used by absl::Mutex as requested by Chromium PiperOrigin-RevId: 319031204 -- 609c491d8bb4f8bb3b44c5a4c0bee51c583df24c by Abseil Team <absl-team@google.com>: Add implementation of %a and %A to absl::StrFormat. Prior to this it just fell back to sprintf. PiperOrigin-RevId: 318888039 -- 5e8ae6392bcd135248aac14c4b9f2a5116868678 by Abseil Team <absl-team@google.com>: Google-internal changes only. PiperOrigin-RevId: 318857077 -- 4a2578e33e8442954e29e5f0380ddfcf0f033f0d by Greg Falcon <gfalcon@google.com>: Change of enum constants to accommodate internal change. PiperOrigin-RevId: 318844716 -- 4b578b102816260c213675759f4c15911735578a by Abseil Team <absl-team@google.com>: Internal change PiperOrigin-RevId: 318704453 -- 0ee82fd24d548b260c9229fa1f54571dae1dfa24 by Gennadiy Rozental <rogeeff@google.com>: Allow lookup of retired flags. At the moment we issue warning on attempt to find a retired flag. This way we can't even check if flag is retired without issuing the warning. With this change we will only issue the warning if one tries to access any functionality of retired flag but it's name "is retired" status, and type. PiperOrigin-RevId: 318605017 -- 3e35fe9b4c79f636fa328c59e2aabb93e29b7c99 by Abseil Team <absl-team@google.com>: Fix error return from InstallSymbolDecorator(). PiperOrigin-RevId: 318490405 -- ae46063f3eb2998cb961f62a359d932e5908a4bc by Abseil Team <absl-team@google.com>: Do not make copies of iterated collection elements into the loop variable. PiperOrigin-RevId: 318423139 -- d06a075a12aab5f6ab98474677ce50d588b21de3 by Abseil Team <absl-team@google.com>: add missing word making the error code better English PiperOrigin-RevId: 318335052 GitOrigin-RevId: 739f9fb80212c21c015fec473e9e29803a156ef9 Change-Id: Id77a0a4b1959036b00555deef40e82d51884fbc1
* Export of internal Abseil changesGravatar Abseil Team2020-05-14
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | -- b8e6b64b604449bb51ed0ba8e9439097f3aa8773 by Abseil Team <absl-team@google.com>: fix typo 'implentation' -> 'implementation' PiperOrigin-RevId: 311623471 -- 2b9262a311f3329c8006835a79498edd90568acd by Matt Kulukundis <kfm@google.com>: Internal cleanup PiperOrigin-RevId: 311549039 -- 7507ed3c28113e28f993aa634bd44a9a0d4c4a2c by Derek Mauro <dmauro@google.com>: Delete LinkerInitialized Now that all SpinLocks have the same scheduling mode for their entire lives, the scheduling mode does not need to be re-tested in the loop in LockSlow. PiperOrigin-RevId: 311521474 -- abf5fae67e21b38cda4083aaafd7012e2c6fbb7d by Andy Getzendanner <durandal@google.com>: Fix public target name of the random library Import of https://github.com/abseil/abseil-cpp/pull/684 PiperOrigin-RevId: 311429555 GitOrigin-RevId: b8e6b64b604449bb51ed0ba8e9439097f3aa8773 Change-Id: Ic48f671846bda059cc46f4a0b967cc3b1a733ba0
* Export of internal Abseil changesGravatar Abseil Team2020-04-30
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | -- 53550735f5a943dfb99225e7c53f211c2d6e7951 by Gennadiy Rozental <rogeeff@google.com>: Import of CCTZ from GitHub. PiperOrigin-RevId: 309333648 -- 847bbf8a1d9cd322ec058c6f932d1f687fd3d331 by Gennadiy Rozental <rogeeff@google.com>: Make Validation interfaces private in CommandLineFlag. Calls are rewired via private interface access struct. PiperOrigin-RevId: 309323013 -- a600fc5051e0a0af50a7850450fd3ed1aef3f316 by Matthew Brown <matthewbr@google.com>: Internal Change. PiperOrigin-RevId: 309292207 -- 937d00ce3cf62c5f23f59b5377471fd01d6bfbc7 by Gennadiy Rozental <rogeeff@google.com>: Make TypeId interface private in CommandLineFlag. We also rewire the SaveState via the new PrivateHandleInterface trampoline class. This class will be the only way to access private methods of class CommandLineFlag. PiperOrigin-RevId: 309282547 -- 796c4bd35073b6a8337762bdb13603dae12a4df1 by Derek Mauro <dmauro@google.com>: Cleanup uses of kLinkerInitialized PiperOrigin-RevId: 309274734 -- c831446c52d9ef4bdcb1ea369840904620abc4b9 by Gennadiy Rozental <rogeeff@google.com>: Eliminate the interface IsModified of CommndLineFlag. PiperOrigin-RevId: 309256248 -- a1db59d7f7aa39cb0a37dbf80f8c04e371da8465 by Gennadiy Rozental <rogeeff@google.com>: Avoid default value generator if default value expression is constexpr. If possible, we detect constexpr-ness of default value expression and avoid storing default value generator in side of flag and instead set the flag's value to the value of that expression at const initialization time of flag objects. At the moment we only do this for flags of (all) integral, float and double value types PiperOrigin-RevId: 309110630 -- ae3b4a139aacd8fc165c9acd2a3cbae1f9e26af4 by Gennadiy Rozental <rogeeff@google.com>: Make SaveState a private method of the CommandLineFlag and make it only accessible from FlagSaverImpl. There is no other call sites for this call. PiperOrigin-RevId: 309073989 -- cbc24b4dcc166dd6b0208e9d7620484eaaaa7ee0 by Abseil Team <absl-team@google.com>: Eliminate the interface IsModified of CommndLineFlag. PiperOrigin-RevId: 309064639 -- 08e79645a89d71785c5381cea9c413357db9824a by Gennadiy Rozental <rogeeff@google.com>: Eliminate the interface IsModified of CommndLineFlag. PiperOrigin-RevId: 309054430 -- 4a6c70233c60dc8c39b7fa9beb5fa687c215261f by Gennadiy Rozental <rogeeff@google.com>: Internal change PiperOrigin-RevId: 308900784 -- 13160efdf7710f142778d5a1e4c85aa309f019b6 by Abseil Team <absl-team@google.com>: Provide definitions of static member variables -- improved C++11 support. PiperOrigin-RevId: 308900290 -- 0343b8228657b9b313afdfe88c4a7b2137d56db4 by Gennadiy Rozental <rogeeff@google.com>: Rename method Get<T> to TryGet<T> per approved spec before making interface public. PiperOrigin-RevId: 308889113 -- 7b84e27fb857fc1296a05504970f506d47d2f2c1 by Derek Mauro <dmauro@google.com>: Remove node_hash_* methods that were deprecated on release PiperOrigin-RevId: 308837933 -- 599d44ee72c02b6bb6e1c1a1db72873841441416 by Gennadiy Rozental <rogeeff@google.com>: Eliminate CommandLineFlag::Typename interface per approved spec before making CommandLineFlag public. PiperOrigin-RevId: 308814376 GitOrigin-RevId: 53550735f5a943dfb99225e7c53f211c2d6e7951 Change-Id: Iae52c65b7322152c7e58f222d60eb5a21699a2cb
* Export of internal Abseil changesGravatar Abseil Team2020-03-23
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | -- 79913a12f0cad4baf948430315aabf53f03b6475 by Abseil Team <absl-team@google.com>: Don't inline (Un)LockSlow. PiperOrigin-RevId: 302502344 -- 6b340e80f0690655f24799c8de6707b3a95b8579 by Derek Mauro <dmauro@google.com>: Add hardening assertions to absl::optional's dereference operators PiperOrigin-RevId: 302492862 -- a9951bf4852d8c1aec472cb4b539830411270e4c by Derek Mauro <dmauro@google.com>: Correctly add hardware AES compiler flags under Linux X86-64 Fixes #643 PiperOrigin-RevId: 302490673 -- 314c3621ee4d57b6bc8d64338a1f1d48a69741d1 by Derek Mauro <dmauro@google.com>: Upgrade to hardening assertions in absl::Span::remove_prefix and absl::Span::remove_suffix PiperOrigin-RevId: 302481191 -- a142b8c6c62705c5f0d4fe3113150f0c0b7822b9 by Derek Mauro <dmauro@google.com>: Update docker containers to Bazel 2.2.0, GCC 9.3, and new Clang snapshot PiperOrigin-RevId: 302454042 -- afedeb70a2adc87010030c9ba6f06fe35ec26407 by Derek Mauro <dmauro@google.com>: Add hardening assertions for the preconditions of absl::FixedArray PiperOrigin-RevId: 302441767 -- 44442bfbc0a9a742df32f07cee86a47712efb8b4 by Derek Mauro <dmauro@google.com>: Fix new Clang warning about SpinLock doing operations on enums of different types PiperOrigin-RevId: 302430387 -- 69eaff7f97231779f696321c2ba8b88debf6dd9e by Derek Mauro <dmauro@google.com>: Convert precondition assertions to ABSL_HARDENING_ASSERT for absl::InlinedVector PiperOrigin-RevId: 302427894 -- 26b6db906a0942fd18583dc2cdd1bab32919d964 by Gennadiy Rozental <rogeeff@google.com>: Internal change PiperOrigin-RevId: 302425283 -- e62e81422979e922505d2cd9000e1de58123c088 by Derek Mauro <dmauro@google.com>: Add an option to build Abseil in hardened mode In hardened mode, the ABSL_HARDENING_ASSERT() macro is active even when NDEBUG is defined. This allows Abseil to perform runtime checks even in release mode. This should be used to implement things like bounds checks that could otherwise lead to security vulnerabilities. Use the new assertion in absl::string_view and absl::Span to test it. PiperOrigin-RevId: 302119187 GitOrigin-RevId: 79913a12f0cad4baf948430315aabf53f03b6475 Change-Id: I0cc3341fd333a1df313167bab72dc5a759c4a048
* Export of internal Abseil changesGravatar Abseil Team2019-12-10
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | -- b842b7fd9b1289be31f0b7ee8e62e48e550747cf by Greg Falcon <gfalcon@google.com>: Change the Cord str_format formatter to use iteration instead of CordReader. When Cord is publicly released, CordReader is not going with it. PiperOrigin-RevId: 284780736 -- 28e76c08ea7185a7ff9f4e0e02ae565fbbf7980f by Greg Falcon <gfalcon@google.com>: Implementation detail change. Introduce ABSL_NAMESPACE_BEGIN and _END annotation macros which indicate the beginning and end of a `namespace absl` scope. Currently these do nothing, but they will be used to inject an inline namespace for LTS builds (to avoid symbol collisions against other Abseil versions). These macros should not be used by end users, because end users should never write `namespace absl {` in their own code. This CL applies these annotations to all code under //absl/base/. The rest of Abseil will be annotated in this way in follow-up CLs. PiperOrigin-RevId: 284776410 -- e1711dc6d696dcca50d4e7d4b4d8f3076575b7ec by Abseil Team <absl-team@google.com>: --help changed to report long flags. PiperOrigin-RevId: 284757720 -- 78f66a68f428bbbd19d8d60e1125f43ba765fd35 by Tom Manshreck <shreck@google.com>: Update comment on + or - in SimpleAToi() PiperOrigin-RevId: 284231843 GitOrigin-RevId: b842b7fd9b1289be31f0b7ee8e62e48e550747cf Change-Id: I3046b31391bd11c8bc4abab7785a863c377cd757
* Export of internal Abseil changesGravatar Abseil Team2019-09-05
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | -- 972333fe1e43427849b8a634aa35061e81be3642 by Abseil Team <absl-team@google.com>: Replace deprecated thread annotations macros. PiperOrigin-RevId: 267332619 -- 7039c6dc499a31c372b4872eda0772455931c360 by Gennadiy Rozental <rogeeff@google.com>: Internal change PiperOrigin-RevId: 267220271 -- a3f524d2afc2535686f206a7ce06961016349d7a by Abseil Team <absl-team@google.com>: Factor kernel_timeout out of synchronization. PiperOrigin-RevId: 267217304 -- 90287de4114ef9a06cafe50256a2d03349772c21 by Abseil Team <absl-team@google.com>: Fixed comment typo. PiperOrigin-RevId: 267198532 -- d312c1a1e52aeca1871ff0deead416d09a7f237e by Gennadiy Rozental <rogeeff@google.com>: Internal change PiperOrigin-RevId: 267185804 GitOrigin-RevId: 972333fe1e43427849b8a634aa35061e81be3642 Change-Id: Ia8a2f877c57cef9854aad48f1753af872fc04dc8
* Export of internal Abseil changesGravatar Abseil Team2019-08-23
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | -- d6748c733a70cd74ad9b76a0c9cd6b3fe2cecacf by Xiaoyi Zhang <zhangxy@google.com>: Remove empty block, to address alerts reported in https://github.com/abseil/abseil-cpp/issues/368. PiperOrigin-RevId: 265099887 -- 232e2036b5668d6d1296b881f9347756d84541ee by Derek Mauro <dmauro@google.com>: Make the Linux Bazel CI scripts test with the exception mode explicitly set. PiperOrigin-RevId: 265092105 -- 942a40696c2c9b833be03e92d22a6ede7bccb6d4 by Xiaoyi Zhang <zhangxy@google.com>: Import https://github.com/abseil/abseil-cpp/pull/372. Suppress the unused variable warning on GCC, i.e. "-Wunused-variable". PiperOrigin-RevId: 265063925 -- 7ef90796b52cbdc260afc77cf47206f9356471d0 by Xiaoyi Zhang <zhangxy@google.com>: Add quotes to `ABSL_COMMON_INCLUDE_DIRS` since it's a list and may contain a `;`. This addresses https://github.com/abseil/abseil-cpp/issues/373. PiperOrigin-RevId: 265059077 -- 43f3ae742e00b83672ad6c5bc5b17fdb8f9fe6fe by Gennadiy Rozental <rogeeff@google.com>: Internal re-organization PiperOrigin-RevId: 264913945 -- 6a2adf9c08ee1d98cc6b2855a676345c6495294a by Andy Soffer <asoffer@google.com>: Publicly expose type names for uniform interval tags as in, for example, absl::IntervalClosedClosedTag, and add equality comparison operators. PiperOrigin-RevId: 264861162 -- 3c90c6e05fd61d56b419cd2d39dab8f17b8711b8 by Abseil Team <absl-team@google.com>: Add validity check on returned frame pointer. PiperOrigin-RevId: 264858823 -- 2db87e0cfa0c6bea7ba81684b834cb8a73b7d748 by Gennadiy Rozental <rogeeff@google.com>: Add MUST_USE_RESULT attribute to absl::GetFlag to prevent accidental misuse. PiperOrigin-RevId: 264782762 GitOrigin-RevId: d6748c733a70cd74ad9b76a0c9cd6b3fe2cecacf Change-Id: I169e9c5358e4f63000c1255e806d26b8afecf5ff
* Export of internal Abseil changes.Gravatar Abseil Team2019-05-17
| | | | | | | | | | | | | | | | | | | | -- cae9f0c87632d690ec3f471e181be247fe4fb025 by Abseil Team <absl-team@google.com>: Run IWYU on some headers. PiperOrigin-RevId: 248749194 -- f57dcac97cacbe31769a8646020a99b6686987dc by Samuel Benzaquen <sbenza@google.com>: Accept vector<bool>::reference in StrFormat and friends. The proxy types might overload `operator&`. Use std::addressof instead. PiperOrigin-RevId: 248619661 GitOrigin-RevId: cae9f0c87632d690ec3f471e181be247fe4fb025 Change-Id: Iacf5d46a59d1d5f1fa1fd4a1e0d0de8c6cbedb3e
* Export of internal Abseil changes.Gravatar Abseil Team2019-05-16
| | | | | | | | | | | | | | | | | | | | -- 6fca451d74e509671f0996e15ea05008f73c9957 by Eric Fiselier <ericwf@google.com>: Support vector<bool>::reference and ::const_reference in absl::Substitute. PiperOrigin-RevId: 248524270 -- a4b298c74acb8ae0688ed681052593623d8021c7 by Abseil Team <absl-team@google.com>: Clarify that a static `SpinLock` using the `LinkerInitialized` constructor is initialized in non-cooperative mode. PiperOrigin-RevId: 248386381 GitOrigin-RevId: 6fca451d74e509671f0996e15ea05008f73c9957 Change-Id: I13d54c2034695e7677170cdc7b86384b7d7d9cb5
* Changed HTTP URLs to HTTPS where possible (#270)Gravatar nik72732019-03-08
|
* Export of internal Abseil changes.Gravatar Abseil Team2018-12-04
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | -- cd076f55c1fa600131f6dda392533dfe61679fc0 by Abseil Team <absl-team@google.com>: Internal change PiperOrigin-RevId: 224008762 -- e05f62b01286d51044ff86ec6ef565749b9faf82 by Abseil Team <absl-team@google.com>: Create a pow10() test helper function to compute guaranteed-precise double values of 10^x. Not all standard libraries ship bit-accurate pow() functions, causing tests to fail that rely on expected values generated by it. PiperOrigin-RevId: 223883762 -- fd88e5e3f7ab80f7f5df9fd1488cd58b4573be69 by Abseil Team <absl-team@google.com>: Remove some absl:: qualifications to work around inline namespace bugs on MSVC 2015. PiperOrigin-RevId: 223869642 -- 6276cfff969d596edd36a2bbaba65ee045808903 by Abseil Team <absl-team@google.com>: Update absl/memory/CMakeLists.txt to use new functions i.e. absl_cc_(library|test) PiperOrigin-RevId: 223854224 -- 359de9afc7a34c975fd3e0cbc52afd96637d97bd by Chris Kennelly <ckennelly@google.com>: Mark spinlock_benchmark_common as alwayslink = 1. PiperOrigin-RevId: 223844536 -- 450cd8cbe2789a6d54ed1eb87170259bb334f8b9 by Abseil Team <absl-team@google.com>: Support .* (pointer-to-member dereference) expressions in demangle.cc. PiperOrigin-RevId: 223826797 -- 772ca92179c3634f3e31a80bbc272ed8022e3572 by Abseil Team <absl-team@google.com>: Fix misspellings in absl::variant comments and replace a ' with a `. PiperOrigin-RevId: 223807911 -- 35dcdc2fbf299d195658aac101887f6dcad1de2f by Abseil Team <absl-team@google.com>: Bug fix in CMakeLists.txt file (SRCS --> HDRS). The compressed_tuple header-only library is being defined with the SRCS parameter instead of the HDRS parameter and this has been observed to cause some builds on some platforms to attempt to create a static library from it which fails since there are no .cc sources. PiperOrigin-RevId: 223805367 -- 4a57a3d2045bb137c0c97958e45ce425190b8d3e by Chris Kennelly <ckennelly@google.com>: Add test that absl::make_unique value initializes memory. PiperOrigin-RevId: 223801819 -- dfe8289d7f4dcc6bb568a26aaf192a89e896bdfd by Chris Kennelly <ckennelly@google.com>: SpinLock: Use exchange to avoid missing wakeups. The default fast path for SpinLock::Unlock does not use an atomic. If the SpinLock becomes contended while we are unlocking between lockword_.load and lockword_.store, we will fail to wake up the new waiter. This can cause unexpected latency spikes. PiperOrigin-RevId: 223800369 -- 9b9d35df786482f0016f77dd31691eff81503d23 by Abseil Team <absl-team@google.com>: Update absl/hash/CMakeLists.txt to use new functions i.e. absl_cc_(library|test) PiperOrigin-RevId: 223755819 -- c2014e2704b87e7cdce2d2a0287c7e2397752296 by Abseil Team <absl-team@google.com>: Update absl/debugging/CMakeLists.txt to use new functions i.e. absl_cc_(library|test) PiperOrigin-RevId: 223751986 -- d83a4e09126400e3fd80645cb03ee558f532271e by Derek Mauro <dmauro@google.com>: Cleanup synchronization benchmarks. PiperOrigin-RevId: 223589416 -- fad140b473586531b5b12843f942ec27dfcf5e93 by CJ Johnson <johnsoncj@google.com>: Makes unifies the order of forward_iterator and input_iterator overloads PiperOrigin-RevId: 223580660 -- 6cd7c96faa7cc5f79f574e35a1b13837ef187d05 by Abseil Team <absl-team@google.com>: Internal Change. PiperOrigin-RevId: 223561629 -- bd2e545356b0f548af0e3c14bb2f7f0e712e49d0 by Shaindel Schwartz <shaindel@google.com>: Remove misleading comments. try_emplace() does not exist for the hash_set containers. PiperOrigin-RevId: 223543089 -- 0cd380a53b587eb7aacc4003a4a3bbb6c78d7c10 by Derek Mauro <dmauro@google.com>: Internal change PiperOrigin-RevId: 223512551 -- 7156dfee599cb72e9adddfe0e6ae07a95ddf10bb by Greg Miller <jgm@google.com>: Fixes UB that would result from constructing, multiplying, or dividing a Duration with a double "NaN" value. This CL changes the absl::Duration *implementation* to return an InfiniteDuration value that has the same sign as the given NaN. PiperOrigin-RevId: 223407499 -- 196b7d18609958267951882baf7f9429e49bcafa by CJ Johnson <johnsoncj@google.com>: Addresses NVCC+MSVC compilation bug where `inlined_capacity()` was not considered valid in constexpr PiperOrigin-RevId: 223397718 GitOrigin-RevId: cd076f55c1fa600131f6dda392533dfe61679fc0 Change-Id: I5423ca6470f661a7c6f73aa8fee49990446f157f
* Export of internal Abseil changes.Gravatar Abseil Team2018-11-07
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | -- 178e7a9a76fc8fcd6df6335b59139cbe644a16b9 by Jon Cohen <cohenjon@google.com>: Import of CCTZ from GitHub. PiperOrigin-RevId: 220523164 -- 59ef14fe7034a3148f1e9cef1f128b8ca264b444 by Jon Cohen <cohenjon@google.com>: Don't assume how much std::vector's constructors allocate in InlinedVector's test for scoped_allocator_adaptor support. PiperOrigin-RevId: 220464683 -- 6f8351be43a44a8f10bf20612b2cc744a4a911c7 by Jon Cohen <cohenjon@google.com>: Add VS Code and some Bazel output files to absl/.gitignore PiperOrigin-RevId: 220464362 -- 43fac22f8af6b6ed55309a784a9d25d837393d0e by Abseil Team <absl-team@google.com>: absl: fix SpinLock::EncodeWaitCycles If a thread has ever observed or set kSpinLockSleeper, it must never leave 0 in kWaitTimeMask because at this point it is expected to wake subsequent threads. Current calculations in EncodeWaitCycles can result in 0 in kWaitTimeMask and lead to missed wakeups. This is mostly theoretical today, because the futex call needs to finish within 128 cycles (futex can return immediately without waiting, but 128 cycles still look too low for this). But this can well fire in future if we bump granularity and/or threshold for recording contention. Use kSpinLockSleeper instead of 0. PiperOrigin-RevId: 220463123 -- def9b7e3d45c99d68cc52a4429256116d7f421f2 by Abseil Team <absl-team@google.com>: absl: optimize SpinLock::SlowLock Currently we record contention even after the first initial spin. This leads to several performance issues: 1. If we succeed in acquiring the lock after the initial spin, overall wait time can be within tens/hundreds of nanoseconds. Recording such low wait time looks completely unnecessary and excessive. From some point of view this is not even a wait, because we did not sleep. And, for example, Mutex does not record contention in this case. In majority of cases the lock should be acquired exactly during the initial spin, yet we still go through full overhead of submitting contention. 2. Whenever a thread submits contention it also calls FUTEX_WAKE (there is no way to understand if it's necessary or not when wait value is stored in the lock). So if there are just 2 threads and a brief contention, the second thread will still call FUTEX_WAKE which is completely unnecessary overhead. Don't record contention after the initial spin wait. FWIW this also removes 2 CycleClock::Now calls and EncodeWaitCycles from the common hot path. PiperOrigin-RevId: 220379972 -- 75b0c0cb214de904ea622f81ec3f4eabdc8695b0 by Derek Mauro <dmauro@google.com>: Supress MSVC warnings in raw_hash_set's use of TrailingZeros and LeadingZeros. https://github.com/abseil/abseil-cpp/issues/208 PiperOrigin-RevId: 220372204 GitOrigin-RevId: 178e7a9a76fc8fcd6df6335b59139cbe644a16b9 Change-Id: I3a66af4e050810a3274e45d4e055b2aa19ffba1b
* Changes imported from Abseil "staging" branch:Gravatar Abseil Team2018-01-25
| | | | | | | | | | - a74a7e9027e3f90835ae0f553f98be294781da18 Internal change by Abseil Team <absl-team@google.com> - 2d32db6ed063f93b67886b9c27602d5aea3c21f7 Add /D_SCL_SECURE_NO_WARNINGS to MSVC builds to disable c... by Jon Cohen <cohenjon@google.com> - 54f40318d1de67b6b25f8aa68343f8bbcde8c304 Use sized delete in FixedArray. by Chris Kennelly <ckennelly@google.com> - 193f50b3500ab1a102a00df4e05ad7b969e9337b Fixes some warnings that show up during builds with msvc. by Greg Miller <jgm@google.com> GitOrigin-RevId: a74a7e9027e3f90835ae0f553f98be294781da18 Change-Id: I6d2b1f496974a1399ca5db6b71274368c2699a59
* Changes imported from Abseil "staging" branch:Gravatar Abseil Team2017-12-18
| | | | | | | | - f59c2332341d6b1a3e045d61eb0065f7a226f807 Avoid preprocessing '__CUDACC_VER__ >= 70000' on CUDA 9,... by Abseil Team <absl-team@google.com> - 12dd22cf967603e9a12d58abfe877989d61844e3 Internal change. by Greg Falcon <gfalcon@google.com> GitOrigin-RevId: f59c2332341d6b1a3e045d61eb0065f7a226f807 Change-Id: If4f5274e6d638a2ac86f1377e6ac0481dc584f19
* Changes imported from Abseil "staging" branch:Gravatar Abseil Team2017-11-13
| | | | | | | | - 5677afe8f626bb9db6d8bf9f25ba3d835ffa12d6 Internal TSAN bookkeeping change. by Greg Falcon <gfalcon@google.com> - c7492bad6fe6c8f106d3fcb1f8a939ea73b1a962 MSVC fix. by Alex Strelnikov <strel@google.com> GitOrigin-RevId: 5677afe8f626bb9db6d8bf9f25ba3d835ffa12d6 Change-Id: I1b8497508c8005a094824b4ccf9b220812b81bdb
* Changes imported from Abseil "staging" branch:Gravatar Abseil Team2017-09-20
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | - 06c8c67f5a564d00696e023060f05a5c34e7e164 IWYU | absl/base by Juemin Yang <jueminyang@google.com> - 2b1a054a09bda55843b449843b2a125741e936e7 Internal refactoring by Greg Miller <jgm@google.com> - f43f7f1f91bee26b5ddcd0c5bbbc47cb977aef77 Make std::hash<absl::optional<T>> to be standard compliant: by Xiaoyi Zhang <zhangxy@google.com> - 539bad2ebc22e610e1f292285a30a87945bc663e Update utility.h to Abseil standards by Tom Manshreck <shreck@google.com> - d05ec10a5f16a5d6640e0db91ecc7ab3ea971fd4 Add a test for absl::Barrier. by Derek Mauro <dmauro@google.com> - d707e27acb3c06f0d74c5f7ad7861e3841a5471f Run leak-checking tool over all outbound code. by Daniel Katz <katzdm@google.com> - 55f07f482a50422b8f99f7176374a19d0d473c5f Add alignas(16) to uint128. by Alex Strelnikov <strel@google.com> - 94999b7edde82308f736fb939501537ee9edbca6 Update attributes.h to Abseil standards by Tom Manshreck <shreck@google.com> - 321bed0061c41b53d0206ad4865528c00dd6d825 Test git merge + piper cl process by Juemin Yang <jueminyang@google.com> - 69920e7351a1053a7f4940bbde1768e839ce84bc Adds support for "/etc/localtime" as an embedded time zon... by Greg Miller <jgm@google.com> - 6839c06bf232903d3a9cbffa6eb2c960db78e67b Add copyright notices to inlined_vector code. by Greg Falcon <gfalcon@google.com> - 4e2714f6266263515cdfd31675c30c6ed6f98e1a Adding Apache 2.0 License by Gennadiy Civil <misterg@google.com> - 7402e7594016a4cd0a8b823fe6bc1bad1874bb85 IWYU | absl/utility by Juemin Yang <jueminyang@google.com> - 271a3812337eed97c412042738482688a80e19bd IWYU | absl/memory by Juemin Yang <jueminyang@google.com> - 32bda13a8098c2b06e25a5cf7bb782d6b79eb006 IWYU | absl/numeric by Juemin Yang <jueminyang@google.com> - 62d375cedc133108904bc06e340e303091a565df Remove "no_test"-annotations on span_test_noexceptions. by Daniel Katz <katzdm@google.com> - ebcbae9a55a93a7f1bb6862edc2715a6d9877206 Move CI-testing support files out of public-facing reposi... by Daniel Katz <katzdm@google.com> - d3f05eff4daa6030bfacb31cca0f9213fb702247 Fixes ToInt64Minutes() and ToInt64Hours() to properly sat... by Greg Miller <jgm@google.com> - b8dfae3facb6bb002622f083a10d14448f19e6e0 Fix typo. by Abseil Team <absl-team@google.com> - 150f03baa0afa231c2fc01597ea2321da586caba Update README.md by Yilei Yang <yileiyang@google.com> - 05276aa837dd081686518fd27bda4bd206ac4443 Adding Apache 2.0 License by Gennadiy Civil <misterg@google.com> - 37bf8e223e79ad06a195e28db9499e0c3d140f73 IWYU | absl/container by Juemin Yang <jueminyang@google.com> - 49164928f220978a32f88d16a55549bdf871daef IWYU | absl/algorithm by Juemin Yang <jueminyang@google.com> - a6804734e129039f9580a4fcd0f66425d0d0ac30 Move throw delegate wrappers to an internal namespace. by Greg Falcon <gfalcon@google.com> - ac83e73f67f593e2aff957b2be0b28e59c552a71 Fix error in comment stripping directives. by Greg Falcon <gfalcon@google.com> - e018a24185a984e787fb81a75fc35b74ad3a4d3d Update copyright headers all BUILD files by Gennadiy Civil <misterg@google.com> - a3be0990bfd76b0dec76bd85cecfa4dcec68b3ea Fix closing namespace comment typo. by Abseil Team <absl-team@google.com> - be3e3c4327e4f83949e0f29fd7a190d7eaa8b50b Update TODO by Abseil Team <absl-team@google.com> - f56a5d6f72685d92bb9c2905841b950d8177210c Add test-coverage for leak-sanitizer. by Daniel Katz <katzdm@google.com> - 7694bf161c7e00fdd08bfadc2aaf8e0fb09335f8 span.h: further touch up wording around the std::initiali... by Abseil Team <absl-team@google.com> - 3a12e081c0f8b359973e020d1e91f65356548ebc Update time.h to Abseil standards by Tom Manshreck <shreck@google.com> - 48d28f6468129420f4b20d451dca8e08012a7a77 Remove references to google from comments in Abseil. by Greg Falcon <gfalcon@google.com> - 773e34402d15fcad6370d5ed2430482d17db910d Rename the ExpectTime macro to match Abseil naming conven... by Greg Falcon <gfalcon@google.com> - 774d2ff1fe26c7313b301ff203e83e1aaac86627 Internal change. by Daniel Katz <katzdm@google.com> - 2e8a5830e95c8a1b839721bb2f1d4f5c85b9fb60 Fix typo in comment (missing '*' on a pointer). by Abseil Team <absl-team@google.com> - 458106feb707cf9609dd243713bde44aa9679e2a Correct capitalization: github -> GitHub by Yilei Yang <yileiyang@google.com> - af440725f02c2a83ca5cbaf176e1142f9e9d9b2f Update copyright headers by Gennadiy Civil <misterg@google.com> - 05b1118cce4ab87d23c33d48e64a96bcfec08761 Update copyright headers by Gennadiy Civil <misterg@google.com> - d5c6669a62d047156bb77055c5da03ee1b3c61b9 Update Abseil README to include descriptions of the inclu... by Tom Manshreck <shreck@google.com> - 3cd7e4663dddc840087469a6495f6cf433bfad8d Update copyright headers in //base by Tom Manshreck <shreck@google.com> - 7a876da657cd6698c5da2008a582d52eedc85dd1 Update strings overview with robust string library docume... by Tom Manshreck <shreck@google.com> - d9e3d0768d6f1c77d30992bdbef7b47ec92994bb Update copyright headers all BUILD files by Abseil Team <absl-team@google.com> - 6fe942728bceb0625f7c79b2840c4a6154d076b3 Make InlinedVector, FixedArray, and Span's at() throw on ... by Jon Cohen <cohenjon@google.com> - 5b52d5ec6cb9fbb07fc2e2fa020bd3eeb48c4953 Update clock.h to Abseil standards by Tom Manshreck <shreck@google.com> - c03c1ca3aee8bb7e40aa0315f6c432d31a72c30c Update //algorithm copyright headers by Tom Manshreck <shreck@google.com> - d46f40ddc596aaacb0459351d0e4aa6871289fa2 Temporarily prevent running mutex_test on crosstool17, wh... by Jon Cohen <cohenjon@google.com> - 61f11476189df68edfb9908308d677a91f03ff67 Update copyright headers in //container by Tom Manshreck <shreck@google.com> - 91832c00948954edf0b3dda12219c9a0202421ac Update copyright headers for //synchronization by Tom Manshreck <shreck@google.com> - 4e09100264b4585af6b4508ff35b9c627ac1f1ce Update copyright headers all BUILD files by Gennadiy Civil <misterg@google.com> - 13a0e8aebedec0f95b33750cbcd6b5548619b2a5 Update copyright headers in //memory by Tom Manshreck <shreck@google.com> - 63e1b9d4fdbcdf097e5276050ad1f76f0053e553 Update copyright headers for //strings (+ one from //nume... by Tom Manshreck <shreck@google.com> - 0108e7cfc50777a94c56d00e9c305161364df341 Convert ASSERT and EXPECT to ABSL_RAW_CHECK in helper fun... by Derek Mauro <dmauro@google.com> - 0122306fe47a3093248254a1b475c3a1d82abec5 Internal change by Abseil Team <absl-team@google.com> - 89c0c2698c98a12cd63172eeb02063b2f67e7c81 #absl Fix comment. by Abseil Team <absl-team@google.com> - 6621cc1ff54800e0aadb5e3071dbaa84b2077ceb Publishing contributing guidelines. by Gennadiy Civil <misterg@google.com> - e48c5be3c75e794b3e3827d40915b01fe1a1afc5 Avoid PRIdPTR. Cast to long long and use %lld insted. by Abseil Team <absl-team@google.com> - 2640ea4a260d89b94b07a3142660327e47db33fd No algorithmic changes. by Abseil Team <absl-team@google.com> - 1bc6c1bad17754f5d84963bf1d0db279402a0a1d Internal change. by Derek Mauro <dmauro@google.com> - 6845d24733e8c95bebde825ba78a2abfd9e35bdb span.h: fix up incorrect wording around lvalues. by Abseil Team <absl-team@google.com> - d8f5caee721e252e5f9b1080fb996363f498ac28 Add more exaustive Mutex testing. by Derek Mauro <dmauro@google.com> - e8b4cb053eb98858eef10cc53280b6ed5d6815a7 Change Span::subspan to not call into a deprecated constr... by Jon Cohen <cohenjon@google.com> - 49c36a82b3114926390557670aaaf0ea25b5760c s/std::size_t/size_t/g by Jon Cohen <cohenjon@google.com> - e17487c3c4d4a99f2fd8bc3e42176fc3171614d1 Account for the case of timeval::tv_sec being smaller than by Abseil Team <absl-team@google.com> - ecbb89d5fb98483e777c03d97ac02d7b7b54985e Alias absl::string_view to std::string_view when C++17 st... by Xiaoyi Zhang <zhangxy@google.com> - 6820e5a51459cdbb6a423cbae25a0cc839c85d44 Internal cleanup. by Xiaoyi Zhang <zhangxy@google.com> - 6976469b76a6faaf4111a24ddb37f40211ffadae More Span constexpr by Jon Cohen <cohenjon@google.com> - 8521c8956eee1125b7759eb272ec4a5a86fcefc5 #absl Fix comment. by Abseil Team <absl-team@google.com> - 20eae7a67fde5dd809aa47e5f7de8a493701645e Embed enough zoneinfo data to make time:time_test (under ... by Abseil Team <absl-team@google.com> - 841f5d98ceef4a423839ea73ee06c2f47a9b9680 Clean up macros in attributes.h | ATTRIBUTE_INITIAL_EXEC by Juemin Yang <jueminyang@google.com> - 83d8b36656e47919b5d0bac82eece897e195697e Update any.h comments to Abseil standards by Tom Manshreck <shreck@google.com> - bb3fae11d3459eeae2f63bfd22e65d3193187cc8 Update type_traits.h comments to Abseil standards by Tom Manshreck <shreck@google.com> - 992e1b07c0dec64271f8c44f22fd8df3734d0c47 Renamespace CycleClock code. by Greg Falcon <gfalcon@google.com> - 08d6fb0594098493ffbc0e737405182638122e7e Eliminate more existing lint warnings by Gennadiy Rozental <rogeeff@google.com> - 1cc6fdc71eb777497239f8c3e9168e6c9d40ea53 Update optional.h to Abseil standards by Tom Manshreck <shreck@google.com> - baa91747aa55009a9eb31b6072e33db06cfce2d2 Enforce internal namespace symbol reference policy by Gennadiy Rozental <rogeeff@google.com> - 939251e39342ce559e5d23fe43799671581f7cf5 Add CycleClock scaling shift to mitigate a possible overf... by Derek Mauro <dmauro@google.com> - c6dfdeecea0c7470938bed47c99ea2b2a95889d8 Add constexpr tests for absl::make_optional(). by Xiaoyi Zhang <zhangxy@google.com> - 509e949b992db33041d840746fbd05cc01cb206e Alias absl::optional to std::optional when C++17 std::opt... by Xiaoyi Zhang <zhangxy@google.com> - a1ae6d96a8826ba75281cac8632a766b5856acaf Remove no_test_* tags from span_test to increase test cov... by Xiaoyi Zhang <zhangxy@google.com> - 3c2a43cc09791723c8a324836629644ac44cb9c8 Remove accidental bits of Google-internal code and short ... by Greg Falcon <gfalcon@google.com> - 4874d49d496ac0b6ec36f4280a14b2159e7af930 Replaces the macro-generated Duration factory functions e... by Greg Miller <jgm@google.com> - 90e62695e03cb4a57e137ca0c3e116b1d802db57 Fix namespacing for a couple files in base/internal, and ... by Greg Falcon <gfalcon@google.com> - b0e6e00e34f967924849aaf8c123bba068f093e3 Publishing contributing guidelines. by Gennadiy Civil <misterg@google.com> - d74eafbccc3dffa6c25f9b6a2219425a24b5a959 Internal change by Abseil Team <absl-team@google.com> - 27477badbbf720265f5b9509b6c0e01913dc0a9f Update escaping.h comments to Abseil standards by Tom Manshreck <shreck@google.com> - 67002f55738319c2875197c3b6282de215ec250d adds absl namespace to debugging/stacktrace.h by Behzad Nouri <bnouri@google.com> - e608018f7faa384d5b202ac0a4c7a0d5166f4d9c Update string_view.h comments to Abseil standards by Tom Manshreck <shreck@google.com> - e884f04d4c648e01ed7dcde2fda80c24e8452047 Exclude strings/ files we are not releasing from OSS univ... by Gennadiy Rozental <rogeeff@google.com> - 3f4c4032ed520f2dd10a81d58ef4f399c001c5cc Strip out eventmanager reference from release. by Gennadiy Rozental <rogeeff@google.com> - fb0f1c204793c3792bad101dbaa734e7c2a35887 Fix copybara strip comments by Gennadiy Rozental <rogeeff@google.com> - 3eaaac942f77c3d41d63d414630403bfd0f6b70c Strip out style guide waivers. by Gennadiy Rozental <rogeeff@google.com> - 020e045058173178b51266b99a2a5dc9ed921960 substitute_test portability | MUST_USE_RESULT cast-to-voi... by Juemin Yang <jueminyang@google.com> - 86c093bf81d80ff537ed5e8b89225ce75a636220 Internal change. by Derek Mauro <dmauro@google.com> - 330375eb952fe78276e75631a28e750d5bfdb198 Prefer absl::FixedTimeZone() over loading "Etc/GMT[-+]<N>". by Abseil Team <absl-team@google.com> - 2e07ebee46a8201adc0dfd2c4ddb3df76e524357 Internal change. by Derek Mauro <dmauro@google.com> - 1f0c8b78c8ebd66f14cdf39fcba9f4c9986dcdca ::absl -> absl by Gennadiy Rozental <rogeeff@google.com> - ad163566d12ea08f1da2c23931eeacfffc564139 Avoid old style loops where possible. by Gennadiy Rozental <rogeeff@google.com> - bce2108818fe57b5617ce0090ddd4f753808f0a1 Update comments in str_cat.h in line with recent changes. by Abseil Team <absl-team@google.com> - cfd593a80f4897256f2ce1ea0be55dc14e3fcad4 Copybara-out gtl aliases. by Gennadiy Rozental <rogeeff@google.com> - 584f1524d717993c1a16093caccd9ed2b1e5409e Fix a warning for Windows/Kokoro time_test.cc. by Daniel Katz <katzdm@google.com> (And 562 more changes) GitOrigin-RevId: 06c8c67f5a564d00696e023060f05a5c34e7e164 Change-Id: I89907a6188fe7de05da400bf49ddfeba242aff8e
* Initial CommitGravatar misterg2017-09-19