Commit Graph

4676 Commits

Author SHA1 Message Date
Bartosz Taudul
f29669152e Handle closed socket on win32. 2017-09-15 21:43:57 +02:00
Bartosz Taudul
a2fa319a42 Allow connecting to remote client. 2017-09-15 21:37:28 +02:00
Bartosz Taudul
1955d50ff8 Standalone tracy server skeleton.
Copy pasta of imgui opengl3 example.
2017-09-15 21:25:47 +02:00
Bartosz Taudul
01f63c8d7c Can't declare variable after goto. 2017-09-15 21:09:19 +02:00
Bartosz Taudul
19f67504b1 Throughput data is not related to event data. 2017-09-15 20:31:59 +02:00
Bartosz Taudul
2947fb6563 Initialize allocated memory. 2017-09-15 20:24:15 +02:00
Bartosz Taudul
b4faa0a9b9 Use small vector. 2017-09-15 20:17:39 +02:00
Bartosz Taudul
6b589e9479 Add small vector implementation.
Not used at the moment.
2017-09-15 20:17:02 +02:00
Bartosz Taudul
1c56347f1d Use slab allocator to store event data. 2017-09-15 19:56:55 +02:00
Bartosz Taudul
de0b50aef9 Add shortcut for allocation of a type. 2017-09-15 19:54:43 +02:00
Bartosz Taudul
47f6c8d06b Add slab allocator. 2017-09-15 19:41:09 +02:00
Bartosz Taudul
7bd3ce319f Add proper locking. 2017-09-15 02:33:49 +02:00
Bartosz Taudul
74f692c254 Display throughput plot. 2017-09-15 02:30:22 +02:00
Bartosz Taudul
d7c09605d6 Collect throughput statistics. 2017-09-15 02:29:48 +02:00
Bartosz Taudul
c1a90f2b0f Add imgui 1.51. 2017-09-14 22:08:15 +02:00
Bartosz Taudul
0220907a14 Timeline construction sketches. 2017-09-14 21:28:40 +02:00
Bartosz Taudul
c0dd0ef5bc Dispatch new zone, update zone events. 2017-09-14 21:05:01 +02:00
Bartosz Taudul
e3edd7e336 Explicit zone index. 2017-09-14 21:04:35 +02:00
Bartosz Taudul
e8989d955c Handle incoming strings. 2017-09-14 19:44:49 +02:00
Bartosz Taudul
bbbf52eafd String adding functionality. 2017-09-14 19:43:40 +02:00
Bartosz Taudul
ff07576d96 Reply to string requests. 2017-09-14 19:25:16 +02:00
Bartosz Taudul
f61f50385d Add ability to send strings over network. 2017-09-14 19:24:35 +02:00
Bartosz Taudul
f3ce055568 Mirror TracyView::ShouldExit in TracyProfiler. 2017-09-14 19:23:50 +02:00
Bartosz Taudul
2442c8fe58 Use one flag to control whether LZ4 is enabled. 2017-09-14 19:09:14 +02:00
Bartosz Taudul
76df000467 Move sending data to a separate function. 2017-09-14 19:07:56 +02:00
Bartosz Taudul
cd9218e952 Check string availability. 2017-09-14 02:16:51 +02:00
Bartosz Taudul
b9c76f3452 Make View socket available to every method in class. 2017-09-14 02:15:04 +02:00
Bartosz Taudul
ef7dca9073 Init winsock at application init, not on first socket use. 2017-09-14 02:13:45 +02:00
Bartosz Taudul
a159b70d40 Reconstruct event data. 2017-09-14 02:00:13 +02:00
Bartosz Taudul
b1fcf88cf4 Implement checking if there's data to read on the socket. 2017-09-14 01:14:40 +02:00
Bartosz Taudul
d999f35dfa Exchange time and id in queue header and data structs. 2017-09-14 01:14:40 +02:00
Bartosz Taudul
3e1b736b34 Use better variable name. 2017-09-14 01:06:40 +02:00
Bartosz Taudul
10b88754d8 Allow direct access to data size table index. 2017-09-14 01:05:08 +02:00
Bartosz Taudul
89dd244693 Read QueueItems from network. 2017-09-13 23:40:28 +02:00
Bartosz Taudul
52d24d0d4c s_instance ptr may be accessed by thread. 2017-09-13 23:36:40 +02:00
Bartosz Taudul
037a4d7fac Handle connection closed/no data in Socket::Read(). 2017-09-13 23:27:17 +02:00
Bartosz Taudul
efd66bb609 Allow changing lz4 size type. 2017-09-13 23:27:17 +02:00
Bartosz Taudul
16dd561029 Move protocol specific sizes to common header. 2017-09-13 22:56:55 +02:00
Bartosz Taudul
a31ab6a256 Move TracyQueue.hpp to common. 2017-09-13 22:56:08 +02:00
Bartosz Taudul
f0d76af15c Use proper function to read data from socket. 2017-09-13 02:08:35 +02:00
Bartosz Taudul
3dd744019a Socket read loop. 2017-09-13 02:08:30 +02:00
Bartosz Taudul
407a256e68 Make sure data is actually received. 2017-09-13 02:00:22 +02:00
Bartosz Taudul
afde32549d Basic receive loop. 2017-09-13 01:54:22 +02:00
Bartosz Taudul
365f2cde23 Use select in Recv(). 2017-09-13 01:53:47 +02:00
Bartosz Taudul
953e9c6206 View server skeleton. 2017-09-13 01:33:50 +02:00
Bartosz Taudul
45646c4f45 Move TracySystem to a common directory. 2017-09-13 01:32:11 +02:00
Bartosz Taudul
997f0c64c3 Store pointers as uint64.
Pointers can't be stored as pointers, as that would cause mismatch in
wire protocol between 32 and 64 bit builds.
2017-09-13 01:24:42 +02:00
Bartosz Taudul
e8d64de5c1 Disable LZ4 in debug builds (too slow). 2017-09-12 02:20:05 +02:00
Bartosz Taudul
1ea61c2f2c Use LZ4 to compress network data.
This greatly reduces required network bandwidth, which in effect speeds
up queue processing.

Time to process a single event queue item:

      | Raw data | With LZ4 |
------+----------+----------+
Deque |  6.86 ns |   6.7 ns |
Pack  |  4.03 ns |   4.0 ns |
LZ4   |  ---     |  21.6 ns |
Send  | 214.5 ns |   5.2 ns |
------+----------+----------+
Total | 225.4 ns | 37.58 ns |
2017-09-12 02:13:22 +02:00
Bartosz Taudul
5c2cb6098d Move lz4 to tracy namespace. 2017-09-12 01:30:29 +02:00