From 8dde57ec136eccb0ac42079b5d65f3f91a01bf4a Mon Sep 17 00:00:00 2001 From: Julien Couvreur Date: Wed, 17 Jan 2018 16:39:17 -0800 Subject: [PATCH 1/4] Splitting ILVerify into exe and library --- src/ILVerification/ILVerification.sln | 31 ++ src/ILVerification/README.md | 3 + .../src/AccessVerificationHelpers.cs | 0 src/ILVerification/src/AssemblyInfo.cs | 4 + .../src/ILImporter.StackValue.cs | 0 .../src/ILImporter.Verify.cs | 0 src/ILVerification/src/ILVerification.csproj | 303 ++++++++++++++++++ .../src/ILVerifyTypeSystemContext.cs | 0 .../src/IResolver.cs | 0 .../src/InstantiatedGenericParameter.cs | 0 .../src/Resources/Strings.resx | 0 ...impleArrayOfTRuntimeInterfacesAlgorithm.cs | 0 .../src/TypeSystemHelpers.cs | 0 .../src/VerificationResult.cs | 0 .../src/Verifier.cs | 2 +- .../src/VerifierError.cs | 0 .../tests/ILMethodTester.cs | 0 .../tests/ILTests/AccessTests.il | 0 .../tests/ILTests/AccessTestsExtern.il | 0 .../tests/ILTests/AccessTestsFriend.il | 0 .../tests/ILTests/ArrayTests.il | 0 .../tests/ILTests/BasicArithmeticTests.il | 0 .../tests/ILTests/BranchingTests.il | 0 .../tests/ILTests/CallTests.il | 0 .../tests/ILTests/CastingTests.il | 0 .../tests/ILTests/ComparisonTests.il | 0 .../tests/ILTests/DelegateTests.il | 0 .../tests/ILTests/ExceptionRegionTests.il | 0 .../tests/ILTests/FieldTests.il | 0 .../tests/ILTests/FtnTests.il | 0 .../tests/ILTests/LoadStoreIndirectTests.il | 0 .../tests/ILTests/NewobjTests.il | 0 .../tests/ILTests/PrefixTests.il | 0 .../tests/ILTests/ReturnTests.il | 0 .../tests/ILTests/ShiftTests.il | 0 .../tests/ILTests/SwitchTests.il | 0 .../tests/ILTests/ThisStateTests.il | 0 .../tests/ILTests/ValueTypeTests.il | 0 .../tests/ILVerification.Tests.csproj} | 7 +- .../tests/TestDataLoader.cs | 0 src/ILVerify/ILVerify.sln | 19 +- src/ILVerify/README.md | 14 +- src/ILVerify/src/AssemblyInfo.cs | 3 - src/ILVerify/src/ILVerify.csproj | 292 +---------------- 44 files changed, 373 insertions(+), 305 deletions(-) create mode 100644 src/ILVerification/ILVerification.sln create mode 100644 src/ILVerification/README.md rename src/{ILVerify => ILVerification}/src/AccessVerificationHelpers.cs (100%) create mode 100644 src/ILVerification/src/AssemblyInfo.cs rename src/{ILVerify => ILVerification}/src/ILImporter.StackValue.cs (100%) rename src/{ILVerify => ILVerification}/src/ILImporter.Verify.cs (100%) create mode 100644 src/ILVerification/src/ILVerification.csproj rename src/{ILVerify => ILVerification}/src/ILVerifyTypeSystemContext.cs (100%) rename src/{ILVerify => ILVerification}/src/IResolver.cs (100%) rename src/{ILVerify => ILVerification}/src/InstantiatedGenericParameter.cs (100%) rename src/{ILVerify => ILVerification}/src/Resources/Strings.resx (100%) rename src/{ILVerify => ILVerification}/src/SimpleArrayOfTRuntimeInterfacesAlgorithm.cs (100%) rename src/{ILVerify => ILVerification}/src/TypeSystemHelpers.cs (100%) rename src/{ILVerify => ILVerification}/src/VerificationResult.cs (100%) rename src/{ILVerify => ILVerification}/src/Verifier.cs (99%) rename src/{ILVerify => ILVerification}/src/VerifierError.cs (100%) rename src/{ILVerify => ILVerification}/tests/ILMethodTester.cs (100%) rename src/{ILVerify => ILVerification}/tests/ILTests/AccessTests.il (100%) rename src/{ILVerify => ILVerification}/tests/ILTests/AccessTestsExtern.il (100%) rename src/{ILVerify => ILVerification}/tests/ILTests/AccessTestsFriend.il (100%) rename src/{ILVerify => ILVerification}/tests/ILTests/ArrayTests.il (100%) rename src/{ILVerify => ILVerification}/tests/ILTests/BasicArithmeticTests.il (100%) rename src/{ILVerify => ILVerification}/tests/ILTests/BranchingTests.il (100%) rename src/{ILVerify => ILVerification}/tests/ILTests/CallTests.il (100%) rename src/{ILVerify => ILVerification}/tests/ILTests/CastingTests.il (100%) rename src/{ILVerify => ILVerification}/tests/ILTests/ComparisonTests.il (100%) rename src/{ILVerify => ILVerification}/tests/ILTests/DelegateTests.il (100%) rename src/{ILVerify => ILVerification}/tests/ILTests/ExceptionRegionTests.il (100%) rename src/{ILVerify => ILVerification}/tests/ILTests/FieldTests.il (100%) rename src/{ILVerify => ILVerification}/tests/ILTests/FtnTests.il (100%) rename src/{ILVerify => ILVerification}/tests/ILTests/LoadStoreIndirectTests.il (100%) rename src/{ILVerify => ILVerification}/tests/ILTests/NewobjTests.il (100%) rename src/{ILVerify => ILVerification}/tests/ILTests/PrefixTests.il (100%) rename src/{ILVerify => ILVerification}/tests/ILTests/ReturnTests.il (100%) rename src/{ILVerify => ILVerification}/tests/ILTests/ShiftTests.il (100%) rename src/{ILVerify => ILVerification}/tests/ILTests/SwitchTests.il (100%) rename src/{ILVerify => ILVerification}/tests/ILTests/ThisStateTests.il (100%) rename src/{ILVerify => ILVerification}/tests/ILTests/ValueTypeTests.il (100%) rename src/{ILVerify/tests/ILVerify.Tests.csproj => ILVerification/tests/ILVerification.Tests.csproj} (80%) rename src/{ILVerify => ILVerification}/tests/TestDataLoader.cs (100%) delete mode 100644 src/ILVerify/src/AssemblyInfo.cs diff --git a/src/ILVerification/ILVerification.sln b/src/ILVerification/ILVerification.sln new file mode 100644 index 00000000000..a5b238ba06a --- /dev/null +++ b/src/ILVerification/ILVerification.sln @@ -0,0 +1,31 @@ + +Microsoft Visual Studio Solution File, Format Version 12.00 +# Visual Studio 15 +VisualStudioVersion = 15.0.26510.0 +MinimumVisualStudioVersion = 10.0.40219.1 +Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "ILVerfication", "src\ILVerfication.csproj", "{56AA4730-39A4-4B48-95E9-89E8A29F0A06}" +EndProject +Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "ILVerification.Tests", "tests\ILVerification.Tests.csproj", "{1228E4B6-E5E5-414A-94EC-69B792984FAB}" +EndProject +Global + GlobalSection(SolutionConfigurationPlatforms) = preSolution + Debug|Any CPU = Debug|Any CPU + Release|Any CPU = Release|Any CPU + EndGlobalSection + GlobalSection(ProjectConfigurationPlatforms) = postSolution + {56AA4730-39A4-4B48-95E9-89E8A29F0A06}.Debug|Any CPU.ActiveCfg = Debug|Any CPU + {56AA4730-39A4-4B48-95E9-89E8A29F0A06}.Debug|Any CPU.Build.0 = Debug|Any CPU + {56AA4730-39A4-4B48-95E9-89E8A29F0A06}.Release|Any CPU.ActiveCfg = Release|Any CPU + {56AA4730-39A4-4B48-95E9-89E8A29F0A06}.Release|Any CPU.Build.0 = Release|Any CPU + {1228E4B6-E5E5-414A-94EC-69B792984FAB}.Debug|Any CPU.ActiveCfg = Debug|Any CPU + {1228E4B6-E5E5-414A-94EC-69B792984FAB}.Debug|Any CPU.Build.0 = Debug|Any CPU + {1228E4B6-E5E5-414A-94EC-69B792984FAB}.Release|Any CPU.ActiveCfg = Release|Any CPU + {1228E4B6-E5E5-414A-94EC-69B792984FAB}.Release|Any CPU.Build.0 = Release|Any CPU + EndGlobalSection + GlobalSection(SolutionProperties) = preSolution + HideSolutionNode = FALSE + EndGlobalSection + GlobalSection(ExtensibilityGlobals) = postSolution + SolutionGuid = {3B6C08A7-1F82-4EC0-9CA7-1F07716F36B1} + EndGlobalSection +EndGlobal diff --git a/src/ILVerification/README.md b/src/ILVerification/README.md new file mode 100644 index 00000000000..6056ba59aee --- /dev/null +++ b/src/ILVerification/README.md @@ -0,0 +1,3 @@ +# ILVerification + +The ILVerification library is part of the ILVerify project. See details under [src/ILVerify/](https://github.com/dotnet/corert/tree/master/src/ILVerify). \ No newline at end of file diff --git a/src/ILVerify/src/AccessVerificationHelpers.cs b/src/ILVerification/src/AccessVerificationHelpers.cs similarity index 100% rename from src/ILVerify/src/AccessVerificationHelpers.cs rename to src/ILVerification/src/AccessVerificationHelpers.cs diff --git a/src/ILVerification/src/AssemblyInfo.cs b/src/ILVerification/src/AssemblyInfo.cs new file mode 100644 index 00000000000..722ae42996f --- /dev/null +++ b/src/ILVerification/src/AssemblyInfo.cs @@ -0,0 +1,4 @@ +using System.Runtime.CompilerServices; + +[assembly: InternalsVisibleTo("ILVerification.Tests")] +[assembly: InternalsVisibleTo("ILVerify")] diff --git a/src/ILVerify/src/ILImporter.StackValue.cs b/src/ILVerification/src/ILImporter.StackValue.cs similarity index 100% rename from src/ILVerify/src/ILImporter.StackValue.cs rename to src/ILVerification/src/ILImporter.StackValue.cs diff --git a/src/ILVerify/src/ILImporter.Verify.cs b/src/ILVerification/src/ILImporter.Verify.cs similarity index 100% rename from src/ILVerify/src/ILImporter.Verify.cs rename to src/ILVerification/src/ILImporter.Verify.cs diff --git a/src/ILVerification/src/ILVerification.csproj b/src/ILVerification/src/ILVerification.csproj new file mode 100644 index 00000000000..c7a6161a38c --- /dev/null +++ b/src/ILVerification/src/ILVerification.csproj @@ -0,0 +1,303 @@ + + + + Library + netcoreapp2.0;net46 + AnyCPU + false + true + false + + + + + + + + + + + + + + + + + + + + TypeSystem\CodeGen\MethodDesc.CodeGen.cs + + + Utilities\AlignmentHelper.cs + + + TypeSystem\Common\CastingHelper.cs + + + TypeSystem\Common\FunctionPointerType.cs + + + TypeSystem\Common\IAssemblyDesc.cs + + + TypeSystem\Common\Instantiation.cs + + + TypeSystem\Common\ModuleDesc.cs + + + TypeSystem\Common\TypeSystemEntity.cs + + + TypeSystem\Common\TypeSystemException.cs + + + Utilities\CustomAttributeTypeNameParser.cs + + + Utilities\LockFreeReaderHashtable.cs + + + TypeSystem\Common\ArrayType.cs + + + TypeSystem\Common\ArrayOfTRuntimeInterfacesAlgorithm.cs + + + TypeSystem\Common\BaseTypeRuntimeInterfacesAlgorithm.cs + + + TypeSystem\Common\ByRefType.cs + + + TypeSystem\Common\GenericParameterDesc.cs + + + TypeSystem\Common\ExceptionStringID.cs + + + TypeSystem\Common\FieldForInstantiatedType.cs + + + TypeSystem\Common\FieldDesc.cs + + + TypeSystem\Common\FieldDesc.FieldLayout.cs + + + TypeSystem\Common\FieldLayoutAlgorithm.cs + + + TypeSystem\Common\InstantiatedMethod.cs + + + TypeSystem\Common\InstantiatedType.cs + + + TypeSystem\Common\InstantiatedType.Interfaces.cs + + + TypeSystem\Common\InstantiatedType.MethodImpls.cs + + + TypeSystem\Common\LayoutInt.cs + + + TypeSystem\Common\MetadataType.cs + + + TypeSystem\Common\MetadataType.Interfaces.cs + + + TypeSystem\Common\MetadataType.MethodImpls.cs + + + TypeSystem\Common\MetadataFieldLayoutAlgorithm.cs + + + TypeSystem\Common\MetadataRuntimeInterfacesAlgorithm.cs + + + TypeSystem\Common\MetadataTypeSystemContext.cs + + + TypeSystem\Common\MethodForInstantiatedType.cs + + + TypeSystem\Common\ParameterizedType.cs + + + TypeSystem\Common\PointerType.cs + + + TypeSystem\Common\PropertySignature.cs + + + TypeSystem\Common\SignatureVariable.cs + + + TypeSystem\Common\TargetDetails.cs + + + TypeSystem\Common\ThreadSafeFlags.cs + + + TypeSystem\Common\TypeFlags.cs + + + TypeSystem\Common\TypeHashingAlgorithms.cs + + + TypeSystem\Common\TypeSystemContext.cs + + + TypeSystem\Common\TypeSystemHelpers.cs + + + Utilities\TypeNameFormatter.cs + + + TypeSystem\Common\WellKnownType.cs + + + TypeSystem\Common\VirtualMethodAlgorithm.cs + + + TypeSystem\Common\MethodDesc.cs + + + TypeSystem\Common\StandardVirtualMethodAlgorithm.cs + + + TypeSystem\Common\TypeDesc.cs + + + TypeSystem\Common\TypeDesc.Interfaces.cs + + + TypeSystem\Common\DefType.cs + + + TypeSystem\Common\DefType.FieldLayout.cs + + + TypeSystem\Common\RuntimeInterfacesAlgorithm.cs + + + TypeSystem\Common\ThrowHelper.Common.cs + + + TypeSystem\Common\ThrowHelper.cs + + + TypeSystem\Common\Utilities\ExceptionTypeNameFormatter.cs + + + TypeSystem\Common\Utilities\ExceptionTypeNameFormatter.Metadata.cs + + + Ecma\CustomAttributeTypeProvider.cs + + + Ecma\EcmaAssembly.cs + + + Ecma\EcmaField.cs + + + Ecma\EcmaGenericParameter.cs + + + Ecma\EcmaMethod.cs + + + Ecma\EcmaModule.cs + + + Ecma\EcmaSignatureParser.cs + + + Ecma\EcmaType.cs + + + Ecma\EcmaType.MethodImpls.cs + + + Ecma\EcmaType.Interfaces.cs + + + Ecma\MetadataExtensions.cs + + + Ecma\IMetadataStringDecoderProvider.cs + + + Ecma\CachingMetadataStringDecoder.cs + + + Ecma\PrimitiveTypeProvider.cs + + + IL\EcmaMethodIL.cs + + + IL\MethodIL.cs + + + IL\MethodILDebugView.cs + + + IL\ILDisassembler.cs + + + IL\InstantiatedMethodIL.cs + + + IL\ILOpcode.cs + + + IL\ILImporter.cs + + + Interop\InstantiatedType.Interop.cs + + + Interop\MetadataType.Interop.cs + + + Interop\MethodDesc.Interop.cs + + + TypeSystem\Interop\MarshalAsDescriptor.cs + + + Utilities\ArrayBuilder.cs + + + TypeSystem\Common\LocalVariableDefinition.cs + + + Common\System\FormattingHelpers.cs + + + TypeSystem\Common\TypeSystemConstraintsHelpers.cs + + + + + CommandLine\CommandLineException.cs + + + CommandLine\CommandLineHelpers.cs + + + System\NotImplemented.cs + + + + + + + + diff --git a/src/ILVerify/src/ILVerifyTypeSystemContext.cs b/src/ILVerification/src/ILVerifyTypeSystemContext.cs similarity index 100% rename from src/ILVerify/src/ILVerifyTypeSystemContext.cs rename to src/ILVerification/src/ILVerifyTypeSystemContext.cs diff --git a/src/ILVerify/src/IResolver.cs b/src/ILVerification/src/IResolver.cs similarity index 100% rename from src/ILVerify/src/IResolver.cs rename to src/ILVerification/src/IResolver.cs diff --git a/src/ILVerify/src/InstantiatedGenericParameter.cs b/src/ILVerification/src/InstantiatedGenericParameter.cs similarity index 100% rename from src/ILVerify/src/InstantiatedGenericParameter.cs rename to src/ILVerification/src/InstantiatedGenericParameter.cs diff --git a/src/ILVerify/src/Resources/Strings.resx b/src/ILVerification/src/Resources/Strings.resx similarity index 100% rename from src/ILVerify/src/Resources/Strings.resx rename to src/ILVerification/src/Resources/Strings.resx diff --git a/src/ILVerify/src/SimpleArrayOfTRuntimeInterfacesAlgorithm.cs b/src/ILVerification/src/SimpleArrayOfTRuntimeInterfacesAlgorithm.cs similarity index 100% rename from src/ILVerify/src/SimpleArrayOfTRuntimeInterfacesAlgorithm.cs rename to src/ILVerification/src/SimpleArrayOfTRuntimeInterfacesAlgorithm.cs diff --git a/src/ILVerify/src/TypeSystemHelpers.cs b/src/ILVerification/src/TypeSystemHelpers.cs similarity index 100% rename from src/ILVerify/src/TypeSystemHelpers.cs rename to src/ILVerification/src/TypeSystemHelpers.cs diff --git a/src/ILVerify/src/VerificationResult.cs b/src/ILVerification/src/VerificationResult.cs similarity index 100% rename from src/ILVerify/src/VerificationResult.cs rename to src/ILVerification/src/VerificationResult.cs diff --git a/src/ILVerify/src/Verifier.cs b/src/ILVerification/src/Verifier.cs similarity index 99% rename from src/ILVerify/src/Verifier.cs rename to src/ILVerification/src/Verifier.cs index 8e10ec212da..aa17d13b967 100644 --- a/src/ILVerify/src/Verifier.cs +++ b/src/ILVerification/src/Verifier.cs @@ -18,7 +18,7 @@ namespace ILVerify public class Verifier { private Lazy _stringResourceManager = - new Lazy(() => new ResourceManager("ILVerify.Resources.Strings", Assembly.GetExecutingAssembly())); + new Lazy(() => new ResourceManager("ILVerification.Resources.Strings", Assembly.GetExecutingAssembly())); private ILVerifyTypeSystemContext _typeSystemContext; diff --git a/src/ILVerify/src/VerifierError.cs b/src/ILVerification/src/VerifierError.cs similarity index 100% rename from src/ILVerify/src/VerifierError.cs rename to src/ILVerification/src/VerifierError.cs diff --git a/src/ILVerify/tests/ILMethodTester.cs b/src/ILVerification/tests/ILMethodTester.cs similarity index 100% rename from src/ILVerify/tests/ILMethodTester.cs rename to src/ILVerification/tests/ILMethodTester.cs diff --git a/src/ILVerify/tests/ILTests/AccessTests.il b/src/ILVerification/tests/ILTests/AccessTests.il similarity index 100% rename from src/ILVerify/tests/ILTests/AccessTests.il rename to src/ILVerification/tests/ILTests/AccessTests.il diff --git a/src/ILVerify/tests/ILTests/AccessTestsExtern.il b/src/ILVerification/tests/ILTests/AccessTestsExtern.il similarity index 100% rename from src/ILVerify/tests/ILTests/AccessTestsExtern.il rename to src/ILVerification/tests/ILTests/AccessTestsExtern.il diff --git a/src/ILVerify/tests/ILTests/AccessTestsFriend.il b/src/ILVerification/tests/ILTests/AccessTestsFriend.il similarity index 100% rename from src/ILVerify/tests/ILTests/AccessTestsFriend.il rename to src/ILVerification/tests/ILTests/AccessTestsFriend.il diff --git a/src/ILVerify/tests/ILTests/ArrayTests.il b/src/ILVerification/tests/ILTests/ArrayTests.il similarity index 100% rename from src/ILVerify/tests/ILTests/ArrayTests.il rename to src/ILVerification/tests/ILTests/ArrayTests.il diff --git a/src/ILVerify/tests/ILTests/BasicArithmeticTests.il b/src/ILVerification/tests/ILTests/BasicArithmeticTests.il similarity index 100% rename from src/ILVerify/tests/ILTests/BasicArithmeticTests.il rename to src/ILVerification/tests/ILTests/BasicArithmeticTests.il diff --git a/src/ILVerify/tests/ILTests/BranchingTests.il b/src/ILVerification/tests/ILTests/BranchingTests.il similarity index 100% rename from src/ILVerify/tests/ILTests/BranchingTests.il rename to src/ILVerification/tests/ILTests/BranchingTests.il diff --git a/src/ILVerify/tests/ILTests/CallTests.il b/src/ILVerification/tests/ILTests/CallTests.il similarity index 100% rename from src/ILVerify/tests/ILTests/CallTests.il rename to src/ILVerification/tests/ILTests/CallTests.il diff --git a/src/ILVerify/tests/ILTests/CastingTests.il b/src/ILVerification/tests/ILTests/CastingTests.il similarity index 100% rename from src/ILVerify/tests/ILTests/CastingTests.il rename to src/ILVerification/tests/ILTests/CastingTests.il diff --git a/src/ILVerify/tests/ILTests/ComparisonTests.il b/src/ILVerification/tests/ILTests/ComparisonTests.il similarity index 100% rename from src/ILVerify/tests/ILTests/ComparisonTests.il rename to src/ILVerification/tests/ILTests/ComparisonTests.il diff --git a/src/ILVerify/tests/ILTests/DelegateTests.il b/src/ILVerification/tests/ILTests/DelegateTests.il similarity index 100% rename from src/ILVerify/tests/ILTests/DelegateTests.il rename to src/ILVerification/tests/ILTests/DelegateTests.il diff --git a/src/ILVerify/tests/ILTests/ExceptionRegionTests.il b/src/ILVerification/tests/ILTests/ExceptionRegionTests.il similarity index 100% rename from src/ILVerify/tests/ILTests/ExceptionRegionTests.il rename to src/ILVerification/tests/ILTests/ExceptionRegionTests.il diff --git a/src/ILVerify/tests/ILTests/FieldTests.il b/src/ILVerification/tests/ILTests/FieldTests.il similarity index 100% rename from src/ILVerify/tests/ILTests/FieldTests.il rename to src/ILVerification/tests/ILTests/FieldTests.il diff --git a/src/ILVerify/tests/ILTests/FtnTests.il b/src/ILVerification/tests/ILTests/FtnTests.il similarity index 100% rename from src/ILVerify/tests/ILTests/FtnTests.il rename to src/ILVerification/tests/ILTests/FtnTests.il diff --git a/src/ILVerify/tests/ILTests/LoadStoreIndirectTests.il b/src/ILVerification/tests/ILTests/LoadStoreIndirectTests.il similarity index 100% rename from src/ILVerify/tests/ILTests/LoadStoreIndirectTests.il rename to src/ILVerification/tests/ILTests/LoadStoreIndirectTests.il diff --git a/src/ILVerify/tests/ILTests/NewobjTests.il b/src/ILVerification/tests/ILTests/NewobjTests.il similarity index 100% rename from src/ILVerify/tests/ILTests/NewobjTests.il rename to src/ILVerification/tests/ILTests/NewobjTests.il diff --git a/src/ILVerify/tests/ILTests/PrefixTests.il b/src/ILVerification/tests/ILTests/PrefixTests.il similarity index 100% rename from src/ILVerify/tests/ILTests/PrefixTests.il rename to src/ILVerification/tests/ILTests/PrefixTests.il diff --git a/src/ILVerify/tests/ILTests/ReturnTests.il b/src/ILVerification/tests/ILTests/ReturnTests.il similarity index 100% rename from src/ILVerify/tests/ILTests/ReturnTests.il rename to src/ILVerification/tests/ILTests/ReturnTests.il diff --git a/src/ILVerify/tests/ILTests/ShiftTests.il b/src/ILVerification/tests/ILTests/ShiftTests.il similarity index 100% rename from src/ILVerify/tests/ILTests/ShiftTests.il rename to src/ILVerification/tests/ILTests/ShiftTests.il diff --git a/src/ILVerify/tests/ILTests/SwitchTests.il b/src/ILVerification/tests/ILTests/SwitchTests.il similarity index 100% rename from src/ILVerify/tests/ILTests/SwitchTests.il rename to src/ILVerification/tests/ILTests/SwitchTests.il diff --git a/src/ILVerify/tests/ILTests/ThisStateTests.il b/src/ILVerification/tests/ILTests/ThisStateTests.il similarity index 100% rename from src/ILVerify/tests/ILTests/ThisStateTests.il rename to src/ILVerification/tests/ILTests/ThisStateTests.il diff --git a/src/ILVerify/tests/ILTests/ValueTypeTests.il b/src/ILVerification/tests/ILTests/ValueTypeTests.il similarity index 100% rename from src/ILVerify/tests/ILTests/ValueTypeTests.il rename to src/ILVerification/tests/ILTests/ValueTypeTests.il diff --git a/src/ILVerify/tests/ILVerify.Tests.csproj b/src/ILVerification/tests/ILVerification.Tests.csproj similarity index 80% rename from src/ILVerify/tests/ILVerify.Tests.csproj rename to src/ILVerification/tests/ILVerification.Tests.csproj index 94c21cd1599..4fc70ba336d 100644 --- a/src/ILVerify/tests/ILVerify.Tests.csproj +++ b/src/ILVerification/tests/ILVerification.Tests.csproj @@ -13,15 +13,16 @@ - + - + - + + diff --git a/src/ILVerify/tests/TestDataLoader.cs b/src/ILVerification/tests/TestDataLoader.cs similarity index 100% rename from src/ILVerify/tests/TestDataLoader.cs rename to src/ILVerification/tests/TestDataLoader.cs diff --git a/src/ILVerify/ILVerify.sln b/src/ILVerify/ILVerify.sln index a26a9be5c18..ce368247dcf 100644 --- a/src/ILVerify/ILVerify.sln +++ b/src/ILVerify/ILVerify.sln @@ -5,7 +5,9 @@ VisualStudioVersion = 15.0.26510.0 MinimumVisualStudioVersion = 10.0.40219.1 Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "ILVerify", "src\ILVerify.csproj", "{56AA4730-39A4-4B48-95E9-89E8A29F0A06}" EndProject -Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "ILVerify.Tests", "tests\ILVerify.Tests.csproj", "{1228E4B6-E5E5-414A-94EC-69B792984FAB}" +Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "ILVerification", "..\ILVerification\src\ILVerification.csproj", "{6166B258-3D41-4431-88D9-510FAF5E6927}" +EndProject +Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "ILVerification.Tests", "..\ILVerification\tests\ILVerification.Tests.csproj", "{894F0BC9-31D1-42D0-9C3F-4FC9A41CD07E}" EndProject Global GlobalSection(SolutionConfigurationPlatforms) = preSolution @@ -17,12 +19,19 @@ Global {56AA4730-39A4-4B48-95E9-89E8A29F0A06}.Debug|Any CPU.Build.0 = Debug|Any CPU {56AA4730-39A4-4B48-95E9-89E8A29F0A06}.Release|Any CPU.ActiveCfg = Release|Any CPU {56AA4730-39A4-4B48-95E9-89E8A29F0A06}.Release|Any CPU.Build.0 = Release|Any CPU - {1228E4B6-E5E5-414A-94EC-69B792984FAB}.Debug|Any CPU.ActiveCfg = Debug|Any CPU - {1228E4B6-E5E5-414A-94EC-69B792984FAB}.Debug|Any CPU.Build.0 = Debug|Any CPU - {1228E4B6-E5E5-414A-94EC-69B792984FAB}.Release|Any CPU.ActiveCfg = Release|Any CPU - {1228E4B6-E5E5-414A-94EC-69B792984FAB}.Release|Any CPU.Build.0 = Release|Any CPU + {6166B258-3D41-4431-88D9-510FAF5E6927}.Debug|Any CPU.ActiveCfg = Debug|Any CPU + {6166B258-3D41-4431-88D9-510FAF5E6927}.Debug|Any CPU.Build.0 = Debug|Any CPU + {6166B258-3D41-4431-88D9-510FAF5E6927}.Release|Any CPU.ActiveCfg = Release|Any CPU + {6166B258-3D41-4431-88D9-510FAF5E6927}.Release|Any CPU.Build.0 = Release|Any CPU + {894F0BC9-31D1-42D0-9C3F-4FC9A41CD07E}.Debug|Any CPU.ActiveCfg = Debug|Any CPU + {894F0BC9-31D1-42D0-9C3F-4FC9A41CD07E}.Debug|Any CPU.Build.0 = Debug|Any CPU + {894F0BC9-31D1-42D0-9C3F-4FC9A41CD07E}.Release|Any CPU.ActiveCfg = Release|Any CPU + {894F0BC9-31D1-42D0-9C3F-4FC9A41CD07E}.Release|Any CPU.Build.0 = Release|Any CPU EndGlobalSection GlobalSection(SolutionProperties) = preSolution HideSolutionNode = FALSE EndGlobalSection + GlobalSection(ExtensibilityGlobals) = postSolution + SolutionGuid = {3B6C08A7-1F82-4EC0-9CA7-1F07716F36B1} + EndGlobalSection EndGlobal diff --git a/src/ILVerify/README.md b/src/ILVerify/README.md index 662bf8ca2eb..b183414a8df 100644 --- a/src/ILVerify/README.md +++ b/src/ILVerify/README.md @@ -17,13 +17,17 @@ Historically on Full Framework IL generators used PEVerify to make sure that the - Fast spin up/tear down. ## The codebase -The project targets netcoreapp2.0 and uses the new .csproj based project format. If you want to open and compile it with Visual Studio then you need a version, which supports .NET Core 2.0 tooling. This is supported in Visual Studio 2017 Update 3 (Version 15.3) or later. The other option is to use command (with .NET Core 2.0 tooling). +The project targets netcoreapp2.0 and uses the new .csproj based project format. If you want to open and compile it with Visual Studio then you need a version, which supports .NET Core 2.0 tooling. This is supported in Visual Studio 2017 Update 3 (Version 15.3) or later. The other option is to use command (with .NET Core 2.0 tooling). +The code is split into three projects: +- ILVerification is the library with the core verification logic, +- ILVerification.Tests contains the tests for ILVerification, +- ILVerify is an application that provides a command-line interface on top of ILVerification. ## Tests -To test ILVerify we have small methods checked in as .il files testing specific verification scenarios. These tests live under [src/ILVerify/tests/ILTests](https://github.com/dotnet/corert/tree/master/src/ILVerify/tests/ILTests). Tests are grouped into .il files based on functionalities they test. There is no strict policy here, the goal is to have a few dozen .il files instead of thousands containing each only a single method. +To test the ILVerification library we have small methods checked in as .il files testing specific verification scenarios. These tests live under [src/ILVerification/tests/ILTests](https://github.com/dotnet/corert/tree/master/src/ILVerification/tests/ILTests). Tests are grouped into .il files based on functionalities they test. There is no strict policy here, the goal is to have a few dozen .il files instead of thousands containing each only a single method. -Currently the IL files are NOT compiled automatically. You have to compile manually (We want to automatize this step later): +Currently the IL files are NOT compiled automatically. You have to compile manually (We want to automate this step later): ``` ilasm [filename.il] /dll /ERROR @@ -35,7 +39,7 @@ Note: if you run the tests and get an error similar to this then it means that t Result Message: System.InvalidOperationException : No data found for ILVerify.Tests.ILMethodTester.TestMethodsWithInvalidIL ``` -The test project itself is under [src/ILVerify/tests](https://github.com/dotnet/corert/tree/master/src/ILVerify/tests) +The test project itself is under [src/ILVerification/tests](https://github.com/dotnet/corert/tree/master/src/ILVerification/tests) Method names in the .il files must follow the following naming convention: @@ -58,7 +62,7 @@ E.g.: ```SimpleAdd_Valid``` The method name must contain 2 '`_`' characters. 1. part: a friendly name 2. part: must be the word 'Invalid' (Case sensitive) - 3. part: the expected [VerifierErrors](https://github.com/dotnet/corert/blob/master/src/ILVerify/src/VerifierError.cs) as string separated by '.'. We assert on these errors; the test fails if ILVerify does not report these errors. + 3. part: the expected [VerifierErrors](https://github.com/dotnet/corert/blob/master/src/ILVerification/src/VerifierError.cs) as string separated by '.'. We assert on these errors; the test fails if ILVerify does not report these errors. E.g.: ```SimpleAdd_Invalid_ExpectedNumericType``` diff --git a/src/ILVerify/src/AssemblyInfo.cs b/src/ILVerify/src/AssemblyInfo.cs deleted file mode 100644 index 8e392ff7bc6..00000000000 --- a/src/ILVerify/src/AssemblyInfo.cs +++ /dev/null @@ -1,3 +0,0 @@ -using System.Runtime.CompilerServices; - -[assembly: InternalsVisibleTo("ILVerify.Tests")] diff --git a/src/ILVerify/src/ILVerify.csproj b/src/ILVerify/src/ILVerify.csproj index aad89545205..042fd7946c3 100644 --- a/src/ILVerify/src/ILVerify.csproj +++ b/src/ILVerify/src/ILVerify.csproj @@ -7,299 +7,15 @@ false true false + + - - - - - - - - - - - - - - - - TypeSystem\CodeGen\MethodDesc.CodeGen.cs - - - Utilities\AlignmentHelper.cs - - - TypeSystem\Common\CastingHelper.cs - - - TypeSystem\Common\FunctionPointerType.cs - - - TypeSystem\Common\IAssemblyDesc.cs - - - TypeSystem\Common\Instantiation.cs - - - TypeSystem\Common\ModuleDesc.cs - - - TypeSystem\Common\TypeSystemEntity.cs - - - TypeSystem\Common\TypeSystemException.cs - - - Utilities\CustomAttributeTypeNameParser.cs - - - Utilities\LockFreeReaderHashtable.cs - - - TypeSystem\Common\ArrayType.cs - - - TypeSystem\Common\ArrayOfTRuntimeInterfacesAlgorithm.cs - - - TypeSystem\Common\BaseTypeRuntimeInterfacesAlgorithm.cs - - - TypeSystem\Common\ByRefType.cs - - - TypeSystem\Common\GenericParameterDesc.cs - - - TypeSystem\Common\ExceptionStringID.cs - - - TypeSystem\Common\FieldForInstantiatedType.cs - - - TypeSystem\Common\FieldDesc.cs - - - TypeSystem\Common\FieldDesc.FieldLayout.cs - - - TypeSystem\Common\FieldLayoutAlgorithm.cs - - - TypeSystem\Common\InstantiatedMethod.cs - - - TypeSystem\Common\InstantiatedType.cs - - - TypeSystem\Common\InstantiatedType.Interfaces.cs - - - TypeSystem\Common\InstantiatedType.MethodImpls.cs - - - TypeSystem\Common\LayoutInt.cs - - - TypeSystem\Common\MetadataType.cs - - - TypeSystem\Common\MetadataType.Interfaces.cs - - - TypeSystem\Common\MetadataType.MethodImpls.cs - - - TypeSystem\Common\MetadataFieldLayoutAlgorithm.cs - - - TypeSystem\Common\MetadataRuntimeInterfacesAlgorithm.cs - - - TypeSystem\Common\MetadataTypeSystemContext.cs - - - TypeSystem\Common\MethodForInstantiatedType.cs - - - TypeSystem\Common\ParameterizedType.cs - - - TypeSystem\Common\PointerType.cs - - - TypeSystem\Common\PropertySignature.cs - - - TypeSystem\Common\SignatureVariable.cs - - - TypeSystem\Common\TargetDetails.cs - - - TypeSystem\Common\ThreadSafeFlags.cs - - - TypeSystem\Common\TypeFlags.cs - - - TypeSystem\Common\TypeHashingAlgorithms.cs - - - TypeSystem\Common\TypeSystemContext.cs - - - TypeSystem\Common\TypeSystemHelpers.cs - - - Utilities\TypeNameFormatter.cs - - - TypeSystem\Common\WellKnownType.cs - - - TypeSystem\Common\VirtualMethodAlgorithm.cs - - - TypeSystem\Common\MethodDesc.cs - - - TypeSystem\Common\StandardVirtualMethodAlgorithm.cs - - - TypeSystem\Common\TypeDesc.cs - - - TypeSystem\Common\TypeDesc.Interfaces.cs - - - TypeSystem\Common\DefType.cs - - - TypeSystem\Common\DefType.FieldLayout.cs - - - TypeSystem\Common\RuntimeInterfacesAlgorithm.cs - - - TypeSystem\Common\ThrowHelper.Common.cs - - - TypeSystem\Common\ThrowHelper.cs - - - TypeSystem\Common\Utilities\ExceptionTypeNameFormatter.cs - - - TypeSystem\Common\Utilities\ExceptionTypeNameFormatter.Metadata.cs - - - Ecma\CustomAttributeTypeProvider.cs - - - Ecma\EcmaAssembly.cs - - - Ecma\EcmaField.cs - - - Ecma\EcmaGenericParameter.cs - - - Ecma\EcmaMethod.cs - - - Ecma\EcmaModule.cs - - - Ecma\EcmaSignatureParser.cs - - - Ecma\EcmaType.cs - - - Ecma\EcmaType.MethodImpls.cs - - - Ecma\EcmaType.Interfaces.cs - - - Ecma\MetadataExtensions.cs - - - Ecma\IMetadataStringDecoderProvider.cs - - - Ecma\CachingMetadataStringDecoder.cs - - - Ecma\PrimitiveTypeProvider.cs - - - IL\EcmaMethodIL.cs - - - IL\MethodIL.cs - - - IL\MethodILDebugView.cs - - - IL\ILDisassembler.cs - - - IL\InstantiatedMethodIL.cs - - - IL\ILOpcode.cs - - - IL\ILImporter.cs - - - Interop\InstantiatedType.Interop.cs - - - Interop\MetadataType.Interop.cs - - - Interop\MethodDesc.Interop.cs - - - TypeSystem\Interop\MarshalAsDescriptor.cs - - - Utilities\ArrayBuilder.cs - - - TypeSystem\Common\LocalVariableDefinition.cs - - - Common\System\FormattingHelpers.cs - - - TypeSystem\Common\TypeSystemConstraintsHelpers.cs - - - - - CommandLine\CommandLineException.cs - - - CommandLine\CommandLineHelpers.cs - - - System\NotImplemented.cs - - - - - - + + From 7f0e6a6ab91f90e01a923be05add152c37f7aee6 Mon Sep 17 00:00:00 2001 From: Julien Couvreur Date: Wed, 17 Jan 2018 20:34:35 -0800 Subject: [PATCH 2/4] Cleanups --- src/ILVerification/ILVerification.sln | 31 ------------------- src/ILVerification/src/ILVerification.csproj | 1 + .../tests/ILVerification.Tests.csproj | 7 ++--- src/ILVerify/src/ILVerify.csproj | 2 -- 4 files changed, 4 insertions(+), 37 deletions(-) delete mode 100644 src/ILVerification/ILVerification.sln diff --git a/src/ILVerification/ILVerification.sln b/src/ILVerification/ILVerification.sln deleted file mode 100644 index a5b238ba06a..00000000000 --- a/src/ILVerification/ILVerification.sln +++ /dev/null @@ -1,31 +0,0 @@ - -Microsoft Visual Studio Solution File, Format Version 12.00 -# Visual Studio 15 -VisualStudioVersion = 15.0.26510.0 -MinimumVisualStudioVersion = 10.0.40219.1 -Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "ILVerfication", "src\ILVerfication.csproj", "{56AA4730-39A4-4B48-95E9-89E8A29F0A06}" -EndProject -Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "ILVerification.Tests", "tests\ILVerification.Tests.csproj", "{1228E4B6-E5E5-414A-94EC-69B792984FAB}" -EndProject -Global - GlobalSection(SolutionConfigurationPlatforms) = preSolution - Debug|Any CPU = Debug|Any CPU - Release|Any CPU = Release|Any CPU - EndGlobalSection - GlobalSection(ProjectConfigurationPlatforms) = postSolution - {56AA4730-39A4-4B48-95E9-89E8A29F0A06}.Debug|Any CPU.ActiveCfg = Debug|Any CPU - {56AA4730-39A4-4B48-95E9-89E8A29F0A06}.Debug|Any CPU.Build.0 = Debug|Any CPU - {56AA4730-39A4-4B48-95E9-89E8A29F0A06}.Release|Any CPU.ActiveCfg = Release|Any CPU - {56AA4730-39A4-4B48-95E9-89E8A29F0A06}.Release|Any CPU.Build.0 = Release|Any CPU - {1228E4B6-E5E5-414A-94EC-69B792984FAB}.Debug|Any CPU.ActiveCfg = Debug|Any CPU - {1228E4B6-E5E5-414A-94EC-69B792984FAB}.Debug|Any CPU.Build.0 = Debug|Any CPU - {1228E4B6-E5E5-414A-94EC-69B792984FAB}.Release|Any CPU.ActiveCfg = Release|Any CPU - {1228E4B6-E5E5-414A-94EC-69B792984FAB}.Release|Any CPU.Build.0 = Release|Any CPU - EndGlobalSection - GlobalSection(SolutionProperties) = preSolution - HideSolutionNode = FALSE - EndGlobalSection - GlobalSection(ExtensibilityGlobals) = postSolution - SolutionGuid = {3B6C08A7-1F82-4EC0-9CA7-1F07716F36B1} - EndGlobalSection -EndGlobal diff --git a/src/ILVerification/src/ILVerification.csproj b/src/ILVerification/src/ILVerification.csproj index c7a6161a38c..1035652440f 100644 --- a/src/ILVerification/src/ILVerification.csproj +++ b/src/ILVerification/src/ILVerification.csproj @@ -299,5 +299,6 @@ + diff --git a/src/ILVerification/tests/ILVerification.Tests.csproj b/src/ILVerification/tests/ILVerification.Tests.csproj index 4fc70ba336d..ceca7fc932e 100644 --- a/src/ILVerification/tests/ILVerification.Tests.csproj +++ b/src/ILVerification/tests/ILVerification.Tests.csproj @@ -13,16 +13,15 @@ - + - + - - + diff --git a/src/ILVerify/src/ILVerify.csproj b/src/ILVerify/src/ILVerify.csproj index 042fd7946c3..08bf2e12ca0 100644 --- a/src/ILVerify/src/ILVerify.csproj +++ b/src/ILVerify/src/ILVerify.csproj @@ -7,8 +7,6 @@ false true false - - From a3a33b84f917da41cc9f109b82f7b35a25ad36de Mon Sep 17 00:00:00 2001 From: Julien Couvreur Date: Wed, 17 Jan 2018 21:20:05 -0800 Subject: [PATCH 3/4] Fix dirs.proj --- src/dirs.proj | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/dirs.proj b/src/dirs.proj index 2356eef0de5..65f51f4710f 100644 --- a/src/dirs.proj +++ b/src/dirs.proj @@ -7,8 +7,9 @@ + + - From 573ea6257a2f1ffcbf35e9e62a2f13c45ec3017f Mon Sep 17 00:00:00 2001 From: Julien Couvreur Date: Thu, 18 Jan 2018 09:54:05 -0800 Subject: [PATCH 4/4] Use relative links. Removed trailing whitespaces --- src/ILVerify/README.md | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) diff --git a/src/ILVerify/README.md b/src/ILVerify/README.md index b183414a8df..ef4d0d81f6e 100644 --- a/src/ILVerify/README.md +++ b/src/ILVerify/README.md @@ -14,7 +14,7 @@ Historically on Full Framework IL generators used PEVerify to make sure that the - No coupling with CoreLib: ILVerify can point to any assembly and verify it. This also includes the full framework base assemblies (especially mscorlib). - Cross-platform, Open-Source - It should be easy to add new verification rules -- Fast spin up/tear down. +- Fast spin up/tear down. ## The codebase The project targets netcoreapp2.0 and uses the new .csproj based project format. If you want to open and compile it with Visual Studio then you need a version, which supports .NET Core 2.0 tooling. This is supported in Visual Studio 2017 Update 3 (Version 15.3) or later. The other option is to use command (with .NET Core 2.0 tooling). @@ -25,7 +25,7 @@ The code is split into three projects: ## Tests -To test the ILVerification library we have small methods checked in as .il files testing specific verification scenarios. These tests live under [src/ILVerification/tests/ILTests](https://github.com/dotnet/corert/tree/master/src/ILVerification/tests/ILTests). Tests are grouped into .il files based on functionalities they test. There is no strict policy here, the goal is to have a few dozen .il files instead of thousands containing each only a single method. +To test the ILVerification library we have small methods checked in as .il files testing specific verification scenarios. These tests live under [src/ILVerification/tests/ILTests](../ILVerification/tests/ILTests). Tests are grouped into .il files based on functionalities they test. There is no strict policy here, the goal is to have a few dozen .il files instead of thousands containing each only a single method. Currently the IL files are NOT compiled automatically. You have to compile manually (We want to automate this step later): @@ -39,7 +39,7 @@ Note: if you run the tests and get an error similar to this then it means that t Result Message: System.InvalidOperationException : No data found for ILVerify.Tests.ILMethodTester.TestMethodsWithInvalidIL ``` -The test project itself is under [src/ILVerification/tests](https://github.com/dotnet/corert/tree/master/src/ILVerification/tests) +The test project itself is under [src/ILVerification/tests](../ILVerification/tests) Method names in the .il files must follow the following naming convention: @@ -48,9 +48,9 @@ The test project itself is under [src/ILVerification/tests](https://github.com/d ``` [FriendlyName]_Valid ``` -The method must contain 1 '`_`'. +The method must contain 1 '`_`'. - The part before the `_` is a friendly name describing what the method does. - - The word after the `_` must be 'Valid' (Case sensitive) + - The word after the `_` must be 'Valid' (Case sensitive) E.g.: ```SimpleAdd_Valid``` @@ -62,10 +62,10 @@ E.g.: ```SimpleAdd_Valid``` The method name must contain 2 '`_`' characters. 1. part: a friendly name 2. part: must be the word 'Invalid' (Case sensitive) - 3. part: the expected [VerifierErrors](https://github.com/dotnet/corert/blob/master/src/ILVerification/src/VerifierError.cs) as string separated by '.'. We assert on these errors; the test fails if ILVerify does not report these errors. - + 3. part: the expected [VerifierErrors](../ILVerification/src/VerifierError.cs) as string separated by '.'. We assert on these errors; the test fails if ILVerify does not report these errors. + E.g.: ```SimpleAdd_Invalid_ExpectedNumericType``` - + ### Methods with special names: In order to test methods with special names (e.g. '.ctor'), the specialname method is defined as usual and a separate empty method is added to the type: @@ -96,7 +96,7 @@ Currently every IL command falls into one of these categories: - Not implemented: the implementation is completely missing. The easiest way is to pick one of them (look for NotImplentedException in the code) and implement it. First you should 100% understand the spec. (see [ECMA-335](https://www.ecma-international.org/publications/standards/Ecma-335.htm)), then try to port an existing implementation (sources below). - Partially implemented: These are typically methods with TODOs in it. As the first phase we want to make sure that for every command the stack is correctly maintained, therefore for some commands we either have no verification or we have only a not complete verification. You can also pick one of these and finish it. - - Implemented: find and fix bugs ;) . + - Implemented: find and fix bugs ;) . Another option to contribute is to write tests (see Tests section). @@ -104,4 +104,4 @@ Useful sources: - [PEVerify source code](https://github.com/lewischeng-ms/sscli/blob/master/clr/src/jit64/newverify.cpp) - [RyuJIT source code](https://github.com/dotnet/coreclr/blob/master/src/jit), specifically: [exception handling specific part](https://github.com/dotnet/coreclr/blob/master/src/jit/jiteh.cpp), [importer.cpp](https://github.com/dotnet/coreclr/blob/master/src/jit/importer.cpp) (look for `Compiler::ver`, `Verify`, `VerifyOrReturn`, and `VerifyOrReturnSpeculative`), [_typeinfo.h](https://github.com/dotnet/coreclr/blob/master/src/jit/_typeinfo.h), [typeinfo.cpp](https://github.com/dotnet/coreclr/blob/master/src/jit/typeinfo.cpp) - [ECMA-335 standard](https://www.ecma-international.org/publications/standards/Ecma-335.htm) - - [Expert .NET 2.0 IL Assembler book](http://www.apress.com/us/book/9781590596463) by Serge Lidin + - [Expert .NET 2.0 IL Assembler book](http://www.apress.com/us/book/9781590596463) by Serge Lidin