Code Monkey home page Code Monkey logo

Comments (4)

simonpj avatar simonpj commented on August 28, 2024

I don't understand the problem you are trying to solve. What's wrong with the order that postorder_dfs comes up with?

Perhaps you have in mind that after postorder_dfs then you can pretty-print as a sequence of machine instructions with a fall-through for the conditional jump? But you can still get a fall-through by negating the condition can't you? And none of this matters if generating LLVM.

from hoopl.

hth313 avatar hth313 commented on August 28, 2024

I want a sequence of instructions that have the order as they should appear in the final output. Conditional branches need to be able to fall-through to the next block.

However, it turns out that it is easy to rectify this issue in my case as I need a branch optimizer that works on the flattened output anyway and correcting the potential out of order sequence there is trivial.

So any post processing, be it the way I do it or (apparently) LLVM can easily correct the issue.

I will close this.

from hoopl.

simonmar avatar simonmar commented on August 28, 2024

from hoopl.

hth313 avatar hth313 commented on August 28, 2024

Thank you! That is very useful information to me, I will keep it in mind for the future as I expect to get back and do more elaborate branch optimizations.

from hoopl.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.