Skip to content
This repository was archived by the owner on Jan 23, 2023. It is now read-only.

Add hack for arm64/x86 to skip build tools restore #20390

Merged
merged 3 commits into from
Oct 17, 2018

Conversation

jashook
Copy link

@jashook jashook commented Oct 12, 2018

Addresses issue caused by #20370. Unfortunately as we do not entirely know when x86 is actually x86 or arm64 easily I have added an environment variable from the parent caller which will skip the build tools restore.

Summary below:

This change basically breaks any x64 build of coreclr in a normal cmd window (ie, one that has its processor architecture set to x86). With it, I get the following error:

@jashook
Copy link
Author

jashook commented Oct 12, 2018

/cc @dotnet/jit-contrib

Copy link

@michellemcdaniel michellemcdaniel left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the quick fix.

I think another issue is that in a developer command prompt, the processor architecture is AMD64 not amd64, because I tried running there, but that isn't your problem.

@BruceForstall
Copy link

Unfortunately as we do not entirely know when x86 is actually x86 or arm64 easily

Not sure what that means. Can't you just use PROCESSOR_ARCHITECTURE? If that's x86 but you really care if you're on an x64 OS (which is virtually every OS these days), you will also have PROCESSOR_ARCHITEW6432=AMD64

@BruceForstall
Copy link

On Windows arm64, you'll see:

Native arm64 cmd:

PROCESSOR_ARCHITECTURE=ARM64

Arm32 cmd (from c:\Windows\SysArm32):

PROCESSOR_ARCHITECTURE=ARM
PROCESSOR_ARCHITEW6432=ARM64

x86 cmd (from C:\Windows\SysWOW64):

PROCESSOR_ARCHITECTURE=x86
PROCESSOR_ARCHITEW6432=ARM64

@jashook jashook closed this Oct 16, 2018
@jashook jashook reopened this Oct 16, 2018
@jashook
Copy link
Author

jashook commented Oct 16, 2018

@dotnet-bot test Windows_NT arm Cross Checked Innerloop Build and Test

@jashook jashook merged commit 683aa87 into dotnet:master Oct 17, 2018
@jashook jashook deleted the unblock_perf_x86_runs branch October 17, 2018 20:50
echesakov added a commit that referenced this pull request Oct 24, 2018
…lix queue

Port (partially) the following changes:

*  Build xunit wrappers the same way on windows and unix (#18695)
*  Update vc-runtime package to support ARM and ARM64 with current builds (#19265)
*  build-test - fix TestWrapper CS warnings (#19180)
*  Clean up build.cmd/build-test.cmd/runtest.cmd (#19291)
*  Use runtest.py to run tests for all platforms (#19213)
*  Updating runtest.py so that it works with Python 3 (#19768)
*  Fix build-test.sh wrapper build (#19779)
*  Move ARM64 Windows boxen to be Helix-provisioned (#20204)
*  Runtest.py on Windows Arm(64) (#20227)
*  Use runtest.cmd for arm(64) windows testing (#20301)
*  Do not restore or initialize buildtools for x86/arm64 (#20370)
*  Add hack for arm64/x86 to skip build tools restore (#20390)

Update Xunit to 2.4.1 prerelease version

Use the latest version (dbf0bf1) of tests/runtest.py
echesakov added a commit that referenced this pull request Oct 24, 2018
…lix queue

Port (partially) the following changes:

*  Build xunit wrappers the same way on windows and unix (#18695)
*  Work around cmd command length limit in xunit Exec task (#19095)
*  Update vc-runtime package to support ARM and ARM64 with current builds (#19265)
*  build-test - fix TestWrapper CS warnings (#19180)
*  Clean up build.cmd/build-test.cmd/runtest.cmd (#19291)
*  Use runtest.py to run tests for all platforms (#19213)
*  Updating runtest.py so that it works with Python 3 (#19768)
*  Fix build-test.sh wrapper build (#19779)
*  Move ARM64 Windows boxen to be Helix-provisioned (#20204)
*  Runtest.py on Windows Arm(64) (#20227)
*  Use runtest.cmd for arm(64) windows testing (#20301)
*  Do not restore or initialize buildtools for x86/arm64 (#20370)
*  Add hack for arm64/x86 to skip build tools restore (#20390)

Update Xunit to 2.4.1 prerelease version

Use the latest version (dbf0bf1) of tests/runtest.py
echesakov added a commit that referenced this pull request Oct 25, 2018
…lix queue

Port (partially) the following changes:

*  Build xunit wrappers the same way on windows and unix (#18695)
*  Work around cmd command length limit in xunit Exec task (#19095)
*  Update vc-runtime package to support ARM and ARM64 with current builds (#19265)
*  build-test - fix TestWrapper CS warnings (#19180)
*  Clean up build.cmd/build-test.cmd/runtest.cmd (#19291)
*  Use runtest.py to run tests for all platforms (#19213)
*  Updating runtest.py so that it works with Python 3 (#19768)
*  Fix build-test.sh wrapper build (#19779)
*  Move ARM64 Windows boxen to be Helix-provisioned (#20204)
*  Runtest.py on Windows Arm(64) (#20227)
*  Use runtest.cmd for arm(64) windows testing (#20301)
*  Do not restore or initialize buildtools for x86/arm64 (#20370)
*  Add hack for arm64/x86 to skip build tools restore (#20390)

Update Xunit to 2.4.1 prerelease version

Use the latest version (dbf0bf1) of tests/runtest.py
echesakov added a commit that referenced this pull request Oct 26, 2018
…lix queue

Port (partially) the following changes:

*  Build xunit wrappers the same way on windows and unix (#18695)
*  Work around cmd command length limit in xunit Exec task (#19095)
*  Update vc-runtime package to support ARM and ARM64 with current builds (#19265)
*  build-test - fix TestWrapper CS warnings (#19180)
*  Clean up build.cmd/build-test.cmd/runtest.cmd (#19291)
*  Use runtest.py to run tests for all platforms (#19213)
*  Updating runtest.py so that it works with Python 3 (#19768)
*  Fix build-test.sh wrapper build (#19779)
*  Move ARM64 Windows boxen to be Helix-provisioned (#20204)
*  Runtest.py on Windows Arm(64) (#20227)
*  Use runtest.cmd for arm(64) windows testing (#20301)
*  Do not restore or initialize buildtools for x86/arm64 (#20370)
*  Add hack for arm64/x86 to skip build tools restore (#20390)

Update Xunit to 2.4.1 prerelease version

Use the latest version (dbf0bf1) of tests/runtest.py
A-And pushed a commit to A-And/coreclr that referenced this pull request Nov 20, 2018
* Add hack for arm64/x86 to skip build tools restore

* Address pr feedback

* Correct PROCESSOR_ARCHITEW6432 comparison
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants