switch root namespace name to NITLOAD
This commit is contained in:
@@ -0,0 +1,40 @@
|
||||
// -----------------------------------------------------------------------------
|
||||
// file="NumaNode"
|
||||
// Project: StgSharp
|
||||
// Copyright (c) Nitload.
|
||||
// SPDX-License-Identifier: MIT
|
||||
// -----------------------------------------------------------------------------
|
||||
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Runtime.InteropServices;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
|
||||
namespace Nitload.Common.HighPerformance.ProcessorAbstraction
|
||||
{
|
||||
public class NumaNode
|
||||
{
|
||||
|
||||
private LogicalCore[] _logicalCores;
|
||||
|
||||
internal NumaNode(
|
||||
uint numaId,
|
||||
int count,
|
||||
Span<uint> logicalCoreIds
|
||||
|
||||
)
|
||||
{
|
||||
_logicalCores = new LogicalCore[count];
|
||||
for (int i = 0; i < count; i++) {
|
||||
_logicalCores[i] = new LogicalCore(1, numaId, logicalCoreIds[i]);
|
||||
}
|
||||
}
|
||||
|
||||
public int LogicalCoreCount => _logicalCores.Length;
|
||||
|
||||
public ReadOnlySpan<LogicalCore> LogicalCores => _logicalCores;
|
||||
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user