I have two assemblies, A.dll and B.dll.
A.dll contains two methods. One method, UsesB, uses a type from B.dll
whereas the other, DoesNotUseB, does not.
To cache a native image of A.dll with both methods precompiled, I believe I
can do
ngen A.dll B.dll
I think I could also do
ngen B.dll
ngen A.dll
Will just
ngen A.dll
also produce a native image of A.dll with both methods precompiled, or will
it precompile only the method that does *not* use types from B.dll? (or will
it precompile neither?)
In other words, does
ngen A.dll
resolve B.dll and use the metadata in B.dll to work out the physical layout
of the types in B.dll so that it can generate native code for A.UsesB(), or
does it need B.dll to be in the native image cache already, or do I actually
have to supply both dlls to ngen at the same time, ie
ngen A.dll B.dll
TIA 2 2736
"ngen A.dll" is not the same as "ngen A.dll B.dll". The latter will
pre-compile both assemblies.
"ngen A.dll" will load B automatically (through the normal assembly probing
logic), and compile both methods.
To prove it, run "ntsd ngen A.dll", you will see b.dll in the loaded module
list, assuming b.dll can be found by ngen.
"Wol" <mr***@hotmail. com> wrote in message
news:O8******** ******@TK2MSFTN GP10.phx.gbl... I have two assemblies, A.dll and B.dll.
A.dll contains two methods. One method, UsesB, uses a type from B.dll whereas the other, DoesNotUseB, does not.
To cache a native image of A.dll with both methods precompiled, I believe
I can do
ngen A.dll B.dll
I think I could also do
ngen B.dll ngen A.dll Will just
ngen A.dll
also produce a native image of A.dll with both methods precompiled, or
will it precompile only the method that does *not* use types from B.dll? (or
will it precompile neither?)
In other words, does
ngen A.dll
resolve B.dll and use the metadata in B.dll to work out the physical
layout of the types in B.dll so that it can generate native code for A.UsesB(),
or does it need B.dll to be in the native image cache already, or do I
actually have to supply both dlls to ngen at the same time, ie
ngen A.dll B.dll
TIA
The ngen image of A will use indirections (similar to IATs in the unmanaged
world) to access data from B.dll. (In the next version, these indirections
can be removed).
We will resolve the physical layout of types in B. So if B.dll changes, you
need to re-ngen A.dll as the old ngen image is/may be invalid and will not
be used anymore.
"Wol" <mr***@hotmail. com> wrote in message
news:O8******** ******@TK2MSFTN GP10.phx.gbl... I have two assemblies, A.dll and B.dll.
A.dll contains two methods. One method, UsesB, uses a type from B.dll whereas the other, DoesNotUseB, does not.
To cache a native image of A.dll with both methods precompiled, I believe
I can do
ngen A.dll B.dll
I think I could also do
ngen B.dll ngen A.dll Will just
ngen A.dll
also produce a native image of A.dll with both methods precompiled, or
will it precompile only the method that does *not* use types from B.dll? (or
will it precompile neither?)
In other words, does
ngen A.dll
resolve B.dll and use the metadata in B.dll to work out the physical
layout of the types in B.dll so that it can generate native code for A.UsesB(),
or does it need B.dll to be in the native image cache already, or do I
actually have to supply both dlls to ngen at the same time, ie
ngen A.dll B.dll
TIA
This thread has been closed and replies have been disabled. Please start a new discussion. Similar topics |
by: Doug Holland |
last post by:
Hi There
If you have a .NET based application installed and you'd like to increase
the start-up performance of that application; can you NGen assemblies once
the application is installed?
The application in question is quite a complex one and I doubt this will be
a simple task.
Thereafter it is likely that the publishers of the application will want to
|
by: Will |
last post by:
Hi All,
* I have 2 dev machines, one is running WinXP Pro and one is running
Win2K Server. Each has Visual Studio .NET 7.0 installed (the .NET 1.0
dev tools.)
* I have a .NET .dll (let's call it a.dll) which I can run NGEN on,
giving me the native image, (let's call it a_native.dll.)
* Using the same version of NGEN and the same a.dll, I create
a_native.dll on both of these dev boxes.
* I do a binary diff on the 2 a_native.dll files...
|
by: Laurence |
last post by:
So I had an 1D10T moment today: ran ngen /delete * and then compounded my error by closing the window. Of course now my window code starts far slower, but I don't want to blindly precompile assemblies because from what I know that might just as well slow things down as speed them up. Could someone out there run ngen /show for me and post a list of the standard precompiled assemblies so I know which ones to re-precompile? NGen is typically in...
|
by: JMMB |
last post by:
Just a confirmation.
NGen generates native code when i install the windows application on the
client or when I run it for the first time?
thanks,
|
by: Mark |
last post by:
I was hoping to use nGen to speed up the time taken for our web site to
start running. However, on the web we found this quote:
"NGen is not recommend for Asp.Net because the assemblies NGen produces
cannot be shared between App Domains"
I'm afraid I'm not sure what an App Domain is in this context, but we don't
have a web farm/web garden. It's a single web site running on IIS 6. We do
not use the GAC for any of our assemblies.
| |
by: Wol |
last post by:
I have two assemblies, A.dll and B.dll.
A.dll contains two methods. One method, UsesB, uses a type from B.dll
whereas the other, DoesNotUseB, does not.
To cache a native image of A.dll with both methods precompiled, I believe I
can do
ngen A.dll B.dll
|
by: musosdev |
last post by:
Hi guys
I've just read the article in this months MSDN about using Ngen to speed up
initial load times and I thought "great, I can speed up initial load of my
web app!".
However, having just read the conversation between Steven Cheng and MLibby
on this group (search for "ngen" to find it) - I'm thinking my plan is
scuppered. Then again, that's 2004.
|
by: Vince |
last post by:
My current project (a desktop application that’s currently developed on .net
v1.1) call for
1) Use ngen.exe to improve the startup speed.
2) Use multiple AppDomain to reduce the memory requirement. The idea is some
of the modules in the application are quite large and users could be working
on multiple modules during a single application session. We would like to
unload the modules they are finished. Each module will be loaded in a...
|
by: mcintyre321 |
last post by:
Hi all,
I am looking into NGen.exe to solve a problem. At my firm, when we upload new code to the live servers they take an age to start up. I've heard that NGen can speed this time by be JITing the IL assemblies. However it seems that NGen is run on a per machine basis, so I would still have to run it after copying it across. is it possible to copy NGen'd assemblies between machines so you don't need to NGen again?
cheers
|
by: marktang |
last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look !
Part I. Meaning of...
|
by: Hystou |
last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it.
First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
| |
by: Hystou |
last post by:
Overview:
Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
|
by: tracyyun |
last post by:
Dear forum friends,
With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
|
by: TSSRALBI |
last post by:
Hello
I'm a network technician in training and I need your help.
I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs.
The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols.
I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
|
by: adsilva |
last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
|
by: 6302768590 |
last post by:
Hai team
i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
|
by: muto222 |
last post by:
How can i add a mobile payment intergratation into php mysql website.
| |
by: bsmnconsultancy |
last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...
| |