Commit Graph

92 Commits

Author SHA1 Message Date
Alexey Rybalchenko
ac5b475a00 shm: refactor UnamangedRegion: rename fRemote to fController 2022-10-05 03:31:12 +02:00
Alexey Rybalchenko
f33599d207 shm: Improve debug output a bit 2022-10-05 03:31:12 +02:00
Alexey Rybalchenko
de09018198 Shm: fix region init with external regions 2022-09-09 15:11:12 +02:00
Alexey Rybalchenko
75e68e3e4d fix(shm): Fix incorrect parameters when mapping regions 2022-09-06 07:57:45 +02:00
Alexey Rybalchenko
4587af2eb4 fix(shm): race/deadlock in region locks 2022-08-19 12:24:35 +02:00
Alexey Rybalchenko
29827f0426 Shm: bring back thread-safety for fRegions (intra-process) 2022-02-16 23:17:04 +01:00
Alexey Rybalchenko
8efe7adf0e Shm: fix number of region events 2022-02-16 23:17:04 +01:00
Alexey Rybalchenko
1a75141fc4 shm: allow monitor::ResetContent to cleanup after a crash 2022-02-02 10:49:00 +01:00
Alexey Rybalchenko
ddf9bc7272 shm: keep mng segment around when skipping cleanup 2022-01-12 19:54:49 +01:00
Alexey Rybalchenko
f79a0714b4 shm: fix double unlock() 2022-01-12 19:54:49 +01:00
Alexey Rybalchenko
c04958e2a4 shm: reduce contention on region events 2022-01-10 19:42:08 +01:00
Alexey Rybalchenko
692576a5b1 shm: add APIs for implementing keep-alive process 2021-12-16 16:27:07 +01:00
Alexey Rybalchenko
eb4620b1ec shm: always open_or_create segment 2021-12-16 16:27:07 +01:00
Alexey Rybalchenko
08ba068791 shm: remove unused member 2021-12-16 16:27:07 +01:00
Alexey Rybalchenko
1839f7e8c0 shm: integrate mtx and cv into management segment 2021-12-16 16:27:07 +01:00
Alexey Rybalchenko
80ed45df63 extend region config 2021-12-16 16:27:07 +01:00
Alexey Rybalchenko
eef42d2dea simplify region cleanup 2021-12-16 16:27:07 +01:00
Alexey Rybalchenko
d630fbb1e4 consolidate UnmanagedRegion options 2021-12-16 16:27:07 +01:00
Alexey Rybalchenko
d7fb01908c fix(shm): fix regression in debug mode data 2021-10-08 09:42:28 +02:00
Alexey Rybalchenko
1449166d44 feat: add options to control allocation attempts 2021-10-08 09:42:28 +02:00
Alexey Rybalchenko
153dcfab94 Apply modernize-use-override 2021-09-27 12:04:07 +02:00
Alexey Rybalchenko
ad824b4de1 Define copy/move ctors and assignment ops
Delete special member functions where they are not used.
(as part of applying suggestions from cppcoreguidelines-special-member-functions)

These classes don't need to be copyable/movable:
  # copy/move not used:
  zmq:: TransportFactory, Socket, Message, UnmanagedRegion, Poller, Context
  shm:: TransportFactory, Socket, Message, UnmanagedRegion, Poller
  ofi:: TransportFactory, Socket, Message, Context
  shm:: ZMsg, Region, Monitor, TerminalConfig, Manager
  plugins:: Config, Control, TerminalConfig
  fairmq::StateQueue, StateMachine, ProgOptions, PluginServices, PluginManager, Plugin, Device, StateSubscription
  TestData, BadDevice, TestDevice (test suite heplers)

  # used via ptr interface:
  fairmq::UnmanagedRegion, TransportFactory, Socket, Poller, Message

These classes need to be movable/copyable:
 MyClass (test suite helper), fairmq::Channel, fairmq::Parts
2021-09-27 12:04:07 +02:00
Alexey Rybalchenko
597d88277b Apply clang-analyzer-optin.performance.Padding 2021-09-27 12:04:07 +02:00
Alexey Rybalchenko
e484bf4578 Shm: Fix SetUsedSize() 2021-09-20 13:29:28 +02:00
Alexey Rybalchenko
bce380d871 Implement shmem msg zero-copy 2021-09-07 20:53:16 +02:00
Alexey Rybalchenko
815b2f1d76 shm: reimplement alignment 2021-09-07 20:53:16 +02:00
Dennis Klein
1007de8e49 feat(ofi): Require asiofi 0.5
* Modernize some ofi transport code along the way
  * Replace Boost.Container with `<memory_resource>`
  * Introduce namespaced headers
    * `<fairmq/Channel.h>`
    * `<fairmq/Message.h>`
    * `<fairmq/Poller.h>`
    * `<fairmq/Socket.h>`
    * `<fairmq/TransportFactory.h>`
    * `<fairmq/UnmanagedRegion.h>`
* Compile-firewall Boost.Process in `shmem::Manager` because it conflicts
with standalone asio
2021-07-16 12:31:17 +02:00
Alexey Rybalchenko
03ba9eb558 Add --shm-zero-segment-on-creation option 2021-07-16 09:40:17 +02:00
David Rohr
a6193a380d Add --shm-mlock-segment-on-creation option 2021-07-16 09:40:17 +02:00
Alexey Rybalchenko
a8bdb91165 shm: throw TransportError if could not lock region 2021-06-15 11:54:29 +02:00
Alexey Rybalchenko
37c059177f shm: improve exception handling 2021-06-15 11:54:29 +02:00
Alexey Rybalchenko
28a887a457 shm: optimize monitor heartbeats 2021-06-15 11:54:29 +02:00
Alexey Rybalchenko
9444de5868 Apply readability-redundant-member-init 2021-05-28 13:14:51 +02:00
Alexey Rybalchenko
9bf908fb52 shm: revert some changes from c85d6e0 that introduced a race 2021-05-20 00:40:58 +02:00
Alexey Rybalchenko
091d0824d1 ofi: fix Events() signature 2021-05-07 21:33:15 +02:00
Alexey Rybalchenko
857aa84fa3 add mlock/zero options to unmanaged region 2021-05-07 21:33:15 +02:00
Alexey Rybalchenko
c85d6e079c shm: reduce shm contention when dealing with ack queues 2021-05-07 21:33:15 +02:00
Alexey Rybalchenko
b67b80e0ad shmmonitor: add severity setting 2021-05-07 21:33:15 +02:00
Alexey Rybalchenko
2c89b24857 shm: eliminate race/deadlock in region subscriptions 2021-05-07 21:33:15 +02:00
Alexey Rybalchenko
8a2641d842 shm: check result of region acquisition 2021-05-07 21:33:15 +02:00
Alexey Rybalchenko
2ca62d06db shm region cache: fix multiple sessions issue 2021-05-07 14:20:00 +02:00
Gvozden Neskovic
ef5b3c782e improve message counter cache line use 2021-05-07 14:20:00 +02:00
Gvozden Neskovic
f7ba3052aa use thread local cache to avoid interprocess lock on shm GetData 2021-05-07 14:20:00 +02:00
Alexey Rybalchenko
0976465338 shm: reduce delay between monitor daemon launch & HBs 2021-04-08 10:11:23 +02:00
Alexey Rybalchenko
9144258b89 shmmonitor: daemon output to file if FAIRMQ_SHMMONITOR_VERBOSE is true 2021-04-08 10:11:23 +02:00
Alexey Rybalchenko
72175e5757 shmmonitor: optimize startup to avoid repeated start 2021-04-08 10:11:23 +02:00
Alexey Rybalchenko
effba534f0 shmmonitor: add session name and creator id to the output 2021-04-08 10:11:23 +02:00
Alexey Rybalchenko
5228407932 shmmonitor: distinguish daemon from monitor mode (orthogonal) 2021-04-08 10:11:23 +02:00
Dennis Klein
4b6cf8b181 Fix aggregate initialization issue before C++20
Use value initialization to prevent

error: temporary of type ... has protected destructor

see https://stackoverflow.com/a/56745475
2021-03-26 10:06:10 +01:00
Alexey Rybalchenko
62438bd99e shm: Improve error message when segment cannot be opened 2021-03-18 09:02:08 +01:00