flat assembler
Message board for the users of flat assembler.
![]() |
Author |
|
Roman
I was surprised when I did not find on x86
Call NZ and Call Z Ret NZ and Ret Z Useful commands. On zx-spectrum was this commands. |
|||
![]() |
|
Roman
emulation CAll nz
Code: cmp eax,10 push lab1 jnz ProcDoSomeCode lab1: Code:
ProcDoSomeCode:
some code
ret
|
|||
![]() |
|
Furs
Roman wrote: emulation CAll nz ![]() Also it always pushes, I don't think that's intentional and probably a bug (I don't know about ZX Spectrum). Why not keep it simple like: Code: cmp eax, 10 jz @f call ProcDoSomeCode @@: |
|||
![]() |
|
Roman
Furs
Yes good too Code: cmp eax, 10 jz @f call ProcDoSomeCode @@: ZX-Spectrum was in 1982 !!! I just show on example how useful Call Z or Call NZ. One Call Nz or write 3 line code. |
|||
![]() |
|
revolution
ARM in 32-bit mode can also do conditional calls.
But in 64-bit code that was eliminated. C code compilers can't generated conditional call instructions, so the instructions are unused by most software. Therefore the CPU makers found no compelling reason to include it in the instruction set. And, as we all know, no one writes assembly code directly, by hand. OMG, that would be just too difficult for any human to do. ![]() |
|||
![]() |
|
< Last Thread | Next Thread > |
Forum Rules:
|
Copyright © 1999-2019, Tomasz Grysztar.
Powered by rwasa.