- 14 Jul, 2014 5 commits
-
-
Elizabeth Smith authored
Summary: Folly is almost "out of the box" working with cygwin This has the proper ifdefs to include cygwin in two areas and a workaround for a cygwin bug when including headers Test Plan: fbconfig -r folly && fbmake runtests Reviewed By: delong.j@fb.com FB internal diff: D1413303
-
Elizabeth Smith authored
Summary: MSVC has all the sockets and internet functionality required except for one missing item - which can safely be defined to a windows specific type But it requires a different set of headers than on *nix systems Test Plan: fbconfig -r folly && fbmake runtests Reviewed By: delong.j@fb.com FB internal diff: D1413265
-
Elizabeth Smith authored
Summary: Use msvc intrinsics for cpuid, popcount, byteswap, and bit scan functionality Test Plan: fbconfig -r folly && fbmake runtests Reviewed By: delong.j@fb.com FB internal diff: D1413254
-
Elizabeth Smith authored
Summary: MSVC 14 is still broken with expression sfinae - and the things that break are often strange Moving this out into two expr templates solves the compilation issue Test Plan: fbconfig -r folly && fbmake runtests Reviewed By: tjackson@fb.com FB internal diff: D1413297
-
Wez Furlong authored
Summary: maelstrom destructs a Promise during an indirect call from maybeCallback and deadlocks on itself unless we use a recursive mutex. There may be a smarter way to proceed but at the moment I can't build and deploy a package from trunk because the service is non-functional :-/ Test Plan: run ``` fbconfig -r folly/wangle messaging/maelstrom fbmake runtests ``` Reviewed By: hannesr@fb.com Subscribers: fugalh, fsilva FB internal diff: D1428504
-
- 09 Jul, 2014 10 commits
-
-
Tudor Bosman authored
Summary: No need to specialize std::hash for std::basic_string; the STL already does this. Plus, the specializations were broken in multiple ways: 1. std::hash does not treat const char* specially, so it just hashes the pointer value (contrasting the old __gnu_cxx::hash, which hashed a C-string) 2. Either way, using __gnu_cxx::hash<const char*> for std::string is broken, as it won't hash anything past the first null byte. Also, make sure fbstring gets the same (full) specializations as std::string does in the standard. Test Plan: fbconfig -r folly && fbmake runtests_opt, also tests in tupperware/agent which is still using __gnu_cxx::hash_map with string keys. Reviewed By: pgriess@fb.com, andrei.alexandrescu@fb.com Subscribers: njormrod, jhj, kma, lesha FB internal diff: D1426479
-
Gunjan Sharma authored
Summary: When we are changing value of numActiveConsumers_ with setActive from handlerReady at the SCOPE_EXIT we have a race with reading of the same variable in putMessageImpl. Test Plan: Had a local race which works fine now. Reviewed By: davejwatson@fb.com Subscribers: trunkagent FB internal diff: D1424674
-
Tudor Bosman authored
Summary: per @rockyliu's suggestions Test Plan: subprocess_test Reviewed By: rockyliu4@fb.com Subscribers: rockyliu, jhj, lesha, kma FB internal diff: D1423157
-
Paul Tarjan authored
Summary: This reverts commit 5ea0eb0c705224b82a5c284dc5f7722e1f71199f. This breaks the HHVM clang build test. Test Plan: clang will pass now Reviewed By: smith@fb.com Subscribers: dmitrys FB internal diff: D1426399 Tasks: 4667712
-
Tyler MacDonald authored
Summary: on advice of @tudorb, move most of `folly::Formatter` into `folly::BaseFormatter` so that we can use compile-time polymorphism to provide different types of Formatters. I wasn't able to get the recursive formatter to be polymorphic -- whenever I tried to convert `class FormatValue<Formatter<containerMode, Args...>, void>` into `class FormatValue<BaseFormatter...`, `FormatTest.cpp:Test(Format, Nested)` wouldn't compile because it couldn't find the template. @tudorb, if you have an easy fix for this, lmk, otherwise I'm (reluctantly) okay with requiring that `Formatter`s define their own nesting `FormatValue`. phew. the last time I did this sort of metaprogramming was over 5 years ago in perl. Doing it in C++ is... interesting. Test Plan: `fbconfig -r thrift folly cold_storage && fbmake dbg && fbmake runtests` Reviewed By: tudorb@fb.com Subscribers: tudorb, dgp FB internal diff: D1422343 Tasks: 4624268
-
Tudor Bosman authored
Summary: Reported externally: https://github.com/facebook/folly/issues/70 https://github.com/facebook/folly/issues/71 https://github.com/facebook/folly/issues/72 https://github.com/facebook/folly/issues/73 Note that I can't test on libc++ myself, but the reports suggested fixes which sounded good. Test Plan: fbconfig -r folly && fbmake runtests_opt Reviewed By: marcelo.juchem@fb.com Subscribers: jhj, ntv, lesha, kma, fugalh, jdelong FB internal diff: D1421029
-
Tudor Bosman authored
Summary: We've wanted to use pipe2 in Subprocess for a while, but that's not supported on glibc 2.5.1. This is not a problem in OSS (autoconf can solve this), but, internally, we don't run autoconf; add an internal platform include file with such per-platform differences. Test Plan: fbconfig -r folly && fbmake runtests_opt Reviewed By: meyering@fb.com Subscribers: jhj, lesha, kma, agallagher FB internal diff: D1422128
-
Tom Jackson authored
Summary: thatwaseasy Test Plan: iloveunittests Reviewed By: lucian@fb.com Subscribers: philipp FB internal diff: D1419848 Tasks: 4636617
-
Brian Pane authored
Summary: * Moved the fast toLower code into folly * Updated the name to emphasize that it's ASCII-only Test Plan: * Unit tests and benchmarks included. Reviewed By: tudorb@fb.com Subscribers: ruibalp, bmatheny FB internal diff: D1421056
-
Hans Fugal authored
Summary: Not sure why this shadow error didn't turn up in my tests, but whatevs Test Plan: traffic manager builds without warning-errors Reviewed By: suhas@fb.com Subscribers: hannesr, net-systems@, fugalh, exa FB internal diff: D1421495 Tasks: 4653938
-
- 07 Jul, 2014 10 commits
-
-
Tudor Bosman authored
Summary: wangle/detail.h -> wangle/detail/State.h Test Plan: OSS build Reviewed By: meyering@fb.com Subscribers: fugalh, lesha FB internal diff: D1421490
-
Tudor Bosman authored
Summary: Use namespace gflags going forward, import namespace google into it if backward. Also added a few "checking for..." messages in autoconf. Test Plan: fbconfig -r folly && fbmake runtests_opt, OSS build Reviewed By: meyering@fb.com Subscribers: fjargsto, ntv, jhj, lesha, kma, davejwatson FB internal diff: D1420575
-
Hans Fugal authored
Summary: Instead of returning a Later, `via` returns a cold future. This works without keeping a backreference like Later does, because an inactive Future will always activate on destruction. Alternatively we could have an extra Promise, a la Later, and pass that along like Later does, and require launch() at the end (though, implicit launching on destruction would be an option there too). If you think this approach is viable I'll clean it up on Wednesday: make sure all the calling sites work, etc. Test Plan: new unit test This may fail in contbuild, I haven't done the codemod for calling sites, if there are any. Reviewed By: hannesr@fb.com Subscribers: jsedgwick, net-systems@, fugalh, exa FB internal diff: D1412499 Tasks: 4480567
-
Hans Fugal authored
Summary: Bring a bit more sanity to the lifetime. Now Future and Promise detach by calling the respective methods on State, and they do it during their destruction only. State manages its own lifetime. Besides being cleaner, this also sets the stage for cancellation (where we'll need Future to hang on to its reference to State after setting the callback), and for folding in Later (we will have a bool for whether the future is hot and hold off executing the callback if it isn't). Also cleans up various things I noticed while auditing the code for usages of `state_`. Test Plan: All the unit tests still pass. Ran with ASAN (and found I had introduced a bug, then fixed it. yay) Reviewed By: hannesr@fb.com Subscribers: jsedgwick, net-systems@, fugalh, exa FB internal diff: D1412038 Tasks: 4618297
-
Hannes Roth authored
Summary: Suggested by @aalexandre. Test Plan: Compile. Reviewed By: andrei.alexandrescu@fb.com Subscribers: folly@lists, njormrod, aalexandre FB internal diff: D1246180
-
Lucian Grijincu authored
Test Plan: copied from folly::json Reviewed By: philipp@fb.com, soren@fb.com FB internal diff: D1417992 Tasks: 4527315
-
Hans Fugal authored
Summary: This isn't really an internal-to-this-class method. :-/ Test Plan: builds Reviewed By: hannesr@fb.com Subscribers: jsedgwick, net-systems@, fugalh, exa FB internal diff: D1412008
-
Hans Fugal authored
Summary: In the spirit of D1406753 Test Plan: still builds and tests pass Reviewed By: hannesr@fb.com Subscribers: jsedgwick, net-systems@, fugalh, exa FB internal diff: D1412002
-
Hans Fugal authored
Summary: codemod I never was satisfied with this name. `State` feels a little better. More descriptive. But still pretty generic, so I'm open to alternative ideas. Test Plan: It still builds and tests pass. Reviewed By: hannesr@fb.com Subscribers: jsedgwick, net-systems@, fugalh, exa FB internal diff: D1411506
-
Kevin Chou authored
Summary: The bug is when ignoreEmpty is true, we use the wrong token size, which will be 0 when last token is shorter than delimiter. Test Plan: 1. Add unit test 2. fbconfig -r folly && fbmake runtests Reviewed By: philipp@fb.com Subscribers: maxime, xiaol FB internal diff: D1415803
-
- 02 Jul, 2014 1 commit
-
-
Tudor Bosman authored
Test Plan: OSS Reviewed By: lesha@fb.com FB internal diff: D1415190 @override-unit-failures
-
- 01 Jul, 2014 4 commits
-
-
Dave Watson authored
Summary: Update targets so that gtest isn't required unless you run 'make check'. Simply make everything that uses gtest a 'check_PROGRAM' instead of a 'noinst_PROGRAM' Test Plan: build folly with 'make -j32', gtest isn't required. Reviewed By: andrewjcg@fb.com Subscribers: pavlo, doug FB internal diff: D1408288
-
Tudor Bosman authored
Summary: so #include <folly/File.h> works Test Plan: built OSS folly, make check, built tiny program out of tree Reviewed By: davejwatson@fb.com FB internal diff: D1412123
-
Tudor Bosman authored
Summary: Also changed the thrift compilers to emit code with <...>. Test Plan: fbconfig -r folly thrift && fbmake opt && fbmake runtests_opt Reviewed By: davejwatson@fb.com Subscribers: ruibalp, nli, shilin, tjackson, fugalh, alandau, bmatheny, njormrod FB internal diff: D1411225
-
Philip Pronin authored
Summary: As it turns out, `io_getevents` may actually return less than `min_nr` events. According to the aio logic (https://github.com/torvalds/linux/blob/10b5b5361a3c2a7fff9dbfa0f127adc2531e7732/fs/aio.c#L1634), there may be a couple of rounds required to get at least `nr_min` events, and if interrupted after the first one, incomplete results would be returned Test Plan: fbconfig -r folly/experimental/io/test && fbmake runtests_opt -32 and was no longer able to repro #4609062 Reviewed By: soren@fb.com FB internal diff: D1410389 Tasks: 4609062
-
- 27 Jun, 2014 10 commits
-
-
Joel Marcey authored
Summary: This prevents a linker error on OSX: ``` Undefined symbols for architecture x86_64: "folly::detail::EndianIntBase::swap(unsigned long)", referenced from: __GLOBAL__sub_I_MacAddress.cpp in libfolly.a(MacAddress.cpp.o) ld: symbol(s) not found for architecture x86_64 ``` We need folly and third-party changes in order to land a pull request for HHVM that starts to get FastCGI running on OSX. See the checklist of the HHVM pull request here: https://github.com/facebook/hhvm/pull/2944#issuecomment-47281003 Closes #68 GitHub Author: Daniel Sloof <goapsychadelic@gmail.com> @override-unit-failures Test Plan: fbmake runtests 100% Reviewed By: pt@fb.com, njormrod@fb.com FB internal diff: D1407426
-
Joel Marcey authored
Summary: A recent change in folly/MemoryMapping.cpp uses MAP_ANONYMOUS, which is named MAP_ANON on OSX/BSD. We need folly and third-party changes in order to land a pull request for HHVM that starts to get FastCGI running on OSX. See the checklist of the HHVM pull request here: https://github.com/facebook/hhvm/pull/2944#issuecomment-47281003 Closes #67 GitHub Author: Daniel Sloof <goapsychadelic@gmail.com> @override-unit-failures Test Plan: fbmake runtests 100% Reviewed By: pt@fb.com, njormrod@fb.com FB internal diff: D1407393
-
Hans Fugal authored
Summary: Stroke of brilliance, Hannes. Test Plan: unit tests, including a new one Looked through `fbgs 'via('` and all the extant `via`s are attached to `Later`s already so it shouldn't break anything. But check contbuild before commit. Reviewed By: hannesr@fb.com Subscribers: net-systems@, fugalh, exa FB internal diff: D1406976 Tasks: 4480567
-
Jim Meyering authored
Summary: * folly/test/DeterministicSchedule.cpp (folly): Tao/queues tests exposed an unhandled case in this code: when (futex->data == expected) happens, we would call futexErrnoToFutexResult with a futexErrno value of 0, which would cause an abort (unhandled valued in switch). Here's a stack trace from the abort: https://phabricator.fb.com/P12558008 showing the invalid futexErrno value in frame #4. Test Plan: fbconfig -r --platform-all=gcc-4.8.1-glibc-2.17 --sanitize=address tao/queues:TimeoutWorkQueueTests _bin/tao/queues/WorkQueueTests -fbunit_test_regexp '^mt\_stress\_deterministic$' Reviewed By: mssarang@fb.com FB internal diff: D1404572 Tasks: 4494871
-
Sarang Masti authored
Summary: Handle wake-ups correctly in futexWaitUntilImpl. Test Plan: -- ran all folly unit tests -- ran TimeoutWorkQueue test under tao/queues Reviewed By: ngbronson@fb.com, meyering@fb.com FB internal diff: D1406845 Tasks: 4494871
-
Hans Fugal authored
Summary: to make lint happy Test Plan: builds Reviewed By: hannesr@fb.com Subscribers: net-systems@, fugalh, exa FB internal diff: D1406766 Tasks: 4480567
-
Hans Fugal authored
Summary: The word "continuation" is too ambiguous. Prefer callback (except where we are actually talking about CSP continuations in the README). Test Plan: Still builds. Nothing external is or should be calling `setContinuation`. But I'll wait for contbuild anyway. Reviewed By: hannesr@fb.com Subscribers: net-systems@, fugalh, exa FB internal diff: D1406753 Tasks: 4480567
-
Hans Fugal authored
Summary: Removing this crufty API. The only callsite for `executeWith` was `Later::via` so I just folded it in there. Test Plan: unit tests contbuild Reviewed By: hannesr@fb.com Subscribers: net-systems@, fugalh, exa FB internal diff: D1406592 Tasks: 4480567
-
Hans Fugal authored
Summary: I have no idea why the compiler is gettings its britches in a bunch because a unit test has a predictable output. Really, gcc?! But whatever, avoiding inlining by putting it in the cpp file solves it. Test Plan: fbmake runtests_opt Reviewed By: davejwatson@fb.com Subscribers: net-systems@, fugalh, exa FB internal diff: D1405811 Tasks: 4591823
-
Hans Fugal authored
Summary: Add the `QueuedImmediateExecutor` which behaves like `InlineExecutor` but with different (and usually better) ordering semantics for nested calls. @override-unit-failures Test Plan: unit tests Reviewed By: davejwatson@fb.com Subscribers: folly@lists, net-systems@, fugalh, exa FB internal diff: D1364904 Tasks: 3789661
-