Skip to content

Conversation

@uenoku
Copy link
Member

@uenoku uenoku commented Oct 7, 2025

This commit refactors the LongestPathAnalysis API to improve clarity and expose external path query methods. The main change renames "closed paths" to "internal paths" to better reflect their meaning as register-to-register paths within a module.

The C API and Python bindings now expose getOpenPathsFromInputPortsToInternal() and getOpenPathsFromInternalToOutputPorts(), allowing users to query input-to-register and register-to-output paths separately. The Python getAllPaths() method now composes results from these three path query methods rather than calling a single C API function.

This commit refactors the LongestPathAnalysis API to improve clarity and expose external path query methods. The main change renames "closed paths" to "internal paths" to better reflect their meaning as register-to-register paths within a module.

The C API and Python bindings now expose getOpenPathsFromInputPortsToInternal() and getOpenPathsFromInternalToOutputPorts(), allowing users to query input-to-register and register-to-output paths separately. The Python getAllPaths() method now composes results from these three path query methods rather than calling a single C API function.
@uenoku uenoku force-pushed the dev/hidetou/longest-path branch from c497627 to 82b9606 Compare October 7, 2025 22:47
@uenoku uenoku changed the title [python][Synth] Provide a fine-grained APIs for path queries [python][Synth] Provide fine-grained APIs for path queries Oct 7, 2025

m = Module.create()
with InsertionPoint(m.body):
i4 = IntegerType.get_signless(2)
Copy link
Member Author

Choose a reason for hiding this comment

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

Suggested change
i4 = IntegerType.get_signless(2)
i2 = IntegerType.get_signless(2)

Copy link
Contributor

@fabianschuiki fabianschuiki left a comment

Choose a reason for hiding this comment

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

LGTM!

@uenoku uenoku merged commit f585d9a into llvm:main Oct 9, 2025
7 checks passed
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.

2 participants