-
Notifications
You must be signed in to change notification settings - Fork 4.9k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[wasm] Re-enable source generator tests failing due to OOM #60701
Changes from all commits
4038554
8023855
e51a76f
8436395
9a6d859
4fb5bf4
485d481
5554733
ddb1ffb
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
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 |
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -152,6 +152,8 @@ | |
<_WasmPInvokeTablePath>$(_WasmIntermediateOutputPath)pinvoke-table.h</_WasmPInvokeTablePath> | ||
<_WasmPInvokeHPath>$(_WasmRuntimePackIncludeDir)wasm\pinvoke.h</_WasmPInvokeHPath> | ||
<_DriverGenCPath>$(_WasmIntermediateOutputPath)driver-gen.c</_DriverGenCPath> | ||
<DisableParallelAot Condition="'$(DisableParallelAot)' == ''">false</DisableParallelAot> | ||
<DisableParallelEmccCompile Condition="'$(DisableParallelEmccCompile)' == ''">$(DisableParallelAot)</DisableParallelEmccCompile> | ||
|
||
<_DriverGenCNeeded Condition="'$(_DriverGenCNeeded)' == '' and '$(_WasmShouldAOT)' == 'true'">true</_DriverGenCNeeded> | ||
|
||
|
@@ -283,7 +285,7 @@ | |
<!-- warm up the cache --> | ||
<Exec Command="$(_EmBuilder) build MINIMAL" EnvironmentVariables="@(EmscriptenEnvVars)" StandardOutputImportance="Low" StandardErrorImportance="Low" /> | ||
|
||
<Message Text="Compiling native assets with emcc. This may take a while ..." Importance="High" /> | ||
<Message Text="Compiling native assets with emcc with $(EmccCompileOptimizationFlag). This may take a while ..." Importance="High" /> | ||
<ItemGroup> | ||
<_WasmSourceFileToCompile Remove="@(_WasmSourceFileToCompile)" /> | ||
<_WasmSourceFileToCompile Include="@(_WasmRuntimePackSrcFile)" Dependencies="%(_WasmRuntimePackSrcFile.Dependencies);$(_EmccDefaultFlagsRsp);$(_EmccCompileRsp)" /> | ||
|
@@ -292,6 +294,7 @@ | |
SourceFiles="@(_WasmSourceFileToCompile)" | ||
Arguments='"@$(_EmccDefaultFlagsRsp)" "@$(_EmccCompileRsp)"' | ||
EnvironmentVariables="@(EmscriptenEnvVars)" | ||
DisableParallelCompile="$(DisableParallelEmccCompile)" | ||
OutputMessageImportance="$(_EmccCompileOutputMessageImportance)"> | ||
<Output TaskParameter="OutputFiles" ItemName="FileWrites" /> | ||
</EmccCompile> | ||
|
@@ -308,11 +311,12 @@ | |
<_BitCodeFile Dependencies="%(_BitCodeFile.Dependencies);$(_EmccDefaultFlagsRsp);$(_EmccCompileBitcodeRsp)" /> | ||
</ItemGroup> | ||
|
||
<Message Text="Compiling assembly bitcode files..." Importance="High" Condition="@(_BitCodeFile->Count()) > 0" /> | ||
<Message Text="Compiling assembly bitcode files with $(EmccLinkOptimizationFlag) ..." Importance="High" Condition="@(_BitCodeFile->Count()) > 0" /> | ||
<EmccCompile | ||
SourceFiles="@(_BitCodeFile)" | ||
Arguments=""@$(_EmccDefaultFlagsRsp)" "@$(_EmccCompileBitcodeRsp)"" | ||
EnvironmentVariables="@(EmscriptenEnvVars)" | ||
DisableParallelCompile="$(DisableParallelEmccCompile)" | ||
OutputMessageImportance="$(_EmccCompileOutputMessageImportance)"> | ||
<Output TaskParameter="OutputFiles" ItemName="FileWrites" /> | ||
</EmccCompile> | ||
|
@@ -371,7 +375,7 @@ | |
DependsOnTargets="_WasmSelectRuntimeComponentsForLinking;_WasmCompileAssemblyBitCodeFilesForAOT;_WasmWriteRspFilesForLinking" | ||
Returns="@(FileWrites)" > | ||
|
||
<Message Text="Linking with emcc. This may take a while ..." Importance="High" /> | ||
<Message Text="Linking with emcc with $(EmccLinkOptimizationFlag). This may take a while ..." Importance="High" /> | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. (Optional suggestion) Maybe put a prefix on these 3 stages like '2/3' to indicate how many more emcc steps are left in the build since each step is so slow There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Right now, a AOT build looks like:
Adding another level of numbering might be confusing. Maybe some other way of communicating the same idea? |
||
<Message Text="Running emcc with @(_EmccLinkStepArgs->'%(Identity)', ' ')" Importance="Low" /> | ||
<Exec Command='emcc "@$(_EmccDefaultFlagsRsp)" "@$(_EmccLinkRsp)"' EnvironmentVariables="@(EmscriptenEnvVars)" /> | ||
<ItemGroup> | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
An xml comment (doesn't need to be long) explaining why these specific flags were selected would be great here
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'll leave this one for @radekdoulik to add, since he set these originally.