Will console programs still work in WinXP x64?

This is a discussion on Will console programs still work in WinXP x64? within the C++ Programming forums, part of the General Programming Boards category; I heard it doesn't support DOS anymore. Will this mean that all console programs will stop functioning, eg those cout<<"hello ...

  1. #1
    Registered User
    Join Date
    Nov 2002
    Posts
    43

    Will console programs still work in WinXP x64?

    I heard it doesn't support DOS anymore. Will this mean that all console programs will stop functioning, eg those cout<<"hello world" stuff?

  2. #2
    essence of digital xddxogm3's Avatar
    Join Date
    Sep 2003
    Posts
    589
    if i remember correctly xp 32 doesn't support dos.
    i thought dos was eliminated from the system as of the converstion from win 98 to xp.
    the command line prompt is still available in xp 32.
    i have not heard anything about it not being offered in the 64 version.
    [edit1]
    i just confirmed from msdn.com that the command line is still included in the 64 bit windows.
    here is the link
    http://www.microsoft.com/resources/d...en-us/mmc.mspx

    i just talks about using the command line in the 64 bit windows.
    [\edit1]
    Last edited by xviddivxoggmp3; 04-23-2005 at 11:53 PM.
    "Hence to fight and conquer in all your battles is not supreme excellence;
    supreme excellence consists in breaking the enemy's resistance without fighting."
    Art of War Sun Tzu

  3. #3
    Registered User
    Join Date
    Nov 2002
    Posts
    43
    So my console-type programs will still work in XP x64? I'm too lazy to master the Win32 API yet.

  4. #4
    Devil's Advocate SlyMaelstrom's Avatar
    Join Date
    May 2004
    Location
    Out of scope
    Posts
    4,074
    Yes they will.
    Sent from my iPadŽ

  5. #5
    Registered User
    Join Date
    Nov 2002
    Posts
    43
    Will performance be greatly hit? Because the program I am writing is a benchmark program

  6. #6
    Registered User
    Join Date
    Jan 2005
    Posts
    847
    A WIN32 console program isn't a DOS program. The differences between a WIN32 console program and a WIN32 GUI program is a linker switch which tells the linker to look for a main() or WinMain() function and sets a flag in the exe to tell the OS weather or not to allocate a console for the program.
    I think exe files compiled for 32 bit windows would probably be run inside an emulator on 64 bit windows. The API is probably the same so you could recompile for 64 bit windows.

  7. #7
    Registered User
    Join Date
    Nov 2002
    Posts
    43
    Mm ok, so it's a 32-bit program?

  8. #8
    Registered User
    Join Date
    Jan 2005
    Posts
    847
    Yes, as long as your not using an old 16 bit compiler you will be creating a 32 bit program.

  9. #9
    Cat without Hat CornedBee's Avatar
    Join Date
    Apr 2003
    Posts
    8,893
    Your programs will not work, however, as native 64-bit programs if you make the wrong assumptions. For example, quite a few programs nowadays assume that they can cast a pointer to an int and back without bad things happening. On 64-bit, that's not possible.
    Also, assumptions about the length of datatypes are bad. On 64-bit, the length of long will depend on the compiler: VC++ will make it 32 bits, gcc makes it 64 bits.
    All the buzzt!
    CornedBee

    "There is not now, nor has there ever been, nor will there ever be, any programming language in which it is the least bit difficult to write bad code."
    - Flon's Law

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. help on console programs needed
    By thrice in forum C++ Programming
    Replies: 2
    Last Post: 07-26-2003, 05:32 PM
  2. POSIX/DOS programs?
    By nickname_changed in forum C++ Programming
    Replies: 1
    Last Post: 02-28-2003, 04:42 AM
  3. fopen();
    By GanglyLamb in forum C Programming
    Replies: 8
    Last Post: 11-03-2002, 11:39 AM
  4. Just one Question?
    By Irish-Slasher in forum C++ Programming
    Replies: 6
    Last Post: 02-12-2002, 09:19 AM
  5. Console Buffers, Why doesnt this work ?
    By richardnuk in forum C++ Programming
    Replies: 2
    Last Post: 02-01-2002, 03:24 PM

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21