PC Review


Reply
Thread Tools Rate Thread

Compilar options or ngen.exe?

 
 
Ramon Guerrero
Guest
Posts: n/a
 
      20th Dec 2003
One thing that bugs me is whether to use the ngen tool or
to compile the code to run under certain processors,
using the compiler options G5, G6, ect...? Say i
deployed an app to a user running a pentium 4 on his
computer. I know that the ngen tool is used for start
up, but which would cause the app to start up faster,
ngen or the compilar options? Thanks!!
 
Reply With Quote
 
 
 
 
Miha Markic
Guest
Posts: n/a
 
      23rd Dec 2003
Hi Ramon,

I don't think that Gx options have any effect on managed code (I assume you
are talking about managed code) since it is compiled always to MSIL.
Thus NGEN on target machine is the only way to speed up managed code.

--
Miha Markic - RightHand .NET consulting & software development
miha at rthand com
www.rthand.com

"Ramon Guerrero" <(E-Mail Removed)> wrote in message
news:07ff01c3c6a9$91422630$(E-Mail Removed)...
> One thing that bugs me is whether to use the ngen tool or
> to compile the code to run under certain processors,
> using the compiler options G5, G6, ect...? Say i
> deployed an app to a user running a pentium 4 on his
> computer. I know that the ngen tool is used for start
> up, but which would cause the app to start up faster,
> ngen or the compilar options? Thanks!!



 
Reply With Quote
 
Ramon Guerrero
Guest
Posts: n/a
 
      24th Dec 2003

>-----Original Message-----
>Hi Ramon,
>
>I don't think that Gx options have any effect on managed

code (I assume you
>are talking about managed code) since it is compiled

always to MSIL.
>Thus NGEN on target machine is the only way to speed up

managed code.
>
>--
>Miha Markic - RightHand .NET consulting & software

development
>miha at rthand com
>www.rthand.com
>
>"Ramon Guerrero" <(E-Mail Removed)> wrote in

message
>news:07ff01c3c6a9$91422630$(E-Mail Removed)...
>> One thing that bugs me is whether to use the ngen tool

or
>> to compile the code to run under certain processors,
>> using the compiler options G5, G6, ect...? Say i
>> deployed an app to a user running a pentium 4 on his
>> computer. I know that the ngen tool is used for start
>> up, but which would cause the app to start up faster,
>> ngen or the compilar options? Thanks!!

>
>
>.
>

Are you sure the Gx options have nothing to do with
managed code, because the default compilation option is
O2 (or O3 i can't rem). With that option set, it
combines many of the other options into one, which is the
default release build. You could either use this default
or custom make your own.
 
Reply With Quote
 
Miha Markic
Guest
Posts: n/a
 
      24th Dec 2003

> Are you sure the Gx options have nothing to do with
> managed code, because the default compilation option is
> O2 (or O3 i can't rem). With that option set, it
> combines many of the other options into one, which is the
> default release build. You could either use this default
> or custom make your own.


I am pretty sure that there is no point optimizing MSIL for a processor (I
don't have much experience with C++ optimitzations though) as this is the
work for ngen or jit.
However, you might try different optimizing options and see if they make a
difference in msil.

--
Miha Markic - RightHand .NET consulting & software development
miha at rthand com
www.rthand.com


 
Reply With Quote
 
Willy Denoyette [MVP]
Guest
Posts: n/a
 
      24th Dec 2003
The compiler options you are talking about is for VC++ native mode only,
managed code compilers have no such optimization flags as they produce MSIL
code that get's optimized by the JIT compiler.

Willy.

"Ramon Guerrero" <(E-Mail Removed)> wrote in message
news:064101c3c9f8$117b46f0$(E-Mail Removed)...
>
> >-----Original Message-----
> >Hi Ramon,
> >
> >I don't think that Gx options have any effect on managed

> code (I assume you
> >are talking about managed code) since it is compiled

> always to MSIL.
> >Thus NGEN on target machine is the only way to speed up

> managed code.
> >
> >--
> >Miha Markic - RightHand .NET consulting & software

> development
> >miha at rthand com
> >www.rthand.com
> >
> >"Ramon Guerrero" <(E-Mail Removed)> wrote in

> message
> >news:07ff01c3c6a9$91422630$(E-Mail Removed)...
> >> One thing that bugs me is whether to use the ngen tool

> or
> >> to compile the code to run under certain processors,
> >> using the compiler options G5, G6, ect...? Say i
> >> deployed an app to a user running a pentium 4 on his
> >> computer. I know that the ngen tool is used for start
> >> up, but which would cause the app to start up faster,
> >> ngen or the compilar options? Thanks!!

> >
> >
> >.
> >

> Are you sure the Gx options have nothing to do with
> managed code, because the default compilation option is
> O2 (or O3 i can't rem). With that option set, it
> combines many of the other options into one, which is the
> default release build. You could either use this default
> or custom make your own.



 
Reply With Quote
 
Ramon Guerrero
Guest
Posts: n/a
 
      24th Dec 2003

>-----Original Message-----
>The compiler options you are talking about is for VC++

native mode only,
>managed code compilers have no such optimization flags

as they produce MSIL
>code that get's optimized by the JIT compiler.
>
>Willy.
>
>"Ramon Guerrero" <(E-Mail Removed)> wrote in

message
>news:064101c3c9f8$117b46f0$(E-Mail Removed)...
>>
>> >-----Original Message-----
>> >Hi Ramon,
>> >
>> >I don't think that Gx options have any effect on

managed
>> code (I assume you
>> >are talking about managed code) since it is compiled

>> always to MSIL.
>> >Thus NGEN on target machine is the only way to speed

up
>> managed code.
>> >
>> >--
>> >Miha Markic - RightHand .NET consulting & software

>> development
>> >miha at rthand com
>> >www.rthand.com
>> >
>> >"Ramon Guerrero" <(E-Mail Removed)> wrote in

>> message
>> >news:07ff01c3c6a9$91422630$(E-Mail Removed)...
>> >> One thing that bugs me is whether to use the ngen

tool
>> or
>> >> to compile the code to run under certain processors,
>> >> using the compiler options G5, G6, ect...? Say i
>> >> deployed an app to a user running a pentium 4 on his
>> >> computer. I know that the ngen tool is used for

start
>> >> up, but which would cause the app to start up

faster,
>> >> ngen or the compilar options? Thanks!!
>> >
>> >
>> >.
>> >

>> Are you sure the Gx options have nothing to do with
>> managed code, because the default compilation option is
>> O2 (or O3 i can't rem). With that option set, it
>> combines many of the other options into one, which is

the
>> default release build. You could either use this

default
>> or custom make your own.

>
>
>.
>

Ok i understand. I thought the options affected managed
code too. Yeah I am a straight VC++ freak, sorry for not
mentioning that. I figured the options for VC++ were the
same with C# because of the managed extension tacked on
to VC++. I thought those were .NET features. Thanks a
lot for your help Miha and Willy!! Ramon
 
Reply With Quote
 
 
 
Reply

Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
ngen.exe Samuel Microsoft VB .NET 5 19th Mar 2007 02:25 AM
NGEN.exe =?Utf-8?B?QWxlYw==?= Windows Vista Performance 0 31st Jul 2006 02:35 AM
NGen Use in NTD? localhost Microsoft Dot NET Framework Forms 5 5th Feb 2004 08:35 PM
Serious bug in ngen.exe =?Utf-8?B?VmxhZA==?= Microsoft Dot NET 0 30th Jan 2004 02:21 PM
Re: nGen Frans Bouma Microsoft ADO .NET 2 21st Aug 2003 07:48 PM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 03:07 PM.