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

[Profiling] Small adjustments and improved timeline view #2388

Merged
merged 83 commits into from
Jan 8, 2025

Conversation

ayakayorihiro
Copy link
Contributor

@ayakayorihiro ayakayorihiro commented Jan 6, 2025

This PR contains a series of minor changes I made over the past couple of weeks.

I made some small changes to non-profiler parts of the repo:

  • Adding *.svg and *.folded to the gitignore
  • Adding a profiler-specific pass alias (-p profiler)
  • Using -p profiler in fud2 so there's no inconsistency in what passes we use.

In profiler-specific code, I fixed a bug where the flame graph recorded one extra cycle for main, added colors to categorize nodes in the aggregate tree picture (between cells, groups, and primitives), and have the profiler emit a timeline JSON involving all cells by default.

@ayakayorihiro ayakayorihiro added the C: calyx-profiler Profiling Calyx programs label Jan 6, 2025
@ayakayorihiro ayakayorihiro self-assigned this Jan 6, 2025
@@ -40,7 +39,7 @@ fn calyx_to_flamegraph(e, input, output) {
e.build_cmd(["$cells"], "component-cells", [input], []);
e.build_cmd([instrumented_verilog], "calyx", [input], []);
e.arg("backend", "verilog");
e.arg("args", " -p static-inline -p compile-static -p compile-repeat -p compile-invoke -p profiler-instrumentation -p $passes -x tdcc:dump-fsm-json=fsm.json");
e.arg("args", "-p profiler");
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

let's undo this change so that people can set custom passes

Copy link
Contributor

@ekiwi ekiwi left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

One small change and then you can merge

@ayakayorihiro ayakayorihiro enabled auto-merge (squash) January 8, 2025 17:46
@ayakayorihiro ayakayorihiro merged commit 2e18d55 into main Jan 8, 2025
18 checks passed
@ayakayorihiro ayakayorihiro deleted the profiler-timeline branch January 8, 2025 18:01
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
C: calyx-profiler Profiling Calyx programs
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants