A third option: generate assembly code and look at it.
I tend to favour one of these; compiling with debug support will often skew the result because of the 'observer effect'.
The code that we observe will typically not be the code that runs when debug support is not enabled. https://en.wikipedia.org/wiki/Observer_effect_(physics)