Skip to content
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

Generate profiling reports #17

Merged
merged 6 commits into from
Feb 4, 2017
Merged

Generate profiling reports #17

merged 6 commits into from
Feb 4, 2017

Conversation

jmitchell
Copy link
Owner

Reports are output to ./profile, and are based on fprof and eflame.

Resolves most of #12 (remaining task now tracked in #16). Graphing metrics over time (#14) and exposing profiling reports to users (#15) are still pending.

The example puzzle is the same as the one in the Sudoku solver test, except with
several more cells filled in. Using the original causes :eflame to time out
while creating the final report (see
proger/eflame#13).

Ensure rebar is installed (the original, not rebar3), and run the following:

    $ MIX_ENV=prod mix do clean, deps.get, deps.compile, compile
    $ MIX_ENV=prod iex -S mix run -e "Backtrex.Profiler.eflame; exit(:normal)"
    $ ./deps/eflame/stack_to_flame.sh < stacks.out > flame-prod.svg

Credit goes to http://learningelixir.joekain.com/profiling-elixir-2/ for getting
me started.
Runs fprof and eflame on all combinations of backends and frontends, each with
a list of input problems they can handle.
Ignore fprof's "Unknown functions" because they don't seem to be included in the
Erlang PLT. Add mix as an explicit dependency to resolve the warning about the
custom mix task.
Backtrex.Profiler calls the script, but it was never committed.
@jmitchell jmitchell merged commit c82acf5 into master Feb 4, 2017
@jmitchell jmitchell deleted the profiling branch February 4, 2017 20:52
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant