locked
64 bit Compile for web application at Visual Studio Web Developer Express 2005

    Question

  • Hí,

    How can I compile a managed web application at 64 bit. Is there any adjustment or configuration at Visual Studio Express Web Developer Edition or does it directly compile at 64 bit. I need urgent help please

    Best Wishes,
    Thursday, December 08, 2005 12:42 AM

Answers

  • Hmmm, sorry but I'm not running 2003 any more - I can't because .NET 1.1 and 2.0 won't coexist in my experience.

    From memory, VS2003 does not support x64. So your target platform is x86 as usual. Optimise code is a build setting, which you can find in the menu under project settings. Sorry but as you know there's a lot of options. There is a combo box somewhere which lets you select between options like 'No optimisation', 'Optimise for speed', 'Optimise for size'. As I said it's a build setting, sorry but I can't help you without opening the old IDE :-)

     

    I don't think I made myself very clear when I replied to you at work today, I'm sorry. You asked:

    What is the difference of building at 64 bit with visual studio 2005 and running with 64 bit framework 2.0 AND
    building at 32 bit .NET 2003 and running with 64 bit framework 2.0?

    OK as I understand it: no difference.

    Your code compiled by Visual Studio is not targeted at a specific framework - it is 'Pseudo Code'. It will run in 32 or 64 bit mode depending on what the .NET framework installed on the target machine is - .NET compiles your CLR pseudo-code into native code when the app is started. You need to clarify whether you are using .NET 2.0 inside 32-bit Visual Studio 2003, but my understanding is that even .NET 1.1 code will run as 64-bit code if you have 64-bit .NET 2.0 installed. (It worked OK here).

    So: in essence - you can compile your code targeted to 64-bit machines in Visual Studio 2005. I do not know why, because the .NET framework should run the code to suit 32-bit or 64-bit when the application is launched.

    If you are having problems you can target specifically 32-bit machines and the .NET framework will make 32-bit code which works better with the present libraries. I also don't understand what optimising would do in any case.

    Yes, this is confusing. I think it is a matter of time before all the bugs are ironed out and you just don't worry about it.

    I don't know how you do it in 2003, but since I'm sitting in front of it now, here is the way to set the target architecture in 2005:

     

    Menu: Tools -> Options

    Tick 'Show all settings'

    TreeView: Projects and Solutions -> General

    Tick 'Show advanced build configurations'

    Click OK

    Toolbar: ComboBox: 'Any CPU' -> Choose 'New...'

    Create the x86 or x64 target platform

    Toolbar: ComboBox: 'Any CPU' -> Choose x86 or x64.

     

    I seriously hope that someone will correct any of this if it's wrong.  I think I covered everything about 32-bit vs 64-bit in Visual C# Express 2005.

    I hope this will help you. If not can you restate your entire question? Having reread the entire thread, I am no longer sure what you were trying to get going.

    Thursday, December 15, 2005 8:34 AM

All replies

  • The Express Edition doesn't come with a 64-bit compiler. Here is a basic comparision chart from the previous thread http://msdn.microsoft.com/vstudio/products/compare/

    Do you know the answer for my question two thread before?
    Thanks.
    George
    Thursday, December 08, 2005 1:08 AM
  • With any of the Express editions which target .NET, compiling your code will build an image which can run on either 32bit or 64bit.  If there is a 64bit runtime available on the machine where your code is being run (the web-server in your case), then your code will run in 64bit.  If there is not a 64bit runtime installed, then your application will run in 32bit.

    Thanks,
    Luke Hoban
    Visual C# IDE Program Manager

    Friday, December 09, 2005 9:09 PM
  • I have developed the web site with Visual Studio .NET 2003 Frmaework 1.1. I have deployed website on 64 bit Windows 2003 OS, framework 2.0 64 bit. Then I ran the web application directly from browser. Is this mean my application ran in 64 bit mode or 32 bit mode.

    Sorry for my DUMPY,

    What is the difference of building at 64 bit with visual studio 2005 and running with 64 bit framework 2.0 AND
    building at 32 bit .NET 2003 and running with 64 bit framework 2.0?

    If there is no difference,
    then how does the codes compiled at 64 bit? How does the modification of 64 bit code embedded to my web application's code?

    AND final question to make it clear,

    Does it completely mean that, what ever visual studio I have used, if I use 64 bit 2.0 framework, then it means my application works COMPLETELY at 64 bit? And I see the performance(if any) of 64 bit on my application?

    thank you very much,
    Fatih Ucar


    Saturday, December 10, 2005 1:19 AM
  • What I read on MSDN is that the application runs in 64-bit if you have installed .NET2.0 x64 on your machine so in answer to your final question, "Yes". You have Server x64 like me, so I'm guessing that is the case.

    I also saw some interesting performance statistics - the best performance was compiling 32-bit code with 'Optimise Code' enabled and running on a 64-bit machine. Go figure. It is supposed to be faster with 64-bit optimisations running on a 64-bit machine, but that was not the case.

    In short, .NET does make your program work on 64-bit machines as 64-bit code. And remember that the 64-bit architecture is all about addressing more than 4Gb of memory, so there isn't really any performance enhancements to take advantage of unless you count SSE3, which will not help the average coder.

    Thursday, December 15, 2005 1:50 AM
  • Thanks Freqy,

    How will I compile 32 bit code with 'Optimise Code' enable at Visual Studio 2003?

    Thursday, December 15, 2005 3:43 AM
  • Hmmm, sorry but I'm not running 2003 any more - I can't because .NET 1.1 and 2.0 won't coexist in my experience.

    From memory, VS2003 does not support x64. So your target platform is x86 as usual. Optimise code is a build setting, which you can find in the menu under project settings. Sorry but as you know there's a lot of options. There is a combo box somewhere which lets you select between options like 'No optimisation', 'Optimise for speed', 'Optimise for size'. As I said it's a build setting, sorry but I can't help you without opening the old IDE :-)

     

    I don't think I made myself very clear when I replied to you at work today, I'm sorry. You asked:

    What is the difference of building at 64 bit with visual studio 2005 and running with 64 bit framework 2.0 AND
    building at 32 bit .NET 2003 and running with 64 bit framework 2.0?

    OK as I understand it: no difference.

    Your code compiled by Visual Studio is not targeted at a specific framework - it is 'Pseudo Code'. It will run in 32 or 64 bit mode depending on what the .NET framework installed on the target machine is - .NET compiles your CLR pseudo-code into native code when the app is started. You need to clarify whether you are using .NET 2.0 inside 32-bit Visual Studio 2003, but my understanding is that even .NET 1.1 code will run as 64-bit code if you have 64-bit .NET 2.0 installed. (It worked OK here).

    So: in essence - you can compile your code targeted to 64-bit machines in Visual Studio 2005. I do not know why, because the .NET framework should run the code to suit 32-bit or 64-bit when the application is launched.

    If you are having problems you can target specifically 32-bit machines and the .NET framework will make 32-bit code which works better with the present libraries. I also don't understand what optimising would do in any case.

    Yes, this is confusing. I think it is a matter of time before all the bugs are ironed out and you just don't worry about it.

    I don't know how you do it in 2003, but since I'm sitting in front of it now, here is the way to set the target architecture in 2005:

     

    Menu: Tools -> Options

    Tick 'Show all settings'

    TreeView: Projects and Solutions -> General

    Tick 'Show advanced build configurations'

    Click OK

    Toolbar: ComboBox: 'Any CPU' -> Choose 'New...'

    Create the x86 or x64 target platform

    Toolbar: ComboBox: 'Any CPU' -> Choose x86 or x64.

     

    I seriously hope that someone will correct any of this if it's wrong.  I think I covered everything about 32-bit vs 64-bit in Visual C# Express 2005.

    I hope this will help you. If not can you restate your entire question? Having reread the entire thread, I am no longer sure what you were trying to get going.

    Thursday, December 15, 2005 8:34 AM
  • Hi Aron,

    Thanks for your your answers. They are the asnwers what I asked. I was confused about this issue. I want to benefit the performance of 64 bit architecture. I have developed my project using VS 2003 for 11 months then VS 2005 stable version released. Conversion is also very hard and time consuming so I decided not to convert at this time as the project deadline nearly coming.

    Sorry for my final question, If I compile optimised code option at Visual Studio 2003, is the code optimised for 32 bit architecture and run at WOW64 mode. I know project compiled to CLR and 64 bit.NET Framework runtime compiles it 64 bit native code. But optimization may be done to target platform at Visual Studio. Is that the case?

     

    Best Wishes.

    Thursday, December 15, 2005 5:20 PM
  • Well, now I'm just guessing, but I'd say yes, since I saw different performance statistics for the various combinations of optimisation and platform.

    So the code would be optimised for a 32-bit system and would run in emulated 64-bit mode which, assuming you have an Athlon-64, is no slower than running in 64-bit mode. And in fact the statistics I saw (I wish I had the URL sorry) showed that 32-bit optimised code running on a 64-bit platform is the fastest combination.

    Sunday, December 18, 2005 10:18 PM