content
stringlengths
23
1.05M
SECTION code_clib SECTION code_fp_math32 PUBLIC __dtoa_sgnabs EXTERN m32__dtoa_sgnabs ; enter : x = dehl' = floating point number ; ; exit : dehl' = |x| ; a = sgn(x) = 1 if negative, 0 otherwise ; ; uses : af DEFC __dtoa_sgnabs = m32__dtoa_sgnabs ; enter stack = ret ...
clc lda {c1} adc #<{c2} sta {c1} lda {c1}+1 adc #>{c2} sta {c1}+1
.thumb .org 0x0 @r4=attacker or defender data in battle struct mov r0,#0x4C mov r7,#0x14 ldr r0,[r4,r0] mov r5,#0x2 tst r5,r0 beq IsStr cmp r0,#0x40 bge IsStr mov r7,#0x3A IsStr: ldrb r7,[r6,r7] ldrh r0,[r4,#0xE] @current damage add r0,r0,r7 strh r0,[r4,#0xE] bx r14
;This is a verry shitty algorithm btw owo MOV Br, 0o10 ;load multiplier MOV Ix, 0o42 ;load multiplicand XOR Ac ;clears the accumulator CMP Ac, Ix ;Checks if multiplicand is 0 JMP end -z ;if so, end the program with Ac = 0 multLoop: ADD Br DEC Ix JMP multLoop -nz end: HLT ;stops the program, result is now in Ac
%ifdef CONFIG { "Match": "All", "RegData": { "RAX": "0xf" }, "MemoryRegions": { "0x100000000": "4096" } } %endif mov rdx, 0xe0000000 ; generate a lot of re-used constants mov dword[rdx], 0x0 mov dword[rdx], 0x1 mov dword[rdx], 0x2 mov dword[rdx], 0x3 mov dword[rdx], 0x4 mov dword[rdx], 0x5 mov dword...
;------------------------------------------------------------------------------- ; ; WinRoll 2.0 - WinRoll easily manages multiple open windows. ; Copyright (C) 2003-2004 Wil Palma <wilpalma@hotmail.com> ; ; This software is provided 'as-is', without any express or implied ; warranty. In no event will the authors ...
Name: z00_mpd3.asm Type: file Size: 5855 Last-Modified: '2016-05-13T04:36:32Z' SHA-1: AEAAA6FD629CBEC41C17C3A948CC3992037A6286 Description: null
; void ba_stack_destroy(ba_stack_t *s) SECTION code_adt_ba_stack PUBLIC _ba_stack_destroy EXTERN _b_array_destroy defc _ba_stack_destroy = _b_array_destroy
; Locate code in this address .org E000h ; Set a LED patron MVI A,AAh ; Call the subrutines BUCLE: CALL LED CALL DELAY JMP BUCLE ; Locate subrutines in this address .org C0DEh ; Create LED subrutine LED: ; Switch the lights LEDs XRI FFh OUT 00h RET ; One second delay DELAY: PUSH B MVI B,4BH L1: M...
%define Count 3 %define SYS_write 0x2000004 %define SYS_exit 0x2000001 %define STDOUT 1 global _main ; Entry point section .data msg: db "Hello, world!", 10 .len: equ $ - msg section .text _main: call loop call exit ret loop: xor r15, r15 ; Set zero value .loop_body: inc r15 ...
nop foo: nop nop .bar: nop baz5: nop nop nop
Name: w-select-e.asm Type: file Size: 25167 Last-Modified: '1992-11-18T01:42:36Z' SHA-1: CCD6F4B2D6DF7A560ADCDEE8BCE11A3C9A6CE009 Description: null
; =============================================================== ; 2014 ; =============================================================== ; ; void zx_cls_wc(struct r_Rect8 *r, uchar attr) ; ; Clear the rectangular area on screen. ; ; =============================================================== SECTION code_clib ...
page ,132 title RomDrive initialization module (disposable) .xlist include version.inc ; <jrcb> include biosseg.inc include msgroup.inc .list assume cs:datagrp ; INIT PACKET OFFSETS INIT_NUM EQU BYTE PTR (13) + 0 INIT_BREAK EQU DWORD PTR (13) + 1 INIT_BPB EQU DWORD PTR (13) + 5 INIT_DOSDEV EQU BYTE PTR (13) ...
.386 .model flat,C PUBLIC bioscom .code bioscom proc near sub eax,eax mov ah,[esp+4] mov al,[esp+8] mov edx,[esp+12] int 14h ret bioscom endp end
-- HUMAN RESOURCE MACHINE PROGRAM -- a: COPYFROM 9 COPYTO 3 INBOX COPYTO 0 INBOX COPYTO 1 COMMENT 0 b: COPYFROM 0 SUB 1 JUMPN c COPYTO 0 BUMPUP 3 JUMP b c: COPYFROM 3 OUTBOX JUMP a DEFINE COMMENT 0 eJwzZWBgaBfN02sXVfJJ...
.MODEL small .STACK .DATA n db 4h num1 db 01h,02h,03h,04h num2 db 04h,03h,07h,09h sum db 00h .CODE .STARTUP mov cx, 00h mov cl,n clc add: mov al,num1[si] mov bl,num2[si] adc al,00h clc add al,bl mov sum[di],al inc si inc di loop add .EXIT END
# n! # caso base: n == 1 -> 1 # caso ricorsivo: n*(n-1)! .text .globl fattoriale fattoriale: #preambolo move $t0 $fp addi $fp $sp -4 sw $t0 0($fp) sw $sp -4($fp) sw $s0 -8($fp) sw $ra -12($fp) addi $sp $fp -12 #codice #$a0 == input move $s0 $a0 beq $a0 1 base addi $a0 $a0 -1 jal fattoriale ...
COMMENT @%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% Copyright (c) GeoWorks 1990 -- All Rights Reserved PROJECT: PC GEOS MODULE: Kernel Library FILE: Graphics/graphicsCreateBitmap.asm AUTHOR: Jim DeFrisco, 5/23/90 ROUTINES: Name Description ---- ----------- CreateBi...
;============================================================= ;=== FILE: ARTADDF32U.asm ;=== ;=== Copyright (c)1998 Metrowerks, Inc. All rights reserved. ;============================================================= ; Recommended tab stop = 8. ;=======================================================================...
;RaTol Symbolinen konekieli: Harjoitus 3, tehtävä 2 ;Tero Kukka IY96A ;Tiedosto: teht32.asm Versio 1.1 ;Luotu 5.4.1998 include a:makrot.txt ;Ohjelman kuvaus: ;Luetaan kaksi ascii-merkkiä (esim. '2' ja '9') ja muutetaan ;ne binääriksi AL:ään (esim. AL = ...
;***************************************************************************** ;*++ ;* Name : $RCSfile: fast.asm,v $ ;* Title : ;* ASM Author : Jim Page ;* Created : 20/04/94 ;* ;* Copyright : 1995-2022 Imagination Technologies (c) ;* License : MIT ;* ;* Description : Pentium optimised...
; green screen ; Turned this into generic fg/bg colour screen .fx_greenscreen_fg EQUB 144+2 .fx_greenscreen_bg EQUB 0 .fx_greenscreen_update { LDX #0 LDA fx_greenscreen_bg BEQ no_bg jsr mode7_set_column_shadow_fast INX LDA #MODE7_new_bg jsr mode7_set_column_shadow_fast INX .no_bg LDA fx_greenscreen_fg B...
song331restored_pri equ 100 song331restored_rev equ 0 song331restored_mvl equ 127 song331restored_key equ 0 song331restored_tbs equ 1 song331restored_exg equ 0 song331restored_cmp equ 1 .align 4 ;**************** Track 1 (Midi-Chn.7) ****************; @song331restored_1: .byte KEYSH , song331restored_key...
org 0x100 %include "defaults_common.asm" %macro outputCharacter 0 call doPrintCharacter %endmacro %macro outputHex 0 call doPrintHex %endMacro %macro outputString 0 call doPrintString %endMacro %macro complete 0 xor ax,ax int 0x21 %endmacro jmp main doPrintCharacter: push ax push bx push cx pu...
; load DH sectors to ES:BX from drive DL disk_load: push dx mov ah , 0x02 ; BIOS read sector function mov al , dh ; Read DH sectors mov ch , 0x00 ; Select cylinder 0 mov dh , 0x00 ; Select head 0 mov cl , 0x02 ; Start reading from second sector int 0x13 ; BIOS interrupt jc disk_error ; Jump if error...
Name: yst_en_edit.asm Type: file Size: 37695 Last-Modified: '2016-05-13T04:52:55Z' SHA-1: 065AE3AC49D76186FE2ADA375EB878E889F58DC0 Description: null
; ; $Id: 0x18.asm,v 1.1.1.1 2016/03/27 08:40:12 raptor Exp $ ; ; 0x18 explanation - from xchg rax,rax by xorpd@xorpd.net ; Copyright (c) 2016 Marco Ivaldi <raptor@0xdeadbeef.info> ; ; This snippet introduces the rdtsc instruction, which ; loads the current value of the processor's timestamp ; counter (a 64-bit Machine ...
db "LEAF@" ; species name db "The scent that" next "wafts from the" next "leaves on its neck" page "causes anyone who" next "smells it to" next "become energetic.@"
;Testname=bin; Arguments=-fbin -o_file_.bin; Files=stdout stderr _file_.bin db __FILE__, `\r\n` db __FILE__, `\r\n` dw __LINE__ dw __LINE__
SECTION code_clib PUBLIC generic_console_cls PUBLIC generic_console_vpeek PUBLIC generic_console_printc PUBLIC generic_console_scrollup PUBLIC generic_console_ioctl PUBLIC generic_console_set_ink PUBLIC generic_console_set_paper PUBL...
;; Code for installing/uninstalling the TSR %include "macros.asm" %include "string.asm" ;------------------------------------------------------------------------------- ; Constants ;------------------------------------------------------------------------------- ; The install/uninstall routines need a way to tell our ...
; prints text for bookshelves in buildings without sign events PrintBookshelfText:: ld a, [wSpritePlayerStateData1FacingDirection] cp SPRITE_FACING_UP jr nz, .noMatch ; facing up ld a, [wCurMapTileset] ld b, a lda_coord 8, 7 ld c, a ld hl, BookshelfTileIDs .loop ld a, [hli] cp $ff jr z, .noMatch cp b jr nz...
SECTION code_fp_math32 PUBLIC l_f32_lt EXTERN m32_compare_callee l_f32_lt: call m32_compare_callee ret C dec hl ret
Name: runed2.asm Type: file Size: 19055 Last-Modified: '1992-11-18T01:42:32Z' SHA-1: D8069438A5423D5A97FD3E594E505B155D12855F Description: null
; int wv_stack_shrink_to_fit_fastcall(wv_stack_t *s) SECTION code_clib SECTION code_adt_wv_stack PUBLIC _wv_stack_shrink_to_fit_fastcall EXTERN asm_wv_stack_shrink_to_fit defc _wv_stack_shrink_to_fit_fastcall = asm_wv_stack_shrink_to_fit
global kbd_intr extern reset_intr_pic1 extern reset_intr_pic2 extern kbd_key kbd_intr: pushad xor eax, eax in al, 0x60 push eax call kbd_key add esp, 4 call reset_intr_pic1 call reset_intr_pic2 popad iret
; ; Amstrad CPC Stdio ; ; getkey() Wait for keypress ; ; Stefano Bodrato - 8/6/2001 ; ; ; $Id: fgetc_cons.asm,v 1.3 2007/07/21 21:28:22 dom Exp $ ; XLIB fgetc_cons INCLUDE "#cpcfirm.def" .fgetc_cons call firmware defw km_wait_char ld h,0 ...
; @file ; Copyright (C) 2013 Intel Corporation. All rights reserved. ; Copyright (C) 2021, ISP RAS. All rights reserved. ; ; This program and the accompanying materials ; are licensed and made available under the terms and conditions of the BSD License ; which accompanies this distribution. The full text of the licens...
; ; ; ZX Maths Routines ; ; 9/12/02 - Stefano Bodrato ; ; $Id: fmod.asm,v 1.1 2003/03/24 09:17:40 stefano Exp $ ; ;double fmod(n,m) ;Number in FA.. IF FORzx INCLUDE "#zxfp.def" ELSE INCLUDE "#81fp.def" ENDIF XLIB fmod LIB fsetup LIB stkequ...
;--------------------------------------------------------- ; ; LDOS (Leonard Demo Operating System) ; AMIGA version ; Written by Leonard/Oxygene ; https://github.com/arnaud-carre/ldos ; ; debug_screen ; ;--------------------------------------------------------- High = 256 Width = 320 DiwStartyv = 172-High/2 DiwS...
seq r1, r2, r3 ; move 1 into R1 seq r2, r2, r3 ; move 1 into R2 add r2, r1, r2 ; R2 = 1 + 1 add r2, r1, r2 ; R2 = 1 + 2 add r2, r1, r2 ; R2 = 1 + 3 add r1, r1, r2 ; R1 = 1 + 4 = 5 add r2, r1, r2 ; R2 = 4 + 5 = 9 xor r1, r1, r2 xor r2, r2, r1 xor r1, r1, r2 ; now R1 contains 9, R2 contains 5
; ********************************************************** ; Exemplo de Multiplicação ; ********************************************************** SECTION .data var1: db 10H ; 16 var2: db 0xFF ; (-1) SECTION .text ; code section global _start _start: mov ax,[var1] mov bx,[var2] imul bx ; 16 * (-1) = -1...
;;; ; Creates a new pixel colour buffer of the specified width and height ; You must free() the memory when you dont use the buffer anymore ; ; params: ; width - The width of the buffer ; height - The height of the buffer ; ; returns: (QWORD) A pointer to the created buffer ;;; proc BufferCreate, width:...
meuBinario: file format elf64-x86-64 Disassembly of section .init: 00000000000004b8 <_init>: 4b8: 48 83 ec 08 sub rsp,0x8 4bc: 48 8b 05 25 0b 20 00 mov rax,QWORD PTR [rip+0x200b25] # 200fe8 <__gmon_start__> 4c3: 48 85 c0 test rax,rax 4c6: 74 02 je 4...
D7_Header: sHeaderInit ; Z80 offset is $DE73 sHeaderPatch D7_Patches sHeaderTick $01 sHeaderCh $02 sHeaderSFX $80, $05, D7_FM5, $90, $00 sHeaderSFX $80, $C0, D7_PSG3, $00, $00 D7_FM5: sPatFM $00 ssModZ80 $01, $01, $C5, $1A dc.b nF7, $07 sStop D7_PSG3: sVolEnvPSG v07 dc.b nRst, $07 ssModZ80 $01, $02...
Name: bank2.asm Type: file Size: 2219 Last-Modified: '1993-01-07T04:42:26Z' SHA-1: BC67CE6711B230F92118E53AC28B2DBA1C2EA7FB Description: null
@ --------------------------------------------------- @ @ Raspberry Pi Assembly GAME#1 by KJ/P1X @ @ http://p1x.in | http://krzysztofjankowski.com @ https://github.com/w84death/arm-assembly @ @ --------------------------------------------------- .arm .include "globals.asm" .data clear_screen: .ascii "\033c" ...
test START 0 EXTDEF foo foo EQU 1 * 2 * 3 * 4 + 500 . error: exported symbol must be relative END test
L1: EQU 1 L2: EQU 0 L: EQU 4 L3: CONST -4 SECTION TEXT IF L1 LOAD SPACE ;faz esta opera ̧c~ao se L1 for verdadeiro IF L2 INPUT SPACE ;faz esta opera ̧c~ao se L2 for verdadeiro SECTION DATA N: SPACE
Route14Object: db $43 ; border block db $0 ; warps db $1 ; signs db $d, $11, $b ; Route14Text11 db $a ; objects object SPRITE_ROCKER, $4, $4, STAY, DOWN, $1, OPP_BIRD_KEEPER, $8 object SPRITE_ROCKER, $f, $6, STAY, DOWN, $2, OPP_BIRD_KEEPER, $9 object SPRITE_ROCKER, $c, $b, STAY, DOWN, $3, OPP_BIRD_KEEPER, $6...
%if 0 SNEeSe, an Open Source Super NES emulator. Copyright (c) 1998-2015, Charles Bilyue. Portions copyright (c) 1998-2003, Brad Martin. Portions copyright (c) 2003-2004, Daniel Horchner. Portions copyright (c) 2004-2005, Nach. ( http://nsrt.edgeemu.com/ ) Unzip Technology, copyright (c) 1998 Gilles Vollant. zlib Te...
;count number of spaces in a string section .data msg1 : db 'Enter string : ' l1 : equ $-msg1 msg2 : db 'Number of spaces in the string is ' l2 : equ $-msg2 newline : db 10 section .bss string : resb 50 temp : resb 1 strlen : resb 1 space_count : resb 1 section .text global _start: _start: mov eax, 4 mov ebx,...
; A202169: Size of maximal independent set in graph S_3(n). ; Submitted by Jamie Morken(s2) ; 1,3,4,6,7,10,12,15,19,22 add $0,1 pow $0,2 mov $1,2 mod $1,$0 add $0,4 div $0,5 add $0,$1
-- 7 Billion Humans (2087) -- -- 10: Emergency Escapades -- -- Author: landfillbaby -- Size: 28 -- Speed: 16 step w step w a: b: step w if c != 1 and s != wall: jump b endif if s == wall: step nw jump a endif if nw != hole: step nw jump c endif if w != hole: step w jump d endif step sw d: c: step sw step s st...
# (C) by Piotr Woźniak # Cieniowanie trójkąta .data intro: .ascii "Cieniowanie trojkata algorytmem Gourauda\n" .asciiz "Wprowadz dane dla 3 wierzcholkow:\n" un: .asciiz "1.\n" deux: .asciiz "2.\n" trois: .asciiz "3.\n" out1: .asciiz "Wprowadz wspolrzedne wierzcholka\nX: " out2: .asciiz "Y: " out3: .asciiz "Wpr...
global bar global foo section .bar bar: dd foo-$ dd baz-$ call foo call baz foo: section .data baz: dd foo-$ ;dd $-foo ; illegal dd baz-$ dd $-baz dd foo+4-$ ; with constant dd $-baz+foo+4-$ ; both local and cross-segment (legal) dd baz+foo+4-$-$ ; ditto, slightly different ;dd (bar-$)+(foo-$) ; illegal (too many cr...
parameter "_OutCoord", float2, f0.rg, in texture "wave0", t0 parameter "result", float4, f1, out parameter "scale", float2, f0.ba, in parameter "c", float2, f2.rg, in ;---------------------------------------------------------- texn f1, f0.rg, t0 mul f0.rg, f0.ba set f3.r, 2 sub f0.rg, ...
; ; Paging ; ; load.asm ; [bits 16] ; Define load_sectors ; Sector start point in bx ; Number of sectors to read in cx ; Destination address in dx load_bios: ; Save the registers push ax push bx push cx push dx ; Save the number of registers to load for later push cx ; For the ...
GLOBAL _mutexLock GLOBAL _mutexUnlock EXTERN _contextSwitchProcess section .text _mutexLock: mov rax, 1 xchg rax, [rdi] test rax, rax jz ok call _contextSwitchProcess jmp _mutexLock ok: ret _mutexUnlock: mov rax, 0 xchg rax, [rdi] ret
; Output handlers for the Lisp system. ; Temporarily a hack that uses the serial link, later using the LEM. :print_char ; (raw_char) -> set b, a ; Move the character into B. set a, 3 ; Transmit hwi [hw_serial] ifn c, 0 ; Error occurred brk 5 ret :print_lisp_str ; (str) -> pushX set x, a :print_lisp_str_loop ife x,...
; get the data to be printed in DX ; for e.g: DX=0x1234 will print 0x1234 HEX string print_hex: pusha mov cx, 0 ; our counter ; for ascii conversion add 0x30 for 0(0x30) - 9(0x39) chars ; for A - F add 0x40 for A (0x41) - to F (0x46) hex_loop: cmp cx, 4 ; loop four times je end mov ax, dx ; mov dx to ax ...
; Executable name : reverse-shell ; Designed OS : Linux (32-bit) ; Author : wetw0rk ; Version : 1.0 ; Created Following : SLAE ; Description : A linux/x86 reverse shell. Created by analysing msfvenom; ; The shellcode generated by msfvenom was 68 bytes, howe...
;SUM OF 8bit elements array MVI A,00H LXI H,2000H ;count(no of elements) in 2000 address MOV C,M zone:INX H ;from 2001 data is there ADD M MOV B,A DCR C JNZ zone STA 20C0H RST 1
prog 2 1 jmp $5 copy 0 3 copy 1 4 halt copy 3 2 jmpl $2 3 $3 dec 3 inc 4 jmp $6
LIST P = 16F84A #include "p16f84A.inc" __CONFIG _FOSC_XT & _WDTE_OFF & _PWRTE_ON & _CP_OFF ;******************************************************************************* ; INICIO DEL PROGRAMA ;******************************************************************************* ORG 0X00 GOTO START ;****************...
; ; ZX Spectrum specific routines ; by Stefano Bodrato, 14/09/2006 ; ; int zx_iss_stick(); ; ; The result is: ; - 1 (true) if the ISS Joystick interface is connected ; - 0 (false) otherwise ; ; $Id: zx_iss_stick.asm,v 1.2 2015/01/19 01:33:08 pauloscustodio Exp $ ; PUBLIC zx_iss_stick zx_iss_stick: ld hl,0 in a,(3...
; Exhaustive test of AVX instructions ; Also includes based-upon SSE instructions for comparison ; ; Copyright (C) 2008 Peter Johnson ; ; Redistribution and use in source and binary forms, with or without ; modification, are permitted provided that the following conditions ; are met: ; 1. Redistributions of source co...
; Set File Information V1.01  1989 Tony Tebby QJUMP ; ; 2007-07-30 1.01 Show big file sizes in MB (MK) section gen_util xdef gu_flinf xdef gu_flinm xref gu_prlis xref cv_d1asc include 'dev8_keys_qlv' include 'dev8_keys_fll' include 'dev8_mac_assert' ;--- ; Sets the minumum file information for the ...
.text # .align 2 # MARS doesn't like this .globl main main: subu $sp, $sp, 40 # stack push, 40 bytes sw $ra, 20($sp) # save return address register (sw = store word) sd $a0, 32($sp) # save registers $a0, $a1 (sd = store doubleword) sw $0, 24($sp) # sum = 0 sw $0, 28($sp) # i = 0 loop: lw $t6, ...
include "../../../src/common/struct.inc" include "../../../src/common/assert.inc" namespace Base { basestruct() struct_maxsize(12) field(a, 5) endstruct() } namespace Child1 { childstruct(Base) field(b, 5) endstruct() } namespace Child2 { childstruct(Base) field(b, 10...
SECTION code_driver PUBLIC _asci1_putc EXTERN asm_asci1_putc defc _asci1_putc = asm_asci1_putc EXTERN asm_asci1_need defc NEED = asm_asci1_need
; Program 01 - Addition of two word-numbers ; Written by Hamidreza Hosseinkhani (hosseinkhani@live.com) ; June, 2011 TITLE Addition of two word-numbers StkSeg SEGMENT para stack 'stack' DB 64 DUP (?) StkSeg ENDS DtaSeg SEGMENT para private 'data' Num1 DW 00EFEh Num2 DW 0CDCDh ORG 000Ah Sum DW ...
BITS 32 global _start _start: xor ecx,ecx imul ecx push ecx add al, 0xb jmp short _two _one: pop esi mov edi, esi pushad mov cl, 0x8 _mangle: mov al, [esi] ror al, 0x2 stosb inc esi loop _mangle popad xchg esp,esi xchg ebx,esp int 0x80 _two: call _one dq 0xa1cdbcbcb9a589bc
%ifidn __OUTPUT_FORMAT__,obj section code use32 class=code align=64 %elifidn __OUTPUT_FORMAT__,win32 $@feat.00 equ 1 section .text code align=64 %else section .text code %endif ;extern _OPENSSL_ia32cap_P align 64 global _poly1305_init align 16 _poly1305_init: L$_poly1305_init_begin: push ebp push ebx ...
;=============================================================================== ; Copyright 2014-2019 Intel Corporation ; All Rights Reserved. ; ; If this software was obtained under the Intel Simplified Software License, ; the following terms apply: ; ; The source code, information and material ("Material") co...
; x00 .ORIG x0001 .FILL 612 ; x01 .END
; ***************************************************************************** ; ***************************************************************************** ; ; Name: input.asm ; Purpose: Input string/integer ; Created: 12th March 2020 ; Reviewed: 17th March 2020 ; Author: Paul Robson (paul@robsons.org.uk) ;...
; we use 32 register bytes as scratch ; so r11-r18 .asg r11, scratch .asg r26, gpio0_mask .asg r27, gpio1_mask .asg r28, gpio2_mask .asg r29, gpio3_mask ; 0 .asg 2, c0_gpio ; the gpio bank we output to .asg gpio2_mask, c0_gpio_mask ;the gpio mask we intoract with .asg 3, c0_pin ; our output bit...
t IS $255 LOC Data_Segment GREG @ String BYTE "Fuck You Github",#a,0 LOC #100 Main LDA t,String TRAP 0,Fputs,StdOut TRAP 0,Halt,0
; functions section .text GLOBAL io_hlt, io_cli, io_sti GLOBAL io_in8, io_in16, io_in32 GLOBAL io_out8, io_out16, io_out32 GLOBAL io_load_eflags, io_store_eflags GLOBAL load_gdtr, load_idtr GLOBAL asm_interrupt21, asm_interrupt2c io_hlt: ; void io_hlt(void); HLT RET io_cli: ; ...
.text .globl MAIN MAIN: #set n-1 li $a0, 4 #set i li $a1, 1 # clear v1 li $v1, 0 #call SUM jal SUM #exit program li $v0, 10 syscall SUM: #setup return stack addi $sp, $sp, -4 sw $ra, 0($sp) #multiply a1 by a1 mul $t0, $a1, $a1 #add result to $v1 add $v1, $v1, $t0 #add 1 to i addi $a1, $a1, 1 #if ...
;############################################### ; ; Copyright 2018-2019 0x8BitDev ( MIT license ) ; ;############################################### ; ; Simple character controller ; .segment "ZP" ; character controller variables _player_pos_x: .res 1 _player_pos_y: .res 1 _player_jump_max_height...
SFX_Pokedex_Rating_3_Ch4: executemusic tempo 256 volume 7, 7 duty 2 notetype 5, 11, 1 octave 3 A_ 2 A_ 2 G_ 2 G_ 2 F_ 2 E_ 2 F_ 2 A_ 2 octave 4 C_ 4 E_ 4 octave 3 F_ 4 endchannel SFX_Pokedex_Rating_3_Ch5: executemusic duty 2 notetype 5, 12, 2 octave 5 F_ 2 E_ 1 rest 1 D_ 2 C_ 1 rest 1 o...
.MODEL SMALL .STACK 100H .DATA MSG1 DB 'ENTER A STRING OF CAPITAL LETTERS:',0AH,'$' MSG2 DB 'THE LONGEST CONSECUTIVELY INCREASING STRING IS:',0AH,'$' NOW DB 0 I DB 0 ; to count the segment length J DB 0 ; help to store initial position of segments MAX DB 0 ; store the maximum length of the result INIT DB 0 ; store ...
; ARJ mode4 decode function ; Size optimized ; Placed in public domain 1993-2007 Hans Wessels (Mr Ni! (the Great) of the TOS-crew) ; ; void decode_m4(unsigned short origsize, char* depack_space, char* packed_data) ; CALL: ; D0 = origsize (short) ; A0 = ptr to depack space ; A1 = ptr to packed data ; ; Register usage: ;...
code proc PlayerIcon 80 20 ADDRLP4 4 ARGP4 ADDRFP4 0 INDIRP4 ARGP4 CNSTI4 64 ARGI4 ADDRGP4 Q_strncpyz CALLV pop ADDRLP4 4 ARGP4 CNSTI4 47 ARGI4 ADDRLP4 68 ADDRGP4 qk_strrchr CALLP4 ASGNP4 ADDRLP4 0 ADDRLP4 68 INDIRP4 ASGNP4 ADDRLP4 0 INDIRP4 CVPU4 4 CNSTU4 0 EQU4 $70 ADDRLP4 72 ADDRLP4 0 INDIRP4 ASGNP4 ADDRLP4 0 ADDRLP...
;/* himem.asm ; * ; * Microsoft Confidential ; * Copyright (C) Microsoft Corporation 1988-1991 ; * All Rights Reserved. ; * ; * Modification History ; * ; * Sudeepb 14-May-1991 Ported for NT XMS support ; * ; * williamh 25-Sept-1992 Added RequestUMB and ReleaseUMB ; */ page 95,160 title 'HIMEM.SYS ...
/* Copyright (c) 2019 SChernykh This file is part of RandomX OpenCL. RandomX OpenCL is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. Random...
JSR device_discovery ; find clock SET A, 0xb402 SET B, 0x12d0 SET C, clock_index JSR find_device ; set up clock SET B, 60 ; tick once per second SET A, 0 HWI [clock_index] ; turn on clock ; find SPED3 index SET A, 0xbf3c SET B, 0x42ba SET C, sped3_index JSR find_device ; poll SPEC3 device SET A, 0 HWI ...
bits 32 section .text global isr00,isr01,isr02,isr03,isr04,isr05,isr06,isr07,isr08,isr09 global isr10,isr11,isr12,isr13,isr14,isr15,isr16,isr17,isr18,isr19 global isr20,isr21,isr22,isr23,isr24,isr25,isr26,isr27,isr28,isr29 global isr30,isr31 extern fault_exception isr_jmp: pushad push ds push es push fs push gs ...
MtSilverCaveObject: db $19 ; border block db $2 ; warps db $5, $5, $0, MT_SILVER db $1f, $25, $0, MT_SILVER db $0 ; signs db $2 ; objects object SPRITE_BUG_CATCHER,$1e, $1b, STAY, RIGHT, $1, OPP_BUG_CATCHER, $8 object SPRITE_OAK, $21, $3, STAY, DOWN, $2, OPP_PROF_OAK, $3 ;object SPRITE_BALL, $1e, $1c, STAY...
;; Licensed to the .NET Foundation under one or more agreements. ;; The .NET Foundation licenses this file to you under the MIT license. ;; ;; Define the helpers used to implement the write barrier required when writing an object reference into a ;; location residing on the GC heap. Such write barriers allow the GC to...
LXI H,0070H LXI B,0070H MVI D,04H LOOP: MOV A,M MOV E,A INX H MOV A,M SUB E STAX B INX B INX H DCR D JNZ LOOP hlt
SECTION rodata_clib PUBLIC keys_cursor PUBLIC keys_qaop PUBLIC keys_vi PUBLIC keys_8246 keys_cursor: defw $0243, $1043, $2042, $0442, $1006, $0000 keys_qaop: defw $0801, $0202, $2006, $0807, $0802, $1002, $0000 keys_vi: defw $1001, $1003, $2002, $0402, $0406, $1005, $0000 keys_8246: defw $0104, $0405, $01...
bits 16 global disk_read_sec global disk_write_sec extern BOOT_DRIVE_NUMBER disk_read_sec: push bp mov bp, sp mov ah, 0x02 mov al, [bp + 14] mov ch, 0 mov cl, [bp + 10] mov dh, 0 mov dl, [BOOT_DRIVE_NUMBER] mov bx, [bp + 6] int 0x13 mov sp, bp pop bp ret disk_write_sec: push b...
; This table translates key presses into ascii codes. ; Also used by 'GetKey' and 'LookupKey'. An effort has been made for ; this key translation table to emulate a PC keyboard with the 'CTRL' key SECTION rodata_clib PUBLIC in_keytranstbl .in_keytranstbl ; Each table 64 bytes ;Unshifted defb 255, 255, 255, 255,...
// This file is part of www.nand2tetris.org // and the book "The Elements of Computing Systems" // by Nisan and Schocken, MIT Press. // File name: projects/04/Fill.asm // Runs an infinite loop that listens to the keyboard input. // When a key is pressed (any key), the program blackens the screen, // i.e. writes...
;invalid instructions, should not be highlighted cwdqo fbst fcmovnbu fiaddp/fisubp cmovnpo/cmovpos fucomipp fidivp/fidivrp ficomip/ficompp fimulp fisubp/fisubrp paddub/padduw cvtsi2pi/cvtps2ps/cvtsi2si/cvtpi2pi/cvtss2ss/cvtss2ps/cvtss2pi/cvtpi2ss cvttsi2si/cvttps2ps/cvttpi2pi cvttdq2ps pmovsxww vmovbe vmovdq2q/vmovq2dq...
SECTION code_clib SECTION code_l_sccz80 PUBLIC l_cm_bc .l_cm_bc ld a,b or a ret P cpl ld b,a ld a,c cpl ld c,a inc bc ret