Commit Graph
250 Commits
Author SHA1 Message Date
Parker Bibus c929be171f Finish59071 update ci argsh (#60206)
* Updated channel passed to ci_setup in the performance-setup.sh file.

* Removed spaces from assignments so they are seen as actual variabls, and tested locally.
2021-10-08 16:00:59 -07:00
Parker Bibus 3cffddd7e4 Rollback verify command changes. (#60203) 2021-10-08 15:07:06 -07:00
Aaron Kunkle 61c204398c Fix Robocopy Verification (#60196)
* Fix robocopy exit code response

* Fix failure condition

* Rollback performance-setup.sh
2021-10-08 11:46:36 -07:00
Aaron Kunkle d2a05e3429 Fix performance-setup Function Definitions (#60102)
* Fix function definitions
2021-10-06 16:01:03 -07:00
Aaron Kunkle a442df07a5 Fix errors from earlier performance-setup PR (#60073) 2021-10-06 09:51:51 -07:00
Parker Bibus b3f21a045f Updated channel passed to ci_setup in the performance-setup.sh file. (#60034)
* Updated channel passed to ci_setup in the performance-setup.sh file.

* Removed spaces from assignments so they are seen as actual variabls, and tested locally.
2021-10-06 09:50:38 -07:00
Aaron Kunkle 191c60e679 Nonzero Exit Code for performance-setup Failures (#59483)
* failed git clone causes script failure

* Failure notification for moves & copies

* Fix robocopy failure detection

* Use functions to verify

* Close shell ifs

* Remove unintended tabs
2021-10-05 15:27:05 -07:00
Adeel Mujahid ce99c5658c Use ProductVersion in how-to-debug-dump (#59848)
* Use ProductVersion in how-to-debug-dump
2021-10-01 10:05:14 -07:00
Aleksey Kliger (λgeek)andAnkit Jain acb00500a0 Build one MonoTargetsTasks assembly for Microsoft.NET.Runtime.MonoTargets.Sdk pack (#59720)
* Build one MonoTargetsTasks assembly for Mono.NET.Runtime.MonoTargets.Sdk pack

   Instead of 3 assemblies for some tiny tasks.

   Building a single assembly also ensures that everything in the pack depends on and bundles identical versions of dependent assemblies.  For example on net472, a single version of System.Text.Json with a single fixed version shared by both the JsonToItemsTaskFactory task factory and the RuntimeConfigParser task.

   Related to https://github.com/dotnet/runtime/issues/59619

* Update testing and wasm to use MonoTargetsTasks.dll

* Move assembly stripper to a separate assembly

   Build it with nullability checking disabled.

   Build the main MonoTargetsTasks assembly with nullability enabled

* Don't include msbuild assemblies in MonoTargets package

* re-enable analyzers for the MonoTargetsTasks assembly

* Include *.dll in the MonoTargetsTasks nupkg

   In particular, pick up all the dependent assemblies for the net472 build

* Update various READMEs

* remove unneeded target

* Switch ILStrip to use the same Parallel.ForEach logic as MonoAOTCompiler

* Remove unneeded NoWarn warnings

* rearrange package references in MonoTargetsTask.csproj for readabilty

* More ItemGroup reformatting

* fix nits

* Use SystemThreadingTasksExtensionsVersion instead of hardcoding

Co-authored-by: Ankit Jain <[email protected]>
2021-09-30 11:13:26 -04:00
Mitchell HwangandMitchell Hwang fcb73d8158 Remove ILStrip temporarily to retain ActiveIssue attributes in release mobile device configuration (#59762)
* Remove ILStrip temporarily to retain ActiveIssue attributes in release mobile device configuration

* Add Android Active Issue

Co-authored-by: Mitchell Hwang <[email protected]>
2021-09-30 10:30:00 -04:00
Adeel Mujahid 37e1ba1f35 Update how-to-debug-dump template (#59798)
* Update how-to-debug-dump template

* Address CR feedback

* Update windows instructions

* Use backslashes on Windows
2021-09-30 15:13:07 +02:00
Ankit JainandLarry Ewing 80f015da0f [wasm] Build improvements based on feedback (#59391)
- Fix for a incremental build issue
- Change native build defaults for `Debug` config, to make it faster (thanks @SteveSandersonMS, @mattleibow)

- MonoAOTCompiler:
  - Skip unmanaged assemblies, and emit a warning
- PInvokeTableGenerator:
  - Fix to not fail in presence of native variadic functions, and pinvokes with function pointers (eg. used by sqlite)

Co-authored-by: Larry Ewing <[email protected]>
2021-09-30 00:53:21 -04:00
Drew Scoggins f807a6bae3 Change logic to not break private runs (#59356)
The previous change here broke private runs as it required the channel map
to have an entry matching the name of the runtime branch you were testing.
This fix now defaults the channel to main for private runs.
2021-09-20 12:51:11 -07:00
Ankit Jain 4af01264ae [wasm] Add support for native relinking after Build, and… (#59153)
… AOT after publish (#58913)

Forward port #58913

(cherry picked from commit f38d58f)
2021-09-16 19:38:26 -04:00
Drew Scoggins 965f95e967 Change channel passed to ci_setup to track runtime branch (#59070)
With this change we move to specifing the channel that is passed to ci_setup,
instead of it always being main. The allows us to have the runtime branch
help decide the correct version of the sdk that we should pull down with
dotnet-install. This means that going forward, we will need to have channels
that match the names of all branches that we plan to run from the runtime
side. If we do not, the sdk installation step will fail during ci_setup.
2021-09-15 15:07:26 -07:00
Alexander Köplinger 0becd27f72 Create a parent CMake project for building app bundles on CI (#58965) 2021-09-13 10:26:58 +02:00
f88633994b Enable more iOS/tvOS device tests (#58846)
Add a few more suites to help validate the device infrastructure

Enable soft trimming and skip failing tests

Co-authored-by: Steve Pfister <[email protected]>
Co-authored-by: Alexander Köplinger <[email protected]>
2021-09-10 11:30:59 -04:00
Fan Yang 18fd263784 Create a separate RuntimeConfig test for Android and add incremental build (#58835)
* Create a separate RuntimeConfig test for Android

* Add incremental build
2021-09-09 09:44:37 +02:00
Viktor Hofer 67354a2fb4 Upgrade to net7.0 and remove target frameworks (#58011)
* Remove EOL tfms and upgrade to net7.0

* Make linker tests net7 aware

Make installer tests run on net7.0

Don't attempt to use live apphost

Fix payloads

Regenerate test files

Fix package testing
2021-09-08 22:04:23 +02:00
cad4c6b1de Run minimal set of iOS / tvOS device tests (#58444)
With each test suite app taking up ~100MB in space, it's not practical to build the tests on the build machine. Only enable a few now as an interim step.

Co-authored-by: Steve Pfister <[email protected]>
Co-authored-by: Alexander Köplinger <[email protected]>
2021-09-04 00:01:58 +02:00
Drew Scoggins 0ce134d743 Update mono version string to 7.0.0 (#58150) 2021-08-25 18:06:04 -07:00
Drew Scoggins fa36dc8438 Escape semicolons in proj file (#58066) 2021-08-24 16:03:09 -07:00
Drew Scoggins d6223adfb5 Add crossgen2 runs for x86 (#58053)
* Add crossgen2 runs for x86 and Arm64

* Remove Arm64 for now
2021-08-24 14:23:50 -07:00
Bill Wert 9a3efe8b7e fix python path (#58055)
* Remove AzurePiplineReporter=false

* Backup and restore python path
2021-08-24 12:19:02 -07:00
Drew Scoggins 5bbd5b64f1 Add wasm path (#57857)
* Add Wasm runtime config path variable

* Fix typo
2021-08-24 10:10:51 -07:00
Alicia Li ec252380c2 fix PYTHONPATH on Linux (#57701)
* fix PYTHONPATH on Linux for issue#1928

* fix PYTHONPATH on Linux for issue#1928

* roll back setting PYTHONPATH, set EnableAzurePipelinesReporter to false instead

* set EnableAzurePipelinesReporter to false since perf test doesn't use the reporter. This avoids a helix crash
2021-08-20 10:43:37 -07:00
Larry Ewing 797f161df8 Enable more passing test assemblies on AOT (#57678) 2021-08-18 18:14:45 -05:00
Larry Ewing 82f7144f79 [wasm] Enable tests blocked by IL2105 (#57457)
* Disable ReflectionCachesUpdateHandler_CachesCleared with aggressive trimming

* Enable more tests stopped by 2105

* Create tests.mobile.targets

Suppress IL2025

* Remove comment enabling trim warnings

* Mark more active issues
2021-08-17 16:28:09 -05:00
Ankit JainandLarry Ewing 3e3b00c53b [wasm] Add incremental build support (#57113)
* Update tasks to support incremental build

MonoAOTCompiler:
- Compiles assemblies to .bc files.
- Hashes for the .bc files are stored in a json cache file.
- And uses .depfile generated by mono-aot-cross, to figure out the
  if any of the dependencies have changed
- Writes out the actual .bc file only if the assembly, or it's
  dependencies changed

EmccCompile.cs: Support a `%(Dependencies)` metadata on the source
files, to compile the files only when needed.

* Update wasm targets

* don't pass unncessary args to RunTests

* Add tests for incremental builds

* Disable non-wasm builds, for testing

* Add miggins LogAsErrorException.cs

* Bump sdk for workload testing to 6.0.100-rc.1.21410.3

* fix build

* MonoAOTCompiler: use the full path to copy the final .bc file

* Make the method used with `MemberData`, static

otherwise xunit just shows a cryptic:
```
    Wasm.Build.Tests.RebuildTests.NoOpRebuild [STARTING]
    Wasm.Build.Tests.RebuildTests.NoOpRebuild [FAIL]
      System.NotSupportedException : Specified method is not supported.
```

* add back builds

* Split Wasm.Build.Tests into multiple helix jobs

* Revert "add back builds"

This reverts commit 1d031c04e13780ec73180ba6f06a37ee42c24203.

* Split up native rebuild tests

* remove non-test classes

* add back builds

This reverts commit b008130a7886c2e2b9f16c83641c1b8c936082f6.

* MonoAOTCompiler: make cache optional

* MonoAOTCompiler: handle the case where we have a cache entry, but the file on disk doesn't exist

* Fix aot compiler task output

* MonoAOTCompiler: Use hashes of .bc files instead of assemblies

`--depfile` isn't supported on aot config used by android, and fails
with:

```
* Assertion at /__w/1/s/src/mono/mono/mini/aot-compiler.c:14216, condition `acfg->aot_opts.llvm_only && acfg->aot_opts.asm_only && acfg->aot_opts.llvm_outfile' not met
```

Instead, use hashes of the .bc.tmp files generated, with the existing
.bc files.

* MonoAOTCompiler: Support more than one output file

The earlier implementation assumed that there would be only one output
file. But in some cases (eg. android), there are more than one, like
`.s`, `.dll-llvm.o`.

* -bump sdk for workload testing

* MonoAOTCompiler: don't use tmp files at all, when cache isn't being

.. used.

Co-authored-by: Larry Ewing <[email protected]>
2021-08-17 11:58:50 -05:00
Ankit Jain 98ca2ffa27 [wasm] Don't use workload for tfm < net6.0 (#56606)
* Bump sdk used for testing to 6.0.100-rc.1.21402.6

* InstallWorkloadFromArtifacts: Add OnlyUpdateManifests parameter

* [wasm] Run Wasm.Build.Tests with sdk/no-workload/+EMSDK

Currently, Wasm.Build.Tests are run in two modes:

1. sdk(`$(SdkVersionForWorkloadTesting)`)+workload installed
2. sdk(from global.json)+EMSDK+LocalBuild targets

this commit changes (2) to:

2. sdk(`$(SdkVersionForWorkloadTesting)`), no workload installed, +
   EMSDK+LocalBuild targets

This makes it closer to what a user would actually use.

Also, for the workload tests, this removes `$(WasmNativeWorkload)`
always being set to `true`. The workload should be setting that, and not
the tests.

* Wasm.Build.Tests: Add test for net5.0 blazor projects

* Disable unrelated builds for now

* Revert "Disable unrelated builds for now"

This reverts commit 6fa0efe2ffcfdbcfaba3bdf519a7717809c22672.

* Rename OnlyWasmBuildTests -> TestWasmBuildTests
2021-08-15 13:10:26 -05:00
7d12f7596a Upgrade SDK to 6.0.100-rc.1.21411.13 (#57143)
* Upgrade SDK to 6.0.100-rc.1.21379.2

Both the AzDO and the Core-Eng team believe believe that the issue is on our side and was caused by a thread pool regression. The assumption stands that we need to update to a newer SDK which contains the fix for the thread pool hang.

Pros:
-	AzDO and Core-Eng believe that this will mitigate the AzDO feed restore issues.
Cons:
-	We will upgrade to an unsigned SDK build. Arcade and other repos already did the same to workaround the issue.
-	That SDK build isn’t officially released and won’t until RC 1 ships. This means that developers need to install that build via the nightly channel (from https://github.com/dotnet/installer) if they want to use their globally installed SDK in combination with dotnet/runtime.
-	Even though this is a breaking change, we can’t wait for the next monthly infrastructure rollout.

* set StaticWebAssetsEnabled=false

* Remove IsSupported2 since asserting it is true when it might not be

* Try enabling the runtimeconfig generator everywhere

* Revert part of runtimeconfig parser change

* Fix System.Text.Json tests to run with trimming by setting MetadataUpdaterSupport=true.

Work around SDK issue by overwriting EnableUnsafeUTF7Encoding in System.Text.Encoding

* Disable bundling tests on Mac due to bug

See https://github.com/dotnet/runtime/issues/57242

* Make ProcessInfo tests resilient to RuntimeConfig switches on commandline

* Update global.json

Updating to 6.0.100-rc.1.21411.13

* Update to latest SDK.
Remove System.Text.Encoding.Tests workaround

* ignore runtimeconfig switches _if_ they show up

* Remove test which uses `dotnet run, which is SDK-specific

Co-authored-by: Larry Ewing <[email protected]>
Co-authored-by: Eric Erhardt <[email protected]>
Co-authored-by: Andy Gocke <[email protected]>
Co-authored-by: John Salem <[email protected]>
Co-authored-by: Dan Moseley <[email protected]>
2021-08-12 15:09:01 -07:00
Jose Perez Rodriguez ffa6aae114 Clean up rd.xml now that DCS has been annotated (#57013)
* Clean up rd.xml now that DCS has been annotated

* Adding annotation to keep KeyValue.GetKeyValuePair method

* Use GetMemberWithSameMetadataDefinitionAs instead

* fix typo in the type being kept

* Save constructor metadata as a workaround as opposed to using DynamicDependency
2021-08-11 11:10:30 -05:00
Fan YangandAnkit Jain 13f80656cd Add runtimeconfig.json support for WebAssembly (#56486)
* Initial change for adding runtimeconfig to wasm

* Add runtimeconfig support to wasm

* Move test folder and update runtimeconifg task name

* Fix test

* Fix test csproj file

* Use the right var for main dll name

* Resolve review feedback part 1

* Resolve review feedbacks part 2

* Add doc for updating dependencies when adding new tasks

* Remove redundant condition and redundant copy

* There is no runtimeconfig.json file to parse, when OutputType is library. So skip it.

* Skip for Android tests as well.

* Remove the wrong locatioin of WasmFilesToIncludeInFileSystem

* Update runtimeconfig file path

* Add RuntimeConfigParserTasksAssemblyPath to linker test project template

* Fix test failures on WASM EAT and AOT lanes

* [wasm] Add a test for reading runtimeconfig.json

* improve error reporting slightly

* Enable tests

* One more thing to enable tests

* Run target _WasmGenerateRuntimeConfig when runtimeconfig.json file exists

* Add a test for configure runtime using msbuild properties

* Fix runtime test failures

* Update tests base on feedback

* Add missing ")"

* Add one more condition

* More format changes

* Better error handling

* [wasm] Fix build for a test support project

This fixes the build for ApplyUpdateReferencedAssembly.csproj, which is
a support project for HotReload wasm functional test.

```
D:\workspace\_work\1\s\src\mono\wasm\build\WasmApp.targets(131,5): error : Could not find
    D:\workspace\_work\1\s\artifacts\bin\ApplyUpdateReferencedAssembly\net6.0-Release\browser-wasm\publish\ApplyUpdateReferencedAssembly.runtimeconfig.json
    for D:\workspace\_work\1\s\artifacts\bin\ApplyUpdateReferencedAssembly\net6.0-Release\browser-wasm\publish\ApplyUpdateReferencedAssembly.dll.

    [D:\workspace\_work\1\s\src\tests\FunctionalTests\WebAssembly\Browser\HotReload\ApplyUpdateReferencedAssembly\ApplyUpdateReferencedAssembly.csproj]
```

The wasm targets should be run at all for this project. But they are run
because they get imported by tests.wasm.targets, which gets imported because
`$(IsTestProject)=true`.

The csproj has `$(IsTestProject)=false`, and `$(IsTestSupportProject)=true`,
which should mean that the test.props/targets don't get imported. But the
import is conditioned on `$(EnableTestSupport)`, which gets set in
`src/libraries/Directory.Build.props`. And that means setting
`$(IsTestProject)=true` in the csproj is too late.

So, instead, set that in a `Directory.Build.props`. And also, ensure that the
`Directory.Build.props` for functional tests doesn't override the value!

Co-authored-by: Ankit Jain <[email protected]>
2021-08-06 09:04:16 -04:00
9dc2059c32 Enable WASM AOT microbenchmark run (#55353)
* bring up WASM AOT microbenchmarks run

* bring up WASM AOT microbenchmarks run

* adding diagnostice log for testing

* commend out some jobs while testing to save lab run resource

* commend out some jobs while testing to save lab run resource

* Add WASM AOT in not scheduled run

* Only run selected jobs

* add "ls -l" to print out permission before calling performance-setup.sh

* add "ls -l" to print out permission before calling performance-setup.sh

* Add "--buildTimeout 3600" to benchmarkdotnet to extend default timeout time. Adjust -aotcompilermode format to "--aotcompilermode=wasm".

* Add "--buildTimeout 3600" to benchmarkdotnet to extend default timeout time. Adjust -aotcompilermode format to "--aotcompilermode=wasm".

* Correct runtimeSrcDir value

* Correct --runtimeSrcDir location to $HELIX_CORRELATION_PAYLOAD

* Correct --runtimeSrcDir location to $HELIX_CORRELATION_PAYLOAD

* Remove not used parameters in WASM AOT mode and  add temperary diagnostic info

* Remove not used parameters in WASM AOT mode and  add temperary diagnostic info

* make \$HELIX_CORRELATION_PAYLOAD/dotnet-wasm to be the root directory of runtime repo source

* Only copy runtime repo source directory to helix payload when it's wasm aot

* Add diagnosic log for testing only

* omite unneeded runtime repo file from helix payload

* omite unneeded runtime repo file from helix payload

* use rsync instead of cp exclusion command since cp doesn't work with sub directory as expected.

* Add temp diagnostic logging, should be removed before PR.

* remove artifacts/obj from helix payload

* remove artifacts/obj from helix payload

* copy back helix job for diagnosis and silent rsync

* For testing only, clone performance repor alicial/hikeMicro-benchmark private branch, which contains copying back helix job folder for diagnosis

* enable rsync verbose for diagnosis

* add --keepfiles for wasm intepreter as well for diagnosis

* Remove temporary diagnostic code

* recover all the jobs in the pipeline

* recover all the jobs in the pipeline

* copy wasm build drop to the location that aot build expects

* using private perf branch to enable binlog for benchmarkdotnet for diagnosis

* comment out none wasm runs temporarily for testing only

* comment out none wasm runs temporarily for testing only

* add "--keepfiles" to keep diagnostic files

* fixed $wasm_dotnet_path/artifacts/BrowserWasm/artifacts path

* instead of copy, move $wasm_dotnet_path/artifacts/BrowserWasm/artifacts/* to save space

* benchmarkdotnet using --cli \$HELIX_CORRELATION_PAYLOAD/dotnet-wasm/dotnet.sh instead

* benchmarkdotnet using --cli \$HELIX_CORRELATION_PAYLOAD/dotnet-wasm/dotnet.sh instead

* add executable permission

* Enable other non run to compare

* Enable other non run to compare

* remove "--cli \$HELIX_CORRELATION_PAYLOAD/dotnet-wasm/dotnet.sh"

* fixes per CR

* copy EMSDK_PATH to expected location in helix payload

* install emsdk

* fix emsdk path

* minor fix

* removed more not used files to reduce helix payload size

* remove more jobs for testing purpose

* Fix the download path

* Add BenchmarkDotNet sources to the payload

* Fix __download__ path

* set BenchmarkDotNetSources to use benchmarkdotnet built from source

* use benchmarkdotnet private branch:alicial/tempwasmaot for BenchmarkDotNetSources

* use benchmarkdonet private branch with BenchmarkDotNetSources option

* Debug prints

* Clone B.NET to different location

Fix rsync exclusion
Add more debug prints

* Move B.NET back, clone upstream B.NET

To avoid:

    [INFO] ERROR(S):
    [INFO]   Option 'BenchmarkDotNetSources' is unknown.

* Use my branch for performance repo

* Revert "set BenchmarkDotNetSources to use benchmarkdotnet built from source"

This reverts commit bccfadde684922c0440d928224c8e7ec7c220fe9.

To avoid:

    [INFO] ERROR(S):
    [INFO]   Option 'BenchmarkDotNetSources' is unknown.

* Disable one more job I missed in merge

* Switch back to nuget packages for BenchmarkDotNet

* tempararily use pr-alicias-branch to test new fixes

* [mono] Fix invalid memory write

Fixes https://github.com/dotnet/runtime/issues/56526 and probably also
https://github.com/dotnet/runtime/issues/53546

Allocate enough memory when `SIZEOF_REGISTER == 4`, so that code like

    defs [ins->dreg + 1] = NULL;
    defs [ins->dreg + 2] = NULL;

doesn't write after allocated range.

* [mono] Fix an uninitialized memory access in the ABCREM pass.

Detected by valgrind.

* clean up PR

* add missing param

* fix perf.yml and make wasm interpreter to be consistent with wasm AOT

* comment out more job for fast testing

* remove extra job

* exclude copying __download__ dir instead of delete it.

* add parameters.codeGenType

* fix aot javascriptengine

* correct livelibrariesbuildconfig from release to Release

* install emsdk before copy $source_directory

* add back all the temporarily commented out jobs in perf.yml

* clean up work around code

* minor clean up

* remove performance submodule

* switch back to use performance repo main branch

* add --quiet to git clone

Co-authored-by: Radek Doulik <[email protected]>
Co-authored-by: Zoltan Varga <[email protected]>
2021-08-04 20:00:15 -07:00
a35aff789d [main] Update dependencies from mono/linker (#56593)
* Update linker warning suppressions

https://github.com/mono/linker/pull/2145 warns when accessing members
annotated with DynamicallyAccessedMembers using reflection, and
https://github.com/mono/linker/pull/2162 updates the warning origin of
warnings for DynamicallyAccessedMembers on types.

This adds suppressions for the new warnings.

* Add windows-specific suppressions

* Update dependencies from https://github.com/mono/linker build 20210729.2

Microsoft.NET.ILLink.Tasks
 From Version 6.0.100-preview.6.21378.1 -> To Version 6.0.100-preview.6.21379.2

* Fix failures and address feedback

- Annotate mono's EnumBuilder and TypeBuilder
- Add (non-unique) readable short names to the warning codes

* Update dependencies from https://github.com/mono/linker build 20210730.2

Microsoft.NET.ILLink.Tasks
 From Version 6.0.100-preview.6.21378.1 -> To Version 6.0.100-preview.6.21380.2

* Suppress IL2111

* Update dependencies from https://github.com/mono/linker build 20210802.2

Microsoft.NET.ILLink.Tasks
 From Version 6.0.100-preview.6.21378.1 -> To Version 6.0.100-preview.6.21402.2

* Feedback

- Suppress IL2111 in trimming tests
- Remove unnecessary DynamicDependency
- Fix indentation

* Update readable warning names

Co-authored-by: Sven Boemer <[email protected]>
Co-authored-by: dotnet-maestro[bot] <dotnet-maestro[bot]@users.noreply.github.com>
2021-08-03 15:31:28 -07:00
Drew Scoggins f35b474fd5 Add new msbuild prop for wasm runtime config path (#56650) 2021-08-02 10:54:09 -07:00
Alexander Köplinger 5938d685c4 Remove invalid Castle.DynamicProxy.Internal.AbstractInvocation from ILLink descriptor files (#56392)
The type is actually in the `Castle.DynamicProxy` namespace, not the `.Internal` one.
This causes an error with newer linker versions.

The whole `Castle.DynamicProxy` namespace is already preserved so we can remove the entry for AbstractInvocation.
2021-07-27 15:06:31 -05:00
Steve Pfister 881f3c6c2b [Mono] Cleans up test build when targeting iOS/tvOSSimulator on arm64. Enables arm64 sim on CI (#55577) 2021-07-23 12:40:37 -04:00
159a01acab Update SDK to 6.0 Preview 5 (#55283)
* Update SDK to 6.0 Preview 5

Part of https://github.com/dotnet/runtime/issues/55281

* Enable COM support to work around missing symbols in tests

* Update eng/testing/linker/project.csproj.template

* Disable the workload targets

* Disable workloads for wasm builds

For in-tree builds, and tests we don't want to use workloads from dotnet
being used to build these.

For the projects being built on the build machine, we can disable them
via `Directory.Build.props`, and wasm's InTree/LocalBuild props. But for
projects that get built on helix, eg. the runtime tests, we are setting
the property values as environment variables.

* Fix setting envvars for disabling workloads

* Another attempt to fix wasm tests

In preview5, the workload manifest overrides
`$(UsingBrowserRuntimeWorkload)` setting, so pass it on the command
line.

``xml
    <PropertyGroup Condition="'$(RuntimeIdentifier)' == 'browser-wasm'">
        <UsingBrowserRuntimeWorkload Condition="'$(RunAOTCompilation)' == 'true' or '$(UsingMicrosoftNETSdkBlazorWebAssembly)' != 'true'" >true</UsingBrowserRuntimeWorkload>
        <UsingBrowserRuntimeWorkload Condition="'$(UsingBrowserRuntimeWorkload)' == ''" >$(WasmNativeWorkload)</UsingBrowserRuntimeWorkload>
    </PropertyGroup>
```

* Fix host tests after upgrade to P5

In P5 we don't generate .runtimeconfig.dev.json anymore. Some tests started to fail because they relied on the .runtime.dev.json to include local nuget cache in the probing paths.

I changed one of those tests to force-generate .runtimeconfig.dev.json as for the tested scenario it seems to make sense. For the other test I modified it to copy the necessary dependency into the right location instead.

* Fix up reflection to private FileStatus field

* Disable workload resolver for wasm.build.tests, EMSDK run

* Disable workloads for wasm with MSBuildEnableWorkloadResolver=false everywhere

* remove linker workaround

* [wasm] Remove args unnecessary for disabling workloads

* Pass MSBuildEnableWorkloadResolver property to individual trimming projects

Co-authored-by: Juan Sebastian Hoyos Ayala <[email protected]>
Co-authored-by: Santiago Fernandez Madero <[email protected]>
Co-authored-by: Larry Ewing <[email protected]>
Co-authored-by: Ankit Jain <[email protected]>
Co-authored-by: vitek-karas <[email protected]>
Co-authored-by: Eric Erhardt <[email protected]>
Co-authored-by: Anirudh Agnihotry <[email protected]>
2021-07-22 12:27:11 -07:00
Radek DoulikandPeter Sollich a587fa4b85 [wasm] Run browser tests on helix/windows (#52699)
* [wasm] Run browser tests on helix/windows

* Build just wasm/browsertests on helix/windows

* Use $(ChromiumRevision) in windows links

* Fix conditions

* Set PATH differently

* Use backslash in PATH on windows

* Try different version of chromium

* Pass scenario and browser host to build

And set browser path on windows to be able to start chrome
from xharness

* Try to get more info from the helix workitems

* Fix dir separator, add broser path

* Create WasmBuildSupportDir

* Revert "Try to get more info from the helix workitems"

This reverts commit 8807434a33a09a27f2c21cb321b743f155955cb2.

* Put the dir cmds back, fix mkdir call

* More debug info

* Bump xharness

* Bump xharness again

With darc this time

* StressLogAnalyzer didn't print the number of messages correctly if it exceeded the int range (2 billion). (#54832)

Fix is to just use 64 bit ints instead.

* Found a race condition where the LOH flag on a segment is set too late. This gives another thread the chance to allocate in a fresh LOH region that doesn't have the LOH flag set just yet and trip over an assert in Object::ValidateInner. (#54839)

The fix is simply to set the flag in get_new_region before the region is put on the list for the LOH generation.

* Try to show the chrome logs

* Use different path for chrome logs

* Use newer image with font for chrome

The chrome was crashing, because it didn't find any sans-serif font.

* Increase timeouts

* Disable tests which timeout

* Remove debug calls

* Put back normal scenario

* Do not set scenario in build args

* Add browser sample exclusion

* Restore the platform matrix

* Remove the wasm build test changes

That will be handled in https://github.com/dotnet/runtime/pull/54451

* Remove duplicate exclusion

* Suggested property name change

* Fix last merge

* Simplify condition

We don't pass Scenario anymore

* Include chrome and chromedriver in the payload

Co-authored-by: Peter Sollich <[email protected]>
2021-07-18 22:32:33 -05:00
62fad9df39 Disable array support for the COM variant wrapper classes when built-in COM is disabled. (#55756)
* Disable array support for the COM variant wrapper classes when built-in COM is disabled.

Fixes #55600

* Fix config call.

* Fix one more location of wrapper class usage.

* Fix method name.

* Add trimming test.

* Fix AV in IsArrayOfWrappers

* Fix trimming test

* Apply suggestions from code review

Co-authored-by: Eric Erhardt <[email protected]>

* Set Trim=true

Co-authored-by: Elinor Fung <[email protected]>
Co-authored-by: Eric Erhardt <[email protected]>
2021-07-18 18:46:19 -05:00
Steve Pfister 44655fd0dc Include native underlying handler support in HttpClientHandler for iOS/tvOS/MacCatalyst and Android (#55384)
Completes the plan for net6 laid out in https://github.com/dotnet/designs/blob/main/accepted/2020/mono-convergence/platform-specific-httpclient.md#the-plan-for-net-5

This change supports using either the native HttpMessageHandler types that exist in the Xamarin repos (NSUrlSessionHandler for iOS/tvOS/Catalyst and AndroidMessageHandler for Android) or SocketsHttpHandler as the underlying handler in HttpClientHandler.

The behavior for new HttpClient() was established earlier in net6, but did not go all the way. For example, if the System.Net.Http.UseNativeHttpHandler feature switch was set to true, using HttpClient in different ways would lead to different underlying handlers.

Before this PR:

// System.Net.Http.UseNativeHttpHandler == true

new HttpClient();    // Chooses the native handler as the underlying handler

var handler = new HttpClientHandler();       // SocketsHttpHandler is the only choice 
new HttpClient(handler);

The change creates a handful of partial HttpClientHandler files in order to split out the platform specific parts. As you review the PR, you'll notice a bunch of if (IsSocketHandler) blocks. The intent of these are to make use of the linker and get linked out once the linker knows which handler is the active one.

get
{
    if (IsSocketHandler)
    {
        return _socketHandler!.UseCookies;
    }
    else
    {
        return GetUseCookies();
    }
}

Get and Set methods like GetUseCookies make it easier to tell the linker via DynamicDependency to preserve the reflection calls being made to the native underlying handler.

[DynamicDependency("get_UseCookies", "Xamarin.Android.Net.AndroidMessageHandler", "Mono.Android")]
private bool GetUseCookies() => (bool)InvokeNativeHandlerMethod("get_UseCookies");

It is important to point out that the underlying handler has to be derived from HttpMessageHandler. It cannot be HttpClientHandler or you'll end up with a circular dependency.
2021-07-15 00:36:02 -04:00
Ankit JainandLarry Ewing d953229d54 [wasm] Run Wasm.Build.Tests against workloads (#54451)
Co-authored-by: Larry Ewing <[email protected]>
2021-07-14 10:47:03 -04:00
Ankit JainandLarry Ewing 0ef56df4a7 [wasm] Update Wasm.Build.Tests to build with net6.0 (#54936)
Co-authored-by: Larry Ewing <[email protected]>
2021-07-07 19:32:43 -04:00
Bill Wert 1c79e60368 Fix LLVM path (#55244) 2021-07-07 12:08:08 -07:00
Bill Wert 656775f584 Add llvm ios (#55222)
* add LLVM scenario

* add copy to payload

* reverse paths

* fix log path

* Move log fix

* remove extra scenario
2021-07-06 12:00:30 -07:00
Fan Yang a291fabdad Preserve necessary type and method (#54932)
* Preserve necessary type and method

* Change the way of getting the type

* Inline the constants

* Enable NonValidated_ValidAndInvalidValues_DictionaryMembersWork

* Enable TransformStrStrResolver3
2021-07-01 13:11:09 -04:00
a5e27d0cab [main] Update dependencies from 8 repositories (#54907)
* Update dependencies from https://github.com/dotnet/arcade build 20210628.2

Microsoft.DotNet.XUnitExtensions , Microsoft.DotNet.VersionTools.Tasks , Microsoft.DotNet.Build.Tasks.TargetFramework.Sdk , Microsoft.DotNet.Build.Tasks.Packaging , Microsoft.DotNet.Build.Tasks.Installers , Microsoft.DotNet.Build.Tasks.Feed , Microsoft.DotNet.Build.Tasks.Archives , Microsoft.DotNet.Arcade.Sdk , Microsoft.DotNet.ApiCompat , Microsoft.DotNet.CodeAnalysis , Microsoft.DotNet.XUnitConsoleRunner , Microsoft.DotNet.GenFacades , Microsoft.DotNet.GenAPI , Microsoft.DotNet.RemoteExecutor , Microsoft.DotNet.PackageTesting , Microsoft.DotNet.Helix.Sdk , Microsoft.DotNet.SharedFramework.Sdk
 From Version 6.0.0-beta.21324.3 -> To Version 6.0.0-beta.21328.2

* Update dependencies from https://github.com/dotnet/icu build 20210628.1

Microsoft.NETCore.Runtime.ICU.Transport
 From Version 6.0.0-preview.7.21321.1 -> To Version 6.0.0-preview.7.21328.1

* Update dependencies from https://github.com/dotnet/xharness build 20210628.4

Microsoft.DotNet.XHarness.CLI , Microsoft.DotNet.XHarness.TestRunners.Xunit
 From Version 1.0.0-prerelease.21328.2 -> To Version 1.0.0-prerelease.21328.4

* Update dependencies from https://github.com/dotnet/llvm-project build 20210628.1

runtime.win-x64.Microsoft.NETCore.Runtime.Mono.LLVM.Tools , runtime.win-x64.Microsoft.NETCore.Runtime.Mono.LLVM.Sdk , runtime.osx.10.12-x64.Microsoft.NETCore.Runtime.Mono.LLVM.Tools , runtime.osx.10.12-x64.Microsoft.NETCore.Runtime.Mono.LLVM.Sdk , runtime.linux-arm64.Microsoft.NETCore.Runtime.Mono.LLVM.Sdk , runtime.linux-arm64.Microsoft.NETCore.Runtime.Mono.LLVM.Tools , runtime.linux-x64.Microsoft.NETCore.Runtime.Mono.LLVM.Sdk , runtime.linux-x64.Microsoft.NETCore.Runtime.Mono.LLVM.Tools
 From Version 11.1.0-alpha.1.21321.1 -> To Version 11.1.0-alpha.1.21328.1

* Update dependencies from https://github.com/mono/linker build 20210628.2

Microsoft.NET.ILLink.Tasks
 From Version 6.0.100-preview.6.21327.1 -> To Version 6.0.100-preview.6.21328.2

* Update dependencies from https://github.com/dotnet/hotreload-utils build 20210628.1

Microsoft.DotNet.HotReload.Utils.Generator.BuildTool
 From Version 1.0.1-alpha.0.21321.1 -> To Version 1.0.1-alpha.0.21328.1

* Update dependencies from https://github.com/dotnet/emsdk build 20210629.1

Microsoft.NET.Runtime.Emscripten.2.0.23.Node.win-x64
 From Version 6.0.0-preview.7.21323.1 -> To Version 6.0.0-preview.7.21329.1

* Address new IL3002 and IL3003 warnings for the latest linker to unblock the build.

* Disable the trim analyzer for tests with EnableAggressiveTrimming

* Update dependencies from https://dev.azure.com/dnceng/internal/_git/dotnet-optimization build 20210629.4

optimization.linux-x64.MIBC.Runtime , optimization.windows_nt-x64.MIBC.Runtime , optimization.windows_nt-x86.MIBC.Runtime , optimization.PGO.CoreCLR
 From Version 1.0.0-prerelease.21320.4 -> To Version 1.0.0-prerelease.21329.4

* Update dependencies from https://github.com/dotnet/arcade build 20210629.8

Microsoft.DotNet.XUnitExtensions , Microsoft.DotNet.VersionTools.Tasks , Microsoft.DotNet.Build.Tasks.TargetFramework.Sdk , Microsoft.DotNet.Build.Tasks.Packaging , Microsoft.DotNet.Build.Tasks.Installers , Microsoft.DotNet.Build.Tasks.Feed , Microsoft.DotNet.Build.Tasks.Archives , Microsoft.DotNet.Arcade.Sdk , Microsoft.DotNet.ApiCompat , Microsoft.DotNet.CodeAnalysis , Microsoft.DotNet.XUnitConsoleRunner , Microsoft.DotNet.GenFacades , Microsoft.DotNet.GenAPI , Microsoft.DotNet.RemoteExecutor , Microsoft.DotNet.PackageTesting , Microsoft.DotNet.Helix.Sdk , Microsoft.DotNet.SharedFramework.Sdk
 From Version 6.0.0-beta.21321.1 -> To Version 6.0.0-beta.21329.8

* Update dependencies from https://github.com/mono/linker build 20210629.2

Microsoft.NET.ILLink.Tasks
 From Version 6.0.100-preview.6.21317.4 -> To Version 6.0.100-preview.6.21329.2

* Update dependencies from https://github.com/dotnet/emsdk build 20210630.1

Microsoft.NET.Runtime.Emscripten.2.0.23.Node.win-x64
 From Version 6.0.0-preview.7.21323.1 -> To Version 6.0.0-preview.7.21330.1

* Update dependencies from https://github.com/mono/linker build 20210630.1

Microsoft.NET.ILLink.Tasks
 From Version 6.0.100-preview.6.21317.4 -> To Version 6.0.100-preview.6.21330.1

Co-authored-by: dotnet-maestro[bot] <dotnet-maestro[bot]@users.noreply.github.com>
Co-authored-by: Ankit Jain <[email protected]>
Co-authored-by: Eric Erhardt <[email protected]>
2021-07-01 00:37:22 -05:00
Viktor Hofer 6f7f30e118 Revert "[main] Update dependencies from 11 repositories (#54741)" (#54909)
This reverts commit 8103a7e3f2.
2021-06-29 18:18:36 +02:00
dotnet-maestro[bot] 8103a7e3f2 [main] Update dependencies from 11 repositories (#54741)
[main] Update dependencies from 11 repositories


 - Address new IL3002 and IL3003 warnings for the latest linker to unblock the build.

 - Disable the trim analyzer for tests with EnableAggressiveTrimming

 - Merge branch 'main' into darc-main-997daf91-1bd1-4e82-9eac-1347a9231dc5
2021-06-29 16:02:32 +00:00