Ok, i know (a bit) assembly. I know how i can make a language (that's not hard). But how the hell can i write a program that makes .exe files?
I mean, what i have to do is to take the text from the .programming_language file, and turn it to and .exe. How do i make an .exe? I DON'T want to convert to .asm and compile it again, i want to make the compiler myself.
Anybody know how?
Creating own language and compiler
Started by Davide, Feb 12 2010 09:35 AM
15 replies to this topic
#1
Posted 12 February 2010 - 09:35 AM
Are you a newbie programmer trying to learn C#? Check out my small tutorial: Visual C# Programming Basics
|
|
|
#2
Posted 12 February 2010 - 10:07 AM
That requires you to write an assembler, which is a program that takes assembly source code and converts it to it's hexadecimal representation. I wouldn't know the first thing about writing an assembler, but I know there are several open source assemblers out there you can look at.
This is one of the few places where I find "LOL" to be highly appropriate. The assembler should be trivial compared to the compiler and language semantics.
Davide said:
I know how i can make a language (that's not hard).
Wow I changed my sig!
#3
Posted 14 February 2010 - 10:32 AM
Davide said:
Ok, i know (a bit) assembly. I know how i can make a language (that's not hard). But how the hell can i write a program that makes .exe files?
This statement is really interesting. First you say that making a programming language is easy, and just after that, you ask "how to make an .exe file?" (the really easy part). I assume that you have absolutely no idea of what a file really is. Have you heard about file headers, which describe the file information?
Another thing is, you must know more than a bit of assembly to make a programming language. You must really know assembly, architectures, the differences between them, parsing (tokenization, syntactic analysis, parse trees), compilation, optimizations, file formats, operating systems... just to name a few things. You must have a very good knowledge about programming, the most single mistake in compilation immediately leads to an invalid executable.
#4
Posted 14 February 2010 - 12:17 PM
An interpreted programming language is completly different, it doesnt require an exe, and guess what? I managed to make one, it's just that i don't like it like that.
A bit doesn't describes all my experience with assembly.
I found my answer guys btw, thanks for your help.
A bit doesn't describes all my experience with assembly.
I found my answer guys btw, thanks for your help.
Are you a newbie programmer trying to learn C#? Check out my small tutorial: Visual C# Programming Basics
#5
Posted 14 February 2010 - 12:31 PM
Glad that you found your answer Davide, I'd be quite interesting to see a bit of your language just from curioisity.
#6
Posted 18 February 2010 - 12:30 PM
I wrote a programming language (scripts) in delphi for a project im still working on
its very simple but adequate for its job,
originally everything was done as functions, however i have taught the compiler to handle + - * / and brackets
since it only uses floating point numbers and the Scripts aren't used outside the application all function are pre-coded into the application
although its very limited it is the basis of a fully functional language
I am working on a more advanced version for another project
its very simple but adequate for its job,
originally everything was done as functions, however i have taught the compiler to handle + - * / and brackets
since it only uses floating point numbers and the Scripts aren't used outside the application all function are pre-coded into the application
although its very limited it is the basis of a fully functional language
I am working on a more advanced version for another project
#7
Posted 24 July 2010 - 09:03 PM
@x42: Less than five minutes on Google got me this:
Processors
Intel
http://www.intel.com...nual/253666.pdf
http://www.intel.com...nual/253667.pdf
MIPS
http://dkrizanc.web....7/MIPS_Vol2.pdf
ARM
http://simplemachine...oc/arm_inst.pdf
SPARC
http://www.sparc.org/standards/V8.pdf
Interpreted Languages
Java
Java bytecode - Wikipedia, the free encyclopedia
Java bytecode:
Python
31.12. dis
Ruby
YARV: Yet another RubyVM / Instruction Table
Processors
Intel
http://www.intel.com...nual/253666.pdf
http://www.intel.com...nual/253667.pdf
MIPS
http://dkrizanc.web....7/MIPS_Vol2.pdf
ARM
http://simplemachine...oc/arm_inst.pdf
SPARC
http://www.sparc.org/standards/V8.pdf
Interpreted Languages
Java
Java bytecode - Wikipedia, the free encyclopedia
Java bytecode:
Python
31.12. dis
Ruby
YARV: Yet another RubyVM / Instruction Table
sudo rm -rf /
#8
Posted 24 July 2010 - 10:31 PM
I think that might be another one of those "LOL" moments
#9
Posted 24 July 2010 - 10:34 PM
Seriously, x42, you need to spend some time looking on the Internet before you make claims like that. It's misleading.
sudo rm -rf /
#10
Posted 25 July 2010 - 02:24 AM
This is like "he got owned". I have 6 big intel manuals that i have requested long time ago for free, 2 of them were posted by dargueta. It's pretty obvious that each processor have manuals that covers everything we need to know about them.
#11
Posted 25 July 2010 - 08:26 AM
Ok guys, let's stop lambasting x42 and get back to the topic, shall we?
@ outsid3r: I like your avatar. Very true. :)
@ outsid3r: I like your avatar. Very true. :)
sudo rm -rf /
#12
Posted 25 July 2010 - 08:50 AM
dargueta said:
Ok guys, let's stop lambasting x42 and get back to the topic, shall we?
@ outsid3r: I like your avatar. Very true. :)
@ outsid3r: I like your avatar. Very true. :)
It was stolen from a guy named salem from another forum hehehe.


Sign In
Create Account


Back to top









