Conversation
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: c0e12fcb53
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| List<ImClass> classes = new ArrayList<>(prog.getClasses()); | ||
| classes.sort(Comparator.comparing(this::classSortKey)); | ||
| for (ImClass candidateClass : classes) { | ||
| if (!sharesClosureFamilyAnchor(candidateClass, anchors, new HashSet<>())) { | ||
| continue; |
There was a problem hiding this comment.
Cache closure-family class scan to avoid quadratic compilation
collectEquivalentClosureFamilyMethodNames is called from createMethods for each dispatch group, but it rebuilds and sorts prog.getClasses() and then re-traverses inheritance for every candidate on every call. On projects with many generated closures this turns class-table setup into a repeated whole-program scan and introduces a significant compile-time regression compared to the previous local-hierarchy lookup. Precomputing/caching candidates per closure-family anchor would keep this from scaling with #groups × #classes.
Useful? React with 👍 / 👎.
No description provided.