Commit Graph

7 Commits

Author SHA1 Message Date
Xavier Deguillard
be1aeaf5be utils: add default constructor to ImmediateFuture
Summary:
When a T can be default constructed, make an ImmediateFuture default
constructible.

Reviewed By: fanzeyi

Differential Revision: D28292874

fbshipit-source-id: 4c239cc9c3f448652b2bcdc103ea1a81ace46402
2021-05-11 08:05:11 -07:00
Xavier Deguillard
b7ab05edc5 utils: add an ImmediateFuture type
Summary:
In very hot code path, EdenFS is spending a very large amount of time creating
and destroying folly::Future objects. This is due to the required memory
allocation, as well as the handful of atomics that are happening at creation
time, and these are showing up in EdenFS profiles.

In the steady state, EdenFS actually doesn't need futures, as it often times is
able to service requests from its in-memory caches, in which case we should
ideally just return the value itself and not wrap it in a folly::Future. The
added ImmediateFuture is a step in this direction, as it can hold either an
immediate value, or a folly::SemiFuture, and allow the same API to be used
transparently between these 2.

Reviewed By: genevievehelsel

Differential Revision: D28006802

fbshipit-source-id: 89eaa32e7fa82c44844c4b23c4cb30dbeea46ca8
2021-05-06 10:54:03 -07:00
Chad Austin
9f651a8f28 Remove dead includes in eden
Reviewed By: simpkins

Differential Revision: D23864216

fbshipit-source-id: e1e3803ee47398639bf3cf85e3347d54ecaff424
2020-10-09 15:25:47 -07:00
Chad Austin
d0fb86a240 add 4k random writes benchmark
Summary:
To help investigate a Linux kernel performance dropoff where the
kernel falsely thinks the EdenFS FUSE mount can't handle dirty page
writes at a high rate, add a 4k random writes benchmark.

Reviewed By: simpkins

Differential Revision: D21328771

fbshipit-source-id: c9977bd2e291d01e92631094aba3d8d807ec62da
2020-07-14 16:13:37 -07:00
Chad Austin
58cf030382 prepare for unique_ptr AsyncSocket::newSocket
Summary:
AsyncSocket::newSocket will soon return a unique_ptr. In preparation,
explicitly update the call sites to move instead of copy the socket
when possible.

Reviewed By: simpkins

Differential Revision: D22402156

fbshipit-source-id: 52580826fb70fea915cf124d264bbe13bd56484e
2020-07-13 12:34:28 -07:00
Chad Austin
6185a90dc6 fix warnings on macOS
Summary: Fix a couple warnings in the macOS build.

Reviewed By: genevievehelsel

Differential Revision: D21992085

fbshipit-source-id: 578adb3b95d29177740debbce4dc4626ba9eed64
2020-06-12 10:28:28 -07:00
Chad Austin
bb7005d60e move benchmarks/ into eden/fs/
Summary: These benchmarks are edenfs-specific, so move them into /eden/fs/

Reviewed By: genevievehelsel

Differential Revision: D21314464

fbshipit-source-id: 1dcf6adfbdea1394f222de4d462397ea531ced00
2020-05-04 11:33:12 -07:00