From 501bd583e2ba04f401c17538c2a76d531df5d597 Mon Sep 17 00:00:00 2001 From: Youmu Liu <105042599+Nitload-NSI@users.noreply.github.com> Date: Mon, 20 Apr 2026 13:31:36 +0800 Subject: [PATCH] before merge --- .../HighPerformance/Memory/L4.Predictor.cs | 20 +++++++++---------- StgSharp.Common/HighPerformance/Memory/L4.cs | 2 +- 2 files changed, 11 insertions(+), 11 deletions(-) diff --git a/StgSharp.Common/HighPerformance/Memory/L4.Predictor.cs b/StgSharp.Common/HighPerformance/Memory/L4.Predictor.cs index 8d7ed1be..94526e1c 100644 --- a/StgSharp.Common/HighPerformance/Memory/L4.Predictor.cs +++ b/StgSharp.Common/HighPerformance/Memory/L4.Predictor.cs @@ -44,7 +44,6 @@ namespace StgSharp.HighPerformance.Memory public interface IL4Predict { - /* * Planned optimization contract types: * 1. internal interface IL4PredictOptimizationContract @@ -62,14 +61,14 @@ namespace StgSharp.HighPerformance.Memory */ /// - /// Determines whether a cache line materialized by under - /// can be adopted by the current predictor without an - /// intermediate rematerialization. + /// Determines whether a cache line materialized by under can be adopted by the current predictor without an intermediate + /// rematerialization. /// /// - /// This is intentionally stronger than comparing raw policy bits for equality. A true - /// result means the resident bytes can continue to be interpreted safely after ownership - /// is transferred to the current predictor. + /// This is intentionally stronger than comparing raw policy bits for equality. A true result + /// means the resident bytes can continue to be interpreted safely after ownership is transferred + /// to the current predictor. /// bool IsSamePolicy( uint policy, @@ -82,7 +81,7 @@ namespace StgSharp.HighPerformance.Memory ); /// - /// Materializes the cache line identified by into into . /// /// @@ -162,8 +161,9 @@ namespace StgSharp.HighPerformance.Memory #pragma warning disable CA1051 public nuint Address; - public uint MapPolicy; - internal uint Predictor; + public int Size; + public ushort MapPolicy; + internal short Predictor; #pragma warning restore CA1051 } } diff --git a/StgSharp.Common/HighPerformance/Memory/L4.cs b/StgSharp.Common/HighPerformance/Memory/L4.cs index 279cbb23..ecc63634 100644 --- a/StgSharp.Common/HighPerformance/Memory/L4.cs +++ b/StgSharp.Common/HighPerformance/Memory/L4.cs @@ -111,7 +111,7 @@ namespace StgSharp.HighPerformance.Memory "Design", "CA1063:Implement IDisposable correctly", Justification = """ - Only owns native memory via NativeMemory.AlignedFree(); + Only owns native memory via Numa.Free(); no managed IDisposable fields. Dispose(bool) pattern is unnecessary. """)]