-
Notifications
You must be signed in to change notification settings - Fork 4.8k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[wasm] Re-enable source generator tests failing due to OOM (#60701)
This adds support for setting per-project optimization flags, and sets them for these projects so they don't OOM. Microsoft.Extensions.Logging.Generators.Roslyn3.11.Tests Microsoft.Extensions.Logging.Generators.Roslyn4.0.Tests System.Text.Json.SourceGeneration.Roslyn3.11.Unit.Tests System.Text.Json.SourceGeneration.Roslyn4.0.Unit.Tests System.Text.RegularExpressions.Generators.Tests Some individual ones are disabled due to #58226, and #60899 . Additionally, if a AOT build fails, then on linux it dumps the last few lines from dmesg, to help identify it was an oom-kill. Fixes #51961 . Co-authored-by: Larry Ewing <[email protected]>
- Loading branch information
Showing
17 changed files
with
120 additions
and
24 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,57 @@ | ||
#!/usr/bin/env bash | ||
|
||
EXECUTION_DIR=$(dirname $0) | ||
SCENARIO=$3 | ||
|
||
cd $EXECUTION_DIR | ||
|
||
if [ -z "$HELIX_WORKITEM_UPLOAD_ROOT" ]; then | ||
XHARNESS_OUT="$EXECUTION_DIR/xharness-output" | ||
else | ||
XHARNESS_OUT="$HELIX_WORKITEM_UPLOAD_ROOT/xharness-output" | ||
fi | ||
|
||
if [ ! -z "$XHARNESS_CLI_PATH" ]; then | ||
# When running in CI, we only have the .NET runtime available | ||
# We need to call the XHarness CLI DLL directly via dotnet exec | ||
HARNESS_RUNNER="dotnet exec $XHARNESS_CLI_PATH" | ||
else | ||
HARNESS_RUNNER="dotnet xharness" | ||
fi | ||
|
||
if [ "$SCENARIO" == "WasmTestOnBrowser" ]; then | ||
XHARNESS_COMMAND="test-browser" | ||
elif [ -z "$XHARNESS_COMMAND" ]; then | ||
XHARNESS_COMMAND="test" | ||
fi | ||
|
||
function _buildAOTFunc() | ||
{ | ||
local projectFile=$1 | ||
local binLog=$2 | ||
shift 2 | ||
|
||
time dotnet msbuild $projectFile /bl:$binLog $* | ||
local buildExitCode=$? | ||
|
||
echo "\n** Performance summary for the build **\n" | ||
dotnet msbuild $binLog -clp:PerformanceSummary -v:q -nologo | ||
if [[ "$(uname -s)" == "Linux" && $buildExitCode -ne 0 ]]; then | ||
echo "\nLast few messages from dmesg:\n" | ||
dmesg | tail -n 20 | ||
fi | ||
|
||
echo | ||
echo | ||
|
||
return $buildExitCode | ||
} | ||
|
||
# RunCommands defined in tests.mobile.targets | ||
[[RunCommands]] | ||
|
||
_exitCode=$? | ||
|
||
echo "XHarness artifacts: $XHARNESS_OUT" | ||
|
||
exit $_exitCode |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
1 change: 1 addition & 0 deletions
1
...ourceGeneration.Unit.Tests/System.Text.Json.SourceGeneration.Roslyn3.11.Unit.Tests.csproj
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
3 changes: 2 additions & 1 deletion
3
src/mono/sample/wasm/browser-bench/Wasm.Browser.Bench.Sample.csproj
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters