Thread: my method to optimize application startup performance

  1. #16
    Deathray Engineer MacGyver's Avatar
    Join Date
    Mar 2007
    Posts
    3,210
    Quote Originally Posted by brewbuck View Post
    So, you want to skip all that "useless" initialization of the environment and standard library and go straight to main(). Okay chief. Yeah. You're optimizing now.
    lol.

    Skipping any under-the-hood initialization of the program before main() is actually called without knowing what you're doing is a bad idea.

  2. #17
    Officially An Architect brewbuck's Avatar
    Join Date
    Mar 2007
    Location
    Portland, OR
    Posts
    7,396
    Quote Originally Posted by MacGyver View Post
    lol.

    Skipping any under-the-hood initialization of the program before main() is actually called without knowing what you're doing is a bad idea.
    I doubt much of anything would work correctly. argc and argv probably won't be right. Attempting to access them will probably crash. Calling malloc() will probably crash. Calling printf() will probably crash. Just returning from main() will probably crash.

  3. #18
    Deathray Engineer MacGyver's Avatar
    Join Date
    Mar 2007
    Posts
    3,210
    Might be fun to mess with and find out exactly what happens and how to optimize the process, but whatever you find out would probably be operating system specific and then compiler specific on top of that, so perhaps it's not worth the effort.

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Application fails to load settings only at windows startup
    By DanFraser in forum C# Programming
    Replies: 3
    Last Post: 09-27-2009, 11:15 AM
  2. Optimize file writing
    By Opariti in forum Windows Programming
    Replies: 7
    Last Post: 10-23-2008, 01:32 PM
  3. Application.Exit
    By George2 in forum C# Programming
    Replies: 8
    Last Post: 05-02-2008, 02:24 AM
  4. Speed of C++
    By bobthebullet990 in forum A Brief History of Cprogramming.com
    Replies: 64
    Last Post: 01-12-2007, 02:39 AM
  5. Startup using STARTUP folder method for winXP & win98
    By hanhao in forum Windows Programming
    Replies: 2
    Last Post: 05-26-2005, 04:59 AM