tags:

views:

142

answers:

1

How can you determine whether a particular .Net assembly has already been ngen'd or not? I need to check from code. Even invoking the command-line would be fine. At the moment I can't see any way of determining this.

A: 

You can try to find your assembly in "ngen cash" (C:\Windows\assembly\NativeImages_v2XXXXXXX). Сashed assemblies have the following format name: [basename].ni.[baseextension].

Sasha
Windows 7 seems to store them is a slightly different location, and with no '.ni.' in the name: C:\Windows\assembly
Gareth
Very strange. I have Windows 7 installed, and "ngen cash" path is "C:\Windows\assembly\NativeImages_v2.0.50727_32\".
Sasha