Alec Taylor
2015-Jun-20 07:05 UTC
[LLVMdev] Code-generation: lang=>JSON, JSON=>lang and merging into lang
Considering engineering my own code-generator. If I do go ahead, will open-source the end result. Needs to read [parse] one language, and output JSON (conformant to a specific JSON-schema). Then needs to read JSON, and reproduce the code in that language, and [possibly] merge the generated code with existing code. Languages I'm looking to support are all rather popular (Python, Go, Rust, JavaScript). Any pointers—e.g.: specific LLVM libraries and sub-projects to use—would be appreciated. Thanks -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20150620/079f9c02/attachment.html>
Stephen Cross
2015-Jun-20 13:22 UTC
[LLVMdev] Code-generation: lang=>JSON, JSON=>lang and merging into lang
> reproduce the code in that languageIs the intention to exactly reproduce the original source code? Or some code that's functionally equivalent? On Sat, Jun 20, 2015 at 8:05 AM, Alec Taylor <alec.taylor6 at gmail.com> wrote:> Considering engineering my own code-generator. If I do go ahead, will > open-source the end result. > > Needs to read [parse] one language, and output JSON (conformant to a > specific JSON-schema). > > Then needs to read JSON, and reproduce the code in that language, and > [possibly] merge the generated code with existing code. > > Languages I'm looking to support are all rather popular (Python, Go, Rust, > JavaScript). > > Any pointers—e.g.: specific LLVM libraries and sub-projects to use—would be > appreciated. > > Thanks > > _______________________________________________ > LLVM Developers mailing list > LLVMdev at cs.uiuc.edu http://llvm.cs.uiuc.edu > http://lists.cs.uiuc.edu/mailman/listinfo/llvmdev >
Kenneth Adam Miller
2015-Jun-20 13:41 UTC
[LLVMdev] Code-generation: lang=>JSON, JSON=>lang and merging into lang
Possibly protobuf or capn proto would be much more clean alternatives to json. I was working with interpreting instruction semantics a while back, and you shouldn't have to write a parser to get the data structure back into coherent form, you can get what you want automatically and have the structure isolated into a common schema. On Sat, Jun 20, 2015 at 9:22 AM, Stephen Cross <scross at scross.co.uk> wrote:> > reproduce the code in that language > > Is the intention to exactly reproduce the original source code? Or > some code that's functionally equivalent? > > On Sat, Jun 20, 2015 at 8:05 AM, Alec Taylor <alec.taylor6 at gmail.com> > wrote: > > Considering engineering my own code-generator. If I do go ahead, will > > open-source the end result. > > > > Needs to read [parse] one language, and output JSON (conformant to a > > specific JSON-schema). > > > > Then needs to read JSON, and reproduce the code in that language, and > > [possibly] merge the generated code with existing code. > > > > Languages I'm looking to support are all rather popular (Python, Go, > Rust, > > JavaScript). > > > > Any pointers—e.g.: specific LLVM libraries and sub-projects to use—would > be > > appreciated. > > > > Thanks > > > > _______________________________________________ > > LLVM Developers mailing list > > LLVMdev at cs.uiuc.edu http://llvm.cs.uiuc.edu > > http://lists.cs.uiuc.edu/mailman/listinfo/llvmdev > > > > _______________________________________________ > LLVM Developers mailing list > LLVMdev at cs.uiuc.edu http://llvm.cs.uiuc.edu > http://lists.cs.uiuc.edu/mailman/listinfo/llvmdev >-------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20150620/114ca7d1/attachment.html>
Reasonably Related Threads
- [LLVMdev] Code-generation: lang=>JSON, JSON=>lang and merging into lang
- [LLVMdev] LLVM parsers for popular languages? - Python, Rust, Go
- [LLVMdev] LLVM parsers for popular languages? - Python, Rust, Go
- [LLVMdev] LLVM parsers for popular languages? - Python, Rust, Go
- Join and listen to conference call through web-interface