- 05 Mar, 2015 4 commits
-
-
Sara Golemon authored
-
Ram Kumar Rengaswamy authored
Summary: generate_escape_tables.py uses python range function which does not include the end of the range. Closes #131 Test Plan: See attached test case. Reviewed By: njormrod@fb.com Subscribers: trunkagent, folly-diffs@, yfeldblum FB internal diff: D1871692 Signature: t1:1871692:1425076132:2438ab7554fe87bdef17c82ff27713811a270d7c
-
Nicholas Ormrod authored
Summary: D1845525 was missing some makefile changes. Test Plan: Examine similar change in D1732895 Reviewed By: markisaa@fb.com Subscribers: sdwilsh, folly-diffs@, yfeldblum FB internal diff: D1890197 Signature: t1:1890197:1425526255:e9a23fd96a89d4463cbdfda1385d4fd5f5781e8e
-
Hans Fugal authored
Summary: sugar providing `foo.move()` instead of `std::move(*foo)`. Test Plan: Inspection. Using it in another diff. Reviewed By: yfeldblum@fb.com, hannesr@fb.com Subscribers: trunkagent, exa, folly-diffs@, yfeldblum FB internal diff: D1882208 Signature: t1:1882208:1425331389:a9c09ad2739838c829e2afdad64e985810154226
-
- 03 Mar, 2015 36 commits
-
-
Alecs King authored
-
Subodh Iyengar authored
Summary: Add a test to check what will happen if someone tries to run a job on evb after termination. Test Plan: Unit tests Reviewed By: seanc@fb.com Subscribers: seanc, folly-diffs@, yfeldblum FB internal diff: D1882308 Signature: t1:1882308:1425333248:7ab6692eb0b866fcc9685048eb385bacd90023d1
-
Hans Fugal authored
Summary: Because why not? Test Plan: new unit tests Reviewed By: hannesr@fb.com Subscribers: trunkagent, exa, folly-diffs@, yfeldblum, marccelani FB internal diff: D1866123 Signature: t1:1866123:1425331395:742369597757456e5925af55c5d4198b607126f1
-
Sara Golemon authored
Summary: Use malloc_size() instead Test Plan: HHVM build on MacOS Reviewed By: joelm@fb.com Subscribers: trunkagent, folly-diffs@, yfeldblum FB internal diff: D1875364 Signature: t1:1875364:1425061479:7d8cec757c186fa8c30b6500fca6b2fe4c1ed137
-
Dor Gross authored
Summary: Method will only be applicable for types of the form Future<Future<T>>, calling flatten() on a Future<T> where <T> != Future<R> for any <R> will result with a compile time error. Test Plan: Added tests in FutureTest.cpp. Reviewed By: hans@fb.com Subscribers: ldbrandy, trunkagent, folly-diffs@, jsedgwick, yfeldblum, icanadi FB internal diff: D1843581 Tasks: 6166903 Signature: t1:1843581:1424399517:7146924db3c238b77dd309f1d5916e44a7e81968
-
zhaokai authored
Summary: Make it clear that the variable is const Closes #139 Test Plan: authored tested, contbuild Reviewed By: markisaa@fb.com Subscribers: folly-diffs@, yfeldblum FB internal diff: D1878361 Signature: t1:1878361:1425071448:6871577ddb34f4a8dc30ea37842f9950c3825dde
-
zhaokai authored
Summary: 1. Split the original simple test 2. Add unit test of function: get_ref_default Closes #138 Test Plan: authored tested, contbuild Reviewed By: markisaa@fb.com Subscribers: folly-diffs@, yfeldblum FB internal diff: D1878603 Signature: t1:1878603:1425073330:914a2365fa648142d11b41b387423d78e52f2e08
-
zhaokai authored
Summary: Remove one of the "one" in the comment of BENCHMARK Closes: #140 Test Plan: Inspection. Reviewed By: markisaa@fb.com Subscribers: trunkagent, folly-diffs@, yfeldblum FB internal diff: D1877997 Signature: t1:1877997:1425063475:c53c09d105809de9a9070f464fb0571a4dd1e5d1
-
Dave Watson authored
Summary: Basically a ripoff of Dave's D1483148 but with ChannelPipeline instead of rx. There's going to be a long tail of unit tests here, this is still pretty broken... Not convinced that this is the way to go but I wanted to get a feel for what it would be like to plug it into an IRL system. I think the simplicity/clarity of the handler implementations and to some extent the pipeline spec is an improvement over the rx way but I'm less sure about everything else. Test Plan: compiles and kind of works some of the time but not really Reviewed By: alandau@fb.com Subscribers: wormhole-diffs@, mcduff, hitesh, doug, yfeldblum, folly-diffs@, jsedgwick, subodh, andrewcox, njormrod, trunkagent, fugalh, alandau, bmatheny, mshneer FB internal diff: D1618704 Tasks: 5981284 Signature: t1:1618704:1424980854:83c6193b1156be2ec65cf79f9f2ad1af670da7f8
-
Monica Lee authored
Summary: Added willEqual function and wrote unit tests for it. Test Plan: fbconfig --clang folly/futures && fbmake runtests Reviewed By: hans@fb.com Subscribers: hannesr, trunkagent, folly-diffs@, jsedgwick, yfeldblum FB internal diff: D1859840 Tasks: 6166911 Signature: t1:1859840:1424967149:865ee96ab4d3f5dbf17eb371b2ac3ccb5066ac87
-
Nathan Bronson authored
Summary: This diff gives IndexedMemPool<T> emplace-like semantics when T is not trivial. Test Plan: 1. new unit tests 2. LifoSem benchmark Reviewed By: march@fb.com Subscribers: folly-diffs@, yfeldblum FB internal diff: D1874941 Signature: t1:1874941:1424987308:61bbe7b7e5e6df625a6208cd873c65e523a79fa0
-
Nicholas Ormrod authored
Summary: Update copyright notices in folly to 2015 find folly/ -type f | xargs sed -i 's/Copyright 2014 Facebook, Inc./Copyright 2015 Facebook, Inc./g'find . -type f | xargs sed -i 's/Copyright 2014 Facebook, Inc./Copyright 2015 Facebook, Inc./g' Test Plan: fbconfig -r folly && fbmake runtests Reviewed By: markisaa@fb.com Subscribers: ldbrandy, shilin, sdwilsh, fugalh, njormrod, folly-diffs@, jsedgwick, yfeldblum FB internal diff: D1869183 Signature: t1:1869183:1424823514:a2dd33741a86bf099d5c9e3d8702e6cca6dd672f
-
Haim Grosman authored
Summary: EventBase::runAfterDelay to throw an exception in case it fails to schedule a proper execution of the given callback (instead of silently returning false) it appears to be the right thing to do, since: @davejwatson: Digging through the layers of code, it appears this can only fail if epoll_ctl() with EPOLL_CTL_ADD fails. Ignoring libevent bugs, it looks like the only relevant errors could be ENOMEM or ENOSPC. So nonrecoverable Test Plan: Unit tests Reviewed By: anca@fb.com Subscribers: yzhan, haijunz, simpkins, net-systems@, varunk, zeus-diffs@, nli, dfechete, fugalh, atlas2-eng@, alandau, bmatheny, everstore-dev@, zhuohuang, wormhole-diffs@, anca, mwa, jgehring, oujin, alikhtarov, fuegen, mshneer, wch, bil, sanketh, zippydb, maxwellsayles, jsedgwick, trunkagent, fbcode-common-diffs@, chaoyc, search-fbcode-diffs@, andrewcox, unicorn-diffs@, tw-eng@, xie, kennyyu, yfeldblum, folly-diffs@, davejwatson FB internal diff: D1805125 Signature: t1:1805125:1424927912:8bebb4c3b9f1fa189c0ce97b12cdb8f95dba97ae
-
John Ehrhardt authored
Summary: Updating Folly Formatting's use of separators for Decimal Integers 'd' and Numbers 'n'. Updated Decimal Integers 'd' use of separators to directly use commas ',' and grouping of 3 digits. Updated Numbers use of separators and grouping to follow locale settings. Test Plan: Wrote unit tests to validate the insertion of thousandsSeparators works. Note that the numbers unit test does not modify the locale since the test cases are not thread safe. Reviewed By: lesha@fb.com Subscribers: tudorb, trunkagent, folly-diffs@, yfeldblum, aric FB internal diff: D1821156 Tasks: 6087521 Signature: t1:1821156:1424923837:d0fb383a07fd733375b72b1905e6112afa141265
-
Sean Cannella authored
Summary: Manual inspection of AsyncSocket.o shows the constructors are generating ugly (and large) code. Call the smaller constructors instead of duplicating the code. This reduces the debug .o size from ~1.9MB to ~1.6MB. Test Plan: existing tests Reviewed By: benyluo@fb.com Subscribers: mzlee, folly-diffs@, yfeldblum, mathieubaudet, subodh, pgriess, benyluo FB internal diff: D1870896 Signature: t1:1870896:1424885638:d37fc79c0f88d04109c8bb73e632dc506b9f773b
-
Hans Fugal authored
Summary: Unconditionally execute the action, passthrough semantics. Test Plan: new unit test Reviewed By: bmatheny@fb.com Subscribers: trunkagent, exa, folly-diffs@, yfeldblum, jsedgwick FB internal diff: D1868837 Tasks: 6166860 Signature: t1:1868837:1424820181:0e83f54b59d7091dac60ab65feb387992e8ae89c
-
Sven Over authored
Summary: writeFull() returns ssize_t and without proper casting, comparing it with data.size() triggers a compiler warning (which is treated as an error) in the gcc-4.9-glibc-2.20 toolchain. Test Plan: fbmake runtests Reviewed By: mhx@fb.com Subscribers: folly-diffs@, yfeldblum FB internal diff: D1870710 Signature: t1:1870710:1424874592:f51026c35196d763ad4b192d43c8ccee0255b41d
-
Nicholas Ormrod authored
Summary: See the github pull request at https://github.com/facebook/folly/issues/135 Important optimizations: remove one of the branches and change ##empty()## to ##capacity()==0## Test Plan: Ran extended fbvector test suite (re-enabled in experimental/njormrod) Also fbconfig -r folly && fbmake runtests Reviewed By: markisaa@fb.com Subscribers: trunkagent, sdwilsh, njormrod, folly-diffs@, yfeldblum FB internal diff: D1869112 Tasks: 6338531 Signature: t1:1869112:1424823901:d2d7331aef82edad1e8c159005cc1c7185550d0c
-
Andrei Alexandrescu authored
Summary: Funnily, google::setThreadName is Facebook specific: it's introduced only in the FB build of glog. This diff removes the call because folly should not depend on FB's glog. Test Plan: made sure the line was deleted Reviewed By: ldbrandy@fb.com Subscribers: net-systems@, folly-diffs@, yfeldblum FB internal diff: D1868249 Tasks: 6345935 Signature: t1:1868249:1424812595:2a084754d614ab9b7b6168454f33638882e3f6db
-
Praveen Kumar authored
Summary: EmulatedFutexAtomic concisely says here that it doesn't copy construct, move construct, copy assign, or move assign. Closes #130 Test Plan: Inspection and all unit tests. ``` Summary (total time 66.97s): PASS: 2029 FAIL: 0 SKIP: 0 FATAL: 0 TIMEOUT: 0 ``` Reviewed By: ngbronson@fb.com Subscribers: folly-diffs@, yfeldblum FB internal diff: D1868033 Signature: t1:1868033:1424808823:d9dd618981b29b5949c00190d69d670d96e60e07
-
Beny Luo authored
Summary: encodeVarintToIOBuf and decodeVarintFromCursor are not used when FOLLY_HAVE_LIBLZMA and FOLLY_HAVE_LIBLZ4 are false, which will trigger -Werror,-Wunused-function on compile on mobile. Test Plan: unit test Reviewed By: seanc@fb.com Subscribers: meisner, trunkagent, seanc, folly-diffs@, yfeldblum FB internal diff: D1864016 Signature: t1:1864016:1424702813:75535ea92ac16385ce5c272d93bba507ccbb67a1
-
Andrii Grynenko authored
Summary: Previously leak-fatal could never happen because we were incorrectly checking singleton state. Sending this diff to see how many tests will actually fail and potentially fix worst offenders. Test Plan: unit tests Reviewed By: stepan@fb.com Subscribers: trunkagent, folly-diffs@, yfeldblum FB internal diff: D1838405 Signature: t1:1838405:1424478983:94cda86ed57f38b0cf626b74804fbc168d182c66
-
Andre Pinto authored
Summary: Add option to disable time measurement in EventBase::loopBody() to improve performances when time measurement is not used. Test Plan: Unit tests, benchmarking and manual tests. Reviewed By: pavlo@fb.com Subscribers: trunkagent, folly-diffs@, yfeldblum FB internal diff: D1846020 Tasks: 6086197 Signature: t1:1846020:1424459703:9686a84027e1137ee43eb0458b0baa4fee3a8abf
-
Andrey Goder authored
Summary: This 'moves' bistro::AutoTimer into folly. I actually changed it a bit, so I'm not migrating any existing uses in this diff, but I can do that as a followup. We're using it in various places now, so it doesn't make sense to have it in bistro. Basically this class lets you conveniently time a series of things while printing log messages, e.g.: { AutoTimer t("Done"); processA(); t.log("processA() complete"); } would print "processA() complete in XXX seconds" "Done in YYY seconds" I changed some things from bistro::AutoTimer: - Use std::chrono::time_point<Clock> to store the start time. - I removed the gflags. It seems weird to rely on those to control the timer, since they would affect all uses of this. If a specific user of the timer wants to actually control timing at runtime, I think it's better to use a custom logger. - I removed the 'min log duration'. As implemented it actually made the constructor conflict: AutoTimer("foo", 1.2) is ambiguous. Also, it should probably be set on the logger, so this likewise feels like a place where you could make a custom logger. I'm not sure that the way I use the default logger as a template argument is best, so please suggest improvements to that. Test Plan: unit test Reviewed By: lesha@fb.com Subscribers: trunkagent, folly-diffs@, yfeldblum FB internal diff: D1860794 Signature: t1:1860794:1424458219:a2dd0d428aedf063a888b2937b1443c7142554e8
-
Hans Fugal authored
Summary: I thought this was a race, but I think now it was something to do with using a value that had been moved out or something. Anyway, this refactor is cleaner and consolidates a few methods so it's all kinds of fuzzy feelings. Test Plan: unit tests Reviewed By: hannesr@fb.com Subscribers: exa, folly-diffs@, yfeldblum, jsedgwick FB internal diff: D1861376 Tasks: 6298004 Signature: t1:1861376:1424465861:736353ab3174656fec9e036e0ebd964970da38d0
-
Ranjeeth Dasineni authored
Summary: a couple of files were catching this exception and included the .cpp file :O. So we moved to .h before realizing this was not intended to be caught. reverting the move to .h. codemod will follow. Test Plan: fbmake -r folly && fbmake && fbmake runtests Reviewed By: delong.j@fb.com Subscribers: trunkagent, doug, seanc, folly-diffs@, yfeldblum FB internal diff: D1854301 Tasks: 6245781 Signature: t1:1854301:1424375745:7e226196315fac99835752896cc5e549e91df2da
-
Hans Fugal authored
Summary: Instead of returning a deactivated future, have `via` just set the executor. Propagate the executor from `then`. This fixes the `via().get()` problem, and has semantics similar to before for `via().then().then()`. However, the semantics are now slightly different - each `then` goes back through the executor. This adds some overhead and tweaks the semantics (e.g. if the executor is a threadpool it might execute subsequent `then`s in another thread). However, with `futures::chain` recently introduced, and any other convenience methods that you can dream up and make a case for, we can reasonably get the old once-through-the-executor behavior when performance or other concerns demand it. e.g. `via().then(futures::chain(a, b, c))`. Test Plan: unit tests Reviewed By: hannesr@fb.com Subscribers: zeus-diffs@, mmandal, steveo, rituraj, trunkagent, exa, folly-diffs@, yfeldblum, jsedgwick, davejwatson FB internal diff: D1839691 Tasks: 6048744 Signature: t1:1839691:1424397180:ca0b0ea7b3867769ab8abd254a510059df67011e
-
Hannes Roth authored
Summary: This reverts commit 1e407b48d379a41f32e7a980285dbdf4dadb2e33. Test Plan: revert-hammer Reviewed By: yitingli@fb.com Subscribers: folly-diffs@, jsedgwick, yfeldblum FB internal diff: D1858994 Signature: t1:1858994:1424386588:5c4608ecbe1f9ab1108ac12e506b157b54d0078b
-
Hannes Roth authored
Summary: These were doing more assignments than necessary. 1) We don't need to set `core_` to `nullptr` and then immediately overwrite it with `other.core_`. 2) Don't need to swap the booleans (this was actually an unitialized memory access). Test Plan: Ran all the tests. Reviewed By: hans@fb.com Subscribers: trunkagent, folly-diffs@, jsedgwick, yfeldblum FB internal diff: D1852386 Signature: t1:1852386:1424375154:25997209e76ccd16169125597e868932a5143ffb
-
Michael Lee authored
Summary: This diff should let us include folly/io:compression into iOS and Android projects without pulling in a lot of dependencies and should allow the use of zlib. Test Plan: fbconfig -r folly/io/tests && fbmake runtests Reviewed By: seanc@fb.com Subscribers: trunkagent, bmatheny, folly-diffs@, yfeldblum, seanc, benyluo FB internal diff: D1853058 Tasks: 6245912 Signature: t1:1853058:1424370881:2ea243d93e6041502e5e356fa430c2483f652b40
-
Dave Watson authored
Summary: Use server bootstrap. * code reuse * Allows multiple accept threads easily. Accept now doesn't happen in the server's eventBase, but a new thread. I think I hit all the corner cases involving existingSocket, duplex, stopListening(), etc. There are a lot of minor changes here to support all the cases, let me know if I should split anything to separate diffs Test Plan: fbconfig -r thrift/lib/cpp2; fbmake runtests Reviewed By: hans@fb.com Subscribers: haijunz, yfeldblum, ruibalp, fbcode-common-diffs@, davejwatson, jsedgwick, trunkagent, doug, alandau, bmatheny, mshneer, folly-diffs@, mcduff, andrewcox, fugalh FB internal diff: D1732895 Tasks: 5788102 Signature: t1:1732895:1423087631:379bbb131c35ce2221801bc7cec226f87ba0b1d9
-
Dave Watson authored
Summary: from discussion Test Plan: unit tests Reviewed By: hans@fb.com Subscribers: doug, folly-diffs@, jsedgwick, yfeldblum FB internal diff: D1829282 Signature: t1:1829282:1423180907:3630dac1378750b05f316c672fbbd71138d2bc0a
-
Dave Watson authored
Summary: They are functionaly equivalent, no need to have more than one Test Plan: fbconfig -r realtime/voip; fbmake runtests Reviewed By: naizhi@fb.com Subscribers: trunkagent, doug, ps, bmatheny, folly-diffs@, yfeldblum FB internal diff: D1828044 Tasks: 6154007 Signature: t1:1828044:1423165354:f71d2fd28ca76a8f67a597c747f8578d2909823c
-
Andrii Grynenko authored
Summary: After D1827390 regular get and get_weak is comparable to Meyers and static singletons, so there's no need to keey _fast APIs. Test Plan: benchmark && fbmake Reviewed By: mshneer@fb.com Subscribers: trunkagent, configerator-diffs@, fbcode-common-diffs@, mcduff, hitesh, mshneer, fugalh, acampi, alikhtarov, folly-diffs@, jsedgwick, yfeldblum FB internal diff: D1843219 Signature: t1:1843219:1424216566:f2f182a1c86bb5f0fb1f978d8c6b7a4388198f5f
-
Andrei Alexandrescu authored
Summary: This are the open-source-related additions. A separate diff will replace the current implementation in common/concurrency/ to use this one. Test Plan: fbmake runtests Reviewed By: simpkins@fb.com Subscribers: trunkagent, net-systems@, folly-diffs@, yfeldblum FB internal diff: D1845525 Signature: t1:1845525:1424207291:d30e3c5e85222527c2aff39c1250aa1e41b9a2cf
-
Sara Golemon authored
Summary: The continuation at the end of the line with the while was causing gcc to complain about it because it's a single line comment. Reformat it into a multiline comment and wrap it to 80 chars. Test Plan: It's just a comment... Reviewed By: paulbiss@fb.com Subscribers: trunkagent, folly-diffs@, yfeldblum FB internal diff: D1850876 Signature: t1:1850876:1424124973:b2afbc2a8177ac6d11a21bf5a52093bcfd9cbb3e
-