I've been reading Eric Lippert's article about the /optimize command line option of the C# compiler. The article describes what kind of optimizations the compiler performs. However it remains unclear to me if this option affects JIT optimization as well. It is not unthinkable, that this option would make the compiler to emit some metadata, that jitter can understand to change "optimization mode". Is there any reference that can confirm or otherwise if this option does indeed affect JITter?
Is there any reference that can confirm or otherwise if this option does indeed affect JITter?
According to Jeffrey Richter in his CLR via C# book, 3rd edition (chapter 1, page 13), it does. The /optimize+
switch will result in optimizations for C# IL code, as well as the native code generated by the JIT compiler. As to how it actually does that, I'm not sure. My wild guess is that it might have something to do with the CorDebugJITCompilerFlags enumeration.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With