What's Changed
✨ Features
📦 formatter
- implement MemoryPack-inspired high-performance custom formatter system [5d6be51] by @JasonXuDeveloper
📦 generator
- add ConcurrentQueue and ConcurrentStack support [a9cddb4] by @JasonXuDeveloper
- add multi-dimensional array support [47279ab] by @JasonXuDeveloper
- add new collection type generators and optimize unmanaged types [60d4831] by @JasonXuDeveloper
- allow inheritance over
[NinoType][7cf3ae5] by @JasonXuDeveloper - expose NinoBuiltInTypesRegistration as public [b1288f2] by @JasonXuDeveloper
- support NinoTypes from referenced assemblies [a2591b9] by @JasonXuDeveloper
📦 serialization
- add boxed object support for generic type serialization with restrictions [8fc6476] by @JasonXuDeveloper
📦 workflow
- add benchmark posting to secure workflow [4fc1433] by @JasonXuDeveloper
🐛 Bug Fixes
🔧 General
- always commit Unity DLL updates to main branch for all releases [dba0eda] by @JasonXuDeveloper
- clean up temporary branch after Unity DLL push [c4aa14c] by @JasonXuDeveloper
- correct release workflow DLL copy path for Nino.Generator [b58708b] by @JasonXuDeveloper
- ensure Unity DLL updates reach main branch for stable releases [fb0edd9] by @JasonXuDeveloper
- ensure temporary branch cleanup even on push failure [454a334] by @JasonXuDeveloper
- restore complete CLAUDE.md with all original instructions [5aa8f43] by @JasonXuDeveloper
📦 ci
- correct DLL copy paths in release workflow [cb7051d] by @JasonXuDeveloper
- move release tag to Unity DLL commit for UPM compatibility [df7b32c] by @JasonXuDeveloper
- prevent canceling previous CI runs on non-code changes [b8e0cdf] by @JasonXuDeveloper
📦 generator
- capture member types from parsed Nino types to include generic field types [6cc5636] by @JasonXuDeveloper
- check type argument accessibility recursively to prevent CS0051 errors [271b99e] by @JasonXuDeveloper
- check type argument accessibility recursively to prevent CS0051 errors [fbaf9d1] by @JasonXuDeveloper
- ensure all NinoType members use CachedDeserializer [ecca399] by @JasonXuDeveloper
- implement offset-based UPM preview version increments [6aa92f0] by @JasonXuDeveloper
- improve ArraySegment fast path implementation [37e4d59] by @JasonXuDeveloper
- modify emit namespace and improve GetKind correctness [c7c0a29] by @JasonXuDeveloper
- resolve IDE duplicate code issue with comprehensive deduplication [3fa682c] by @JasonXuDeveloper
- restore member type validation checks [8a590ba] by @JasonXuDeveloper
- suppress CS8669 nullable annotation warnings in generated code [335b43e] by @JasonXuDeveloper
- use CustomDeserializer instead of CustomSerializer for deserializer prefix [52f85cd] by @JasonXuDeveloper
- use tempDict for ReadOnlyDictionary with unmanaged KVP [6d20a9f] by @JasonXuDeveloper
📦 serialization
- fix nullable type handling and restore tuple grouping in deserializer [cc675c6] by @JasonXuDeveloper
📦 workflow
- use GitHub API to download artifacts from workflow_run [ab102aa] by @JasonXuDeveloper
⚡ Performance
🔧 General
- optimize deserializer to use UnsafeRead for unmanaged types [8505fb6] by @JasonXuDeveloper
📦 core
- add thread-local buffer pooling and volatile cache access [c6bc61f] by @JasonXuDeveloper
- add thread-local cache for polymorphic serialization [519ad0b] by @JasonXuDeveloper
- implement lock-free type registration with CAS [c7188b8] by @JasonXuDeveloper
- optimize FastMap by removing System.Numerics dependency [aa99377] by @JasonXuDeveloper
- optimize buffer management and array serialization [cbe7303] by @JasonXuDeveloper
- optimize polymorphic serialization with per-instance caching [ca9fdb9] by @JasonXuDeveloper
- remove inline cache from polymorphic serialization [722ca4b] by @JasonXuDeveloper
- use shared volatile cache for polymorphic serialization [3ccbd64] by @JasonXuDeveloper
📦 deserializer
- optimize CachedDeserializer with direct typeId lookup [27159dc] by @JasonXuDeveloper
📦 generator
- add aggressive inlining to SerializeImpl/DeserializeImpl methods [6bbaeea] by @JasonXuDeveloper
- inline sealed type serialization to eliminate delegate overhead [cb7f33c] by @JasonXuDeveloper
- move AggressiveInlining from NinoType impls to built-in types [f5e0d6c] by @JasonXuDeveloper
- optimize collection deserialization with three-phase ref overload and Array.Resize pattern [c92f070] by @JasonXuDeveloper
- skip code generation when Nino.Core is not used [21006f3] by @JasonXuDeveloper
📦 serialization
- optimize array ref overloads with Array.Resize and object reuse [ea6c808] by @JasonXuDeveloper
- optimize dictionary and array loops [7f93c22] by @JasonXuDeveloper
- optimize polymorphic handling with static wrappers [e80031a] by @JasonXuDeveloper
📦 serializer
- add inline caching for polymorphic serialization/deserialization [c538842] by @JasonXuDeveloper
- optimize polymorphic type resolution with multiple strategies [672c2c3] by @JasonXuDeveloper
🔧 Improvements
📦 generator
- add type hierarchy ordering and pre-filtering for built-in type generation [074c2a2] by @JasonXuDeveloper
- consolidate built-in type generators into unified output [975bc7d] by @JasonXuDeveloper
- dramatically simplify deserializer generator with 64% code reduction [7df5751] by @JasonXuDeveloper
- extract built-in type generation framework and implement nullable types [b1348ba] by @JasonXuDeveloper
- migrate KeyValuePair and Tuple to dedicated generators with shared helpers [0dbab00] by @JasonXuDeveloper
- migrate collection types to built-in generator framework with optimized List ref handling [b340785] by @JasonXuDeveloper
- optimize fast path detection and add ArraySegment fast path support [4109053] by @JasonXuDeveloper
- optimize type validation with iterative algorithm and extract nested type discovery [e885ded] by @JasonXuDeveloper
- remove overly strict member type validation [33353db] by @JasonXuDeveloper
- simplify GetNinoTypeAttribute and fix minor issues [d09252e] by @JasonXuDeveloper
- simplify type discovery pipeline and remove redundant code [b3109f1] by @JasonXuDeveloper
- use GetKind pattern and NinoTuple for grouped deserialization [451acf6] by @JasonXuDeveloper
📦 serializer
- convert CachedSerializer and CachedDeserializer to static classes [9bb574b] by @JasonXuDeveloper
📚 Documentation
🔧 General
- add DeepWiki badge to README [870def1] by @JasonXuDeveloper
- merge CLAUDE.md files into unified root configuration [9baae43] by @JasonXuDeveloper
- merge CLAUDE.md files into unified root configuration [b268b2e] by @JasonXuDeveloper
📦 generator
- translate Chinese comments to English [254d5aa] by @JasonXuDeveloper
🧪 Testing
📦 analyzer
- fix inheritance analyzer test expectations [befba6e] by @JasonXuDeveloper
📦 serialization
- add comprehensive array shrinking test for ref overload [f935e24] by @JasonXuDeveloper
🏗️ Maintenance
🔧 General
- add Claude Code development environment and tooling [1b149f3] by @JasonXuDeveloper
- add Claude Flow development environment and metrics [7af6abf] by @JasonXuDeveloper
- ignore Claude Flow metrics files and remove from tracking [f5f5478] by @JasonXuDeveloper
- remove remaining Claude Flow metrics files and update docs [a14a045] by @JasonXuDeveloper
- update Claude Flow metrics to latest state [29d5191] by @JasonXuDeveloper
📦 ci
- optimize workflow with path-based change detection [ed6dc3a] by @JasonXuDeveloper
📦 generator
- guard memorymarshal helpers for unity [cbd0313] by @JasonXuDeveloper
📦 repo
- remove CLAUDE.md from version control [f576d7b] by @JasonXuDeveloper
- remove LLM agent configuration files and exclude from version control [5f27fda] by @JasonXuDeveloper
🔀 Other Changes
📦 other
- "Update Claude Code Review workflow" [aec6819] by @JasonXuDeveloper
- "Update Claude PR Assistant workflow" [59b79a5] by @JasonXuDeveloper
- Add Claude Code GitHub Workflow (#159) [37abd2d] by @JasonXuDeveloper
- Merge branch 'main' of https://github.com/JasonXuDeveloper/Nino [d9d98c2] by @JasonXuDeveloper
- Merge remote-tracking branch 'origin/main' into pr-work [dc40a40] by @JasonXuDeveloper
- ci(workflow): add github_token to fix OIDC authentication error [344ff8f] by @JasonXuDeveloper
- ci(workflow): implement two-workflow handoff for secure fork PR reviews [5d3068f] by @JasonXuDeveloper
- ci(workflow): switch to pull_request_target for forked PR secret access [67177d4] by @JasonXuDeveloper
- ci(workflow): use pull_request trigger for immediate workflow updates [5a48135] by @JasonXuDeveloper
- ci: fix Claude Code Review workflow configuration [adc309b] by @JasonXuDeveloper
- ci: fix benchmark results detection [544f583] by @JasonXuDeveloper
- ci: run benchmarks on PRs and post results as comments [2873746] by @JasonXuDeveloper
- fix: resolve deserialization issue with nested complex types (#157) [45c68b0] by @JasonXuDeveloper
- temporary unity ci removal [b38bf17] by @JasonXuDeveloper
- 增加继承父类NinoType [fd6c905] by @wang-er-s
👥 Contributors
Full Changelog: https://github.com/JasonXuDeveloper/Nino/compare/v4.0.0-beta.8..v4.0.0-beta.29
⚠️ Pre-release - Use with caution in production
Installation
NuGet:
dotnet add package Nino --version 4.0.0-beta.29
Unity: Preview version available via UPM
📊 Performance Report
Click to expand benchmark results
BenchmarkDotNet v0.15.2, Linux Ubuntu 24.04.3 LTS (Noble Numbat)
AMD EPYC 7763, 1 CPU, 4 logical and 2 physical cores
.NET SDK 9.0.305
[Host] : .NET 8.0.20 (8.0.2025.41914), X64 RyuJIT AVX2
ShortRun-.NET 9.0 : .NET 9.0.9 (9.0.925.41916), X64 RyuJIT AVX2
Job=ShortRun-.NET 9.0 Runtime=.NET 9.0 Server=True
IterationCount=3 LaunchCount=1 WarmupCount=3
| Type | Method | Mean | Min | Max | Ratio | Payload | Gen0 | Gen1 | Gen2 | Allocated | Alloc Ratio |
|---|---|---|---|---|---|---|---|---|---|---|---|
| PolymorphicTest | NinoDeserializePolymorphicClasses | 144,029.6230 ns | 142,083.2711 ns | 147,245.3351 ns | 1.00 | - | 22.2168 | 7.3242 | - | 341624 B | 1.00 |
| PolymorphicTest | MemoryPackDeserializePolymorphicClasses | 131,442.2163 ns | 128,812.4078 ns | 134,472.6049 ns | 0.91 | - | 21.7285 | 7.0801 | - | 341624 B | 1.00 |
| PolymorphicTest | MessagePackDeserializePolymorphicClasses | 572,407.3843 ns | 559,700.4692 ns | 582,280.4058 ns | 3.98 | - | 43.9453 | 15.6250 | - | 758424 B | 2.22 |
| PolymorphicTest | NinoSerializePolymorphicClasses | 55,919.3884 ns | 55,876.8786 ns | 55,970.3492 ns | 1.00 | 136.72KB | - | - | - | - | NA |
| PolymorphicTest | MemoryPackSerializePolymorphicClasses | 124,161.1701 ns | 124,050.8647 ns | 124,274.9194 ns | 2.22 | 135.26KB | - | - | - | - | NA |
| PolymorphicTest | MessagePackSerializePolymorphicClasses | 164,207.6862 ns | 163,928.9535 ns | 164,756.2137 ns | 2.94 | 100.98KB | - | - | - | - | NA |
| PolymorphicTest | NinoDeserializePolymorphicClass | 1,283.8730 ns | 1,278.2967 ns | 1,287.9496 ns | 1.00 | - | 0.3376 | - | - | 3408 B | 1.00 |
| PolymorphicTest | MemoryPackDeserializePolymorphicClass | 1,168.2880 ns | 1,167.7862 ns | 1,168.7007 ns | 0.91 | - | 0.3376 | - | - | 3408 B | 1.00 |
| PolymorphicTest | MessagePackDeserializePolymorphicClass | 4,439.9838 ns | 4,422.6966 ns | 4,467.6197 ns | 3.46 | - | 0.7629 | 0.0153 | 0.0076 | 17420 B | 5.11 |
| PolymorphicTest | NinoSerializePolymorphicClass | 551.9128 ns | 548.6929 ns | 554.2173 ns | 1.00 | 1.37KB | - | - | - | - | NA |
| PolymorphicTest | MemoryPackSerializePolymorphicClass | 1,141.7917 ns | 1,136.7372 ns | 1,151.5059 ns | 2.07 | 1.35KB | - | - | - | - | NA |
| PolymorphicTest | MessagePackSerializePolymorphicClass | 1,648.3796 ns | 1,643.2196 ns | 1,656.7439 ns | 2.99 | 1.01KB | - | - | - | - | NA |
| PolymorphicTest | NinoDeserializePolymorphicFoos | 2,319.4677 ns | 2,309.5676 ns | 2,338.4382 ns | 1.00 | - | 0.6332 | 0.0038 | - | 6424 B | 1.00 |
| PolymorphicTest | MemoryPackDeserializePolymorphicFoos | 2,014.5989 ns | 2,006.7282 ns | 2,029.7400 ns | 0.87 | - | 0.6332 | 0.0076 | - | 6424 B | 1.00 |
| PolymorphicTest | MessagePackDeserializePolymorphicFoos | 24,574.4231 ns | 24,532.2204 ns | 24,632.7030 ns | 10.60 | - | 0.8850 | 0.0305 | 0.0305 | - | 0.00 |
| PolymorphicTest | NinoSerializePolymorphicFoos | 1,649.8721 ns | 1,629.8438 ns | 1,687.4711 ns | 1.00 | 2.35KB | - | - | - | - | NA |
| PolymorphicTest | MemoryPackSerializePolymorphicFoos | 2,323.9736 ns | 2,320.7922 ns | 2,329.9088 ns | 1.41 | 2.15KB | - | - | - | - | NA |
| PolymorphicTest | MessagePackSerializePolymorphicFoos | 8,008.9658 ns | 8,006.6513 ns | 8,010.1519 ns | 4.86 | 4.79KB | - | - | - | - | NA |
| PolymorphicTest | NinoDeserializePolymorphicFoo | 23.9342 ns | 23.4111 ns | 24.8705 ns | 1.00 | - | 0.0074 | - | - | 56 B | 1.00 |
| PolymorphicTest | MemoryPackDeserializePolymorphicFoo | 38.7419 ns | 38.4776 ns | 39.2080 ns | 1.62 | - | 0.0093 | 0.0001 | 0.0001 | - | 0.00 |
| PolymorphicTest | MessagePackDeserializePolymorphicFoo | 182.2915 ns | 181.2182 ns | 183.3485 ns | 7.62 | - | 0.0057 | 0.0002 | 0.0002 | - | 0.00 |
| PolymorphicTest | NinoSerializePolymorphicFoo | 17.7961 ns | 17.5089 ns | 18.3563 ns | 1.00 | 24B | - | - | - | - | NA |
| PolymorphicTest | MemoryPackSerializePolymorphicFoo | 53.2089 ns | 53.2047 ns | 53.2144 ns | 2.99 | 22B | - | - | - | - | NA |
| PolymorphicTest | MessagePackSerializePolymorphicFoo | 129.3699 ns | 129.2461 ns | 129.5220 ns | 7.27 | 49B | - | - | - | - | NA |
| SimpleTest | NinoDeserializeSimpleClass | 530.0504 ns | 528.7236 ns | 532.1996 ns | 1.00 | - | 0.2308 | - | - | 2528 B | 1.00 |
| SimpleTest | MemoryPackDeserializeSimpleClass | 678.7964 ns | 674.9949 ns | 686.2480 ns | 1.28 | - | 0.2460 | - | - | 2528 B | 1.00 |
| SimpleTest | MessagePackDeserializeSimpleClass | 1,877.0926 ns | 1,871.9996 ns | 1,886.2322 ns | 3.54 | - | 0.3033 | 0.0038 | 0.0019 | 551 B | 0.22 |
| SimpleTest | NinoSerializeSimpleClass | 236.7934 ns | 236.4648 ns | 237.1604 ns | 1.00 | 1.13KB | - | - | - | - | NA |
| SimpleTest | MemoryPackSerializeSimpleClass | 532.1822 ns | 531.7901 ns | 532.6580 ns | 2.25 | 1.12KB | - | - | - | - | NA |
| SimpleTest | MessagePackSerializeSimpleClass | 1,214.4033 ns | 1,211.5253 ns | 1,216.2395 ns | 5.13 | 1.09KB | - | - | - | - | NA |
| SimpleTest | NinoDeserializeSimpleClasses | 53,115.6755 ns | 53,065.6004 ns | 53,214.3810 ns | 1.00 | - | 18.0664 | 5.8594 | - | 253624 B | 1.00 |
| SimpleTest | MemoryPackDeserializeSimpleClasses | 67,348.3770 ns | 67,244.5381 ns | 67,514.0581 ns | 1.27 | - | 17.7002 | 5.4932 | - | 253624 B | 1.00 |
| SimpleTest | MessagePackDeserializeSimpleClasses | 197,889.8617 ns | 196,791.0017 ns | 198,798.3828 ns | 3.73 | - | 18.0664 | 6.1035 | - | 253624 B | 1.00 |
| SimpleTest | NinoSerializeSimpleClasses | 24,866.3512 ns | 24,794.7617 ns | 24,903.1615 ns | 1.00 | 112.5KB | - | - | - | - | NA |
| SimpleTest | MemoryPackSerializeSimpleClasses | 50,226.0602 ns | 50,195.2592 ns | 50,265.8107 ns | 2.02 | 112.11KB | - | - | - | - | NA |
| SimpleTest | MessagePackSerializeSimpleClasses | 117,471.8976 ns | 117,369.3094 ns | 117,534.4860 ns | 4.72 | 108.59KB | - | - | - | - | NA |
| SimpleTest | NinoDeserializeSimpleStruct | 0.2979 ns | 0.2916 ns | 0.3030 ns | 1.00 | - | - | - | - | - | NA |
| SimpleTest | MemoryPackDeserializeSimpleStruct | 1.8682 ns | 1.8665 ns | 1.8692 ns | 6.27 | - | - | - | - | - | NA |
| SimpleTest | MessagePackDeserializeSimpleStruct | 71.2352 ns | 71.1930 ns | 71.3076 ns | 239.16 | - | - | - | - | - | NA |
| SimpleTest | NinoSerializeSimpleStruct | 6.8053 ns | 6.7882 ns | 6.8207 ns | 1.00 | 16B | - | - | - | - | NA |
| SimpleTest | MemoryPackSerializeSimpleStruct | 6.2308 ns | 6.2227 ns | 6.2349 ns | 0.92 | 16B | - | - | - | - | NA |
| SimpleTest | MessagePackSerializeSimpleStruct | 82.5017 ns | 82.4786 ns | 82.5452 ns | 12.12 | 16B | - | - | - | - | NA |
| SimpleTest | NinoDeserializeSimpleStructs | 115.2806 ns | 114.8844 ns | 115.6957 ns | 1.00 | - | 0.1624 | - | - | 1624 B | 1.00 |
| SimpleTest | MemoryPackDeserializeSimpleStructs | 135.8059 ns | 134.3241 ns | 137.0740 ns | 1.18 | - | 0.1624 | - | - | 1624 B | 1.00 |
| SimpleTest | MessagePackDeserializeSimpleStructs | 3,723.9279 ns | 3,720.4267 ns | 3,729.5059 ns | 32.30 | - | 0.1755 | 0.0038 | 0.0038 | - | 0.00 |
| SimpleTest | NinoSerializeSimpleStructs | 29.6300 ns | 29.6174 ns | 29.6496 ns | 1.00 | 1.57KB | - | - | - | - | NA |
| SimpleTest | MemoryPackSerializeSimpleStructs | 31.2385 ns | 31.2325 ns | 31.2429 ns | 1.05 | 1.57KB | - | - | - | - | NA |
| SimpleTest | MessagePackSerializeSimpleStructs | 4,220.3297 ns | 4,208.0726 ns | 4,244.0519 ns | 142.43 | 1.57KB | - | - | - | - | NA |
| SimpleTest | NinoDeserializeVectors | 117,927.1745 ns | 117,153.3003 ns | 118,693.6545 ns | 1.00 | - | 13.1836 | 13.1836 | 13.1836 | 160026 B | 1.00 |
| SimpleTest | MemoryPackDeserializeVectors | 119,021.4504 ns | 114,679.3696 ns | 121,369.6284 ns | 1.01 | - | 12.9395 | 12.9395 | 12.9395 | 160025 B | 1.00 |
| SimpleTest | MessagePackDeserializeVectors | 355,022.2977 ns | 352,438.8633 ns | 359,933.7222 ns | 3.01 | - | 19.0430 | 19.0430 | 19.0430 | - | 0.00 |
| SimpleTest | NinoSerializeVectors | 3,533.0708 ns | 3,528.5459 ns | 3,536.2640 ns | 1.00 | 156.25KB | - | - | - | - | NA |
| SimpleTest | MemoryPackSerializeVectors | 3,592.6423 ns | 3,591.9923 ns | 3,593.9030 ns | 1.02 | 156.25KB | - | - | - | - | NA |
| SimpleTest | MessagePackSerializeVectors | 297,394.6068 ns | 297,288.2090 ns | 297,529.7710 ns | 84.17 | 205.08KB | - | - | - | - | NA |
Benchmark generated automatically on 2025-10-11 11:17:03 UTC