Hacker Newsnew | past | comments | ask | show | jobs | submitlogin
Rose: Compiler Infrastructure for Source-to-Source Program Transformation (github.com/rose-compiler)
80 points by ingve on Feb 19, 2019 | hide | past | favorite | 12 comments



seems similar in spirit to facebook's [pfff](https://github.com/facebook/pfff)


Long ago I found this:

https://www.reddit.com/r/lisp/comments/1totwx/some_useful_li...

lisp to pascal .. with vanilla pretty-printer customization


> Chapter 1 published as "Using the New Common Lisp Pretty Printer", ACM Lisp Pointers , 5(2):27 34, April 1992. Copyright (c) Mitsubishi Electric Research Laboratories, 1991

Someone wasn't getting any electric research done, that's for sure.


I once saw this machine (from ten meters away :-( ):

http://museum.ipsj.or.jp/en/computer/other/0009.html


You're not aware of Mitsubishi line of pretty laser printers ?


So... is the idea to be like Pandoc[1], but for programming languages? Like, with the current support, could you write a PHP-to-Fortran89 translator? (Assuming you would want to)

[1] https://pandoc.org/


While this seems very nice, I'm a bit disappointed to see that it seems focused only on C, Fortran and PHP. Since it seems that ROSE operates directly on ASTs, I see no reason why the project couldn't be language-agnostic if given appropriate information about the AST to be processed.

(Of course, as this project was originally started for the DOE's purposes, it seems that it might just be a matter of simplicity)


ROSE has been around for a long time, and from what I've heard there's tons of legacy code. I wouldn't be surprised if there's significant technical debt or other structural limitations.

That said, I don't really know anything firsthand about the architecture.


Has anyone integrated "program analysis" algorithms into ROSE?

Even basic stuff like Steensgaard, Andersen can take a lot of effort to integrate into new frameworks


There are a bunch of analyses at https://github.com/rose-compiler/rose-develop/tree/master/sr..., it wasn't that hard to get there with four clicks.

Of the ones you mentioned, there is what appears to be a Steensgaard analysis.


Looks really cool. From a quick look, it seems to be for writing analyzers and optimizers on your code. It supports Fortran, C, C++, OpenMP, UPC, and PHP.


I thought it was like Babel. Turns out it was way more than that.




Consider applying for YC's Fall 2025 batch! Applications are open till Aug 4

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: