IL assembly has no version number of its own: a .il file does not say which edition of the language it is written for. The language moves with three things: the editions of the standard ECMA-335 (the same text is the international standard ISO/IEC 23271), the runtime’s addendum to that standard, which records what .NET did beyond it, and the source of ilasm, which accepts more than either describes. Which word each release of ilasm added is known from the keyword table of every release branch of the runtime (.NET Core 1.0 to 11), and from running the ilasm of .NET 6.0 to 11.0 on each word (below). The versions of the standard come from the PDF of each of its six editions.
The standard
| Edition | What it holds and what changed (from the PDF of each edition, ecma-international.org) |
|---|---|
| 1st edition, December 2001 | Partitions I to IV. Partition II defines the ILAsm syntax (the text says that “the ilasm syntax itself is considered a normative part of this ECMA standard”) and names Partition V for “a complete syntax for ilasm”, but that partition was not yet in the book. It specified an XML encoding for permission sets, which the sixth edition says implementations should keep supporting (II.22.11). No generics, and no list of ilasm keywords |
| 2nd edition, December 2002 | Partitions I to V. Partition V (Annexes) is new and holds Annex C, “CIL Assembler Implementation”, with the list of ILAsm keywords (C.1) and the grammar. The directive set of Partition II (.assembly, .class, .vtfixup, .mresource, .hash, .override, .permissionset and so on) is already in the first edition |
| 3rd edition, June 2005 | The foreword lists: generic types and methods (in Partition II the words variance, contravariant and .param type appear from this edition on: the 2nd edition has none of the last two and one of the first), the prefixes constrained., no. and readonly., the instructions ldelem, stelem and unbox.any, a new Partition V “Debug Interchange Format”, and the old Partition V renamed Partition VI, with “Extensions to metadata” and “Imprecise faults” added. The keyword list of Annex C.1 grows by exactly those six words. It also received Technical Report 89 (TR89), a collection of generic types; the 6th edition took a selection of them into the standard |
| 4th edition, June 2006 | “Changes from the previous edition were made to align this Standard with ISO/IEC 23271:2006”. The keyword list is the same as in the third |
| 5th edition, December 2010 | “Technically revised”. Its foreword lists: the rules for assignment compatibility rewritten as a relation, the verification rules of many instructions, delegate signature compatibility and newobj for delegates; dispatch rules for variance (II.12.2); type forwarders (.class extern forwarder, II.6.8); variance redefined as a core feature, so that dispatch may prefer a match by variance over an exact match; and the requirement on ilasm to keep the left-to-right order of the interfaces of a type header and the top-to-bottom order of the methods in the metadata tables (II.10.2). The keyword list is unchanged |
| 6th edition, June 2012 | “Fully aligned with ISO/IEC 23271:2012”. Its foreword repeats the items of the fifth (type forwarders, the variance dispatch rules, the ilasm order rules and the others) and adds the list of types of the class library that changed; in Annex VI.C.1 the keyword list is the same as in the fourth and fifth editions. An earlier version of this page gave these changes to the sixth edition; the foreword of the fifth edition already has them, word for word |
The comparison of the keyword lists (a token by token comparison of Annex C.1 in editions 2 to 6) is the basis of two statements: the language of the standard did not change between the 3rd and 6th editions as far as its list of reserved words goes, and ilasm of .NET reserves words that the standard does not list and the other way round (the dialects). A line-by-line comparison of the grammar of Partition II across editions was not made; the foreword of each edition is the source of what changed.
The runtime’s addendum
docs/design/specs/Ecma-335-Augments.md in dotnet/runtime lists additions and corrections to the standard, some documenting new runtime features and some the quirks of the Microsoft implementation. Its sections show where the language grew; the syntax that each needs in IL assembly is in the pages named.
| Section of the addendum | What it covers | In IL assembly |
|---|---|---|
| Signatures | five corrections to how types and custom modifiers may appear in signatures (class or valuetype followed by a type spec, modifiers in more places, byref before modifiers, richer type specs) | Types and signatures |
| Heap sizes, metadata merging, metadata logical format | rules for the metadata streams | not source syntax |
| Module initializer | the type initializer of the <Module> type runs at or before the first access to a static field or the first call of a method of the module, once | a global .cctor: a .method declared outside any class (Classes) |
| Default interface methods | interfaces may have instance methods with a body, and interface methods may implement other interfaces’ methods through final method impls | .override in an interface (Classes) |
| Static interface methods, covariant return types, function pointer type identity | static virtual members of interfaces; overrides that return a more derived type; when two method pointer types are the same | Classes, Types |
| Unsigned data conversion with overflow detection | the conv.ovf.*.un instructions | The instruction set |
| Ref fields, ByRefLike types in generics | fields that hold managed pointers; by-ref-like types as type arguments | byreflike on a generic parameter (Classes) |
Rules for IL rewriters, checked user-defined operators, atomic reads and writes, backward branch constraints, transient pointers, arrays created with newobj | further rules for code that edits IL, the op_Checked… operators, the sizes for which reads and writes are atomic, and so on | The instruction set |
| API documentation, debug interchange format | how the documentation of the class library and the portable debug information relate to the standard | not source syntax |
| Extended layout | the extended layout of value types, set by an ExtendedLayoutAttribute; .pack and .size are not valid on such a type | extended, in ilasm 11.0.0 and later only (Classes) |
| Implicit argument coercion rules, init-only static fields | the coercion rules of the stack; changing an init-only static field outside the type initializer can compromise memory integrity and type safety (instance init-only fields are not affected) | Fields and data |
Words and options ilasm has that the sixth edition does not
Read from the keyword table and the grammar of the current ilasm; when each arrived is in the next section.
- class and generic parameter words:
extended,byreflike,windowsruntime,flags(…); - method implementation words:
aggressiveinlining,aggressiveoptimization,async,preservesig,optil; - assembly words:
retargetable,noplatform,legacy library,cil,x86,amd64,arm,arm64; - directives:
.interfaceimpl,.param constraint,.typedef,.language,.namespace, and the preprocessor; - options:
/PE64,/X64,/ARM,/ARM64,/32BITPREFERRED,/APPCONTAINER,/HIGHENTROPYVA,/DET(Tooling).
ilasm release by release
The master keyword table il_kywd.h (all 256 to 263 words, directives and # words included) was fetched from the release branch of every release from .NET Core 1.0 to 10.0 and from main and compared word by word. The ilasm of .NET 6.0.0, 7.0.0, 8.0.0, 9.0.0, three previews and the release of 10.0, and 11.0.0 (NuGet packages for macOS arm64) were run, each with every word of the table used as a class name: a bare keyword is a syntax error, anything else is a name. Both methods agree wherever both apply. The instruction table (opcode.def) has the same 294 OPDEF rows in .NET Core 1.0, 5.0 and today, and one file that uses every instruction name assembled with every release from 6.0.0 to 11.0.0.
| Release | Change in the words of ilasm | Checked by |
|---|---|---|
| .NET Core 1.0, 2.0, 2.1, 2.2 | 256 words, no change between them | table of the branch |
| .NET Core 3.0 (the table of 3.1 is the same) | aggressiveoptimization and arm64 added; ia64 removed (the only word ever dropped) | table of the branches 2.2, 3.0 and 3.1 |
| .NET 5.0 | constraint added (for .param constraint) | table of the branch 5.0 against 3.1 |
| .NET 6.0 | no change | table, and the run of 6.0.0 |
| .NET 7.0 | byreflike added (a generic parameter may be a by-reference-like type; dotnet/runtime pull request 67783, April 2022); ildasm gains /R2RNATIVEMETADATA; the banner loses “Microsoft (R)” | table, and the runs: byreflike is a name in 6.0.0 and a keyword in 7.0.0 |
| .NET 8.0 and 9.0 | no change in words or in options | table, and the runs |
| .NET 10.0, first previews | the options /DET and /ANAME of ilasm (in 10.0.0-preview.1, not in 9.0.0) | usage text of each package |
| .NET 10.0, preview 6 and the release | async added, the miAsync flag of runtime-async methods (pull request 115332 of May 2025 was reverted two days later and merged again as 115658), and the twelve method-implementation words native cil optil managed unmanaged forwardref preservesig runtime internalcall synchronized noinlining aggressiveinlining nooptimization aggressiveoptimization become usable as plain names (the id rule of the grammar). 10.0.0-preview.5 still refuses both | table of the branch 10.0, and the runs of the previews 4, 5 and 6, 10.0.0 |
.NET 11.0 (the table of main) | extended added, the layout of ExtendedLayoutAttribute and CStruct (pull request 116082, September 2025). Neither 10.0.15 nor 10.0.0 knows it | table of main; ilasm 11.0.0 accepts the word, 10.0.0 refuses it |
A second check on real files: the 3,403 .il files of the runtime’s tests (the main branch, 2026) were each assembled from their own folder. 3,343 assemble with ilasm 10.0.15 and with 11.0.0; with 6.0.0 it is 3,336. The seven that only 6.0.0 refuses are four files that use async and three that use byreflike, which is what the table says. Of the 60 that no release assembles, 58 name classes defined in files that are not assembled with them (56 of them MCCTest.VType…), one has two .assembly declarations after its includes, and one (UnitTest_TypeLoadException.il) has a syntax error before its last line.
Nothing was run for .NET Core 1.0 to 5.0: the NuGet packages of those releases exist for macOS x64 only, and this Mac has no x86-64 emulation. The directives (.class and the others) are part of the same table, so the table comparison covers them: no directive was added or removed in any release listed; the grammar rules behind them were not compared release by release. The ilasm of .NET Framework (Windows) was not compared.
Not described
Known, not yet covered
- Reference: only the keyword table, the opcode table and the usage text were compared across releases; changes to the grammar rules (what a word may be combined with) were not, except for the three the table shows (
byreflike,async,extended) and theidrule found by running. The git log ofasmparse.ywas not read. - Reference: Partition II of the editions 1 to 5 was compared with the sixth only through the forewords, the keyword annex and word counts, not rule by rule.
- Reference: the sections of the addendum to the standard are named, and only those that were read in detail (the module initializer, default interface methods, extended layout, init-only static fields) are described.