Skip to content

Commit 1370336

Browse files
committed
💚 Fix CI
1 parent 6b3588a commit 1370336

File tree

2 files changed

+6
-12
lines changed

2 files changed

+6
-12
lines changed

‎src/Cosmos.Build.Ilc/build/Cosmos.Build.Ilc.targets‎

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -109,7 +109,8 @@
109109
<!-- ARM64: Use only base instruction set. X86 intrinsics are not applicable to ARM64 architecture.
110110
Runtime plugs in X86IntrinsicsPlug.cs ensure X86 intrinsics report IsSupported=false at runtime. -->
111111
<IlcArg Include="--instruction-set:base" Condition="'$(CosmosArch)' == 'arm64'" />
112-
<IlcArg Include="--preinitstatics" /> <!-- Implied by -O, but we rely on this for Limine requests. -->
112+
<!-- ARM64 cross-compilation: Skip preinitstatics to avoid x64-host issues with ARM64-target static initialization -->
113+
<IlcArg Include="--preinitstatics" Condition="'$(CosmosArch)' != 'arm64'" />
113114
<IlcArg Include="@(UnmanagedEntryPointsAssembly->'--generateunmanagedentrypoints:%(Identity)')" />
114115

115116
<!-- The managed debugging support in libraries is unused - trim it -->

‎tests/Cosmos.TestRunner.Framework/TestRunner.cs‎

Lines changed: 4 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,4 @@
11
using System;
2-
using System.Diagnostics;
32
using Cosmos.Kernel.Core.IO;
43

54
namespace Cosmos.TestRunner.Framework
@@ -15,7 +14,6 @@ public static class TestRunner
1514
private static ushort _passedCount;
1615
private static ushort _failedCount;
1716
private static ushort _currentTestNumber;
18-
private static long _testStartTicks;
1917

2018
/// <summary>
2119
/// Start a test suite
@@ -43,22 +41,17 @@ public static void Run(string testName, Action testAction)
4341
// Send TestStart message
4442
SendTestStart(_currentTestNumber, testName);
4543

46-
// Record start time
47-
_testStartTicks = Stopwatch.GetTimestamp();
44+
// TODO: Timing disabled for ARM64 cross-compilation compatibility
45+
// _testStartMs = Environment.TickCount64;
4846

4947
try
5048
{
5149
// Execute test
5250
testAction();
5351

54-
// Calculate duration
55-
var endTicks = Stopwatch.GetTimestamp();
56-
var elapsedTicks = endTicks - _testStartTicks;
57-
var durationMs = (uint)((elapsedTicks * 1000) / Stopwatch.Frequency);
58-
59-
// Test passed
52+
// Test passed (duration = 0 for ARM64 compatibility)
6053
_passedCount++;
61-
SendTestPass(_currentTestNumber, durationMs);
54+
SendTestPass(_currentTestNumber, 0);
6255
}
6356
catch (AssertionException ex)
6457
{

0 commit comments

Comments
 (0)