Asked  6 Months ago    Answers:  5   Viewed   24 times

I have some confusion related to the .NET platform build options in Visual Studio 2008.

What is the "Any CPU" compilation target, and what sort of files does it generate? I examined the output executable of this "Any CPU" build and found that they are the x86 executables (who would not see that coming!). So, is there any difference between targeting executable to x86 vs. "Any CPU"?

Another thing that I noticed, is that managed C++ projects do not have this platform as an option. Why is that? Does that mean that my suspicion about "Any CPU" executables being plain 32-bit ones is right?

 Answers

66

An AnyCPU assembly will JIT to 64-bit code when loaded into a 64-bit process and 32 bit when loaded into a 32-bit process.

By limiting the CPU you would be saying: There is something being used by the assembly (something likely unmanaged) that requires 32 bits or 64 bits.

Tuesday, June 1, 2021
 
Saxophlutist
answered 6 Months ago
28

It likely indicates the app is AnyCpu but when 32 bit is available it shouold run as such. This makes sense - 64 bit apps use more memory, and sometimes you just dont need the memory space ;)

Monday, July 19, 2021
 
dzm
answered 5 Months ago
dzm
22

Seems to be all 64-bit processors has SSE2. Since compiler option always switched on by default no need to switch it on manually.

From Wikipedia:

SSE instructions: The original AMD64 architecture adopted Intel's SSE and SSE2 as core instructions. SSE3 instructions were added in April 2005. SSE2 replaces the x87 instruction set's IEEE 80-bit precision with the choice of either IEEE 32-bit or 64-bit floating-point mathematics. This provides floating-point operations compatible with many other modern CPUs. The SSE and SSE2 instructions have also been extended to operate on the eight new XMM registers. SSE and SSE2 are available in 32-bit mode in modern x86 processors; however, if they're used in 32-bit programs, those programs will only work on systems with processors that have the feature. This is not an issue in 64-bit programs, as all AMD64 processors have SSE and SSE2, so using SSE and SSE2 instructions instead of x87 instructions does not reduce the set of machines on which x64 programs can be run. SSE and SSE2 are generally faster than, and duplicate most of the features of the traditional x87 instructions, MMX, and 3DNow!.

Tuesday, August 10, 2021
 
Saurabh
answered 4 Months ago
82

According to this mailing list thread, that just means you're utilising an optional library and Eclipse can't be sure it's installed on the device. Eclipse knows you're using a compatible version of the API, it's just not sure about the optional extension you're using. So you should be fine, as long as the app works on the phone.

Friday, September 17, 2021
 
Mike Schall
answered 3 Months ago
72

OK folks. The problem was more simple than I at first thought. On the PCs that this did not work as desired I had to turn on the Visual Studio setting (Options->Projects and Solutions->Build and Run) named "Only build startup projects and dependencies on run". This appears to have solved my problem.

Monday, November 15, 2021
 
neon29
answered 2 Weeks ago
Only authorized users can answer the question. Please sign in first, or register a free account.
Not the answer you're looking for? Browse other questions tagged :  
Share