-
-
Notifications
You must be signed in to change notification settings - Fork 5.5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Documenting best practice for profiling *internals* of Julia #6639
Comments
For better ways of sending new flags to LLVM's configure: |
…user Also add --enable-keep-symbols --enable-debug-symbols when doing `make LLVM_DEBUG=1` As discussed in #6639.
You can now set LLVM configure options in |
Shold we document all these Make.user configuration options somewhere? |
The FAQ? |
The thing is that you can pretty much override anything in our Makefiles through Make.user. If we want to do this, we should probably just have a |
There is of course the problem that build options tend to be added without much thought (or inadvertently broken), so any documentation will quickly be outdated. Still I think some of these options deserves to listed somewhere. |
I think the reverse ought to be true though. Options that are documented should be treated no different than APIs. Any changes to documented options should reflect in documentation and version updates. |
My impression is that |
We can certainly enable optimizations in |
At some levels there's not much difference between retaining debug symbols and turning off optimizations. C++ relies on heavy inlining to make anything fast, so you'll never get great stack traces when debugging optimized code. |
I guess there is the generic |
Using
[Updated 2014-May-7] The first line is necessary if you are using Intel VTune Amplifier.
Amplifier has been complaining about needing a bigger signal stack, but I haven't figured out whether that's hurting the profiles. |
we have better support for this now (with |
Julia compilation speed is important, and to study it requires profiling the compiler, including LLVM. So I'd like to use this issue to collect the best known practices, and maybe even get it documented somewhere. Basically, the issue is how to turn on debugging symbols in the binaries without turning on assertions and other baggage.
[Updated 2014-Apr-28] See later note for current best practice. Rest of this note retained only for preserving context of later comments.
Here is what I've been doing so far (which is likely not best possible practice):
1.In
Make.user
, include the lines:The first line is necessary if using Intel VTune Amplifier.
2. Start a release build. After LLVM is configured, I stopped the process and edited
julia/deps/llvm-3.3/build_Release
and uncommented these two lines (not consecutive):Then I rebuilt LLVM and Julia.
It appears that the LLVM configure script has options
--enable-debug-symbols
and--enable-keep-symbols
to set said symbols above. But it's unclear to me if these can be somehow set inMake.user
and passed on down to LLVM's configure script.The text was updated successfully, but these errors were encountered: