Most voted "assembly" questions
DO NOT use this tag to mark over . Net’s Assembly which has its own tag. Assembly Language (ASM) is a family of very low-level programming languages, just above machine code. Also specify a tag with the processor or instruction set your question is related, as well as the Assembler you are using.
Learn more…160 questions
Sort by count of
-
53
votes2
answers3546
viewsHow does a computer understand binary code?
How does a computer understand binary code? How binary code was created and who created it?
-
46
votes2
answers3637
viewsThe first programming language
Until the time when computers were purely mechanics and were programmed by punch cards I understand how it works. Later, when the first "digital" computers operated with valves and relays appeared,…
assembly compilers language-design computer-theoryasked 8 years, 2 months ago Michael Pacheco 1,657 -
33
votes2
answers844
viewsMemory Position Array
I’m doing an implementation of a game on Assembly in the Proteus. I draw two random numbers from 1 to 99 and need to generate on the LCD an image referring to the numbers I generated. Example: If I…
-
18
votes1
answer237
viewsStack and memory align operation in MASM X64
I have an application that takes a TAC code (IL) and generates an ASM code using x64 MASM. The problem is that I’m not having any compilation error, and yes, (at least that’s what I think) at the…
-
16
votes1
answer462
viewsSecurity - Syscall inside shellcode does not run
I’m studying information security and doing experiments trying to exploit a classic case of buffer overflow. I succeeded in creating the shellcode, in its injection into the code and its execution,…
-
15
votes4
answers6341
viewsWhat is the Assembler?
I always read things related to the Assembler and get confused. At first, I thought this was a mess and that Assembler was the same thing as Assembly. But it turns out that’s not it. What is…
-
13
votes1
answer560
viewsProblems decoding Assembly x86 from binary
I have written a program whose goal is to read a binary executable file compiled for the x86 (intel) architecture and interpret the Assembly code contained therein by executing instruction by…
-
13
votes1
answer447
viewsInstruction to add value to AX
What command/syntax to use to set the value 55d in the AX register?
-
11
votes3
answers409
viewsWould it be necessary to have another programming language to create the Assembler?
Would it be necessary to have another programming language to create the Assembler? If so, which one? If not, what could you do to get started? I know that according to the years, right after the…
-
9
votes1
answer138
viewsSwitching from 16 to 64 bits while booting an Intel PC compatible
Some time ago I studied to create a draft operating system for Intel PC compatible computers, which actually didn’t need to do much, besides putting the computer in 32-bit mode, handle keyboard…
-
9
votes1
answer3671
viewsAre there any other low-level languages besides assembly?
Are there other low-level languages besides Assembly? LISP is not (I think) nor Fortran.. Low-level language would be language closer to binary, as well as Assembly, language that works directly…
-
8
votes1
answer881
viewsMapping video card memory to access via Intel compatible x86 processor
Thinking of Intel compatible x86 computers, without considering the facilities provided by modern operating systems, anyone who wants to draw/write something on the computer screen can access some…
-
8
votes1
answer778
viewsDoes every processor use the same instruction set?
I was researching about machine language, but everything I found on the Internet is very little and only theoretical so I wanted to know if it is possible to create a simple program in machine…
assemblyasked 8 years, 10 months ago Paulo Abreu 416 -
8
votes1
answer2785
viewsHow to run Assembly inline in a code with variables in C?
From an example book, I was able to run the following Assembly (AT&T) code with gas, which returns a message with the processor name: .section .data output: .asciz "The processor Vendor ID is…
-
8
votes2
answers271
views -
7
votes2
answers315
viewsWhy are you giving Segmentation fault in my Assembly inline?
I’m trying to call the job execve("bin/sh"...) using Assembly, but in instruction: mov %rsi,0x8(%rsi) i carry a segmentation error. This is the 64bit version of the article code "Smash the stack for…
-
7
votes2
answers1503
viewsHow to identify the MVC version?
How can I identify the MVC version I’m using in my project?
-
7
votes3
answers12436
viewsWhat are recorders and what is their basic functioning?
I am reading a book about Assembly in order to better understand how a low-level language works, it will help me to understand more effectively the internal functioning of the programs I develop in…
-
6
votes1
answer77
viewsWhat are the real problems for those working with Assembly development?
I am studying the architecture and implementation in MIPS, but as I do not work at low level what I am doing are basic initial exercises in any beginning of learning, I would like to know what are…
software-architecture assembly architecture-computers mipsasked 9 years, 3 months ago Emanoel 1,621 -
6
votes1
answer1312
viewsDoubt in substituting string Assembly (MIPS)
I have to make a code in Assembly mips requesting a sentence and if the sentence contains the character - is replaced by the character *. So far I’ve only managed to reach that code: .data buffer:…
-
6
votes1
answer135
viewsIs the assembly code of a compiled program different from what was written?
I compiled this Assembly code global _main extern _printf section .text _main: push message call _printf add esp, 4 ret message: db 'Hello, World!', 10, 0 when I went to give u dump in code Assembly…
-
6
votes1
answer61
viewsWhy in MOS 6502 the SBC subtracts 2 instead of 1 the first time?
I am trying to learn Assembly for MOS 6502 and I came across unusual behavior when testing my code on online emulator. Code LDA #$5 ; A=5 SBC #$1 ; A=3 mas deveria ser 4 SBC #$1 ; A=2 mas deveria…
-
6
votes1
answer130
viewsWhat is the difference of syscall and call in Assembly?
The following simple code I wrote, based on a code I read in a book, was not compiling: ;myhello section .data msg db "Boa tarde",0 NL db 0xa section .bss section .text global main main: push rbp…
-
5
votes2
answers4801
viewsHow to use multiple languages in a single program?
I saw that Google Chrome is made in Python, C++ and Assembly and came to mind, like programming using multiple languages in a SINGLE program?
-
5
votes2
answers195
viewsCompile Linux-ready Assembly on OSX
I’m trying to do a study of compilers, so I have to compile an Assembly of a language called howto with nasm. the intermediate code generated by the howto compiler is as follows: extern printf…
-
4
votes1
answer293
viewsAssembly compatibility and architectures
I have no experience with low-level Assembly language. What is required to obtain the maximum of cross Platform with that language? I mean, if I just focus on AMD64 (x86-64) I’ll get compatibility…
-
4
votes1
answer1832
viewsHow to Make a Simple Assembly Assembler
I’m learning about processor architecture and I intend to assemble an Assembler. What is the procedure and steps for writing a program that transforms written code into machine code? The assembler…
-
4
votes1
answer813
viewsHow to make a Chained List in Assembly?
I have a college job and I need to make a chained list at Assembly, would like to know how to do the loop to insert all items in the list and keep them connected. The list must contain the data of a…
-
4
votes1
answer3307
viewsIs OS development restricted to beginners?
One thing I’ve always wanted to do is develop my own operating system (not necessarily as good as Linux or Windows, it would have some basic functions at prompt). I’m not a complete beginner in this…
-
4
votes2
answers2453
viewsIs it possible to do multiplications only with operators &, |, + and -?
I have to create a program with the Assembly language K & S Model 2 that multiplies one number by another, the problem is that this language does not provide a multiplication operation. So I…
-
4
votes2
answers254
viewsExecution of Instructions
I’m reading a book on Introduction to Computer Architecture. One excerpt from the book says the following about the RISC interface of processors: "Each instruction typically takes a clock cycle."…
-
4
votes1
answer2375
viewsHow to compile this code in Assembly on Windows?
I was seeing a creation of a basic window on Assembly that displays a message, already installed the compiler NASM but error to compile. .386 .MODEL FLAT, STDCALL INCLUDE windows.inc INCLUDE…
-
4
votes1
answer2333
viewsHow do I split into Assembly?
Boa Pessoal , I’m new to Assembly, I’m having trouble with division. When I compile the program on the command line, I get this error Floating point Exception. .section .data .global op1 .global op2…
assemblyasked 8 years, 2 months ago Programador 135 -
4
votes3
answers430
viewsHow to know if a binary sum of unsigneds has overflowed?
If I have a sum of two unsigned numbers (1 byte each) in an Assembly without carry flag, how do I know if I have overflow? Edit: the architecture in question is Neander Solution: I found a way to do…
-
4
votes3
answers2830
viewsLoop of repetition in Assembly
How can I do a repeat a certain number of times in Assembly (no MIPS)? Example in pseudocode, assuming the variable registrador be a registrar that I want to receive all numbers from 1 to 6 (one at…
-
4
votes1
answer146
viewsProblems with Assembly
I recently started studying computer architecture in which it is necessary to know this language. Because it is an assembly language (low level language), I did not find any IDE so I could test the…
assemblyasked 7 years, 1 month ago Maurício Z.B 1,098 -
4
votes1
answer185
viewsDifference between MOV and MOV ptr
Maybe it’s not the ideal place to ask this, but I’m having a test and I don’t understand the difference between MOV and MOV ptr. for example, if we have in c language "unsigned char x,y", in…
-
3
votes1
answer291
views$zero - What do you do and how does it work?
Good! I started studying a little Assembly for MIPS. Can anyone explain to me how this line of code works, Ld R4,A(R0), where R0 has the same meaning of $zero? .data A: .word 10 B: .word 8 C: .word…
assemblyasked 10 years, 8 months ago user6902 -
3
votes1
answer89
viewsARM atomic operations without Visual Studio
When programming in C/C++ on the x86 and x86-64 (AMD64) architecture and using the Microsoft compiler that comes with Visual Studio, there are two intrinsic functions to perform atomic operations,…
-
3
votes1
answer724
viewsWhere are the instructions for a processor stored?
I’m studying computer architecture, and I’m very confused about the instruction set of a processor. When we write something, for example, ADD A1, B1, the processor adds the value of the A1 register…
-
3
votes1
answer1565
viewsHow does it work and what is the syntax of the machine code?
I need to understand how the machine code works, for example, the statements of the instructions and how it can become readable like Assembly, where I can see instruction like mov, "interpret".…
-
3
votes0
answers237
viewsBinary search mips
I am developing a code in mips in order to perform a binary search recursively, well along the development have arisen some doubts, being them: Right after my function call, I pop my arguments, but…
-
3
votes1
answer85
viewsDoes not write on screen, turns black and should appear a square 2x2
Pos_Bloco_Ini_x dw 30 ; posição inicial do bloco em x Pos_Bloco_Ini_y dw 30 ; posição inicial do bloco em y Tam_Bloco DW 2 ;tamanho do bloco MOV AH, 00h ;Prepara para definir o modo…
-
3
votes1
answer1901
viewsMOD in Assembly
I need to make a comparison to see if the number X is PAR or ODD. I store the number in the AX register. How do I know that AX content is even or odd? Note: I store a number from 1 to 99.…
-
3
votes0
answers92
viewsOptimization of poorly compiled
I set up Visual Studio to compile VC++ with /Ox and compiled this code (with more others that were omitted to simplify). union { unsigned long long u64 ; unsigned short u16[4] ; } x ; union {…
-
3
votes1
answer503
viewsHow can I print a user-typed string in Assembly 8086?
I’m having trouble printing a string that was later typed by the user through INT 21h/AH 0Ah. I have no idea how I can print the string that was filed in AL. mov ah, 0Ah int 21h I tried to use the…
-
3
votes1
answer463
viewsWhat is object code?
What is object code? What is object code for? What is the process of translating object code into machine code called? I’ve seen talk until the language C uses Assembly as object code, is that…
-
3
votes1
answer40
viewsshellcode amended "Segmentation fault"
Well I have a file called test.asm with the code (for windows): section .text global _main extern _printf msg: db "%d", 0 _main: mov eax, 10 add eax, 20 push eax push msg call _printf add esp, 8 ret…
-
3
votes0
answers41
viewsProblem with Assembly subtraction
My teacher sent this simple code in C, to turn it into Assembly: int num1, num2, resultado; printf("Digite o primeiro numero: \n"); scanf("%d", &num1); printf("Digite o segundo numero: \n");…
-
2
votes0
answers134
viewsHow to turn off your PC in 16-bit Assembly in boot mode
Good night I’m developing a bootloader that saves to a floppy disk. I was able to restart now, but I can’t get it to turn off. I’ve tried several codes in Assembly, but nothing works. It always…