diff options
author | Andy Ayers <andya@microsoft.com> | 2017-02-17 17:17:34 -0800 |
---|---|---|
committer | GitHub <noreply@github.com> | 2017-02-17 17:17:34 -0800 |
commit | f685d633c131a17cbfdc1ef1ae6ad8a56779a135 (patch) | |
tree | ddbab5624a04401ad13b042caa7325022e43ba23 /tests | |
parent | 380cda50c89fa4534b9b8f144d1ecec0bb5d584b (diff) | |
parent | fc8c7ec56bc1cab1525c879f2c4776766830ab67 (diff) | |
download | coreclr-f685d633c131a17cbfdc1ef1ae6ad8a56779a135.tar.gz coreclr-f685d633c131a17cbfdc1ef1ae6ad8a56779a135.tar.bz2 coreclr-f685d633c131a17cbfdc1ef1ae6ad8a56779a135.zip |
Merge pull request #9657 from AndyAyersMS/FixFinallyChainMergeAssert
JIT: relax assert in fgMergeFinallyChains
Diffstat (limited to 'tests')
-rw-r--r-- | tests/src/jit/Regression/JitBlue/GitHub_9651/GitHub_9651.il | 44 | ||||
-rw-r--r-- | tests/src/jit/Regression/JitBlue/GitHub_9651/GitHub_9651.ilproj | 41 |
2 files changed, 85 insertions, 0 deletions
diff --git a/tests/src/jit/Regression/JitBlue/GitHub_9651/GitHub_9651.il b/tests/src/jit/Regression/JitBlue/GitHub_9651/GitHub_9651.il new file mode 100644 index 0000000000..28ca36ae7e --- /dev/null +++ b/tests/src/jit/Regression/JitBlue/GitHub_9651/GitHub_9651.il @@ -0,0 +1,44 @@ +// Licensed to the .NET Foundation under one or more agreements. +// The .NET Foundation licenses this file to you under the MIT license. +// See the LICENSE file in the project root for more information. + +.assembly extern mscorlib {} +.assembly a {} +.module a.exe + +// Test case triggers reimportation of a leave, +// leading to an unreachable callfinally pair. + +.class FinallyReimp +{ +.method static int32 Main(class [mscorlib]System.String[]) cil managed +{ + .entrypoint + .locals init (int32 V0, native int V1) + .try + { + ldarg.0 + ldlen + ldc.i4 1 + beq FOO + ldloca V0 + br JOIN +FOO: + ldc.i4 0 +JOIN: + stloc V1 + leave AFTER + } + finally + { + ldc.i4 100 + stloc.0 + endfinally + } +AFTER: + ldloc.1 + ldind.i + ret +} +} + diff --git a/tests/src/jit/Regression/JitBlue/GitHub_9651/GitHub_9651.ilproj b/tests/src/jit/Regression/JitBlue/GitHub_9651/GitHub_9651.ilproj new file mode 100644 index 0000000000..0a2003afca --- /dev/null +++ b/tests/src/jit/Regression/JitBlue/GitHub_9651/GitHub_9651.ilproj @@ -0,0 +1,41 @@ +<?xml version="1.0" encoding="utf-8"?> +<Project ToolsVersion="12.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003"> + <Import Project="$([MSBuild]::GetDirectoryNameOfFileAbove($(MSBuildThisFileDirectory), dir.props))\dir.props" /> + <PropertyGroup> + <Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration> + <Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform> + <AssemblyName>$(MSBuildProjectName)</AssemblyName> + <SchemaVersion>2.0</SchemaVersion> + <ProjectGuid>{95DFC527-4DC1-495E-97D7-E94EE1F7140D}</ProjectGuid> + <OutputType>Exe</OutputType> + <AppDesignerFolder>Properties</AppDesignerFolder> + <FileAlignment>512</FileAlignment> + <ProjectTypeGuids>{786C830F-07A1-408B-BD7F-6EE04809D6DB};{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}</ProjectTypeGuids> + <ReferencePath>$(ProgramFiles)\Common Files\microsoft shared\VSTT .0\UITestExtensionPackages</ReferencePath> + <SolutionDir Condition="$(SolutionDir) == '' Or $(SolutionDir) == '*Undefined*'">..\..\</SolutionDir> + <NuGetPackageImportStamp>7a9bfb7d</NuGetPackageImportStamp> + </PropertyGroup> + <!-- Default configurations to help VS understand the configurations --> + <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' "> + </PropertyGroup> + <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' "> + </PropertyGroup> + <ItemGroup> + <CodeAnalysisDependentAssemblyPaths Condition=" '$(VS100COMNTOOLS)' != '' " Include="$(VS100COMNTOOLS)..\IDE\PrivateAssemblies"> + <Visible>False</Visible> + </CodeAnalysisDependentAssemblyPaths> + </ItemGroup> + <PropertyGroup> + <DebugType>None</DebugType> + <Optimize>True</Optimize> + </PropertyGroup> + <ItemGroup> + <Compile Include="GitHub_9651.il" /> + </ItemGroup> + <ItemGroup> + <Service Include="{82A7F48D-3B50-4B1E-B82E-3ADA8210C358}" /> + </ItemGroup> + <Import Project="$([MSBuild]::GetDirectoryNameOfFileAbove($(MSBuildThisFileDirectory), dir.targets))\dir.targets" /> + <PropertyGroup Condition=" '$(MsBuildProjectDirOverride)' != '' "> + </PropertyGroup> +</Project> |