|
From: | ian |
Subject: | Re: [Tinycc-devel] Can a biggener (and idiot) like me read and understand TCC's backend so I can create my own frontend with it? |
Date: | Sat, 29 Jan 2022 10:43:00 +0100 |
User-agent: | Mozilla/5.0 (X11; Linux i686; rv:68.0) Gecko/20100101 Thunderbird/68.2.2 |
Hi
One thing or the other :
- you wanna learn asm or algorithmics, and it's not the best
place; but you obviously need to have to know them a "few",
- or, you already know how to code something in ASM, and then the suggested book about how to make an interpreter is the good starting point for you.
Rgds
29 Ιαν 2022, 03:20 Από sean@conman.org:It was thus said that the Great rempas via Tinycc-devel once stated:I would advice you to start with this https://craftinginterpreters.com/contents.html first. The rest will follow before you know it.Thanks! However, I don't understand how this will help me. I mean, I don't even want to create an intepreter to begin with. So this has nothing to do with what I want to make. Unless you are referring to the frontend so in this case, It will probably be a good idea to read this book. Or maybe I should make an intepreter in the end? Hmmmmm....It's interpreters all the way down (what do you think CPUs do with machine code? They interpret it). Also, if you have parsed code into a form you can interpret, you have enough information to generate machine code. -spc _______________________________________________ Tinycc-devel mailing list Tinycc-devel@nongnu.org https://lists.nongnu.org/mailman/listinfo/tinycc-develI don't know if I'm that stupid but I really don't understand. I know that the CPU interprets the instructions but an interpreter will use a programming language to interpret. For example, the following statement: `println("Hello from my lang: {}", "BestLang")` will be translated to (suppose the interpreted is written in C) and then be executed: `printf("Hello from my lang: %s", "BestLang);` So how is this going to teach my assembly and how the instructions are represented in binary? The book specifically says that it won't work with teaching assembly. The interpreted is a binary that takes source code and executes it. It doesn't create a binary. So I really don't understand what's going on here... _______________________________________________ Tinycc-devel mailing list Tinycc-devel@nongnu.org https://lists.nongnu.org/mailman/listinfo/tinycc-devel
[Prev in Thread] | Current Thread | [Next in Thread] |