What is contained in a PE Header and CLR Header as

2019-08-14 22:47发布

What is meant by PE header in a .net assembly? I have read that .net programs are compiled into a portable executable which will contain IL Code and Meta Data.

But these terms PE Header and CLR Header are new.

Are they different from IF Code and Metadata? If so what do they contain and when will one need to use it?

标签: c# .net clr
1条回答
孤傲高冷的网名
2楼-- · 2019-08-14 23:43

The PE file format is used for executables in Windows, like progams and DLLs, but also for some other data like .FON font files.

The PE header is the header of the file, which contains the basic information about what the file contains.

The CLR header is a data block in a PE file, present if the file contains a .NET assembly. The CLR header contains .NET metadata that the CLR loader uses.

More reading: http://en.wikipedia.org/wiki/Portable_Executable#.NET.2C_metadata.2C_and_the_PE_format

查看更多
登录 后发表回答