Full Disclosure mailing list archives
[ElectronicSouls] - RISK Assembly
From: es () hush com
Date: Fri, 29 Nov 2002 09:27:44 -0800
-----BEGIN PGP SIGNED MESSAGE----- Dear List, We would like to demonstrate our efficiency in RISK Assembly, which is not to be confused with MIPS. Our Indy in the lab uses a RISK processor and NOT a Motorola. # cat risk.a ## ## (C) BrainStorm - ElectronicSouls ## RISK baby ;) ..well im working on a system of a friend ## rightnow ..and im going into low-level coding now .. ## so well this is one of my 1st RISK arch codes. ## convert decimal number to hex, print the result. ## ## Quick Greetz: ghQst,it_fresh,erebus,0x90,SectorX,Resistor,Freq.. ## of course all ES members! ## ## http://www.ElectronicSouls.org ## LOW LEVEL R0X ################################################# # text segment # ################################################# .text .globl __begin __begin: la $a0,ESouls ## print on terminal li $v0,4 syscall li $v0,5 ## syscall 5 reads an integer syscall move $t2,$v0 ## $t2 holds the hex number la $a0,string ## print string before result li $v0,4 syscall li $t0,8 ## eight hex digits la $t3,hax ## setup answer string loop: rol $t2,$t2,4 ## start with leftmost digit and $t1,$t2,0xf ## mask one digit ble $t1,9,print ## check if 0 to 9 add $t1,$t1,7 ## 7 characters between '9' and 'A' print: add $t1,$t1,48 ## '0' is 48 sb $t1,($t3) ## save in string add $t3,$t3,1 ## advanced destination pointer add $t0,$t0,-1 ## decrement counter bnez $t0,loop ## and continue if counter>0 la $a0,hax ## print 'hax' on term li $v0,4 syscall li $v0,10 syscall ## here we go :) ################################################# # data segment # ################################################# # <- i bet those segments ph34r ghQst ;) .data hax: .space 8 ESouls: .asciiz "\n\n ElectronicSouls Simple hex convert0r :> RISK 0wns! \n" .asciiz "- Enter decimal Number: " string: .asciiz "- Hexadecimal is " ## - EOF - # The Electronic Souls Crew [ElectronicSouls] (c) 2002 "Narwhales are lost at sea." -----BEGIN PGP SIGNATURE----- Version: Hush 2.2 (Java) Note: This signature can be verified at https://www.hushtools.com/verify wlMEARECABMFAj3no6IMHGVzQGh1c2guY29tAAoJEN5nGqhGcjlthAYAoJf9Kwd8bWnW LRYeyCiObWapn2doAKC++9HQ0loH4pZW5NmnoONUA05ugQ== =zT7v -----END PGP SIGNATURE----- Concerned about your privacy? Follow this link to get FREE encrypted email: https://www.hushmail.com/?l=2 Big $$$ to be made with the HushMail Affiliate Program: https://www.hushmail.com/about.php?subloc=affiliate&l=427 _______________________________________________ Full-Disclosure - We believe in it. Charter: http://lists.netsys.com/full-disclosure-charter.html
Current thread:
- [ElectronicSouls] - RISK Assembly es (Nov 29)