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

Represent size-change graphs as matrices (addresses #2954) #3108

Merged
merged 23 commits into from
Nov 6, 2023

Conversation

mjustus
Copy link
Collaborator

@mjustus mjustus commented Oct 17, 2023

No description provided.

Copy link
Member

@gallais gallais left a comment

Choose a reason for hiding this comment

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

Exciting!

src/Core/Termination/CallGraph.idr Show resolved Hide resolved
src/Core/Termination/CallGraph.idr Outdated Show resolved Hide resolved
src/Core/Termination/SizeChange.idr Outdated Show resolved Hide resolved
src/Libraries/Data/SparseMatrix.idr Show resolved Hide resolved
We also update sc-graph generation to
- fully traverse `As` patterns
- go under `Dotted` patterns
- consider `f x <= f`
Changes to the termination checker brought along some otherwise
insignificant changes to debug and error messages.
@mjustus mjustus marked this pull request as ready for review November 2, 2023 15:12
@mjustus
Copy link
Collaborator Author

mjustus commented Nov 2, 2023

It could always be improved further but I am reasonably happy with this PR now. Some things I considered but didn't do in the end:

  • select the non-terminating sc-graph corresponding to the shortest call sequence
  • print the selected sc-graph as part of the error message
  • make columns in printed sc-graphs right-aligned

@mjustus mjustus merged commit a26766e into idris-lang:main Nov 6, 2023
22 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants