Assembly.LoadFrom and machine restart - DOTNET
This is a discussion on Assembly.LoadFrom and machine restart - DOTNET ; Dear All,
I have developed a client .net application that gets launched via
No Touch Deployment...using the Assembly.LoadForm method...I have a
dll xrt.dll for which I have not maintained versioning...
When I launch my application after a machine reboot (xrt.dll ...
-
Assembly.LoadFrom and machine restart
Dear All,
I have developed a client .net application that gets launched via
No Touch Deployment...using the Assembly.LoadForm method...I have a
dll xrt.dll for which I have not maintained versioning...
When I launch my application after a machine reboot (xrt.dll already
present on client machine) it takes 2 seconds to load this dll...I
assume this is because I have not maintained versioning of this dll
and hence it downloads this dll again...but if I close my application
and start it again, this dll gets loaded in 300ms seconds...how come
it is fast the second time? My guess is it should have still taken 2
seconds...can someone explain wot is MS doing here...
I swear the following...:-)
1. xrt.dll was not changed in the server.
2. xrt.dll was already present on the client machine. (I ran the
application once and then restarted my client machine).
Please help...I want to enjoy my X'Mas...:-)
TALIA
Many Regards
Jack
-
Re: Assembly.LoadFrom and machine restart
The first time the dll is run on the machine the JIT Compiler compiles the
dll. The second time your run it, it is already compiled; it looks to see
that a new version doesn't exist first. Whenever you restart the dll have to
be recompiled. There is a way to "pre-compile" the .net dll on that
machine, but I don't remember the name of the exe to do it.
Chris
"Jack Wright" <sunil@volcanomail.com> wrote in message
news:8f556eeb.0412230613.340f564b@posting.google.com...
> Dear All,
> I have developed a client .net application that gets launched via
> No Touch Deployment...using the Assembly.LoadForm method...I have a
> dll xrt.dll for which I have not maintained versioning...
> When I launch my application after a machine reboot (xrt.dll already
> present on client machine) it takes 2 seconds to load this dll...I
> assume this is because I have not maintained versioning of this dll
> and hence it downloads this dll again...but if I close my application
> and start it again, this dll gets loaded in 300ms seconds...how come
> it is fast the second time? My guess is it should have still taken 2
> seconds...can someone explain wot is MS doing here...
> I swear the following...:-)
> 1. xrt.dll was not changed in the server.
> 2. xrt.dll was already present on the client machine. (I ran the
> application once and then restarted my client machine).
>
> Please help...I want to enjoy my X'Mas...:-)
>
> TALIA
> Many Regards
> Jack
-
Re: Assembly.LoadFrom and machine restart
ngen to "pre-compile"
Michael
"Chris, Master of All Things Insignificant" <chris@No_Spam_Please.com> wrote
in message news:OJry5hS6EHA.2624@TK2MSFTNGP11.phx.gbl...
> The first time the dll is run on the machine the JIT Compiler compiles the
> dll. The second time your run it, it is already compiled; it looks to see
> that a new version doesn't exist first. Whenever you restart the dll have
to
> be recompiled. There is a way to "pre-compile" the .net dll on that
> machine, but I don't remember the name of the exe to do it.
>
> Chris
>
> "Jack Wright" <sunil@volcanomail.com> wrote in message
> news:8f556eeb.0412230613.340f564b@posting.google.com...
> > Dear All,
> > I have developed a client .net application that gets launched via
> > No Touch Deployment...using the Assembly.LoadForm method...I have a
> > dll xrt.dll for which I have not maintained versioning...
> > When I launch my application after a machine reboot (xrt.dll already
> > present on client machine) it takes 2 seconds to load this dll...I
> > assume this is because I have not maintained versioning of this dll
> > and hence it downloads this dll again...but if I close my application
> > and start it again, this dll gets loaded in 300ms seconds...how come
> > it is fast the second time? My guess is it should have still taken 2
> > seconds...can someone explain wot is MS doing here...
> > I swear the following...:-)
> > 1. xrt.dll was not changed in the server.
> > 2. xrt.dll was already present on the client machine. (I ran the
> > application once and then restarted my client machine).
> >
> > Please help...I want to enjoy my X'Mas...:-)
> >
> > TALIA
> > Many Regards
> > Jack
>
>
-
Re: Assembly.LoadFrom and machine restart
Hello
Most probably your assembly is cached in memory by windows the first time,
and in the later runs, it is loaded from memory. You can try this any
application (Outlook for example) and watch the hard disk led if first and
second run, you will notice a difference.
Best regards,
Sherif
"Jack Wright" <sunil@volcanomail.com> wrote in message
news:8f556eeb.0412230613.340f564b@posting.google.com...
> Dear All,
> I have developed a client .net application that gets launched via
> No Touch Deployment...using the Assembly.LoadForm method...I have a
> dll xrt.dll for which I have not maintained versioning...
> When I launch my application after a machine reboot (xrt.dll already
> present on client machine) it takes 2 seconds to load this dll...I
> assume this is because I have not maintained versioning of this dll
> and hence it downloads this dll again...but if I close my application
> and start it again, this dll gets loaded in 300ms seconds...how come
> it is fast the second time? My guess is it should have still taken 2
> seconds...can someone explain wot is MS doing here...
> I swear the following...:-)
> 1. xrt.dll was not changed in the server.
> 2. xrt.dll was already present on the client machine. (I ran the
> application once and then restarted my client machine).
>
> Please help...I want to enjoy my X'Mas...:-)
>
> TALIA
> Many Regards
> Jack
Similar Threads
-
By Application Development in forum DOTNET
Replies: 0
Last Post: 05-16-2007, 09:28 AM
-
By Application Development in forum DOTNET
Replies: 0
Last Post: 09-13-2006, 09:25 AM
-
By Application Development in forum DOTNET
Replies: 2
Last Post: 12-05-2005, 09:08 PM
-
By Application Development in forum DOTNET
Replies: 5
Last Post: 03-07-2005, 08:34 PM
-
By Application Development in forum DOTNET
Replies: 0
Last Post: 02-22-2004, 07:20 AM