Hello everyone, I was discussing about arrays in C# with some colleages and we started to look at the MSIL code generated for a simple inialization, for example:
int [] a = { 3, 5, 7 }; using ildasm. We realized that the MSIL code calls the funtion: System.Runtime.CompilerServices.RuntimeHelpers::InitializeArray(...) I wanted to see the code for InitializeArray(...) but it is declared "internalcall" so I thought I could find it somewhere in sscli code but the only thing I found was in the C# file for the corresponding class and it was declared extern. If clix can find it, it is somewhere. How do we go about finding the code for such a function, in general? Richter's book explain the meaning of the tokens used in the ildasm output and there is some code in the vm directory that seem to be relevant but what is the exact mapping? I was also trying to compare the code execution under rotor and standard CLI with cordbg. When you use rotor, the number of instructions executed for a statement, like the one above, as given with the wt command under cordbg is twice the number when run under the standard CLI. The standard CLI is suppose to use the same backend as the C++ compiler but is the rotor implementation of the Jiter so much slower? Some light would be appreciated. Daniel Perron