Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
119 commits
Select commit Hold shift + click to select a range
5a4cbf3
fix: restore PackageLicense
DocSvartz Mar 18, 2026
08f49dd
chore: Merge pull request #870 from DocSvartz/fix-package-license
DocSvartz Mar 18, 2026
6b5e461
fix(ProjectToType): add Test case
DocSvartz Mar 20, 2026
5c63ddc
fix(ProjectToType): fix 10.0 regression - member name is null
DocSvartz Mar 20, 2026
2467b6e
chore: Merge pull request #876 from DocSvartz/FIx-ProjectToType-Regre…
DocSvartz Mar 20, 2026
b18cc86
chore: Up mapster version to 10.0.2
DocSvartz Mar 20, 2026
f34cd6d
chore: Merge pull request #877 from DocSvartz/bump
DocSvartz Mar 20, 2026
2b6f16f
feat: Up EF6 and EF Core to v10.0.1
DocSvartz Mar 20, 2026
5b5e2e4
chore: Merge pull request #878 from DocSvartz/bump-EFcore-and-EF6
DocSvartz Mar 20, 2026
f8395af
fix: mapster Version and mapster core version
DocSvartz Mar 20, 2026
b834f6a
chore: Merge pull request #879 from DocSvartz/Up-version-Mapster-core
DocSvartz Mar 20, 2026
bbf9b76
fix: fix version number
DocSvartz Mar 20, 2026
3b5fb32
chore: Merge pull request #880 from DocSvartz/d22
DocSvartz Mar 20, 2026
d9ad048
feat: Add Record Projecttion test
DocSvartz Mar 21, 2026
6f046f5
fix: Quick fix for #881 ProjectToType from Record types
DocSvartz Mar 21, 2026
73620c0
feat: Up Mapster version
DocSvartz Mar 21, 2026
64626f5
chore: Merge pull request #882 from DocSvartz/d22
DocSvartz Mar 21, 2026
e9b33cf
feat: fix #883 activate ctor param using default value
DocSvartz Mar 23, 2026
a60020b
fix(test): ignore and remove not actual tests after fix #883
DocSvartz Mar 23, 2026
f9bbb96
feat: Adding a simple way to set member using the UseDistinationValue…
DocSvartz Mar 23, 2026
94b86dc
feat(test): add test to new UseDestinatonValue config method
DocSvartz Mar 23, 2026
307d282
feat: add IsMapsterImmutable type helper
DocSvartz Mar 23, 2026
dfae8b6
fix: Restored v7.4.0 behavior from class property without setter
DocSvartz Mar 23, 2026
58efada
feat(test): add Readonly AutoProperty Primitive type use UsingDestina…
DocSvartz Mar 23, 2026
58bed37
fix(test): Correction of the test based on the behavior used in Mapst…
DocSvartz Mar 23, 2026
6e69ad8
fix: #881 - ProjectToType record regression
DocSvartz Mar 23, 2026
0f44b7e
feat: Simplifying library version changes
DocSvartz Mar 23, 2026
fd5c6b6
fix(build): drop dublicate props: Copyright, Authors, Description in …
DocSvartz Mar 23, 2026
ffa4633
chore: Merge pull request #886 from DocSvartz/feat---Simplification-U…
DocSvartz Mar 24, 2026
b4feddb
chore: Merge pull request #885 from DocSvartz/add-class-ctor--using-d…
DocSvartz Mar 24, 2026
a14b54e
chore: Merge pull request #887 from DocSvartz/restore-v7.4.0-behavior…
DocSvartz Mar 24, 2026
f8a7763
chore: Merge pull request #888 from DocSvartz/Fix-#881
DocSvartz Mar 24, 2026
83f2f59
chore: Merge pull request #889 from DocSvartz/feat-build-libs
DocSvartz Mar 24, 2026
22b232a
fix: Typo in Data-types.md (#891)
NLHaarP Mar 24, 2026
d3a3fe8
feat(build): Consolidate TFMs
DocSvartz Mar 25, 2026
3f05df6
fix: #893
DocSvartz Mar 25, 2026
0721ae0
chore: Bump Version to 10.0.5
DocSvartz Mar 25, 2026
e06d96a
chore: Merge pull request #894 from DocSvartz/build-simplicate-part-2
DocSvartz Mar 25, 2026
3ea2df4
fix: Regression in v10 - ConstructUsing and MapToConstructor was disa…
DocSvartz Mar 26, 2026
e192f41
chore: Bump version to 10.0.6 (#897)
DocSvartz Mar 26, 2026
39a4ca4
fix: regression when update required property (#902)
DocSvartz Mar 29, 2026
1117602
fix: added Null Propagation improvement for constructor (#903)
DocSvartz Mar 29, 2026
4ceb064
chore: Bump Version to 10.0.7-pre01
DocSvartz Mar 29, 2026
6a581ce
chore: Merge pull request #904 from DocSvartz/d26
DocSvartz Mar 29, 2026
5848f85
fix: fix bug in #903. Drop collect ctor param with Getter == null
DocSvartz Mar 30, 2026
f9a44f6
feat(test): add test for new behavior Property NullablePropagation
DocSvartz Mar 30, 2026
d88d346
fix: add new Property NullablePropagation
DocSvartz Mar 30, 2026
d27d466
chore: Bump version to 10.0.7-pre02
DocSvartz Mar 30, 2026
456502f
chore: Merge pull request #905 from DocSvartz/d26
DocSvartz Mar 30, 2026
ec6cf52
feat(test): replace RequiredProperty test and new Polymorphic test
DocSvartz Mar 31, 2026
a06ce02
fix: #906 - InvalidCastException when using polymorphic mapping with …
DocSvartz Mar 31, 2026
c049cf6
chore: Bump Version to 10.0.7-pre03
DocSvartz Mar 31, 2026
6d82c35
chore: Merge pull request #907 from DocSvartz/d26
DocSvartz Mar 31, 2026
8b02e28
fix: re-fix #858 and fix IgnoreNullValues regression from MapToTarget…
DocSvartz Apr 1, 2026
731af09
chore: Bump version to 10.0.7-pre04
DocSvartz Apr 1, 2026
7278f90
chore: Merge pull request #909 from DocSvartz/d27
DocSvartz Apr 1, 2026
1fcf33b
fix: #911- return in 7.4.0 behavior for types cannot be instantiated …
DocSvartz Apr 7, 2026
0f0f2fb
chore: Merge pull request #912 from DocSvartz/IsNotSelfCreation
DocSvartz Apr 7, 2026
27f41a4
chore: Bump version to 10.0.7 - Release
DocSvartz Apr 7, 2026
98962ae
chore: Merge pull request #913 from DocSvartz/d28
DocSvartz Apr 7, 2026
56935ea
--Duplicate .\Data-types.md history into .\data-types\Record-types.md
DocSvartz Apr 8, 2026
491eec7
--Restore .\Data-types.md
DocSvartz Apr 8, 2026
6161c27
Copy .\Data-types.md into .\data-types\Record-types.md
DocSvartz Apr 8, 2026
4bccc4c
--Duplicate .\Data-types.md history into .\data-types\Mapping-types.md
DocSvartz Apr 8, 2026
d84b3e7
--Restore .\Data-types.md
DocSvartz Apr 8, 2026
ba539d7
Copy .\Data-types.md into .\data-types\Mapping-types.md
DocSvartz Apr 8, 2026
f863678
--Duplicate .\Data-types.md history into .\data-types\Primitive-types.md
DocSvartz Apr 8, 2026
1878ffe
--Restore .\Data-types.md
DocSvartz Apr 8, 2026
9c4bb89
Copy .\Data-types.md into .\data-types\Primitive-types.md
DocSvartz Apr 8, 2026
e34d659
--Duplicate .\Data-types.md history into .\data-types\Mappable-Object…
DocSvartz Apr 8, 2026
c075df5
--Restore .\Data-types.md
DocSvartz Apr 8, 2026
41af9e4
Copy .\Data-types.md into .\data-types\Mappable-Objects.md
DocSvartz Apr 8, 2026
1590468
--Duplicate .\Data-types.md history into .\data-types\Collections.md
DocSvartz Apr 8, 2026
7edece5
--Restore .\Data-types.md
DocSvartz Apr 8, 2026
4682eb9
Copy .\Data-types.md into .\data-types\Collections.md
DocSvartz Apr 8, 2026
7cb1f6d
fix(docs): copy data to new articles
DocSvartz Apr 8, 2026
d3bc578
fix(docs): fix links
DocSvartz Apr 8, 2026
966589e
fix(docs): drop Data-types.md and fix links
DocSvartz Apr 8, 2026
fe82ce0
feat: add Flattening mapping for all source type only primitive
DocSvartz Apr 8, 2026
c28ab9b
chore: Merge pull request #916 from DocSvartz/add-flatenning-to-inter…
DocSvartz Apr 14, 2026
4a6c544
chore: Bump version to 10.0.8-pre01
DocSvartz Apr 14, 2026
f82047c
chore: Merge pull request #917 from DocSvartz/d31
DocSvartz Apr 14, 2026
388602b
fix: fix IsNotSelfCreation detect from #918
DocSvartz Apr 20, 2026
120ac3c
chore: Merge pull request #919 from DocSvartz/d31
DocSvartz Apr 20, 2026
5bb4d26
chore: Bump version to 10.0.8-pre02
DocSvartz Apr 20, 2026
bcea4f3
chore: Merge pull request #920 from DocSvartz/d31
DocSvartz Apr 20, 2026
7e83af0
fix: fix race condition when mapping to RecordType using IgnoreNullVa…
DocSvartz Apr 21, 2026
e1f9190
chore: Bump version to 10.0.8-pre03
DocSvartz Apr 21, 2026
cf343ee
chore: Merge pull request #923 from DocSvartz/d31
DocSvartz Apr 21, 2026
d148117
fix: fix IgnoreNonMapped member collector #924
DocSvartz Apr 24, 2026
06535e6
fix: #928 - not creation abstract destination if souce is null
DocSvartz Apr 27, 2026
15daf08
feat(test): add test from # 928
DocSvartz Apr 27, 2026
8bb3051
fix: #927 add skip if destination member is not setter
DocSvartz Apr 28, 2026
5444cfa
fix: #925 - Compile config with open generic is not throw exception
DocSvartz Apr 28, 2026
0fdc7fa
chore: Merge pull request #929 from DocSvartz/fix-ignoreNonMappedMemb…
DocSvartz Apr 28, 2026
04abab2
chore: Merge pull request #933 from DocSvartz/fix-928
DocSvartz Apr 28, 2026
2924ac4
chore: Merge pull request #934 from DocSvartz/fix-927
DocSvartz Apr 28, 2026
49a8748
chore: Merge pull request #935 from DocSvartz/fix-#925
DocSvartz Apr 28, 2026
f7abb5f
feat(test): add tests to case in #927
DocSvartz Apr 28, 2026
a0cd3c1
chore: Bump version to 10.0.8-pre04
DocSvartz Apr 28, 2026
1f6d3e7
chore: Merge pull request #936 from DocSvartz/d32
DocSvartz Apr 28, 2026
1aaa504
feat: #938 - Add DirectAssignmentForSameType setting parametr
DocSvartz Apr 29, 2026
e8d12a7
fix: #925 disable Compile check for open generic configs
DocSvartz May 5, 2026
290417f
fix: refactoring and fix DirectAssignmentForSameType implementation
DocSvartz May 6, 2026
9bbb178
chore: Merge pull request #941 from DocSvartz/feat-938
DocSvartz May 6, 2026
d72876e
chore: Merge pull request #942 from DocSvartz/disable-check-for-OpenG…
DocSvartz May 6, 2026
1d89074
chore: Bump version to 10.0.8-pre05
DocSvartz May 6, 2026
75231f0
fix: refactoring fix #903
DocSvartz May 9, 2026
f1f264a
feat(test): add test to #943
DocSvartz May 9, 2026
a87a5f8
fix: #943
DocSvartz May 9, 2026
231c0fe
chore: Merge pull request #945 from DocSvartz/Refactoring-fix-#903-an…
DocSvartz May 12, 2026
d1dc709
chore: Bump version to 10.0.8-pre06
DocSvartz May 12, 2026
e35dc29
feat(benchmark): fix and actualize Benchmark project
Qyperion May 12, 2026
b72cc01
docs: actualize benchmark result in docs
Qyperion May 12, 2026
d856d0e
feat(benchmark): refactor benchmarks: add flat, recursive, complex sc…
Qyperion May 15, 2026
c89a232
docs: add benchmark docs page and actualize results
Qyperion May 15, 2026
0562073
fix(docs): replace Benchmark project link in README.md
Qyperion May 17, 2026
2dcc8a0
chore: Merge pull request #946 from Qyperion/actualize-benchmark
DocSvartz May 17, 2026
19c2b77
chore: Merge pull request #914 from DocSvartz/docs-separate-datatypes
DocSvartz May 18, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
30 changes: 19 additions & 11 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -141,21 +141,29 @@ public static class StudentMapper {

### Performance & Memory efficient

Mapster was designed to be efficient on both speed and memory. You could gain a 4x performance improvement whilst using only 1/3 of memory.
And you could gain up to 12x faster performance with:
Mapster was designed to be efficient on both speed and memory. The repository includes a benchmark project in [`src/Benchmark`](https://github.com/MapsterMapper/Mapster/tree/master/src/Benchmark) that compares the local Mapster build, its compiler variants, and other modern mapping libraries like AutoMapper, Mapperly, and Facet.

- [Roslyn Compiler](https://mapstermapper.github.io/Mapster/articles/packages/ExpressionDebugging.html)
- [FEC](https://mapstermapper.github.io/Mapster/articles/packages/FastExpressionCompiler.html)
- Code generation

| Method | Mean | StdDev | Error | Gen 0 | Gen 1 | Gen 2 | Allocated |
|-------------------------- |----------:|----------:|----------:|-----------:|------:|------:|----------:|
| 'Mapster 6.0.0' | 108.59 ms | 1.198 ms | 1.811 ms | 31000.0000 | - | - | 124.36 MB |
| 'Mapster 6.0.0 (Roslyn)' | 38.45 ms | 0.494 ms | 0.830 ms | 31142.8571 | - | - | 124.36 MB |
| 'Mapster 6.0.0 (FEC)' | 37.03 ms | 0.281 ms | 0.472 ms | 29642.8571 | - | - | 118.26 MB |
| 'Mapster 6.0.0 (Codegen)' | 34.16 ms | 0.209 ms | 0.316 ms | 31133.3333 | - | - | 124.36 MB |
| 'ExpressMapper 1.9.1' | 205.78 ms | 5.357 ms | 8.098 ms | 59000.0000 | - | - | 236.51 MB |
| 'AutoMapper 10.0.0' | 420.97 ms | 23.266 ms | 35.174 ms | 87000.0000 | - | - | 350.95 MB |
- Facet
- Mapperly

The snapshot below shows the `FlatTypes` scenario (`Person -> PersonDTO`), a best-case DTO with simple property-to-property mapping and no nested objects or collections.

> [!NOTE]
> More complex object shapes can change the relative results. See the [complete benchmark results](https://mapstermapper.github.io/Mapster/articles/benchmarks.html) for `ComplexTypes`, `RecursiveTypes`, and `TotalAllTypes`.

| Method | MapOperations | Mean | StdDev | Error | Ns/Map | Ratio | Gen0 | Allocated | Alloc Ratio | Bytes/Map |
|------------------------------------ |-------------- |----------:|----------:|----------:|-------:|------:|-----:|----------:|------------:|----------:|
| `Mapster 10.0.7` | 1000000 | 6.849 ms | 0.6851 ms | 1.0358 ms | 6.849 | 1.01 | 4781 | 76.29 MB | 1.00 | 80 |
| `Mapster 10.0.7 (Roslyn)` | 1000000 | 6.579 ms | 0.2782 ms | 0.4206 ms | 6.579 | 0.97 | 4781 | 76.29 MB | 1.00 | 80 |
| `Mapster 10.0.7 (FEC)` | 1000000 | 6.549 ms | 0.9130 ms | 1.3803 ms | 6.549 | 0.97 | 4781 | 76.29 MB | 1.00 | 80 |
| `Mapster 10.0.7 (Codegen)` | 1000000 | 5.868 ms | 0.3266 ms | 0.5488 ms | 5.868 | 0.86 | 4781 | 76.29 MB | 1.00 | 80 |
| `AutoMapper 14.0.0` | 1000000 | 29.645 ms | 0.8963 ms | 1.5062 ms | 29.645 | 4.37 | 4750 | 76.29 MB | 1.00 | 80 |
| `Facet 6.5.5` | 1000000 | 7.801 ms | 1.0231 ms | 1.5467 ms | 7.801 | 1.15 | 8601 | 137.33 MB | 1.80 | 144 |
| `Facet 6.5.5 (Compiled Projection)` | 1000000 | 5.508 ms | 0.7064 ms | 1.0679 ms | 5.508 | 0.81 | 4781 | 76.29 MB | 1.00 | 80 |
| `Mapperly 4.3.1` | 1000000 | 6.521 ms | 0.8369 ms | 1.2652 ms | 6.521 | 0.96 | 4781 | 76.29 MB | 1.00 | 80 |

### Step into debugging

Expand Down
4 changes: 2 additions & 2 deletions docs/api/Reference.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ uid: Mapster.References
| `src.Adapt<Dest>()` | Mapping to new type | [basic](xref:Mapster.Mapping.BasicUsages) |
| `src.Adapt(dest)` | Mapping to existing object | [basic](xref:Mapster.Mapping.BasicUsages) |
| `query.ProjectToType<Dest>()` | Mapping from queryable | [basic](xref:Mapster.Mapping.BasicUsages) |
| | Convention & Data type support | [data types](xref:Mapster.Mapping.DataTypes) |
| | Convention & Data type support | [data types](xref:Mapster.Mapping.DataTypes.Overview) |

### Mapper instance (for dependency injection)

Expand Down Expand Up @@ -84,7 +84,7 @@ uid: Mapster.References
| `BeforeMapping` | Add steps before mapping start | | [before-after](xref:Mapster.Settings.BeforeAfterMapping) |
| `ConstructUsing` | Define how to create object | x | [constructor](xref:Mapster.Settings.ConstructorMapping) |
| `EnableNonPublicMembers` | Mapping non-public properties | | [non-public](xref:Mapster.Settings.Custom.NonPublicMembers) |
| `EnumMappingStrategy` | Choose whether mapping enum by value or by name | | [data types](xref:Mapster.Mapping.DataTypes) |
| `EnumMappingStrategy` | Choose whether mapping enum by value or by name | | [data types](xref:Mapster.Mapping.DataTypes.Primitives) |
| `Fork` | Add new settings without side effect on main config | x | [nested mapping](xref:Mapster.Configuration.NestedMapping) |
| `GetMemberName` | Define how to resolve property name | x | [custom naming](xref:Mapster.Settings.Custom.NamingConvention) |
| `Ignore` | Ignore specific properties | x | [ignore](xref:Mapster.Settings.Custom.IgnoringMembers) |
Expand Down
5 changes: 5 additions & 0 deletions docs/articles/_Sidebar.md
Original file line number Diff line number Diff line change
Expand Up @@ -54,3 +54,8 @@
* [Fluent API](https://github.com/MapsterMapper/Mapster/wiki/Fluent-API-Code-generation)
* [Attributes](https://github.com/MapsterMapper/Mapster/wiki/Attribute-base-Code-generation)
* [Interfaces](https://github.com/MapsterMapper/Mapster/wiki/Interface-base-Code-generation)

## Benchmarks

* [Benchmark results](https://mapstermapper.github.io/Mapster/articles/benchmarks.html)
*
103 changes: 103 additions & 0 deletions docs/articles/benchmarks.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,103 @@
---
uid: Mapster.Benchmarks
title: "Benchmark results"
---

Mapster includes a benchmark project in [`src/Benchmark`](https://github.com/MapsterMapper/Mapster/tree/master/src/Benchmark) that compares the local Mapster build with AutoMapper, Facet, and Mapperly across several object shapes.

This page is a May 2026 snapshot of those benchmarks. Treat the numbers as a comparison point for this environment and benchmark configuration rather than an absolute guarantee for every machine or application.

## How to read the tables

- `Mean` is the total time for one BenchmarkDotNet benchmark invocation. Each invocation runs a manual hot loop with `MapOperations = 1,000,000`.
- `Ns/Map` normalizes `Mean` to the approximate cost of one logical mapping call.
- `Allocated` is the memory allocated by one benchmark invocation.
- `Bytes/Map` normalizes `Allocated` to one logical mapping call.
- `Ratio` and `Alloc Ratio` are relative to the default Mapster benchmark in the same scenario.
- `TotalAllTypes` runs three mapping scenarios in one benchmark invocation, so its `Ns/Map` and `Bytes/Map` values are divided by `MapOperations * 3`.

## Benchmark scenarios

### FlatTypes

`FlatTypes` maps `Person -> PersonDTO`. It is a flat DTO shape: simple property-to-property copy, no nested objects, and no collections. This scenario mostly highlights mapper call overhead, generated IL quality, and allocation rate for a best-case DTO.

### ComplexTypes

`ComplexTypes` maps `Customer -> CustomerDTO`. It includes nested address mapping, array/list shape changes, and a flattening rule (`AddressCity <- Address.City`). This scenario is useful for typical DTOs that combine nested objects, collections, and a small amount of custom member mapping.

### RecursiveTypes

`RecursiveTypes` maps `Foo -> FooDTO`. The type shape is self-recursive: a `Foo` can contain another `Foo`, an enumerable of `Foo`, and an array of `Foo`. The sample data does not intentionally create a back-reference cycle, but the mapping graph is deeper and allocates more nested DTOs than the flat or customer scenarios.

### TotalAllTypes

`TotalAllTypes` runs `FlatTypes`, `RecursiveTypes`, and `ComplexTypes` sequentially in one benchmark method. `Mean` is therefore the total batch time for all three scenarios; use `Ns/Map` and `Bytes/Map` for normalized per-map interpretation.

## Compared methods

- `Mapster` uses the default Mapster expression compiler.
- `Mapster (Roslyn)` uses the Roslyn/debug-info compiler path.
- `Mapster (FEC)` uses FastExpressionCompiler.
- `Mapster (Codegen)` uses generated mapping code.
- `AutoMapper`, `Facet`, and `Mapperly` are included as external comparison points.
- `Facet (Compiled Projection)` uses Facet's compiled projection path, which can behave very differently from the constructor path depending on the object shape.

## Results

### FlatTypes

| Scenario | Method | MapOperations | Mean | StdDev | Error | Ns/Map | Ratio | Gen0 | Allocated | Alloc Ratio | Bytes/Map |
|---------- |------------------------------------ |-------------- |----------:|----------:|----------:|-------:|------:|-----:|----------:|------------:|----------:|
| FlatTypes | `Mapster 10.0.7` | 1000000 | 6.849 ms | 0.6851 ms | 1.0358 ms | 6.849 | 1.01 | 4781 | 76.29 MB | 1.00 | 80 |
| FlatTypes | `Mapster 10.0.7 (Roslyn)` | 1000000 | 6.579 ms | 0.2782 ms | 0.4206 ms | 6.579 | 0.97 | 4781 | 76.29 MB | 1.00 | 80 |
| FlatTypes | `Mapster 10.0.7 (FEC)` | 1000000 | 6.549 ms | 0.9130 ms | 1.3803 ms | 6.549 | 0.97 | 4781 | 76.29 MB | 1.00 | 80 |
| FlatTypes | `Mapster 10.0.7 (Codegen)` | 1000000 | 5.868 ms | 0.3266 ms | 0.5488 ms | 5.868 | 0.86 | 4781 | 76.29 MB | 1.00 | 80 |
| FlatTypes | `AutoMapper 14.0.0` | 1000000 | 29.645 ms | 0.8963 ms | 1.5062 ms | 29.645 | 4.37 | 4750 | 76.29 MB | 1.00 | 80 |
| FlatTypes | `Facet 6.5.5` | 1000000 | 7.801 ms | 1.0231 ms | 1.5467 ms | 7.801 | 1.15 | 8601 | 137.33 MB | 1.80 | 144 |
| FlatTypes | `Facet 6.5.5 (Compiled Projection)` | 1000000 | 5.508 ms | 0.7064 ms | 1.0679 ms | 5.508 | 0.81 | 4781 | 76.29 MB | 1.00 | 80 |
| FlatTypes | `Mapperly 4.3.1` | 1000000 | 6.521 ms | 0.8369 ms | 1.2652 ms | 6.521 | 0.96 | 4781 | 76.29 MB | 1.00 | 80 |

### ComplexTypes

| Scenario | Method | MapOperations | Mean | StdDev | Error | Ns/Map | Ratio | Gen0 | Gen1 | Allocated | Alloc Ratio | Bytes/Map |
|------------- |------------------------------------ |-------------- |----------:|----------:|----------:|--------:|------:|-------:|-----:|-----------:|------------:|----------:|
| ComplexTypes | `Mapster 10.0.7` | 1000000 | 78.59 ms | 1.519 ms | 2.553 ms | 78.586 | 1.00 | 28111 | - | 450.13 MB | 1.00 | 472 |
| ComplexTypes | `Mapster 10.0.7 (Roslyn)` | 1000000 | 53.48 ms | 1.760 ms | 2.958 ms | 53.475 | 0.68 | 25818 | - | 411.99 MB | 0.92 | 432 |
| ComplexTypes | `Mapster 10.0.7 (FEC)` | 1000000 | 69.29 ms | 1.539 ms | 2.326 ms | 69.288 | 0.88 | 28200 | - | 450.13 MB | 1.00 | 472 |
| ComplexTypes | `Mapster 10.0.7 (Codegen)` | 1000000 | 51.86 ms | 2.514 ms | 3.801 ms | 51.863 | 0.66 | 25750 | - | 411.99 MB | 0.92 | 432 |
| ComplexTypes | `AutoMapper 14.0.0` | 1000000 | 112.27 ms | 4.516 ms | 7.590 ms | 112.270 | 1.43 | 29142 | - | 465.39 MB | 1.03 | 488 |
| ComplexTypes | `Facet 6.5.5` | 1000000 | 446.72 ms | 51.706 ms | 78.172 ms | 446.725 | 5.69 | 175000 | 500 | 2792.36 MB | 6.20 | 2928 |
| ComplexTypes | `Facet 6.5.5 (Compiled Projection)` | 1000000 | 678.87 ms | 42.646 ms | 64.474 ms | 678.868 | 8.64 | 44000 | - | 709.53 MB | 1.58 | 744 |
| ComplexTypes | `Mapperly 4.3.1` | 1000000 | 52.81 ms | 1.134 ms | 1.714 ms | 52.812 | 0.67 | 25769 | - | 411.99 MB | 0.92 | 432 |

### RecursiveTypes

| Scenario | Method | MapOperations | Mean | StdDev | Error | Ns/Map | Ratio | Gen0 | Gen1 | Allocated | Alloc Ratio | Bytes/Map |
|--------------- |------------------------------------ |-------------- |----------:|----------:|----------:|--------:|------:|-------:|-----:|-----------:|------------:|----------:|
| RecursiveTypes | `Mapster 10.0.7` | 1000000 | 404.49 ms | 63.593 ms | 96.14 ms | 404.486 | 1.02 | 49000 | - | 793.46 MB | 1.00 | 832 |
| RecursiveTypes | `Mapster 10.0.7 (Roslyn)` | 1000000 | 383.00 ms | 34.563 ms | 52.25 ms | 382.999 | 0.97 | 49000 | - | 793.46 MB | 1.00 | 832 |
| RecursiveTypes | `Mapster 10.0.7 (FEC)` | 1000000 | 84.82 ms | 10.777 ms | 16.29 ms | 84.816 | 0.21 | 45875 | 125 | 732.42 MB | 0.92 | 768 |
| RecursiveTypes | `Mapster 10.0.7 (Codegen)` | 1000000 | 82.81 ms | 11.104 ms | 16.79 ms | 82.806 | 0.21 | 49625 | 125 | 793.46 MB | 1.00 | 832 |
| RecursiveTypes | `AutoMapper 14.0.0` | 1000000 | 585.42 ms | 88.660 ms | 134.04 ms | 585.425 | 1.48 | 168000 | 1000 | 2693.18 MB | 3.39 | 2824 |
| RecursiveTypes | `Facet 6.5.5` | 1000000 | 302.24 ms | 9.444 ms | 18.06 ms | 302.241 | 0.76 | 150000 | 666 | 2395.63 MB | 3.02 | 2512 |
| RecursiveTypes | `Facet 6.5.5 (Compiled Projection)` | 1000000 | 708.77 ms | 58.207 ms | 88.00 ms | 708.770 | 1.79 | 73000 | - | 1174.93 MB | 1.48 | 1232 |
| RecursiveTypes | `Mapperly 4.3.1` | 1000000 | 116.05 ms | 16.639 ms | 25.16 ms | 116.055 | 0.29 | 68833 | 166 | 1098.63 MB | 1.38 | 1152 |

### TotalAllTypes

| Scenario | Method | MapOperations | Mean | StdDev | Error | Ns/Map | Ratio | Gen0 | Gen1 | Allocated | Alloc Ratio | Bytes/Map |
|-------------- |------------------------------------ |-------------- |-----------:|---------:|----------:|-------:|------:|-------:|-----:|----------:|------------:|----------:|
| TotalAllTypes | `Mapster 10.0.7` | 1000000 | 413.9 ms | 16.88 ms | 25.52 ms | 137.97 | 1.00 | 82000 | - | 1.29 GB | 1.00 | 461 |
| TotalAllTypes | `Mapster 10.0.7 (Roslyn)` | 1000000 | 546.4 ms | 29.01 ms | 43.86 ms | 182.12 | 1.32 | 80000 | - | 1.25 GB | 0.97 | 448 |
| TotalAllTypes | `Mapster 10.0.7 (FEC)` | 1000000 | 155.7 ms | 24.48 ms | 37.01 ms | 51.91 | 0.38 | 78800 | - | 1.23 GB | 0.95 | 440 |
| TotalAllTypes | `Mapster 10.0.7 (Codegen)` | 1000000 | 117.4 ms | 8.56 ms | 12.94 ms | 39.14 | 0.28 | 80250 | - | 1.25 GB | 0.97 | 448 |
| TotalAllTypes | `AutoMapper 14.0.0` | 1000000 | 681.4 ms | 76.25 ms | 115.27 ms | 227.13 | 1.65 | 202000 | 1000 | 3.16 GB | 2.45 | 1130 |
| TotalAllTypes | `Facet 6.5.5` | 1000000 | 677.4 ms | 33.30 ms | 55.96 ms | 225.80 | 1.64 | 329000 | 1000 | 5.14 GB | 3.99 | 1840 |
| TotalAllTypes | `Facet 6.5.5 (Compiled Projection)` | 1000000 | 1,337.4 ms | 42.95 ms | 64.94 ms | 445.81 | 3.24 | 122000 | - | 1.91 GB | 1.49 | 685 |
| TotalAllTypes | `Mapperly 4.3.1` | 1000000 | 141.5 ms | 3.04 ms | 5.81 ms | 47.10 | 0.34 | 99250 | 250 | 1.55 GB | 1.20 | 554 |

## Interpretation notes

- The fastest method depends on the object shape. Flat DTOs mostly measure low-level call overhead; recursive graphs and collection-heavy DTOs shift the bottleneck toward nested object creation and collection mapping.
- `Facet` constructor and compiled-projection paths are shown separately because they exercise different APIs and can trade CPU time for allocation behavior differently across scenarios.
Loading
Loading