- 29 Jan, 2021 2 commits
-
-
Andrew McFague authored
Summary: This introduces the concept of a *concurrent* version of `folly::lazy` that stems from our own needs for use lazily instantiated class variables in a multi-threaded environment. Reviewed By: ot, praihan, luciang Differential Revision: D25958581 fbshipit-source-id: 6b85402708fe9ca31b4d93607cf92f23d6a3edb5
-
Dan Melnic authored
Summary: Fix broken build Reviewed By: ispeters, Orvid Differential Revision: D26138456 fbshipit-source-id: 8f46b268ecaf923e507db6706af7840095a151f7
-
- 28 Jan, 2021 5 commits
-
-
Lee Howes authored
Summary: DefaultCPUExecutor is the same as InlineExecutor, but hidden to avoid instantiating it to allow filtering on type, primarily in coro::task. Reviewed By: mpark, terrelln Differential Revision: D26077566 fbshipit-source-id: 06704134f2446727cbb9f093df0b1954b46d2e49
-
Pranjal Raihan authored
Summary: The current data storage API code assumes that the MicroLock is 4-byte aligned and that the lock lives in the lowest byte of `word()`. This assumption is incorrect (see added test). We should instead rely on `baseShift()`. This API is only used for `folly::compact_once_flag` which is new so low chance something broke. Reviewed By: andriigrynenko, davidtgoldblatt Differential Revision: D26091484 fbshipit-source-id: c6e6e9aa7a963cada16e0ef7783fcc6bf6d2aed6
-
Pranjal Raihan authored
Summary: Even though `folly::MicroLock` is 1 byte, `detail::Futex<>` (aka `std::atomic<uint32_t>`) operates on 4 bytes. So 3 bytes are accessed but not used in any way. So we need to disable memory sanitizer. Reviewed By: andriigrynenko Differential Revision: D26082888 fbshipit-source-id: fe585b60c96f48c02df69d182bd75a8eccde2a42
-
Mingtao Yang authored
Summary: Many protocols often only require certificate information at the beginning of the connection (for authentication and authorization). Often, the protocol implementation will itself store its own representation of a transport identity. Certain certificates, such as X509 certificates, may be large and unnecessary to hold onto during the entirety of a connection past the initial connection establishment / handshaking phase. It is desirable to hint to transport implementations when certificate information is no longer needed. Reviewed By: AjanthanAsogamoorthy Differential Revision: D26031748 fbshipit-source-id: de5164acfc141755debc0aa4f36474b1c7fd3109
-
Philip Pronin authored
Summary: `dynamic::merge_diff` currently fully replicates `target` within the patch. Reviewed By: psjanani, luciang Differential Revision: D26100408 fbshipit-source-id: f6800e665281d87393fed0bb48bda888e24bbcfc
-
- 27 Jan, 2021 4 commits
-
-
Francesco Zoffoli authored
Summary: The linked paper, the implementation and the tests use the parameter as the old value, but the parameter name is called `expected`. Reviewed By: aary Differential Revision: D25975108 fbshipit-source-id: bb67a95b057973e31512e9f972e1646e5a0f7d77
-
Cameron Pickett authored
Differential Revision: D26084514 fbshipit-source-id: ab7e94bb0f0da04d60af7112f34c7c221125feb7
-
Pedro Eugenio Rocha Pedreira authored
Summary: Adding simple getdeps.py manifest for f4d. Reviewed By: amitkdutta Differential Revision: D25842791 fbshipit-source-id: eabc33ec526c454f301f8cd401156f6250e5eaa1
-
Dan Melnic authored
Summary: Fix flakey test Reviewed By: kevin-vigor Differential Revision: D26090290 fbshipit-source-id: f03d6abf389815993e8742d5c27c2ccbcb13949a
-
- 26 Jan, 2021 6 commits
-
-
Chad Austin authored
Summary: Pull Request resolved: https://github.com/facebookincubator/resctl/pull/8076 D26025779 (https://github.com/facebook/folly/commit/4731bb0c37cc39a7a689a8369c9564eddeae146c) may have broken the getdeps build when logging surrogates. Use errors=surrogateescape to try to avoid that. Reviewed By: danobi Differential Revision: D26079717 fbshipit-source-id: 98d938bfced417e0b39a6dcddb241225ffb69c06
-
Alexey Spiridonov authored
Reviewed By: nilesr Differential Revision: D26059442 fbshipit-source-id: d323ab38d7171b344c5a15863ec8d0a70b877853
-
Pranjal Raihan authored
Summary: Use the 1 byte version of `once_flag` such that there is no more memory overhead than `Optional`. Reviewed By: andriigrynenko Differential Revision: D25909346 fbshipit-source-id: 1bb2f41200917ba58b20815bfafe3314137e9680
-
Pranjal Raihan authored
Summary: `folly::MicroLock` is actually 4 locks in one. Turns out that it's not very useful considering there is not a single use in fbcode. Instead `MicroLock` should allow a nicer API for exposing the 6 unused bits as user data. By limiting the lock to one slot (least significant 2 bits), we can make the assumption that the 6 contiguous most significant bits are user data. This means that all the masking logic can go away (see `slotMask` and `LockGuardWithDataSlots`). Now `lockAndLoad`, `unlockAndStore`, `LockGuardWithData` "just work" with needing to worry about user data interfering with the slots used for locking. Reviewed By: davidtgoldblatt Differential Revision: D25909068 fbshipit-source-id: 3f050fa7393b40cff949ed6e30b691d7f40d0edf
-
Xiangyu Bu authored
Summary: This diff corrects two references to `MutableStringPiece` that are misspelled as `MutablesStringPiece` which doesn't exist. Reviewed By: Orvid Differential Revision: D26011095 fbshipit-source-id: 2503e13b84e04654c242bcd1f7bb17f9c1b757dc
-
David Detlefs authored
Summary: I thought that since I noticed it, and it tripped me up a bit, we might as well fix it. Reviewed By: LeeHowes Differential Revision: D26048767 fbshipit-source-id: 91ba9f834df411eb2d775691be4aec8a8d99776b
-
- 25 Jan, 2021 4 commits
-
-
Pranjal Raihan authored
Summary: `folly::compact_once_flag` is implemented using 1 byte. `folly::MicroLock` slot0 is used as the mutex for the slow path and slot1 is used for the stored boolean. Reviewed By: andriigrynenko Differential Revision: D25797066 fbshipit-source-id: 529de84b50e61523318a19606bc24c54f1ffa3a4
-
Chad Austin authored
Summary: The log file should be opened with a defined encoding rather than whatever the platform default is. On Windows, that might be cp1252, which throws an encoding error when the text is unicode. Reviewed By: genevievehelsel Differential Revision: D26025779 fbshipit-source-id: 0102b2555e91812dfe94a7c332eb896ca2c9ef7e
-
Xiao Shi authored
Summary: As title https://gcc.godbolt.org/z/58Mqb6 Reviewed By: Orvid Differential Revision: D26012680 fbshipit-source-id: 7c8859fec4a5f3a58b05e4ff7924273bd05891ec
-
Kevin Vigor authored
Summary: Add co-routine interface to SImpleAsyncIO. Reviewed By: iahs Differential Revision: D25932969 fbshipit-source-id: df14e25a0fe293a218d6bef0c4bd1bc8e690efba
-
- 24 Jan, 2021 2 commits
-
-
Laurent Stacul authored
Summary: Hello, It seems it is a missing include. Regards, Laurent Pull Request resolved: https://github.com/facebook/folly/pull/1464 Reviewed By: yfeldblum Differential Revision: D25730356 Pulled By: Orvid fbshipit-source-id: 61faa2fdc161450909de6678c1bb8aa331260f64
-
Lucian Grijincu authored
folly: symbolizer: add minimal folly-addr2line tool -- intented for validation tests/debugging, not as a full-featured replacement for addr2line Reviewed By: Orvid Differential Revision: D25991335 fbshipit-source-id: fcdc1b1cdeab7623c67b69ce2f80b062c0935436
-
- 22 Jan, 2021 4 commits
-
-
Pranjal Raihan authored
Summary: Trying to use `ZeroSizeMutex` in `CallOnce.h` causes a circular dependency: ``` //folly/synchronization:call_once -> //folly/synchronization:call_once-module -> //folly/synchronization:call_once-module-helper -> //folly/synchronization:zero_size_mutex -> //folly/synchronization:baton -> //folly/detail:memory_idler -> //folly/synchronization:call_once ``` The benefits of `folly::once_flag` are as follows: https://www.internalfb.com/intern/diffusion/FBS/browse/master/fbcode/folly/synchronization/CallOnce.h?commit=d0211e9462c39c4655a7d2ff9d313f6fb433d74a&lines=37-42 A fast path is not necessary here because it's just logging within an error case. Exception-proof behavior is not needed because glog does not throw. Reviewed By: yfeldblum, andriigrynenko Differential Revision: D25797067 fbshipit-source-id: 4de20235ff4115b73ab8a2689e7697fc9fe4ba65
-
Andrew McFague authored
Summary: This allows `try_emplace_with` to receive objects by copy-ellision or specific moves; without it, any attempts to pass an object would result in a copy. Reviewed By: praihan, luciang Differential Revision: D26008949 fbshipit-source-id: b43d2dc941c7415e2189668a2b577cc0f1165665
-
Victor Zverovich authored
Summary: `constexpr` is known to be broken in MSVC causing errors when using format string compilation so disable `FMT_COMPILE` there. Reviewed By: neildhar Differential Revision: D26019769 fbshipit-source-id: b823b24d4e73fcf9632f8e648ebb9a4e73c43bb1
-
Orvid King authored
Summary: As per title, as fmt doesn't currently handle them well. Reviewed By: vitaut Differential Revision: D26004515 fbshipit-source-id: dbbd1e6550fa10c4a6fcb0fc5597887c9411ca70
-
- 21 Jan, 2021 7 commits
-
-
Niles Rogoff authored
Differential Revision: D25985696 fbshipit-source-id: 52ede8dc494f8bf1991dbfed455fbc6bbba83d87
-
Orvid King authored
Summary: It wasn't guarded at all, which is causing issues for non-sanitizer builds on platforms without shared library support. Ref: https://github.com/facebook/folly/issues/1507 Reviewed By: meyering Differential Revision: D25970872 fbshipit-source-id: f710e752fdf8ebc5529314d335f4559e690b787a
-
Victor Zverovich authored
Summary: Switch to format string compilation to prevent pulling in too many symbols from the {fmt} library into `folly/detail:ip_address`. This change saves ~64k (fixed cost) in opt mode compared to the current master or ~36k compared to the old code using Folly Format. This doesn't matter for server projects especially since {fmt} will likely be linked anyway but matters for some mobile ones. Reviewed By: Orvid Differential Revision: D25904078 fbshipit-source-id: 56473cf9bf4456a3cb3c5aa375c16393e144b6e1
-
Udip Pant authored
Summary: Allows us to use new APIs in libbpf Reviewed By: anakryiko Differential Revision: D25933787 fbshipit-source-id: f0988caae351760b814eba74f6f716db51f728bd
-
Adam Simpkins authored
Summary: Previously the `EXPECT_THROW_RE()` macro required the regular expression be passed in as a `const char*`. This updates the code to accept a `std::string_view` instead. This allows the API to accept either `const char*` arguments, `std::string`, or `std::string_view` objects. Reviewed By: yfeldblum Differential Revision: D25837542 fbshipit-source-id: e6fb00034046ad7f2810367f946f0135858ed065
-
Dan Melnic authored
Summary: Handle values different from pending_ Reviewed By: kevin-vigor Differential Revision: D25968014 fbshipit-source-id: fd70dd6339d02a6325b237e6c9401d8962b17b51
-
Xiao Shi authored
Summary: This diff moves the gdb related test into `folly/support/test` (as opposed to `tests`) so that CMake rules [here](https://github.com/facebook/folly/blob/194b7732bd65d56b4afb58b6d9e411c1b014b3e3/CMakeLists.txt#L155) will exclude these files from OSS library builds--also to maintain consistency with other test folder names under folly. I still separated out the auto gdb breakpoint functionality into GdbUtil.h so that if MSVC users want to manually compile and use the gdb script tests, they have the option to do so. Re: asm syntax on MSVC: https://gcc.godbolt.org/z/1rMh4v Fixes #1515. Reviewed By: Orvid Differential Revision: D25947735 fbshipit-source-id: 97e75e972fcf8eea280df804c98c400f03c37496
-
- 20 Jan, 2021 2 commits
-
-
Pedro Eugenio Rocha Pedreira authored
Summary: Adding protobuf manifest, which will be used to compile f4d/velox. Reviewed By: spershin Differential Revision: D25926384 fbshipit-source-id: 08a2dffc9e9baa0d393e5f648ce99ca032a9df5f
-
Pedro Eugenio Rocha Pedreira authored
Summary: Adding lzo manifest, which will be used by f4d/velox Reviewed By: amitkdutta Differential Revision: D25926434 fbshipit-source-id: 4d7efe5eba7cdca1f682fbd4cfd6ff0337ce7c19
-
- 19 Jan, 2021 1 commit
-
-
Stepan Palamarchuk authored
Summary: The current code is calling `runInMainContext` on the FiberManager that we're scheduling to, which will do nothing if we're calling it from another fiber manager. This will assume fiber stack as a main stack which is incorrect. This diff fixes it to call `folly::fibers::runInMainContext` that would properly call `runInMainContext` on the active FiberManager. Reviewed By: andriigrynenko Differential Revision: D25116215 fbshipit-source-id: 1d13f436a0599c077e7531dc1fe75f3a143e3478
-
- 16 Jan, 2021 1 commit
-
-
Giuseppe Ottaviano authored
Summary: The implementation doesn't need explicit locking or condition variables, everything can be done with a single concurrent queue. Reviewed By: yfeldblum Differential Revision: D25919429 fbshipit-source-id: a2b1e6332305174ba41d02fd79d9525a12b82218
-
- 15 Jan, 2021 2 commits
-
-
Giuseppe Ottaviano authored
Summary: Make it consistent with the other executors. Reviewed By: yfeldblum Differential Revision: D25926045 fbshipit-source-id: ad2f101fbba918fe2a421e394870bf67c0a044b9
-
Xiao Shi authored
Summary: As title, move gdb pretty printers from internal repo to OSS repo Reviewed By: yfeldblum Differential Revision: D25684325 fbshipit-source-id: b7999dee1379801ee68553de64f16ac4db78b174
-