1. 23 Nov, 2015 3 commits
    • Michael Oliver's avatar
      Benchmark std::to_string vs. folly::to<std::string> · 4b750cf3
      Michael Oliver authored
      Summary: We wanted to compare the benefits of using folly::to<std::string> directly, and decided this benchmarking might as well be contributed back to folly.  Here are the results:
      
      ```
        ============================================================================
        folly/test/ConvTest.cpp                         relative  time/iter  iters/s
        ============================================================================
        ...
        ----------------------------------------------------------------------------
        u64ToStringClibMeasure(1)                                  157.88ns    6.33M
        u64ToStringFollyMeasure(1)                       212.52%    74.29ns   13.46M
        ----------------------------------------------------------------------------
        u64ToStringClibMeasure(12)                                 158.14ns    6.32M
        u64ToStringFollyMeasure(12)                      212.55%    74.40ns   13.44M
        ----------------------------------------------------------------------------
        u64ToStringClibMeasure(123)                                152.26ns    6.57M
        u64ToStringFollyMeasure(123)                     210.95%    72.18ns   13.85M
        ----------------------------------------------------------------------------
        u64ToStringClibMeasure(1234)                               152.40ns    6.56M
        u64ToStringFollyMeasure(1234)                    204.82%    74.41ns   13.44M
        ----------------------------------------------------------------------------
        u64ToStringClibMeasure(12345)                              156.01ns    6.41M
        u64ToStringFollyMeasure(12345)                   208.90%    74.68ns   13.39M
        ----------------------------------------------------------------------------
        u64ToStringClibMeasure(123456)                             178.21ns    5.61M
        u64ToStringFollyMeasure(123456)                  238.77%    74.63ns   13.40M
        ----------------------------------------------------------------------------
        u64ToStringClibMeasure(1234567)                            161.38ns    6.20M
        u64ToStringFollyMeasure(1234567)                 203.09%    79.46ns   12.58M
        ----------------------------------------------------------------------------
        u64ToStringClibMeasure(12345678)                           159.01ns    6.29M
        u64ToStringFollyMeasure(12345678)                192.42%    82.64ns   12.10M
        ----------------------------------------------------------------------------
        u64ToStringClibMeasure(123456789)                          169.07ns    5.91M
        u64ToStringFollyMeasure(123456789)               203.70%    83.00ns   12.05M
        ----------------------------------------------------------------------------
        u64ToStringClibMeasure(1234567890)                         166.56ns    6.00M
        u64ToStringFollyMeasure(1234567890)              187.21%    88.97ns   11.24M
        ----------------------------------------------------------------------------
        u64ToStringClibMeasure(12345678901)                        176.22ns    5.67M
        u64ToStringFollyMeasure(12345678901)             197.57%    89.20ns   11.21M
        ----------------------------------------------------------------------------
        u64ToStringClibMeasure(123456789012)                       174.74ns    5.72M
        u64ToStringFollyMeasure(123456789012)            182.52%    95.74ns   10.45M
        ----------------------------------------------------------------------------
        u64ToStringClibMeasure(1234567890123)                      178.47ns    5.60M
        u64ToStringFollyMeasure(1234567890123)           186.81%    95.54ns   10.47M
        ----------------------------------------------------------------------------
        u64ToStringClibMeasure(12345678901234)                     187.33ns    5.34M
        u64ToStringFollyMeasure(12345678901234)          184.05%   101.78ns    9.82M
        ----------------------------------------------------------------------------
        u64ToStringClibMeasure(123456789012345)                    198.16ns    5.05M
        u64ToStringFollyMeasure(123456789012345)         182.48%   108.59ns    9.21M
        ----------------------------------------------------------------------------
        u64ToStringClibMeasure(1234567890123456)                   182.56ns    5.48M
        u64ToStringFollyMeasure(1234567890123456)        164.19%   111.19ns    8.99M
        ----------------------------------------------------------------------------
        u64ToStringClibMeasure(12345678901234567)                  186.80ns    5.35M
        u64ToStringFollyMeasure(12345678901234567)       162.33%   115.07ns    8.69M
        ----------------------------------------------------------------------------
        u64ToStringClibMeasure(123456789012345678)                 195.08ns    5.13M
        u64ToStringFollyMeasure(123456789012345678)      165.51%   117.87ns    8.48M
        ----------------------------------------------------------------------------
        u64ToStringClibMeasure(1234567890123456789)                200.27ns    4.99M
        u64ToStringFollyMeasure(1234567890123456789)     164.62%   121.65ns    8.22M
        ----------------------------------------------------------------------------
        u64ToStringClibMeasure(12345678901234567890U)              203.18ns    4.92M
        u64ToStringFollyMeasure(12345678901234567890U)   162.38%   125.13ns    7.99M
        ----------------------------------------------------------------------------
        ...
        ============================================================================
      ```
      
      Reviewed By: yfeldblum
      
      Differential Revision: D2680998
      
      fb-gh-sync-id: 179fbd756c714c92b7230d3750af024865ecbb0a
      4b750cf3
    • Sara Golemon's avatar
      Add missing header files to folly-automake · eebb50f2
      Sara Golemon authored
      Summary: Closes https://github.com/facebook/folly/issues/304
      
      Reviewed By: yfeldblum
      
      Differential Revision: D2685289
      
      fb-gh-sync-id: 563697fb01ee358472b9080058848d2b557ba466
      eebb50f2
    • Sara Golemon's avatar
      Fix minor typo in folly/Conv.h · f757d940
      Sara Golemon authored
      Summary: 'flating point' => 'floating point'
      
      Closes https://github.com/facebook/folly/issues/241
      
      Reviewed By: yfeldblum
      
      Differential Revision: D2685280
      
      fb-gh-sync-id: 2e9c2b5419d0c631af4a32c5ab6b7366033ca34c
      f757d940
  2. 21 Nov, 2015 1 commit
  3. 20 Nov, 2015 5 commits
    • Lucian Grijincu's avatar
      Revert "Fix folly::ThreadLocal to work in a shared library" · 7ce0da39
      Lucian Grijincu authored
      Summary: This reverts commit 9d355f96c4fe073c889f28070d5952fa4eb007a0.
      
      build-break
      
      Reviewed By: sctaylor
      
      Differential Revision: D2680784
      
      fb-gh-sync-id: a2df233bcd3721ffbfcd6fd71ea3cabbebebd4c4
      7ce0da39
    • Haijun Zhu's avatar
      get back AsyncServerSocket's setMaxNumMessagesInQueue · 16811575
      Haijun Zhu authored
      Summary: D2613681 codemod'ed a thrift server api but it also renamed that api
      in AsyncServerSocket, which is a mistake. Fix that in AsyncServerSocket, and
      all other places that calls this api.
      
      Reviewed By: alandau, JoelMarcey
      
      Differential Revision: D2677837
      
      fb-gh-sync-id: 0d91f1a623229e99be59ca9dcd27f1330a9a1b64
      16811575
    • Anirudh Ramachandran's avatar
      Remove unnecessary resetClientHelloParsing callback in AsyncSSLSocket · 422bf874
      Anirudh Ramachandran authored
      Summary: Remove unnecessary resetClientHelloParsing callback which causes problems wiht
      Openssl 1.0.2
      
      Reviewed By: knekritz
      
      Differential Revision: D2664730
      
      fb-gh-sync-id: d1b55ae493b4c92627ad41e7bf85f1e1a777bd2b
      422bf874
    • Alexander Shaposhnikov's avatar
      Remove busy wait and support multiple wait · badc3ebe
      Alexander Shaposhnikov authored
      Summary: Remove busy wait from Future::wait.
      If future.wait(timeout) has succeded we should
      return a ready future, otherwise we should return a future
      for the final result (not necessarily ready).
      
      Reviewed By: yfeldblum
      
      Differential Revision: D2646860
      
      fb-gh-sync-id: 62671d09073ad86e84df8c9257e961d2a8c2a339
      badc3ebe
    • Delyan Kratunov's avatar
      Expose move result from LockFreeRingBuffer::Cursor · 587e4b4d
      Delyan Kratunov authored
      Summary: Without feedback that a `moveForward` or `moveBackward` did nothing, a user
      cannot implement this idiom safely:
      
      ```
      while(rb.tryRead(entry, cursor)) {
        doSomething(entry);
        cursor.moveBackward();
      }
      ```
      
      In the case where the ring buffer has not overflowed and slot 0 is still
      available, the reader will get stuck at it (read it continuously) until
      the buffer overflows.
      
      This diff allows the above example to become:
      
      ```
      while(rb.tryRead(entry, cursor)) {
        doSomething(etnry);
        if (!cursor.moveBackward()) {
          break;
        }
      }
      ```
      
      Reviewed By: bryceredd
      
      Differential Revision: D2674975
      
      fb-gh-sync-id: a0c5857daf186ef19e203f90acc2145590f85c3b
      587e4b4d
  4. 19 Nov, 2015 3 commits
    • Giuseppe Ottaviano's avatar
      Fix usingJEMalloc with Clang · 78022b6e
      Giuseppe Ottaviano authored
      Summary: Clang is too clever and in some contexts optimizes away the `malloc`, but we rely on a side-effect. Declaring the variable as static forces it to call `malloc`. We could free the pointer relying on the fact that the lambda is guaranteed to be called only once, but I feel more comfortable just leaking it (LSan won't complain).
      
      Reviewed By: philippv
      
      Differential Revision: D2674769
      
      fb-gh-sync-id: 1153a3ca226c6b7aa64c453bd61b036dcbf3ffcc
      78022b6e
    • Anton Likhtarov's avatar
      Fix invalid DCHECK · 2fa98577
      Anton Likhtarov authored
      Summary: There's a race between insert() and erase(): as soon as insert()
      releases the lock (swaps kLockedKey_ with the actual key), an erase() might
      jump in and invalidate the key.
      
      As far as I can tell, this bug existed since the beginning.
      
      Reviewed By: nbronson
      
      Differential Revision: D2673099
      
      fb-gh-sync-id: 4721893d2ad4836e11acc0fb4ecb0dd7b2b69be1
      2fa98577
    • Andrii Grynenko's avatar
      Fix folly::ThreadLocal to work in a shared library · f2daf056
      Andrii Grynenko authored
      Reviewed By: bmaurer
      
      Differential Revision: D2667499
      
      fb-gh-sync-id: 463f86752240bd88761910de934ba25d6e62fafe
      f2daf056
  5. 18 Nov, 2015 1 commit
  6. 17 Nov, 2015 1 commit
  7. 16 Nov, 2015 1 commit
  8. 15 Nov, 2015 1 commit
  9. 13 Nov, 2015 2 commits
    • Andrii Grynenko's avatar
      Make collect work for types with no default constructors · 5bad4e9f
      Andrii Grynenko authored
      Summary: This doesn't make the code less efficient, because RVO can't be used for CollectVariadicContext. Thus moving existing tuple vs constructing new tuple by moving all values from other tuple (where each value is wrapped in folly::Optional) should be pretty much the same.
      
      Reviewed By: hannesr
      
      Differential Revision: D2650293
      
      fb-gh-sync-id: 648a358bf093a0bb9d058a997af9bf59014ad77c
      5bad4e9f
    • Yang Chi's avatar
      Allow a AsyncSocket to be corked the whole time · 07c15086
      Yang Chi authored
      Summary: Add a new method to cork a socket in a persistent manner, instead of the current on-off manner. This is default to false. The liger part of turning this on will be in a separate diff.
      
      I thought about whether I need to turn cork off based on some criteria to alleviate the perf degradation. The obvious things I can think off is just amount of data written as a threshold, or a timeout. But TCP is doing this already for us, unless we want the data threshold to be less than MSS, or we want the timeout to be less than 200ms. THoughts?
      
      Reviewed By: shikong
      
      Differential Revision: D2639260
      
      fb-gh-sync-id: 2821f669c9f72d5ac4c33195bb192fc4110ffe9d
      07c15086
  10. 12 Nov, 2015 3 commits
    • Giuseppe Ottaviano's avatar
      Make Malloc.h self-contained · 19d24e21
      Giuseppe Ottaviano authored
      Reviewed By: philippv
      
      Differential Revision: D2643313
      
      fb-gh-sync-id: 10b9f735725ce47fab4bbfaa5972b3863357365f
      19d24e21
    • Giuseppe Ottaviano's avatar
      Disable assertions in FBString when used as std::string · a348e154
      Giuseppe Ottaviano authored
      Reviewed By: Gownta
      
      Differential Revision: D2643850
      
      fb-gh-sync-id: 2c4bb844ea2006215b0637cb1ba08c636faefe05
      a348e154
    • Chad Parry's avatar
      Restore the definition of HHWheelTimer::UniquePtr · 65b8a020
      Chad Parry authored
      Summary: Changing the definition of `HHWheelTimer::UniquePtr` wasn't safe, because some clients were using that type outside of the `HHWheelTimer::newTimer` helper. I'm changing that part back. We'll still be able to proceed with my other codemod to `HHWheelTimer`, but we'll always have two different smart pointer types to manage: `UniquePtr` and `IntrusivePtr`.
      
      Reviewed By: djwatson
      
      Differential Revision: D2644721
      
      fb-gh-sync-id: 14685be62355f09d39c4139ef7186d60b5f48dcd
      65b8a020
  11. 11 Nov, 2015 6 commits
    • Stepan Palamarchuk's avatar
      Make Optional nothrow_default_constructible · 2cf78a6a
      Stepan Palamarchuk authored
      Summary: It never throws.
      
      Reviewed By: pavlo-fb
      
      Differential Revision: D2640886
      
      fb-gh-sync-id: cd643f8847f4bf5619415731484f91fb07116784
      2cf78a6a
    • Yang Chi's avatar
      Add a buffer callback to AsyncSocket · 7749a469
      Yang Chi authored
      Summary: This is probably easier than D2612490. The idea is just to add a callback to write, writev and writeChain in AsyncSocket, so upper layer can know when data starts to buffer up
      
      Reviewed By: mzlee
      
      Differential Revision: D2623385
      
      fb-gh-sync-id: 98d32ca83871aaa4f6c75a769b5f1bf0b5d62c3e
      7749a469
    • Chad Parry's avatar
      Improve the DelayedDestruction smart pointer · 596d6f6d
      Chad Parry authored
      Summary: There have been several ASAN bugs cropping up because the lifetime of an `HHWheelTimer` is not being manager properly. I think that people are too comfortable passing around a raw `HHWheelTimer*` even when it is difficult to prove correctness. The recommended solution used to be to create a `DestructorGuard` every time it was needed. There is enough friction there that not everyone is doing that like they should. We should make resource management easier---as easy as using raw pointers, in fact.
      
      I've fixed the broken copy semantics of `DestructorGuard` and added the operators that allow it to be used as a smart pointer. I added the `IntrusivePtr` helper that can manage an arbitrary derived class of `DelayedDestructionBase`. Now, clients can all safely pass around an `IntrusivePtr` everywhere they used to use a raw pointer. They will get automatic resource management for free.
      
      If you are not convinced that `DestructorGuard` should be changed, then note that the existing behavior is dangerously buggy. Consider the following innocent code that accidentally uses the implicitly-defined copy constructor:
        auto d = DestructorGuard(p);
      This results in undefined behavior, because `p` can be accessed after it is destroyed! The bug happens because the default copy constructor copies the raw pointer but doesn't increment the count.
      
      In a separate diff, I'll change all clients who pass around a raw `HHWheelTimer*` to use an `IntrusivePtr<HHWheelTimer>` instead. Then we can even entertain a long-term plan of switching from intrusive pointers to the standard `shared_ptr`.
      
      Reviewed By: djwatson
      
      Differential Revision: D2627941
      
      fb-gh-sync-id: 58a934d64540d0bbab334adc4f23d31d507692da
      596d6f6d
    • Shaft Wu's avatar
      UNSYNCHRONIZED does NOT unlock the mutex · 6762f08b
      Shaft Wu authored
      Summary: My colleague tuomaspelkonen discovered a weird UNSYNCHRONIZED issue a few weeks ago and we ever since stopped using it. Now I finally have some time to root cause it. It turns out UNSYNCHRONIZED unlock the mutex then lock the mutex again, because it copy constructs LockedPtr for overriding the name within the scope, and copy construct locks the mutex again. A one character fix here is to take a reference of LockedPtr instead of copy construct it. However since this is my first time look at the code here, please advise if this is horribly wrong or propose better fix. Also added a test to reproduce the issue without the fix as well as verify the fix.
      
      Reviewed By: yfeldblum
      
      Differential Revision: D2633028
      
      fb-gh-sync-id: a9e8d39b08d4d1265979f8bdaae83619566d10a0
      6762f08b
    • Alexander Shaposhnikov's avatar
      Revert my change (which broke down the cont build) · 7ab42fa8
      Alexander Shaposhnikov authored
      Summary: hg backout -r c9f7b5f3185a
      Revert my change (which broke down the cont build t9048692)
      
      Reviewed By: djwatson
      
      Differential Revision: D2640797
      
      fb-gh-sync-id: 51f196ac5a3560fde4dc8fe7bb6ef278d74136e5
      7ab42fa8
    • Alexander Shaposhnikov's avatar
      Remove busy wait · 52b003af
      Alexander Shaposhnikov authored
      Summary: Wait uses baton & callback running baton.post
      when the original future is ready. However wrapping baton.post
      with a funciton call (preparing a new value) adds the following race: baton.wait wakes up
      before that function has call actually finished.
      The explanation is the following: to prepare the value of the new future it's necessary
      1. baton.post() 2. set the value (move constructor, memory operations, ...)
      and this code is executed in a separate thread.
      The main idea of this fix is to avoid creating a new future
      (whose value is calculated using that 2-step procedure)
      and set a callback instead. This callback will be executed when the future is ready and actually
      it either will be the last step of promise.setValue or it will run immediately if the future
      we are waiting for already contains a value.
      
      Reviewed By: fugalh
      
      Differential Revision: D2636409
      
      fb-gh-sync-id: df3e9bbcc56a5fac5834ffecc63f1bcb94ace02c
      52b003af
  12. 10 Nov, 2015 2 commits
    • Shijin Kong's avatar
      change log error back to check when pipe read fail in notification queue · 658a60b3
      Shijin Kong authored
      Summary: Revert D2632752
      
      Reviewed By: afrind
      
      Differential Revision: D2638974
      
      fb-gh-sync-id: 43d8135421510db7840a99f3c197119a0fd26c09
      658a60b3
    • Steve O'Brien's avatar
      FBString: fix constructors so it compiles with newer Clang's · c5ec1136
      Steve O'Brien authored
      Summary: Using Clang 3.7, this minimal test program:
      
        #include <folly/FBString.h>
        struct S { folly::basic_fbstring<char> x; };
        int main(int argc, char *argv[]) {
          S s {};
          return 0;
        }
      
      ... breaks with the following error output:
      
        FBStringTest.cpp:5:8: error: chosen constructor is explicit in copy-initialization
          S s {};
               ^
        ./folly/FBString.h:1009:12: note: constructor declared here
          explicit basic_fbstring(const A& = A()) noexcept {
                   ^
        FBStringTest.cpp:3:40: note: in implicit initialization of field 'x' with omitted initializer
        struct S { folly::basic_fbstring<char> x; };
      
      ... because this `basic_fbstring` is used in a struct and the struct is being default-constructed.
      
      This patch splits the (nevertheless-correct) one-default-arg constructor into two, to deconfuse clang and have it select the correct constructor to avoid this issue.
      
      Reviewed By: matbd
      
      Differential Revision: D2632953
      
      fb-gh-sync-id: 2c75ae85732678c31543f5cccc73d58317982f07
      c5ec1136
  13. 09 Nov, 2015 3 commits
    • Shijin Kong's avatar
      change CHECK to LOG(ERROR) when pipe read error on NotificationQueue · e56f9393
      Shijin Kong authored
      Summary: The check was originally added to track down cpu pinning issue. In reality the check did get triggered, so change to soft error to calm the crazy nag bot. what's wrong with you.
      We need to see the soft error log to find out what the error is.
      
      Reviewed By: mzlee
      
      Differential Revision: D2632752
      
      fb-gh-sync-id: 87c11b186f97f0eb4a6c5ac13a1117b280198673
      e56f9393
    • Alexey Spiridonov's avatar
      Add a tag type for in-place construction · 7c4e381e
      Alexey Spiridonov authored
      Summary: Without this tag type, it's impossible to use `Synchronized` with types like:
      
      ```
      struct A {
        A(int, const char*);
        A(const A&) = delete;
        A& operator=(const A&) = delete;
        A(A&&) = delete;
        A& operator=(A&&) = delete;
      };
      ```
      
      In-place construction solves this problem. Usage:
      
      ```
      Synchronized a(construct_in_place, 5, "c");
      ```
      
      Reviewed By: nbronson
      
      Differential Revision: D2610071
      
      fb-gh-sync-id: 251fe8f8f6a2d7484dda64cf04dcacb998145230
      7c4e381e
    • Chad Parry's avatar
      Make sure there are no outstanding timers in the destructor · a93b1f39
      Chad Parry authored
      Summary: This is the solution for our `HHWheelTimer` crashes, as suggested in D2617966#25.
      
      djwatson also mentioned that maybe there should be some logging in the destructor if there are outstanding callbacks. I couldn't think of anything that would add to the `assert` that already exists in `destroy`. I'm open to suggestions though.
      
      Reviewed By: djwatson
      
      Differential Revision: D2628154
      
      fb-gh-sync-id: f3db6e9384517c9bf3cbb60af8c1e711703a07fa
      a93b1f39
  14. 08 Nov, 2015 1 commit
    • Igor Sugak's avatar
      folly/portability: add clang version check · 408597e5
      Igor Sugak authored
      Summary: Define `__CLANG_PREREQ` macro to check version of clang.
      
      Reviewed By: yfeldblum
      
      Differential Revision: D2630325
      
      fb-gh-sync-id: 3d666e554e8ddfc2c1fecd439aaf93f015829025
      408597e5
  15. 06 Nov, 2015 2 commits
    • Chad Parry's avatar
      Callbacks should ref the HHWheelTimer · cb65a6b2
      Chad Parry authored
      Summary: Callbacks sometimes outlive the `HHWheelTimer` that they reference. Then the `Callback` tries to reference the dead `HHWheelTimer` and it could either misbehave or crash. This was caught reliably by ASAN tests.
      
      Since `HHWheelTimer` already supports intrusive ref counting, the solution is to acquire a reference within the `Callback`.
      
      Reviewed By: djwatson
      
      Differential Revision: D2617966
      
      fb-gh-sync-id: 02be9ffc5851c269d5933288a17ad394b33ac2dd
      cb65a6b2
    • Jon Maltiel Swenson's avatar
      Cancel timeout only if not run · 06b04cb1
      Jon Maltiel Swenson authored
      Summary: Do not cancel TimeoutHandler timeout if the timeout has already run.
      
      Reviewed By: spalamarchuk
      
      Differential Revision: D2622280
      
      fb-gh-sync-id: 27d83b44ab225e2859695f4e5f21cef934824a35
      06b04cb1
  16. 05 Nov, 2015 3 commits
    • Haijun Zhu's avatar
      codemod setMaxNumMessagesInQueue to setMaxNumPendingConnectionsPerWorker · 131db120
      Haijun Zhu authored
      Summary: This name's meaning is very obscure, this method actually sets the
      queue size of each acceptor and if all acceptor's queues are full the
      connection will be dropped. Change it to a more meaningful name.
      
      Reviewed By: alandau
      
      Differential Revision: D2613681
      
      fb-gh-sync-id: baa374cdf0a87c460df3dd5687e3d755b55f4b4f
      131db120
    • Jon Maltiel Swenson's avatar
      Activate server timeout after write success · a166df21
      Jon Maltiel Swenson authored
      Summary: Start server timeout after socket write succeeds in mcrouter.  Add neceessary Fibers logic to enable this behavior.
      
      Reviewed By: pavlo-fb
      
      Differential Revision: D2613344
      
      fb-gh-sync-id: 1bc0fbe8b325a3e91cd010f89104b83ebf183679
      a166df21
    • Viswanath Sivakumar's avatar
      Set interrupt handler correctly on SharedPromise · 8cb94e9b
      Viswanath Sivakumar authored
      Summary: If SharedPromise::getFuture() is invoked after a call to setInterruptHandler,
      then the interrupt handler isn't set on the newly created promise. This diff
      fixes that.
      
      Reviewed By: yfeldblum
      
      Differential Revision: D2610289
      
      fb-gh-sync-id: bf8fce9e881b83ccac17d13c6788ec2afd0b0153
      8cb94e9b
  17. 04 Nov, 2015 2 commits
    • Subodh Iyengar's avatar
      Add ability to get application protocol from AsyncTransportWrapper · 8f06296e
      Subodh Iyengar authored
      Summary: Allows AsyncTransportWrapper's to supply the underlying application
      protocol being used, for example using NPN for SSL or some other
      generic protocol indication mechanism.
      
      Reviewed By: ranjeeth
      
      Differential Revision: D2614179
      
      fb-gh-sync-id: 2079782bb7d44f898fb14c7df15077209b022424
      8f06296e
    • Zhen (Growth) Li's avatar
      switch the IndexType and Allocator in AtomicUnorderedInsertMap template · 46bf40d1
      Zhen (Growth) Li authored
      Summary: Our use case need to have the IndexType Configurable, but in this diff D2583752, lint error shows
        Code from folly::detail is logically private, please avoid use outside of folly.
      In order to fix this lint error, I switch the IndexType and Allocator in the AtomicUnorderedInsertMap template.
      
      Reviewed By: nbronson
      
      Differential Revision: D2610921
      
      fb-gh-sync-id: ae81b41e7c8c971f26c61b8c67dabeadff379584
      46bf40d1