your favorite assembly instruction

code the shit
Post Reply
User avatar
hataita_database
Member
Member
Posts: 43
Joined: Mon Sep 25, 2023 2:34 pm

your favorite assembly instruction

Post by hataita_database »

mine is subl in IA-32 because you can subl $4, %esp which is like moving back in time imagine the room shifting around you!!
(*) will never forget goatse sig (*)
(*) 2023/09/20 - 2023/09/20 (*)
User avatar
nishi
Site Admin
Site Admin
Posts: 123
Joined: Mon Sep 25, 2023 5:08 am
Contact:

Re: your favorite assembly instruction

Post by nishi »

mov
Image
User avatar
sysrq
Member
Member
Posts: 46
Joined: Mon Sep 25, 2023 4:25 am

Re: your favorite assembly instruction

Post by sysrq »

In 8086 assembler, there were these instructions for dealing with BCD stuff, not really documented well. Anyway I forget the exact instruction but I believe someone found that by using it, you could convert a digit into it's hex value in ascii in only 3 instructions. So whatever instruction that person used is my favorite.

I need to find where I found it though, it's really old.
Mine brain has meditated on the spinning of The Chao;
It is hovering o'er the table where the Chiefs of Staff are now
Gathered in discussion of the dropping of The Bomb;
Her Apple Corps is strong!
-----
Survivor of the first forum rapture
User avatar
sysrq
Member
Member
Posts: 46
Joined: Mon Sep 25, 2023 4:25 am

Re: your favorite assembly instruction

Post by sysrq »

sysrq wrote: Sat Jan 18, 1992 6:23 pm In 8086 assembler, there were these instructions for dealing with BCD stuff, not really documented well. Anyway I forget the exact instruction but I believe someone found that by using it, you could convert a digit into it's hex value in ascii in only 3 instructions. So whatever instruction that person used is my favorite.

I need to find where I found it though, it's really old.
I've revised my position. It's this now.

Code: Select all

        xchg %ax, %ax
Mine brain has meditated on the spinning of The Chao;
It is hovering o'er the table where the Chiefs of Staff are now
Gathered in discussion of the dropping of The Bomb;
Her Apple Corps is strong!
-----
Survivor of the first forum rapture
User avatar
Mastemerchant
Member
Member
Posts: 13
Joined: Sun Oct 08, 2023 2:40 pm
Location: Schwartzwelt

Re: your favorite assembly instruction

Post by Mastemerchant »

hataita_database wrote: Tue Sep 26, 2023 2:36 pm mine is subl in IA-32 because you can subl $4, %esp which is like moving back in time imagine the room shifting around you!!
x86 because it's the only one I know and I had fun with it in a Uni class
Image
Post Reply