A
A
armadillo-cld2020-09-08 22:58:26
assembler
armadillo-cld, 2020-09-08 22:58:26

Real low-level assembly language programming?

Hello.
I have been very drawn to assembler lately, but the fact is that I do not know how to use it correctly, and the syntax is not the same, it does not light me up.
Let's say I'm writing an assembler program that writes text to a file. I use WinApi, which results in some high-level code that does not appeal to me.
In what cases can you write in assembler like in DOS? That is, what would the code look like:
(Looks pretty high-level, I don’t see assembler here. It’s like I’m writing in C ++)

invoke CreateFile, ...
invoke WriteFile, ...
invoke CloseHandle, ...

And like this (another example, here is not a file entry, but simply gave the syntax):
mov ds, 09h
mov ax, message
int 21h

In terms of syntax, it looks very nice and professional, you can immediately say that it is really an assembler. Is it possible to write software on Windows using a similar syntax?

Answer the question

In order to leave comments, you need to log in

1 answer(s)
J
jcmvbkbc, 2020-09-08
@armadillo-cld

the syntax is not the same, it does not light me up.

And the assembler syntax was not designed with the aim of "igniting". It was designed with in mind, first of all, the ease of translating it into machine code.
it turns out some high-level code that does not attract me.

The high level of code is not in how it looks, but in what it does. Take a look, for example, in the sources of qemu , in the main code there is not a single line in assembler at all, everything is in C. Nevertheless, in places this is awesome low-level code.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question