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

Emit C global declarations in topological order #58

Closed
surovic opened this issue Dec 19, 2019 · 5 comments
Closed

Emit C global declarations in topological order #58

surovic opened this issue Dec 19, 2019 · 5 comments
Labels
decomp Related to LLVM IR to C decompiler enhancement New feature or request

Comments

@surovic
Copy link
Collaborator

surovic commented Dec 19, 2019

No description provided.

@pgoodman
Copy link
Collaborator

Another option might be to forward declare everything?

@pgoodman
Copy link
Collaborator

Or both, e.g. emit in topological order, but for cycles, support forward declarations.

@surovic
Copy link
Collaborator Author

surovic commented Dec 19, 2019

Or both, e.g. emit in topological order, but for cycles, support forward declarations.

Yeah, that's the plan. We currently forward declare everything so I thought it might be neat to sometime reduce the amount of forward declarations by emitting in order. This is not really a priority feature or bug. More or less just a reminder.

@surovic surovic added decomp Related to LLVM IR to C decompiler enhancement New feature or request labels Mar 3, 2021
frabert added a commit that referenced this issue Mar 29, 2022
frabert added a commit that referenced this issue Mar 29, 2022
* WIP: Provide provenance info for `llvm::Use`s

* Fix dangling uses

* Fix missing decl

* Fix overzealous substitution in `NestedCondProp` (#247)

* Add regression test

* Fix overzealous propagation

* Do not assume variables stay constant

* Fix provenance tracking

* Refactor `rellic-xref`

* Bundle all provenance info in a single struct

* Revert multimaps to standard maps

* Remove confusing method

* Explain `BlockVisitor`

* Remove wrapper

* Put `BlockVisitor` in a separate file

* Rename `GetOperandExpr` to `CreateOperandExpr`

* Refactor `IRToASTVisitor`

* Separate method declarations and definitions
Also fixes #249 and #58
@surovic
Copy link
Collaborator Author

surovic commented Mar 30, 2022

@frabert Since #249 was closed. Do you think we can close this one as well?

@frabert
Copy link
Collaborator

frabert commented Mar 30, 2022

I think we can!

@frabert frabert closed this as completed Mar 30, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
decomp Related to LLVM IR to C decompiler enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

3 participants