人生是一场不能存盘的RPG,我只能尽量多搞几个Screenshot

November 10, 2006

GAC里有什么?

Filed under: .NET

Keywords:GAC,GAC_32,GAC_MSIL,NativeImages

安装了.net2.0后,在命令行下可以看到
c:\windows\assembly目录下有如下内容
2006-04-08 00:32 <DIR> GAC
2006-11-10 21:55 <DIR> GAC_32
2006-04-07 23:39 <DIR> GAC_MSIL
2006-04-08 00:32 <DIR> NativeImages1_v1.1.4322
2006-10-20 04:23 <DIR> NativeImages_v2.0.50727_32
2006-10-19 02:18 <DIR> temp
2006-10-19 02:19 <DIR> tmp

GAC中是.net1.1的assembly

从.net2.0开始支持64bit,理论上.net assembly是MSIL代码,不用关心平台是
32位还是64位,但有些Manage c++的assembly同时包含MSIL code和Native code,
所以出现了32bit .net assembly 和64bit .net assemlby,在32位平台上,只需要安装
32bit .net assembly, 在64位平台上,要能直接运行32位的程序(Windows on windows),
所以要同时安装32bit .net assembly和64bit .net assembly,然而不是所有的assembly
都包含native code,所以可以把.net assembly分为两部分,所以在32位机器上会看到
GAC_32和GAC_MSIL这两个目录,在64位机器上会看到GAC_32,GAC_64,
GAC_MSIL这三个目录.打开GAC_32和GAC_MSIL这两个目录,可以看到GAC_MSIL
中包含大部分.net framework assembly和所有应用程序的assemly,GAC_32中包含
mscorlib等底层的assembly.

打开NativeImages目录,可以看到目录中包含所有的.net framework assembly的Native
Image,可见为了提高性能,MS为所有的.net framework assembly生成了image,

temp和tmp是两个空目录.

c:\windows\assembly下的隐藏文件Desktop.ini指定了使用Shell扩展SHFusion.dll来显示目录下的文件.

Comments »

The URI to TrackBack this entry is: http://recordsome.blogsome.com/2006/11/10/p187/trackback/

No comments yet.

RSS feed for comments on this post.

Leave a comment

Line and paragraph breaks automatic, e-mail address never displayed, HTML allowed: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <code> <em> <i> <strike> <strong>



Anti-spam measure: please retype the above text into the box provided.






















Get free blog up and running in minutes with Blogsome
Theme designed by Hadley Wickham