1
0
mirror of https://github.com/samba-team/samba.git synced 2025-01-07 17:18:11 +03:00
Commit Graph

123 Commits

Author SHA1 Message Date
Stefan Metzmacher
9d9f945281 tsocket: use the correct 'ret' variable for tdgram_disconnect_send/recv()
metze
2009-04-06 15:49:08 +02:00
Stefan Metzmacher
3bbad34a02 tsocket: remove DGRAM support from tsocket_context
metze
2009-04-02 21:54:08 +02:00
Stefan Metzmacher
c59ee5a139 tsocket: optimize tdgram_bsd a lot
The desire is to do as less syscalls during the
tdgram_sendto_send/recv() and tdgram_recvfrom_send/recv()
operations.

1. we first try the sendto()/recvfrom() syscall and
   only use a fd event if we got EAGAIN.

2. we cache the fd event and only change it's flags
   if really needed.

For the highload case we do almost no epoll_ctl() and epoll_wait()/select()
syscalls anymore. This speeds up the LDAP-BENCH-CLDAP test
by more than 20%. (With a modified version of this test
which let the server skip any ldb calls and just return success
I'm getting about 8000 requests per second, while I'm getting
just about 6000 requests per second without optimization)

metze
2009-04-02 21:54:00 +02:00
Stefan Metzmacher
85742dbc06 tsocket: add tdgram_sendto_queue_send/recv()
metze
2009-04-02 21:53:59 +02:00
Stefan Metzmacher
8d98070a9f tsocket: split out a smaller tdgram_context abstraction
The idea is to have a tdgram and a tstream abstraction
which only provide tevent_req based io functions.

metze
2009-04-02 21:53:03 +02:00
Stefan Metzmacher
c200e8632f tsocket: try to fix the build on solaris FIONREAD was missing
metze
2009-03-31 20:33:33 +02:00
Stefan Metzmacher
23bb1eedf6 tsocket: more s/sun/un to make the build on solaris happy
metze
2009-03-28 23:50:56 +01:00
Stefan Metzmacher
cacfae159f tsocket: try to fix the build on solaris systems
It seems that 'sun' is somewhere defined and we can
use it as name for variables or struct/union members.

metze
2009-03-27 11:40:36 +01:00
Stefan Metzmacher
4e18c24e2e lib/tsocket: add tsocket_guide.txt section with specific details about bsd style sockets
metze
2009-03-19 16:25:58 +01:00
Stefan Metzmacher
f6efec5dd4 lib/tsocket: add a fast path to tsocket_writev_send/recv()
This is similar to the tsocket_sendto_send/recv() fast path.

metze
2009-03-19 16:25:57 +01:00
Stefan Metzmacher
b900e92425 lib/tsocket: add a fast path to tsocket_sendto_send/recv()
By first trying to send data without waiting for the socket
to become writeable we gain about 10-20% performance in the
LDAP-BENCH-CLDAP test.

metze
2009-03-19 16:25:57 +01:00
Stefan Metzmacher
235a7a420b lib/tsocket: add tsocket_guide.txt section about the async _send/recv() helper functions
metze
2009-03-19 16:25:56 +01:00
Stefan Metzmacher
a27c6eb8e2 lib/tsocket: add tsocket_readv_send/recv()
metze
2009-03-19 16:25:56 +01:00
Stefan Metzmacher
6c8bd1005d lib/tsocket: add tsocket_writev_queue_send/recv()
metze
2009-03-19 16:25:55 +01:00
Stefan Metzmacher
2e44ceaea8 lib/tsocket: add tsocket_writev_send/recv()
metze
2009-03-19 16:25:55 +01:00
Stefan Metzmacher
a140823cc9 lib/tsocket: add tsocket_connect_send/recv()
metze
2009-03-19 16:25:54 +01:00
Stefan Metzmacher
4002b7bdc1 lib/tsocket: add tsocket_sendto_queue_send/recv()
metze
2009-03-19 16:25:54 +01:00
Stefan Metzmacher
9ed7a45c88 lib/tsocket: add tsocket_sendto_send/recv()
metze
2009-03-19 16:25:54 +01:00
Stefan Metzmacher
ccfd6a6e39 lib/tsocket: add tsocket_recvfrom_send/recv()
metze
2009-03-19 16:25:53 +01:00
Stefan Metzmacher
6c88d61bdd lib/tsocket: add an implementation for bsd style sockets.
metze
2009-03-19 16:25:53 +01:00
Stefan Metzmacher
c00126e609 lib/tsocket: add a tsocket_guide.txt with a description of the design
metze
2009-03-19 16:25:52 +01:00
Stefan Metzmacher
d848d517b5 lib/tsocket: add some useful helper functions
metze
2009-03-19 16:20:22 +01:00
Stefan Metzmacher
2e0e416676 lib/tsocket: add generic socket abstraction layer
This will replace source4/lib/socket/.

metze
2009-03-19 15:01:12 +01:00