diff --git a/src/Uno.Wasm.Tuner/IcallTableGenerator.net5.cs b/src/Uno.Wasm.Tuner/IcallTableGenerator.net5.cs index 8d56fcd7..072a1b9c 100644 --- a/src/Uno.Wasm.Tuner/IcallTableGenerator.net5.cs +++ b/src/Uno.Wasm.Tuner/IcallTableGenerator.net5.cs @@ -77,7 +77,18 @@ public IcallTableGenerator(string? runtimeIcallTableFile, Func f Log = log; _fixupSymbolName = fixupSymbolName; if (runtimeIcallTableFile != null && !runtimeIcallTableFile.Equals("__static_icalls__")) + { ReadTable(runtimeIcallTableFile); + + // validate that the _signatures are in the _staticSignatures table + foreach (var sig in _signatures) + { + if (!_staticSignatures.Contains(sig)) + { + throw new Exception($"Icall signature '{sig}' is not in the static icall signatures table"); + } + } + } else { Log.LogMessage(MessageImportance.Low, $"Using static signatures"); @@ -118,15 +129,6 @@ public IEnumerable Generate(string? outputPath) Log.LogMessage(MessageImportance.Low, $"Icalls signatures: " + string.Join(",", _signatures)); - // validate that the _signatures are in the _staticSignatures table - foreach (var sig in _signatures) - { - if (!_staticSignatures.Contains(sig)) - { - throw new Exception($"Icall signature '{sig}' is not in the static icall signatures table"); - } - } - return _signatures; }