Detailed statistics command - #38
Conversation
There was a problem hiding this comment.
Pull request overview
This PR adds a new egraph-detailed-stats command to the egglog-experimental library for retrieving detailed statistics about the e-graph state.
- Adds a new stats module with the
EgraphDetailedStatscommand implementation - Registers the
egraph-detailed-statscommand in the experimental e-graph - Includes test coverage with a dedicated test file and integration into an existing comprehensive test
Reviewed changes
Copilot reviewed 3 out of 3 changed files in this pull request and generated 2 comments.
| File | Description |
|---|---|
| src/lib.rs | Imports the new stats module and registers the egraph-detailed-stats command in the experimental e-graph setup |
| tests/web-demo/detailed-stats.egg | New test file demonstrating the egraph-detailed-stats command with a simple Math datatype example |
| tests/herbie-rational.egg | Adds a call to egraph-detailed-stats in an existing comprehensive test case to verify it works in a real-world scenario |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
| mod stats; | ||
| pub use stats::*; |
There was a problem hiding this comment.
The code references a stats module and uses EgraphDetailedStats struct, but the src/stats.rs file is not included in this PR and does not exist in the repository. This will cause a compilation error. The implementation of the stats module containing the EgraphDetailedStats command needs to be added.
| (run-schedule (saturate (run))) | ||
|
|
||
| ; Get detailed statistics | ||
| (egraph-detailed-stats) |
There was a problem hiding this comment.
The test for the new egraph-detailed-stats command doesn't include any assertions to verify the command's output or behavior. Consider adding checks to validate that the command executes successfully and potentially verify aspects of the returned statistics, similar to how get-size! is validated in other tests.
|
Ooops CI very unhappy haha |
No description provided.