This is lesson 3 of 12 in this module Course 84% complete

2D Arrays in Intermediate Language

Premium Content

Sign in with your account or join us to access this lesson.

The lesson show that accessing a two-dimensional array compiles into a virtual method call to Array.Set rather than a dedicated intermediate language instruction, because Microsoft chose not to reserve IL opcodes for the rarely-used multi-dimensional case. This extra method call is the root cause of the surprising performance penalty measured later.