Summary of changes
This PR makes sure that combined conditional expression win't throw exceotion when one of the operands is not a boolean.
Implementation details
We are checking for undifined expression only for the right operand.
We need to make sure that both operands treated as booleans.
Test coverage
All existing EL tests.
Datadog Report
Branch report: dudik/el/undefined-value-guard
Commit report: 44d37d6
Test service: dd-trace-dotnet
:white_check_mark: 0 Failed, 56 Passed, 0 Skipped, 33m 46.39s Total Time
Benchmarks
Benchmarks Report for benchmark platform :snail:
Benchmarks for #7008 compared to master:
- 3 benchmarks are faster, with geometric mean 1.438
- 4 benchmarks have fewer allocations
- 5 benchmarks have more allocations
The following thresholds were used for comparing the benchmark speeds:
- Mann–Whitney U test with statistical test for significance of 5%
- Only results indicating a difference greater than 10% and 0.3 ns are considered.
Allocation changes below 0.5% are ignored.
Benchmark details
Benchmarks.Trace.ActivityBenchmark - Same speed :heavy_check_mark: More allocations :warning:
More allocations :warning: in #7008
| Benchmark |
Base Allocated |
Diff Allocated |
Change |
Change % |
| Benchmarks.Trace.ActivityBenchmark.StartStopWithChild‑netcoreapp3.1 |
5.69 KB |
5.72 KB |
38 B |
0.67% |
Raw results
| Branch |
Method |
Toolchain |
Mean |
StdError |
StdDev |
Gen 0 |
Gen 1 |
Gen 2 |
Allocated |
| master |
StartStopWithChild |
net6.0 |
10.5μs |
58.5ns |
361ns |
0 |
0 |
0 |
5.51 KB |
| master |
StartStopWithChild |
netcoreapp3.1 |
14μs |
70.9ns |
333ns |
0 |
0 |
0 |
5.69 KB |
| master |
StartStopWithChild |
net472 |
22.1μs |
119ns |
676ns |
0.952 |
0.212 |
0 |
6.11 KB |
| #7008 |
StartStopWithChild |
net6.0 |
10.4μs |
55.4ns |
298ns |
0 |
0 |
0 |
5.52 KB |
| #7008 |
StartStopWithChild |
netcoreapp3.1 |
13.5μs |
70.2ns |
329ns |
0 |
0 |
0 |
5.72 KB |
| #7008 |
StartStopWithChild |
net472 |
21.8μs |
108ns |
698ns |
0.879 |
0.22 |
0 |
6.11 KB |
Benchmarks.Trace.AgentWriterBenchmark - Same speed :heavy_check_mark: Same allocations :heavy_check_mark:
Raw results
| Branch |
Method |
Toolchain |
Mean |
StdError |
StdDev |
Gen 0 |
Gen 1 |
Gen 2 |
Allocated |
| master |
WriteAndFlushEnrichedTraces |
net6.0 |
927μs |
173ns |
624ns |
0 |
0 |
0 |
2.7 KB |
| master |
WriteAndFlushEnrichedTraces |
netcoreapp3.1 |
1.05ms |
599ns |
2.32μs |
0 |
0 |
0 |
2.7 KB |
| master |
WriteAndFlushEnrichedTraces |
net472 |
1.18ms |
71.7ns |
268ns |
0 |
0 |
0 |
3.31 KB |
| #7008 |
WriteAndFlushEnrichedTraces |
net6.0 |
932μs |
54.4ns |
196ns |
0 |
0 |
0 |
2.7 KB |
| #7008 |
WriteAndFlushEnrichedTraces |
netcoreapp3.1 |
1.03ms |
124ns |
446ns |
0 |
0 |
0 |
2.7 KB |
| #7008 |
WriteAndFlushEnrichedTraces |
net472 |
1.18ms |
751ns |
2.91μs |
0 |
0 |
0 |
3.31 KB |
Benchmarks.Trace.Asm.AppSecBodyBenchmark - Same speed :heavy_check_mark: Same allocations :heavy_check_mark:
Raw results
| Branch |
Method |
Toolchain |
Mean |
StdError |
StdDev |
Gen 0 |
Gen 1 |
Gen 2 |
Allocated |
| master |
AllCycleSimpleBody |
net6.0 |
345μs |
1.64μs |
6.75μs |
0 |
0 |
0 |
178.25 KB |
| master |
AllCycleSimpleBody |
netcoreapp3.1 |
505μs |
1.46μs |
5.66μs |
0 |
0 |
0 |
184.01 KB |
| master |
AllCycleSimpleBody |
net472 |
462μs |
84ns |
314ns |
31.2 |
0 |
0 |
203.96 KB |
| master |
AllCycleMoreComplexBody |
net6.0 |
353μs |
1.01μs |
3.76μs |
0 |
0 |
0 |
181.77 KB |
| master |
AllCycleMoreComplexBody |
netcoreapp3.1 |
502μs |
1.71μs |
6.61μs |
0 |
0 |
0 |
187.44 KB |
| master |
AllCycleMoreComplexBody |
net472 |
472μs |
97.3ns |
351ns |
32.4 |
0 |
0 |
207.5 KB |
| master |
ObjectExtractorSimpleBody |
net6.0 |
325ns |
0.203ns |
0.784ns |
0 |
0 |
0 |
280 B |
| master |
ObjectExtractorSimpleBody |
netcoreapp3.1 |
388ns |
2.21ns |
15.2ns |
0 |
0 |
0 |
272 B |
| master |
ObjectExtractorSimpleBody |
net472 |
308ns |
0.0144ns |
0.05ns |
0.0445 |
0 |
0 |
281 B |
| master |
ObjectExtractorMoreComplexBody |
net6.0 |
6.39μs |
31.1ns |
136ns |
0 |
0 |
0 |
3.78 KB |
| master |
ObjectExtractorMoreComplexBody |
netcoreapp3.1 |
7.77μs |
35.6ns |
138ns |
0 |
0 |
0 |
3.69 KB |
| master |
ObjectExtractorMoreComplexBody |
net472 |
6.75μs |
1.81ns |
6.79ns |
0.573 |
0 |
0 |
3.8 KB |
| #7008 |
AllCycleSimpleBody |
net6.0 |
341μs |
1.75μs |
7.82μs |
0 |
0 |
0 |
178.25 KB |
| #7008 |
AllCycleSimpleBody |
netcoreapp3.1 |
496μs |
1.8μs |
6.97μs |
0 |
0 |
0 |
184.01 KB |
| #7008 |
AllCycleSimpleBody |
net472 |
460μs |
116ns |
416ns |
31.2 |
0 |
0 |
203.96 KB |
| #7008 |
AllCycleMoreComplexBody |
net6.0 |
356μs |
954ns |
3.57μs |
0 |
0 |
0 |
181.77 KB |
| #7008 |
AllCycleMoreComplexBody |
netcoreapp3.1 |
526μs |
1.85μs |
7.17μs |
0 |
0 |
0 |
187.44 KB |
| #7008 |
AllCycleMoreComplexBody |
net472 |
473μs |
116ns |
448ns |
32.4 |
0 |
0 |
207.5 KB |
| #7008 |
ObjectExtractorSimpleBody |
net6.0 |
323ns |
1.16ns |
4.5ns |
0 |
0 |
0 |
280 B |
| #7008 |
ObjectExtractorSimpleBody |
netcoreapp3.1 |
394ns |
2.21ns |
14.1ns |
0 |
0 |
0 |
272 B |
| #7008 |
ObjectExtractorSimpleBody |
net472 |
300ns |
0.0209ns |
0.0808ns |
0.0434 |
0 |
0 |
281 B |
| #7008 |
ObjectExtractorMoreComplexBody |
net6.0 |
6.31μs |
28.9ns |
112ns |
0 |
0 |
0 |
3.78 KB |
| #7008 |
ObjectExtractorMoreComplexBody |
netcoreapp3.1 |
7.86μs |
31.8ns |
123ns |
0 |
0 |
0 |
3.69 KB |
| #7008 |
ObjectExtractorMoreComplexBody |
net472 |
6.62μs |
2.13ns |
7.99ns |
0.597 |
0 |
0 |
3.8 KB |
Benchmarks.Trace.Asm.AppSecEncoderBenchmark - Same speed :heavy_check_mark: Same allocations :heavy_check_mark:
Raw results
| Branch |
Method |
Toolchain |
Mean |
StdError |
StdDev |
Gen 0 |
Gen 1 |
Gen 2 |
Allocated |
| master |
EncodeArgs |
net6.0 |
78.7μs |
87.4ns |
327ns |
0 |
0 |
0 |
32.4 KB |
| master |
EncodeArgs |
netcoreapp3.1 |
98.3μs |
231ns |
896ns |
0 |
0 |
0 |
32.4 KB |
| master |
EncodeArgs |
net472 |
109μs |
13.2ns |
49.4ns |
4.9 |
0 |
0 |
32.51 KB |
| master |
EncodeLegacyArgs |
net6.0 |
147μs |
193ns |
749ns |
0 |
0 |
0 |
2.15 KB |
| master |
EncodeLegacyArgs |
netcoreapp3.1 |
198μs |
183ns |
709ns |
0 |
0 |
0 |
2.14 KB |
| master |
EncodeLegacyArgs |
net472 |
265μs |
109ns |
423ns |
0 |
0 |
0 |
2.16 KB |
| #7008 |
EncodeArgs |
net6.0 |
76.5μs |
233ns |
874ns |
0 |
0 |
0 |
32.4 KB |
| #7008 |
EncodeArgs |
netcoreapp3.1 |
96.2μs |
86ns |
322ns |
0 |
0 |
0 |
32.4 KB |
| #7008 |
EncodeArgs |
net472 |
109μs |
13.2ns |
49.4ns |
4.96 |
0 |
0 |
32.51 KB |
| #7008 |
EncodeLegacyArgs |
net6.0 |
143μs |
159ns |
596ns |
0 |
0 |
0 |
2.14 KB |
| #7008 |
EncodeLegacyArgs |
netcoreapp3.1 |
199μs |
338ns |
1.31μs |
0 |
0 |
0 |
2.14 KB |
| #7008 |
EncodeLegacyArgs |
net472 |
266μs |
24.1ns |
93.3ns |
0 |
0 |
0 |
2.16 KB |
Benchmarks.Trace.Asm.AppSecWafBenchmark - Faster :tada: Same allocations :heavy_check_mark:
Faster :tada: in #7008
| Benchmark |
base/diff |
Base Median (ns) |
Diff Median (ns) |
Modality |
| Benchmarks.Trace.Asm.AppSecWafBenchmark.RunWafRealisticBenchmark‑netcoreapp3.1 |
2.131 |
874,284.38 |
410,183.96 |
|
Raw results
| Branch |
Method |
Toolchain |
Mean |
StdError |
StdDev |
Gen 0 |
Gen 1 |
Gen 2 |
Allocated |
| master |
RunWafRealisticBenchmark |
net6.0 |
409μs |
147ns |
510ns |
0 |
0 |
0 |
4.55 KB |
| master |
RunWafRealisticBenchmark |
netcoreapp3.1 |
819μs |
11.4μs |
113μs |
0 |
0 |
0 |
4.48 KB |
| master |
RunWafRealisticBenchmark |
net472 |
434μs |
80.3ns |
311ns |
0 |
0 |
0 |
4.68 KB |
| master |
RunWafRealisticBenchmarkWithAttack |
net6.0 |
296μs |
62.9ns |
244ns |
0 |
0 |
0 |
2.24 KB |
| master |
RunWafRealisticBenchmarkWithAttack |
netcoreapp3.1 |
298μs |
224ns |
866ns |
0 |
0 |
0 |
2.22 KB |
| master |
RunWafRealisticBenchmarkWithAttack |
net472 |
312μs |
56.3ns |
218ns |
0 |
0 |
0 |
2.29 KB |
| #7008 |
RunWafRealisticBenchmark |
net6.0 |
393μs |
56.7ns |
212ns |
0 |
0 |
0 |
4.55 KB |
| #7008 |
RunWafRealisticBenchmark |
netcoreapp3.1 |
410μs |
41.4ns |
149ns |
0 |
0 |
0 |
4.48 KB |
| #7008 |
RunWafRealisticBenchmark |
net472 |
427μs |
54.9ns |
213ns |
0 |
0 |
0 |
4.66 KB |
| #7008 |
RunWafRealisticBenchmarkWithAttack |
net6.0 |
286μs |
48.9ns |
176ns |
0 |
0 |
0 |
2.24 KB |
| #7008 |
RunWafRealisticBenchmarkWithAttack |
netcoreapp3.1 |
298μs |
51.4ns |
178ns |
0 |
0 |
0 |
2.22 KB |
| #7008 |
RunWafRealisticBenchmarkWithAttack |
net472 |
316μs |
27.1ns |
105ns |
0 |
0 |
0 |
2.29 KB |
Benchmarks.Trace.AspNetCoreBenchmark - Same speed :heavy_check_mark: Same allocations :heavy_check_mark:
Raw results
| Branch |
Method |
Toolchain |
Mean |
StdError |
StdDev |
Gen 0 |
Gen 1 |
Gen 2 |
Allocated |
| master |
SendRequest |
net6.0 |
62μs |
56.9ns |
220ns |
0 |
0 |
0 |
14.52 KB |
| master |
SendRequest |
netcoreapp3.1 |
72.8μs |
106ns |
381ns |
0 |
0 |
0 |
17.42 KB |
| master |
SendRequest |
net472 |
0.00389ns |
0.0018ns |
0.00698ns |
0 |
0 |
0 |
0 b |
| #7008 |
SendRequest |
net6.0 |
61.4μs |
40.9ns |
142ns |
0 |
0 |
0 |
14.52 KB |
| #7008 |
SendRequest |
netcoreapp3.1 |
71.8μs |
27.7ns |
100ns |
0 |
0 |
0 |
17.42 KB |
| #7008 |
SendRequest |
net472 |
0.00359ns |
0.00135ns |
0.00522ns |
0 |
0 |
0 |
0 b |
Benchmarks.Trace.CharSliceBenchmark - Same speed :heavy_check_mark: More allocations :warning:
More allocations :warning: in #7008
| Benchmark |
Base Allocated |
Diff Allocated |
Change |
Change % |
| Benchmarks.Trace.CharSliceBenchmark.OptimizedCharSliceWithPool‑net6.0 |
1 B |
2 B |
1 B |
100.00% |
Fewer allocations :tada: in #7008
| Benchmark |
Base Allocated |
Diff Allocated |
Change |
Change % |
| Benchmarks.Trace.CharSliceBenchmark.OptimizedCharSlice‑net6.0 |
4 B |
2 B |
-2 B |
-50.00% |
Raw results
| Branch |
Method |
Toolchain |
Mean |
StdError |
StdDev |
Gen 0 |
Gen 1 |
Gen 2 |
Allocated |
| master |
OriginalCharSlice |
net6.0 |
1.95ms |
609ns |
2.28μs |
0 |
0 |
0 |
640.01 KB |
| master |
OriginalCharSlice |
netcoreapp3.1 |
2.06ms |
4.72μs |
17.7μs |
0 |
0 |
0 |
640 KB |
| master |
OriginalCharSlice |
net472 |
2.71ms |
1.73μs |
6.7μs |
100 |
0 |
0 |
641.95 KB |
| master |
OptimizedCharSlice |
net6.0 |
1.51ms |
210ns |
814ns |
0 |
0 |
0 |
4 B |
| master |
OptimizedCharSlice |
netcoreapp3.1 |
1.67ms |
365ns |
1.42μs |
0 |
0 |
0 |
1 B |
| master |
OptimizedCharSlice |
net472 |
1.94ms |
249ns |
965ns |
0 |
0 |
0 |
0 b |
| master |
OptimizedCharSliceWithPool |
net6.0 |
807μs |
59.1ns |
229ns |
0 |
0 |
0 |
1 B |
| master |
OptimizedCharSliceWithPool |
netcoreapp3.1 |
835μs |
151ns |
586ns |
0 |
0 |
0 |
0 b |
| master |
OptimizedCharSliceWithPool |
net472 |
1.2ms |
197ns |
738ns |
0 |
0 |
0 |
0 b |
| #7008 |
OriginalCharSlice |
net6.0 |
1.92ms |
1.67μs |
6.24μs |
0 |
0 |
0 |
640.01 KB |
| #7008 |
OriginalCharSlice |
netcoreapp3.1 |
2.11ms |
4.19μs |
15.1μs |
0 |
0 |
0 |
640 KB |
| #7008 |
OriginalCharSlice |
net472 |
2.72ms |
104ns |
388ns |
100 |
0 |
0 |
641.95 KB |
| #7008 |
OptimizedCharSlice |
net6.0 |
1.47ms |
575ns |
2.23μs |
0 |
0 |
0 |
2 B |
| #7008 |
OptimizedCharSlice |
netcoreapp3.1 |
1.71ms |
714ns |
2.77μs |
0 |
0 |
0 |
1 B |
| #7008 |
OptimizedCharSlice |
net472 |
1.97ms |
407ns |
1.57μs |
0 |
0 |
0 |
0 b |
| #7008 |
OptimizedCharSliceWithPool |
net6.0 |
799μs |
37.4ns |
145ns |
0 |
0 |
0 |
2 B |
| #7008 |
OptimizedCharSliceWithPool |
netcoreapp3.1 |
844μs |
103ns |
400ns |
0 |
0 |
0 |
0 b |
| #7008 |
OptimizedCharSliceWithPool |
net472 |
1.15ms |
92.9ns |
360ns |
0 |
0 |
0 |
0 b |
Benchmarks.Trace.CIVisibilityProtocolWriterBenchmark - Faster :tada: Fewer allocations :tada:
Faster :tada: in #7008
| Benchmark |
base/diff |
Base Median (ns) |
Diff Median (ns) |
Modality |
| Benchmarks.Trace.CIVisibilityProtocolWriterBenchmark.WriteAndFlushEnrichedTraces‑netcoreapp3.1 |
1.159 |
765,567.19 |
660,646.88 |
|
Fewer allocations :tada: in #7008
| Benchmark |
Base Allocated |
Diff Allocated |
Change |
Change % |
| Benchmarks.Trace.CIVisibilityProtocolWriterBenchmark.WriteAndFlushEnrichedTraces‑netcoreapp3.1 |
42.29 KB |
41.94 KB |
-347 B |
-0.82% |
Raw results
| Branch |
Method |
Toolchain |
Mean |
StdError |
StdDev |
Gen 0 |
Gen 1 |
Gen 2 |
Allocated |
| master |
WriteAndFlushEnrichedTraces |
net6.0 |
695μs |
4.01μs |
33.8μs |
0 |
0 |
0 |
41.82 KB |
| master |
WriteAndFlushEnrichedTraces |
netcoreapp3.1 |
759μs |
4.01μs |
20.4μs |
0 |
0 |
0 |
42.29 KB |
| master |
WriteAndFlushEnrichedTraces |
net472 |
987μs |
3.03μs |
11.3μs |
4.81 |
0 |
0 |
55.97 KB |
| #7008 |
WriteAndFlushEnrichedTraces |
net6.0 |
659μs |
3.26μs |
13.8μs |
0 |
0 |
0 |
41.65 KB |
| #7008 |
WriteAndFlushEnrichedTraces |
netcoreapp3.1 |
668μs |
3.25μs |
13.4μs |
0 |
0 |
0 |
41.94 KB |
| #7008 |
WriteAndFlushEnrichedTraces |
net472 |
1.01ms |
5μs |
21.2μs |
4.81 |
0 |
0 |
55.86 KB |
Benchmarks.Trace.DbCommandBenchmark - Same speed :heavy_check_mark: Same allocations :heavy_check_mark:
Raw results
| Branch |
Method |
Toolchain |
Mean |
StdError |
StdDev |
Gen 0 |
Gen 1 |
Gen 2 |
Allocated |
| master |
ExecuteNonQuery |
net6.0 |
1.92μs |
9.49ns |
39.1ns |
0 |
0 |
0 |
1.02 KB |
| master |
ExecuteNonQuery |
netcoreapp3.1 |
2.57μs |
11.6ns |
44.8ns |
0 |
0 |
0 |
1.02 KB |
| master |
ExecuteNonQuery |
net472 |
2.77μs |
5.69ns |
21.3ns |
0.15 |
0.0136 |
0 |
987 B |
| #7008 |
ExecuteNonQuery |
net6.0 |
1.91μs |
1.1ns |
4.11ns |
0 |
0 |
0 |
1.02 KB |
| #7008 |
ExecuteNonQuery |
netcoreapp3.1 |
2.66μs |
6.33ns |
22.8ns |
0 |
0 |
0 |
1.02 KB |
| #7008 |
ExecuteNonQuery |
net472 |
2.8μs |
8.09ns |
30.3ns |
0.152 |
0.0138 |
0 |
987 B |
Benchmarks.Trace.ElasticsearchBenchmark - Same speed :heavy_check_mark: Same allocations :heavy_check_mark:
Raw results
| Branch |
Method |
Toolchain |
Mean |
StdError |
StdDev |
Gen 0 |
Gen 1 |
Gen 2 |
Allocated |
| master |
CallElasticsearch |
net6.0 |
1.75μs |
7.58ns |
36.4ns |
0 |
0 |
0 |
1.03 KB |
| master |
CallElasticsearch |
netcoreapp3.1 |
2.32μs |
11.3ns |
46.7ns |
0 |
0 |
0 |
1.03 KB |
| master |
CallElasticsearch |
net472 |
3.5μs |
4ns |
15.5ns |
0.158 |
0 |
0 |
1.04 KB |
| master |
CallElasticsearchAsync |
net6.0 |
1.84μs |
6.28ns |
24.3ns |
0 |
0 |
0 |
1.01 KB |
| master |
CallElasticsearchAsync |
netcoreapp3.1 |
2.43μs |
8.84ns |
34.2ns |
0 |
0 |
0 |
1.08 KB |
| master |
CallElasticsearchAsync |
net472 |
3.88μs |
3.58ns |
13.4ns |
0.173 |
0 |
0 |
1.1 KB |
| #7008 |
CallElasticsearch |
net6.0 |
1.73μs |
7.96ns |
31.8ns |
0 |
0 |
0 |
1.03 KB |
| #7008 |
CallElasticsearch |
netcoreapp3.1 |
2.27μs |
11.6ns |
53.4ns |
0 |
0 |
0 |
1.03 KB |
| #7008 |
CallElasticsearch |
net472 |
3.43μs |
2.3ns |
8.6ns |
0.154 |
0 |
0 |
1.04 KB |
| #7008 |
CallElasticsearchAsync |
net6.0 |
1.85μs |
7.98ns |
29.9ns |
0 |
0 |
0 |
1.01 KB |
| #7008 |
CallElasticsearchAsync |
netcoreapp3.1 |
2.42μs |
8.87ns |
34.4ns |
0 |
0 |
0 |
1.08 KB |
| #7008 |
CallElasticsearchAsync |
net472 |
3.64μs |
3.62ns |
14ns |
0.163 |
0 |
0 |
1.1 KB |
Benchmarks.Trace.GraphQLBenchmark - Same speed :heavy_check_mark: Same allocations :heavy_check_mark:
Raw results
| Branch |
Method |
Toolchain |
Mean |
StdError |
StdDev |
Gen 0 |
Gen 1 |
Gen 2 |
Allocated |
| master |
ExecuteAsync |
net6.0 |
2.01μs |
8.69ns |
33.6ns |
0 |
0 |
0 |
952 B |
| master |
ExecuteAsync |
netcoreapp3.1 |
2.33μs |
9.79ns |
35.3ns |
0 |
0 |
0 |
952 B |
| master |
ExecuteAsync |
net472 |
2.52μs |
7.62ns |
29.5ns |
0.141 |
0 |
0 |
915 B |
| #7008 |
ExecuteAsync |
net6.0 |
1.83μs |
2.4ns |
9.31ns |
0 |
0 |
0 |
952 B |
| #7008 |
ExecuteAsync |
netcoreapp3.1 |
2.48μs |
8.88ns |
34.4ns |
0 |
0 |
0 |
952 B |
| #7008 |
ExecuteAsync |
net472 |
2.52μs |
2.33ns |
9.02ns |
0.138 |
0 |
0 |
915 B |
Benchmarks.Trace.HttpClientBenchmark - Same speed :heavy_check_mark: Same allocations :heavy_check_mark:
Raw results
| Branch |
Method |
Toolchain |
Mean |
StdError |
StdDev |
Gen 0 |
Gen 1 |
Gen 2 |
Allocated |
| master |
SendAsync |
net6.0 |
6.98μs |
5.84ns |
20.2ns |
0 |
0 |
0 |
2.36 KB |
| master |
SendAsync |
netcoreapp3.1 |
8.65μs |
24.5ns |
91.5ns |
0 |
0 |
0 |
2.9 KB |
| master |
SendAsync |
net472 |
12.3μs |
12.9ns |
50.1ns |
0.493 |
0 |
0 |
3.18 KB |
| #7008 |
SendAsync |
net6.0 |
6.95μs |
11.9ns |
44.6ns |
0 |
0 |
0 |
2.36 KB |
| #7008 |
SendAsync |
netcoreapp3.1 |
8.68μs |
30.9ns |
120ns |
0 |
0 |
0 |
2.9 KB |
| #7008 |
SendAsync |
net472 |
12.1μs |
5.11ns |
19.1ns |
0.48 |
0 |
0 |
3.18 KB |
Benchmarks.Trace.Iast.StringAspectsBenchmark - Faster :tada: More allocations :warning:
Faster :tada: in #7008
| Benchmark |
base/diff |
Base Median (ns) |
Diff Median (ns) |
Modality |
| Benchmarks.Trace.Iast.StringAspectsBenchmark.StringConcatAspectBenchmark‑net6.0 |
1.203 |
553,600.00 |
460,300.00 |
|
More allocations :warning: in #7008
| Benchmark |
Base Allocated |
Diff Allocated |
Change |
Change % |
| Benchmarks.Trace.Iast.StringAspectsBenchmark.StringConcatBenchmark‑net472 |
57.34 KB |
65.54 KB |
8.19 KB |
14.29% |
| Benchmarks.Trace.Iast.StringAspectsBenchmark.StringConcatAspectBenchmark‑netcoreapp3.1 |
248.67 KB |
275.21 KB |
26.54 KB |
10.67% |
| Benchmarks.Trace.Iast.StringAspectsBenchmark.StringConcatBenchmark‑netcoreapp3.1 |
42.78 KB |
43.44 KB |
656 B |
1.53% |
Fewer allocations :tada: in #7008
| Benchmark |
Base Allocated |
Diff Allocated |
Change |
Change % |
| Benchmarks.Trace.Iast.StringAspectsBenchmark.StringConcatBenchmark‑net6.0 |
44.9 KB |
43.33 KB |
-1.57 KB |
-3.49% |
| Benchmarks.Trace.Iast.StringAspectsBenchmark.StringConcatAspectBenchmark‑net6.0 |
277.88 KB |
259.86 KB |
-18.02 KB |
-6.48% |
Raw results
| Branch |
Method |
Toolchain |
Mean |
StdError |
StdDev |
Gen 0 |
Gen 1 |
Gen 2 |
Allocated |
| master |
StringConcatBenchmark |
net6.0 |
51.7μs |
809ns |
8μs |
0 |
0 |
0 |
44.9 KB |
| master |
StringConcatBenchmark |
netcoreapp3.1 |
50.4μs |
444ns |
4.28μs |
0 |
0 |
0 |
42.78 KB |
| master |
StringConcatBenchmark |
net472 |
57.4μs |
281ns |
1.16μs |
0 |
0 |
0 |
57.34 KB |
| master |
StringConcatAspectBenchmark |
net6.0 |
555μs |
2.58μs |
9.65μs |
0 |
0 |
0 |
277.88 KB |
| master |
StringConcatAspectBenchmark |
netcoreapp3.1 |
523μs |
2.44μs |
9.11μs |
0 |
0 |
0 |
248.67 KB |
| master |
StringConcatAspectBenchmark |
net472 |
404μs |
2.29μs |
16.8μs |
0 |
0 |
0 |
278.53 KB |
| #7008 |
StringConcatBenchmark |
net6.0 |
44.1μs |
120ns |
414ns |
0 |
0 |
0 |
43.33 KB |
| #7008 |
StringConcatBenchmark |
netcoreapp3.1 |
48.9μs |
255ns |
1.76μs |
0 |
0 |
0 |
43.44 KB |
| #7008 |
StringConcatBenchmark |
net472 |
56.5μs |
217ns |
782ns |
0 |
0 |
0 |
65.54 KB |
| #7008 |
StringConcatAspectBenchmark |
net6.0 |
462μs |
2.05μs |
7.09μs |
0 |
0 |
0 |
259.86 KB |
| #7008 |
StringConcatAspectBenchmark |
netcoreapp3.1 |
522μs |
1.24μs |
4.29μs |
0 |
0 |
0 |
275.21 KB |
| #7008 |
StringConcatAspectBenchmark |
net472 |
407μs |
1.97μs |
9.86μs |
0 |
0 |
0 |
278.53 KB |
Benchmarks.Trace.ILoggerBenchmark - Same speed :heavy_check_mark: Same allocations :heavy_check_mark:
Raw results
| Branch |
Method |
Toolchain |
Mean |
StdError |
StdDev |
Gen 0 |
Gen 1 |
Gen 2 |
Allocated |
| master |
EnrichedLog |
net6.0 |
2.48μs |
8.94ns |
34.6ns |
0 |
0 |
0 |
1.7 KB |
| master |
EnrichedLog |
netcoreapp3.1 |
3.58μs |
12.9ns |
50.1ns |
0 |
0 |
0 |
1.7 KB |
| master |
EnrichedLog |
net472 |
3.78μs |
6.93ns |
26.9ns |
0.246 |
0 |
0 |
1.64 KB |
| #7008 |
EnrichedLog |
net6.0 |
2.52μs |
13ns |
60.8ns |
0 |
0 |
0 |
1.7 KB |
| #7008 |
EnrichedLog |
netcoreapp3.1 |
3.5μs |
7.01ns |
27.2ns |
0 |
0 |
0 |
1.7 KB |
| #7008 |
EnrichedLog |
net472 |
3.63μs |
1.7ns |
6.6ns |
0.253 |
0 |
0 |
1.64 KB |
Benchmarks.Trace.Log4netBenchmark - Same speed :heavy_check_mark: Same allocations :heavy_check_mark:
Raw results
| Branch |
Method |
Toolchain |
Mean |
StdError |
StdDev |
Gen 0 |
Gen 1 |
Gen 2 |
Allocated |
| master |
EnrichedLog |
net6.0 |
125μs |
546ns |
2.5μs |
0 |
0 |
0 |
4.31 KB |
| master |
EnrichedLog |
netcoreapp3.1 |
127μs |
133ns |
498ns |
0 |
0 |
0 |
4.31 KB |
| master |
EnrichedLog |
net472 |
167μs |
105ns |
405ns |
0 |
0 |
0 |
4.52 KB |
| #7008 |
EnrichedLog |
net6.0 |
123μs |
126ns |
470ns |
0 |
0 |
0 |
4.31 KB |
| #7008 |
EnrichedLog |
netcoreapp3.1 |
128μs |
398ns |
1.49μs |
0 |
0 |
0 |
4.31 KB |
| #7008 |
EnrichedLog |
net472 |
167μs |
195ns |
757ns |
0 |
0 |
0 |
4.52 KB |
Benchmarks.Trace.NLogBenchmark - Same speed :heavy_check_mark: Same allocations :heavy_check_mark:
Raw results
| Branch |
Method |
Toolchain |
Mean |
StdError |
StdDev |
Gen 0 |
Gen 1 |
Gen 2 |
Allocated |
| master |
EnrichedLog |
net6.0 |
4.98μs |
10.8ns |
41.6ns |
0 |
0 |
0 |
2.26 KB |
| master |
EnrichedLog |
netcoreapp3.1 |
6.8μs |
13.1ns |
50.6ns |
0 |
0 |
0 |
2.26 KB |
| master |
EnrichedLog |
net472 |
7.26μs |
5.4ns |
20.9ns |
0.325 |
0 |
0 |
2.08 KB |
| #7008 |
EnrichedLog |
net6.0 |
4.86μs |
22.7ns |
87.9ns |
0 |
0 |
0 |
2.26 KB |
| #7008 |
EnrichedLog |
netcoreapp3.1 |
6.72μs |
13.1ns |
50.8ns |
0 |
0 |
0 |
2.26 KB |
| #7008 |
EnrichedLog |
net472 |
7.38μs |
6ns |
23.2ns |
0.296 |
0 |
0 |
2.08 KB |
Benchmarks.Trace.RedisBenchmark - Same speed :heavy_check_mark: Same allocations :heavy_check_mark:
Raw results
| Branch |
Method |
Toolchain |
Mean |
StdError |
StdDev |
Gen 0 |
Gen 1 |
Gen 2 |
Allocated |
| master |
SendReceive |
net6.0 |
1.94μs |
10.1ns |
50.5ns |
0 |
0 |
0 |
1.2 KB |
| master |
SendReceive |
netcoreapp3.1 |
2.86μs |
7.7ns |
29.8ns |
0 |
0 |
0 |
1.2 KB |
| master |
SendReceive |
net472 |
3.05μs |
4.77ns |
18.5ns |
0.186 |
0 |
0 |
1.2 KB |
| #7008 |
SendReceive |
net6.0 |
2.06μs |
9.82ns |
39.3ns |
0 |
0 |
0 |
1.2 KB |
| #7008 |
SendReceive |
netcoreapp3.1 |
2.64μs |
8.82ns |
34.1ns |
0 |
0 |
0 |
1.2 KB |
| #7008 |
SendReceive |
net472 |
3.11μs |
1.41ns |
5.44ns |
0.186 |
0 |
0 |
1.2 KB |
Benchmarks.Trace.SerilogBenchmark - Same speed :heavy_check_mark: Same allocations :heavy_check_mark:
Raw results
| Branch |
Method |
Toolchain |
Mean |
StdError |
StdDev |
Gen 0 |
Gen 1 |
Gen 2 |
Allocated |
| master |
EnrichedLog |
net6.0 |
4.16μs |
17.2ns |
61.9ns |
0 |
0 |
0 |
1.58 KB |
| master |
EnrichedLog |
netcoreapp3.1 |
5.47μs |
12.8ns |
49.6ns |
0 |
0 |
0 |
1.63 KB |
| master |
EnrichedLog |
net472 |
6.43μs |
4.53ns |
16.3ns |
0.322 |
0 |
0 |
2.03 KB |
| #7008 |
EnrichedLog |
net6.0 |
4.07μs |
14.9ns |
57.7ns |
0 |
0 |
0 |
1.58 KB |
| #7008 |
EnrichedLog |
netcoreapp3.1 |
5.64μs |
9.38ns |
33.8ns |
0 |
0 |
0 |
1.63 KB |
| #7008 |
EnrichedLog |
net472 |
6.41μs |
5.81ns |
22.5ns |
0.321 |
0 |
0 |
2.03 KB |
Benchmarks.Trace.SpanBenchmark - Same speed :heavy_check_mark: Same allocations :heavy_check_mark:
Raw results
| Branch |
Method |
Toolchain |
Mean |
StdError |
StdDev |
Gen 0 |
Gen 1 |
Gen 2 |
Allocated |
| master |
StartFinishSpan |
net6.0 |
742ns |
3.39ns |
13.6ns |
0 |
0 |
0 |
576 B |
| master |
StartFinishSpan |
netcoreapp3.1 |
919ns |
0.601ns |
2.33ns |
0 |
0 |
0 |
576 B |
| master |
StartFinishSpan |
net472 |
891ns |
0.563ns |
2.18ns |
0.0895 |
0 |
0 |
578 B |
| master |
StartFinishScope |
net6.0 |
878ns |
4.86ns |
24.8ns |
0 |
0 |
0 |
696 B |
| master |
StartFinishScope |
netcoreapp3.1 |
1.14μs |
6.1ns |
32.3ns |
0 |
0 |
0 |
696 B |
| master |
StartFinishScope |
net472 |
1.11μs |
1.53ns |
5.92ns |
0.0995 |
0 |
0 |
658 B |
| #7008 |
StartFinishSpan |
net6.0 |
728ns |
3.88ns |
20.5ns |
0 |
0 |
0 |
576 B |
| #7008 |
StartFinishSpan |
netcoreapp3.1 |
916ns |
4.35ns |
17.4ns |
0 |
0 |
0 |
576 B |
| #7008 |
StartFinishSpan |
net472 |
903ns |
0.143ns |
0.536ns |
0.0907 |
0 |
0 |
578 B |
| #7008 |
StartFinishScope |
net6.0 |
890ns |
4.77ns |
27.4ns |
0 |
0 |
0 |
696 B |
| #7008 |
StartFinishScope |
netcoreapp3.1 |
1.14μs |
6.07ns |
32.1ns |
0 |
0 |
0 |
696 B |
| #7008 |
StartFinishScope |
net472 |
1.08μs |
1.12ns |
4.34ns |
0.104 |
0 |
0 |
658 B |
Benchmarks.Trace.TraceAnnotationsBenchmark - Same speed :heavy_check_mark: Same allocations :heavy_check_mark:
Raw results
| Branch |
Method |
Toolchain |
Mean |
StdError |
StdDev |
Gen 0 |
Gen 1 |
Gen 2 |
Allocated |
| master |
RunOnMethodBegin |
net6.0 |
1.03μs |
5.57ns |
31ns |
0 |
0 |
0 |
696 B |
| master |
RunOnMethodBegin |
netcoreapp3.1 |
1.45μs |
6.05ns |
23.4ns |
0 |
0 |
0 |
696 B |
| master |
RunOnMethodBegin |
net472 |
1.44μs |
0.394ns |
1.42ns |
0.101 |
0 |
0 |
658 B |
| #7008 |
RunOnMethodBegin |
net6.0 |
1.02μs |
4.73ns |
18.3ns |
0 |
0 |
0 |
696 B |
| #7008 |
RunOnMethodBegin |
netcoreapp3.1 |
1.4μs |
6.92ns |
30.9ns |
0 |
0 |
0 |
696 B |
| #7008 |
RunOnMethodBegin |
net472 |
1.39μs |
2.38ns |
9.22ns |
0.105 |
0 |
0 |
658 B |