Process Create Event

This benchmarks simulates a process create event (emitted by Windows Event Log). The idea is to see how well algorithms handle a real world scenario. The size of the event is 233 bytes (by setting up different strings and values).

#![allow(unused)]
fn main() {
pub struct ProcessCreated {
    name: String,
    pid: u32,
    parent_pid: u32,
    parent: String,
    user: String,
    command_line: String,
    timestamp: u32,
    unique_id: u32,
    memory_usage: u64,
    protected_process: bool,
}
}

Test specs

  • Iterations: k = 10
  • Serialization and deserialization repetitions / iteration: n = 100000
  • Data size: 233 bytes
  • Protobuf: Supported

Results

1. Windows Execution

AlgorithmSize (b)Ser. (ms)Deser. (ms)Ser+Deser.(ms)
FlatMessage (⚠️)298
[ +27%]
2.53
[ 2.06 - 3.01]
17.06
[ 15.59 - 23.34]
20.32
[ 18.00 - 26.85]
FlatMessage298
[ +27%]
2.75
[ 2.33 - 2.95]
20.48
[ 18.86 - 26.08]
22.84
[ 21.59 - 28.98]
bincode (schema)234
[ +0%]
3.50
[ 3.38 - 4.51]
20.86
[ 20.23 - 26.15]
26.65
[ 24.19 - 32.55]
postcard (schema)230
[ -2%]
5.39
[ 4.32 - 5.99]
23.17
[ 19.36 - 26.94]
29.71
[ 25.19 - 34.40]
rmp (schema)238
[ +2%]
4.47
[ 4.00 - 6.65]
26.44
[ 23.71 - 31.10]
30.58
[ 29.34 - 39.52]
protobuf (schema)240
[ +3%]
7.59
[ 5.62 - 8.23]
28.76
[ 24.06 - 33.60]
37.73
[ 33.30 - 44.25]
rmp334
[ +43%]
6.56
[ 5.54 - 9.08]
39.26
[ 38.51 - 49.63]
48.26
[ 47.28 - 60.12]
bson376
[ +61%]
19.40
[ 16.17 - 21.45]
67.24
[ 54.95 - 74.92]
88.09
[ 74.82 - 99.26]
cbor334
[ +43%]
16.38
[ 13.99 - 18.86]
80.14
[ 68.09 - 96.12]
98.78
[ 83.80 - 115.44]
json402
[ +72%]
29.18
[ 24.55 - 34.15]
118.07
[ 93.40 - 126.61]
156.74
[125.77 - 168.44]
simd_json402
[ +72%]
33.36
[ 26.10 - 37.58]
126.90
[108.99 - 147.91]
169.84
[144.93 - 197.78]
flexbuffers453
[ +94%]
134.07
[120.30 - 168.56]
66.81
[ 60.73 - 84.08]
215.41
[191.04 - 268.91]
toml385
[ +65%]
154.82
[129.26 - 181.64]
317.42
[271.30 - 359.40]
506.82
[442.59 - 574.69]

2. MacOs Execution

AlgorithmSize (b)Ser. (ms)Deser. (ms)Ser+Deser.(ms)
FlatMessage (⚠️)298
[ +27%]
2.45
[ 2.42 - 2.56]
9.31
[ 9.12 - 9.61]
11.86
[ 11.77 - 12.46]
FlatMessage298
[ +27%]
2.52
[ 2.44 - 2.60]
11.95
[ 11.85 - 12.48]
14.83
[ 14.49 - 15.05]
bincode (schema)234
[ +0%]
3.83
[ 3.76 - 4.02]
11.87
[ 11.79 - 12.32]
15.77
[ 15.65 - 16.19]
postcard (schema)230
[ -2%]
5.34
[ 5.31 - 5.53]
13.81
[ 13.65 - 14.43]
19.20
[ 19.12 - 20.62]
rmp (schema)238
[ +2%]
4.33
[ 4.30 - 4.81]
16.04
[ 15.89 - 18.12]
20.41
[ 20.30 - 20.86]
protobuf (schema)240
[ +3%]
6.58
[ 6.50 - 7.18]
17.12
[ 16.95 - 17.42]
23.50
[ 23.30 - 23.80]
rmp334
[ +43%]
6.40
[ 6.38 - 6.47]
27.50
[ 27.30 - 27.77]
33.84
[ 33.66 - 34.55]
bson376
[ +61%]
17.01
[ 16.91 - 17.28]
42.29
[ 42.12 - 42.55]
59.32
[ 59.06 - 59.65]
cbor334
[ +43%]
13.65
[ 13.62 - 13.70]
64.24
[ 64.04 - 64.67]
78.41
[ 78.06 - 81.76]
json402
[ +72%]
29.79
[ 29.73 - 29.90]
61.86
[ 61.52 - 62.38]
91.77
[ 91.13 - 94.74]
simd_json402
[ +72%]
30.43
[ 30.33 - 31.44]
90.45
[ 89.90 - 94.72]
124.31
[122.48 - 128.54]
flexbuffers453
[ +94%]
84.15
[ 83.71 - 85.45]
48.21
[ 47.58 - 48.85]
134.98
[134.00 - 137.54]
toml385
[ +65%]
117.64
[115.60 - 120.67]
199.51
[198.30 - 243.70]
325.06
[323.88 - 332.56]

3. Linux Execution

AlgorithmSize (b)Ser. (ms)Deser. (ms)Ser+Deser.(ms)
FlatMessage (⚠️)298
[ +27%]
1.89
[ 1.87 - 3.12]
5.94
[ 5.78 - 9.80]
8.15
[ 8.05 - 11.84]
FlatMessage298
[ +27%]
1.91
[ 1.71 - 2.48]
9.75
[ 9.28 - 13.14]
12.16
[ 11.86 - 17.74]
postcard (schema)230
[ -2%]
4.34
[ 4.20 - 4.41]
11.18
[ 10.92 - 11.34]
14.90
[ 14.70 - 15.95]
bincode (schema)234
[ +0%]
3.50
[ 3.29 - 4.77]
12.08
[ 11.61 - 20.70]
15.75
[ 15.23 - 28.67]
rmp (schema)238
[ +2%]
3.66
[ 3.54 - 5.76]
14.15
[ 13.61 - 22.21]
18.64
[ 17.89 - 29.29]
protobuf (schema)240
[ +3%]
5.17
[ 4.97 - 5.35]
15.62
[ 15.23 - 21.73]
20.84
[ 20.50 - 30.03]
rmp334
[ +43%]
4.65
[ 4.51 - 6.99]
27.44
[ 26.77 - 35.82]
33.97
[ 32.88 - 36.01]
bson376
[ +61%]
16.35
[ 16.25 - 16.51]
44.33
[ 43.72 - 47.85]
65.05
[ 64.64 - 71.13]
cbor334
[ +43%]
14.22
[ 14.00 - 14.34]
62.14
[ 61.48 - 62.66]
79.70
[ 79.01 - 81.40]
json402
[ +72%]
29.82
[ 29.49 - 31.11]
67.72
[ 66.33 - 72.12]
102.07
[100.37 - 106.50]
simd_json402
[ +72%]
26.07
[ 25.57 - 27.85]
75.24
[ 73.56 - 80.16]
110.27
[108.32 - 113.10]
flexbuffers453
[ +94%]
101.88
[ 98.59 - 132.70]
53.95
[ 53.63 - 83.60]
172.32
[168.33 - 187.01]
toml385
[ +65%]
123.92
[121.40 - 126.69]
245.35
[244.16 - 272.99]
402.49
[386.93 - 444.40]