summaryrefslogtreecommitdiff
path: root/build.cmd
AgeCommit message (Collapse)AuthorFilesLines
2017-09-14PGI: Load pgort<ver>.dll from the VS native tools env; do not `install` it ↵Daniel Podder1-0/+25
(#12581) On Windows, PGO instrumented builds (build.cmd release <arch> pgoinstrument) introduce a runtime dependency on pgort<ver>.dll for instrumented binaries. This DLL is distributed alongside the C++ compiler, and is made available via the native tools environment that ships with Visual Studio. Previously, we were using cmake to find and "install" this binary alongside the product when doing an instrumented build, so that the resulting bin\Product drop is free of any added external dependencies. However, this approach is fragile, and despite a best effort to make the implementation work across multiple VS releases, it already broke with VS 2017. To fix support for pgoinstrument on VS 2017, and to harden the implementation for future releases of VS, I'm removing the custom cmake install logic for the pgort DLL. Instead, we fall back to the officially supported method: load the correct (native tools) environment before invoking any command that uses an instrumented binary. This happens in one place in the build today--loading the JIT to crossgen System.Private.CoreLib.dll. Note that there's still an existing CLI/Setup bug that requires copying the pgort DLL. We're now doing it from within build.cmd, which is not nearly as fragile for this as cmake is. The workaround is also isolated, so when the referenced issue is fixed, the workaround (as documented) can simply be removed. Fixes #12347.
2017-08-30Remove -sequential build-flag (#13658)Omair Majid1-2/+0
The flag is not implemented anywhere and is completely ignored. Remove it form various help notices too. Fixes #12035
2017-08-25Scope environment variable settingBruce Forstall1-49/+103
The product and test build scripts invoke Visual Studio environment setting scripts several times during the build process. If doing a full cross architecture build including test build, it's as many as five times. These environment changes are cumulative. For the PATH variable, in particular, they can lead to a failure by exceeding the variable length limit. This seems to have been exacerbated by VS2017, which has very long paths, and for which many things are added to the PATH. Fix this by adding "setlocal" / "endlocal" around various sections of the scripts, so that the multiple calls to the environment script are not cumulative. (There is still some cumulative environment setting, as build.cmd calls VsDevCmd.bat, then if tests are being built, calls build-test.cmd, which also calls VsDevCmd.bat, and then possibly in addition calls vcvarsall.bat.) In addition, I simplified the code that sets up the msbuild logging parameters, so it is more readable, regular, and doesn't have so much repeated text.
2017-08-22Follow-up: Add enforce PGO to official builds (#13437)Victor "Nate" Graf1-4/+2
* Add variables to pipeline to enable enforcepgo for Release * Address review
2017-08-15Use dashes for build options (#13353)Vance Morrison1-22/+64
* Fix IndexOutOfRangeException in PayloadNames property If you pass an null payload using Write<T>, and in the EventListener then call PayloadNames, it will throw an IndexOutOfRangeException. It should just return null. This fixes this. * To be consistant with the other build.cmd files use - for options * Update docs to track change in option convention * Updated Unix script to use - for options. * Fix build break * Fix Whitespace (review feedback) * Another fix
2017-08-11Fix bug where whitespace breaks arg proccessing (#13320)Victor "Nate" Graf1-2/+5
* Fix bug where whitespace breaks arg proccessing * Fix whitespace proccessing bug in buil-text.cmd
2017-08-08Add build-time check to enforce PGO compilation for applicable DLL files ↵Victor "Nate" Graf1-0/+15
(#13258) * Added PGO execution verification script Added a script which can help verify whether or not PGO was used to compile PE files passed to it * Added target to enforce PGO compilation * Remove OS checking for enforcepgo
2017-07-07Revert change that always publish runtime layout (#12679)Yi Zhang (CLR)1-10/+0
2017-07-05Automatic build runtime layout when skipping tests (#12587)Yi Zhang (CLR)1-1/+11
2017-06-29Implement a /verbose flag to show the verbose output from crossgenBrian Sullivan1-0/+1
Added info on /verbose option to PrintUsageHelper() Convert printf(ascii) to wide strings in methodtable.cpp In build.cmd echo the crossgen /CreatePdb command line
2017-06-28Fix usage style.Pat Gavlin1-1/+1
2017-06-28Add a flag to build.{sh,cmd} to disable PGO.Pat Gavlin1-2/+7
This is helpful when performing JIT throughput measurements.
2017-06-07Only restore optdata for release builds (#12136)Daniel Podder1-1/+1
Avoid restoring optdata during a non-release build to minimize work done by build.sh/cmd. Fix #12126
2017-06-06Fix a bad merge for Windows standalone GC build (#12097)Sean Gillespie1-1/+1
2017-06-02Merge pull request #11699 from swgillespie/local-gc-branch-mergeSean Gillespie1-1/+7
Integration from dev/local-gc into master
2017-06-01Fix optdata restore functionality (#11935)Daniel Podder1-15/+14
Fix optdata restore functionality (#11935) Bring back optdata restore functionality following the move to 2.0 BuildTools and csproj-based CLI. Disable a harmless warning that broke the Linux build when consuming PGO counts due to -Werr. Fix #11796 for master
2017-06-01[Local GC] Scaffolding for loading a standalone GC (#11242)Sean Gillespie1-1/+7
* Configure the build system to build a CoreCLR capable of loading a standalone GC * Proto-implementation of dynamic GC loading * Build the GC with the VM's CMakeLists when doing a non-standalone build of the GC * [Local GC] Introduce a new feature define, FEATURE_STANDALONE_GC_ONLY, to be used by the CI to explicitly test local GC dynamic loading code paths * Fix the FEATURE_STANDALONE_GC_ONLY build for unix linkers * Rebase against master * Code review feedback: use the existing Unix exports file
2017-05-31Default to portable build in dev and official builds (#11985)Gaurav Khanna1-6/+1
2017-04-27Remove support for the x86 compat JIT from .NET Core.Pat Gavlin1-16/+1
These changes remove support for the x86 compat JIT from the build, the runtime, and the various perf/test scripts. Fixes #10733, #10734.
2017-04-27[WIP] Enable binding to CoreLib as NI image (#11040)Gaurav Khanna1-3/+3
Enable binding to CoreLib as NI image
2017-04-24Support other toolsets in Win/ARM64 buildRuss Keldorph1-0/+5
2017-04-05Only build compatjit.dll when building JIT32.Pat Gavlin1-3/+7
In order to avoid confusion, do not build and package compatjit.dll unless we are building JIT32. Fixes #10106.
2017-03-22Unify command line arg for portable RID build (#10408)Gaurav Khanna1-1/+1
2017-03-22Enable Portable Windows RID (#10365)Gaurav Khanna1-1/+7
* Enable Portable RID support for Windows and OSX.
2017-03-17Fix build.cmd "all" to work with pass-through args againBruce Forstall1-1/+5
2017-03-16Add IBC support to managed build (#10180)Daniel Podder1-7/+20
Add a new build switch, `ibcinstrument`, that adds `/Tuning` on the `crossgen` command line when building System.Private.CoreLib and its peers. Automatically consume IBC optdata during builds when these conditions are met: 1. `ibcinstrument` is *not* passed to the build, 2. optdata is available 3. ibcmerge is available Note that `optdata` will not yet be restored with this change; once packages for master are made available, a new package reference will still need to be added. This PR attempts to unblock manually testing IBC, as well as surrounding CI/infrastructure work. To help produce an IBC-optimized build using manually generated profile data, run the newly added `tests/scripts/optdata/bootstrap.py` script. It will configure the build to consume IBC data from a path automatically, and print out that path where profile data can be copied.
2017-03-16Delete mscorlib facade (#10157)Jan Kotas1-15/+0
Fixes #7607
2017-03-08Merge pull request #9956 from tannergooding/vs2017Tanner Gooding1-8/+30
Updating the build scripts to support VS2017.
2017-03-08Stop building x86 LEGACY_BACKENDBruce Forstall1-13/+0
Since we require a compatjit.dll to be built so the JIT NuGet package can be built, even if JIT32 isn't being built, change the compatjit.dll build (when JIT32 isn't being built) to just a normal JIT build.
2017-03-07Port Windows PGO support to master (#9985)Daniel Podder1-2/+33
The bulk of this PR is a cherry-pick of commit fa02660 that shipped in release/1.1.0, updating the build system support for PGO to support consuming PGDs properly during release builds on Windows. Also included are the following new changes: * Skip restore of opdata if the requisite project.json is missing * If the optdata package restore fails, fail the build. * Add new build option: 'skiprestoreoptdata' Note: This change doesn't by itself enable PGO in master yet, because training data (optdata packages) for master don't exist on myget yet. However, with these changes, the only step remaining to enable PGO optimizations is to add a project.json referencing the correct optdata package.
2017-03-07Updating the various windows build scripts to have a comment explaining the ↵Tanner Gooding1-0/+14
VS version selection logic.
2017-03-06Updating the build scripts to support VS2017.Tanner Gooding1-8/+16
2017-02-21Have Crossgen Failures exit in a dedicated exit routinewtgodbe1-3/+6
2017-02-07Remove bclrewriter (#9351)Dan Moseley1-4/+7
* Remove bclrewriter * Dump crossgen error to Jenkins log
2017-01-23[Local GC] Provide an implementation of GCToOSInterface for Unix-like ↵Sean Gillespie1-0/+1
platforms (#8976) * Add way to build with FEATURE_STANDALONE_GC from build.sh * Make CMake changes to build the GC 'PAL' as its own build target (to avoid -nostdinc). In addition, introduce a "GC PAL" that provides an implementation of GCToOSInterface on Unix-like platforms, for use with FEATURE_STANDALONE_GC.
2016-12-17Use ExecutionPolicy ByPass to execute probe-win.ps1 script during the build ↵Jan Kotas1-1/+1
(#8673) Port of https://github.com/dotnet/corert/issues/2377
2016-11-23Make RyuJIT/x86 the default x86 JITBruce Forstall1-5/+19
JIT32 becomes compatjit.dll and RyuJIT LEGACY_BACKEND becomes legacyjit.dll (and is an altjit). If JIT32 is not being built, then RyuJIT LEGACY_BACKEND becomes compatjit.dll and is a normal jit (not an altjit). Both clrjit.dll and compatjit.dll are added to the JIT NuGet package.
2016-11-18Add CI job and build.cmd command for building with FEATURE_STANDALONE_GC (#8183)Sean Gillespie1-1/+3
* Add CI job and build.cmd command for building with FEATURE_STANDALONE_GC * Add missed case * Correct a condition * Accidental fallthrough in switch * Only run on x64
2016-11-07Use the alt JIT for S.P.CoreLib if altjitcrossgen is specified.Pat Gavlin1-6/+6
The check for altjitcrossgen was previously located s.t. only mscorlib was being crossgen'd using the alt JIT (which is not very insteresting, as mscorlib is just a facade these days). This change moves the check back s.t. the alt JIT is also used for System.Private.CoreLib.
2016-10-15Few more fixes for WinArm32 CI build.Gaurav Khanna1-2/+2
2016-10-14Explicitly specify the Windows SDK version for CMake.Gaurav Khanna1-2/+9
2016-10-13Added Docs for Using Visual Studio to Edit and Debug in CoreCLR Repo (#7582)Vance Morrison1-1/+2
2016-10-07Standardize on _echo name (#7532)Vance Morrison1-5/+5
2016-10-04Merge pull request #7481 from pgavlin/RyuJITCrossgenPat Gavlin1-1/+15
Add an option to crossgen S.P.CoreLib using the alt jit.
2016-10-04Add an option to crossgen S.P.CoreLib using the alt jit.Pat Gavlin1-1/+15
This also changes the x86/RyuJIT CI job to pass this option to build.cmd. This leg will now use RyuJIT when crossgen'ing S.P.CoreLib and when running tests.
2016-10-04Add PGO GENPROFILE support to coreclr and clrjit (#7423)Daniel Podder1-2/+7
* Add PGO GENPROFILE support to coreclr and clrjit Update the cmake build system to enable support for Profile Guided Optimization (PGO) on Windows, and enable this feature for two target binaries (coreclr and clrjit). With this change, toggle between instrumented and profile-optimized settings for target binaries by passing pgoinstrument argument to the build.cmd Assume profile-optimized mode by default. Fall back to regular non-PGO optimized builds if profile data is not available.
2016-09-22Generate CrossGen Pdbs as part of bulid (#7298)Vance Morrison1-1/+17
This change has two parts. The first part changes build.cmd and the pkgproj so that as part of generating a .NET Core package we also generate the PDBS for the Native System.Private.Corelib.ni.dll. The second part changes crossgen so that it marks the Native Images as having a list of 0 exports. This is important because we want the generated PDBs to be naturally published on the symbol server, and currently the symbol server skips DLLs what are 'resource only' (no imports or exports). Because native images don't use 'normal' PE imports and exports, they get optimized away by the symbol server. Making a empy list of exports fixes this.
2016-08-24Merge pull request #6883 from gkhanna79/WinArm32Gaurav Khanna1-4/+14
Enable Windows Arm32 build
2016-08-24Update build to optionally configure with nmakeMichelle McDaniel1-0/+2
For formatting, we want to be able to obtain the compile_commands.json file so that we do not have to 1) do a full build of coreclr and 2) generate it ourselves from the build log. This change modifies build.cmd to take an option "usenmakemakefiles." This option will set __NMakeMakefiles to 1, which is used by the gen-buildsys-win.bat script. This option also sets all the same options as configureonly, as we cannot do a full build using NMake Makefiles, and we only want to use this to force CMake to generate a compile_commands.json file for the jit directory, which it can do using NMake Makefiles, but not Visual Studio. The update to gen-buildsys-win.bat checks the value of __NMakeMakefiles, and if it is set to 1, it sets the CMake Generator to NMake Makefiles.
2016-08-23Initial commit to build Win32 Arm CoreCLRGaurav Khanna1-4/+14