Revisit CMake projects architecture#3329
Merged
Merged
Conversation
This comment has been minimized.
This comment has been minimized.
gleocadie
force-pushed
the
gleocadie/use-module-for-cmake
branch
2 times, most recently
from
October 8, 2022 21:26
4fe9a14 to
38e6f74
Compare
This comment has been minimized.
This comment has been minimized.
gleocadie
force-pushed
the
gleocadie/use-module-for-cmake
branch
2 times, most recently
from
October 8, 2022 22:36
d13f649 to
030c661
Compare
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
gleocadie
force-pushed
the
gleocadie/use-module-for-cmake
branch
from
October 9, 2022 19:30
9f8c407 to
68be990
Compare
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
gleocadie
force-pushed
the
gleocadie/use-module-for-cmake
branch
3 times, most recently
from
October 10, 2022 00:36
416275c to
47966d2
Compare
This comment has been minimized.
This comment has been minimized.
gleocadie
force-pushed
the
gleocadie/use-module-for-cmake
branch
7 times, most recently
from
October 10, 2022 02:03
09c3df5 to
1715a64
Compare
This comment has been minimized.
This comment has been minimized.
gleocadie
force-pushed
the
gleocadie/use-module-for-cmake
branch
from
October 10, 2022 11:50
1715a64 to
d6daa9a
Compare
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
gleocadie
force-pushed
the
gleocadie/use-module-for-cmake
branch
from
October 10, 2022 17:02
d6daa9a to
5f0e463
Compare
This comment has been minimized.
This comment has been minimized.
gleocadie
force-pushed
the
gleocadie/use-module-for-cmake
branch
from
October 10, 2022 21:06
ab91842 to
78fc425
Compare
This comment has been minimized.
This comment has been minimized.
corprof_i.cpp is compiled multiple times by the profiler, the tracer and the native loader. With this new type of library (OBJECT), we can compile it once and use the object file every time.
gleocadie
force-pushed
the
gleocadie/use-module-for-cmake
branch
from
October 13, 2022 11:33
523a02e to
0be69c0
Compare
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
chrisnas
approved these changes
Oct 13, 2022
chrisnas
left a comment
Contributor
There was a problem hiding this comment.
LGTM after validating comments
gleocadie
force-pushed
the
gleocadie/use-module-for-cmake
branch
from
October 13, 2022 15:05
c4b12eb to
608a9bd
Compare
Member
Benchmarks Report 🐌Benchmarks for #3329 compared to master:
The following thresholds were used for comparing the benchmark speeds:
Allocation changes below 0.5% are ignored. Benchmark detailsBenchmarks.Trace.AgentWriterBenchmark - Same speed ✔️ Same allocations ✔️Raw results
Benchmarks.Trace.AppSecBodyBenchmark - Faster 🎉 Same allocations ✔️
|
| Benchmark | base/diff | Base Median (ns) | Diff Median (ns) | Modality |
|---|---|---|---|---|
| Benchmarks.Trace.AppSecBodyBenchmark.BodyExtractorSimpleBody‑net472 | 1.174 | 316.94 | 269.85 |
Raw results
| Branch | Method | Toolchain | Mean | StdError | StdDev | Gen 0 | Gen 1 | Gen 2 | Allocated |
|---|---|---|---|---|---|---|---|---|---|
| master | AllCycleSimpleBody |
net472 | 198ns | 0.0787ns | 0.284ns | 0.0726 | 0 | 0 | 457 B |
| master | AllCycleSimpleBody |
netcoreapp3.1 | 255ns | 0.146ns | 0.548ns | 0.00614 | 0 | 0 | 456 B |
| master | AllCycleMoreComplexBody |
net472 | 200ns | 0.052ns | 0.18ns | 0.0688 | 0 | 0 | 433 B |
| master | AllCycleMoreComplexBody |
netcoreapp3.1 | 252ns | 0.161ns | 0.601ns | 0.00595 | 0 | 0 | 432 B |
| master | BodyExtractorSimpleBody |
net472 | 317ns | 0.0885ns | 0.319ns | 0.0572 | 0 | 0 | 361 B |
| master | BodyExtractorSimpleBody |
netcoreapp3.1 | 238ns | 0.0973ns | 0.351ns | 0.0037 | 0 | 0 | 272 B |
| master | BodyExtractorMoreComplexBody |
net472 | 15.8μs | 17.1ns | 63.8ns | 1.21 | 0.0158 | 0 | 7.62 KB |
| master | BodyExtractorMoreComplexBody |
netcoreapp3.1 | 12.8μs | 5.29ns | 20.5ns | 0.089 | 0 | 0 | 6.75 KB |
| #3329 | AllCycleSimpleBody |
net472 | 196ns | 0.0546ns | 0.204ns | 0.0727 | 0 | 0 | 457 B |
| #3329 | AllCycleSimpleBody |
netcoreapp3.1 | 261ns | 0.393ns | 1.52ns | 0.00624 | 0 | 0 | 456 B |
| #3329 | AllCycleMoreComplexBody |
net472 | 195ns | 0.0552ns | 0.199ns | 0.0689 | 0 | 0 | 433 B |
| #3329 | AllCycleMoreComplexBody |
netcoreapp3.1 | 258ns | 0.395ns | 1.48ns | 0.0059 | 0 | 0 | 432 B |
| #3329 | BodyExtractorSimpleBody |
net472 | 270ns | 0.118ns | 0.443ns | 0.0573 | 0 | 0 | 361 B |
| #3329 | BodyExtractorSimpleBody |
netcoreapp3.1 | 240ns | 0.165ns | 0.637ns | 0.00374 | 0 | 0 | 272 B |
| #3329 | BodyExtractorMoreComplexBody |
net472 | 15.7μs | 12.3ns | 47.7ns | 1.2 | 0.0156 | 0 | 7.62 KB |
| #3329 | BodyExtractorMoreComplexBody |
netcoreapp3.1 | 12.9μs | 3.8ns | 14.2ns | 0.0903 | 0 | 0 | 6.75 KB |
Benchmarks.Trace.AspNetCoreBenchmark - Same speed ✔️ Same allocations ✔️
Raw results
| Branch | Method | Toolchain | Mean | StdError | StdDev | Gen 0 | Gen 1 | Gen 2 | Allocated |
|---|---|---|---|---|---|---|---|---|---|
| master | SendRequest |
net472 | 0ns | 0ns | 0ns | 0 | 0 | 0 | 0 b |
| master | SendRequest |
netcoreapp3.1 | 181μs | 185ns | 715ns | 0.27 | 0 | 0 | 20.68 KB |
| #3329 | SendRequest |
net472 | 0ns | 0ns | 0ns | 0 | 0 | 0 | 0 b |
| #3329 | SendRequest |
netcoreapp3.1 | 183μs | 290ns | 1.12μs | 0.182 | 0 | 0 | 20.68 KB |
Benchmarks.Trace.DbCommandBenchmark - Same speed ✔️ Same allocations ✔️
Raw results
| Branch | Method | Toolchain | Mean | StdError | StdDev | Gen 0 | Gen 1 | Gen 2 | Allocated |
|---|---|---|---|---|---|---|---|---|---|
| master | ExecuteNonQuery |
net472 | 1.79μs | 0.719ns | 2.69ns | 0.155 | 0.000901 | 0 | 979 B |
| master | ExecuteNonQuery |
netcoreapp3.1 | 1.46μs | 0.646ns | 2.33ns | 0.0131 | 0 | 0 | 968 B |
| #3329 | ExecuteNonQuery |
net472 | 1.79μs | 1.16ns | 4.17ns | 0.155 | 0.000895 | 0 | 979 B |
| #3329 | ExecuteNonQuery |
netcoreapp3.1 | 1.49μs | 0.803ns | 3.01ns | 0.0126 | 0 | 0 | 968 B |
Benchmarks.Trace.ElasticsearchBenchmark - Same speed ✔️ Same allocations ✔️
Raw results
| Branch | Method | Toolchain | Mean | StdError | StdDev | Gen 0 | Gen 1 | Gen 2 | Allocated |
|---|---|---|---|---|---|---|---|---|---|
| master | CallElasticsearch |
net472 | 2.48μs | 1.12ns | 4.35ns | 0.188 | 0 | 0 | 1.19 KB |
| master | CallElasticsearch |
netcoreapp3.1 | 1.58μs | 0.725ns | 2.81ns | 0.015 | 0 | 0 | 1.13 KB |
| master | CallElasticsearchAsync |
net472 | 2.7μs | 1.22ns | 4.73ns | 0.209 | 0 | 0 | 1.32 KB |
| master | CallElasticsearchAsync |
netcoreapp3.1 | 1.63μs | 0.616ns | 2.31ns | 0.0171 | 0 | 0 | 1.25 KB |
| #3329 | CallElasticsearch |
net472 | 2.53μs | 0.716ns | 2.58ns | 0.188 | 0 | 0 | 1.19 KB |
| #3329 | CallElasticsearch |
netcoreapp3.1 | 1.6μs | 1.53ns | 5.71ns | 0.0151 | 0 | 0 | 1.13 KB |
| #3329 | CallElasticsearchAsync |
net472 | 2.69μs | 0.896ns | 3.47ns | 0.21 | 0 | 0 | 1.32 KB |
| #3329 | CallElasticsearchAsync |
netcoreapp3.1 | 1.7μs | 0.828ns | 2.99ns | 0.017 | 0 | 0 | 1.25 KB |
Benchmarks.Trace.GraphQLBenchmark - Same speed ✔️ Same allocations ✔️
Raw results
| Branch | Method | Toolchain | Mean | StdError | StdDev | Gen 0 | Gen 1 | Gen 2 | Allocated |
|---|---|---|---|---|---|---|---|---|---|
| master | ExecuteAsync |
net472 | 2.76μs | 1.59ns | 6.16ns | 0.23 | 0 | 0 | 1.45 KB |
| master | ExecuteAsync |
netcoreapp3.1 | 1.73μs | 0.672ns | 2.42ns | 0.0183 | 0 | 0 | 1.38 KB |
| #3329 | ExecuteAsync |
net472 | 2.85μs | 1.22ns | 4.39ns | 0.231 | 0 | 0 | 1.45 KB |
| #3329 | ExecuteAsync |
netcoreapp3.1 | 1.75μs | 0.564ns | 2.03ns | 0.0183 | 0 | 0 | 1.38 KB |
Benchmarks.Trace.HttpClientBenchmark - Same speed ✔️ Same allocations ✔️
Raw results
| Branch | Method | Toolchain | Mean | StdError | StdDev | Gen 0 | Gen 1 | Gen 2 | Allocated |
|---|---|---|---|---|---|---|---|---|---|
| master | SendAsync |
net472 | 5.85μs | 2.16ns | 8.36ns | 0.444 | 0 | 0 | 2.8 KB |
| master | SendAsync |
netcoreapp3.1 | 3.63μs | 1.26ns | 4.7ns | 0.0344 | 0 | 0 | 2.63 KB |
| #3329 | SendAsync |
net472 | 5.96μs | 2.56ns | 9.92ns | 0.445 | 0 | 0 | 2.8 KB |
| #3329 | SendAsync |
netcoreapp3.1 | 3.76μs | 20.1ns | 108ns | 0.0357 | 0 | 0 | 2.63 KB |
Benchmarks.Trace.ILoggerBenchmark - Same speed ✔️ Same allocations ✔️
Raw results
| Branch | Method | Toolchain | Mean | StdError | StdDev | Gen 0 | Gen 1 | Gen 2 | Allocated |
|---|---|---|---|---|---|---|---|---|---|
| master | EnrichedLog |
net472 | 3.13μs | 3.5ns | 13.1ns | 0.297 | 0 | 0 | 1.88 KB |
| master | EnrichedLog |
netcoreapp3.1 | 2.44μs | 2.13ns | 7.96ns | 0.0257 | 0 | 0 | 1.91 KB |
| #3329 | EnrichedLog |
net472 | 3.17μs | 2.97ns | 11.1ns | 0.298 | 0 | 0 | 1.88 KB |
| #3329 | EnrichedLog |
netcoreapp3.1 | 2.53μs | 1.02ns | 3.82ns | 0.0264 | 0 | 0 | 1.91 KB |
Benchmarks.Trace.Log4netBenchmark - Same speed ✔️ Same allocations ✔️
Raw results
| Branch | Method | Toolchain | Mean | StdError | StdDev | Gen 0 | Gen 1 | Gen 2 | Allocated |
|---|---|---|---|---|---|---|---|---|---|
| master | EnrichedLog |
net472 | 153μs | 172ns | 642ns | 0.688 | 0.229 | 0 | 4.72 KB |
| master | EnrichedLog |
netcoreapp3.1 | 122μs | 229ns | 886ns | 0.0606 | 0 | 0 | 4.55 KB |
| #3329 | EnrichedLog |
net472 | 152μs | 168ns | 651ns | 0.684 | 0.228 | 0 | 4.72 KB |
| #3329 | EnrichedLog |
netcoreapp3.1 | 121μs | 177ns | 686ns | 0.0601 | 0 | 0 | 4.55 KB |
Benchmarks.Trace.NLogBenchmark - Same speed ✔️ Same allocations ✔️
Raw results
| Branch | Method | Toolchain | Mean | StdError | StdDev | Gen 0 | Gen 1 | Gen 2 | Allocated |
|---|---|---|---|---|---|---|---|---|---|
| master | EnrichedLog |
net472 | 5.66μs | 2.45ns | 9.18ns | 0.578 | 0.00284 | 0 | 3.65 KB |
| master | EnrichedLog |
netcoreapp3.1 | 4.81μs | 1.97ns | 7.35ns | 0.0531 | 0 | 0 | 3.98 KB |
| #3329 | EnrichedLog |
net472 | 6.02μs | 2.4ns | 8.97ns | 0.578 | 0.00301 | 0 | 3.65 KB |
| #3329 | EnrichedLog |
netcoreapp3.1 | 4.54μs | 3.37ns | 13ns | 0.0544 | 0 | 0 | 3.98 KB |
Benchmarks.Trace.RedisBenchmark - Same speed ✔️ Same allocations ✔️
Raw results
| Branch | Method | Toolchain | Mean | StdError | StdDev | Gen 0 | Gen 1 | Gen 2 | Allocated |
|---|---|---|---|---|---|---|---|---|---|
| master | SendReceive |
net472 | 2.35μs | 2.84ns | 11ns | 0.222 | 0 | 0 | 1.4 KB |
| master | SendReceive |
netcoreapp3.1 | 1.87μs | 0.794ns | 2.97ns | 0.0179 | 0 | 0 | 1.35 KB |
| #3329 | SendReceive |
net472 | 2.35μs | 2.87ns | 11.1ns | 0.223 | 0 | 0 | 1.4 KB |
| #3329 | SendReceive |
netcoreapp3.1 | 1.86μs | 1.09ns | 4.06ns | 0.0184 | 0 | 0 | 1.35 KB |
Benchmarks.Trace.SerilogBenchmark - Same speed ✔️ Same allocations ✔️
Raw results
| Branch | Method | Toolchain | Mean | StdError | StdDev | Gen 0 | Gen 1 | Gen 2 | Allocated |
|---|---|---|---|---|---|---|---|---|---|
| master | EnrichedLog |
net472 | 5.08μs | 1.81ns | 7ns | 0.364 | 0 | 0 | 2.3 KB |
| master | EnrichedLog |
netcoreapp3.1 | 4.18μs | 1.36ns | 5.28ns | 0.0251 | 0 | 0 | 1.86 KB |
| #3329 | EnrichedLog |
net472 | 5.21μs | 2.8ns | 10.9ns | 0.363 | 0 | 0 | 2.3 KB |
| #3329 | EnrichedLog |
netcoreapp3.1 | 4.19μs | 14.9ns | 57.5ns | 0.0249 | 0 | 0 | 1.86 KB |
Benchmarks.Trace.SpanBenchmark - Same speed ✔️ Same allocations ✔️
Raw results
| Branch | Method | Toolchain | Mean | StdError | StdDev | Gen 0 | Gen 1 | Gen 2 | Allocated |
|---|---|---|---|---|---|---|---|---|---|
| master | StartFinishSpan |
net472 | 1.21μs | 0.369ns | 1.33ns | 0.134 | 0 | 0 | 842 B |
| master | StartFinishSpan |
netcoreapp3.1 | 959ns | 0.552ns | 2.14ns | 0.0111 | 0 | 0 | 792 B |
| master | StartFinishScope |
net472 | 1.37μs | 0.43ns | 1.67ns | 0.147 | 0 | 0 | 923 B |
| master | StartFinishScope |
netcoreapp3.1 | 1.07μs | 0.261ns | 0.975ns | 0.0123 | 0 | 0 | 912 B |
| #3329 | StartFinishSpan |
net472 | 1.25μs | 0.63ns | 2.36ns | 0.134 | 0 | 0 | 842 B |
| #3329 | StartFinishSpan |
netcoreapp3.1 | 917ns | 0.473ns | 1.77ns | 0.0105 | 0 | 0 | 792 B |
| #3329 | StartFinishScope |
net472 | 1.4μs | 0.409ns | 1.59ns | 0.146 | 0 | 0 | 923 B |
| #3329 | StartFinishScope |
netcoreapp3.1 | 1.11μs | 0.326ns | 1.26ns | 0.0123 | 0 | 0 | 912 B |
Benchmarks.Trace.TraceAnnotationsBenchmark - Same speed ✔️ Same allocations ✔️
Raw results
| Branch | Method | Toolchain | Mean | StdError | StdDev | Gen 0 | Gen 1 | Gen 2 | Allocated |
|---|---|---|---|---|---|---|---|---|---|
| master | RunOnMethodBegin |
net472 | 1.54μs | 0.34ns | 1.27ns | 0.147 | 0 | 0 | 923 B |
| master | RunOnMethodBegin |
netcoreapp3.1 | 1.18μs | 0.32ns | 1.24ns | 0.0123 | 0 | 0 | 912 B |
| #3329 | RunOnMethodBegin |
net472 | 1.53μs | 0.456ns | 1.76ns | 0.146 | 0 | 0 | 923 B |
| #3329 | RunOnMethodBegin |
netcoreapp3.1 | 1.12μs | 0.565ns | 2.04ns | 0.0124 | 0 | 0 | 912 B |
Member
Code Coverage Report 📊✔️ Merging #3329 into master will not change line coverage
View the full report for further details: Datadog.Trace Breakdown ✔️
The following classes have significant coverage changes.
The following classes were added in #3329:
View the full reports for further details: |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary of changes
Revisiting the CMake projects architecture, to unify dependencies amongst projects.
Reason for change
Profiler, tracer and native loader have native dependencies, but each project has its own way to download/retrieve it, to build it. This becomes difficult when we need to update to a newer version. We would have to touch different part of the repository.
Implementation details
Test coverage
Other details