code stringlengths 2 1.05M | repo_name stringlengths 5 101 | path stringlengths 4 991 | language stringclasses 3 values | license stringclasses 5 values | size int64 2 1.05M |
|---|---|---|---|---|---|
list p=18f4550
#include <p18f4550.inc>
;Zona de los bits de configuración (falta)
CONFIG FOSC = XT_XT ; Oscillator Selection bits (XT oscillator (XT))
CONFIG PWRT = ON ; Power-up Timer Enable bit (PWRT enabled)
CONFIG BOR = OFF ; Brown-out Reset Enable bits (Brown-out Reset disabled in hardware and software)
CONFIG WDT = OFF ; Watchdog Timer Enable bit (WDT disabled (control is placed on the SWDTEN bit))
CONFIG PBADEN = OFF ; PORTB A/D Enable bit (PORTB<4:0> pins are configured as digital I/O on Reset)
CONFIG LVP = OFF ; Single-Supply ICSP Enable bit (Single-Supply ICSP disabled)
CONFIG CCP2MX = ON ; CCP2 MUX bit (CCP2 input/output is multiplexed with RC1)
CONFIG MCLRE = ON ; MCLR Pin Enable bit (MCLR pin enabled; RE3 input pin disabled)
variable_i EQU 0x060
variable_j EQU 0x061
variable_k EQU 0x062
org 0x0000 ;Vector de RESET
goto configuro
org 0x0020
configuro:
bcf TRISB, 3 ;Puerto RB3 como salida
inicio:
bsf LATB, 3 ;Encendemos el LED conectado en RB3
call retrasados ;Instrucción de "no operación"
bcf LATB, 3 ;Apagamos el LED conectado en RB3
call retrasados
goto inicio
retrasados:
movlw .100 ; 0x20 d'100' b'00100000'
movwf variable_i
otro1: call bucle1
decfsz variable_i, 1
goto otro1
return
bucle1: movlw .100
movwf variable_j
otro2: call bucle2
decfsz variable_j, 1
goto otro2
return
bucle2: movlw .10
movwf variable_k
otro3: decfsz variable_k, 1
goto otro3
return
end | tocache/picomones | UPC Microcontroladores 2018-2/Semana 02/20182_prendeapaga2.X/cincocincocinco.asm | Assembly | cc0-1.0 | 1,685 |
Map_6820C: dc.w word_68226-Map_6820C
dc.w word_6822E-Map_6820C
dc.w word_68236-Map_6820C
dc.w word_68244-Map_6820C
dc.w word_6824C-Map_6820C
dc.w word_68254-Map_6820C
dc.w word_6829E-Map_6820C
dc.w word_682A6-Map_6820C
dc.w word_682C0-Map_6820C
dc.w word_682F2-Map_6820C
dc.w word_68306-Map_6820C
dc.w word_68332-Map_6820C
dc.w word_68358-Map_6820C
word_68226: dc.w 1 ; DATA XREF: ROM:0006820Co
dc.b $F8, $D, 0, 0, $FF, $F0
word_6822E: dc.w 1 ; DATA XREF: ROM:0006820Co
dc.b $F8, $D, 0, 8, $FF, $F0
word_68236: dc.w 2 ; DATA XREF: ROM:0006820Co
dc.b $F8, $D, 0, $10, $FF, $EC
dc.b $F8, 1, 0, $18, 0, $C
word_68244: dc.w 1 ; DATA XREF: ROM:0006820Co
dc.b $F8, $D, 0, $1A, $FF, $F0
word_6824C: dc.w 1 ; DATA XREF: ROM:0006820Co
dc.b $F8, 5, 0, $4E, 0, 0
word_68254: dc.w $C ; DATA XREF: ROM:0006820Co
dc.b $EC, $C, 0, $22, $FF, $E4
dc.b $EC, 8, 0, $26, 0, 4
dc.b $F4, $E, 0, $29, $FF, $E4
dc.b $F4, $A, 0, $35, 0, 4
dc.b $C, 8, 0, $3E, $FF, $EC
dc.b $C, 4, 0, $41, 0, 4
dc.b $D4, 5, 0, $43, $FF, $F0
dc.b $DC, 1, 0, $47, $FF, $E8
dc.b $D4, 5, 8, $43, 0, 0
dc.b $DC, 1, 8, $47, 0, $10
dc.b $DA, 0, 0, $4B, $FF, $FE
dc.b $E4, 4, 0, $49, $FF, $EC
word_6829E: dc.w 1 ; DATA XREF: ROM:0006820Co
dc.b $FC, 4, 0, $4C, $FF, $F8
word_682A6: dc.w 4 ; DATA XREF: ROM:0006820Co
dc.b $F4, 5, 0, $43, $FF, $F0
dc.b $FC, 1, 0, $47, $FF, $E8
dc.b $F4, 5, 8, $43, 0, 0
dc.b $FC, 1, 8, $47, 0, $10
word_682C0: dc.w 8 ; DATA XREF: ROM:0006820Co
dc.b $EC, $C, 0, $22, $FF, $E4
dc.b $EC, 8, 0, $26, 0, 4
dc.b $D4, 5, 0, $43, $FF, $F0
dc.b $DC, 1, 0, $47, $FF, $E8
dc.b $D4, 5, 8, $43, 0, 0
dc.b $DC, 1, 8, $47, 0, $10
dc.b $DA, 0, 0, $4B, $FF, $FE
dc.b $E4, 4, 0, $49, $FF, $EC
word_682F2: dc.w 3 ; DATA XREF: ROM:0006820Co
dc.b $EC, $C, 0, $22, $FF, $E4
dc.b $EC, 8, 0, $26, 0, 4
dc.b $E4, 4, 0, $49, $FF, $EC
word_68306: dc.w 7 ; DATA XREF: ROM:0006820Co
dc.b $EC, $C, 0, $22, $FF, $E4
dc.b $EC, 8, 0, $26, 0, 4
dc.b $F4, $E, 0, $29, $FF, $E4
dc.b $F4, $A, 0, $35, 0, 4
dc.b $C, 8, 0, $3E, $FF, $EC
dc.b $C, 4, 0, $41, 0, 4
dc.b $E4, 4, 0, $49, $FF, $EC
word_68332: dc.w 6 ; DATA XREF: ROM:0006820Co
dc.b $EC, $C, 0, $22, $FF, $E4
dc.b $EC, 8, 0, $26, 0, 4
dc.b $D4, 5, 0, $43, $FF, $F0
dc.b $DC, 1, 0, $47, $FF, $E8
dc.b $D4, 5, 8, $43, 0, 0
dc.b $DC, 1, 8, $47, 0, $10
word_68358: dc.w 6 ; DATA XREF: ROM:0006820Co
dc.b $D4, 5, 0, $43, $FF, $F0
dc.b $DC, 1, 0, $47, $FF, $E8
dc.b $D4, 5, 8, $43, 0, 0
dc.b $DC, 1, 8, $47, 0, $10
dc.b $DA, 0, 0, $4B, $FF, $FE
dc.b $E4, 4, 0, $49, $FF, $EC
| TeamASM-Blur/Sonic-3-Blue-Balls-Edition | Working Disassembly/General/Sprites/Robotnik/Map - Robotnik Ship.asm | Assembly | apache-2.0 | 2,957 |
/*
LD/ST C の テストプログラム
*/
start:
// 4バイト store したものを 1, 2, 4 バイト load するテスト
LD C, $deadbeef
ST C, [0]
LD C, [0]O
CMP C, $ef
JNE test-failed
LD C, [0]H
CMP C, $beef
JNE test-failed
LD C, [0]
CMP C, $deadbeef
JNE test-failed
// 2バイト store したものを 1, 2, 4 バイト load するテスト
LD C, $abcd
ST C, [0]H
LD C, [0]O
CMP C, $cd
JNE test-failed
LD C, [0]H
CMP C, $abcd
JNE test-failed
LD C, [0]
CMP C, $deadabcd
JNE test-failed
// 1バイト store したものを 1, 2, 4 バイト load するテスト
LD C, $10
ST C, [0]O
LD C, [0]O
CMP C, $10
JNE test-failed
LD C, [0]H
CMP C, $ab10
JNE test-failed
LD C, [0]
CMP C, $deadab10
JNE test-failed
// レジスタからのload
LD A, $A001
LD B, $B001
LD D, $D001
LD C, A
CMP C, $A001
JNE test-failed
LD C, B
CMP C, $B001
JNE test-failed
LD C, D
CMP C, $D001
JNE test-failed
// レジスタ指定アドレスからのload
LD A, $12345678
ST A, [0]
LD A, $90abcdef
ST A, [4]
LD A, 4
LD C, [A]O
CMP C, $ef
JNE test-failed
LD C, [A]H
CMP C, $cdef
JNE test-failed
LD C, [A]
CMP C, $90abcdef
JNE test-failed
LD B, 4
LD C, [B]O
CMP C, $ef
JNE test-failed
LD C, [B]H
CMP C, $cdef
JNE test-failed
LD C, [B]
CMP C, $90abcdef
JNE test-failed
LD C, 4
LD C, [C]O
CMP C, $ef
JNE test-failed
LD C, 4
LD C, [C]H
CMP C, $cdef
JNE test-failed
LD C, 4
LD C, [C]
CMP C, $90abcdef
JNE test-failed
LD D, 4
LD C, [D]O
CMP C, $ef
JNE test-failed
LD C, [D]H
CMP C, $cdef
JNE test-failed
LD C, [D]
CMP C, $90abcdef
JNE test-failed
// レジスタ指定アドレスへのstore
LD C, $55555555
ST C, [16]
LD C, 16
LD A, 16
ST C, [A]o
LD C, [16]
CMP C, $55555510
JNE test-failed
LD C, 16
LD A, 16
ST C, [A]h
LD C, [16]
CMP C, $55550010
JNE test-failed
LD C, 16
LD A, 16
ST C, [A]
LD C, [16]
CMP C, $00000010
JNE test-failed
LD C, $55555555
ST C, [16]
LD C, 16
LD B, 16
ST C, [B]o
LD C, [16]
CMP C, $55555510
JNE test-failed
LD C, 16
LD B, 16
ST C, [B]h
LD C, [16]
CMP C, $55550010
JNE test-failed
LD C, 16
LD B, 16
ST C, [B]
LD C, [16]
CMP C, $00000010
JNE test-failed
LD C, $55555555
ST C, [16]
LD C, 16
ST C, [C]o
LD C, [16]
CMP C, $55555510
JNE test-failed
LD C, 16
ST C, [C]h
LD C, [16]
CMP C, $55550010
JNE test-failed
LD C, 16
ST C, [C]
LD C, [16]
CMP C, $00000010
JNE test-failed
LD C, $55555555
ST C, [16]
LD C, 16
LD D, 16
ST C, [D]o
LD C, [16]
CMP C, $55555510
JNE test-failed
LD C, 16
LD D, 16
ST C, [D]h
LD C, [16]
CMP C, $55550010
JNE test-failed
LD C, 16
LD D, 16
ST C, [D]
LD C, [16]
CMP C, $00000010
JNE test-failed
LD D, 1
BRK
test-failed:
INT $00
LD D, -1
BRK
| suzukiplan/vgs-cpu | src/test/asm_ld_st_c.asm | Assembly | bsd-2-clause | 4,089 |
include 'a32.inc'
_start:
VM_CREATE_THREAD thread2, t_stack
VM_CREATE_THREAD thread3, t_stack
VM_CREATE_THREAD thread4, t_stack
thread1:
LOAD_R1 'A'
VM_CALL 0
JMPF thread1
thread2:
LOAD_R1 'B'
VM_CALL 0
JMPF thread2
thread3:
LOAD_R1 'C'
VM_CALL 0
JMPF thread3
thread4:
LOAD_R1 'D'
VM_CALL 0
JMPF thread4
t_stack:
DECLARE_STACK_SPACE 50 ; 50 bytes of cool stack
_end_start:
_data:
_end_data:
_bss:
_end_bss:
| Benderx2/FVM | examples/thread.asm | Assembly | bsd-2-clause | 423 |
.code
NtUserDefSetText PROC
mov r10, rcx
mov eax, 107Fh
syscall
ret
NtUserDefSetText ENDP
END | MortenSchenk/BHUSA2017 | tagWND_KASLR_1703/Syscall.asm | Assembly | mit | 108 |
nt!AuthzBasepRemoveSecurityAttributeFromLists:
fffff803`22141f74 4183cbff or r11d,0FFFFFFFFh
fffff803`22141f78 458ad0 mov r10b,r8b
fffff803`22141f7b 4584c9 test r9b,r9b
fffff803`22141f7e 7431 je nt!AuthzBasepRemoveSecurityAttributeFromLists+0x3d (fffff803`22141fb1)
nt!AuthzBasepRemoveSecurityAttributeFromLists+0xc:
fffff803`22141f80 8b4238 mov eax,dword ptr [rdx+38h]
fffff803`22141f83 a802 test al,2
fffff803`22141f85 742a je nt!AuthzBasepRemoveSecurityAttributeFromLists+0x3d (fffff803`22141fb1)
nt!AuthzBasepRemoveSecurityAttributeFromLists+0x13:
fffff803`22141f87 488d4210 lea rax,[rdx+10h]
fffff803`22141f8b 4c8b08 mov r9,qword ptr [rax]
fffff803`22141f8e 4c8b4008 mov r8,qword ptr [rax+8]
fffff803`22141f92 49394108 cmp qword ptr [r9+8],rax
fffff803`22141f96 754b jne nt!AuthzBasepRemoveSecurityAttributeFromLists+0x6f (fffff803`22141fe3)
nt!AuthzBasepRemoveSecurityAttributeFromLists+0x24:
fffff803`22141f98 493900 cmp qword ptr [r8],rax
fffff803`22141f9b 7546 jne nt!AuthzBasepRemoveSecurityAttributeFromLists+0x6f (fffff803`22141fe3)
nt!AuthzBasepRemoveSecurityAttributeFromLists+0x29:
fffff803`22141f9d 4d8908 mov qword ptr [r8],r9
fffff803`22141fa0 4d894108 mov qword ptr [r9+8],r8
fffff803`22141fa4 836238fd and dword ptr [rdx+38h],0FFFFFFFDh
fffff803`22141fa8 4885c9 test rcx,rcx
fffff803`22141fab 7404 je nt!AuthzBasepRemoveSecurityAttributeFromLists+0x3d (fffff803`22141fb1)
nt!AuthzBasepRemoveSecurityAttributeFromLists+0x39:
fffff803`22141fad 44015918 add dword ptr [rcx+18h],r11d
nt!AuthzBasepRemoveSecurityAttributeFromLists+0x3d:
fffff803`22141fb1 4584d2 test r10b,r10b
fffff803`22141fb4 742c je nt!AuthzBasepRemoveSecurityAttributeFromLists+0x6e (fffff803`22141fe2)
nt!AuthzBasepRemoveSecurityAttributeFromLists+0x42:
fffff803`22141fb6 8b4238 mov eax,dword ptr [rdx+38h]
fffff803`22141fb9 a801 test al,1
fffff803`22141fbb 7425 je nt!AuthzBasepRemoveSecurityAttributeFromLists+0x6e (fffff803`22141fe2)
nt!AuthzBasepRemoveSecurityAttributeFromLists+0x49:
fffff803`22141fbd 4c8b02 mov r8,qword ptr [rdx]
fffff803`22141fc0 488b4208 mov rax,qword ptr [rdx+8]
fffff803`22141fc4 49395008 cmp qword ptr [r8+8],rdx
fffff803`22141fc8 7520 jne nt!AuthzBasepRemoveSecurityAttributeFromLists+0x76 (fffff803`22141fea)
nt!AuthzBasepRemoveSecurityAttributeFromLists+0x56:
fffff803`22141fca 483910 cmp qword ptr [rax],rdx
fffff803`22141fcd 751b jne nt!AuthzBasepRemoveSecurityAttributeFromLists+0x76 (fffff803`22141fea)
nt!AuthzBasepRemoveSecurityAttributeFromLists+0x5b:
fffff803`22141fcf 4c8900 mov qword ptr [rax],r8 ; rax->Flink = r8
fffff803`22141fd2 49894008 mov qword ptr [r8+8],rax ; r8->Blink = rax
fffff803`22141fd6 836238fe and dword ptr [rdx+38h],0FFFFFFFEh
fffff803`22141fda 4885c9 test rcx,rcx
fffff803`22141fdd 7403 je nt!AuthzBasepRemoveSecurityAttributeFromLists+0x6e (fffff803`22141fe2)
nt!AuthzBasepRemoveSecurityAttributeFromLists+0x6b:
fffff803`22141fdf 440119 add dword ptr [rcx],r11d
nt!AuthzBasepRemoveSecurityAttributeFromLists+0x6e:
fffff803`22141fe2 c3 ret
nt!AuthzBasepRemoveSecurityAttributeFromLists+0x6f:
fffff803`22141fe3 b903000000 mov ecx,3
fffff803`22141fe8 cd29 int 29h
nt!AuthzBasepRemoveSecurityAttributeFromLists+0x76:
fffff803`22141fea b903000000 mov ecx,3
fffff803`22141fef cd29 int 29h
fffff803`22141ff1 90 nop
fffff803`22141ff2 90 nop
fffff803`22141ff3 90 nop
fffff803`22141ff4 90 nop
fffff803`22141ff5 90 nop
fffff803`22141ff6 90 nop
fffff803`22141ff7 90 nop
fffff803`22141ff8 458ad0 mov r10b,r8b
fffff803`22141ffb 4584c9 test r9b,r9b
fffff803`22141ffe 7434 je nt!AuthzBasepAddSecurityAttributeToLists+0x3c (fffff803`22142034)
nt!AuthzBasepAddSecurityAttributeToLists+0x8:
fffff803`22142000 8b4238 mov eax,dword ptr [rdx+38h]
fffff803`22142003 a802 test al,2
fffff803`22142005 752d jne nt!AuthzBasepAddSecurityAttributeToLists+0x3c (fffff803`22142034)
nt!AuthzBasepAddSecurityAttributeToLists+0xf:
fffff803`22142007 4c8d4120 lea r8,[rcx+20h]
fffff803`2214200b 488d4210 lea rax,[rdx+10h]
fffff803`2214200f 4d8b4808 mov r9,qword ptr [r8+8]
fffff803`22142013 4c8900 mov qword ptr [rax],r8
fffff803`22142016 4c894808 mov qword ptr [rax+8],r9
fffff803`2214201a 4d3901 cmp qword ptr [r9],r8
fffff803`2214201d 7407 je nt!AuthzBasepAddSecurityAttributeToLists+0x2e (fffff803`22142026)
nt!AuthzBasepAddSecurityAttributeToLists+0x27:
fffff803`2214201f b903000000 mov ecx,3
fffff803`22142024 cd29 int 29h
nt!AuthzBasepAddSecurityAttributeToLists+0x2e:
fffff803`22142026 498901 mov qword ptr [r9],rax
fffff803`22142029 49894008 mov qword ptr [r8+8],rax
fffff803`2214202d 834a3802 or dword ptr [rdx+38h],2
fffff803`22142031 ff4118 inc dword ptr [rcx+18h]
nt!AuthzBasepAddSecurityAttributeToLists+0x3c:
fffff803`22142034 4584d2 test r10b,r10b
fffff803`22142037 742f je nt!AuthzBasepAddSecurityAttributeToLists+0x70 (fffff803`22142068)
nt!AuthzBasepAddSecurityAttributeToLists+0x41:
fffff803`22142039 8b4238 mov eax,dword ptr [rdx+38h]
fffff803`2214203c a801 test al,1
fffff803`2214203e 7528 jne nt!AuthzBasepAddSecurityAttributeToLists+0x70 (fffff803`22142068)
nt!AuthzBasepAddSecurityAttributeToLists+0x48:
fffff803`22142040 488d4108 lea rax,[rcx+8]
fffff803`22142044 4c8b4008 mov r8,qword ptr [rax+8]
fffff803`22142048 488902 mov qword ptr [rdx],rax
fffff803`2214204b 4c894208 mov qword ptr [rdx+8],r8
fffff803`2214204f 493900 cmp qword ptr [r8],rax
fffff803`22142052 7407 je nt!AuthzBasepAddSecurityAttributeToLists+0x63 (fffff803`2214205b)
nt!AuthzBasepAddSecurityAttributeToLists+0x5c:
fffff803`22142054 b903000000 mov ecx,3
fffff803`22142059 cd29 int 29h
nt!AuthzBasepAddSecurityAttributeToLists+0x63:
fffff803`2214205b 498910 mov qword ptr [r8],rdx
fffff803`2214205e 48895008 mov qword ptr [rax+8],rdx
fffff803`22142062 834a3801 or dword ptr [rdx+38h],1
fffff803`22142066 ff01 inc dword ptr [rcx]
nt!AuthzBasepAddSecurityAttributeToLists+0x70:
fffff803`22142068 c3 ret
| shxdow/practical-reverse-engineering | practical-reverse-engineering/chapter_03/page123/exercise06/AlpcpUnregisterCompletionListDatabase.asm | Assembly | mit | 6,956 |
; Copyright (c) 2004, Intel Corporation. All rights reserved.<BR>
; 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 license may be found at
; http://opensource.org/licenses/bsd-license.php
;
; THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
; WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
;
; Module Name:
;
; ReadMm7.Asm
;
; Abstract:
;
; AsmReadMm7 function
;
; Notes:
;
;------------------------------------------------------------------------------
.code
;------------------------------------------------------------------------------
; UINT64
; EFIAPI
; AsmReadMm7 (
; VOID
; );
;------------------------------------------------------------------------------
AsmReadMm7 PROC
;
; 64-bit MASM doesn't support MMX instructions, so use opcode here
;
DB 48h, 0fh, 7eh, 0f8h
ret
AsmReadMm7 ENDP
END
| google/google-ctf | third_party/edk2/EdkCompatibilityPkg/Foundation/Library/EdkIIGlueLib/Library/BaseLib/X64/ReadMm7.asm | Assembly | apache-2.0 | 1,281 |
;
; Copyright (c) 2010 The WebM project authors. All Rights Reserved.
;
; Use of this source code is governed by a BSD-style license
; that can be found in the LICENSE file in the root of the source
; tree. An additional intellectual property rights grant can be found
; in the file PATENTS. All contributing project authors may
; be found in the AUTHORS file in the root of the source tree.
;
%include "vpx_ports/x86_abi_support.asm"
;void vp8_short_inv_walsh4x4_mmx(short *input, short *output)
global sym(vp8_short_inv_walsh4x4_mmx)
sym(vp8_short_inv_walsh4x4_mmx):
push rbp
mov rbp, rsp
SHADOW_ARGS_TO_STACK 2
; end prolog
mov rdx, arg(0)
mov rax, 30003h
movq mm0, [rdx + 0] ;ip[0]
movq mm1, [rdx + 8] ;ip[4]
movd mm7, rax
movq mm2, [rdx + 16] ;ip[8]
movq mm3, [rdx + 24] ;ip[12]
punpcklwd mm7, mm7 ;0003000300030003h
mov rdx, arg(1)
movq mm4, mm0
movq mm5, mm1
paddw mm4, mm3 ;ip[0] + ip[12] aka al
paddw mm5, mm2 ;ip[4] + ip[8] aka bl
movq mm6, mm4 ;temp al
paddw mm4, mm5 ;al + bl
psubw mm6, mm5 ;al - bl
psubw mm0, mm3 ;ip[0] - ip[12] aka d1
psubw mm1, mm2 ;ip[4] - ip[8] aka c1
movq mm5, mm0 ;temp dl
paddw mm0, mm1 ;dl + cl
psubw mm5, mm1 ;dl - cl
; 03 02 01 00
; 13 12 11 10
; 23 22 21 20
; 33 32 31 30
movq mm3, mm4 ; 03 02 01 00
punpcklwd mm4, mm0 ; 11 01 10 00
punpckhwd mm3, mm0 ; 13 03 12 02
movq mm1, mm6 ; 23 22 21 20
punpcklwd mm6, mm5 ; 31 21 30 20
punpckhwd mm1, mm5 ; 33 23 32 22
movq mm0, mm4 ; 11 01 10 00
movq mm2, mm3 ; 13 03 12 02
punpckldq mm0, mm6 ; 30 20 10 00 aka ip[0]
punpckhdq mm4, mm6 ; 31 21 11 01 aka ip[4]
punpckldq mm2, mm1 ; 32 22 12 02 aka ip[8]
punpckhdq mm3, mm1 ; 33 23 13 03 aka ip[12]
;~~~~~~~~~~~~~~~~~~~~~
movq mm1, mm0
movq mm5, mm4
paddw mm1, mm3 ;ip[0] + ip[12] aka al
paddw mm5, mm2 ;ip[4] + ip[8] aka bl
movq mm6, mm1 ;temp al
paddw mm1, mm5 ;al + bl
psubw mm6, mm5 ;al - bl
paddw mm1, mm7
paddw mm6, mm7
psraw mm1, 3
psraw mm6, 3
psubw mm0, mm3 ;ip[0] - ip[12] aka d1
psubw mm4, mm2 ;ip[4] - ip[8] aka c1
movq mm5, mm0 ;temp dl
paddw mm0, mm4 ;dl + cl
psubw mm5, mm4 ;dl - cl
paddw mm0, mm7
paddw mm5, mm7
psraw mm0, 3
psraw mm5, 3
;~~~~~~~~~~~~~~~~~~~~~
movd eax, mm1
movd ecx, mm0
psrlq mm0, 32
psrlq mm1, 32
mov word ptr[rdx+32*0], ax
mov word ptr[rdx+32*1], cx
shr eax, 16
shr ecx, 16
mov word ptr[rdx+32*4], ax
mov word ptr[rdx+32*5], cx
movd eax, mm1
movd ecx, mm0
mov word ptr[rdx+32*8], ax
mov word ptr[rdx+32*9], cx
shr eax, 16
shr ecx, 16
mov word ptr[rdx+32*12], ax
mov word ptr[rdx+32*13], cx
movd eax, mm6
movd ecx, mm5
psrlq mm5, 32
psrlq mm6, 32
mov word ptr[rdx+32*2], ax
mov word ptr[rdx+32*3], cx
shr eax, 16
shr ecx, 16
mov word ptr[rdx+32*6], ax
mov word ptr[rdx+32*7], cx
movd eax, mm6
movd ecx, mm5
mov word ptr[rdx+32*10], ax
mov word ptr[rdx+32*11], cx
shr eax, 16
shr ecx, 16
mov word ptr[rdx+32*14], ax
mov word ptr[rdx+32*15], cx
; begin epilog
UNSHADOW_ARGS
pop rbp
ret
| awatry/libvpx.opencl | vp8/common/x86/iwalsh_mmx.asm | Assembly | bsd-3-clause | 4,194 |
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
; Copyright(c) 2011-2015 Intel Corporation All rights reserved.
;
; Redistribution and use in source and binary forms, with or without
; modification, are permitted provided that the following conditions
; are met:
; * Redistributions of source code must retain the above copyright
; notice, this list of conditions and the following disclaimer.
; * Redistributions in binary form must reproduce the above copyright
; notice, this list of conditions and the following disclaimer in
; the documentation and/or other materials provided with the
; distribution.
; * Neither the name of Intel Corporation nor the names of its
; contributors may be used to endorse or promote products derived
; from this software without specific prior written permission.
;
; THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
; "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
; LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
; A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
; OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
; SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
; LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
; DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
; THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
; (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
; OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;;;
;;; gf_5vect_mad_sse(len, vec, vec_i, mul_array, src, dest);
;;;
%include "reg_sizes.asm"
%define PS 8
%ifidn __OUTPUT_FORMAT__, win64
%define arg0 rcx
%define arg0.w ecx
%define arg1 rdx
%define arg2 r8
%define arg3 r9
%define arg4 r12
%define arg5 r15
%define tmp r11
%define tmp2 r10
%define tmp3 r13
%define tmp4 r14
%define return rax
%define return.w eax
%define stack_size 16*10 + 5*8
%define arg(x) [rsp + stack_size + PS + PS*x]
%define func(x) proc_frame x
%macro FUNC_SAVE 0
sub rsp, stack_size
movdqa [rsp+16*0],xmm6
movdqa [rsp+16*1],xmm7
movdqa [rsp+16*2],xmm8
movdqa [rsp+16*3],xmm9
movdqa [rsp+16*4],xmm10
movdqa [rsp+16*5],xmm11
movdqa [rsp+16*6],xmm12
movdqa [rsp+16*7],xmm13
movdqa [rsp+16*8],xmm14
movdqa [rsp+16*9],xmm15
save_reg r12, 10*16 + 0*8
save_reg r13, 10*16 + 1*8
save_reg r14, 10*16 + 2*8
save_reg r15, 10*16 + 3*8
end_prolog
mov arg4, arg(4)
mov arg5, arg(5)
%endmacro
%macro FUNC_RESTORE 0
movdqa xmm6, [rsp+16*0]
movdqa xmm7, [rsp+16*1]
movdqa xmm8, [rsp+16*2]
movdqa xmm9, [rsp+16*3]
movdqa xmm10, [rsp+16*4]
movdqa xmm11, [rsp+16*5]
movdqa xmm12, [rsp+16*6]
movdqa xmm13, [rsp+16*7]
movdqa xmm14, [rsp+16*8]
movdqa xmm15, [rsp+16*9]
mov r12, [rsp + 10*16 + 0*8]
mov r13, [rsp + 10*16 + 1*8]
mov r14, [rsp + 10*16 + 2*8]
mov r15, [rsp + 10*16 + 3*8]
add rsp, stack_size
%endmacro
%elifidn __OUTPUT_FORMAT__, elf64
%define arg0 rdi
%define arg0.w edi
%define arg1 rsi
%define arg2 rdx
%define arg3 rcx
%define arg4 r8
%define arg5 r9
%define tmp r11
%define tmp2 r10
%define tmp3 r12
%define tmp4 r13
%define return rax
%define return.w eax
%define func(x) x: endbranch
%macro FUNC_SAVE 0
push r12
push r13
%endmacro
%macro FUNC_RESTORE 0
pop r13
pop r12
%endmacro
%endif
;;; gf_5vect_mad_sse(len, vec, vec_i, mul_array, src, dest)
%define len arg0
%define len.w arg0.w
%define vec arg1
%define vec_i arg2
%define mul_array arg3
%define src arg4
%define dest1 arg5
%define pos return
%define pos.w return.w
%define dest2 tmp4
%define dest3 mul_array
%define dest4 tmp2
%define dest5 vec_i
%ifndef EC_ALIGNED_ADDR
;;; Use Un-aligned load/store
%define XLDR movdqu
%define XSTR movdqu
%else
;;; Use Non-temporal load/stor
%ifdef NO_NT_LDST
%define XLDR movdqa
%define XSTR movdqa
%else
%define XLDR movntdqa
%define XSTR movntdq
%endif
%endif
default rel
[bits 64]
section .text
%define xmask0f xmm15
%define xgft5_hi xmm14
%define xgft4_lo xmm13
%define xgft4_hi xmm12
%define x0 xmm0
%define xtmpa xmm1
%define xtmph1 xmm2
%define xtmpl1 xmm3
%define xtmph2 xmm4
%define xtmpl2 xmm5
%define xtmph3 xmm6
%define xtmpl3 xmm7
%define xtmph5 xmm8
%define xtmpl5 xmm9
%define xd1 xmm10
%define xd2 xmm11
%define xd3 xtmpl1
%define xd4 xtmph1
%define xd5 xtmpl2
align 16
mk_global gf_5vect_mad_sse, function
func(gf_5vect_mad_sse)
FUNC_SAVE
sub len, 16
jl .return_fail
xor pos, pos
movdqa xmask0f, [mask0f] ;Load mask of lower nibble in each byte
mov tmp, vec
sal vec_i, 5 ;Multiply by 32
lea tmp3, [mul_array + vec_i]
sal tmp, 6 ;Multiply by 64
movdqu xgft5_hi, [tmp3+2*tmp+16] ; " Ex{00}, Ex{10}, ..., Ex{f0}
sal vec, 5 ;Multiply by 32
add tmp, vec
movdqu xgft4_hi, [tmp3+tmp+16] ; " Dx{00}, Dx{10}, Dx{20}, ... , Dx{f0}
movdqu xgft4_lo, [tmp3+tmp] ;Load array Dx{00}, Dx{01}, Dx{02}, ...
mov dest3, [dest1+2*PS] ; reuse mul_array
mov dest4, [dest1+3*PS]
mov dest5, [dest1+4*PS] ; reuse vec_i
mov dest2, [dest1+PS]
mov dest1, [dest1]
.loop16:
XLDR x0, [src+pos] ;Get next source vector
movdqu xtmph1, [tmp3+16] ; " Ax{00}, Ax{10}, Ax{20}, ... , Ax{f0}
movdqu xtmpl1, [tmp3] ;Load array Ax{00}, Ax{01}, Ax{02}, ...
movdqu xtmph2, [tmp3+vec+16] ; " Bx{00}, Bx{10}, Bx{20}, ... , Bx{f0}
movdqu xtmpl2, [tmp3+vec] ;Load array Bx{00}, Bx{01}, Bx{02}, ...
movdqu xtmph3, [tmp3+2*vec+16] ; " Cx{00}, Cx{10}, Cx{20}, ... , Cx{f0}
movdqu xtmpl3, [tmp3+2*vec] ;Load array Cx{00}, Cx{01}, Cx{02}, ...
movdqu xtmpl5, [tmp3+4*vec] ;Load array Ex{00}, Ex{01}, ..., Ex{0f}
movdqa xtmph5, xgft5_hi ;Reload const array registers
XLDR xd1, [dest1+pos] ;Get next dest vector
XLDR xd2, [dest2+pos] ;Get next dest vector
movdqa xtmpa, x0 ;Keep unshifted copy of src
psraw x0, 4 ;Shift to put high nibble into bits 4-0
pand x0, xmask0f ;Mask high src nibble in bits 4-0
pand xtmpa, xmask0f ;Mask low src nibble in bits 4-0
; dest1
pshufb xtmph1, x0 ;Lookup mul table of high nibble
pshufb xtmpl1, xtmpa ;Lookup mul table of low nibble
pxor xtmph1, xtmpl1 ;GF add high and low partials
pxor xd1, xtmph1
XLDR xd3, [dest3+pos] ;Reuse xtmpl1, Get next dest vector
XLDR xd4, [dest4+pos] ;Reuse xtmph1. Get next dest vector
; dest2
pshufb xtmph2, x0 ;Lookup mul table of high nibble
pshufb xtmpl2, xtmpa ;Lookup mul table of low nibble
pxor xtmph2, xtmpl2 ;GF add high and low partials
pxor xd2, xtmph2
XLDR xd5, [dest5+pos] ;Reuse xtmpl2. Get next dest vector
; dest3
pshufb xtmph3, x0 ;Lookup mul table of high nibble
pshufb xtmpl3, xtmpa ;Lookup mul table of low nibble
pxor xtmph3, xtmpl3 ;GF add high and low partials
pxor xd3, xtmph3
movdqa xtmph2, xgft4_hi ;Reload const array registers
movdqa xtmpl3, xgft4_lo ;Reload const array registers
; dest5
pshufb xtmph5, x0 ;Lookup mul table of high nibble
pshufb xtmpl5, xtmpa ;Lookup mul table of low nibble
pxor xtmph5, xtmpl5 ;GF add high and low partials
pxor xd5, xtmph5
; dest4
pshufb xtmph2, x0 ;Lookup mul table of high nibble
pshufb xtmpl3, xtmpa ;Lookup mul table of low nibble
pxor xtmph2, xtmpl3 ;GF add high and low partials
pxor xd4, xtmph2
XSTR [dest1+pos], xd1 ;Store result into dest1
XSTR [dest2+pos], xd2 ;Store result into dest2
XSTR [dest3+pos], xd3 ;Store result into dest3
XSTR [dest4+pos], xd4 ;Store result into dest4
XSTR [dest5+pos], xd5 ;Store result into dest5
add pos, 16 ;Loop on 16 bytes at a time
cmp pos, len
jle .loop16
lea tmp, [len + 16]
cmp pos, tmp
je .return_pass
.lessthan16:
;; Tail len
;; Do one more overlap pass
mov tmp, len ;Overlapped offset length-16
XLDR x0, [src+tmp] ;Get next source vector
sub len, pos
movdqa xtmpl1, [constip16] ;Load const of i + 16
pinsrb xtmph5, len.w, 15
pshufb xtmph5, xmask0f ;Broadcast len to all bytes
pcmpgtb xtmph5, xtmpl1
movdqu xtmph1, [tmp3+16] ; " Ax{00}, Ax{10}, Ax{20}, ... , Ax{f0}
movdqu xtmpl1, [tmp3] ;Load array Ax{00}, Ax{01}, Ax{02}, ...
movdqu xtmph2, [tmp3+vec+16] ; " Bx{00}, Bx{10}, Bx{20}, ... , Bx{f0}
movdqu xtmpl2, [tmp3+vec] ;Load array Bx{00}, Bx{01}, Bx{02}, ...
movdqu xtmph3, [tmp3+2*vec+16] ; " Cx{00}, Cx{10}, Cx{20}, ... , Cx{f0}
movdqu xtmpl3, [tmp3+2*vec] ;Load array Cx{00}, Cx{01}, Cx{02}, ...
movdqu xtmpl5, [tmp3+4*vec] ;Load array Ex{00}, Ex{01}, ..., Ex{0f}
XLDR xd1, [dest1+tmp] ;Get next dest vector
XLDR xd2, [dest2+tmp] ;Get next dest vector
movdqa xtmpa, x0 ;Keep unshifted copy of src
psraw x0, 4 ;Shift to put high nibble into bits 4-0
pand x0, xmask0f ;Mask high src nibble in bits 4-0
pand xtmpa, xmask0f ;Mask low src nibble in bits 4-0
; dest1
pshufb xtmph1, x0 ;Lookup mul table of high nibble
pshufb xtmpl1, xtmpa ;Lookup mul table of low nibble
pxor xtmph1, xtmpl1 ;GF add high and low partials
pand xtmph1, xtmph5
pxor xd1, xtmph1
XLDR xd3, [dest3+tmp] ;Reuse xtmpl1, Get next dest vector
XLDR xd4, [dest4+tmp] ;Reuse xtmph1. Get next dest vector
; dest2
pshufb xtmph2, x0 ;Lookup mul table of high nibble
pshufb xtmpl2, xtmpa ;Lookup mul table of low nibble
pxor xtmph2, xtmpl2 ;GF add high and low partials
pand xtmph2, xtmph5
pxor xd2, xtmph2
XLDR xd5, [dest5+tmp] ;Reuse xtmpl2. Get next dest vector
; dest3
pshufb xtmph3, x0 ;Lookup mul table of high nibble
pshufb xtmpl3, xtmpa ;Lookup mul table of low nibble
pxor xtmph3, xtmpl3 ;GF add high and low partials
pand xtmph3, xtmph5
pxor xd3, xtmph3
; dest4
pshufb xgft4_hi, x0 ;Lookup mul table of high nibble
pshufb xgft4_lo, xtmpa ;Lookup mul table of low nibble
pxor xgft4_hi, xgft4_lo ;GF add high and low partials
pand xgft4_hi, xtmph5
pxor xd4, xgft4_hi
; dest5
pshufb xgft5_hi, x0 ;Lookup mul table of high nibble
pshufb xtmpl5, xtmpa ;Lookup mul table of low nibble
pxor xgft5_hi, xtmpl5 ;GF add high and low partials
pand xgft5_hi, xtmph5
pxor xd5, xgft5_hi
XSTR [dest1+tmp], xd1 ;Store result into dest1
XSTR [dest2+tmp], xd2 ;Store result into dest2
XSTR [dest3+tmp], xd3 ;Store result into dest3
XSTR [dest4+tmp], xd4 ;Store result into dest4
XSTR [dest5+tmp], xd5 ;Store result into dest5
.return_pass:
FUNC_RESTORE
mov return, 0
ret
.return_fail:
FUNC_RESTORE
mov return, 1
ret
endproc_frame
section .data
align 16
mask0f:
dq 0x0f0f0f0f0f0f0f0f, 0x0f0f0f0f0f0f0f0f
constip16:
dq 0xf8f9fafbfcfdfeff, 0xf0f1f2f3f4f5f6f7
;;; func core, ver, snum
slversion gf_5vect_mad_sse, 00, 01, 020c
| Intel-HLS/GKL | src/main/native/compression/isa-l-master/erasure_code/gf_5vect_mad_sse.asm | Assembly | mit | 10,727 |
/*
* Common module to set offset into the scoreboard
* Copyright © <2010>, Intel Corporation.
*
* This program is licensed under the terms and conditions of the
* Eclipse Public License (EPL), version 1.0. The full text of the EPL is at
* http://www.opensource.org/licenses/eclipse-1.0.php.
*
*/
//
// Module name: set_SB_offset.asm
//
// Common module to set offset into the scoreboard
// Note: This is to encapsulate the way M0.5:ud in ForwardMsg is filled.
//
// $Revision: 2 $
// $Date: 10/16/06 5:19p $
//
add (1) MSGHDRY1.10<1>:uw r0.20:ub 0x0200:uw // Message length = 1 DWORD
add (16) acc0<1>:w r0.12<0;1,0>:uw -LEADING_THREAD:w // 0-based thread count derived from r0.6:ud
shl (1) M05_STORE<1>:uw acc0<0;1,0>:uw 0x2:uw // Store for future "update" use, in DWORD unit
and (16) acc0<1>:w acc0<16;16,1>:uw SB_MASK:uw // Wrap around scoreboard
shl (1) MSGHDRY1.11<1>:uw acc0<0;1,0>:uw 0x2:uw // Convert to DWORD offset
// End of set_SB_offset | halleyzhao/libva-intel-driver-fdo | src/shaders/h264/mc/set_SB_offset.asm | Assembly | mit | 1,000 |
; MASM.ASM
; --------
; uFMOD public source code release. Provided as-is.
; *** This stub allows compiling uFMOD sources using MASM32.
.386
.model flat
ifdef f44100
FSOUND_MixRate = 44100
FREQ_40HZ_p = 1DB8Bh
FREQ_40HZ_f = 3B7160h
PCM_format = 3
else
ifdef f22050
FSOUND_MixRate = 22050
FREQ_40HZ_p = 3B716h
FREQ_40HZ_f = 76E2C0h
PCM_format = 9
else
ifndef f48000
echo UF_FREQ not specified (defaulting to 48KHz)
endif
FSOUND_MixRate = 48000
FREQ_40HZ_p = 1B4E8h
FREQ_40HZ_f = 369D00h
PCM_format = 1
endif
endif
RAMP_NONE = 0
RAMP_WEAK = 0
RAMP_STRONG = 0
ifdef NONE
RAMP_NONE = 1
else
ifdef WEAK
RAMP_WEAK = 1
else
ifndef STRONG
echo UF_RAMP not specified (defaulting to STRONG)
endif
RAMP_STRONG = 1
endif
endif
UCODE = 0
DEBUG = 0
CHK4VALIDITY = 1
ifdef UNSAFE
echo WARNING! Unsafe mod is ON. Library may crash while loading damaged XM tracks!
CHK4VALIDITY = 0
endif
AC97SND_ON = 0
ifdef AC97SND
AC97SND_ON = 1
endif
include eff.inc
FSOUND_SAMPLE STRUC
_length dd ?
loopstart dd ?
looplen dd ?
defvol db ?
finetune db ?
bytes db ?
defpan db ?
relative db ?
Resved db ?
loopmode db ?
_align db ?
buff db ?,?
FSOUND_SAMPLE ENDS
FSOUND_CHANNEL STRUC
actualvolume dd ?
actualpan dd ?
fsampleoffset dd ?
leftvolume dd ?
rightvolume dd ?
mixpos dd ?
speedlo dd ?
speedhi dd ?
ramp_lefttarget dw ?
ramp_righttarget dw ?
ramp_leftspeed dd ?
ramp_rightspeed dd ?
fsptr dd ?
mixposlo dd ?
ramp_leftvolume dd ?
ramp_rightvolume dd ?
ramp_count dw ?
speeddir db ?,?
FSOUND_CHANNEL ENDS
FMUSIC_NOTE STRUC
unote db ?
number db ?
uvolume db ?
effect db ?
eparam db ?
FMUSIC_NOTE ENDS
FMUSIC_PATTERN STRUC
rows dw ?
patternsize dw ?
data dd ?
FMUSIC_PATTERN ENDS
FMUSIC_INSTRUMENT STRUC
sample dd 16 dup (?)
keymap db 96 dup (?)
VOLPoints dw 24 dup (?)
PANPoints dw 24 dup (?)
VOLnumpoints db ?
PANnumpoints db ?
VOLsustain db ?
VOLLoopStart db ?
VOLLoopEnd db ?
PANsustain db ?
PANLoopStart db ?
PANLoopEnd db ?
VOLtype db ?
PANtype db ?
VIBtype db ?
VIBsweep db ?
iVIBdepth db ?
VIBrate db ?
VOLfade dw ?
FMUSIC_INSTRUMENT ENDS
FMUSIC_CHANNEL STRUC
note db ?
samp db ?
notectrl db ?
inst db ?
cptr dd ?
freq dd ?
volume dd ?
voldelta dd ?
freqdelta dd ?
pan dd ?
envvoltick dd ?
envvolpos dd ?
envvoldelta dd ?
envpantick dd ?
envpanpos dd ?
envpandelta dd ?
ivibsweeppos dd ?
ivibpos dd ?
keyoff db ?,?
envvolstopped db ?
envpanstopped db ?
envvolfrac dd ?
envvol dd ?
fadeoutvol dd ?
envpanfrac dd ?
envpan dd ?
period dd ?
sampleoffset dd ?
portatarget dd ?
patloopno db ?,?,?,?
patlooprow dd ?
realnote db ?
recenteffect db ?
portaupdown db ?
db ?
xtraportadown db ?
xtraportaup db ?
volslide db ?
panslide db ?
retrigx db ?
retrigy db ?
portaspeed db ?
vibpos db ?
vibspeed db ?
vibdepth db ?
tremolopos db ?
tremolospeed db ?
tremolodepth db ?
tremorpos db ?
tremoron db ?
tremoroff db ?
wavecontrol db ?
finevslup db ?
fineportaup db ?
fineportadown db ?
FMUSIC_CHANNEL ENDS
FMUSIC_MODULE STRUC
pattern dd ?
instrument dd ?
mixer_samplesleft dd ?
globalvolume dd ?
tick dd ?
speed dd ?
order dd ?
row dd ?
patterndelay dd ?
nextorder dd ?
nextrow dd ?
unused1 dd ?
numchannels dd ?
Channels dd ?
uFMOD_Ch dd ?
mixer_samplespertick dd ?
numorders dw ?
restart dw ?
numchannels_xm db ?
globalvsl db ?
numpatternsmem dw ?
numinsts dw ?
flags dw ?
defaultspeed dw ?
defaultbpm dw ?
orderlist db 256 dup (?)
FMUSIC_MODULE ENDS
FMUSIC_MODULE_size = SIZE FMUSIC_MODULE
FSOUND_CHANNEL_size = SIZE FSOUND_CHANNEL
FMUSIC_CHANNEL_size = SIZE FMUSIC_CHANNEL
FMUSIC_INSTRUMENT_size = SIZE FMUSIC_INSTRUMENT
FMUSIC_PATTERN_size = SIZE FMUSIC_PATTERN
FMUSIC_NOTE_size = SIZE FMUSIC_NOTE
; FPU register stack
st0 TEXTEQU <st(0)>
st1 TEXTEQU <st(1)>
.CODE
include ufmod.asm
include core.asm
.DATA?
_mod = $
FMUSIC_MODULE<>
mmt dd ?,?,?
ufmod_heap dd ?,?
if AC97SND_ON
EXTERN hSound:DWORD
dd ?
else
hSound dd ?
endif
hBuff dd ?
SW_Exit dd ?
MixBuf db FSOUND_BlockSize*8 dup (?)
ufmod_noloop db ?
ufmod_pause_ db ?
mix_endflag db ?,?
mmf dd ?,?,?,?
ufmod_vol dd ?
uFMOD_fopen dd ?
uFMOD_fread dd ?
file_struct dd 7 dup (?)
cache_offset dd ?
if INFO_API_ON
time_ms dd ?
L_vol dw ?
R_vol dw ?
s_row dw ?
s_order dw ?
szTtl db 24 dup (?)
endif
DummySamp FSOUND_SAMPLE<>
end
| devlato/kolibrios-llvm | programs/develop/libraries/ufmod/masm.asm | Assembly | mit | 5,234 |
;; rdtmain - main part of test program for RDX execution.
;; returns true (0) if its parameter equals the phrase "hello"
;; "hello" is stored in the library part, to complicate the
;; linkage.
;; assemble and link with the following commands:
;; nasm -f rdf rdtmain.asm
;; nasm -f rdf rdtlib.asm
;; ldrdf rdtmain.rdf rdtlib.rdf -o rdxtest.rdx
;; run with 'rdx rdxtest.rdx [parameters]' on a Linux (or possibly
;; other 32 bit OS) systems (x86 architectures only!)
;; try using '&& echo Yes' afterwards to find out when it returns 0.
[EXTERN _strcmp] ; strcmp is an imported function
[EXTERN _message] ; imported data
[SECTION .text]
[BITS 32]
;; main(int argc,char **argv)
[GLOBAL _main]
_main:
push ebp
mov ebp,esp
;; ebp+8 = argc, ebp+12 = argv
cmp dword [ebp+8],2
jb error ; cause error if < 1 parameters
mov eax, [ebp+12] ; eax = argv
mov ebx, [eax+4] ; ebx = argv[1]
mov ecx, _message ; ecx = "hello"
push ecx
push ebx
call _strcmp ; compare strings
add esp,8 ; caller clears stack
pop ebp
ret ; return return value of _strcmp
error:
mov eax,2 ; return 2 on error
pop ebp
ret
| coapp-packages/nasm | rdoff/test/rdtmain.asm | Assembly | bsd-2-clause | 1,179 |
/*
* Copyright © <2010>, Intel Corporation.
*
* Permission is hereby granted, free of charge, to any person obtaining a
* copy of this software and associated documentation files (the
* "Software"), to deal in the Software without restriction, including
* without limitation the rights to use, copy, modify, merge, publish,
* distribute, sub license, and/or sell copies of the Software, and to
* permit persons to whom the Software is furnished to do so, subject to
* the following conditions:
*
* The above copyright notice and this permission notice (including the
* next paragraph) shall be included in all copies or substantial portions
* of the Software.
*
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
* OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT.
* IN NO EVENT SHALL PRECISION INSIGHT AND/OR ITS SUPPLIERS BE LIABLE FOR
* ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
*
* This file was originally licensed under the following license
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*
*/
// Module Name: Loadnv12_16X4.Asm
//
// Load Nv12 16X4 Block
//
//----------------------------------------------------------------
// Symbols Need To Be Defined Before Including This Module
//
// Source Region In :Ud
// Src_Yd: Src_Yd Base=Rxx Elementsize=4 Srcregion=Region(8,1) Type=Ud // 3 Grfs (2 For Y, 1 For U+V)
//
// Source Region Is :Ub. The Same Region As :Ud Region
// Src_Yb: Src_Yb Base=Rxx Elementsize=1 Srcregion=Region(16,1) Type=Ub // 2 Grfs
// Src_Ub: Src_Ub Base=Rxx Elementsize=1 Srcregion=Region(16,1) Type=Ub // 0.5 Grf
// Src_Vb: Src_Vb Base=Rxx Elementsize=1 Srcregion=Region(16,1) Type=Ub // 0.5 Grf
//
// Binding Table Index:
// Bi_Src_Y: Binding Table Index Of Y Surface
// Bi_Src_UV: Binding Table Index Of UV Surface (Nv12)
//
// Temp Buffer:
// Buf_D: Buf_D Base=Rxx Elementsize=4 Srcregion=Region(8,1) Type=Ud
// Buf_B: Buf_B Base=Rxx Elementsize=1 Srcregion=Region(16,1) Type=Ub
//
//----------------------------------------------------------------
#if defined(_DEBUG)
mov (1) EntrySignatureC:w 0xDDD2:w
#endif
// Read Y
mov (2) MSGSRC.0<1>:ud ORIX<2;2,1>:w // Block origin
mov (1) MSGSRC.2<1>:ud 0x0003000F:ud // Block width and height (16x4)
send (8) PREV_MB_YD(0)<1> MSGHDRY MSGSRC<8;8,1>:ud DAPREAD RESP_LEN(2)+DWBRMSGDSC_RC+BI_SRC_Y // Read 2 GRFs
// Read U+V
asr (1) MSGSRC.1:ud MSGSRC.1:ud 1:w // NV12 U+V block origin y = half of Y comp
mov (1) MSGSRC.2<1>:ud 0x0001000F:ud // NV12 U+V block width and height (16x2)
// Load NV12 U+V tp a temp buf
send (8) BUF_D(0)<1> MSGHDRU MSGSRC<8;8,1>:ud DAPREAD RESP_LEN(1)+DWBRMSGDSC_RC+BI_SRC_UV // Read 1 GRF
// Convert NV12 U+V to internal planar U and V and place them right after Y.
// mov (16) SRC_UB(0,0)<1> BUF_B(0,0)<32;16,2>
// mov (16) SRC_VB(0,0)<1> BUF_B(0,1)<32;16,2>
// End of loadNV12_16x4.asm
| uartie/vaapi-intel-driver | src/shaders/h264/ildb/loadNV12_16x4.asm | Assembly | mit | 3,725 |
PROG equ 0x5c53
NEWPPC equ 0x5c42
NSPPC equ 0x5c44
VARS equ 0x5c4b
NXTLIN equ 0x5c55
org 0xc000
jp hello
ld bc, newProgEnd-newProg
ld de, newProg
loadBasic:
;set NEWPPC to $000a
ld hl, $000a
ld (NEWPPC), hl
;set NSPPC to 0
push af
ld a, 0
ld (NSPPC), a
pop af
;set VARS to prog + (newProgEnd-newProg)
ld hl, (PROG)
add hl, bc
ld (VARS), hl
;set NXTLIN to prog + (newProgEnd-newProg) - 2
dec hl
dec hl
ld (NXTLIN), hl
;copy the new program
ld hl, (PROG)
ex de, hl
ldir
ret
newProg:
;10 CLEAR VAL "46000":PRINT"Filename?":INPUT LINE a$:RANDOMIZE USR VAL "49152"
defb $00, $0a, $27, $00, $fd, $b0, $22, $34, $36, $30, $30, $30, $22, $3a
defb $f5, $22, $46, $69, $6c, $65, $6e, $61, $6d, $65, $3f, $22, $3a
defb $ee, $ca, $61, $24, $3a
defb $f9, $c0, $b0, $22, $34, $39, $31, $35, $32, $22, $0d, $ff, $0d, $80
newProgEnd:
hello:
ld a, 2 ; upper screen
call 0x1601 ; open channel
ld hl, msg
loop:
ld a, (hl)
or a
jr z, exit
cp 0x0d
jr z, dee
cp 0x0a
jr z, ay
print:
rst 16
inc hl
jr loop
exit:
ret
dee:
ld a, 0x0a
jr print
ay:
ld a, 0x0d
jr print
msg:
defb "Hello, World!\n", 0
| pjshumphreys/querycsv | env/zx/backups/replace.asm | Assembly | mit | 1,186 |
; Ejercicio 7 del TP 2.
aseg
org 1000h
start: ld A, 13h ; carga registro A con 13h
add A, 20h ; se suma 20h
add A, 0CFh ; se suma CFh
rst 38h
end start
| scoffey/jz80sim | test/jzas/sintactic/valid/success30.asm | Assembly | mit | 218 |
kp_song
kp_reloc
dc.w kp_song_registers
dc.w kp_speed
dc.w kp_grooveboxpos
dc.w kp_grooveboxlen
dc.w kp_groovebox
dc.w kp_patternlen
dc.w kp_patternmap_lo
dc.w kp_patternmap_hi
dc.w kp_insmap_lo
dc.w kp_insmap_hi
dc.w kp_volmap_lo
dc.w kp_volmap_hi
dc.w kp_sequence
kp_song_registers
kp_speed
dc.b $02
kp_grooveboxpos
dc.b $00
kp_grooveboxlen
dc.b $04
kp_groovebox
dc.b $06
dc.b $05
dc.b $07
dc.b $06
dc.b $05
dc.b $04
dc.b $06
dc.b $04
kp_patternlen
dc.b $3F
kp_patternmap_lo
dc.b #<patnil
dc.b #<pat1
dc.b #<pat2
dc.b #<pat3
dc.b #<pat4
dc.b #<pat5
dc.b #<pat6
dc.b #<pat7
dc.b #<pat8
dc.b #<pat9
dc.b #<pat10
dc.b #<pat11
dc.b #<pat12
dc.b #<pat13
kp_patternmap_hi
dc.b #>patnil
dc.b #>pat1
dc.b #>pat2
dc.b #>pat3
dc.b #>pat4
dc.b #>pat5
dc.b #>pat6
dc.b #>pat7
dc.b #>pat8
dc.b #>pat9
dc.b #>pat10
dc.b #>pat11
dc.b #>pat12
dc.b #>pat13
patnil
kp_setinstrument 8,0
kp_settrackregister 0,16
kp_rewind $00
pat1
pat1loop
kp_settrackregister $01,$10
kp_settrackregister $03,$0F
kp_setinstrument $01,$01
kp_settrackregister $03,$09
kp_settrackregister $00,$01
kp_settrackregister $03,$0F
kp_setinstrument $01,$01
kp_settrackregister $03,$09
kp_settrackregister $00,$01
kp_settrackregister $01,$30
kp_settrackregister $03,$0F
kp_setinstrument $02,$02
kp_settrackregister $01,$10
kp_setinstrument $01,$01
kp_settrackregister $03,$09
kp_settrackregister $00,$01
kp_settrackregister $03,$0F
kp_setinstrument $01,$01
kp_settrackregister $03,$09
kp_settrackregister $00,$01
kp_settrackregister $03,$0F
kp_setinstrument $01,$01
kp_settrackregister $03,$09
kp_settrackregister $00,$01
kp_settrackregister $01,$30
kp_settrackregister $03,$0F
kp_setinstrument $02,$02
kp_settrackregister $01,$10
kp_setinstrument $01,$01
kp_settrackregister $03,$09
kp_settrackregister $00,$03
kp_settrackregister $03,$0F
kp_setinstrument $01,$01
kp_settrackregister $03,$09
kp_settrackregister $00,$01
kp_settrackregister $01,$30
kp_settrackregister $03,$0F
kp_setinstrument $02,$02
kp_settrackregister $01,$10
kp_setinstrument $01,$01
kp_settrackregister $03,$09
kp_settrackregister $00,$01
kp_settrackregister $03,$0F
kp_setinstrument $01,$01
kp_settrackregister $03,$09
kp_settrackregister $00,$01
kp_settrackregister $03,$0F
kp_setinstrument $01,$01
kp_settrackregister $03,$09
kp_settrackregister $00,$01
kp_settrackregister $01,$30
kp_settrackregister $03,$0F
kp_setinstrument $02,$02
kp_settrackregister $01,$10
kp_setinstrument $01,$01
kp_settrackregister $03,$09
kp_settrackregister $00,$01
kp_settrackregister $03,$0F
kp_setinstrument $01,$01
kp_settrackregister $03,$09
kp_settrackregister $00,$01
kp_settrackregister $03,$0F
kp_setinstrument $01,$01
kp_settrackregister $03,$09
kp_settrackregister $00,$01
kp_settrackregister $01,$30
kp_settrackregister $03,$0F
kp_setinstrument $02,$02
kp_settrackregister $01,$10
kp_setinstrument $01,$01
kp_settrackregister $03,$09
kp_settrackregister $00,$01
kp_settrackregister $03,$0F
kp_setinstrument $01,$01
kp_settrackregister $03,$09
kp_settrackregister $00,$01
kp_settrackregister $03,$0F
kp_setinstrument $01,$01
kp_settrackregister $03,$09
kp_settrackregister $00,$01
kp_settrackregister $01,$30
kp_settrackregister $03,$0F
kp_setinstrument $02,$02
kp_settrackregister $01,$10
kp_setinstrument $01,$01
kp_settrackregister $03,$09
kp_settrackregister $00,$03
kp_settrackregister $03,$0F
kp_setinstrument $01,$01
kp_settrackregister $03,$09
kp_settrackregister $00,$01
kp_settrackregister $01,$30
kp_settrackregister $03,$0F
kp_setinstrument $02,$02
kp_settrackregister $01,$10
kp_setinstrument $01,$01
kp_settrackregister $03,$09
kp_settrackregister $00,$01
kp_settrackregister $03,$0F
kp_setinstrument $01,$01
kp_settrackregister $03,$09
kp_settrackregister $00,$01
kp_settrackregister $03,$0F
kp_setinstrument $01,$01
kp_settrackregister $03,$09
kp_settrackregister $00,$01
kp_settrackregister $01,$30
kp_settrackregister $03,$0F
kp_setinstrument $02,$02
kp_setinstrument $01,$02
kp_settrackregister $03,$09
kp_settrackregister $00,$01
kp_rewind [pat1loop-pat1]
pat2
pat2loop
kp_settrackregister $01,$70
kp_settrackregister $03,$0B
kp_setinstrument $01,$03
kp_settrackregister $03,$0A
kp_settrackregister $00,$01
kp_settrackregister $01,$68
kp_settrackregister $03,$0B
kp_setinstrument $01,$03
kp_settrackregister $03,$0A
kp_settrackregister $00,$01
kp_settrackregister $01,$70
kp_settrackregister $03,$0B
kp_setinstrument $01,$03
kp_settrackregister $03,$0A
kp_settrackregister $00,$01
kp_settrackregister $03,$0B
kp_setinstrument $01,$03
kp_settrackregister $03,$0A
kp_settrackregister $00,$01
kp_settrackregister $03,$0B
kp_setinstrument $01,$03
kp_settrackregister $03,$0A
kp_settrackregister $00,$01
kp_settrackregister $03,$0B
kp_setinstrument $01,$03
kp_settrackregister $03,$0A
kp_settrackregister $00,$01
kp_settrackregister $01,$7C
kp_settrackregister $03,$0B
kp_setinstrument $01,$03
kp_settrackregister $03,$0A
kp_settrackregister $00,$01
kp_settrackregister $01,$78
kp_settrackregister $03,$0B
kp_setinstrument $01,$03
kp_settrackregister $03,$0A
kp_settrackregister $00,$03
kp_settrackregister $01,$68
kp_settrackregister $03,$0B
kp_setinstrument $01,$03
kp_settrackregister $03,$0A
kp_settrackregister $00,$03
kp_settrackregister $01,$5C
kp_settrackregister $03,$0B
kp_setinstrument $01,$03
kp_settrackregister $03,$0A
kp_settrackregister $00,$01
kp_settrackregister $01,$68
kp_settrackregister $03,$0B
kp_setinstrument $01,$03
kp_settrackregister $03,$0A
kp_settrackregister $00,$01
kp_settrackregister $01,$70
kp_settrackregister $03,$0B
kp_setinstrument $01,$03
kp_settrackregister $03,$0A
kp_settrackregister $00,$01
kp_settrackregister $03,$0B
kp_setinstrument $01,$03
kp_settrackregister $03,$0A
kp_settrackregister $00,$01
kp_settrackregister $01,$5C
kp_settrackregister $03,$0B
kp_setinstrument $01,$03
kp_settrackregister $03,$0A
kp_settrackregister $00,$01
kp_settrackregister $01,$70
kp_settrackregister $03,$0B
kp_setinstrument $01,$03
kp_settrackregister $03,$0A
kp_settrackregister $00,$01
kp_settrackregister $01,$68
kp_settrackregister $03,$0B
kp_setinstrument $01,$03
kp_settrackregister $03,$0A
kp_settrackregister $00,$01
kp_settrackregister $01,$70
kp_settrackregister $03,$0B
kp_setinstrument $01,$03
kp_settrackregister $03,$0A
kp_settrackregister $00,$01
kp_settrackregister $03,$0B
kp_setinstrument $01,$03
kp_settrackregister $03,$0A
kp_settrackregister $00,$01
kp_settrackregister $03,$0B
kp_setinstrument $01,$03
kp_settrackregister $03,$0A
kp_settrackregister $00,$01
kp_settrackregister $03,$0B
kp_setinstrument $01,$03
kp_settrackregister $03,$0A
kp_settrackregister $00,$01
kp_settrackregister $01,$7C
kp_settrackregister $03,$0B
kp_setinstrument $01,$03
kp_settrackregister $03,$0A
kp_settrackregister $00,$01
kp_settrackregister $01,$78
kp_settrackregister $03,$0B
kp_setinstrument $01,$03
kp_settrackregister $03,$0A
kp_settrackregister $00,$03
kp_settrackregister $01,$68
kp_settrackregister $03,$0B
kp_setinstrument $01,$03
kp_settrackregister $03,$0A
kp_settrackregister $00,$03
kp_settrackregister $01,$54
kp_settrackregister $03,$0B
kp_setinstrument $01,$03
kp_settrackregister $03,$0A
kp_settrackregister $00,$01
kp_settrackregister $01,$84
kp_settrackregister $03,$0B
kp_setinstrument $01,$03
kp_settrackregister $03,$0A
kp_settrackregister $00,$01
kp_settrackregister $01,$7C
kp_settrackregister $03,$0B
kp_setinstrument $01,$03
kp_settrackregister $03,$0A
kp_settrackregister $00,$01
kp_settrackregister $01,$78
kp_settrackregister $03,$0B
kp_setinstrument $01,$03
kp_settrackregister $03,$0A
kp_settrackregister $00,$01
kp_settrackregister $01,$40
kp_settrackregister $03,$0B
kp_setinstrument $01,$03
kp_settrackregister $03,$0A
kp_settrackregister $00,$01
kp_rewind [pat2loop-pat2]
pat3
pat3loop
kp_settrackregister $01,$10
kp_settrackregister $03,$0F
kp_setinstrument $01,$01
kp_settrackregister $03,$09
kp_settrackregister $00,$01
kp_settrackregister $03,$0F
kp_setinstrument $01,$01
kp_settrackregister $03,$09
kp_settrackregister $00,$01
kp_settrackregister $01,$30
kp_settrackregister $03,$0F
kp_setinstrument $02,$02
kp_settrackregister $01,$10
kp_setinstrument $01,$01
kp_settrackregister $03,$09
kp_settrackregister $00,$01
kp_settrackregister $03,$0F
kp_setinstrument $01,$01
kp_settrackregister $03,$09
kp_settrackregister $00,$01
kp_settrackregister $03,$0F
kp_setinstrument $01,$01
kp_settrackregister $03,$09
kp_settrackregister $00,$01
kp_settrackregister $01,$30
kp_settrackregister $03,$0F
kp_setinstrument $02,$02
kp_settrackregister $01,$10
kp_setinstrument $01,$01
kp_settrackregister $03,$09
kp_settrackregister $00,$03
kp_settrackregister $03,$0F
kp_setinstrument $01,$01
kp_settrackregister $03,$09
kp_settrackregister $00,$01
kp_settrackregister $01,$30
kp_settrackregister $03,$0F
kp_setinstrument $02,$02
kp_settrackregister $01,$10
kp_setinstrument $01,$01
kp_settrackregister $03,$09
kp_settrackregister $00,$01
kp_settrackregister $03,$0F
kp_setinstrument $01,$01
kp_settrackregister $03,$09
kp_settrackregister $00,$01
kp_settrackregister $03,$0F
kp_setinstrument $01,$01
kp_settrackregister $03,$09
kp_settrackregister $00,$01
kp_settrackregister $01,$30
kp_settrackregister $03,$0F
kp_setinstrument $02,$02
kp_settrackregister $01,$10
kp_setinstrument $01,$01
kp_settrackregister $03,$09
kp_settrackregister $00,$01
kp_settrackregister $01,$00
kp_settrackregister $03,$0F
kp_setinstrument $01,$01
kp_settrackregister $03,$09
kp_settrackregister $00,$01
kp_settrackregister $03,$0F
kp_setinstrument $01,$01
kp_settrackregister $03,$09
kp_settrackregister $00,$01
kp_settrackregister $01,$30
kp_settrackregister $03,$0F
kp_setinstrument $02,$02
kp_settrackregister $01,$00
kp_setinstrument $01,$01
kp_settrackregister $03,$09
kp_settrackregister $00,$01
kp_settrackregister $03,$0F
kp_setinstrument $01,$01
kp_settrackregister $03,$09
kp_settrackregister $00,$01
kp_settrackregister $03,$0F
kp_setinstrument $01,$01
kp_settrackregister $03,$09
kp_settrackregister $00,$01
kp_settrackregister $01,$30
kp_settrackregister $03,$0F
kp_setinstrument $02,$02
kp_settrackregister $01,$00
kp_setinstrument $01,$01
kp_settrackregister $03,$09
kp_settrackregister $00,$03
kp_settrackregister $03,$0F
kp_setinstrument $01,$01
kp_settrackregister $03,$09
kp_settrackregister $00,$01
kp_settrackregister $01,$30
kp_settrackregister $03,$0F
kp_setinstrument $02,$02
kp_settrackregister $01,$00
kp_setinstrument $01,$01
kp_settrackregister $03,$09
kp_settrackregister $00,$01
kp_settrackregister $03,$0F
kp_setinstrument $01,$01
kp_settrackregister $03,$09
kp_settrackregister $00,$01
kp_settrackregister $03,$0F
kp_setinstrument $01,$01
kp_settrackregister $03,$09
kp_settrackregister $00,$01
kp_settrackregister $01,$30
kp_settrackregister $03,$0F
kp_setinstrument $02,$02
kp_settrackregister $01,$00
kp_setinstrument $01,$01
kp_settrackregister $03,$09
kp_settrackregister $00,$01
kp_rewind [pat3loop-pat3]
pat4
pat4loop
kp_settrackregister $01,$70
kp_settrackregister $03,$0B
kp_setinstrument $01,$03
kp_settrackregister $03,$0A
kp_settrackregister $00,$01
kp_settrackregister $01,$68
kp_settrackregister $03,$0B
kp_setinstrument $01,$03
kp_settrackregister $03,$0A
kp_settrackregister $00,$01
kp_settrackregister $01,$70
kp_settrackregister $03,$0B
kp_setinstrument $01,$03
kp_settrackregister $03,$0A
kp_settrackregister $00,$01
kp_settrackregister $03,$0B
kp_setinstrument $01,$03
kp_settrackregister $03,$0A
kp_settrackregister $00,$01
kp_settrackregister $03,$0B
kp_setinstrument $01,$03
kp_settrackregister $03,$0A
kp_settrackregister $00,$01
kp_settrackregister $03,$0B
kp_setinstrument $01,$03
kp_settrackregister $03,$0A
kp_settrackregister $00,$01
kp_settrackregister $01,$7C
kp_settrackregister $03,$0B
kp_setinstrument $01,$03
kp_settrackregister $03,$0A
kp_settrackregister $00,$01
kp_settrackregister $01,$78
kp_settrackregister $03,$0B
kp_setinstrument $01,$03
kp_settrackregister $03,$0A
kp_settrackregister $00,$03
kp_settrackregister $01,$68
kp_settrackregister $03,$0B
kp_setinstrument $01,$03
kp_settrackregister $03,$0A
kp_settrackregister $00,$03
kp_settrackregister $01,$5C
kp_settrackregister $03,$0B
kp_setinstrument $01,$03
kp_settrackregister $03,$0A
kp_settrackregister $00,$01
kp_settrackregister $01,$68
kp_settrackregister $03,$0B
kp_setinstrument $01,$03
kp_settrackregister $03,$0A
kp_settrackregister $00,$01
kp_settrackregister $01,$70
kp_settrackregister $03,$0B
kp_setinstrument $01,$03
kp_settrackregister $03,$0A
kp_settrackregister $00,$01
kp_settrackregister $03,$0B
kp_setinstrument $01,$03
kp_settrackregister $03,$0A
kp_settrackregister $00,$01
kp_settrackregister $01,$5C
kp_settrackregister $03,$0B
kp_setinstrument $01,$03
kp_settrackregister $03,$0A
kp_settrackregister $00,$01
kp_settrackregister $01,$70
kp_settrackregister $03,$0B
kp_setinstrument $01,$03
kp_settrackregister $03,$0A
kp_settrackregister $00,$01
kp_settrackregister $01,$68
kp_settrackregister $03,$0B
kp_setinstrument $01,$03
kp_settrackregister $03,$0A
kp_settrackregister $00,$01
kp_settrackregister $01,$70
kp_settrackregister $03,$0B
kp_setinstrument $01,$03
kp_settrackregister $03,$0A
kp_settrackregister $00,$01
kp_settrackregister $03,$0B
kp_setinstrument $01,$03
kp_settrackregister $03,$0A
kp_settrackregister $00,$01
kp_settrackregister $03,$0B
kp_setinstrument $01,$03
kp_settrackregister $03,$0A
kp_settrackregister $00,$01
kp_settrackregister $03,$0B
kp_setinstrument $01,$03
kp_settrackregister $03,$0A
kp_settrackregister $00,$01
kp_settrackregister $01,$7C
kp_settrackregister $03,$0B
kp_setinstrument $01,$03
kp_settrackregister $03,$0A
kp_settrackregister $00,$01
kp_settrackregister $01,$78
kp_settrackregister $03,$0B
kp_setinstrument $01,$03
kp_settrackregister $03,$0A
kp_settrackregister $00,$03
kp_settrackregister $01,$68
kp_settrackregister $03,$0B
kp_setinstrument $01,$03
kp_settrackregister $03,$0A
kp_settrackregister $00,$03
kp_settrackregister $01,$54
kp_settrackregister $03,$0B
kp_setinstrument $01,$03
kp_settrackregister $03,$0A
kp_settrackregister $00,$01
kp_settrackregister $01,$84
kp_settrackregister $03,$0B
kp_setinstrument $01,$03
kp_settrackregister $03,$0A
kp_settrackregister $00,$01
kp_settrackregister $01,$8C
kp_settrackregister $03,$0B
kp_setinstrument $01,$03
kp_settrackregister $03,$0A
kp_settrackregister $00,$01
kp_settrackregister $01,$78
kp_settrackregister $03,$0B
kp_setinstrument $01,$03
kp_settrackregister $03,$0A
kp_settrackregister $00,$01
kp_settrackregister $01,$54
kp_settrackregister $03,$0B
kp_setinstrument $01,$03
kp_settrackregister $03,$0A
kp_settrackregister $00,$01
kp_rewind [pat4loop-pat4]
pat5
pat5loop
kp_settrackregister $01,$08
kp_settrackregister $03,$0F
kp_setinstrument $01,$01
kp_settrackregister $03,$09
kp_settrackregister $00,$01
kp_settrackregister $03,$0F
kp_setinstrument $01,$01
kp_settrackregister $03,$09
kp_settrackregister $00,$01
kp_settrackregister $01,$30
kp_settrackregister $03,$0F
kp_setinstrument $02,$02
kp_settrackregister $01,$08
kp_setinstrument $01,$01
kp_settrackregister $03,$09
kp_settrackregister $00,$01
kp_settrackregister $03,$0F
kp_setinstrument $01,$01
kp_settrackregister $03,$09
kp_settrackregister $00,$01
kp_settrackregister $03,$0F
kp_setinstrument $01,$01
kp_settrackregister $03,$09
kp_settrackregister $00,$01
kp_settrackregister $01,$30
kp_settrackregister $03,$0F
kp_setinstrument $02,$02
kp_settrackregister $01,$08
kp_setinstrument $01,$01
kp_settrackregister $03,$09
kp_settrackregister $00,$03
kp_settrackregister $03,$0F
kp_setinstrument $01,$01
kp_settrackregister $03,$09
kp_settrackregister $00,$01
kp_settrackregister $01,$30
kp_settrackregister $03,$0F
kp_setinstrument $02,$02
kp_settrackregister $01,$08
kp_setinstrument $01,$01
kp_settrackregister $03,$09
kp_settrackregister $00,$01
kp_settrackregister $03,$0F
kp_setinstrument $01,$01
kp_settrackregister $03,$09
kp_settrackregister $00,$01
kp_settrackregister $03,$0F
kp_setinstrument $01,$01
kp_settrackregister $03,$09
kp_settrackregister $00,$01
kp_settrackregister $01,$30
kp_settrackregister $03,$0F
kp_setinstrument $02,$02
kp_settrackregister $01,$08
kp_setinstrument $01,$01
kp_settrackregister $03,$09
kp_settrackregister $00,$01
kp_settrackregister $01,$24
kp_settrackregister $03,$0F
kp_setinstrument $01,$01
kp_settrackregister $03,$09
kp_settrackregister $00,$01
kp_settrackregister $03,$0F
kp_setinstrument $01,$01
kp_settrackregister $03,$09
kp_settrackregister $00,$01
kp_settrackregister $01,$30
kp_settrackregister $03,$0F
kp_setinstrument $02,$02
kp_settrackregister $01,$24
kp_setinstrument $01,$01
kp_settrackregister $03,$09
kp_settrackregister $00,$01
kp_settrackregister $03,$0F
kp_setinstrument $01,$01
kp_settrackregister $03,$09
kp_settrackregister $00,$01
kp_settrackregister $03,$0F
kp_setinstrument $01,$01
kp_settrackregister $03,$09
kp_settrackregister $00,$01
kp_settrackregister $01,$30
kp_settrackregister $03,$0F
kp_setinstrument $02,$02
kp_settrackregister $01,$24
kp_setinstrument $01,$01
kp_settrackregister $03,$09
kp_settrackregister $00,$03
kp_settrackregister $03,$0F
kp_setinstrument $01,$01
kp_settrackregister $03,$09
kp_settrackregister $00,$01
kp_settrackregister $01,$30
kp_settrackregister $03,$0F
kp_setinstrument $02,$02
kp_settrackregister $01,$24
kp_setinstrument $01,$01
kp_settrackregister $03,$09
kp_settrackregister $00,$01
kp_settrackregister $03,$0F
kp_setinstrument $01,$01
kp_settrackregister $03,$09
kp_settrackregister $00,$01
kp_settrackregister $03,$0F
kp_setinstrument $01,$01
kp_settrackregister $03,$09
kp_settrackregister $00,$01
kp_settrackregister $01,$30
kp_settrackregister $03,$0F
kp_setinstrument $02,$02
kp_settrackregister $01,$24
kp_setinstrument $01,$01
kp_settrackregister $03,$09
kp_settrackregister $00,$01
kp_rewind [pat5loop-pat5]
pat6
pat6loop
kp_settrackregister $01,$70
kp_settrackregister $03,$0C
kp_setinstrument $02,$04
kp_settrackregister $01,$78
kp_setinstrument $02,$04
kp_settrackregister $01,$7C
kp_setinstrument $02,$04
kp_settrackregister $03,$09
kp_settrackregister $00,$06
kp_settrackregister $01,$84
kp_settrackregister $03,$0C
kp_setinstrument $02,$04
kp_settrackregister $01,$8C
kp_setinstrument $02,$04
kp_settrackregister $03,$09
kp_settrackregister $00,$02
kp_settrackregister $01,$84
kp_settrackregister $03,$0C
kp_setinstrument $02,$04
kp_settrackregister $03,$09
kp_settrackregister $00,$02
kp_settrackregister $01,$7C
kp_settrackregister $03,$0C
kp_setinstrument $02,$04
kp_settrackregister $03,$09
kp_settrackregister $00,$02
kp_settrackregister $01,$84
kp_settrackregister $03,$0C
kp_setinstrument $02,$04
kp_settrackregister $03,$09
kp_settrackregister $00,$02
kp_settrackregister $01,$90
kp_settrackregister $03,$0C
kp_setinstrument $02,$04
kp_settrackregister $03,$09
kp_settrackregister $00,$02
kp_settrackregister $01,$8C
kp_settrackregister $03,$0C
kp_setinstrument $02,$04
kp_settrackregister $03,$09
kp_settrackregister $00,$02
kp_settrackregister $01,$7C
kp_settrackregister $03,$0C
kp_setinstrument $02,$04
kp_settrackregister $03,$09
kp_settrackregister $00,$02
kp_settrackregister $01,$70
kp_settrackregister $03,$0C
kp_setinstrument $02,$04
kp_settrackregister $03,$09
kp_settrackregister $00,$02
kp_settrackregister $01,$60
kp_settrackregister $03,$0C
kp_setinstrument $02,$04
kp_settrackregister $03,$09
kp_settrackregister $00,$02
kp_settrackregister $01,$7C
kp_settrackregister $03,$0B
kp_setinstrument $01,$03
kp_settrackregister $03,$0A
kp_settrackregister $00,$01
kp_settrackregister $03,$0B
kp_setinstrument $01,$03
kp_settrackregister $03,$0A
kp_settrackregister $00,$01
kp_settrackregister $03,$0B
kp_setinstrument $01,$03
kp_settrackregister $03,$0A
kp_settrackregister $00,$01
kp_settrackregister $01,$84
kp_settrackregister $03,$0B
kp_setinstrument $01,$03
kp_settrackregister $03,$0A
kp_settrackregister $00,$02
kp_settrackregister $03,$09
kp_settrackregister $00,$01
kp_settrackregister $01,$7C
kp_settrackregister $03,$0B
kp_setinstrument $01,$03
kp_settrackregister $03,$0A
kp_settrackregister $00,$03
kp_rewind [pat6loop-pat6]
pat7
pat7loop
kp_settrackregister $01,$98
kp_settrackregister $03,$0C
kp_setinstrument $02,$04
kp_settrackregister $01,$90
kp_setinstrument $02,$04
kp_settrackregister $03,$09
kp_settrackregister $00,$02
kp_settrackregister $01,$8C
kp_settrackregister $03,$0C
kp_setinstrument $02,$04
kp_settrackregister $03,$09
kp_settrackregister $00,$02
kp_settrackregister $01,$84
kp_settrackregister $03,$0C
kp_setinstrument $02,$04
kp_settrackregister $03,$09
kp_settrackregister $00,$02
kp_settrackregister $01,$90
kp_settrackregister $03,$0C
kp_setinstrument $02,$04
kp_settrackregister $03,$09
kp_settrackregister $00,$02
kp_settrackregister $01,$8C
kp_settrackregister $03,$0C
kp_setinstrument $02,$04
kp_settrackregister $03,$09
kp_settrackregister $00,$02
kp_settrackregister $01,$84
kp_settrackregister $03,$0C
kp_setinstrument $02,$04
kp_settrackregister $03,$09
kp_settrackregister $00,$02
kp_settrackregister $01,$7C
kp_settrackregister $03,$0C
kp_setinstrument $02,$04
kp_settrackregister $01,$84
kp_setinstrument $02,$04
kp_settrackregister $03,$09
kp_settrackregister $00,$14
kp_settrackregister $01,$8C
kp_settrackregister $03,$0B
kp_setinstrument $01,$03
kp_settrackregister $03,$0A
kp_settrackregister $00,$01
kp_settrackregister $03,$0B
kp_setinstrument $01,$03
kp_settrackregister $03,$0A
kp_settrackregister $00,$01
kp_settrackregister $03,$0B
kp_setinstrument $01,$03
kp_settrackregister $03,$0A
kp_settrackregister $00,$01
kp_settrackregister $01,$7C
kp_settrackregister $03,$0B
kp_setinstrument $01,$03
kp_settrackregister $03,$0A
kp_settrackregister $00,$03
kp_settrackregister $01,$78
kp_settrackregister $03,$0B
kp_setinstrument $01,$03
kp_settrackregister $03,$0A
kp_settrackregister $00,$03
kp_rewind [pat7loop-pat7]
pat8
pat8loop
kp_settrackregister $01,$08
kp_settrackregister $03,$0F
kp_setinstrument $01,$01
kp_settrackregister $03,$09
kp_settrackregister $00,$01
kp_settrackregister $03,$0F
kp_setinstrument $01,$01
kp_settrackregister $03,$09
kp_settrackregister $00,$01
kp_settrackregister $01,$30
kp_settrackregister $03,$0F
kp_setinstrument $02,$02
kp_settrackregister $01,$08
kp_setinstrument $01,$01
kp_settrackregister $03,$09
kp_settrackregister $00,$01
kp_settrackregister $03,$0F
kp_setinstrument $01,$01
kp_settrackregister $03,$09
kp_settrackregister $00,$01
kp_settrackregister $03,$0F
kp_setinstrument $01,$01
kp_settrackregister $03,$09
kp_settrackregister $00,$01
kp_settrackregister $01,$30
kp_settrackregister $03,$0F
kp_setinstrument $02,$02
kp_settrackregister $01,$08
kp_setinstrument $01,$01
kp_settrackregister $03,$09
kp_settrackregister $00,$03
kp_settrackregister $03,$0F
kp_setinstrument $01,$01
kp_settrackregister $03,$09
kp_settrackregister $00,$01
kp_settrackregister $01,$30
kp_settrackregister $03,$0F
kp_setinstrument $02,$02
kp_settrackregister $01,$08
kp_setinstrument $01,$01
kp_settrackregister $03,$09
kp_settrackregister $00,$01
kp_settrackregister $03,$0F
kp_setinstrument $01,$01
kp_settrackregister $03,$09
kp_settrackregister $00,$01
kp_settrackregister $03,$0F
kp_setinstrument $01,$01
kp_settrackregister $03,$09
kp_settrackregister $00,$01
kp_settrackregister $01,$30
kp_settrackregister $03,$0F
kp_setinstrument $02,$02
kp_settrackregister $01,$08
kp_setinstrument $01,$01
kp_settrackregister $03,$09
kp_settrackregister $00,$01
kp_settrackregister $01,$24
kp_settrackregister $03,$0F
kp_setinstrument $01,$01
kp_settrackregister $03,$09
kp_settrackregister $00,$01
kp_settrackregister $03,$0F
kp_setinstrument $01,$01
kp_settrackregister $03,$09
kp_settrackregister $00,$01
kp_settrackregister $01,$30
kp_settrackregister $03,$0F
kp_setinstrument $02,$02
kp_settrackregister $01,$24
kp_setinstrument $01,$01
kp_settrackregister $03,$09
kp_settrackregister $00,$01
kp_settrackregister $03,$0F
kp_setinstrument $01,$01
kp_settrackregister $03,$09
kp_settrackregister $00,$01
kp_settrackregister $03,$0F
kp_setinstrument $01,$01
kp_settrackregister $03,$09
kp_settrackregister $00,$01
kp_settrackregister $01,$30
kp_settrackregister $03,$0F
kp_setinstrument $02,$02
kp_settrackregister $01,$24
kp_setinstrument $01,$01
kp_settrackregister $03,$09
kp_settrackregister $00,$03
kp_settrackregister $01,$30
kp_settrackregister $03,$0F
kp_setinstrument $02,$02
kp_setinstrument $02,$02
kp_setinstrument $02,$02
kp_setinstrument $02,$02
kp_settrackregister $01,$24
kp_setinstrument $01,$01
kp_settrackregister $03,$09
kp_settrackregister $00,$01
kp_settrackregister $01,$30
kp_settrackregister $03,$0F
kp_setinstrument $02,$02
kp_settrackregister $01,$24
kp_setinstrument $01,$01
kp_settrackregister $03,$09
kp_settrackregister $00,$01
kp_rewind [pat8loop-pat8]
pat9
pat9loop
kp_settrackregister $01,$A0
kp_settrackregister $03,$0C
kp_setinstrument $02,$04
kp_settrackregister $01,$8C
kp_setinstrument $02,$04
kp_settrackregister $01,$7C
kp_setinstrument $02,$04
kp_settrackregister $03,$09
kp_settrackregister $00,$06
kp_settrackregister $01,$84
kp_settrackregister $03,$0C
kp_setinstrument $02,$04
kp_settrackregister $01,$8C
kp_setinstrument $02,$04
kp_settrackregister $03,$09
kp_settrackregister $00,$02
kp_settrackregister $01,$84
kp_settrackregister $03,$0C
kp_setinstrument $02,$04
kp_settrackregister $03,$09
kp_settrackregister $00,$02
kp_settrackregister $01,$7C
kp_settrackregister $03,$0C
kp_setinstrument $02,$04
kp_settrackregister $03,$09
kp_settrackregister $00,$02
kp_settrackregister $01,$84
kp_settrackregister $03,$0C
kp_setinstrument $02,$04
kp_settrackregister $03,$09
kp_settrackregister $00,$02
kp_settrackregister $01,$98
kp_settrackregister $03,$0C
kp_setinstrument $02,$04
kp_settrackregister $03,$09
kp_settrackregister $00,$02
kp_settrackregister $01,$90
kp_settrackregister $03,$0C
kp_setinstrument $02,$04
kp_settrackregister $03,$09
kp_settrackregister $00,$02
kp_settrackregister $01,$7C
kp_settrackregister $03,$0C
kp_setinstrument $02,$04
kp_settrackregister $03,$09
kp_settrackregister $00,$02
kp_settrackregister $01,$84
kp_settrackregister $03,$0C
kp_setinstrument $02,$04
kp_settrackregister $03,$09
kp_settrackregister $00,$02
kp_settrackregister $01,$70
kp_settrackregister $03,$0C
kp_setinstrument $02,$04
kp_settrackregister $03,$09
kp_settrackregister $00,$02
kp_settrackregister $01,$7C
kp_settrackregister $03,$0B
kp_setinstrument $01,$03
kp_settrackregister $03,$0A
kp_settrackregister $00,$01
kp_settrackregister $03,$0B
kp_setinstrument $01,$03
kp_settrackregister $03,$0A
kp_settrackregister $00,$01
kp_settrackregister $03,$0B
kp_setinstrument $01,$03
kp_settrackregister $03,$0A
kp_settrackregister $00,$01
kp_settrackregister $01,$84
kp_settrackregister $03,$0B
kp_setinstrument $01,$03
kp_settrackregister $03,$0A
kp_settrackregister $00,$02
kp_settrackregister $03,$09
kp_settrackregister $00,$01
kp_settrackregister $01,$78
kp_settrackregister $03,$0B
kp_setinstrument $01,$03
kp_settrackregister $03,$0A
kp_settrackregister $00,$03
kp_rewind [pat9loop-pat9]
pat10
pat10loop
kp_settrackregister $01,$98
kp_settrackregister $03,$0C
kp_setinstrument $02,$04
kp_settrackregister $01,$90
kp_setinstrument $02,$04
kp_settrackregister $03,$09
kp_settrackregister $00,$02
kp_settrackregister $01,$8C
kp_settrackregister $03,$0C
kp_setinstrument $02,$04
kp_settrackregister $03,$09
kp_settrackregister $00,$02
kp_settrackregister $01,$98
kp_settrackregister $03,$0C
kp_setinstrument $02,$04
kp_settrackregister $03,$09
kp_settrackregister $00,$02
kp_settrackregister $01,$90
kp_settrackregister $03,$0C
kp_setinstrument $02,$04
kp_settrackregister $03,$09
kp_settrackregister $00,$02
kp_settrackregister $01,$8C
kp_settrackregister $03,$0C
kp_setinstrument $02,$04
kp_settrackregister $03,$09
kp_settrackregister $00,$02
kp_settrackregister $01,$84
kp_settrackregister $03,$0C
kp_setinstrument $02,$04
kp_settrackregister $03,$09
kp_settrackregister $00,$02
kp_settrackregister $01,$7C
kp_settrackregister $03,$0C
kp_setinstrument $02,$04
kp_settrackregister $01,$84
kp_setinstrument $02,$04
kp_settrackregister $03,$09
kp_settrackregister $00,$14
kp_settrackregister $01,$70
kp_settrackregister $03,$0B
kp_setinstrument $01,$03
kp_settrackregister $03,$0A
kp_settrackregister $00,$01
kp_settrackregister $03,$0B
kp_setinstrument $01,$03
kp_settrackregister $03,$0A
kp_settrackregister $00,$01
kp_settrackregister $01,$8C
kp_settrackregister $03,$0B
kp_setinstrument $01,$03
kp_settrackregister $03,$0A
kp_settrackregister $00,$01
kp_settrackregister $01,$7C
kp_settrackregister $03,$0B
kp_setinstrument $01,$03
kp_settrackregister $03,$0A
kp_settrackregister $00,$03
kp_settrackregister $01,$78
kp_settrackregister $03,$0B
kp_setinstrument $01,$03
kp_settrackregister $03,$0A
kp_settrackregister $00,$03
kp_rewind [pat10loop-pat10]
pat11
pat11loop
kp_settrackregister $01,$8C
kp_settrackregister $03,$0C
kp_setinstrument $02,$05
kp_settrackregister $03,$0D
kp_settrackregister $00,$02
kp_settrackregister $01,$7C
kp_settrackregister $03,$0C
kp_setinstrument $02,$05
kp_settrackregister $03,$0D
kp_settrackregister $00,$02
kp_settrackregister $01,$70
kp_settrackregister $03,$0C
kp_setinstrument $02,$05
kp_settrackregister $03,$0D
kp_settrackregister $00,$02
kp_settrackregister $01,$68
kp_settrackregister $03,$0C
kp_setinstrument $02,$05
kp_settrackregister $01,$70
kp_setinstrument $02,$05
kp_settrackregister $03,$0D
kp_settrackregister $00,$02
kp_settrackregister $01,$7C
kp_settrackregister $03,$0C
kp_setinstrument $02,$05
kp_settrackregister $03,$0D
kp_settrackregister $00,$02
kp_settrackregister $03,$0C
kp_setinstrument $02,$05
kp_settrackregister $01,$90
kp_setinstrument $02,$05
kp_settrackregister $01,$8C
kp_setinstrument $02,$05
kp_settrackregister $01,$84
kp_setinstrument $02,$05
kp_settrackregister $01,$7C
kp_setinstrument $02,$05
kp_settrackregister $01,$90
kp_setinstrument $02,$05
kp_settrackregister $03,$0D
kp_settrackregister $00,$02
kp_settrackregister $01,$7C
kp_settrackregister $03,$0C
kp_setinstrument $02,$05
kp_settrackregister $03,$0D
kp_settrackregister $00,$02
kp_settrackregister $01,$70
kp_settrackregister $03,$0C
kp_setinstrument $02,$05
kp_settrackregister $03,$0D
kp_settrackregister $00,$02
kp_settrackregister $01,$68
kp_settrackregister $03,$0C
kp_setinstrument $02,$05
kp_settrackregister $01,$70
kp_setinstrument $02,$05
kp_settrackregister $03,$0D
kp_settrackregister $00,$02
kp_settrackregister $01,$7C
kp_settrackregister $03,$0C
kp_setinstrument $02,$05
kp_settrackregister $03,$0D
kp_settrackregister $00,$02
kp_settrackregister $01,$70
kp_settrackregister $03,$0C
kp_setinstrument $02,$05
kp_settrackregister $01,$68
kp_setinstrument $02,$05
kp_settrackregister $01,$70
kp_setinstrument $02,$05
kp_settrackregister $01,$7C
kp_setinstrument $02,$05
kp_settrackregister $01,$78
kp_setinstrument $02,$05
kp_rewind [pat11loop-pat11]
pat12
pat12loop
kp_settrackregister $01,$84
kp_settrackregister $03,$0C
kp_setinstrument $02,$05
kp_settrackregister $03,$0D
kp_settrackregister $00,$02
kp_settrackregister $01,$78
kp_settrackregister $03,$0C
kp_setinstrument $02,$05
kp_settrackregister $03,$0D
kp_settrackregister $00,$02
kp_settrackregister $01,$70
kp_settrackregister $03,$0C
kp_setinstrument $02,$05
kp_settrackregister $03,$0D
kp_settrackregister $00,$02
kp_settrackregister $01,$68
kp_settrackregister $03,$0C
kp_setinstrument $02,$05
kp_settrackregister $01,$70
kp_setinstrument $02,$05
kp_settrackregister $03,$0D
kp_settrackregister $00,$02
kp_settrackregister $01,$78
kp_settrackregister $03,$0C
kp_setinstrument $02,$05
kp_settrackregister $03,$0D
kp_settrackregister $00,$02
kp_settrackregister $01,$68
kp_settrackregister $03,$0C
kp_setinstrument $02,$05
kp_settrackregister $01,$70
kp_setinstrument $02,$05
kp_settrackregister $01,$78
kp_setinstrument $02,$05
kp_settrackregister $01,$84
kp_setinstrument $02,$05
kp_settrackregister $01,$8C
kp_setinstrument $02,$05
kp_settrackregister $01,$84
kp_setinstrument $02,$05
kp_settrackregister $03,$0D
kp_settrackregister $00,$04
kp_settrackregister $03,$0C
kp_settrackregister $00,$0C
kp_settrackregister $01,$7C
kp_settrackregister $03,$0B
kp_setinstrument $01,$03
kp_settrackregister $03,$0A
kp_settrackregister $00,$01
kp_settrackregister $03,$0B
kp_setinstrument $01,$03
kp_settrackregister $03,$0A
kp_settrackregister $00,$01
kp_settrackregister $01,$84
kp_settrackregister $03,$0B
kp_setinstrument $01,$03
kp_settrackregister $03,$0A
kp_settrackregister $00,$01
kp_settrackregister $01,$78
kp_settrackregister $03,$0B
kp_setinstrument $01,$03
kp_settrackregister $03,$0A
kp_settrackregister $00,$03
kp_settrackregister $01,$70
kp_settrackregister $03,$0B
kp_setinstrument $01,$03
kp_settrackregister $03,$0A
kp_settrackregister $00,$03
kp_rewind [pat12loop-pat12]
pat13
pat13loop
kp_settrackregister $01,$98
kp_settrackregister $03,$0C
kp_setinstrument $02,$05
kp_settrackregister $03,$0D
kp_settrackregister $00,$02
kp_settrackregister $01,$90
kp_settrackregister $03,$0C
kp_setinstrument $02,$05
kp_settrackregister $03,$0D
kp_settrackregister $00,$02
kp_settrackregister $01,$8C
kp_settrackregister $03,$0C
kp_setinstrument $02,$05
kp_settrackregister $03,$0D
kp_settrackregister $00,$02
kp_settrackregister $01,$84
kp_settrackregister $03,$0C
kp_setinstrument $02,$05
kp_settrackregister $01,$90
kp_setinstrument $02,$05
kp_settrackregister $03,$0D
kp_settrackregister $00,$02
kp_settrackregister $01,$8C
kp_settrackregister $03,$0C
kp_setinstrument $02,$05
kp_settrackregister $03,$0D
kp_settrackregister $00,$02
kp_settrackregister $01,$68
kp_settrackregister $03,$0C
kp_setinstrument $02,$05
kp_settrackregister $01,$70
kp_setinstrument $02,$05
kp_settrackregister $01,$78
kp_setinstrument $02,$05
kp_settrackregister $01,$84
kp_setinstrument $02,$05
kp_settrackregister $01,$8C
kp_setinstrument $02,$05
kp_settrackregister $01,$84
kp_setinstrument $02,$05
kp_settrackregister $03,$0D
kp_settrackregister $00,$04
kp_settrackregister $03,$0C
kp_settrackregister $00,$0C
kp_settrackregister $01,$68
kp_settrackregister $03,$0B
kp_setinstrument $01,$03
kp_settrackregister $03,$0A
kp_settrackregister $00,$01
kp_settrackregister $03,$0B
kp_setinstrument $01,$03
kp_settrackregister $03,$0A
kp_settrackregister $00,$01
kp_settrackregister $03,$0B
kp_setinstrument $01,$03
kp_settrackregister $03,$0A
kp_settrackregister $00,$01
kp_settrackregister $01,$7C
kp_settrackregister $03,$0B
kp_setinstrument $01,$03
kp_settrackregister $03,$0A
kp_settrackregister $00,$03
kp_settrackregister $01,$78
kp_settrackregister $03,$0B
kp_setinstrument $01,$03
kp_settrackregister $03,$0A
kp_settrackregister $00,$03
kp_rewind [pat13loop-pat13]
kp_insmap_lo
dc.b #<insnil
dc.b #<ins1
dc.b #<ins2
dc.b #<ins3
dc.b #<ins4
dc.b #<ins5
kp_insmap_hi
dc.b #>insnil
dc.b #>ins1
dc.b #>ins2
dc.b #>ins3
dc.b #>ins4
dc.b #>ins5
kp_volmap_lo
dc.b #<volnil
dc.b #<vol1
dc.b #<vol2
dc.b #<vol3
dc.b #<vol4
dc.b #<vol5
kp_volmap_hi
dc.b #>volnil
dc.b #>vol1
dc.b #>vol2
dc.b #>vol3
dc.b #>vol4
dc.b #>vol5
insnil
KP_OSCV 0,0,0,0,15
KP_OSCJ 0
volnil
KP_VOLV 0,15
KP_VOLJ 0
ins1
KP_OSCV $00,0,1,1,$05
ins1loop
KP_OSCV $00,0,1,1,$03
KP_OSCJ [ins1loop-ins1]
vol1
KP_VOLV $07,$02
KP_VOLV $06,$01
KP_VOLV $05,$00
vol1loop
KP_VOLV $02,$00
KP_VOLJ [vol1loop-vol1]
ins2
KP_OSCV $CE,1,0,0,$00
KP_OSCV $58,0,1,0,$00
KP_OSCV $48,0,1,0,$00
ins2loop
KP_OSCV $D4,1,0,0,$00
KP_OSCV $D2,1,0,0,$00
KP_OSCJ [ins2loop-ins2]
vol2
KP_VOLV $0E,$00
KP_VOLV $0C,$00
KP_VOLV $0A,$00
KP_VOLV $08,$00
KP_VOLV $06,$00
KP_VOLV $04,$00
KP_VOLV $02,$00
KP_VOLV $01,$00
vol2loop
KP_VOLV $00,$00
KP_VOLJ [vol2loop-vol2]
ins3
ins3loop
KP_OSCV $00,0,1,1,$01
KP_OSCV $30,0,1,1,$01
KP_OSCV $90,0,1,1,$01
KP_OSCJ [ins3loop-ins3]
vol3
KP_VOLV $0A,$01
KP_VOLV $08,$01
KP_VOLV $07,$01
vol3loop
KP_VOLV $06,$01
KP_VOLJ [vol3loop-vol3]
ins4
KP_OSCV $24,0,1,1,$01
KP_OSCV $00,0,1,1,$00
ins4loop
KP_OSCV $00,0,1,1,$00
KP_OSCJ [ins4loop-ins4]
vol4
KP_VOLV $08,$00
vol4loop
KP_VOLV $07,$00
KP_VOLJ [vol4loop-vol4]
ins5
ins5loop
KP_OSCV $00,0,1,1,$00
KP_OSCJ [ins5loop-ins5]
vol5
KP_VOLV $0E,$00
KP_VOLV $0C,$00
KP_VOLV $0A,$00
KP_VOLV $09,$00
KP_VOLV $06,$00
KP_VOLV $04,$00
vol5loop
KP_VOLV $03,$01
KP_VOLJ [vol5loop-vol5]
kp_sequence
dc.b $00,$00,$01,$00
dc.b $00,$02,$03,$00
dc.b $00,$04,$05,$00
dc.b $00,$02,$03,$00
dc.b $00,$04,$05,$00
dc.b $00,$06,$03,$00
dc.b $00,$07,$08,$00
dc.b $00,$09,$03,$00
dc.b $00,$0A,$05,$00
dc.b $00,$0B,$03,$00
dc.b $00,$0C,$05,$00
dc.b $00,$0B,$03,$00
dc.b $00,$0D,$05,$00
dc.b $ff
dc.w $0030
| kosmonautdnb/TheLandsOfZador | Musics/LevelSongs/source/welt4_star1.asm | Assembly | mit | 37,560 |
; ASM source file created by SevenuP v1.20
; SevenuP (C) Copyright 2002-2006 by Jaime Tejedor Gomez, aka Metalbrain
;GRAPHIC DATA:
;Pixel Size: ( 24, 32)
;Char Size: ( 3, 4)
;Frames: 4
;Sort Priorities: X char, Char line, Y char, Frame number
;Data Outputted: Gfx
;Interleave: Sprite
;Mask: No
barbaro_espada_golpebajo:
DEFB 0, 0, 0, 0, 0, 0, 0, 0
DEFB 0, 0, 0, 0, 0, 0, 0, 0
DEFB 192, 0, 1, 32, 0, 2, 65,192
DEFB 2, 62, 32, 1, 0, 64, 2,128
DEFB 128, 2, 20, 0, 0, 30, 0, 3
DEFB 158, 0, 7,204,128, 56,128, 64
DEFB 63, 0,160, 7,226, 0, 0,253
DEFB 168, 3, 29,148, 0,234, 40, 0
DEFB 3, 0, 0,120, 0, 0, 4, 80
DEFB 0, 0,168, 0,193, 0, 6,240
DEFB 80, 7,120, 0, 7, 56, 64, 6
DEFB 248,128, 6,113, 80, 3, 2,168
DEFB 0, 0, 0, 0, 0, 0, 0, 0
DEFB 0, 0, 0, 0, 0, 0, 0, 0
DEFB 0, 0, 2, 0, 0, 5,128,128
DEFB 4,127, 64, 2, 0, 64, 3,128
DEFB 64, 4, 20,128, 0, 30, 0, 3
DEFB 158, 0, 7,204,128, 7,128, 64
DEFB 7,224,168, 3,252, 1, 0,255
DEFB 205, 1, 63,205, 0,128, 5, 0
DEFB 127, 0, 0, 58, 0, 0, 4, 80
DEFB 0, 0,168, 0,193, 0, 6,240
DEFB 80, 7,120, 0, 7, 56, 64, 6
DEFB 248,128, 6,113, 80, 3, 2,168
DEFB 0, 0, 0, 0, 0, 0, 0, 0
DEFB 0, 0, 0, 0, 0, 0, 0, 0
DEFB 0, 0, 0, 0, 0, 0, 0, 0
DEFB 0, 0, 0, 0, 0, 0, 0, 0
DEFB 0, 0, 0, 0, 0, 0, 0, 0
DEFB 0, 0, 0, 0, 0, 0, 0, 0
DEFB 0, 0, 0, 0, 0, 0,255,255
DEFB 240,255,255,240, 0, 0, 0, 0
DEFB 0, 0, 0, 0, 0, 0, 0, 0
DEFB 0, 0, 0, 0, 0, 0, 0, 0
DEFB 0, 0, 0, 0, 0, 0, 0, 0
DEFB 0, 0, 0, 0, 0, 0, 0, 0
DEFB 0, 0, 0, 0, 0, 3, 0, 0
DEFB 3, 0, 0, 3, 0, 7,195, 0
DEFB 8, 35, 0, 16, 19, 0, 34,150
DEFB 0, 3,214, 0,227,214, 1,241
DEFB 150, 1,250, 6, 1,238,198, 1
DEFB 246,204, 0,240, 12, 0,243,204
DEFB 0,109,140, 0,126, 30, 0, 31
DEFB 128, 0, 3,156, 0, 0, 24, 0
DEFB 0, 0, 0, 32, 64, 0,112,160
DEFB 0,121, 80, 0,120,168, 2, 56
DEFB 0, 7,188, 80, 7,156, 0, 6
DEFB 216,128, 2, 1, 80, 1,130,168 | fjpena/sword-of-ianna-zx | artwork/barbaro_espada_golpebajo.asm | Assembly | apache-2.0 | 2,189 |
LongLong:
.long 0x0001e240,0x00000000
.type LongLong,@object
.size LongLong,8
.align 4
.globl Int
Int:
.long 123
.type Int,@object
.size Int,4
.align 2
.globl Short
Short:
.word 4660
.type Short,@object
.size Short,2
.align 1
.globl Char
Char:
.byte -128
.type Char,@object
.size Char,1
.data
| ibuclaw/gcc-explorer | test/cases/icc-static.asm | Assembly | bsd-2-clause | 469 |
; asmsyntax=nasm
gdt:
gdt_null:
dd 0
dd 0
gdt_code:
dw 0xffff
dw 0
db 0
db 10011010b
db 11001111b
db 0
gdt_data:
dw 0xffff
dw 0
db 0
db 10010010b
db 11001111b
db 0
gdt_end:
gdt_desc:
dw gdt_end - gdt - 1
dd gdt
| duckinator/semplice | src/stage2/gdt.asm | Assembly | mit | 250 |
;;;
;;; tritiled22_nobutton.asm : PIC12F1571 code for CRxxxx LED glow marker
;;;
;;; 16ms flash period reduces flicker
;;; 2 pulses per loop increases brightness
;;; resets PIC every 256 flashes to re-initialize RAM values
;;;
;;; estimated run-times:
;;; CR2032 (220 mAh): 2 years
;;; CR2354 (560 mAh): 5 years
;;; CR2477 (1000 mAh): 10 years
;;;
LIST P=12LF1571
#include <p12lf1571.inc>
ERRORLEVEL -302
;;;
;;; OSCTUNE_VAL: set to fine-tune current draw for compensating for
;;; component tolerances
;;; -.32 = slowest frequency (highest LED power)
;;; .0 = factory-calibrated frequency
;;; +.31 = highest frequency (lowest LED power)
OSCTUNE_VAL equ +.31
;;;
;;; I/O pin configuration
;;;
GATE_DRIVE_A equ 4
GATE_DRIVE_B equ 5
__CONFIG _CONFIG1, _FOSC_INTOSC & _WDTE_ON & _PWRTE_OFF & _MCLRE_OFF & _CP_OFF & _BOREN_OFF & _CLKOUTEN_OFF
__CONFIG _CONFIG2, _WRT_OFF & _PLLEN_OFF & _STVREN_OFF & _BORV_HI & _LPBOREN_OFF & _LVP_ON
;;;
;;; variables in Common RAM (accessable from all banks)
;;;
CBLOCK 0x70
reset_counter
ENDC
ORG 0
RESET_VEC:
movlw .255
movwf reset_counter
BANKSEL OSCTUNE
movlw OSCTUNE_VAL & 0x3f
movwf OSCTUNE
BANKSEL ANSELA
movlw b'00000000' ; all digital I/O
movwf ANSELA
BANKSEL LATA
clrf LATA
BANKSEL TRISA
;; set gate driver lines as output
movlw ((0xff ^ (1 << GATE_DRIVE_A)) ^ (1 << GATE_DRIVE_B))
movwf TRISA
BANKSEL OSCCON
movlw b'00111011' ; 500 kHz MF osc
movwf OSCCON
BANKSEL WDTCON
movlw b'00001001' ; WDT 16ms timeout
movwf WDTCON
BANKSEL LATA
movlw (1 << GATE_DRIVE_A) | (1 << GATE_DRIVE_B)
MAIN_LOOP:
movwf LATA ;start inductor ramp-up
clrf LATA ;end inductor ramp-up
nop
nop
movwf LATA ;start inductor ramp-up
clrf LATA ;end inductor ramp-up
sleep
decfsz reset_counter
goto MAIN_LOOP
reset
;; fill remainder of program memory with reset instructions
fill (reset), 0x0400-$
END
| tedyapo/tritiled | software/tritiled22/src/tritiled22_nobutton.asm | Assembly | mit | 2,169 |
DEVICE ZXSPECTRUM128
nop ; this test can't have space in file name, because of `--sld=...` option
nop ; but this file is assembled twice! (as two input files)
| z00m128/sjasmplus | tests/test build script and options/opt sld/opt_sld_explicit.asm | Assembly | bsd-3-clause | 179 |
;
; jimmxint.asm - accurate integer IDCT (MMX)
;
; Copyright 2009 Pierre Ossman <ossman@cendio.se> for Cendio AB
;
; Based on
; x86 SIMD extension for IJG JPEG library
; Copyright (C) 1999-2006, MIYASAKA Masaru.
; For conditions of distribution and use, see copyright notice in jsimdext.inc
;
; This file should be assembled with NASM (Netwide Assembler),
; can *not* be assembled with Microsoft's MASM or any compatible
; assembler (including Borland's Turbo Assembler).
; NASM is available from http://nasm.sourceforge.net/ or
; http://sourceforge.net/project/showfiles.php?group_id=6208
;
; This file contains a slow-but-accurate integer implementation of the
; inverse DCT (Discrete Cosine Transform). The following code is based
; directly on the IJG's original jidctint.c; see the jidctint.c for
; more details.
;
; [TAB8]
%include "jsimdext.inc"
%include "jdct.inc"
; --------------------------------------------------------------------------
%define CONST_BITS 13
%define PASS1_BITS 2
%define DESCALE_P1 (CONST_BITS-PASS1_BITS)
%define DESCALE_P2 (CONST_BITS+PASS1_BITS+3)
%if CONST_BITS == 13
F_0_298 equ 2446 ; FIX(0.298631336)
F_0_390 equ 3196 ; FIX(0.390180644)
F_0_541 equ 4433 ; FIX(0.541196100)
F_0_765 equ 6270 ; FIX(0.765366865)
F_0_899 equ 7373 ; FIX(0.899976223)
F_1_175 equ 9633 ; FIX(1.175875602)
F_1_501 equ 12299 ; FIX(1.501321110)
F_1_847 equ 15137 ; FIX(1.847759065)
F_1_961 equ 16069 ; FIX(1.961570560)
F_2_053 equ 16819 ; FIX(2.053119869)
F_2_562 equ 20995 ; FIX(2.562915447)
F_3_072 equ 25172 ; FIX(3.072711026)
%else
; NASM cannot do compile-time arithmetic on floating-point constants.
%define DESCALE(x,n) (((x)+(1<<((n)-1)))>>(n))
F_0_298 equ DESCALE( 320652955,30-CONST_BITS) ; FIX(0.298631336)
F_0_390 equ DESCALE( 418953276,30-CONST_BITS) ; FIX(0.390180644)
F_0_541 equ DESCALE( 581104887,30-CONST_BITS) ; FIX(0.541196100)
F_0_765 equ DESCALE( 821806413,30-CONST_BITS) ; FIX(0.765366865)
F_0_899 equ DESCALE( 966342111,30-CONST_BITS) ; FIX(0.899976223)
F_1_175 equ DESCALE(1262586813,30-CONST_BITS) ; FIX(1.175875602)
F_1_501 equ DESCALE(1612031267,30-CONST_BITS) ; FIX(1.501321110)
F_1_847 equ DESCALE(1984016188,30-CONST_BITS) ; FIX(1.847759065)
F_1_961 equ DESCALE(2106220350,30-CONST_BITS) ; FIX(1.961570560)
F_2_053 equ DESCALE(2204520673,30-CONST_BITS) ; FIX(2.053119869)
F_2_562 equ DESCALE(2751909506,30-CONST_BITS) ; FIX(2.562915447)
F_3_072 equ DESCALE(3299298341,30-CONST_BITS) ; FIX(3.072711026)
%endif
; --------------------------------------------------------------------------
SECTION SEG_CONST
alignz 16
global EXTN(jconst_idct_islow_mmx)
EXTN(jconst_idct_islow_mmx):
PW_F130_F054 times 2 dw (F_0_541+F_0_765), F_0_541
PW_F054_MF130 times 2 dw F_0_541, (F_0_541-F_1_847)
PW_MF078_F117 times 2 dw (F_1_175-F_1_961), F_1_175
PW_F117_F078 times 2 dw F_1_175, (F_1_175-F_0_390)
PW_MF060_MF089 times 2 dw (F_0_298-F_0_899),-F_0_899
PW_MF089_F060 times 2 dw -F_0_899, (F_1_501-F_0_899)
PW_MF050_MF256 times 2 dw (F_2_053-F_2_562),-F_2_562
PW_MF256_F050 times 2 dw -F_2_562, (F_3_072-F_2_562)
PD_DESCALE_P1 times 2 dd 1 << (DESCALE_P1-1)
PD_DESCALE_P2 times 2 dd 1 << (DESCALE_P2-1)
PB_CENTERJSAMP times 8 db CENTERJSAMPLE
alignz 16
; --------------------------------------------------------------------------
SECTION SEG_TEXT
BITS 32
;
; Perform dequantization and inverse DCT on one block of coefficients.
;
; GLOBAL(void)
; jsimd_idct_islow_mmx (void * dct_table, JCOEFPTR coef_block,
; JSAMPARRAY output_buf, JDIMENSION output_col)
;
%define dct_table(b) (b)+8 ; jpeg_component_info * compptr
%define coef_block(b) (b)+12 ; JCOEFPTR coef_block
%define output_buf(b) (b)+16 ; JSAMPARRAY output_buf
%define output_col(b) (b)+20 ; JDIMENSION output_col
%define original_ebp ebp+0
%define wk(i) ebp-(WK_NUM-(i))*SIZEOF_MMWORD ; mmword wk[WK_NUM]
%define WK_NUM 12
%define workspace wk(0)-DCTSIZE2*SIZEOF_JCOEF
; JCOEF workspace[DCTSIZE2]
align 16
global EXTN(jsimd_idct_islow_mmx)
EXTN(jsimd_idct_islow_mmx):
push ebp
mov eax,esp ; eax = original ebp
sub esp, byte 4
and esp, byte (-SIZEOF_MMWORD) ; align to 64 bits
mov [esp],eax
mov ebp,esp ; ebp = aligned ebp
lea esp, [workspace]
push ebx
; push ecx ; need not be preserved
; push edx ; need not be preserved
push esi
push edi
get_GOT ebx ; get GOT address
; ---- Pass 1: process columns from input, store into work array.
; mov eax, [original_ebp]
mov edx, POINTER [dct_table(eax)] ; quantptr
mov esi, JCOEFPTR [coef_block(eax)] ; inptr
lea edi, [workspace] ; JCOEF * wsptr
mov ecx, DCTSIZE/4 ; ctr
alignx 16,7
.columnloop:
%ifndef NO_ZERO_COLUMN_TEST_ISLOW_MMX
mov eax, DWORD [DWBLOCK(1,0,esi,SIZEOF_JCOEF)]
or eax, DWORD [DWBLOCK(2,0,esi,SIZEOF_JCOEF)]
jnz short .columnDCT
movq mm0, MMWORD [MMBLOCK(1,0,esi,SIZEOF_JCOEF)]
movq mm1, MMWORD [MMBLOCK(2,0,esi,SIZEOF_JCOEF)]
por mm0, MMWORD [MMBLOCK(3,0,esi,SIZEOF_JCOEF)]
por mm1, MMWORD [MMBLOCK(4,0,esi,SIZEOF_JCOEF)]
por mm0, MMWORD [MMBLOCK(5,0,esi,SIZEOF_JCOEF)]
por mm1, MMWORD [MMBLOCK(6,0,esi,SIZEOF_JCOEF)]
por mm0, MMWORD [MMBLOCK(7,0,esi,SIZEOF_JCOEF)]
por mm1,mm0
packsswb mm1,mm1
movd eax,mm1
test eax,eax
jnz short .columnDCT
; -- AC terms all zero
movq mm0, MMWORD [MMBLOCK(0,0,esi,SIZEOF_JCOEF)]
pmullw mm0, MMWORD [MMBLOCK(0,0,edx,SIZEOF_ISLOW_MULT_TYPE)]
psllw mm0,PASS1_BITS
movq mm2,mm0 ; mm0=in0=(00 01 02 03)
punpcklwd mm0,mm0 ; mm0=(00 00 01 01)
punpckhwd mm2,mm2 ; mm2=(02 02 03 03)
movq mm1,mm0
punpckldq mm0,mm0 ; mm0=(00 00 00 00)
punpckhdq mm1,mm1 ; mm1=(01 01 01 01)
movq mm3,mm2
punpckldq mm2,mm2 ; mm2=(02 02 02 02)
punpckhdq mm3,mm3 ; mm3=(03 03 03 03)
movq MMWORD [MMBLOCK(0,0,edi,SIZEOF_JCOEF)], mm0
movq MMWORD [MMBLOCK(0,1,edi,SIZEOF_JCOEF)], mm0
movq MMWORD [MMBLOCK(1,0,edi,SIZEOF_JCOEF)], mm1
movq MMWORD [MMBLOCK(1,1,edi,SIZEOF_JCOEF)], mm1
movq MMWORD [MMBLOCK(2,0,edi,SIZEOF_JCOEF)], mm2
movq MMWORD [MMBLOCK(2,1,edi,SIZEOF_JCOEF)], mm2
movq MMWORD [MMBLOCK(3,0,edi,SIZEOF_JCOEF)], mm3
movq MMWORD [MMBLOCK(3,1,edi,SIZEOF_JCOEF)], mm3
jmp near .nextcolumn
alignx 16,7
%endif
.columnDCT:
; -- Even part
movq mm0, MMWORD [MMBLOCK(0,0,esi,SIZEOF_JCOEF)]
movq mm1, MMWORD [MMBLOCK(2,0,esi,SIZEOF_JCOEF)]
pmullw mm0, MMWORD [MMBLOCK(0,0,edx,SIZEOF_ISLOW_MULT_TYPE)]
pmullw mm1, MMWORD [MMBLOCK(2,0,edx,SIZEOF_ISLOW_MULT_TYPE)]
movq mm2, MMWORD [MMBLOCK(4,0,esi,SIZEOF_JCOEF)]
movq mm3, MMWORD [MMBLOCK(6,0,esi,SIZEOF_JCOEF)]
pmullw mm2, MMWORD [MMBLOCK(4,0,edx,SIZEOF_ISLOW_MULT_TYPE)]
pmullw mm3, MMWORD [MMBLOCK(6,0,edx,SIZEOF_ISLOW_MULT_TYPE)]
; (Original)
; z1 = (z2 + z3) * 0.541196100;
; tmp2 = z1 + z3 * -1.847759065;
; tmp3 = z1 + z2 * 0.765366865;
;
; (This implementation)
; tmp2 = z2 * 0.541196100 + z3 * (0.541196100 - 1.847759065);
; tmp3 = z2 * (0.541196100 + 0.765366865) + z3 * 0.541196100;
movq mm4,mm1 ; mm1=in2=z2
movq mm5,mm1
punpcklwd mm4,mm3 ; mm3=in6=z3
punpckhwd mm5,mm3
movq mm1,mm4
movq mm3,mm5
pmaddwd mm4,[GOTOFF(ebx,PW_F130_F054)] ; mm4=tmp3L
pmaddwd mm5,[GOTOFF(ebx,PW_F130_F054)] ; mm5=tmp3H
pmaddwd mm1,[GOTOFF(ebx,PW_F054_MF130)] ; mm1=tmp2L
pmaddwd mm3,[GOTOFF(ebx,PW_F054_MF130)] ; mm3=tmp2H
movq mm6,mm0
paddw mm0,mm2 ; mm0=in0+in4
psubw mm6,mm2 ; mm6=in0-in4
pxor mm7,mm7
pxor mm2,mm2
punpcklwd mm7,mm0 ; mm7=tmp0L
punpckhwd mm2,mm0 ; mm2=tmp0H
psrad mm7,(16-CONST_BITS) ; psrad mm7,16 & pslld mm7,CONST_BITS
psrad mm2,(16-CONST_BITS) ; psrad mm2,16 & pslld mm2,CONST_BITS
movq mm0,mm7
paddd mm7,mm4 ; mm7=tmp10L
psubd mm0,mm4 ; mm0=tmp13L
movq mm4,mm2
paddd mm2,mm5 ; mm2=tmp10H
psubd mm4,mm5 ; mm4=tmp13H
movq MMWORD [wk(0)], mm7 ; wk(0)=tmp10L
movq MMWORD [wk(1)], mm2 ; wk(1)=tmp10H
movq MMWORD [wk(2)], mm0 ; wk(2)=tmp13L
movq MMWORD [wk(3)], mm4 ; wk(3)=tmp13H
pxor mm5,mm5
pxor mm7,mm7
punpcklwd mm5,mm6 ; mm5=tmp1L
punpckhwd mm7,mm6 ; mm7=tmp1H
psrad mm5,(16-CONST_BITS) ; psrad mm5,16 & pslld mm5,CONST_BITS
psrad mm7,(16-CONST_BITS) ; psrad mm7,16 & pslld mm7,CONST_BITS
movq mm2,mm5
paddd mm5,mm1 ; mm5=tmp11L
psubd mm2,mm1 ; mm2=tmp12L
movq mm0,mm7
paddd mm7,mm3 ; mm7=tmp11H
psubd mm0,mm3 ; mm0=tmp12H
movq MMWORD [wk(4)], mm5 ; wk(4)=tmp11L
movq MMWORD [wk(5)], mm7 ; wk(5)=tmp11H
movq MMWORD [wk(6)], mm2 ; wk(6)=tmp12L
movq MMWORD [wk(7)], mm0 ; wk(7)=tmp12H
; -- Odd part
movq mm4, MMWORD [MMBLOCK(1,0,esi,SIZEOF_JCOEF)]
movq mm6, MMWORD [MMBLOCK(3,0,esi,SIZEOF_JCOEF)]
pmullw mm4, MMWORD [MMBLOCK(1,0,edx,SIZEOF_ISLOW_MULT_TYPE)]
pmullw mm6, MMWORD [MMBLOCK(3,0,edx,SIZEOF_ISLOW_MULT_TYPE)]
movq mm1, MMWORD [MMBLOCK(5,0,esi,SIZEOF_JCOEF)]
movq mm3, MMWORD [MMBLOCK(7,0,esi,SIZEOF_JCOEF)]
pmullw mm1, MMWORD [MMBLOCK(5,0,edx,SIZEOF_ISLOW_MULT_TYPE)]
pmullw mm3, MMWORD [MMBLOCK(7,0,edx,SIZEOF_ISLOW_MULT_TYPE)]
movq mm5,mm6
movq mm7,mm4
paddw mm5,mm3 ; mm5=z3
paddw mm7,mm1 ; mm7=z4
; (Original)
; z5 = (z3 + z4) * 1.175875602;
; z3 = z3 * -1.961570560; z4 = z4 * -0.390180644;
; z3 += z5; z4 += z5;
;
; (This implementation)
; z3 = z3 * (1.175875602 - 1.961570560) + z4 * 1.175875602;
; z4 = z3 * 1.175875602 + z4 * (1.175875602 - 0.390180644);
movq mm2,mm5
movq mm0,mm5
punpcklwd mm2,mm7
punpckhwd mm0,mm7
movq mm5,mm2
movq mm7,mm0
pmaddwd mm2,[GOTOFF(ebx,PW_MF078_F117)] ; mm2=z3L
pmaddwd mm0,[GOTOFF(ebx,PW_MF078_F117)] ; mm0=z3H
pmaddwd mm5,[GOTOFF(ebx,PW_F117_F078)] ; mm5=z4L
pmaddwd mm7,[GOTOFF(ebx,PW_F117_F078)] ; mm7=z4H
movq MMWORD [wk(10)], mm2 ; wk(10)=z3L
movq MMWORD [wk(11)], mm0 ; wk(11)=z3H
; (Original)
; z1 = tmp0 + tmp3; z2 = tmp1 + tmp2;
; tmp0 = tmp0 * 0.298631336; tmp1 = tmp1 * 2.053119869;
; tmp2 = tmp2 * 3.072711026; tmp3 = tmp3 * 1.501321110;
; z1 = z1 * -0.899976223; z2 = z2 * -2.562915447;
; tmp0 += z1 + z3; tmp1 += z2 + z4;
; tmp2 += z2 + z3; tmp3 += z1 + z4;
;
; (This implementation)
; tmp0 = tmp0 * (0.298631336 - 0.899976223) + tmp3 * -0.899976223;
; tmp1 = tmp1 * (2.053119869 - 2.562915447) + tmp2 * -2.562915447;
; tmp2 = tmp1 * -2.562915447 + tmp2 * (3.072711026 - 2.562915447);
; tmp3 = tmp0 * -0.899976223 + tmp3 * (1.501321110 - 0.899976223);
; tmp0 += z3; tmp1 += z4;
; tmp2 += z3; tmp3 += z4;
movq mm2,mm3
movq mm0,mm3
punpcklwd mm2,mm4
punpckhwd mm0,mm4
movq mm3,mm2
movq mm4,mm0
pmaddwd mm2,[GOTOFF(ebx,PW_MF060_MF089)] ; mm2=tmp0L
pmaddwd mm0,[GOTOFF(ebx,PW_MF060_MF089)] ; mm0=tmp0H
pmaddwd mm3,[GOTOFF(ebx,PW_MF089_F060)] ; mm3=tmp3L
pmaddwd mm4,[GOTOFF(ebx,PW_MF089_F060)] ; mm4=tmp3H
paddd mm2, MMWORD [wk(10)] ; mm2=tmp0L
paddd mm0, MMWORD [wk(11)] ; mm0=tmp0H
paddd mm3,mm5 ; mm3=tmp3L
paddd mm4,mm7 ; mm4=tmp3H
movq MMWORD [wk(8)], mm2 ; wk(8)=tmp0L
movq MMWORD [wk(9)], mm0 ; wk(9)=tmp0H
movq mm2,mm1
movq mm0,mm1
punpcklwd mm2,mm6
punpckhwd mm0,mm6
movq mm1,mm2
movq mm6,mm0
pmaddwd mm2,[GOTOFF(ebx,PW_MF050_MF256)] ; mm2=tmp1L
pmaddwd mm0,[GOTOFF(ebx,PW_MF050_MF256)] ; mm0=tmp1H
pmaddwd mm1,[GOTOFF(ebx,PW_MF256_F050)] ; mm1=tmp2L
pmaddwd mm6,[GOTOFF(ebx,PW_MF256_F050)] ; mm6=tmp2H
paddd mm2,mm5 ; mm2=tmp1L
paddd mm0,mm7 ; mm0=tmp1H
paddd mm1, MMWORD [wk(10)] ; mm1=tmp2L
paddd mm6, MMWORD [wk(11)] ; mm6=tmp2H
movq MMWORD [wk(10)], mm2 ; wk(10)=tmp1L
movq MMWORD [wk(11)], mm0 ; wk(11)=tmp1H
; -- Final output stage
movq mm5, MMWORD [wk(0)] ; mm5=tmp10L
movq mm7, MMWORD [wk(1)] ; mm7=tmp10H
movq mm2,mm5
movq mm0,mm7
paddd mm5,mm3 ; mm5=data0L
paddd mm7,mm4 ; mm7=data0H
psubd mm2,mm3 ; mm2=data7L
psubd mm0,mm4 ; mm0=data7H
movq mm3,[GOTOFF(ebx,PD_DESCALE_P1)] ; mm3=[PD_DESCALE_P1]
paddd mm5,mm3
paddd mm7,mm3
psrad mm5,DESCALE_P1
psrad mm7,DESCALE_P1
paddd mm2,mm3
paddd mm0,mm3
psrad mm2,DESCALE_P1
psrad mm0,DESCALE_P1
packssdw mm5,mm7 ; mm5=data0=(00 01 02 03)
packssdw mm2,mm0 ; mm2=data7=(70 71 72 73)
movq mm4, MMWORD [wk(4)] ; mm4=tmp11L
movq mm3, MMWORD [wk(5)] ; mm3=tmp11H
movq mm7,mm4
movq mm0,mm3
paddd mm4,mm1 ; mm4=data1L
paddd mm3,mm6 ; mm3=data1H
psubd mm7,mm1 ; mm7=data6L
psubd mm0,mm6 ; mm0=data6H
movq mm1,[GOTOFF(ebx,PD_DESCALE_P1)] ; mm1=[PD_DESCALE_P1]
paddd mm4,mm1
paddd mm3,mm1
psrad mm4,DESCALE_P1
psrad mm3,DESCALE_P1
paddd mm7,mm1
paddd mm0,mm1
psrad mm7,DESCALE_P1
psrad mm0,DESCALE_P1
packssdw mm4,mm3 ; mm4=data1=(10 11 12 13)
packssdw mm7,mm0 ; mm7=data6=(60 61 62 63)
movq mm6,mm5 ; transpose coefficients(phase 1)
punpcklwd mm5,mm4 ; mm5=(00 10 01 11)
punpckhwd mm6,mm4 ; mm6=(02 12 03 13)
movq mm1,mm7 ; transpose coefficients(phase 1)
punpcklwd mm7,mm2 ; mm7=(60 70 61 71)
punpckhwd mm1,mm2 ; mm1=(62 72 63 73)
movq mm3, MMWORD [wk(6)] ; mm3=tmp12L
movq mm0, MMWORD [wk(7)] ; mm0=tmp12H
movq mm4, MMWORD [wk(10)] ; mm4=tmp1L
movq mm2, MMWORD [wk(11)] ; mm2=tmp1H
movq MMWORD [wk(0)], mm5 ; wk(0)=(00 10 01 11)
movq MMWORD [wk(1)], mm6 ; wk(1)=(02 12 03 13)
movq MMWORD [wk(4)], mm7 ; wk(4)=(60 70 61 71)
movq MMWORD [wk(5)], mm1 ; wk(5)=(62 72 63 73)
movq mm5,mm3
movq mm6,mm0
paddd mm3,mm4 ; mm3=data2L
paddd mm0,mm2 ; mm0=data2H
psubd mm5,mm4 ; mm5=data5L
psubd mm6,mm2 ; mm6=data5H
movq mm7,[GOTOFF(ebx,PD_DESCALE_P1)] ; mm7=[PD_DESCALE_P1]
paddd mm3,mm7
paddd mm0,mm7
psrad mm3,DESCALE_P1
psrad mm0,DESCALE_P1
paddd mm5,mm7
paddd mm6,mm7
psrad mm5,DESCALE_P1
psrad mm6,DESCALE_P1
packssdw mm3,mm0 ; mm3=data2=(20 21 22 23)
packssdw mm5,mm6 ; mm5=data5=(50 51 52 53)
movq mm1, MMWORD [wk(2)] ; mm1=tmp13L
movq mm4, MMWORD [wk(3)] ; mm4=tmp13H
movq mm2, MMWORD [wk(8)] ; mm2=tmp0L
movq mm7, MMWORD [wk(9)] ; mm7=tmp0H
movq mm0,mm1
movq mm6,mm4
paddd mm1,mm2 ; mm1=data3L
paddd mm4,mm7 ; mm4=data3H
psubd mm0,mm2 ; mm0=data4L
psubd mm6,mm7 ; mm6=data4H
movq mm2,[GOTOFF(ebx,PD_DESCALE_P1)] ; mm2=[PD_DESCALE_P1]
paddd mm1,mm2
paddd mm4,mm2
psrad mm1,DESCALE_P1
psrad mm4,DESCALE_P1
paddd mm0,mm2
paddd mm6,mm2
psrad mm0,DESCALE_P1
psrad mm6,DESCALE_P1
packssdw mm1,mm4 ; mm1=data3=(30 31 32 33)
packssdw mm0,mm6 ; mm0=data4=(40 41 42 43)
movq mm7, MMWORD [wk(0)] ; mm7=(00 10 01 11)
movq mm2, MMWORD [wk(1)] ; mm2=(02 12 03 13)
movq mm4,mm3 ; transpose coefficients(phase 1)
punpcklwd mm3,mm1 ; mm3=(20 30 21 31)
punpckhwd mm4,mm1 ; mm4=(22 32 23 33)
movq mm6,mm0 ; transpose coefficients(phase 1)
punpcklwd mm0,mm5 ; mm0=(40 50 41 51)
punpckhwd mm6,mm5 ; mm6=(42 52 43 53)
movq mm1,mm7 ; transpose coefficients(phase 2)
punpckldq mm7,mm3 ; mm7=(00 10 20 30)
punpckhdq mm1,mm3 ; mm1=(01 11 21 31)
movq mm5,mm2 ; transpose coefficients(phase 2)
punpckldq mm2,mm4 ; mm2=(02 12 22 32)
punpckhdq mm5,mm4 ; mm5=(03 13 23 33)
movq mm3, MMWORD [wk(4)] ; mm3=(60 70 61 71)
movq mm4, MMWORD [wk(5)] ; mm4=(62 72 63 73)
movq MMWORD [MMBLOCK(0,0,edi,SIZEOF_JCOEF)], mm7
movq MMWORD [MMBLOCK(1,0,edi,SIZEOF_JCOEF)], mm1
movq MMWORD [MMBLOCK(2,0,edi,SIZEOF_JCOEF)], mm2
movq MMWORD [MMBLOCK(3,0,edi,SIZEOF_JCOEF)], mm5
movq mm7,mm0 ; transpose coefficients(phase 2)
punpckldq mm0,mm3 ; mm0=(40 50 60 70)
punpckhdq mm7,mm3 ; mm7=(41 51 61 71)
movq mm1,mm6 ; transpose coefficients(phase 2)
punpckldq mm6,mm4 ; mm6=(42 52 62 72)
punpckhdq mm1,mm4 ; mm1=(43 53 63 73)
movq MMWORD [MMBLOCK(0,1,edi,SIZEOF_JCOEF)], mm0
movq MMWORD [MMBLOCK(1,1,edi,SIZEOF_JCOEF)], mm7
movq MMWORD [MMBLOCK(2,1,edi,SIZEOF_JCOEF)], mm6
movq MMWORD [MMBLOCK(3,1,edi,SIZEOF_JCOEF)], mm1
.nextcolumn:
add esi, byte 4*SIZEOF_JCOEF ; coef_block
add edx, byte 4*SIZEOF_ISLOW_MULT_TYPE ; quantptr
add edi, byte 4*DCTSIZE*SIZEOF_JCOEF ; wsptr
dec ecx ; ctr
jnz near .columnloop
; ---- Pass 2: process rows from work array, store into output array.
mov eax, [original_ebp]
lea esi, [workspace] ; JCOEF * wsptr
mov edi, JSAMPARRAY [output_buf(eax)] ; (JSAMPROW *)
mov eax, JDIMENSION [output_col(eax)]
mov ecx, DCTSIZE/4 ; ctr
alignx 16,7
.rowloop:
; -- Even part
movq mm0, MMWORD [MMBLOCK(0,0,esi,SIZEOF_JCOEF)]
movq mm1, MMWORD [MMBLOCK(2,0,esi,SIZEOF_JCOEF)]
movq mm2, MMWORD [MMBLOCK(4,0,esi,SIZEOF_JCOEF)]
movq mm3, MMWORD [MMBLOCK(6,0,esi,SIZEOF_JCOEF)]
; (Original)
; z1 = (z2 + z3) * 0.541196100;
; tmp2 = z1 + z3 * -1.847759065;
; tmp3 = z1 + z2 * 0.765366865;
;
; (This implementation)
; tmp2 = z2 * 0.541196100 + z3 * (0.541196100 - 1.847759065);
; tmp3 = z2 * (0.541196100 + 0.765366865) + z3 * 0.541196100;
movq mm4,mm1 ; mm1=in2=z2
movq mm5,mm1
punpcklwd mm4,mm3 ; mm3=in6=z3
punpckhwd mm5,mm3
movq mm1,mm4
movq mm3,mm5
pmaddwd mm4,[GOTOFF(ebx,PW_F130_F054)] ; mm4=tmp3L
pmaddwd mm5,[GOTOFF(ebx,PW_F130_F054)] ; mm5=tmp3H
pmaddwd mm1,[GOTOFF(ebx,PW_F054_MF130)] ; mm1=tmp2L
pmaddwd mm3,[GOTOFF(ebx,PW_F054_MF130)] ; mm3=tmp2H
movq mm6,mm0
paddw mm0,mm2 ; mm0=in0+in4
psubw mm6,mm2 ; mm6=in0-in4
pxor mm7,mm7
pxor mm2,mm2
punpcklwd mm7,mm0 ; mm7=tmp0L
punpckhwd mm2,mm0 ; mm2=tmp0H
psrad mm7,(16-CONST_BITS) ; psrad mm7,16 & pslld mm7,CONST_BITS
psrad mm2,(16-CONST_BITS) ; psrad mm2,16 & pslld mm2,CONST_BITS
movq mm0,mm7
paddd mm7,mm4 ; mm7=tmp10L
psubd mm0,mm4 ; mm0=tmp13L
movq mm4,mm2
paddd mm2,mm5 ; mm2=tmp10H
psubd mm4,mm5 ; mm4=tmp13H
movq MMWORD [wk(0)], mm7 ; wk(0)=tmp10L
movq MMWORD [wk(1)], mm2 ; wk(1)=tmp10H
movq MMWORD [wk(2)], mm0 ; wk(2)=tmp13L
movq MMWORD [wk(3)], mm4 ; wk(3)=tmp13H
pxor mm5,mm5
pxor mm7,mm7
punpcklwd mm5,mm6 ; mm5=tmp1L
punpckhwd mm7,mm6 ; mm7=tmp1H
psrad mm5,(16-CONST_BITS) ; psrad mm5,16 & pslld mm5,CONST_BITS
psrad mm7,(16-CONST_BITS) ; psrad mm7,16 & pslld mm7,CONST_BITS
movq mm2,mm5
paddd mm5,mm1 ; mm5=tmp11L
psubd mm2,mm1 ; mm2=tmp12L
movq mm0,mm7
paddd mm7,mm3 ; mm7=tmp11H
psubd mm0,mm3 ; mm0=tmp12H
movq MMWORD [wk(4)], mm5 ; wk(4)=tmp11L
movq MMWORD [wk(5)], mm7 ; wk(5)=tmp11H
movq MMWORD [wk(6)], mm2 ; wk(6)=tmp12L
movq MMWORD [wk(7)], mm0 ; wk(7)=tmp12H
; -- Odd part
movq mm4, MMWORD [MMBLOCK(1,0,esi,SIZEOF_JCOEF)]
movq mm6, MMWORD [MMBLOCK(3,0,esi,SIZEOF_JCOEF)]
movq mm1, MMWORD [MMBLOCK(5,0,esi,SIZEOF_JCOEF)]
movq mm3, MMWORD [MMBLOCK(7,0,esi,SIZEOF_JCOEF)]
movq mm5,mm6
movq mm7,mm4
paddw mm5,mm3 ; mm5=z3
paddw mm7,mm1 ; mm7=z4
; (Original)
; z5 = (z3 + z4) * 1.175875602;
; z3 = z3 * -1.961570560; z4 = z4 * -0.390180644;
; z3 += z5; z4 += z5;
;
; (This implementation)
; z3 = z3 * (1.175875602 - 1.961570560) + z4 * 1.175875602;
; z4 = z3 * 1.175875602 + z4 * (1.175875602 - 0.390180644);
movq mm2,mm5
movq mm0,mm5
punpcklwd mm2,mm7
punpckhwd mm0,mm7
movq mm5,mm2
movq mm7,mm0
pmaddwd mm2,[GOTOFF(ebx,PW_MF078_F117)] ; mm2=z3L
pmaddwd mm0,[GOTOFF(ebx,PW_MF078_F117)] ; mm0=z3H
pmaddwd mm5,[GOTOFF(ebx,PW_F117_F078)] ; mm5=z4L
pmaddwd mm7,[GOTOFF(ebx,PW_F117_F078)] ; mm7=z4H
movq MMWORD [wk(10)], mm2 ; wk(10)=z3L
movq MMWORD [wk(11)], mm0 ; wk(11)=z3H
; (Original)
; z1 = tmp0 + tmp3; z2 = tmp1 + tmp2;
; tmp0 = tmp0 * 0.298631336; tmp1 = tmp1 * 2.053119869;
; tmp2 = tmp2 * 3.072711026; tmp3 = tmp3 * 1.501321110;
; z1 = z1 * -0.899976223; z2 = z2 * -2.562915447;
; tmp0 += z1 + z3; tmp1 += z2 + z4;
; tmp2 += z2 + z3; tmp3 += z1 + z4;
;
; (This implementation)
; tmp0 = tmp0 * (0.298631336 - 0.899976223) + tmp3 * -0.899976223;
; tmp1 = tmp1 * (2.053119869 - 2.562915447) + tmp2 * -2.562915447;
; tmp2 = tmp1 * -2.562915447 + tmp2 * (3.072711026 - 2.562915447);
; tmp3 = tmp0 * -0.899976223 + tmp3 * (1.501321110 - 0.899976223);
; tmp0 += z3; tmp1 += z4;
; tmp2 += z3; tmp3 += z4;
movq mm2,mm3
movq mm0,mm3
punpcklwd mm2,mm4
punpckhwd mm0,mm4
movq mm3,mm2
movq mm4,mm0
pmaddwd mm2,[GOTOFF(ebx,PW_MF060_MF089)] ; mm2=tmp0L
pmaddwd mm0,[GOTOFF(ebx,PW_MF060_MF089)] ; mm0=tmp0H
pmaddwd mm3,[GOTOFF(ebx,PW_MF089_F060)] ; mm3=tmp3L
pmaddwd mm4,[GOTOFF(ebx,PW_MF089_F060)] ; mm4=tmp3H
paddd mm2, MMWORD [wk(10)] ; mm2=tmp0L
paddd mm0, MMWORD [wk(11)] ; mm0=tmp0H
paddd mm3,mm5 ; mm3=tmp3L
paddd mm4,mm7 ; mm4=tmp3H
movq MMWORD [wk(8)], mm2 ; wk(8)=tmp0L
movq MMWORD [wk(9)], mm0 ; wk(9)=tmp0H
movq mm2,mm1
movq mm0,mm1
punpcklwd mm2,mm6
punpckhwd mm0,mm6
movq mm1,mm2
movq mm6,mm0
pmaddwd mm2,[GOTOFF(ebx,PW_MF050_MF256)] ; mm2=tmp1L
pmaddwd mm0,[GOTOFF(ebx,PW_MF050_MF256)] ; mm0=tmp1H
pmaddwd mm1,[GOTOFF(ebx,PW_MF256_F050)] ; mm1=tmp2L
pmaddwd mm6,[GOTOFF(ebx,PW_MF256_F050)] ; mm6=tmp2H
paddd mm2,mm5 ; mm2=tmp1L
paddd mm0,mm7 ; mm0=tmp1H
paddd mm1, MMWORD [wk(10)] ; mm1=tmp2L
paddd mm6, MMWORD [wk(11)] ; mm6=tmp2H
movq MMWORD [wk(10)], mm2 ; wk(10)=tmp1L
movq MMWORD [wk(11)], mm0 ; wk(11)=tmp1H
; -- Final output stage
movq mm5, MMWORD [wk(0)] ; mm5=tmp10L
movq mm7, MMWORD [wk(1)] ; mm7=tmp10H
movq mm2,mm5
movq mm0,mm7
paddd mm5,mm3 ; mm5=data0L
paddd mm7,mm4 ; mm7=data0H
psubd mm2,mm3 ; mm2=data7L
psubd mm0,mm4 ; mm0=data7H
movq mm3,[GOTOFF(ebx,PD_DESCALE_P2)] ; mm3=[PD_DESCALE_P2]
paddd mm5,mm3
paddd mm7,mm3
psrad mm5,DESCALE_P2
psrad mm7,DESCALE_P2
paddd mm2,mm3
paddd mm0,mm3
psrad mm2,DESCALE_P2
psrad mm0,DESCALE_P2
packssdw mm5,mm7 ; mm5=data0=(00 10 20 30)
packssdw mm2,mm0 ; mm2=data7=(07 17 27 37)
movq mm4, MMWORD [wk(4)] ; mm4=tmp11L
movq mm3, MMWORD [wk(5)] ; mm3=tmp11H
movq mm7,mm4
movq mm0,mm3
paddd mm4,mm1 ; mm4=data1L
paddd mm3,mm6 ; mm3=data1H
psubd mm7,mm1 ; mm7=data6L
psubd mm0,mm6 ; mm0=data6H
movq mm1,[GOTOFF(ebx,PD_DESCALE_P2)] ; mm1=[PD_DESCALE_P2]
paddd mm4,mm1
paddd mm3,mm1
psrad mm4,DESCALE_P2
psrad mm3,DESCALE_P2
paddd mm7,mm1
paddd mm0,mm1
psrad mm7,DESCALE_P2
psrad mm0,DESCALE_P2
packssdw mm4,mm3 ; mm4=data1=(01 11 21 31)
packssdw mm7,mm0 ; mm7=data6=(06 16 26 36)
packsswb mm5,mm7 ; mm5=(00 10 20 30 06 16 26 36)
packsswb mm4,mm2 ; mm4=(01 11 21 31 07 17 27 37)
movq mm6, MMWORD [wk(6)] ; mm6=tmp12L
movq mm1, MMWORD [wk(7)] ; mm1=tmp12H
movq mm3, MMWORD [wk(10)] ; mm3=tmp1L
movq mm0, MMWORD [wk(11)] ; mm0=tmp1H
movq MMWORD [wk(0)], mm5 ; wk(0)=(00 10 20 30 06 16 26 36)
movq MMWORD [wk(1)], mm4 ; wk(1)=(01 11 21 31 07 17 27 37)
movq mm7,mm6
movq mm2,mm1
paddd mm6,mm3 ; mm6=data2L
paddd mm1,mm0 ; mm1=data2H
psubd mm7,mm3 ; mm7=data5L
psubd mm2,mm0 ; mm2=data5H
movq mm5,[GOTOFF(ebx,PD_DESCALE_P2)] ; mm5=[PD_DESCALE_P2]
paddd mm6,mm5
paddd mm1,mm5
psrad mm6,DESCALE_P2
psrad mm1,DESCALE_P2
paddd mm7,mm5
paddd mm2,mm5
psrad mm7,DESCALE_P2
psrad mm2,DESCALE_P2
packssdw mm6,mm1 ; mm6=data2=(02 12 22 32)
packssdw mm7,mm2 ; mm7=data5=(05 15 25 35)
movq mm4, MMWORD [wk(2)] ; mm4=tmp13L
movq mm3, MMWORD [wk(3)] ; mm3=tmp13H
movq mm0, MMWORD [wk(8)] ; mm0=tmp0L
movq mm5, MMWORD [wk(9)] ; mm5=tmp0H
movq mm1,mm4
movq mm2,mm3
paddd mm4,mm0 ; mm4=data3L
paddd mm3,mm5 ; mm3=data3H
psubd mm1,mm0 ; mm1=data4L
psubd mm2,mm5 ; mm2=data4H
movq mm0,[GOTOFF(ebx,PD_DESCALE_P2)] ; mm0=[PD_DESCALE_P2]
paddd mm4,mm0
paddd mm3,mm0
psrad mm4,DESCALE_P2
psrad mm3,DESCALE_P2
paddd mm1,mm0
paddd mm2,mm0
psrad mm1,DESCALE_P2
psrad mm2,DESCALE_P2
movq mm5,[GOTOFF(ebx,PB_CENTERJSAMP)] ; mm5=[PB_CENTERJSAMP]
packssdw mm4,mm3 ; mm4=data3=(03 13 23 33)
packssdw mm1,mm2 ; mm1=data4=(04 14 24 34)
movq mm0, MMWORD [wk(0)] ; mm0=(00 10 20 30 06 16 26 36)
movq mm3, MMWORD [wk(1)] ; mm3=(01 11 21 31 07 17 27 37)
packsswb mm6,mm1 ; mm6=(02 12 22 32 04 14 24 34)
packsswb mm4,mm7 ; mm4=(03 13 23 33 05 15 25 35)
paddb mm0,mm5
paddb mm3,mm5
paddb mm6,mm5
paddb mm4,mm5
movq mm2,mm0 ; transpose coefficients(phase 1)
punpcklbw mm0,mm3 ; mm0=(00 01 10 11 20 21 30 31)
punpckhbw mm2,mm3 ; mm2=(06 07 16 17 26 27 36 37)
movq mm1,mm6 ; transpose coefficients(phase 1)
punpcklbw mm6,mm4 ; mm6=(02 03 12 13 22 23 32 33)
punpckhbw mm1,mm4 ; mm1=(04 05 14 15 24 25 34 35)
movq mm7,mm0 ; transpose coefficients(phase 2)
punpcklwd mm0,mm6 ; mm0=(00 01 02 03 10 11 12 13)
punpckhwd mm7,mm6 ; mm7=(20 21 22 23 30 31 32 33)
movq mm5,mm1 ; transpose coefficients(phase 2)
punpcklwd mm1,mm2 ; mm1=(04 05 06 07 14 15 16 17)
punpckhwd mm5,mm2 ; mm5=(24 25 26 27 34 35 36 37)
movq mm3,mm0 ; transpose coefficients(phase 3)
punpckldq mm0,mm1 ; mm0=(00 01 02 03 04 05 06 07)
punpckhdq mm3,mm1 ; mm3=(10 11 12 13 14 15 16 17)
movq mm4,mm7 ; transpose coefficients(phase 3)
punpckldq mm7,mm5 ; mm7=(20 21 22 23 24 25 26 27)
punpckhdq mm4,mm5 ; mm4=(30 31 32 33 34 35 36 37)
pushpic ebx ; save GOT address
mov edx, JSAMPROW [edi+0*SIZEOF_JSAMPROW]
mov ebx, JSAMPROW [edi+1*SIZEOF_JSAMPROW]
movq MMWORD [edx+eax*SIZEOF_JSAMPLE], mm0
movq MMWORD [ebx+eax*SIZEOF_JSAMPLE], mm3
mov edx, JSAMPROW [edi+2*SIZEOF_JSAMPROW]
mov ebx, JSAMPROW [edi+3*SIZEOF_JSAMPROW]
movq MMWORD [edx+eax*SIZEOF_JSAMPLE], mm7
movq MMWORD [ebx+eax*SIZEOF_JSAMPLE], mm4
poppic ebx ; restore GOT address
add esi, byte 4*SIZEOF_JCOEF ; wsptr
add edi, byte 4*SIZEOF_JSAMPROW
dec ecx ; ctr
jnz near .rowloop
emms ; empty MMX state
pop edi
pop esi
; pop edx ; need not be preserved
; pop ecx ; need not be preserved
pop ebx
mov esp,ebp ; esp <- aligned ebp
pop esp ; esp <- original ebp
pop ebp
ret
; For some reason, the OS X linker does not honor the request to align the
; segment unless we do this.
align 16
| jiangzhu1212/oooii | Ouroboros/External/libjpegTurbo/simd/jimmxint.asm | Assembly | mit | 26,451 |
title CpuIoAccess.asm
;------------------------------------------------------------------------------
;*
;* Copyright (c) 2005, Intel Corporation
;* 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 license may be found at
;* http://opensource.org/licenses/bsd-license.php
;*
;* THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
;* WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
;*
;* Module Name:
;* CpuIoAccess.asm
;*
;* Abstract:
;* Supports IA32 CPU IO operation
;*
;------------------------------------------------------------------------------
;
;
;------------------------------------------------------------------------------
.686
.MODEL FLAT,C
.CODE
UINT8 TYPEDEF BYTE
UINT16 TYPEDEF WORD
UINT32 TYPEDEF DWORD
UINT64 TYPEDEF QWORD
UINTN TYPEDEF UINT32
;------------------------------------------------------------------------------
; UINT8
; CpuIoRead8 (
; IN UINT16 Port
; )
;------------------------------------------------------------------------------
CpuIoRead8 PROC PUBLIC Port:UINT16
mov dx, Port
in al, dx
ret
CpuIoRead8 ENDP
;------------------------------------------------------------------------------
; UINT16
; CpuIoRead16 (
; IN UINT16 Port
; )
;------------------------------------------------------------------------------
CpuIoRead16 PROC PUBLIC Port:UINT16
mov dx, Port
in ax, dx
ret
CpuIoRead16 ENDP
;------------------------------------------------------------------------------
; UINT32
; CpuIoRead32 (
; IN UINT16 Port
; )
;------------------------------------------------------------------------------
CpuIoRead32 PROC PUBLIC Port:UINT16
mov dx, Port
in eax, dx
ret
CpuIoRead32 ENDP
;------------------------------------------------------------------------------
; VOID
; CpuIoWrite8 (
; IN UINT16 Port,
; IN UINT32 Data
; )
;------------------------------------------------------------------------------
CpuIoWrite8 PROC PUBLIC Port:UINT16, Data:UINT32
mov eax, Data
mov dx, Port
out dx, al
ret
CpuIoWrite8 ENDP
;------------------------------------------------------------------------------
; VOID
; CpuIoWrite16 (
; IN UINT16 Port,
; IN UINT32 Data
; )
;------------------------------------------------------------------------------
CpuIoWrite16 PROC PUBLIC Port:UINT16, Data:UINT32
mov eax, Data
mov dx, Port
out dx, ax
ret
CpuIoWrite16 ENDP
;------------------------------------------------------------------------------
; VOID
; CpuIoWrite32 (
; IN UINT16 Port,
; IN UINT32 Data
; )
;------------------------------------------------------------------------------
CpuIoWrite32 PROC PUBLIC Port:UINT16, Data:UINT32
mov eax, Data
mov dx, Port
out dx, eax
ret
CpuIoWrite32 ENDP
END | tianocore/edk | Sample/Cpu/Pentium/CpuIo/RuntimeDxe/Ia32/CpuIoAccess.asm | Assembly | bsd-3-clause | 3,427 |
;
; Copyright (c) 2010 The WebM project authors. All Rights Reserved.
;
; Use of this source code is governed by a BSD-style license
; that can be found in the LICENSE file in the root of the source
; tree. An additional intellectual property rights grant can be found
; in the file PATENTS. All contributing project authors may
; be found in the AUTHORS file in the root of the source tree.
;
%include "vpx_ports/x86_abi_support.asm"
%define xmm_filter_shift 7
;unsigned int vp8_get_mb_ss_sse2
;(
; short *src_ptr
;)
global sym(vp8_get_mb_ss_sse2)
sym(vp8_get_mb_ss_sse2):
push rbp
mov rbp, rsp
SHADOW_ARGS_TO_STACK 1
GET_GOT rbx
push rsi
push rdi
sub rsp, 16
; end prolog
mov rax, arg(0) ;[src_ptr]
mov rcx, 8
pxor xmm4, xmm4
.NEXTROW:
movdqa xmm0, [rax]
movdqa xmm1, [rax+16]
movdqa xmm2, [rax+32]
movdqa xmm3, [rax+48]
pmaddwd xmm0, xmm0
pmaddwd xmm1, xmm1
pmaddwd xmm2, xmm2
pmaddwd xmm3, xmm3
paddd xmm0, xmm1
paddd xmm2, xmm3
paddd xmm4, xmm0
paddd xmm4, xmm2
add rax, 0x40
dec rcx
ja .NEXTROW
movdqa xmm3,xmm4
psrldq xmm4,8
paddd xmm4,xmm3
movdqa xmm3,xmm4
psrldq xmm4,4
paddd xmm4,xmm3
movq rax,xmm4
; begin epilog
add rsp, 16
pop rdi
pop rsi
RESTORE_GOT
UNSHADOW_ARGS
pop rbp
ret
;unsigned int vp8_get16x16var_sse2
;(
; unsigned char * src_ptr,
; int source_stride,
; unsigned char * ref_ptr,
; int recon_stride,
; unsigned int * SSE,
; int * Sum
;)
global sym(vp8_get16x16var_sse2)
sym(vp8_get16x16var_sse2):
push rbp
mov rbp, rsp
SHADOW_ARGS_TO_STACK 6
SAVE_XMM 7
push rbx
push rsi
push rdi
; end prolog
mov rsi, arg(0) ;[src_ptr]
mov rdi, arg(2) ;[ref_ptr]
movsxd rax, DWORD PTR arg(1) ;[source_stride]
movsxd rdx, DWORD PTR arg(3) ;[recon_stride]
; Prefetch data
lea rcx, [rax+rax*2]
prefetcht0 [rsi]
prefetcht0 [rsi+rax]
prefetcht0 [rsi+rax*2]
prefetcht0 [rsi+rcx]
lea rbx, [rsi+rax*4]
prefetcht0 [rbx]
prefetcht0 [rbx+rax]
prefetcht0 [rbx+rax*2]
prefetcht0 [rbx+rcx]
lea rcx, [rdx+rdx*2]
prefetcht0 [rdi]
prefetcht0 [rdi+rdx]
prefetcht0 [rdi+rdx*2]
prefetcht0 [rdi+rcx]
lea rbx, [rdi+rdx*4]
prefetcht0 [rbx]
prefetcht0 [rbx+rdx]
prefetcht0 [rbx+rdx*2]
prefetcht0 [rbx+rcx]
pxor xmm0, xmm0 ; clear xmm0 for unpack
pxor xmm7, xmm7 ; clear xmm7 for accumulating diffs
pxor xmm6, xmm6 ; clear xmm6 for accumulating sse
mov rcx, 16
.var16loop:
movdqu xmm1, XMMWORD PTR [rsi]
movdqu xmm2, XMMWORD PTR [rdi]
prefetcht0 [rsi+rax*8]
prefetcht0 [rdi+rdx*8]
movdqa xmm3, xmm1
movdqa xmm4, xmm2
punpcklbw xmm1, xmm0
punpckhbw xmm3, xmm0
punpcklbw xmm2, xmm0
punpckhbw xmm4, xmm0
psubw xmm1, xmm2
psubw xmm3, xmm4
paddw xmm7, xmm1
pmaddwd xmm1, xmm1
paddw xmm7, xmm3
pmaddwd xmm3, xmm3
paddd xmm6, xmm1
paddd xmm6, xmm3
add rsi, rax
add rdi, rdx
sub rcx, 1
jnz .var16loop
movdqa xmm1, xmm6
pxor xmm6, xmm6
pxor xmm5, xmm5
punpcklwd xmm6, xmm7
punpckhwd xmm5, xmm7
psrad xmm5, 16
psrad xmm6, 16
paddd xmm6, xmm5
movdqa xmm2, xmm1
punpckldq xmm1, xmm0
punpckhdq xmm2, xmm0
movdqa xmm7, xmm6
paddd xmm1, xmm2
punpckldq xmm6, xmm0
punpckhdq xmm7, xmm0
paddd xmm6, xmm7
movdqa xmm2, xmm1
movdqa xmm7, xmm6
psrldq xmm1, 8
psrldq xmm6, 8
paddd xmm7, xmm6
paddd xmm1, xmm2
mov rax, arg(5) ;[Sum]
mov rdi, arg(4) ;[SSE]
movd DWORD PTR [rax], xmm7
movd DWORD PTR [rdi], xmm1
; begin epilog
pop rdi
pop rsi
pop rbx
RESTORE_XMM
UNSHADOW_ARGS
pop rbp
ret
;unsigned int vp8_get8x8var_sse2
;(
; unsigned char * src_ptr,
; int source_stride,
; unsigned char * ref_ptr,
; int recon_stride,
; unsigned int * SSE,
; int * Sum
;)
global sym(vp8_get8x8var_sse2)
sym(vp8_get8x8var_sse2):
push rbp
mov rbp, rsp
SHADOW_ARGS_TO_STACK 6
SAVE_XMM 7
GET_GOT rbx
push rsi
push rdi
sub rsp, 16
; end prolog
mov rsi, arg(0) ;[src_ptr]
mov rdi, arg(2) ;[ref_ptr]
movsxd rax, DWORD PTR arg(1) ;[source_stride]
movsxd rdx, DWORD PTR arg(3) ;[recon_stride]
pxor xmm0, xmm0 ; clear xmm0 for unpack
pxor xmm7, xmm7 ; clear xmm7 for accumulating diffs
movq xmm1, QWORD PTR [rsi]
movq xmm2, QWORD PTR [rdi]
punpcklbw xmm1, xmm0
punpcklbw xmm2, xmm0
psubsw xmm1, xmm2
paddw xmm7, xmm1
pmaddwd xmm1, xmm1
movq xmm2, QWORD PTR[rsi + rax]
movq xmm3, QWORD PTR[rdi + rdx]
punpcklbw xmm2, xmm0
punpcklbw xmm3, xmm0
psubsw xmm2, xmm3
paddw xmm7, xmm2
pmaddwd xmm2, xmm2
paddd xmm1, xmm2
movq xmm2, QWORD PTR[rsi + rax * 2]
movq xmm3, QWORD PTR[rdi + rdx * 2]
punpcklbw xmm2, xmm0
punpcklbw xmm3, xmm0
psubsw xmm2, xmm3
paddw xmm7, xmm2
pmaddwd xmm2, xmm2
paddd xmm1, xmm2
lea rsi, [rsi + rax * 2]
lea rdi, [rdi + rdx * 2]
movq xmm2, QWORD PTR[rsi + rax]
movq xmm3, QWORD PTR[rdi + rdx]
punpcklbw xmm2, xmm0
punpcklbw xmm3, xmm0
psubsw xmm2, xmm3
paddw xmm7, xmm2
pmaddwd xmm2, xmm2
paddd xmm1, xmm2
movq xmm2, QWORD PTR[rsi + rax *2]
movq xmm3, QWORD PTR[rdi + rdx *2]
punpcklbw xmm2, xmm0
punpcklbw xmm3, xmm0
psubsw xmm2, xmm3
paddw xmm7, xmm2
pmaddwd xmm2, xmm2
paddd xmm1, xmm2
lea rsi, [rsi + rax * 2]
lea rdi, [rdi + rdx * 2]
movq xmm2, QWORD PTR[rsi + rax]
movq xmm3, QWORD PTR[rdi + rdx]
punpcklbw xmm2, xmm0
punpcklbw xmm3, xmm0
psubsw xmm2, xmm3
paddw xmm7, xmm2
pmaddwd xmm2, xmm2
paddd xmm1, xmm2
movq xmm2, QWORD PTR[rsi + rax *2]
movq xmm3, QWORD PTR[rdi + rdx *2]
punpcklbw xmm2, xmm0
punpcklbw xmm3, xmm0
psubsw xmm2, xmm3
paddw xmm7, xmm2
pmaddwd xmm2, xmm2
paddd xmm1, xmm2
lea rsi, [rsi + rax * 2]
lea rdi, [rdi + rdx * 2]
movq xmm2, QWORD PTR[rsi + rax]
movq xmm3, QWORD PTR[rdi + rdx]
punpcklbw xmm2, xmm0
punpcklbw xmm3, xmm0
psubsw xmm2, xmm3
paddw xmm7, xmm2
pmaddwd xmm2, xmm2
paddd xmm1, xmm2
movdqa xmm6, xmm7
punpcklwd xmm6, xmm0
punpckhwd xmm7, xmm0
movdqa xmm2, xmm1
paddw xmm6, xmm7
punpckldq xmm1, xmm0
punpckhdq xmm2, xmm0
movdqa xmm7, xmm6
paddd xmm1, xmm2
punpckldq xmm6, xmm0
punpckhdq xmm7, xmm0
paddw xmm6, xmm7
movdqa xmm2, xmm1
movdqa xmm7, xmm6
psrldq xmm1, 8
psrldq xmm6, 8
paddw xmm7, xmm6
paddd xmm1, xmm2
mov rax, arg(5) ;[Sum]
mov rdi, arg(4) ;[SSE]
movq rdx, xmm7
movsx rcx, dx
mov dword ptr [rax], ecx
movd DWORD PTR [rdi], xmm1
; begin epilog
add rsp, 16
pop rdi
pop rsi
RESTORE_GOT
RESTORE_XMM
UNSHADOW_ARGS
pop rbp
ret
;void vp8_filter_block2d_bil_var_sse2
;(
; unsigned char *ref_ptr,
; int ref_pixels_per_line,
; unsigned char *src_ptr,
; int src_pixels_per_line,
; unsigned int Height,
; int xoffset,
; int yoffset,
; int *sum,
; unsigned int *sumsquared;;
;
;)
global sym(vp8_filter_block2d_bil_var_sse2)
sym(vp8_filter_block2d_bil_var_sse2):
push rbp
mov rbp, rsp
SHADOW_ARGS_TO_STACK 9
SAVE_XMM 7
GET_GOT rbx
push rsi
push rdi
push rbx
; end prolog
pxor xmm6, xmm6 ;
pxor xmm7, xmm7 ;
lea rsi, [GLOBAL(xmm_bi_rd)] ; rounding
movdqa xmm4, XMMWORD PTR [rsi]
lea rcx, [GLOBAL(vp8_bilinear_filters_sse2)]
movsxd rax, dword ptr arg(5) ; xoffset
cmp rax, 0 ; skip first_pass filter if xoffset=0
je filter_block2d_bil_var_sse2_sp_only
shl rax, 5 ; point to filter coeff with xoffset
lea rax, [rax + rcx] ; HFilter
movsxd rdx, dword ptr arg(6) ; yoffset
cmp rdx, 0 ; skip second_pass filter if yoffset=0
je filter_block2d_bil_var_sse2_fp_only
shl rdx, 5
lea rdx, [rdx + rcx] ; VFilter
mov rsi, arg(0) ;ref_ptr
mov rdi, arg(2) ;src_ptr
movsxd rcx, dword ptr arg(4) ;Height
pxor xmm0, xmm0 ;
movq xmm1, QWORD PTR [rsi] ;
movq xmm3, QWORD PTR [rsi+1] ;
punpcklbw xmm1, xmm0 ;
pmullw xmm1, [rax] ;
punpcklbw xmm3, xmm0
pmullw xmm3, [rax+16] ;
paddw xmm1, xmm3 ;
paddw xmm1, xmm4 ;
psraw xmm1, xmm_filter_shift ;
movdqa xmm5, xmm1
movsxd rbx, dword ptr arg(1) ;ref_pixels_per_line
lea rsi, [rsi + rbx]
%if ABI_IS_32BIT=0
movsxd r9, dword ptr arg(3) ;src_pixels_per_line
%endif
filter_block2d_bil_var_sse2_loop:
movq xmm1, QWORD PTR [rsi] ;
movq xmm3, QWORD PTR [rsi+1] ;
punpcklbw xmm1, xmm0 ;
pmullw xmm1, [rax] ;
punpcklbw xmm3, xmm0 ;
pmullw xmm3, [rax+16] ;
paddw xmm1, xmm3 ;
paddw xmm1, xmm4 ;
psraw xmm1, xmm_filter_shift ;
movdqa xmm3, xmm5 ;
movdqa xmm5, xmm1 ;
pmullw xmm3, [rdx] ;
pmullw xmm1, [rdx+16] ;
paddw xmm1, xmm3 ;
paddw xmm1, xmm4 ;
psraw xmm1, xmm_filter_shift ;
movq xmm3, QWORD PTR [rdi] ;
punpcklbw xmm3, xmm0 ;
psubw xmm1, xmm3 ;
paddw xmm6, xmm1 ;
pmaddwd xmm1, xmm1 ;
paddd xmm7, xmm1 ;
lea rsi, [rsi + rbx] ;ref_pixels_per_line
%if ABI_IS_32BIT
add rdi, dword ptr arg(3) ;src_pixels_per_line
%else
lea rdi, [rdi + r9]
%endif
sub rcx, 1 ;
jnz filter_block2d_bil_var_sse2_loop ;
jmp filter_block2d_bil_variance
filter_block2d_bil_var_sse2_sp_only:
movsxd rdx, dword ptr arg(6) ; yoffset
cmp rdx, 0 ; skip all if both xoffset=0 and yoffset=0
je filter_block2d_bil_var_sse2_full_pixel
shl rdx, 5
lea rdx, [rdx + rcx] ; VFilter
mov rsi, arg(0) ;ref_ptr
mov rdi, arg(2) ;src_ptr
movsxd rcx, dword ptr arg(4) ;Height
movsxd rax, dword ptr arg(1) ;ref_pixels_per_line
pxor xmm0, xmm0 ;
movq xmm1, QWORD PTR [rsi] ;
punpcklbw xmm1, xmm0 ;
movsxd rbx, dword ptr arg(3) ;src_pixels_per_line
lea rsi, [rsi + rax]
filter_block2d_bil_sp_only_loop:
movq xmm3, QWORD PTR [rsi] ;
punpcklbw xmm3, xmm0 ;
movdqa xmm5, xmm3
pmullw xmm1, [rdx] ;
pmullw xmm3, [rdx+16] ;
paddw xmm1, xmm3 ;
paddw xmm1, xmm4 ;
psraw xmm1, xmm_filter_shift ;
movq xmm3, QWORD PTR [rdi] ;
punpcklbw xmm3, xmm0 ;
psubw xmm1, xmm3 ;
paddw xmm6, xmm1 ;
pmaddwd xmm1, xmm1 ;
paddd xmm7, xmm1 ;
movdqa xmm1, xmm5 ;
lea rsi, [rsi + rax] ;ref_pixels_per_line
lea rdi, [rdi + rbx] ;src_pixels_per_line
sub rcx, 1 ;
jnz filter_block2d_bil_sp_only_loop ;
jmp filter_block2d_bil_variance
filter_block2d_bil_var_sse2_full_pixel:
mov rsi, arg(0) ;ref_ptr
mov rdi, arg(2) ;src_ptr
movsxd rcx, dword ptr arg(4) ;Height
movsxd rax, dword ptr arg(1) ;ref_pixels_per_line
movsxd rbx, dword ptr arg(3) ;src_pixels_per_line
pxor xmm0, xmm0 ;
filter_block2d_bil_full_pixel_loop:
movq xmm1, QWORD PTR [rsi] ;
punpcklbw xmm1, xmm0 ;
movq xmm2, QWORD PTR [rdi] ;
punpcklbw xmm2, xmm0 ;
psubw xmm1, xmm2 ;
paddw xmm6, xmm1 ;
pmaddwd xmm1, xmm1 ;
paddd xmm7, xmm1 ;
lea rsi, [rsi + rax] ;ref_pixels_per_line
lea rdi, [rdi + rbx] ;src_pixels_per_line
sub rcx, 1 ;
jnz filter_block2d_bil_full_pixel_loop ;
jmp filter_block2d_bil_variance
filter_block2d_bil_var_sse2_fp_only:
mov rsi, arg(0) ;ref_ptr
mov rdi, arg(2) ;src_ptr
movsxd rcx, dword ptr arg(4) ;Height
movsxd rdx, dword ptr arg(1) ;ref_pixels_per_line
pxor xmm0, xmm0 ;
movsxd rbx, dword ptr arg(3) ;src_pixels_per_line
filter_block2d_bil_fp_only_loop:
movq xmm1, QWORD PTR [rsi] ;
movq xmm3, QWORD PTR [rsi+1] ;
punpcklbw xmm1, xmm0 ;
pmullw xmm1, [rax] ;
punpcklbw xmm3, xmm0 ;
pmullw xmm3, [rax+16] ;
paddw xmm1, xmm3 ;
paddw xmm1, xmm4 ;
psraw xmm1, xmm_filter_shift ;
movq xmm3, QWORD PTR [rdi] ;
punpcklbw xmm3, xmm0 ;
psubw xmm1, xmm3 ;
paddw xmm6, xmm1 ;
pmaddwd xmm1, xmm1 ;
paddd xmm7, xmm1 ;
lea rsi, [rsi + rdx]
lea rdi, [rdi + rbx] ;src_pixels_per_line
sub rcx, 1 ;
jnz filter_block2d_bil_fp_only_loop ;
jmp filter_block2d_bil_variance
filter_block2d_bil_variance:
movdq2q mm6, xmm6 ;
movdq2q mm7, xmm7 ;
psrldq xmm6, 8
psrldq xmm7, 8
movdq2q mm2, xmm6
movdq2q mm3, xmm7
paddw mm6, mm2
paddd mm7, mm3
pxor mm3, mm3 ;
pxor mm2, mm2 ;
punpcklwd mm2, mm6 ;
punpckhwd mm3, mm6 ;
paddd mm2, mm3 ;
movq mm6, mm2 ;
psrlq mm6, 32 ;
paddd mm2, mm6 ;
psrad mm2, 16 ;
movq mm4, mm7 ;
psrlq mm4, 32 ;
paddd mm4, mm7 ;
mov rsi, arg(7) ; sum
mov rdi, arg(8) ; sumsquared
movd [rsi], mm2 ; xsum
movd [rdi], mm4 ; xxsum
; begin epilog
pop rbx
pop rdi
pop rsi
RESTORE_GOT
RESTORE_XMM
UNSHADOW_ARGS
pop rbp
ret
;void vp8_half_horiz_vert_variance8x_h_sse2
;(
; unsigned char *ref_ptr,
; int ref_pixels_per_line,
; unsigned char *src_ptr,
; int src_pixels_per_line,
; unsigned int Height,
; int *sum,
; unsigned int *sumsquared
;)
global sym(vp8_half_horiz_vert_variance8x_h_sse2)
sym(vp8_half_horiz_vert_variance8x_h_sse2):
push rbp
mov rbp, rsp
SHADOW_ARGS_TO_STACK 7
SAVE_XMM 7
GET_GOT rbx
push rsi
push rdi
; end prolog
%if ABI_IS_32BIT=0
movsxd r8, dword ptr arg(1) ;ref_pixels_per_line
movsxd r9, dword ptr arg(3) ;src_pixels_per_line
%endif
pxor xmm6, xmm6 ; error accumulator
pxor xmm7, xmm7 ; sse eaccumulator
mov rsi, arg(0) ;ref_ptr ;
mov rdi, arg(2) ;src_ptr ;
movsxd rcx, dword ptr arg(4) ;Height ;
movsxd rax, dword ptr arg(1) ;ref_pixels_per_line
pxor xmm0, xmm0 ;
movq xmm5, QWORD PTR [rsi] ; xmm5 = s0,s1,s2..s8
movq xmm3, QWORD PTR [rsi+1] ; xmm3 = s1,s2,s3..s9
pavgb xmm5, xmm3 ; xmm5 = avg(xmm1,xmm3) horizontal line 1
%if ABI_IS_32BIT
add rsi, dword ptr arg(1) ;ref_pixels_per_line ; next source
%else
add rsi, r8
%endif
vp8_half_horiz_vert_variance8x_h_1:
movq xmm1, QWORD PTR [rsi] ;
movq xmm2, QWORD PTR [rsi+1] ;
pavgb xmm1, xmm2 ; xmm1 = avg(xmm1,xmm3) horizontal line i+1
pavgb xmm5, xmm1 ; xmm = vertical average of the above
punpcklbw xmm5, xmm0 ; xmm5 = words of above
movq xmm3, QWORD PTR [rdi] ; xmm3 = d0,d1,d2..d8
punpcklbw xmm3, xmm0 ; xmm3 = words of above
psubw xmm5, xmm3 ; xmm5 -= xmm3
paddw xmm6, xmm5 ; xmm6 += accumulated column differences
pmaddwd xmm5, xmm5 ; xmm5 *= xmm5
paddd xmm7, xmm5 ; xmm7 += accumulated square column differences
movdqa xmm5, xmm1 ; save xmm1 for use on the next row
%if ABI_IS_32BIT
add esi, dword ptr arg(1) ;ref_pixels_per_line ; next source
add edi, dword ptr arg(3) ;src_pixels_per_line ; next destination
%else
add rsi, r8
add rdi, r9
%endif
sub rcx, 1 ;
jnz vp8_half_horiz_vert_variance8x_h_1 ;
movdq2q mm6, xmm6 ;
movdq2q mm7, xmm7 ;
psrldq xmm6, 8
psrldq xmm7, 8
movdq2q mm2, xmm6
movdq2q mm3, xmm7
paddw mm6, mm2
paddd mm7, mm3
pxor mm3, mm3 ;
pxor mm2, mm2 ;
punpcklwd mm2, mm6 ;
punpckhwd mm3, mm6 ;
paddd mm2, mm3 ;
movq mm6, mm2 ;
psrlq mm6, 32 ;
paddd mm2, mm6 ;
psrad mm2, 16 ;
movq mm4, mm7 ;
psrlq mm4, 32 ;
paddd mm4, mm7 ;
mov rsi, arg(5) ; sum
mov rdi, arg(6) ; sumsquared
movd [rsi], mm2 ;
movd [rdi], mm4 ;
; begin epilog
pop rdi
pop rsi
RESTORE_GOT
RESTORE_XMM
UNSHADOW_ARGS
pop rbp
ret
;void vp8_half_horiz_vert_variance16x_h_sse2
;(
; unsigned char *ref_ptr,
; int ref_pixels_per_line,
; unsigned char *src_ptr,
; int src_pixels_per_line,
; unsigned int Height,
; int *sum,
; unsigned int *sumsquared
;)
global sym(vp8_half_horiz_vert_variance16x_h_sse2)
sym(vp8_half_horiz_vert_variance16x_h_sse2):
push rbp
mov rbp, rsp
SHADOW_ARGS_TO_STACK 7
SAVE_XMM 7
GET_GOT rbx
push rsi
push rdi
; end prolog
pxor xmm6, xmm6 ; error accumulator
pxor xmm7, xmm7 ; sse eaccumulator
mov rsi, arg(0) ;ref_ptr ;
mov rdi, arg(2) ;src_ptr ;
movsxd rcx, dword ptr arg(4) ;Height ;
movsxd rax, dword ptr arg(1) ;ref_pixels_per_line
movsxd rdx, dword ptr arg(3) ;src_pixels_per_line
pxor xmm0, xmm0 ;
movdqu xmm5, XMMWORD PTR [rsi]
movdqu xmm3, XMMWORD PTR [rsi+1]
pavgb xmm5, xmm3 ; xmm5 = avg(xmm1,xmm3) horizontal line 1
lea rsi, [rsi + rax]
vp8_half_horiz_vert_variance16x_h_1:
movdqu xmm1, XMMWORD PTR [rsi] ;
movdqu xmm2, XMMWORD PTR [rsi+1] ;
pavgb xmm1, xmm2 ; xmm1 = avg(xmm1,xmm3) horizontal line i+1
pavgb xmm5, xmm1 ; xmm = vertical average of the above
movdqa xmm4, xmm5
punpcklbw xmm5, xmm0 ; xmm5 = words of above
punpckhbw xmm4, xmm0
movq xmm3, QWORD PTR [rdi] ; xmm3 = d0,d1,d2..d7
punpcklbw xmm3, xmm0 ; xmm3 = words of above
psubw xmm5, xmm3 ; xmm5 -= xmm3
movq xmm3, QWORD PTR [rdi+8]
punpcklbw xmm3, xmm0
psubw xmm4, xmm3
paddw xmm6, xmm5 ; xmm6 += accumulated column differences
paddw xmm6, xmm4
pmaddwd xmm5, xmm5 ; xmm5 *= xmm5
pmaddwd xmm4, xmm4
paddd xmm7, xmm5 ; xmm7 += accumulated square column differences
paddd xmm7, xmm4
movdqa xmm5, xmm1 ; save xmm1 for use on the next row
lea rsi, [rsi + rax]
lea rdi, [rdi + rdx]
sub rcx, 1 ;
jnz vp8_half_horiz_vert_variance16x_h_1 ;
pxor xmm1, xmm1
pxor xmm5, xmm5
punpcklwd xmm0, xmm6
punpckhwd xmm1, xmm6
psrad xmm0, 16
psrad xmm1, 16
paddd xmm0, xmm1
movdqa xmm1, xmm0
movdqa xmm6, xmm7
punpckldq xmm6, xmm5
punpckhdq xmm7, xmm5
paddd xmm6, xmm7
punpckldq xmm0, xmm5
punpckhdq xmm1, xmm5
paddd xmm0, xmm1
movdqa xmm7, xmm6
movdqa xmm1, xmm0
psrldq xmm7, 8
psrldq xmm1, 8
paddd xmm6, xmm7
paddd xmm0, xmm1
mov rsi, arg(5) ;[Sum]
mov rdi, arg(6) ;[SSE]
movd [rsi], xmm0
movd [rdi], xmm6
; begin epilog
pop rdi
pop rsi
RESTORE_GOT
RESTORE_XMM
UNSHADOW_ARGS
pop rbp
ret
;void vp8_half_vert_variance8x_h_sse2
;(
; unsigned char *ref_ptr,
; int ref_pixels_per_line,
; unsigned char *src_ptr,
; int src_pixels_per_line,
; unsigned int Height,
; int *sum,
; unsigned int *sumsquared
;)
global sym(vp8_half_vert_variance8x_h_sse2)
sym(vp8_half_vert_variance8x_h_sse2):
push rbp
mov rbp, rsp
SHADOW_ARGS_TO_STACK 7
SAVE_XMM 7
GET_GOT rbx
push rsi
push rdi
; end prolog
%if ABI_IS_32BIT=0
movsxd r8, dword ptr arg(1) ;ref_pixels_per_line
movsxd r9, dword ptr arg(3) ;src_pixels_per_line
%endif
pxor xmm6, xmm6 ; error accumulator
pxor xmm7, xmm7 ; sse eaccumulator
mov rsi, arg(0) ;ref_ptr ;
mov rdi, arg(2) ;src_ptr ;
movsxd rcx, dword ptr arg(4) ;Height ;
movsxd rax, dword ptr arg(1) ;ref_pixels_per_line
pxor xmm0, xmm0 ;
vp8_half_vert_variance8x_h_1:
movq xmm5, QWORD PTR [rsi] ; xmm5 = s0,s1,s2..s8
movq xmm3, QWORD PTR [rsi+rax] ; xmm3 = s1,s2,s3..s9
pavgb xmm5, xmm3 ; xmm5 = avg(xmm1,xmm3)
punpcklbw xmm5, xmm0 ; xmm5 = words of above
movq xmm3, QWORD PTR [rdi] ; xmm3 = d0,d1,d2..d8
punpcklbw xmm3, xmm0 ; xmm3 = words of above
psubw xmm5, xmm3 ; xmm5 -= xmm3
paddw xmm6, xmm5 ; xmm6 += accumulated column differences
pmaddwd xmm5, xmm5 ; xmm5 *= xmm5
paddd xmm7, xmm5 ; xmm7 += accumulated square column differences
%if ABI_IS_32BIT
add esi, dword ptr arg(1) ;ref_pixels_per_line ; next source
add edi, dword ptr arg(3) ;src_pixels_per_line ; next destination
%else
add rsi, r8
add rdi, r9
%endif
sub rcx, 1 ;
jnz vp8_half_vert_variance8x_h_1 ;
movdq2q mm6, xmm6 ;
movdq2q mm7, xmm7 ;
psrldq xmm6, 8
psrldq xmm7, 8
movdq2q mm2, xmm6
movdq2q mm3, xmm7
paddw mm6, mm2
paddd mm7, mm3
pxor mm3, mm3 ;
pxor mm2, mm2 ;
punpcklwd mm2, mm6 ;
punpckhwd mm3, mm6 ;
paddd mm2, mm3 ;
movq mm6, mm2 ;
psrlq mm6, 32 ;
paddd mm2, mm6 ;
psrad mm2, 16 ;
movq mm4, mm7 ;
psrlq mm4, 32 ;
paddd mm4, mm7 ;
mov rsi, arg(5) ; sum
mov rdi, arg(6) ; sumsquared
movd [rsi], mm2 ;
movd [rdi], mm4 ;
; begin epilog
pop rdi
pop rsi
RESTORE_GOT
RESTORE_XMM
UNSHADOW_ARGS
pop rbp
ret
;void vp8_half_vert_variance16x_h_sse2
;(
; unsigned char *ref_ptr,
; int ref_pixels_per_line,
; unsigned char *src_ptr,
; int src_pixels_per_line,
; unsigned int Height,
; int *sum,
; unsigned int *sumsquared
;)
global sym(vp8_half_vert_variance16x_h_sse2)
sym(vp8_half_vert_variance16x_h_sse2):
push rbp
mov rbp, rsp
SHADOW_ARGS_TO_STACK 7
SAVE_XMM 7
GET_GOT rbx
push rsi
push rdi
; end prolog
pxor xmm6, xmm6 ; error accumulator
pxor xmm7, xmm7 ; sse eaccumulator
mov rsi, arg(0) ;ref_ptr
mov rdi, arg(2) ;src_ptr
movsxd rcx, dword ptr arg(4) ;Height
movsxd rax, dword ptr arg(1) ;ref_pixels_per_line
movsxd rdx, dword ptr arg(3) ;src_pixels_per_line
movdqu xmm5, XMMWORD PTR [rsi]
lea rsi, [rsi + rax ]
pxor xmm0, xmm0
vp8_half_vert_variance16x_h_1:
movdqu xmm3, XMMWORD PTR [rsi]
pavgb xmm5, xmm3 ; xmm5 = avg(xmm1,xmm3)
movdqa xmm4, xmm5
punpcklbw xmm5, xmm0
punpckhbw xmm4, xmm0
movq xmm2, QWORD PTR [rdi]
punpcklbw xmm2, xmm0
psubw xmm5, xmm2
movq xmm2, QWORD PTR [rdi+8]
punpcklbw xmm2, xmm0
psubw xmm4, xmm2
paddw xmm6, xmm5 ; xmm6 += accumulated column differences
paddw xmm6, xmm4
pmaddwd xmm5, xmm5 ; xmm5 *= xmm5
pmaddwd xmm4, xmm4
paddd xmm7, xmm5 ; xmm7 += accumulated square column differences
paddd xmm7, xmm4
movdqa xmm5, xmm3
lea rsi, [rsi + rax]
lea rdi, [rdi + rdx]
sub rcx, 1
jnz vp8_half_vert_variance16x_h_1
pxor xmm1, xmm1
pxor xmm5, xmm5
punpcklwd xmm0, xmm6
punpckhwd xmm1, xmm6
psrad xmm0, 16
psrad xmm1, 16
paddd xmm0, xmm1
movdqa xmm1, xmm0
movdqa xmm6, xmm7
punpckldq xmm6, xmm5
punpckhdq xmm7, xmm5
paddd xmm6, xmm7
punpckldq xmm0, xmm5
punpckhdq xmm1, xmm5
paddd xmm0, xmm1
movdqa xmm7, xmm6
movdqa xmm1, xmm0
psrldq xmm7, 8
psrldq xmm1, 8
paddd xmm6, xmm7
paddd xmm0, xmm1
mov rsi, arg(5) ;[Sum]
mov rdi, arg(6) ;[SSE]
movd [rsi], xmm0
movd [rdi], xmm6
; begin epilog
pop rdi
pop rsi
RESTORE_GOT
RESTORE_XMM
UNSHADOW_ARGS
pop rbp
ret
;void vp8_half_horiz_variance8x_h_sse2
;(
; unsigned char *ref_ptr,
; int ref_pixels_per_line,
; unsigned char *src_ptr,
; int src_pixels_per_line,
; unsigned int Height,
; int *sum,
; unsigned int *sumsquared
;)
global sym(vp8_half_horiz_variance8x_h_sse2)
sym(vp8_half_horiz_variance8x_h_sse2):
push rbp
mov rbp, rsp
SHADOW_ARGS_TO_STACK 7
SAVE_XMM 7
GET_GOT rbx
push rsi
push rdi
; end prolog
%if ABI_IS_32BIT=0
movsxd r8, dword ptr arg(1) ;ref_pixels_per_line
movsxd r9, dword ptr arg(3) ;src_pixels_per_line
%endif
pxor xmm6, xmm6 ; error accumulator
pxor xmm7, xmm7 ; sse eaccumulator
mov rsi, arg(0) ;ref_ptr ;
mov rdi, arg(2) ;src_ptr ;
movsxd rcx, dword ptr arg(4) ;Height ;
pxor xmm0, xmm0 ;
vp8_half_horiz_variance8x_h_1:
movq xmm5, QWORD PTR [rsi] ; xmm5 = s0,s1,s2..s8
movq xmm3, QWORD PTR [rsi+1] ; xmm3 = s1,s2,s3..s9
pavgb xmm5, xmm3 ; xmm5 = avg(xmm1,xmm3)
punpcklbw xmm5, xmm0 ; xmm5 = words of above
movq xmm3, QWORD PTR [rdi] ; xmm3 = d0,d1,d2..d8
punpcklbw xmm3, xmm0 ; xmm3 = words of above
psubw xmm5, xmm3 ; xmm5 -= xmm3
paddw xmm6, xmm5 ; xmm6 += accumulated column differences
pmaddwd xmm5, xmm5 ; xmm5 *= xmm5
paddd xmm7, xmm5 ; xmm7 += accumulated square column differences
%if ABI_IS_32BIT
add esi, dword ptr arg(1) ;ref_pixels_per_line ; next source
add edi, dword ptr arg(3) ;src_pixels_per_line ; next destination
%else
add rsi, r8
add rdi, r9
%endif
sub rcx, 1 ;
jnz vp8_half_horiz_variance8x_h_1 ;
movdq2q mm6, xmm6 ;
movdq2q mm7, xmm7 ;
psrldq xmm6, 8
psrldq xmm7, 8
movdq2q mm2, xmm6
movdq2q mm3, xmm7
paddw mm6, mm2
paddd mm7, mm3
pxor mm3, mm3 ;
pxor mm2, mm2 ;
punpcklwd mm2, mm6 ;
punpckhwd mm3, mm6 ;
paddd mm2, mm3 ;
movq mm6, mm2 ;
psrlq mm6, 32 ;
paddd mm2, mm6 ;
psrad mm2, 16 ;
movq mm4, mm7 ;
psrlq mm4, 32 ;
paddd mm4, mm7 ;
mov rsi, arg(5) ; sum
mov rdi, arg(6) ; sumsquared
movd [rsi], mm2 ;
movd [rdi], mm4 ;
; begin epilog
pop rdi
pop rsi
RESTORE_GOT
RESTORE_XMM
UNSHADOW_ARGS
pop rbp
ret
;void vp8_half_horiz_variance16x_h_sse2
;(
; unsigned char *ref_ptr,
; int ref_pixels_per_line,
; unsigned char *src_ptr,
; int src_pixels_per_line,
; unsigned int Height,
; int *sum,
; unsigned int *sumsquared
;)
global sym(vp8_half_horiz_variance16x_h_sse2)
sym(vp8_half_horiz_variance16x_h_sse2):
push rbp
mov rbp, rsp
SHADOW_ARGS_TO_STACK 7
SAVE_XMM 7
GET_GOT rbx
push rsi
push rdi
; end prolog
pxor xmm6, xmm6 ; error accumulator
pxor xmm7, xmm7 ; sse eaccumulator
mov rsi, arg(0) ;ref_ptr ;
mov rdi, arg(2) ;src_ptr ;
movsxd rcx, dword ptr arg(4) ;Height ;
movsxd rax, dword ptr arg(1) ;ref_pixels_per_line
movsxd rdx, dword ptr arg(3) ;src_pixels_per_line
pxor xmm0, xmm0 ;
vp8_half_horiz_variance16x_h_1:
movdqu xmm5, XMMWORD PTR [rsi] ; xmm5 = s0,s1,s2..s15
movdqu xmm3, XMMWORD PTR [rsi+1] ; xmm3 = s1,s2,s3..s16
pavgb xmm5, xmm3 ; xmm5 = avg(xmm1,xmm3)
movdqa xmm1, xmm5
punpcklbw xmm5, xmm0 ; xmm5 = words of above
punpckhbw xmm1, xmm0
movq xmm3, QWORD PTR [rdi] ; xmm3 = d0,d1,d2..d7
punpcklbw xmm3, xmm0 ; xmm3 = words of above
movq xmm2, QWORD PTR [rdi+8]
punpcklbw xmm2, xmm0
psubw xmm5, xmm3 ; xmm5 -= xmm3
psubw xmm1, xmm2
paddw xmm6, xmm5 ; xmm6 += accumulated column differences
paddw xmm6, xmm1
pmaddwd xmm5, xmm5 ; xmm5 *= xmm5
pmaddwd xmm1, xmm1
paddd xmm7, xmm5 ; xmm7 += accumulated square column differences
paddd xmm7, xmm1
lea rsi, [rsi + rax]
lea rdi, [rdi + rdx]
sub rcx, 1 ;
jnz vp8_half_horiz_variance16x_h_1 ;
pxor xmm1, xmm1
pxor xmm5, xmm5
punpcklwd xmm0, xmm6
punpckhwd xmm1, xmm6
psrad xmm0, 16
psrad xmm1, 16
paddd xmm0, xmm1
movdqa xmm1, xmm0
movdqa xmm6, xmm7
punpckldq xmm6, xmm5
punpckhdq xmm7, xmm5
paddd xmm6, xmm7
punpckldq xmm0, xmm5
punpckhdq xmm1, xmm5
paddd xmm0, xmm1
movdqa xmm7, xmm6
movdqa xmm1, xmm0
psrldq xmm7, 8
psrldq xmm1, 8
paddd xmm6, xmm7
paddd xmm0, xmm1
mov rsi, arg(5) ;[Sum]
mov rdi, arg(6) ;[SSE]
movd [rsi], xmm0
movd [rdi], xmm6
; begin epilog
pop rdi
pop rsi
RESTORE_GOT
RESTORE_XMM
UNSHADOW_ARGS
pop rbp
ret
SECTION_RODATA
; short xmm_bi_rd[8] = { 64, 64, 64, 64,64, 64, 64, 64};
align 16
xmm_bi_rd:
times 8 dw 64
align 16
vp8_bilinear_filters_sse2:
dw 128, 128, 128, 128, 128, 128, 128, 128, 0, 0, 0, 0, 0, 0, 0, 0
dw 112, 112, 112, 112, 112, 112, 112, 112, 16, 16, 16, 16, 16, 16, 16, 16
dw 96, 96, 96, 96, 96, 96, 96, 96, 32, 32, 32, 32, 32, 32, 32, 32
dw 80, 80, 80, 80, 80, 80, 80, 80, 48, 48, 48, 48, 48, 48, 48, 48
dw 64, 64, 64, 64, 64, 64, 64, 64, 64, 64, 64, 64, 64, 64, 64, 64
dw 48, 48, 48, 48, 48, 48, 48, 48, 80, 80, 80, 80, 80, 80, 80, 80
dw 32, 32, 32, 32, 32, 32, 32, 32, 96, 96, 96, 96, 96, 96, 96, 96
dw 16, 16, 16, 16, 16, 16, 16, 16, 112, 112, 112, 112, 112, 112, 112, 112
| awatry/libvpx.opencl | vp8/encoder/x86/variance_impl_sse2.asm | Assembly | bsd-3-clause | 47,154 |
%include "pm.inc"
org 0100h
jmp LABEL_BEGIN
[section .gdt]
; GDT
; 段基址, 段界限 , 属性
LABEL_GDT: Descriptor 0, 0, 0
; 空描述符
LABEL_DESC_NORMAL: Descriptor 0, 0ffffh, DA_DRW
; Normal 描述符
LABEL_DESC_CODE32: Descriptor 0, SegCode32Len-1, DA_C+DA_32
; 非一致代码段, 32
LABEL_DESC_CODE16: Descriptor 0, 0ffffh, DA_C
; 非一致代码段, 16
LABEL_DESC_DATA: Descriptor 0, DataLen-1, DA_DRW
; Data
LABEL_DESC_STACK: Descriptor 0, TopOfStack, DA_DRWA+DA_32
; Stack, 32 位
LABEL_DESC_TEST: Descriptor 0500000h, 0ffffh, DA_DRW
; test 数据段
LABEL_DESC_VIDEO: Descriptor 0B8000h, 0ffffh, DA_DRW
; 显存首地址
; GDT 结束
GdtLen equ $-LABEL_GDT
GdtPtr dw GdtLen-1
dd 0
; selector
SelectorNormal equ LABEL_DESC_NORMAL - LABEL_GDT
SelectorCode32 equ LABEL_DESC_CODE32 - LABEL_GDT
SelectorCode16 equ LABEL_DESC_CODE16 - LABEL_GDT
SelectorData equ LABEL_DESC_DATA - LABEL_GDT
SelectorStack equ LABEL_DESC_STACK - LABEL_GDT
SelectorTest equ LABEL_DESC_TEST - LABEL_GDT
SelectorVideo equ LABEL_DESC_VIDEO - LABEL_GDT
; END of [SECTION .gdt]
[section .data1]
align 32
[BITS 32]
LABEL_DATA:
SPValueInRealMode dw 0
PMMessage: db "In Protect Mode now." ,0 ;保护模式显示
OffsetPMMessage equ PMMessage-$$
StrText: db "ABCDEFGHIJKLMNOP" ,0 ;
OffsetStrText equ StrText-$$
DataLen equ $-LABEL_DATA
; end of [section .data1]
[section .gs]
align 32
[bits 32]
LABEL_STACK:
times 512 db 0
TopOfStack equ $-LABEL_STACK-1
; end of [section .gs]
[section .s16]
[BITS 16]
LABEL_BEGIN:
mov ax, cs
mov ds, ax
mov es, ax
mov ss, ax
mov sp, 0100h
mov [LABEL_GO_BACK_TO_REAL+3] ,ax
;整个程序的最后一个指令的下一个地址
mov [SPValueInRealMode] ,sp
mov ax, cs
movzx eax, ax
shl eax ,4
add eax ,LABEL_SEG_CODE16
mov word[LABEL_DESC_CODE16+2] ,ax
shr eax ,16
mov byte[LABEL_DESC_CODE16+4] ,al
mov byte[LABEL_DESC_CODE16+7] ,ah
xor eax ,eax
mov ax ,cs
shl eax ,4
add eax ,LABEL_SEG_CODE32
mov word[LABEL_DESC_CODE32+2] ,ax
shr eax ,16
mov byte[LABEL_DESC_CODE32+4] ,al
mov byte[LABEL_DESC_CODE32+7] ,ah
xor eax ,eax
mov ax ,ds
shl eax ,4
add eax ,LABEL_DATA
mov word[LABEL_DESC_DATA+2] ,ax
shr eax ,16
mov byte[LABEL_DESC_DATA+4] ,al
mov byte[LABEL_DESC_DATA+7] ,ah
xor eax ,eax
mov ax ,ds
shl eax ,4
add eax ,LABEL_STACK
mov word[LABEL_DESC_STACK+2] ,ax
shr eax ,16
mov byte[LABEL_DESC_STACK+4] ,al
mov byte[LABEL_DESC_STACK+7] ,ah
xor eax ,eax
mov ax ,ds
xor eax ,eax
mov ax ,ds
shl eax ,4
add eax ,LABEL_GDT
mov dword[GdtPtr+2] ,eax
lgdt [GdtPtr]
cli
in al ,92h
or al ,00000010b
out 92h ,al
mov eax ,cr0
or eax ,1
mov cr0 ,eax
jmp dword SelectorCode32:0
LABEL_REAL_ENTRY:
mov ax ,cs
mov ds ,ax
mov es ,ax
mov ss ,ax
mov sp ,[SPValueInRealMode]
in al ,92h
and al ,11111101b
out 92h ,al
sti
mov ax ,004ch
int 21h
; end of [section .s16]
[section .s32]
[BITS 32]
LABEL_SEG_CODE32:
mov ax ,SelectorData
mov ds ,ax
mov ax ,SelectorTest
mov es ,ax
mov ax ,SelectorVideo
mov gs ,ax
mov ax ,SelectorStack
mov ss ,ax
mov esp ,TopOfStack
mov ah ,0Ch
xor esi ,esi
xor edi ,edi
mov esi ,OffsetPMMessage
mov edi ,40
cld
.1:
lodsb
test al ,al
jz .2
mov [gs:edi] ,ax
add edi ,2
jmp .1
.2:; 显示完毕
call DispReturn
call TestRead
call TestWrite
call TestRead
jmp SelectorCode16:0
TestRead:
xor esi ,esi
mov ecx ,8
.loop:
mov al ,[es:esi]
call DispAL
inc esi
loop .loop
call DispReturn
ret
TestWrite:
push esi
push edi
xor esi ,esi
xor edi ,edi
mov esi ,OffsetStrText
cld
.1:
lodsb
test al ,al
jz .2
mov [es:edi] ,al
inc edi
jmp .1
.2:
pop edi
pop esi
ret
DispAL:
push ecx
push edx
mov ah ,0Ch
mov dl ,al
shr al ,4
mov ecx ,2
.begin:
and al ,01111b
cmp al ,9
ja .1
add al ,'0'
jmp .2
.1:
sub al ,0Ah
add al ,'A'
.2:
mov [gs:edi] ,ax
add edi ,2
mov al ,dl
loop .begin
add edi ,2
pop edx
pop ecx
ret
DispReturn:
push eax
push ebx
mov eax ,edi
mov bl ,160
div bl
and eax ,0FFh
inc eax
mov bl ,160
mul bl
mov edi ,eax
pop ebx
pop eax
ret
SegCode32Len equ $-LABEL_SEG_CODE32
[SECTION .s16code]
align 32
[BITS 16]
LABEL_SEG_CODE16:
mov ax ,SelectorNormal
mov ds ,ax
mov es ,ax
mov fs ,ax
mov gs ,ax
mov ss ,ax
mov eax ,cr0
and al ,11111110b
mov cr0 ,eax
LABEL_GO_BACK_TO_REAL:
jmp 0:LABEL_REAL_ENTRY
Code16Len equ $-LABEL_SEG_CODE16
| RongbinZhuang/simpleOS | ver0/2_pro/2longJmp/pmtest2.asm | Assembly | mit | 4,584 |
; DOSboot.asm - Boot from DOS loader
; Written in 2013 by Congdm
;
; To the extent possible under law, the author(s) have dedicated
; all copyright and related and neighboring rights to this software
; to the public domain worldwide. This software is distributed
; without any warranty.
; You should have received a copy of the CC0 Public Domain Dedication
; along with this software.
; If not, see http://creativecommons.org/publicdomain/zero/1.0/
org $100
use16
Begin:
push Var.Loader4_filename
push $1000
push $7E00
push $3000
call Procedure_Load_file
push Var.Excp_filename
push $1000
push $0
push $4000
call Procedure_Load_file
push Var.Memory_filename
push $1000
push $1000
push $4000
call Procedure_Load_file
;push Var.Module_filename
;push $1000
;push $1000
;push $4000
;call Procedure_Load_file
;push Var.Video_filename
;push $1000
;push $2000
;push $4000
;call Procedure_Load_file
;push Var.8259A_filename
;push $1000
;push $3000
;push $4000
;call Procedure_Load_file
;push Var.Thread_filename
;push $1000
;push $4000
;push $4000
;call Procedure_Load_file
push ds
xor ax, ax
mov ds, ax
mov [$F000], ax
mov [$F002], ax
mov ax, $E801
int $15
test ax, ax
jz .Use_CX
mov [$F000], ax
mov [$F002], bx
jmp .j1
.Use_CX:
mov [$F000], cx
mov [$F002], dx
.j1: pop ds
jmp Switch_to_Protected_Mode
Procedure_Load_file:
.Filename equ word [ss:bp + 10]
.Size equ word [ss:bp + 8]
.Dest_off equ word [ss:bp + 6]
.Dest_seg equ word [ss:bp + 4]
push bp
mov bp, sp
mov ah, $3D
xor al, al
mov dx, .Filename
xor cl, cl
int $21
jc .Error1
push ds
push ax
mov bx, ax
mov cx, .Size
mov ax, .Dest_seg
mov ds, ax
mov dx, .Dest_off
mov ah, $3F
int $21
jc .Error2
.Finish:
pop bx
mov ah, $3E
int $21
pop ds
mov ah, 9
mov dx, .Filename
int $21
mov ah, 9
mov dx, Var.Text1
int $21
.Return:
pop bp
ret 8
.Error1:
mov ah, 9
mov dx, Var.Error_text1
int $21
mov ah, 9
mov dx, .Filename
int $21
int $20
.Error2:
pop bx
mov ah, $3E
int $21
pop ds
mov ah, 9
mov dx, Var.Error_text2
int $21
mov ah, 9
mov dx, .Filename
int $21
int $20
restore .Filename
restore .Dest_off
restore .Dest_seg
Var:
.Loader4_filename db 'Loader4.bin',0,'$'
.Excp_filename db 'Excp.bin',0,'$'
.Memory_filename db 'Memory.bin',0,'$'
.Module_filename db 'Module.bin',0,'$'
.Video_filename db 'CoreVGA.bin',0,'$'
.8259A_filename db '8259A.bin',0,'$'
.Thread_filename db 'Thread.bin',0,'$'
.Error_text1 db 'Can not open file $'
.Error_text2 db 'Can not read file $'
.Text1 db 'is loaded',13,10,'$'
Switch_to_Protected_Mode:
cli
call enable_A20
xor ebx, ebx
mov bx, ds
shl ebx, 4
add [GDT_Desc.gdtaddr], ebx
xor ax, ax
mov es, ax
mov [es:0], byte $EA
mov [es:1], byte $00
mov [es:2], byte $7E
mov [es:3], byte $03
mov [es:4], byte $00
mov [es:5], byte $08
mov [es:6], byte $00
lgdt [GDT_Desc]
mov eax, cr0
or eax, 1
mov cr0, eax
jmp $8:$0
enable_A20:
call .a20wait
mov al, $AD
out $64, al
call .a20wait
mov al, $D0
out $64, al
call .a20wait2
in al, $60
push ax
call .a20wait
mov al, $D1
out $64, al
call .a20wait
pop ax
or al, 2
out $60, al
call .a20wait
mov al, $AE
out $64, al
call .a20wait
ret
.a20wait:
in al, $64
test al, 2
jnz .a20wait
ret
.a20wait2:
in al, $64
test al, 1
jz .a20wait2
ret
GDT:
.gdt_null: ; 0 - Null
dq 0
.gdt_code: ; 1 - Code
dw $FFFF
dw 0
db 0
db 10011010b
db 11001111b
db 0
.gdt_gdata: ; 2 - Data
dw $FFFF
dw 0
db 0
db 10010010b
db 11001111b
db 0
gdt_end:
GDT_Desc:
dw gdt_end - GDT - 1
.gdtaddr dd GDT | softzian/ElseeSystem | source/DOSboot.asm | Assembly | cc0-1.0 | 3,874 |
;////////////////////////////////////////////////////////////////////////////////////////////////////////
;// Part of Injectable Generic Camera System
;// Copyright(c) 2017, Frans Bouma
;// All rights reserved.
;// https://github.com/FransBouma/InjectableGenericCameraSystem
;//
;// Redistribution and use in source and binary forms, with or without
;// modification, are permitted provided that the following conditions are met :
;//
;// * Redistributions of source code must retain the above copyright notice, this
;// list of conditions and the following disclaimer.
;//
;// * Redistributions in binary form must reproduce the above copyright notice,
;// this list of conditions and the following disclaimer in the documentation
;// and / or other materials provided with the distribution.
;//
;// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
;// AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
;// IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
;// DISCLAIMED.IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE
;// FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
;// DAMAGES(INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
;// SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
;// CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
;// OR TORT(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
;// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
;////////////////////////////////////////////////////////////////////////////////////////////////////////
;---------------------------------------------------------------
; Game specific asm file to intercept execution flow to obtain addresses, prevent writes etc.
;---------------------------------------------------------------
;---------------------------------------------------------------
; Public definitions so the linker knows which names are present in this file
PUBLIC cameraStructInterceptor
PUBLIC cameraWrite1Interceptor
PUBLIC cameraWrite2Interceptor
PUBLIC cameraWrite3Interceptor
PUBLIC fovReadInterceptor
;---------------------------------------------------------------
;---------------------------------------------------------------
; Externs which are used and set by the system. Read / write these
; values in asm to communicate with the system
EXTERN g_cameraEnabled: byte
EXTERN g_cameraStructAddress: qword
EXTERN g_fovConstructAddress: qword
EXTERN g_timestopStructAddress: qword
;---------------------------------------------------------------
;---------------------------------------------------------------
; Own externs, defined in InterceptorHelper.cpp
EXTERN _cameraStructInterceptionContinue: qword
EXTERN _cameraWrite1InterceptionContinue: qword
EXTERN _cameraWrite2InterceptionContinue: qword
EXTERN _cameraWrite3InterceptionContinue: qword
EXTERN _fovReadInterceptionContinue: qword
EXTERN _timestopInterceptionContinue: qword
.data
;---------------------------------------------------------------
; Scratch pad
; player intercept. Is matrix (3x4, where the the coords are the lower row, write like this:
;---------------------------------------------------------------
; Blocks used by camera tools, not by this .asm file, blocks are used in AOB scans to obtain RIP relative addresses (see commments below)
; Supersampling read
; patch v1.0.3
;0000000140FC3FF0 | 41 F7 F8 | idiv r8d << START OF AOB BLOCK
;0000000140FC3FF3 | 44 8B C0 | mov r8d,eax
;0000000140FC3FF6 | 8B C1 | mov eax,ecx
;0000000140FC3FF8 | 8B 0D 7A E7 4E 01 | mov ecx,dword ptr ds:[1424B2778] << Supersampling read
;0000000140FC3FFE | 99 | cdq
;0000000140FC3FFF | F7 FF | idiv edi
;0000000140FC4001 | 44 3B C0 | cmp r8d,eax
;0000000140FC4004 | 41 0F 4C C0 | cmovl eax,r8d
;0000000140FC4008 | 83 F9 01 | cmp ecx,1
;0000000140FC400B | 7D 07 | jge prey_dump.140FC4014
;0000000140FC400D | B8 01 00 00 00 | mov eax,1
;0000000140FC4012 | EB 05 | jmp prey_dump.140FC4019
;0000000140FC4014 | 3B C8 | cmp ecx,eax
;0000000140FC4016 | 0F 4C C1 | cmovl eax,ecx
;0000000140FC4019 | 39 83 F4 F3 00 00 | cmp dword ptr ds:[rbx+F3F4],eax
;0000000140FC401F | 74 13 | je prey_dump.140FC4034
;0000000140FC4021 | 89 83 F4 F3 00 00 | mov dword ptr ds:[rbx+F3F4],eax
;0000000140FC4027 | B0 01 | mov al,1
;0000000140FC4029 | 48 8B 5C 24 30 | mov rbx,qword ptr ss:[rsp+30]
;0000000140FC402E | 48 83 C4 20 | add rsp,20
;0000000140FC4032 | 5F | pop rdi
;0000000140FC4033 | C3 | ret
;0000000140FC4034 | 32 C0 | xor al,al
;0000000140FC4036 | 48 8B 5C 24 30 | mov rbx,qword ptr ss:[rsp+30]
;0000000140FC403B | 48 83 C4 20 | add rsp,20
;0000000140FC403F | 5F | pop rdi
;0000000140FC4040 | C3 | ret
;
; sys_flash cvar read (for hud toggle)
; v1.0.3
;0000000146F06D30 | 48 89 74 24 10 | mov qword ptr ss:[rsp+10],rsi
;0000000146F06D35 | 57 | push rdi
;0000000146F06D36 | 48 83 EC 20 | sub rsp,20
;0000000146F06D3A | 83 3D 2B 46 48 FB 00 | cmp dword ptr ds:[14238B36C],0 << sys_flash read << START OF AOB BLOCK
;0000000146F06D41 | 0F B6 F2 | movzx esi,dl
;0000000146F06D44 | 48 89 CF | mov rdi,rcx
;0000000146F06D47 | 74 2E | je prey_dump.146F06D77
;0000000146F06D49 | 48 8B 81 C8 00 00 00 | mov rax,qword ptr ds:[rcx+C8]
;0000000146F06D50 | 48 89 5C 24 30 | mov qword ptr ss:[rsp+30],rbx
;0000000146F06D55 | 48 8B 58 38 | mov rbx,qword ptr ds:[rax+38]
;0000000146F06D59 | 48 8B 01 | mov rax,qword ptr ds:[rcx]
;0000000146F06D5C | FF 10 | call qword ptr ds:[rax]
;0000000146F06D5E | 48 8B 03 | mov rax,qword ptr ds:[rbx]
;0000000146F06D61 | 48 8D 57 08 | lea rdx,qword ptr ds:[rdi+8]
;0000000146F06D65 | 44 0F B6 C6 | movzx r8d,sil
;0000000146F06D69 | 48 89 D9 | mov rcx,rbx
;0000000146F06D6C | FF 90 68 03 00 00 | call qword ptr ds:[rax+368]
;0000000146F06D72 | 48 8B 5C 24 30 | mov rbx,qword ptr ss:[rsp+30]
;0000000146F06D77 | 48 8B 74 24 38 | mov rsi,qword ptr ss:[rsp+38]
;0000000146F06D7C | 48 83 C4 20 | add rsp,20
;0000000146F06D80 | 5F | pop rdi
;0000000146F06D81 | C3 | ret
;
.code
cameraStructInterceptor PROC
; Struct interceptor is also a write interceptor for coords/quaternion
; patch 1.0.2
;Prey.exe+150E5DF - F3 0F11 4E 0C - movss [rsi+0C],xmm1 // quaternion << intercept here
;Prey.exe+150E5E4 - F3 0F11 56 10 - movss [rsi+10],xmm2
;Prey.exe+150E5E9 - F3 0F11 5E 14 - movss [rsi+14],xmm3
;Prey.exe+150E5EE - F3 0F11 46 18 - movss [rsi+18],xmm0
;Prey.exe+150E5F3 - F3 0F11 3E - movss [rsi],xmm7 // coords
;Prey.exe+150E5F7 - F3 0F11 76 04 - movss [rsi+04],xmm6
;Prey.exe+150E5FC - F3 44 0F11 46 08 - movss [rsi+08],xmm8
;Prey.exe+150E602 - E8 8946D5FF - call Prey.exe+1262C90 << continue here
; This function intercepts the camera address and also blocks the writes by reading from our own two structs.
mov [g_cameraStructAddress], rsi
cmp byte ptr [g_cameraEnabled], 1 ; check if the user enabled the camera. If so, just skip the write statements, otherwise just execute the original code.
je exit ; our own camera is enabled, just skip the writes
originalCode:
movss dword ptr [rsi+0Ch],xmm1 ; quaternion (x/y/z/w)
movss dword ptr [rsi+10h],xmm2
movss dword ptr [rsi+14h],xmm3
movss dword ptr [rsi+18h],xmm0
movss dword ptr [rsi],xmm7 ; coords
movss dword ptr [rsi+04h],xmm6
movss dword ptr [rsi+08h],xmm8
exit:
jmp qword ptr [_cameraStructInterceptionContinue] ; jmp back into the original game code, which is the location after the original statements above.
cameraStructInterceptor ENDP
cameraWrite1Interceptor PROC
; patch 1.0.2
;Prey.exe+386A10 - 8B 02 - mov eax,[rdx] << INTERCEPT HERE
;Prey.exe+386A12 - 89 01 - mov [rcx],eax // coords
;Prey.exe+386A14 - 8B 42 04 - mov eax,[rdx+04]
;Prey.exe+386A17 - 89 41 04 - mov [rcx+04],eax
;Prey.exe+386A1A - 8B 42 08 - mov eax,[rdx+08]
;Prey.exe+386A1D - 89 41 08 - mov [rcx+08],eax
;Prey.exe+386A20 - 8B 42 0C - mov eax,[rdx+0C]
;Prey.exe+386A23 - 89 41 0C - mov [rcx+0C],eax // qX
;Prey.exe+386A26 - 8B 42 10 - mov eax,[rdx+10]
;Prey.exe+386A29 - 89 41 10 - mov [rcx+10],eax
;Prey.exe+386A2C - 8B 42 14 - mov eax,[rdx+14]
;Prey.exe+386A2F - 89 41 14 - mov [rcx+14],eax
;Prey.exe+386A32 - 8B 42 18 - mov eax,[rdx+18]
;Prey.exe+386A35 - 89 41 18 - mov [rcx+18],eax // qW
;Prey.exe+386A38 - 8B 42 1C - mov eax,[rdx+1C]
;Prey.exe+386A3B - 89 41 1C - mov [rcx+1C],eax << CONTINUE HERE
;Prey.exe+386A3E - 8B 42 20 - mov eax,[rdx+20]
;Prey.exe+386A41 - 89 41 20 - mov [rcx+20],eax
;Prey.exe+386A44 - 8B 42 24 - mov eax,[rdx+24]
;Prey.exe+386A47 - 89 41 24 - mov [rcx+24],eax
;Prey.exe+386A4A - 8B 42 28 - mov eax,[rdx+28]
;Prey.exe+386A4D - 89 41 28 - mov [rcx+28],eax
;Prey.exe+386A50 - 8B 42 2C - mov eax,[rdx+2C]
;Prey.exe+386A53 - 89 41 2C - mov [rcx+2C],eax
;Prey.exe+386A56 - 8B 42 30 - mov eax,[rdx+30]
;Prey.exe+386A59 - 89 41 30 - mov [rcx+30],eax
;Prey.exe+386A5C - 8B 42 34 - mov eax,[rdx+34]
;Prey.exe+386A5F - 89 41 34 - mov [rcx+34],eax
;Prey.exe+386A62 - 0FB6 42 38 - movzx eax,byte ptr [rdx+38]
;Prey.exe+386A66 - 88 41 38 - mov [rcx+38],al
;Prey.exe+386A69 - 0FB6 42 39 - movzx eax,byte ptr [rdx+39]
;Prey.exe+386A6D - 88 41 39 - mov [rcx+39],al
cmp byte ptr [g_cameraEnabled], 1 ; check if the user enabled the camera. If so, just skip the write statements, otherwise just execute the original code.
je exit ; our own camera is enabled, just skip the writes
originalCode:
mov eax,[rdx]
mov [rcx],eax
mov eax,[rdx+04h]
mov [rcx+04h],eax
mov eax,[rdx+08h]
mov [rcx+08h],eax
mov eax,[rdx+0Ch]
mov [rcx+0Ch],eax
mov eax,[rdx+10h]
mov [rcx+10h],eax
mov eax,[rdx+14h]
mov [rcx+14h],eax
mov eax,[rdx+18h]
mov [rcx+18h],eax
exit:
jmp qword ptr [_cameraWrite1InterceptionContinue] ; jmp back into the original game code, which is the location after the original statements above.
cameraWrite1Interceptor ENDP
cameraWrite2Interceptor PROC
; coord write intercept is broken up in two blocks as it has a relative read in the middle.... WHY is that statement placed at that spot!
;Prey.AK::Monitor::PostCode+24A38A - F3 44 0F58 68 04 - addss xmm13,[rax+04] << INTERCEPT HERE
;Prey.AK::Monitor::PostCode+24A390 - F3 44 0F58 20 - addss xmm12,[rax]
;Prey.AK::Monitor::PostCode+24A395 - F3 44 0F58 70 08 - addss xmm14,[rax+08]
;Prey.AK::Monitor::PostCode+24A39B - F3 44 0F11 67 1C - movss [rdi+1C],xmm12 // write x
;Prey.AK::Monitor::PostCode+24A3A1 - F3 44 0F11 6F 20 - movss [rdi+20],xmm13 // write y
;Prey.AK::Monitor::PostCode+24A3A7 - F3 44 0F10 2D 08DAC401 - movss xmm13,[Prey.CreateAudioInputSource+51B6B8] << CONTINUE HERE
addss xmm13, dword ptr [rax+04h] ; original statement
addss xmm12, dword ptr [rax]
addss xmm14, dword ptr [rax+08h]
cmp byte ptr [g_cameraEnabled], 1 ; check if the user enabled the camera. If so, just skip the write statements, otherwise just execute the original code.
je exit ; our own camera is enabled, just skip the writes
movss dword ptr [rdi+1Ch],xmm12
movss dword ptr [rdi+20h],xmm13
exit:
jmp qword ptr [_cameraWrite2InterceptionContinue] ; jmp back into the original game code, which is the location after the original statements above.
cameraWrite2Interceptor ENDP
cameraWrite3Interceptor PROC
;Prey.AK::Monitor::PostCode+24A3B0 - F3 44 0F11 77 24 - movss [rdi+24],xmm14 << INTERCEPT HERE, write Z
;Prey.AK::Monitor::PostCode+24A3B6 - F3 0F10 8D 88000000 - movss xmm1,[rbp+00000088]
;Prey.AK::Monitor::PostCode+24A3BE - 48 8D 4F 1C - lea rcx,[rdi+1C]
;Prey.AK::Monitor::PostCode+24A3C2 - E8 79410000 - call Prey.AK::Monitor::PostCode+24E540 << CONTINUE HERE
cmp byte ptr [g_cameraEnabled], 1 ; check if the user enabled the camera. If so, just skip the write statements, otherwise just execute the original code.
je noWrite ; our own camera is enabled, just skip the writes
movss dword ptr [rdi+24h],xmm14
noWrite:
movss xmm1, dword ptr [rbp+00000088h]
lea rcx,[rdi+1Ch]
exit:
jmp qword ptr [_cameraWrite3InterceptionContinue] ; jmp back into the original game code, which is the location after the original statements above.
cameraWrite3Interceptor ENDP
timestopInterceptor PROC
; start of function which contains timestop read. Contains CryAction instance (with m_pause) in rcx
;Prey.exe+5D6AD0 - 48 89 5C 24 10 - mov [rsp+10],rbx <<< INTERCEPT HERE
;Prey.exe+5D6AD5 - 48 89 6C 24 18 - mov [rsp+18],rbp
;Prey.exe+5D6ADA - 48 89 74 24 20 - mov [rsp+20],rsi
;Prey.exe+5D6ADF - 57 - push rdi <<< CONTINUE HERE
;Prey.exe+5D6AE0 - 41 54 - push r12
;Prey.exe+5D6AE2 - 41 55 - push r13
;Prey.exe+5D6AE4 - 41 56 - push r14
;Prey.exe+5D6AE6 - 41 57 - push r15
;...
;Prey.exe+5D6C99 - 74 09 - je Prey.exe+5D6CA4
;Prey.exe+5D6C9B - 44 38 6B 08 - cmp [rbx+08],r13l <<< TImestop read
;Prey.exe+5D6C9F - 75 03 - jne Prey.exe+5D6CA4
;Prey.exe+5D6CA1 - 45 8B FD - mov r15d,r13d
;
mov [g_timestopStructAddress], rcx
originalCode:
mov [rsp+10h],rbx
mov [rsp+18h],rbp
mov [rsp+20h],rsi
exit:
jmp qword ptr [_timestopInterceptionContinue] ; jmp back into the original game code, which is the location after the original statements above.
timestopInterceptor ENDP
fovReadInterceptor PROC
;Prey.exe+1511CAE - F3 0F10 4B 18 - movss xmm1,[rbx+18]
;Prey.exe+1511CB3 - 48 8B 05 26D9EF00 - mov rax,[Prey.exe+240F5E0] { [2ED22CE0] }
;Prey.exe+1511CBA - F3 0F5C C8 - subss xmm1,xmm0
;Prey.exe+1511CBE - F3 0F10 05 F256AC00 - movss xmm0,[Prey.exe+1FD73B8] { [1.00] }
;Prey.exe+1511CC6 - F3 0F58 48 08 - addss xmm1,[rax+08] << INTERCEPT HERE. FOV Read
;Prey.exe+1511CCB - 0F2F C8 - comiss xmm1,xmm0
;Prey.exe+1511CCE - 76 03 - jna Prey.exe+1511CD3
;Prey.exe+1511CD0 - 0F28 C1 - movaps xmm0,xmm1
;Prey.exe+1511CD3 - 48 83 C4 20 - add rsp,20 { 32 }
;Prey.exe+1511CD7 - 5B - pop rbx << CONTINUE HERE
;Prey.exe+1511CD8 - C3 - ret
mov [g_fovConstructAddress], rax
originalCode:
addss xmm1, dword ptr [rax+08h]
comiss xmm1,xmm0
jna noMove
movaps xmm0,xmm1
noMove:
add rsp, 20h
exit:
jmp qword ptr [_fovReadInterceptionContinue] ; jmp back into the original game code, which is the location after the original statements above.
fovReadInterceptor ENDP
END | FransBouma/InjectableGenericCameraSystem | Cameras/Prey/InjectableGenericCameraSystem/Interceptor.asm | Assembly | bsd-2-clause | 16,373 |
; Generated at 3/12/2016 8:37:32 PM
DebugStub_AsmBreakEIP dd 0
DebugStub_AsmOrigByte dd 0
DebugStub_DoAsmBreak:
Mov ESI, [DebugStub_CallerESP]
Mov EAX, [DebugStub_AsmBreakEIP]
Mov [ESI - 12], EAX
Call DebugStub_ClearAsmBreak
Call DebugStub_Break
DebugStub_DoAsmBreak_Exit:
mov dword [static_field__Cosmos_Core_INTs_mLastKnownAddress], DebugStub_DoAsmBreak_Exit
Ret
DebugStub_SetAsmBreak:
Call DebugStub_ClearAsmBreak
Call DebugStub_ComReadEAX
Mov [DebugStub_AsmBreakEIP], EAX
Mov EDI, EAX
Mov AL, [EDI + 0]
Mov [DebugStub_AsmOrigByte], AL
Mov AL, 0xCC
Mov [EDI + 0], AL
DebugStub_SetAsmBreak_Exit:
mov dword [static_field__Cosmos_Core_INTs_mLastKnownAddress], DebugStub_SetAsmBreak_Exit
Ret
DebugStub_ClearAsmBreak:
Mov EDI, [DebugStub_AsmBreakEIP]
Cmp EDI, 0
JE DebugStub_ClearAsmBreak_Exit
Mov AL, [DebugStub_AsmOrigByte]
Mov [EDI + 0], AL
Mov dword [DebugStub_AsmBreakEIP], 0
DebugStub_ClearAsmBreak_Exit:
mov dword [static_field__Cosmos_Core_INTs_mLastKnownAddress], DebugStub_ClearAsmBreak_Exit
Ret
DebugStub_SetINT1_TrapFLAG:
Push EBP
Push EAX
Mov EBP, [DebugStub_CallerESP]
Sub EBP, 4
Mov EAX, [EBP]
Or EAX, 0x0100
Mov [EBP], EAX
Pop EAX
Pop EBP
DebugStub_SetINT1_TrapFLAG_Exit:
mov dword [static_field__Cosmos_Core_INTs_mLastKnownAddress], DebugStub_SetINT1_TrapFLAG_Exit
Ret
DebugStub_ResetINT1_TrapFLAG:
Push EBP
Push EAX
Mov EBP, [DebugStub_CallerESP]
Sub EBP, 4
Mov EAX, [EBP]
And EAX, 0xFEFF
Mov [EBP], EAX
Pop EAX
Pop EBP
DebugStub_ResetINT1_TrapFLAG_Exit:
mov dword [static_field__Cosmos_Core_INTs_mLastKnownAddress], DebugStub_ResetINT1_TrapFLAG_Exit
Ret
| Cyber4/Cosmos | source/Cosmos.Debug.DebugStub/AsmBreak.asm | Assembly | bsd-3-clause | 1,677 |
section .text
global _start
_start:
mov rbx, rax
mov rbx, r8
mov rbx, r9
mov rbx, r10
mov rbx, r11
mov rbx, r12
mov rbx, r13
mov rbx, r14 | tangentforks/vanar | src/asmcache/lx.asm | Assembly | bsd-3-clause | 138 |
;/****************************************************************************
; *
; * XVID MPEG-4 VIDEO CODEC
; * - MMX and XMM forward discrete cosine transform -
; *
; * Copyright(C) 2002 Pascal Massimino <skal@planet-d.net>
; *
; * This program 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 2 of the License, or
; * (at your option) any later version.
; *
; * This program is distributed in the hope that it will be useful,
; * but WITHOUT ANY WARRANTY; without even the implied warranty of
; * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
; * GNU General Public License for more details.
; *
; * You should have received a copy of the GNU General Public License
; * along with this program; if not, write to the Free Software
; * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
; *
; * $Id: fdct_mmx_skal.asm,v 1.12 2009-09-16 17:07:58 Isibaar Exp $
; *
; ***************************************************************************/
%include "nasm.inc"
;;; Define this if you want an unrolled version of the code
%define UNROLLED_LOOP
;=============================================================================
;
; Vertical pass is an implementation of the scheme:
; Loeffler C., Ligtenberg A., and Moschytz C.S.:
; Practical Fast 1D DCT Algorithm with Eleven Multiplications,
; Proc. ICASSP 1989, 988-991.
;
; Horizontal pass is a double 4x4 vector/matrix multiplication,
; (see also Intel's Application Note 922:
; http://developer.intel.com/vtune/cbts/strmsimd/922down.htm
; Copyright (C) 1999 Intel Corporation)
;
; Notes:
; * tan(3pi/16) is greater than 0.5, and would use the
; sign bit when turned into 16b fixed-point precision. So,
; we use the trick: x*tan3 = x*(tan3-1)+x
;
; * There's only one SSE-specific instruction (pshufw).
; Porting to SSE2 also seems straightforward.
;
; * There's still 1 or 2 ticks to save in fLLM_PASS, but
; I prefer having a readable code, instead of a tightly
; scheduled one...
;
; * Quantization stage (as well as pre-transposition for the
; idct way back) can be included in the fTab* constants
; (with induced loss of precision, somehow)
;
; * Some more details at: http://skal.planet-d.net/coding/dct.html
;
;=============================================================================
;
; idct-like IEEE errors:
;
; =========================
; Peak error: 1.0000
; Peak MSE: 0.0365
; Overall MSE: 0.0201
; Peak ME: 0.0265
; Overall ME: 0.0006
;
; == Mean square errors ==
; 0.000 0.001 0.001 0.002 0.000 0.002 0.001 0.000 [0.001]
; 0.035 0.029 0.032 0.032 0.031 0.032 0.034 0.035 [0.032]
; 0.026 0.028 0.027 0.027 0.025 0.028 0.028 0.025 [0.027]
; 0.037 0.032 0.031 0.030 0.028 0.029 0.026 0.031 [0.030]
; 0.000 0.001 0.001 0.002 0.000 0.002 0.001 0.001 [0.001]
; 0.025 0.024 0.022 0.022 0.022 0.022 0.023 0.023 [0.023]
; 0.026 0.028 0.025 0.028 0.030 0.025 0.026 0.027 [0.027]
; 0.021 0.020 0.020 0.022 0.020 0.022 0.017 0.019 [0.020]
;
; == Abs Mean errors ==
; 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 [0.000]
; 0.020 0.001 0.003 0.003 0.000 0.004 0.002 0.003 [0.002]
; 0.000 0.001 0.001 0.001 0.001 0.004 0.000 0.000 [0.000]
; 0.027 0.001 0.000 0.002 0.002 0.002 0.001 0.000 [0.003]
; 0.000 0.000 0.000 0.000 0.000 0.001 0.000 0.001 [-0.000]
; 0.001 0.003 0.001 0.001 0.002 0.001 0.000 0.000 [-0.000]
; 0.000 0.002 0.002 0.001 0.001 0.002 0.001 0.000 [-0.000]
; 0.000 0.002 0.001 0.002 0.001 0.002 0.001 0.001 [-0.000]
;
;=============================================================================
;=============================================================================
; Read only data
;=============================================================================
DATA
ALIGN SECTION_ALIGN
tan1:
dw 0x32ec,0x32ec,0x32ec,0x32ec ; tan( pi/16)
tan2:
dw 0x6a0a,0x6a0a,0x6a0a,0x6a0a ; tan(2pi/16) (=sqrt(2)-1)
tan3:
dw 0xab0e,0xab0e,0xab0e,0xab0e ; tan(3pi/16)-1
sqrt2:
dw 0x5a82,0x5a82,0x5a82,0x5a82 ; 0.5/sqrt(2)
ALIGN SECTION_ALIGN
fdct_table:
;fTab1:
dw 0x4000, 0x4000, 0x58c5, 0x4b42
dw 0x4000, 0x4000, 0x3249, 0x11a8
dw 0x539f, 0x22a3, 0x4b42, 0xee58
dw 0xdd5d, 0xac61, 0xa73b, 0xcdb7
dw 0x4000, 0xc000, 0x3249, 0xa73b
dw 0xc000, 0x4000, 0x11a8, 0x4b42
dw 0x22a3, 0xac61, 0x11a8, 0xcdb7
dw 0x539f, 0xdd5d, 0x4b42, 0xa73b
;fTab2:
dw 0x58c5, 0x58c5, 0x7b21, 0x6862
dw 0x58c5, 0x58c5, 0x45bf, 0x187e
dw 0x73fc, 0x300b, 0x6862, 0xe782
dw 0xcff5, 0x8c04, 0x84df, 0xba41
dw 0x58c5, 0xa73b, 0x45bf, 0x84df
dw 0xa73b, 0x58c5, 0x187e, 0x6862
dw 0x300b, 0x8c04, 0x187e, 0xba41
dw 0x73fc, 0xcff5, 0x6862, 0x84df
;fTab3:
dw 0x539f, 0x539f, 0x73fc, 0x6254
dw 0x539f, 0x539f, 0x41b3, 0x1712
dw 0x6d41, 0x2d41, 0x6254, 0xe8ee
dw 0xd2bf, 0x92bf, 0x8c04, 0xbe4d
dw 0x539f, 0xac61, 0x41b3, 0x8c04
dw 0xac61, 0x539f, 0x1712, 0x6254
dw 0x2d41, 0x92bf, 0x1712, 0xbe4d
dw 0x6d41, 0xd2bf, 0x6254, 0x8c04
;fTab4:
dw 0x4b42, 0x4b42, 0x6862, 0x587e
dw 0x4b42, 0x4b42, 0x3b21, 0x14c3
dw 0x6254, 0x28ba, 0x587e, 0xeb3d
dw 0xd746, 0x9dac, 0x979e, 0xc4df
dw 0x4b42, 0xb4be, 0x3b21, 0x979e
dw 0xb4be, 0x4b42, 0x14c3, 0x587e
dw 0x28ba, 0x9dac, 0x14c3, 0xc4df
dw 0x6254, 0xd746, 0x587e, 0x979e
;fTab1:
dw 0x4000, 0x4000, 0x58c5, 0x4b42
dw 0x4000, 0x4000, 0x3249, 0x11a8
dw 0x539f, 0x22a3, 0x4b42, 0xee58
dw 0xdd5d, 0xac61, 0xa73b, 0xcdb7
dw 0x4000, 0xc000, 0x3249, 0xa73b
dw 0xc000, 0x4000, 0x11a8, 0x4b42
dw 0x22a3, 0xac61, 0x11a8, 0xcdb7
dw 0x539f, 0xdd5d, 0x4b42, 0xa73b
;fTab4:
dw 0x4b42, 0x4b42, 0x6862, 0x587e
dw 0x4b42, 0x4b42, 0x3b21, 0x14c3
dw 0x6254, 0x28ba, 0x587e, 0xeb3d
dw 0xd746, 0x9dac, 0x979e, 0xc4df
dw 0x4b42, 0xb4be, 0x3b21, 0x979e
dw 0xb4be, 0x4b42, 0x14c3, 0x587e
dw 0x28ba, 0x9dac, 0x14c3, 0xc4df
dw 0x6254, 0xd746, 0x587e, 0x979e
;fTab3:
dw 0x539f, 0x539f, 0x73fc, 0x6254
dw 0x539f, 0x539f, 0x41b3, 0x1712
dw 0x6d41, 0x2d41, 0x6254, 0xe8ee
dw 0xd2bf, 0x92bf, 0x8c04, 0xbe4d
dw 0x539f, 0xac61, 0x41b3, 0x8c04
dw 0xac61, 0x539f, 0x1712, 0x6254
dw 0x2d41, 0x92bf, 0x1712, 0xbe4d
dw 0x6d41, 0xd2bf, 0x6254, 0x8c04
;fTab2:
dw 0x58c5, 0x58c5, 0x7b21, 0x6862
dw 0x58c5, 0x58c5, 0x45bf, 0x187e
dw 0x73fc, 0x300b, 0x6862, 0xe782
dw 0xcff5, 0x8c04, 0x84df, 0xba41
dw 0x58c5, 0xa73b, 0x45bf, 0x84df
dw 0xa73b, 0x58c5, 0x187e, 0x6862
dw 0x300b, 0x8c04, 0x187e, 0xba41
dw 0x73fc, 0xcff5, 0x6862, 0x84df
ALIGN SECTION_ALIGN
fdct_rounding_1:
dw 6, 8, 8, 8
dw 10, 8, 8, 8
dw 8, 8, 8, 8
dw 8, 8, 8, 8
dw 6, 8, 8, 8
dw 8, 8, 8, 8
dw 8, 8, 8, 8
dw 8, 8, 8, 8
ALIGN SECTION_ALIGN
fdct_rounding_2:
dw 6, 8, 8, 8
dw 8, 8, 8, 8
dw 8, 8, 8, 8
dw 8, 8, 8, 8
dw 6, 8, 8, 8
dw 8, 8, 8, 8
dw 8, 8, 8, 8
dw 8, 8, 8, 8
ALIGN SECTION_ALIGN
MMX_One:
dw 1, 1, 1, 1
;=============================================================================
; Helper Macros for real code
;=============================================================================
;-----------------------------------------------------------------------------
; FDCT LLM vertical pass (~39c)
; %1=dst, %2=src, %3:Shift
;-----------------------------------------------------------------------------
%macro fLLM_PASS 3
movq mm0, [%2+0*16] ; In0
movq mm2, [%2+2*16] ; In2
movq mm3, mm0
movq mm4, mm2
movq mm7, [%2+7*16] ; In7
movq mm5, [%2+5*16] ; In5
psubsw mm0, mm7 ; t7 = In0-In7
paddsw mm7, mm3 ; t0 = In0+In7
psubsw mm2, mm5 ; t5 = In2-In5
paddsw mm5, mm4 ; t2 = In2+In5
movq mm3, [%2+3*16] ; In3
movq mm4, [%2+4*16] ; In4
movq mm1, mm3
psubsw mm3, mm4 ; t4 = In3-In4
paddsw mm4, mm1 ; t3 = In3+In4
movq mm6, [%2+6*16] ; In6
movq mm1, [%2+1*16] ; In1
psubsw mm1, mm6 ; t6 = In1-In6
paddsw mm6, [%2+1*16] ; t1 = In1+In6
psubsw mm7, mm4 ; tm03 = t0-t3
psubsw mm6, mm5 ; tm12 = t1-t2
paddsw mm4, mm4 ; 2.t3
paddsw mm5, mm5 ; 2.t2
paddsw mm4, mm7 ; tp03 = t0+t3
paddsw mm5, mm6 ; tp12 = t1+t2
psllw mm2, %3+1 ; shift t5 (shift +1 to..
psllw mm1, %3+1 ; shift t6 ..compensate cos4/2)
psllw mm4, %3 ; shift t3
psllw mm5, %3 ; shift t2
psllw mm7, %3 ; shift t0
psllw mm6, %3 ; shift t1
psllw mm3, %3 ; shift t4
psllw mm0, %3 ; shift t7
psubsw mm4, mm5 ; out4 = tp03-tp12
psubsw mm1, mm2 ; mm1: t6-t5
paddsw mm5, mm5
paddsw mm2, mm2
paddsw mm5, mm4 ; out0 = tp03+tp12
movq [%1+4*16], mm4 ; => out4
paddsw mm2, mm1 ; mm2: t6+t5
movq [%1+0*16], mm5 ; => out0
movq mm4, [tan2] ; mm4 <= tan2
pmulhw mm4, mm7 ; tm03*tan2
movq mm5, [tan2] ; mm5 <= tan2
psubsw mm4, mm6 ; out6 = tm03*tan2 - tm12
pmulhw mm5, mm6 ; tm12*tan2
paddsw mm5, mm7 ; out2 = tm12*tan2 + tm03
movq mm6, [sqrt2]
movq mm7, [MMX_One]
pmulhw mm2, mm6 ; mm2: tp65 = (t6 + t5)*cos4
por mm5, mm7 ; correct out2
por mm4, mm7 ; correct out6
pmulhw mm1, mm6 ; mm1: tm65 = (t6 - t5)*cos4
por mm2, mm7 ; correct tp65
movq [%1+2*16], mm5 ; => out2
movq mm5, mm3 ; save t4
movq [%1+6*16], mm4 ; => out6
movq mm4, mm0 ; save t7
psubsw mm3, mm1 ; mm3: tm465 = t4 - tm65
psubsw mm0, mm2 ; mm0: tm765 = t7 - tp65
paddsw mm2, mm4 ; mm2: tp765 = t7 + tp65
paddsw mm1, mm5 ; mm1: tp465 = t4 + tm65
movq mm4, [tan3] ; tan3 - 1
movq mm5, [tan1] ; tan1
movq mm7, mm3 ; save tm465
pmulhw mm3, mm4 ; tm465*(tan3-1)
movq mm6, mm1 ; save tp465
pmulhw mm1, mm5 ; tp465*tan1
paddsw mm3, mm7 ; tm465*tan3
pmulhw mm4, mm0 ; tm765*(tan3-1)
paddsw mm4, mm0 ; tm765*tan3
pmulhw mm5, mm2 ; tp765*tan1
paddsw mm1, mm2 ; out1 = tp765 + tp465*tan1
psubsw mm0, mm3 ; out3 = tm765 - tm465*tan3
paddsw mm7, mm4 ; out5 = tm465 + tm765*tan3
psubsw mm5, mm6 ; out7 =-tp465 + tp765*tan1
movq [%1+1*16], mm1 ; => out1
movq [%1+3*16], mm0 ; => out3
movq [%1+5*16], mm7 ; => out5
movq [%1+7*16], mm5 ; => out7
%endmacro
;-----------------------------------------------------------------------------
; fMTX_MULT_XMM (~20c)
; %1=dst, %2=src, %3 = Coeffs, %4/%5=rounders
;-----------------------------------------------------------------------------
%macro fMTX_MULT_XMM 5
movq mm0, [%2 + 0] ; mm0 = [0123]
; the 'pshufw' below is the only SSE instruction.
; For MMX-only version, it should be emulated with
; some 'punpck' soup...
pshufw mm1, [%2 + 8], 00011011b ; mm1 = [7654]
movq mm7, mm0
paddsw mm0, mm1 ; mm0 = [a0 a1 a2 a3]
psubsw mm7, mm1 ; mm7 = [b0 b1 b2 b3]
movq mm1, mm0
punpckldq mm0, mm7 ; mm0 = [a0 a1 b0 b1]
punpckhdq mm1, mm7 ; mm1 = [b2 b3 a2 a3]
movq mm2, qword [%3 + 0] ; [ M00 M01 M16 M17]
movq mm3, qword [%3 + 8] ; [ M02 M03 M18 M19]
pmaddwd mm2, mm0 ; [a0.M00+a1.M01 | b0.M16+b1.M17]
movq mm4, qword [%3 + 16] ; [ M04 M05 M20 M21]
pmaddwd mm3, mm1 ; [a2.M02+a3.M03 | b2.M18+b3.M19]
movq mm5, qword [%3 + 24] ; [ M06 M07 M22 M23]
pmaddwd mm4, mm0 ; [a0.M04+a1.M05 | b0.M20+b1.M21]
movq mm6, qword [%3 + 32] ; [ M08 M09 M24 M25]
pmaddwd mm5, mm1 ; [a2.M06+a3.M07 | b2.M22+b3.M23]
movq mm7, qword [%3 + 40] ; [ M10 M11 M26 M27]
pmaddwd mm6, mm0 ; [a0.M08+a1.M09 | b0.M24+b1.M25]
paddd mm2, mm3 ; [ out0 | out1 ]
pmaddwd mm7, mm1 ; [a0.M10+a1.M11 | b0.M26+b1.M27]
psrad mm2, 16
pmaddwd mm0, [%3 + 48] ; [a0.M12+a1.M13 | b0.M28+b1.M29]
paddd mm4, mm5 ; [ out2 | out3 ]
pmaddwd mm1, [%3 + 56] ; [a0.M14+a1.M15 | b0.M30+b1.M31]
psrad mm4, 16
paddd mm6, mm7 ; [ out4 | out5 ]
psrad mm6, 16
paddd mm0, mm1 ; [ out6 | out7 ]
psrad mm0, 16
packssdw mm2, mm4 ; [ out0|out1|out2|out3 ]
paddsw mm2, [%4] ; Round
packssdw mm6, mm0 ; [ out4|out5|out6|out7 ]
paddsw mm6, [%5] ; Round
psraw mm2, 4 ; => [-2048, 2047]
psraw mm6, 4
movq [%1 + 0], mm2
movq [%1 + 8], mm6
%endmacro
;-----------------------------------------------------------------------------
; fMTX_MULT_MMX (~22c)
; %1=dst, %2=src, %3 = Coeffs, %4/%5=rounders
;-----------------------------------------------------------------------------
%macro fMTX_MULT_MMX 5
; MMX-only version (no 'pshufw'. ~10% overall slower than SSE)
movd mm1, [%2 + 8 + 4] ; [67..]
movq mm0, [%2 + 0] ; mm0 = [0123]
movq mm7, mm0
punpcklwd mm1, [%2 + 8] ; [6475]
movq mm2, mm1
psrlq mm1, 32 ; [75..]
punpcklwd mm1,mm2 ; [7654]
paddsw mm0, mm1 ; mm0 = [a0 a1 a2 a3]
psubsw mm7, mm1 ; mm7 = [b0 b1 b2 b3]
movq mm1, mm0
punpckldq mm0, mm7 ; mm0 = [a0 a1 b0 b1]
punpckhdq mm1, mm7 ; mm1 = [b2 b3 a2 a3]
movq mm2, qword [%3 + 0] ; [ M00 M01 M16 M17]
movq mm3, qword [%3 + 8] ; [ M02 M03 M18 M19]
pmaddwd mm2, mm0 ; [a0.M00+a1.M01 | b0.M16+b1.M17]
movq mm4, qword [%3 + 16] ; [ M04 M05 M20 M21]
pmaddwd mm3, mm1 ; [a2.M02+a3.M03 | b2.M18+b3.M19]
movq mm5, qword [%3 + 24] ; [ M06 M07 M22 M23]
pmaddwd mm4, mm0 ; [a0.M04+a1.M05 | b0.M20+b1.M21]
movq mm6, qword [%3 + 32] ; [ M08 M09 M24 M25]
pmaddwd mm5, mm1 ; [a2.M06+a3.M07 | b2.M22+b3.M23]
movq mm7, qword [%3 + 40] ; [ M10 M11 M26 M27]
pmaddwd mm6, mm0 ; [a0.M08+a1.M09 | b0.M24+b1.M25]
paddd mm2, mm3 ; [ out0 | out1 ]
pmaddwd mm7, mm1 ; [a0.M10+a1.M11 | b0.M26+b1.M27]
psrad mm2, 16
pmaddwd mm0, [%3 + 48] ; [a0.M12+a1.M13 | b0.M28+b1.M29]
paddd mm4, mm5 ; [ out2 | out3 ]
pmaddwd mm1, [%3 + 56] ; [a0.M14+a1.M15 | b0.M30+b1.M31]
psrad mm4, 16
paddd mm6, mm7 ; [ out4 | out5 ]
psrad mm6, 16
paddd mm0, mm1 ; [ out6 | out7 ]
psrad mm0, 16
packssdw mm2, mm4 ; [ out0|out1|out2|out3 ]
paddsw mm2, [%4] ; Round
packssdw mm6, mm0 ; [ out4|out5|out6|out7 ]
paddsw mm6, [%5] ; Round
psraw mm2, 4 ; => [-2048, 2047]
psraw mm6, 4
movq [%1 + 0], mm2
movq [%1 + 8], mm6
%endmacro
;-----------------------------------------------------------------------------
; MAKE_FDCT_FUNC
; %1 funcname, %2 macro for row dct
;-----------------------------------------------------------------------------
%macro MAKE_FDCT_FUNC 2
ALIGN SECTION_ALIGN
cglobal %1
%1:
mov TMP0, prm1
%ifndef UNROLLED_LOOP
push _EBX
push _EDI
%endif
fLLM_PASS TMP0+0, TMP0+0, 3
fLLM_PASS TMP0+8, TMP0+8, 3
%ifdef UNROLLED_LOOP
%assign i 0
%rep 8
%2 TMP0+i*16, TMP0+i*16, fdct_table+i*64, fdct_rounding_1+i*8, fdct_rounding_2+i*8
%assign i i+1
%endrep
%else
mov _EAX, 8
mov TMP1, fdct_table
mov _EBX, fdct_rounding_1
mov _EDI, fdct_rounding_2
.loop
%2 TMP0, TMP0, TMP1, _EBX, _EDI
add TMP0, 2*8
add TMP1, 2*32
add _EBX, 2*4
add _EDI, 2*4
dec _EAX
jne .loop
pop _EDI
pop _EBX
%endif
ret
ENDFUNC
%endmacro
;=============================================================================
; Code
;=============================================================================
TEXT
;-----------------------------------------------------------------------------
; void fdct_mmx_skal(int16_t block[64]];
;-----------------------------------------------------------------------------
MAKE_FDCT_FUNC fdct_mmx_skal, fMTX_MULT_MMX
;-----------------------------------------------------------------------------
; void fdct_xmm_skal(int16_t block[64]];
;-----------------------------------------------------------------------------
MAKE_FDCT_FUNC fdct_xmm_skal, fMTX_MULT_XMM
NON_EXEC_STACK
| ninetian/ffmpeginstaller | xvidcore/src/dct/x86_asm/fdct_mmx_skal.asm | Assembly | apache-2.0 | 16,430 |
.686p
.model flat, stdcall
option casemap: none
.code
tes PROC t: Ptr BYTE
LOCAL n: Ptr BYTE
mov eax, t
mov n, eax
ret
tes ENDP
END
| mmoeller86/jsonx64 | test.asm | Assembly | mit | 145 |
list p=p12f1840
include <p12f1840.inc>
__CONFIG _CONFIG1, _FOSC_INTOSC & _MCLRE_OFF & _WDTE_OFF
__CONFIG _CONFIG2, _LVP_OFF
org 0
;;; Set internal oscillator to 32 MHz
movlw 0xF0 ; store OSCCON value (=1111 0000=) in W
movlb 0x01 ; Select page bank 1
movwf 0x19 ; move value of W to register at OSCCON (address 0x19)
;;; Define pin 5 (RA2) as output
BANKSEL PORTA ; select bank 0 (PORTA)
CLRF PORTA ; clear PORTA
BANKSEL LATA ; select bank 2 (LATA)
CLRF LATA ; clear LATA
BANKSEL ANSELA ; select bank 3 (ANSELA)
CLRF ANSELA ; clear ANSELA
BANKSEL TRISA ; select bank 1 (TRISA)
BCF TRISA, 2 ; define RA2 as an output port (clear TRISA bit 2)
BANKSEL T2CON
CLRF T2CON ; Timer2 off, prescale 1:1, postscaler not used in PWM
MOVLW 0x09
MOVWF PR2 ; Set PWM period to 1.25us
BANKSEL CCPR1L
MOVLW 0x05
MOVWF CCPR1L ; Set PWM duty cycle to 50%
CLRF CCP1CON
MOVLW 0x0C
MOVWF CCP1CON ; Set up for PWM on pin 5
BANKSEL T2CON
BSF T2CON, 2 ; Timer2 on
BANKSEL CCPR1L
; hack - write a slightly different 24bit value 16 different times, pause,
; redo from start
CONSTANT PIXEL=0x2F0
CONSTANT RED=0x2F1
CONSTANT BLUE=0x2F2
CONSTANT GREEN=0x2F3
movlw 0x00
movwf RED
movwf BLUE
movwf GREEN
PixelLoopSetup
BANKSEL CCPR1L
movlw 0x0F
movwf PIXEL
PixelLoop
BANKSEL CCPR1L
decfsz PIXEL,1
bra $+2
goto Latch
; send bits
BANKSEL CCPR1L
btfsc GREEN,7
CALL SendOne
BANKSEL CCPR1L
btfss GREEN,7
CALL SendZero
BANKSEL CCPR1L
btfsc GREEN,6
CALL SendOne
BANKSEL CCPR1L
btfss GREEN,6
CALL SendZero
BANKSEL CCPR1L
btfsc GREEN,5
CALL SendOne
BANKSEL CCPR1L
btfss GREEN,5
CALL SendZero
BANKSEL CCPR1L
btfsc GREEN,4
CALL SendOne
BANKSEL CCPR1L
btfss GREEN,4
CALL SendZero
BANKSEL CCPR1L
btfsc GREEN,3
CALL SendOne
BANKSEL CCPR1L
btfss GREEN,3
CALL SendZero
BANKSEL CCPR1L
btfsc GREEN,2
CALL SendOne
BANKSEL CCPR1L
btfss GREEN,2
CALL SendZero
BANKSEL CCPR1L
btfsc GREEN,1
CALL SendOne
BANKSEL CCPR1L
btfss GREEN,1
CALL SendZero
BANKSEL CCPR1L
btfsc GREEN,0
CALL SendOne
BANKSEL CCPR1L
btfss GREEN,0
CALL SendZero
BANKSEL CCPR1L
btfsc RED,7
CALL SendOne
BANKSEL CCPR1L
btfss RED,7
CALL SendZero
BANKSEL CCPR1L
btfsc RED,6
CALL SendOne
BANKSEL CCPR1L
btfss RED,6
CALL SendZero
BANKSEL CCPR1L
btfsc RED,5
CALL SendOne
BANKSEL CCPR1L
btfss RED,5
CALL SendZero
BANKSEL CCPR1L
btfsc RED,4
CALL SendOne
BANKSEL CCPR1L
btfss RED,4
CALL SendZero
BANKSEL CCPR1L
btfsc RED,3
CALL SendOne
BANKSEL CCPR1L
btfss RED,3
CALL SendZero
BANKSEL CCPR1L
btfsc RED,2
CALL SendOne
BANKSEL CCPR1L
btfss RED,2
CALL SendZero
BANKSEL CCPR1L
btfsc RED,1
CALL SendOne
BANKSEL CCPR1L
btfss RED,1
CALL SendZero
BANKSEL CCPR1L
btfsc RED,0
CALL SendOne
BANKSEL CCPR1L
btfss RED,0
CALL SendZero
BANKSEL CCPR1L
btfsc BLUE,7
CALL SendOne
BANKSEL CCPR1L
btfss BLUE,7
CALL SendZero
BANKSEL CCPR1L
btfsc BLUE,6
CALL SendOne
BANKSEL CCPR1L
btfss BLUE,6
CALL SendZero
BANKSEL CCPR1L
btfsc BLUE,5
CALL SendOne
BANKSEL CCPR1L
btfss BLUE,5
CALL SendZero
BANKSEL CCPR1L
btfsc BLUE,4
CALL SendOne
BANKSEL CCPR1L
btfss BLUE,4
CALL SendZero
BANKSEL CCPR1L
btfsc BLUE,3
CALL SendOne
BANKSEL CCPR1L
btfss BLUE,3
CALL SendZero
BANKSEL CCPR1L
btfsc BLUE,2
CALL SendOne
BANKSEL CCPR1L
btfss BLUE,2
CALL SendZero
BANKSEL CCPR1L
btfsc BLUE,1
CALL SendOne
BANKSEL CCPR1L
btfss BLUE,1
CALL SendZero
BANKSEL CCPR1L
btfsc BLUE,0
CALL SendOne
BANKSEL CCPR1L
btfss BLUE,0
CALL SendZero
BANKSEL CCPR1L
incf RED,1
btfsc RED,5
clrf RED
incf GREEN,1
btfsc GREEN,5
clrf GREEN
incf BLUE,1
btfsc BLUE,5
clrf BLUE
goto PixelLoop
SendOne
BANKSEL CCPR1L
MOVLW 0x08
MOVWF CCPR1L
BCF CCP1CON, 4
BCF CCP1CON, 5
BANKSEL PIR1
BTFSS PIR1,1
BRA $-1
RETURN
SendZero
BANKSEL CCPR1L
MOVLW 0x02
MOVWF CCPR1L
BSF CCP1CON, 4
BSF CCP1CON, 5
BANKSEL PIR1
BTFSS PIR1,1
BRA $-1
RETURN
Latch
; Set to 100% low
BANKSEL CCPR1L
MOVLW 0x00
MOVWF CCPR1L
BCF CCP1CON,4
BCF CCP1CON,5
Delay
; Delay for 15us / 1/2sec
movlw 0x20
movwf 0x2F5
movlw 0xC7 ; 0xC7 = 199
movwf 0x2F6 ; set 0x30 to 199
movwf 0x2F7 ; set 0x31 to 199
decfsz 0x2F7, 1 ; decrement 0x30
bra $-1 ; if 0x31 != 0 go back 1 instruction
decfsz 0x2F6, 1 ; decrement 0x31
bra $-4 ; if 0x30 != 0 go back 4 instruction
decfsz 0x2F5, 1
bra $-7
goto PixelLoopSetup
END
| mdennehy/PIC12F | lightchaser/lightchaser.asm | Assembly | mit | 4,660 |
;Este es un comentario, se le antecede un punto y coma
list p=18f4550 ;Modelo del microcontrolador
#include <p18f4550.inc> ;Llamada a la librería de nombre de los registros
;Directivas de preprocesador o bits de configuración
CONFIG PLLDIV = 1 ; PLL Prescaler Selection bits (No prescale (4 MHz oscillator input drives PLL directly))
CONFIG CPUDIV = OSC1_PLL2 ; System Clock Postscaler Selection bits ([Primary Oscillator Src: /1][96 MHz PLL Src: /2])
CONFIG FOSC = XT_XT ; Oscillator Selection bits (XT oscillator (XT))
CONFIG PWRT = ON ; Power-up Timer Enable bit (PWRT enabled)
CONFIG BOR = OFF ; Brown-out Reset Enable bits (Brown-out Reset disabled in hardware and software)
CONFIG WDT = OFF ; Watchdog Timer Enable bit (WDT disabled (control is placed on the SWDTEN bit))
CONFIG CCP2MX = ON ; CCP2 MUX bit (CCP2 input/output is multiplexed with RC1)
CONFIG PBADEN = OFF ; PORTB A/D Enable bit (PORTB<4:0> pins are configured as digital I/O on Reset)
CONFIG MCLRE = ON ; MCLR Pin Enable bit (MCLR pin enabled; RE3 input pin disabled)
CONFIG LVP = OFF ; Single-Supply ICSP Enable bit (Single-Supply ICSP disabled)
org 0x0000
goto init_conf
org 0x0008
goto TMR1_ISR
;Aquí se pueden declarar las constantes en la memoria de programa
org 0x0020
init_conf:
bcf TRISD, 0 ;RD0 como salida
movlw 0x07
movwf T1CON ;TMR1 en modo RTC
movlw 0xC0
movwf INTCON ;GIE=1 PEIE=1
bsf PIE1, TMR1IE ;TMR1IE=1
loop:
nop
goto loop
TMR1_ISR:
movlw 0xE0
movwf TMR1H
clrf TMR1L ;Tengo 5us de tiempo ejecutado luego de producirse la INT
btg LATD, 0
bcf PIR1, TMR1IF ;Bajamos la bandera de desborde del TMR1
retfie
end | tocache/picomones | UPC Microcontroladores 2020-2/Semana 06/20202_rtc_led_500ms.X/maincode.asm | Assembly | cc0-1.0 | 1,869 |
PLC_2A0498: dc.w Frame_2A04FC-PLC_2A0498 ; ...
dc.w Frame_2A04FE-PLC_2A0498
dc.w Frame_2A0502-PLC_2A0498
dc.w Frame_2A0506-PLC_2A0498
dc.w Frame_2A050A-PLC_2A0498
dc.w Frame_2A050E-PLC_2A0498
dc.w Frame_2A0512-PLC_2A0498
dc.w Frame_2A0516-PLC_2A0498
dc.w Frame_2A051A-PLC_2A0498
dc.w Frame_2A051E-PLC_2A0498
dc.w Frame_2A0522-PLC_2A0498
dc.w Frame_2A0526-PLC_2A0498
dc.w Frame_2A052A-PLC_2A0498
dc.w Frame_2A052E-PLC_2A0498
dc.w Frame_2A0532-PLC_2A0498
dc.w Frame_2A0536-PLC_2A0498
dc.w Frame_2A053A-PLC_2A0498
dc.w Frame_2A053E-PLC_2A0498
dc.w Frame_2A0542-PLC_2A0498
dc.w Frame_2A0546-PLC_2A0498
dc.w Frame_2A054A-PLC_2A0498
dc.w Frame_2A054E-PLC_2A0498
dc.w Frame_2A0552-PLC_2A0498
dc.w Frame_2A0556-PLC_2A0498
dc.w Frame_2A055A-PLC_2A0498
dc.w Frame_2A055E-PLC_2A0498
dc.w Frame_2A0562-PLC_2A0498
dc.w Frame_2A0566-PLC_2A0498
dc.w Frame_2A056A-PLC_2A0498
dc.w Frame_2A056E-PLC_2A0498
dc.w Frame_2A0572-PLC_2A0498
dc.w Frame_2A0576-PLC_2A0498
dc.w Frame_2A057A-PLC_2A0498
dc.w Frame_2A057E-PLC_2A0498
dc.w Frame_2A0582-PLC_2A0498
dc.w Frame_2A0586-PLC_2A0498
dc.w Frame_2A058A-PLC_2A0498
dc.w Frame_2A058E-PLC_2A0498
dc.w Frame_2A0592-PLC_2A0498
dc.w Frame_2A0596-PLC_2A0498
dc.w Frame_2A059A-PLC_2A0498
dc.w Frame_2A059E-PLC_2A0498
dc.w Frame_2A05A2-PLC_2A0498
dc.w Frame_2A05A6-PLC_2A0498
dc.w Frame_2A05AA-PLC_2A0498
dc.w Frame_2A05AE-PLC_2A0498
dc.w Frame_2A05B2-PLC_2A0498
dc.w Frame_2A05B6-PLC_2A0498
dc.w Frame_2A05BA-PLC_2A0498
dc.w Frame_2A05BE-PLC_2A0498
Frame_2A04FC: dc.w 0
Frame_2A04FE: dc.w 1
dc.w $8000
Frame_2A0502: dc.w 1
dc.w $8009
Frame_2A0506: dc.w 1
dc.w $8012
Frame_2A050A: dc.w 1
dc.w $801B
Frame_2A050E: dc.w 1
dc.w $8024
Frame_2A0512: dc.w 1
dc.w $802D
Frame_2A0516: dc.w 1
dc.w $8036
Frame_2A051A: dc.w 1
dc.w $803F
Frame_2A051E: dc.w 1
dc.w $8048
Frame_2A0522: dc.w 1
dc.w $8051
Frame_2A0526: dc.w 1
dc.w $805A
Frame_2A052A: dc.w 1
dc.w $8063
Frame_2A052E: dc.w 1
dc.w $806C
Frame_2A0532: dc.w 1
dc.w $8075
Frame_2A0536: dc.w 1
dc.w $807E
Frame_2A053A: dc.w 1
dc.w $8087
Frame_2A053E: dc.w 1
dc.w $8090
Frame_2A0542: dc.w 1
dc.w $8099
Frame_2A0546: dc.w 1
dc.w $80A2
Frame_2A054A: dc.w 1
dc.w $80AB
Frame_2A054E: dc.w 1
dc.w $80B4
Frame_2A0552: dc.w 1
dc.w $80BD
Frame_2A0556: dc.w 1
dc.w $80C6
Frame_2A055A: dc.w 1
dc.w $80CF
Frame_2A055E: dc.w 1
dc.w $80D8
Frame_2A0562: dc.w 1
dc.w $80E1
Frame_2A0566: dc.w 1
dc.w $50EA
Frame_2A056A: dc.w 1
dc.w $50F0
Frame_2A056E: dc.w 1
dc.w $50F6
Frame_2A0572: dc.w 1
dc.w $50FC
Frame_2A0576: dc.w 1
dc.w $8102
Frame_2A057A: dc.w 1
dc.w $810B
Frame_2A057E: dc.w 1
dc.w $8114
Frame_2A0582: dc.w 1
dc.w $B11D
Frame_2A0586: dc.w 1
dc.w $5129
Frame_2A058A: dc.w 1
dc.w $512F
Frame_2A058E: dc.w 1
dc.w $8135
Frame_2A0592: dc.w 1
dc.w $813E
Frame_2A0596: dc.w 1
dc.w $8147
Frame_2A059A: dc.w 1
dc.w $8150
Frame_2A059E: dc.w 1
dc.w $8159
Frame_2A05A2: dc.w 1
dc.w $8162
Frame_2A05A6: dc.w 1
dc.w $31A0
Frame_2A05AA: dc.w 1
dc.w $816B
Frame_2A05AE: dc.w 1
dc.w $8174
Frame_2A05B2: dc.w 1
dc.w $817D
Frame_2A05B6: dc.w 1
dc.w $7186
Frame_2A05BA: dc.w 1
dc.w $518E
Frame_2A05BE: dc.w 1
dc.w $B194
ArtUnc_SurfboardIntro:dc.w 0 ; ...
| TeamASM-Blur/Sonic-3-Blue-Balls-Edition | Working Disassembly/General/Sprites/Knuckles/DPLC - Knuckles 2P.asm | Assembly | apache-2.0 | 3,289 |
default rel
%define XMMWORD
%define YMMWORD
%define ZMMWORD
section .text code align=64
ALIGN 32
_aesni_ctr32_ghash_6x:
vmovdqu xmm2,XMMWORD[32+r11]
sub rdx,6
vpxor xmm4,xmm4,xmm4
vmovdqu xmm15,XMMWORD[((0-128))+rcx]
vpaddb xmm10,xmm1,xmm2
vpaddb xmm11,xmm10,xmm2
vpaddb xmm12,xmm11,xmm2
vpaddb xmm13,xmm12,xmm2
vpaddb xmm14,xmm13,xmm2
vpxor xmm9,xmm1,xmm15
vmovdqu XMMWORD[(16+8)+rsp],xmm4
jmp NEAR $L$oop6x
ALIGN 32
$L$oop6x:
add ebx,100663296
jc NEAR $L$handle_ctr32
vmovdqu xmm3,XMMWORD[((0-32))+r9]
vpaddb xmm1,xmm14,xmm2
vpxor xmm10,xmm10,xmm15
vpxor xmm11,xmm11,xmm15
$L$resume_ctr32:
vmovdqu XMMWORD[r8],xmm1
vpclmulqdq xmm5,xmm7,xmm3,0x10
vpxor xmm12,xmm12,xmm15
vmovups xmm2,XMMWORD[((16-128))+rcx]
vpclmulqdq xmm6,xmm7,xmm3,0x01
xor r12,r12
cmp r15,r14
vaesenc xmm9,xmm9,xmm2
vmovdqu xmm0,XMMWORD[((48+8))+rsp]
vpxor xmm13,xmm13,xmm15
vpclmulqdq xmm1,xmm7,xmm3,0x00
vaesenc xmm10,xmm10,xmm2
vpxor xmm14,xmm14,xmm15
setnc r12b
vpclmulqdq xmm7,xmm7,xmm3,0x11
vaesenc xmm11,xmm11,xmm2
vmovdqu xmm3,XMMWORD[((16-32))+r9]
neg r12
vaesenc xmm12,xmm12,xmm2
vpxor xmm6,xmm6,xmm5
vpclmulqdq xmm5,xmm0,xmm3,0x00
vpxor xmm8,xmm8,xmm4
vaesenc xmm13,xmm13,xmm2
vpxor xmm4,xmm1,xmm5
and r12,0x60
vmovups xmm15,XMMWORD[((32-128))+rcx]
vpclmulqdq xmm1,xmm0,xmm3,0x10
vaesenc xmm14,xmm14,xmm2
vpclmulqdq xmm2,xmm0,xmm3,0x01
lea r14,[r12*1+r14]
vaesenc xmm9,xmm9,xmm15
vpxor xmm8,xmm8,XMMWORD[((16+8))+rsp]
vpclmulqdq xmm3,xmm0,xmm3,0x11
vmovdqu xmm0,XMMWORD[((64+8))+rsp]
vaesenc xmm10,xmm10,xmm15
movbe r13,QWORD[88+r14]
vaesenc xmm11,xmm11,xmm15
movbe r12,QWORD[80+r14]
vaesenc xmm12,xmm12,xmm15
mov QWORD[((32+8))+rsp],r13
vaesenc xmm13,xmm13,xmm15
mov QWORD[((40+8))+rsp],r12
vmovdqu xmm5,XMMWORD[((48-32))+r9]
vaesenc xmm14,xmm14,xmm15
vmovups xmm15,XMMWORD[((48-128))+rcx]
vpxor xmm6,xmm6,xmm1
vpclmulqdq xmm1,xmm0,xmm5,0x00
vaesenc xmm9,xmm9,xmm15
vpxor xmm6,xmm6,xmm2
vpclmulqdq xmm2,xmm0,xmm5,0x10
vaesenc xmm10,xmm10,xmm15
vpxor xmm7,xmm7,xmm3
vpclmulqdq xmm3,xmm0,xmm5,0x01
vaesenc xmm11,xmm11,xmm15
vpclmulqdq xmm5,xmm0,xmm5,0x11
vmovdqu xmm0,XMMWORD[((80+8))+rsp]
vaesenc xmm12,xmm12,xmm15
vaesenc xmm13,xmm13,xmm15
vpxor xmm4,xmm4,xmm1
vmovdqu xmm1,XMMWORD[((64-32))+r9]
vaesenc xmm14,xmm14,xmm15
vmovups xmm15,XMMWORD[((64-128))+rcx]
vpxor xmm6,xmm6,xmm2
vpclmulqdq xmm2,xmm0,xmm1,0x00
vaesenc xmm9,xmm9,xmm15
vpxor xmm6,xmm6,xmm3
vpclmulqdq xmm3,xmm0,xmm1,0x10
vaesenc xmm10,xmm10,xmm15
movbe r13,QWORD[72+r14]
vpxor xmm7,xmm7,xmm5
vpclmulqdq xmm5,xmm0,xmm1,0x01
vaesenc xmm11,xmm11,xmm15
movbe r12,QWORD[64+r14]
vpclmulqdq xmm1,xmm0,xmm1,0x11
vmovdqu xmm0,XMMWORD[((96+8))+rsp]
vaesenc xmm12,xmm12,xmm15
mov QWORD[((48+8))+rsp],r13
vaesenc xmm13,xmm13,xmm15
mov QWORD[((56+8))+rsp],r12
vpxor xmm4,xmm4,xmm2
vmovdqu xmm2,XMMWORD[((96-32))+r9]
vaesenc xmm14,xmm14,xmm15
vmovups xmm15,XMMWORD[((80-128))+rcx]
vpxor xmm6,xmm6,xmm3
vpclmulqdq xmm3,xmm0,xmm2,0x00
vaesenc xmm9,xmm9,xmm15
vpxor xmm6,xmm6,xmm5
vpclmulqdq xmm5,xmm0,xmm2,0x10
vaesenc xmm10,xmm10,xmm15
movbe r13,QWORD[56+r14]
vpxor xmm7,xmm7,xmm1
vpclmulqdq xmm1,xmm0,xmm2,0x01
vpxor xmm8,xmm8,XMMWORD[((112+8))+rsp]
vaesenc xmm11,xmm11,xmm15
movbe r12,QWORD[48+r14]
vpclmulqdq xmm2,xmm0,xmm2,0x11
vaesenc xmm12,xmm12,xmm15
mov QWORD[((64+8))+rsp],r13
vaesenc xmm13,xmm13,xmm15
mov QWORD[((72+8))+rsp],r12
vpxor xmm4,xmm4,xmm3
vmovdqu xmm3,XMMWORD[((112-32))+r9]
vaesenc xmm14,xmm14,xmm15
vmovups xmm15,XMMWORD[((96-128))+rcx]
vpxor xmm6,xmm6,xmm5
vpclmulqdq xmm5,xmm8,xmm3,0x10
vaesenc xmm9,xmm9,xmm15
vpxor xmm6,xmm6,xmm1
vpclmulqdq xmm1,xmm8,xmm3,0x01
vaesenc xmm10,xmm10,xmm15
movbe r13,QWORD[40+r14]
vpxor xmm7,xmm7,xmm2
vpclmulqdq xmm2,xmm8,xmm3,0x00
vaesenc xmm11,xmm11,xmm15
movbe r12,QWORD[32+r14]
vpclmulqdq xmm8,xmm8,xmm3,0x11
vaesenc xmm12,xmm12,xmm15
mov QWORD[((80+8))+rsp],r13
vaesenc xmm13,xmm13,xmm15
mov QWORD[((88+8))+rsp],r12
vpxor xmm6,xmm6,xmm5
vaesenc xmm14,xmm14,xmm15
vpxor xmm6,xmm6,xmm1
vmovups xmm15,XMMWORD[((112-128))+rcx]
vpslldq xmm5,xmm6,8
vpxor xmm4,xmm4,xmm2
vmovdqu xmm3,XMMWORD[16+r11]
vaesenc xmm9,xmm9,xmm15
vpxor xmm7,xmm7,xmm8
vaesenc xmm10,xmm10,xmm15
vpxor xmm4,xmm4,xmm5
movbe r13,QWORD[24+r14]
vaesenc xmm11,xmm11,xmm15
movbe r12,QWORD[16+r14]
vpalignr xmm0,xmm4,xmm4,8
vpclmulqdq xmm4,xmm4,xmm3,0x10
mov QWORD[((96+8))+rsp],r13
vaesenc xmm12,xmm12,xmm15
mov QWORD[((104+8))+rsp],r12
vaesenc xmm13,xmm13,xmm15
vmovups xmm1,XMMWORD[((128-128))+rcx]
vaesenc xmm14,xmm14,xmm15
vaesenc xmm9,xmm9,xmm1
vmovups xmm15,XMMWORD[((144-128))+rcx]
vaesenc xmm10,xmm10,xmm1
vpsrldq xmm6,xmm6,8
vaesenc xmm11,xmm11,xmm1
vpxor xmm7,xmm7,xmm6
vaesenc xmm12,xmm12,xmm1
vpxor xmm4,xmm4,xmm0
movbe r13,QWORD[8+r14]
vaesenc xmm13,xmm13,xmm1
movbe r12,QWORD[r14]
vaesenc xmm14,xmm14,xmm1
vmovups xmm1,XMMWORD[((160-128))+rcx]
cmp ebp,11
jb NEAR $L$enc_tail
vaesenc xmm9,xmm9,xmm15
vaesenc xmm10,xmm10,xmm15
vaesenc xmm11,xmm11,xmm15
vaesenc xmm12,xmm12,xmm15
vaesenc xmm13,xmm13,xmm15
vaesenc xmm14,xmm14,xmm15
vaesenc xmm9,xmm9,xmm1
vaesenc xmm10,xmm10,xmm1
vaesenc xmm11,xmm11,xmm1
vaesenc xmm12,xmm12,xmm1
vaesenc xmm13,xmm13,xmm1
vmovups xmm15,XMMWORD[((176-128))+rcx]
vaesenc xmm14,xmm14,xmm1
vmovups xmm1,XMMWORD[((192-128))+rcx]
je NEAR $L$enc_tail
vaesenc xmm9,xmm9,xmm15
vaesenc xmm10,xmm10,xmm15
vaesenc xmm11,xmm11,xmm15
vaesenc xmm12,xmm12,xmm15
vaesenc xmm13,xmm13,xmm15
vaesenc xmm14,xmm14,xmm15
vaesenc xmm9,xmm9,xmm1
vaesenc xmm10,xmm10,xmm1
vaesenc xmm11,xmm11,xmm1
vaesenc xmm12,xmm12,xmm1
vaesenc xmm13,xmm13,xmm1
vmovups xmm15,XMMWORD[((208-128))+rcx]
vaesenc xmm14,xmm14,xmm1
vmovups xmm1,XMMWORD[((224-128))+rcx]
jmp NEAR $L$enc_tail
ALIGN 32
$L$handle_ctr32:
vmovdqu xmm0,XMMWORD[r11]
vpshufb xmm6,xmm1,xmm0
vmovdqu xmm5,XMMWORD[48+r11]
vpaddd xmm10,xmm6,XMMWORD[64+r11]
vpaddd xmm11,xmm6,xmm5
vmovdqu xmm3,XMMWORD[((0-32))+r9]
vpaddd xmm12,xmm10,xmm5
vpshufb xmm10,xmm10,xmm0
vpaddd xmm13,xmm11,xmm5
vpshufb xmm11,xmm11,xmm0
vpxor xmm10,xmm10,xmm15
vpaddd xmm14,xmm12,xmm5
vpshufb xmm12,xmm12,xmm0
vpxor xmm11,xmm11,xmm15
vpaddd xmm1,xmm13,xmm5
vpshufb xmm13,xmm13,xmm0
vpshufb xmm14,xmm14,xmm0
vpshufb xmm1,xmm1,xmm0
jmp NEAR $L$resume_ctr32
ALIGN 32
$L$enc_tail:
vaesenc xmm9,xmm9,xmm15
vmovdqu XMMWORD[(16+8)+rsp],xmm7
vpalignr xmm8,xmm4,xmm4,8
vaesenc xmm10,xmm10,xmm15
vpclmulqdq xmm4,xmm4,xmm3,0x10
vpxor xmm2,xmm1,XMMWORD[rdi]
vaesenc xmm11,xmm11,xmm15
vpxor xmm0,xmm1,XMMWORD[16+rdi]
vaesenc xmm12,xmm12,xmm15
vpxor xmm5,xmm1,XMMWORD[32+rdi]
vaesenc xmm13,xmm13,xmm15
vpxor xmm6,xmm1,XMMWORD[48+rdi]
vaesenc xmm14,xmm14,xmm15
vpxor xmm7,xmm1,XMMWORD[64+rdi]
vpxor xmm3,xmm1,XMMWORD[80+rdi]
vmovdqu xmm1,XMMWORD[r8]
vaesenclast xmm9,xmm9,xmm2
vmovdqu xmm2,XMMWORD[32+r11]
vaesenclast xmm10,xmm10,xmm0
vpaddb xmm0,xmm1,xmm2
mov QWORD[((112+8))+rsp],r13
lea rdi,[96+rdi]
vaesenclast xmm11,xmm11,xmm5
vpaddb xmm5,xmm0,xmm2
mov QWORD[((120+8))+rsp],r12
lea rsi,[96+rsi]
vmovdqu xmm15,XMMWORD[((0-128))+rcx]
vaesenclast xmm12,xmm12,xmm6
vpaddb xmm6,xmm5,xmm2
vaesenclast xmm13,xmm13,xmm7
vpaddb xmm7,xmm6,xmm2
vaesenclast xmm14,xmm14,xmm3
vpaddb xmm3,xmm7,xmm2
add r10,0x60
sub rdx,0x6
jc NEAR $L$6x_done
vmovups XMMWORD[(-96)+rsi],xmm9
vpxor xmm9,xmm1,xmm15
vmovups XMMWORD[(-80)+rsi],xmm10
vmovdqa xmm10,xmm0
vmovups XMMWORD[(-64)+rsi],xmm11
vmovdqa xmm11,xmm5
vmovups XMMWORD[(-48)+rsi],xmm12
vmovdqa xmm12,xmm6
vmovups XMMWORD[(-32)+rsi],xmm13
vmovdqa xmm13,xmm7
vmovups XMMWORD[(-16)+rsi],xmm14
vmovdqa xmm14,xmm3
vmovdqu xmm7,XMMWORD[((32+8))+rsp]
jmp NEAR $L$oop6x
$L$6x_done:
vpxor xmm8,xmm8,XMMWORD[((16+8))+rsp]
vpxor xmm8,xmm8,xmm4
DB 0F3h,0C3h ;repret
global aesni_gcm_decrypt
ALIGN 32
aesni_gcm_decrypt:
mov QWORD[8+rsp],rdi ;WIN64 prologue
mov QWORD[16+rsp],rsi
mov rax,rsp
$L$SEH_begin_aesni_gcm_decrypt:
mov rdi,rcx
mov rsi,rdx
mov rdx,r8
mov rcx,r9
mov r8,QWORD[40+rsp]
mov r9,QWORD[48+rsp]
xor r10,r10
cmp rdx,0x60
jb NEAR $L$gcm_dec_abort
lea rax,[rsp]
push rbx
push rbp
push r12
push r13
push r14
push r15
lea rsp,[((-168))+rsp]
movaps XMMWORD[(-216)+rax],xmm6
movaps XMMWORD[(-200)+rax],xmm7
movaps XMMWORD[(-184)+rax],xmm8
movaps XMMWORD[(-168)+rax],xmm9
movaps XMMWORD[(-152)+rax],xmm10
movaps XMMWORD[(-136)+rax],xmm11
movaps XMMWORD[(-120)+rax],xmm12
movaps XMMWORD[(-104)+rax],xmm13
movaps XMMWORD[(-88)+rax],xmm14
movaps XMMWORD[(-72)+rax],xmm15
$L$gcm_dec_body:
vzeroupper
vmovdqu xmm1,XMMWORD[r8]
add rsp,-128
mov ebx,DWORD[12+r8]
lea r11,[$L$bswap_mask]
lea r14,[((-128))+rcx]
mov r15,0xf80
vmovdqu xmm8,XMMWORD[r9]
and rsp,-128
vmovdqu xmm0,XMMWORD[r11]
lea rcx,[128+rcx]
lea r9,[((32+32))+r9]
mov ebp,DWORD[((240-128))+rcx]
vpshufb xmm8,xmm8,xmm0
and r14,r15
and r15,rsp
sub r15,r14
jc NEAR $L$dec_no_key_aliasing
cmp r15,768
jnc NEAR $L$dec_no_key_aliasing
sub rsp,r15
$L$dec_no_key_aliasing:
vmovdqu xmm7,XMMWORD[80+rdi]
lea r14,[rdi]
vmovdqu xmm4,XMMWORD[64+rdi]
lea r15,[((-192))+rdx*1+rdi]
vmovdqu xmm5,XMMWORD[48+rdi]
shr rdx,4
xor r10,r10
vmovdqu xmm6,XMMWORD[32+rdi]
vpshufb xmm7,xmm7,xmm0
vmovdqu xmm2,XMMWORD[16+rdi]
vpshufb xmm4,xmm4,xmm0
vmovdqu xmm3,XMMWORD[rdi]
vpshufb xmm5,xmm5,xmm0
vmovdqu XMMWORD[48+rsp],xmm4
vpshufb xmm6,xmm6,xmm0
vmovdqu XMMWORD[64+rsp],xmm5
vpshufb xmm2,xmm2,xmm0
vmovdqu XMMWORD[80+rsp],xmm6
vpshufb xmm3,xmm3,xmm0
vmovdqu XMMWORD[96+rsp],xmm2
vmovdqu XMMWORD[112+rsp],xmm3
call _aesni_ctr32_ghash_6x
vmovups XMMWORD[(-96)+rsi],xmm9
vmovups XMMWORD[(-80)+rsi],xmm10
vmovups XMMWORD[(-64)+rsi],xmm11
vmovups XMMWORD[(-48)+rsi],xmm12
vmovups XMMWORD[(-32)+rsi],xmm13
vmovups XMMWORD[(-16)+rsi],xmm14
vpshufb xmm8,xmm8,XMMWORD[r11]
vmovdqu XMMWORD[(-64)+r9],xmm8
vzeroupper
movaps xmm6,XMMWORD[((-216))+rax]
movaps xmm7,XMMWORD[((-200))+rax]
movaps xmm8,XMMWORD[((-184))+rax]
movaps xmm9,XMMWORD[((-168))+rax]
movaps xmm10,XMMWORD[((-152))+rax]
movaps xmm11,XMMWORD[((-136))+rax]
movaps xmm12,XMMWORD[((-120))+rax]
movaps xmm13,XMMWORD[((-104))+rax]
movaps xmm14,XMMWORD[((-88))+rax]
movaps xmm15,XMMWORD[((-72))+rax]
mov r15,QWORD[((-48))+rax]
mov r14,QWORD[((-40))+rax]
mov r13,QWORD[((-32))+rax]
mov r12,QWORD[((-24))+rax]
mov rbp,QWORD[((-16))+rax]
mov rbx,QWORD[((-8))+rax]
lea rsp,[rax]
$L$gcm_dec_abort:
mov rax,r10
mov rdi,QWORD[8+rsp] ;WIN64 epilogue
mov rsi,QWORD[16+rsp]
DB 0F3h,0C3h ;repret
$L$SEH_end_aesni_gcm_decrypt:
ALIGN 32
_aesni_ctr32_6x:
vmovdqu xmm4,XMMWORD[((0-128))+rcx]
vmovdqu xmm2,XMMWORD[32+r11]
lea r13,[((-1))+rbp]
vmovups xmm15,XMMWORD[((16-128))+rcx]
lea r12,[((32-128))+rcx]
vpxor xmm9,xmm1,xmm4
add ebx,100663296
jc NEAR $L$handle_ctr32_2
vpaddb xmm10,xmm1,xmm2
vpaddb xmm11,xmm10,xmm2
vpxor xmm10,xmm10,xmm4
vpaddb xmm12,xmm11,xmm2
vpxor xmm11,xmm11,xmm4
vpaddb xmm13,xmm12,xmm2
vpxor xmm12,xmm12,xmm4
vpaddb xmm14,xmm13,xmm2
vpxor xmm13,xmm13,xmm4
vpaddb xmm1,xmm14,xmm2
vpxor xmm14,xmm14,xmm4
jmp NEAR $L$oop_ctr32
ALIGN 16
$L$oop_ctr32:
vaesenc xmm9,xmm9,xmm15
vaesenc xmm10,xmm10,xmm15
vaesenc xmm11,xmm11,xmm15
vaesenc xmm12,xmm12,xmm15
vaesenc xmm13,xmm13,xmm15
vaesenc xmm14,xmm14,xmm15
vmovups xmm15,XMMWORD[r12]
lea r12,[16+r12]
dec r13d
jnz NEAR $L$oop_ctr32
vmovdqu xmm3,XMMWORD[r12]
vaesenc xmm9,xmm9,xmm15
vpxor xmm4,xmm3,XMMWORD[rdi]
vaesenc xmm10,xmm10,xmm15
vpxor xmm5,xmm3,XMMWORD[16+rdi]
vaesenc xmm11,xmm11,xmm15
vpxor xmm6,xmm3,XMMWORD[32+rdi]
vaesenc xmm12,xmm12,xmm15
vpxor xmm8,xmm3,XMMWORD[48+rdi]
vaesenc xmm13,xmm13,xmm15
vpxor xmm2,xmm3,XMMWORD[64+rdi]
vaesenc xmm14,xmm14,xmm15
vpxor xmm3,xmm3,XMMWORD[80+rdi]
lea rdi,[96+rdi]
vaesenclast xmm9,xmm9,xmm4
vaesenclast xmm10,xmm10,xmm5
vaesenclast xmm11,xmm11,xmm6
vaesenclast xmm12,xmm12,xmm8
vaesenclast xmm13,xmm13,xmm2
vaesenclast xmm14,xmm14,xmm3
vmovups XMMWORD[rsi],xmm9
vmovups XMMWORD[16+rsi],xmm10
vmovups XMMWORD[32+rsi],xmm11
vmovups XMMWORD[48+rsi],xmm12
vmovups XMMWORD[64+rsi],xmm13
vmovups XMMWORD[80+rsi],xmm14
lea rsi,[96+rsi]
DB 0F3h,0C3h ;repret
ALIGN 32
$L$handle_ctr32_2:
vpshufb xmm6,xmm1,xmm0
vmovdqu xmm5,XMMWORD[48+r11]
vpaddd xmm10,xmm6,XMMWORD[64+r11]
vpaddd xmm11,xmm6,xmm5
vpaddd xmm12,xmm10,xmm5
vpshufb xmm10,xmm10,xmm0
vpaddd xmm13,xmm11,xmm5
vpshufb xmm11,xmm11,xmm0
vpxor xmm10,xmm10,xmm4
vpaddd xmm14,xmm12,xmm5
vpshufb xmm12,xmm12,xmm0
vpxor xmm11,xmm11,xmm4
vpaddd xmm1,xmm13,xmm5
vpshufb xmm13,xmm13,xmm0
vpxor xmm12,xmm12,xmm4
vpshufb xmm14,xmm14,xmm0
vpxor xmm13,xmm13,xmm4
vpshufb xmm1,xmm1,xmm0
vpxor xmm14,xmm14,xmm4
jmp NEAR $L$oop_ctr32
global aesni_gcm_encrypt
ALIGN 32
aesni_gcm_encrypt:
mov QWORD[8+rsp],rdi ;WIN64 prologue
mov QWORD[16+rsp],rsi
mov rax,rsp
$L$SEH_begin_aesni_gcm_encrypt:
mov rdi,rcx
mov rsi,rdx
mov rdx,r8
mov rcx,r9
mov r8,QWORD[40+rsp]
mov r9,QWORD[48+rsp]
xor r10,r10
cmp rdx,0x60*3
jb NEAR $L$gcm_enc_abort
lea rax,[rsp]
push rbx
push rbp
push r12
push r13
push r14
push r15
lea rsp,[((-168))+rsp]
movaps XMMWORD[(-216)+rax],xmm6
movaps XMMWORD[(-200)+rax],xmm7
movaps XMMWORD[(-184)+rax],xmm8
movaps XMMWORD[(-168)+rax],xmm9
movaps XMMWORD[(-152)+rax],xmm10
movaps XMMWORD[(-136)+rax],xmm11
movaps XMMWORD[(-120)+rax],xmm12
movaps XMMWORD[(-104)+rax],xmm13
movaps XMMWORD[(-88)+rax],xmm14
movaps XMMWORD[(-72)+rax],xmm15
$L$gcm_enc_body:
vzeroupper
vmovdqu xmm1,XMMWORD[r8]
add rsp,-128
mov ebx,DWORD[12+r8]
lea r11,[$L$bswap_mask]
lea r14,[((-128))+rcx]
mov r15,0xf80
lea rcx,[128+rcx]
vmovdqu xmm0,XMMWORD[r11]
and rsp,-128
mov ebp,DWORD[((240-128))+rcx]
and r14,r15
and r15,rsp
sub r15,r14
jc NEAR $L$enc_no_key_aliasing
cmp r15,768
jnc NEAR $L$enc_no_key_aliasing
sub rsp,r15
$L$enc_no_key_aliasing:
lea r14,[rsi]
lea r15,[((-192))+rdx*1+rsi]
shr rdx,4
call _aesni_ctr32_6x
vpshufb xmm8,xmm9,xmm0
vpshufb xmm2,xmm10,xmm0
vmovdqu XMMWORD[112+rsp],xmm8
vpshufb xmm4,xmm11,xmm0
vmovdqu XMMWORD[96+rsp],xmm2
vpshufb xmm5,xmm12,xmm0
vmovdqu XMMWORD[80+rsp],xmm4
vpshufb xmm6,xmm13,xmm0
vmovdqu XMMWORD[64+rsp],xmm5
vpshufb xmm7,xmm14,xmm0
vmovdqu XMMWORD[48+rsp],xmm6
call _aesni_ctr32_6x
vmovdqu xmm8,XMMWORD[r9]
lea r9,[((32+32))+r9]
sub rdx,12
mov r10,0x60*2
vpshufb xmm8,xmm8,xmm0
call _aesni_ctr32_ghash_6x
vmovdqu xmm7,XMMWORD[32+rsp]
vmovdqu xmm0,XMMWORD[r11]
vmovdqu xmm3,XMMWORD[((0-32))+r9]
vpunpckhqdq xmm1,xmm7,xmm7
vmovdqu xmm15,XMMWORD[((32-32))+r9]
vmovups XMMWORD[(-96)+rsi],xmm9
vpshufb xmm9,xmm9,xmm0
vpxor xmm1,xmm1,xmm7
vmovups XMMWORD[(-80)+rsi],xmm10
vpshufb xmm10,xmm10,xmm0
vmovups XMMWORD[(-64)+rsi],xmm11
vpshufb xmm11,xmm11,xmm0
vmovups XMMWORD[(-48)+rsi],xmm12
vpshufb xmm12,xmm12,xmm0
vmovups XMMWORD[(-32)+rsi],xmm13
vpshufb xmm13,xmm13,xmm0
vmovups XMMWORD[(-16)+rsi],xmm14
vpshufb xmm14,xmm14,xmm0
vmovdqu XMMWORD[16+rsp],xmm9
vmovdqu xmm6,XMMWORD[48+rsp]
vmovdqu xmm0,XMMWORD[((16-32))+r9]
vpunpckhqdq xmm2,xmm6,xmm6
vpclmulqdq xmm5,xmm7,xmm3,0x00
vpxor xmm2,xmm2,xmm6
vpclmulqdq xmm7,xmm7,xmm3,0x11
vpclmulqdq xmm1,xmm1,xmm15,0x00
vmovdqu xmm9,XMMWORD[64+rsp]
vpclmulqdq xmm4,xmm6,xmm0,0x00
vmovdqu xmm3,XMMWORD[((48-32))+r9]
vpxor xmm4,xmm4,xmm5
vpunpckhqdq xmm5,xmm9,xmm9
vpclmulqdq xmm6,xmm6,xmm0,0x11
vpxor xmm5,xmm5,xmm9
vpxor xmm6,xmm6,xmm7
vpclmulqdq xmm2,xmm2,xmm15,0x10
vmovdqu xmm15,XMMWORD[((80-32))+r9]
vpxor xmm2,xmm2,xmm1
vmovdqu xmm1,XMMWORD[80+rsp]
vpclmulqdq xmm7,xmm9,xmm3,0x00
vmovdqu xmm0,XMMWORD[((64-32))+r9]
vpxor xmm7,xmm7,xmm4
vpunpckhqdq xmm4,xmm1,xmm1
vpclmulqdq xmm9,xmm9,xmm3,0x11
vpxor xmm4,xmm4,xmm1
vpxor xmm9,xmm9,xmm6
vpclmulqdq xmm5,xmm5,xmm15,0x00
vpxor xmm5,xmm5,xmm2
vmovdqu xmm2,XMMWORD[96+rsp]
vpclmulqdq xmm6,xmm1,xmm0,0x00
vmovdqu xmm3,XMMWORD[((96-32))+r9]
vpxor xmm6,xmm6,xmm7
vpunpckhqdq xmm7,xmm2,xmm2
vpclmulqdq xmm1,xmm1,xmm0,0x11
vpxor xmm7,xmm7,xmm2
vpxor xmm1,xmm1,xmm9
vpclmulqdq xmm4,xmm4,xmm15,0x10
vmovdqu xmm15,XMMWORD[((128-32))+r9]
vpxor xmm4,xmm4,xmm5
vpxor xmm8,xmm8,XMMWORD[112+rsp]
vpclmulqdq xmm5,xmm2,xmm3,0x00
vmovdqu xmm0,XMMWORD[((112-32))+r9]
vpunpckhqdq xmm9,xmm8,xmm8
vpxor xmm5,xmm5,xmm6
vpclmulqdq xmm2,xmm2,xmm3,0x11
vpxor xmm9,xmm9,xmm8
vpxor xmm2,xmm2,xmm1
vpclmulqdq xmm7,xmm7,xmm15,0x00
vpxor xmm4,xmm7,xmm4
vpclmulqdq xmm6,xmm8,xmm0,0x00
vmovdqu xmm3,XMMWORD[((0-32))+r9]
vpunpckhqdq xmm1,xmm14,xmm14
vpclmulqdq xmm8,xmm8,xmm0,0x11
vpxor xmm1,xmm1,xmm14
vpxor xmm5,xmm6,xmm5
vpclmulqdq xmm9,xmm9,xmm15,0x10
vmovdqu xmm15,XMMWORD[((32-32))+r9]
vpxor xmm7,xmm8,xmm2
vpxor xmm6,xmm9,xmm4
vmovdqu xmm0,XMMWORD[((16-32))+r9]
vpxor xmm9,xmm7,xmm5
vpclmulqdq xmm4,xmm14,xmm3,0x00
vpxor xmm6,xmm6,xmm9
vpunpckhqdq xmm2,xmm13,xmm13
vpclmulqdq xmm14,xmm14,xmm3,0x11
vpxor xmm2,xmm2,xmm13
vpslldq xmm9,xmm6,8
vpclmulqdq xmm1,xmm1,xmm15,0x00
vpxor xmm8,xmm5,xmm9
vpsrldq xmm6,xmm6,8
vpxor xmm7,xmm7,xmm6
vpclmulqdq xmm5,xmm13,xmm0,0x00
vmovdqu xmm3,XMMWORD[((48-32))+r9]
vpxor xmm5,xmm5,xmm4
vpunpckhqdq xmm9,xmm12,xmm12
vpclmulqdq xmm13,xmm13,xmm0,0x11
vpxor xmm9,xmm9,xmm12
vpxor xmm13,xmm13,xmm14
vpalignr xmm14,xmm8,xmm8,8
vpclmulqdq xmm2,xmm2,xmm15,0x10
vmovdqu xmm15,XMMWORD[((80-32))+r9]
vpxor xmm2,xmm2,xmm1
vpclmulqdq xmm4,xmm12,xmm3,0x00
vmovdqu xmm0,XMMWORD[((64-32))+r9]
vpxor xmm4,xmm4,xmm5
vpunpckhqdq xmm1,xmm11,xmm11
vpclmulqdq xmm12,xmm12,xmm3,0x11
vpxor xmm1,xmm1,xmm11
vpxor xmm12,xmm12,xmm13
vxorps xmm7,xmm7,XMMWORD[16+rsp]
vpclmulqdq xmm9,xmm9,xmm15,0x00
vpxor xmm9,xmm9,xmm2
vpclmulqdq xmm8,xmm8,XMMWORD[16+r11],0x10
vxorps xmm8,xmm8,xmm14
vpclmulqdq xmm5,xmm11,xmm0,0x00
vmovdqu xmm3,XMMWORD[((96-32))+r9]
vpxor xmm5,xmm5,xmm4
vpunpckhqdq xmm2,xmm10,xmm10
vpclmulqdq xmm11,xmm11,xmm0,0x11
vpxor xmm2,xmm2,xmm10
vpalignr xmm14,xmm8,xmm8,8
vpxor xmm11,xmm11,xmm12
vpclmulqdq xmm1,xmm1,xmm15,0x10
vmovdqu xmm15,XMMWORD[((128-32))+r9]
vpxor xmm1,xmm1,xmm9
vxorps xmm14,xmm14,xmm7
vpclmulqdq xmm8,xmm8,XMMWORD[16+r11],0x10
vxorps xmm8,xmm8,xmm14
vpclmulqdq xmm4,xmm10,xmm3,0x00
vmovdqu xmm0,XMMWORD[((112-32))+r9]
vpxor xmm4,xmm4,xmm5
vpunpckhqdq xmm9,xmm8,xmm8
vpclmulqdq xmm10,xmm10,xmm3,0x11
vpxor xmm9,xmm9,xmm8
vpxor xmm10,xmm10,xmm11
vpclmulqdq xmm2,xmm2,xmm15,0x00
vpxor xmm2,xmm2,xmm1
vpclmulqdq xmm5,xmm8,xmm0,0x00
vpclmulqdq xmm7,xmm8,xmm0,0x11
vpxor xmm5,xmm5,xmm4
vpclmulqdq xmm6,xmm9,xmm15,0x10
vpxor xmm7,xmm7,xmm10
vpxor xmm6,xmm6,xmm2
vpxor xmm4,xmm7,xmm5
vpxor xmm6,xmm6,xmm4
vpslldq xmm1,xmm6,8
vmovdqu xmm3,XMMWORD[16+r11]
vpsrldq xmm6,xmm6,8
vpxor xmm8,xmm5,xmm1
vpxor xmm7,xmm7,xmm6
vpalignr xmm2,xmm8,xmm8,8
vpclmulqdq xmm8,xmm8,xmm3,0x10
vpxor xmm8,xmm8,xmm2
vpalignr xmm2,xmm8,xmm8,8
vpclmulqdq xmm8,xmm8,xmm3,0x10
vpxor xmm2,xmm2,xmm7
vpxor xmm8,xmm8,xmm2
vpshufb xmm8,xmm8,XMMWORD[r11]
vmovdqu XMMWORD[(-64)+r9],xmm8
vzeroupper
movaps xmm6,XMMWORD[((-216))+rax]
movaps xmm7,XMMWORD[((-200))+rax]
movaps xmm8,XMMWORD[((-184))+rax]
movaps xmm9,XMMWORD[((-168))+rax]
movaps xmm10,XMMWORD[((-152))+rax]
movaps xmm11,XMMWORD[((-136))+rax]
movaps xmm12,XMMWORD[((-120))+rax]
movaps xmm13,XMMWORD[((-104))+rax]
movaps xmm14,XMMWORD[((-88))+rax]
movaps xmm15,XMMWORD[((-72))+rax]
mov r15,QWORD[((-48))+rax]
mov r14,QWORD[((-40))+rax]
mov r13,QWORD[((-32))+rax]
mov r12,QWORD[((-24))+rax]
mov rbp,QWORD[((-16))+rax]
mov rbx,QWORD[((-8))+rax]
lea rsp,[rax]
$L$gcm_enc_abort:
mov rax,r10
mov rdi,QWORD[8+rsp] ;WIN64 epilogue
mov rsi,QWORD[16+rsp]
DB 0F3h,0C3h ;repret
$L$SEH_end_aesni_gcm_encrypt:
ALIGN 64
$L$bswap_mask:
DB 15,14,13,12,11,10,9,8,7,6,5,4,3,2,1,0
$L$poly:
DB 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0xc2
$L$one_msb:
DB 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1
$L$two_lsb:
DB 2,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0
$L$one_lsb:
DB 1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0
DB 65,69,83,45,78,73,32,71,67,77,32,109,111,100,117,108
DB 101,32,102,111,114,32,120,56,54,95,54,52,44,32,67,82
DB 89,80,84,79,71,65,77,83,32,98,121,32,60,97,112,112
DB 114,111,64,111,112,101,110,115,115,108,46,111,114,103,62,0
ALIGN 64
EXTERN __imp_RtlVirtualUnwind
ALIGN 16
gcm_se_handler:
push rsi
push rdi
push rbx
push rbp
push r12
push r13
push r14
push r15
pushfq
sub rsp,64
mov rax,QWORD[120+r8]
mov rbx,QWORD[248+r8]
mov rsi,QWORD[8+r9]
mov r11,QWORD[56+r9]
mov r10d,DWORD[r11]
lea r10,[r10*1+rsi]
cmp rbx,r10
jb NEAR $L$common_seh_tail
mov rax,QWORD[152+r8]
mov r10d,DWORD[4+r11]
lea r10,[r10*1+rsi]
cmp rbx,r10
jae NEAR $L$common_seh_tail
mov rax,QWORD[120+r8]
mov r15,QWORD[((-48))+rax]
mov r14,QWORD[((-40))+rax]
mov r13,QWORD[((-32))+rax]
mov r12,QWORD[((-24))+rax]
mov rbp,QWORD[((-16))+rax]
mov rbx,QWORD[((-8))+rax]
mov QWORD[240+r8],r15
mov QWORD[232+r8],r14
mov QWORD[224+r8],r13
mov QWORD[216+r8],r12
mov QWORD[160+r8],rbp
mov QWORD[144+r8],rbx
lea rsi,[((-216))+rax]
lea rdi,[512+r8]
mov ecx,20
DD 0xa548f3fc
$L$common_seh_tail:
mov rdi,QWORD[8+rax]
mov rsi,QWORD[16+rax]
mov QWORD[152+r8],rax
mov QWORD[168+r8],rsi
mov QWORD[176+r8],rdi
mov rdi,QWORD[40+r9]
mov rsi,r8
mov ecx,154
DD 0xa548f3fc
mov rsi,r9
xor rcx,rcx
mov rdx,QWORD[8+rsi]
mov r8,QWORD[rsi]
mov r9,QWORD[16+rsi]
mov r10,QWORD[40+rsi]
lea r11,[56+rsi]
lea r12,[24+rsi]
mov QWORD[32+rsp],r10
mov QWORD[40+rsp],r11
mov QWORD[48+rsp],r12
mov QWORD[56+rsp],rcx
call QWORD[__imp_RtlVirtualUnwind]
mov eax,1
add rsp,64
popfq
pop r15
pop r14
pop r13
pop r12
pop rbp
pop rbx
pop rdi
pop rsi
DB 0F3h,0C3h ;repret
section .pdata rdata align=4
ALIGN 4
DD $L$SEH_begin_aesni_gcm_decrypt wrt ..imagebase
DD $L$SEH_end_aesni_gcm_decrypt wrt ..imagebase
DD $L$SEH_gcm_dec_info wrt ..imagebase
DD $L$SEH_begin_aesni_gcm_encrypt wrt ..imagebase
DD $L$SEH_end_aesni_gcm_encrypt wrt ..imagebase
DD $L$SEH_gcm_enc_info wrt ..imagebase
section .xdata rdata align=8
ALIGN 8
$L$SEH_gcm_dec_info:
DB 9,0,0,0
DD gcm_se_handler wrt ..imagebase
DD $L$gcm_dec_body wrt ..imagebase,$L$gcm_dec_abort wrt ..imagebase
$L$SEH_gcm_enc_info:
DB 9,0,0,0
DD gcm_se_handler wrt ..imagebase
DD $L$gcm_enc_body wrt ..imagebase,$L$gcm_enc_abort wrt ..imagebase
| MTASZTAKI/ApertusVR | plugins/languageAPI/jsAPI/3rdParty/nodejs/10.1.0/source/deps/openssl/config/archs/VC-WIN64A/asm/crypto/modes/aesni-gcm-x86_64.asm | Assembly | mit | 22,188 |
;
; Copyright (c) 2014-2015, Alexey Frunze
; 2-clause BSD license.
;
bits 16
extern ___start__
extern __start__bss
extern __stop__bss
section .text
global __start
__start:
mov ax, ss
mov [cs:_ss], ax ; preserve SS as the data segment, which we may need to access from ISRs
mov ds, ax ; DS=ES=SS in small model .EXEs and in tiny model .COMs
mov es, ax
mov bx, cs
cmp ax, bx
jne exe
; CS=SS means it's a .COM program.
; .COM programs get all available memory allocated to them.
; Shrink the PSP block to 64KB.
mov ah, 0x4a
mov bx, 4096
int 0x21
jnc exe
; .COM programs may receive less than 64KB of memory just as well, bail out if it's the case
mov ah, 0x40
mov bx, 2 ; stderr
mov dx, _64kbmsg
mov cx, _64kbmsg_end - _64kbmsg
int 0x21
jmp terminate
exe:
; Init .bss
mov di, __start__bss
mov cx, __stop__bss
sub cx, di
xor al, al
cld
rep stosb
jmp ___start__ ; __start__() will set up argc and argv for main() and call exit(main(argc, argv))
global ___getCS
___getCS:
mov ax, cs
ret
global ___getSS
___getSS:
mov ax, [cs:_ss]
ret
_ss dw 0
extern ___DosSetVect
extern ___Int00DE, ___Int04OF, ___Int06UD
; extern ___Int01DB
; extern ___Int03BP
; These ISRs may be called on the stack that does not belong to the app
; (e.g. it could be internal DOS stack).
;
; In the small and tiny memory models the compiler generates code in the
; assumption that DS=SS and supports no form of far pointers and has no
; way of distinguishing a near 16-bit pointer from one pointing to a
; global variable and one pointing to a local on-stack variable as both
; are expected to be in the same segment, hence DS=SS.
;
; Because of this, implementing ISRs in C or calling C functions from
; ISRs written in asm is difficult in the small and tiny memory models.
;
; For C code to work in the context of an ISR, we need to switch to the
; original stack (whose top we can't always know) or use a dedicated
; ISR stack area within the same data/stack segment of the small/tiny
; app.
;
; Transforming exceptions and Ctrl+C into signals is thus difficult in
; the small and tiny memory models and the only thing that can be done
; easily if one occurs is terminate the app, which is what we're doing
; here.
;
; Note, this technical problem does not exist in the huge memory model
; since all pointers in it include segment information, which is used
; when dereferencing pointers.
global ___ExcIsr
___ExcIsr:
mov ah, 0x40
mov bx, 2 ; stderr
push cs
pop ds
mov dx, _excmsg
mov cx, _excmsg_end - _excmsg
int 0x21
; fallthrough
; It looks like DOS will terminate the app on Ctrl+C even without a custom int 0x23 handler.
; But let's keep the code as I might transform Ctrl+C into SIGINT in the future.
global ___CtrlCIsr
___CtrlCIsr:
mov ax, [cs:_ss]
mov ds, ax
mov es, ax
push ___Int00DE
push 0
call ___DosSetVect
; push ___Int01DB
; push 1
; call ___DosSetVect
; push ___Int03BP
; push 3
; call ___DosSetVect
push ___Int04OF
push 4
call ___DosSetVect
push ___Int06UD
push 6
call ___DosSetVect
terminate:
mov ax, 0x4c01
int 0x21
_excmsg db 13,10,"Unhandled exception!",13,10
_excmsg_end:
_64kbmsg db "Not enough memory!",13,10
_64kbmsg_end:
section .bss
; .bss must exist for __start__bss and __stop__bss to also exist
resw 1
| gdos/SmallerC | v0100/srclib/c0ds.asm | Assembly | bsd-2-clause | 3,622 |
; code name HYPER BALL | 68K code
;==============================================================================;
include "include/neogeo.inc" ; Neo-Geo Hardware and System ROM definitions
include "include/ram_bios.inc" ; BIOS RAM locations
include "include/input.inc" ; Input defines
include "ram_user.inc" ; user RAM
include "macro.asm" ;
;==============================================================================;
include "header_68k.inc" ; 68000 header
;==============================================================================;
ifd ENABLE_SECTION
else
section code
endif
ifd TARGET_CD
include "header_cd.inc"
else
include "header_cart.inc"
endif
include "softdips.inc"
;ID & Info
BG1_id = 1
BG1_w = 32
BG1_h = 32
BG2_id = 33
BG2_w = 32
BG2_h = 32
SCORE_id = 65
CH1_id = 100
CH1_w = 04
CH1_h = 04
;==============================================================================;
; todo: actual versions of the standard routines required by the bios
; (e.g. USER, PLAYER_START, DEMO_END, COIN_SOUND)
;==============================================================================;
Reset:
Init_NeoGeo
jsr clear_fix
Text_Draw 2,3,Hello_text
move.w #$8fff,PALETTE_BACKDROP
;Load Palettes
Load_Palette pal_DefaultFix,$00,1
Load_Palette pal_TestCourt,$01,1
Load_Palette palette_tile1,$10,2
Load_Palette palette_scoreboard,$30,2
;Background
Sprite_init BG1_id,BG1_w,BG1_h,BG1_struct
Sprite_position_ram_init BG1_struct,-8,0
Sprite_DrawBG BG1_struct,BG1_h,Map1
;Score
Sprite_Draw_sp SCORE_id,#$0407,#$3000
Sprite_init_sp SCORE_id,$40,$40
;Ch1
Sprite_init CH1_id,CH1_w,CH1_h,CH1_struct
move.w #$40,CH1_struct+_px
move.w #-$40,CH1_struct+_py
move.w #$0000,CH1_struct+_animact
move.w #$3100,CH1_struct+_tileext
move.w #$0004,CH1_struct+_animv
move.w #$0008,CH1_struct+_animn
move.b #$00,CH1_struct+_direction
;Sprite_Draw_sp 66,#$05E9,#$3000
;Sprite_init_sp 66,$80,$40
move.w #$2000,sr ; Enable VBlank interrupt, go Supervisor
; todo: handle user request
Gameloop:
Animation CH1_struct
jsr Buffer_ch1
move.b #$00,CH1_struct+_animact
cmpi.b #$02,MEM_STDCTRL+_UP
if_ne
move.b #$01,CH1_struct+_animact
move.b #$00,CH1_struct+_direction
addi.w #$0001,CH1_struct+_py
endi
cmpi.b #$02,MEM_STDCTRL+_DOWN
if_ne
move.b #$02,CH1_struct+_animact
subi.w #$0001,CH1_struct+_py
move.b #$01,CH1_struct+_direction
endi
cmpi.b #$02,MEM_STDCTRL+_RIGHT
if_ne
move.b #$04,CH1_struct+_animact
move.b #$02,CH1_struct+_direction
addi.w #$0001,CH1_struct+_px
endi
cmpi.b #$02,MEM_STDCTRL+_LEFT
if_ne
move.b #$03,CH1_struct+_animact
move.b #$03,CH1_struct+_direction
subi.w #$0001,CH1_struct+_px
endi
move.w CH1_struct+_px,d1
move.w CH1_struct+_py,d2
Position_Sprite_update CH1_struct,d1,d2
jsr WaitVBlank
jmp Gameloop
Buffer_ch1:
move.w #$0000,d2
cmpi.b #$01,CH1_struct+_direction
if_ne
move.w #$0120,d2
endi
cmpi.b #$02,CH1_struct+_direction
if_ne
move.w #$1B0,d2
endi
cmpi.b #$03,CH1_struct+_direction
if_ne
move.w #$90,d2
endi
cmpi.b #$00,CH1_struct+_animact
if_ne
move.w #0,CH1_struct+_animi
move.w #0,CH1_struct+_animl
move.w #$0000,CH1_struct+_animv
move.w #$0000,CH1_struct+_animn
endi
cmpi.b #$01,CH1_struct+_animact
if_ne
move.w #$0004,d2
move.w #$0004,CH1_struct+_animv
move.w #$0008,CH1_struct+_animn
endi
cmpi.b #$02,CH1_struct+_animact
if_ne
move.w #$0124,d2
move.w #$0004,CH1_struct+_animv
move.w #$0008,CH1_struct+_animn
endi
cmpi.b #$03,CH1_struct+_animact
if_ne
move.w #$0094,d2
move.w #$0004,CH1_struct+_animv
move.w #$0008,CH1_struct+_animn
endi
cmpi.b #$04,CH1_struct+_animact
if_ne
move.w #$01B4,d2
move.w #$0004,CH1_struct+_animv
move.w #$0008,CH1_struct+_animn
endi
move.w CH1_struct+_animi,d1
lsl #2,d1
add.w d2,d1
move.l #BufferMap,a1
move.w #$05e8+0,d0
add.w d1,d0
move.w d0,(a1)+
move.w #$060C+0,d0
add.w d1,d0
move.w d0,(a1)+
move.w #$0630+0,d0
add.w d1,d0
move.w d0,(a1)+
move.w #$0654+0,d0
add.w d1,d0
move.w d0,(a1)+
move.w #$05e8+1,d0
add.w d1,d0
move.w d0,(a1)+
move.w #$060C+1,d0
add.w d1,d0
move.w d0,(a1)+
move.w #$0630+1,d0
add.w d1,d0
move.w d0,(a1)+
move.w #$0654+1,d0
add.w d1,d0
move.w d0,(a1)+
move.w #$05e8+2,d0
add.w d1,d0
move.w d0,(a1)+
move.w #$060C+2,d0
add.w d1,d0
move.w d0,(a1)+
move.w #$0630+2,d0
add.w d1,d0
move.w d0,(a1)+
move.w #$0654+2,d0
add.w d1,d0
move.w d0,(a1)+
move.w #$05e8+3,d0
add.w d1,d0
move.w d0,(a1)+
move.w #$060C+3,d0
add.w d1,d0
move.w d0,(a1)+
move.w #$0630+3,d0
add.w d1,d0
move.w d0,(a1)+
move.w #$0654+3,d0
add.w d1,d0
move.w d0,(a1)+
rts
;==============================================================================;
; clear_fix
; Clears the Fix layer.
clear_fix:
move.w #FIXMAP,LSPC_ADDR
move.l #$500,d0
do
move.w #$00FF,LSPC_DATA
while_dbra d0
rts
;==============================================================================;
; Joypad
; Joypad control routine
Joypad:
;J1
joypad_event INPUT_A,$00,REG_P1CNT
joypad_event INPUT_B,$01,REG_P1CNT
joypad_event INPUT_C,$02,REG_P1CNT
joypad_event INPUT_D,$03,REG_P1CNT
joypad_event INPUT_UP,$04,REG_P1CNT
joypad_event INPUT_DOWN,$05,REG_P1CNT
joypad_event INPUT_LEFT,$06,REG_P1CNT
joypad_event INPUT_RIGHT,$07,REG_P1CNT
;J2
joypad_event INPUT_A,$10,REG_P2CNT
joypad_event INPUT_B,$11,REG_P2CNT
joypad_event INPUT_C,$12,REG_P2CNT
joypad_event INPUT_D,$13,REG_P2CNT
joypad_event INPUT_UP,$14,REG_P2CNT
joypad_event INPUT_DOWN,$15,REG_P2CNT
joypad_event INPUT_LEFT,$16,REG_P2CNT
joypad_event INPUT_RIGHT,$17,REG_P2CNT
rts
Animation:
cmp.w d4,d5
if_eq
clr.w (a0)
clr.w (a1)
move.w d4,(a2)
clr.w d2
clr.w d3
endi
addi.w #1,(a0)
cmp.w d0,d2
if_ne
clr.w (a0)
addi.w #1,(a1)
addi.w #1,d3
endi
clr.w (a3)
cmp.w d1,d3
if_ne
clr.w (a0)
clr.w (a1)
move.w #1,(a3)
endi
rts
Hello_text:
dc.b "Hellod 2",0,0
palette_ng:
dc.w $0f0f,$0eee,$0ddd,$0ccc,$0bbb,$0aaa,$0999,$0888,$010f,$0f00,$00ff,$0f0f,$0f0f,$0f0f,$0f0f,$0000
palette_tile1:
dc.w $5f0f,$2930,$0333,$0310,$7fff,$0ccc,$0888,$0555,$5246,$5479,$769c,$0620,$0830,$2f96,$7fca,$0000
palette_tile2:
dc.w $5f0f,$2930,$0333,$0310,$7fff,$0ccc,$0888,$0555,$5246,$5479,$769c,$7fca,$0830,$2f96,$0620,$0000
palette_scoreboard:
dc.w $5f0f,$0333,$0555,$0888,$2f96,$7fca,$0ccc,$7fff,$0000,$0000,$0000,$0000,$0000,$0000,$0000,$0000
palette_ch1:
dc.w $5f0f,$0a55,$2fa5,$7ffa,$0555,$2aa5,$0500,$0550,$7aaa,$7fff,$75af,$75aa,$0055,$0000,$0000,$0000
;==============================================================================;
include "mvs.asm"
include "VBlank.asm" ; VBlank and IRQ code
include "palette.asm" ; palette related code
;==============================================================================;
include "paldata.inc" ; game palette data
Map1:
include "Map/map1.sng"
;org $80000
| freem/hyperball | src_68k/main.asm | Assembly | mit | 7,052 |
_zombie: file format elf32-i386
Disassembly of section .text:
00000000 <main>:
#include "stat.h"
#include "user.h"
int
main(void)
{
0: 55 push %ebp
1: 89 e5 mov %esp,%ebp
3: 83 e4 f0 and $0xfffffff0,%esp
6: 83 ec 10 sub $0x10,%esp
if(fork() > 0)
9: e8 7d 02 00 00 call 28b <fork>
e: 85 c0 test %eax,%eax
10: 7e 0c jle 1e <main+0x1e>
sleep(5); // Let child exit before parent.
12: c7 04 24 05 00 00 00 movl $0x5,(%esp)
19: e8 05 03 00 00 call 323 <sleep>
exit();
1e: e8 70 02 00 00 call 293 <exit>
00000023 <stosb>:
"cc");
}
static inline void
stosb(void *addr, int data, int cnt)
{
23: 55 push %ebp
24: 89 e5 mov %esp,%ebp
26: 57 push %edi
27: 53 push %ebx
asm volatile("cld; rep stosb" :
28: 8b 4d 08 mov 0x8(%ebp),%ecx
2b: 8b 55 10 mov 0x10(%ebp),%edx
2e: 8b 45 0c mov 0xc(%ebp),%eax
31: 89 cb mov %ecx,%ebx
33: 89 df mov %ebx,%edi
35: 89 d1 mov %edx,%ecx
37: fc cld
38: f3 aa rep stos %al,%es:(%edi)
3a: 89 ca mov %ecx,%edx
3c: 89 fb mov %edi,%ebx
3e: 89 5d 08 mov %ebx,0x8(%ebp)
41: 89 55 10 mov %edx,0x10(%ebp)
"=D" (addr), "=c" (cnt) :
"0" (addr), "1" (cnt), "a" (data) :
"memory", "cc");
}
44: 5b pop %ebx
45: 5f pop %edi
46: 5d pop %ebp
47: c3 ret
00000048 <strcpy>:
#include "user.h"
#include "x86.h"
char*
strcpy(char *s, char *t)
{
48: 55 push %ebp
49: 89 e5 mov %esp,%ebp
4b: 83 ec 10 sub $0x10,%esp
char *os;
os = s;
4e: 8b 45 08 mov 0x8(%ebp),%eax
51: 89 45 fc mov %eax,-0x4(%ebp)
while((*s++ = *t++) != 0)
54: 90 nop
55: 8b 45 08 mov 0x8(%ebp),%eax
58: 8d 50 01 lea 0x1(%eax),%edx
5b: 89 55 08 mov %edx,0x8(%ebp)
5e: 8b 55 0c mov 0xc(%ebp),%edx
61: 8d 4a 01 lea 0x1(%edx),%ecx
64: 89 4d 0c mov %ecx,0xc(%ebp)
67: 0f b6 12 movzbl (%edx),%edx
6a: 88 10 mov %dl,(%eax)
6c: 0f b6 00 movzbl (%eax),%eax
6f: 84 c0 test %al,%al
71: 75 e2 jne 55 <strcpy+0xd>
;
return os;
73: 8b 45 fc mov -0x4(%ebp),%eax
}
76: c9 leave
77: c3 ret
00000078 <strcmp>:
int
strcmp(const char *p, const char *q)
{
78: 55 push %ebp
79: 89 e5 mov %esp,%ebp
while(*p && *p == *q)
7b: eb 08 jmp 85 <strcmp+0xd>
p++, q++;
7d: 83 45 08 01 addl $0x1,0x8(%ebp)
81: 83 45 0c 01 addl $0x1,0xc(%ebp)
}
int
strcmp(const char *p, const char *q)
{
while(*p && *p == *q)
85: 8b 45 08 mov 0x8(%ebp),%eax
88: 0f b6 00 movzbl (%eax),%eax
8b: 84 c0 test %al,%al
8d: 74 10 je 9f <strcmp+0x27>
8f: 8b 45 08 mov 0x8(%ebp),%eax
92: 0f b6 10 movzbl (%eax),%edx
95: 8b 45 0c mov 0xc(%ebp),%eax
98: 0f b6 00 movzbl (%eax),%eax
9b: 38 c2 cmp %al,%dl
9d: 74 de je 7d <strcmp+0x5>
p++, q++;
return (uchar)*p - (uchar)*q;
9f: 8b 45 08 mov 0x8(%ebp),%eax
a2: 0f b6 00 movzbl (%eax),%eax
a5: 0f b6 d0 movzbl %al,%edx
a8: 8b 45 0c mov 0xc(%ebp),%eax
ab: 0f b6 00 movzbl (%eax),%eax
ae: 0f b6 c0 movzbl %al,%eax
b1: 29 c2 sub %eax,%edx
b3: 89 d0 mov %edx,%eax
}
b5: 5d pop %ebp
b6: c3 ret
000000b7 <strlen>:
uint
strlen(char *s)
{
b7: 55 push %ebp
b8: 89 e5 mov %esp,%ebp
ba: 83 ec 10 sub $0x10,%esp
int n;
for(n = 0; s[n]; n++)
bd: c7 45 fc 00 00 00 00 movl $0x0,-0x4(%ebp)
c4: eb 04 jmp ca <strlen+0x13>
c6: 83 45 fc 01 addl $0x1,-0x4(%ebp)
ca: 8b 55 fc mov -0x4(%ebp),%edx
cd: 8b 45 08 mov 0x8(%ebp),%eax
d0: 01 d0 add %edx,%eax
d2: 0f b6 00 movzbl (%eax),%eax
d5: 84 c0 test %al,%al
d7: 75 ed jne c6 <strlen+0xf>
;
return n;
d9: 8b 45 fc mov -0x4(%ebp),%eax
}
dc: c9 leave
dd: c3 ret
000000de <memset>:
void*
memset(void *dst, int c, uint n)
{
de: 55 push %ebp
df: 89 e5 mov %esp,%ebp
e1: 83 ec 0c sub $0xc,%esp
stosb(dst, c, n);
e4: 8b 45 10 mov 0x10(%ebp),%eax
e7: 89 44 24 08 mov %eax,0x8(%esp)
eb: 8b 45 0c mov 0xc(%ebp),%eax
ee: 89 44 24 04 mov %eax,0x4(%esp)
f2: 8b 45 08 mov 0x8(%ebp),%eax
f5: 89 04 24 mov %eax,(%esp)
f8: e8 26 ff ff ff call 23 <stosb>
return dst;
fd: 8b 45 08 mov 0x8(%ebp),%eax
}
100: c9 leave
101: c3 ret
00000102 <strchr>:
char*
strchr(const char *s, char c)
{
102: 55 push %ebp
103: 89 e5 mov %esp,%ebp
105: 83 ec 04 sub $0x4,%esp
108: 8b 45 0c mov 0xc(%ebp),%eax
10b: 88 45 fc mov %al,-0x4(%ebp)
for(; *s; s++)
10e: eb 14 jmp 124 <strchr+0x22>
if(*s == c)
110: 8b 45 08 mov 0x8(%ebp),%eax
113: 0f b6 00 movzbl (%eax),%eax
116: 3a 45 fc cmp -0x4(%ebp),%al
119: 75 05 jne 120 <strchr+0x1e>
return (char*)s;
11b: 8b 45 08 mov 0x8(%ebp),%eax
11e: eb 13 jmp 133 <strchr+0x31>
}
char*
strchr(const char *s, char c)
{
for(; *s; s++)
120: 83 45 08 01 addl $0x1,0x8(%ebp)
124: 8b 45 08 mov 0x8(%ebp),%eax
127: 0f b6 00 movzbl (%eax),%eax
12a: 84 c0 test %al,%al
12c: 75 e2 jne 110 <strchr+0xe>
if(*s == c)
return (char*)s;
return 0;
12e: b8 00 00 00 00 mov $0x0,%eax
}
133: c9 leave
134: c3 ret
00000135 <gets>:
char*
gets(char *buf, int max)
{
135: 55 push %ebp
136: 89 e5 mov %esp,%ebp
138: 83 ec 28 sub $0x28,%esp
int i, cc;
char c;
for(i=0; i+1 < max; ){
13b: c7 45 f4 00 00 00 00 movl $0x0,-0xc(%ebp)
142: eb 4c jmp 190 <gets+0x5b>
cc = read(0, &c, 1);
144: c7 44 24 08 01 00 00 movl $0x1,0x8(%esp)
14b: 00
14c: 8d 45 ef lea -0x11(%ebp),%eax
14f: 89 44 24 04 mov %eax,0x4(%esp)
153: c7 04 24 00 00 00 00 movl $0x0,(%esp)
15a: e8 4c 01 00 00 call 2ab <read>
15f: 89 45 f0 mov %eax,-0x10(%ebp)
if(cc < 1)
162: 83 7d f0 00 cmpl $0x0,-0x10(%ebp)
166: 7f 02 jg 16a <gets+0x35>
break;
168: eb 31 jmp 19b <gets+0x66>
buf[i++] = c;
16a: 8b 45 f4 mov -0xc(%ebp),%eax
16d: 8d 50 01 lea 0x1(%eax),%edx
170: 89 55 f4 mov %edx,-0xc(%ebp)
173: 89 c2 mov %eax,%edx
175: 8b 45 08 mov 0x8(%ebp),%eax
178: 01 c2 add %eax,%edx
17a: 0f b6 45 ef movzbl -0x11(%ebp),%eax
17e: 88 02 mov %al,(%edx)
if(c == '\n' || c == '\r')
180: 0f b6 45 ef movzbl -0x11(%ebp),%eax
184: 3c 0a cmp $0xa,%al
186: 74 13 je 19b <gets+0x66>
188: 0f b6 45 ef movzbl -0x11(%ebp),%eax
18c: 3c 0d cmp $0xd,%al
18e: 74 0b je 19b <gets+0x66>
gets(char *buf, int max)
{
int i, cc;
char c;
for(i=0; i+1 < max; ){
190: 8b 45 f4 mov -0xc(%ebp),%eax
193: 83 c0 01 add $0x1,%eax
196: 3b 45 0c cmp 0xc(%ebp),%eax
199: 7c a9 jl 144 <gets+0xf>
break;
buf[i++] = c;
if(c == '\n' || c == '\r')
break;
}
buf[i] = '\0';
19b: 8b 55 f4 mov -0xc(%ebp),%edx
19e: 8b 45 08 mov 0x8(%ebp),%eax
1a1: 01 d0 add %edx,%eax
1a3: c6 00 00 movb $0x0,(%eax)
return buf;
1a6: 8b 45 08 mov 0x8(%ebp),%eax
}
1a9: c9 leave
1aa: c3 ret
000001ab <stat>:
int
stat(char *n, struct stat *st)
{
1ab: 55 push %ebp
1ac: 89 e5 mov %esp,%ebp
1ae: 83 ec 28 sub $0x28,%esp
int fd;
int r;
fd = open(n, O_RDONLY);
1b1: c7 44 24 04 00 00 00 movl $0x0,0x4(%esp)
1b8: 00
1b9: 8b 45 08 mov 0x8(%ebp),%eax
1bc: 89 04 24 mov %eax,(%esp)
1bf: e8 0f 01 00 00 call 2d3 <open>
1c4: 89 45 f4 mov %eax,-0xc(%ebp)
if(fd < 0)
1c7: 83 7d f4 00 cmpl $0x0,-0xc(%ebp)
1cb: 79 07 jns 1d4 <stat+0x29>
return -1;
1cd: b8 ff ff ff ff mov $0xffffffff,%eax
1d2: eb 23 jmp 1f7 <stat+0x4c>
r = fstat(fd, st);
1d4: 8b 45 0c mov 0xc(%ebp),%eax
1d7: 89 44 24 04 mov %eax,0x4(%esp)
1db: 8b 45 f4 mov -0xc(%ebp),%eax
1de: 89 04 24 mov %eax,(%esp)
1e1: e8 05 01 00 00 call 2eb <fstat>
1e6: 89 45 f0 mov %eax,-0x10(%ebp)
close(fd);
1e9: 8b 45 f4 mov -0xc(%ebp),%eax
1ec: 89 04 24 mov %eax,(%esp)
1ef: e8 c7 00 00 00 call 2bb <close>
return r;
1f4: 8b 45 f0 mov -0x10(%ebp),%eax
}
1f7: c9 leave
1f8: c3 ret
000001f9 <atoi>:
int
atoi(const char *s)
{
1f9: 55 push %ebp
1fa: 89 e5 mov %esp,%ebp
1fc: 83 ec 10 sub $0x10,%esp
int n;
n = 0;
1ff: c7 45 fc 00 00 00 00 movl $0x0,-0x4(%ebp)
while('0' <= *s && *s <= '9')
206: eb 25 jmp 22d <atoi+0x34>
n = n*10 + *s++ - '0';
208: 8b 55 fc mov -0x4(%ebp),%edx
20b: 89 d0 mov %edx,%eax
20d: c1 e0 02 shl $0x2,%eax
210: 01 d0 add %edx,%eax
212: 01 c0 add %eax,%eax
214: 89 c1 mov %eax,%ecx
216: 8b 45 08 mov 0x8(%ebp),%eax
219: 8d 50 01 lea 0x1(%eax),%edx
21c: 89 55 08 mov %edx,0x8(%ebp)
21f: 0f b6 00 movzbl (%eax),%eax
222: 0f be c0 movsbl %al,%eax
225: 01 c8 add %ecx,%eax
227: 83 e8 30 sub $0x30,%eax
22a: 89 45 fc mov %eax,-0x4(%ebp)
atoi(const char *s)
{
int n;
n = 0;
while('0' <= *s && *s <= '9')
22d: 8b 45 08 mov 0x8(%ebp),%eax
230: 0f b6 00 movzbl (%eax),%eax
233: 3c 2f cmp $0x2f,%al
235: 7e 0a jle 241 <atoi+0x48>
237: 8b 45 08 mov 0x8(%ebp),%eax
23a: 0f b6 00 movzbl (%eax),%eax
23d: 3c 39 cmp $0x39,%al
23f: 7e c7 jle 208 <atoi+0xf>
n = n*10 + *s++ - '0';
return n;
241: 8b 45 fc mov -0x4(%ebp),%eax
}
244: c9 leave
245: c3 ret
00000246 <memmove>:
void*
memmove(void *vdst, void *vsrc, int n)
{
246: 55 push %ebp
247: 89 e5 mov %esp,%ebp
249: 83 ec 10 sub $0x10,%esp
char *dst, *src;
dst = vdst;
24c: 8b 45 08 mov 0x8(%ebp),%eax
24f: 89 45 fc mov %eax,-0x4(%ebp)
src = vsrc;
252: 8b 45 0c mov 0xc(%ebp),%eax
255: 89 45 f8 mov %eax,-0x8(%ebp)
while(n-- > 0)
258: eb 17 jmp 271 <memmove+0x2b>
*dst++ = *src++;
25a: 8b 45 fc mov -0x4(%ebp),%eax
25d: 8d 50 01 lea 0x1(%eax),%edx
260: 89 55 fc mov %edx,-0x4(%ebp)
263: 8b 55 f8 mov -0x8(%ebp),%edx
266: 8d 4a 01 lea 0x1(%edx),%ecx
269: 89 4d f8 mov %ecx,-0x8(%ebp)
26c: 0f b6 12 movzbl (%edx),%edx
26f: 88 10 mov %dl,(%eax)
{
char *dst, *src;
dst = vdst;
src = vsrc;
while(n-- > 0)
271: 8b 45 10 mov 0x10(%ebp),%eax
274: 8d 50 ff lea -0x1(%eax),%edx
277: 89 55 10 mov %edx,0x10(%ebp)
27a: 85 c0 test %eax,%eax
27c: 7f dc jg 25a <memmove+0x14>
*dst++ = *src++;
return vdst;
27e: 8b 45 08 mov 0x8(%ebp),%eax
}
281: c9 leave
282: c3 ret
00000283 <getprocs>:
name: \
movl $SYS_ ## name, %eax; \
int $T_SYSCALL; \
ret
SYSCALL(getprocs)
283: b8 16 00 00 00 mov $0x16,%eax
288: cd 40 int $0x40
28a: c3 ret
0000028b <fork>:
SYSCALL(fork)
28b: b8 01 00 00 00 mov $0x1,%eax
290: cd 40 int $0x40
292: c3 ret
00000293 <exit>:
SYSCALL(exit)
293: b8 02 00 00 00 mov $0x2,%eax
298: cd 40 int $0x40
29a: c3 ret
0000029b <wait>:
SYSCALL(wait)
29b: b8 03 00 00 00 mov $0x3,%eax
2a0: cd 40 int $0x40
2a2: c3 ret
000002a3 <pipe>:
SYSCALL(pipe)
2a3: b8 04 00 00 00 mov $0x4,%eax
2a8: cd 40 int $0x40
2aa: c3 ret
000002ab <read>:
SYSCALL(read)
2ab: b8 05 00 00 00 mov $0x5,%eax
2b0: cd 40 int $0x40
2b2: c3 ret
000002b3 <write>:
SYSCALL(write)
2b3: b8 10 00 00 00 mov $0x10,%eax
2b8: cd 40 int $0x40
2ba: c3 ret
000002bb <close>:
SYSCALL(close)
2bb: b8 15 00 00 00 mov $0x15,%eax
2c0: cd 40 int $0x40
2c2: c3 ret
000002c3 <kill>:
SYSCALL(kill)
2c3: b8 06 00 00 00 mov $0x6,%eax
2c8: cd 40 int $0x40
2ca: c3 ret
000002cb <exec>:
SYSCALL(exec)
2cb: b8 07 00 00 00 mov $0x7,%eax
2d0: cd 40 int $0x40
2d2: c3 ret
000002d3 <open>:
SYSCALL(open)
2d3: b8 0f 00 00 00 mov $0xf,%eax
2d8: cd 40 int $0x40
2da: c3 ret
000002db <mknod>:
SYSCALL(mknod)
2db: b8 11 00 00 00 mov $0x11,%eax
2e0: cd 40 int $0x40
2e2: c3 ret
000002e3 <unlink>:
SYSCALL(unlink)
2e3: b8 12 00 00 00 mov $0x12,%eax
2e8: cd 40 int $0x40
2ea: c3 ret
000002eb <fstat>:
SYSCALL(fstat)
2eb: b8 08 00 00 00 mov $0x8,%eax
2f0: cd 40 int $0x40
2f2: c3 ret
000002f3 <link>:
SYSCALL(link)
2f3: b8 13 00 00 00 mov $0x13,%eax
2f8: cd 40 int $0x40
2fa: c3 ret
000002fb <mkdir>:
SYSCALL(mkdir)
2fb: b8 14 00 00 00 mov $0x14,%eax
300: cd 40 int $0x40
302: c3 ret
00000303 <chdir>:
SYSCALL(chdir)
303: b8 09 00 00 00 mov $0x9,%eax
308: cd 40 int $0x40
30a: c3 ret
0000030b <dup>:
SYSCALL(dup)
30b: b8 0a 00 00 00 mov $0xa,%eax
310: cd 40 int $0x40
312: c3 ret
00000313 <getpid>:
SYSCALL(getpid)
313: b8 0b 00 00 00 mov $0xb,%eax
318: cd 40 int $0x40
31a: c3 ret
0000031b <sbrk>:
SYSCALL(sbrk)
31b: b8 0c 00 00 00 mov $0xc,%eax
320: cd 40 int $0x40
322: c3 ret
00000323 <sleep>:
SYSCALL(sleep)
323: b8 0d 00 00 00 mov $0xd,%eax
328: cd 40 int $0x40
32a: c3 ret
0000032b <uptime>:
SYSCALL(uptime)
32b: b8 0e 00 00 00 mov $0xe,%eax
330: cd 40 int $0x40
332: c3 ret
00000333 <putc>:
#include "stat.h"
#include "user.h"
static void
putc(int fd, char c)
{
333: 55 push %ebp
334: 89 e5 mov %esp,%ebp
336: 83 ec 18 sub $0x18,%esp
339: 8b 45 0c mov 0xc(%ebp),%eax
33c: 88 45 f4 mov %al,-0xc(%ebp)
write(fd, &c, 1);
33f: c7 44 24 08 01 00 00 movl $0x1,0x8(%esp)
346: 00
347: 8d 45 f4 lea -0xc(%ebp),%eax
34a: 89 44 24 04 mov %eax,0x4(%esp)
34e: 8b 45 08 mov 0x8(%ebp),%eax
351: 89 04 24 mov %eax,(%esp)
354: e8 5a ff ff ff call 2b3 <write>
}
359: c9 leave
35a: c3 ret
0000035b <printint>:
static void
printint(int fd, int xx, int base, int sgn)
{
35b: 55 push %ebp
35c: 89 e5 mov %esp,%ebp
35e: 56 push %esi
35f: 53 push %ebx
360: 83 ec 30 sub $0x30,%esp
static char digits[] = "0123456789ABCDEF";
char buf[16];
int i, neg;
uint x;
neg = 0;
363: c7 45 f0 00 00 00 00 movl $0x0,-0x10(%ebp)
if(sgn && xx < 0){
36a: 83 7d 14 00 cmpl $0x0,0x14(%ebp)
36e: 74 17 je 387 <printint+0x2c>
370: 83 7d 0c 00 cmpl $0x0,0xc(%ebp)
374: 79 11 jns 387 <printint+0x2c>
neg = 1;
376: c7 45 f0 01 00 00 00 movl $0x1,-0x10(%ebp)
x = -xx;
37d: 8b 45 0c mov 0xc(%ebp),%eax
380: f7 d8 neg %eax
382: 89 45 ec mov %eax,-0x14(%ebp)
385: eb 06 jmp 38d <printint+0x32>
} else {
x = xx;
387: 8b 45 0c mov 0xc(%ebp),%eax
38a: 89 45 ec mov %eax,-0x14(%ebp)
}
i = 0;
38d: c7 45 f4 00 00 00 00 movl $0x0,-0xc(%ebp)
do{
buf[i++] = digits[x % base];
394: 8b 4d f4 mov -0xc(%ebp),%ecx
397: 8d 41 01 lea 0x1(%ecx),%eax
39a: 89 45 f4 mov %eax,-0xc(%ebp)
39d: 8b 5d 10 mov 0x10(%ebp),%ebx
3a0: 8b 45 ec mov -0x14(%ebp),%eax
3a3: ba 00 00 00 00 mov $0x0,%edx
3a8: f7 f3 div %ebx
3aa: 89 d0 mov %edx,%eax
3ac: 0f b6 80 2c 0a 00 00 movzbl 0xa2c(%eax),%eax
3b3: 88 44 0d dc mov %al,-0x24(%ebp,%ecx,1)
}while((x /= base) != 0);
3b7: 8b 75 10 mov 0x10(%ebp),%esi
3ba: 8b 45 ec mov -0x14(%ebp),%eax
3bd: ba 00 00 00 00 mov $0x0,%edx
3c2: f7 f6 div %esi
3c4: 89 45 ec mov %eax,-0x14(%ebp)
3c7: 83 7d ec 00 cmpl $0x0,-0x14(%ebp)
3cb: 75 c7 jne 394 <printint+0x39>
if(neg)
3cd: 83 7d f0 00 cmpl $0x0,-0x10(%ebp)
3d1: 74 10 je 3e3 <printint+0x88>
buf[i++] = '-';
3d3: 8b 45 f4 mov -0xc(%ebp),%eax
3d6: 8d 50 01 lea 0x1(%eax),%edx
3d9: 89 55 f4 mov %edx,-0xc(%ebp)
3dc: c6 44 05 dc 2d movb $0x2d,-0x24(%ebp,%eax,1)
while(--i >= 0)
3e1: eb 1f jmp 402 <printint+0xa7>
3e3: eb 1d jmp 402 <printint+0xa7>
putc(fd, buf[i]);
3e5: 8d 55 dc lea -0x24(%ebp),%edx
3e8: 8b 45 f4 mov -0xc(%ebp),%eax
3eb: 01 d0 add %edx,%eax
3ed: 0f b6 00 movzbl (%eax),%eax
3f0: 0f be c0 movsbl %al,%eax
3f3: 89 44 24 04 mov %eax,0x4(%esp)
3f7: 8b 45 08 mov 0x8(%ebp),%eax
3fa: 89 04 24 mov %eax,(%esp)
3fd: e8 31 ff ff ff call 333 <putc>
buf[i++] = digits[x % base];
}while((x /= base) != 0);
if(neg)
buf[i++] = '-';
while(--i >= 0)
402: 83 6d f4 01 subl $0x1,-0xc(%ebp)
406: 83 7d f4 00 cmpl $0x0,-0xc(%ebp)
40a: 79 d9 jns 3e5 <printint+0x8a>
putc(fd, buf[i]);
}
40c: 83 c4 30 add $0x30,%esp
40f: 5b pop %ebx
410: 5e pop %esi
411: 5d pop %ebp
412: c3 ret
00000413 <printf>:
// Print to the given fd. Only understands %d, %x, %p, %s.
void
printf(int fd, char *fmt, ...)
{
413: 55 push %ebp
414: 89 e5 mov %esp,%ebp
416: 83 ec 38 sub $0x38,%esp
char *s;
int c, i, state;
uint *ap;
state = 0;
419: c7 45 ec 00 00 00 00 movl $0x0,-0x14(%ebp)
ap = (uint*)(void*)&fmt + 1;
420: 8d 45 0c lea 0xc(%ebp),%eax
423: 83 c0 04 add $0x4,%eax
426: 89 45 e8 mov %eax,-0x18(%ebp)
for(i = 0; fmt[i]; i++){
429: c7 45 f0 00 00 00 00 movl $0x0,-0x10(%ebp)
430: e9 7c 01 00 00 jmp 5b1 <printf+0x19e>
c = fmt[i] & 0xff;
435: 8b 55 0c mov 0xc(%ebp),%edx
438: 8b 45 f0 mov -0x10(%ebp),%eax
43b: 01 d0 add %edx,%eax
43d: 0f b6 00 movzbl (%eax),%eax
440: 0f be c0 movsbl %al,%eax
443: 25 ff 00 00 00 and $0xff,%eax
448: 89 45 e4 mov %eax,-0x1c(%ebp)
if(state == 0){
44b: 83 7d ec 00 cmpl $0x0,-0x14(%ebp)
44f: 75 2c jne 47d <printf+0x6a>
if(c == '%'){
451: 83 7d e4 25 cmpl $0x25,-0x1c(%ebp)
455: 75 0c jne 463 <printf+0x50>
state = '%';
457: c7 45 ec 25 00 00 00 movl $0x25,-0x14(%ebp)
45e: e9 4a 01 00 00 jmp 5ad <printf+0x19a>
} else {
putc(fd, c);
463: 8b 45 e4 mov -0x1c(%ebp),%eax
466: 0f be c0 movsbl %al,%eax
469: 89 44 24 04 mov %eax,0x4(%esp)
46d: 8b 45 08 mov 0x8(%ebp),%eax
470: 89 04 24 mov %eax,(%esp)
473: e8 bb fe ff ff call 333 <putc>
478: e9 30 01 00 00 jmp 5ad <printf+0x19a>
}
} else if(state == '%'){
47d: 83 7d ec 25 cmpl $0x25,-0x14(%ebp)
481: 0f 85 26 01 00 00 jne 5ad <printf+0x19a>
if(c == 'd'){
487: 83 7d e4 64 cmpl $0x64,-0x1c(%ebp)
48b: 75 2d jne 4ba <printf+0xa7>
printint(fd, *ap, 10, 1);
48d: 8b 45 e8 mov -0x18(%ebp),%eax
490: 8b 00 mov (%eax),%eax
492: c7 44 24 0c 01 00 00 movl $0x1,0xc(%esp)
499: 00
49a: c7 44 24 08 0a 00 00 movl $0xa,0x8(%esp)
4a1: 00
4a2: 89 44 24 04 mov %eax,0x4(%esp)
4a6: 8b 45 08 mov 0x8(%ebp),%eax
4a9: 89 04 24 mov %eax,(%esp)
4ac: e8 aa fe ff ff call 35b <printint>
ap++;
4b1: 83 45 e8 04 addl $0x4,-0x18(%ebp)
4b5: e9 ec 00 00 00 jmp 5a6 <printf+0x193>
} else if(c == 'x' || c == 'p'){
4ba: 83 7d e4 78 cmpl $0x78,-0x1c(%ebp)
4be: 74 06 je 4c6 <printf+0xb3>
4c0: 83 7d e4 70 cmpl $0x70,-0x1c(%ebp)
4c4: 75 2d jne 4f3 <printf+0xe0>
printint(fd, *ap, 16, 0);
4c6: 8b 45 e8 mov -0x18(%ebp),%eax
4c9: 8b 00 mov (%eax),%eax
4cb: c7 44 24 0c 00 00 00 movl $0x0,0xc(%esp)
4d2: 00
4d3: c7 44 24 08 10 00 00 movl $0x10,0x8(%esp)
4da: 00
4db: 89 44 24 04 mov %eax,0x4(%esp)
4df: 8b 45 08 mov 0x8(%ebp),%eax
4e2: 89 04 24 mov %eax,(%esp)
4e5: e8 71 fe ff ff call 35b <printint>
ap++;
4ea: 83 45 e8 04 addl $0x4,-0x18(%ebp)
4ee: e9 b3 00 00 00 jmp 5a6 <printf+0x193>
} else if(c == 's'){
4f3: 83 7d e4 73 cmpl $0x73,-0x1c(%ebp)
4f7: 75 45 jne 53e <printf+0x12b>
s = (char*)*ap;
4f9: 8b 45 e8 mov -0x18(%ebp),%eax
4fc: 8b 00 mov (%eax),%eax
4fe: 89 45 f4 mov %eax,-0xc(%ebp)
ap++;
501: 83 45 e8 04 addl $0x4,-0x18(%ebp)
if(s == 0)
505: 83 7d f4 00 cmpl $0x0,-0xc(%ebp)
509: 75 09 jne 514 <printf+0x101>
s = "(null)";
50b: c7 45 f4 df 07 00 00 movl $0x7df,-0xc(%ebp)
while(*s != 0){
512: eb 1e jmp 532 <printf+0x11f>
514: eb 1c jmp 532 <printf+0x11f>
putc(fd, *s);
516: 8b 45 f4 mov -0xc(%ebp),%eax
519: 0f b6 00 movzbl (%eax),%eax
51c: 0f be c0 movsbl %al,%eax
51f: 89 44 24 04 mov %eax,0x4(%esp)
523: 8b 45 08 mov 0x8(%ebp),%eax
526: 89 04 24 mov %eax,(%esp)
529: e8 05 fe ff ff call 333 <putc>
s++;
52e: 83 45 f4 01 addl $0x1,-0xc(%ebp)
} else if(c == 's'){
s = (char*)*ap;
ap++;
if(s == 0)
s = "(null)";
while(*s != 0){
532: 8b 45 f4 mov -0xc(%ebp),%eax
535: 0f b6 00 movzbl (%eax),%eax
538: 84 c0 test %al,%al
53a: 75 da jne 516 <printf+0x103>
53c: eb 68 jmp 5a6 <printf+0x193>
putc(fd, *s);
s++;
}
} else if(c == 'c'){
53e: 83 7d e4 63 cmpl $0x63,-0x1c(%ebp)
542: 75 1d jne 561 <printf+0x14e>
putc(fd, *ap);
544: 8b 45 e8 mov -0x18(%ebp),%eax
547: 8b 00 mov (%eax),%eax
549: 0f be c0 movsbl %al,%eax
54c: 89 44 24 04 mov %eax,0x4(%esp)
550: 8b 45 08 mov 0x8(%ebp),%eax
553: 89 04 24 mov %eax,(%esp)
556: e8 d8 fd ff ff call 333 <putc>
ap++;
55b: 83 45 e8 04 addl $0x4,-0x18(%ebp)
55f: eb 45 jmp 5a6 <printf+0x193>
} else if(c == '%'){
561: 83 7d e4 25 cmpl $0x25,-0x1c(%ebp)
565: 75 17 jne 57e <printf+0x16b>
putc(fd, c);
567: 8b 45 e4 mov -0x1c(%ebp),%eax
56a: 0f be c0 movsbl %al,%eax
56d: 89 44 24 04 mov %eax,0x4(%esp)
571: 8b 45 08 mov 0x8(%ebp),%eax
574: 89 04 24 mov %eax,(%esp)
577: e8 b7 fd ff ff call 333 <putc>
57c: eb 28 jmp 5a6 <printf+0x193>
} else {
// Unknown % sequence. Print it to draw attention.
putc(fd, '%');
57e: c7 44 24 04 25 00 00 movl $0x25,0x4(%esp)
585: 00
586: 8b 45 08 mov 0x8(%ebp),%eax
589: 89 04 24 mov %eax,(%esp)
58c: e8 a2 fd ff ff call 333 <putc>
putc(fd, c);
591: 8b 45 e4 mov -0x1c(%ebp),%eax
594: 0f be c0 movsbl %al,%eax
597: 89 44 24 04 mov %eax,0x4(%esp)
59b: 8b 45 08 mov 0x8(%ebp),%eax
59e: 89 04 24 mov %eax,(%esp)
5a1: e8 8d fd ff ff call 333 <putc>
}
state = 0;
5a6: c7 45 ec 00 00 00 00 movl $0x0,-0x14(%ebp)
int c, i, state;
uint *ap;
state = 0;
ap = (uint*)(void*)&fmt + 1;
for(i = 0; fmt[i]; i++){
5ad: 83 45 f0 01 addl $0x1,-0x10(%ebp)
5b1: 8b 55 0c mov 0xc(%ebp),%edx
5b4: 8b 45 f0 mov -0x10(%ebp),%eax
5b7: 01 d0 add %edx,%eax
5b9: 0f b6 00 movzbl (%eax),%eax
5bc: 84 c0 test %al,%al
5be: 0f 85 71 fe ff ff jne 435 <printf+0x22>
putc(fd, c);
}
state = 0;
}
}
}
5c4: c9 leave
5c5: c3 ret
000005c6 <free>:
static Header base;
static Header *freep;
void
free(void *ap)
{
5c6: 55 push %ebp
5c7: 89 e5 mov %esp,%ebp
5c9: 83 ec 10 sub $0x10,%esp
Header *bp, *p;
bp = (Header*)ap - 1;
5cc: 8b 45 08 mov 0x8(%ebp),%eax
5cf: 83 e8 08 sub $0x8,%eax
5d2: 89 45 f8 mov %eax,-0x8(%ebp)
for(p = freep; !(bp > p && bp < p->s.ptr); p = p->s.ptr)
5d5: a1 48 0a 00 00 mov 0xa48,%eax
5da: 89 45 fc mov %eax,-0x4(%ebp)
5dd: eb 24 jmp 603 <free+0x3d>
if(p >= p->s.ptr && (bp > p || bp < p->s.ptr))
5df: 8b 45 fc mov -0x4(%ebp),%eax
5e2: 8b 00 mov (%eax),%eax
5e4: 3b 45 fc cmp -0x4(%ebp),%eax
5e7: 77 12 ja 5fb <free+0x35>
5e9: 8b 45 f8 mov -0x8(%ebp),%eax
5ec: 3b 45 fc cmp -0x4(%ebp),%eax
5ef: 77 24 ja 615 <free+0x4f>
5f1: 8b 45 fc mov -0x4(%ebp),%eax
5f4: 8b 00 mov (%eax),%eax
5f6: 3b 45 f8 cmp -0x8(%ebp),%eax
5f9: 77 1a ja 615 <free+0x4f>
free(void *ap)
{
Header *bp, *p;
bp = (Header*)ap - 1;
for(p = freep; !(bp > p && bp < p->s.ptr); p = p->s.ptr)
5fb: 8b 45 fc mov -0x4(%ebp),%eax
5fe: 8b 00 mov (%eax),%eax
600: 89 45 fc mov %eax,-0x4(%ebp)
603: 8b 45 f8 mov -0x8(%ebp),%eax
606: 3b 45 fc cmp -0x4(%ebp),%eax
609: 76 d4 jbe 5df <free+0x19>
60b: 8b 45 fc mov -0x4(%ebp),%eax
60e: 8b 00 mov (%eax),%eax
610: 3b 45 f8 cmp -0x8(%ebp),%eax
613: 76 ca jbe 5df <free+0x19>
if(p >= p->s.ptr && (bp > p || bp < p->s.ptr))
break;
if(bp + bp->s.size == p->s.ptr){
615: 8b 45 f8 mov -0x8(%ebp),%eax
618: 8b 40 04 mov 0x4(%eax),%eax
61b: 8d 14 c5 00 00 00 00 lea 0x0(,%eax,8),%edx
622: 8b 45 f8 mov -0x8(%ebp),%eax
625: 01 c2 add %eax,%edx
627: 8b 45 fc mov -0x4(%ebp),%eax
62a: 8b 00 mov (%eax),%eax
62c: 39 c2 cmp %eax,%edx
62e: 75 24 jne 654 <free+0x8e>
bp->s.size += p->s.ptr->s.size;
630: 8b 45 f8 mov -0x8(%ebp),%eax
633: 8b 50 04 mov 0x4(%eax),%edx
636: 8b 45 fc mov -0x4(%ebp),%eax
639: 8b 00 mov (%eax),%eax
63b: 8b 40 04 mov 0x4(%eax),%eax
63e: 01 c2 add %eax,%edx
640: 8b 45 f8 mov -0x8(%ebp),%eax
643: 89 50 04 mov %edx,0x4(%eax)
bp->s.ptr = p->s.ptr->s.ptr;
646: 8b 45 fc mov -0x4(%ebp),%eax
649: 8b 00 mov (%eax),%eax
64b: 8b 10 mov (%eax),%edx
64d: 8b 45 f8 mov -0x8(%ebp),%eax
650: 89 10 mov %edx,(%eax)
652: eb 0a jmp 65e <free+0x98>
} else
bp->s.ptr = p->s.ptr;
654: 8b 45 fc mov -0x4(%ebp),%eax
657: 8b 10 mov (%eax),%edx
659: 8b 45 f8 mov -0x8(%ebp),%eax
65c: 89 10 mov %edx,(%eax)
if(p + p->s.size == bp){
65e: 8b 45 fc mov -0x4(%ebp),%eax
661: 8b 40 04 mov 0x4(%eax),%eax
664: 8d 14 c5 00 00 00 00 lea 0x0(,%eax,8),%edx
66b: 8b 45 fc mov -0x4(%ebp),%eax
66e: 01 d0 add %edx,%eax
670: 3b 45 f8 cmp -0x8(%ebp),%eax
673: 75 20 jne 695 <free+0xcf>
p->s.size += bp->s.size;
675: 8b 45 fc mov -0x4(%ebp),%eax
678: 8b 50 04 mov 0x4(%eax),%edx
67b: 8b 45 f8 mov -0x8(%ebp),%eax
67e: 8b 40 04 mov 0x4(%eax),%eax
681: 01 c2 add %eax,%edx
683: 8b 45 fc mov -0x4(%ebp),%eax
686: 89 50 04 mov %edx,0x4(%eax)
p->s.ptr = bp->s.ptr;
689: 8b 45 f8 mov -0x8(%ebp),%eax
68c: 8b 10 mov (%eax),%edx
68e: 8b 45 fc mov -0x4(%ebp),%eax
691: 89 10 mov %edx,(%eax)
693: eb 08 jmp 69d <free+0xd7>
} else
p->s.ptr = bp;
695: 8b 45 fc mov -0x4(%ebp),%eax
698: 8b 55 f8 mov -0x8(%ebp),%edx
69b: 89 10 mov %edx,(%eax)
freep = p;
69d: 8b 45 fc mov -0x4(%ebp),%eax
6a0: a3 48 0a 00 00 mov %eax,0xa48
}
6a5: c9 leave
6a6: c3 ret
000006a7 <morecore>:
static Header*
morecore(uint nu)
{
6a7: 55 push %ebp
6a8: 89 e5 mov %esp,%ebp
6aa: 83 ec 28 sub $0x28,%esp
char *p;
Header *hp;
if(nu < 4096)
6ad: 81 7d 08 ff 0f 00 00 cmpl $0xfff,0x8(%ebp)
6b4: 77 07 ja 6bd <morecore+0x16>
nu = 4096;
6b6: c7 45 08 00 10 00 00 movl $0x1000,0x8(%ebp)
p = sbrk(nu * sizeof(Header));
6bd: 8b 45 08 mov 0x8(%ebp),%eax
6c0: c1 e0 03 shl $0x3,%eax
6c3: 89 04 24 mov %eax,(%esp)
6c6: e8 50 fc ff ff call 31b <sbrk>
6cb: 89 45 f4 mov %eax,-0xc(%ebp)
if(p == (char*)-1)
6ce: 83 7d f4 ff cmpl $0xffffffff,-0xc(%ebp)
6d2: 75 07 jne 6db <morecore+0x34>
return 0;
6d4: b8 00 00 00 00 mov $0x0,%eax
6d9: eb 22 jmp 6fd <morecore+0x56>
hp = (Header*)p;
6db: 8b 45 f4 mov -0xc(%ebp),%eax
6de: 89 45 f0 mov %eax,-0x10(%ebp)
hp->s.size = nu;
6e1: 8b 45 f0 mov -0x10(%ebp),%eax
6e4: 8b 55 08 mov 0x8(%ebp),%edx
6e7: 89 50 04 mov %edx,0x4(%eax)
free((void*)(hp + 1));
6ea: 8b 45 f0 mov -0x10(%ebp),%eax
6ed: 83 c0 08 add $0x8,%eax
6f0: 89 04 24 mov %eax,(%esp)
6f3: e8 ce fe ff ff call 5c6 <free>
return freep;
6f8: a1 48 0a 00 00 mov 0xa48,%eax
}
6fd: c9 leave
6fe: c3 ret
000006ff <malloc>:
void*
malloc(uint nbytes)
{
6ff: 55 push %ebp
700: 89 e5 mov %esp,%ebp
702: 83 ec 28 sub $0x28,%esp
Header *p, *prevp;
uint nunits;
nunits = (nbytes + sizeof(Header) - 1)/sizeof(Header) + 1;
705: 8b 45 08 mov 0x8(%ebp),%eax
708: 83 c0 07 add $0x7,%eax
70b: c1 e8 03 shr $0x3,%eax
70e: 83 c0 01 add $0x1,%eax
711: 89 45 ec mov %eax,-0x14(%ebp)
if((prevp = freep) == 0){
714: a1 48 0a 00 00 mov 0xa48,%eax
719: 89 45 f0 mov %eax,-0x10(%ebp)
71c: 83 7d f0 00 cmpl $0x0,-0x10(%ebp)
720: 75 23 jne 745 <malloc+0x46>
base.s.ptr = freep = prevp = &base;
722: c7 45 f0 40 0a 00 00 movl $0xa40,-0x10(%ebp)
729: 8b 45 f0 mov -0x10(%ebp),%eax
72c: a3 48 0a 00 00 mov %eax,0xa48
731: a1 48 0a 00 00 mov 0xa48,%eax
736: a3 40 0a 00 00 mov %eax,0xa40
base.s.size = 0;
73b: c7 05 44 0a 00 00 00 movl $0x0,0xa44
742: 00 00 00
}
for(p = prevp->s.ptr; ; prevp = p, p = p->s.ptr){
745: 8b 45 f0 mov -0x10(%ebp),%eax
748: 8b 00 mov (%eax),%eax
74a: 89 45 f4 mov %eax,-0xc(%ebp)
if(p->s.size >= nunits){
74d: 8b 45 f4 mov -0xc(%ebp),%eax
750: 8b 40 04 mov 0x4(%eax),%eax
753: 3b 45 ec cmp -0x14(%ebp),%eax
756: 72 4d jb 7a5 <malloc+0xa6>
if(p->s.size == nunits)
758: 8b 45 f4 mov -0xc(%ebp),%eax
75b: 8b 40 04 mov 0x4(%eax),%eax
75e: 3b 45 ec cmp -0x14(%ebp),%eax
761: 75 0c jne 76f <malloc+0x70>
prevp->s.ptr = p->s.ptr;
763: 8b 45 f4 mov -0xc(%ebp),%eax
766: 8b 10 mov (%eax),%edx
768: 8b 45 f0 mov -0x10(%ebp),%eax
76b: 89 10 mov %edx,(%eax)
76d: eb 26 jmp 795 <malloc+0x96>
else {
p->s.size -= nunits;
76f: 8b 45 f4 mov -0xc(%ebp),%eax
772: 8b 40 04 mov 0x4(%eax),%eax
775: 2b 45 ec sub -0x14(%ebp),%eax
778: 89 c2 mov %eax,%edx
77a: 8b 45 f4 mov -0xc(%ebp),%eax
77d: 89 50 04 mov %edx,0x4(%eax)
p += p->s.size;
780: 8b 45 f4 mov -0xc(%ebp),%eax
783: 8b 40 04 mov 0x4(%eax),%eax
786: c1 e0 03 shl $0x3,%eax
789: 01 45 f4 add %eax,-0xc(%ebp)
p->s.size = nunits;
78c: 8b 45 f4 mov -0xc(%ebp),%eax
78f: 8b 55 ec mov -0x14(%ebp),%edx
792: 89 50 04 mov %edx,0x4(%eax)
}
freep = prevp;
795: 8b 45 f0 mov -0x10(%ebp),%eax
798: a3 48 0a 00 00 mov %eax,0xa48
return (void*)(p + 1);
79d: 8b 45 f4 mov -0xc(%ebp),%eax
7a0: 83 c0 08 add $0x8,%eax
7a3: eb 38 jmp 7dd <malloc+0xde>
}
if(p == freep)
7a5: a1 48 0a 00 00 mov 0xa48,%eax
7aa: 39 45 f4 cmp %eax,-0xc(%ebp)
7ad: 75 1b jne 7ca <malloc+0xcb>
if((p = morecore(nunits)) == 0)
7af: 8b 45 ec mov -0x14(%ebp),%eax
7b2: 89 04 24 mov %eax,(%esp)
7b5: e8 ed fe ff ff call 6a7 <morecore>
7ba: 89 45 f4 mov %eax,-0xc(%ebp)
7bd: 83 7d f4 00 cmpl $0x0,-0xc(%ebp)
7c1: 75 07 jne 7ca <malloc+0xcb>
return 0;
7c3: b8 00 00 00 00 mov $0x0,%eax
7c8: eb 13 jmp 7dd <malloc+0xde>
nunits = (nbytes + sizeof(Header) - 1)/sizeof(Header) + 1;
if((prevp = freep) == 0){
base.s.ptr = freep = prevp = &base;
base.s.size = 0;
}
for(p = prevp->s.ptr; ; prevp = p, p = p->s.ptr){
7ca: 8b 45 f4 mov -0xc(%ebp),%eax
7cd: 89 45 f0 mov %eax,-0x10(%ebp)
7d0: 8b 45 f4 mov -0xc(%ebp),%eax
7d3: 8b 00 mov (%eax),%eax
7d5: 89 45 f4 mov %eax,-0xc(%ebp)
return (void*)(p + 1);
}
if(p == freep)
if((p = morecore(nunits)) == 0)
return 0;
}
7d8: e9 70 ff ff ff jmp 74d <malloc+0x4e>
}
7dd: c9 leave
7de: c3 ret
| mcm852/Op-Sys-proj1 | zombie.asm | Assembly | mit | 39,481 |
PAGE ,132
TITLE System utilities, not relying on MS-DOS.
;*****************************************************************************;
; ;
; FILE NAME: PUTCHCOL.ASM ;
; ;
; DESCRIPTION: Routine to display a string with a given color attribute ;
; ;
; NOTES: Uses only BIOS calls to work before DOS is available. ;
; ;
; HISTORY: ;
; 1993/10/07 JFL Separated from alibc.c. ;
; ;
; (c) Copyright 1990-2017 Hewlett Packard Enterprise Development LP ;
; Licensed under the Apache 2.0 license - www.apache.org/licenses/LICENSE-2.0 ;
;*****************************************************************************;
.286
;-----------------------------------------------------------------------------;
; ;
; Globally defined constants ;
; ;
;-----------------------------------------------------------------------------;
include adefine.inc ; All assembly language definitions
;-----------------------------------------------------------------------------;
; ;
; Public routines ;
; ;
;-----------------------------------------------------------------------------;
.code
;=============================================================================;
;
; ENTRY POINT NAME: putch_color
;
; DESCRIPTION: Output a character with a given attribute
;
; INPUT PARAMETERS
; ARG1 Attribute
; ARG2 ASCII code in low byte
;
; OUTPUT PARAMETERS
; None
;
; REGISTERS DESTROYED: AX, BX, CX
;
; REGISTERS PRESERVED: Others
;
; DEPENDENCIES
;
; ALGORITHM USED
; Use video BIOS calls "write character attribute" for printable
; characters, and "write character teletype" for control characters.
;
; NOTES
;
; MODIFICATION HISTORY NOTES
; JFL 90/11/02 Initial implementation.
; JFL 93/10/06 Use the BIOS page variable.
;
;=============================================================================;
CPROC putch_color ; Use color ARG1 to display char. ARG2
push bp
mov bp, sp
push ds
mov ax, seg BDA
mov ds, ax
ASSUME ds:BDA
; Characters 07, 08, 09, 0A and 0D are ascii commands,
; and have no color.
mov al, [bp+ARG2] ; Character
cmp al, 0DH
je write_chartel
cmp al, 07H
jb setch_color
cmp al, 0AH
jbe write_chartel
setch_color:
mov ah, F10_WR_CHARATR
mov al, " " ; Space
mov bh, video_page ; Active video page
mov bl, [bp+ARG1] ; Color
mov cx, 1 ; 1 character
int VIDEO
write_chartel:
mov ah, F10_WR_CHARTEL
mov al, [bp+ARG2] ; Character
mov bh, video_page ; Active video page
mov bl, [bp+ARG1] ; Color
int VIDEO
pop ds
ASSUME ds:@data
pop bp
ret
ENDCPROC putch_color
END
| JFLarvoire/SysToolsLib | C/BiosLib/putchcol.asm | Assembly | apache-2.0 | 2,804 |
ORG RESET
mov a, #100
mov b, #10
call multiply
; at this point, the result of 100*10 = 1000 = 03e8h is stored in registers a and b
; a = e8
; b = 03
jmp $
multiply:
mul ab
ret
| fnaith/notepad_plus_plus_tips | test/function.asm | Assembly | apache-2.0 | 177 |
_cat: file format elf32-i386
Disassembly of section .text:
00000000 <cat>:
char buf[512];
void
cat(int fd)
{
0: 55 push %ebp
1: 89 e5 mov %esp,%ebp
3: 83 ec 28 sub $0x28,%esp
int n;
while((n = read(fd, buf, sizeof(buf))) > 0)
6: eb 1b jmp 23 <cat+0x23>
write(1, buf, n);
8: 8b 45 f4 mov -0xc(%ebp),%eax
b: 89 44 24 08 mov %eax,0x8(%esp)
f: c7 44 24 04 c0 0b 00 movl $0xbc0,0x4(%esp)
16: 00
17: c7 04 24 01 00 00 00 movl $0x1,(%esp)
1e: e8 82 03 00 00 call 3a5 <write>
void
cat(int fd)
{
int n;
while((n = read(fd, buf, sizeof(buf))) > 0)
23: c7 44 24 08 00 02 00 movl $0x200,0x8(%esp)
2a: 00
2b: c7 44 24 04 c0 0b 00 movl $0xbc0,0x4(%esp)
32: 00
33: 8b 45 08 mov 0x8(%ebp),%eax
36: 89 04 24 mov %eax,(%esp)
39: e8 5f 03 00 00 call 39d <read>
3e: 89 45 f4 mov %eax,-0xc(%ebp)
41: 83 7d f4 00 cmpl $0x0,-0xc(%ebp)
45: 7f c1 jg 8 <cat+0x8>
write(1, buf, n);
if(n < 0){
47: 83 7d f4 00 cmpl $0x0,-0xc(%ebp)
4b: 79 19 jns 66 <cat+0x66>
printf(1, "cat: read error\n");
4d: c7 44 24 04 f1 08 00 movl $0x8f1,0x4(%esp)
54: 00
55: c7 04 24 01 00 00 00 movl $0x1,(%esp)
5c: e8 c4 04 00 00 call 525 <printf>
exit();
61: e8 1f 03 00 00 call 385 <exit>
}
}
66: c9 leave
67: c3 ret
00000068 <main>:
int
main(int argc, char *argv[])
{
68: 55 push %ebp
69: 89 e5 mov %esp,%ebp
6b: 83 e4 f0 and $0xfffffff0,%esp
6e: 83 ec 20 sub $0x20,%esp
int fd, i;
if(argc <= 1){
71: 83 7d 08 01 cmpl $0x1,0x8(%ebp)
75: 7f 11 jg 88 <main+0x20>
cat(0);
77: c7 04 24 00 00 00 00 movl $0x0,(%esp)
7e: e8 7d ff ff ff call 0 <cat>
exit();
83: e8 fd 02 00 00 call 385 <exit>
}
for(i = 1; i < argc; i++){
88: c7 44 24 1c 01 00 00 movl $0x1,0x1c(%esp)
8f: 00
90: eb 79 jmp 10b <main+0xa3>
if((fd = open(argv[i], 0)) < 0){
92: 8b 44 24 1c mov 0x1c(%esp),%eax
96: 8d 14 85 00 00 00 00 lea 0x0(,%eax,4),%edx
9d: 8b 45 0c mov 0xc(%ebp),%eax
a0: 01 d0 add %edx,%eax
a2: 8b 00 mov (%eax),%eax
a4: c7 44 24 04 00 00 00 movl $0x0,0x4(%esp)
ab: 00
ac: 89 04 24 mov %eax,(%esp)
af: e8 11 03 00 00 call 3c5 <open>
b4: 89 44 24 18 mov %eax,0x18(%esp)
b8: 83 7c 24 18 00 cmpl $0x0,0x18(%esp)
bd: 79 2f jns ee <main+0x86>
printf(1, "cat: cannot open %s\n", argv[i]);
bf: 8b 44 24 1c mov 0x1c(%esp),%eax
c3: 8d 14 85 00 00 00 00 lea 0x0(,%eax,4),%edx
ca: 8b 45 0c mov 0xc(%ebp),%eax
cd: 01 d0 add %edx,%eax
cf: 8b 00 mov (%eax),%eax
d1: 89 44 24 08 mov %eax,0x8(%esp)
d5: c7 44 24 04 02 09 00 movl $0x902,0x4(%esp)
dc: 00
dd: c7 04 24 01 00 00 00 movl $0x1,(%esp)
e4: e8 3c 04 00 00 call 525 <printf>
exit();
e9: e8 97 02 00 00 call 385 <exit>
}
cat(fd);
ee: 8b 44 24 18 mov 0x18(%esp),%eax
f2: 89 04 24 mov %eax,(%esp)
f5: e8 06 ff ff ff call 0 <cat>
close(fd);
fa: 8b 44 24 18 mov 0x18(%esp),%eax
fe: 89 04 24 mov %eax,(%esp)
101: e8 a7 02 00 00 call 3ad <close>
if(argc <= 1){
cat(0);
exit();
}
for(i = 1; i < argc; i++){
106: 83 44 24 1c 01 addl $0x1,0x1c(%esp)
10b: 8b 44 24 1c mov 0x1c(%esp),%eax
10f: 3b 45 08 cmp 0x8(%ebp),%eax
112: 0f 8c 7a ff ff ff jl 92 <main+0x2a>
exit();
}
cat(fd);
close(fd);
}
exit();
118: e8 68 02 00 00 call 385 <exit>
0000011d <stosb>:
"cc");
}
static inline void
stosb(void *addr, int data, int cnt)
{
11d: 55 push %ebp
11e: 89 e5 mov %esp,%ebp
120: 57 push %edi
121: 53 push %ebx
asm volatile("cld; rep stosb" :
122: 8b 4d 08 mov 0x8(%ebp),%ecx
125: 8b 55 10 mov 0x10(%ebp),%edx
128: 8b 45 0c mov 0xc(%ebp),%eax
12b: 89 cb mov %ecx,%ebx
12d: 89 df mov %ebx,%edi
12f: 89 d1 mov %edx,%ecx
131: fc cld
132: f3 aa rep stos %al,%es:(%edi)
134: 89 ca mov %ecx,%edx
136: 89 fb mov %edi,%ebx
138: 89 5d 08 mov %ebx,0x8(%ebp)
13b: 89 55 10 mov %edx,0x10(%ebp)
"=D" (addr), "=c" (cnt) :
"0" (addr), "1" (cnt), "a" (data) :
"memory", "cc");
}
13e: 5b pop %ebx
13f: 5f pop %edi
140: 5d pop %ebp
141: c3 ret
00000142 <strcpy>:
#include "user.h"
#include "x86.h"
char*
strcpy(char *s, char *t)
{
142: 55 push %ebp
143: 89 e5 mov %esp,%ebp
145: 83 ec 10 sub $0x10,%esp
char *os;
os = s;
148: 8b 45 08 mov 0x8(%ebp),%eax
14b: 89 45 fc mov %eax,-0x4(%ebp)
while((*s++ = *t++) != 0)
14e: 90 nop
14f: 8b 45 08 mov 0x8(%ebp),%eax
152: 8d 50 01 lea 0x1(%eax),%edx
155: 89 55 08 mov %edx,0x8(%ebp)
158: 8b 55 0c mov 0xc(%ebp),%edx
15b: 8d 4a 01 lea 0x1(%edx),%ecx
15e: 89 4d 0c mov %ecx,0xc(%ebp)
161: 0f b6 12 movzbl (%edx),%edx
164: 88 10 mov %dl,(%eax)
166: 0f b6 00 movzbl (%eax),%eax
169: 84 c0 test %al,%al
16b: 75 e2 jne 14f <strcpy+0xd>
;
return os;
16d: 8b 45 fc mov -0x4(%ebp),%eax
}
170: c9 leave
171: c3 ret
00000172 <strcmp>:
int
strcmp(const char *p, const char *q)
{
172: 55 push %ebp
173: 89 e5 mov %esp,%ebp
while(*p && *p == *q)
175: eb 08 jmp 17f <strcmp+0xd>
p++, q++;
177: 83 45 08 01 addl $0x1,0x8(%ebp)
17b: 83 45 0c 01 addl $0x1,0xc(%ebp)
}
int
strcmp(const char *p, const char *q)
{
while(*p && *p == *q)
17f: 8b 45 08 mov 0x8(%ebp),%eax
182: 0f b6 00 movzbl (%eax),%eax
185: 84 c0 test %al,%al
187: 74 10 je 199 <strcmp+0x27>
189: 8b 45 08 mov 0x8(%ebp),%eax
18c: 0f b6 10 movzbl (%eax),%edx
18f: 8b 45 0c mov 0xc(%ebp),%eax
192: 0f b6 00 movzbl (%eax),%eax
195: 38 c2 cmp %al,%dl
197: 74 de je 177 <strcmp+0x5>
p++, q++;
return (uchar)*p - (uchar)*q;
199: 8b 45 08 mov 0x8(%ebp),%eax
19c: 0f b6 00 movzbl (%eax),%eax
19f: 0f b6 d0 movzbl %al,%edx
1a2: 8b 45 0c mov 0xc(%ebp),%eax
1a5: 0f b6 00 movzbl (%eax),%eax
1a8: 0f b6 c0 movzbl %al,%eax
1ab: 29 c2 sub %eax,%edx
1ad: 89 d0 mov %edx,%eax
}
1af: 5d pop %ebp
1b0: c3 ret
000001b1 <strlen>:
uint
strlen(char *s)
{
1b1: 55 push %ebp
1b2: 89 e5 mov %esp,%ebp
1b4: 83 ec 10 sub $0x10,%esp
int n;
for(n = 0; s[n]; n++)
1b7: c7 45 fc 00 00 00 00 movl $0x0,-0x4(%ebp)
1be: eb 04 jmp 1c4 <strlen+0x13>
1c0: 83 45 fc 01 addl $0x1,-0x4(%ebp)
1c4: 8b 55 fc mov -0x4(%ebp),%edx
1c7: 8b 45 08 mov 0x8(%ebp),%eax
1ca: 01 d0 add %edx,%eax
1cc: 0f b6 00 movzbl (%eax),%eax
1cf: 84 c0 test %al,%al
1d1: 75 ed jne 1c0 <strlen+0xf>
;
return n;
1d3: 8b 45 fc mov -0x4(%ebp),%eax
}
1d6: c9 leave
1d7: c3 ret
000001d8 <memset>:
void*
memset(void *dst, int c, uint n)
{
1d8: 55 push %ebp
1d9: 89 e5 mov %esp,%ebp
1db: 83 ec 0c sub $0xc,%esp
stosb(dst, c, n);
1de: 8b 45 10 mov 0x10(%ebp),%eax
1e1: 89 44 24 08 mov %eax,0x8(%esp)
1e5: 8b 45 0c mov 0xc(%ebp),%eax
1e8: 89 44 24 04 mov %eax,0x4(%esp)
1ec: 8b 45 08 mov 0x8(%ebp),%eax
1ef: 89 04 24 mov %eax,(%esp)
1f2: e8 26 ff ff ff call 11d <stosb>
return dst;
1f7: 8b 45 08 mov 0x8(%ebp),%eax
}
1fa: c9 leave
1fb: c3 ret
000001fc <strchr>:
char*
strchr(const char *s, char c)
{
1fc: 55 push %ebp
1fd: 89 e5 mov %esp,%ebp
1ff: 83 ec 04 sub $0x4,%esp
202: 8b 45 0c mov 0xc(%ebp),%eax
205: 88 45 fc mov %al,-0x4(%ebp)
for(; *s; s++)
208: eb 14 jmp 21e <strchr+0x22>
if(*s == c)
20a: 8b 45 08 mov 0x8(%ebp),%eax
20d: 0f b6 00 movzbl (%eax),%eax
210: 3a 45 fc cmp -0x4(%ebp),%al
213: 75 05 jne 21a <strchr+0x1e>
return (char*)s;
215: 8b 45 08 mov 0x8(%ebp),%eax
218: eb 13 jmp 22d <strchr+0x31>
}
char*
strchr(const char *s, char c)
{
for(; *s; s++)
21a: 83 45 08 01 addl $0x1,0x8(%ebp)
21e: 8b 45 08 mov 0x8(%ebp),%eax
221: 0f b6 00 movzbl (%eax),%eax
224: 84 c0 test %al,%al
226: 75 e2 jne 20a <strchr+0xe>
if(*s == c)
return (char*)s;
return 0;
228: b8 00 00 00 00 mov $0x0,%eax
}
22d: c9 leave
22e: c3 ret
0000022f <gets>:
char*
gets(char *buf, int max)
{
22f: 55 push %ebp
230: 89 e5 mov %esp,%ebp
232: 83 ec 28 sub $0x28,%esp
int i, cc;
char c;
for(i=0; i+1 < max; ){
235: c7 45 f4 00 00 00 00 movl $0x0,-0xc(%ebp)
23c: eb 4c jmp 28a <gets+0x5b>
cc = read(0, &c, 1);
23e: c7 44 24 08 01 00 00 movl $0x1,0x8(%esp)
245: 00
246: 8d 45 ef lea -0x11(%ebp),%eax
249: 89 44 24 04 mov %eax,0x4(%esp)
24d: c7 04 24 00 00 00 00 movl $0x0,(%esp)
254: e8 44 01 00 00 call 39d <read>
259: 89 45 f0 mov %eax,-0x10(%ebp)
if(cc < 1)
25c: 83 7d f0 00 cmpl $0x0,-0x10(%ebp)
260: 7f 02 jg 264 <gets+0x35>
break;
262: eb 31 jmp 295 <gets+0x66>
buf[i++] = c;
264: 8b 45 f4 mov -0xc(%ebp),%eax
267: 8d 50 01 lea 0x1(%eax),%edx
26a: 89 55 f4 mov %edx,-0xc(%ebp)
26d: 89 c2 mov %eax,%edx
26f: 8b 45 08 mov 0x8(%ebp),%eax
272: 01 c2 add %eax,%edx
274: 0f b6 45 ef movzbl -0x11(%ebp),%eax
278: 88 02 mov %al,(%edx)
if(c == '\n' || c == '\r')
27a: 0f b6 45 ef movzbl -0x11(%ebp),%eax
27e: 3c 0a cmp $0xa,%al
280: 74 13 je 295 <gets+0x66>
282: 0f b6 45 ef movzbl -0x11(%ebp),%eax
286: 3c 0d cmp $0xd,%al
288: 74 0b je 295 <gets+0x66>
gets(char *buf, int max)
{
int i, cc;
char c;
for(i=0; i+1 < max; ){
28a: 8b 45 f4 mov -0xc(%ebp),%eax
28d: 83 c0 01 add $0x1,%eax
290: 3b 45 0c cmp 0xc(%ebp),%eax
293: 7c a9 jl 23e <gets+0xf>
break;
buf[i++] = c;
if(c == '\n' || c == '\r')
break;
}
buf[i] = '\0';
295: 8b 55 f4 mov -0xc(%ebp),%edx
298: 8b 45 08 mov 0x8(%ebp),%eax
29b: 01 d0 add %edx,%eax
29d: c6 00 00 movb $0x0,(%eax)
return buf;
2a0: 8b 45 08 mov 0x8(%ebp),%eax
}
2a3: c9 leave
2a4: c3 ret
000002a5 <stat>:
int
stat(char *n, struct stat *st)
{
2a5: 55 push %ebp
2a6: 89 e5 mov %esp,%ebp
2a8: 83 ec 28 sub $0x28,%esp
int fd;
int r;
fd = open(n, O_RDONLY);
2ab: c7 44 24 04 00 00 00 movl $0x0,0x4(%esp)
2b2: 00
2b3: 8b 45 08 mov 0x8(%ebp),%eax
2b6: 89 04 24 mov %eax,(%esp)
2b9: e8 07 01 00 00 call 3c5 <open>
2be: 89 45 f4 mov %eax,-0xc(%ebp)
if(fd < 0)
2c1: 83 7d f4 00 cmpl $0x0,-0xc(%ebp)
2c5: 79 07 jns 2ce <stat+0x29>
return -1;
2c7: b8 ff ff ff ff mov $0xffffffff,%eax
2cc: eb 23 jmp 2f1 <stat+0x4c>
r = fstat(fd, st);
2ce: 8b 45 0c mov 0xc(%ebp),%eax
2d1: 89 44 24 04 mov %eax,0x4(%esp)
2d5: 8b 45 f4 mov -0xc(%ebp),%eax
2d8: 89 04 24 mov %eax,(%esp)
2db: e8 fd 00 00 00 call 3dd <fstat>
2e0: 89 45 f0 mov %eax,-0x10(%ebp)
close(fd);
2e3: 8b 45 f4 mov -0xc(%ebp),%eax
2e6: 89 04 24 mov %eax,(%esp)
2e9: e8 bf 00 00 00 call 3ad <close>
return r;
2ee: 8b 45 f0 mov -0x10(%ebp),%eax
}
2f1: c9 leave
2f2: c3 ret
000002f3 <atoi>:
int
atoi(const char *s)
{
2f3: 55 push %ebp
2f4: 89 e5 mov %esp,%ebp
2f6: 83 ec 10 sub $0x10,%esp
int n;
n = 0;
2f9: c7 45 fc 00 00 00 00 movl $0x0,-0x4(%ebp)
while('0' <= *s && *s <= '9')
300: eb 25 jmp 327 <atoi+0x34>
n = n*10 + *s++ - '0';
302: 8b 55 fc mov -0x4(%ebp),%edx
305: 89 d0 mov %edx,%eax
307: c1 e0 02 shl $0x2,%eax
30a: 01 d0 add %edx,%eax
30c: 01 c0 add %eax,%eax
30e: 89 c1 mov %eax,%ecx
310: 8b 45 08 mov 0x8(%ebp),%eax
313: 8d 50 01 lea 0x1(%eax),%edx
316: 89 55 08 mov %edx,0x8(%ebp)
319: 0f b6 00 movzbl (%eax),%eax
31c: 0f be c0 movsbl %al,%eax
31f: 01 c8 add %ecx,%eax
321: 83 e8 30 sub $0x30,%eax
324: 89 45 fc mov %eax,-0x4(%ebp)
atoi(const char *s)
{
int n;
n = 0;
while('0' <= *s && *s <= '9')
327: 8b 45 08 mov 0x8(%ebp),%eax
32a: 0f b6 00 movzbl (%eax),%eax
32d: 3c 2f cmp $0x2f,%al
32f: 7e 0a jle 33b <atoi+0x48>
331: 8b 45 08 mov 0x8(%ebp),%eax
334: 0f b6 00 movzbl (%eax),%eax
337: 3c 39 cmp $0x39,%al
339: 7e c7 jle 302 <atoi+0xf>
n = n*10 + *s++ - '0';
return n;
33b: 8b 45 fc mov -0x4(%ebp),%eax
}
33e: c9 leave
33f: c3 ret
00000340 <memmove>:
void*
memmove(void *vdst, void *vsrc, int n)
{
340: 55 push %ebp
341: 89 e5 mov %esp,%ebp
343: 83 ec 10 sub $0x10,%esp
char *dst, *src;
dst = vdst;
346: 8b 45 08 mov 0x8(%ebp),%eax
349: 89 45 fc mov %eax,-0x4(%ebp)
src = vsrc;
34c: 8b 45 0c mov 0xc(%ebp),%eax
34f: 89 45 f8 mov %eax,-0x8(%ebp)
while(n-- > 0)
352: eb 17 jmp 36b <memmove+0x2b>
*dst++ = *src++;
354: 8b 45 fc mov -0x4(%ebp),%eax
357: 8d 50 01 lea 0x1(%eax),%edx
35a: 89 55 fc mov %edx,-0x4(%ebp)
35d: 8b 55 f8 mov -0x8(%ebp),%edx
360: 8d 4a 01 lea 0x1(%edx),%ecx
363: 89 4d f8 mov %ecx,-0x8(%ebp)
366: 0f b6 12 movzbl (%edx),%edx
369: 88 10 mov %dl,(%eax)
{
char *dst, *src;
dst = vdst;
src = vsrc;
while(n-- > 0)
36b: 8b 45 10 mov 0x10(%ebp),%eax
36e: 8d 50 ff lea -0x1(%eax),%edx
371: 89 55 10 mov %edx,0x10(%ebp)
374: 85 c0 test %eax,%eax
376: 7f dc jg 354 <memmove+0x14>
*dst++ = *src++;
return vdst;
378: 8b 45 08 mov 0x8(%ebp),%eax
}
37b: c9 leave
37c: c3 ret
0000037d <fork>:
name: \
movl $SYS_ ## name, %eax; \
int $T_SYSCALL; \
ret
SYSCALL(fork)
37d: b8 01 00 00 00 mov $0x1,%eax
382: cd 40 int $0x40
384: c3 ret
00000385 <exit>:
SYSCALL(exit)
385: b8 02 00 00 00 mov $0x2,%eax
38a: cd 40 int $0x40
38c: c3 ret
0000038d <wait>:
SYSCALL(wait)
38d: b8 03 00 00 00 mov $0x3,%eax
392: cd 40 int $0x40
394: c3 ret
00000395 <pipe>:
SYSCALL(pipe)
395: b8 04 00 00 00 mov $0x4,%eax
39a: cd 40 int $0x40
39c: c3 ret
0000039d <read>:
SYSCALL(read)
39d: b8 05 00 00 00 mov $0x5,%eax
3a2: cd 40 int $0x40
3a4: c3 ret
000003a5 <write>:
SYSCALL(write)
3a5: b8 10 00 00 00 mov $0x10,%eax
3aa: cd 40 int $0x40
3ac: c3 ret
000003ad <close>:
SYSCALL(close)
3ad: b8 15 00 00 00 mov $0x15,%eax
3b2: cd 40 int $0x40
3b4: c3 ret
000003b5 <kill>:
SYSCALL(kill)
3b5: b8 06 00 00 00 mov $0x6,%eax
3ba: cd 40 int $0x40
3bc: c3 ret
000003bd <exec>:
SYSCALL(exec)
3bd: b8 07 00 00 00 mov $0x7,%eax
3c2: cd 40 int $0x40
3c4: c3 ret
000003c5 <open>:
SYSCALL(open)
3c5: b8 0f 00 00 00 mov $0xf,%eax
3ca: cd 40 int $0x40
3cc: c3 ret
000003cd <mknod>:
SYSCALL(mknod)
3cd: b8 11 00 00 00 mov $0x11,%eax
3d2: cd 40 int $0x40
3d4: c3 ret
000003d5 <unlink>:
SYSCALL(unlink)
3d5: b8 12 00 00 00 mov $0x12,%eax
3da: cd 40 int $0x40
3dc: c3 ret
000003dd <fstat>:
SYSCALL(fstat)
3dd: b8 08 00 00 00 mov $0x8,%eax
3e2: cd 40 int $0x40
3e4: c3 ret
000003e5 <link>:
SYSCALL(link)
3e5: b8 13 00 00 00 mov $0x13,%eax
3ea: cd 40 int $0x40
3ec: c3 ret
000003ed <mkdir>:
SYSCALL(mkdir)
3ed: b8 14 00 00 00 mov $0x14,%eax
3f2: cd 40 int $0x40
3f4: c3 ret
000003f5 <chdir>:
SYSCALL(chdir)
3f5: b8 09 00 00 00 mov $0x9,%eax
3fa: cd 40 int $0x40
3fc: c3 ret
000003fd <dup>:
SYSCALL(dup)
3fd: b8 0a 00 00 00 mov $0xa,%eax
402: cd 40 int $0x40
404: c3 ret
00000405 <getpid>:
SYSCALL(getpid)
405: b8 0b 00 00 00 mov $0xb,%eax
40a: cd 40 int $0x40
40c: c3 ret
0000040d <sbrk>:
SYSCALL(sbrk)
40d: b8 0c 00 00 00 mov $0xc,%eax
412: cd 40 int $0x40
414: c3 ret
00000415 <sleep>:
SYSCALL(sleep)
415: b8 0d 00 00 00 mov $0xd,%eax
41a: cd 40 int $0x40
41c: c3 ret
0000041d <uptime>:
SYSCALL(uptime)
41d: b8 0e 00 00 00 mov $0xe,%eax
422: cd 40 int $0x40
424: c3 ret
00000425 <sigset>:
SYSCALL(sigset)
425: b8 16 00 00 00 mov $0x16,%eax
42a: cd 40 int $0x40
42c: c3 ret
0000042d <sigsend>:
SYSCALL(sigsend)
42d: b8 17 00 00 00 mov $0x17,%eax
432: cd 40 int $0x40
434: c3 ret
00000435 <sigret>:
SYSCALL(sigret)
435: b8 18 00 00 00 mov $0x18,%eax
43a: cd 40 int $0x40
43c: c3 ret
0000043d <sigpause>:
43d: b8 19 00 00 00 mov $0x19,%eax
442: cd 40 int $0x40
444: c3 ret
00000445 <putc>:
#include "stat.h"
#include "user.h"
static void
putc(int fd, char c)
{
445: 55 push %ebp
446: 89 e5 mov %esp,%ebp
448: 83 ec 18 sub $0x18,%esp
44b: 8b 45 0c mov 0xc(%ebp),%eax
44e: 88 45 f4 mov %al,-0xc(%ebp)
write(fd, &c, 1);
451: c7 44 24 08 01 00 00 movl $0x1,0x8(%esp)
458: 00
459: 8d 45 f4 lea -0xc(%ebp),%eax
45c: 89 44 24 04 mov %eax,0x4(%esp)
460: 8b 45 08 mov 0x8(%ebp),%eax
463: 89 04 24 mov %eax,(%esp)
466: e8 3a ff ff ff call 3a5 <write>
}
46b: c9 leave
46c: c3 ret
0000046d <printint>:
static void
printint(int fd, int xx, int base, int sgn)
{
46d: 55 push %ebp
46e: 89 e5 mov %esp,%ebp
470: 56 push %esi
471: 53 push %ebx
472: 83 ec 30 sub $0x30,%esp
static char digits[] = "0123456789ABCDEF";
char buf[16];
int i, neg;
uint x;
neg = 0;
475: c7 45 f0 00 00 00 00 movl $0x0,-0x10(%ebp)
if(sgn && xx < 0){
47c: 83 7d 14 00 cmpl $0x0,0x14(%ebp)
480: 74 17 je 499 <printint+0x2c>
482: 83 7d 0c 00 cmpl $0x0,0xc(%ebp)
486: 79 11 jns 499 <printint+0x2c>
neg = 1;
488: c7 45 f0 01 00 00 00 movl $0x1,-0x10(%ebp)
x = -xx;
48f: 8b 45 0c mov 0xc(%ebp),%eax
492: f7 d8 neg %eax
494: 89 45 ec mov %eax,-0x14(%ebp)
497: eb 06 jmp 49f <printint+0x32>
} else {
x = xx;
499: 8b 45 0c mov 0xc(%ebp),%eax
49c: 89 45 ec mov %eax,-0x14(%ebp)
}
i = 0;
49f: c7 45 f4 00 00 00 00 movl $0x0,-0xc(%ebp)
do{
buf[i++] = digits[x % base];
4a6: 8b 4d f4 mov -0xc(%ebp),%ecx
4a9: 8d 41 01 lea 0x1(%ecx),%eax
4ac: 89 45 f4 mov %eax,-0xc(%ebp)
4af: 8b 5d 10 mov 0x10(%ebp),%ebx
4b2: 8b 45 ec mov -0x14(%ebp),%eax
4b5: ba 00 00 00 00 mov $0x0,%edx
4ba: f7 f3 div %ebx
4bc: 89 d0 mov %edx,%eax
4be: 0f b6 80 84 0b 00 00 movzbl 0xb84(%eax),%eax
4c5: 88 44 0d dc mov %al,-0x24(%ebp,%ecx,1)
}while((x /= base) != 0);
4c9: 8b 75 10 mov 0x10(%ebp),%esi
4cc: 8b 45 ec mov -0x14(%ebp),%eax
4cf: ba 00 00 00 00 mov $0x0,%edx
4d4: f7 f6 div %esi
4d6: 89 45 ec mov %eax,-0x14(%ebp)
4d9: 83 7d ec 00 cmpl $0x0,-0x14(%ebp)
4dd: 75 c7 jne 4a6 <printint+0x39>
if(neg)
4df: 83 7d f0 00 cmpl $0x0,-0x10(%ebp)
4e3: 74 10 je 4f5 <printint+0x88>
buf[i++] = '-';
4e5: 8b 45 f4 mov -0xc(%ebp),%eax
4e8: 8d 50 01 lea 0x1(%eax),%edx
4eb: 89 55 f4 mov %edx,-0xc(%ebp)
4ee: c6 44 05 dc 2d movb $0x2d,-0x24(%ebp,%eax,1)
while(--i >= 0)
4f3: eb 1f jmp 514 <printint+0xa7>
4f5: eb 1d jmp 514 <printint+0xa7>
putc(fd, buf[i]);
4f7: 8d 55 dc lea -0x24(%ebp),%edx
4fa: 8b 45 f4 mov -0xc(%ebp),%eax
4fd: 01 d0 add %edx,%eax
4ff: 0f b6 00 movzbl (%eax),%eax
502: 0f be c0 movsbl %al,%eax
505: 89 44 24 04 mov %eax,0x4(%esp)
509: 8b 45 08 mov 0x8(%ebp),%eax
50c: 89 04 24 mov %eax,(%esp)
50f: e8 31 ff ff ff call 445 <putc>
buf[i++] = digits[x % base];
}while((x /= base) != 0);
if(neg)
buf[i++] = '-';
while(--i >= 0)
514: 83 6d f4 01 subl $0x1,-0xc(%ebp)
518: 83 7d f4 00 cmpl $0x0,-0xc(%ebp)
51c: 79 d9 jns 4f7 <printint+0x8a>
putc(fd, buf[i]);
}
51e: 83 c4 30 add $0x30,%esp
521: 5b pop %ebx
522: 5e pop %esi
523: 5d pop %ebp
524: c3 ret
00000525 <printf>:
// Print to the given fd. Only understands %d, %x, %p, %s.
void
printf(int fd, char *fmt, ...)
{
525: 55 push %ebp
526: 89 e5 mov %esp,%ebp
528: 83 ec 38 sub $0x38,%esp
char *s;
int c, i, state;
uint *ap;
state = 0;
52b: c7 45 ec 00 00 00 00 movl $0x0,-0x14(%ebp)
ap = (uint*)(void*)&fmt + 1;
532: 8d 45 0c lea 0xc(%ebp),%eax
535: 83 c0 04 add $0x4,%eax
538: 89 45 e8 mov %eax,-0x18(%ebp)
for(i = 0; fmt[i]; i++){
53b: c7 45 f0 00 00 00 00 movl $0x0,-0x10(%ebp)
542: e9 7c 01 00 00 jmp 6c3 <printf+0x19e>
c = fmt[i] & 0xff;
547: 8b 55 0c mov 0xc(%ebp),%edx
54a: 8b 45 f0 mov -0x10(%ebp),%eax
54d: 01 d0 add %edx,%eax
54f: 0f b6 00 movzbl (%eax),%eax
552: 0f be c0 movsbl %al,%eax
555: 25 ff 00 00 00 and $0xff,%eax
55a: 89 45 e4 mov %eax,-0x1c(%ebp)
if(state == 0){
55d: 83 7d ec 00 cmpl $0x0,-0x14(%ebp)
561: 75 2c jne 58f <printf+0x6a>
if(c == '%'){
563: 83 7d e4 25 cmpl $0x25,-0x1c(%ebp)
567: 75 0c jne 575 <printf+0x50>
state = '%';
569: c7 45 ec 25 00 00 00 movl $0x25,-0x14(%ebp)
570: e9 4a 01 00 00 jmp 6bf <printf+0x19a>
} else {
putc(fd, c);
575: 8b 45 e4 mov -0x1c(%ebp),%eax
578: 0f be c0 movsbl %al,%eax
57b: 89 44 24 04 mov %eax,0x4(%esp)
57f: 8b 45 08 mov 0x8(%ebp),%eax
582: 89 04 24 mov %eax,(%esp)
585: e8 bb fe ff ff call 445 <putc>
58a: e9 30 01 00 00 jmp 6bf <printf+0x19a>
}
} else if(state == '%'){
58f: 83 7d ec 25 cmpl $0x25,-0x14(%ebp)
593: 0f 85 26 01 00 00 jne 6bf <printf+0x19a>
if(c == 'd'){
599: 83 7d e4 64 cmpl $0x64,-0x1c(%ebp)
59d: 75 2d jne 5cc <printf+0xa7>
printint(fd, *ap, 10, 1);
59f: 8b 45 e8 mov -0x18(%ebp),%eax
5a2: 8b 00 mov (%eax),%eax
5a4: c7 44 24 0c 01 00 00 movl $0x1,0xc(%esp)
5ab: 00
5ac: c7 44 24 08 0a 00 00 movl $0xa,0x8(%esp)
5b3: 00
5b4: 89 44 24 04 mov %eax,0x4(%esp)
5b8: 8b 45 08 mov 0x8(%ebp),%eax
5bb: 89 04 24 mov %eax,(%esp)
5be: e8 aa fe ff ff call 46d <printint>
ap++;
5c3: 83 45 e8 04 addl $0x4,-0x18(%ebp)
5c7: e9 ec 00 00 00 jmp 6b8 <printf+0x193>
} else if(c == 'x' || c == 'p'){
5cc: 83 7d e4 78 cmpl $0x78,-0x1c(%ebp)
5d0: 74 06 je 5d8 <printf+0xb3>
5d2: 83 7d e4 70 cmpl $0x70,-0x1c(%ebp)
5d6: 75 2d jne 605 <printf+0xe0>
printint(fd, *ap, 16, 0);
5d8: 8b 45 e8 mov -0x18(%ebp),%eax
5db: 8b 00 mov (%eax),%eax
5dd: c7 44 24 0c 00 00 00 movl $0x0,0xc(%esp)
5e4: 00
5e5: c7 44 24 08 10 00 00 movl $0x10,0x8(%esp)
5ec: 00
5ed: 89 44 24 04 mov %eax,0x4(%esp)
5f1: 8b 45 08 mov 0x8(%ebp),%eax
5f4: 89 04 24 mov %eax,(%esp)
5f7: e8 71 fe ff ff call 46d <printint>
ap++;
5fc: 83 45 e8 04 addl $0x4,-0x18(%ebp)
600: e9 b3 00 00 00 jmp 6b8 <printf+0x193>
} else if(c == 's'){
605: 83 7d e4 73 cmpl $0x73,-0x1c(%ebp)
609: 75 45 jne 650 <printf+0x12b>
s = (char*)*ap;
60b: 8b 45 e8 mov -0x18(%ebp),%eax
60e: 8b 00 mov (%eax),%eax
610: 89 45 f4 mov %eax,-0xc(%ebp)
ap++;
613: 83 45 e8 04 addl $0x4,-0x18(%ebp)
if(s == 0)
617: 83 7d f4 00 cmpl $0x0,-0xc(%ebp)
61b: 75 09 jne 626 <printf+0x101>
s = "(null)";
61d: c7 45 f4 17 09 00 00 movl $0x917,-0xc(%ebp)
while(*s != 0){
624: eb 1e jmp 644 <printf+0x11f>
626: eb 1c jmp 644 <printf+0x11f>
putc(fd, *s);
628: 8b 45 f4 mov -0xc(%ebp),%eax
62b: 0f b6 00 movzbl (%eax),%eax
62e: 0f be c0 movsbl %al,%eax
631: 89 44 24 04 mov %eax,0x4(%esp)
635: 8b 45 08 mov 0x8(%ebp),%eax
638: 89 04 24 mov %eax,(%esp)
63b: e8 05 fe ff ff call 445 <putc>
s++;
640: 83 45 f4 01 addl $0x1,-0xc(%ebp)
} else if(c == 's'){
s = (char*)*ap;
ap++;
if(s == 0)
s = "(null)";
while(*s != 0){
644: 8b 45 f4 mov -0xc(%ebp),%eax
647: 0f b6 00 movzbl (%eax),%eax
64a: 84 c0 test %al,%al
64c: 75 da jne 628 <printf+0x103>
64e: eb 68 jmp 6b8 <printf+0x193>
putc(fd, *s);
s++;
}
} else if(c == 'c'){
650: 83 7d e4 63 cmpl $0x63,-0x1c(%ebp)
654: 75 1d jne 673 <printf+0x14e>
putc(fd, *ap);
656: 8b 45 e8 mov -0x18(%ebp),%eax
659: 8b 00 mov (%eax),%eax
65b: 0f be c0 movsbl %al,%eax
65e: 89 44 24 04 mov %eax,0x4(%esp)
662: 8b 45 08 mov 0x8(%ebp),%eax
665: 89 04 24 mov %eax,(%esp)
668: e8 d8 fd ff ff call 445 <putc>
ap++;
66d: 83 45 e8 04 addl $0x4,-0x18(%ebp)
671: eb 45 jmp 6b8 <printf+0x193>
} else if(c == '%'){
673: 83 7d e4 25 cmpl $0x25,-0x1c(%ebp)
677: 75 17 jne 690 <printf+0x16b>
putc(fd, c);
679: 8b 45 e4 mov -0x1c(%ebp),%eax
67c: 0f be c0 movsbl %al,%eax
67f: 89 44 24 04 mov %eax,0x4(%esp)
683: 8b 45 08 mov 0x8(%ebp),%eax
686: 89 04 24 mov %eax,(%esp)
689: e8 b7 fd ff ff call 445 <putc>
68e: eb 28 jmp 6b8 <printf+0x193>
} else {
// Unknown % sequence. Print it to draw attention.
putc(fd, '%');
690: c7 44 24 04 25 00 00 movl $0x25,0x4(%esp)
697: 00
698: 8b 45 08 mov 0x8(%ebp),%eax
69b: 89 04 24 mov %eax,(%esp)
69e: e8 a2 fd ff ff call 445 <putc>
putc(fd, c);
6a3: 8b 45 e4 mov -0x1c(%ebp),%eax
6a6: 0f be c0 movsbl %al,%eax
6a9: 89 44 24 04 mov %eax,0x4(%esp)
6ad: 8b 45 08 mov 0x8(%ebp),%eax
6b0: 89 04 24 mov %eax,(%esp)
6b3: e8 8d fd ff ff call 445 <putc>
}
state = 0;
6b8: c7 45 ec 00 00 00 00 movl $0x0,-0x14(%ebp)
int c, i, state;
uint *ap;
state = 0;
ap = (uint*)(void*)&fmt + 1;
for(i = 0; fmt[i]; i++){
6bf: 83 45 f0 01 addl $0x1,-0x10(%ebp)
6c3: 8b 55 0c mov 0xc(%ebp),%edx
6c6: 8b 45 f0 mov -0x10(%ebp),%eax
6c9: 01 d0 add %edx,%eax
6cb: 0f b6 00 movzbl (%eax),%eax
6ce: 84 c0 test %al,%al
6d0: 0f 85 71 fe ff ff jne 547 <printf+0x22>
putc(fd, c);
}
state = 0;
}
}
}
6d6: c9 leave
6d7: c3 ret
000006d8 <free>:
static Header base;
static Header *freep;
void
free(void *ap)
{
6d8: 55 push %ebp
6d9: 89 e5 mov %esp,%ebp
6db: 83 ec 10 sub $0x10,%esp
Header *bp, *p;
bp = (Header*)ap - 1;
6de: 8b 45 08 mov 0x8(%ebp),%eax
6e1: 83 e8 08 sub $0x8,%eax
6e4: 89 45 f8 mov %eax,-0x8(%ebp)
for(p = freep; !(bp > p && bp < p->s.ptr); p = p->s.ptr)
6e7: a1 a8 0b 00 00 mov 0xba8,%eax
6ec: 89 45 fc mov %eax,-0x4(%ebp)
6ef: eb 24 jmp 715 <free+0x3d>
if(p >= p->s.ptr && (bp > p || bp < p->s.ptr))
6f1: 8b 45 fc mov -0x4(%ebp),%eax
6f4: 8b 00 mov (%eax),%eax
6f6: 3b 45 fc cmp -0x4(%ebp),%eax
6f9: 77 12 ja 70d <free+0x35>
6fb: 8b 45 f8 mov -0x8(%ebp),%eax
6fe: 3b 45 fc cmp -0x4(%ebp),%eax
701: 77 24 ja 727 <free+0x4f>
703: 8b 45 fc mov -0x4(%ebp),%eax
706: 8b 00 mov (%eax),%eax
708: 3b 45 f8 cmp -0x8(%ebp),%eax
70b: 77 1a ja 727 <free+0x4f>
free(void *ap)
{
Header *bp, *p;
bp = (Header*)ap - 1;
for(p = freep; !(bp > p && bp < p->s.ptr); p = p->s.ptr)
70d: 8b 45 fc mov -0x4(%ebp),%eax
710: 8b 00 mov (%eax),%eax
712: 89 45 fc mov %eax,-0x4(%ebp)
715: 8b 45 f8 mov -0x8(%ebp),%eax
718: 3b 45 fc cmp -0x4(%ebp),%eax
71b: 76 d4 jbe 6f1 <free+0x19>
71d: 8b 45 fc mov -0x4(%ebp),%eax
720: 8b 00 mov (%eax),%eax
722: 3b 45 f8 cmp -0x8(%ebp),%eax
725: 76 ca jbe 6f1 <free+0x19>
if(p >= p->s.ptr && (bp > p || bp < p->s.ptr))
break;
if(bp + bp->s.size == p->s.ptr){
727: 8b 45 f8 mov -0x8(%ebp),%eax
72a: 8b 40 04 mov 0x4(%eax),%eax
72d: 8d 14 c5 00 00 00 00 lea 0x0(,%eax,8),%edx
734: 8b 45 f8 mov -0x8(%ebp),%eax
737: 01 c2 add %eax,%edx
739: 8b 45 fc mov -0x4(%ebp),%eax
73c: 8b 00 mov (%eax),%eax
73e: 39 c2 cmp %eax,%edx
740: 75 24 jne 766 <free+0x8e>
bp->s.size += p->s.ptr->s.size;
742: 8b 45 f8 mov -0x8(%ebp),%eax
745: 8b 50 04 mov 0x4(%eax),%edx
748: 8b 45 fc mov -0x4(%ebp),%eax
74b: 8b 00 mov (%eax),%eax
74d: 8b 40 04 mov 0x4(%eax),%eax
750: 01 c2 add %eax,%edx
752: 8b 45 f8 mov -0x8(%ebp),%eax
755: 89 50 04 mov %edx,0x4(%eax)
bp->s.ptr = p->s.ptr->s.ptr;
758: 8b 45 fc mov -0x4(%ebp),%eax
75b: 8b 00 mov (%eax),%eax
75d: 8b 10 mov (%eax),%edx
75f: 8b 45 f8 mov -0x8(%ebp),%eax
762: 89 10 mov %edx,(%eax)
764: eb 0a jmp 770 <free+0x98>
} else
bp->s.ptr = p->s.ptr;
766: 8b 45 fc mov -0x4(%ebp),%eax
769: 8b 10 mov (%eax),%edx
76b: 8b 45 f8 mov -0x8(%ebp),%eax
76e: 89 10 mov %edx,(%eax)
if(p + p->s.size == bp){
770: 8b 45 fc mov -0x4(%ebp),%eax
773: 8b 40 04 mov 0x4(%eax),%eax
776: 8d 14 c5 00 00 00 00 lea 0x0(,%eax,8),%edx
77d: 8b 45 fc mov -0x4(%ebp),%eax
780: 01 d0 add %edx,%eax
782: 3b 45 f8 cmp -0x8(%ebp),%eax
785: 75 20 jne 7a7 <free+0xcf>
p->s.size += bp->s.size;
787: 8b 45 fc mov -0x4(%ebp),%eax
78a: 8b 50 04 mov 0x4(%eax),%edx
78d: 8b 45 f8 mov -0x8(%ebp),%eax
790: 8b 40 04 mov 0x4(%eax),%eax
793: 01 c2 add %eax,%edx
795: 8b 45 fc mov -0x4(%ebp),%eax
798: 89 50 04 mov %edx,0x4(%eax)
p->s.ptr = bp->s.ptr;
79b: 8b 45 f8 mov -0x8(%ebp),%eax
79e: 8b 10 mov (%eax),%edx
7a0: 8b 45 fc mov -0x4(%ebp),%eax
7a3: 89 10 mov %edx,(%eax)
7a5: eb 08 jmp 7af <free+0xd7>
} else
p->s.ptr = bp;
7a7: 8b 45 fc mov -0x4(%ebp),%eax
7aa: 8b 55 f8 mov -0x8(%ebp),%edx
7ad: 89 10 mov %edx,(%eax)
freep = p;
7af: 8b 45 fc mov -0x4(%ebp),%eax
7b2: a3 a8 0b 00 00 mov %eax,0xba8
}
7b7: c9 leave
7b8: c3 ret
000007b9 <morecore>:
static Header*
morecore(uint nu)
{
7b9: 55 push %ebp
7ba: 89 e5 mov %esp,%ebp
7bc: 83 ec 28 sub $0x28,%esp
char *p;
Header *hp;
if(nu < 4096)
7bf: 81 7d 08 ff 0f 00 00 cmpl $0xfff,0x8(%ebp)
7c6: 77 07 ja 7cf <morecore+0x16>
nu = 4096;
7c8: c7 45 08 00 10 00 00 movl $0x1000,0x8(%ebp)
p = sbrk(nu * sizeof(Header));
7cf: 8b 45 08 mov 0x8(%ebp),%eax
7d2: c1 e0 03 shl $0x3,%eax
7d5: 89 04 24 mov %eax,(%esp)
7d8: e8 30 fc ff ff call 40d <sbrk>
7dd: 89 45 f4 mov %eax,-0xc(%ebp)
if(p == (char*)-1)
7e0: 83 7d f4 ff cmpl $0xffffffff,-0xc(%ebp)
7e4: 75 07 jne 7ed <morecore+0x34>
return 0;
7e6: b8 00 00 00 00 mov $0x0,%eax
7eb: eb 22 jmp 80f <morecore+0x56>
hp = (Header*)p;
7ed: 8b 45 f4 mov -0xc(%ebp),%eax
7f0: 89 45 f0 mov %eax,-0x10(%ebp)
hp->s.size = nu;
7f3: 8b 45 f0 mov -0x10(%ebp),%eax
7f6: 8b 55 08 mov 0x8(%ebp),%edx
7f9: 89 50 04 mov %edx,0x4(%eax)
free((void*)(hp + 1));
7fc: 8b 45 f0 mov -0x10(%ebp),%eax
7ff: 83 c0 08 add $0x8,%eax
802: 89 04 24 mov %eax,(%esp)
805: e8 ce fe ff ff call 6d8 <free>
return freep;
80a: a1 a8 0b 00 00 mov 0xba8,%eax
}
80f: c9 leave
810: c3 ret
00000811 <malloc>:
void*
malloc(uint nbytes)
{
811: 55 push %ebp
812: 89 e5 mov %esp,%ebp
814: 83 ec 28 sub $0x28,%esp
Header *p, *prevp;
uint nunits;
nunits = (nbytes + sizeof(Header) - 1)/sizeof(Header) + 1;
817: 8b 45 08 mov 0x8(%ebp),%eax
81a: 83 c0 07 add $0x7,%eax
81d: c1 e8 03 shr $0x3,%eax
820: 83 c0 01 add $0x1,%eax
823: 89 45 ec mov %eax,-0x14(%ebp)
if((prevp = freep) == 0){
826: a1 a8 0b 00 00 mov 0xba8,%eax
82b: 89 45 f0 mov %eax,-0x10(%ebp)
82e: 83 7d f0 00 cmpl $0x0,-0x10(%ebp)
832: 75 23 jne 857 <malloc+0x46>
base.s.ptr = freep = prevp = &base;
834: c7 45 f0 a0 0b 00 00 movl $0xba0,-0x10(%ebp)
83b: 8b 45 f0 mov -0x10(%ebp),%eax
83e: a3 a8 0b 00 00 mov %eax,0xba8
843: a1 a8 0b 00 00 mov 0xba8,%eax
848: a3 a0 0b 00 00 mov %eax,0xba0
base.s.size = 0;
84d: c7 05 a4 0b 00 00 00 movl $0x0,0xba4
854: 00 00 00
}
for(p = prevp->s.ptr; ; prevp = p, p = p->s.ptr){
857: 8b 45 f0 mov -0x10(%ebp),%eax
85a: 8b 00 mov (%eax),%eax
85c: 89 45 f4 mov %eax,-0xc(%ebp)
if(p->s.size >= nunits){
85f: 8b 45 f4 mov -0xc(%ebp),%eax
862: 8b 40 04 mov 0x4(%eax),%eax
865: 3b 45 ec cmp -0x14(%ebp),%eax
868: 72 4d jb 8b7 <malloc+0xa6>
if(p->s.size == nunits)
86a: 8b 45 f4 mov -0xc(%ebp),%eax
86d: 8b 40 04 mov 0x4(%eax),%eax
870: 3b 45 ec cmp -0x14(%ebp),%eax
873: 75 0c jne 881 <malloc+0x70>
prevp->s.ptr = p->s.ptr;
875: 8b 45 f4 mov -0xc(%ebp),%eax
878: 8b 10 mov (%eax),%edx
87a: 8b 45 f0 mov -0x10(%ebp),%eax
87d: 89 10 mov %edx,(%eax)
87f: eb 26 jmp 8a7 <malloc+0x96>
else {
p->s.size -= nunits;
881: 8b 45 f4 mov -0xc(%ebp),%eax
884: 8b 40 04 mov 0x4(%eax),%eax
887: 2b 45 ec sub -0x14(%ebp),%eax
88a: 89 c2 mov %eax,%edx
88c: 8b 45 f4 mov -0xc(%ebp),%eax
88f: 89 50 04 mov %edx,0x4(%eax)
p += p->s.size;
892: 8b 45 f4 mov -0xc(%ebp),%eax
895: 8b 40 04 mov 0x4(%eax),%eax
898: c1 e0 03 shl $0x3,%eax
89b: 01 45 f4 add %eax,-0xc(%ebp)
p->s.size = nunits;
89e: 8b 45 f4 mov -0xc(%ebp),%eax
8a1: 8b 55 ec mov -0x14(%ebp),%edx
8a4: 89 50 04 mov %edx,0x4(%eax)
}
freep = prevp;
8a7: 8b 45 f0 mov -0x10(%ebp),%eax
8aa: a3 a8 0b 00 00 mov %eax,0xba8
return (void*)(p + 1);
8af: 8b 45 f4 mov -0xc(%ebp),%eax
8b2: 83 c0 08 add $0x8,%eax
8b5: eb 38 jmp 8ef <malloc+0xde>
}
if(p == freep)
8b7: a1 a8 0b 00 00 mov 0xba8,%eax
8bc: 39 45 f4 cmp %eax,-0xc(%ebp)
8bf: 75 1b jne 8dc <malloc+0xcb>
if((p = morecore(nunits)) == 0)
8c1: 8b 45 ec mov -0x14(%ebp),%eax
8c4: 89 04 24 mov %eax,(%esp)
8c7: e8 ed fe ff ff call 7b9 <morecore>
8cc: 89 45 f4 mov %eax,-0xc(%ebp)
8cf: 83 7d f4 00 cmpl $0x0,-0xc(%ebp)
8d3: 75 07 jne 8dc <malloc+0xcb>
return 0;
8d5: b8 00 00 00 00 mov $0x0,%eax
8da: eb 13 jmp 8ef <malloc+0xde>
nunits = (nbytes + sizeof(Header) - 1)/sizeof(Header) + 1;
if((prevp = freep) == 0){
base.s.ptr = freep = prevp = &base;
base.s.size = 0;
}
for(p = prevp->s.ptr; ; prevp = p, p = p->s.ptr){
8dc: 8b 45 f4 mov -0xc(%ebp),%eax
8df: 89 45 f0 mov %eax,-0x10(%ebp)
8e2: 8b 45 f4 mov -0xc(%ebp),%eax
8e5: 8b 00 mov (%eax),%eax
8e7: 89 45 f4 mov %eax,-0xc(%ebp)
return (void*)(p + 1);
}
if(p == freep)
if((p = morecore(nunits)) == 0)
return 0;
}
8ea: e9 70 ff ff ff jmp 85f <malloc+0x4e>
}
8ef: c9 leave
8f0: c3 ret
| reutz19/xv6_ass2 | cat.asm | Assembly | mit | 43,389 |
INCLUDE "hardware.inc"
INCLUDE "header.inc"
SECTION "var",BSS
repeat_loop: DS 1
SECTION "Main",HOME
GLOBAL LCD_function
LCD_function::
push af
ld a,[rLY]
cp a,100
jr nz,._not_100
; 100
ld a,101
ld [rLYC],a
pop af
xor a,a
ld b,a
ld c,a
ld d,a
reti
._not_100:
pop af
ld [hl+],a
ld [hl],b
inc hl
ld [hl],c
inc hl
ld [hl],d
inc hl
ret
;--------------------------------------------------------------------------
;- Main() -
;--------------------------------------------------------------------------
Main:
call screen_off
ld bc,16
ld de,0
ld hl,font_tiles
call vram_copy_tiles
ld hl,$A000
ld a,LCDCF_ON
ld [rLCDC],a
ld a,[Init_Reg_A]
cp a,$11
jr nz,.skip1
ld a,0
ld [repeat_loop],a
call CPU_slow
.skip1:
.repeat_all:
; -------------------------------------------------------
ld a,$0A
ld [$0000],a ; enable ram
; -------------------------------------------------------
di
ld a,IEF_LCDC
ld [rIE],a
ld a,100
ld [rLYC],a
ld a,STATF_LYC
ld [rSTAT],a
ld b,100
call wait_ly
ld b,99
call wait_ly
ld a,0
ld [rIF],a
ei
REPT 2
REPT 256
inc a
ENDR
REPT 256
inc b
ENDR
REPT 256
inc c
ENDR
REPT 256
inc d
ENDR
ENDR
; -------------------------------------------------------
push hl ; magic number
ld [hl],$12
inc hl
ld [hl],$34
inc hl
ld [hl],$56
inc hl
ld [hl],$78
pop hl
ld a,$00
ld [$0000],a ; disable ram
; -------------------------------------------------------
ld a,[Init_Reg_A]
cp a,$11
jr nz,.dontchange
ld a,[repeat_loop]
and a,a
jr nz,.dontchange
; -------------------------------------------------------
call CPU_fast
ld a,1
ld [repeat_loop],a
jp .repeat_all
.dontchange:
call screen_off
ld a,$0A
ld [$0000],a
WRITE_NUMBER : MACRO
ld a,[\1]
ld b,a
swap a
and a,$0F
ld [_SCRN0+2*(\2)],a
ld a,b
and a,$0F
ld [_SCRN0+2*(\2)+1],a
ENDM
WRITE_NUMBER $A000,0
WRITE_NUMBER $A001,1
WRITE_NUMBER $A002,2
WRITE_NUMBER $A003,3
WRITE_NUMBER $A004,4
WRITE_NUMBER $A005,5
WRITE_NUMBER $A006,6
WRITE_NUMBER $A007,7
ld a,$00
ld [$0000],a ; disable ram
ld hl,bg_palette
ld a,0
call bg_set_palette
ld a,LCDCF_ON|LCDCF_BG8000|LCDCF_BG9800|LCDCF_BGON ; configuration
ld [rLCDC],a
ld a,$E4
ld [rBGP],a
.endloop:
halt
jr .endloop
SECTION "FONT",ROMX[$4000],BANK[1]
font_tiles: ; 16 tiles
DB $C3,$C3,$99,$99,$99,$99,$99,$99
DB $99,$99,$C3,$C3,$FF,$FF,$FF,$FF
DB $E7,$E7,$C7,$C7,$E7,$E7,$E7,$E7
DB $E7,$E7,$C3,$C3,$FF,$FF,$FF,$FF
DB $C3,$C3,$99,$99,$F9,$F9,$E3,$E3
DB $CF,$CF,$81,$81,$FF,$FF,$FF,$FF
DB $C3,$C3,$99,$99,$F3,$F3,$F9,$F9
DB $99,$99,$C3,$C3,$FF,$FF,$FF,$FF
DB $F3,$F3,$E3,$E3,$D3,$D3,$B3,$B3
DB $81,$81,$F3,$F3,$FF,$FF,$FF,$FF
DB $83,$83,$9F,$9F,$83,$83,$F9,$F9
DB $99,$99,$C3,$C3,$FF,$FF,$FF,$FF
DB $C3,$C3,$9F,$9F,$83,$83,$99,$99
DB $99,$99,$C3,$C3,$FF,$FF,$FF,$FF
DB $C1,$C1,$F9,$F9,$F3,$F3,$E7,$E7
DB $E7,$E7,$E7,$E7,$FF,$FF,$FF,$FF
DB $C3,$C3,$99,$99,$C3,$C3,$99,$99
DB $99,$99,$C3,$C3,$FF,$FF,$FF,$FF
DB $C3,$C3,$99,$99,$81,$81,$F9,$F9
DB $99,$99,$C3,$C3,$FF,$FF,$FF,$FF
DB $C3,$C3,$99,$99,$99,$99,$81,$81
DB $99,$99,$99,$99,$FF,$FF,$FF,$FF
DB $83,$83,$99,$99,$83,$83,$99,$99
DB $99,$99,$83,$83,$FF,$FF,$FF,$FF
DB $C3,$C3,$99,$99,$9F,$9F,$9F,$9F
DB $99,$99,$C3,$C3,$FF,$FF,$FF,$FF
DB $83,$83,$99,$99,$99,$99,$99,$99
DB $99,$99,$83,$83,$FF,$FF,$FF,$FF
DB $81,$81,$9F,$9F,$87,$87,$9F,$9F
DB $9F,$9F,$81,$81,$FF,$FF,$FF,$FF
DB $81,$81,$9F,$9F,$87,$87,$9F,$9F
DB $9F,$9F,$9F,$9F,$FF,$FF,$FF,$FF
bg_palette:
DW 32767,22197,12684,0
| AntonioND/gbc-hw-tests | lcd/ly_clocks/main.asm | Assembly | mit | 3,593 |
[BITS 16]
[ORG 0x7C00]
MOV SI, DataString
CALL OutString
HLT
OutCharacter: ;modified registers: AH, BH, BL
;ASCII value is in register AL
MOV AH, 0x0E ;Tell BIOS that we need to print one character on screen.
MOV BH, 0x00 ;Page no.
MOV BL, 0x07 ;Text attribute 0x07 is light grey font on black background
INT 0x10 ;Call video interrupt
RET
OutString: ;modified registers AL, SI, AH, BH, BL
;String Pointer in SI
MOV AL, [SI] ;Load next character from string into AL to send to OutCharacter
INC SI
OR AL, AL ;Check if AL is zero without changing AL
JZ OutString_Exit ;if zero stop
CALL OutCharacter ;print character in AL
JMP OutString ;loop until end of string
OutString_Exit:
RET ;End of routine
;Data
DataString db 'NotAnOS Bootloader',0
TIMES 510 - ($ - $$) db 0 ;Fill the rest of sector 0 with zeroes
DW 0xAA55 ;Legacy boot signature
| DuskDragon/ImplosionOS | kernel/bootloader.asm | Assembly | mit | 920 |
PLC_3607EC: dc.w Frame_360816-PLC_3607EC
dc.w Frame_36081C-PLC_3607EC
dc.w Frame_360822-PLC_3607EC
dc.w Frame_360828-PLC_3607EC
dc.w Frame_36082E-PLC_3607EC
dc.w Frame_360834-PLC_3607EC
dc.w Frame_36083A-PLC_3607EC
dc.w Frame_360840-PLC_3607EC
dc.w Frame_360846-PLC_3607EC
dc.w Frame_36084C-PLC_3607EC
dc.w Frame_360852-PLC_3607EC
dc.w Frame_360858-PLC_3607EC
dc.w Frame_36085E-PLC_3607EC
dc.w Frame_360866-PLC_3607EC
dc.w Frame_36086C-PLC_3607EC
dc.w Frame_360870-PLC_3607EC
dc.w Frame_360876-PLC_3607EC
dc.w Frame_36087C-PLC_3607EC
dc.w Frame_360882-PLC_3607EC
dc.w Frame_360888-PLC_3607EC
dc.w Frame_36088E-PLC_3607EC
Frame_360816: dc.w 1
dc.w $83
dc.w 7
Frame_36081C: dc.w 1
dc.w $C3
dc.w 7
Frame_360822: dc.w 1
dc.w $103
dc.w 7
Frame_360828: dc.w 1
dc.w $143
dc.w 7
Frame_36082E: dc.w 1
dc.w $183
dc.w 7
Frame_360834: dc.w 1
dc.w $1C3
dc.w 7
Frame_36083A: dc.w 1
dc.w $202
dc.w 7
Frame_360840: dc.w 1
dc.w $232
dc.w 7
Frame_360846: dc.w 1
dc.w $263
dc.w 7
Frame_36084C: dc.w 1
dc.w $2A3
dc.w 7
Frame_360852: dc.w 1
dc.w $2E7
dc.w $360
Frame_360858: dc.w 1
dc.w $377
dc.w $3F0
Frame_36085E: dc.w 2
dc.w $407
dc.w $480
dc.w $490
Frame_360866: dc.w 1
dc.w $4A7
dc.w $521
Frame_36086C: dc.w 0
dc.w $547
Frame_360870: dc.w 1
dc.w $5C1
dc.w $5E7
Frame_360876: dc.w 1
dc.w $665
dc.w $6C2
Frame_36087C: dc.w 1
dc.w $6F1
dc.w $718
Frame_360882: dc.w 1
dc.w $7A8
dc.w $830
Frame_360888: dc.w 1
dc.w $848
dc.w $8D0
Frame_36088E: dc.w 2
dc.w $8E0
dc.w $8F8
dc.w $980
| TeamASM-Blur/Sonic-3-Blue-Balls-Edition | Working Disassembly/General/Sprites/Flybot/DPLC - Flybot.asm | Assembly | apache-2.0 | 1,586 |
;*!
;* \copy
;* Copyright (c) 2010-2013, Cisco Systems
;* All rights reserved.
;*
;* Redistribution and use in source and binary forms, with or without
;* modification, are permitted provided that the following conditions
;* are met:
;*
;* * Redistributions of source code must retain the above copyright
;* notice, this list of conditions and the following disclaimer.
;*
;* * Redistributions in binary form must reproduce the above copyright
;* notice, this list of conditions and the following disclaimer in
;* the documentation and/or other materials provided with the
;* distribution.
;*
;* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
;* "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
;* LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
;* FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
;* COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT,
;* INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
;* BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
;* LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
;* CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
;* LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN
;* ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
;* POSSIBILITY OF SUCH DAMAGE.
;*
;*
;* memzero.asm
;*
;* Abstract
;* cavlc
;*
;* History
;* 09/08/2010 Created
;*
;*
;*************************************************************************/
%include "asm_inc.asm"
SECTION .rodata align=16
align 16
sse2_b8 db 8, 8, 8, 8, 8, 8, 8, 8
ALIGN 16
sse2_b_1 db -1, -1, -1, -1, -1, -1, -1, 0, -1, -1, -1, -1, -1, -1, -1, -1
align 16
byte_1pos_table:
db 0,0,0,0,0,0,0,0, ;0
db 0,0,0,0,0,0,0,1, ;1
db 1,0,0,0,0,0,0,1, ;2
db 1,0,0,0,0,0,0,2, ;3
db 2,0,0,0,0,0,0,1, ;4
db 2,0,0,0,0,0,0,2, ;5
db 2,1,0,0,0,0,0,2, ;6
db 2,1,0,0,0,0,0,3, ;7
db 3,0,0,0,0,0,0,1, ;8
db 3,0,0,0,0,0,0,2, ;9
db 3,1,0,0,0,0,0,2, ;10
db 3,1,0,0,0,0,0,3, ;11
db 3,2,0,0,0,0,0,2, ;12
db 3,2,0,0,0,0,0,3, ;13
db 3,2,1,0,0,0,0,3, ;14
db 3,2,1,0,0,0,0,4, ;15
db 4,0,0,0,0,0,0,1, ;16
db 4,0,0,0,0,0,0,2, ;17
db 4,1,0,0,0,0,0,2, ;18
db 4,1,0,0,0,0,0,3, ;19
db 4,2,0,0,0,0,0,2, ;20
db 4,2,0,0,0,0,0,3, ;21
db 4,2,1,0,0,0,0,3, ;22
db 4,2,1,0,0,0,0,4, ;23
db 4,3,0,0,0,0,0,2, ;24
db 4,3,0,0,0,0,0,3, ;25
db 4,3,1,0,0,0,0,3, ;26
db 4,3,1,0,0,0,0,4, ;27
db 4,3,2,0,0,0,0,3, ;28
db 4,3,2,0,0,0,0,4, ;29
db 4,3,2,1,0,0,0,4, ;30
db 4,3,2,1,0,0,0,5, ;31
db 5,0,0,0,0,0,0,1, ;32
db 5,0,0,0,0,0,0,2, ;33
db 5,1,0,0,0,0,0,2, ;34
db 5,1,0,0,0,0,0,3, ;35
db 5,2,0,0,0,0,0,2, ;36
db 5,2,0,0,0,0,0,3, ;37
db 5,2,1,0,0,0,0,3, ;38
db 5,2,1,0,0,0,0,4, ;39
db 5,3,0,0,0,0,0,2, ;40
db 5,3,0,0,0,0,0,3, ;41
db 5,3,1,0,0,0,0,3, ;42
db 5,3,1,0,0,0,0,4, ;43
db 5,3,2,0,0,0,0,3, ;44
db 5,3,2,0,0,0,0,4, ;45
db 5,3,2,1,0,0,0,4, ;46
db 5,3,2,1,0,0,0,5, ;47
db 5,4,0,0,0,0,0,2, ;48
db 5,4,0,0,0,0,0,3, ;49
db 5,4,1,0,0,0,0,3, ;50
db 5,4,1,0,0,0,0,4, ;51
db 5,4,2,0,0,0,0,3, ;52
db 5,4,2,0,0,0,0,4, ;53
db 5,4,2,1,0,0,0,4, ;54
db 5,4,2,1,0,0,0,5, ;55
db 5,4,3,0,0,0,0,3, ;56
db 5,4,3,0,0,0,0,4, ;57
db 5,4,3,1,0,0,0,4, ;58
db 5,4,3,1,0,0,0,5, ;59
db 5,4,3,2,0,0,0,4, ;60
db 5,4,3,2,0,0,0,5, ;61
db 5,4,3,2,1,0,0,5, ;62
db 5,4,3,2,1,0,0,6, ;63
db 6,0,0,0,0,0,0,1, ;64
db 6,0,0,0,0,0,0,2, ;65
db 6,1,0,0,0,0,0,2, ;66
db 6,1,0,0,0,0,0,3, ;67
db 6,2,0,0,0,0,0,2, ;68
db 6,2,0,0,0,0,0,3, ;69
db 6,2,1,0,0,0,0,3, ;70
db 6,2,1,0,0,0,0,4, ;71
db 6,3,0,0,0,0,0,2, ;72
db 6,3,0,0,0,0,0,3, ;73
db 6,3,1,0,0,0,0,3, ;74
db 6,3,1,0,0,0,0,4, ;75
db 6,3,2,0,0,0,0,3, ;76
db 6,3,2,0,0,0,0,4, ;77
db 6,3,2,1,0,0,0,4, ;78
db 6,3,2,1,0,0,0,5, ;79
db 6,4,0,0,0,0,0,2, ;80
db 6,4,0,0,0,0,0,3, ;81
db 6,4,1,0,0,0,0,3, ;82
db 6,4,1,0,0,0,0,4, ;83
db 6,4,2,0,0,0,0,3, ;84
db 6,4,2,0,0,0,0,4, ;85
db 6,4,2,1,0,0,0,4, ;86
db 6,4,2,1,0,0,0,5, ;87
db 6,4,3,0,0,0,0,3, ;88
db 6,4,3,0,0,0,0,4, ;89
db 6,4,3,1,0,0,0,4, ;90
db 6,4,3,1,0,0,0,5, ;91
db 6,4,3,2,0,0,0,4, ;92
db 6,4,3,2,0,0,0,5, ;93
db 6,4,3,2,1,0,0,5, ;94
db 6,4,3,2,1,0,0,6, ;95
db 6,5,0,0,0,0,0,2, ;96
db 6,5,0,0,0,0,0,3, ;97
db 6,5,1,0,0,0,0,3, ;98
db 6,5,1,0,0,0,0,4, ;99
db 6,5,2,0,0,0,0,3, ;100
db 6,5,2,0,0,0,0,4, ;101
db 6,5,2,1,0,0,0,4, ;102
db 6,5,2,1,0,0,0,5, ;103
db 6,5,3,0,0,0,0,3, ;104
db 6,5,3,0,0,0,0,4, ;105
db 6,5,3,1,0,0,0,4, ;106
db 6,5,3,1,0,0,0,5, ;107
db 6,5,3,2,0,0,0,4, ;108
db 6,5,3,2,0,0,0,5, ;109
db 6,5,3,2,1,0,0,5, ;110
db 6,5,3,2,1,0,0,6, ;111
db 6,5,4,0,0,0,0,3, ;112
db 6,5,4,0,0,0,0,4, ;113
db 6,5,4,1,0,0,0,4, ;114
db 6,5,4,1,0,0,0,5, ;115
db 6,5,4,2,0,0,0,4, ;116
db 6,5,4,2,0,0,0,5, ;117
db 6,5,4,2,1,0,0,5, ;118
db 6,5,4,2,1,0,0,6, ;119
db 6,5,4,3,0,0,0,4, ;120
db 6,5,4,3,0,0,0,5, ;121
db 6,5,4,3,1,0,0,5, ;122
db 6,5,4,3,1,0,0,6, ;123
db 6,5,4,3,2,0,0,5, ;124
db 6,5,4,3,2,0,0,6, ;125
db 6,5,4,3,2,1,0,6, ;126
db 6,5,4,3,2,1,0,7, ;127
db 7,0,0,0,0,0,0,1, ;128
db 7,0,0,0,0,0,0,2, ;129
db 7,1,0,0,0,0,0,2, ;130
db 7,1,0,0,0,0,0,3, ;131
db 7,2,0,0,0,0,0,2, ;132
db 7,2,0,0,0,0,0,3, ;133
db 7,2,1,0,0,0,0,3, ;134
db 7,2,1,0,0,0,0,4, ;135
db 7,3,0,0,0,0,0,2, ;136
db 7,3,0,0,0,0,0,3, ;137
db 7,3,1,0,0,0,0,3, ;138
db 7,3,1,0,0,0,0,4, ;139
db 7,3,2,0,0,0,0,3, ;140
db 7,3,2,0,0,0,0,4, ;141
db 7,3,2,1,0,0,0,4, ;142
db 7,3,2,1,0,0,0,5, ;143
db 7,4,0,0,0,0,0,2, ;144
db 7,4,0,0,0,0,0,3, ;145
db 7,4,1,0,0,0,0,3, ;146
db 7,4,1,0,0,0,0,4, ;147
db 7,4,2,0,0,0,0,3, ;148
db 7,4,2,0,0,0,0,4, ;149
db 7,4,2,1,0,0,0,4, ;150
db 7,4,2,1,0,0,0,5, ;151
db 7,4,3,0,0,0,0,3, ;152
db 7,4,3,0,0,0,0,4, ;153
db 7,4,3,1,0,0,0,4, ;154
db 7,4,3,1,0,0,0,5, ;155
db 7,4,3,2,0,0,0,4, ;156
db 7,4,3,2,0,0,0,5, ;157
db 7,4,3,2,1,0,0,5, ;158
db 7,4,3,2,1,0,0,6, ;159
db 7,5,0,0,0,0,0,2, ;160
db 7,5,0,0,0,0,0,3, ;161
db 7,5,1,0,0,0,0,3, ;162
db 7,5,1,0,0,0,0,4, ;163
db 7,5,2,0,0,0,0,3, ;164
db 7,5,2,0,0,0,0,4, ;165
db 7,5,2,1,0,0,0,4, ;166
db 7,5,2,1,0,0,0,5, ;167
db 7,5,3,0,0,0,0,3, ;168
db 7,5,3,0,0,0,0,4, ;169
db 7,5,3,1,0,0,0,4, ;170
db 7,5,3,1,0,0,0,5, ;171
db 7,5,3,2,0,0,0,4, ;172
db 7,5,3,2,0,0,0,5, ;173
db 7,5,3,2,1,0,0,5, ;174
db 7,5,3,2,1,0,0,6, ;175
db 7,5,4,0,0,0,0,3, ;176
db 7,5,4,0,0,0,0,4, ;177
db 7,5,4,1,0,0,0,4, ;178
db 7,5,4,1,0,0,0,5, ;179
db 7,5,4,2,0,0,0,4, ;180
db 7,5,4,2,0,0,0,5, ;181
db 7,5,4,2,1,0,0,5, ;182
db 7,5,4,2,1,0,0,6, ;183
db 7,5,4,3,0,0,0,4, ;184
db 7,5,4,3,0,0,0,5, ;185
db 7,5,4,3,1,0,0,5, ;186
db 7,5,4,3,1,0,0,6, ;187
db 7,5,4,3,2,0,0,5, ;188
db 7,5,4,3,2,0,0,6, ;189
db 7,5,4,3,2,1,0,6, ;190
db 7,5,4,3,2,1,0,7, ;191
db 7,6,0,0,0,0,0,2, ;192
db 7,6,0,0,0,0,0,3, ;193
db 7,6,1,0,0,0,0,3, ;194
db 7,6,1,0,0,0,0,4, ;195
db 7,6,2,0,0,0,0,3, ;196
db 7,6,2,0,0,0,0,4, ;197
db 7,6,2,1,0,0,0,4, ;198
db 7,6,2,1,0,0,0,5, ;199
db 7,6,3,0,0,0,0,3, ;200
db 7,6,3,0,0,0,0,4, ;201
db 7,6,3,1,0,0,0,4, ;202
db 7,6,3,1,0,0,0,5, ;203
db 7,6,3,2,0,0,0,4, ;204
db 7,6,3,2,0,0,0,5, ;205
db 7,6,3,2,1,0,0,5, ;206
db 7,6,3,2,1,0,0,6, ;207
db 7,6,4,0,0,0,0,3, ;208
db 7,6,4,0,0,0,0,4, ;209
db 7,6,4,1,0,0,0,4, ;210
db 7,6,4,1,0,0,0,5, ;211
db 7,6,4,2,0,0,0,4, ;212
db 7,6,4,2,0,0,0,5, ;213
db 7,6,4,2,1,0,0,5, ;214
db 7,6,4,2,1,0,0,6, ;215
db 7,6,4,3,0,0,0,4, ;216
db 7,6,4,3,0,0,0,5, ;217
db 7,6,4,3,1,0,0,5, ;218
db 7,6,4,3,1,0,0,6, ;219
db 7,6,4,3,2,0,0,5, ;220
db 7,6,4,3,2,0,0,6, ;221
db 7,6,4,3,2,1,0,6, ;222
db 7,6,4,3,2,1,0,7, ;223
db 7,6,5,0,0,0,0,3, ;224
db 7,6,5,0,0,0,0,4, ;225
db 7,6,5,1,0,0,0,4, ;226
db 7,6,5,1,0,0,0,5, ;227
db 7,6,5,2,0,0,0,4, ;228
db 7,6,5,2,0,0,0,5, ;229
db 7,6,5,2,1,0,0,5, ;230
db 7,6,5,2,1,0,0,6, ;231
db 7,6,5,3,0,0,0,4, ;232
db 7,6,5,3,0,0,0,5, ;233
db 7,6,5,3,1,0,0,5, ;234
db 7,6,5,3,1,0,0,6, ;235
db 7,6,5,3,2,0,0,5, ;236
db 7,6,5,3,2,0,0,6, ;237
db 7,6,5,3,2,1,0,6, ;238
db 7,6,5,3,2,1,0,7, ;239
db 7,6,5,4,0,0,0,4, ;240
db 7,6,5,4,0,0,0,5, ;241
db 7,6,5,4,1,0,0,5, ;242
db 7,6,5,4,1,0,0,6, ;243
db 7,6,5,4,2,0,0,5, ;244
db 7,6,5,4,2,0,0,6, ;245
db 7,6,5,4,2,1,0,6, ;246
db 7,6,5,4,2,1,0,7, ;247
db 7,6,5,4,3,0,0,5, ;248
db 7,6,5,4,3,0,0,6, ;249
db 7,6,5,4,3,1,0,6, ;250
db 7,6,5,4,3,1,0,7, ;251
db 7,6,5,4,3,2,0,6, ;252
db 7,6,5,4,3,2,0,7, ;253
db 7,6,5,4,3,2,1,7, ;254
db 7,6,5,4,3,2,1,8, ;255
;***********************************************************************
; Code
;***********************************************************************
SECTION .text
;***********************************************************************
;int32_t CavlcParamCal_sse2(int16_t*coffLevel, uint8_t* run, int16_t *Level, int32_t* total_coeffs , int32_t endIdx);
;***********************************************************************
WELS_EXTERN CavlcParamCal_sse2
CavlcParamCal_sse2:
push ebx
push edi
push esi
mov eax, [esp+16] ;coffLevel
mov edi, [esp+24] ;Level
mov ebx, [esp+32] ;endIdx
cmp ebx, 3
jne .Level16
pxor xmm1, xmm1
movq xmm0, [eax] ; removed QWORD
jmp .Cal_begin
.Level16:
movdqa xmm0, [eax]
movdqa xmm1, [eax+16]
.Cal_begin:
movdqa xmm2, xmm0
packsswb xmm0, xmm1
movdqa xmm4, xmm0
pxor xmm3, xmm3
pcmpgtb xmm0, xmm3
pcmpgtb xmm3, xmm4
por xmm0, xmm3
pmovmskb edx, xmm0
cmp edx, 0
je near .return
movdqa xmm6, [sse2_b_1]
pcmpeqw xmm7, xmm7 ;generate -1
mov ebx, 0xff
;pinsrw xmm6, ebx, 3
mov bl, dh
lea ebx, [byte_1pos_table+8*ebx]
movq xmm0, [ebx]
pextrw ecx, xmm0, 3
shr ecx, 8
mov dh, cl
.loopHighFind0:
cmp ecx, 0
je .loopHighFind0End
;mov esi, [ebx]
;and esi, 0xff
movzx esi, byte [ebx]
add esi, 8
mov esi, [eax+2*esi]
mov [edi], si
add edi, 2
;add ebx, 1
inc ebx
dec ecx
jmp .loopHighFind0
.loopHighFind0End:
mov cl, dh
cmp cl, 8
pand xmm0, xmm6
jne .LowByteFind0
sub edi, 2
mov esi, [eax+16]
mov [edi], esi
add edi, 2
.LowByteFind0:
and edx, 0xff
lea ebx, [byte_1pos_table+8*edx]
movq xmm1, [ebx]
pextrw esi, xmm1, 3
or esi, 0xff
or ecx, 0xff00
and ecx, esi
shr esi, 8
pand xmm1, xmm6
.loopLowFind0:
cmp esi, 0
je .loopLowFind0End
;mov edx, [ebx]
;and edx, 0xff
movzx edx, byte [ebx]
mov edx, [eax+2*edx]
mov [edi], dx
add edi, 2
;add ebx, 1
inc ebx
dec esi
jmp .loopLowFind0
.loopLowFind0End:
cmp ch, 8
jne .getLevelEnd
sub edi, 2
mov edx, [eax]
mov [edi], dx
.getLevelEnd:
mov edx, [esp+28] ;total_coeffs
;mov ebx, ecx
;and ebx, 0xff
movzx ebx, byte cl
add cl, ch
mov [edx], cl
;getRun
movq xmm5, [sse2_b8]
paddb xmm0, xmm5
pxor xmm2, xmm2
pxor xmm3, xmm3
mov eax, 8
sub eax, ebx
shl eax, 3
shl ebx, 3
pinsrw xmm2, ebx, 0
pinsrw xmm3, eax, 0
psllq xmm0, xmm3
psrlq xmm0, xmm3
movdqa xmm4, xmm1
psllq xmm1, xmm2
psrlq xmm4, xmm3
punpcklqdq xmm1, xmm4
por xmm0, xmm1
pextrw eax, xmm0, 0
and eax, 0xff
inc eax
sub al, cl
movdqa xmm1, xmm0
paddb xmm1, xmm7
psrldq xmm0, 1
psubb xmm1, xmm0
mov ecx, [esp+20] ;run
movdqa [ecx], xmm1
;getRunEnd
.return:
pop esi
pop edi
pop ebx
ret | chenxy/openh264 | codec/encoder/core/asm/coeff.asm | Assembly | bsd-2-clause | 11,754 |
; ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
; string.asm
; ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
; Forrest Yu, 2005
; ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
[SECTION .text]
; 导出函数
global memcpy
; ------------------------------------------------------------------------
; void* memcpy(void* es:pDest, void* ds:pSrc, int iSize);
; ------------------------------------------------------------------------
memcpy:
push ebp
mov ebp, esp
push esi
push edi
push ecx
mov edi, [ebp + 8] ; Destination
mov esi, [ebp + 12] ; Source
mov ecx, [ebp + 16] ; Counter
.1:
cmp ecx, 0 ; 判断计数器
jz .2 ; 计数器为零时跳出
mov al, [ds:esi] ; ┓
inc esi ; ┃
; ┣ 逐字节移动
mov byte [es:edi], al ; ┃
inc edi ; ┛
dec ecx ; 计数器减一
jmp .1 ; 循环
.2:
mov eax, [ebp + 8] ; 返回值
pop ecx
pop edi
pop esi
mov esp, ebp
pop ebp
ret ; 函数结束,返回
; memcpy 结束------------------------------------------------------------- | RongbinZhuang/simpleOS | ver0/reference/chapter5/g/lib/string.asm | Assembly | mit | 1,185 |
; Licensed to the .NET Foundation under one or more agreements.
; The .NET Foundation licenses this file to you under the MIT license.
; See the LICENSE file in the project root for more information.
; ==++==
;
;
; ==--==
include AsmMacros.inc
include asmconstants.inc
Thread__GetAbortContext equ ?GetAbortContext@Thread@@QEAAPEAU_CONTEXT@@XZ
extern FixContextHandler:proc
extern LinkFrameAndThrow:proc
extern GetCurrentSavedRedirectContext:proc
extern Thread__GetAbortContext:proc
extern HijackHandler:proc
extern ThrowControlForThread:proc
extern FixRedirectContextHandler:proc
;
; WARNING!! These functions immediately ruin thread unwindability. This is
; WARNING!! OK as long as there is a mechanism for saving the thread context
; WARNING!! prior to running these functions as well as a mechanism for
; WARNING!! restoring the context prior to any stackwalk. This means that
; WARNING!! we need to ensure that no GC can occur while the stack is
; WARNING!! unwalkable. This further means that we cannot allow any exception
; WARNING!! to occure when the stack is unwalkable
;
; If you edit this macro, make sure you update GetCONTEXTFromRedirectedStubStackFrame.
; This function is used by both the personality routine and the debugger to retrieve the original CONTEXT.
GenerateRedirectedHandledJITCaseStub macro reason
extern ?RedirectedHandledJITCaseFor&reason&@Thread@@CAXXZ:proc
NESTED_ENTRY RedirectedHandledJITCaseFor&reason&_Stub, _TEXT, FixRedirectContextHandler
;
; To aid debugging, we'll fake a call to this function. Allocate an
; extra stack slot that is hidden from the unwind info, where we can
; stuff the "return address". If we wanted to preserve full
; unwindability, we would need to copy all preserved registers.
; Ordinarily, rbp is used for the frame pointer, so since we're only
; interested is debugability, we'll just handle that common case.
;
push rax ; where to stuff the fake return address
push_nonvol_reg rbp ; save interrupted rbp for stack walk
alloc_stack 28h ; CONTEXT*, callee scratch area
set_frame rbp, 0
.errnz REDIRECTSTUB_ESTABLISHER_OFFSET_RBP, REDIRECTSTUB_ESTABLISHER_OFFSET_RBP has changed - update asm stubs
END_PROLOGUE
;
; Align rsp. rsp must misaligned at entry to any C function.
;
and rsp, -16
;
; Save a copy of the redirect CONTEXT* in case an exception occurs.
; The personality routine will use this to restore unwindability for
; the exception dispatcher.
;
call GetCurrentSavedRedirectContext
mov [rbp+20h], rax
.errnz REDIRECTSTUB_RBP_OFFSET_CONTEXT - 20h, REDIRECTSTUB_RBP_OFFSET_CONTEXT has changed - update asm stubs
;
; Fetch the interrupted rip and save it as our return address.
;
mov rax, [rax + OFFSETOF__CONTEXT__Rip]
mov [rbp+30h], rax
;
; Call target, which will do whatever we needed to do in the context
; of the target thread, and will RtlRestoreContext when it is done.
;
call ?RedirectedHandledJITCaseFor&reason&@Thread@@CAXXZ
int 3 ; target shouldn't return.
; Put a label here to tell the debugger where the end of this function is.
PATCH_LABEL RedirectedHandledJITCaseFor&reason&_StubEnd
NESTED_END RedirectedHandledJITCaseFor&reason&_Stub, _TEXT
endm
GenerateRedirectedHandledJITCaseStub GCThreadControl
GenerateRedirectedHandledJITCaseStub DbgThreadControl
GenerateRedirectedHandledJITCaseStub UserSuspend
ifdef _DEBUG
ifdef HAVE_GCCOVER
GenerateRedirectedHandledJITCaseStub GCStress
endif
endif
; scratch area; padding; GSCookie
OFFSET_OF_FRAME = SIZEOF_MAX_OUTGOING_ARGUMENT_HOMES + 8 + SIZEOF_GSCookie
; force evaluation to avoid "expression is too complex errors"
SIZEOF__FaultingExceptionFrame = SIZEOF__FaultingExceptionFrame
GenerateRedirectedStubWithFrame macro STUB, FILTER, TARGET
altentry STUB&_RspAligned
NESTED_ENTRY STUB, _TEXT, FILTER
;
; IN: rcx: original IP before redirect
;
mov rdx, rsp
; This push of the return address must not be recorded in the unwind
; info. After this push, unwinding will work.
push rcx
test rsp, 0fh
jnz STUB&_FixRsp
STUB&_RspAligned:
; Any stack operations hereafter must be recorded in the unwind info, but
; only nonvolatile register locations are needed. Anything else is only
; a "sub rsp, 8" to the unwinder.
; m_ctx must be 16-byte aligned
.errnz (OFFSET_OF_FRAME + SIZEOF__FaultingExceptionFrame) MOD 16
alloc_stack OFFSET_OF_FRAME + SIZEOF__FaultingExceptionFrame
.errnz THROWSTUB_ESTABLISHER_OFFSET_FaultingExceptionFrame - OFFSET_OF_FRAME, THROWSTUB_ESTABLISHER_OFFSET_FaultingExceptionFrame has changed - update asm stubs
END_PROLOGUE
lea rcx, [rsp + OFFSET_OF_FRAME]
mov dword ptr [rcx], 0 ; Initialize vtbl (it is not strictly necessary)
mov dword ptr [rcx + OFFSETOF__FaultingExceptionFrame__m_fFilterExecuted], 0 ; Initialize BOOL for personality routine
call TARGET
; Target should not return.
int 3
NESTED_END STUB, _TEXT
; This function is used by the stub above to adjust the stack alignment. The
; stub can't conditionally push something on the stack because the unwind
; encodings have no way to express that.
;
; CONSIDER: we could move the frame pointer above the FaultingExceptionFrame,
; and detect the misalignment adjustment in
; GetFrameFromRedirectedStubStackFrame. This is probably less code and more
; straightforward.
LEAF_ENTRY STUB&_FixRsp, _TEXT
call STUB&_RspAligned
; Target should not return.
int 3
LEAF_END STUB&_FixRsp, _TEXT
endm
REDIRECT_FOR_THROW_CONTROL_FRAME_SIZE = SIZEOF_MAX_OUTGOING_ARGUMENT_HOMES + 8
NESTED_ENTRY RedirectForThrowControl2, _TEXT
; On entry
; rcx -> FaultingExceptionFrame
; rdx -> Original RSP
alloc_stack REDIRECT_FOR_THROW_CONTROL_FRAME_SIZE
save_reg_postrsp rcx, REDIRECT_FOR_THROW_CONTROL_FRAME_SIZE + 8h ; FaultingExceptionFrame
save_reg_postrsp rdx, REDIRECT_FOR_THROW_CONTROL_FRAME_SIZE + 10h ; Original RSP
END_PROLOGUE
; Fetch rip from a CONTEXT, and store it as our return address.
INLINE_GETTHREAD rcx
call Thread__GetAbortContext
mov rax, [rax + OFFSETOF__CONTEXT__Rip]
mov rdx, [rsp + REDIRECT_FOR_THROW_CONTROL_FRAME_SIZE + 10h] ; Original RSP
mov [rdx - 8], rax
mov rcx, [rsp + REDIRECT_FOR_THROW_CONTROL_FRAME_SIZE + 8h] ; FaultingExceptionFrame
call ThrowControlForThread
; ThrowControlForThread doesn't return.
int 3
NESTED_END RedirectForThrowControl2, _TEXT
GenerateRedirectedStubWithFrame RedirectForThrowControl, HijackHandler, RedirectForThrowControl2
NAKED_THROW_HELPER_FRAME_SIZE = SIZEOF_MAX_OUTGOING_ARGUMENT_HOMES + 8
NESTED_ENTRY NakedThrowHelper2, _TEXT
; On entry
; rcx -> FaultingExceptionFrame
alloc_stack NAKED_THROW_HELPER_FRAME_SIZE
END_PROLOGUE
call LinkFrameAndThrow
; LinkFrameAndThrow doesn't return.
int 3
NESTED_END NakedThrowHelper2, _TEXT
GenerateRedirectedStubWithFrame NakedThrowHelper, FixContextHandler, NakedThrowHelper2
end
| poizan42/coreclr | src/vm/amd64/RedirectedHandledJITCase.asm | Assembly | mit | 7,956 |
\ ******************************************************************
\\ VGM Player
\\ Code module
\ ******************************************************************
VGM_PLAYER_ORG = *
_VGM_TRIGGER_BEAT_ON_VOLUME = TRUE
ORG &0380
GUARD &03E0
\ ******************************************************************
\ * VGM music player data area
\ ******************************************************************
.vgm_player_song_title_len SKIP 1
.vgm_player_song_title SKIP VGM_PLAYER_string_max
.vgm_player_song_author_len SKIP 1
.vgm_player_song_author SKIP VGM_PLAYER_string_max
ORG VGM_PLAYER_ORG
.vgm_player_start
\\ Frequency array for vu-meter effect, plus beat bars for 4 channels
\\ These two must be contiguous in memory
.vgm_freq_array SKIP VGM_FX_num_freqs
.vgm_chan_array SKIP VGM_FX_num_channels
.vgm_player_reg_vals SKIP SN_REG_MAX ; data values passed to each channel during audio playback (4x channels x pitch + volume)
.tmp_var SKIP 1
.tmp_msg_idx SKIP 1
.num_to_bit ; look up bit N
EQUB &01, &02, &04, &08, &10, &20, &40, &80
\ ******************************************************************
\ * VGM music player routines
\ * Plays a RAW format VGM music stream from an Exomiser compressed data stream
\ ******************************************************************
\ * EXO VGM data file
\ * This must be compressed using the following flags:
\ * exomizer.exe raw -c -m 1024 <file.raw> -o <file.exo>
\\ Initialise the VGM player with an Exomizer compressed data stream
\\ X - lo byte of data stream to be played
\\ Y - hi byte of data stream to be played
.vgm_init_stream
{
\\ Initialise exomizer - must have some data ready to decrunch
JSR exo_init_decruncher
\\ Initialise music player - parses header
JSR vgm_init_player
RTS
}
.vgm_init_player ; return non-zero if error
{
\\ <header section>
\\ [byte] - header size - indicates number of bytes in header section
LDA #1
STA vgm_player_packet_offset
jsr exo_get_decrunched_byte
STA tmp_var
CMP #5
BCS parse_header ; we need at least 5 bytes to parse!
JMP error
.parse_header
CLC
ADC vgm_player_packet_offset
STA vgm_player_packet_offset
\\ [byte] - indicates the required playback rate in Hz eg. 50/60/100
jsr exo_get_decrunched_byte ; should really check carry status for EOF
;CMP #VGM_PLAYER_sample_rate ; we only support 50Hz files
;BEQ is_50HZ ; return non-zero to indicate error
;JMP error
.is_50HZ
DEC tmp_var
\\ [byte] - packet count lsb
jsr exo_get_decrunched_byte ; should really check carry status for EOF
STA vgm_player_packet_count
DEC tmp_var
\\ [byte] - packet count msb
jsr exo_get_decrunched_byte ; should really check carry status for EOF
STA vgm_player_packet_count+1
DEC tmp_var
\\ [byte] - duration minutes
jsr exo_get_decrunched_byte ; should really check carry status for EOF
STA vgm_player_duration_mins
DEC tmp_var
\\ [byte] - duration seconds
jsr exo_get_decrunched_byte ; should really check carry status for EOF
STA vgm_player_duration_secs
.header_loop
DEC tmp_var
BEQ done_header
jsr exo_get_decrunched_byte ; should really check carry status for EOF
\\ don't know what this byte is so ignore it
JMP header_loop
.done_header
\\ <title section>
\\ [byte] - title string size
INC vgm_player_packet_offset
jsr exo_get_decrunched_byte ; should really check carry status for EOF
STA tmp_var
CLC
ADC vgm_player_packet_offset
STA vgm_player_packet_offset
\\ [dd] ... - ZT title string
LDX #0
.title_loop
STX tmp_msg_idx
LDA tmp_var
BEQ done_title ; make sure we consume all the title string
DEC tmp_var
jsr exo_get_decrunched_byte ; should really check carry status for EOF
LDX tmp_msg_idx
CPX #VGM_PLAYER_string_max
BCS title_loop ; don't write if buffer full
STA vgm_player_song_title,X
INX
JMP title_loop
\\ Where title string is smaller than our buffer
.done_title
STX vgm_player_song_title_len
LDA #' '
.title_pad_loop
CPX #VGM_PLAYER_string_max
BCS done_title_padding
STA vgm_player_song_title,X
INX
JMP title_pad_loop
.done_title_padding
\\ <author section>
\\ [byte] - author string size
INC vgm_player_packet_offset
jsr exo_get_decrunched_byte ; should really check carry status for EOF
STA tmp_var
CLC
ADC vgm_player_packet_offset
STA vgm_player_packet_offset
\\ [dd] ... - ZT author string
LDX #0
.author_loop
STX tmp_msg_idx
LDA tmp_var
BEQ done_author ; make sure we consume all the author string
DEC tmp_var
jsr exo_get_decrunched_byte ; should really check carry status for EOF
LDX tmp_msg_idx
CPX #VGM_PLAYER_string_max
BCS author_loop
STA vgm_player_song_author,X ; don't write if buffer full
INX
JMP author_loop
\\ Where author string is smaller than our buffer
.done_author
STX vgm_player_song_author_len
LDA #' '
.author_pad_loop
CPX #VGM_PLAYER_string_max
BCS done_author_padding
STA vgm_player_song_author,X
INX
JMP author_pad_loop
.done_author_padding
\\ Initialise vars
LDA #&FF
STA vgm_player_counter
STA vgm_player_counter+1
LDA #0
STA vgm_player_ended
STA vgm_player_last_reg
STA vgm_player_reg_bits
\\ Return zero
RTS
\\ Return error
.error
LDA #&FF
RTS
}
.deinit_player
{
\\ Zero volume on all channels
LDA #&9F: JSR psg_strobe
LDA #&BF: JSR psg_strobe
LDA #&DF: JSR psg_strobe
LDA #&FF: JSR psg_strobe
.return
RTS
}
.poll_player
{
\\ Assume this is called every 20ms..
LDA #0
STA vgm_player_reg_bits
LDA vgm_player_ended
BNE _sample_end
\\ <packets section>
\\ [byte] - indicating number of data writes within the current packet (max 11)
\\ [dd] ... - data
\\ [byte] - number of data writes within the next packet
\\ [dd] ... - data
\\ ...`
\\ <eof section>
\\ [0xff] - eof
\\ Get next byte from the stream
jsr exo_get_decrunched_byte
bcs _sample_end
cmp #&ff
beq _player_end
\\ Byte is #data bytes to send to sound chip:
TAY
.sound_data_loop
BEQ wait_20_ms
TYA:PHA
jsr exo_get_decrunched_byte
bcc not_sample_end
PLA
JMP _sample_end
.not_sample_end
JSR psg_decode
JSR psg_strobe
PLA:TAY:DEY
JMP sound_data_loop
.wait_20_ms
INC vgm_player_counter ; indicate we have completed another frame of audio
BNE no_carry
INC vgm_player_counter+1
.no_carry
CLC
RTS
._player_end
STA vgm_player_ended
\\ Silence sound chip
JSR deinit_player
INC vgm_player_counter ; indicate we have completed one last frame of audio
BNE _sample_end
INC vgm_player_counter+1
._sample_end
SEC
RTS
}
.psg_strobe
{
sei ; **SELF-MODIFIED CODE**
ldy #255
sty $fe43
sta $fe41
lda #0
sta $fe40
nop
nop
nop
nop
nop
nop
lda #$08
sta $fe40
cli ; **SELF-MODIFIED CODE**
RTS
}
PSG_STROBE_SEI_INSN = psg_strobe
PSG_STROBE_CLI_INSN = psg_strobe + 25
.psg_decode
{
STA vgm_player_data
AND #SN_FREQ_BYTE_MASK
BEQ second_byte
\\ First byte
\\ Obtain register fields
\\ Get register from bits 7,6,5
LDA vgm_player_data
AND #SN_REG_MASK
LSR A:LSR A:LSR A:LSR A
STA vgm_player_last_reg
\\ Y is our register number
TAY
\\ Set bit field for each register used this frame
LDA num_to_bit,Y ; look up bit for reg number
ORA vgm_player_reg_bits ; mask in bit
STA vgm_player_reg_bits ; ** COULD BE REMOVED FOR BEEB-STEP
\\ Is this tone or volume register?
TYA
AND #&01
BEQ process_tone_data
\\ Volume data
LDA vgm_player_data
AND #SN_VOL_MASK
STA vgm_player_reg_vals,Y
\\ Invert volume (0 = max 15 = off)
SEC
LDA #SN_VOL_MAX
SBC vgm_player_reg_vals,Y
STA vgm_player_reg_vals,Y
IF _VGM_TRIGGER_BEAT_ON_VOLUME
;BEQ return ; for non zero volume only
JMP trigger_beat
ELSE
JMP return
ENDIF
\\ Frequency / tone data
.process_tone_data
CPY #SN_REG_NOISE_CTRL ; Y already register number
BNE tone_channel
\\ Noise channel
LDA vgm_player_data
AND #(SN_NF_MASK OR SN_FB_MASK) ; store noise freq data
STA vgm_player_reg_vals,Y
JMP trigger_beat
.tone_channel
LDA vgm_player_data
AND #SN_FREQ_FIRST_BYTE_MASK ; F3 - F0
LSR A: LSR A ; lose bottom 2 bits
STA vgm_player_reg_vals,Y
.trigger_beat
\\ trigger the beat effect for this channel
TYA:LSR A:TAY ; channel is register / 2
LDA #9
STA vgm_chan_array, Y
JMP return
.second_byte
LDA vgm_player_data
AND #SN_FREQ_SECOND_BYTE_MASK ; F9 - F4
STA tmp_var
ASL A: ASL A ; put 6 bits to top of byte
LDY vgm_player_last_reg
ORA vgm_player_reg_vals,Y ; combine with bottom 2 bits
STA vgm_player_reg_vals,Y
\\ trigger the beat effect for this channel
; technically correct, but better visuals without this.
; TYA:LSR A:TAY ; channel is register / 2
; LDA #9
; STA vgm_chan_array, Y
; LDA tmp_var
; map 8 bit frequency to frequency trigger table
FOR n,1,8-VGM_FX_num_freqs_bits
LSR A
NEXT
\\ invert
STA tmp_var
LDA #VGM_FX_num_freqs-1
SEC
SBC tmp_var
TAX
LDA #15
STA vgm_freq_array,X
.return
LDA vgm_player_data
RTS
}
.vgm_player_end
| bitshifters/beeb-step | lib/vgmplayer.asm | Assembly | mit | 8,912 |
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
; Copyright(c) 2011-2015 Intel Corporation All rights reserved.
;
; Redistribution and use in source and binary forms, with or without
; modification, are permitted provided that the following conditions
; are met:
; * Redistributions of source code must retain the above copyright
; notice, this list of conditions and the following disclaimer.
; * Redistributions in binary form must reproduce the above copyright
; notice, this list of conditions and the following disclaimer in
; the documentation and/or other materials provided with the
; distribution.
; * Neither the name of Intel Corporation nor the names of its
; contributors may be used to endorse or promote products derived
; from this software without specific prior written permission.
;
; THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
; "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
; LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
; A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
; OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
; SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
; LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
; DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
; THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
; (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
; OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;;;
;;; gf_2vect_mad_sse(len, vec, vec_i, mul_array, src, dest);
;;;
%include "reg_sizes.asm"
%define PS 8
%ifidn __OUTPUT_FORMAT__, win64
%define arg0 rcx
%define arg0.w ecx
%define arg1 rdx
%define arg2 r8
%define arg3 r9
%define arg4 r12
%define arg5 r15
%define tmp r11
%define tmp2 r10
%define return rax
%define return.w eax
%define stack_size 16*9 + 3*8
%define arg(x) [rsp + stack_size + PS + PS*x]
%define func(x) proc_frame x
%macro FUNC_SAVE 0
sub rsp, stack_size
movdqa [rsp+16*0],xmm6
movdqa [rsp+16*1],xmm7
movdqa [rsp+16*2],xmm8
movdqa [rsp+16*3],xmm9
movdqa [rsp+16*4],xmm10
movdqa [rsp+16*5],xmm11
movdqa [rsp+16*6],xmm12
movdqa [rsp+16*7],xmm13
movdqa [rsp+16*8],xmm14
save_reg r12, 9*16 + 0*8
save_reg r15, 9*16 + 1*8
end_prolog
mov arg4, arg(4)
mov arg5, arg(5)
%endmacro
%macro FUNC_RESTORE 0
movdqa xmm6, [rsp+16*0]
movdqa xmm7, [rsp+16*1]
movdqa xmm8, [rsp+16*2]
movdqa xmm9, [rsp+16*3]
movdqa xmm10, [rsp+16*4]
movdqa xmm11, [rsp+16*5]
movdqa xmm12, [rsp+16*6]
movdqa xmm13, [rsp+16*7]
movdqa xmm14, [rsp+16*8]
mov r12, [rsp + 9*16 + 0*8]
mov r15, [rsp + 9*16 + 1*8]
add rsp, stack_size
%endmacro
%elifidn __OUTPUT_FORMAT__, elf64
%define arg0 rdi
%define arg0.w edi
%define arg1 rsi
%define arg2 rdx
%define arg3 rcx
%define arg4 r8
%define arg5 r9
%define tmp r11
%define tmp2 r10
%define return rax
%define return.w eax
%define func(x) x: endbranch
%define FUNC_SAVE
%define FUNC_RESTORE
%endif
;;; gf_2vect_mad_sse(len, vec, vec_i, mul_array, src, dest)
%define len arg0
%define len.w arg0.w
%define vec arg1
%define vec_i arg2
%define mul_array arg3
%define src arg4
%define dest1 arg5
%define pos return
%define pos.w return.w
%define dest2 tmp2
%ifndef EC_ALIGNED_ADDR
;;; Use Un-aligned load/store
%define XLDR movdqu
%define XSTR movdqu
%else
;;; Use Non-temporal load/stor
%ifdef NO_NT_LDST
%define XLDR movdqa
%define XSTR movdqa
%else
%define XLDR movntdqa
%define XSTR movntdq
%endif
%endif
default rel
[bits 64]
section .text
%define xmask0f xmm14
%define xgft1_lo xmm13
%define xgft1_hi xmm12
%define xgft2_lo xmm11
%define xgft2_hi xmm10
%define x0 xmm0
%define xtmpa xmm1
%define xtmph1 xmm2
%define xtmpl1 xmm3
%define xtmph2 xmm4
%define xtmpl2 xmm5
%define xd1 xmm6
%define xd2 xmm7
%define xtmpd1 xmm8
%define xtmpd2 xmm9
align 16
mk_global gf_2vect_mad_sse, function
func(gf_2vect_mad_sse)
FUNC_SAVE
sub len, 16
jl .return_fail
xor pos, pos
movdqa xmask0f, [mask0f] ;Load mask of lower nibble in each byte
sal vec_i, 5 ;Multiply by 32
sal vec, 5
lea tmp, [mul_array + vec_i]
movdqu xgft1_lo,[tmp] ;Load array Ax{00}, Ax{01}, Ax{02}, ...
movdqu xgft1_hi, [tmp+16] ; " Ax{00}, Ax{10}, Ax{20}, ... , Ax{f0}
movdqu xgft2_lo, [tmp+vec] ;Load array Bx{00}, Bx{01}, Bx{02}, ...
movdqu xgft2_hi, [tmp+vec+16] ; " Bx{00}, Bx{10}, Bx{20}, ... , Bx{f0}
mov dest2, [dest1+PS]
mov dest1, [dest1]
XLDR xtmpd1, [dest1+len] ;backup the last 16 bytes in dest
XLDR xtmpd2, [dest2+len] ;backup the last 16 bytes in dest
.loop16:
XLDR xd1, [dest1+pos] ;Get next dest vector
XLDR xd2, [dest2+pos] ;Get next dest vector
.loop16_overlap:
XLDR x0, [src+pos] ;Get next source vector
movdqa xtmph1, xgft1_hi ;Reload const array registers
movdqa xtmpl1, xgft1_lo
movdqa xtmph2, xgft2_hi ;Reload const array registers
movdqa xtmpl2, xgft2_lo
movdqa xtmpa, x0 ;Keep unshifted copy of src
psraw x0, 4 ;Shift to put high nibble into bits 4-0
pand x0, xmask0f ;Mask high src nibble in bits 4-0
pand xtmpa, xmask0f ;Mask low src nibble in bits 4-0
pshufb xtmph1, x0 ;Lookup mul table of high nibble
pshufb xtmpl1, xtmpa ;Lookup mul table of low nibble
pxor xtmph1, xtmpl1 ;GF add high and low partials
pxor xd1, xtmph1
pshufb xtmph2, x0 ;Lookup mul table of high nibble
pshufb xtmpl2, xtmpa ;Lookup mul table of low nibble
pxor xtmph2, xtmpl2 ;GF add high and low partials
pxor xd2, xtmph2
XSTR [dest1+pos], xd1 ;Store result
XSTR [dest2+pos], xd2 ;Store result
add pos, 16 ;Loop on 16 bytes at a time
cmp pos, len
jle .loop16
lea tmp, [len + 16]
cmp pos, tmp
je .return_pass
;; Tail len
mov pos, len ;Overlapped offset length-16
movdqa xd1, xtmpd1 ;Restore xd1
movdqa xd2, xtmpd2 ;Restore xd2
jmp .loop16_overlap ;Do one more overlap pass
.return_pass:
FUNC_RESTORE
mov return, 0
ret
.return_fail:
FUNC_RESTORE
mov return, 1
ret
endproc_frame
section .data
align 16
mask0f:
dq 0x0f0f0f0f0f0f0f0f, 0x0f0f0f0f0f0f0f0f
;;; func core, ver, snum
slversion gf_2vect_mad_sse, 00, 01, 0203
| Intel-HLS/GKL | src/main/native/compression/isa-l-master/erasure_code/gf_2vect_mad_sse.asm | Assembly | mit | 6,391 |
; ASM source file created by SevenuP v1.21
; SevenuP (C) Copyright 2002-2007 by Jaime Tejedor Gomez, aka Metalbrain
;GRAPHIC DATA:
;Pixel Size: ( 24, 32)
;Char Size: ( 3, 4)
;Frames: 4
;Sort Priorities: X char, Char line, Y char, Frame number
;Data Outputted: Gfx
;Interleave: Sprite
;Mask: No
esqueleto_espada_golpealto:
DEFB 0,255, 96, 1,254,104, 3,240
DEFB 0, 3,128, 64, 4, 0, 72, 0
DEFB 3, 68, 0, 7, 32, 0, 13,164
DEFB 0, 2, 32, 0, 24,196, 0, 27
DEFB 8, 0, 64, 96, 0, 95, 64, 0
DEFB 1, 0, 0, 29, 0, 0, 2, 0
DEFB 0, 12, 0, 0, 1, 0, 0, 18
DEFB 0, 0, 57, 0, 0, 90, 80, 0
DEFB 100, 8, 0, 32, 20, 0, 32, 8
DEFB 0, 32, 0, 0, 32, 32, 0, 80
DEFB 0, 0,160, 34, 1, 0, 68, 1
DEFB 0, 40, 3,128, 64, 7,240, 0
DEFB 0, 0, 0, 0, 0, 0, 0, 1
DEFB 240, 0, 3,248, 0, 3,168, 0
DEFB 3,100, 0, 1,184, 0, 0, 76
DEFB 0, 5,160, 0, 13,152, 0, 8
DEFB 64, 0, 1, 49, 0, 0, 76, 0
DEFB 15,195, 0, 0,128, 0, 15, 0
DEFB 0, 0, 0, 0, 16, 0, 0, 31
DEFB 232, 0, 8, 20, 0, 1, 8, 0
DEFB 0, 16, 0, 1, 32, 0, 0, 64
DEFB 0, 2, 64, 0, 0,192, 0, 5
DEFB 192, 0, 0, 96, 0, 8, 24, 0
DEFB 16, 0, 0, 32, 0, 0, 85, 0
DEFB 0,170, 0, 0, 85, 0, 0, 42
DEFB 128, 0, 85, 64, 0, 42,160, 0
DEFB 21, 80, 0, 42,168, 0, 85, 80
DEFB 0, 42,168, 0, 85, 84, 2,170
DEFB 170, 84, 85, 85, 0, 0, 0,237
DEFB 255,255, 12,127,252, 0, 15,224
DEFB 0, 0, 0, 0, 0, 0, 0, 0
DEFB 0, 0, 0, 0, 0, 0, 0, 0
DEFB 0, 0, 0, 0, 0, 0, 0, 0
DEFB 0, 0, 0, 0, 0, 0, 0, 0
DEFB 0, 0, 0, 0, 0, 0, 0, 0
DEFB 0, 0, 0, 0, 0, 0, 0, 0
DEFB 0, 0, 0, 0, 0, 0, 0, 0
DEFB 0, 0, 0, 0, 0, 60, 0, 0
DEFB 126, 0, 0,238, 0, 0,164, 0
DEFB 0, 30, 0, 6, 62, 0, 6, 20
DEFB 128, 1,128, 64, 0, 96,168, 1
DEFB 158, 4, 0, 0, 1, 15,255,236
DEFB 1,255, 12, 0, 0, 0, 0, 8
DEFB 0, 0,226, 0, 0,118, 0, 1
DEFB 180, 0, 1,137, 0, 0, 96,128
DEFB 0, 24, 64, 0, 6, 32, 0, 5
DEFB 80, 0, 10, 32, 0, 48, 64, 0
DEFB 64,128, 1,129, 0, 3,250,168 | fjpena/sword-of-ianna-zx | artwork/esqueleto/esqueleto_espada_golpealto.asm | Assembly | apache-2.0 | 2,191 |
_init: file format elf32-i386
Disassembly of section .text:
00000000 <main>:
char *argv[] = { "sh", 0 };
int
main(void)
{
0: 55 push %ebp
1: 89 e5 mov %esp,%ebp
3: 83 e4 f0 and $0xfffffff0,%esp
6: 83 ec 20 sub $0x20,%esp
int pid, wpid;
if(open("console", O_RDWR) < 0){
9: c7 44 24 04 02 00 00 movl $0x2,0x4(%esp)
10: 00
11: c7 04 24 c6 08 00 00 movl $0x8c6,(%esp)
18: e8 9a 03 00 00 call 3b7 <open>
1d: 85 c0 test %eax,%eax
1f: 79 30 jns 51 <main+0x51>
mknod("console", 1, 1);
21: c7 44 24 08 01 00 00 movl $0x1,0x8(%esp)
28: 00
29: c7 44 24 04 01 00 00 movl $0x1,0x4(%esp)
30: 00
31: c7 04 24 c6 08 00 00 movl $0x8c6,(%esp)
38: e8 82 03 00 00 call 3bf <mknod>
open("console", O_RDWR);
3d: c7 44 24 04 02 00 00 movl $0x2,0x4(%esp)
44: 00
45: c7 04 24 c6 08 00 00 movl $0x8c6,(%esp)
4c: e8 66 03 00 00 call 3b7 <open>
}
dup(0); // stdout
51: c7 04 24 00 00 00 00 movl $0x0,(%esp)
58: e8 92 03 00 00 call 3ef <dup>
dup(0); // stderr
5d: c7 04 24 00 00 00 00 movl $0x0,(%esp)
64: e8 86 03 00 00 call 3ef <dup>
for(;;){
printf(1, "init: starting sh\n");
69: c7 44 24 04 ce 08 00 movl $0x8ce,0x4(%esp)
70: 00
71: c7 04 24 01 00 00 00 movl $0x1,(%esp)
78: e8 7a 04 00 00 call 4f7 <printf>
pid = fork();
7d: e8 ed 02 00 00 call 36f <fork>
82: 89 44 24 1c mov %eax,0x1c(%esp)
if(pid < 0){
86: 83 7c 24 1c 00 cmpl $0x0,0x1c(%esp)
8b: 79 19 jns a6 <main+0xa6>
printf(1, "init: fork failed\n");
8d: c7 44 24 04 e1 08 00 movl $0x8e1,0x4(%esp)
94: 00
95: c7 04 24 01 00 00 00 movl $0x1,(%esp)
9c: e8 56 04 00 00 call 4f7 <printf>
exit();
a1: e8 d1 02 00 00 call 377 <exit>
}
if(pid == 0){
a6: 83 7c 24 1c 00 cmpl $0x0,0x1c(%esp)
ab: 75 2d jne da <main+0xda>
exec("sh", argv);
ad: c7 44 24 04 60 0b 00 movl $0xb60,0x4(%esp)
b4: 00
b5: c7 04 24 c3 08 00 00 movl $0x8c3,(%esp)
bc: e8 ee 02 00 00 call 3af <exec>
printf(1, "init: exec sh failed\n");
c1: c7 44 24 04 f4 08 00 movl $0x8f4,0x4(%esp)
c8: 00
c9: c7 04 24 01 00 00 00 movl $0x1,(%esp)
d0: e8 22 04 00 00 call 4f7 <printf>
exit();
d5: e8 9d 02 00 00 call 377 <exit>
}
while((wpid=wait()) >= 0 && wpid != pid)
da: eb 14 jmp f0 <main+0xf0>
printf(1, "zombie!\n");
dc: c7 44 24 04 0a 09 00 movl $0x90a,0x4(%esp)
e3: 00
e4: c7 04 24 01 00 00 00 movl $0x1,(%esp)
eb: e8 07 04 00 00 call 4f7 <printf>
if(pid == 0){
exec("sh", argv);
printf(1, "init: exec sh failed\n");
exit();
}
while((wpid=wait()) >= 0 && wpid != pid)
f0: e8 8a 02 00 00 call 37f <wait>
f5: 89 44 24 18 mov %eax,0x18(%esp)
f9: 83 7c 24 18 00 cmpl $0x0,0x18(%esp)
fe: 78 0a js 10a <main+0x10a>
100: 8b 44 24 18 mov 0x18(%esp),%eax
104: 3b 44 24 1c cmp 0x1c(%esp),%eax
108: 75 d2 jne dc <main+0xdc>
printf(1, "zombie!\n");
}
10a: e9 5a ff ff ff jmp 69 <main+0x69>
0000010f <stosb>:
"cc");
}
static inline void
stosb(void *addr, int data, int cnt)
{
10f: 55 push %ebp
110: 89 e5 mov %esp,%ebp
112: 57 push %edi
113: 53 push %ebx
asm volatile("cld; rep stosb" :
114: 8b 4d 08 mov 0x8(%ebp),%ecx
117: 8b 55 10 mov 0x10(%ebp),%edx
11a: 8b 45 0c mov 0xc(%ebp),%eax
11d: 89 cb mov %ecx,%ebx
11f: 89 df mov %ebx,%edi
121: 89 d1 mov %edx,%ecx
123: fc cld
124: f3 aa rep stos %al,%es:(%edi)
126: 89 ca mov %ecx,%edx
128: 89 fb mov %edi,%ebx
12a: 89 5d 08 mov %ebx,0x8(%ebp)
12d: 89 55 10 mov %edx,0x10(%ebp)
"=D" (addr), "=c" (cnt) :
"0" (addr), "1" (cnt), "a" (data) :
"memory", "cc");
}
130: 5b pop %ebx
131: 5f pop %edi
132: 5d pop %ebp
133: c3 ret
00000134 <strcpy>:
#include "user.h"
#include "x86.h"
char*
strcpy(char *s, char *t)
{
134: 55 push %ebp
135: 89 e5 mov %esp,%ebp
137: 83 ec 10 sub $0x10,%esp
char *os;
os = s;
13a: 8b 45 08 mov 0x8(%ebp),%eax
13d: 89 45 fc mov %eax,-0x4(%ebp)
while((*s++ = *t++) != 0)
140: 90 nop
141: 8b 45 08 mov 0x8(%ebp),%eax
144: 8d 50 01 lea 0x1(%eax),%edx
147: 89 55 08 mov %edx,0x8(%ebp)
14a: 8b 55 0c mov 0xc(%ebp),%edx
14d: 8d 4a 01 lea 0x1(%edx),%ecx
150: 89 4d 0c mov %ecx,0xc(%ebp)
153: 0f b6 12 movzbl (%edx),%edx
156: 88 10 mov %dl,(%eax)
158: 0f b6 00 movzbl (%eax),%eax
15b: 84 c0 test %al,%al
15d: 75 e2 jne 141 <strcpy+0xd>
;
return os;
15f: 8b 45 fc mov -0x4(%ebp),%eax
}
162: c9 leave
163: c3 ret
00000164 <strcmp>:
int
strcmp(const char *p, const char *q)
{
164: 55 push %ebp
165: 89 e5 mov %esp,%ebp
while(*p && *p == *q)
167: eb 08 jmp 171 <strcmp+0xd>
p++, q++;
169: 83 45 08 01 addl $0x1,0x8(%ebp)
16d: 83 45 0c 01 addl $0x1,0xc(%ebp)
}
int
strcmp(const char *p, const char *q)
{
while(*p && *p == *q)
171: 8b 45 08 mov 0x8(%ebp),%eax
174: 0f b6 00 movzbl (%eax),%eax
177: 84 c0 test %al,%al
179: 74 10 je 18b <strcmp+0x27>
17b: 8b 45 08 mov 0x8(%ebp),%eax
17e: 0f b6 10 movzbl (%eax),%edx
181: 8b 45 0c mov 0xc(%ebp),%eax
184: 0f b6 00 movzbl (%eax),%eax
187: 38 c2 cmp %al,%dl
189: 74 de je 169 <strcmp+0x5>
p++, q++;
return (uchar)*p - (uchar)*q;
18b: 8b 45 08 mov 0x8(%ebp),%eax
18e: 0f b6 00 movzbl (%eax),%eax
191: 0f b6 d0 movzbl %al,%edx
194: 8b 45 0c mov 0xc(%ebp),%eax
197: 0f b6 00 movzbl (%eax),%eax
19a: 0f b6 c0 movzbl %al,%eax
19d: 29 c2 sub %eax,%edx
19f: 89 d0 mov %edx,%eax
}
1a1: 5d pop %ebp
1a2: c3 ret
000001a3 <strlen>:
uint
strlen(char *s)
{
1a3: 55 push %ebp
1a4: 89 e5 mov %esp,%ebp
1a6: 83 ec 10 sub $0x10,%esp
int n;
for(n = 0; s[n]; n++)
1a9: c7 45 fc 00 00 00 00 movl $0x0,-0x4(%ebp)
1b0: eb 04 jmp 1b6 <strlen+0x13>
1b2: 83 45 fc 01 addl $0x1,-0x4(%ebp)
1b6: 8b 55 fc mov -0x4(%ebp),%edx
1b9: 8b 45 08 mov 0x8(%ebp),%eax
1bc: 01 d0 add %edx,%eax
1be: 0f b6 00 movzbl (%eax),%eax
1c1: 84 c0 test %al,%al
1c3: 75 ed jne 1b2 <strlen+0xf>
;
return n;
1c5: 8b 45 fc mov -0x4(%ebp),%eax
}
1c8: c9 leave
1c9: c3 ret
000001ca <memset>:
void*
memset(void *dst, int c, uint n)
{
1ca: 55 push %ebp
1cb: 89 e5 mov %esp,%ebp
1cd: 83 ec 0c sub $0xc,%esp
stosb(dst, c, n);
1d0: 8b 45 10 mov 0x10(%ebp),%eax
1d3: 89 44 24 08 mov %eax,0x8(%esp)
1d7: 8b 45 0c mov 0xc(%ebp),%eax
1da: 89 44 24 04 mov %eax,0x4(%esp)
1de: 8b 45 08 mov 0x8(%ebp),%eax
1e1: 89 04 24 mov %eax,(%esp)
1e4: e8 26 ff ff ff call 10f <stosb>
return dst;
1e9: 8b 45 08 mov 0x8(%ebp),%eax
}
1ec: c9 leave
1ed: c3 ret
000001ee <strchr>:
char*
strchr(const char *s, char c)
{
1ee: 55 push %ebp
1ef: 89 e5 mov %esp,%ebp
1f1: 83 ec 04 sub $0x4,%esp
1f4: 8b 45 0c mov 0xc(%ebp),%eax
1f7: 88 45 fc mov %al,-0x4(%ebp)
for(; *s; s++)
1fa: eb 14 jmp 210 <strchr+0x22>
if(*s == c)
1fc: 8b 45 08 mov 0x8(%ebp),%eax
1ff: 0f b6 00 movzbl (%eax),%eax
202: 3a 45 fc cmp -0x4(%ebp),%al
205: 75 05 jne 20c <strchr+0x1e>
return (char*)s;
207: 8b 45 08 mov 0x8(%ebp),%eax
20a: eb 13 jmp 21f <strchr+0x31>
}
char*
strchr(const char *s, char c)
{
for(; *s; s++)
20c: 83 45 08 01 addl $0x1,0x8(%ebp)
210: 8b 45 08 mov 0x8(%ebp),%eax
213: 0f b6 00 movzbl (%eax),%eax
216: 84 c0 test %al,%al
218: 75 e2 jne 1fc <strchr+0xe>
if(*s == c)
return (char*)s;
return 0;
21a: b8 00 00 00 00 mov $0x0,%eax
}
21f: c9 leave
220: c3 ret
00000221 <gets>:
char*
gets(char *buf, int max)
{
221: 55 push %ebp
222: 89 e5 mov %esp,%ebp
224: 83 ec 28 sub $0x28,%esp
int i, cc;
char c;
for(i=0; i+1 < max; ){
227: c7 45 f4 00 00 00 00 movl $0x0,-0xc(%ebp)
22e: eb 4c jmp 27c <gets+0x5b>
cc = read(0, &c, 1);
230: c7 44 24 08 01 00 00 movl $0x1,0x8(%esp)
237: 00
238: 8d 45 ef lea -0x11(%ebp),%eax
23b: 89 44 24 04 mov %eax,0x4(%esp)
23f: c7 04 24 00 00 00 00 movl $0x0,(%esp)
246: e8 44 01 00 00 call 38f <read>
24b: 89 45 f0 mov %eax,-0x10(%ebp)
if(cc < 1)
24e: 83 7d f0 00 cmpl $0x0,-0x10(%ebp)
252: 7f 02 jg 256 <gets+0x35>
break;
254: eb 31 jmp 287 <gets+0x66>
buf[i++] = c;
256: 8b 45 f4 mov -0xc(%ebp),%eax
259: 8d 50 01 lea 0x1(%eax),%edx
25c: 89 55 f4 mov %edx,-0xc(%ebp)
25f: 89 c2 mov %eax,%edx
261: 8b 45 08 mov 0x8(%ebp),%eax
264: 01 c2 add %eax,%edx
266: 0f b6 45 ef movzbl -0x11(%ebp),%eax
26a: 88 02 mov %al,(%edx)
if(c == '\n' || c == '\r')
26c: 0f b6 45 ef movzbl -0x11(%ebp),%eax
270: 3c 0a cmp $0xa,%al
272: 74 13 je 287 <gets+0x66>
274: 0f b6 45 ef movzbl -0x11(%ebp),%eax
278: 3c 0d cmp $0xd,%al
27a: 74 0b je 287 <gets+0x66>
gets(char *buf, int max)
{
int i, cc;
char c;
for(i=0; i+1 < max; ){
27c: 8b 45 f4 mov -0xc(%ebp),%eax
27f: 83 c0 01 add $0x1,%eax
282: 3b 45 0c cmp 0xc(%ebp),%eax
285: 7c a9 jl 230 <gets+0xf>
break;
buf[i++] = c;
if(c == '\n' || c == '\r')
break;
}
buf[i] = '\0';
287: 8b 55 f4 mov -0xc(%ebp),%edx
28a: 8b 45 08 mov 0x8(%ebp),%eax
28d: 01 d0 add %edx,%eax
28f: c6 00 00 movb $0x0,(%eax)
return buf;
292: 8b 45 08 mov 0x8(%ebp),%eax
}
295: c9 leave
296: c3 ret
00000297 <stat>:
int
stat(char *n, struct stat *st)
{
297: 55 push %ebp
298: 89 e5 mov %esp,%ebp
29a: 83 ec 28 sub $0x28,%esp
int fd;
int r;
fd = open(n, O_RDONLY);
29d: c7 44 24 04 00 00 00 movl $0x0,0x4(%esp)
2a4: 00
2a5: 8b 45 08 mov 0x8(%ebp),%eax
2a8: 89 04 24 mov %eax,(%esp)
2ab: e8 07 01 00 00 call 3b7 <open>
2b0: 89 45 f4 mov %eax,-0xc(%ebp)
if(fd < 0)
2b3: 83 7d f4 00 cmpl $0x0,-0xc(%ebp)
2b7: 79 07 jns 2c0 <stat+0x29>
return -1;
2b9: b8 ff ff ff ff mov $0xffffffff,%eax
2be: eb 23 jmp 2e3 <stat+0x4c>
r = fstat(fd, st);
2c0: 8b 45 0c mov 0xc(%ebp),%eax
2c3: 89 44 24 04 mov %eax,0x4(%esp)
2c7: 8b 45 f4 mov -0xc(%ebp),%eax
2ca: 89 04 24 mov %eax,(%esp)
2cd: e8 fd 00 00 00 call 3cf <fstat>
2d2: 89 45 f0 mov %eax,-0x10(%ebp)
close(fd);
2d5: 8b 45 f4 mov -0xc(%ebp),%eax
2d8: 89 04 24 mov %eax,(%esp)
2db: e8 bf 00 00 00 call 39f <close>
return r;
2e0: 8b 45 f0 mov -0x10(%ebp),%eax
}
2e3: c9 leave
2e4: c3 ret
000002e5 <atoi>:
int
atoi(const char *s)
{
2e5: 55 push %ebp
2e6: 89 e5 mov %esp,%ebp
2e8: 83 ec 10 sub $0x10,%esp
int n;
n = 0;
2eb: c7 45 fc 00 00 00 00 movl $0x0,-0x4(%ebp)
while('0' <= *s && *s <= '9')
2f2: eb 25 jmp 319 <atoi+0x34>
n = n*10 + *s++ - '0';
2f4: 8b 55 fc mov -0x4(%ebp),%edx
2f7: 89 d0 mov %edx,%eax
2f9: c1 e0 02 shl $0x2,%eax
2fc: 01 d0 add %edx,%eax
2fe: 01 c0 add %eax,%eax
300: 89 c1 mov %eax,%ecx
302: 8b 45 08 mov 0x8(%ebp),%eax
305: 8d 50 01 lea 0x1(%eax),%edx
308: 89 55 08 mov %edx,0x8(%ebp)
30b: 0f b6 00 movzbl (%eax),%eax
30e: 0f be c0 movsbl %al,%eax
311: 01 c8 add %ecx,%eax
313: 83 e8 30 sub $0x30,%eax
316: 89 45 fc mov %eax,-0x4(%ebp)
atoi(const char *s)
{
int n;
n = 0;
while('0' <= *s && *s <= '9')
319: 8b 45 08 mov 0x8(%ebp),%eax
31c: 0f b6 00 movzbl (%eax),%eax
31f: 3c 2f cmp $0x2f,%al
321: 7e 0a jle 32d <atoi+0x48>
323: 8b 45 08 mov 0x8(%ebp),%eax
326: 0f b6 00 movzbl (%eax),%eax
329: 3c 39 cmp $0x39,%al
32b: 7e c7 jle 2f4 <atoi+0xf>
n = n*10 + *s++ - '0';
return n;
32d: 8b 45 fc mov -0x4(%ebp),%eax
}
330: c9 leave
331: c3 ret
00000332 <memmove>:
void*
memmove(void *vdst, void *vsrc, int n)
{
332: 55 push %ebp
333: 89 e5 mov %esp,%ebp
335: 83 ec 10 sub $0x10,%esp
char *dst, *src;
dst = vdst;
338: 8b 45 08 mov 0x8(%ebp),%eax
33b: 89 45 fc mov %eax,-0x4(%ebp)
src = vsrc;
33e: 8b 45 0c mov 0xc(%ebp),%eax
341: 89 45 f8 mov %eax,-0x8(%ebp)
while(n-- > 0)
344: eb 17 jmp 35d <memmove+0x2b>
*dst++ = *src++;
346: 8b 45 fc mov -0x4(%ebp),%eax
349: 8d 50 01 lea 0x1(%eax),%edx
34c: 89 55 fc mov %edx,-0x4(%ebp)
34f: 8b 55 f8 mov -0x8(%ebp),%edx
352: 8d 4a 01 lea 0x1(%edx),%ecx
355: 89 4d f8 mov %ecx,-0x8(%ebp)
358: 0f b6 12 movzbl (%edx),%edx
35b: 88 10 mov %dl,(%eax)
{
char *dst, *src;
dst = vdst;
src = vsrc;
while(n-- > 0)
35d: 8b 45 10 mov 0x10(%ebp),%eax
360: 8d 50 ff lea -0x1(%eax),%edx
363: 89 55 10 mov %edx,0x10(%ebp)
366: 85 c0 test %eax,%eax
368: 7f dc jg 346 <memmove+0x14>
*dst++ = *src++;
return vdst;
36a: 8b 45 08 mov 0x8(%ebp),%eax
}
36d: c9 leave
36e: c3 ret
0000036f <fork>:
name: \
movl $SYS_ ## name, %eax; \
int $T_SYSCALL; \
ret
SYSCALL(fork)
36f: b8 01 00 00 00 mov $0x1,%eax
374: cd 40 int $0x40
376: c3 ret
00000377 <exit>:
SYSCALL(exit)
377: b8 02 00 00 00 mov $0x2,%eax
37c: cd 40 int $0x40
37e: c3 ret
0000037f <wait>:
SYSCALL(wait)
37f: b8 03 00 00 00 mov $0x3,%eax
384: cd 40 int $0x40
386: c3 ret
00000387 <pipe>:
SYSCALL(pipe)
387: b8 04 00 00 00 mov $0x4,%eax
38c: cd 40 int $0x40
38e: c3 ret
0000038f <read>:
SYSCALL(read)
38f: b8 05 00 00 00 mov $0x5,%eax
394: cd 40 int $0x40
396: c3 ret
00000397 <write>:
SYSCALL(write)
397: b8 10 00 00 00 mov $0x10,%eax
39c: cd 40 int $0x40
39e: c3 ret
0000039f <close>:
SYSCALL(close)
39f: b8 15 00 00 00 mov $0x15,%eax
3a4: cd 40 int $0x40
3a6: c3 ret
000003a7 <kill>:
SYSCALL(kill)
3a7: b8 06 00 00 00 mov $0x6,%eax
3ac: cd 40 int $0x40
3ae: c3 ret
000003af <exec>:
SYSCALL(exec)
3af: b8 07 00 00 00 mov $0x7,%eax
3b4: cd 40 int $0x40
3b6: c3 ret
000003b7 <open>:
SYSCALL(open)
3b7: b8 0f 00 00 00 mov $0xf,%eax
3bc: cd 40 int $0x40
3be: c3 ret
000003bf <mknod>:
SYSCALL(mknod)
3bf: b8 11 00 00 00 mov $0x11,%eax
3c4: cd 40 int $0x40
3c6: c3 ret
000003c7 <unlink>:
SYSCALL(unlink)
3c7: b8 12 00 00 00 mov $0x12,%eax
3cc: cd 40 int $0x40
3ce: c3 ret
000003cf <fstat>:
SYSCALL(fstat)
3cf: b8 08 00 00 00 mov $0x8,%eax
3d4: cd 40 int $0x40
3d6: c3 ret
000003d7 <link>:
SYSCALL(link)
3d7: b8 13 00 00 00 mov $0x13,%eax
3dc: cd 40 int $0x40
3de: c3 ret
000003df <mkdir>:
SYSCALL(mkdir)
3df: b8 14 00 00 00 mov $0x14,%eax
3e4: cd 40 int $0x40
3e6: c3 ret
000003e7 <chdir>:
SYSCALL(chdir)
3e7: b8 09 00 00 00 mov $0x9,%eax
3ec: cd 40 int $0x40
3ee: c3 ret
000003ef <dup>:
SYSCALL(dup)
3ef: b8 0a 00 00 00 mov $0xa,%eax
3f4: cd 40 int $0x40
3f6: c3 ret
000003f7 <getpid>:
SYSCALL(getpid)
3f7: b8 0b 00 00 00 mov $0xb,%eax
3fc: cd 40 int $0x40
3fe: c3 ret
000003ff <sbrk>:
SYSCALL(sbrk)
3ff: b8 0c 00 00 00 mov $0xc,%eax
404: cd 40 int $0x40
406: c3 ret
00000407 <sleep>:
SYSCALL(sleep)
407: b8 0d 00 00 00 mov $0xd,%eax
40c: cd 40 int $0x40
40e: c3 ret
0000040f <uptime>:
SYSCALL(uptime)
40f: b8 0e 00 00 00 mov $0xe,%eax
414: cd 40 int $0x40
416: c3 ret
00000417 <putc>:
#include "stat.h"
#include "user.h"
static void
putc(int fd, char c)
{
417: 55 push %ebp
418: 89 e5 mov %esp,%ebp
41a: 83 ec 18 sub $0x18,%esp
41d: 8b 45 0c mov 0xc(%ebp),%eax
420: 88 45 f4 mov %al,-0xc(%ebp)
write(fd, &c, 1);
423: c7 44 24 08 01 00 00 movl $0x1,0x8(%esp)
42a: 00
42b: 8d 45 f4 lea -0xc(%ebp),%eax
42e: 89 44 24 04 mov %eax,0x4(%esp)
432: 8b 45 08 mov 0x8(%ebp),%eax
435: 89 04 24 mov %eax,(%esp)
438: e8 5a ff ff ff call 397 <write>
}
43d: c9 leave
43e: c3 ret
0000043f <printint>:
static void
printint(int fd, int xx, int base, int sgn)
{
43f: 55 push %ebp
440: 89 e5 mov %esp,%ebp
442: 56 push %esi
443: 53 push %ebx
444: 83 ec 30 sub $0x30,%esp
static char digits[] = "0123456789ABCDEF";
char buf[16];
int i, neg;
uint x;
neg = 0;
447: c7 45 f0 00 00 00 00 movl $0x0,-0x10(%ebp)
if(sgn && xx < 0){
44e: 83 7d 14 00 cmpl $0x0,0x14(%ebp)
452: 74 17 je 46b <printint+0x2c>
454: 83 7d 0c 00 cmpl $0x0,0xc(%ebp)
458: 79 11 jns 46b <printint+0x2c>
neg = 1;
45a: c7 45 f0 01 00 00 00 movl $0x1,-0x10(%ebp)
x = -xx;
461: 8b 45 0c mov 0xc(%ebp),%eax
464: f7 d8 neg %eax
466: 89 45 ec mov %eax,-0x14(%ebp)
469: eb 06 jmp 471 <printint+0x32>
} else {
x = xx;
46b: 8b 45 0c mov 0xc(%ebp),%eax
46e: 89 45 ec mov %eax,-0x14(%ebp)
}
i = 0;
471: c7 45 f4 00 00 00 00 movl $0x0,-0xc(%ebp)
do{
buf[i++] = digits[x % base];
478: 8b 4d f4 mov -0xc(%ebp),%ecx
47b: 8d 41 01 lea 0x1(%ecx),%eax
47e: 89 45 f4 mov %eax,-0xc(%ebp)
481: 8b 5d 10 mov 0x10(%ebp),%ebx
484: 8b 45 ec mov -0x14(%ebp),%eax
487: ba 00 00 00 00 mov $0x0,%edx
48c: f7 f3 div %ebx
48e: 89 d0 mov %edx,%eax
490: 0f b6 80 68 0b 00 00 movzbl 0xb68(%eax),%eax
497: 88 44 0d dc mov %al,-0x24(%ebp,%ecx,1)
}while((x /= base) != 0);
49b: 8b 75 10 mov 0x10(%ebp),%esi
49e: 8b 45 ec mov -0x14(%ebp),%eax
4a1: ba 00 00 00 00 mov $0x0,%edx
4a6: f7 f6 div %esi
4a8: 89 45 ec mov %eax,-0x14(%ebp)
4ab: 83 7d ec 00 cmpl $0x0,-0x14(%ebp)
4af: 75 c7 jne 478 <printint+0x39>
if(neg)
4b1: 83 7d f0 00 cmpl $0x0,-0x10(%ebp)
4b5: 74 10 je 4c7 <printint+0x88>
buf[i++] = '-';
4b7: 8b 45 f4 mov -0xc(%ebp),%eax
4ba: 8d 50 01 lea 0x1(%eax),%edx
4bd: 89 55 f4 mov %edx,-0xc(%ebp)
4c0: c6 44 05 dc 2d movb $0x2d,-0x24(%ebp,%eax,1)
while(--i >= 0)
4c5: eb 1f jmp 4e6 <printint+0xa7>
4c7: eb 1d jmp 4e6 <printint+0xa7>
putc(fd, buf[i]);
4c9: 8d 55 dc lea -0x24(%ebp),%edx
4cc: 8b 45 f4 mov -0xc(%ebp),%eax
4cf: 01 d0 add %edx,%eax
4d1: 0f b6 00 movzbl (%eax),%eax
4d4: 0f be c0 movsbl %al,%eax
4d7: 89 44 24 04 mov %eax,0x4(%esp)
4db: 8b 45 08 mov 0x8(%ebp),%eax
4de: 89 04 24 mov %eax,(%esp)
4e1: e8 31 ff ff ff call 417 <putc>
buf[i++] = digits[x % base];
}while((x /= base) != 0);
if(neg)
buf[i++] = '-';
while(--i >= 0)
4e6: 83 6d f4 01 subl $0x1,-0xc(%ebp)
4ea: 83 7d f4 00 cmpl $0x0,-0xc(%ebp)
4ee: 79 d9 jns 4c9 <printint+0x8a>
putc(fd, buf[i]);
}
4f0: 83 c4 30 add $0x30,%esp
4f3: 5b pop %ebx
4f4: 5e pop %esi
4f5: 5d pop %ebp
4f6: c3 ret
000004f7 <printf>:
// Print to the given fd. Only understands %d, %x, %p, %s.
void
printf(int fd, char *fmt, ...)
{
4f7: 55 push %ebp
4f8: 89 e5 mov %esp,%ebp
4fa: 83 ec 38 sub $0x38,%esp
char *s;
int c, i, state;
uint *ap;
state = 0;
4fd: c7 45 ec 00 00 00 00 movl $0x0,-0x14(%ebp)
ap = (uint*)(void*)&fmt + 1;
504: 8d 45 0c lea 0xc(%ebp),%eax
507: 83 c0 04 add $0x4,%eax
50a: 89 45 e8 mov %eax,-0x18(%ebp)
for(i = 0; fmt[i]; i++){
50d: c7 45 f0 00 00 00 00 movl $0x0,-0x10(%ebp)
514: e9 7c 01 00 00 jmp 695 <printf+0x19e>
c = fmt[i] & 0xff;
519: 8b 55 0c mov 0xc(%ebp),%edx
51c: 8b 45 f0 mov -0x10(%ebp),%eax
51f: 01 d0 add %edx,%eax
521: 0f b6 00 movzbl (%eax),%eax
524: 0f be c0 movsbl %al,%eax
527: 25 ff 00 00 00 and $0xff,%eax
52c: 89 45 e4 mov %eax,-0x1c(%ebp)
if(state == 0){
52f: 83 7d ec 00 cmpl $0x0,-0x14(%ebp)
533: 75 2c jne 561 <printf+0x6a>
if(c == '%'){
535: 83 7d e4 25 cmpl $0x25,-0x1c(%ebp)
539: 75 0c jne 547 <printf+0x50>
state = '%';
53b: c7 45 ec 25 00 00 00 movl $0x25,-0x14(%ebp)
542: e9 4a 01 00 00 jmp 691 <printf+0x19a>
} else {
putc(fd, c);
547: 8b 45 e4 mov -0x1c(%ebp),%eax
54a: 0f be c0 movsbl %al,%eax
54d: 89 44 24 04 mov %eax,0x4(%esp)
551: 8b 45 08 mov 0x8(%ebp),%eax
554: 89 04 24 mov %eax,(%esp)
557: e8 bb fe ff ff call 417 <putc>
55c: e9 30 01 00 00 jmp 691 <printf+0x19a>
}
} else if(state == '%'){
561: 83 7d ec 25 cmpl $0x25,-0x14(%ebp)
565: 0f 85 26 01 00 00 jne 691 <printf+0x19a>
if(c == 'd'){
56b: 83 7d e4 64 cmpl $0x64,-0x1c(%ebp)
56f: 75 2d jne 59e <printf+0xa7>
printint(fd, *ap, 10, 1);
571: 8b 45 e8 mov -0x18(%ebp),%eax
574: 8b 00 mov (%eax),%eax
576: c7 44 24 0c 01 00 00 movl $0x1,0xc(%esp)
57d: 00
57e: c7 44 24 08 0a 00 00 movl $0xa,0x8(%esp)
585: 00
586: 89 44 24 04 mov %eax,0x4(%esp)
58a: 8b 45 08 mov 0x8(%ebp),%eax
58d: 89 04 24 mov %eax,(%esp)
590: e8 aa fe ff ff call 43f <printint>
ap++;
595: 83 45 e8 04 addl $0x4,-0x18(%ebp)
599: e9 ec 00 00 00 jmp 68a <printf+0x193>
} else if(c == 'x' || c == 'p'){
59e: 83 7d e4 78 cmpl $0x78,-0x1c(%ebp)
5a2: 74 06 je 5aa <printf+0xb3>
5a4: 83 7d e4 70 cmpl $0x70,-0x1c(%ebp)
5a8: 75 2d jne 5d7 <printf+0xe0>
printint(fd, *ap, 16, 0);
5aa: 8b 45 e8 mov -0x18(%ebp),%eax
5ad: 8b 00 mov (%eax),%eax
5af: c7 44 24 0c 00 00 00 movl $0x0,0xc(%esp)
5b6: 00
5b7: c7 44 24 08 10 00 00 movl $0x10,0x8(%esp)
5be: 00
5bf: 89 44 24 04 mov %eax,0x4(%esp)
5c3: 8b 45 08 mov 0x8(%ebp),%eax
5c6: 89 04 24 mov %eax,(%esp)
5c9: e8 71 fe ff ff call 43f <printint>
ap++;
5ce: 83 45 e8 04 addl $0x4,-0x18(%ebp)
5d2: e9 b3 00 00 00 jmp 68a <printf+0x193>
} else if(c == 's'){
5d7: 83 7d e4 73 cmpl $0x73,-0x1c(%ebp)
5db: 75 45 jne 622 <printf+0x12b>
s = (char*)*ap;
5dd: 8b 45 e8 mov -0x18(%ebp),%eax
5e0: 8b 00 mov (%eax),%eax
5e2: 89 45 f4 mov %eax,-0xc(%ebp)
ap++;
5e5: 83 45 e8 04 addl $0x4,-0x18(%ebp)
if(s == 0)
5e9: 83 7d f4 00 cmpl $0x0,-0xc(%ebp)
5ed: 75 09 jne 5f8 <printf+0x101>
s = "(null)";
5ef: c7 45 f4 13 09 00 00 movl $0x913,-0xc(%ebp)
while(*s != 0){
5f6: eb 1e jmp 616 <printf+0x11f>
5f8: eb 1c jmp 616 <printf+0x11f>
putc(fd, *s);
5fa: 8b 45 f4 mov -0xc(%ebp),%eax
5fd: 0f b6 00 movzbl (%eax),%eax
600: 0f be c0 movsbl %al,%eax
603: 89 44 24 04 mov %eax,0x4(%esp)
607: 8b 45 08 mov 0x8(%ebp),%eax
60a: 89 04 24 mov %eax,(%esp)
60d: e8 05 fe ff ff call 417 <putc>
s++;
612: 83 45 f4 01 addl $0x1,-0xc(%ebp)
} else if(c == 's'){
s = (char*)*ap;
ap++;
if(s == 0)
s = "(null)";
while(*s != 0){
616: 8b 45 f4 mov -0xc(%ebp),%eax
619: 0f b6 00 movzbl (%eax),%eax
61c: 84 c0 test %al,%al
61e: 75 da jne 5fa <printf+0x103>
620: eb 68 jmp 68a <printf+0x193>
putc(fd, *s);
s++;
}
} else if(c == 'c'){
622: 83 7d e4 63 cmpl $0x63,-0x1c(%ebp)
626: 75 1d jne 645 <printf+0x14e>
putc(fd, *ap);
628: 8b 45 e8 mov -0x18(%ebp),%eax
62b: 8b 00 mov (%eax),%eax
62d: 0f be c0 movsbl %al,%eax
630: 89 44 24 04 mov %eax,0x4(%esp)
634: 8b 45 08 mov 0x8(%ebp),%eax
637: 89 04 24 mov %eax,(%esp)
63a: e8 d8 fd ff ff call 417 <putc>
ap++;
63f: 83 45 e8 04 addl $0x4,-0x18(%ebp)
643: eb 45 jmp 68a <printf+0x193>
} else if(c == '%'){
645: 83 7d e4 25 cmpl $0x25,-0x1c(%ebp)
649: 75 17 jne 662 <printf+0x16b>
putc(fd, c);
64b: 8b 45 e4 mov -0x1c(%ebp),%eax
64e: 0f be c0 movsbl %al,%eax
651: 89 44 24 04 mov %eax,0x4(%esp)
655: 8b 45 08 mov 0x8(%ebp),%eax
658: 89 04 24 mov %eax,(%esp)
65b: e8 b7 fd ff ff call 417 <putc>
660: eb 28 jmp 68a <printf+0x193>
} else {
// Unknown % sequence. Print it to draw attention.
putc(fd, '%');
662: c7 44 24 04 25 00 00 movl $0x25,0x4(%esp)
669: 00
66a: 8b 45 08 mov 0x8(%ebp),%eax
66d: 89 04 24 mov %eax,(%esp)
670: e8 a2 fd ff ff call 417 <putc>
putc(fd, c);
675: 8b 45 e4 mov -0x1c(%ebp),%eax
678: 0f be c0 movsbl %al,%eax
67b: 89 44 24 04 mov %eax,0x4(%esp)
67f: 8b 45 08 mov 0x8(%ebp),%eax
682: 89 04 24 mov %eax,(%esp)
685: e8 8d fd ff ff call 417 <putc>
}
state = 0;
68a: c7 45 ec 00 00 00 00 movl $0x0,-0x14(%ebp)
int c, i, state;
uint *ap;
state = 0;
ap = (uint*)(void*)&fmt + 1;
for(i = 0; fmt[i]; i++){
691: 83 45 f0 01 addl $0x1,-0x10(%ebp)
695: 8b 55 0c mov 0xc(%ebp),%edx
698: 8b 45 f0 mov -0x10(%ebp),%eax
69b: 01 d0 add %edx,%eax
69d: 0f b6 00 movzbl (%eax),%eax
6a0: 84 c0 test %al,%al
6a2: 0f 85 71 fe ff ff jne 519 <printf+0x22>
putc(fd, c);
}
state = 0;
}
}
}
6a8: c9 leave
6a9: c3 ret
000006aa <free>:
static Header base;
static Header *freep;
void
free(void *ap)
{
6aa: 55 push %ebp
6ab: 89 e5 mov %esp,%ebp
6ad: 83 ec 10 sub $0x10,%esp
Header *bp, *p;
bp = (Header*)ap - 1;
6b0: 8b 45 08 mov 0x8(%ebp),%eax
6b3: 83 e8 08 sub $0x8,%eax
6b6: 89 45 f8 mov %eax,-0x8(%ebp)
for(p = freep; !(bp > p && bp < p->s.ptr); p = p->s.ptr)
6b9: a1 84 0b 00 00 mov 0xb84,%eax
6be: 89 45 fc mov %eax,-0x4(%ebp)
6c1: eb 24 jmp 6e7 <free+0x3d>
if(p >= p->s.ptr && (bp > p || bp < p->s.ptr))
6c3: 8b 45 fc mov -0x4(%ebp),%eax
6c6: 8b 00 mov (%eax),%eax
6c8: 3b 45 fc cmp -0x4(%ebp),%eax
6cb: 77 12 ja 6df <free+0x35>
6cd: 8b 45 f8 mov -0x8(%ebp),%eax
6d0: 3b 45 fc cmp -0x4(%ebp),%eax
6d3: 77 24 ja 6f9 <free+0x4f>
6d5: 8b 45 fc mov -0x4(%ebp),%eax
6d8: 8b 00 mov (%eax),%eax
6da: 3b 45 f8 cmp -0x8(%ebp),%eax
6dd: 77 1a ja 6f9 <free+0x4f>
free(void *ap)
{
Header *bp, *p;
bp = (Header*)ap - 1;
for(p = freep; !(bp > p && bp < p->s.ptr); p = p->s.ptr)
6df: 8b 45 fc mov -0x4(%ebp),%eax
6e2: 8b 00 mov (%eax),%eax
6e4: 89 45 fc mov %eax,-0x4(%ebp)
6e7: 8b 45 f8 mov -0x8(%ebp),%eax
6ea: 3b 45 fc cmp -0x4(%ebp),%eax
6ed: 76 d4 jbe 6c3 <free+0x19>
6ef: 8b 45 fc mov -0x4(%ebp),%eax
6f2: 8b 00 mov (%eax),%eax
6f4: 3b 45 f8 cmp -0x8(%ebp),%eax
6f7: 76 ca jbe 6c3 <free+0x19>
if(p >= p->s.ptr && (bp > p || bp < p->s.ptr))
break;
if(bp + bp->s.size == p->s.ptr){
6f9: 8b 45 f8 mov -0x8(%ebp),%eax
6fc: 8b 40 04 mov 0x4(%eax),%eax
6ff: 8d 14 c5 00 00 00 00 lea 0x0(,%eax,8),%edx
706: 8b 45 f8 mov -0x8(%ebp),%eax
709: 01 c2 add %eax,%edx
70b: 8b 45 fc mov -0x4(%ebp),%eax
70e: 8b 00 mov (%eax),%eax
710: 39 c2 cmp %eax,%edx
712: 75 24 jne 738 <free+0x8e>
bp->s.size += p->s.ptr->s.size;
714: 8b 45 f8 mov -0x8(%ebp),%eax
717: 8b 50 04 mov 0x4(%eax),%edx
71a: 8b 45 fc mov -0x4(%ebp),%eax
71d: 8b 00 mov (%eax),%eax
71f: 8b 40 04 mov 0x4(%eax),%eax
722: 01 c2 add %eax,%edx
724: 8b 45 f8 mov -0x8(%ebp),%eax
727: 89 50 04 mov %edx,0x4(%eax)
bp->s.ptr = p->s.ptr->s.ptr;
72a: 8b 45 fc mov -0x4(%ebp),%eax
72d: 8b 00 mov (%eax),%eax
72f: 8b 10 mov (%eax),%edx
731: 8b 45 f8 mov -0x8(%ebp),%eax
734: 89 10 mov %edx,(%eax)
736: eb 0a jmp 742 <free+0x98>
} else
bp->s.ptr = p->s.ptr;
738: 8b 45 fc mov -0x4(%ebp),%eax
73b: 8b 10 mov (%eax),%edx
73d: 8b 45 f8 mov -0x8(%ebp),%eax
740: 89 10 mov %edx,(%eax)
if(p + p->s.size == bp){
742: 8b 45 fc mov -0x4(%ebp),%eax
745: 8b 40 04 mov 0x4(%eax),%eax
748: 8d 14 c5 00 00 00 00 lea 0x0(,%eax,8),%edx
74f: 8b 45 fc mov -0x4(%ebp),%eax
752: 01 d0 add %edx,%eax
754: 3b 45 f8 cmp -0x8(%ebp),%eax
757: 75 20 jne 779 <free+0xcf>
p->s.size += bp->s.size;
759: 8b 45 fc mov -0x4(%ebp),%eax
75c: 8b 50 04 mov 0x4(%eax),%edx
75f: 8b 45 f8 mov -0x8(%ebp),%eax
762: 8b 40 04 mov 0x4(%eax),%eax
765: 01 c2 add %eax,%edx
767: 8b 45 fc mov -0x4(%ebp),%eax
76a: 89 50 04 mov %edx,0x4(%eax)
p->s.ptr = bp->s.ptr;
76d: 8b 45 f8 mov -0x8(%ebp),%eax
770: 8b 10 mov (%eax),%edx
772: 8b 45 fc mov -0x4(%ebp),%eax
775: 89 10 mov %edx,(%eax)
777: eb 08 jmp 781 <free+0xd7>
} else
p->s.ptr = bp;
779: 8b 45 fc mov -0x4(%ebp),%eax
77c: 8b 55 f8 mov -0x8(%ebp),%edx
77f: 89 10 mov %edx,(%eax)
freep = p;
781: 8b 45 fc mov -0x4(%ebp),%eax
784: a3 84 0b 00 00 mov %eax,0xb84
}
789: c9 leave
78a: c3 ret
0000078b <morecore>:
static Header*
morecore(uint nu)
{
78b: 55 push %ebp
78c: 89 e5 mov %esp,%ebp
78e: 83 ec 28 sub $0x28,%esp
char *p;
Header *hp;
if(nu < 4096)
791: 81 7d 08 ff 0f 00 00 cmpl $0xfff,0x8(%ebp)
798: 77 07 ja 7a1 <morecore+0x16>
nu = 4096;
79a: c7 45 08 00 10 00 00 movl $0x1000,0x8(%ebp)
p = sbrk(nu * sizeof(Header));
7a1: 8b 45 08 mov 0x8(%ebp),%eax
7a4: c1 e0 03 shl $0x3,%eax
7a7: 89 04 24 mov %eax,(%esp)
7aa: e8 50 fc ff ff call 3ff <sbrk>
7af: 89 45 f4 mov %eax,-0xc(%ebp)
if(p == (char*)-1)
7b2: 83 7d f4 ff cmpl $0xffffffff,-0xc(%ebp)
7b6: 75 07 jne 7bf <morecore+0x34>
return 0;
7b8: b8 00 00 00 00 mov $0x0,%eax
7bd: eb 22 jmp 7e1 <morecore+0x56>
hp = (Header*)p;
7bf: 8b 45 f4 mov -0xc(%ebp),%eax
7c2: 89 45 f0 mov %eax,-0x10(%ebp)
hp->s.size = nu;
7c5: 8b 45 f0 mov -0x10(%ebp),%eax
7c8: 8b 55 08 mov 0x8(%ebp),%edx
7cb: 89 50 04 mov %edx,0x4(%eax)
free((void*)(hp + 1));
7ce: 8b 45 f0 mov -0x10(%ebp),%eax
7d1: 83 c0 08 add $0x8,%eax
7d4: 89 04 24 mov %eax,(%esp)
7d7: e8 ce fe ff ff call 6aa <free>
return freep;
7dc: a1 84 0b 00 00 mov 0xb84,%eax
}
7e1: c9 leave
7e2: c3 ret
000007e3 <malloc>:
void*
malloc(uint nbytes)
{
7e3: 55 push %ebp
7e4: 89 e5 mov %esp,%ebp
7e6: 83 ec 28 sub $0x28,%esp
Header *p, *prevp;
uint nunits;
nunits = (nbytes + sizeof(Header) - 1)/sizeof(Header) + 1;
7e9: 8b 45 08 mov 0x8(%ebp),%eax
7ec: 83 c0 07 add $0x7,%eax
7ef: c1 e8 03 shr $0x3,%eax
7f2: 83 c0 01 add $0x1,%eax
7f5: 89 45 ec mov %eax,-0x14(%ebp)
if((prevp = freep) == 0){
7f8: a1 84 0b 00 00 mov 0xb84,%eax
7fd: 89 45 f0 mov %eax,-0x10(%ebp)
800: 83 7d f0 00 cmpl $0x0,-0x10(%ebp)
804: 75 23 jne 829 <malloc+0x46>
base.s.ptr = freep = prevp = &base;
806: c7 45 f0 7c 0b 00 00 movl $0xb7c,-0x10(%ebp)
80d: 8b 45 f0 mov -0x10(%ebp),%eax
810: a3 84 0b 00 00 mov %eax,0xb84
815: a1 84 0b 00 00 mov 0xb84,%eax
81a: a3 7c 0b 00 00 mov %eax,0xb7c
base.s.size = 0;
81f: c7 05 80 0b 00 00 00 movl $0x0,0xb80
826: 00 00 00
}
for(p = prevp->s.ptr; ; prevp = p, p = p->s.ptr){
829: 8b 45 f0 mov -0x10(%ebp),%eax
82c: 8b 00 mov (%eax),%eax
82e: 89 45 f4 mov %eax,-0xc(%ebp)
if(p->s.size >= nunits){
831: 8b 45 f4 mov -0xc(%ebp),%eax
834: 8b 40 04 mov 0x4(%eax),%eax
837: 3b 45 ec cmp -0x14(%ebp),%eax
83a: 72 4d jb 889 <malloc+0xa6>
if(p->s.size == nunits)
83c: 8b 45 f4 mov -0xc(%ebp),%eax
83f: 8b 40 04 mov 0x4(%eax),%eax
842: 3b 45 ec cmp -0x14(%ebp),%eax
845: 75 0c jne 853 <malloc+0x70>
prevp->s.ptr = p->s.ptr;
847: 8b 45 f4 mov -0xc(%ebp),%eax
84a: 8b 10 mov (%eax),%edx
84c: 8b 45 f0 mov -0x10(%ebp),%eax
84f: 89 10 mov %edx,(%eax)
851: eb 26 jmp 879 <malloc+0x96>
else {
p->s.size -= nunits;
853: 8b 45 f4 mov -0xc(%ebp),%eax
856: 8b 40 04 mov 0x4(%eax),%eax
859: 2b 45 ec sub -0x14(%ebp),%eax
85c: 89 c2 mov %eax,%edx
85e: 8b 45 f4 mov -0xc(%ebp),%eax
861: 89 50 04 mov %edx,0x4(%eax)
p += p->s.size;
864: 8b 45 f4 mov -0xc(%ebp),%eax
867: 8b 40 04 mov 0x4(%eax),%eax
86a: c1 e0 03 shl $0x3,%eax
86d: 01 45 f4 add %eax,-0xc(%ebp)
p->s.size = nunits;
870: 8b 45 f4 mov -0xc(%ebp),%eax
873: 8b 55 ec mov -0x14(%ebp),%edx
876: 89 50 04 mov %edx,0x4(%eax)
}
freep = prevp;
879: 8b 45 f0 mov -0x10(%ebp),%eax
87c: a3 84 0b 00 00 mov %eax,0xb84
return (void*)(p + 1);
881: 8b 45 f4 mov -0xc(%ebp),%eax
884: 83 c0 08 add $0x8,%eax
887: eb 38 jmp 8c1 <malloc+0xde>
}
if(p == freep)
889: a1 84 0b 00 00 mov 0xb84,%eax
88e: 39 45 f4 cmp %eax,-0xc(%ebp)
891: 75 1b jne 8ae <malloc+0xcb>
if((p = morecore(nunits)) == 0)
893: 8b 45 ec mov -0x14(%ebp),%eax
896: 89 04 24 mov %eax,(%esp)
899: e8 ed fe ff ff call 78b <morecore>
89e: 89 45 f4 mov %eax,-0xc(%ebp)
8a1: 83 7d f4 00 cmpl $0x0,-0xc(%ebp)
8a5: 75 07 jne 8ae <malloc+0xcb>
return 0;
8a7: b8 00 00 00 00 mov $0x0,%eax
8ac: eb 13 jmp 8c1 <malloc+0xde>
nunits = (nbytes + sizeof(Header) - 1)/sizeof(Header) + 1;
if((prevp = freep) == 0){
base.s.ptr = freep = prevp = &base;
base.s.size = 0;
}
for(p = prevp->s.ptr; ; prevp = p, p = p->s.ptr){
8ae: 8b 45 f4 mov -0xc(%ebp),%eax
8b1: 89 45 f0 mov %eax,-0x10(%ebp)
8b4: 8b 45 f4 mov -0xc(%ebp),%eax
8b7: 8b 00 mov (%eax),%eax
8b9: 89 45 f4 mov %eax,-0xc(%ebp)
return (void*)(p + 1);
}
if(p == freep)
if((p = morecore(nunits)) == 0)
return 0;
}
8bc: e9 70 ff ff ff jmp 831 <malloc+0x4e>
}
8c1: c9 leave
8c2: c3 ret
| tzulang/os3 | init.asm | Assembly | mit | 42,058 |
;--------------------------------------------------------
; File Created by SDCC : free open source ANSI-C Compiler
; Version 3.3.0 #8604 (Dec 30 2013) (Linux)
; This file was generated Tue Jul 7 11:37:29 2015
;--------------------------------------------------------
.module flash
.optsdcc -mmcs51 --model-large
;--------------------------------------------------------
; Public variables in this module
;--------------------------------------------------------
.globl _app_signature
.globl _SDN
.globl _NSS1
.globl _IRQ
.globl _PIN_ENABLE
.globl _PIN_CONFIG
.globl _LED_GREEN
.globl _LED_RED
.globl _SPI0EN
.globl _TXBMT0
.globl _NSS0MD0
.globl _NSS0MD1
.globl _RXOVRN0
.globl _MODF0
.globl _WCOL0
.globl _SPIF0
.globl _AD0CM0
.globl _AD0CM1
.globl _AD0CM2
.globl _AD0WINT
.globl _AD0BUSY
.globl _AD0INT
.globl _BURSTEN
.globl _AD0EN
.globl _CCF0
.globl _CCF1
.globl _CCF2
.globl _CCF3
.globl _CCF4
.globl _CCF5
.globl _CR
.globl _CF
.globl _P
.globl _F1
.globl _OV
.globl _RS0
.globl _RS1
.globl _F0
.globl _AC
.globl _CY
.globl _T2XCLK
.globl _T2RCLK
.globl _TR2
.globl _T2SPLIT
.globl _TF2CEN
.globl _TF2LEN
.globl _TF2L
.globl _TF2H
.globl _SI
.globl _ACK
.globl _ARBLOST
.globl _ACKRQ
.globl _STO
.globl _STA
.globl _TXMODE
.globl _MASTER
.globl _PX0
.globl _PT0
.globl _PX1
.globl _PT1
.globl _PS0
.globl _PT2
.globl _PSPI0
.globl _SPI1EN
.globl _TXBMT1
.globl _NSS1MD0
.globl _NSS1MD1
.globl _RXOVRN1
.globl _MODF1
.globl _WCOL1
.globl _SPIF1
.globl _EX0
.globl _ET0
.globl _EX1
.globl _ET1
.globl _ES0
.globl _ET2
.globl _ESPI0
.globl _EA
.globl _RI0
.globl _TI0
.globl _RB80
.globl _TB80
.globl _REN0
.globl _MCE0
.globl _S0MODE
.globl _CRC0VAL
.globl _CRC0INIT
.globl _CRC0SEL
.globl _IT0
.globl _IE0
.globl _IT1
.globl _IE1
.globl _TR0
.globl _TF0
.globl _TR1
.globl _TF1
.globl _PCA0CP4
.globl _PCA0CP0
.globl _PCA0
.globl _PCA0CP3
.globl _PCA0CP2
.globl _PCA0CP1
.globl _PCA0CP5
.globl _TMR2
.globl _TMR2RL
.globl _ADC0LT
.globl _ADC0GT
.globl _ADC0
.globl _TMR3
.globl _TMR3RL
.globl _TOFF
.globl _DP
.globl _VDM0CN
.globl _PCA0CPH4
.globl _PCA0CPL4
.globl _PCA0CPH0
.globl _PCA0CPL0
.globl _PCA0H
.globl _PCA0L
.globl _SPI0CN
.globl _EIP2
.globl _EIP1
.globl _SMB0ADM
.globl _SMB0ADR
.globl _P2MDIN
.globl _P1MDIN
.globl _P0MDIN
.globl _B
.globl _RSTSRC
.globl _PCA0CPH3
.globl _PCA0CPL3
.globl _PCA0CPH2
.globl _PCA0CPL2
.globl _PCA0CPH1
.globl _PCA0CPL1
.globl _ADC0CN
.globl _EIE2
.globl _EIE1
.globl _FLWR
.globl _IT01CF
.globl _XBR2
.globl _XBR1
.globl _XBR0
.globl _ACC
.globl _PCA0PWM
.globl _PCA0CPM4
.globl _PCA0CPM3
.globl _PCA0CPM2
.globl _PCA0CPM1
.globl _PCA0CPM0
.globl _PCA0MD
.globl _PCA0CN
.globl _P0MAT
.globl _P2SKIP
.globl _P1SKIP
.globl _P0SKIP
.globl _PCA0CPH5
.globl _PCA0CPL5
.globl _REF0CN
.globl _PSW
.globl _P1MAT
.globl _PCA0CPM5
.globl _TMR2H
.globl _TMR2L
.globl _TMR2RLH
.globl _TMR2RLL
.globl _REG0CN
.globl _TMR2CN
.globl _P0MASK
.globl _ADC0LTH
.globl _ADC0LTL
.globl _ADC0GTH
.globl _ADC0GTL
.globl _SMB0DAT
.globl _SMB0CF
.globl _SMB0CN
.globl _P1MASK
.globl _ADC0H
.globl _ADC0L
.globl _ADC0TK
.globl _ADC0CF
.globl _ADC0MX
.globl _ADC0PWR
.globl _ADC0AC
.globl _IREF0CN
.globl _IP
.globl _FLKEY
.globl _FLSCL
.globl _PMU0CF
.globl _OSCICL
.globl _OSCICN
.globl _OSCXCN
.globl _SPI1CN
.globl _ONESHOT
.globl _EMI0TC
.globl _RTC0KEY
.globl _RTC0DAT
.globl _RTC0ADR
.globl _EMI0CF
.globl _EMI0CN
.globl _CLKSEL
.globl _IE
.globl _SFRPAGE
.globl _P2DRV
.globl _P2MDOUT
.globl _P1DRV
.globl _P1MDOUT
.globl _P0DRV
.globl _P0MDOUT
.globl _SPI0DAT
.globl _SPI0CKR
.globl _SPI0CFG
.globl _P2
.globl _CPT0MX
.globl _CPT1MX
.globl _CPT0MD
.globl _CPT1MD
.globl _CPT0CN
.globl _CPT1CN
.globl _SBUF0
.globl _SCON0
.globl _CRC0CNT
.globl _DC0CN
.globl _CRC0AUTO
.globl _DC0CF
.globl _TMR3H
.globl _CRC0FLIP
.globl _TMR3L
.globl _CRC0IN
.globl _TMR3RLH
.globl _CRC0CN
.globl _TMR3RLL
.globl _CRC0DAT
.globl _TMR3CN
.globl _P1
.globl _PSCTL
.globl _CKCON
.globl _TH1
.globl _TH0
.globl _TL1
.globl _TL0
.globl _TMOD
.globl _TCON
.globl _PCON
.globl _TOFFH
.globl _SPI1DAT
.globl _TOFFL
.globl _SPI1CKR
.globl _SPI1CFG
.globl _DPH
.globl _DPL
.globl _SP
.globl _P0
.globl _flash_write_scratch_PARM_2
.globl _flash_erase_scratch
.globl _flash_read_scratch
.globl _flash_write_scratch
;--------------------------------------------------------
; special function registers
;--------------------------------------------------------
.area RSEG (ABS,DATA)
.org 0x0000
_P0 = 0x0080
_SP = 0x0081
_DPL = 0x0082
_DPH = 0x0083
_SPI1CFG = 0x0084
_SPI1CKR = 0x0085
_TOFFL = 0x0085
_SPI1DAT = 0x0086
_TOFFH = 0x0086
_PCON = 0x0087
_TCON = 0x0088
_TMOD = 0x0089
_TL0 = 0x008a
_TL1 = 0x008b
_TH0 = 0x008c
_TH1 = 0x008d
_CKCON = 0x008e
_PSCTL = 0x008f
_P1 = 0x0090
_TMR3CN = 0x0091
_CRC0DAT = 0x0091
_TMR3RLL = 0x0092
_CRC0CN = 0x0092
_TMR3RLH = 0x0093
_CRC0IN = 0x0093
_TMR3L = 0x0094
_CRC0FLIP = 0x0095
_TMR3H = 0x0095
_DC0CF = 0x0096
_CRC0AUTO = 0x0096
_DC0CN = 0x0097
_CRC0CNT = 0x0097
_SCON0 = 0x0098
_SBUF0 = 0x0099
_CPT1CN = 0x009a
_CPT0CN = 0x009b
_CPT1MD = 0x009c
_CPT0MD = 0x009d
_CPT1MX = 0x009e
_CPT0MX = 0x009f
_P2 = 0x00a0
_SPI0CFG = 0x00a1
_SPI0CKR = 0x00a2
_SPI0DAT = 0x00a3
_P0MDOUT = 0x00a4
_P0DRV = 0x00a4
_P1MDOUT = 0x00a5
_P1DRV = 0x00a5
_P2MDOUT = 0x00a6
_P2DRV = 0x00a6
_SFRPAGE = 0x00a7
_IE = 0x00a8
_CLKSEL = 0x00a9
_EMI0CN = 0x00aa
_EMI0CF = 0x00ab
_RTC0ADR = 0x00ac
_RTC0DAT = 0x00ad
_RTC0KEY = 0x00ae
_EMI0TC = 0x00af
_ONESHOT = 0x00af
_SPI1CN = 0x00b0
_OSCXCN = 0x00b1
_OSCICN = 0x00b2
_OSCICL = 0x00b3
_PMU0CF = 0x00b5
_FLSCL = 0x00b6
_FLKEY = 0x00b7
_IP = 0x00b8
_IREF0CN = 0x00b9
_ADC0AC = 0x00ba
_ADC0PWR = 0x00ba
_ADC0MX = 0x00bb
_ADC0CF = 0x00bc
_ADC0TK = 0x00bd
_ADC0L = 0x00bd
_ADC0H = 0x00be
_P1MASK = 0x00bf
_SMB0CN = 0x00c0
_SMB0CF = 0x00c1
_SMB0DAT = 0x00c2
_ADC0GTL = 0x00c3
_ADC0GTH = 0x00c4
_ADC0LTL = 0x00c5
_ADC0LTH = 0x00c6
_P0MASK = 0x00c7
_TMR2CN = 0x00c8
_REG0CN = 0x00c9
_TMR2RLL = 0x00ca
_TMR2RLH = 0x00cb
_TMR2L = 0x00cc
_TMR2H = 0x00cd
_PCA0CPM5 = 0x00ce
_P1MAT = 0x00cf
_PSW = 0x00d0
_REF0CN = 0x00d1
_PCA0CPL5 = 0x00d2
_PCA0CPH5 = 0x00d3
_P0SKIP = 0x00d4
_P1SKIP = 0x00d5
_P2SKIP = 0x00d6
_P0MAT = 0x00d7
_PCA0CN = 0x00d8
_PCA0MD = 0x00d9
_PCA0CPM0 = 0x00da
_PCA0CPM1 = 0x00db
_PCA0CPM2 = 0x00dc
_PCA0CPM3 = 0x00dd
_PCA0CPM4 = 0x00de
_PCA0PWM = 0x00df
_ACC = 0x00e0
_XBR0 = 0x00e1
_XBR1 = 0x00e2
_XBR2 = 0x00e3
_IT01CF = 0x00e4
_FLWR = 0x00e5
_EIE1 = 0x00e6
_EIE2 = 0x00e7
_ADC0CN = 0x00e8
_PCA0CPL1 = 0x00e9
_PCA0CPH1 = 0x00ea
_PCA0CPL2 = 0x00eb
_PCA0CPH2 = 0x00ec
_PCA0CPL3 = 0x00ed
_PCA0CPH3 = 0x00ee
_RSTSRC = 0x00ef
_B = 0x00f0
_P0MDIN = 0x00f1
_P1MDIN = 0x00f2
_P2MDIN = 0x00f3
_SMB0ADR = 0x00f4
_SMB0ADM = 0x00f5
_EIP1 = 0x00f6
_EIP2 = 0x00f7
_SPI0CN = 0x00f8
_PCA0L = 0x00f9
_PCA0H = 0x00fa
_PCA0CPL0 = 0x00fb
_PCA0CPH0 = 0x00fc
_PCA0CPL4 = 0x00fd
_PCA0CPH4 = 0x00fe
_VDM0CN = 0x00ff
_DP = 0x8382
_TOFF = 0x8685
_TMR3RL = 0x9392
_TMR3 = 0x9594
_ADC0 = 0xbebd
_ADC0GT = 0xc4c3
_ADC0LT = 0xc6c5
_TMR2RL = 0xcbca
_TMR2 = 0xcdcc
_PCA0CP5 = 0xd3d2
_PCA0CP1 = 0xeae9
_PCA0CP2 = 0xeceb
_PCA0CP3 = 0xeeed
_PCA0 = 0xfaf9
_PCA0CP0 = 0xfcfb
_PCA0CP4 = 0xfefd
;--------------------------------------------------------
; special function bits
;--------------------------------------------------------
.area RSEG (ABS,DATA)
.org 0x0000
_TF1 = 0x008f
_TR1 = 0x008e
_TF0 = 0x008d
_TR0 = 0x008c
_IE1 = 0x008b
_IT1 = 0x008a
_IE0 = 0x0089
_IT0 = 0x0088
_CRC0SEL = 0x0096
_CRC0INIT = 0x0095
_CRC0VAL = 0x0094
_S0MODE = 0x009f
_MCE0 = 0x009d
_REN0 = 0x009c
_TB80 = 0x009b
_RB80 = 0x009a
_TI0 = 0x0099
_RI0 = 0x0098
_EA = 0x00af
_ESPI0 = 0x00ae
_ET2 = 0x00ad
_ES0 = 0x00ac
_ET1 = 0x00ab
_EX1 = 0x00aa
_ET0 = 0x00a9
_EX0 = 0x00a8
_SPIF1 = 0x00b7
_WCOL1 = 0x00b6
_MODF1 = 0x00b5
_RXOVRN1 = 0x00b4
_NSS1MD1 = 0x00b3
_NSS1MD0 = 0x00b2
_TXBMT1 = 0x00b1
_SPI1EN = 0x00b0
_PSPI0 = 0x00be
_PT2 = 0x00bd
_PS0 = 0x00bc
_PT1 = 0x00bb
_PX1 = 0x00ba
_PT0 = 0x00b9
_PX0 = 0x00b8
_MASTER = 0x00c7
_TXMODE = 0x00c6
_STA = 0x00c5
_STO = 0x00c4
_ACKRQ = 0x00c3
_ARBLOST = 0x00c2
_ACK = 0x00c1
_SI = 0x00c0
_TF2H = 0x00cf
_TF2L = 0x00ce
_TF2LEN = 0x00cd
_TF2CEN = 0x00cc
_T2SPLIT = 0x00cb
_TR2 = 0x00ca
_T2RCLK = 0x00c9
_T2XCLK = 0x00c8
_CY = 0x00d7
_AC = 0x00d6
_F0 = 0x00d5
_RS1 = 0x00d4
_RS0 = 0x00d3
_OV = 0x00d2
_F1 = 0x00d1
_P = 0x00d0
_CF = 0x00df
_CR = 0x00de
_CCF5 = 0x00dd
_CCF4 = 0x00dc
_CCF3 = 0x00db
_CCF2 = 0x00da
_CCF1 = 0x00d9
_CCF0 = 0x00d8
_AD0EN = 0x00ef
_BURSTEN = 0x00ee
_AD0INT = 0x00ed
_AD0BUSY = 0x00ec
_AD0WINT = 0x00eb
_AD0CM2 = 0x00ea
_AD0CM1 = 0x00e9
_AD0CM0 = 0x00e8
_SPIF0 = 0x00ff
_WCOL0 = 0x00fe
_MODF0 = 0x00fd
_RXOVRN0 = 0x00fc
_NSS0MD1 = 0x00fb
_NSS0MD0 = 0x00fa
_TXBMT0 = 0x00f9
_SPI0EN = 0x00f8
_LED_RED = 0x0096
_LED_GREEN = 0x0095
_PIN_CONFIG = 0x0082
_PIN_ENABLE = 0x0083
_IRQ = 0x0087
_NSS1 = 0x0094
_SDN = 0x00a6
;--------------------------------------------------------
; overlayable register banks
;--------------------------------------------------------
.area REG_BANK_0 (REL,OVR,DATA)
.ds 8
;--------------------------------------------------------
; internal ram data
;--------------------------------------------------------
.area DSEG (DATA)
;--------------------------------------------------------
; overlayable items in internal ram
;--------------------------------------------------------
;--------------------------------------------------------
; indirectly addressable internal ram data
;--------------------------------------------------------
.area ISEG (DATA)
;--------------------------------------------------------
; absolute internal ram data
;--------------------------------------------------------
.area IABS (ABS,DATA)
.area IABS (ABS,DATA)
;--------------------------------------------------------
; bit data
;--------------------------------------------------------
.area BSEG (BIT)
;--------------------------------------------------------
; paged external ram data
;--------------------------------------------------------
.area PSEG (PAG,XDATA)
_flash_write_scratch_PARM_2:
.ds 1
;--------------------------------------------------------
; external ram data
;--------------------------------------------------------
.area XSEG (XDATA)
;--------------------------------------------------------
; absolute external ram data
;--------------------------------------------------------
.area XABS (ABS,XDATA)
;--------------------------------------------------------
; external initialized ram data
;--------------------------------------------------------
.area XISEG (XDATA)
.area HOME (CODE)
.area GSINIT0 (CODE)
.area GSINIT1 (CODE)
.area GSINIT2 (CODE)
.area GSINIT3 (CODE)
.area GSINIT4 (CODE)
.area GSINIT5 (CODE)
.area GSINIT (CODE)
.area GSFINAL (CODE)
.area CSEG (CODE)
;--------------------------------------------------------
; global & static initialisations
;--------------------------------------------------------
.area HOME (CODE)
.area GSINIT (CODE)
.area GSFINAL (CODE)
.area GSINIT (CODE)
;--------------------------------------------------------
; Home
;--------------------------------------------------------
.area HOME (CODE)
.area HOME (CODE)
;--------------------------------------------------------
; code
;--------------------------------------------------------
.area CSEG (CODE)
;------------------------------------------------------------
;Allocation info for local variables in function 'flash_load_keys'
;------------------------------------------------------------
; radio/flash.c:53: flash_load_keys(void)
; -----------------------------------------
; function flash_load_keys
; -----------------------------------------
_flash_load_keys:
ar7 = 0x07
ar6 = 0x06
ar5 = 0x05
ar4 = 0x04
ar3 = 0x03
ar2 = 0x02
ar1 = 0x01
ar0 = 0x00
; radio/flash.c:55: FLKEY = 0xa5;
mov _FLKEY,#0xA5
; radio/flash.c:56: FLKEY = 0xf1;
mov _FLKEY,#0xF1
ret
;------------------------------------------------------------
;Allocation info for local variables in function 'flash_erase_scratch'
;------------------------------------------------------------
; radio/flash.c:60: flash_erase_scratch(void)
; -----------------------------------------
; function flash_erase_scratch
; -----------------------------------------
_flash_erase_scratch:
setb c
jbc ea,00103$
clr c
00103$:
push psw
; radio/flash.c:63: flash_load_keys(); // unlock flash for one operation
lcall _flash_load_keys
; radio/flash.c:64: PSCTL = 0x07; // enable flash erase of the scratch page
mov _PSCTL,#0x07
; radio/flash.c:65: *(uint8_t __xdata *)0 = 0xff; // trigger the erase
mov dptr,#0x0000
mov a,#0xFF
movx @dptr,a
; radio/flash.c:66: PSCTL = 0x00; // disable flash write & scratch access
mov _PSCTL,#0x00
pop psw
mov ea,c
ret
;------------------------------------------------------------
;Allocation info for local variables in function 'flash_read_scratch'
;------------------------------------------------------------
;d Allocated with name '_flash_read_scratch_d_1_122'
;------------------------------------------------------------
; radio/flash.c:70: flash_read_scratch(__pdata uint16_t address)
; -----------------------------------------
; function flash_read_scratch
; -----------------------------------------
_flash_read_scratch:
setb c
jbc ea,00103$
clr c
00103$:
push psw
mov r6,dpl
mov r7,dph
; radio/flash.c:74: PSCTL = 0x04;
mov _PSCTL,#0x04
; radio/flash.c:75: d = *(uint8_t __code *)address;
mov dpl,r6
mov dph,r7
clr a
movc a,@a+dptr
mov r7,a
; radio/flash.c:76: PSCTL = 0x00;
mov _PSCTL,#0x00
; radio/flash.c:77: return d;
mov dpl,r7
pop psw
mov ea,c
ret
;------------------------------------------------------------
;Allocation info for local variables in function 'flash_write_scratch'
;------------------------------------------------------------
; radio/flash.c:81: flash_write_scratch(__pdata uint16_t address, __pdata uint8_t c)
; -----------------------------------------
; function flash_write_scratch
; -----------------------------------------
_flash_write_scratch:
setb c
jbc ea,00103$
clr c
00103$:
push psw
mov r6,dpl
mov r7,dph
; radio/flash.c:83: flash_load_keys();
push ar7
push ar6
lcall _flash_load_keys
pop ar6
pop ar7
; radio/flash.c:84: PSCTL = 0x05;
mov _PSCTL,#0x05
; radio/flash.c:85: *(uint8_t __xdata *)address = c;
mov dpl,r6
mov dph,r7
mov r0,#_flash_write_scratch_PARM_2
movx a,@r0
movx @dptr,a
; radio/flash.c:86: PSCTL = 0x00;
mov _PSCTL,#0x00
pop psw
mov ea,c
ret
.area CSEG (CODE)
.area CONST (CODE)
.area XINIT (CODE)
.area CABS (ABS,CODE)
.org 0xF7FE
_app_signature:
.db #0x3D ; 61
.db #0xC2 ; 194
| YifanJiangPolyU/SiK-master-Yifan-TDMA | Firmware-bk/obj/hm_trp/radio~hm_trp/flash.asm | Assembly | bsd-2-clause | 14,809 |
/*
* All Video Processing kernels
* Copyright © <2010>, Intel Corporation.
*
* Permission is hereby granted, free of charge, to any person obtaining a
* copy of this software and associated documentation files (the
* "Software"), to deal in the Software without restriction, including
* without limitation the rights to use, copy, modify, merge, publish,
* distribute, sub license, and/or sell copies of the Software, and to
* permit persons to whom the Software is furnished to do so, subject to
* the following conditions:
*
* The above copyright notice and this permission notice (including the
* next paragraph) shall be included in all copies or substantial portions
* of the Software.
*
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
* OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT.
* IN NO EVENT SHALL PRECISION INSIGHT AND/OR ITS SUPPLIERS BE LIABLE FOR
* ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
*
* This file was originally licensed under the following license
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*
*/
//---------- PL3_AVS_IEF_Unpack_8x4.asm ----------
// Move 1st 8x8 words of Y to dest GRF at lower 8 words of each RGF.
$for(0; <8/2; 1) {
mov (8) uwDEST_Y(%1*2)<1> ubAVS_RESPONSE(%1,1)<16;4,2> // Copy high byte in a word
mov (8) uwDEST_Y(%1*2+1)<1> ubAVS_RESPONSE(%1,8+1)<16;4,2> // Copy high byte in a word
}
// Move 8x4 words of U to dest GRF (Copy high byte in a word)
mov (8) uwDEST_U(0)<1> ubAVS_RESPONSE(4,1)<16;4,2>
mov (8) uwDEST_U(0,8)<1> ubAVS_RESPONSE(4,9)<16;4,2>
mov (8) uwDEST_U(1)<1> ubAVS_RESPONSE(5,1)<16;4,2>
mov (8) uwDEST_U(1,8)<1> ubAVS_RESPONSE(5,9)<16;4,2>
// Move 8x4 words of V to dest GRF
mov (8) uwDEST_V(0)<1> ubAVS_RESPONSE(8,1)<16;4,2>
mov (8) uwDEST_V(0,8)<1> ubAVS_RESPONSE(8,9)<16;4,2>
mov (8) uwDEST_V(1)<1> ubAVS_RESPONSE(9,1)<16;4,2>
mov (8) uwDEST_V(1,8)<1> ubAVS_RESPONSE(9,9)<16;4,2>
// Move 2nd 8x8 words of Y to dest GRF at higher 8 words of each RGF.
$for(0; <8/2; 1) {
mov (8) uwDEST_Y(%1*2,8)<1> ubAVS_RESPONSE(%1+12,1)<16;4,2> // Copy high byte in a word
mov (8) uwDEST_Y(%1*2+1,8)<1> ubAVS_RESPONSE(%1+12,8+1)<16;4,2> // Copy high byte in a word
}
//------------------------------------------------------------------------------
// Re-define new # of lines
#undef nUV_NUM_OF_ROWS
#undef nY_NUM_OF_ROWS
#define nY_NUM_OF_ROWS 8
#define nUV_NUM_OF_ROWS 4
| chenxianqin/vaapi-intel-driver | src/shaders/post_processing/gen5_6/Core_Kernels/PL3_AVS_IEF_Unpack_8x4.asm | Assembly | mit | 3,477 |
;--------------------------------------------------------
; File Created by SDCC : free open source ANSI-C Compiler
; Version 3.3.0 #8604 (Dec 30 2013) (Linux)
; This file was generated Tue Jun 23 12:38:30 2015
;--------------------------------------------------------
.module util
.optsdcc -mmcs51 --model-small
;--------------------------------------------------------
; Public variables in this module
;--------------------------------------------------------
.globl _SPI0EN
.globl _TXBMT0
.globl _NSS0MD0
.globl _NSS0MD1
.globl _RXOVRN0
.globl _MODF0
.globl _WCOL0
.globl _SPIF0
.globl _AD0CM0
.globl _AD0CM1
.globl _AD0CM2
.globl _AD0WINT
.globl _AD0BUSY
.globl _AD0INT
.globl _BURSTEN
.globl _AD0EN
.globl _CCF0
.globl _CCF1
.globl _CCF2
.globl _CCF3
.globl _CCF4
.globl _CCF5
.globl _CR
.globl _CF
.globl _P
.globl _F1
.globl _OV
.globl _RS0
.globl _RS1
.globl _F0
.globl _AC
.globl _CY
.globl _T2XCLK
.globl _T2RCLK
.globl _TR2
.globl _T2SPLIT
.globl _TF2CEN
.globl _TF2LEN
.globl _TF2L
.globl _TF2H
.globl _SI
.globl _ACK
.globl _ARBLOST
.globl _ACKRQ
.globl _STO
.globl _STA
.globl _TXMODE
.globl _MASTER
.globl _PX0
.globl _PT0
.globl _PX1
.globl _PT1
.globl _PS0
.globl _PT2
.globl _PSPI0
.globl _SPI1EN
.globl _TXBMT1
.globl _NSS1MD0
.globl _NSS1MD1
.globl _RXOVRN1
.globl _MODF1
.globl _WCOL1
.globl _SPIF1
.globl _EX0
.globl _ET0
.globl _EX1
.globl _ET1
.globl _ES0
.globl _ET2
.globl _ESPI0
.globl _EA
.globl _RI0
.globl _TI0
.globl _RB80
.globl _TB80
.globl _REN0
.globl _MCE0
.globl _S0MODE
.globl _CRC0VAL
.globl _CRC0INIT
.globl _CRC0SEL
.globl _IT0
.globl _IE0
.globl _IT1
.globl _IE1
.globl _TR0
.globl _TF0
.globl _TR1
.globl _TF1
.globl _PCA0CP4
.globl _PCA0CP0
.globl _PCA0
.globl _PCA0CP3
.globl _PCA0CP2
.globl _PCA0CP1
.globl _PCA0CP5
.globl _TMR2
.globl _TMR2RL
.globl _ADC0LT
.globl _ADC0GT
.globl _ADC0
.globl _TMR3
.globl _TMR3RL
.globl _TOFF
.globl _DP
.globl _VDM0CN
.globl _PCA0CPH4
.globl _PCA0CPL4
.globl _PCA0CPH0
.globl _PCA0CPL0
.globl _PCA0H
.globl _PCA0L
.globl _SPI0CN
.globl _EIP2
.globl _EIP1
.globl _SMB0ADM
.globl _SMB0ADR
.globl _P2MDIN
.globl _P1MDIN
.globl _P0MDIN
.globl _B
.globl _RSTSRC
.globl _PCA0CPH3
.globl _PCA0CPL3
.globl _PCA0CPH2
.globl _PCA0CPL2
.globl _PCA0CPH1
.globl _PCA0CPL1
.globl _ADC0CN
.globl _EIE2
.globl _EIE1
.globl _FLWR
.globl _IT01CF
.globl _XBR2
.globl _XBR1
.globl _XBR0
.globl _ACC
.globl _PCA0PWM
.globl _PCA0CPM4
.globl _PCA0CPM3
.globl _PCA0CPM2
.globl _PCA0CPM1
.globl _PCA0CPM0
.globl _PCA0MD
.globl _PCA0CN
.globl _P0MAT
.globl _P2SKIP
.globl _P1SKIP
.globl _P0SKIP
.globl _PCA0CPH5
.globl _PCA0CPL5
.globl _REF0CN
.globl _PSW
.globl _P1MAT
.globl _PCA0CPM5
.globl _TMR2H
.globl _TMR2L
.globl _TMR2RLH
.globl _TMR2RLL
.globl _REG0CN
.globl _TMR2CN
.globl _P0MASK
.globl _ADC0LTH
.globl _ADC0LTL
.globl _ADC0GTH
.globl _ADC0GTL
.globl _SMB0DAT
.globl _SMB0CF
.globl _SMB0CN
.globl _P1MASK
.globl _ADC0H
.globl _ADC0L
.globl _ADC0TK
.globl _ADC0CF
.globl _ADC0MX
.globl _ADC0PWR
.globl _ADC0AC
.globl _IREF0CN
.globl _IP
.globl _FLKEY
.globl _FLSCL
.globl _PMU0CF
.globl _OSCICL
.globl _OSCICN
.globl _OSCXCN
.globl _SPI1CN
.globl _ONESHOT
.globl _EMI0TC
.globl _RTC0KEY
.globl _RTC0DAT
.globl _RTC0ADR
.globl _EMI0CF
.globl _EMI0CN
.globl _CLKSEL
.globl _IE
.globl _SFRPAGE
.globl _P2DRV
.globl _P2MDOUT
.globl _P1DRV
.globl _P1MDOUT
.globl _P0DRV
.globl _P0MDOUT
.globl _SPI0DAT
.globl _SPI0CKR
.globl _SPI0CFG
.globl _P2
.globl _CPT0MX
.globl _CPT1MX
.globl _CPT0MD
.globl _CPT1MD
.globl _CPT0CN
.globl _CPT1CN
.globl _SBUF0
.globl _SCON0
.globl _CRC0CNT
.globl _DC0CN
.globl _CRC0AUTO
.globl _DC0CF
.globl _TMR3H
.globl _CRC0FLIP
.globl _TMR3L
.globl _CRC0IN
.globl _TMR3RLH
.globl _CRC0CN
.globl _TMR3RLL
.globl _CRC0DAT
.globl _TMR3CN
.globl _P1
.globl _PSCTL
.globl _CKCON
.globl _TH1
.globl _TH0
.globl _TL1
.globl _TL0
.globl _TMOD
.globl _TCON
.globl _PCON
.globl _TOFFH
.globl _SPI1DAT
.globl _TOFFL
.globl _SPI1CKR
.globl _SPI1CFG
.globl _DPH
.globl _DPL
.globl _SP
.globl _P0
.globl _cout
.globl _cin
;--------------------------------------------------------
; special function registers
;--------------------------------------------------------
.area RSEG (ABS,DATA)
.org 0x0000
_P0 = 0x0080
_SP = 0x0081
_DPL = 0x0082
_DPH = 0x0083
_SPI1CFG = 0x0084
_SPI1CKR = 0x0085
_TOFFL = 0x0085
_SPI1DAT = 0x0086
_TOFFH = 0x0086
_PCON = 0x0087
_TCON = 0x0088
_TMOD = 0x0089
_TL0 = 0x008a
_TL1 = 0x008b
_TH0 = 0x008c
_TH1 = 0x008d
_CKCON = 0x008e
_PSCTL = 0x008f
_P1 = 0x0090
_TMR3CN = 0x0091
_CRC0DAT = 0x0091
_TMR3RLL = 0x0092
_CRC0CN = 0x0092
_TMR3RLH = 0x0093
_CRC0IN = 0x0093
_TMR3L = 0x0094
_CRC0FLIP = 0x0095
_TMR3H = 0x0095
_DC0CF = 0x0096
_CRC0AUTO = 0x0096
_DC0CN = 0x0097
_CRC0CNT = 0x0097
_SCON0 = 0x0098
_SBUF0 = 0x0099
_CPT1CN = 0x009a
_CPT0CN = 0x009b
_CPT1MD = 0x009c
_CPT0MD = 0x009d
_CPT1MX = 0x009e
_CPT0MX = 0x009f
_P2 = 0x00a0
_SPI0CFG = 0x00a1
_SPI0CKR = 0x00a2
_SPI0DAT = 0x00a3
_P0MDOUT = 0x00a4
_P0DRV = 0x00a4
_P1MDOUT = 0x00a5
_P1DRV = 0x00a5
_P2MDOUT = 0x00a6
_P2DRV = 0x00a6
_SFRPAGE = 0x00a7
_IE = 0x00a8
_CLKSEL = 0x00a9
_EMI0CN = 0x00aa
_EMI0CF = 0x00ab
_RTC0ADR = 0x00ac
_RTC0DAT = 0x00ad
_RTC0KEY = 0x00ae
_EMI0TC = 0x00af
_ONESHOT = 0x00af
_SPI1CN = 0x00b0
_OSCXCN = 0x00b1
_OSCICN = 0x00b2
_OSCICL = 0x00b3
_PMU0CF = 0x00b5
_FLSCL = 0x00b6
_FLKEY = 0x00b7
_IP = 0x00b8
_IREF0CN = 0x00b9
_ADC0AC = 0x00ba
_ADC0PWR = 0x00ba
_ADC0MX = 0x00bb
_ADC0CF = 0x00bc
_ADC0TK = 0x00bd
_ADC0L = 0x00bd
_ADC0H = 0x00be
_P1MASK = 0x00bf
_SMB0CN = 0x00c0
_SMB0CF = 0x00c1
_SMB0DAT = 0x00c2
_ADC0GTL = 0x00c3
_ADC0GTH = 0x00c4
_ADC0LTL = 0x00c5
_ADC0LTH = 0x00c6
_P0MASK = 0x00c7
_TMR2CN = 0x00c8
_REG0CN = 0x00c9
_TMR2RLL = 0x00ca
_TMR2RLH = 0x00cb
_TMR2L = 0x00cc
_TMR2H = 0x00cd
_PCA0CPM5 = 0x00ce
_P1MAT = 0x00cf
_PSW = 0x00d0
_REF0CN = 0x00d1
_PCA0CPL5 = 0x00d2
_PCA0CPH5 = 0x00d3
_P0SKIP = 0x00d4
_P1SKIP = 0x00d5
_P2SKIP = 0x00d6
_P0MAT = 0x00d7
_PCA0CN = 0x00d8
_PCA0MD = 0x00d9
_PCA0CPM0 = 0x00da
_PCA0CPM1 = 0x00db
_PCA0CPM2 = 0x00dc
_PCA0CPM3 = 0x00dd
_PCA0CPM4 = 0x00de
_PCA0PWM = 0x00df
_ACC = 0x00e0
_XBR0 = 0x00e1
_XBR1 = 0x00e2
_XBR2 = 0x00e3
_IT01CF = 0x00e4
_FLWR = 0x00e5
_EIE1 = 0x00e6
_EIE2 = 0x00e7
_ADC0CN = 0x00e8
_PCA0CPL1 = 0x00e9
_PCA0CPH1 = 0x00ea
_PCA0CPL2 = 0x00eb
_PCA0CPH2 = 0x00ec
_PCA0CPL3 = 0x00ed
_PCA0CPH3 = 0x00ee
_RSTSRC = 0x00ef
_B = 0x00f0
_P0MDIN = 0x00f1
_P1MDIN = 0x00f2
_P2MDIN = 0x00f3
_SMB0ADR = 0x00f4
_SMB0ADM = 0x00f5
_EIP1 = 0x00f6
_EIP2 = 0x00f7
_SPI0CN = 0x00f8
_PCA0L = 0x00f9
_PCA0H = 0x00fa
_PCA0CPL0 = 0x00fb
_PCA0CPH0 = 0x00fc
_PCA0CPL4 = 0x00fd
_PCA0CPH4 = 0x00fe
_VDM0CN = 0x00ff
_DP = 0x8382
_TOFF = 0x8685
_TMR3RL = 0x9392
_TMR3 = 0x9594
_ADC0 = 0xbebd
_ADC0GT = 0xc4c3
_ADC0LT = 0xc6c5
_TMR2RL = 0xcbca
_TMR2 = 0xcdcc
_PCA0CP5 = 0xd3d2
_PCA0CP1 = 0xeae9
_PCA0CP2 = 0xeceb
_PCA0CP3 = 0xeeed
_PCA0 = 0xfaf9
_PCA0CP0 = 0xfcfb
_PCA0CP4 = 0xfefd
;--------------------------------------------------------
; special function bits
;--------------------------------------------------------
.area RSEG (ABS,DATA)
.org 0x0000
_TF1 = 0x008f
_TR1 = 0x008e
_TF0 = 0x008d
_TR0 = 0x008c
_IE1 = 0x008b
_IT1 = 0x008a
_IE0 = 0x0089
_IT0 = 0x0088
_CRC0SEL = 0x0096
_CRC0INIT = 0x0095
_CRC0VAL = 0x0094
_S0MODE = 0x009f
_MCE0 = 0x009d
_REN0 = 0x009c
_TB80 = 0x009b
_RB80 = 0x009a
_TI0 = 0x0099
_RI0 = 0x0098
_EA = 0x00af
_ESPI0 = 0x00ae
_ET2 = 0x00ad
_ES0 = 0x00ac
_ET1 = 0x00ab
_EX1 = 0x00aa
_ET0 = 0x00a9
_EX0 = 0x00a8
_SPIF1 = 0x00b7
_WCOL1 = 0x00b6
_MODF1 = 0x00b5
_RXOVRN1 = 0x00b4
_NSS1MD1 = 0x00b3
_NSS1MD0 = 0x00b2
_TXBMT1 = 0x00b1
_SPI1EN = 0x00b0
_PSPI0 = 0x00be
_PT2 = 0x00bd
_PS0 = 0x00bc
_PT1 = 0x00bb
_PX1 = 0x00ba
_PT0 = 0x00b9
_PX0 = 0x00b8
_MASTER = 0x00c7
_TXMODE = 0x00c6
_STA = 0x00c5
_STO = 0x00c4
_ACKRQ = 0x00c3
_ARBLOST = 0x00c2
_ACK = 0x00c1
_SI = 0x00c0
_TF2H = 0x00cf
_TF2L = 0x00ce
_TF2LEN = 0x00cd
_TF2CEN = 0x00cc
_T2SPLIT = 0x00cb
_TR2 = 0x00ca
_T2RCLK = 0x00c9
_T2XCLK = 0x00c8
_CY = 0x00d7
_AC = 0x00d6
_F0 = 0x00d5
_RS1 = 0x00d4
_RS0 = 0x00d3
_OV = 0x00d2
_F1 = 0x00d1
_P = 0x00d0
_CF = 0x00df
_CR = 0x00de
_CCF5 = 0x00dd
_CCF4 = 0x00dc
_CCF3 = 0x00db
_CCF2 = 0x00da
_CCF1 = 0x00d9
_CCF0 = 0x00d8
_AD0EN = 0x00ef
_BURSTEN = 0x00ee
_AD0INT = 0x00ed
_AD0BUSY = 0x00ec
_AD0WINT = 0x00eb
_AD0CM2 = 0x00ea
_AD0CM1 = 0x00e9
_AD0CM0 = 0x00e8
_SPIF0 = 0x00ff
_WCOL0 = 0x00fe
_MODF0 = 0x00fd
_RXOVRN0 = 0x00fc
_NSS0MD1 = 0x00fb
_NSS0MD0 = 0x00fa
_TXBMT0 = 0x00f9
_SPI0EN = 0x00f8
;--------------------------------------------------------
; overlayable register banks
;--------------------------------------------------------
.area REG_BANK_0 (REL,OVR,DATA)
.ds 8
;--------------------------------------------------------
; internal ram data
;--------------------------------------------------------
.area DSEG (DATA)
;--------------------------------------------------------
; overlayable items in internal ram
;--------------------------------------------------------
.area OSEG (OVR,DATA)
;--------------------------------------------------------
; indirectly addressable internal ram data
;--------------------------------------------------------
.area ISEG (DATA)
;--------------------------------------------------------
; absolute internal ram data
;--------------------------------------------------------
.area IABS (ABS,DATA)
.area IABS (ABS,DATA)
;--------------------------------------------------------
; bit data
;--------------------------------------------------------
.area BSEG (BIT)
;--------------------------------------------------------
; paged external ram data
;--------------------------------------------------------
.area PSEG (PAG,XDATA)
;--------------------------------------------------------
; external ram data
;--------------------------------------------------------
.area XSEG (XDATA)
;--------------------------------------------------------
; absolute external ram data
;--------------------------------------------------------
.area XABS (ABS,XDATA)
;--------------------------------------------------------
; external initialized ram data
;--------------------------------------------------------
.area HOME (CODE)
.area GSINIT0 (CODE)
.area GSINIT1 (CODE)
.area GSINIT2 (CODE)
.area GSINIT3 (CODE)
.area GSINIT4 (CODE)
.area GSINIT5 (CODE)
.area GSINIT (CODE)
.area GSFINAL (CODE)
.area CSEG (CODE)
;--------------------------------------------------------
; global & static initialisations
;--------------------------------------------------------
.area HOME (CODE)
.area GSINIT (CODE)
.area GSFINAL (CODE)
.area GSINIT (CODE)
;--------------------------------------------------------
; Home
;--------------------------------------------------------
.area HOME (CODE)
.area HOME (CODE)
;--------------------------------------------------------
; code
;--------------------------------------------------------
.area CSEG (CODE)
;------------------------------------------------------------
;Allocation info for local variables in function 'cout'
;------------------------------------------------------------
;c Allocated to registers r7
;------------------------------------------------------------
; bootloader/util.c:46: cout(uint8_t c)
; -----------------------------------------
; function cout
; -----------------------------------------
_cout:
ar7 = 0x07
ar6 = 0x06
ar5 = 0x05
ar4 = 0x04
ar3 = 0x03
ar2 = 0x02
ar1 = 0x01
ar0 = 0x00
mov r7,dpl
; bootloader/util.c:48: while (!TI0)
00101$:
; bootloader/util.c:50: TI0 = 0;
jbc _TI0,00112$
sjmp 00101$
00112$:
; bootloader/util.c:51: SBUF0 = c;
mov _SBUF0,r7
ret
;------------------------------------------------------------
;Allocation info for local variables in function 'cin'
;------------------------------------------------------------
; bootloader/util.c:55: cin(void)
; -----------------------------------------
; function cin
; -----------------------------------------
_cin:
; bootloader/util.c:57: while (!RI0)
00101$:
; bootloader/util.c:59: RI0 = 0;
jbc _RI0,00112$
sjmp 00101$
00112$:
; bootloader/util.c:60: return SBUF0;
mov dpl,_SBUF0
ret
.area CSEG (CODE)
.area CONST (CODE)
.area CABS (ABS,CODE)
| YifanJiangPolyU/SiK-master-Yifan-TDMA | Firmware-bk/obj/rfd900a/bootloader~rfd900a/util.asm | Assembly | bsd-2-clause | 12,376 |
;
; Copyright (c) 2016, Alliance for Open Media. All rights reserved
;
; This source code is subject to the terms of the BSD 2 Clause License and
; the Alliance for Open Media Patent License 1.0. If the BSD 2 Clause License
; was not distributed with this source code in the LICENSE file, you can
; obtain it at www.aomedia.org/license/software. If the Alliance for Open
; Media Patent License 1.0 was not distributed with this source code in the
; PATENTS file, you can obtain it at www.aomedia.org/license/patent.
;
EXPORT |aom_idct16x16_1_add_neon|
ARM
REQUIRE8
PRESERVE8
AREA ||.text||, CODE, READONLY, ALIGN=2
;void aom_idct16x16_1_add_neon(int16_t *input, uint8_t *dest,
; int dest_stride)
;
; r0 int16_t input
; r1 uint8_t *dest
; r2 int dest_stride)
|aom_idct16x16_1_add_neon| PROC
ldrsh r0, [r0]
; generate cospi_16_64 = 11585
mov r12, #0x2d00
add r12, #0x41
; out = dct_const_round_shift(input[0] * cospi_16_64)
mul r0, r0, r12 ; input[0] * cospi_16_64
add r0, r0, #0x2000 ; +(1 << ((DCT_CONST_BITS) - 1))
asr r0, r0, #14 ; >> DCT_CONST_BITS
; out = dct_const_round_shift(out * cospi_16_64)
mul r0, r0, r12 ; out * cospi_16_64
mov r12, r1 ; save dest
add r0, r0, #0x2000 ; +(1 << ((DCT_CONST_BITS) - 1))
asr r0, r0, #14 ; >> DCT_CONST_BITS
; a1 = ROUND_POWER_OF_TWO(out, 6)
add r0, r0, #32 ; + (1 <<((6) - 1))
asr r0, r0, #6 ; >> 6
vdup.s16 q0, r0 ; duplicate a1
mov r0, #8
sub r2, #8
; load destination data row0 - row3
vld1.64 {d2}, [r1], r0
vld1.64 {d3}, [r1], r2
vld1.64 {d4}, [r1], r0
vld1.64 {d5}, [r1], r2
vld1.64 {d6}, [r1], r0
vld1.64 {d7}, [r1], r2
vld1.64 {d16}, [r1], r0
vld1.64 {d17}, [r1], r2
vaddw.u8 q9, q0, d2 ; dest[x] + a1
vaddw.u8 q10, q0, d3 ; dest[x] + a1
vaddw.u8 q11, q0, d4 ; dest[x] + a1
vaddw.u8 q12, q0, d5 ; dest[x] + a1
vqmovun.s16 d2, q9 ; clip_pixel
vqmovun.s16 d3, q10 ; clip_pixel
vqmovun.s16 d30, q11 ; clip_pixel
vqmovun.s16 d31, q12 ; clip_pixel
vst1.64 {d2}, [r12], r0
vst1.64 {d3}, [r12], r2
vst1.64 {d30}, [r12], r0
vst1.64 {d31}, [r12], r2
vaddw.u8 q9, q0, d6 ; dest[x] + a1
vaddw.u8 q10, q0, d7 ; dest[x] + a1
vaddw.u8 q11, q0, d16 ; dest[x] + a1
vaddw.u8 q12, q0, d17 ; dest[x] + a1
vqmovun.s16 d2, q9 ; clip_pixel
vqmovun.s16 d3, q10 ; clip_pixel
vqmovun.s16 d30, q11 ; clip_pixel
vqmovun.s16 d31, q12 ; clip_pixel
vst1.64 {d2}, [r12], r0
vst1.64 {d3}, [r12], r2
vst1.64 {d30}, [r12], r0
vst1.64 {d31}, [r12], r2
; load destination data row4 - row7
vld1.64 {d2}, [r1], r0
vld1.64 {d3}, [r1], r2
vld1.64 {d4}, [r1], r0
vld1.64 {d5}, [r1], r2
vld1.64 {d6}, [r1], r0
vld1.64 {d7}, [r1], r2
vld1.64 {d16}, [r1], r0
vld1.64 {d17}, [r1], r2
vaddw.u8 q9, q0, d2 ; dest[x] + a1
vaddw.u8 q10, q0, d3 ; dest[x] + a1
vaddw.u8 q11, q0, d4 ; dest[x] + a1
vaddw.u8 q12, q0, d5 ; dest[x] + a1
vqmovun.s16 d2, q9 ; clip_pixel
vqmovun.s16 d3, q10 ; clip_pixel
vqmovun.s16 d30, q11 ; clip_pixel
vqmovun.s16 d31, q12 ; clip_pixel
vst1.64 {d2}, [r12], r0
vst1.64 {d3}, [r12], r2
vst1.64 {d30}, [r12], r0
vst1.64 {d31}, [r12], r2
vaddw.u8 q9, q0, d6 ; dest[x] + a1
vaddw.u8 q10, q0, d7 ; dest[x] + a1
vaddw.u8 q11, q0, d16 ; dest[x] + a1
vaddw.u8 q12, q0, d17 ; dest[x] + a1
vqmovun.s16 d2, q9 ; clip_pixel
vqmovun.s16 d3, q10 ; clip_pixel
vqmovun.s16 d30, q11 ; clip_pixel
vqmovun.s16 d31, q12 ; clip_pixel
vst1.64 {d2}, [r12], r0
vst1.64 {d3}, [r12], r2
vst1.64 {d30}, [r12], r0
vst1.64 {d31}, [r12], r2
; load destination data row8 - row11
vld1.64 {d2}, [r1], r0
vld1.64 {d3}, [r1], r2
vld1.64 {d4}, [r1], r0
vld1.64 {d5}, [r1], r2
vld1.64 {d6}, [r1], r0
vld1.64 {d7}, [r1], r2
vld1.64 {d16}, [r1], r0
vld1.64 {d17}, [r1], r2
vaddw.u8 q9, q0, d2 ; dest[x] + a1
vaddw.u8 q10, q0, d3 ; dest[x] + a1
vaddw.u8 q11, q0, d4 ; dest[x] + a1
vaddw.u8 q12, q0, d5 ; dest[x] + a1
vqmovun.s16 d2, q9 ; clip_pixel
vqmovun.s16 d3, q10 ; clip_pixel
vqmovun.s16 d30, q11 ; clip_pixel
vqmovun.s16 d31, q12 ; clip_pixel
vst1.64 {d2}, [r12], r0
vst1.64 {d3}, [r12], r2
vst1.64 {d30}, [r12], r0
vst1.64 {d31}, [r12], r2
vaddw.u8 q9, q0, d6 ; dest[x] + a1
vaddw.u8 q10, q0, d7 ; dest[x] + a1
vaddw.u8 q11, q0, d16 ; dest[x] + a1
vaddw.u8 q12, q0, d17 ; dest[x] + a1
vqmovun.s16 d2, q9 ; clip_pixel
vqmovun.s16 d3, q10 ; clip_pixel
vqmovun.s16 d30, q11 ; clip_pixel
vqmovun.s16 d31, q12 ; clip_pixel
vst1.64 {d2}, [r12], r0
vst1.64 {d3}, [r12], r2
vst1.64 {d30}, [r12], r0
vst1.64 {d31}, [r12], r2
; load destination data row12 - row15
vld1.64 {d2}, [r1], r0
vld1.64 {d3}, [r1], r2
vld1.64 {d4}, [r1], r0
vld1.64 {d5}, [r1], r2
vld1.64 {d6}, [r1], r0
vld1.64 {d7}, [r1], r2
vld1.64 {d16}, [r1], r0
vld1.64 {d17}, [r1], r2
vaddw.u8 q9, q0, d2 ; dest[x] + a1
vaddw.u8 q10, q0, d3 ; dest[x] + a1
vaddw.u8 q11, q0, d4 ; dest[x] + a1
vaddw.u8 q12, q0, d5 ; dest[x] + a1
vqmovun.s16 d2, q9 ; clip_pixel
vqmovun.s16 d3, q10 ; clip_pixel
vqmovun.s16 d30, q11 ; clip_pixel
vqmovun.s16 d31, q12 ; clip_pixel
vst1.64 {d2}, [r12], r0
vst1.64 {d3}, [r12], r2
vst1.64 {d30}, [r12], r0
vst1.64 {d31}, [r12], r2
vaddw.u8 q9, q0, d6 ; dest[x] + a1
vaddw.u8 q10, q0, d7 ; dest[x] + a1
vaddw.u8 q11, q0, d16 ; dest[x] + a1
vaddw.u8 q12, q0, d17 ; dest[x] + a1
vqmovun.s16 d2, q9 ; clip_pixel
vqmovun.s16 d3, q10 ; clip_pixel
vqmovun.s16 d30, q11 ; clip_pixel
vqmovun.s16 d31, q12 ; clip_pixel
vst1.64 {d2}, [r12], r0
vst1.64 {d3}, [r12], r2
vst1.64 {d30}, [r12], r0
vst1.64 {d31}, [r12], r2
bx lr
ENDP ; |aom_idct16x16_1_add_neon|
END
| luctrudeau/VideoExperiments | tf/adst/aom_dsp/arm/idct16x16_1_add_neon.asm | Assembly | mit | 8,426 |
; libgcc routines for ARC cpu.
/* Copyright (C) 1995, 1997,2004 Free Software Foundation, Inc.
This file 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 2, or (at your option) any
later version.
In addition to the permissions in the GNU General Public License, the
Free Software Foundation gives you unlimited permission to link the
compiled version of this file into combinations with other programs,
and to distribute those combinations without any restriction coming
from the use of this file. (The General Public License restrictions
do apply in other respects; for example, they cover modification of
the file, and distribution when not linked into a combine
executable.)
This file is distributed in the hope that it will be useful, but
WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
General Public License for more details.
You should have received a copy of the GNU General Public License
along with GCC; see the file COPYING. If not, write to
the Free Software Foundation, 51 Franklin Street, Fifth Floor,
Boston, MA 02110-1301, USA. */
#ifdef L_mulsi3
.section .text
.align 4
#ifdef __base__
.cpu base
.global ___mulsi3
___mulsi3:
/* This the simple version.
while (a)
{
if (a & 1)
r += b;
a >>= 1;
b <<= 1;
}
*/
mov r2,0 ; Accumulate result here.
.Lloop:
sub.f 0,r0,0 ; while (a)
nop
beq.nd .Ldone
and.f 0,r0,1 ; if (a & 1)
add.nz r2,r2,r1 ; r += b
lsr r0,r0 ; a >>= 1
b.d .Lloop
lsl r1,r1 ; b <<= 1
.Ldone:
j.d blink
mov r0,r2
#endif
#endif /* L_mulsi3 */
#ifdef L_umulsidi3
.section .text
.align 4
#ifdef __base__
.cpu base
.global ___umulsidi3
___umulsidi3:
/* This the simple version.
while (a)
{
if (a & 1)
r += b;
a >>= 1;
b <<= 1;
}
*/
mov r2,0 ; Top part of b.
mov r3,0 ; Accumulate result here.
mov r4,0
.Lloop:
sub.f 0,r0,0 ; while (a)
nop
beq.nd .Ldone
and.f 0,r0,1 ; if (a & 1)
sub.f 0,r0,0
nop
beq .Ldontadd
add.f r4,r4,r1 ; r += b
adc r3,r3,r2
.Ldontadd:
lsr r0,r0 ; a >>= 1
lsl.f r1,r1 ; b <<= 1
b.d .Lloop
rlc r2,r2
.Ldone:
#ifdef __big_endian__
mov r1,r4
j.d blink
mov r0,r3
#else
mov r0,r4
j.d blink
mov r1,r3
#endif
#endif
#endif /* L_umulsidi3 */
#ifdef L_divmod_tools
; Utilities used by all routines.
.section .text
.align 4
; inputs: r0 = numerator, r1 = denominator
; outputs: positive r0/r1,
; r6.bit1 = sign of numerator, r6.bit0 = sign of result
.global ___divnorm
___divnorm:
mov r6,0 ; keep sign in r6
sub.f 0,r0,0 ; is numerator -ve?
sub.lt r0,0,r0 ; negate numerator
mov.lt r6,3 ; sign is -ve
sub.f 0,r1,0 ; is denominator -ve?
sub.lt r1,0,r1 ; negate denominator
xor.lt r6,r6,1 ; toggle sign
j.nd blink
/*
unsigned long
udivmodsi4(int modwanted, unsigned long num, unsigned long den)
{
unsigned long bit = 1;
unsigned long res = 0;
while (den < num && bit && !(den & (1L<<31)))
{
den <<=1;
bit <<=1;
}
while (bit)
{
if (num >= den)
{
num -= den;
res |= bit;
}
bit >>=1;
den >>=1;
}
if (modwanted) return num;
return res;
}
*/
; inputs: r0 = numerator, r1 = denominator
; outputs: r0 = quotient, r1 = remainder, r2/r3 trashed
.global ___udivmodsi4
___udivmodsi4:
mov r2,1 ; bit = 1
mov r3,0 ; res = 0
.Lloop1:
sub.f 0,r1,r0 ; while (den < num
nop
bnc.nd .Lloop2
sub.f 0,r2,0 ; && bit
nop
bz.nd .Lloop2
lsl.f 0,r1 ; && !(den & (1<<31))
nop
bc.nd .Lloop2
lsl r1,r1 ; den <<= 1
b.d .Lloop1
lsl r2,r2 ; bit <<= 1
.Lloop2:
sub.f 0,r2,0 ; while (bit)
nop
bz.nd .Ldivmodend
sub.f 0,r0,r1 ; if (num >= den)
nop
bc.nd .Lshiftdown
sub r0,r0,r1 ; num -= den
or r3,r3,r2 ; res |= bit
.Lshiftdown:
lsr r2,r2 ; bit >>= 1
b.d .Lloop2
lsr r1,r1 ; den >>= 1
.Ldivmodend:
mov r1,r0 ; r1 = mod
j.d blink
mov r0,r3 ; r0 = res
#endif
#ifdef L_udivsi3
.section .text
.align 4
#ifdef __base__
.cpu base
.global ___udivsi3
___udivsi3:
mov r7,blink
bl.nd ___udivmodsi4
j.nd r7
#endif
#endif /* L_udivsi3 */
#ifdef L_divsi3
.section .text
.align 4
#ifdef __base__
.cpu base
.global ___divsi3
___divsi3:
mov r7,blink
bl.nd ___divnorm
bl.nd ___udivmodsi4
and.f 0,r6,1
sub.nz r0,0,r0 ; cannot go in delay slot, has limm value
j.nd r7
#endif
#endif /* L_divsi3 */
#ifdef L_umodsi3
.section .text
.align 4
#ifdef __base__
.cpu base
.global ___umodsi3
___umodsi3:
mov r7,blink
bl.nd ___udivmodsi4
j.d r7
mov r0,r1
#endif
#endif /* L_umodsi3 */
#ifdef L_modsi3
.section .text
.align 4
#ifdef __base__
.cpu base
.global ___modsi3
___modsi3:
mov r7,blink
bl.nd ___divnorm
bl.nd ___udivmodsi4
and.f 0,r6,2
sub.nz r1,0,r1
j.d r7
mov r0,r1
#endif
#endif /* L_modsi3 */
| shaotuanchen/sunflower_exp | tools/source/gcc-4.2.4/gcc/config/arc/lib1funcs.asm | Assembly | bsd-3-clause | 4,922 |
;;; PC Speaker 1-bit digital audio
;;;
;;; This routine demonstrates producing crackly but recognizable
;;; sound with the PC speaker by jamming the high bit of PCM data
;;; into the PC speaker state.
;;;
;;; Because of the 60-microsecond transition time of the PC speaker,
;;; very high transfer rates start making this work like multi-bit
;;; ADPCM. This effect is barely present at 16kHz, the speed we use
;;; in this test program.
;;;
;;; Despite the "cpu 8086" marker here, the fact that this code is
;;; firing timing interrupts at 16 kHz does mean that you will
;;; probably want a reasonably fast (12MHz+) machine. DOSBox's default
;;; 3000-cycles speed is fine.
cpu 8086
bits 16
org 100h
counter equ (0x1234DC / 16000) & 0xFFFE
segment .bss
biostick: resb 4
dataptr: resb 4
segment .text
;; Record the original BIOS timing routine
mov ax, 0x3508
int 21h
mov [biostick], bx
mov bx, es
mov [biostick+2], bx
;; Load the data pointer for use by our sound code
mov ax, data
mov [dataptr], ax
mov ax, ds
mov [dataptr+2], ax
;; Replace IRQ0 with our sound code
mov dx, tick
mov ax, 0x2508
int 21h
;; Reprogram PIT Channel 0 to fire IRQ0 at 16kHz
cli
mov al, 0x36
out 0x43, al
mov ax, counter
out 0x40, al
mov al, ah
out 0x40, al
sti
;; Keep processing interrupts until it says we're done
mainlp: hlt
mov ax, [done]
or ax, ax
jz mainlp
;; Restore original IRQ0
lds dx, [biostick]
mov ax, 0x2508
int 21h
;; And quit with success
mov ax, 0x4c00
int 21h
;; *** IRQ0 TICK ROUTINE ***
tick: push ds ; Save flags
push ax
push bx
push si
lds bx, [dataptr] ; Load our data pointers
mov si, [offset]
cmp si, datasize ; past the end?
jae .nosnd
mov ah, [ds:bx+si] ; If not, load up the value
rol ah, 1 ; Move bit 7 to bit 1
rol ah, 1
and ah, 2 ; And mask out everything else
in al, 0x61 ; Or that with the state of port 0x61
and al, 0xFC ; (setting the PC speaker's target
or al, ah ; state to the sample's high bit)
out 0x61, al
inc si ; Update pointer
mov [offset], si
jmp .intend ; ... and jump to end of interrupt
;; If we get here, we're past the end of the sound.
.nosnd: mov ax, [done] ; Have we already marked it done?
jnz .intend ; If so, nothing left to do
mov ax, 1 ; Otherwise, mark it done...
mov [done], ax
mov al, 0x36 ; ... and slow the timer back down
out 0x43, al ; to 18.2 Hz
xor al, al
out 0x40, al
out 0x40, al
.intend:
mov ax, [subtick] ; Add microsecond count to the counter
add ax, counter
mov [subtick], ax
jnc .nobios ; If carry, it's time for a BIOS call
mov bx, biostick ; Point DS:BX at our saved address...
pushf ; and PUSHF/CALL FAR to simulate an
call far [ds:bx] ; interrupt
jmp .fin
.nobios:
mov al, 0x20 ; If not, then acknowledge the IRQ
out 0x20, al
.fin:
pop si ; Restore stack and get out
pop bx
pop ax
pop ds
iret
segment .data
done: dw 0
offset: dw 0
subtick: dw 0
data: incbin "wow.raw" ; Up to 64KB of 16 kHz 8-bit unsigned LPCM
dataend:
datasize equ dataend - data
| michaelcmartin/bumbershoot | dos/sound/1bitdac.asm | Assembly | mit | 4,069 |
processor 6502
include "scenesetup.inc"
ORG ENDFONTADR
incbin "finCharset.bin" | kosmonautdnb/TheLandsOfZador | EndingScene/_code/GlobalCode/finCharset.asm | Assembly | mit | 96 |
%define LoadImageEx (0x4065c0 - 0x116000)
%define RegularExit_OslLoadDrivers (0x405b99 - 0x116000)
%define SEGMENT_START (0x4c3000 - 0x116000)
BITS 64 ; Y U NO ALL THE BITS?
; TO CALL TO BOOTY, you want JUMP 0x4c301b ;)
SECTION .booty
driverPath db "\SystemRoot\zomgdabest.sys", 0
; since we're jumping here at the end of the function
; re-run the checks to see if we got here by regular exit
; ie don't run the below code if we were only gonna exit because of failure
cmp rdi, r15
jnz cleanup
cmp eax, ebx
jnz cleanup
mov rcx, SEGMENT_START + driverPath
;mov dword [rsp+0B8h+var_98], 0E0000013h ; in case warning was called, this gets wiped out
nop
nop
nop
nop
nop
nop
nop
nop
mov r14, LoadImageEx
call r14
cleanup:
pop r15
pop r14
pop r13
pop r12
pop rdi
pop rsi
pop rbp
retn | ahixon/booty | src/winload-hacks/assembly/codecave.asm | Assembly | mit | 1,042 |
.model small
.data
text db 10,13,'Your processor is: $'
n86 db '8086',10,13,'$'
n286 db '80286',10,13,'$'
n386 db '80386',10,13,'$'
n486 db '80486',10,13,'$'
n686 db '6x86',10,13,'$'
nPentium db 'Pentium',10,13,'$'
nPentiumII db 'Pentium II',10,13,'$'
nAMD db 'AMD',10,13,'$'
.code
s:
mov ax, @data
mov ds, ax
mov dx, offset text
mov ah, 09h
int 21h
mov ax, 1686h
int 2Fh
cmp cl, 0
jne n2Check
mov dx, offset n86
jmp Print
n2Check:
cmp cl, 02h
jne n3Check
mov dx, offset n286
jmp Print
n3Check:
cmp cl, 03h
jne n4Check
mov dx, offset n386
jmp Print
n4Check:
cmp cl, 04h
jne n5Check
mov dx, offset n486
jmp Print
n5Check:
cmp cl, 05h
jne n6Check
mov dx, offset n686
jmp Print
n6Check:
cmp cl, 06h
jne n7Check
mov dx, offset nPentium
jmp Print
n7Check:
cmp cl, 07h
jne n8Check
mov dx, offset nPentiumII
jmp Print
n8Check:
cmp cl, 0ffh
jne X
mov dx, offset nAMD
Print:
mov ah, 09h
int 21h
X:
mov ax, 4c00h
int 21h
end s | vbmacher/qsOS | utils/hardware/cputype/cpu.asm | Assembly | apache-2.0 | 932 |
*
* $Id: amiga_callhooka.asm,v 1.3 2006-01-08 12:04:22 obarthel Exp $
*
* :ts=8
*
* Portable ISO 'C' (1994) runtime library for the Amiga computer
* Copyright (c) 2002-2015 by Olaf Barthel <obarthel (at) gmx.net>
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions
* are met:
*
* - Redistributions of source code must retain the above copyright
* notice, this list of conditions and the following disclaimer.
*
* - Neither the name of Olaf Barthel nor the names of contributors
* may be used to endorse or promote products derived from this
* software without specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
* AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
* IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
* ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE
* LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
* CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
* SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
* INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
* CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
* ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
* POSSIBILITY OF SUCH DAMAGE.
*
section text,code
h_Entry equ 8
xdef _CallHookA
****************************************************************************
* new hook standard
* use struct Hook (with minnode at the top)
*
* *** register calling convention: ***
* A0 - pointer to hook itself
* A1 - pointer to parameter packed ("message")
* A2 - Hook specific address data ("object," e.g, gadget )
*
* *** C conventions: ***
* Note that parameters are in unusual register order: a0, a2, a1.
* This is to provide a performance boost for assembly language
* programming (the object in a2 is most frequently untouched).
* It is also no problem in "register direct" C function parameters.
*
* calling through a hook
* CallHook( hook, object, msgid, p1, p2, ... );
* CallHookA( hook, object, msgpkt );
*
* using a C function: CFunction( hook, object, message );
* hook.h_Entry = HookEntry;
* hook.h_SubEntry = CFunction;
*
****************************************************************************
* C calling hook interface for prepared message packet
_CallHookA:
movem.l a2/a6,-(sp)
move.l 12(sp),a0
move.l 16(sp),a2
move.l 20(sp),a1
pea.l hook_return(pc)
move.l h_Entry(a0),-(sp)
rts
hook_return:
movem.l (sp)+,a2/a6
rts
end
| adtools/clib2 | library/amiga_callhooka.asm | Assembly | bsd-3-clause | 2,761 |
$NOMOD51
;-----------------------------------------------------------------------------
$include (c8051f020.inc) ; Include register definition file.
;Authors: Tyler Long, Wil Smith, and Vincent Watkins
;-----------------------------------------------------------------------------
; RESET and INTERRUPT VECTORS
;-----------------------------------------------------------------------------
; Reset Vector
cseg AT 0
ljmp Main ; Locate a jump to the start of code at
; the reset vector.
;-----------------------------------------------------------------------------
; CODE SEGMENT
;-----------------------------------------------------------------------------
Blink segment CODE
rseg Blink ; Switch to this code segment.
using 0 ; Specify register bank for the following
; program code.
Main: ; Disable the WDT. (IRQs not enabled at this point.)
; If interrupts were enabled, we would need to explicitly disable
; them so that the 2nd move to WDTCN occurs no more than four clock
; cycles after the first move to WDTCN.
mov WDTCN, #0DEh
mov WDTCN, #0ADh
mov XBR2, #40h ; Enable the Port I/O Crossbar
mov XBR1, #80h ; Place Clock on P0.0 for CPLD
; Set all of P1 as digital output in push-pull mode.
orl P1MDIN, #0FFh
orl P1MDOUT,#0FFh
; Initialize LED to OFF
clr P1.0
clr P1.1
clr P1.2
clr P1.3
clr P1.4
clr P1.5
clr P1.6
clr P1.7
mov A, #80h ;Create Exit from loop
; Simple delay loop.
Loop2: mov R7, #03h
Loop1: mov R6, #00h
Loop0: mov R5, #00h
djnz R5, $
djnz R6, Loop0
djnz R7, Loop1
setb P1.0 ;Enable Flash
cpl P1.1 ; Toggle LED.
cpl P1.2 ; Toggle LED.
cpl P1.3 ; Toggle LED.
cpl P1.4 ; Toggle LED.
cpl P1.5 ; Toggle LED.
cpl P1.6 ; Toggle LED.
cpl P1.7 ; Toggle LED.
dec A
jz Finish ; Jump out of loop
jmp Loop2
Finish: clr P1.0 ;Turn off Flash
clr P1.1 ;Turn off LED
clr P1.2 ;Turn off LED
clr P1.3 ;Turn off LED
clr P1.4 ;Turn off LED
clr P1.5 ;Turn off LED
clr P1.6 ;Turn off LED
clr P1.7 ;Turn off LED
sjmp $ ;Lock up program
;-----------------------------------------------------------------------------
; End of file.
END | tblong/school | ECET 3220/Code/Milestone_01/Milestone1/test.asm | Assembly | mit | 2,883 |
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
; Copyright(c) 2011-2020 Intel Corporation All rights reserved.
;
; Redistribution and use in source and binary forms, with or without
; modification, are permitted provided that the following conditions
; are met:
; * Redistributions of source code must retain the above copyright
; notice, this list of conditions and the following disclaimer.
; * Redistributions in binary form must reproduce the above copyright
; notice, this list of conditions and the following disclaimer in
; the documentation and/or other materials provided with the
; distribution.
; * Neither the name of Intel Corporation nor the names of its
; contributors may be used to endorse or promote products derived
; from this software without specific prior written permission.
;
; THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
; "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
; LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
; A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
; OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
; SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
; LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
; DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
; THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
; (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
; OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
; Function API:
; UINT32 crc32_gzip_refl_by16_10(
; UINT32 init_crc, //initial CRC value, 32 bits
; const unsigned char *buf, //buffer pointer to calculate CRC on
; UINT64 len //buffer length in bytes (64-bit data)
; );
;
; Authors:
; Erdinc Ozturk
; Vinodh Gopal
; James Guilford
;
; Reference paper titled "Fast CRC Computation for Generic Polynomials Using PCLMULQDQ Instruction"
; URL: http://www.intel.com/content/dam/www/public/us/en/documents/white-papers/fast-crc-computation-generic-polynomials-pclmulqdq-paper.pdf
;
;
%include "reg_sizes.asm"
%ifndef FUNCTION_NAME
%define FUNCTION_NAME crc32_ieee_by16_10
%endif
%if (AS_FEATURE_LEVEL) >= 10
[bits 64]
default rel
section .text
%ifidn __OUTPUT_FORMAT__, win64
%xdefine arg1 rcx
%xdefine arg2 rdx
%xdefine arg3 r8
%xdefine arg1_low32 ecx
%else
%xdefine arg1 rdi
%xdefine arg2 rsi
%xdefine arg3 rdx
%xdefine arg1_low32 edi
%endif
%define TMP 16*0
%ifidn __OUTPUT_FORMAT__, win64
%define XMM_SAVE 16*2
%define VARIABLE_OFFSET 16*12+8
%else
%define VARIABLE_OFFSET 16*2+8
%endif
align 16
mk_global FUNCTION_NAME, function
FUNCTION_NAME:
endbranch
not arg1_low32
sub rsp, VARIABLE_OFFSET
%ifidn __OUTPUT_FORMAT__, win64
; push the xmm registers into the stack to maintain
vmovdqa [rsp + XMM_SAVE + 16*0], xmm6
vmovdqa [rsp + XMM_SAVE + 16*1], xmm7
vmovdqa [rsp + XMM_SAVE + 16*2], xmm8
vmovdqa [rsp + XMM_SAVE + 16*3], xmm9
vmovdqa [rsp + XMM_SAVE + 16*4], xmm10
vmovdqa [rsp + XMM_SAVE + 16*5], xmm11
vmovdqa [rsp + XMM_SAVE + 16*6], xmm12
vmovdqa [rsp + XMM_SAVE + 16*7], xmm13
vmovdqa [rsp + XMM_SAVE + 16*8], xmm14
vmovdqa [rsp + XMM_SAVE + 16*9], xmm15
%endif
vbroadcasti32x4 zmm18, [SHUF_MASK]
cmp arg3, 256
jl .less_than_256
; load the initial crc value
vmovd xmm10, arg1_low32 ; initial crc
; crc value does not need to be byte-reflected, but it needs to be moved to the high part of the register.
; because data will be byte-reflected and will align with initial crc at correct place.
vpslldq xmm10, 12
; receive the initial 64B data, xor the initial crc value
vmovdqu8 zmm0, [arg2+16*0]
vmovdqu8 zmm4, [arg2+16*4]
vpshufb zmm0, zmm0, zmm18
vpshufb zmm4, zmm4, zmm18
vpxorq zmm0, zmm10
vbroadcasti32x4 zmm10, [rk3] ;xmm10 has rk3 and rk4
;imm value of pclmulqdq instruction will determine which constant to use
sub arg3, 256
cmp arg3, 256
jl .fold_128_B_loop
vmovdqu8 zmm7, [arg2+16*8]
vmovdqu8 zmm8, [arg2+16*12]
vpshufb zmm7, zmm7, zmm18
vpshufb zmm8, zmm8, zmm18
vbroadcasti32x4 zmm16, [rk_1] ;zmm16 has rk-1 and rk-2
sub arg3, 256
.fold_256_B_loop:
add arg2, 256
vmovdqu8 zmm3, [arg2+16*0]
vpshufb zmm3, zmm3, zmm18
vpclmulqdq zmm1, zmm0, zmm16, 0x00
vpclmulqdq zmm2, zmm0, zmm16, 0x11
vpxorq zmm0, zmm1, zmm2
vpxorq zmm0, zmm0, zmm3
vmovdqu8 zmm9, [arg2+16*4]
vpshufb zmm9, zmm9, zmm18
vpclmulqdq zmm5, zmm4, zmm16, 0x00
vpclmulqdq zmm6, zmm4, zmm16, 0x11
vpxorq zmm4, zmm5, zmm6
vpxorq zmm4, zmm4, zmm9
vmovdqu8 zmm11, [arg2+16*8]
vpshufb zmm11, zmm11, zmm18
vpclmulqdq zmm12, zmm7, zmm16, 0x00
vpclmulqdq zmm13, zmm7, zmm16, 0x11
vpxorq zmm7, zmm12, zmm13
vpxorq zmm7, zmm7, zmm11
vmovdqu8 zmm17, [arg2+16*12]
vpshufb zmm17, zmm17, zmm18
vpclmulqdq zmm14, zmm8, zmm16, 0x00
vpclmulqdq zmm15, zmm8, zmm16, 0x11
vpxorq zmm8, zmm14, zmm15
vpxorq zmm8, zmm8, zmm17
sub arg3, 256
jge .fold_256_B_loop
;; Fold 256 into 128
add arg2, 256
vpclmulqdq zmm1, zmm0, zmm10, 0x00
vpclmulqdq zmm2, zmm0, zmm10, 0x11
vpternlogq zmm7, zmm1, zmm2, 0x96 ; xor ABC
vpclmulqdq zmm5, zmm4, zmm10, 0x00
vpclmulqdq zmm6, zmm4, zmm10, 0x11
vpternlogq zmm8, zmm5, zmm6, 0x96 ; xor ABC
vmovdqa32 zmm0, zmm7
vmovdqa32 zmm4, zmm8
add arg3, 128
jmp .fold_128_B_register
; at this section of the code, there is 128*x+y (0<=y<128) bytes of buffer. The fold_128_B_loop
; loop will fold 128B at a time until we have 128+y Bytes of buffer
; fold 128B at a time. This section of the code folds 8 xmm registers in parallel
.fold_128_B_loop:
add arg2, 128
vmovdqu8 zmm8, [arg2+16*0]
vpshufb zmm8, zmm8, zmm18
vpclmulqdq zmm2, zmm0, zmm10, 0x00
vpclmulqdq zmm1, zmm0, zmm10, 0x11
vpxorq zmm0, zmm2, zmm1
vpxorq zmm0, zmm0, zmm8
vmovdqu8 zmm9, [arg2+16*4]
vpshufb zmm9, zmm9, zmm18
vpclmulqdq zmm5, zmm4, zmm10, 0x00
vpclmulqdq zmm6, zmm4, zmm10, 0x11
vpxorq zmm4, zmm5, zmm6
vpxorq zmm4, zmm4, zmm9
sub arg3, 128
jge .fold_128_B_loop
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
add arg2, 128
; at this point, the buffer pointer is pointing at the last y Bytes of the buffer, where 0 <= y < 128
; the 128B of folded data is in 8 of the xmm registers: xmm0, xmm1, xmm2, xmm3, xmm4, xmm5, xmm6, xmm7
.fold_128_B_register:
; fold the 8 128b parts into 1 xmm register with different constants
vmovdqu8 zmm16, [rk9] ; multiply by rk9-rk16
vmovdqu8 zmm11, [rk17] ; multiply by rk17-rk20, rk1,rk2, 0,0
vpclmulqdq zmm1, zmm0, zmm16, 0x00
vpclmulqdq zmm2, zmm0, zmm16, 0x11
vextracti64x2 xmm7, zmm4, 3 ; save last that has no multiplicand
vpclmulqdq zmm5, zmm4, zmm11, 0x00
vpclmulqdq zmm6, zmm4, zmm11, 0x11
vmovdqa xmm10, [rk1] ; Needed later in reduction loop
vpternlogq zmm1, zmm2, zmm5, 0x96 ; xor ABC
vpternlogq zmm1, zmm6, zmm7, 0x96 ; xor ABC
vshufi64x2 zmm8, zmm1, zmm1, 0x4e ; Swap 1,0,3,2 - 01 00 11 10
vpxorq ymm8, ymm8, ymm1
vextracti64x2 xmm5, ymm8, 1
vpxorq xmm7, xmm5, xmm8
; instead of 128, we add 128-16 to the loop counter to save 1 instruction from the loop
; instead of a cmp instruction, we use the negative flag with the jl instruction
add arg3, 128-16
jl .final_reduction_for_128
; now we have 16+y bytes left to reduce. 16 Bytes is in register xmm7 and the rest is in memory
; we can fold 16 bytes at a time if y>=16
; continue folding 16B at a time
.16B_reduction_loop:
vpclmulqdq xmm8, xmm7, xmm10, 0x11
vpclmulqdq xmm7, xmm7, xmm10, 0x00
vpxor xmm7, xmm8
vmovdqu xmm0, [arg2]
vpshufb xmm0, xmm0, xmm18
vpxor xmm7, xmm0
add arg2, 16
sub arg3, 16
; instead of a cmp instruction, we utilize the flags with the jge instruction
; equivalent of: cmp arg3, 16-16
; check if there is any more 16B in the buffer to be able to fold
jge .16B_reduction_loop
;now we have 16+z bytes left to reduce, where 0<= z < 16.
;first, we reduce the data in the xmm7 register
.final_reduction_for_128:
add arg3, 16
je .128_done
; here we are getting data that is less than 16 bytes.
; since we know that there was data before the pointer, we can offset
; the input pointer before the actual point, to receive exactly 16 bytes.
; after that the registers need to be adjusted.
.get_last_two_xmms:
vmovdqa xmm2, xmm7
vmovdqu xmm1, [arg2 - 16 + arg3]
vpshufb xmm1, xmm18
; get rid of the extra data that was loaded before
; load the shift constant
lea rax, [pshufb_shf_table + 16]
sub rax, arg3
vmovdqu xmm0, [rax]
vpshufb xmm2, xmm0
vpxor xmm0, [mask1]
vpshufb xmm7, xmm0
vpblendvb xmm1, xmm1, xmm2, xmm0
vpclmulqdq xmm8, xmm7, xmm10, 0x11
vpclmulqdq xmm7, xmm7, xmm10, 0x00
vpxor xmm7, xmm8
vpxor xmm7, xmm1
.128_done:
; compute crc of a 128-bit value
vmovdqa xmm10, [rk5]
vmovdqa xmm0, xmm7
;64b fold
vpclmulqdq xmm7, xmm10, 0x01 ; H*L
vpslldq xmm0, 8
vpxor xmm7, xmm0
;32b fold
vmovdqa xmm0, xmm7
vpand xmm0, [mask2]
vpsrldq xmm7, 12
vpclmulqdq xmm7, xmm10, 0x10
vpxor xmm7, xmm0
;barrett reduction
.barrett:
vmovdqa xmm10, [rk7] ; rk7 and rk8 in xmm10
vmovdqa xmm0, xmm7
vpclmulqdq xmm7, xmm10, 0x01
vpslldq xmm7, 4
vpclmulqdq xmm7, xmm10, 0x11
vpslldq xmm7, 4
vpxor xmm7, xmm0
vpextrd eax, xmm7, 1
.cleanup:
not eax
%ifidn __OUTPUT_FORMAT__, win64
vmovdqa xmm6, [rsp + XMM_SAVE + 16*0]
vmovdqa xmm7, [rsp + XMM_SAVE + 16*1]
vmovdqa xmm8, [rsp + XMM_SAVE + 16*2]
vmovdqa xmm9, [rsp + XMM_SAVE + 16*3]
vmovdqa xmm10, [rsp + XMM_SAVE + 16*4]
vmovdqa xmm11, [rsp + XMM_SAVE + 16*5]
vmovdqa xmm12, [rsp + XMM_SAVE + 16*6]
vmovdqa xmm13, [rsp + XMM_SAVE + 16*7]
vmovdqa xmm14, [rsp + XMM_SAVE + 16*8]
vmovdqa xmm15, [rsp + XMM_SAVE + 16*9]
%endif
add rsp, VARIABLE_OFFSET
ret
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
align 16
.less_than_256:
; check if there is enough buffer to be able to fold 16B at a time
cmp arg3, 32
jl .less_than_32
; if there is, load the constants
vmovdqa xmm10, [rk1] ; rk1 and rk2 in xmm10
vmovd xmm0, arg1_low32 ; get the initial crc value
vpslldq xmm0, 12 ; align it to its correct place
vmovdqu xmm7, [arg2] ; load the plaintext
vpshufb xmm7, xmm18 ; byte-reflect the plaintext
vpxor xmm7, xmm0
; update the buffer pointer
add arg2, 16
; update the counter. subtract 32 instead of 16 to save one instruction from the loop
sub arg3, 32
jmp .16B_reduction_loop
align 16
.less_than_32:
; mov initial crc to the return value. this is necessary for zero-length buffers.
mov eax, arg1_low32
test arg3, arg3
je .cleanup
vmovd xmm0, arg1_low32 ; get the initial crc value
vpslldq xmm0, 12 ; align it to its correct place
cmp arg3, 16
je .exact_16_left
jl .less_than_16_left
vmovdqu xmm7, [arg2] ; load the plaintext
vpshufb xmm7, xmm18
vpxor xmm7, xmm0 ; xor the initial crc value
add arg2, 16
sub arg3, 16
vmovdqa xmm10, [rk1] ; rk1 and rk2 in xmm10
jmp .get_last_two_xmms
align 16
.less_than_16_left:
; use stack space to load data less than 16 bytes, zero-out the 16B in memory first.
vpxor xmm1, xmm1
mov r11, rsp
vmovdqa [r11], xmm1
cmp arg3, 4
jl .only_less_than_4
; backup the counter value
mov r9, arg3
cmp arg3, 8
jl .less_than_8_left
; load 8 Bytes
mov rax, [arg2]
mov [r11], rax
add r11, 8
sub arg3, 8
add arg2, 8
.less_than_8_left:
cmp arg3, 4
jl .less_than_4_left
; load 4 Bytes
mov eax, [arg2]
mov [r11], eax
add r11, 4
sub arg3, 4
add arg2, 4
.less_than_4_left:
cmp arg3, 2
jl .less_than_2_left
; load 2 Bytes
mov ax, [arg2]
mov [r11], ax
add r11, 2
sub arg3, 2
add arg2, 2
.less_than_2_left:
cmp arg3, 1
jl .zero_left
; load 1 Byte
mov al, [arg2]
mov [r11], al
.zero_left:
vmovdqa xmm7, [rsp]
vpshufb xmm7, xmm18
vpxor xmm7, xmm0 ; xor the initial crc value
lea rax, [pshufb_shf_table + 16]
sub rax, r9
vmovdqu xmm0, [rax]
vpxor xmm0, [mask1]
vpshufb xmm7,xmm0
jmp .128_done
align 16
.exact_16_left:
vmovdqu xmm7, [arg2]
vpshufb xmm7, xmm18
vpxor xmm7, xmm0 ; xor the initial crc value
jmp .128_done
.only_less_than_4:
cmp arg3, 3
jl .only_less_than_3
; load 3 Bytes
mov al, [arg2]
mov [r11], al
mov al, [arg2+1]
mov [r11+1], al
mov al, [arg2+2]
mov [r11+2], al
vmovdqa xmm7, [rsp]
vpshufb xmm7, xmm18
vpxor xmm7, xmm0 ; xor the initial crc value
vpsrldq xmm7, 5
jmp .barrett
.only_less_than_3:
cmp arg3, 2
jl .only_less_than_2
; load 2 Bytes
mov al, [arg2]
mov [r11], al
mov al, [arg2+1]
mov [r11+1], al
vmovdqa xmm7, [rsp]
vpshufb xmm7, xmm18
vpxor xmm7, xmm0 ; xor the initial crc value
vpsrldq xmm7, 6
jmp .barrett
.only_less_than_2:
; load 1 Byte
mov al, [arg2]
mov [r11], al
vmovdqa xmm7, [rsp]
vpshufb xmm7, xmm18
vpxor xmm7, xmm0 ; xor the initial crc value
vpsrldq xmm7, 7
jmp .barrett
section .data
align 32
%ifndef USE_CONSTS
; precomputed constants
rk_1: dq 0x1851689900000000
rk_2: dq 0xa3dc855100000000
rk1: dq 0xf200aa6600000000
rk2: dq 0x17d3315d00000000
rk3: dq 0x022ffca500000000
rk4: dq 0x9d9ee22f00000000
rk5: dq 0xf200aa6600000000
rk6: dq 0x490d678d00000000
rk7: dq 0x0000000104d101df
rk8: dq 0x0000000104c11db7
rk9: dq 0x6ac7e7d700000000
rk10: dq 0xfcd922af00000000
rk11: dq 0x34e45a6300000000
rk12: dq 0x8762c1f600000000
rk13: dq 0x5395a0ea00000000
rk14: dq 0x54f2d5c700000000
rk15: dq 0xd3504ec700000000
rk16: dq 0x57a8445500000000
rk17: dq 0xc053585d00000000
rk18: dq 0x766f1b7800000000
rk19: dq 0xcd8c54b500000000
rk20: dq 0xab40b71e00000000
rk_1b: dq 0xf200aa6600000000
rk_2b: dq 0x17d3315d00000000
dq 0x0000000000000000
dq 0x0000000000000000
%else
INCLUDE_CONSTS
%endif
mask1: dq 0x8080808080808080, 0x8080808080808080
mask2: dq 0xFFFFFFFFFFFFFFFF, 0x00000000FFFFFFFF
SHUF_MASK: dq 0x08090A0B0C0D0E0F, 0x0001020304050607
pshufb_shf_table:
; use these values for shift constants for the pshufb instruction
; different alignments result in values as shown:
; dq 0x8887868584838281, 0x008f8e8d8c8b8a89 ; shl 15 (16-1) / shr1
; dq 0x8988878685848382, 0x01008f8e8d8c8b8a ; shl 14 (16-3) / shr2
; dq 0x8a89888786858483, 0x0201008f8e8d8c8b ; shl 13 (16-4) / shr3
; dq 0x8b8a898887868584, 0x030201008f8e8d8c ; shl 12 (16-4) / shr4
; dq 0x8c8b8a8988878685, 0x04030201008f8e8d ; shl 11 (16-5) / shr5
; dq 0x8d8c8b8a89888786, 0x0504030201008f8e ; shl 10 (16-6) / shr6
; dq 0x8e8d8c8b8a898887, 0x060504030201008f ; shl 9 (16-7) / shr7
; dq 0x8f8e8d8c8b8a8988, 0x0706050403020100 ; shl 8 (16-8) / shr8
; dq 0x008f8e8d8c8b8a89, 0x0807060504030201 ; shl 7 (16-9) / shr9
; dq 0x01008f8e8d8c8b8a, 0x0908070605040302 ; shl 6 (16-10) / shr10
; dq 0x0201008f8e8d8c8b, 0x0a09080706050403 ; shl 5 (16-11) / shr11
; dq 0x030201008f8e8d8c, 0x0b0a090807060504 ; shl 4 (16-12) / shr12
; dq 0x04030201008f8e8d, 0x0c0b0a0908070605 ; shl 3 (16-13) / shr13
; dq 0x0504030201008f8e, 0x0d0c0b0a09080706 ; shl 2 (16-14) / shr14
; dq 0x060504030201008f, 0x0e0d0c0b0a090807 ; shl 1 (16-15) / shr15
dq 0x8786858483828100, 0x8f8e8d8c8b8a8988
dq 0x0706050403020100, 0x000e0d0c0b0a0908
dq 0x8080808080808080, 0x0f0e0d0c0b0a0908
dq 0x8080808080808080, 0x8080808080808080
%else ; Assembler doesn't understand these opcodes. Add empty symbol for windows.
%ifidn __OUTPUT_FORMAT__, win64
global no_ %+ FUNCTION_NAME
no_ %+ FUNCTION_NAME %+ :
%endif
%endif ; (AS_FEATURE_LEVEL) >= 10
| Intel-HLS/GKL | src/main/native/compression/isa-l-master/crc/crc32_ieee_by16_10.asm | Assembly | mit | 16,027 |
.686p
.mmx
.model flat,stdcall
option casemap:none
option prologue:none
option epilogue:none
.code
compareone proc ptrA:DWORD
push eax
push esi
mov esi, dword ptr [esp+4+8]
mov eax, dword ptr [esi+12]
or eax, dword ptr [esi+ 8]
or eax, dword ptr [esi+ 4]
test eax, eax
jnz @F
cmp dword ptr [esi], 1
@@: pop esi
pop eax
ret 4
compareone endp
end | FloydZ/Crypto-Hash | ecdsa128/src/GFp_src/src/compareone.asm | Assembly | mit | 365 |
// Rockman X3 Practice ROM hack
// by Myria
//
arch snes.cpu
// LoROM org macro - see bass's snes-cpu.asm "seek" macro
macro reorg n
org ((({n}) & 0x7f0000) >> 1) | (({n}) & 0x7fff)
base {n}
endmacro
// Warn if the current address is greater than the specified value.
macro warnpc n
{#}:
if {#} > {n}
warning "warnpc assertion failure"
endif
endmacro
// Allows saving the current location and seeking somewhere else.
define savepc push origin, base
define loadpc pull base, origin
// Warn if the expression is false.
macro static_assert n
if ({n}) == 0
warning "static assertion failure"
endif
endmacro
// Copy the original ROM to initialize the address space.
{reorg $008000}
incbin "RockmanX3-original.smc"
// Version tags
eval version_major 0
eval version_minor 8
eval version_revision 2
// Constants
eval stage_intro 0
eval stage_doppler1 9
eval stage_doppler2 10
eval stage_doppler3 11
eval stage_doppler4 12
eval game_config_size $1B
eval soundnum_cant_escape $5A
eval magic_sram_tag_lo $3358 // Combined, these say "X3PR"
eval magic_sram_tag_hi $5250
eval magic_config_tag_lo $3358 // Combined, these say "X3C1"
eval magic_config_tag_hi $3147
// RAM addresses
eval title_screen_option $7E003C
eval controller_1_current $7E00A8
eval controller_1_previous $7E00AA
eval controller_1_new $7E00AC
eval controller_2_current $7E00AE
eval controller_2_previous $7E00B0
eval controller_2_new $7E00B2
eval screen_control_shadow $7E00B4
eval nmi_control_shadow $7E00C3
eval hdma_control_shadow $7E00C4
eval rng_value $7E09D6
eval controller_1_disable $7E1F63
eval event_flags $7E1FB2
eval state_vars $7E1FA0
eval state_level_already_loaded $7E1FB6
//x3fixme eval current_level $7E1F7A
//x3fixme eval life_count $7E1F80
//x3fixme eval midpoint_flag $7E1F81
//x3fixme eval weapon_power $7E1F85
//x3fixme eval intro_completed $7E1F9B
eval config_selected_option $7EFF80
eval config_data $7EFFC0
eval config_shot $7EFFC0
eval config_jump $7EFFC1
eval config_dash $7EFFC2
eval config_select_l $7EFFC3
eval config_select_r $7EFFC4
eval config_menu $7EFFC5
eval config_bgm $7EFFC8 // unused in X2 and X3, but might as well reuse these
eval config_se $7EFFC9 // unused in X2 and X3, but might as well reuse these
eval config_sound $7EFFCA
eval spc_state_shadow $7EFFFE
// Temporary storage for load process. Overlaps game use.
eval load_temporary_rng $7F0000
// ROM addresses
//x3fixme eval rom_play_music $80878B
eval rom_play_sound $01802B
//x3fixme eval rom_rtl_instruction $808798 // last instruction of rom_play_sound
//x3fixme eval rom_rts_instruction $8087D0 // last instruction of some part of rom_play_music
//x3fixme eval rom_nmi_after_pushes $808173
eval rom_nmi_after_controller $088621
eval ram_nmi_after_controller $7E2621 // RAM copy of rom_nmi_after_controller
//x3fixme eval rom_config_loop $80EAAA
//x3fixme eval rom_config_button $80EB55
//x3fixme eval rom_config_stereo $80EBE8
//x3fixme eval rom_config_bgm $80EC30
//x3fixme eval rom_config_se $80EC74
//x3fixme eval rom_config_exit $80ECC0
eval rom_default_config $06E0E4
eval rom_level_table $069C04
// SRAM addresses for saved states
eval sram_start $700000
eval sram_previous_command $700200
eval sram_wram_7E0000 $710000
eval sram_wram_7E8000 $720000
eval sram_wram_7F0000 $730000
eval sram_wram_7F8000 $740000
eval sram_vram_0000 $750000
eval sram_vram_8000 $760000
eval sram_cgram $772000
eval sram_oam $772200
eval sram_dma_bank $770000
eval sram_validity $774000
eval sram_saved_sp $774004
eval sram_saved_dp $774006
// SRAM addresses for general config. These are at lower addresses to support
// emulators and cartridges that don't support 256 KB of SRAM.
eval sram_config_valid $700100
eval sram_config_game $700104 // Main game config. game_config_size bytes.
eval sram_config_extra {sram_config_game} + {game_config_size}
eval sram_config_category {sram_config_extra} + 0
eval sram_config_route {sram_config_extra} + 1
eval sram_config_midpointsoff {sram_config_extra} + 2
eval sram_config_keeprng {sram_config_extra} + 3
eval sram_config_musicoff {sram_config_extra} + 4
eval sram_config_godmode {sram_config_extra} + 5
eval sram_config_extra_size 6 // adjust this as more are added
eval sram_banks $08
// Constants for categories and routing.
eval category_anyp 0
eval num_categories 1
eval route_anyp_default 0
eval num_routes_anyp 1
// State table index offsets for special data.
eval state_entry_size 64
eval index_offset_vile_flag (10 * 2) + 0
// Header edits
{savepc}
// Change SRAM size to 256 KB
{reorg $00FFD8}
db $08
{loadpc}
// Init hook
{savepc}
{reorg $00800E}
jml init_hook
{loadpc}
// Start of primary data bank (2B8000-2BE1FF)
{reorg $2B8000}
// Gameplay hacks.
incsrc "gameplay.asm"
// Stage select hacks.
incsrc "stageselect.asm"
// Config code.
incsrc "config.asm"
// Saved state code.
incsrc "savedstates.asm"
// The state table for each level is in statetable.asm.
incsrc "statetable.asm"
// End of primary data bank (2B8000-2BE1FF)
{warnpc $2BE200}
| Myriachan/RockmanX3Practice | hack.asm | Assembly | mit | 5,174 |
DebugStub_CallerEBP dd 0
DebugStub_CallerEIP dd 0
DebugStub_CallerESP dd 0
DebugStub_TraceMode dd 0
DebugStub_DebugStatus dd 0
DebugStub_PushAllPtr dd 0
DebugStub_DebugBreakOnNextTrace dd 0
DebugStub_BreakEBP dd 0
DebugStub_CommandID dd 0
DebugStub_BreakOnAddress:
Pushad
Call DebugStub_ComReadEAX
Mov ECX, EAX
Mov EAX, 0
Call DebugStub_ComReadAL
Push EAX
Mov EBX, DebugStub_DebugBPs
SHL EAX, 2
Add EBX, EAX
Cmp ECX, 0
JNE DebugStub_BreakOnAddress_Block1_End
Mov EDI, [EBX + 0]
Mov AL, 0x90
Mov [EDI + 0], AL
Jmp DebugStub_BreakOnAddress_DontSetBP
DebugStub_BreakOnAddress_Block1_End:
Mov [EBX + 0], ECX
Mov EDI, [EBX + 0]
Mov AL, 0xCC
Mov [EDI + 0], AL
DebugStub_BreakOnAddress_DontSetBP:
Pop EAX
Mov ECX, 256
DebugStub_BreakOnAddress_FindBPLoop:
Dec ECX
Mov EBX, DebugStub_DebugBPs
Mov EAX, ECX
SHL EAX, 2
Add EBX, EAX
Mov EAX, [EBX + 0]
Cmp EAX, 0
JE DebugStub_BreakOnAddress_Block2_End
Inc ECX
Mov [DebugStub_MaxBPId], ECX
Jmp DebugStub_BreakOnAddress_Continue
DebugStub_BreakOnAddress_Block2_End:
Cmp ECX, 0
JNE DebugStub_BreakOnAddress_Block3_End
Jmp DebugStub_BreakOnAddress_FindBPLoopExit
DebugStub_BreakOnAddress_Block3_End:
Jmp DebugStub_BreakOnAddress_FindBPLoop
DebugStub_BreakOnAddress_FindBPLoopExit:
Mov dword [DebugStub_MaxBPId], 0
DebugStub_BreakOnAddress_Continue:
DebugStub_BreakOnAddress_Exit:
Popad
Ret
DebugStub_SetINT3:
Pushad
Call DebugStub_ComReadEAX
Mov EDI, EAX
Mov AL, 0xCC
Mov [EDI + 0], AL
DebugStub_SetINT3_Exit:
Popad
Ret
DebugStub_ClearINT3:
Pushad
Call DebugStub_ComReadEAX
Mov EDI, EAX
Mov AL, 0x90
Mov [EDI + 0], AL
DebugStub_ClearINT3_Exit:
Popad
Ret
DebugStub_Executing:
MOV EAX, DR6
And EAX, 0x4000
Cmp EAX, 0x4000
JNE DebugStub_Executing_Block1_End
And EAX, 0xBFFF
MOV DR6, EAX
Call DebugStub_ResetINT1_TrapFLAG
Call DebugStub_Break
Jmp DebugStub_Executing_Normal
DebugStub_Executing_Block1_End:
Mov EAX, [DebugStub_CallerEIP]
Cmp EAX, [DebugStub_AsmBreakEIP]
JNE DebugStub_Executing_Block2_End
Call DebugStub_DoAsmBreak
Jmp DebugStub_Executing_Normal
DebugStub_Executing_Block2_End:
Mov EAX, [DebugStub_MaxBPId]
Cmp EAX, 0
JNE DebugStub_Executing_Block3_End
Jmp DebugStub_Executing_SkipBPScan
DebugStub_Executing_Block3_End:
Mov EAX, [DebugStub_CallerEIP]
Mov EDI, DebugStub_DebugBPs
Mov ECX, [DebugStub_MaxBPId]
repne scasd
JNE DebugStub_Executing_Block4_End
Call DebugStub_Break
Jmp DebugStub_Executing_Normal
DebugStub_Executing_Block4_End:
DebugStub_Executing_SkipBPScan:
Cmp dword [DebugStub_DebugBreakOnNextTrace], DebugStub_Const_StepTrigger_Into
JNE DebugStub_Executing_Block5_End
Call DebugStub_Break
Jmp DebugStub_Executing_Normal
DebugStub_Executing_Block5_End:
Mov EAX, [DebugStub_CallerEBP]
Cmp dword [DebugStub_DebugBreakOnNextTrace], DebugStub_Const_StepTrigger_Over
JNE DebugStub_Executing_Block6_End
Cmp EAX, [DebugStub_BreakEBP]
JB DebugStub_Executing_Block7_End
Call DebugStub_Break
DebugStub_Executing_Block7_End:
Jmp DebugStub_Executing_Normal
DebugStub_Executing_Block6_End:
Cmp dword [DebugStub_DebugBreakOnNextTrace], DebugStub_Const_StepTrigger_Out
JNE DebugStub_Executing_Block8_End
Cmp EAX, [DebugStub_BreakEBP]
JBE DebugStub_Executing_Block9_End
Call DebugStub_Break
DebugStub_Executing_Block9_End:
Jmp DebugStub_Executing_Normal
DebugStub_Executing_Block8_End:
DebugStub_Executing_Normal:
Cmp dword [DebugStub_TraceMode], DebugStub_Const_Tracing_On
JNE DebugStub_Executing_Block10_End
Call DebugStub_SendTrace
DebugStub_Executing_Block10_End:
DebugStub_Executing_CheckForCmd:
Mov DX, [DebugStub_ComAddr]
Add DX, 5
In AL, DX
Test AL, 1
JZ DebugStub_Executing_Block11_End
Call DebugStub_ProcessCommand
Jmp DebugStub_Executing_CheckForCmd
DebugStub_Executing_Block11_End:
DebugStub_Executing_Exit:
Ret
DebugStub_Break:
Mov dword [DebugStub_DebugBreakOnNextTrace], DebugStub_Const_StepTrigger_None
Mov dword [DebugStub_BreakEBP], 0
Mov dword [DebugStub_DebugStatus], DebugStub_Const_Status_Break
Call DebugStub_SendTrace
DebugStub_Break_WaitCmd:
Call DebugStub_ProcessCommand
Cmp AL, DebugStub_Const_Vs2Ds_Continue
JE DebugStub_Break_Done
Cmp AL, DebugStub_Const_Vs2Ds_AsmStepInto
JNE DebugStub_Break_Block1_End
Call DebugStub_SetINT1_TrapFLAG
Jmp DebugStub_Break_Done
DebugStub_Break_Block1_End:
Cmp AL, DebugStub_Const_Vs2Ds_SetAsmBreak
JNE DebugStub_Break_Block2_End
Call DebugStub_SetAsmBreak
Call DebugStub_AckCommand
Jmp DebugStub_Break_WaitCmd
DebugStub_Break_Block2_End:
Cmp AL, DebugStub_Const_Vs2Ds_StepInto
JNE DebugStub_Break_Block3_End
Mov dword [DebugStub_DebugBreakOnNextTrace], DebugStub_Const_StepTrigger_Into
Mov [DebugStub_BreakEBP], EAX
Jmp DebugStub_Break_Done
DebugStub_Break_Block3_End:
Cmp AL, DebugStub_Const_Vs2Ds_StepOver
JNE DebugStub_Break_Block4_End
Mov dword [DebugStub_DebugBreakOnNextTrace], DebugStub_Const_StepTrigger_Over
Mov EAX, [DebugStub_CallerEBP]
Mov [DebugStub_BreakEBP], EAX
Jmp DebugStub_Break_Done
DebugStub_Break_Block4_End:
Cmp AL, DebugStub_Const_Vs2Ds_StepOut
JNE DebugStub_Break_Block5_End
Mov dword [DebugStub_DebugBreakOnNextTrace], DebugStub_Const_StepTrigger_Out
Mov EAX, [DebugStub_CallerEBP]
Mov [DebugStub_BreakEBP], EAX
Jmp DebugStub_Break_Done
DebugStub_Break_Block5_End:
Jmp DebugStub_Break_WaitCmd
DebugStub_Break_Done:
Call DebugStub_AckCommand
Mov dword [DebugStub_DebugStatus], DebugStub_Const_Status_Run
DebugStub_Break_Exit:
Ret
| Coder-666/COSMOS | source2/Compiler/Cosmos.Compiler.DebugStub/DebugStub.asm | Assembly | bsd-3-clause | 5,562 |
ORG 100
BSA MUL
IN_X, DEC 74
IN_Y, DEC 41
OUT, DEC 0
HLT
MUL,HEX 0
CLA
CLE
BUN START
N, DEC -16
X, DEC 0
Y, DEC 0
RIS, DEC 0
START, LDA MUL I
STA X
ISZ MUL
LDA MUL I
STA Y
ISZ MUL
LOOP, LDA Y
CIR
STA Y
SZE
BUN SUM
BUN AFTSUM
SUM, LDA RIS
ADD X
STA RIS
AFTSUM, CLE
LDA X
CIL
CLE
STA X
LDA Y
SPA
BUN FINE
ISZ N
BUN LOOP
FINE, LDA RIS
STA MUL I
ISZ MUL
BUN MUL I
END | MircoT/js-pdp8 | lib/test/sources/bsa_args.asm | Assembly | mit | 371 |
;; Licensed to the .NET Foundation under one or more agreements.
;; The .NET Foundation licenses this file to you under the MIT license.
;; See the LICENSE file in the project root for more information.
#include "kxarm.h"
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; DATA SECTIONS ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; ConstrainedCall Support Helpers ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;;
;; Note: The "__jmpstub__" prefix is used to indicate to debugger
;; that it must step-through this stub when it encounters it while
;; stepping.
;;
;;
;; sp-4 - AddressOfAddressOfFunctionToCallAfterDereferencingThis
;;
LEAF_ENTRY __jmpstub__ConstrainedCallSupport_DerefThisAndCall_CommonCallingStub
ldr r12, [sp, #-4]
ldr r12, [r12]
ldr r0, [r0]
bx r12
LEAF_END __jmpstub__ConstrainedCallSupport_DerefThisAndCall_CommonCallingStub
;;
;; void ConstrainedCallSupport_GetStubs(IntPtr *__jmpstub__ConstrainedCallSupport_DerefThisAndCall_CommonCallingStub,
;; IntPtr *__jmpstub__ConstrainedCallSupport_DirectConstrainedCallCommonStub)
;;
LEAF_ENTRY ConstrainedCallSupport_GetStubs
ldr r12, =__jmpstub__ConstrainedCallSupport_DerefThisAndCall_CommonCallingStub
str r12, [r0]
ldr r12, =__jmpstub__ConstrainedCallSupport_DirectConstrainedCallCommonStub
str r12, [r1]
bx lr
LEAF_END ConstrainedCallSupport_GetStubs
;;
;; __jmpstub__ConstrainedCallSupport_DirectConstrainedCallCommonStub
;;
;; struct ConstrainedCallDesc
;; {
;; ULONG_PTR ExactTarget;
;; ULONG_PTR LookupFunc; // Put UniversalThunk here
;; }
;;
;; struct CommonCallingStubInputData
;; {
;; ULONG_PTR ConstrainedCallDesc;
;; ULONG_PTR DirectConstrainedCallResolver;
;; }
;;
;; sp-4 - Points at CommonCallingStubInputData
;;
;;
LEAF_ENTRY __jmpstub__ConstrainedCallSupport_DirectConstrainedCallCommonStub
ldr r12, [sp, #-4] ; put CommonCallingStubInputData into r12 (Temp for getting ExactTarget)
ldr r12, [r12] ; put ConstrainedCallDesc into r12 (Temp for getting ExactTarget)
ldr r12, [r12] ; put ExactTarget into r12
cmp r12, 0 ; Is ExactTarget null?
beq NeedHelperCall ; if null use a helper call
bx r12 ; Otherwise tail-call the ExactTarget
NeedHelperCall
;; Setup arguments for UniversalThunk and call it.
ldr r12, [sp, #-4] ; put CommonCallingStubInputData into r12 (Temp for getting ConstrainedCallDesc)
ldr r12, [r12] ; put ConstrainedCallDesc into r12
str r12, [sp, #-8] ; put ConstrainedCallDesc into sp-8 (red zone location of custom calling convention for universal thunk)
ldr r12, [sp, #-4] ; put CommonCallingStubInputData into r12 (Temp for getting DirectConstrainedCallResolver)
ldr r12, [r12, #4] ; put DirectConstrainedCallResolver into r12
str r12, [sp, #-4] ; put DirectConstrainedCallResolver into sp-4 (red zone location of custom calling convention for universal thunk)
ldr r12, [sp, #-8] ; put ConstrainedCallDesc into r12 (Temp for getting ExactTarget)
ldr r12, [r12, #4] ; put LookupFunc into r12 (This should be universal thunk pointer)
bx r12 ; Tail-Call Universal thunk
LEAF_END __jmpstub__ConstrainedCallSupport_DirectConstrainedCallCommonStub
END
| zenos-os/zenos | vendor/corert/src/Native/System.Private.TypeLoader.Native/arm/ConstrainedCallSupportHelpers.asm | Assembly | mit | 3,485 |
.686
include /masm32/include/io.asm
.data
lpstrMessage db "Hello, World", 13,10,0
lpstrMsgInput db "Type number> ",0
msgArr db "====Array===",0
num dd 5
arr dd 10 dup(?)
.code
start:
outstr offset lpstrMsgInput
inint32 eax
outstr offset lpstrMessage
sub eax, 5
outint32 eax, 3
newline
outint32 num
newline
outstr offset msgArr
newline
mov ebx, 0
mov eax, 2
.while ebx < 10
mov arr[ebx], eax
outint32 arr[ebx]
newline
inc ebx
mul ebx
.endw
exit
end start | KubSU/SIOMASM | Tests/MainTest.asm | Assembly | mit | 470 |
include "macro_blake2b_avx2.asm"
macro RecordRdtsc
{
rdtsc
mov rcx, [rbp+EH.debugptr]
mov [rcx], eax
mov [rcx+4], edx
add rcx, 8
mov [rbp+EH.debugptr], rcx
}
macro Record reg1
{
mov rcx, [rbp+EH.debugptr]
mov [rcx], reg1
add rcx, 8
mov [rbp+EH.debugptr], rcx
}
_ProcEhSolver:
push r15
push r14
push r13
push r12
push rdi
push rsi
push rbp
push rbx
mov rax, rsp
sub rsp, 0xd8
and rsp, -32
vmovdqa [rsp+0x20], xmm6
vmovdqa [rsp+0x30], xmm7
vmovdqa [rsp+0x40], xmm8
vmovdqa [rsp+0x50], xmm9
vmovdqa [rsp+0x60], xmm10
vmovdqa [rsp+0x70], xmm11
vmovdqa [rsp+0x80], xmm12
vmovdqa [rsp+0x90], xmm13
vmovdqa [rsp+0xa0], xmm14
vmovdqa [rsp+0xb0], xmm15
mov [rsp+0xc0], rax
mov rbp, rcx
vmovd xmm0, edx
vpbroadcastq ymm0, xmm0
vpblendd ymm0, ymm0, yword [yctrinit], 0xaa
vmovdqa yword [rbp+EH.mids+0xe0], ymm0
lea rcx, [rbp+EH.debug]
rdtsc
mov [rcx], eax
mov [rcx+4], edx
add rcx, 8
mov [rbp+EH.debugptr], rcx
lea rdi, [rbp+EH.bucket1ptr]
mov r12, rdi
mov ecx, 256
xor eax, eax
rep stosq
lea rsi, [rbp+EH.pairs+STATE0_DEST]
xor ecx, ecx
lea rbx, [rbp+EH.basemap]
_LoopBlake2b:
Blake2beq2of2 rbp+EH.mids, rbp+EH.mids+0xc0
vmovdqa ymm7, yword [rbp+EH.mids+0xe0]
vpaddd ymm7, ymm7, yword [yctrinc]
vmovdqa yword [rbp+EH.mids+0xe0], ymm7
vbroadcasti128 ymm7, xword [xshufb_bswap8]
vpshufb ymm0, ymm0, ymm7
vpshufb ymm1, ymm1, ymm7
vpshufb ymm2, ymm2, ymm7
vpshufb ymm3, ymm3, ymm7
vpshufb ymm4, ymm4, ymm7
vpshufb ymm5, ymm5, ymm7
vpshufb ymm6, ymm6, ymm7
vpsrlq ymm8, ymm0, 56
vpsllq ymm0, ymm0, 8
;vpsrlq ymm0, ymm0, 0
vpunpcklqdq ymm7, ymm2, ymm1
vpunpckhqdq ymm2, ymm2, ymm1
vpsrlq ymm1, ymm1, 56
vpor ymm9, ymm0, ymm1 ;xmm9=bucket data 2,0
vpshufd ymm1, ymm3, 0x4e
vpextrw r8d, xmm8, 0
movzx eax, word [r12+r8*2]
cmp eax, 10240
jae _SkipA0
imul edx, eax, 24
imul r10d, eax, 1024
add eax, 1
mov word [r12+r8*2], ax
lea r11, [rbx+r8*4]
mov [r10+r11], ecx
imul r8d, r8d, PARTS*ITEMS*STATE0_BYTES
lea rdi, [rsi+r8]
add rdi, rdx
vpalignr ymm10, ymm7, ymm1, 15 ;xmm10=xor data 0
vmovq rax, xmm10
movnti [rdi], rax
vpextrq rax, xmm10, 1
movnti [rdi+8], rax
vmovq rax, xmm9
movnti [rdi+16], rax
_SkipA0:
vpextrw r8d, xmm8, 4
movzx eax, word [r12+r8*2]
add ecx, 2
cmp eax, 10240
jae _SkipA2
imul edx, eax, 24
imul r10d, eax, 1024
add eax, 1
mov word [r12+r8*2], ax
lea r11, [rbx+r8*4]
mov [r10+r11], ecx
imul r8d, r8d, PARTS*ITEMS*STATE0_BYTES
lea rdi, [rsi+r8]
add rdi, rdx
vpalignr ymm11, ymm2, ymm3, 15 ;xmm11=xor data 2
vmovq rax, xmm11
movnti [rdi], rax
vpextrq rax, xmm11, 1
movnti [rdi+8], rax
vpextrq rax, xmm9, 1
movnti [rdi+16], rax
_SkipA2:
vextracti128 xmm8, ymm8, 1
vextracti128 xmm9, ymm9, 1
vextracti128 xmm10, ymm10, 1
vextracti128 xmm11, ymm11, 1
vpextrw r8d, xmm8, 0
movzx eax, word [r12+r8*2]
add ecx, 2
cmp eax, 10240
jae _SkipA4
imul edx, eax, 24
imul r10d, eax, 1024
add eax, 1
mov word [r12+r8*2], ax
lea r11, [rbx+r8*4]
mov [r10+r11], ecx
imul r8d, r8d, PARTS*ITEMS*STATE0_BYTES
lea rdi, [rsi+r8]
add rdi, rdx
vmovq rax, xmm10
movnti [rdi], rax
vpextrq rax, xmm10, 1
movnti [rdi+8], rax
vmovq rax, xmm9
movnti [rdi+16], rax
_SkipA4:
vpextrw r8d, xmm8, 4
movzx eax, word [r12+r8*2]
add ecx, 2
cmp eax, 10240
jae _SkipA6
imul edx, eax, 24
imul r10d, eax, 1024
add eax, 1
mov word [r12+r8*2], ax
lea r11, [rbx+r8*4]
mov [r10+r11], ecx
imul r8d, r8d, PARTS*ITEMS*STATE0_BYTES
lea rdi, [rsi+r8]
add rdi, rdx
vmovq rax, xmm11
movnti [rdi], rax
vpextrq rax, xmm11, 1
movnti [rdi+8], rax
vpextrq rax, xmm9, 1
movnti [rdi+16], rax
_SkipA6:
vpsllq ymm8, ymm3, 8
vpsrlq ymm8, ymm8, 56
vpunpcklqdq ymm2, ymm4, ymm3
vpunpckhqdq ymm3, ymm4, ymm3
vpunpcklqdq ymm4, ymm6, ymm5
vpunpckhqdq ymm5, ymm6, ymm5
vpsrldq ymm0, ymm2, 6
vpsrldq ymm1, ymm3, 6
;vbroadcasti128 ymm7, xword [xqmask64bit]
;vpand ymm0, ymm0, ymm7 ;bucket data 1
;vpand ymm1, ymm1, ymm7 ;bucket data 3
vpextrw r8d, xmm8, 0
movzx eax, word [r12+r8*2]
sub ecx, 5
cmp eax, 10240
jae _SkipA1
imul edx, eax, 24
imul r10d, eax, 1024
add eax, 1
mov word [r12+r8*2], ax
lea r11, [rbx+r8*4]
mov [r10+r11], ecx
imul r8d, r8d, PARTS*ITEMS*STATE0_BYTES
lea rdi, [rsi+r8]
add rdi, rdx
vpalignr ymm2, ymm2, ymm4, 6 ;xor data 1
vmovq rax, xmm2
movnti [rdi], rax
vpextrq rax, xmm2, 1
movnti [rdi+8], rax
vmovq rax, xmm0
movnti [rdi+16], rax
_SkipA1:
vpextrw r8d, xmm8, 4
movzx eax, word [r12+r8*2]
add ecx, 2
cmp eax, 10240
jae _SkipA3
imul edx, eax, 24
imul r10d, eax, 1024
add eax, 1
mov word [r12+r8*2], ax
lea r11, [rbx+r8*4]
mov [r10+r11], ecx
imul r8d, r8d, PARTS*ITEMS*STATE0_BYTES
lea rdi, [rsi+r8]
add rdi, rdx
vpalignr ymm3, ymm3, ymm5, 6 ;xor data 3
vmovq rax, xmm3
movnti [rdi], rax
vpextrq rax, xmm3, 1
movnti [rdi+8], rax
vmovq rax, xmm1
movnti [rdi+16], rax
_SkipA3:
vextracti128 xmm8, ymm8, 1
vextracti128 xmm0, ymm0, 1
vextracti128 xmm1, ymm1, 1
vextracti128 xmm2, ymm2, 1
vextracti128 xmm3, ymm3, 1
vpextrw r8d, xmm8, 0
movzx eax, word [r12+r8*2]
add ecx, 2
cmp eax, 10240
jae _SkipA5
imul edx, eax, 24
imul r10d, eax, 1024
add eax, 1
mov word [r12+r8*2], ax
lea r11, [rbx+r8*4]
mov [r10+r11], ecx
imul r8d, r8d, PARTS*ITEMS*STATE0_BYTES
lea rdi, [rsi+r8]
add rdi, rdx
vmovq rax, xmm2
movnti [rdi], rax
vpextrq rax, xmm2, 1
movnti [rdi+8], rax
vmovq rax, xmm0
movnti [rdi+16], rax
_SkipA5:
vpextrw r8d, xmm8, 4
movzx eax, word [r12+r8*2]
add ecx, 2
cmp eax, 10240
jae _SkipA7
imul edx, eax, 24
imul r10d, eax, 1024
add eax, 1
mov word [r12+r8*2], ax
lea r11, [rbx+r8*4]
mov [r10+r11], ecx
imul r8d, r8d, PARTS*ITEMS*STATE0_BYTES
lea rdi, [rsi+r8]
add rdi, rdx
vmovq rax, xmm3
movnti [rdi], rax
vpextrq rax, xmm3, 1
movnti [rdi+8], rax
vmovq rax, xmm1
movnti [rdi+16], rax
_SkipA7:
add ecx, 1
test ecx, 0x0007ffff
jnz _LoopBlake2b
add r12, BUCKETS*2
add rsi, ITEMS*STATE0_BYTES
add rbx, ITEMS*BUCKETS*4
cmp ecx, 2097152
jb _LoopBlake2b
RecordRdtsc
;Stage1
mov dword [rsp], 0
lea rdi, [rbp+EH.bucket0ptr]
mov r13, rdi
mov ecx, BUCKETS
xor eax, eax
rep stosq
xor r12d, r12d ;bucket multiplied by 2
lea r14, [rbp+EH.pairs+STATE1_DEST-STATE1_BYTES]
lea r15, [rbp+EH.pairs-BUCKETS*4]
_EhStage1:
lea rdi, [rbp+EH.hashtab]
mov ecx, HASHTAB_ENTRIES/2
xor eax, eax
rep stosq
xor r11d, r11d
xor esi, esi
_EhStage1inner:
mov r8d, r11d
shl r8d, 9 ;log2 (BUCKET*2)
or r8d, r12d
movzx r8d, word [rbp+r8+EH.bucket1ptr]
mov r10d, STATE0_BYTES
imul edx, r11d, ITEMS*0x10000
lea eax, [r11+r12*2] ;PARTS/2
imul r9d, eax, ITEMS*STATE0_BYTES
lea r9, [rbp+r9+EH.pairs+STATE0_DEST+STATE0_OFFSET]
call _ProcEhMakeLinksShr4
add r11d, 1
cmp r11d, PARTS
jb _EhStage1inner
add [rsp], esi
imul r10d, r12d, PARTS*ITEMS*STATE0_BYTES/2
lea r10, [rbp+r10+EH.pairs+STATE0_DEST]
lea r8, [rbp+EH.workingpairs]
EhXor1_3 1
add r12d, 2
test r12d, 0x7e
jnz _EhStage1
add r13, BUCKETS*2
add r14, ITEMS*STATE1_BYTES
add r15, ITEMS*BUCKETS*4
cmp r12d, BUCKETS*2
jb _EhStage1
RecordRdtsc
mov eax, [rsp]
Record rax
;Stage2
mov dword [rsp], 0
lea rdi, [rbp+EH.bucket1ptr]
mov r13, rdi
mov ecx, BUCKETS
xor eax, eax
rep stosq
xor r12d, r12d ;bucket multiplied by 2
lea r14, [rbp+EH.pairs+STATE2_DEST-STATE2_BYTES]
lea r15, [rbp+EH.pairs+1*BLOCKUNIT-BUCKETS*4]
_EhStage2:
lea rdi, [rbp+EH.hashtab]
mov ecx, HASHTAB_ENTRIES/2
xor eax, eax
rep stosq
xor r11d, r11d
xor esi, esi
_EhStage2inner:
mov r8d, r11d
shl r8d, 9 ;log2 (BUCKET*2)
or r8d, r12d
movzx r8d, word [rbp+r8+EH.bucket0ptr]
mov r10d, STATE1_BYTES
imul edx, r11d, ITEMS*0x10000
lea eax, [r11+r12*2] ;PARTS/2
imul r9d, eax, ITEMS*STATE1_BYTES
lea r9, [rbp+r9+EH.pairs+STATE1_DEST+STATE1_OFFSET]
call _ProcEhMakeLinks
add r11d, 1
cmp r11d, PARTS
jb _EhStage2inner
add [rsp], esi
imul r10d, r12d, PARTS*ITEMS*STATE1_BYTES/2
lea r10, [rbp+r10+EH.pairs+STATE1_DEST]
lea r8, [rbp+EH.workingpairs]
EhXor1_3 2
add r12d, 2
test r12d, 0x7e
jnz _EhStage2
add r13, BUCKETS*2
add r14, ITEMS*STATE2_BYTES
add r15, ITEMS*BUCKETS*4
cmp r12d, BUCKETS*2
jb _EhStage2
RecordRdtsc
mov eax, [rsp]
Record rax
;Stage3
mov dword [rsp], 0
lea rdi, [rbp+EH.bucket0ptr]
mov r13, rdi
mov ecx, BUCKETS
xor eax, eax
rep stosq
xor r12d, r12d ;bucket multiplied by 2
lea r14, [rbp+EH.pairs+STATE3_DEST-STATE3_BYTES]
lea r15, [rbp+EH.pairs+2*BLOCKUNIT-BUCKETS*4]
_EhStage3:
lea rdi, [rbp+EH.hashtab]
mov ecx, HASHTAB_ENTRIES/2
xor eax, eax
rep stosq
xor r11d, r11d
xor esi, esi
_EhStage3inner:
mov r8d, r11d
shl r8d, 9 ;log2 (BUCKET*2)
or r8d, r12d
movzx r8d, word [rbp+r8+EH.bucket1ptr]
mov r10d, STATE2_BYTES
imul edx, r11d, ITEMS*0x10000
lea eax, [r11+r12*2] ;PARTS/2
imul r9d, eax, ITEMS*STATE2_BYTES
lea r9, [rbp+r9+EH.pairs+STATE2_DEST+STATE2_OFFSET]
call _ProcEhMakeLinksShr4
add r11d, 1
cmp r11d, PARTS
jb _EhStage3inner
add [rsp], esi
imul r10d, r12d, PARTS*ITEMS*STATE2_BYTES/2
lea r10, [rbp+r10+EH.pairs+STATE2_DEST]
lea r8, [rbp+EH.workingpairs]
EhXor1_3 3
add r12d, 2
test r12d, 0x7e
jnz _EhStage3
add r13, BUCKETS*2
add r14, ITEMS*STATE3_BYTES
add r15, ITEMS*BUCKETS*4
cmp r12d, BUCKETS*2
jb _EhStage3
RecordRdtsc
mov eax, [rsp]
Record rax
;Stage4
mov dword [rsp], 0
lea rdi, [rbp+EH.bucket1ptr]
mov r13, rdi
mov ecx, BUCKETS
xor eax, eax
rep stosq
xor r12d, r12d ;bucket multiplied by 2
lea r14, [rbp+EH.pairs+STATE4_DEST-STATE4_BYTES]
lea r15, [rbp+EH.pairs+3*BLOCKUNIT-BUCKETS*4]
_EhStage4:
lea rdi, [rbp+EH.hashtab]
mov ecx, HASHTAB_ENTRIES/2
xor eax, eax
rep stosq
xor r11d, r11d
xor esi, esi
_EhStage4inner:
mov r8d, r11d
shl r8d, 9 ;log2 (BUCKET*2)
or r8d, r12d
movzx r8d, word [rbp+r8+EH.bucket0ptr]
mov r10d, STATE3_BYTES
imul edx, r11d, ITEMS*0x10000
lea eax, [r11+r12*2] ;PARTS/2
imul r9d, eax, ITEMS*STATE3_BYTES
lea r9, [rbp+r9+EH.pairs+STATE3_DEST+STATE3_OFFSET]
call _ProcEhMakeLinks
add r11d, 1
cmp r11d, PARTS
jb _EhStage4inner
add [rsp], esi
imul r10d, r12d, PARTS*ITEMS*STATE3_BYTES/2
lea r10, [rbp+r10+EH.pairs+STATE3_DEST]
lea r8, [rbp+EH.workingpairs]
EhXor4
add r12d, 2
test r12d, 0x7e
jnz _EhStage4
add r13, BUCKETS*2
add r14, ITEMS*STATE4_BYTES
add r15, ITEMS*BUCKETS*4
cmp r12d, BUCKETS*2
jb _EhStage4
RecordRdtsc
mov eax, [rsp]
Record rax
;Stage5
mov dword [rsp], 0
lea rdi, [rbp+EH.bucket0ptr]
mov r13, rdi
mov ecx, BUCKETS
xor eax, eax
rep stosq
xor r12d, r12d ;bucket multiplied by 2
lea r14, [rbp+EH.pairs+STATE5_DEST-STATE5_BYTES]
lea r15, [rbp+EH.pairs+4*BLOCKUNIT-BUCKETS*4]
_EhStage5:
lea rdi, [rbp+EH.hashtab]
mov ecx, HASHTAB_ENTRIES/2
xor eax, eax
rep stosq
xor r11d, r11d
xor esi, esi
_EhStage5inner:
mov r8d, r11d
shl r8d, 9 ;log2 (BUCKET*2)
or r8d, r12d
movzx r8d, word [rbp+r8+EH.bucket1ptr]
mov r10d, STATE4_BYTES
imul edx, r11d, ITEMS*0x10000
lea eax, [r11+r12*2] ;PARTS/2
imul r9d, eax, ITEMS*STATE4_BYTES
lea r9, [rbp+r9+EH.pairs+STATE4_DEST+STATE4_OFFSET]
call _ProcEhMakeLinksShr4
add r11d, 1
cmp r11d, PARTS
jb _EhStage5inner
add [rsp], esi
imul r10d, r12d, PARTS*ITEMS*STATE4_BYTES/2
lea r10, [rbp+r10+EH.pairs+STATE4_DEST]
lea r8, [rbp+EH.workingpairs]
EhXor5
add r12d, 2
test r12d, 0x7e
jnz _EhStage5
add r13, BUCKETS*2
add r14, ITEMS*STATE5_BYTES
add r15, ITEMS*BUCKETS*4
cmp r12d, BUCKETS*2
jb _EhStage5
RecordRdtsc
mov eax, [rsp]
Record rax
;Stage6
mov dword [rsp], 0
lea rdi, [rbp+EH.bucket1ptr]
mov r13, rdi
mov ecx, BUCKETS
xor eax, eax
rep stosq
xor r12d, r12d ;bucket multiplied by 2
lea r14, [rbp+EH.pairs+STATE6_DEST-STATE6_BYTES]
lea r15, [rbp+EH.pairs+5*BLOCKUNIT-BUCKETS*4]
_EhStage6:
lea rdi, [rbp+EH.hashtab]
mov ecx, HASHTAB_ENTRIES/2
xor eax, eax
rep stosq
xor r11d, r11d
xor esi, esi
_EhStage6inner:
mov r8d, r11d
shl r8d, 9 ;log2 (BUCKET*2)
or r8d, r12d
movzx r8d, word [rbp+r8+EH.bucket0ptr]
mov r10d, STATE5_BYTES
imul edx, r11d, ITEMS*0x10000
lea eax, [r11+r12*2] ;PARTS/2
imul r9d, eax, ITEMS*STATE5_BYTES
lea r9, [rbp+r9+EH.pairs+STATE5_DEST+STATE5_OFFSET]
call _ProcEhMakeLinks
add r11d, 1
cmp r11d, PARTS
jb _EhStage6inner
add [rsp], esi
imul r10d, r12d, PARTS*ITEMS*STATE5_BYTES/2
lea r10, [rbp+r10+EH.pairs+STATE5_DEST]
lea r8, [rbp+EH.workingpairs]
EhXor6_7 6
add r12d, 2
test r12d, 0x7e
jnz _EhStage6
add r13, BUCKETS*2
add r14, ITEMS*STATE6_BYTES
add r15, ITEMS*BUCKETS*4
cmp r12d, BUCKETS*2
jb _EhStage6
RecordRdtsc
mov eax, [rsp]
Record rax
;Stage7
mov dword [rsp], 0
lea rdi, [rbp+EH.bucket0ptr]
mov r13, rdi
mov ecx, BUCKETS
xor eax, eax
rep stosq
xor r12d, r12d ;bucket multiplied by 2
lea r14, [rbp+EH.pairs+STATE7_DEST-STATE7_BYTES]
lea r15, [rbp+EH.pairs+6*BLOCKUNIT-BUCKETS*4]
_EhStage7:
lea rdi, [rbp+EH.hashtab]
mov ecx, HASHTAB_ENTRIES/2
xor eax, eax
rep stosq
xor r11d, r11d
xor esi, esi
_EhStage7inner:
mov r8d, r11d
shl r8d, 9 ;log2 (BUCKET*2)
or r8d, r12d
movzx r8d, word [rbp+r8+EH.bucket1ptr]
mov r10d, STATE6_BYTES
imul edx, r11d, ITEMS*0x10000
lea eax, [r11+r12*2] ;PARTS/2
imul r9d, eax, ITEMS*STATE6_BYTES
lea r9, [rbp+r9+EH.pairs+STATE6_DEST+STATE6_OFFSET]
call _ProcEhMakeLinksShr4
add r11d, 1
cmp r11d, PARTS
jb _EhStage7inner
add [rsp], esi
imul r10d, r12d, PARTS*ITEMS*STATE6_BYTES/2
lea r10, [rbp+r10+EH.pairs+STATE6_DEST]
lea r8, [rbp+EH.workingpairs]
EhXor6_7 7
add r12d, 2
test r12d, 0x7e
jnz _EhStage7
add r13, BUCKETS*2
add r14, ITEMS*STATE7_BYTES
add r15, ITEMS*BUCKETS*4
cmp r12d, BUCKETS*2
jb _EhStage7
RecordRdtsc
mov eax, [rsp]
Record rax
;Stage8
mov dword [rsp], 0
lea rdi, [rbp+EH.bucket1ptr]
mov r13, rdi
mov ecx, BUCKETS
xor eax, eax
rep stosq
xor r12d, r12d ;bucket multiplied by 2
lea r14, [rbp+EH.pairs+STATE8_DEST-STATE8_BYTES]
lea r15, [rbp+EH.pairs+7*BLOCKUNIT-BUCKETS*4]
_EhStage8:
lea rdi, [rbp+EH.hashtab]
mov ecx, HASHTAB_ENTRIES/2
xor eax, eax
rep stosq
xor r11d, r11d
xor esi, esi
_EhStage8inner:
mov r8d, r11d
shl r8d, 9 ;log2 (BUCKET*2)
or r8d, r12d
movzx r8d, word [rbp+r8+EH.bucket0ptr]
mov r10d, STATE7_BYTES
imul edx, r11d, ITEMS*0x10000
lea eax, [r11+r12*2] ;PARTS/2
imul r9d, eax, ITEMS*STATE7_BYTES
lea r9, [rbp+r9+EH.pairs+STATE7_DEST+STATE7_OFFSET]
call _ProcEhMakeLinks
add r11d, 1
cmp r11d, PARTS
jb _EhStage8inner
add [rsp], esi
imul r10d, r12d, PARTS*ITEMS*STATE7_BYTES/2
lea r10, [rbp+r10+EH.pairs+STATE7_DEST]
lea r8, [rbp+EH.workingpairs]
EhXor8
add r12d, 2
test r12d, 0x7e
jnz _EhStage8
add r13, BUCKETS*2
add r14, ITEMS*STATE8_BYTES
add r15, ITEMS*BUCKETS*4
cmp r12d, BUCKETS*2
jb _EhStage8
RecordRdtsc
mov eax, [rsp]
Record rax
;Stage9
mov dword [rsp], 0
xor r12d, r12d ;bucket multiplied by 1
lea r15, [rbp+EH.pairs+8*BLOCKUNIT]
_EhStage9:
lea rdi, [rbp+EH.hashtab]
mov ecx, HASHTAB_ENTRIES/2
xor eax, eax
rep stosq
xor r11d, r11d
xor esi, esi
_EhStage9inner:
mov r8d, r11d
shl r8d, 8 ;log2 (BUCKET)
or r8d, r12d
movzx r8d, word [rbp+r8*2+EH.bucket1ptr]
mov r10d, STATE8_BYTES
imul edx, r11d, ITEMS*0x10000
lea eax, [r11+r12*4] ;PARTS
imul r9d, eax, ITEMS*STATE8_BYTES
lea r9, [rbp+r9+EH.pairs+STATE8_DEST+STATE8_OFFSET]
call _ProcEhMakeLinksShr4
add r11d, 1
cmp r11d, PARTS
jb _EhStage9inner
add [rsp], esi
imul r10d, r12d, PARTS*ITEMS*STATE8_BYTES
lea r10, [rbp+r10+EH.pairs+STATE8_DEST]
lea r8, [rbp+EH.workingpairs]
EhXor9
add r12d, 1
cmp r12d, BUCKETS
jb _EhStage9
mov eax, r15d
lea ecx, [rbp+EH.pairs+8*BLOCKUNIT]
sub eax, ecx
shr eax, 3
mov dword [rbp+EH.bucket0ptr], eax
RecordRdtsc
mov eax, [rsp]
Record rax
;mov ecx, fmtdn
;mov edx, dword [rbp+EH.bucket0ptr]
;call [printf]
;jmp _EhNoSolution
EhGetSolutions
mov ebx, eax
RecordRdtsc
mov eax, ebx
_EhSolverEpilog:
vmovdqa xmm6, [rsp+0x20]
vmovdqa xmm7, [rsp+0x30]
vmovdqa xmm8, [rsp+0x40]
vmovdqa xmm9, [rsp+0x50]
vmovdqa xmm10, [rsp+0x60]
vmovdqa xmm11, [rsp+0x70]
vmovdqa xmm12, [rsp+0x80]
vmovdqa xmm13, [rsp+0x90]
vmovdqa xmm14, [rsp+0xa0]
vmovdqa xmm15, [rsp+0xb0]
mov rsp, [rsp+0xc0]
pop rbx
pop rbp
pop rsi
pop rdi
pop r12
pop r13
pop r14
pop r15
ret
_EhNoSolution:
xor eax, eax
jmp _EhSolverEpilog
_ProcEhMakeLinksShr4:
;r9: src bucket+offset
;r8d: src count
;r10d: stride
;esi: pairs count
;edx: input item id <<16
;Output:
;[workingpairs]
;esi: pairs count
;Destroy: rax, rcx, rdx, rbx, rsi, rdi, r8, r9
xor ebx, ebx
_LoopMakeLinksShr4:
movzx ecx, word [r9]
add r9, r10
shr ecx, 2
and ecx, HASHTAB_PATTERN_MASK shl 2
mov eax, [rbp+rcx+EH.hashtab]
cmp eax, HASHTAB_COUNT_2
jae _EhMultipairsShr4
mov edi, eax
and eax, HASHTAB_LOCATION_MASK
or eax, edx
mov [rbp+rsi*4+EH.workingpairs], eax
mov eax, edx
shr eax, 16
and edi, HASHTAB_COUNT_1
setnz bl
cmovnz eax, esi
add esi, ebx
add edi, HASHTAB_COUNT_1
or eax, edi
mov dword [rbp+rcx+EH.hashtab], eax
add edx, 0x10000
sub r8d, 1
ja _LoopMakeLinksShr4
ret
_EhMultipairsShr4:
mov edi, eax
add eax, HASHTAB_COUNT_1
and eax, HASHTAB_COUNT_MASK
jz _EhHashtabExShr4
_EhHashtabExShr4Back:
or eax, esi
mov dword [rbp+rcx+EH.hashtab], eax
mov ecx, edi
sub edi, HASHTAB_COUNT_2
and ecx, HASHTAB_LOCATION_MASK
lea rcx, [rbp+rcx*4+EH.workingpairs]
_LoopMultipairsShr4:
movzx eax, word [rcx]
add rcx, 4
or eax, edx
mov [rbp+rsi*4+EH.workingpairs], eax
add esi, 1
sub edi, HASHTAB_COUNT_1
jns _LoopMultipairsShr4
movzx eax, word [rcx-2]
or eax, edx
mov [rbp+rsi*4+EH.workingpairs], eax
add esi, 1
cmp esi, WORKINGPAIRS_LIMIT
jae _EhTruncateShr4
add edx, 0x10000
sub r8d, 1
ja _LoopMakeLinksShr4
ret
_EhHashtabExShr4:
mov eax, HASHTAB_COUNT_MASK
jmp _EhHashtabExShr4Back
_EhTruncateShr4:
mov esi, WORKINGPAIRS_LIMIT
ret
_ProcEhMakeLinks:
;r9: src bucket+offset
;r8d: src count
;r10d: stride
;esi: pairs count
;edx: input item id <<16
;Output:
;[workingpairs]
;esi: pairs count
;Destroy: rax, rcx, rdx, rbx, rsi, rdi, r8, r9
xor ebx, ebx
_LoopMakeLinks:
movzx ecx, word [r9]
add r9, r10
and ecx, HASHTAB_PATTERN_MASK
mov eax, dword [rbp+rcx*4+EH.hashtab]
cmp eax, HASHTAB_COUNT_2
jae _EhMultipairs
mov edi, eax
and eax, HASHTAB_LOCATION_MASK
or eax, edx
mov [rbp+rsi*4+EH.workingpairs], eax
mov eax, edx
shr eax, 16
and edi, HASHTAB_COUNT_1
setnz bl
cmovnz eax, esi
add esi, ebx
add edi, HASHTAB_COUNT_1
or eax, edi
mov dword [rbp+rcx*4+EH.hashtab], eax
add edx, 0x10000
sub r8d, 1
ja _LoopMakeLinks
ret
_EhMultipairs:
mov edi, eax
add eax, HASHTAB_COUNT_1
and eax, HASHTAB_COUNT_MASK
jz _EhHashtabEx
_EhHashtabExBack:
or eax, esi
mov dword [rbp+rcx*4+EH.hashtab], eax
mov ecx, edi
sub edi, HASHTAB_COUNT_2
and ecx, HASHTAB_LOCATION_MASK
lea rcx, [rbp+rcx*4+EH.workingpairs]
_LoopMultipairs:
movzx eax, word [rcx]
add rcx, 4
or eax, edx
mov [rbp+rsi*4+EH.workingpairs], eax
add esi, 1
sub edi, HASHTAB_COUNT_1
jns _LoopMultipairs
movzx eax, word [rcx-2]
or eax, edx
mov [rbp+rsi*4+EH.workingpairs], eax
add esi, 1
cmp esi, WORKINGPAIRS_LIMIT
jae _EhTruncate
add edx, 0x10000
sub r8d, 1
ja _LoopMakeLinks
ret
_EhHashtabEx:
mov eax, HASHTAB_COUNT_MASK
jmp _EhHashtabExBack
_EhTruncate:
mov esi, WORKINGPAIRS_LIMIT
ret
| xenoncat/equihash-xenon | Windows/proc_ehsolver_avx2.asm | Assembly | mit | 19,247 |
;==============================================================
; WLA-DX banking setup
;==============================================================
.memorymap
defaultslot 0
slotsize $8000
slot 0 $0000
.endme
.rombankmap
bankstotal 1
banksize $8000
banks 1
.endro
;==============================================================
; SDSC tag and SMS rom header
;==============================================================
.sdsctag 1.10,"Hello World!","SMS programming tutorial program (bugfixed)","Maxim"
.bank 0 slot 0
.org $0000
;==============================================================
; Boot section
;==============================================================
di ; disable interrupts
im 1 ; Interrupt mode 1
jp main ; jump to main program
.org $0066
;==============================================================
; Pause button handler
;==============================================================
; Do nothing
retn
;==============================================================
; Main program
;==============================================================
main:
ld sp, $dff0
;==============================================================
; Set up VDP registers
;==============================================================
ld hl,VdpData
ld b,VdpDataEnd-VdpData
ld c,$bf
otir
;==============================================================
; Clear VRAM
;==============================================================
; 1. Set VRAM write address to 0 by outputting $4000 ORed with $0000
ld a,$00
out ($bf),a
ld a,$40
out ($bf),a
; 2. Output 16KB of zeroes
ld bc, $4000 ; Counter for 16KB of VRAM
ld a,$00 ; Value to write
ClearVRAMLoop:
out ($be),a ; Output to VRAM address, which is auto-incremented after each write
dec c
jp nz,ClearVRAMLoop
dec b
jp nz,ClearVRAMLoop
;==============================================================
; Load palette
;==============================================================
; 1. Set VRAM write address to CRAM (palette) address 0 (for palette index 0)
; by outputting $c000 ORed with $0000
ld a,$00
out ($bf),a
ld a,$c0
out ($bf),a
; 2. Output colour data
ld hl,PaletteData
ld b,(PaletteDataEnd-PaletteData)
ld c,$be
otir
;==============================================================
; Load tiles (font)
;==============================================================
; 1. Set VRAM write address to tile index 0
; by outputting $4000 ORed with $0000
ld a,$00
out ($bf),a
ld a,$40
out ($bf),a
; 2. Output tile data
ld hl,FontData ; Location of tile data
ld bc,FontDataEnd-FontData ; Counter for number of bytes to write
WriteTilesLoop:
; Output data byte then three zeroes, because our tile data is 1 bit
; and must be increased to 4 bit
ld a,(hl) ; Get data byte
out ($be),a
ld a,$00
out ($be),a
out ($be),a
out ($be),a
inc hl ; Add one to hl so it points to the next data byte
dec c
jp nz,WriteTilesLoop
dec b
jp nz,WriteTilesLoop
;==============================================================
; Write text to name table
;==============================================================
; 1. Set VRAM write address to name table index 0
; by outputting $4000 ORed with $3800+0
ld a,$00
out ($bf),a
ld a,$38|$40
out ($bf),a
; 2. Loop through text data, converting from ASCII ans writing tile indices
; to name table. Stop when a zero byte is found.
ld hl,Message
WriteTextLoop:
ld a,(hl) ; Get data byte
cp $00 ; Is it zero?
jp z,EndWriteTextLoop ; If so, exit loop
sub $20 ; In ASCII, space=$20 and the rest follow on. We want space=$00 so we subtract $20.
out ($be),a
ld a,$00
out ($be),a
inc hl ; Point to next letter
jp WriteTextLoop
EndWriteTextLoop:
; Turn screen on
ld a,%11000100
; |||| |`- Zoomed sprites -> 16x16 pixels
; |||| `-- Doubled sprites -> 2 tiles per sprite, 8x16
; |||`---- 30 row/240 line mode
; ||`----- 28 row/224 line mode
; |`------ VBlank interrupts
; `------- Enable display
out ($bf),a
ld a,$81
out ($bf),a
; Infinite loop to stop program
Loop:
jp Loop
;==============================================================
; Data
;==============================================================
Message:
.db "Hello world!",0
PaletteData:
.db $00,$3f ; Black, White
PaletteDataEnd:
; VDP initialisation data
VdpData:
.db $04,$80,$84,$81,$ff,$82,$ff,$85,$ff,$86,$ff,$87,$00,$88,$00,$89,$ff,$8a
VdpDataEnd:
FontData:
; This font data was provided by Mike G and is reproduced here in its entirety:
;------------------------------------------
; In loving memory of Acorn Computers Ltd.
; Mike G proudly presents the:
;
; BBC Micro Character Set!
; ========================
;
; This source was created automatically
; from character data stored in the BBC
; Microcomputer operating system ROM.
;
; The BBC set is a nice, clear font which
; (unlike the classic Namco/Sega font)
; includes lower-case letters as well as
; upper-case.
;
; Being a British micro, there's even a
; Pound Sterling currency symbol, which
; should come in handy when I begin to
; write financial apps on the SMS. (Just
; kidding!)
;
; Hopefully by using binary representation
; it will be obvious how the character
; data is stored.
;
;------------------------------------------
; Character 0x20 (space)
.DB %00000000 ; Hex 00h
.DB %00000000 ; Hex 00h
.DB %00000000 ; Hex 00h
.DB %00000000 ; Hex 00h
.DB %00000000 ; Hex 00h
.DB %00000000 ; Hex 00h
.DB %00000000 ; Hex 00h
.DB %00000000 ; Hex 00h
; Character 0x21 !
.DB %00011000 ; Hex 18h
.DB %00011000 ; Hex 18h
.DB %00011000 ; Hex 18h
.DB %00011000 ; Hex 18h
.DB %00011000 ; Hex 18h
.DB %00000000 ; Hex 00h
.DB %00011000 ; Hex 18h
.DB %00000000 ; Hex 00h
; Character 0x22 "
.DB %01101100 ; Hex 6Ch
.DB %01101100 ; Hex 6Ch
.DB %01101100 ; Hex 6Ch
.DB %00000000 ; Hex 00h
.DB %00000000 ; Hex 00h
.DB %00000000 ; Hex 00h
.DB %00000000 ; Hex 00h
.DB %00000000 ; Hex 00h
; Character 0x23 #
.DB %00110110 ; Hex 36h
.DB %00110110 ; Hex 36h
.DB %01111111 ; Hex 7Fh
.DB %00110110 ; Hex 36h
.DB %01111111 ; Hex 7Fh
.DB %00110110 ; Hex 36h
.DB %00110110 ; Hex 36h
.DB %00000000 ; Hex 00h
; Character 0x24 $
.DB %00001100 ; Hex 0Ch
.DB %00111111 ; Hex 3Fh
.DB %01101000 ; Hex 68h
.DB %00111110 ; Hex 3Eh
.DB %00001011 ; Hex 0Bh
.DB %01111110 ; Hex 7Eh
.DB %00011000 ; Hex 18h
.DB %00000000 ; Hex 00h
; Character 0x25 %
.DB %01100000 ; Hex 60h
.DB %01100110 ; Hex 66h
.DB %00001100 ; Hex 0Ch
.DB %00011000 ; Hex 18h
.DB %00110000 ; Hex 30h
.DB %01100110 ; Hex 66h
.DB %00000110 ; Hex 06h
.DB %00000000 ; Hex 00h
; Character 0x26 &
.DB %00111000 ; Hex 38h
.DB %01101100 ; Hex 6Ch
.DB %01101100 ; Hex 6Ch
.DB %00111000 ; Hex 38h
.DB %01101101 ; Hex 6Dh
.DB %01100110 ; Hex 66h
.DB %00111011 ; Hex 3Bh
.DB %00000000 ; Hex 00h
; Character 0x27 '
.DB %00001100 ; Hex 0Ch
.DB %00011000 ; Hex 18h
.DB %00110000 ; Hex 30h
.DB %00000000 ; Hex 00h
.DB %00000000 ; Hex 00h
.DB %00000000 ; Hex 00h
.DB %00000000 ; Hex 00h
.DB %00000000 ; Hex 00h
; Character 0x28 (
.DB %00001100 ; Hex 0Ch
.DB %00011000 ; Hex 18h
.DB %00110000 ; Hex 30h
.DB %00110000 ; Hex 30h
.DB %00110000 ; Hex 30h
.DB %00011000 ; Hex 18h
.DB %00001100 ; Hex 0Ch
.DB %00000000 ; Hex 00h
; Character 0x29 )
.DB %00110000 ; Hex 30h
.DB %00011000 ; Hex 18h
.DB %00001100 ; Hex 0Ch
.DB %00001100 ; Hex 0Ch
.DB %00001100 ; Hex 0Ch
.DB %00011000 ; Hex 18h
.DB %00110000 ; Hex 30h
.DB %00000000 ; Hex 00h
; Character 0x2A *
.DB %00000000 ; Hex 00h
.DB %00011000 ; Hex 18h
.DB %01111110 ; Hex 7Eh
.DB %00111100 ; Hex 3Ch
.DB %01111110 ; Hex 7Eh
.DB %00011000 ; Hex 18h
.DB %00000000 ; Hex 00h
.DB %00000000 ; Hex 00h
; Character 0x2B +
.DB %00000000 ; Hex 00h
.DB %00011000 ; Hex 18h
.DB %00011000 ; Hex 18h
.DB %01111110 ; Hex 7Eh
.DB %00011000 ; Hex 18h
.DB %00011000 ; Hex 18h
.DB %00000000 ; Hex 00h
.DB %00000000 ; Hex 00h
; Character 0x2C ,
.DB %00000000 ; Hex 00h
.DB %00000000 ; Hex 00h
.DB %00000000 ; Hex 00h
.DB %00000000 ; Hex 00h
.DB %00000000 ; Hex 00h
.DB %00011000 ; Hex 18h
.DB %00011000 ; Hex 18h
.DB %00110000 ; Hex 30h
; Character 0x2D -
.DB %00000000 ; Hex 00h
.DB %00000000 ; Hex 00h
.DB %00000000 ; Hex 00h
.DB %01111110 ; Hex 7Eh
.DB %00000000 ; Hex 00h
.DB %00000000 ; Hex 00h
.DB %00000000 ; Hex 00h
.DB %00000000 ; Hex 00h
; Character 0x2E .
.DB %00000000 ; Hex 00h
.DB %00000000 ; Hex 00h
.DB %00000000 ; Hex 00h
.DB %00000000 ; Hex 00h
.DB %00000000 ; Hex 00h
.DB %00011000 ; Hex 18h
.DB %00011000 ; Hex 18h
.DB %00000000 ; Hex 00h
; Character 0x2F /
.DB %00000000 ; Hex 00h
.DB %00000110 ; Hex 06h
.DB %00001100 ; Hex 0Ch
.DB %00011000 ; Hex 18h
.DB %00110000 ; Hex 30h
.DB %01100000 ; Hex 60h
.DB %00000000 ; Hex 00h
.DB %00000000 ; Hex 00h
; Character 0x30 0
.DB %00111100 ; Hex 3Ch
.DB %01100110 ; Hex 66h
.DB %01101110 ; Hex 6Eh
.DB %01111110 ; Hex 7Eh
.DB %01110110 ; Hex 76h
.DB %01100110 ; Hex 66h
.DB %00111100 ; Hex 3Ch
.DB %00000000 ; Hex 00h
; Character 0x31 1
.DB %00011000 ; Hex 18h
.DB %00111000 ; Hex 38h
.DB %00011000 ; Hex 18h
.DB %00011000 ; Hex 18h
.DB %00011000 ; Hex 18h
.DB %00011000 ; Hex 18h
.DB %01111110 ; Hex 7Eh
.DB %00000000 ; Hex 00h
; Character 0x32 2
.DB %00111100 ; Hex 3Ch
.DB %01100110 ; Hex 66h
.DB %00000110 ; Hex 06h
.DB %00001100 ; Hex 0Ch
.DB %00011000 ; Hex 18h
.DB %00110000 ; Hex 30h
.DB %01111110 ; Hex 7Eh
.DB %00000000 ; Hex 00h
; Character 0x33 3
.DB %00111100 ; Hex 3Ch
.DB %01100110 ; Hex 66h
.DB %00000110 ; Hex 06h
.DB %00011100 ; Hex 1Ch
.DB %00000110 ; Hex 06h
.DB %01100110 ; Hex 66h
.DB %00111100 ; Hex 3Ch
.DB %00000000 ; Hex 00h
; Character 0x34 4
.DB %00001100 ; Hex 0Ch
.DB %00011100 ; Hex 1Ch
.DB %00111100 ; Hex 3Ch
.DB %01101100 ; Hex 6Ch
.DB %01111110 ; Hex 7Eh
.DB %00001100 ; Hex 0Ch
.DB %00001100 ; Hex 0Ch
.DB %00000000 ; Hex 00h
; Character 0x35 5
.DB %01111110 ; Hex 7Eh
.DB %01100000 ; Hex 60h
.DB %01111100 ; Hex 7Ch
.DB %00000110 ; Hex 06h
.DB %00000110 ; Hex 06h
.DB %01100110 ; Hex 66h
.DB %00111100 ; Hex 3Ch
.DB %00000000 ; Hex 00h
; Character 0x36 6
.DB %00011100 ; Hex 1Ch
.DB %00110000 ; Hex 30h
.DB %01100000 ; Hex 60h
.DB %01111100 ; Hex 7Ch
.DB %01100110 ; Hex 66h
.DB %01100110 ; Hex 66h
.DB %00111100 ; Hex 3Ch
.DB %00000000 ; Hex 00h
; Character 0x37 7
.DB %01111110 ; Hex 7Eh
.DB %00000110 ; Hex 06h
.DB %00001100 ; Hex 0Ch
.DB %00011000 ; Hex 18h
.DB %00110000 ; Hex 30h
.DB %00110000 ; Hex 30h
.DB %00110000 ; Hex 30h
.DB %00000000 ; Hex 00h
; Character 0x38 8
.DB %00111100 ; Hex 3Ch
.DB %01100110 ; Hex 66h
.DB %01100110 ; Hex 66h
.DB %00111100 ; Hex 3Ch
.DB %01100110 ; Hex 66h
.DB %01100110 ; Hex 66h
.DB %00111100 ; Hex 3Ch
.DB %00000000 ; Hex 00h
; Character 0x39 9
.DB %00111100 ; Hex 3Ch
.DB %01100110 ; Hex 66h
.DB %01100110 ; Hex 66h
.DB %00111110 ; Hex 3Eh
.DB %00000110 ; Hex 06h
.DB %00001100 ; Hex 0Ch
.DB %00111000 ; Hex 38h
.DB %00000000 ; Hex 00h
; Character 0x3A :
.DB %00000000 ; Hex 00h
.DB %00000000 ; Hex 00h
.DB %00011000 ; Hex 18h
.DB %00011000 ; Hex 18h
.DB %00000000 ; Hex 00h
.DB %00011000 ; Hex 18h
.DB %00011000 ; Hex 18h
.DB %00000000 ; Hex 00h
; Character 0x3B ;
.DB %00000000 ; Hex 00h
.DB %00000000 ; Hex 00h
.DB %00011000 ; Hex 18h
.DB %00011000 ; Hex 18h
.DB %00000000 ; Hex 00h
.DB %00011000 ; Hex 18h
.DB %00011000 ; Hex 18h
.DB %00110000 ; Hex 30h
; Character 0x3C <
.DB %00001100 ; Hex 0Ch
.DB %00011000 ; Hex 18h
.DB %00110000 ; Hex 30h
.DB %01100000 ; Hex 60h
.DB %00110000 ; Hex 30h
.DB %00011000 ; Hex 18h
.DB %00001100 ; Hex 0Ch
.DB %00000000 ; Hex 00h
; Character 0x3D =
.DB %00000000 ; Hex 00h
.DB %00000000 ; Hex 00h
.DB %01111110 ; Hex 7Eh
.DB %00000000 ; Hex 00h
.DB %01111110 ; Hex 7Eh
.DB %00000000 ; Hex 00h
.DB %00000000 ; Hex 00h
.DB %00000000 ; Hex 00h
; Character 0x3E >
.DB %00110000 ; Hex 30h
.DB %00011000 ; Hex 18h
.DB %00001100 ; Hex 0Ch
.DB %00000110 ; Hex 06h
.DB %00001100 ; Hex 0Ch
.DB %00011000 ; Hex 18h
.DB %00110000 ; Hex 30h
.DB %00000000 ; Hex 00h
; Character 0x3F ?
.DB %00111100 ; Hex 3Ch
.DB %01100110 ; Hex 66h
.DB %00001100 ; Hex 0Ch
.DB %00011000 ; Hex 18h
.DB %00011000 ; Hex 18h
.DB %00000000 ; Hex 00h
.DB %00011000 ; Hex 18h
.DB %00000000 ; Hex 00h
; Character 0x40 @
.DB %00111100 ; Hex 3Ch
.DB %01100110 ; Hex 66h
.DB %01101110 ; Hex 6Eh
.DB %01101010 ; Hex 6Ah
.DB %01101110 ; Hex 6Eh
.DB %01100000 ; Hex 60h
.DB %00111100 ; Hex 3Ch
.DB %00000000 ; Hex 00h
; Character 0x41 A
.DB %00111100 ; Hex 3Ch
.DB %01100110 ; Hex 66h
.DB %01100110 ; Hex 66h
.DB %01111110 ; Hex 7Eh
.DB %01100110 ; Hex 66h
.DB %01100110 ; Hex 66h
.DB %01100110 ; Hex 66h
.DB %00000000 ; Hex 00h
; Character 0x42 B
.DB %01111100 ; Hex 7Ch
.DB %01100110 ; Hex 66h
.DB %01100110 ; Hex 66h
.DB %01111100 ; Hex 7Ch
.DB %01100110 ; Hex 66h
.DB %01100110 ; Hex 66h
.DB %01111100 ; Hex 7Ch
.DB %00000000 ; Hex 00h
; Character 0x43 C
.DB %00111100 ; Hex 3Ch
.DB %01100110 ; Hex 66h
.DB %01100000 ; Hex 60h
.DB %01100000 ; Hex 60h
.DB %01100000 ; Hex 60h
.DB %01100110 ; Hex 66h
.DB %00111100 ; Hex 3Ch
.DB %00000000 ; Hex 00h
; Character 0x44 D
.DB %01111000 ; Hex 78h
.DB %01101100 ; Hex 6Ch
.DB %01100110 ; Hex 66h
.DB %01100110 ; Hex 66h
.DB %01100110 ; Hex 66h
.DB %01101100 ; Hex 6Ch
.DB %01111000 ; Hex 78h
.DB %00000000 ; Hex 00h
; Character 0x45 E
.DB %01111110 ; Hex 7Eh
.DB %01100000 ; Hex 60h
.DB %01100000 ; Hex 60h
.DB %01111100 ; Hex 7Ch
.DB %01100000 ; Hex 60h
.DB %01100000 ; Hex 60h
.DB %01111110 ; Hex 7Eh
.DB %00000000 ; Hex 00h
; Character 0x46 F
.DB %01111110 ; Hex 7Eh
.DB %01100000 ; Hex 60h
.DB %01100000 ; Hex 60h
.DB %01111100 ; Hex 7Ch
.DB %01100000 ; Hex 60h
.DB %01100000 ; Hex 60h
.DB %01100000 ; Hex 60h
.DB %00000000 ; Hex 00h
; Character 0x47 G
.DB %00111100 ; Hex 3Ch
.DB %01100110 ; Hex 66h
.DB %01100000 ; Hex 60h
.DB %01101110 ; Hex 6Eh
.DB %01100110 ; Hex 66h
.DB %01100110 ; Hex 66h
.DB %00111100 ; Hex 3Ch
.DB %00000000 ; Hex 00h
; Character 0x48 H
.DB %01100110 ; Hex 66h
.DB %01100110 ; Hex 66h
.DB %01100110 ; Hex 66h
.DB %01111110 ; Hex 7Eh
.DB %01100110 ; Hex 66h
.DB %01100110 ; Hex 66h
.DB %01100110 ; Hex 66h
.DB %00000000 ; Hex 00h
; Character 0x49 I
.DB %01111110 ; Hex 7Eh
.DB %00011000 ; Hex 18h
.DB %00011000 ; Hex 18h
.DB %00011000 ; Hex 18h
.DB %00011000 ; Hex 18h
.DB %00011000 ; Hex 18h
.DB %01111110 ; Hex 7Eh
.DB %00000000 ; Hex 00h
; Character 0x4A J
.DB %00111110 ; Hex 3Eh
.DB %00001100 ; Hex 0Ch
.DB %00001100 ; Hex 0Ch
.DB %00001100 ; Hex 0Ch
.DB %00001100 ; Hex 0Ch
.DB %01101100 ; Hex 6Ch
.DB %00111000 ; Hex 38h
.DB %00000000 ; Hex 00h
; Character 0x4B K
.DB %01100110 ; Hex 66h
.DB %01101100 ; Hex 6Ch
.DB %01111000 ; Hex 78h
.DB %01110000 ; Hex 70h
.DB %01111000 ; Hex 78h
.DB %01101100 ; Hex 6Ch
.DB %01100110 ; Hex 66h
.DB %00000000 ; Hex 00h
; Character 0x4C L
.DB %01100000 ; Hex 60h
.DB %01100000 ; Hex 60h
.DB %01100000 ; Hex 60h
.DB %01100000 ; Hex 60h
.DB %01100000 ; Hex 60h
.DB %01100000 ; Hex 60h
.DB %01111110 ; Hex 7Eh
.DB %00000000 ; Hex 00h
; Character 0x4D M
.DB %01100011 ; Hex 63h
.DB %01110111 ; Hex 77h
.DB %01111111 ; Hex 7Fh
.DB %01101011 ; Hex 6Bh
.DB %01101011 ; Hex 6Bh
.DB %01100011 ; Hex 63h
.DB %01100011 ; Hex 63h
.DB %00000000 ; Hex 00h
; Character 0x4E N
.DB %01100110 ; Hex 66h
.DB %01100110 ; Hex 66h
.DB %01110110 ; Hex 76h
.DB %01111110 ; Hex 7Eh
.DB %01101110 ; Hex 6Eh
.DB %01100110 ; Hex 66h
.DB %01100110 ; Hex 66h
.DB %00000000 ; Hex 00h
; Character 0x4F O
.DB %00111100 ; Hex 3Ch
.DB %01100110 ; Hex 66h
.DB %01100110 ; Hex 66h
.DB %01100110 ; Hex 66h
.DB %01100110 ; Hex 66h
.DB %01100110 ; Hex 66h
.DB %00111100 ; Hex 3Ch
.DB %00000000 ; Hex 00h
; Character 0x50 P
.DB %01111100 ; Hex 7Ch
.DB %01100110 ; Hex 66h
.DB %01100110 ; Hex 66h
.DB %01111100 ; Hex 7Ch
.DB %01100000 ; Hex 60h
.DB %01100000 ; Hex 60h
.DB %01100000 ; Hex 60h
.DB %00000000 ; Hex 00h
; Character 0x51 Q
.DB %00111100 ; Hex 3Ch
.DB %01100110 ; Hex 66h
.DB %01100110 ; Hex 66h
.DB %01100110 ; Hex 66h
.DB %01101010 ; Hex 6Ah
.DB %01101100 ; Hex 6Ch
.DB %00110110 ; Hex 36h
.DB %00000000 ; Hex 00h
; Character 0x52 R
.DB %01111100 ; Hex 7Ch
.DB %01100110 ; Hex 66h
.DB %01100110 ; Hex 66h
.DB %01111100 ; Hex 7Ch
.DB %01101100 ; Hex 6Ch
.DB %01100110 ; Hex 66h
.DB %01100110 ; Hex 66h
.DB %00000000 ; Hex 00h
; Character 0x53 S
.DB %00111100 ; Hex 3Ch
.DB %01100110 ; Hex 66h
.DB %01100000 ; Hex 60h
.DB %00111100 ; Hex 3Ch
.DB %00000110 ; Hex 06h
.DB %01100110 ; Hex 66h
.DB %00111100 ; Hex 3Ch
.DB %00000000 ; Hex 00h
; Character 0x54 T
.DB %01111110 ; Hex 7Eh
.DB %00011000 ; Hex 18h
.DB %00011000 ; Hex 18h
.DB %00011000 ; Hex 18h
.DB %00011000 ; Hex 18h
.DB %00011000 ; Hex 18h
.DB %00011000 ; Hex 18h
.DB %00000000 ; Hex 00h
; Character 0x55 U
.DB %01100110 ; Hex 66h
.DB %01100110 ; Hex 66h
.DB %01100110 ; Hex 66h
.DB %01100110 ; Hex 66h
.DB %01100110 ; Hex 66h
.DB %01100110 ; Hex 66h
.DB %00111100 ; Hex 3Ch
.DB %00000000 ; Hex 00h
; Character 0x56 V
.DB %01100110 ; Hex 66h
.DB %01100110 ; Hex 66h
.DB %01100110 ; Hex 66h
.DB %01100110 ; Hex 66h
.DB %01100110 ; Hex 66h
.DB %00111100 ; Hex 3Ch
.DB %00011000 ; Hex 18h
.DB %00000000 ; Hex 00h
; Character 0x57 W
.DB %01100011 ; Hex 63h
.DB %01100011 ; Hex 63h
.DB %01101011 ; Hex 6Bh
.DB %01101011 ; Hex 6Bh
.DB %01111111 ; Hex 7Fh
.DB %01110111 ; Hex 77h
.DB %01100011 ; Hex 63h
.DB %00000000 ; Hex 00h
; Character 0x58 X
.DB %01100110 ; Hex 66h
.DB %01100110 ; Hex 66h
.DB %00111100 ; Hex 3Ch
.DB %00011000 ; Hex 18h
.DB %00111100 ; Hex 3Ch
.DB %01100110 ; Hex 66h
.DB %01100110 ; Hex 66h
.DB %00000000 ; Hex 00h
; Character 0x59 Y
.DB %01100110 ; Hex 66h
.DB %01100110 ; Hex 66h
.DB %01100110 ; Hex 66h
.DB %00111100 ; Hex 3Ch
.DB %00011000 ; Hex 18h
.DB %00011000 ; Hex 18h
.DB %00011000 ; Hex 18h
.DB %00000000 ; Hex 00h
; Character 0x5A Z
.DB %01111110 ; Hex 7Eh
.DB %00000110 ; Hex 06h
.DB %00001100 ; Hex 0Ch
.DB %00011000 ; Hex 18h
.DB %00110000 ; Hex 30h
.DB %01100000 ; Hex 60h
.DB %01111110 ; Hex 7Eh
.DB %00000000 ; Hex 00h
; Character 0x5B [
.DB %01111100 ; Hex 7Ch
.DB %01100000 ; Hex 60h
.DB %01100000 ; Hex 60h
.DB %01100000 ; Hex 60h
.DB %01100000 ; Hex 60h
.DB %01100000 ; Hex 60h
.DB %01111100 ; Hex 7Ch
.DB %00000000 ; Hex 00h
; Character 0x5C \
.DB %00000000 ; Hex 00h
.DB %01100000 ; Hex 60h
.DB %00110000 ; Hex 30h
.DB %00011000 ; Hex 18h
.DB %00001100 ; Hex 0Ch
.DB %00000110 ; Hex 06h
.DB %00000000 ; Hex 00h
.DB %00000000 ; Hex 00h
; Character 0x5D ]
.DB %00111110 ; Hex 3Eh
.DB %00000110 ; Hex 06h
.DB %00000110 ; Hex 06h
.DB %00000110 ; Hex 06h
.DB %00000110 ; Hex 06h
.DB %00000110 ; Hex 06h
.DB %00111110 ; Hex 3Eh
.DB %00000000 ; Hex 00h
; Character 0x5E ^
.DB %00011000 ; Hex 18h
.DB %00111100 ; Hex 3Ch
.DB %01100110 ; Hex 66h
.DB %01000010 ; Hex 42h
.DB %00000000 ; Hex 00h
.DB %00000000 ; Hex 00h
.DB %00000000 ; Hex 00h
.DB %00000000 ; Hex 00h
; Character 0x5F (underscore)
.DB %00000000 ; Hex 00h
.DB %00000000 ; Hex 00h
.DB %00000000 ; Hex 00h
.DB %00000000 ; Hex 00h
.DB %00000000 ; Hex 00h
.DB %00000000 ; Hex 00h
.DB %00000000 ; Hex 00h
.DB %11111111 ; Hex FFh
; Character 0x60 (Pound Sterling)
.DB %00011100 ; Hex 1Ch
.DB %00110110 ; Hex 36h
.DB %00110000 ; Hex 30h
.DB %01111100 ; Hex 7Ch
.DB %00110000 ; Hex 30h
.DB %00110000 ; Hex 30h
.DB %01111110 ; Hex 7Eh
.DB %00000000 ; Hex 00h
; Character 0x61 a
.DB %00000000 ; Hex 00h
.DB %00000000 ; Hex 00h
.DB %00111100 ; Hex 3Ch
.DB %00000110 ; Hex 06h
.DB %00111110 ; Hex 3Eh
.DB %01100110 ; Hex 66h
.DB %00111110 ; Hex 3Eh
.DB %00000000 ; Hex 00h
; Character 0x62 b
.DB %01100000 ; Hex 60h
.DB %01100000 ; Hex 60h
.DB %01111100 ; Hex 7Ch
.DB %01100110 ; Hex 66h
.DB %01100110 ; Hex 66h
.DB %01100110 ; Hex 66h
.DB %01111100 ; Hex 7Ch
.DB %00000000 ; Hex 00h
; Character 0x63 c
.DB %00000000 ; Hex 00h
.DB %00000000 ; Hex 00h
.DB %00111100 ; Hex 3Ch
.DB %01100110 ; Hex 66h
.DB %01100000 ; Hex 60h
.DB %01100110 ; Hex 66h
.DB %00111100 ; Hex 3Ch
.DB %00000000 ; Hex 00h
; Character 0x64 d
.DB %00000110 ; Hex 06h
.DB %00000110 ; Hex 06h
.DB %00111110 ; Hex 3Eh
.DB %01100110 ; Hex 66h
.DB %01100110 ; Hex 66h
.DB %01100110 ; Hex 66h
.DB %00111110 ; Hex 3Eh
.DB %00000000 ; Hex 00h
; Character 0x65 e
.DB %00000000 ; Hex 00h
.DB %00000000 ; Hex 00h
.DB %00111100 ; Hex 3Ch
.DB %01100110 ; Hex 66h
.DB %01111110 ; Hex 7Eh
.DB %01100000 ; Hex 60h
.DB %00111100 ; Hex 3Ch
.DB %00000000 ; Hex 00h
; Character 0x66 f
.DB %00011100 ; Hex 1Ch
.DB %00110000 ; Hex 30h
.DB %00110000 ; Hex 30h
.DB %01111100 ; Hex 7Ch
.DB %00110000 ; Hex 30h
.DB %00110000 ; Hex 30h
.DB %00110000 ; Hex 30h
.DB %00000000 ; Hex 00h
; Character 0x67 g
.DB %00000000 ; Hex 00h
.DB %00000000 ; Hex 00h
.DB %00111110 ; Hex 3Eh
.DB %01100110 ; Hex 66h
.DB %01100110 ; Hex 66h
.DB %00111110 ; Hex 3Eh
.DB %00000110 ; Hex 06h
.DB %00111100 ; Hex 3Ch
; Character 0x68 h
.DB %01100000 ; Hex 60h
.DB %01100000 ; Hex 60h
.DB %01111100 ; Hex 7Ch
.DB %01100110 ; Hex 66h
.DB %01100110 ; Hex 66h
.DB %01100110 ; Hex 66h
.DB %01100110 ; Hex 66h
.DB %00000000 ; Hex 00h
; Character 0x69 i
.DB %00011000 ; Hex 18h
.DB %00000000 ; Hex 00h
.DB %00111000 ; Hex 38h
.DB %00011000 ; Hex 18h
.DB %00011000 ; Hex 18h
.DB %00011000 ; Hex 18h
.DB %00111100 ; Hex 3Ch
.DB %00000000 ; Hex 00h
; Character 0x6A j
.DB %00011000 ; Hex 18h
.DB %00000000 ; Hex 00h
.DB %00111000 ; Hex 38h
.DB %00011000 ; Hex 18h
.DB %00011000 ; Hex 18h
.DB %00011000 ; Hex 18h
.DB %00011000 ; Hex 18h
.DB %01110000 ; Hex 70h
; Character 0x6B k
.DB %01100000 ; Hex 60h
.DB %01100000 ; Hex 60h
.DB %01100110 ; Hex 66h
.DB %01101100 ; Hex 6Ch
.DB %01111000 ; Hex 78h
.DB %01101100 ; Hex 6Ch
.DB %01100110 ; Hex 66h
.DB %00000000 ; Hex 00h
; Character 0x6C l
.DB %00111000 ; Hex 38h
.DB %00011000 ; Hex 18h
.DB %00011000 ; Hex 18h
.DB %00011000 ; Hex 18h
.DB %00011000 ; Hex 18h
.DB %00011000 ; Hex 18h
.DB %00111100 ; Hex 3Ch
.DB %00000000 ; Hex 00h
; Character 0x6D m
.DB %00000000 ; Hex 00h
.DB %00000000 ; Hex 00h
.DB %00110110 ; Hex 36h
.DB %01111111 ; Hex 7Fh
.DB %01101011 ; Hex 6Bh
.DB %01101011 ; Hex 6Bh
.DB %01100011 ; Hex 63h
.DB %00000000 ; Hex 00h
; Character 0x6E n
.DB %00000000 ; Hex 00h
.DB %00000000 ; Hex 00h
.DB %01111100 ; Hex 7Ch
.DB %01100110 ; Hex 66h
.DB %01100110 ; Hex 66h
.DB %01100110 ; Hex 66h
.DB %01100110 ; Hex 66h
.DB %00000000 ; Hex 00h
; Character 0x6F o
.DB %00000000 ; Hex 00h
.DB %00000000 ; Hex 00h
.DB %00111100 ; Hex 3Ch
.DB %01100110 ; Hex 66h
.DB %01100110 ; Hex 66h
.DB %01100110 ; Hex 66h
.DB %00111100 ; Hex 3Ch
.DB %00000000 ; Hex 00h
; Character 0x70 p
.DB %00000000 ; Hex 00h
.DB %00000000 ; Hex 00h
.DB %01111100 ; Hex 7Ch
.DB %01100110 ; Hex 66h
.DB %01100110 ; Hex 66h
.DB %01111100 ; Hex 7Ch
.DB %01100000 ; Hex 60h
.DB %01100000 ; Hex 60h
; Character 0x71 q
.DB %00000000 ; Hex 00h
.DB %00000000 ; Hex 00h
.DB %00111110 ; Hex 3Eh
.DB %01100110 ; Hex 66h
.DB %01100110 ; Hex 66h
.DB %00111110 ; Hex 3Eh
.DB %00000110 ; Hex 06h
.DB %00000111 ; Hex 07h
; Character 0x72 r
.DB %00000000 ; Hex 00h
.DB %00000000 ; Hex 00h
.DB %01101100 ; Hex 6Ch
.DB %01110110 ; Hex 76h
.DB %01100000 ; Hex 60h
.DB %01100000 ; Hex 60h
.DB %01100000 ; Hex 60h
.DB %00000000 ; Hex 00h
; Character 0x73 s
.DB %00000000 ; Hex 00h
.DB %00000000 ; Hex 00h
.DB %00111110 ; Hex 3Eh
.DB %01100000 ; Hex 60h
.DB %00111100 ; Hex 3Ch
.DB %00000110 ; Hex 06h
.DB %01111100 ; Hex 7Ch
.DB %00000000 ; Hex 00h
; Character 0x74 t
.DB %00110000 ; Hex 30h
.DB %00110000 ; Hex 30h
.DB %01111100 ; Hex 7Ch
.DB %00110000 ; Hex 30h
.DB %00110000 ; Hex 30h
.DB %00110000 ; Hex 30h
.DB %00011100 ; Hex 1Ch
.DB %00000000 ; Hex 00h
; Character 0x75 u
.DB %00000000 ; Hex 00h
.DB %00000000 ; Hex 00h
.DB %01100110 ; Hex 66h
.DB %01100110 ; Hex 66h
.DB %01100110 ; Hex 66h
.DB %01100110 ; Hex 66h
.DB %00111110 ; Hex 3Eh
.DB %00000000 ; Hex 00h
; Character 0x76 v
.DB %00000000 ; Hex 00h
.DB %00000000 ; Hex 00h
.DB %01100110 ; Hex 66h
.DB %01100110 ; Hex 66h
.DB %01100110 ; Hex 66h
.DB %00111100 ; Hex 3Ch
.DB %00011000 ; Hex 18h
.DB %00000000 ; Hex 00h
; Character 0x77 w
.DB %00000000 ; Hex 00h
.DB %00000000 ; Hex 00h
.DB %01100011 ; Hex 63h
.DB %01101011 ; Hex 6Bh
.DB %01101011 ; Hex 6Bh
.DB %01111111 ; Hex 7Fh
.DB %00110110 ; Hex 36h
.DB %00000000 ; Hex 00h
; Character 0x78 x
.DB %00000000 ; Hex 00h
.DB %00000000 ; Hex 00h
.DB %01100110 ; Hex 66h
.DB %00111100 ; Hex 3Ch
.DB %00011000 ; Hex 18h
.DB %00111100 ; Hex 3Ch
.DB %01100110 ; Hex 66h
.DB %00000000 ; Hex 00h
; Character 0x79 y
.DB %00000000 ; Hex 00h
.DB %00000000 ; Hex 00h
.DB %01100110 ; Hex 66h
.DB %01100110 ; Hex 66h
.DB %01100110 ; Hex 66h
.DB %00111110 ; Hex 3Eh
.DB %00000110 ; Hex 06h
.DB %00111100 ; Hex 3Ch
; Character 0x7A z
.DB %00000000 ; Hex 00h
.DB %00000000 ; Hex 00h
.DB %01111110 ; Hex 7Eh
.DB %00001100 ; Hex 0Ch
.DB %00011000 ; Hex 18h
.DB %00110000 ; Hex 30h
.DB %01111110 ; Hex 7Eh
.DB %00000000 ; Hex 00h
; Character 0x7B {
.DB %00001100 ; Hex 0Ch
.DB %00011000 ; Hex 18h
.DB %00011000 ; Hex 18h
.DB %01110000 ; Hex 70h
.DB %00011000 ; Hex 18h
.DB %00011000 ; Hex 18h
.DB %00001100 ; Hex 0Ch
.DB %00000000 ; Hex 00h
; Character 0x7C (OR symbol)
.DB %00011000 ; Hex 18h
.DB %00011000 ; Hex 18h
.DB %00011000 ; Hex 18h
.DB %00000000 ; Hex 00h
.DB %00011000 ; Hex 18h
.DB %00011000 ; Hex 18h
.DB %00011000 ; Hex 18h
.DB %00000000 ; Hex 00h
; Character 0x7D }
.DB %00110000 ; Hex 30h
.DB %00011000 ; Hex 18h
.DB %00011000 ; Hex 18h
.DB %00001110 ; Hex 0Eh
.DB %00011000 ; Hex 18h
.DB %00011000 ; Hex 18h
.DB %00110000 ; Hex 30h
.DB %00000000 ; Hex 00h
; Character 0x7E ~
.DB %00110001 ; Hex 31h
.DB %01101011 ; Hex 6Bh
.DB %01000110 ; Hex 46h
.DB %00000000 ; Hex 00h
.DB %00000000 ; Hex 00h
.DB %00000000 ; Hex 00h
.DB %00000000 ; Hex 00h
.DB %00000000 ; Hex 00h
; Character 0x7F (block)
.DB %11111111 ; Hex FFh
.DB %11111111 ; Hex FFh
.DB %11111111 ; Hex FFh
.DB %11111111 ; Hex FFh
.DB %11111111 ; Hex FFh
.DB %11111111 ; Hex FFh
.DB %11111111 ; Hex FFh
.DB %11111111 ; Hex FFh
;------------------------------------------
;
; That's all folks! Now that Acorn is no
; longer with us (RIP), it should be safe
; to use this font in any homebrew
; projects.
;
; Anyone is welcome to distribute and use
; this source file for whatever purpose
; they wish.
;
;
; Best wishes,
;
; Mike G. (mike@mikeg2.freeserve.co.uk)
;
; 4th March 2001
;
; SMS Power! - www.smspower.org
; SMSReader - www.smspower.org/smsreader/
;
; My Home Page: www.mikeg2.freeserve.co.uk
;
;------------------------------------------
; End of Mike G's font.
FontDataEnd:
| haroldo-ok/really-old-stuff | mastersystem/tml2-test/wla-dx/helloworld/Hello World.asm | Assembly | apache-2.0 | 29,488 |
; init32.asm: 32-bit, protected-mode initialization
;
; Copyright 2015, 2016 Vincent Damewood
; All rights reserved.
;
; 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 code must retain the above copyright
; notice, this list of conditions and the following disclaimer.
;
; 2. Redistributions in binary form must reproduce the above copyright
; notice, this list of conditions and the following disclaimer in the
; documentation and/or other materials provided with the distribution.
;
; THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
; "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
; LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
; A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
; HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
; SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
; LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
; DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
; THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
; (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
; OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
extern Init32c
extern KeyboardHandleInterrupt
extern fdHandleInterrupt
extern tmrHandleInterrupt
%macro fprolog 1-*
push ebp
mov ebp, esp
%if %1
sub esp, (%1*4)
%endif
%if %0 > 2
%rotate 1
%rep %0-1
push %1
%rotate 1
%endrep
%endif
%endmacro
%macro freturn 0-*
%rep %0
%rotate -1
pop %1
%endrep
mov esp, ebp
pop ebp
ret
%endmacro
%macro intrfreturn 0-*
%rep %0
%rotate -1
pop %1
%endrep
mov esp, ebp
pop ebp
sti
ret
%endmacro
%define IdtCount 48
%define IdtSize (IdtCount<<3)
%define IdtLimit (IdtSize-1)
%define HexTable '0123456789ABCDEF'
SECTION .data
BssSignature: db '.bss', 0
IntrTableReference:
.Limit: dw IdtLimit
.Base: dd IntrTable
; This makes a table of references to the ISRs so
; that it can be looped through to create the real IDT.
IntrSimpleTable:
%assign i 0
%rep IdtCount
%substr IsrDigit1 HexTable ((i / 16 + 1))
%substr IsrDigit2 HexTable ((i % 16 + 1))
%strcat IsrHexString '0x' IsrDigit1 IsrDigit2
%deftok IsrHexToken IsrHexString
dd IntrIsr%[IsrHexToken]
%assign i i+1
%endrep
%undef IsrHexToken
%undef IsrHexString
%undef IsrDigit2
%undef IsrDigit1
%undef IntrHexTable
SECTION .text
global Init32
Init32:
mov eax, 0x10
mov ds, ax
mov es, ax
mov fs, ax
mov gs, ax
mov ss, ax
mov esp, 0x90000
mov ebp, esp
LoadBss:
mov esi, [0x10020] ; Section Table Offset
add esi, 0x10000 ; Convert offset to memory
; Entry = SectionTable + EntrySize * StringIndex
xor eax, eax
xor edx, edx
mov ax, word[0x1002E] ; Size of Entry in section table
mov dx, word[0x10032] ; Index of .shstrtab section, in section table
mul dx
shl edx, 16
or eax, edx
add eax, esi ; We now have the offset within the table, add offset to base
mov ebx, eax
add ebx, 0x10 ; Byte 0x10 of a table entry the section's offset
mov ebx, [ebx]
add ebx, 0x10000 ; ebx now has the memory address of .shstrtab
xor ecx, ecx
xor edx, edx
mov dx, word[0x1002E] ; Load Entry size... again
mov cx, word[0x10030] ; Count
; eax
; ecx -- Number of Sectons
; edx -- Size of a Section Entry
; ebx -- Address of .shstrtab
; esi -- Current Table Entry
; edi
.BssScanLoop:
push esi
push ecx
mov edi, [esi] ; Read first word in entry (offset in .shstrtab)
add edi, ebx ; Add offset to base
mov esi, BssSignature
mov ecx, 5
repe cmpsb
pop ecx
pop esi
jz .BssFound
add esi, edx
loop .BssScanLoop
jmp .BssDone
.BssFound:
mov eax, [esi]
add eax, ebx
xor eax, eax
mov edi, [esi+0x0C] ; Address of .bss
mov ecx, [esi+0x14] ; Size of .bss
rep stosb
.BssDone:
call IntrSetupInterrupts
JumpToC:
jmp Init32c
section .bss
IntrTable: resb IdtSize
section .text
IntrIsrCommon:
%define Interrupt dword[ebp+4]
%define Code dword[ebp+8]
push ebp
mov ebp, esp
pusha
mov eax, Interrupt
.try_timer:
cmp eax, 0x20
jne .not_timer
.yes_timer:
call tmrHandleInterrupt
jmp .cleanup
.not_timer:
.try_keyboard:
cmp eax, 0x21
jne .not_keyboard
.yes_keyboard:
call KeyboardHandleInterrupt
jmp .cleanup
.not_keyboard:
.try_floppy:
cmp eax, 0x26
jne .not_floppy
.yes_floppy:
call fdHandleInterrupt
jmp .cleanup
.not_floppy:
.cleanup:
mov ecx, Interrupt
cmp ecx, 0x20
jl .done
cmp ecx, 0x2F
jg .done
mov al, 0x20
out 0x20, al
cmp ecx, 0x28
jl .done
out 0xA0, al
.done:
popa
mov esp, ebp
pop ebp
add esp, 8
sti
iret
%undef Interrupt
%undef Code
; The following code creates ISRs for each interrupt.
%assign i 0
%rep IdtCount
%substr IsrDigit1 HexTable ((i / 16 + 1))
%substr IsrDigit2 HexTable ((i % 16 + 1))
%strcat IsrHexString '0x' IsrDigit1 IsrDigit2
%deftok IsrHexToken IsrHexString
IntrIsr%[IsrHexToken]:
cli
%if (0)
%else
push 0
%endif
push i
jmp IntrIsrCommon
%assign i i+1
%endrep
IntrSetupInterrupts:
fprolog 0, eax, edx, ebx
mov eax, 0
mov ebx, IntrSimpleTable
push 0x8E ; Flags
push 0x08 ; Segment
.loop:
push dword[ebx]
push eax
call IntrAddInterrupt
add esp, 8
add ebx, 4 ; next entry
inc eax
cmp eax, IdtCount
jne .loop
mov edx, IntrTableReference
lidt [edx]
;read 0x21
;read 0xA1
in al, 0x21
shl ax, 8
in al, 0xA1
mov bx, ax
;0x20 <-- 0x11
;0xA0 <-- 0x11
mov al, 0x11
out 0x20, al
out 0xA0, al
;0x21 <-- 0x20
;0xA1 <-- 0x28
mov al, 0x20
out 0x21, al
mov al, 0x28
out 0xA1, al
;0x21 <-- 0x04
;0xA1 <-- 0x02
mov al, 0x04
out 0x21, al
mov al, 0x02
out 0xA1, al
;0x21 <-- 0x01
;0xA1 <-- 0x01
mov al, 0x01
out 0x21, al
out 0xA1, al
;replace 0xA1
;replace 0x21
mov ax, bx
out 0xA1, al
shr ax, 8
out 0x21, al
mov al,20h
out 20h,al
intrfreturn eax, edx, ebx
IntrAddInterrupt:
fprolog 0, eax, ebx
%define SrcNumber byte [ebp+ 8]
%define SrcAddr dword [ebp+12]
%define SrcSegment word [ebp+16]
%define SrcFlags byte [ebp+20]
%define DstAddrLo word [ebx+0]
%define DstSegment word [ebx+2]
%define DstZero byte [ebx+4]
%define DstFlags byte [ebx+5]
%define DstAddrHi word [ebx+6]
.EndDebug:
xor eax, eax
xor ebx, ebx
; Establish Entry Address
mov bl, SrcNumber
shl ebx, 3
add ebx, IntrTable
; Set the Always-Zero Field to Zero
mov DstZero, al
; Mangle and save the ISR address
mov eax, SrcAddr
mov DstAddrLo, ax
shr eax, 16
mov DstAddrHi, ax
; Simple copies
mov ax, SrcSegment
mov DstSegment, ax
mov al, SrcFlags
mov DstFlags, al
%undef SrcNumber
%undef SrcAddr
%undef SrcSegment
%undef SrcFlags
%undef DstAddrHi
%undef DstSegment
%undef DstZero
%undef DstFlags
%undef DstAddrLo
freturn eax, ebx
%undef IdtCount
%undef IdtSize
%undef IdtLimit
| vendu/Ukko | stage2/init32.asm | Assembly | bsd-2-clause | 6,890 |
section .usrtext
global usermain
usermain:
mov eax, msg
int 0x83
int 0x82
ret
msg db 'Hello from userland!', 0xA, 0 | TwoUnderscorez/DuckOS | src/asm/testuserapp.asm | Assembly | bsd-3-clause | 131 |
%define ARCH_AARCH64 0
%define ARCH_ALPHA 0
%define ARCH_ARM 0
%define ARCH_AVR32 0
%define ARCH_AVR32_AP 0
%define ARCH_AVR32_UC 0
%define ARCH_BFIN 0
%define ARCH_IA64 0
%define ARCH_M68K 0
%define ARCH_MIPS 0
%define ARCH_MIPS64 0
%define ARCH_PARISC 0
%define ARCH_PPC 0
%define ARCH_PPC64 0
%define ARCH_S390 0
%define ARCH_SH4 0
%define ARCH_SPARC 0
%define ARCH_SPARC64 0
%define ARCH_TILEGX 0
%define ARCH_TILEPRO 0
%define ARCH_TOMI 0
%define ARCH_X86 1
%define ARCH_X86_32 1
%define ARCH_X86_64 0
%define HAVE_ARMV5TE 0
%define HAVE_ARMV6 0
%define HAVE_ARMV6T2 0
%define HAVE_NEON 0
%define HAVE_VFP 0
%define HAVE_VFPV3 0
%define HAVE_AMD3DNOW 1
%define HAVE_AMD3DNOWEXT 1
%define HAVE_AVX 1
%define HAVE_FMA4 1
%define HAVE_MMX 1
%define HAVE_MMXEXT 1
%define HAVE_SSE 1
%define HAVE_SSE2 1
%define HAVE_SSE3 1
%define HAVE_SSE4 1
%define HAVE_SSE42 1
%define HAVE_SSSE3 1
%define HAVE_ALTIVEC 0
%define HAVE_PPC4XX 0
%define HAVE_VIS 0
%define HAVE_MIPSFPU 0
%define HAVE_MIPS32R2 0
%define HAVE_MIPSDSPR1 0
%define HAVE_MIPSDSPR2 0
%define HAVE_ARMV5TE_EXTERNAL 0
%define HAVE_ARMV6_EXTERNAL 0
%define HAVE_ARMV6T2_EXTERNAL 0
%define HAVE_NEON_EXTERNAL 0
%define HAVE_VFP_EXTERNAL 0
%define HAVE_VFPV3_EXTERNAL 0
%define HAVE_AMD3DNOW_EXTERNAL 1
%define HAVE_AMD3DNOWEXT_EXTERNAL 1
%define HAVE_AVX_EXTERNAL 1
%define HAVE_FMA4_EXTERNAL 1
%define HAVE_MMX_EXTERNAL 1
%define HAVE_MMXEXT_EXTERNAL 1
%define HAVE_SSE_EXTERNAL 1
%define HAVE_SSE2_EXTERNAL 1
%define HAVE_SSE3_EXTERNAL 1
%define HAVE_SSE4_EXTERNAL 1
%define HAVE_SSE42_EXTERNAL 1
%define HAVE_SSSE3_EXTERNAL 1
%define HAVE_ALTIVEC_EXTERNAL 0
%define HAVE_PPC4XX_EXTERNAL 0
%define HAVE_VIS_EXTERNAL 0
%define HAVE_MIPSFPU_EXTERNAL 0
%define HAVE_MIPS32R2_EXTERNAL 0
%define HAVE_MIPSDSPR1_EXTERNAL 0
%define HAVE_MIPSDSPR2_EXTERNAL 0
%define HAVE_ARMV5TE_INLINE 0
%define HAVE_ARMV6_INLINE 0
%define HAVE_ARMV6T2_INLINE 0
%define HAVE_NEON_INLINE 0
%define HAVE_VFP_INLINE 0
%define HAVE_VFPV3_INLINE 0
%define HAVE_AMD3DNOW_INLINE 0
%define HAVE_AMD3DNOWEXT_INLINE 0
%define HAVE_AVX_INLINE 0
%define HAVE_FMA4_INLINE 0
%define HAVE_MMX_INLINE 0
%define HAVE_MMXEXT_INLINE 0
%define HAVE_SSE_INLINE 0
%define HAVE_SSE2_INLINE 0
%define HAVE_SSE3_INLINE 0
%define HAVE_SSE4_INLINE 0
%define HAVE_SSE42_INLINE 0
%define HAVE_SSSE3_INLINE 0
%define HAVE_ALTIVEC_INLINE 0
%define HAVE_PPC4XX_INLINE 0
%define HAVE_VIS_INLINE 0
%define HAVE_MIPSFPU_INLINE 0
%define HAVE_MIPS32R2_INLINE 0
%define HAVE_MIPSDSPR1_INLINE 0
%define HAVE_MIPSDSPR2_INLINE 0
%define HAVE_INLINE_ASM 0
%define HAVE_SYMVER 0
%define HAVE_YASM 1
%define HAVE_BIGENDIAN 0
%define HAVE_FAST_UNALIGNED 1
%define HAVE_INCOMPATIBLE_FORK_ABI 0
%define HAVE_PTHREADS 0
%define HAVE_W32THREADS 1
%define HAVE_OS2THREADS 0
%define HAVE_ATOMICS_GCC 0
%define HAVE_ATOMICS_SUNCC 0
%define HAVE_ATOMICS_WIN32 1
%define HAVE_ATANF 1
%define HAVE_ATAN2F 1
%define HAVE_CBRT 0
%define HAVE_CBRTF 0
%define HAVE_COSF 1
%define HAVE_EXP2 0
%define HAVE_EXP2F 0
%define HAVE_EXPF 1
%define HAVE_ISINF 0
%define HAVE_ISNAN 0
%define HAVE_LDEXPF 1
%define HAVE_LLRINT 0
%define HAVE_LLRINTF 0
%define HAVE_LOG2 0
%define HAVE_LOG2F 0
%define HAVE_LOG10F 1
%define HAVE_LRINT 0
%define HAVE_LRINTF 0
%define HAVE_POWF 1
%define HAVE_RINT 0
%define HAVE_ROUND 0
%define HAVE_ROUNDF 0
%define HAVE_SINF 1
%define HAVE_TRUNC 0
%define HAVE_TRUNCF 0
%define HAVE_ACCESS 1
%define HAVE_ALIGNED_MALLOC 1
%define HAVE_ALIGNED_STACK 0
%define HAVE_ALSA_ASOUNDLIB_H 0
%define HAVE_ALTIVEC_H 0
%define HAVE_ARPA_INET_H 0
%define HAVE_ASM_MOD_Q 0
%define HAVE_ASM_MOD_Y 0
%define HAVE_ASM_TYPES_H 0
%define HAVE_ATOMIC_CAS_PTR 0
%define HAVE_ATOMICS_NATIVE 1
%define HAVE_ATTRIBUTE_MAY_ALIAS 0
%define HAVE_ATTRIBUTE_PACKED 0
%define HAVE_CDIO_PARANOIA_H 0
%define HAVE_CDIO_PARANOIA_PARANOIA_H 0
%define HAVE_CLOCK_GETTIME 0
%define HAVE_CLOSESOCKET 0
%define HAVE_CMOV 0
%define HAVE_COMMANDLINETOARGVW 1
%define HAVE_CPUNOP 1
%define HAVE_CRYPTGENRANDOM 1
%define HAVE_DCBZL 0
%define HAVE_DEV_BKTR_IOCTL_BT848_H 0
%define HAVE_DEV_BKTR_IOCTL_METEOR_H 0
%define HAVE_DEV_IC_BT8XX_H 0
%define HAVE_DEV_VIDEO_BKTR_IOCTL_BT848_H 0
%define HAVE_DEV_VIDEO_METEOR_IOCTL_METEOR_H 0
%define HAVE_DIRECT_H 1
%define HAVE_DLFCN_H 0
%define HAVE_DLOPEN 0
%define HAVE_DOS_PATHS 1
%define HAVE_DXVA_H 1
%define HAVE_EBP_AVAILABLE 0
%define HAVE_EBX_AVAILABLE 0
%define HAVE_FAST_64BIT 0
%define HAVE_FAST_CLZ 1
%define HAVE_FAST_CMOV 0
%define HAVE_FCNTL 0
%define HAVE_FORK 0
%define HAVE_GETADDRINFO 0
%define HAVE_GETHRTIME 0
%define HAVE_GETOPT 0
%define HAVE_GETPROCESSAFFINITYMASK 1
%define HAVE_GETPROCESSMEMORYINFO 1
%define HAVE_GETPROCESSTIMES 1
%define HAVE_GETSYSTEMTIMEASFILETIME 1
%define HAVE_GETRUSAGE 0
%define HAVE_GETSERVBYPORT 0
%define HAVE_GETTIMEOFDAY 0
%define HAVE_GLOB 0
%define HAVE_GNU_AS 0
%define HAVE_GSM_H 0
%define HAVE_IBM_ASM 0
%define HAVE_INET_ATON 0
%define HAVE_IO_H 1
%define HAVE_ISATTY 1
%define HAVE_JACK_PORT_GET_LATENCY_RANGE 0
%define HAVE_KBHIT 1
%define HAVE_LDBRX 0
%define HAVE_LIBDC1394_1 0
%define HAVE_LIBDC1394_2 0
%define HAVE_LOCAL_ALIGNED_16 1
%define HAVE_LOCAL_ALIGNED_8 1
%define HAVE_LOCALTIME_R 0
%define HAVE_LOONGSON 0
%define HAVE_LZO1X_999_COMPRESS 0
%define HAVE_MACHINE_IOCTL_BT848_H 0
%define HAVE_MACHINE_IOCTL_METEOR_H 0
%define HAVE_MACHINE_RW_BARRIER 0
%define HAVE_MAKEINFO 1
%define HAVE_MALLOC_H 1
%define HAVE_MAPVIEWOFFILE 1
%define HAVE_MEMALIGN 0
%define HAVE_MEMORYBARRIER 1
%define HAVE_MKSTEMP 0
%define HAVE_MM_EMPTY 1
%define HAVE_MMAP 0
%define HAVE_MPROTECT 0
%define HAVE_MSVCRT 1
%define HAVE_NANOSLEEP 0
%define HAVE_OPENJPEG_1_5_OPENJPEG_H 0
%define HAVE_PEEKNAMEDPIPE 1
%define HAVE_PERL 1
%define HAVE_POD2MAN 1
%define HAVE_POLL_H 0
%define HAVE_POSIX_MEMALIGN 0
%define HAVE_PTHREAD_CANCEL 0
%define HAVE_RDTSC 1
%define HAVE_RSYNC_CONTIMEOUT 1
%define HAVE_SCHED_GETAFFINITY 0
%define HAVE_SDL 0
%define HAVE_SETCONSOLETEXTATTRIBUTE 1
%define HAVE_SETMODE 1
%define HAVE_SETRLIMIT 0
%define HAVE_SLEEP 1
%define HAVE_SNDIO_H 0
%define HAVE_SOCKLEN_T 0
%define HAVE_SOUNDCARD_H 0
%define HAVE_STRERROR_R 0
%define HAVE_STRUCT_ADDRINFO 0
%define HAVE_STRUCT_GROUP_SOURCE_REQ 0
%define HAVE_STRUCT_IP_MREQ_SOURCE 0
%define HAVE_STRUCT_IPV6_MREQ 0
%define HAVE_STRUCT_POLLFD 0
%define HAVE_STRUCT_RUSAGE_RU_MAXRSS 0
%define HAVE_STRUCT_SCTP_EVENT_SUBSCRIBE 0
%define HAVE_STRUCT_SOCKADDR_IN6 0
%define HAVE_STRUCT_SOCKADDR_SA_LEN 0
%define HAVE_STRUCT_SOCKADDR_STORAGE 0
%define HAVE_STRUCT_V4L2_FRMIVALENUM_DISCRETE 0
%define HAVE_SYMVER_ASM_LABEL 0
%define HAVE_SYMVER_GNU_ASM 0
%define HAVE_SYNC_VAL_COMPARE_AND_SWAP 0
%define HAVE_SYSCONF 0
%define HAVE_SYSCTL 0
%define HAVE_SYS_MMAN_H 0
%define HAVE_SYS_PARAM_H 0
%define HAVE_SYS_RESOURCE_H 0
%define HAVE_SYS_SELECT_H 0
%define HAVE_SYS_SOUNDCARD_H 0
%define HAVE_SYS_TIME_H 0
%define HAVE_SYS_VIDEOIO_H 0
%define HAVE_TERMIOS_H 0
%define HAVE_TEXI2HTML 0
%define HAVE_THREADS 1
%define HAVE_UNISTD_H 0
%define HAVE_USLEEP 0
%define HAVE_VFP_ARGS 0
%define HAVE_VIRTUALALLOC 1
%define HAVE_WINDOWS_H 1
%define HAVE_WINSOCK2_H 0
%define HAVE_XFORM_ASM 0
%define HAVE_XMM_CLOBBERS 0
%define CONFIG_BSFS 0
%define CONFIG_DECODERS 1
%define CONFIG_DEMUXERS 1
%define CONFIG_ENCODERS 0
%define CONFIG_FILTERS 0
%define CONFIG_HWACCELS 0
%define CONFIG_INDEVS 0
%define CONFIG_MUXERS 0
%define CONFIG_OUTDEVS 0
%define CONFIG_PARSERS 1
%define CONFIG_PROTOCOLS 0
%define CONFIG_DOC 0
%define CONFIG_HTMLPAGES 0
%define CONFIG_MANPAGES 1
%define CONFIG_PODPAGES 1
%define CONFIG_TXTPAGES 1
%define CONFIG_AVISYNTH 0
%define CONFIG_BZLIB 0
%define CONFIG_CRYSTALHD 0
%define CONFIG_FONTCONFIG 0
%define CONFIG_FREI0R 0
%define CONFIG_GNUTLS 0
%define CONFIG_ICONV 0
%define CONFIG_LIBAACPLUS 0
%define CONFIG_LIBASS 0
%define CONFIG_LIBBLURAY 0
%define CONFIG_LIBCACA 0
%define CONFIG_LIBCDIO 0
%define CONFIG_LIBCELT 0
%define CONFIG_LIBDC1394 0
%define CONFIG_LIBFAAC 0
%define CONFIG_LIBFDK_AAC 0
%define CONFIG_LIBFLITE 0
%define CONFIG_LIBFREETYPE 0
%define CONFIG_LIBGSM 0
%define CONFIG_LIBIEC61883 0
%define CONFIG_LIBILBC 0
%define CONFIG_LIBMODPLUG 0
%define CONFIG_LIBMP3LAME 0
%define CONFIG_LIBNUT 0
%define CONFIG_LIBOPENCORE_AMRNB 0
%define CONFIG_LIBOPENCORE_AMRWB 0
%define CONFIG_LIBOPENCV 0
%define CONFIG_LIBOPENJPEG 0
%define CONFIG_LIBOPUS 0
%define CONFIG_LIBPULSE 0
%define CONFIG_LIBQUVI 0
%define CONFIG_LIBRTMP 0
%define CONFIG_LIBSCHROEDINGER 0
%define CONFIG_LIBSHINE 0
%define CONFIG_LIBSOXR 0
%define CONFIG_LIBSPEEX 0
%define CONFIG_LIBSTAGEFRIGHT_H264 0
%define CONFIG_LIBTHEORA 0
%define CONFIG_LIBTWOLAME 0
%define CONFIG_LIBUTVIDEO 0
%define CONFIG_LIBV4L2 0
%define CONFIG_LIBVIDSTAB 0
%define CONFIG_LIBVO_AACENC 0
%define CONFIG_LIBVO_AMRWBENC 0
%define CONFIG_LIBVORBIS 0
%define CONFIG_LIBVPX 0
%define CONFIG_LIBX264 0
%define CONFIG_LIBXAVS 0
%define CONFIG_LIBXVID 0
%define CONFIG_OPENAL 0
%define CONFIG_OPENCL 0
%define CONFIG_OPENSSL 0
%define CONFIG_X11GRAB 0
%define CONFIG_ZLIB 0
%define CONFIG_DXVA2 0
%define CONFIG_VAAPI 0
%define CONFIG_VDA 0
%define CONFIG_VDPAU 0
%define CONFIG_AVCODEC 1
%define CONFIG_AVDEVICE 0
%define CONFIG_AVFILTER 0
%define CONFIG_AVFORMAT 1
%define CONFIG_AVRESAMPLE 0
%define CONFIG_AVUTIL 1
%define CONFIG_POSTPROC 0
%define CONFIG_SWRESAMPLE 0
%define CONFIG_SWSCALE 0
%define CONFIG_FFPLAY 0
%define CONFIG_FFPROBE 0
%define CONFIG_FFSERVER 0
%define CONFIG_FFMPEG 0
%define CONFIG_DCT 0
%define CONFIG_DWT 0
%define CONFIG_ERROR_RESILIENCE 0
%define CONFIG_FAST_UNALIGNED 1
%define CONFIG_FFT 1
%define CONFIG_FTRAPV 0
%define CONFIG_GPL 0
%define CONFIG_GRAY 0
%define CONFIG_HARDCODED_TABLES 0
%define CONFIG_INCOMPATIBLE_FORK_ABI 0
%define CONFIG_LSP 0
%define CONFIG_LZO 0
%define CONFIG_MDCT 1
%define CONFIG_MEMALIGN_HACK 0
%define CONFIG_MEMORY_POISONING 0
%define CONFIG_NETWORK 0
%define CONFIG_NONFREE 0
%define CONFIG_PIC 0
%define CONFIG_RDFT 1
%define CONFIG_RUNTIME_CPUDETECT 1
%define CONFIG_SAFE_BITSTREAM_READER 1
%define CONFIG_SHARED 1
%define CONFIG_SMALL 0
%define CONFIG_SRAM 0
%define CONFIG_STATIC 0
%define CONFIG_SWSCALE_ALPHA 1
%define CONFIG_THUMB 0
%define CONFIG_VERSION3 0
%define CONFIG_XMM_CLOBBER_TEST 0
%define CONFIG_AANDCTTABLES 0
%define CONFIG_AC3DSP 0
%define CONFIG_AUDIO_FRAME_QUEUE 0
%define CONFIG_DSPUTIL 0
%define CONFIG_FRAME_THREAD_ENCODER 0
%define CONFIG_GCRYPT 0
%define CONFIG_GOLOMB 1
%define CONFIG_GPLV3 0
%define CONFIG_H264CHROMA 0
%define CONFIG_H264DSP 0
%define CONFIG_H264PRED 1
%define CONFIG_H264QPEL 0
%define CONFIG_HPELDSP 1
%define CONFIG_HUFFMAN 0
%define CONFIG_LGPLV3 0
%define CONFIG_LPC 0
%define CONFIG_MPEGAUDIO 0
%define CONFIG_MPEGAUDIODSP 0
%define CONFIG_MPEGVIDEO 0
%define CONFIG_MPEGVIDEOENC 0
%define CONFIG_NETTLE 0
%define CONFIG_RANGECODER 0
%define CONFIG_RTPDEC 0
%define CONFIG_RTPENC_CHAIN 0
%define CONFIG_SINEWIN 0
%define CONFIG_VIDEODSP 1
%define CONFIG_VP3DSP 1
%define CONFIG_AAC_ADTSTOASC_BSF 0
%define CONFIG_CHOMP_BSF 0
%define CONFIG_DUMP_EXTRADATA_BSF 0
%define CONFIG_H264_MP4TOANNEXB_BSF 0
%define CONFIG_IMX_DUMP_HEADER_BSF 0
%define CONFIG_MJPEG2JPEG_BSF 0
%define CONFIG_MJPEGA_DUMP_HEADER_BSF 0
%define CONFIG_MP3_HEADER_COMPRESS_BSF 0
%define CONFIG_MP3_HEADER_DECOMPRESS_BSF 0
%define CONFIG_MOV2TEXTSUB_BSF 0
%define CONFIG_NOISE_BSF 0
%define CONFIG_REMOVE_EXTRADATA_BSF 0
%define CONFIG_TEXT2MOVSUB_BSF 0
%define CONFIG_AASC_DECODER 0
%define CONFIG_AMV_DECODER 0
%define CONFIG_ANM_DECODER 0
%define CONFIG_ANSI_DECODER 0
%define CONFIG_ASV1_DECODER 0
%define CONFIG_ASV2_DECODER 0
%define CONFIG_AURA_DECODER 0
%define CONFIG_AURA2_DECODER 0
%define CONFIG_AVRP_DECODER 0
%define CONFIG_AVRN_DECODER 0
%define CONFIG_AVS_DECODER 0
%define CONFIG_AVUI_DECODER 0
%define CONFIG_AYUV_DECODER 0
%define CONFIG_BETHSOFTVID_DECODER 0
%define CONFIG_BFI_DECODER 0
%define CONFIG_BINK_DECODER 0
%define CONFIG_BMP_DECODER 0
%define CONFIG_BMV_VIDEO_DECODER 0
%define CONFIG_BRENDER_PIX_DECODER 0
%define CONFIG_C93_DECODER 0
%define CONFIG_CAVS_DECODER 0
%define CONFIG_CDGRAPHICS_DECODER 0
%define CONFIG_CDXL_DECODER 0
%define CONFIG_CINEPAK_DECODER 0
%define CONFIG_CLJR_DECODER 0
%define CONFIG_CLLC_DECODER 0
%define CONFIG_COMFORTNOISE_DECODER 0
%define CONFIG_CPIA_DECODER 0
%define CONFIG_CSCD_DECODER 0
%define CONFIG_CYUV_DECODER 0
%define CONFIG_DFA_DECODER 0
%define CONFIG_DIRAC_DECODER 0
%define CONFIG_DNXHD_DECODER 0
%define CONFIG_DPX_DECODER 0
%define CONFIG_DSICINVIDEO_DECODER 0
%define CONFIG_DVVIDEO_DECODER 0
%define CONFIG_DXA_DECODER 0
%define CONFIG_DXTORY_DECODER 0
%define CONFIG_EACMV_DECODER 0
%define CONFIG_EAMAD_DECODER 0
%define CONFIG_EATGQ_DECODER 0
%define CONFIG_EATGV_DECODER 0
%define CONFIG_EATQI_DECODER 0
%define CONFIG_EIGHTBPS_DECODER 0
%define CONFIG_EIGHTSVX_EXP_DECODER 0
%define CONFIG_EIGHTSVX_FIB_DECODER 0
%define CONFIG_ESCAPE124_DECODER 0
%define CONFIG_ESCAPE130_DECODER 0
%define CONFIG_EXR_DECODER 0
%define CONFIG_FFV1_DECODER 0
%define CONFIG_FFVHUFF_DECODER 0
%define CONFIG_FLASHSV_DECODER 0
%define CONFIG_FLASHSV2_DECODER 0
%define CONFIG_FLIC_DECODER 0
%define CONFIG_FLV_DECODER 0
%define CONFIG_FOURXM_DECODER 0
%define CONFIG_FRAPS_DECODER 0
%define CONFIG_FRWU_DECODER 0
%define CONFIG_GIF_DECODER 0
%define CONFIG_H261_DECODER 0
%define CONFIG_H263_DECODER 0
%define CONFIG_H263I_DECODER 0
%define CONFIG_H263P_DECODER 0
%define CONFIG_H264_DECODER 0
%define CONFIG_H264_CRYSTALHD_DECODER 0
%define CONFIG_H264_VDA_DECODER 0
%define CONFIG_H264_VDPAU_DECODER 0
%define CONFIG_HUFFYUV_DECODER 0
%define CONFIG_IDCIN_DECODER 0
%define CONFIG_IFF_BYTERUN1_DECODER 0
%define CONFIG_IFF_ILBM_DECODER 0
%define CONFIG_INDEO2_DECODER 0
%define CONFIG_INDEO3_DECODER 0
%define CONFIG_INDEO4_DECODER 0
%define CONFIG_INDEO5_DECODER 0
%define CONFIG_INTERPLAY_VIDEO_DECODER 0
%define CONFIG_J2K_DECODER 0
%define CONFIG_JPEG2000_DECODER 0
%define CONFIG_JPEGLS_DECODER 0
%define CONFIG_JV_DECODER 0
%define CONFIG_KGV1_DECODER 0
%define CONFIG_KMVC_DECODER 0
%define CONFIG_LAGARITH_DECODER 0
%define CONFIG_LOCO_DECODER 0
%define CONFIG_MDEC_DECODER 0
%define CONFIG_MIMIC_DECODER 0
%define CONFIG_MJPEG_DECODER 0
%define CONFIG_MJPEGB_DECODER 0
%define CONFIG_MMVIDEO_DECODER 0
%define CONFIG_MOTIONPIXELS_DECODER 0
%define CONFIG_MPEG_XVMC_DECODER 0
%define CONFIG_MPEG1VIDEO_DECODER 0
%define CONFIG_MPEG2VIDEO_DECODER 0
%define CONFIG_MPEG4_DECODER 0
%define CONFIG_MPEG4_CRYSTALHD_DECODER 0
%define CONFIG_MPEG4_VDPAU_DECODER 0
%define CONFIG_MPEGVIDEO_DECODER 0
%define CONFIG_MPEG_VDPAU_DECODER 0
%define CONFIG_MPEG1_VDPAU_DECODER 0
%define CONFIG_MPEG2_CRYSTALHD_DECODER 0
%define CONFIG_MSA1_DECODER 0
%define CONFIG_MSMPEG4_CRYSTALHD_DECODER 0
%define CONFIG_MSMPEG4V1_DECODER 0
%define CONFIG_MSMPEG4V2_DECODER 0
%define CONFIG_MSMPEG4V3_DECODER 0
%define CONFIG_MSRLE_DECODER 0
%define CONFIG_MSS1_DECODER 0
%define CONFIG_MSS2_DECODER 0
%define CONFIG_MSVIDEO1_DECODER 0
%define CONFIG_MSZH_DECODER 0
%define CONFIG_MTS2_DECODER 0
%define CONFIG_MVC1_DECODER 0
%define CONFIG_MVC2_DECODER 0
%define CONFIG_MXPEG_DECODER 0
%define CONFIG_NUV_DECODER 0
%define CONFIG_PAF_VIDEO_DECODER 0
%define CONFIG_PAM_DECODER 0
%define CONFIG_PBM_DECODER 0
%define CONFIG_PCX_DECODER 0
%define CONFIG_PGM_DECODER 0
%define CONFIG_PGMYUV_DECODER 0
%define CONFIG_PICTOR_DECODER 0
%define CONFIG_PNG_DECODER 0
%define CONFIG_PPM_DECODER 0
%define CONFIG_PRORES_DECODER 0
%define CONFIG_PRORES_LGPL_DECODER 0
%define CONFIG_PTX_DECODER 0
%define CONFIG_QDRAW_DECODER 0
%define CONFIG_QPEG_DECODER 0
%define CONFIG_QTRLE_DECODER 0
%define CONFIG_R10K_DECODER 0
%define CONFIG_R210_DECODER 0
%define CONFIG_RAWVIDEO_DECODER 0
%define CONFIG_RL2_DECODER 0
%define CONFIG_ROQ_DECODER 0
%define CONFIG_RPZA_DECODER 0
%define CONFIG_RV10_DECODER 0
%define CONFIG_RV20_DECODER 0
%define CONFIG_RV30_DECODER 0
%define CONFIG_RV40_DECODER 0
%define CONFIG_S302M_DECODER 0
%define CONFIG_SANM_DECODER 0
%define CONFIG_SGI_DECODER 0
%define CONFIG_SGIRLE_DECODER 0
%define CONFIG_SMACKER_DECODER 0
%define CONFIG_SMC_DECODER 0
%define CONFIG_SNOW_DECODER 0
%define CONFIG_SP5X_DECODER 0
%define CONFIG_SUNRAST_DECODER 0
%define CONFIG_SVQ1_DECODER 0
%define CONFIG_SVQ3_DECODER 0
%define CONFIG_TARGA_DECODER 0
%define CONFIG_TARGA_Y216_DECODER 0
%define CONFIG_THEORA_DECODER 1
%define CONFIG_THP_DECODER 0
%define CONFIG_TIERTEXSEQVIDEO_DECODER 0
%define CONFIG_TIFF_DECODER 0
%define CONFIG_TMV_DECODER 0
%define CONFIG_TRUEMOTION1_DECODER 0
%define CONFIG_TRUEMOTION2_DECODER 0
%define CONFIG_TSCC_DECODER 0
%define CONFIG_TSCC2_DECODER 0
%define CONFIG_TXD_DECODER 0
%define CONFIG_ULTI_DECODER 0
%define CONFIG_UTVIDEO_DECODER 0
%define CONFIG_V210_DECODER 0
%define CONFIG_V210X_DECODER 0
%define CONFIG_V308_DECODER 0
%define CONFIG_V408_DECODER 0
%define CONFIG_V410_DECODER 0
%define CONFIG_VB_DECODER 0
%define CONFIG_VBLE_DECODER 0
%define CONFIG_VC1_DECODER 0
%define CONFIG_VC1_CRYSTALHD_DECODER 0
%define CONFIG_VC1_VDPAU_DECODER 0
%define CONFIG_VC1IMAGE_DECODER 0
%define CONFIG_VCR1_DECODER 0
%define CONFIG_VMDVIDEO_DECODER 0
%define CONFIG_VMNC_DECODER 0
%define CONFIG_VP3_DECODER 1
%define CONFIG_VP5_DECODER 0
%define CONFIG_VP6_DECODER 0
%define CONFIG_VP6A_DECODER 0
%define CONFIG_VP6F_DECODER 0
%define CONFIG_VP8_DECODER 1
%define CONFIG_VQA_DECODER 0
%define CONFIG_WEBP_DECODER 0
%define CONFIG_WMV1_DECODER 0
%define CONFIG_WMV2_DECODER 0
%define CONFIG_WMV3_DECODER 0
%define CONFIG_WMV3_CRYSTALHD_DECODER 0
%define CONFIG_WMV3_VDPAU_DECODER 0
%define CONFIG_WMV3IMAGE_DECODER 0
%define CONFIG_WNV1_DECODER 0
%define CONFIG_XAN_WC3_DECODER 0
%define CONFIG_XAN_WC4_DECODER 0
%define CONFIG_XBM_DECODER 0
%define CONFIG_XFACE_DECODER 0
%define CONFIG_XL_DECODER 0
%define CONFIG_XWD_DECODER 0
%define CONFIG_Y41P_DECODER 0
%define CONFIG_YOP_DECODER 0
%define CONFIG_YUV4_DECODER 0
%define CONFIG_ZERO12V_DECODER 0
%define CONFIG_ZEROCODEC_DECODER 0
%define CONFIG_ZLIB_DECODER 0
%define CONFIG_ZMBV_DECODER 0
%define CONFIG_AAC_DECODER 0
%define CONFIG_AAC_LATM_DECODER 0
%define CONFIG_AC3_DECODER 0
%define CONFIG_ALAC_DECODER 0
%define CONFIG_ALS_DECODER 0
%define CONFIG_AMRNB_DECODER 0
%define CONFIG_AMRWB_DECODER 0
%define CONFIG_APE_DECODER 0
%define CONFIG_ATRAC1_DECODER 0
%define CONFIG_ATRAC3_DECODER 0
%define CONFIG_BINKAUDIO_DCT_DECODER 0
%define CONFIG_BINKAUDIO_RDFT_DECODER 0
%define CONFIG_BMV_AUDIO_DECODER 0
%define CONFIG_COOK_DECODER 0
%define CONFIG_DCA_DECODER 0
%define CONFIG_DSICINAUDIO_DECODER 0
%define CONFIG_EAC3_DECODER 0
%define CONFIG_EVRC_DECODER 0
%define CONFIG_FFWAVESYNTH_DECODER 0
%define CONFIG_FLAC_DECODER 0
%define CONFIG_G723_1_DECODER 0
%define CONFIG_G729_DECODER 0
%define CONFIG_GSM_DECODER 0
%define CONFIG_GSM_MS_DECODER 0
%define CONFIG_IAC_DECODER 0
%define CONFIG_IMC_DECODER 0
%define CONFIG_MACE3_DECODER 0
%define CONFIG_MACE6_DECODER 0
%define CONFIG_MLP_DECODER 0
%define CONFIG_MP1_DECODER 0
%define CONFIG_MP1FLOAT_DECODER 0
%define CONFIG_MP2_DECODER 0
%define CONFIG_MP2FLOAT_DECODER 0
%define CONFIG_MP3_DECODER 0
%define CONFIG_MP3FLOAT_DECODER 0
%define CONFIG_MP3ADU_DECODER 0
%define CONFIG_MP3ADUFLOAT_DECODER 0
%define CONFIG_MP3ON4_DECODER 0
%define CONFIG_MP3ON4FLOAT_DECODER 0
%define CONFIG_MPC7_DECODER 0
%define CONFIG_MPC8_DECODER 0
%define CONFIG_NELLYMOSER_DECODER 0
%define CONFIG_PAF_AUDIO_DECODER 0
%define CONFIG_QCELP_DECODER 0
%define CONFIG_QDM2_DECODER 0
%define CONFIG_RA_144_DECODER 0
%define CONFIG_RA_288_DECODER 0
%define CONFIG_RALF_DECODER 0
%define CONFIG_SHORTEN_DECODER 0
%define CONFIG_SIPR_DECODER 0
%define CONFIG_SMACKAUD_DECODER 0
%define CONFIG_SONIC_DECODER 0
%define CONFIG_TAK_DECODER 0
%define CONFIG_TRUEHD_DECODER 0
%define CONFIG_TRUESPEECH_DECODER 0
%define CONFIG_TTA_DECODER 0
%define CONFIG_TWINVQ_DECODER 0
%define CONFIG_VMDAUDIO_DECODER 0
%define CONFIG_VORBIS_DECODER 1
%define CONFIG_WAVPACK_DECODER 0
%define CONFIG_WMALOSSLESS_DECODER 0
%define CONFIG_WMAPRO_DECODER 0
%define CONFIG_WMAV1_DECODER 0
%define CONFIG_WMAV2_DECODER 0
%define CONFIG_WMAVOICE_DECODER 0
%define CONFIG_WS_SND1_DECODER 0
%define CONFIG_PCM_ALAW_DECODER 0
%define CONFIG_PCM_BLURAY_DECODER 0
%define CONFIG_PCM_DVD_DECODER 0
%define CONFIG_PCM_F32BE_DECODER 0
%define CONFIG_PCM_F32LE_DECODER 1
%define CONFIG_PCM_F64BE_DECODER 0
%define CONFIG_PCM_F64LE_DECODER 0
%define CONFIG_PCM_LXF_DECODER 0
%define CONFIG_PCM_MULAW_DECODER 0
%define CONFIG_PCM_S8_DECODER 0
%define CONFIG_PCM_S8_PLANAR_DECODER 0
%define CONFIG_PCM_S16BE_DECODER 1
%define CONFIG_PCM_S16BE_PLANAR_DECODER 0
%define CONFIG_PCM_S16LE_DECODER 1
%define CONFIG_PCM_S16LE_PLANAR_DECODER 0
%define CONFIG_PCM_S24BE_DECODER 1
%define CONFIG_PCM_S24DAUD_DECODER 0
%define CONFIG_PCM_S24LE_DECODER 1
%define CONFIG_PCM_S24LE_PLANAR_DECODER 0
%define CONFIG_PCM_S32BE_DECODER 0
%define CONFIG_PCM_S32LE_DECODER 0
%define CONFIG_PCM_S32LE_PLANAR_DECODER 0
%define CONFIG_PCM_U8_DECODER 1
%define CONFIG_PCM_U16BE_DECODER 0
%define CONFIG_PCM_U16LE_DECODER 0
%define CONFIG_PCM_U24BE_DECODER 0
%define CONFIG_PCM_U24LE_DECODER 0
%define CONFIG_PCM_U32BE_DECODER 0
%define CONFIG_PCM_U32LE_DECODER 0
%define CONFIG_PCM_ZORK_DECODER 0
%define CONFIG_INTERPLAY_DPCM_DECODER 0
%define CONFIG_ROQ_DPCM_DECODER 0
%define CONFIG_SOL_DPCM_DECODER 0
%define CONFIG_XAN_DPCM_DECODER 0
%define CONFIG_ADPCM_4XM_DECODER 0
%define CONFIG_ADPCM_ADX_DECODER 0
%define CONFIG_ADPCM_AFC_DECODER 0
%define CONFIG_ADPCM_CT_DECODER 0
%define CONFIG_ADPCM_EA_DECODER 0
%define CONFIG_ADPCM_EA_MAXIS_XA_DECODER 0
%define CONFIG_ADPCM_EA_R1_DECODER 0
%define CONFIG_ADPCM_EA_R2_DECODER 0
%define CONFIG_ADPCM_EA_R3_DECODER 0
%define CONFIG_ADPCM_EA_XAS_DECODER 0
%define CONFIG_ADPCM_G722_DECODER 0
%define CONFIG_ADPCM_G726_DECODER 0
%define CONFIG_ADPCM_IMA_AMV_DECODER 0
%define CONFIG_ADPCM_IMA_APC_DECODER 0
%define CONFIG_ADPCM_IMA_DK3_DECODER 0
%define CONFIG_ADPCM_IMA_DK4_DECODER 0
%define CONFIG_ADPCM_IMA_EA_EACS_DECODER 0
%define CONFIG_ADPCM_IMA_EA_SEAD_DECODER 0
%define CONFIG_ADPCM_IMA_ISS_DECODER 0
%define CONFIG_ADPCM_IMA_OKI_DECODER 0
%define CONFIG_ADPCM_IMA_QT_DECODER 0
%define CONFIG_ADPCM_IMA_SMJPEG_DECODER 0
%define CONFIG_ADPCM_IMA_WAV_DECODER 0
%define CONFIG_ADPCM_IMA_WS_DECODER 0
%define CONFIG_ADPCM_MS_DECODER 0
%define CONFIG_ADPCM_SBPRO_2_DECODER 0
%define CONFIG_ADPCM_SBPRO_3_DECODER 0
%define CONFIG_ADPCM_SBPRO_4_DECODER 0
%define CONFIG_ADPCM_SWF_DECODER 0
%define CONFIG_ADPCM_THP_DECODER 0
%define CONFIG_ADPCM_XA_DECODER 0
%define CONFIG_ADPCM_YAMAHA_DECODER 0
%define CONFIG_VIMA_DECODER 0
%define CONFIG_SSA_DECODER 0
%define CONFIG_ASS_DECODER 0
%define CONFIG_DVBSUB_DECODER 0
%define CONFIG_DVDSUB_DECODER 0
%define CONFIG_JACOSUB_DECODER 0
%define CONFIG_MICRODVD_DECODER 0
%define CONFIG_MOVTEXT_DECODER 0
%define CONFIG_MPL2_DECODER 0
%define CONFIG_PGSSUB_DECODER 0
%define CONFIG_PJS_DECODER 0
%define CONFIG_REALTEXT_DECODER 0
%define CONFIG_SAMI_DECODER 0
%define CONFIG_SRT_DECODER 0
%define CONFIG_SUBRIP_DECODER 0
%define CONFIG_SUBVIEWER_DECODER 0
%define CONFIG_SUBVIEWER1_DECODER 0
%define CONFIG_TEXT_DECODER 0
%define CONFIG_VPLAYER_DECODER 0
%define CONFIG_WEBVTT_DECODER 0
%define CONFIG_XSUB_DECODER 0
%define CONFIG_LIBCELT_DECODER 0
%define CONFIG_LIBGSM_DECODER 0
%define CONFIG_LIBGSM_MS_DECODER 0
%define CONFIG_LIBILBC_DECODER 0
%define CONFIG_LIBOPENCORE_AMRNB_DECODER 0
%define CONFIG_LIBOPENCORE_AMRWB_DECODER 0
%define CONFIG_LIBOPENJPEG_DECODER 0
%define CONFIG_LIBOPUS_DECODER 0
%define CONFIG_LIBSCHROEDINGER_DECODER 0
%define CONFIG_LIBSPEEX_DECODER 0
%define CONFIG_LIBSTAGEFRIGHT_H264_DECODER 0
%define CONFIG_LIBUTVIDEO_DECODER 0
%define CONFIG_LIBVORBIS_DECODER 0
%define CONFIG_LIBVPX_VP8_DECODER 0
%define CONFIG_LIBVPX_VP9_DECODER 0
%define CONFIG_BINTEXT_DECODER 0
%define CONFIG_XBIN_DECODER 0
%define CONFIG_IDF_DECODER 0
%define CONFIG_AAC_DEMUXER 0
%define CONFIG_AC3_DEMUXER 0
%define CONFIG_ACT_DEMUXER 0
%define CONFIG_ADF_DEMUXER 0
%define CONFIG_ADX_DEMUXER 0
%define CONFIG_AEA_DEMUXER 0
%define CONFIG_AFC_DEMUXER 0
%define CONFIG_AIFF_DEMUXER 0
%define CONFIG_AMR_DEMUXER 0
%define CONFIG_ANM_DEMUXER 0
%define CONFIG_APC_DEMUXER 0
%define CONFIG_APE_DEMUXER 0
%define CONFIG_AQTITLE_DEMUXER 0
%define CONFIG_ASF_DEMUXER 0
%define CONFIG_ASS_DEMUXER 0
%define CONFIG_AST_DEMUXER 0
%define CONFIG_AU_DEMUXER 0
%define CONFIG_AVI_DEMUXER 0
%define CONFIG_AVISYNTH_DEMUXER 0
%define CONFIG_AVR_DEMUXER 0
%define CONFIG_AVS_DEMUXER 0
%define CONFIG_BETHSOFTVID_DEMUXER 0
%define CONFIG_BFI_DEMUXER 0
%define CONFIG_BINTEXT_DEMUXER 0
%define CONFIG_BINK_DEMUXER 0
%define CONFIG_BIT_DEMUXER 0
%define CONFIG_BMV_DEMUXER 0
%define CONFIG_BRSTM_DEMUXER 0
%define CONFIG_C93_DEMUXER 0
%define CONFIG_CAF_DEMUXER 0
%define CONFIG_CAVSVIDEO_DEMUXER 0
%define CONFIG_CDG_DEMUXER 0
%define CONFIG_CDXL_DEMUXER 0
%define CONFIG_CONCAT_DEMUXER 0
%define CONFIG_DAUD_DEMUXER 0
%define CONFIG_DFA_DEMUXER 0
%define CONFIG_DIRAC_DEMUXER 0
%define CONFIG_DNXHD_DEMUXER 0
%define CONFIG_DSICIN_DEMUXER 0
%define CONFIG_DTS_DEMUXER 0
%define CONFIG_DTSHD_DEMUXER 0
%define CONFIG_DV_DEMUXER 0
%define CONFIG_DXA_DEMUXER 0
%define CONFIG_EA_DEMUXER 0
%define CONFIG_EA_CDATA_DEMUXER 0
%define CONFIG_EAC3_DEMUXER 0
%define CONFIG_EPAF_DEMUXER 0
%define CONFIG_FFM_DEMUXER 0
%define CONFIG_FFMETADATA_DEMUXER 0
%define CONFIG_FILMSTRIP_DEMUXER 0
%define CONFIG_FLAC_DEMUXER 0
%define CONFIG_FLIC_DEMUXER 0
%define CONFIG_FLV_DEMUXER 0
%define CONFIG_FOURXM_DEMUXER 0
%define CONFIG_FRM_DEMUXER 0
%define CONFIG_G722_DEMUXER 0
%define CONFIG_G723_1_DEMUXER 0
%define CONFIG_G729_DEMUXER 0
%define CONFIG_GIF_DEMUXER 0
%define CONFIG_GSM_DEMUXER 0
%define CONFIG_GXF_DEMUXER 0
%define CONFIG_H261_DEMUXER 0
%define CONFIG_H263_DEMUXER 0
%define CONFIG_H264_DEMUXER 0
%define CONFIG_HLS_DEMUXER 0
%define CONFIG_ICO_DEMUXER 0
%define CONFIG_IDCIN_DEMUXER 0
%define CONFIG_IDF_DEMUXER 0
%define CONFIG_IFF_DEMUXER 0
%define CONFIG_ILBC_DEMUXER 0
%define CONFIG_IMAGE2_DEMUXER 0
%define CONFIG_IMAGE2PIPE_DEMUXER 0
%define CONFIG_INGENIENT_DEMUXER 0
%define CONFIG_IPMOVIE_DEMUXER 0
%define CONFIG_IRCAM_DEMUXER 0
%define CONFIG_ISS_DEMUXER 0
%define CONFIG_IV8_DEMUXER 0
%define CONFIG_IVF_DEMUXER 0
%define CONFIG_JACOSUB_DEMUXER 0
%define CONFIG_JV_DEMUXER 0
%define CONFIG_LATM_DEMUXER 0
%define CONFIG_LMLM4_DEMUXER 0
%define CONFIG_LOAS_DEMUXER 0
%define CONFIG_LVF_DEMUXER 0
%define CONFIG_LXF_DEMUXER 0
%define CONFIG_M4V_DEMUXER 0
%define CONFIG_MATROSKA_DEMUXER 1
%define CONFIG_MGSTS_DEMUXER 0
%define CONFIG_MICRODVD_DEMUXER 0
%define CONFIG_MJPEG_DEMUXER 0
%define CONFIG_MLP_DEMUXER 0
%define CONFIG_MM_DEMUXER 0
%define CONFIG_MMF_DEMUXER 0
%define CONFIG_MOV_DEMUXER 0
%define CONFIG_MP3_DEMUXER 0
%define CONFIG_MPC_DEMUXER 0
%define CONFIG_MPC8_DEMUXER 0
%define CONFIG_MPEGPS_DEMUXER 0
%define CONFIG_MPEGTS_DEMUXER 0
%define CONFIG_MPEGTSRAW_DEMUXER 0
%define CONFIG_MPEGVIDEO_DEMUXER 0
%define CONFIG_MPL2_DEMUXER 0
%define CONFIG_MPSUB_DEMUXER 0
%define CONFIG_MSNWC_TCP_DEMUXER 0
%define CONFIG_MTV_DEMUXER 0
%define CONFIG_MV_DEMUXER 0
%define CONFIG_MVI_DEMUXER 0
%define CONFIG_MXF_DEMUXER 0
%define CONFIG_MXG_DEMUXER 0
%define CONFIG_NC_DEMUXER 0
%define CONFIG_NISTSPHERE_DEMUXER 0
%define CONFIG_NSV_DEMUXER 0
%define CONFIG_NUT_DEMUXER 0
%define CONFIG_NUV_DEMUXER 0
%define CONFIG_OGG_DEMUXER 1
%define CONFIG_OMA_DEMUXER 0
%define CONFIG_PAF_DEMUXER 0
%define CONFIG_PCM_ALAW_DEMUXER 0
%define CONFIG_PCM_MULAW_DEMUXER 0
%define CONFIG_PCM_F64BE_DEMUXER 0
%define CONFIG_PCM_F64LE_DEMUXER 0
%define CONFIG_PCM_F32BE_DEMUXER 0
%define CONFIG_PCM_F32LE_DEMUXER 0
%define CONFIG_PCM_S32BE_DEMUXER 0
%define CONFIG_PCM_S32LE_DEMUXER 0
%define CONFIG_PCM_S24BE_DEMUXER 0
%define CONFIG_PCM_S24LE_DEMUXER 0
%define CONFIG_PCM_S16BE_DEMUXER 0
%define CONFIG_PCM_S16LE_DEMUXER 0
%define CONFIG_PCM_S8_DEMUXER 0
%define CONFIG_PCM_U32BE_DEMUXER 0
%define CONFIG_PCM_U32LE_DEMUXER 0
%define CONFIG_PCM_U24BE_DEMUXER 0
%define CONFIG_PCM_U24LE_DEMUXER 0
%define CONFIG_PCM_U16BE_DEMUXER 0
%define CONFIG_PCM_U16LE_DEMUXER 0
%define CONFIG_PCM_U8_DEMUXER 0
%define CONFIG_PJS_DEMUXER 0
%define CONFIG_PMP_DEMUXER 0
%define CONFIG_PVA_DEMUXER 0
%define CONFIG_PVF_DEMUXER 0
%define CONFIG_QCP_DEMUXER 0
%define CONFIG_R3D_DEMUXER 0
%define CONFIG_RAWVIDEO_DEMUXER 0
%define CONFIG_REALTEXT_DEMUXER 0
%define CONFIG_RL2_DEMUXER 0
%define CONFIG_RM_DEMUXER 0
%define CONFIG_ROQ_DEMUXER 0
%define CONFIG_RPL_DEMUXER 0
%define CONFIG_RSO_DEMUXER 0
%define CONFIG_RTP_DEMUXER 0
%define CONFIG_RTSP_DEMUXER 0
%define CONFIG_SAMI_DEMUXER 0
%define CONFIG_SAP_DEMUXER 0
%define CONFIG_SBG_DEMUXER 0
%define CONFIG_SDP_DEMUXER 0
%define CONFIG_SEGAFILM_DEMUXER 0
%define CONFIG_SHORTEN_DEMUXER 0
%define CONFIG_SIFF_DEMUXER 0
%define CONFIG_SMACKER_DEMUXER 0
%define CONFIG_SMJPEG_DEMUXER 0
%define CONFIG_SMUSH_DEMUXER 0
%define CONFIG_SOL_DEMUXER 0
%define CONFIG_SOX_DEMUXER 0
%define CONFIG_SPDIF_DEMUXER 0
%define CONFIG_SRT_DEMUXER 0
%define CONFIG_STR_DEMUXER 0
%define CONFIG_SUBVIEWER1_DEMUXER 0
%define CONFIG_SUBVIEWER_DEMUXER 0
%define CONFIG_SWF_DEMUXER 0
%define CONFIG_TAK_DEMUXER 0
%define CONFIG_TEDCAPTIONS_DEMUXER 0
%define CONFIG_THP_DEMUXER 0
%define CONFIG_TIERTEXSEQ_DEMUXER 0
%define CONFIG_TMV_DEMUXER 0
%define CONFIG_TRUEHD_DEMUXER 0
%define CONFIG_TTA_DEMUXER 0
%define CONFIG_TXD_DEMUXER 0
%define CONFIG_TTY_DEMUXER 0
%define CONFIG_VC1_DEMUXER 0
%define CONFIG_VC1T_DEMUXER 0
%define CONFIG_VIVO_DEMUXER 0
%define CONFIG_VMD_DEMUXER 0
%define CONFIG_VOBSUB_DEMUXER 0
%define CONFIG_VOC_DEMUXER 0
%define CONFIG_VPLAYER_DEMUXER 0
%define CONFIG_VQF_DEMUXER 0
%define CONFIG_W64_DEMUXER 0
%define CONFIG_WAV_DEMUXER 1
%define CONFIG_WC3_DEMUXER 0
%define CONFIG_WEBVTT_DEMUXER 0
%define CONFIG_WSAUD_DEMUXER 0
%define CONFIG_WSVQA_DEMUXER 0
%define CONFIG_WTV_DEMUXER 0
%define CONFIG_WV_DEMUXER 0
%define CONFIG_XA_DEMUXER 0
%define CONFIG_XBIN_DEMUXER 0
%define CONFIG_XMV_DEMUXER 0
%define CONFIG_XWMA_DEMUXER 0
%define CONFIG_YOP_DEMUXER 0
%define CONFIG_YUV4MPEGPIPE_DEMUXER 0
%define CONFIG_LIBMODPLUG_DEMUXER 0
%define CONFIG_LIBNUT_DEMUXER 0
%define CONFIG_LIBQUVI_DEMUXER 0
%define CONFIG_A64MULTI_ENCODER 0
%define CONFIG_A64MULTI5_ENCODER 0
%define CONFIG_AMV_ENCODER 0
%define CONFIG_ASV1_ENCODER 0
%define CONFIG_ASV2_ENCODER 0
%define CONFIG_AVRP_ENCODER 0
%define CONFIG_AVUI_ENCODER 0
%define CONFIG_AYUV_ENCODER 0
%define CONFIG_BMP_ENCODER 0
%define CONFIG_CLJR_ENCODER 0
%define CONFIG_COMFORTNOISE_ENCODER 0
%define CONFIG_DNXHD_ENCODER 0
%define CONFIG_DPX_ENCODER 0
%define CONFIG_DVVIDEO_ENCODER 0
%define CONFIG_FFV1_ENCODER 0
%define CONFIG_FFVHUFF_ENCODER 0
%define CONFIG_FLASHSV_ENCODER 0
%define CONFIG_FLASHSV2_ENCODER 0
%define CONFIG_FLV_ENCODER 0
%define CONFIG_GIF_ENCODER 0
%define CONFIG_H261_ENCODER 0
%define CONFIG_H263_ENCODER 0
%define CONFIG_H263P_ENCODER 0
%define CONFIG_HUFFYUV_ENCODER 0
%define CONFIG_J2K_ENCODER 0
%define CONFIG_JPEGLS_ENCODER 0
%define CONFIG_LJPEG_ENCODER 0
%define CONFIG_MJPEG_ENCODER 0
%define CONFIG_MPEG1VIDEO_ENCODER 0
%define CONFIG_MPEG2VIDEO_ENCODER 0
%define CONFIG_MPEG4_ENCODER 0
%define CONFIG_MSMPEG4V2_ENCODER 0
%define CONFIG_MSMPEG4V3_ENCODER 0
%define CONFIG_MSVIDEO1_ENCODER 0
%define CONFIG_PAM_ENCODER 0
%define CONFIG_PBM_ENCODER 0
%define CONFIG_PCX_ENCODER 0
%define CONFIG_PGM_ENCODER 0
%define CONFIG_PGMYUV_ENCODER 0
%define CONFIG_PNG_ENCODER 0
%define CONFIG_PPM_ENCODER 0
%define CONFIG_PRORES_ENCODER 0
%define CONFIG_PRORES_AW_ENCODER 0
%define CONFIG_PRORES_KS_ENCODER 0
%define CONFIG_QTRLE_ENCODER 0
%define CONFIG_R10K_ENCODER 0
%define CONFIG_R210_ENCODER 0
%define CONFIG_RAWVIDEO_ENCODER 0
%define CONFIG_ROQ_ENCODER 0
%define CONFIG_RV10_ENCODER 0
%define CONFIG_RV20_ENCODER 0
%define CONFIG_SGI_ENCODER 0
%define CONFIG_SNOW_ENCODER 0
%define CONFIG_SUNRAST_ENCODER 0
%define CONFIG_SVQ1_ENCODER 0
%define CONFIG_TARGA_ENCODER 0
%define CONFIG_TIFF_ENCODER 0
%define CONFIG_UTVIDEO_ENCODER 0
%define CONFIG_V210_ENCODER 0
%define CONFIG_V308_ENCODER 0
%define CONFIG_V408_ENCODER 0
%define CONFIG_V410_ENCODER 0
%define CONFIG_WMV1_ENCODER 0
%define CONFIG_WMV2_ENCODER 0
%define CONFIG_XBM_ENCODER 0
%define CONFIG_XFACE_ENCODER 0
%define CONFIG_XWD_ENCODER 0
%define CONFIG_Y41P_ENCODER 0
%define CONFIG_YUV4_ENCODER 0
%define CONFIG_ZLIB_ENCODER 0
%define CONFIG_ZMBV_ENCODER 0
%define CONFIG_AAC_ENCODER 0
%define CONFIG_AC3_ENCODER 0
%define CONFIG_AC3_FIXED_ENCODER 0
%define CONFIG_ALAC_ENCODER 0
%define CONFIG_DCA_ENCODER 0
%define CONFIG_EAC3_ENCODER 0
%define CONFIG_FLAC_ENCODER 0
%define CONFIG_G723_1_ENCODER 0
%define CONFIG_MP2_ENCODER 0
%define CONFIG_NELLYMOSER_ENCODER 0
%define CONFIG_RA_144_ENCODER 0
%define CONFIG_SONIC_ENCODER 0
%define CONFIG_SONIC_LS_ENCODER 0
%define CONFIG_VORBIS_ENCODER 0
%define CONFIG_WMAV1_ENCODER 0
%define CONFIG_WMAV2_ENCODER 0
%define CONFIG_PCM_ALAW_ENCODER 0
%define CONFIG_PCM_F32BE_ENCODER 0
%define CONFIG_PCM_F32LE_ENCODER 0
%define CONFIG_PCM_F64BE_ENCODER 0
%define CONFIG_PCM_F64LE_ENCODER 0
%define CONFIG_PCM_MULAW_ENCODER 0
%define CONFIG_PCM_S8_ENCODER 0
%define CONFIG_PCM_S8_PLANAR_ENCODER 0
%define CONFIG_PCM_S16BE_ENCODER 0
%define CONFIG_PCM_S16BE_PLANAR_ENCODER 0
%define CONFIG_PCM_S16LE_ENCODER 0
%define CONFIG_PCM_S16LE_PLANAR_ENCODER 0
%define CONFIG_PCM_S24BE_ENCODER 0
%define CONFIG_PCM_S24DAUD_ENCODER 0
%define CONFIG_PCM_S24LE_ENCODER 0
%define CONFIG_PCM_S24LE_PLANAR_ENCODER 0
%define CONFIG_PCM_S32BE_ENCODER 0
%define CONFIG_PCM_S32LE_ENCODER 0
%define CONFIG_PCM_S32LE_PLANAR_ENCODER 0
%define CONFIG_PCM_U8_ENCODER 0
%define CONFIG_PCM_U16BE_ENCODER 0
%define CONFIG_PCM_U16LE_ENCODER 0
%define CONFIG_PCM_U24BE_ENCODER 0
%define CONFIG_PCM_U24LE_ENCODER 0
%define CONFIG_PCM_U32BE_ENCODER 0
%define CONFIG_PCM_U32LE_ENCODER 0
%define CONFIG_ROQ_DPCM_ENCODER 0
%define CONFIG_ADPCM_ADX_ENCODER 0
%define CONFIG_ADPCM_G722_ENCODER 0
%define CONFIG_ADPCM_G726_ENCODER 0
%define CONFIG_ADPCM_IMA_QT_ENCODER 0
%define CONFIG_ADPCM_IMA_WAV_ENCODER 0
%define CONFIG_ADPCM_MS_ENCODER 0
%define CONFIG_ADPCM_SWF_ENCODER 0
%define CONFIG_ADPCM_YAMAHA_ENCODER 0
%define CONFIG_SSA_ENCODER 0
%define CONFIG_ASS_ENCODER 0
%define CONFIG_DVBSUB_ENCODER 0
%define CONFIG_DVDSUB_ENCODER 0
%define CONFIG_MOVTEXT_ENCODER 0
%define CONFIG_SRT_ENCODER 0
%define CONFIG_SUBRIP_ENCODER 0
%define CONFIG_XSUB_ENCODER 0
%define CONFIG_LIBFAAC_ENCODER 0
%define CONFIG_LIBFDK_AAC_ENCODER 0
%define CONFIG_LIBGSM_ENCODER 0
%define CONFIG_LIBGSM_MS_ENCODER 0
%define CONFIG_LIBILBC_ENCODER 0
%define CONFIG_LIBMP3LAME_ENCODER 0
%define CONFIG_LIBOPENCORE_AMRNB_ENCODER 0
%define CONFIG_LIBOPENJPEG_ENCODER 0
%define CONFIG_LIBOPUS_ENCODER 0
%define CONFIG_LIBSCHROEDINGER_ENCODER 0
%define CONFIG_LIBSHINE_ENCODER 0
%define CONFIG_LIBSPEEX_ENCODER 0
%define CONFIG_LIBTHEORA_ENCODER 0
%define CONFIG_LIBTWOLAME_ENCODER 0
%define CONFIG_LIBUTVIDEO_ENCODER 0
%define CONFIG_LIBVO_AACENC_ENCODER 0
%define CONFIG_LIBVO_AMRWBENC_ENCODER 0
%define CONFIG_LIBVORBIS_ENCODER 0
%define CONFIG_LIBVPX_VP8_ENCODER 0
%define CONFIG_LIBVPX_VP9_ENCODER 0
%define CONFIG_LIBX264_ENCODER 0
%define CONFIG_LIBX264RGB_ENCODER 0
%define CONFIG_LIBXAVS_ENCODER 0
%define CONFIG_LIBXVID_ENCODER 0
%define CONFIG_LIBAACPLUS_ENCODER 0
%define CONFIG_ACONVERT_FILTER 0
%define CONFIG_AFADE_FILTER 0
%define CONFIG_AFORMAT_FILTER 0
%define CONFIG_AINTERLEAVE_FILTER 0
%define CONFIG_ALLPASS_FILTER 0
%define CONFIG_AMERGE_FILTER 0
%define CONFIG_AMIX_FILTER 0
%define CONFIG_ANULL_FILTER 0
%define CONFIG_APAD_FILTER 0
%define CONFIG_APERMS_FILTER 0
%define CONFIG_APHASER_FILTER 0
%define CONFIG_ARESAMPLE_FILTER 0
%define CONFIG_ASELECT_FILTER 0
%define CONFIG_ASENDCMD_FILTER 0
%define CONFIG_ASETNSAMPLES_FILTER 0
%define CONFIG_ASETPTS_FILTER 0
%define CONFIG_ASETRATE_FILTER 0
%define CONFIG_ASETTB_FILTER 0
%define CONFIG_ASHOWINFO_FILTER 0
%define CONFIG_ASPLIT_FILTER 0
%define CONFIG_ASTREAMSYNC_FILTER 0
%define CONFIG_ASYNCTS_FILTER 0
%define CONFIG_ATEMPO_FILTER 0
%define CONFIG_BANDPASS_FILTER 0
%define CONFIG_BANDREJECT_FILTER 0
%define CONFIG_BASS_FILTER 0
%define CONFIG_BIQUAD_FILTER 0
%define CONFIG_CHANNELMAP_FILTER 0
%define CONFIG_CHANNELSPLIT_FILTER 0
%define CONFIG_EARWAX_FILTER 0
%define CONFIG_EBUR128_FILTER 0
%define CONFIG_EQUALIZER_FILTER 0
%define CONFIG_HIGHPASS_FILTER 0
%define CONFIG_JOIN_FILTER 0
%define CONFIG_LOWPASS_FILTER 0
%define CONFIG_PAN_FILTER 0
%define CONFIG_RESAMPLE_FILTER 0
%define CONFIG_SILENCEDETECT_FILTER 0
%define CONFIG_TREBLE_FILTER 0
%define CONFIG_VOLUME_FILTER 0
%define CONFIG_VOLUMEDETECT_FILTER 0
%define CONFIG_AEVALSRC_FILTER 0
%define CONFIG_ANULLSRC_FILTER 0
%define CONFIG_FLITE_FILTER 0
%define CONFIG_SINE_FILTER 0
%define CONFIG_ANULLSINK_FILTER 0
%define CONFIG_ALPHAEXTRACT_FILTER 0
%define CONFIG_ALPHAMERGE_FILTER 0
%define CONFIG_ASS_FILTER 0
%define CONFIG_BBOX_FILTER 0
%define CONFIG_BLACKDETECT_FILTER 0
%define CONFIG_BLACKFRAME_FILTER 0
%define CONFIG_BLEND_FILTER 0
%define CONFIG_BOXBLUR_FILTER 0
%define CONFIG_COLORBALANCE_FILTER 0
%define CONFIG_COLORCHANNELMIXER_FILTER 0
%define CONFIG_COLORMATRIX_FILTER 0
%define CONFIG_COPY_FILTER 0
%define CONFIG_CROP_FILTER 0
%define CONFIG_CROPDETECT_FILTER 0
%define CONFIG_CURVES_FILTER 0
%define CONFIG_DECIMATE_FILTER 0
%define CONFIG_DELOGO_FILTER 0
%define CONFIG_DESHAKE_FILTER 0
%define CONFIG_DRAWBOX_FILTER 0
%define CONFIG_DRAWTEXT_FILTER 0
%define CONFIG_EDGEDETECT_FILTER 0
%define CONFIG_FADE_FILTER 0
%define CONFIG_FIELD_FILTER 0
%define CONFIG_FIELDMATCH_FILTER 0
%define CONFIG_FIELDORDER_FILTER 0
%define CONFIG_FORMAT_FILTER 0
%define CONFIG_FPS_FILTER 0
%define CONFIG_FRAMESTEP_FILTER 0
%define CONFIG_FREI0R_FILTER 0
%define CONFIG_GEQ_FILTER 0
%define CONFIG_GRADFUN_FILTER 0
%define CONFIG_HFLIP_FILTER 0
%define CONFIG_HISTEQ_FILTER 0
%define CONFIG_HISTOGRAM_FILTER 0
%define CONFIG_HQDN3D_FILTER 0
%define CONFIG_HUE_FILTER 0
%define CONFIG_IDET_FILTER 0
%define CONFIG_IL_FILTER 0
%define CONFIG_INTERLACE_FILTER 0
%define CONFIG_INTERLEAVE_FILTER 0
%define CONFIG_KERNDEINT_FILTER 0
%define CONFIG_LUT_FILTER 0
%define CONFIG_LUTRGB_FILTER 0
%define CONFIG_LUTYUV_FILTER 0
%define CONFIG_MP_FILTER 0
%define CONFIG_MPDECIMATE_FILTER 0
%define CONFIG_NEGATE_FILTER 0
%define CONFIG_NOFORMAT_FILTER 0
%define CONFIG_NOISE_FILTER 0
%define CONFIG_NULL_FILTER 0
%define CONFIG_OCV_FILTER 0
%define CONFIG_OVERLAY_FILTER 0
%define CONFIG_PAD_FILTER 0
%define CONFIG_PERMS_FILTER 0
%define CONFIG_PIXDESCTEST_FILTER 0
%define CONFIG_PP_FILTER 0
%define CONFIG_REMOVELOGO_FILTER 0
%define CONFIG_SCALE_FILTER 0
%define CONFIG_SELECT_FILTER 0
%define CONFIG_SENDCMD_FILTER 0
%define CONFIG_SEPARATEFIELDS_FILTER 0
%define CONFIG_SETDAR_FILTER 0
%define CONFIG_SETFIELD_FILTER 0
%define CONFIG_SETPTS_FILTER 0
%define CONFIG_SETSAR_FILTER 0
%define CONFIG_SETTB_FILTER 0
%define CONFIG_SHOWINFO_FILTER 0
%define CONFIG_SMARTBLUR_FILTER 0
%define CONFIG_SPLIT_FILTER 0
%define CONFIG_STEREO3D_FILTER 0
%define CONFIG_SUBTITLES_FILTER 0
%define CONFIG_SUPER2XSAI_FILTER 0
%define CONFIG_SWAPUV_FILTER 0
%define CONFIG_TELECINE_FILTER 0
%define CONFIG_THUMBNAIL_FILTER 0
%define CONFIG_TILE_FILTER 0
%define CONFIG_TINTERLACE_FILTER 0
%define CONFIG_TRANSPOSE_FILTER 0
%define CONFIG_UNSHARP_FILTER 0
%define CONFIG_VFLIP_FILTER 0
%define CONFIG_VIDSTABDETECT_FILTER 0
%define CONFIG_VIDSTABTRANSFORM_FILTER 0
%define CONFIG_YADIF_FILTER 0
%define CONFIG_CELLAUTO_FILTER 0
%define CONFIG_COLOR_FILTER 0
%define CONFIG_FREI0R_SRC_FILTER 0
%define CONFIG_LIFE_FILTER 0
%define CONFIG_MANDELBROT_FILTER 0
%define CONFIG_MPTESTSRC_FILTER 0
%define CONFIG_NULLSRC_FILTER 0
%define CONFIG_RGBTESTSRC_FILTER 0
%define CONFIG_SMPTEBARS_FILTER 0
%define CONFIG_SMPTEHDBARS_FILTER 0
%define CONFIG_TESTSRC_FILTER 0
%define CONFIG_NULLSINK_FILTER 0
%define CONFIG_CONCAT_FILTER 0
%define CONFIG_SHOWSPECTRUM_FILTER 0
%define CONFIG_SHOWWAVES_FILTER 0
%define CONFIG_AMOVIE_FILTER 0
%define CONFIG_MOVIE_FILTER 0
%define CONFIG_H263_VAAPI_HWACCEL 0
%define CONFIG_H263_VDPAU_HWACCEL 0
%define CONFIG_H264_DXVA2_HWACCEL 0
%define CONFIG_H264_VAAPI_HWACCEL 0
%define CONFIG_H264_VDA_HWACCEL 0
%define CONFIG_H264_VDPAU_HWACCEL 0
%define CONFIG_MPEG1_VDPAU_HWACCEL 0
%define CONFIG_MPEG2_DXVA2_HWACCEL 0
%define CONFIG_MPEG2_VAAPI_HWACCEL 0
%define CONFIG_MPEG2_VDPAU_HWACCEL 0
%define CONFIG_MPEG4_VAAPI_HWACCEL 0
%define CONFIG_MPEG4_VDPAU_HWACCEL 0
%define CONFIG_VC1_DXVA2_HWACCEL 0
%define CONFIG_VC1_VAAPI_HWACCEL 0
%define CONFIG_VC1_VDPAU_HWACCEL 0
%define CONFIG_WMV3_DXVA2_HWACCEL 0
%define CONFIG_WMV3_VAAPI_HWACCEL 0
%define CONFIG_WMV3_VDPAU_HWACCEL 0
%define CONFIG_ALSA_INDEV 0
%define CONFIG_BKTR_INDEV 0
%define CONFIG_DSHOW_INDEV 0
%define CONFIG_DV1394_INDEV 0
%define CONFIG_FBDEV_INDEV 0
%define CONFIG_IEC61883_INDEV 0
%define CONFIG_JACK_INDEV 0
%define CONFIG_LAVFI_INDEV 0
%define CONFIG_OPENAL_INDEV 0
%define CONFIG_OSS_INDEV 0
%define CONFIG_PULSE_INDEV 0
%define CONFIG_SNDIO_INDEV 0
%define CONFIG_V4L2_INDEV 0
%define CONFIG_VFWCAP_INDEV 0
%define CONFIG_X11GRAB_INDEV 0
%define CONFIG_LIBCDIO_INDEV 0
%define CONFIG_LIBDC1394_INDEV 0
%define CONFIG_A64_MUXER 0
%define CONFIG_AC3_MUXER 0
%define CONFIG_ADTS_MUXER 0
%define CONFIG_ADX_MUXER 0
%define CONFIG_AIFF_MUXER 0
%define CONFIG_AMR_MUXER 0
%define CONFIG_ASF_MUXER 0
%define CONFIG_ASS_MUXER 0
%define CONFIG_AST_MUXER 0
%define CONFIG_ASF_STREAM_MUXER 0
%define CONFIG_AU_MUXER 0
%define CONFIG_AVI_MUXER 0
%define CONFIG_AVM2_MUXER 0
%define CONFIG_BIT_MUXER 0
%define CONFIG_CAF_MUXER 0
%define CONFIG_CAVSVIDEO_MUXER 0
%define CONFIG_CRC_MUXER 0
%define CONFIG_DAUD_MUXER 0
%define CONFIG_DIRAC_MUXER 0
%define CONFIG_DNXHD_MUXER 0
%define CONFIG_DTS_MUXER 0
%define CONFIG_DV_MUXER 0
%define CONFIG_EAC3_MUXER 0
%define CONFIG_F4V_MUXER 0
%define CONFIG_FFM_MUXER 0
%define CONFIG_FFMETADATA_MUXER 0
%define CONFIG_FILMSTRIP_MUXER 0
%define CONFIG_FLAC_MUXER 0
%define CONFIG_FLV_MUXER 0
%define CONFIG_FRAMECRC_MUXER 0
%define CONFIG_FRAMEMD5_MUXER 0
%define CONFIG_G722_MUXER 0
%define CONFIG_G723_1_MUXER 0
%define CONFIG_GIF_MUXER 0
%define CONFIG_GXF_MUXER 0
%define CONFIG_H261_MUXER 0
%define CONFIG_H263_MUXER 0
%define CONFIG_H264_MUXER 0
%define CONFIG_HLS_MUXER 0
%define CONFIG_ICO_MUXER 0
%define CONFIG_ILBC_MUXER 0
%define CONFIG_IMAGE2_MUXER 0
%define CONFIG_IMAGE2PIPE_MUXER 0
%define CONFIG_IPOD_MUXER 0
%define CONFIG_IRCAM_MUXER 0
%define CONFIG_ISMV_MUXER 0
%define CONFIG_IVF_MUXER 0
%define CONFIG_JACOSUB_MUXER 0
%define CONFIG_LATM_MUXER 0
%define CONFIG_M4V_MUXER 0
%define CONFIG_MD5_MUXER 0
%define CONFIG_MATROSKA_MUXER 0
%define CONFIG_MATROSKA_AUDIO_MUXER 0
%define CONFIG_MICRODVD_MUXER 0
%define CONFIG_MJPEG_MUXER 0
%define CONFIG_MLP_MUXER 0
%define CONFIG_MMF_MUXER 0
%define CONFIG_MOV_MUXER 0
%define CONFIG_MP2_MUXER 0
%define CONFIG_MP3_MUXER 0
%define CONFIG_MP4_MUXER 0
%define CONFIG_MPEG1SYSTEM_MUXER 0
%define CONFIG_MPEG1VCD_MUXER 0
%define CONFIG_MPEG1VIDEO_MUXER 0
%define CONFIG_MPEG2DVD_MUXER 0
%define CONFIG_MPEG2SVCD_MUXER 0
%define CONFIG_MPEG2VIDEO_MUXER 0
%define CONFIG_MPEG2VOB_MUXER 0
%define CONFIG_MPEGTS_MUXER 0
%define CONFIG_MPJPEG_MUXER 0
%define CONFIG_MXF_MUXER 0
%define CONFIG_MXF_D10_MUXER 0
%define CONFIG_NULL_MUXER 0
%define CONFIG_NUT_MUXER 0
%define CONFIG_OGG_MUXER 0
%define CONFIG_OMA_MUXER 0
%define CONFIG_PCM_ALAW_MUXER 0
%define CONFIG_PCM_MULAW_MUXER 0
%define CONFIG_PCM_F64BE_MUXER 0
%define CONFIG_PCM_F64LE_MUXER 0
%define CONFIG_PCM_F32BE_MUXER 0
%define CONFIG_PCM_F32LE_MUXER 0
%define CONFIG_PCM_S32BE_MUXER 0
%define CONFIG_PCM_S32LE_MUXER 0
%define CONFIG_PCM_S24BE_MUXER 0
%define CONFIG_PCM_S24LE_MUXER 0
%define CONFIG_PCM_S16BE_MUXER 0
%define CONFIG_PCM_S16LE_MUXER 0
%define CONFIG_PCM_S8_MUXER 0
%define CONFIG_PCM_U32BE_MUXER 0
%define CONFIG_PCM_U32LE_MUXER 0
%define CONFIG_PCM_U24BE_MUXER 0
%define CONFIG_PCM_U24LE_MUXER 0
%define CONFIG_PCM_U16BE_MUXER 0
%define CONFIG_PCM_U16LE_MUXER 0
%define CONFIG_PCM_U8_MUXER 0
%define CONFIG_PSP_MUXER 0
%define CONFIG_RAWVIDEO_MUXER 0
%define CONFIG_RM_MUXER 0
%define CONFIG_ROQ_MUXER 0
%define CONFIG_RSO_MUXER 0
%define CONFIG_RTP_MUXER 0
%define CONFIG_RTSP_MUXER 0
%define CONFIG_SAP_MUXER 0
%define CONFIG_SEGMENT_MUXER 0
%define CONFIG_STREAM_SEGMENT_MUXER 0
%define CONFIG_SMJPEG_MUXER 0
%define CONFIG_SMOOTHSTREAMING_MUXER 0
%define CONFIG_SOX_MUXER 0
%define CONFIG_SPDIF_MUXER 0
%define CONFIG_SRT_MUXER 0
%define CONFIG_SWF_MUXER 0
%define CONFIG_TEE_MUXER 0
%define CONFIG_TG2_MUXER 0
%define CONFIG_TGP_MUXER 0
%define CONFIG_MKVTIMESTAMP_V2_MUXER 0
%define CONFIG_TRUEHD_MUXER 0
%define CONFIG_VC1_MUXER 0
%define CONFIG_VC1T_MUXER 0
%define CONFIG_VOC_MUXER 0
%define CONFIG_W64_MUXER 0
%define CONFIG_WAV_MUXER 0
%define CONFIG_WEBM_MUXER 0
%define CONFIG_WTV_MUXER 0
%define CONFIG_WV_MUXER 0
%define CONFIG_YUV4MPEGPIPE_MUXER 0
%define CONFIG_LIBNUT_MUXER 0
%define CONFIG_ALSA_OUTDEV 0
%define CONFIG_CACA_OUTDEV 0
%define CONFIG_OSS_OUTDEV 0
%define CONFIG_SDL_OUTDEV 0
%define CONFIG_SNDIO_OUTDEV 0
%define CONFIG_AAC_PARSER 0
%define CONFIG_AAC_LATM_PARSER 0
%define CONFIG_AC3_PARSER 0
%define CONFIG_ADX_PARSER 0
%define CONFIG_BMP_PARSER 0
%define CONFIG_CAVSVIDEO_PARSER 0
%define CONFIG_COOK_PARSER 0
%define CONFIG_DCA_PARSER 0
%define CONFIG_DIRAC_PARSER 0
%define CONFIG_DNXHD_PARSER 0
%define CONFIG_DVBSUB_PARSER 0
%define CONFIG_DVDSUB_PARSER 0
%define CONFIG_DVD_NAV_PARSER 0
%define CONFIG_FLAC_PARSER 0
%define CONFIG_GSM_PARSER 0
%define CONFIG_H261_PARSER 0
%define CONFIG_H263_PARSER 0
%define CONFIG_H264_PARSER 0
%define CONFIG_MJPEG_PARSER 0
%define CONFIG_MLP_PARSER 0
%define CONFIG_MPEG4VIDEO_PARSER 0
%define CONFIG_MPEGAUDIO_PARSER 0
%define CONFIG_MPEGVIDEO_PARSER 0
%define CONFIG_PNG_PARSER 0
%define CONFIG_PNM_PARSER 0
%define CONFIG_RV30_PARSER 0
%define CONFIG_RV40_PARSER 0
%define CONFIG_TAK_PARSER 0
%define CONFIG_VC1_PARSER 0
%define CONFIG_VORBIS_PARSER 1
%define CONFIG_VP3_PARSER 1
%define CONFIG_VP8_PARSER 1
%define CONFIG_BLURAY_PROTOCOL 0
%define CONFIG_CACHE_PROTOCOL 0
%define CONFIG_CONCAT_PROTOCOL 0
%define CONFIG_CRYPTO_PROTOCOL 0
%define CONFIG_DATA_PROTOCOL 0
%define CONFIG_FFRTMPCRYPT_PROTOCOL 0
%define CONFIG_FFRTMPHTTP_PROTOCOL 0
%define CONFIG_FILE_PROTOCOL 0
%define CONFIG_GOPHER_PROTOCOL 0
%define CONFIG_HLS_PROTOCOL 0
%define CONFIG_HTTP_PROTOCOL 0
%define CONFIG_HTTPPROXY_PROTOCOL 0
%define CONFIG_HTTPS_PROTOCOL 0
%define CONFIG_MMSH_PROTOCOL 0
%define CONFIG_MMST_PROTOCOL 0
%define CONFIG_MD5_PROTOCOL 0
%define CONFIG_PIPE_PROTOCOL 0
%define CONFIG_RTMP_PROTOCOL 0
%define CONFIG_RTMPE_PROTOCOL 0
%define CONFIG_RTMPS_PROTOCOL 0
%define CONFIG_RTMPT_PROTOCOL 0
%define CONFIG_RTMPTE_PROTOCOL 0
%define CONFIG_RTMPTS_PROTOCOL 0
%define CONFIG_RTP_PROTOCOL 0
%define CONFIG_SCTP_PROTOCOL 0
%define CONFIG_SRTP_PROTOCOL 0
%define CONFIG_TCP_PROTOCOL 0
%define CONFIG_TLS_PROTOCOL 0
%define CONFIG_UDP_PROTOCOL 0
%define CONFIG_LIBRTMP_PROTOCOL 0
%define CONFIG_LIBRTMPE_PROTOCOL 0
%define CONFIG_LIBRTMPS_PROTOCOL 0
%define CONFIG_LIBRTMPT_PROTOCOL 0
%define CONFIG_LIBRTMPTE_PROTOCOL 0
| espadrine/opera | chromium/src/third_party/ffmpeg/chromium/config/Chromium/win/ia32/config.asm | Assembly | bsd-3-clause | 46,983 |
;
; Copyright (c) 2010 The WebM project authors. All Rights Reserved.
;
; Use of this source code is governed by a BSD-style license
; that can be found in the LICENSE file in the root of the source
; tree. An additional intellectual property rights grant can be found
; in the file PATENTS. All contributing project authors may
; be found in the AUTHORS file in the root of the source tree.
;
%include "vpx_ports/x86_abi_support.asm"
; tabulate_ssim - sums sum_s,sum_r,sum_sq_s,sum_sq_r, sum_sxr
%macro TABULATE_SSIM 0
paddusw xmm15, xmm3 ; sum_s
paddusw xmm14, xmm4 ; sum_r
movdqa xmm1, xmm3
pmaddwd xmm1, xmm1
paddq xmm13, xmm1 ; sum_sq_s
movdqa xmm2, xmm4
pmaddwd xmm2, xmm2
paddq xmm12, xmm2 ; sum_sq_r
pmaddwd xmm3, xmm4
paddq xmm11, xmm3 ; sum_sxr
%endmacro
; Sum across the register %1 starting with q words
%macro SUM_ACROSS_Q 1
movdqa xmm2,%1
punpckldq %1,xmm0
punpckhdq xmm2,xmm0
paddq %1,xmm2
movdqa xmm2,%1
punpcklqdq %1,xmm0
punpckhqdq xmm2,xmm0
paddq %1,xmm2
%endmacro
; Sum across the register %1 starting with q words
%macro SUM_ACROSS_W 1
movdqa xmm1, %1
punpcklwd %1,xmm0
punpckhwd xmm1,xmm0
paddd %1, xmm1
SUM_ACROSS_Q %1
%endmacro
;void ssim_parms_sse3(
; unsigned char *s,
; int sp,
; unsigned char *r,
; int rp
; unsigned long *sum_s,
; unsigned long *sum_r,
; unsigned long *sum_sq_s,
; unsigned long *sum_sq_r,
; unsigned long *sum_sxr);
;
; TODO: Use parm passing through structure, probably don't need the pxors
; ( calling app will initialize to 0 ) could easily fit everything in sse2
; without too much hastle, and can probably do better estimates with psadw
; or pavgb At this point this is just meant to be first pass for calculating
; all the parms needed for 16x16 ssim so we can play with dssim as distortion
; in mode selection code.
global sym(vp8_ssim_parms_16x16_sse3)
sym(vp8_ssim_parms_16x16_sse3):
push rbp
mov rbp, rsp
SHADOW_ARGS_TO_STACK 9
push rsi
push rdi
; end prolog
mov rsi, arg(0) ;s
mov rcx, arg(1) ;sp
mov rdi, arg(2) ;r
mov rax, arg(3) ;rp
pxor xmm0, xmm0
pxor xmm15,xmm15 ;sum_s
pxor xmm14,xmm14 ;sum_r
pxor xmm13,xmm13 ;sum_sq_s
pxor xmm12,xmm12 ;sum_sq_r
pxor xmm11,xmm11 ;sum_sxr
mov rdx, 16 ;row counter
NextRow:
;grab source and reference pixels
movdqu xmm5, [rsi]
movdqu xmm6, [rdi]
movdqa xmm3, xmm5
movdqa xmm4, xmm6
punpckhbw xmm3, xmm0 ; high_s
punpckhbw xmm4, xmm0 ; high_r
TABULATE_SSIM
movdqa xmm3, xmm5
movdqa xmm4, xmm6
punpcklbw xmm3, xmm0 ; low_s
punpcklbw xmm4, xmm0 ; low_r
TABULATE_SSIM
add rsi, rcx ; next s row
add rdi, rax ; next r row
dec rdx ; counter
jnz NextRow
SUM_ACROSS_W xmm15
SUM_ACROSS_W xmm14
SUM_ACROSS_Q xmm13
SUM_ACROSS_Q xmm12
SUM_ACROSS_Q xmm11
mov rdi,arg(4)
movq [rdi], xmm15;
mov rdi,arg(5)
movq [rdi], xmm14;
mov rdi,arg(6)
movq [rdi], xmm13;
mov rdi,arg(7)
movq [rdi], xmm12;
mov rdi,arg(8)
movq [rdi], xmm11;
; begin epilog
pop rdi
pop rsi
UNSHADOW_ARGS
pop rbp
ret
;void ssim_parms_sse3(
; unsigned char *s,
; int sp,
; unsigned char *r,
; int rp
; unsigned long *sum_s,
; unsigned long *sum_r,
; unsigned long *sum_sq_s,
; unsigned long *sum_sq_r,
; unsigned long *sum_sxr);
;
; TODO: Use parm passing through structure, probably don't need the pxors
; ( calling app will initialize to 0 ) could easily fit everything in sse2
; without too much hastle, and can probably do better estimates with psadw
; or pavgb At this point this is just meant to be first pass for calculating
; all the parms needed for 16x16 ssim so we can play with dssim as distortion
; in mode selection code.
global sym(vp8_ssim_parms_8x8_sse3)
sym(vp8_ssim_parms_8x8_sse3):
push rbp
mov rbp, rsp
SHADOW_ARGS_TO_STACK 9
push rsi
push rdi
; end prolog
mov rsi, arg(0) ;s
mov rcx, arg(1) ;sp
mov rdi, arg(2) ;r
mov rax, arg(3) ;rp
pxor xmm0, xmm0
pxor xmm15,xmm15 ;sum_s
pxor xmm14,xmm14 ;sum_r
pxor xmm13,xmm13 ;sum_sq_s
pxor xmm12,xmm12 ;sum_sq_r
pxor xmm11,xmm11 ;sum_sxr
mov rdx, 8 ;row counter
NextRow2:
;grab source and reference pixels
movq xmm5, [rsi]
movq xmm6, [rdi]
movdqa xmm3, xmm5
movdqa xmm4, xmm6
punpcklbw xmm3, xmm0 ; low_s
punpcklbw xmm4, xmm0 ; low_r
TABULATE_SSIM
add rsi, rcx ; next s row
add rdi, rax ; next r row
dec rdx ; counter
jnz NextRow2
SUM_ACROSS_W xmm15
SUM_ACROSS_W xmm14
SUM_ACROSS_Q xmm13
SUM_ACROSS_Q xmm12
SUM_ACROSS_Q xmm11
mov rdi,arg(4)
movq [rdi], xmm15;
mov rdi,arg(5)
movq [rdi], xmm14;
mov rdi,arg(6)
movq [rdi], xmm13;
mov rdi,arg(7)
movq [rdi], xmm12;
mov rdi,arg(8)
movq [rdi], xmm11;
; begin epilog
pop rdi
pop rsi
UNSHADOW_ARGS
pop rbp
ret
| thiz11/platform_external_libvpx | vp8/encoder/x86/ssim_opt.asm | Assembly | bsd-3-clause | 6,259 |
; ****************************************************************************************************************
; ****************************************************************************************************************
;
; Console Handler
;
; ****************************************************************************************************************
; ****************************************************************************************************************
; ****************************************************************************************************************
;
; Come here when a program stops running, or at the start.
;
; ****************************************************************************************************************
ConsoleStart:
lpi p3,Print-1
csa ; see if CY/L is set
ani 0x80
jz CONError ; if so, there is an error.
; ****************************************************************************************************************
; Print OK
; ****************************************************************************************************************
CONOk:
lpi p1,CONMsgOk ; print OK.
ldi 0
xppc p3
jmp CONEnter
CONMsgOk: ; OK prompt.
db "OK",13,0
CONMsgErr1: ; Error Message
db "!ERR ",0
db " AT ",0
CONMsgErr2: ; Error Message
db "BREAK",0
db "AT ",0
; ****************************************************************************************************************
; Print Error Message
; ****************************************************************************************************************
CONError:
lpi p1,CONMsgErr1
lde ; check if faux error
xri ERRC_End
jz CONOk
lde
xri ERRC_Break ; check if BREAK
jnz CONError2
lpi p1,CONMsgErr2
ldi ' ' ; makes it print space rather than code.
xae
CONError2:
ldi 0
xppc p3
lde ; get error code
xppc p3
ldi 0 ; print _AT_
xppc p3
lpi p3,CurrentLine ; get current line number into E.
ld (p3)
xae
lpi p3,PrintInteger-1 ; print it.
xppc p3
lpi p3,Print-1
ldi 13 ; print new line
xppc p3
; ****************************************************************************************************************
; Get next command.
; ****************************************************************************************************************
CONEnter:
lpi p3,GetString-1 ; get input from keyboard.
lpi p1,KeyboardBuffer
ldi 0 ; clear current line # using value.
st CurrentLine-KeyboardBuffer(p1)
ldi KeyboardBufferSize ; input length
xppc p3
lpi p3,GetConstant-1 ; extract a constant if there is one.
xppc p3
ani 0x80
jnz CONHasLineNumber ; if okay, has line number.
ld (p1) ; if no text, enter again.
jz CONEnter
; ****************************************************************************************************************
; Execute a command from the keyboard.
; ****************************************************************************************************************
CONEndOfLine:
ld @1(p1) ; find end of line
jnz CONEndOfLine
ldi 0xFF ; put end of code marker at end of string.
st (p1)
lpi p1,KeyboardBuffer
lpi p3,ExecuteFromAddressDirect-1
xppc p3
; ****************************************************************************************************************
; Command has a Line Number - text is at P1, line number in E.
; ****************************************************************************************************************
CONHasLineNumber:
lpi p3,DeleteLine-1 ; delete the line whose number is in E
xppc p3
ld (p1) ; any text in this line ?
jz CONEnter ; if not, then just do the delete (possible)
ldi 0 ; temporarily set the line number to zero.
st -1(p1)
ldi 2
st -1(p2) ; and reset the counter to 2 to get size right.
CONGetLength:
ild -1(p2) ; bump count
ld @1(p1) ; keep going forward till 0 read.
jnz CONGetLength
ld @-1(p1) ; undo the last bump over zero
CONBackToStart:
ld @-1(p1) ; keep going back until zero.
jnz CONBackToStart ; this is the line number we set to zero
lde ; copy line number
st (p1)
ld -1(p2) ; get measured length
st @-1(p1) ; and store in the length slot.
xppc p3 ; put line in using fall through insert routine.
jmp CONEnter ; and get another line.
| paulscottrobson/wallpaper-one | software/minol/source/console.asm | Assembly | mit | 4,824 |
;;
;; Screen.asm -- Real Mode Screen Routines
;;
;; Copyright (c) 2007 by Pablo Bravo
;; All Rights Reserved
;;
;;;;;;;;;;;;;;;;;;;;;;;;;NewLine;;;;;;;;;;;;;;;;;;;;;;;;;;
NewLine: db 13,10,0
;;;;;;;;;;;;;;;;;;;;;;;;;Print;;;;;;;;;;;;;;;;;;;;;;;;;;
Print:
push bp
mov bp, sp
push si
push ax
push bx
mov si, [bp+4]
.message:
lodsb
or al, al
jz .done
mov ah, 0x0E
mov bx, 7
int 0x10
jmp .message
.done:
pop bx
pop ax
pop si
pop bp
ret 2
;;;;;;;;;;;;;;;;;;;;;PrintNewLine;;;;;;;;;;;;;;;;;;;;;;;
PrintNewLine:
push NewLine
call Print
ret
;;;;;;;;;;;;;;;;;;;;;;;PrintLine;;;;;;;;;;;;;;;;;;;;;;;;
PrintLine: ;void PrintLine(word string)
push bp
mov bp, sp
push word [bp+4]
call Print
push NewLine
call Print
pop bp
ret 2
;;;;;;;;;;;;;;;;;;;;;;;Format16;;;;;;;;;;;;;;;;;;;;;;;;;
Format16: ;void Format16(word buffer, word data)
push bp
mov bp, sp
pusha
mov ax, [bp+6]
mov bx, [bp+4]
mov byte [bx+4], 0
mov si, 0x0030
mov di, 0x0037
mov cx, ax
and cx, 0x000F
cmp cx, 9
cmovbe dx, si
cmova dx, di
add dx, cx
mov [bx+3], dl
mov cx, ax
and cx, 0x00F0
shr cx, 4
cmp cx, 9
cmovbe dx, si
cmova dx, di
add dx, cx
mov [bx+2], dl
mov cx, ax
and cx, 0x0F00
shr cx, 8
cmp cx, 9
cmovbe dx, si
cmova dx, di
add dx, cx
mov [bx+1], dl
mov cx, ax
and cx, 0xF000
shr cx, 12
cmp cx, 9
cmovbe dx, si
cmova dx, di
add dx, cx
mov [bx+0], dl
popa
pop bp
ret 4
;;;;;;;;;;;;;;;;;;;;;;;Format32;;;;;;;;;;;;;;;;;;;;;;;;;
Format32: ;void Format32(word buffer, dword data)
push bp
mov bp, sp
push word [bp+8]
push word [bp+4]
call Format16
push word [bp+6]
add word [bp+4], 4
push word [bp+4]
call Format16
pop bp
ret 6
;;;;;;;;;;;;;;;;;;;;;;;Print16;;;;;;;;;;;;;;;;;;;;;;;;;;
Data16: times 5 db 0
Print16: ;void Print16(word data)
push bp
mov bp, sp
push word [bp+4]
push Data16
call Format16
push Data16
call Print
pop bp
ret 2
;;;;;;;;;;;;;;;;;;;;;;Print32;;;;;;;;;;;;;;;;;;;;;;;;;;;
Data32: times 9 db 0
Print32: ;void Print32(dword data)
push bp
mov bp, sp
push dword [bp+4]
push Data32
call Format32
push Data32
call Print
pop bp
ret 4
| yandroskaos/XkyOS | XkyOS/Source/Core/Boot/Screen.asm | Assembly | apache-2.0 | 2,305 |
;;----------------------------------------------------------------------------;;
;; Align the position of the textbox hero menu
;; Copyright 2014 Benito Palacios (aka pleonex)
;;
;; Licensed under the Apache License, Version 2.0 (the "License");
;; you may not use this file except in compliance with the License.
;; You may obtain a copy of the License at
;;
;; http://www.apache.org/licenses/LICENSE-2.0
;;
;; Unless required by applicable law or agreed to in writing, software
;; distributed under the License is distributed on an "AS IS" BASIS,
;; WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
;; See the License for the specific language governing permissions and
;; limitations under the License.
;;----------------------------------------------------------------------------;;
.arm
;; Item name in top screen
.org 0x02134274
MOV r2, #0x43 ; Y pos, original 0x3F
;; Number of cards
.org 0x021339C8
MOV r1, #0xF0 + 6 ; X pos
| pleonex/Ninokuni | Assembly/textbox/menu_hero.asm | Assembly | apache-2.0 | 983 |
;; Licensed to the .NET Foundation under one or more agreements.
;; The .NET Foundation licenses this file to you under the MIT license.
;; See the LICENSE file in the project root for more information.
#include "AsmMacros.h"
TEXTAREA
#ifdef FEATURE_CACHED_INTERFACE_DISPATCH
EXTERN RhpResolveInterfaceMethodCacheMiss
;; Macro that generates code to check a single cache entry.
MACRO
CHECK_CACHE_ENTRY $entry
;; Check a single entry in the cache.
;; R1 : Instance EEType*
;; R12: Cache data structure
;; R2 : Trashed
ldr r2, [r12, #(OFFSETOF__InterfaceDispatchCache__m_rgEntries + ($entry * 8))]
cmp r1, r2
bne %ft0
ldr r12, [r12, #(OFFSETOF__InterfaceDispatchCache__m_rgEntries + ($entry * 8) + 4)]
b %fa99
0
MEND
;; Macro that generates a stub consuming a cache with the given number of entries.
GBLS StubName
MACRO
DEFINE_INTERFACE_DISPATCH_STUB $entries
StubName SETS "RhpInterfaceDispatch$entries"
NESTED_ENTRY $StubName
;; On input we have the indirection cell data structure in r12. But we need more scratch registers and
;; we may A/V on a null this. Both of these suggest we need a real prolog and epilog.
PROLOG_PUSH {r1-r2}
;; r12 currently holds the indirection cell address. We need to update it to point to the cache
;; structure instead.
ldr r12, [r12, #OFFSETOF__InterfaceDispatchCell__m_pCache]
;; Load the EEType from the object instance in r0.
ldr r1, [r0]
GBLA CurrentEntry
CurrentEntry SETA 0
WHILE CurrentEntry < $entries
CHECK_CACHE_ENTRY CurrentEntry
CurrentEntry SETA CurrentEntry + 1
WEND
;; r12 currently contains the cache block. We need to point it back to the
;; indirection cell using the back pointer in the cache block
ldr r12, [r12, #OFFSETOF__InterfaceDispatchCache__m_pCell]
EPILOG_POP {r1-r2}
EPILOG_BRANCH RhpInterfaceDispatchSlow
;; Common epilog for cache hits. Have to out of line it here due to limitation on the number of
;; epilogs imposed by the unwind code macros.
99
EPILOG_POP {r1-r2}
EPILOG_BRANCH_REG r12
NESTED_END $StubName
MEND
;; Define all the stub routines we currently need.
DEFINE_INTERFACE_DISPATCH_STUB 1
DEFINE_INTERFACE_DISPATCH_STUB 2
DEFINE_INTERFACE_DISPATCH_STUB 4
DEFINE_INTERFACE_DISPATCH_STUB 8
DEFINE_INTERFACE_DISPATCH_STUB 16
DEFINE_INTERFACE_DISPATCH_STUB 32
DEFINE_INTERFACE_DISPATCH_STUB 64
;; Initial dispatch on an interface when we don't have a cache yet.
LEAF_ENTRY RhpInitialInterfaceDispatch
;; The stub that jumped here pushed r12, which contains the interface dispatch cell
;; we need to pop it here
pop { r12 }
;; Simply tail call the slow dispatch helper.
b RhpInterfaceDispatchSlow
LEAF_END RhpInitialInterfaceDispatch
;; Cache miss case, call the runtime to resolve the target and update the cache.
NESTED_ENTRY RhpInterfaceDispatchSlow
ALTERNATE_ENTRY RhpInitialDynamicInterfaceDispatch
;; Save argument registers (including floating point) and the return address. Note that we depend on
;; these registers (which may contain GC references) being spilled before we build the
;; PInvokeTransitionFrame below due to the way we build a stack range to report to the GC
;; conservatively during a collection.
PROLOG_PUSH {r0-r3,lr}
PROLOG_VPUSH {d0-d7}
;; Build PInvokeTransitionFrame. This is only required if we end up resolving the interface method via
;; a callout to a managed ICastable method. In that instance we need to be able to cope with garbage
;; collections which in turn need to be able to walk the stack from the ICastable method, skip the
;; unmanaged runtime portions and resume walking at our caller. This frame provides both the means to
;; unwind to that caller and a place to spill callee saved registers in case they contain GC
;; references from the caller.
PROLOG_STACK_ALLOC 8 ; Align the stack and save space for caller's SP
PROLOG_PUSH {r4-r6,r8-r10} ; Save preserved registers
PROLOG_STACK_ALLOC 8 ; Save space for flags and Thread*
PROLOG_PUSH {r7} ; Save caller's FP
PROLOG_PUSH {r11,lr} ; Save caller's frame-chain pointer and PC
;; Compute SP value at entry to this method and save it in the last slot of the frame (slot #11).
add r1, sp, #((12 * 4) + 4 + (8 * 8) + (5 * 4))
str r1, [sp, #(11 * 4)]
;; Record the bitmask of saved registers in the frame (slot #4).
mov r1, #DEFAULT_FRAME_SAVE_FLAGS
str r1, [sp, #(4 * 4)]
;; First argument is the instance we're dispatching on which is already in r0.
;; Second argument is the dispatch data cell.
;; We still have this in r12
mov r1, r12
;; The third argument is the address of the transition frame we build above. Currently it's at the top
;; of the stack so sp points to it.
mov r2, sp
bl RhpResolveInterfaceMethodCacheMiss
;; Move the result (the target address) to r12 so it doesn't get overridden when we restore the
;; argument registers. Additionally make sure the thumb2 bit is set.
orr r12, r0, #1
;; Pop the PInvokeTransitionFrame
EPILOG_POP {r11,lr} ; Restore caller's frame-chain pointer and PC (return address)
EPILOG_POP {r7} ; Restore caller's FP
EPILOG_STACK_FREE 8 ; Discard flags and Thread*
EPILOG_POP {r4-r6,r8-r10} ; Restore preserved registers
EPILOG_STACK_FREE 8 ; Discard caller's SP and stack alignment padding
;; Restore the argument registers.
EPILOG_VPOP {d0-d7}
EPILOG_POP {r0-r3,lr}
EPILOG_BRANCH_REG r12
NESTED_END RhpInterfaceDispatchSlow
#endif // FEATURE_CACHED_INTERFACE_DISPATCH
end
| mjp41/corert | src/Native/Runtime/arm/StubDispatch.asm | Assembly | mit | 6,269 |
; Generated at 20-7-2015 14:42:43
DebugStub_TracerEntry:
cli
Pushad
Mov [DebugStub_PushAllPtr], ESP
Mov [DebugStub_CallerEBP], EBP
Mov EBP, ESP
Add EBP, 32
Mov EAX, [EBP + 0]
Add EBP, 12
Mov [DebugStub_CallerESP], EBP
Mov EBX, EAX
MOV EAX, DR6
And EAX, 0x4000
Cmp EAX, 0x4000
JE DebugStub_TracerEntry_Block1_End
Dec EBX
DebugStub_TracerEntry_Block1_End:
Mov EAX, EBX
Mov [DebugStub_CallerEIP], EAX
Call DebugStub_Executing
Popad
sti
DebugStub_TracerEntry_Exit:
IRet
DebugStub_Interrupt_0:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 48
Call DebugStub_ComWriteAL
DebugStub_Interrupt_0_StartLoop:
hlt
Jmp DebugStub_Interrupt_0_StartLoop
DebugStub_Interrupt_0_Exit:
IRet
DebugStub_Interrupt_2:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 50
Call DebugStub_ComWriteAL
DebugStub_Interrupt_2_StartLoop:
hlt
Jmp DebugStub_Interrupt_2_StartLoop
DebugStub_Interrupt_2_Exit:
IRet
DebugStub_Interrupt_4:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 52
Call DebugStub_ComWriteAL
DebugStub_Interrupt_4_StartLoop:
hlt
Jmp DebugStub_Interrupt_4_StartLoop
DebugStub_Interrupt_4_Exit:
IRet
DebugStub_Interrupt_5:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 53
Call DebugStub_ComWriteAL
DebugStub_Interrupt_5_StartLoop:
hlt
Jmp DebugStub_Interrupt_5_StartLoop
DebugStub_Interrupt_5_Exit:
IRet
DebugStub_Interrupt_6:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 54
Call DebugStub_ComWriteAL
DebugStub_Interrupt_6_StartLoop:
hlt
Jmp DebugStub_Interrupt_6_StartLoop
DebugStub_Interrupt_6_Exit:
IRet
DebugStub_Interrupt_7:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 55
Call DebugStub_ComWriteAL
DebugStub_Interrupt_7_StartLoop:
hlt
Jmp DebugStub_Interrupt_7_StartLoop
DebugStub_Interrupt_7_Exit:
IRet
DebugStub_Interrupt_8:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 56
Call DebugStub_ComWriteAL
DebugStub_Interrupt_8_StartLoop:
hlt
Jmp DebugStub_Interrupt_8_StartLoop
DebugStub_Interrupt_8_Exit:
IRet
DebugStub_Interrupt_9:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 57
Call DebugStub_ComWriteAL
DebugStub_Interrupt_9_StartLoop:
hlt
Jmp DebugStub_Interrupt_9_StartLoop
DebugStub_Interrupt_9_Exit:
IRet
DebugStub_Interrupt_10:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
Mov eax, 48
Call DebugStub_ComWriteAL
DebugStub_Interrupt_10_StartLoop:
hlt
Jmp DebugStub_Interrupt_10_StartLoop
DebugStub_Interrupt_10_Exit:
IRet
DebugStub_Interrupt_11:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
DebugStub_Interrupt_11_StartLoop:
hlt
Jmp DebugStub_Interrupt_11_StartLoop
DebugStub_Interrupt_11_Exit:
IRet
DebugStub_Interrupt_12:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
Mov eax, 50
Call DebugStub_ComWriteAL
DebugStub_Interrupt_12_StartLoop:
hlt
Jmp DebugStub_Interrupt_12_StartLoop
DebugStub_Interrupt_12_Exit:
IRet
DebugStub_Interrupt_13:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
Mov eax, 51
Call DebugStub_ComWriteAL
DebugStub_Interrupt_13_StartLoop:
hlt
Jmp DebugStub_Interrupt_13_StartLoop
DebugStub_Interrupt_13_Exit:
IRet
DebugStub_Interrupt_14:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
Mov eax, 52
Call DebugStub_ComWriteAL
DebugStub_Interrupt_14_StartLoop:
hlt
Jmp DebugStub_Interrupt_14_StartLoop
DebugStub_Interrupt_14_Exit:
IRet
DebugStub_Interrupt_15:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
Mov eax, 53
Call DebugStub_ComWriteAL
DebugStub_Interrupt_15_StartLoop:
hlt
Jmp DebugStub_Interrupt_15_StartLoop
DebugStub_Interrupt_15_Exit:
IRet
DebugStub_Interrupt_16:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
Mov eax, 54
Call DebugStub_ComWriteAL
DebugStub_Interrupt_16_StartLoop:
hlt
Jmp DebugStub_Interrupt_16_StartLoop
DebugStub_Interrupt_16_Exit:
IRet
DebugStub_Interrupt_17:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
Mov eax, 55
Call DebugStub_ComWriteAL
DebugStub_Interrupt_17_StartLoop:
hlt
Jmp DebugStub_Interrupt_17_StartLoop
DebugStub_Interrupt_17_Exit:
IRet
DebugStub_Interrupt_18:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
Mov eax, 56
Call DebugStub_ComWriteAL
DebugStub_Interrupt_18_StartLoop:
hlt
Jmp DebugStub_Interrupt_18_StartLoop
DebugStub_Interrupt_18_Exit:
IRet
DebugStub_Interrupt_19:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
Mov eax, 57
Call DebugStub_ComWriteAL
DebugStub_Interrupt_19_StartLoop:
hlt
Jmp DebugStub_Interrupt_19_StartLoop
DebugStub_Interrupt_19_Exit:
IRet
DebugStub_Interrupt_20:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 50
Call DebugStub_ComWriteAL
Mov eax, 48
Call DebugStub_ComWriteAL
DebugStub_Interrupt_20_StartLoop:
hlt
Jmp DebugStub_Interrupt_20_StartLoop
DebugStub_Interrupt_20_Exit:
IRet
DebugStub_Interrupt_21:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 50
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
DebugStub_Interrupt_21_StartLoop:
hlt
Jmp DebugStub_Interrupt_21_StartLoop
DebugStub_Interrupt_21_Exit:
IRet
DebugStub_Interrupt_22:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 50
Call DebugStub_ComWriteAL
Mov eax, 50
Call DebugStub_ComWriteAL
DebugStub_Interrupt_22_StartLoop:
hlt
Jmp DebugStub_Interrupt_22_StartLoop
DebugStub_Interrupt_22_Exit:
IRet
DebugStub_Interrupt_23:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 50
Call DebugStub_ComWriteAL
Mov eax, 51
Call DebugStub_ComWriteAL
DebugStub_Interrupt_23_StartLoop:
hlt
Jmp DebugStub_Interrupt_23_StartLoop
DebugStub_Interrupt_23_Exit:
IRet
DebugStub_Interrupt_24:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 50
Call DebugStub_ComWriteAL
Mov eax, 52
Call DebugStub_ComWriteAL
DebugStub_Interrupt_24_StartLoop:
hlt
Jmp DebugStub_Interrupt_24_StartLoop
DebugStub_Interrupt_24_Exit:
IRet
DebugStub_Interrupt_25:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 50
Call DebugStub_ComWriteAL
Mov eax, 53
Call DebugStub_ComWriteAL
DebugStub_Interrupt_25_StartLoop:
hlt
Jmp DebugStub_Interrupt_25_StartLoop
DebugStub_Interrupt_25_Exit:
IRet
DebugStub_Interrupt_26:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 50
Call DebugStub_ComWriteAL
Mov eax, 54
Call DebugStub_ComWriteAL
DebugStub_Interrupt_26_StartLoop:
hlt
Jmp DebugStub_Interrupt_26_StartLoop
DebugStub_Interrupt_26_Exit:
IRet
DebugStub_Interrupt_27:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 50
Call DebugStub_ComWriteAL
Mov eax, 55
Call DebugStub_ComWriteAL
DebugStub_Interrupt_27_StartLoop:
hlt
Jmp DebugStub_Interrupt_27_StartLoop
DebugStub_Interrupt_27_Exit:
IRet
DebugStub_Interrupt_28:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 50
Call DebugStub_ComWriteAL
Mov eax, 56
Call DebugStub_ComWriteAL
DebugStub_Interrupt_28_StartLoop:
hlt
Jmp DebugStub_Interrupt_28_StartLoop
DebugStub_Interrupt_28_Exit:
IRet
DebugStub_Interrupt_29:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 50
Call DebugStub_ComWriteAL
Mov eax, 57
Call DebugStub_ComWriteAL
DebugStub_Interrupt_29_StartLoop:
hlt
Jmp DebugStub_Interrupt_29_StartLoop
DebugStub_Interrupt_29_Exit:
IRet
DebugStub_Interrupt_30:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 51
Call DebugStub_ComWriteAL
Mov eax, 48
Call DebugStub_ComWriteAL
DebugStub_Interrupt_30_StartLoop:
hlt
Jmp DebugStub_Interrupt_30_StartLoop
DebugStub_Interrupt_30_Exit:
IRet
DebugStub_Interrupt_31:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 51
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
DebugStub_Interrupt_31_StartLoop:
hlt
Jmp DebugStub_Interrupt_31_StartLoop
DebugStub_Interrupt_31_Exit:
IRet
DebugStub_Interrupt_32:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 51
Call DebugStub_ComWriteAL
Mov eax, 50
Call DebugStub_ComWriteAL
DebugStub_Interrupt_32_StartLoop:
hlt
Jmp DebugStub_Interrupt_32_StartLoop
DebugStub_Interrupt_32_Exit:
IRet
DebugStub_Interrupt_33:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 51
Call DebugStub_ComWriteAL
Mov eax, 51
Call DebugStub_ComWriteAL
DebugStub_Interrupt_33_StartLoop:
hlt
Jmp DebugStub_Interrupt_33_StartLoop
DebugStub_Interrupt_33_Exit:
IRet
DebugStub_Interrupt_34:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 51
Call DebugStub_ComWriteAL
Mov eax, 52
Call DebugStub_ComWriteAL
DebugStub_Interrupt_34_StartLoop:
hlt
Jmp DebugStub_Interrupt_34_StartLoop
DebugStub_Interrupt_34_Exit:
IRet
DebugStub_Interrupt_35:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 51
Call DebugStub_ComWriteAL
Mov eax, 53
Call DebugStub_ComWriteAL
DebugStub_Interrupt_35_StartLoop:
hlt
Jmp DebugStub_Interrupt_35_StartLoop
DebugStub_Interrupt_35_Exit:
IRet
DebugStub_Interrupt_36:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 51
Call DebugStub_ComWriteAL
Mov eax, 54
Call DebugStub_ComWriteAL
DebugStub_Interrupt_36_StartLoop:
hlt
Jmp DebugStub_Interrupt_36_StartLoop
DebugStub_Interrupt_36_Exit:
IRet
DebugStub_Interrupt_37:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 51
Call DebugStub_ComWriteAL
Mov eax, 55
Call DebugStub_ComWriteAL
DebugStub_Interrupt_37_StartLoop:
hlt
Jmp DebugStub_Interrupt_37_StartLoop
DebugStub_Interrupt_37_Exit:
IRet
DebugStub_Interrupt_38:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 51
Call DebugStub_ComWriteAL
Mov eax, 56
Call DebugStub_ComWriteAL
DebugStub_Interrupt_38_StartLoop:
hlt
Jmp DebugStub_Interrupt_38_StartLoop
DebugStub_Interrupt_38_Exit:
IRet
DebugStub_Interrupt_39:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 51
Call DebugStub_ComWriteAL
Mov eax, 57
Call DebugStub_ComWriteAL
DebugStub_Interrupt_39_StartLoop:
hlt
Jmp DebugStub_Interrupt_39_StartLoop
DebugStub_Interrupt_39_Exit:
IRet
DebugStub_Interrupt_40:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 52
Call DebugStub_ComWriteAL
Mov eax, 48
Call DebugStub_ComWriteAL
DebugStub_Interrupt_40_StartLoop:
hlt
Jmp DebugStub_Interrupt_40_StartLoop
DebugStub_Interrupt_40_Exit:
IRet
DebugStub_Interrupt_41:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 52
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
DebugStub_Interrupt_41_StartLoop:
hlt
Jmp DebugStub_Interrupt_41_StartLoop
DebugStub_Interrupt_41_Exit:
IRet
DebugStub_Interrupt_42:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 52
Call DebugStub_ComWriteAL
Mov eax, 50
Call DebugStub_ComWriteAL
DebugStub_Interrupt_42_StartLoop:
hlt
Jmp DebugStub_Interrupt_42_StartLoop
DebugStub_Interrupt_42_Exit:
IRet
DebugStub_Interrupt_43:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 52
Call DebugStub_ComWriteAL
Mov eax, 51
Call DebugStub_ComWriteAL
DebugStub_Interrupt_43_StartLoop:
hlt
Jmp DebugStub_Interrupt_43_StartLoop
DebugStub_Interrupt_43_Exit:
IRet
DebugStub_Interrupt_44:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 52
Call DebugStub_ComWriteAL
Mov eax, 52
Call DebugStub_ComWriteAL
DebugStub_Interrupt_44_StartLoop:
hlt
Jmp DebugStub_Interrupt_44_StartLoop
DebugStub_Interrupt_44_Exit:
IRet
DebugStub_Interrupt_45:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 52
Call DebugStub_ComWriteAL
Mov eax, 53
Call DebugStub_ComWriteAL
DebugStub_Interrupt_45_StartLoop:
hlt
Jmp DebugStub_Interrupt_45_StartLoop
DebugStub_Interrupt_45_Exit:
IRet
DebugStub_Interrupt_46:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 52
Call DebugStub_ComWriteAL
Mov eax, 54
Call DebugStub_ComWriteAL
DebugStub_Interrupt_46_StartLoop:
hlt
Jmp DebugStub_Interrupt_46_StartLoop
DebugStub_Interrupt_46_Exit:
IRet
DebugStub_Interrupt_47:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 52
Call DebugStub_ComWriteAL
Mov eax, 55
Call DebugStub_ComWriteAL
DebugStub_Interrupt_47_StartLoop:
hlt
Jmp DebugStub_Interrupt_47_StartLoop
DebugStub_Interrupt_47_Exit:
IRet
DebugStub_Interrupt_48:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 52
Call DebugStub_ComWriteAL
Mov eax, 56
Call DebugStub_ComWriteAL
DebugStub_Interrupt_48_StartLoop:
hlt
Jmp DebugStub_Interrupt_48_StartLoop
DebugStub_Interrupt_48_Exit:
IRet
DebugStub_Interrupt_49:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 52
Call DebugStub_ComWriteAL
Mov eax, 57
Call DebugStub_ComWriteAL
DebugStub_Interrupt_49_StartLoop:
hlt
Jmp DebugStub_Interrupt_49_StartLoop
DebugStub_Interrupt_49_Exit:
IRet
DebugStub_Interrupt_50:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 53
Call DebugStub_ComWriteAL
Mov eax, 48
Call DebugStub_ComWriteAL
DebugStub_Interrupt_50_StartLoop:
hlt
Jmp DebugStub_Interrupt_50_StartLoop
DebugStub_Interrupt_50_Exit:
IRet
DebugStub_Interrupt_51:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 53
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
DebugStub_Interrupt_51_StartLoop:
hlt
Jmp DebugStub_Interrupt_51_StartLoop
DebugStub_Interrupt_51_Exit:
IRet
DebugStub_Interrupt_52:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 53
Call DebugStub_ComWriteAL
Mov eax, 50
Call DebugStub_ComWriteAL
DebugStub_Interrupt_52_StartLoop:
hlt
Jmp DebugStub_Interrupt_52_StartLoop
DebugStub_Interrupt_52_Exit:
IRet
DebugStub_Interrupt_53:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 53
Call DebugStub_ComWriteAL
Mov eax, 51
Call DebugStub_ComWriteAL
DebugStub_Interrupt_53_StartLoop:
hlt
Jmp DebugStub_Interrupt_53_StartLoop
DebugStub_Interrupt_53_Exit:
IRet
DebugStub_Interrupt_54:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 53
Call DebugStub_ComWriteAL
Mov eax, 52
Call DebugStub_ComWriteAL
DebugStub_Interrupt_54_StartLoop:
hlt
Jmp DebugStub_Interrupt_54_StartLoop
DebugStub_Interrupt_54_Exit:
IRet
DebugStub_Interrupt_55:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 53
Call DebugStub_ComWriteAL
Mov eax, 53
Call DebugStub_ComWriteAL
DebugStub_Interrupt_55_StartLoop:
hlt
Jmp DebugStub_Interrupt_55_StartLoop
DebugStub_Interrupt_55_Exit:
IRet
DebugStub_Interrupt_56:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 53
Call DebugStub_ComWriteAL
Mov eax, 54
Call DebugStub_ComWriteAL
DebugStub_Interrupt_56_StartLoop:
hlt
Jmp DebugStub_Interrupt_56_StartLoop
DebugStub_Interrupt_56_Exit:
IRet
DebugStub_Interrupt_57:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 53
Call DebugStub_ComWriteAL
Mov eax, 55
Call DebugStub_ComWriteAL
DebugStub_Interrupt_57_StartLoop:
hlt
Jmp DebugStub_Interrupt_57_StartLoop
DebugStub_Interrupt_57_Exit:
IRet
DebugStub_Interrupt_58:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 53
Call DebugStub_ComWriteAL
Mov eax, 56
Call DebugStub_ComWriteAL
DebugStub_Interrupt_58_StartLoop:
hlt
Jmp DebugStub_Interrupt_58_StartLoop
DebugStub_Interrupt_58_Exit:
IRet
DebugStub_Interrupt_59:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 53
Call DebugStub_ComWriteAL
Mov eax, 57
Call DebugStub_ComWriteAL
DebugStub_Interrupt_59_StartLoop:
hlt
Jmp DebugStub_Interrupt_59_StartLoop
DebugStub_Interrupt_59_Exit:
IRet
DebugStub_Interrupt_60:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 54
Call DebugStub_ComWriteAL
Mov eax, 48
Call DebugStub_ComWriteAL
DebugStub_Interrupt_60_StartLoop:
hlt
Jmp DebugStub_Interrupt_60_StartLoop
DebugStub_Interrupt_60_Exit:
IRet
DebugStub_Interrupt_61:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 54
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
DebugStub_Interrupt_61_StartLoop:
hlt
Jmp DebugStub_Interrupt_61_StartLoop
DebugStub_Interrupt_61_Exit:
IRet
DebugStub_Interrupt_62:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 54
Call DebugStub_ComWriteAL
Mov eax, 50
Call DebugStub_ComWriteAL
DebugStub_Interrupt_62_StartLoop:
hlt
Jmp DebugStub_Interrupt_62_StartLoop
DebugStub_Interrupt_62_Exit:
IRet
DebugStub_Interrupt_63:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 54
Call DebugStub_ComWriteAL
Mov eax, 51
Call DebugStub_ComWriteAL
DebugStub_Interrupt_63_StartLoop:
hlt
Jmp DebugStub_Interrupt_63_StartLoop
DebugStub_Interrupt_63_Exit:
IRet
DebugStub_Interrupt_64:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 54
Call DebugStub_ComWriteAL
Mov eax, 52
Call DebugStub_ComWriteAL
DebugStub_Interrupt_64_StartLoop:
hlt
Jmp DebugStub_Interrupt_64_StartLoop
DebugStub_Interrupt_64_Exit:
IRet
DebugStub_Interrupt_65:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 54
Call DebugStub_ComWriteAL
Mov eax, 53
Call DebugStub_ComWriteAL
DebugStub_Interrupt_65_StartLoop:
hlt
Jmp DebugStub_Interrupt_65_StartLoop
DebugStub_Interrupt_65_Exit:
IRet
DebugStub_Interrupt_66:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 54
Call DebugStub_ComWriteAL
Mov eax, 54
Call DebugStub_ComWriteAL
DebugStub_Interrupt_66_StartLoop:
hlt
Jmp DebugStub_Interrupt_66_StartLoop
DebugStub_Interrupt_66_Exit:
IRet
DebugStub_Interrupt_67:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 54
Call DebugStub_ComWriteAL
Mov eax, 55
Call DebugStub_ComWriteAL
DebugStub_Interrupt_67_StartLoop:
hlt
Jmp DebugStub_Interrupt_67_StartLoop
DebugStub_Interrupt_67_Exit:
IRet
DebugStub_Interrupt_68:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 54
Call DebugStub_ComWriteAL
Mov eax, 56
Call DebugStub_ComWriteAL
DebugStub_Interrupt_68_StartLoop:
hlt
Jmp DebugStub_Interrupt_68_StartLoop
DebugStub_Interrupt_68_Exit:
IRet
DebugStub_Interrupt_69:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 54
Call DebugStub_ComWriteAL
Mov eax, 57
Call DebugStub_ComWriteAL
DebugStub_Interrupt_69_StartLoop:
hlt
Jmp DebugStub_Interrupt_69_StartLoop
DebugStub_Interrupt_69_Exit:
IRet
DebugStub_Interrupt_70:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 55
Call DebugStub_ComWriteAL
Mov eax, 48
Call DebugStub_ComWriteAL
DebugStub_Interrupt_70_StartLoop:
hlt
Jmp DebugStub_Interrupt_70_StartLoop
DebugStub_Interrupt_70_Exit:
IRet
DebugStub_Interrupt_71:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 55
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
DebugStub_Interrupt_71_StartLoop:
hlt
Jmp DebugStub_Interrupt_71_StartLoop
DebugStub_Interrupt_71_Exit:
IRet
DebugStub_Interrupt_72:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 55
Call DebugStub_ComWriteAL
Mov eax, 50
Call DebugStub_ComWriteAL
DebugStub_Interrupt_72_StartLoop:
hlt
Jmp DebugStub_Interrupt_72_StartLoop
DebugStub_Interrupt_72_Exit:
IRet
DebugStub_Interrupt_73:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 55
Call DebugStub_ComWriteAL
Mov eax, 51
Call DebugStub_ComWriteAL
DebugStub_Interrupt_73_StartLoop:
hlt
Jmp DebugStub_Interrupt_73_StartLoop
DebugStub_Interrupt_73_Exit:
IRet
DebugStub_Interrupt_74:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 55
Call DebugStub_ComWriteAL
Mov eax, 52
Call DebugStub_ComWriteAL
DebugStub_Interrupt_74_StartLoop:
hlt
Jmp DebugStub_Interrupt_74_StartLoop
DebugStub_Interrupt_74_Exit:
IRet
DebugStub_Interrupt_75:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 55
Call DebugStub_ComWriteAL
Mov eax, 53
Call DebugStub_ComWriteAL
DebugStub_Interrupt_75_StartLoop:
hlt
Jmp DebugStub_Interrupt_75_StartLoop
DebugStub_Interrupt_75_Exit:
IRet
DebugStub_Interrupt_76:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 55
Call DebugStub_ComWriteAL
Mov eax, 54
Call DebugStub_ComWriteAL
DebugStub_Interrupt_76_StartLoop:
hlt
Jmp DebugStub_Interrupt_76_StartLoop
DebugStub_Interrupt_76_Exit:
IRet
DebugStub_Interrupt_77:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 55
Call DebugStub_ComWriteAL
Mov eax, 55
Call DebugStub_ComWriteAL
DebugStub_Interrupt_77_StartLoop:
hlt
Jmp DebugStub_Interrupt_77_StartLoop
DebugStub_Interrupt_77_Exit:
IRet
DebugStub_Interrupt_78:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 55
Call DebugStub_ComWriteAL
Mov eax, 56
Call DebugStub_ComWriteAL
DebugStub_Interrupt_78_StartLoop:
hlt
Jmp DebugStub_Interrupt_78_StartLoop
DebugStub_Interrupt_78_Exit:
IRet
DebugStub_Interrupt_79:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 55
Call DebugStub_ComWriteAL
Mov eax, 57
Call DebugStub_ComWriteAL
DebugStub_Interrupt_79_StartLoop:
hlt
Jmp DebugStub_Interrupt_79_StartLoop
DebugStub_Interrupt_79_Exit:
IRet
DebugStub_Interrupt_80:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 56
Call DebugStub_ComWriteAL
Mov eax, 48
Call DebugStub_ComWriteAL
DebugStub_Interrupt_80_StartLoop:
hlt
Jmp DebugStub_Interrupt_80_StartLoop
DebugStub_Interrupt_80_Exit:
IRet
DebugStub_Interrupt_81:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 56
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
DebugStub_Interrupt_81_StartLoop:
hlt
Jmp DebugStub_Interrupt_81_StartLoop
DebugStub_Interrupt_81_Exit:
IRet
DebugStub_Interrupt_82:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 56
Call DebugStub_ComWriteAL
Mov eax, 50
Call DebugStub_ComWriteAL
DebugStub_Interrupt_82_StartLoop:
hlt
Jmp DebugStub_Interrupt_82_StartLoop
DebugStub_Interrupt_82_Exit:
IRet
DebugStub_Interrupt_83:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 56
Call DebugStub_ComWriteAL
Mov eax, 51
Call DebugStub_ComWriteAL
DebugStub_Interrupt_83_StartLoop:
hlt
Jmp DebugStub_Interrupt_83_StartLoop
DebugStub_Interrupt_83_Exit:
IRet
DebugStub_Interrupt_84:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 56
Call DebugStub_ComWriteAL
Mov eax, 52
Call DebugStub_ComWriteAL
DebugStub_Interrupt_84_StartLoop:
hlt
Jmp DebugStub_Interrupt_84_StartLoop
DebugStub_Interrupt_84_Exit:
IRet
DebugStub_Interrupt_85:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 56
Call DebugStub_ComWriteAL
Mov eax, 53
Call DebugStub_ComWriteAL
DebugStub_Interrupt_85_StartLoop:
hlt
Jmp DebugStub_Interrupt_85_StartLoop
DebugStub_Interrupt_85_Exit:
IRet
DebugStub_Interrupt_86:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 56
Call DebugStub_ComWriteAL
Mov eax, 54
Call DebugStub_ComWriteAL
DebugStub_Interrupt_86_StartLoop:
hlt
Jmp DebugStub_Interrupt_86_StartLoop
DebugStub_Interrupt_86_Exit:
IRet
DebugStub_Interrupt_87:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 56
Call DebugStub_ComWriteAL
Mov eax, 55
Call DebugStub_ComWriteAL
DebugStub_Interrupt_87_StartLoop:
hlt
Jmp DebugStub_Interrupt_87_StartLoop
DebugStub_Interrupt_87_Exit:
IRet
DebugStub_Interrupt_88:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 56
Call DebugStub_ComWriteAL
Mov eax, 56
Call DebugStub_ComWriteAL
DebugStub_Interrupt_88_StartLoop:
hlt
Jmp DebugStub_Interrupt_88_StartLoop
DebugStub_Interrupt_88_Exit:
IRet
DebugStub_Interrupt_89:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 56
Call DebugStub_ComWriteAL
Mov eax, 57
Call DebugStub_ComWriteAL
DebugStub_Interrupt_89_StartLoop:
hlt
Jmp DebugStub_Interrupt_89_StartLoop
DebugStub_Interrupt_89_Exit:
IRet
DebugStub_Interrupt_90:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 57
Call DebugStub_ComWriteAL
Mov eax, 48
Call DebugStub_ComWriteAL
DebugStub_Interrupt_90_StartLoop:
hlt
Jmp DebugStub_Interrupt_90_StartLoop
DebugStub_Interrupt_90_Exit:
IRet
DebugStub_Interrupt_91:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 57
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
DebugStub_Interrupt_91_StartLoop:
hlt
Jmp DebugStub_Interrupt_91_StartLoop
DebugStub_Interrupt_91_Exit:
IRet
DebugStub_Interrupt_92:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 57
Call DebugStub_ComWriteAL
Mov eax, 50
Call DebugStub_ComWriteAL
DebugStub_Interrupt_92_StartLoop:
hlt
Jmp DebugStub_Interrupt_92_StartLoop
DebugStub_Interrupt_92_Exit:
IRet
DebugStub_Interrupt_93:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 57
Call DebugStub_ComWriteAL
Mov eax, 51
Call DebugStub_ComWriteAL
DebugStub_Interrupt_93_StartLoop:
hlt
Jmp DebugStub_Interrupt_93_StartLoop
DebugStub_Interrupt_93_Exit:
IRet
DebugStub_Interrupt_94:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 57
Call DebugStub_ComWriteAL
Mov eax, 52
Call DebugStub_ComWriteAL
DebugStub_Interrupt_94_StartLoop:
hlt
Jmp DebugStub_Interrupt_94_StartLoop
DebugStub_Interrupt_94_Exit:
IRet
DebugStub_Interrupt_95:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 57
Call DebugStub_ComWriteAL
Mov eax, 53
Call DebugStub_ComWriteAL
DebugStub_Interrupt_95_StartLoop:
hlt
Jmp DebugStub_Interrupt_95_StartLoop
DebugStub_Interrupt_95_Exit:
IRet
DebugStub_Interrupt_96:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 57
Call DebugStub_ComWriteAL
Mov eax, 54
Call DebugStub_ComWriteAL
DebugStub_Interrupt_96_StartLoop:
hlt
Jmp DebugStub_Interrupt_96_StartLoop
DebugStub_Interrupt_96_Exit:
IRet
DebugStub_Interrupt_97:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 57
Call DebugStub_ComWriteAL
Mov eax, 55
Call DebugStub_ComWriteAL
DebugStub_Interrupt_97_StartLoop:
hlt
Jmp DebugStub_Interrupt_97_StartLoop
DebugStub_Interrupt_97_Exit:
IRet
DebugStub_Interrupt_98:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 57
Call DebugStub_ComWriteAL
Mov eax, 56
Call DebugStub_ComWriteAL
DebugStub_Interrupt_98_StartLoop:
hlt
Jmp DebugStub_Interrupt_98_StartLoop
DebugStub_Interrupt_98_Exit:
IRet
DebugStub_Interrupt_99:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 57
Call DebugStub_ComWriteAL
Mov eax, 57
Call DebugStub_ComWriteAL
DebugStub_Interrupt_99_StartLoop:
hlt
Jmp DebugStub_Interrupt_99_StartLoop
DebugStub_Interrupt_99_Exit:
IRet
DebugStub_Interrupt_100:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
Mov eax, 48
Call DebugStub_ComWriteAL
Mov eax, 48
Call DebugStub_ComWriteAL
DebugStub_Interrupt_100_StartLoop:
hlt
Jmp DebugStub_Interrupt_100_StartLoop
DebugStub_Interrupt_100_Exit:
IRet
DebugStub_Interrupt_101:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
Mov eax, 48
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
DebugStub_Interrupt_101_StartLoop:
hlt
Jmp DebugStub_Interrupt_101_StartLoop
DebugStub_Interrupt_101_Exit:
IRet
DebugStub_Interrupt_102:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
Mov eax, 48
Call DebugStub_ComWriteAL
Mov eax, 50
Call DebugStub_ComWriteAL
DebugStub_Interrupt_102_StartLoop:
hlt
Jmp DebugStub_Interrupt_102_StartLoop
DebugStub_Interrupt_102_Exit:
IRet
DebugStub_Interrupt_103:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
Mov eax, 48
Call DebugStub_ComWriteAL
Mov eax, 51
Call DebugStub_ComWriteAL
DebugStub_Interrupt_103_StartLoop:
hlt
Jmp DebugStub_Interrupt_103_StartLoop
DebugStub_Interrupt_103_Exit:
IRet
DebugStub_Interrupt_104:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
Mov eax, 48
Call DebugStub_ComWriteAL
Mov eax, 52
Call DebugStub_ComWriteAL
DebugStub_Interrupt_104_StartLoop:
hlt
Jmp DebugStub_Interrupt_104_StartLoop
DebugStub_Interrupt_104_Exit:
IRet
DebugStub_Interrupt_105:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
Mov eax, 48
Call DebugStub_ComWriteAL
Mov eax, 53
Call DebugStub_ComWriteAL
DebugStub_Interrupt_105_StartLoop:
hlt
Jmp DebugStub_Interrupt_105_StartLoop
DebugStub_Interrupt_105_Exit:
IRet
DebugStub_Interrupt_106:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
Mov eax, 48
Call DebugStub_ComWriteAL
Mov eax, 54
Call DebugStub_ComWriteAL
DebugStub_Interrupt_106_StartLoop:
hlt
Jmp DebugStub_Interrupt_106_StartLoop
DebugStub_Interrupt_106_Exit:
IRet
DebugStub_Interrupt_107:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
Mov eax, 48
Call DebugStub_ComWriteAL
Mov eax, 55
Call DebugStub_ComWriteAL
DebugStub_Interrupt_107_StartLoop:
hlt
Jmp DebugStub_Interrupt_107_StartLoop
DebugStub_Interrupt_107_Exit:
IRet
DebugStub_Interrupt_108:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
Mov eax, 48
Call DebugStub_ComWriteAL
Mov eax, 56
Call DebugStub_ComWriteAL
DebugStub_Interrupt_108_StartLoop:
hlt
Jmp DebugStub_Interrupt_108_StartLoop
DebugStub_Interrupt_108_Exit:
IRet
DebugStub_Interrupt_109:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
Mov eax, 48
Call DebugStub_ComWriteAL
Mov eax, 57
Call DebugStub_ComWriteAL
DebugStub_Interrupt_109_StartLoop:
hlt
Jmp DebugStub_Interrupt_109_StartLoop
DebugStub_Interrupt_109_Exit:
IRet
DebugStub_Interrupt_110:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
Mov eax, 48
Call DebugStub_ComWriteAL
DebugStub_Interrupt_110_StartLoop:
hlt
Jmp DebugStub_Interrupt_110_StartLoop
DebugStub_Interrupt_110_Exit:
IRet
DebugStub_Interrupt_111:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
DebugStub_Interrupt_111_StartLoop:
hlt
Jmp DebugStub_Interrupt_111_StartLoop
DebugStub_Interrupt_111_Exit:
IRet
DebugStub_Interrupt_112:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
Mov eax, 50
Call DebugStub_ComWriteAL
DebugStub_Interrupt_112_StartLoop:
hlt
Jmp DebugStub_Interrupt_112_StartLoop
DebugStub_Interrupt_112_Exit:
IRet
DebugStub_Interrupt_113:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
Mov eax, 51
Call DebugStub_ComWriteAL
DebugStub_Interrupt_113_StartLoop:
hlt
Jmp DebugStub_Interrupt_113_StartLoop
DebugStub_Interrupt_113_Exit:
IRet
DebugStub_Interrupt_114:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
Mov eax, 52
Call DebugStub_ComWriteAL
DebugStub_Interrupt_114_StartLoop:
hlt
Jmp DebugStub_Interrupt_114_StartLoop
DebugStub_Interrupt_114_Exit:
IRet
DebugStub_Interrupt_115:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
Mov eax, 53
Call DebugStub_ComWriteAL
DebugStub_Interrupt_115_StartLoop:
hlt
Jmp DebugStub_Interrupt_115_StartLoop
DebugStub_Interrupt_115_Exit:
IRet
DebugStub_Interrupt_116:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
Mov eax, 54
Call DebugStub_ComWriteAL
DebugStub_Interrupt_116_StartLoop:
hlt
Jmp DebugStub_Interrupt_116_StartLoop
DebugStub_Interrupt_116_Exit:
IRet
DebugStub_Interrupt_117:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
Mov eax, 55
Call DebugStub_ComWriteAL
DebugStub_Interrupt_117_StartLoop:
hlt
Jmp DebugStub_Interrupt_117_StartLoop
DebugStub_Interrupt_117_Exit:
IRet
DebugStub_Interrupt_118:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
Mov eax, 56
Call DebugStub_ComWriteAL
DebugStub_Interrupt_118_StartLoop:
hlt
Jmp DebugStub_Interrupt_118_StartLoop
DebugStub_Interrupt_118_Exit:
IRet
DebugStub_Interrupt_119:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
Mov eax, 57
Call DebugStub_ComWriteAL
DebugStub_Interrupt_119_StartLoop:
hlt
Jmp DebugStub_Interrupt_119_StartLoop
DebugStub_Interrupt_119_Exit:
IRet
DebugStub_Interrupt_120:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
Mov eax, 50
Call DebugStub_ComWriteAL
Mov eax, 48
Call DebugStub_ComWriteAL
DebugStub_Interrupt_120_StartLoop:
hlt
Jmp DebugStub_Interrupt_120_StartLoop
DebugStub_Interrupt_120_Exit:
IRet
DebugStub_Interrupt_121:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
Mov eax, 50
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
DebugStub_Interrupt_121_StartLoop:
hlt
Jmp DebugStub_Interrupt_121_StartLoop
DebugStub_Interrupt_121_Exit:
IRet
DebugStub_Interrupt_122:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
Mov eax, 50
Call DebugStub_ComWriteAL
Mov eax, 50
Call DebugStub_ComWriteAL
DebugStub_Interrupt_122_StartLoop:
hlt
Jmp DebugStub_Interrupt_122_StartLoop
DebugStub_Interrupt_122_Exit:
IRet
DebugStub_Interrupt_123:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
Mov eax, 50
Call DebugStub_ComWriteAL
Mov eax, 51
Call DebugStub_ComWriteAL
DebugStub_Interrupt_123_StartLoop:
hlt
Jmp DebugStub_Interrupt_123_StartLoop
DebugStub_Interrupt_123_Exit:
IRet
DebugStub_Interrupt_124:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
Mov eax, 50
Call DebugStub_ComWriteAL
Mov eax, 52
Call DebugStub_ComWriteAL
DebugStub_Interrupt_124_StartLoop:
hlt
Jmp DebugStub_Interrupt_124_StartLoop
DebugStub_Interrupt_124_Exit:
IRet
DebugStub_Interrupt_125:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
Mov eax, 50
Call DebugStub_ComWriteAL
Mov eax, 53
Call DebugStub_ComWriteAL
DebugStub_Interrupt_125_StartLoop:
hlt
Jmp DebugStub_Interrupt_125_StartLoop
DebugStub_Interrupt_125_Exit:
IRet
DebugStub_Interrupt_126:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
Mov eax, 50
Call DebugStub_ComWriteAL
Mov eax, 54
Call DebugStub_ComWriteAL
DebugStub_Interrupt_126_StartLoop:
hlt
Jmp DebugStub_Interrupt_126_StartLoop
DebugStub_Interrupt_126_Exit:
IRet
DebugStub_Interrupt_127:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
Mov eax, 50
Call DebugStub_ComWriteAL
Mov eax, 55
Call DebugStub_ComWriteAL
DebugStub_Interrupt_127_StartLoop:
hlt
Jmp DebugStub_Interrupt_127_StartLoop
DebugStub_Interrupt_127_Exit:
IRet
DebugStub_Interrupt_128:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
Mov eax, 50
Call DebugStub_ComWriteAL
Mov eax, 56
Call DebugStub_ComWriteAL
DebugStub_Interrupt_128_StartLoop:
hlt
Jmp DebugStub_Interrupt_128_StartLoop
DebugStub_Interrupt_128_Exit:
IRet
DebugStub_Interrupt_129:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
Mov eax, 50
Call DebugStub_ComWriteAL
Mov eax, 57
Call DebugStub_ComWriteAL
DebugStub_Interrupt_129_StartLoop:
hlt
Jmp DebugStub_Interrupt_129_StartLoop
DebugStub_Interrupt_129_Exit:
IRet
DebugStub_Interrupt_130:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
Mov eax, 51
Call DebugStub_ComWriteAL
Mov eax, 48
Call DebugStub_ComWriteAL
DebugStub_Interrupt_130_StartLoop:
hlt
Jmp DebugStub_Interrupt_130_StartLoop
DebugStub_Interrupt_130_Exit:
IRet
DebugStub_Interrupt_131:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
Mov eax, 51
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
DebugStub_Interrupt_131_StartLoop:
hlt
Jmp DebugStub_Interrupt_131_StartLoop
DebugStub_Interrupt_131_Exit:
IRet
DebugStub_Interrupt_132:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
Mov eax, 51
Call DebugStub_ComWriteAL
Mov eax, 50
Call DebugStub_ComWriteAL
DebugStub_Interrupt_132_StartLoop:
hlt
Jmp DebugStub_Interrupt_132_StartLoop
DebugStub_Interrupt_132_Exit:
IRet
DebugStub_Interrupt_133:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
Mov eax, 51
Call DebugStub_ComWriteAL
Mov eax, 51
Call DebugStub_ComWriteAL
DebugStub_Interrupt_133_StartLoop:
hlt
Jmp DebugStub_Interrupt_133_StartLoop
DebugStub_Interrupt_133_Exit:
IRet
DebugStub_Interrupt_134:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
Mov eax, 51
Call DebugStub_ComWriteAL
Mov eax, 52
Call DebugStub_ComWriteAL
DebugStub_Interrupt_134_StartLoop:
hlt
Jmp DebugStub_Interrupt_134_StartLoop
DebugStub_Interrupt_134_Exit:
IRet
DebugStub_Interrupt_135:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
Mov eax, 51
Call DebugStub_ComWriteAL
Mov eax, 53
Call DebugStub_ComWriteAL
DebugStub_Interrupt_135_StartLoop:
hlt
Jmp DebugStub_Interrupt_135_StartLoop
DebugStub_Interrupt_135_Exit:
IRet
DebugStub_Interrupt_136:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
Mov eax, 51
Call DebugStub_ComWriteAL
Mov eax, 54
Call DebugStub_ComWriteAL
DebugStub_Interrupt_136_StartLoop:
hlt
Jmp DebugStub_Interrupt_136_StartLoop
DebugStub_Interrupt_136_Exit:
IRet
DebugStub_Interrupt_137:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
Mov eax, 51
Call DebugStub_ComWriteAL
Mov eax, 55
Call DebugStub_ComWriteAL
DebugStub_Interrupt_137_StartLoop:
hlt
Jmp DebugStub_Interrupt_137_StartLoop
DebugStub_Interrupt_137_Exit:
IRet
DebugStub_Interrupt_138:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
Mov eax, 51
Call DebugStub_ComWriteAL
Mov eax, 56
Call DebugStub_ComWriteAL
DebugStub_Interrupt_138_StartLoop:
hlt
Jmp DebugStub_Interrupt_138_StartLoop
DebugStub_Interrupt_138_Exit:
IRet
DebugStub_Interrupt_139:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
Mov eax, 51
Call DebugStub_ComWriteAL
Mov eax, 57
Call DebugStub_ComWriteAL
DebugStub_Interrupt_139_StartLoop:
hlt
Jmp DebugStub_Interrupt_139_StartLoop
DebugStub_Interrupt_139_Exit:
IRet
DebugStub_Interrupt_140:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
Mov eax, 52
Call DebugStub_ComWriteAL
Mov eax, 48
Call DebugStub_ComWriteAL
DebugStub_Interrupt_140_StartLoop:
hlt
Jmp DebugStub_Interrupt_140_StartLoop
DebugStub_Interrupt_140_Exit:
IRet
DebugStub_Interrupt_141:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
Mov eax, 52
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
DebugStub_Interrupt_141_StartLoop:
hlt
Jmp DebugStub_Interrupt_141_StartLoop
DebugStub_Interrupt_141_Exit:
IRet
DebugStub_Interrupt_142:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
Mov eax, 52
Call DebugStub_ComWriteAL
Mov eax, 50
Call DebugStub_ComWriteAL
DebugStub_Interrupt_142_StartLoop:
hlt
Jmp DebugStub_Interrupt_142_StartLoop
DebugStub_Interrupt_142_Exit:
IRet
DebugStub_Interrupt_143:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
Mov eax, 52
Call DebugStub_ComWriteAL
Mov eax, 51
Call DebugStub_ComWriteAL
DebugStub_Interrupt_143_StartLoop:
hlt
Jmp DebugStub_Interrupt_143_StartLoop
DebugStub_Interrupt_143_Exit:
IRet
DebugStub_Interrupt_144:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
Mov eax, 52
Call DebugStub_ComWriteAL
Mov eax, 52
Call DebugStub_ComWriteAL
DebugStub_Interrupt_144_StartLoop:
hlt
Jmp DebugStub_Interrupt_144_StartLoop
DebugStub_Interrupt_144_Exit:
IRet
DebugStub_Interrupt_145:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
Mov eax, 52
Call DebugStub_ComWriteAL
Mov eax, 53
Call DebugStub_ComWriteAL
DebugStub_Interrupt_145_StartLoop:
hlt
Jmp DebugStub_Interrupt_145_StartLoop
DebugStub_Interrupt_145_Exit:
IRet
DebugStub_Interrupt_146:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
Mov eax, 52
Call DebugStub_ComWriteAL
Mov eax, 54
Call DebugStub_ComWriteAL
DebugStub_Interrupt_146_StartLoop:
hlt
Jmp DebugStub_Interrupt_146_StartLoop
DebugStub_Interrupt_146_Exit:
IRet
DebugStub_Interrupt_147:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
Mov eax, 52
Call DebugStub_ComWriteAL
Mov eax, 55
Call DebugStub_ComWriteAL
DebugStub_Interrupt_147_StartLoop:
hlt
Jmp DebugStub_Interrupt_147_StartLoop
DebugStub_Interrupt_147_Exit:
IRet
DebugStub_Interrupt_148:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
Mov eax, 52
Call DebugStub_ComWriteAL
Mov eax, 56
Call DebugStub_ComWriteAL
DebugStub_Interrupt_148_StartLoop:
hlt
Jmp DebugStub_Interrupt_148_StartLoop
DebugStub_Interrupt_148_Exit:
IRet
DebugStub_Interrupt_149:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
Mov eax, 52
Call DebugStub_ComWriteAL
Mov eax, 57
Call DebugStub_ComWriteAL
DebugStub_Interrupt_149_StartLoop:
hlt
Jmp DebugStub_Interrupt_149_StartLoop
DebugStub_Interrupt_149_Exit:
IRet
DebugStub_Interrupt_150:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
Mov eax, 53
Call DebugStub_ComWriteAL
Mov eax, 48
Call DebugStub_ComWriteAL
DebugStub_Interrupt_150_StartLoop:
hlt
Jmp DebugStub_Interrupt_150_StartLoop
DebugStub_Interrupt_150_Exit:
IRet
DebugStub_Interrupt_151:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
Mov eax, 53
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
DebugStub_Interrupt_151_StartLoop:
hlt
Jmp DebugStub_Interrupt_151_StartLoop
DebugStub_Interrupt_151_Exit:
IRet
DebugStub_Interrupt_152:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
Mov eax, 53
Call DebugStub_ComWriteAL
Mov eax, 50
Call DebugStub_ComWriteAL
DebugStub_Interrupt_152_StartLoop:
hlt
Jmp DebugStub_Interrupt_152_StartLoop
DebugStub_Interrupt_152_Exit:
IRet
DebugStub_Interrupt_153:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
Mov eax, 53
Call DebugStub_ComWriteAL
Mov eax, 51
Call DebugStub_ComWriteAL
DebugStub_Interrupt_153_StartLoop:
hlt
Jmp DebugStub_Interrupt_153_StartLoop
DebugStub_Interrupt_153_Exit:
IRet
DebugStub_Interrupt_154:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
Mov eax, 53
Call DebugStub_ComWriteAL
Mov eax, 52
Call DebugStub_ComWriteAL
DebugStub_Interrupt_154_StartLoop:
hlt
Jmp DebugStub_Interrupt_154_StartLoop
DebugStub_Interrupt_154_Exit:
IRet
DebugStub_Interrupt_155:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
Mov eax, 53
Call DebugStub_ComWriteAL
Mov eax, 53
Call DebugStub_ComWriteAL
DebugStub_Interrupt_155_StartLoop:
hlt
Jmp DebugStub_Interrupt_155_StartLoop
DebugStub_Interrupt_155_Exit:
IRet
DebugStub_Interrupt_156:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
Mov eax, 53
Call DebugStub_ComWriteAL
Mov eax, 54
Call DebugStub_ComWriteAL
DebugStub_Interrupt_156_StartLoop:
hlt
Jmp DebugStub_Interrupt_156_StartLoop
DebugStub_Interrupt_156_Exit:
IRet
DebugStub_Interrupt_157:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
Mov eax, 53
Call DebugStub_ComWriteAL
Mov eax, 55
Call DebugStub_ComWriteAL
DebugStub_Interrupt_157_StartLoop:
hlt
Jmp DebugStub_Interrupt_157_StartLoop
DebugStub_Interrupt_157_Exit:
IRet
DebugStub_Interrupt_158:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
Mov eax, 53
Call DebugStub_ComWriteAL
Mov eax, 56
Call DebugStub_ComWriteAL
DebugStub_Interrupt_158_StartLoop:
hlt
Jmp DebugStub_Interrupt_158_StartLoop
DebugStub_Interrupt_158_Exit:
IRet
DebugStub_Interrupt_159:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
Mov eax, 53
Call DebugStub_ComWriteAL
Mov eax, 57
Call DebugStub_ComWriteAL
DebugStub_Interrupt_159_StartLoop:
hlt
Jmp DebugStub_Interrupt_159_StartLoop
DebugStub_Interrupt_159_Exit:
IRet
DebugStub_Interrupt_160:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
Mov eax, 54
Call DebugStub_ComWriteAL
Mov eax, 48
Call DebugStub_ComWriteAL
DebugStub_Interrupt_160_StartLoop:
hlt
Jmp DebugStub_Interrupt_160_StartLoop
DebugStub_Interrupt_160_Exit:
IRet
DebugStub_Interrupt_161:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
Mov eax, 54
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
DebugStub_Interrupt_161_StartLoop:
hlt
Jmp DebugStub_Interrupt_161_StartLoop
DebugStub_Interrupt_161_Exit:
IRet
DebugStub_Interrupt_162:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
Mov eax, 54
Call DebugStub_ComWriteAL
Mov eax, 50
Call DebugStub_ComWriteAL
DebugStub_Interrupt_162_StartLoop:
hlt
Jmp DebugStub_Interrupt_162_StartLoop
DebugStub_Interrupt_162_Exit:
IRet
DebugStub_Interrupt_163:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
Mov eax, 54
Call DebugStub_ComWriteAL
Mov eax, 51
Call DebugStub_ComWriteAL
DebugStub_Interrupt_163_StartLoop:
hlt
Jmp DebugStub_Interrupt_163_StartLoop
DebugStub_Interrupt_163_Exit:
IRet
DebugStub_Interrupt_164:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
Mov eax, 54
Call DebugStub_ComWriteAL
Mov eax, 52
Call DebugStub_ComWriteAL
DebugStub_Interrupt_164_StartLoop:
hlt
Jmp DebugStub_Interrupt_164_StartLoop
DebugStub_Interrupt_164_Exit:
IRet
DebugStub_Interrupt_165:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
Mov eax, 54
Call DebugStub_ComWriteAL
Mov eax, 53
Call DebugStub_ComWriteAL
DebugStub_Interrupt_165_StartLoop:
hlt
Jmp DebugStub_Interrupt_165_StartLoop
DebugStub_Interrupt_165_Exit:
IRet
DebugStub_Interrupt_166:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
Mov eax, 54
Call DebugStub_ComWriteAL
Mov eax, 54
Call DebugStub_ComWriteAL
DebugStub_Interrupt_166_StartLoop:
hlt
Jmp DebugStub_Interrupt_166_StartLoop
DebugStub_Interrupt_166_Exit:
IRet
DebugStub_Interrupt_167:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
Mov eax, 54
Call DebugStub_ComWriteAL
Mov eax, 55
Call DebugStub_ComWriteAL
DebugStub_Interrupt_167_StartLoop:
hlt
Jmp DebugStub_Interrupt_167_StartLoop
DebugStub_Interrupt_167_Exit:
IRet
DebugStub_Interrupt_168:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
Mov eax, 54
Call DebugStub_ComWriteAL
Mov eax, 56
Call DebugStub_ComWriteAL
DebugStub_Interrupt_168_StartLoop:
hlt
Jmp DebugStub_Interrupt_168_StartLoop
DebugStub_Interrupt_168_Exit:
IRet
DebugStub_Interrupt_169:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
Mov eax, 54
Call DebugStub_ComWriteAL
Mov eax, 57
Call DebugStub_ComWriteAL
DebugStub_Interrupt_169_StartLoop:
hlt
Jmp DebugStub_Interrupt_169_StartLoop
DebugStub_Interrupt_169_Exit:
IRet
DebugStub_Interrupt_170:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
Mov eax, 55
Call DebugStub_ComWriteAL
Mov eax, 48
Call DebugStub_ComWriteAL
DebugStub_Interrupt_170_StartLoop:
hlt
Jmp DebugStub_Interrupt_170_StartLoop
DebugStub_Interrupt_170_Exit:
IRet
DebugStub_Interrupt_171:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
Mov eax, 55
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
DebugStub_Interrupt_171_StartLoop:
hlt
Jmp DebugStub_Interrupt_171_StartLoop
DebugStub_Interrupt_171_Exit:
IRet
DebugStub_Interrupt_172:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
Mov eax, 55
Call DebugStub_ComWriteAL
Mov eax, 50
Call DebugStub_ComWriteAL
DebugStub_Interrupt_172_StartLoop:
hlt
Jmp DebugStub_Interrupt_172_StartLoop
DebugStub_Interrupt_172_Exit:
IRet
DebugStub_Interrupt_173:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
Mov eax, 55
Call DebugStub_ComWriteAL
Mov eax, 51
Call DebugStub_ComWriteAL
DebugStub_Interrupt_173_StartLoop:
hlt
Jmp DebugStub_Interrupt_173_StartLoop
DebugStub_Interrupt_173_Exit:
IRet
DebugStub_Interrupt_174:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
Mov eax, 55
Call DebugStub_ComWriteAL
Mov eax, 52
Call DebugStub_ComWriteAL
DebugStub_Interrupt_174_StartLoop:
hlt
Jmp DebugStub_Interrupt_174_StartLoop
DebugStub_Interrupt_174_Exit:
IRet
DebugStub_Interrupt_175:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
Mov eax, 55
Call DebugStub_ComWriteAL
Mov eax, 53
Call DebugStub_ComWriteAL
DebugStub_Interrupt_175_StartLoop:
hlt
Jmp DebugStub_Interrupt_175_StartLoop
DebugStub_Interrupt_175_Exit:
IRet
DebugStub_Interrupt_176:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
Mov eax, 55
Call DebugStub_ComWriteAL
Mov eax, 54
Call DebugStub_ComWriteAL
DebugStub_Interrupt_176_StartLoop:
hlt
Jmp DebugStub_Interrupt_176_StartLoop
DebugStub_Interrupt_176_Exit:
IRet
DebugStub_Interrupt_177:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
Mov eax, 55
Call DebugStub_ComWriteAL
Mov eax, 55
Call DebugStub_ComWriteAL
DebugStub_Interrupt_177_StartLoop:
hlt
Jmp DebugStub_Interrupt_177_StartLoop
DebugStub_Interrupt_177_Exit:
IRet
DebugStub_Interrupt_178:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
Mov eax, 55
Call DebugStub_ComWriteAL
Mov eax, 56
Call DebugStub_ComWriteAL
DebugStub_Interrupt_178_StartLoop:
hlt
Jmp DebugStub_Interrupt_178_StartLoop
DebugStub_Interrupt_178_Exit:
IRet
DebugStub_Interrupt_179:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
Mov eax, 55
Call DebugStub_ComWriteAL
Mov eax, 57
Call DebugStub_ComWriteAL
DebugStub_Interrupt_179_StartLoop:
hlt
Jmp DebugStub_Interrupt_179_StartLoop
DebugStub_Interrupt_179_Exit:
IRet
DebugStub_Interrupt_180:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
Mov eax, 56
Call DebugStub_ComWriteAL
Mov eax, 48
Call DebugStub_ComWriteAL
DebugStub_Interrupt_180_StartLoop:
hlt
Jmp DebugStub_Interrupt_180_StartLoop
DebugStub_Interrupt_180_Exit:
IRet
DebugStub_Interrupt_181:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
Mov eax, 56
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
DebugStub_Interrupt_181_StartLoop:
hlt
Jmp DebugStub_Interrupt_181_StartLoop
DebugStub_Interrupt_181_Exit:
IRet
DebugStub_Interrupt_182:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
Mov eax, 56
Call DebugStub_ComWriteAL
Mov eax, 50
Call DebugStub_ComWriteAL
DebugStub_Interrupt_182_StartLoop:
hlt
Jmp DebugStub_Interrupt_182_StartLoop
DebugStub_Interrupt_182_Exit:
IRet
DebugStub_Interrupt_183:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
Mov eax, 56
Call DebugStub_ComWriteAL
Mov eax, 51
Call DebugStub_ComWriteAL
DebugStub_Interrupt_183_StartLoop:
hlt
Jmp DebugStub_Interrupt_183_StartLoop
DebugStub_Interrupt_183_Exit:
IRet
DebugStub_Interrupt_184:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
Mov eax, 56
Call DebugStub_ComWriteAL
Mov eax, 52
Call DebugStub_ComWriteAL
DebugStub_Interrupt_184_StartLoop:
hlt
Jmp DebugStub_Interrupt_184_StartLoop
DebugStub_Interrupt_184_Exit:
IRet
DebugStub_Interrupt_185:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
Mov eax, 56
Call DebugStub_ComWriteAL
Mov eax, 53
Call DebugStub_ComWriteAL
DebugStub_Interrupt_185_StartLoop:
hlt
Jmp DebugStub_Interrupt_185_StartLoop
DebugStub_Interrupt_185_Exit:
IRet
DebugStub_Interrupt_186:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
Mov eax, 56
Call DebugStub_ComWriteAL
Mov eax, 54
Call DebugStub_ComWriteAL
DebugStub_Interrupt_186_StartLoop:
hlt
Jmp DebugStub_Interrupt_186_StartLoop
DebugStub_Interrupt_186_Exit:
IRet
DebugStub_Interrupt_187:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
Mov eax, 56
Call DebugStub_ComWriteAL
Mov eax, 55
Call DebugStub_ComWriteAL
DebugStub_Interrupt_187_StartLoop:
hlt
Jmp DebugStub_Interrupt_187_StartLoop
DebugStub_Interrupt_187_Exit:
IRet
DebugStub_Interrupt_188:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
Mov eax, 56
Call DebugStub_ComWriteAL
Mov eax, 56
Call DebugStub_ComWriteAL
DebugStub_Interrupt_188_StartLoop:
hlt
Jmp DebugStub_Interrupt_188_StartLoop
DebugStub_Interrupt_188_Exit:
IRet
DebugStub_Interrupt_189:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
Mov eax, 56
Call DebugStub_ComWriteAL
Mov eax, 57
Call DebugStub_ComWriteAL
DebugStub_Interrupt_189_StartLoop:
hlt
Jmp DebugStub_Interrupt_189_StartLoop
DebugStub_Interrupt_189_Exit:
IRet
DebugStub_Interrupt_190:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
Mov eax, 57
Call DebugStub_ComWriteAL
Mov eax, 48
Call DebugStub_ComWriteAL
DebugStub_Interrupt_190_StartLoop:
hlt
Jmp DebugStub_Interrupt_190_StartLoop
DebugStub_Interrupt_190_Exit:
IRet
DebugStub_Interrupt_191:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
Mov eax, 57
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
DebugStub_Interrupt_191_StartLoop:
hlt
Jmp DebugStub_Interrupt_191_StartLoop
DebugStub_Interrupt_191_Exit:
IRet
DebugStub_Interrupt_192:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
Mov eax, 57
Call DebugStub_ComWriteAL
Mov eax, 50
Call DebugStub_ComWriteAL
DebugStub_Interrupt_192_StartLoop:
hlt
Jmp DebugStub_Interrupt_192_StartLoop
DebugStub_Interrupt_192_Exit:
IRet
DebugStub_Interrupt_193:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
Mov eax, 57
Call DebugStub_ComWriteAL
Mov eax, 51
Call DebugStub_ComWriteAL
DebugStub_Interrupt_193_StartLoop:
hlt
Jmp DebugStub_Interrupt_193_StartLoop
DebugStub_Interrupt_193_Exit:
IRet
DebugStub_Interrupt_194:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
Mov eax, 57
Call DebugStub_ComWriteAL
Mov eax, 52
Call DebugStub_ComWriteAL
DebugStub_Interrupt_194_StartLoop:
hlt
Jmp DebugStub_Interrupt_194_StartLoop
DebugStub_Interrupt_194_Exit:
IRet
DebugStub_Interrupt_195:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
Mov eax, 57
Call DebugStub_ComWriteAL
Mov eax, 53
Call DebugStub_ComWriteAL
DebugStub_Interrupt_195_StartLoop:
hlt
Jmp DebugStub_Interrupt_195_StartLoop
DebugStub_Interrupt_195_Exit:
IRet
DebugStub_Interrupt_196:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
Mov eax, 57
Call DebugStub_ComWriteAL
Mov eax, 54
Call DebugStub_ComWriteAL
DebugStub_Interrupt_196_StartLoop:
hlt
Jmp DebugStub_Interrupt_196_StartLoop
DebugStub_Interrupt_196_Exit:
IRet
DebugStub_Interrupt_197:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
Mov eax, 57
Call DebugStub_ComWriteAL
Mov eax, 55
Call DebugStub_ComWriteAL
DebugStub_Interrupt_197_StartLoop:
hlt
Jmp DebugStub_Interrupt_197_StartLoop
DebugStub_Interrupt_197_Exit:
IRet
DebugStub_Interrupt_198:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
Mov eax, 57
Call DebugStub_ComWriteAL
Mov eax, 56
Call DebugStub_ComWriteAL
DebugStub_Interrupt_198_StartLoop:
hlt
Jmp DebugStub_Interrupt_198_StartLoop
DebugStub_Interrupt_198_Exit:
IRet
DebugStub_Interrupt_199:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
Mov eax, 57
Call DebugStub_ComWriteAL
Mov eax, 57
Call DebugStub_ComWriteAL
DebugStub_Interrupt_199_StartLoop:
hlt
Jmp DebugStub_Interrupt_199_StartLoop
DebugStub_Interrupt_199_Exit:
IRet
DebugStub_Interrupt_200:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 50
Call DebugStub_ComWriteAL
Mov eax, 48
Call DebugStub_ComWriteAL
Mov eax, 48
Call DebugStub_ComWriteAL
DebugStub_Interrupt_200_StartLoop:
hlt
Jmp DebugStub_Interrupt_200_StartLoop
DebugStub_Interrupt_200_Exit:
IRet
DebugStub_Interrupt_201:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 50
Call DebugStub_ComWriteAL
Mov eax, 48
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
DebugStub_Interrupt_201_StartLoop:
hlt
Jmp DebugStub_Interrupt_201_StartLoop
DebugStub_Interrupt_201_Exit:
IRet
DebugStub_Interrupt_202:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 50
Call DebugStub_ComWriteAL
Mov eax, 48
Call DebugStub_ComWriteAL
Mov eax, 50
Call DebugStub_ComWriteAL
DebugStub_Interrupt_202_StartLoop:
hlt
Jmp DebugStub_Interrupt_202_StartLoop
DebugStub_Interrupt_202_Exit:
IRet
DebugStub_Interrupt_203:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 50
Call DebugStub_ComWriteAL
Mov eax, 48
Call DebugStub_ComWriteAL
Mov eax, 51
Call DebugStub_ComWriteAL
DebugStub_Interrupt_203_StartLoop:
hlt
Jmp DebugStub_Interrupt_203_StartLoop
DebugStub_Interrupt_203_Exit:
IRet
DebugStub_Interrupt_204:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 50
Call DebugStub_ComWriteAL
Mov eax, 48
Call DebugStub_ComWriteAL
Mov eax, 52
Call DebugStub_ComWriteAL
DebugStub_Interrupt_204_StartLoop:
hlt
Jmp DebugStub_Interrupt_204_StartLoop
DebugStub_Interrupt_204_Exit:
IRet
DebugStub_Interrupt_205:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 50
Call DebugStub_ComWriteAL
Mov eax, 48
Call DebugStub_ComWriteAL
Mov eax, 53
Call DebugStub_ComWriteAL
DebugStub_Interrupt_205_StartLoop:
hlt
Jmp DebugStub_Interrupt_205_StartLoop
DebugStub_Interrupt_205_Exit:
IRet
DebugStub_Interrupt_206:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 50
Call DebugStub_ComWriteAL
Mov eax, 48
Call DebugStub_ComWriteAL
Mov eax, 54
Call DebugStub_ComWriteAL
DebugStub_Interrupt_206_StartLoop:
hlt
Jmp DebugStub_Interrupt_206_StartLoop
DebugStub_Interrupt_206_Exit:
IRet
DebugStub_Interrupt_207:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 50
Call DebugStub_ComWriteAL
Mov eax, 48
Call DebugStub_ComWriteAL
Mov eax, 55
Call DebugStub_ComWriteAL
DebugStub_Interrupt_207_StartLoop:
hlt
Jmp DebugStub_Interrupt_207_StartLoop
DebugStub_Interrupt_207_Exit:
IRet
DebugStub_Interrupt_208:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 50
Call DebugStub_ComWriteAL
Mov eax, 48
Call DebugStub_ComWriteAL
Mov eax, 56
Call DebugStub_ComWriteAL
DebugStub_Interrupt_208_StartLoop:
hlt
Jmp DebugStub_Interrupt_208_StartLoop
DebugStub_Interrupt_208_Exit:
IRet
DebugStub_Interrupt_209:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 50
Call DebugStub_ComWriteAL
Mov eax, 48
Call DebugStub_ComWriteAL
Mov eax, 57
Call DebugStub_ComWriteAL
DebugStub_Interrupt_209_StartLoop:
hlt
Jmp DebugStub_Interrupt_209_StartLoop
DebugStub_Interrupt_209_Exit:
IRet
DebugStub_Interrupt_210:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 50
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
Mov eax, 48
Call DebugStub_ComWriteAL
DebugStub_Interrupt_210_StartLoop:
hlt
Jmp DebugStub_Interrupt_210_StartLoop
DebugStub_Interrupt_210_Exit:
IRet
DebugStub_Interrupt_211:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 50
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
DebugStub_Interrupt_211_StartLoop:
hlt
Jmp DebugStub_Interrupt_211_StartLoop
DebugStub_Interrupt_211_Exit:
IRet
DebugStub_Interrupt_212:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 50
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
Mov eax, 50
Call DebugStub_ComWriteAL
DebugStub_Interrupt_212_StartLoop:
hlt
Jmp DebugStub_Interrupt_212_StartLoop
DebugStub_Interrupt_212_Exit:
IRet
DebugStub_Interrupt_213:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 50
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
Mov eax, 51
Call DebugStub_ComWriteAL
DebugStub_Interrupt_213_StartLoop:
hlt
Jmp DebugStub_Interrupt_213_StartLoop
DebugStub_Interrupt_213_Exit:
IRet
DebugStub_Interrupt_214:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 50
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
Mov eax, 52
Call DebugStub_ComWriteAL
DebugStub_Interrupt_214_StartLoop:
hlt
Jmp DebugStub_Interrupt_214_StartLoop
DebugStub_Interrupt_214_Exit:
IRet
DebugStub_Interrupt_215:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 50
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
Mov eax, 53
Call DebugStub_ComWriteAL
DebugStub_Interrupt_215_StartLoop:
hlt
Jmp DebugStub_Interrupt_215_StartLoop
DebugStub_Interrupt_215_Exit:
IRet
DebugStub_Interrupt_216:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 50
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
Mov eax, 54
Call DebugStub_ComWriteAL
DebugStub_Interrupt_216_StartLoop:
hlt
Jmp DebugStub_Interrupt_216_StartLoop
DebugStub_Interrupt_216_Exit:
IRet
DebugStub_Interrupt_217:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 50
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
Mov eax, 55
Call DebugStub_ComWriteAL
DebugStub_Interrupt_217_StartLoop:
hlt
Jmp DebugStub_Interrupt_217_StartLoop
DebugStub_Interrupt_217_Exit:
IRet
DebugStub_Interrupt_218:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 50
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
Mov eax, 56
Call DebugStub_ComWriteAL
DebugStub_Interrupt_218_StartLoop:
hlt
Jmp DebugStub_Interrupt_218_StartLoop
DebugStub_Interrupt_218_Exit:
IRet
DebugStub_Interrupt_219:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 50
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
Mov eax, 57
Call DebugStub_ComWriteAL
DebugStub_Interrupt_219_StartLoop:
hlt
Jmp DebugStub_Interrupt_219_StartLoop
DebugStub_Interrupt_219_Exit:
IRet
DebugStub_Interrupt_220:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 50
Call DebugStub_ComWriteAL
Mov eax, 50
Call DebugStub_ComWriteAL
Mov eax, 48
Call DebugStub_ComWriteAL
DebugStub_Interrupt_220_StartLoop:
hlt
Jmp DebugStub_Interrupt_220_StartLoop
DebugStub_Interrupt_220_Exit:
IRet
DebugStub_Interrupt_221:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 50
Call DebugStub_ComWriteAL
Mov eax, 50
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
DebugStub_Interrupt_221_StartLoop:
hlt
Jmp DebugStub_Interrupt_221_StartLoop
DebugStub_Interrupt_221_Exit:
IRet
DebugStub_Interrupt_222:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 50
Call DebugStub_ComWriteAL
Mov eax, 50
Call DebugStub_ComWriteAL
Mov eax, 50
Call DebugStub_ComWriteAL
DebugStub_Interrupt_222_StartLoop:
hlt
Jmp DebugStub_Interrupt_222_StartLoop
DebugStub_Interrupt_222_Exit:
IRet
DebugStub_Interrupt_223:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 50
Call DebugStub_ComWriteAL
Mov eax, 50
Call DebugStub_ComWriteAL
Mov eax, 51
Call DebugStub_ComWriteAL
DebugStub_Interrupt_223_StartLoop:
hlt
Jmp DebugStub_Interrupt_223_StartLoop
DebugStub_Interrupt_223_Exit:
IRet
DebugStub_Interrupt_224:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 50
Call DebugStub_ComWriteAL
Mov eax, 50
Call DebugStub_ComWriteAL
Mov eax, 52
Call DebugStub_ComWriteAL
DebugStub_Interrupt_224_StartLoop:
hlt
Jmp DebugStub_Interrupt_224_StartLoop
DebugStub_Interrupt_224_Exit:
IRet
DebugStub_Interrupt_225:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 50
Call DebugStub_ComWriteAL
Mov eax, 50
Call DebugStub_ComWriteAL
Mov eax, 53
Call DebugStub_ComWriteAL
DebugStub_Interrupt_225_StartLoop:
hlt
Jmp DebugStub_Interrupt_225_StartLoop
DebugStub_Interrupt_225_Exit:
IRet
DebugStub_Interrupt_226:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 50
Call DebugStub_ComWriteAL
Mov eax, 50
Call DebugStub_ComWriteAL
Mov eax, 54
Call DebugStub_ComWriteAL
DebugStub_Interrupt_226_StartLoop:
hlt
Jmp DebugStub_Interrupt_226_StartLoop
DebugStub_Interrupt_226_Exit:
IRet
DebugStub_Interrupt_227:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 50
Call DebugStub_ComWriteAL
Mov eax, 50
Call DebugStub_ComWriteAL
Mov eax, 55
Call DebugStub_ComWriteAL
DebugStub_Interrupt_227_StartLoop:
hlt
Jmp DebugStub_Interrupt_227_StartLoop
DebugStub_Interrupt_227_Exit:
IRet
DebugStub_Interrupt_228:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 50
Call DebugStub_ComWriteAL
Mov eax, 50
Call DebugStub_ComWriteAL
Mov eax, 56
Call DebugStub_ComWriteAL
DebugStub_Interrupt_228_StartLoop:
hlt
Jmp DebugStub_Interrupt_228_StartLoop
DebugStub_Interrupt_228_Exit:
IRet
DebugStub_Interrupt_229:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 50
Call DebugStub_ComWriteAL
Mov eax, 50
Call DebugStub_ComWriteAL
Mov eax, 57
Call DebugStub_ComWriteAL
DebugStub_Interrupt_229_StartLoop:
hlt
Jmp DebugStub_Interrupt_229_StartLoop
DebugStub_Interrupt_229_Exit:
IRet
DebugStub_Interrupt_230:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 50
Call DebugStub_ComWriteAL
Mov eax, 51
Call DebugStub_ComWriteAL
Mov eax, 48
Call DebugStub_ComWriteAL
DebugStub_Interrupt_230_StartLoop:
hlt
Jmp DebugStub_Interrupt_230_StartLoop
DebugStub_Interrupt_230_Exit:
IRet
DebugStub_Interrupt_231:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 50
Call DebugStub_ComWriteAL
Mov eax, 51
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
DebugStub_Interrupt_231_StartLoop:
hlt
Jmp DebugStub_Interrupt_231_StartLoop
DebugStub_Interrupt_231_Exit:
IRet
DebugStub_Interrupt_232:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 50
Call DebugStub_ComWriteAL
Mov eax, 51
Call DebugStub_ComWriteAL
Mov eax, 50
Call DebugStub_ComWriteAL
DebugStub_Interrupt_232_StartLoop:
hlt
Jmp DebugStub_Interrupt_232_StartLoop
DebugStub_Interrupt_232_Exit:
IRet
DebugStub_Interrupt_233:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 50
Call DebugStub_ComWriteAL
Mov eax, 51
Call DebugStub_ComWriteAL
Mov eax, 51
Call DebugStub_ComWriteAL
DebugStub_Interrupt_233_StartLoop:
hlt
Jmp DebugStub_Interrupt_233_StartLoop
DebugStub_Interrupt_233_Exit:
IRet
DebugStub_Interrupt_234:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 50
Call DebugStub_ComWriteAL
Mov eax, 51
Call DebugStub_ComWriteAL
Mov eax, 52
Call DebugStub_ComWriteAL
DebugStub_Interrupt_234_StartLoop:
hlt
Jmp DebugStub_Interrupt_234_StartLoop
DebugStub_Interrupt_234_Exit:
IRet
DebugStub_Interrupt_235:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 50
Call DebugStub_ComWriteAL
Mov eax, 51
Call DebugStub_ComWriteAL
Mov eax, 53
Call DebugStub_ComWriteAL
DebugStub_Interrupt_235_StartLoop:
hlt
Jmp DebugStub_Interrupt_235_StartLoop
DebugStub_Interrupt_235_Exit:
IRet
DebugStub_Interrupt_236:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 50
Call DebugStub_ComWriteAL
Mov eax, 51
Call DebugStub_ComWriteAL
Mov eax, 54
Call DebugStub_ComWriteAL
DebugStub_Interrupt_236_StartLoop:
hlt
Jmp DebugStub_Interrupt_236_StartLoop
DebugStub_Interrupt_236_Exit:
IRet
DebugStub_Interrupt_237:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 50
Call DebugStub_ComWriteAL
Mov eax, 51
Call DebugStub_ComWriteAL
Mov eax, 55
Call DebugStub_ComWriteAL
DebugStub_Interrupt_237_StartLoop:
hlt
Jmp DebugStub_Interrupt_237_StartLoop
DebugStub_Interrupt_237_Exit:
IRet
DebugStub_Interrupt_238:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 50
Call DebugStub_ComWriteAL
Mov eax, 51
Call DebugStub_ComWriteAL
Mov eax, 56
Call DebugStub_ComWriteAL
DebugStub_Interrupt_238_StartLoop:
hlt
Jmp DebugStub_Interrupt_238_StartLoop
DebugStub_Interrupt_238_Exit:
IRet
DebugStub_Interrupt_239:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 50
Call DebugStub_ComWriteAL
Mov eax, 51
Call DebugStub_ComWriteAL
Mov eax, 57
Call DebugStub_ComWriteAL
DebugStub_Interrupt_239_StartLoop:
hlt
Jmp DebugStub_Interrupt_239_StartLoop
DebugStub_Interrupt_239_Exit:
IRet
DebugStub_Interrupt_240:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 50
Call DebugStub_ComWriteAL
Mov eax, 52
Call DebugStub_ComWriteAL
Mov eax, 48
Call DebugStub_ComWriteAL
DebugStub_Interrupt_240_StartLoop:
hlt
Jmp DebugStub_Interrupt_240_StartLoop
DebugStub_Interrupt_240_Exit:
IRet
DebugStub_Interrupt_241:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 50
Call DebugStub_ComWriteAL
Mov eax, 52
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
DebugStub_Interrupt_241_StartLoop:
hlt
Jmp DebugStub_Interrupt_241_StartLoop
DebugStub_Interrupt_241_Exit:
IRet
DebugStub_Interrupt_242:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 50
Call DebugStub_ComWriteAL
Mov eax, 52
Call DebugStub_ComWriteAL
Mov eax, 50
Call DebugStub_ComWriteAL
DebugStub_Interrupt_242_StartLoop:
hlt
Jmp DebugStub_Interrupt_242_StartLoop
DebugStub_Interrupt_242_Exit:
IRet
DebugStub_Interrupt_243:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 50
Call DebugStub_ComWriteAL
Mov eax, 52
Call DebugStub_ComWriteAL
Mov eax, 51
Call DebugStub_ComWriteAL
DebugStub_Interrupt_243_StartLoop:
hlt
Jmp DebugStub_Interrupt_243_StartLoop
DebugStub_Interrupt_243_Exit:
IRet
DebugStub_Interrupt_244:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 50
Call DebugStub_ComWriteAL
Mov eax, 52
Call DebugStub_ComWriteAL
Mov eax, 52
Call DebugStub_ComWriteAL
DebugStub_Interrupt_244_StartLoop:
hlt
Jmp DebugStub_Interrupt_244_StartLoop
DebugStub_Interrupt_244_Exit:
IRet
DebugStub_Interrupt_245:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 50
Call DebugStub_ComWriteAL
Mov eax, 52
Call DebugStub_ComWriteAL
Mov eax, 53
Call DebugStub_ComWriteAL
DebugStub_Interrupt_245_StartLoop:
hlt
Jmp DebugStub_Interrupt_245_StartLoop
DebugStub_Interrupt_245_Exit:
IRet
DebugStub_Interrupt_246:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 50
Call DebugStub_ComWriteAL
Mov eax, 52
Call DebugStub_ComWriteAL
Mov eax, 54
Call DebugStub_ComWriteAL
DebugStub_Interrupt_246_StartLoop:
hlt
Jmp DebugStub_Interrupt_246_StartLoop
DebugStub_Interrupt_246_Exit:
IRet
DebugStub_Interrupt_247:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 50
Call DebugStub_ComWriteAL
Mov eax, 52
Call DebugStub_ComWriteAL
Mov eax, 55
Call DebugStub_ComWriteAL
DebugStub_Interrupt_247_StartLoop:
hlt
Jmp DebugStub_Interrupt_247_StartLoop
DebugStub_Interrupt_247_Exit:
IRet
DebugStub_Interrupt_248:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 50
Call DebugStub_ComWriteAL
Mov eax, 52
Call DebugStub_ComWriteAL
Mov eax, 56
Call DebugStub_ComWriteAL
DebugStub_Interrupt_248_StartLoop:
hlt
Jmp DebugStub_Interrupt_248_StartLoop
DebugStub_Interrupt_248_Exit:
IRet
DebugStub_Interrupt_249:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 50
Call DebugStub_ComWriteAL
Mov eax, 52
Call DebugStub_ComWriteAL
Mov eax, 57
Call DebugStub_ComWriteAL
DebugStub_Interrupt_249_StartLoop:
hlt
Jmp DebugStub_Interrupt_249_StartLoop
DebugStub_Interrupt_249_Exit:
IRet
DebugStub_Interrupt_250:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 50
Call DebugStub_ComWriteAL
Mov eax, 53
Call DebugStub_ComWriteAL
Mov eax, 48
Call DebugStub_ComWriteAL
DebugStub_Interrupt_250_StartLoop:
hlt
Jmp DebugStub_Interrupt_250_StartLoop
DebugStub_Interrupt_250_Exit:
IRet
DebugStub_Interrupt_251:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 50
Call DebugStub_ComWriteAL
Mov eax, 53
Call DebugStub_ComWriteAL
Mov eax, 49
Call DebugStub_ComWriteAL
DebugStub_Interrupt_251_StartLoop:
hlt
Jmp DebugStub_Interrupt_251_StartLoop
DebugStub_Interrupt_251_Exit:
IRet
DebugStub_Interrupt_252:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 50
Call DebugStub_ComWriteAL
Mov eax, 53
Call DebugStub_ComWriteAL
Mov eax, 50
Call DebugStub_ComWriteAL
DebugStub_Interrupt_252_StartLoop:
hlt
Jmp DebugStub_Interrupt_252_StartLoop
DebugStub_Interrupt_252_Exit:
IRet
DebugStub_Interrupt_253:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 50
Call DebugStub_ComWriteAL
Mov eax, 53
Call DebugStub_ComWriteAL
Mov eax, 51
Call DebugStub_ComWriteAL
DebugStub_Interrupt_253_StartLoop:
hlt
Jmp DebugStub_Interrupt_253_StartLoop
DebugStub_Interrupt_253_Exit:
IRet
DebugStub_Interrupt_254:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 50
Call DebugStub_ComWriteAL
Mov eax, 53
Call DebugStub_ComWriteAL
Mov eax, 52
Call DebugStub_ComWriteAL
DebugStub_Interrupt_254_StartLoop:
hlt
Jmp DebugStub_Interrupt_254_StartLoop
DebugStub_Interrupt_254_Exit:
IRet
DebugStub_Interrupt_255:
Pushad
Mov eax, 73
Call DebugStub_ComWriteAL
Mov eax, 110
Call DebugStub_ComWriteAL
Mov eax, 116
Call DebugStub_ComWriteAL
Mov eax, 50
Call DebugStub_ComWriteAL
Mov eax, 53
Call DebugStub_ComWriteAL
Mov eax, 53
Call DebugStub_ComWriteAL
DebugStub_Interrupt_255_StartLoop:
hlt
Jmp DebugStub_Interrupt_255_StartLoop
DebugStub_Interrupt_255_Exit:
IRet
| MetSystem/Cosmos | source/Cosmos.Debug.DebugStub/TracerEntry.asm | Assembly | bsd-3-clause | 99,033 |
;Testname=unoptimized; Arguments=-O0 -fobj -oalonesym-obj.obj; Files=stdout stderr alonesym-obj.obj
;Testname=optimized; Arguments=-Ox -fobj -oalonesym-obj.obj; Files=stdout stderr alonesym-obj.obj
section DOS32DATA align=16 public use32 FLAT class=DOS32DATA
global sym0000
global sym0001
global sym0002
global sym0003
global sym0004
global sym0005
global sym0006
global sym0007
global sym0008
global sym0009
global sym0010
global sym0011
global sym0012
global sym0013
global sym0014
global sym0015
global sym0016
global sym0017
global sym0018
global sym0019
global sym0020
global sym0021
global sym0022
global sym0023
global sym0024
global sym0025
global sym0026
global sym0027
global sym0028
global sym0029
global sym0030
global sym0031
global sym0032
global sym0033
global sym0034
global sym0035
global sym0036
global sym0037
global sym0038
global sym0039
global sym0040
global sym0041
global sym0042
global sym0043
global sym0044
global sym0045
global sym0046
global sym0047
global sym0048
global sym0049
global sym0050
global sym0051
global sym0052
global sym0053
global sym0054
global sym0055
global sym0056
global sym0057
global sym0058
global sym0059
global sym0060
global sym0061
global sym0062
global sym0063
global sym0064
global sym0065
global sym0066
global sym0067
global sym0068
global sym0069
global sym0070
global sym0071
global sym0072
global sym0073
global sym0074
global sym0075
global sym0076
global sym0077
global s
resb 20000h
sym0000 resd 1
sym0001 resd 1
sym0002 resd 1
sym0003 resd 1
sym0004 resd 1
sym0005 resd 1
sym0006 resd 1
sym0007 resd 1
sym0008 resd 1
sym0009 resd 1
sym0010 resd 1
sym0011 resd 1
sym0012 resd 1
sym0013 resd 1
sym0014 resd 1
sym0015 resd 1
sym0016 resd 1
sym0017 resd 1
sym0018 resd 1
sym0019 resd 1
sym0020 resd 1
sym0021 resd 1
sym0022 resd 1
sym0023 resd 1
sym0024 resd 1
sym0025 resd 1
sym0026 resd 1
sym0027 resd 1
sym0028 resd 1
sym0029 resd 1
sym0030 resd 1
sym0031 resd 1
sym0032 resd 1
sym0033 resd 1
sym0034 resd 1
sym0035 resd 1
sym0036 resd 1
sym0037 resd 1
sym0038 resd 1
sym0039 resd 1
sym0040 resd 1
sym0041 resd 1
sym0042 resd 1
sym0043 resd 1
sym0044 resd 1
sym0045 resd 1
sym0046 resd 1
sym0047 resd 1
sym0048 resd 1
sym0049 resd 1
sym0050 resd 1
sym0051 resd 1
sym0052 resd 1
sym0053 resd 1
sym0054 resd 1
sym0055 resd 1
sym0056 resd 1
sym0057 resd 1
sym0058 resd 1
sym0059 resd 1
sym0060 resd 1
sym0061 resd 1
sym0062 resd 1
sym0063 resd 1
sym0064 resd 1
sym0065 resd 1
sym0066 resd 1
sym0067 resd 1
sym0068 resd 1
sym0069 resd 1
sym0070 resd 1
sym0071 resd 1
sym0072 resd 1
sym0073 resd 1
sym0074 resd 1
sym0075 resd 1
sym0076 resd 1
sym0077 resd 1
s resd 1
| endlessm/chromium-browser | third_party/nasm/test/alonesym-obj.asm | Assembly | bsd-3-clause | 4,559 |
; MIT License
; Copyright (c) 2017 ZetaChain_Native
; Permission is hereby granted, free of charge, to any person obtaining a copy
; of this software and associated documentation files (the "Software"), to deal
; in the Software without restriction, including without limitation the rights
; to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
; copies of the Software, and to permit persons to whom the Software is
; furnished to do so, subject to the following conditions:
; The above copyright notice and this permission notice shall be included in all
; copies or substantial portions of the Software.
; THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
; IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
; FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
; AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
; LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
; OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
; SOFTWARE.
.data
height dq -1
index dq -1
exponent dq 1048575
value dq -1
mmx dq -1
message dq 0
dataSize dq 0
hash dq 5381
.code
calculateValueASM proc
or rcx, exponent
and rax, exponent
not rax
imul rax, rcx
ret
calculateValueASM endp
checkMMXASM proc
mov eax, 1 ; This will tell cpuid to put the cpu features into edx
cpuid
shr edx, 23
and edx, 1
cmp edx, 0
je nommx
mov mmx, 1
jmp exit
nommx:
mov mmx, 0
ret
exit:
nop
ret
checkMMXASM endp
mineASM proc
call checkMMXASM
cmp mmx, 1
jne fail
call calculateValueASM
fail:
mov rax, 0
ret
mineASM endp
HashDataASM proc
mov message, rcx
sub rdx, 1
mov dataSize, rdx
mov rbx, 0
jmp hashLoop
hashLoop:
cmp rbx, dataSize
je done
call HashMessageASM
inc rbx
jmp hashLoop
done:
ret
HashDataASM endp
HashMessageASM proc
mov hash, 5381
mov rax, qword ptr [message]
add rax, rbx
mov rcx, hash
shl rcx, 5
add rcx, hash
add rcx, rax
add rcx, rbx
mov hash, rcx
mov rax, rcx
ret
HashMessageASM endp
end | ZetaChain/ZetaChain_Native | ZetaChain/source/mining.asm | Assembly | mit | 2,115 |
;; idt.asm
;;
;; Provides functions for flushing the Interrupt Descriptor Table
; IDT table pointer
extern idt_ptr
; idt_flush
; Flushes IDT given a defined table pointer.
global idt_flush
idt_flush:
; Install IDT in CPU
lidt [idt_ptr]
ret | matheusportela/bandit-kernel | asm/idt.asm | Assembly | mit | 253 |
;------------------------------------------------------------------------------
;
; Copyright (c) 2006 - 2016, Intel Corporation. All rights reserved.<BR>
; 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 license may be found at
; http://opensource.org/licenses/bsd-license.php.
;
; THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
; WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
;
; Module Name:
;
; InterlockedCompareExchange64.Asm
;
; Abstract:
;
; InterlockedCompareExchange64 function
;
; Notes:
;
;------------------------------------------------------------------------------
.586P
.model flat,C
.code
;------------------------------------------------------------------------------
; UINT64
; EFIAPI
; InternalSyncCompareExchange64 (
; IN volatile UINT64 *Value,
; IN UINT64 CompareValue,
; IN UINT64 ExchangeValue
; );
;------------------------------------------------------------------------------
InternalSyncCompareExchange64 PROC USES esi ebx
mov esi, [esp + 12]
mov eax, [esp + 16]
mov edx, [esp + 20]
mov ebx, [esp + 24]
mov ecx, [esp + 28]
lock cmpxchg8b qword ptr [esi]
ret
InternalSyncCompareExchange64 ENDP
END
| intel/ipmctl | MdePkg/Library/BaseSynchronizationLib/Ia32/InterlockedCompareExchange64.asm | Assembly | bsd-3-clause | 1,481 |
format ELF
include "proc32.inc"
section '.text' executable
public _ksys_get_key
public _ksys_set_keyboard_mode
align 4
proc _ksys_get_key stdcall
mov eax,2
int 0x40
ret
endp
align 4
proc _ksys_set_keyboard_mode stdcall, mode:dword
mov edx,ebx
mov eax,66
xor ebx,ebx
inc ebx
mov ecx,[mode]
mov ebx,edx
ret
endp | devlato/kolibrios-llvm | programs/develop/ktcc/trunk/libc/kolibrisys/keyboard.asm | Assembly | mit | 354 |
include 'me_skin.inc'
SKIN_PARAMS \
height = bmp_base.height,\ ; skin height
margins = [5:1:43:1],\ ; margins [left:top:right:bottom]
colors active = [binner=0x152D41:\ ; border inner color
bouter=0x0B1721:\ ; border outer color
bframe=0x152D41],\ ; border frame color
colors inactive = [binner=0x576067:\ ; border inner color
bouter=0x0B1721:\ ; border outer color
bframe=0x576067],\ ; border frame color
dtp = 'GRAY.DTP' ; dtp colors
SKIN_BUTTONS \
close = [-20:6][12:12],\ ; buttons coordinates
minimize = [-36:6][12:12] ; [left:top][width:height]
SKIN_BITMAPS \
left active = bmp_left,\ ; skin bitmaps pointers
left inactive = bmp_left1,\
oper active = bmp_oper,\
oper inactive = bmp_oper1,\
base active = bmp_base,\
base inactive = bmp_base1
BITMAP bmp_left ,'active/left.bmp' ; skin bitmaps
BITMAP bmp_oper ,'active/oper.bmp'
BITMAP bmp_base ,'active/base.bmp'
BITMAP bmp_left1,'inactive/left.bmp'
BITMAP bmp_oper1,'inactive/oper.bmp'
BITMAP bmp_base1,'inactive/base.bmp'
;================================;
; Created by Rock_maniak_forever ;
;================================;
| devlato/kolibrios-llvm | skins/MenuetOS/4.MenuetOS/1/MenuetOS.asm | Assembly | mit | 1,185 |
// 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/Mult.asm
// Multiplies R0 and R1 and stores the result in R2.
// (R0, R1, R2 refer to RAM[0], RAM[1], and RAM[2], respectively.)
// Put your code here. | TheVainBoy/nand2tetris | projects/04/mult/Mult.asm | Assembly | mit | 312 |
;//###########################################################################
;//
;// FILE: F2837xD_usDelay.asm
;//
;// TITLE: Simple delay function
;//
;// DESCRIPTION:
;// This is a simple delay function that can be used to insert a specified
;// delay into code.
;// This function is only accurate if executed from internal zero-waitstate
;// SARAM. If it is executed from waitstate memory then the delay will be
;// longer then specified.
;// To use this function:
;// 1 - update the CPU clock speed in the F2837xD_Examples.h
;// file. For example:
;// #define CPU_RATE 6.667L // for a 150MHz CPU clock speed
;// 2 - Call this function by using the DELAY_US(A) macro
;// that is defined in the F2837xD_Device.h file. This macro
;// will convert the number of microseconds specified
;// into a loop count for use with this function.
;// This count will be based on the CPU frequency you specify.
;// 3 - For the most accurate delay
;// - Execute this function in 0 waitstate RAM.
;// - Disable interrupts before calling the function
;// If you do not disable interrupts, then think of
;// this as an "at least" delay function as the actual
;// delay may be longer.
;// The C assembly call from the DELAY_US(time) macro will
;// look as follows:
;// extern void Delay(long LoopCount);
;// MOV AL,#LowLoopCount
;// MOV AH,#HighLoopCount
;// LCR _Delay
;// Or as follows (if count is less then 16-bits):
;// MOV ACC,#LoopCount
;// LCR _Delay
;//
;//###########################################################################
;// $TI Release: F2837xD Support Library v3.05.00.00 $
;// $Release Date: Tue Jun 26 03:15:23 CDT 2018 $
;// $Copyright:
;// Copyright (C) 2013-2018 Texas Instruments Incorporated - http://www.ti.com/
;//
;// Redistribution and use in source and binary forms, with or without
;// modification, are permitted provided that the following conditions
;// are met:
;//
;// Redistributions of source code must retain the above copyright
;// notice, this list of conditions and the following disclaimer.
;//
;// Redistributions in binary form must reproduce the above copyright
;// notice, this list of conditions and the following disclaimer in the
;// documentation and/or other materials provided with the
;// distribution.
;//
;// Neither the name of Texas Instruments Incorporated nor the names of
;// its contributors may be used to endorse or promote products derived
;// from this software without specific prior written permission.
;//
;// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
;// "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
;// LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
;// A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
;// OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
;// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
;// LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
;// DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
;// THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
;// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
;// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
;// $
;//###########################################################################
.def _F28x_usDelay
.cdecls LIST ;;Used to populate __TI_COMPILER_VERSION__ macro
%{
%}
.if __TI_COMPILER_VERSION__
.if __TI_COMPILER_VERSION__ >= 15009000
.sect ".TI.ramfunc" ;;Used with compiler v15.9.0 and newer
.else
.sect "ramfuncs" ;;Used with compilers older than v15.9.0
.endif
.endif
.global __F28x_usDelay
_F28x_usDelay:
SUB ACC,#1
BF _F28x_usDelay,GEQ ;; Loop if ACC >= 0
LRETR
;There is a 9/10 cycle overhead and each loop
;takes five cycles. The LoopCount is given by
;the following formula:
; DELAY_CPU_CYCLES = 9 + 5*LoopCount
; LoopCount = (DELAY_CPU_CYCLES - 9) / 5
; The macro DELAY_US(A) performs this calculation for you
;
;
;//
;// End of file
;//
| nongxiaoming/rt-thread | bsp/tms320f28379d/libraries/common/source/F2837xD_usDelay.asm | Assembly | apache-2.0 | 4,284 |
format MS COFF
include '../macros.inc'
$Revision: 928 $
__REV__ = __REV
include "../proc32.inc"
include "../kglobals.inc"
include "../lang.inc"
CR0_PE equ 0x00000001 ;protected mode
CR0_WP equ 0x00010000 ;write protect
CR0_PG equ 0x80000000 ;paging
public _16bit_start
public _16bit_end
public _enter_bootscreen
public _poweroff
public _bx_from_load
extrn core_init
section '.boot' code readable align 16
_16bit_start:
org 0
use16
_enter_bootscreen:
mov eax, cr0
and eax, not 0x80000001
mov cr0, eax
jmp far 0x1000:start_of_code
version db 'Kolibri OS version 0.7.1.0 ',13,10,13,10,0
include "bootstr.inc" ; language-independent boot messages
include "preboot.inc"
if lang eq en
include "booteng.inc" ; english system boot messages
else if lang eq ru
include "bootru.inc" ; russian system boot messages
include "ru.inc" ; Russian font
else if lang eq et
include "bootet.inc" ; estonian system boot messages
include "et.inc" ; Estonian font
else
include "bootge.inc" ; german system boot messages
end if
include "../data16.inc"
include "bootcode.inc" ; 16 bit system boot code
include "../bus/pci/pci16.inc"
include "../detect/biosdisk.inc"
cli
mov eax, cr0
or eax, CR0_PG+CR0_WP+CR0_PE
mov cr0, eax
jmp pword 0x10:core_init
align 4
rmode_idt:
dw 0x400
dd 0
dw 0
align 4
_poweroff:
mov eax, cr0
and eax, not 0x80000001
mov cr0, eax
jmp far 0x1000:@F
@@:
mov eax, 0x3000
mov ss, ax
mov esp, 0xEC00
mov ebx, 0x1000
mov ds, bx
mov es, bx
lidt [rmode_idt]
APM_PowerOff:
mov ax, 5304h
xor bx, bx
int 15h
;!!!!!!!!!!!!!!!!!!!!!!!!
mov ax,0x5300
xor bx,bx
int 0x15
push ax
mov ax,0x5301
xor bx,bx
int 0x15
mov ax,0x5308
mov bx,1
mov cx,bx
int 0x15
mov ax,0x530E
xor bx,bx
pop cx
int 0x15
mov ax,0x530D
mov bx,1
mov cx,bx
int 0x15
mov ax,0x530F
mov bx,1
mov cx,bx
int 0x15
mov ax,0x5307
mov bx,1
mov cx,3
int 0x15
;!!!!!!!!!!!!!!!!!!!!!!!!
jmp $
align 4
_16bit_end:
| devlato/kolibrios-llvm | kernel/branches/kolibri_pe/boot/boot.asm | Assembly | mit | 2,594 |
**************************************************
* *
* APPLE-][ BASIC RENUMBER / APPEND SUBROUTINES *
* *
* VERSION TWO *
* RENUMBER *
* >CLR *
* >START= *
* >STEP= *
* >CALL -10531 *
* *
* OPTIONAL *
* >FROM= *
* >TO= *
* >CALL -10521 *
* *
* USE RENX ENTRY *
* FOR RENUMBER ALL *
* *
* WOZ APRIL 12, 1978 *
* APPLE COMPUTER INC. *
**************************************************
*
*
*
*
ROL EQU $0 LOW-ORDER SW16 R0 BYTE.
ROH EQU $1 HI-ORDER.
ONE EQU $01
R11L EQU $16 LOW-ORDER SW16 R11 BYTE.
R11H EQU $17 HI-ORDER.
HIMEM EQU $4C BASIC HIMEM POINTER.
PPL EQU $CA BASIC PROG POINTER.
PVL EQU $CC BASIC VAR POINTER.
MEMFULL EQU $E36B BASIC MEM FULL ERROR.
PRDEC EQU $E51B BASIC DECIMAL PRINT SUBR.
RANGERR EQU $EE68 BASIC RANGE ERROR.
LOAD EQU $F0DF BASIC LOAD SUBR.
SW16 EQU $F689 SWEET 16 ENTRY.
CROUT EQU $FD8E CAR RET SUBR.
COUT EQU $FDED CHAR OUT SUBR.
*
* SWEET 16 EQUATES
*
ACC EQU $0 SWEET 16 ACCUMULATOR.
NEWLOW EQU $1 NEW INITIAL LNO.
NEWINCR EQU $2 NEW LNO INCR.
LNLOW EQU $3 LOW LNO OF RENUM RANGE.
LNHI EQU $4 HI LNO OF RENUM RANGE.
TBLSTRT EQU $5 LNO TABLE START.
TBLNDX1 EQU $6 PASS 1 LNO TBL INDEX.
TBLIM EQU $7 LNO TABLE LIMIT.
SCR8 EQU $8 SCRATCH REG.
HMEM EQU $8 HIMEM (END OF PRGM).
SCR9 EQU $9 SCRATCH REG.
PRGNDX EQU $9 PASS 1 PROG INDEX.
PRGNDX1 EQU $A ALSO PROG INDEX.
NEWLN EQU $B NEXT "NEW LNO".
NEWLN1 EQU $C PRIOR "NEW LNO" ASSIGN.
TBLND EQU $6 PASS 2 LNO TABLE END.
PRGNDX2 EQU $7 PASS 2 PROG INDEX.
CHR0 EQU $9 ASCII "0".
CHRA EQU $A ASCII "A".
MODE EQU $C CONST/LNO MODE.
TBLNDX2 EQU $B LNO TBL IDX FOR UPDATE.
OLDLN EQU $D OLD LNO FOR UPDATE.
STRCON EQU $B BASIC STR CON TOKEN.
REM EQU $C BASIC REM TOKEN
R13 EQU $D SWEET 16 REG 13 (CPR REG).
THEN EQU $D BASIC THEN TOKEN
LIST EQU $D BASIC LIST TOKEN
DEL EQU $D
SCRC EQU $C SCRATCH REG FOR APPEND.
*
* APPLE-11 BASIC RENUMBER SUBROUTINE - PASS 1
ORG $D400
OBJ $A400
| zellyn/goapple2 | source/progaid/renumapp.asm | Assembly | mit | 2,332 |
;; Various system tales and such.
append TO_INIT_64, tables.init
macro tables.init
{
; Initializing the TSS is currently done in init/main.asm
}
; 1: 32bit code
; 2: 64bit kernel code
; 3: 32/64bit data
; 4: 64bit lusermode code
; 5: 64bit lusermode data
SEL_NULL = 0
SEL_CODE = 1 shl 3
SEL_LONG = 2 shl 3
SEL_DATA = 3 shl 3 ; Data MUST follow long.
SEL_USR_32b = (4 shl 3) or 3 ; USR stuff MUST be in this order.
SEL_USR_DATA = (5 shl 3) or 3
SEL_USR_LONG = (6 shl 3) or 3
SEL_TSS = 8 shl 3
align 8
IDTR:
dw 256*16-1
dq IDENT_MAP
align 8
GDT:
dw 0Ah*8-1
.loc: dd .rGDT
dd 0
align 8
.rGDT:
.0: dq 0 ; Unused
.1: dq 0000000011011111100110100000000000000000000000001111111111111111b
.2: dq 0000000000100000100110000000000000000000000000000000000000000000b
; -ignored-||-----||/|||------------------------------------------
; || || ||`->Conforming
; |`Long || |`->Code/Data
; | || `->User
; | |`->CPL 0-3
; | `->Present
; `->If long, must be zero (default operand size)
.3: dq 0000000011011111100100100000000000000000000000001111111111111111b
; Usermode:
;.4: dq 0 ; 32-bit CPL
.4: dq 0
.5: dq 0000000000110000111100100000000000000000000000000000000000000000b
.6: dq 0000000000110000111111000000000000000000000000000000000000000000b
.7: dq 0 ; Not really needed padding.
.8: system_segment_desc (TSS + IDENT_MAP), 103, 8900h ; Takes 16 bytes
.10:
TSS:
TSS.ign1: dd 0 ; Ignored
TSS.rsp0: dq 0 ; RSP for CPL=0
TSS.rsp1: dq 0 ; RSP for CPL=1
TSS.rsp2: dq 0 ; RSP for CPL=2
TSS.ign2: dq 0 ; Ignored
TSS.ist1: dq 0
TSS.ist2: dq 0
TSS.ist3: dq 0
TSS.ist4: dq 0 ; Interrupt stack tables.
TSS.ist5: dq 0
TSS.ist6: dq 0
TSS.ist7: dq 0
TSS.ign3: dq 0 ; Ignored
TSS.ign4: dw 0 ; Ignored
TSS.iobase: dw 0 ; IO bitmap offset.
; vim: ts=8 sw=8 syn=fasm
| lodvaer/YHBT | kernel/tables.asm | Assembly | bsd-3-clause | 1,818 |
.model tiny
.data
msg dw 13,10,"Enter the Binary String : $ "
msg1 dw 13,10,"Ascii Code : $"
array db 8 dup(0)
.code
mov cx,8 ; for looping
mov si,0 ; set si=0
;display msg
mov dx,offset msg
mov ah,09h
int 21h
enter:
; take numeric input, single digit
mov ah,01h
int 21h
; sub 30h for ascii handling
sub al,30h
; holding in array
mov array[si],al
; inc si
inc si
; re start loop, taking a total of 8 bits of input
loop enter
; MAIN CODE START HERE
mov bl,2 ; taking a constant ==2
mov ax,0001h ; puttng 1 in AX, i.e 2^0 =1
mov si,0 ; source index 0
mov di,7 ; destination index n-1 = 8-1 = 7 ; starting from back, from UNIT PLACE
mov cx,8 ; loop construct cx=8
calculate:
cmp array[di],1 ; compare from backward, UNIT PLACE
jne one ; jump if AX!=1 ,
add si,ax ; else if ==1 , add si,ax , ax was 1 , SI=SI+AX
one:
mul bl ; multiply by 2, increasing power of 2, stored in AX, AX=AX*2
dec di ; decrement index
loop calculate ; loop again
; disp msg1
mov dx,offset msg1
mov ah,09h
int 21h
; move contents of SI to DX for display
mov dx,si
mov ah,02h
int 21h
.exit
end | jatin69/lab-codes | microprocessors/binary to ascii.asm | Assembly | mit | 1,230 |
;**************************************************************************
; arch/z80/src/z180/z180_restoreusercontext.asm
;
; Copyright (C) 2012 Gregory Nutt. All rights reserved.
; Author: Gregory Nutt <gnutt@nuttx.org>
;
; 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 code must retain the above copyright
; notice, this list of conditions and the following disclaimer.
; 2. Redistributions in binary form must reproduce the above copyright
; notice, this list of conditions and the following disclaimer in
; the documentation and/or other materials provided with the
; distribution.
; 3. Neither the name NuttX nor the names of its contributors may be
; used to endorse or promote products derived from this software
; without specific prior written permission.
;
; THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
; "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
; LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
; FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
; COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT,
; INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
; BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS
; OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED
; AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
; LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN
; ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
; POSSIBILITY OF SUCH DAMAGE.
;
;**************************************************************************
; Register save area layout
.globl XCPT_I ; Offset 0: Saved I w/interrupt state in carry
.globl XCPT_BC ; Offset 1: Saved BC register
.globl XCPT_DE ; Offset 2: Saved DE register
.globl XCPT_IX ; Offset 3: Saved IX register
.globl XCPT_IY ; Offset 4: Saved IY register
.globl XCPT_SP ; Offset 5: Offset to SP at time of interrupt
.globl XCPT_HL ; Offset 6: Saved HL register
.globl XCPT_AF ; Offset 7: Saved AF register
.globl XCPT_PC ; Offset 8: Offset to PC at time of interrupt
;**************************************************************************
; z180_restoreusercontext
;**************************************************************************
.area _CODE
_z180_restoreusercontext:
; On entry, stack contains return address (not used), then address
; of the register save structure
; Discard the return address, we won't be returning
pop hl
; Get the address of the beginning of the state save area. Each
; pop will increment to the next element of the structure
pop hl ; BC = Address of save structure
ld sp, hl ; SP points to top of storage area
; Disable interrupts while we muck with the alternative registers. The
; Correct interrupt state will be restore below
di
; Restore registers. HL points to the beginning of the reg structure to restore
ex af, af' ; Select alternate AF
pop af ; Offset 0: AF' = I with interrupt state in parity
ex af, af' ; Restore original AF
pop bc ; Offset 1: BC
pop de ; Offset 2: DE
pop ix ; Offset 3: IX
pop iy ; Offset 4: IY
exx ; Use alternate BC/DE/HL
pop hl ; Offset 5: HL' = Stack pointer after return
exx ; Restore original BC/DE/HL
pop hl ; Offset 6: HL
pop af ; Offset 7: AF
; Restore the stack pointer
exx ; Use alternate BC/DE/HL
pop de ; DE' = return address
ld sp, hl ; Set SP = saved stack pointer value before return
push de ; Save return address for ret instruction
exx ; Restore original BC/DE/HL
; Restore interrupt state
ex af, af' ; Recover interrupt state
jp po, noinrestore ; Odd parity, IFF2=0, means disabled
ex af, af' ; Restore AF (before enabling interrupts)
ei ; yes.. Enable interrupts
ret ; and return
noinrestore:
ex af, af' ; Restore AF
ret ; Return with interrupts disabled
| gcds/project_xxx | nuttx/arch/z80/src/z180/z180_restoreusercontext.asm | Assembly | bsd-3-clause | 4,123 |
;
; jdcolss2-64.asm - colorspace conversion (64-bit SSE2)
;
; Copyright 2009 Pierre Ossman <ossman@cendio.se> for Cendio AB
; Copyright 2009 D. R. Commander
;
; Based on
; x86 SIMD extension for IJG JPEG library
; Copyright (C) 1999-2006, MIYASAKA Masaru.
; For conditions of distribution and use, see copyright notice in jsimdext.inc
;
; This file should be assembled with NASM (Netwide Assembler),
; can *not* be assembled with Microsoft's MASM or any compatible
; assembler (including Borland's Turbo Assembler).
; NASM is available from http://nasm.sourceforge.net/ or
; http://sourceforge.net/project/showfiles.php?group_id=6208
;
; [TAB8]
%include "jsimdext.inc"
; --------------------------------------------------------------------------
%define SCALEBITS 16
F_0_344 equ 22554 ; FIX(0.34414)
F_0_714 equ 46802 ; FIX(0.71414)
F_1_402 equ 91881 ; FIX(1.40200)
F_1_772 equ 116130 ; FIX(1.77200)
F_0_402 equ (F_1_402 - 65536) ; FIX(1.40200) - FIX(1)
F_0_285 equ ( 65536 - F_0_714) ; FIX(1) - FIX(0.71414)
F_0_228 equ (131072 - F_1_772) ; FIX(2) - FIX(1.77200)
; --------------------------------------------------------------------------
SECTION SEG_CONST
alignz 16
global EXTN(jconst_ycc_rgb_convert_sse2) PRIVATE
EXTN(jconst_ycc_rgb_convert_sse2):
PW_F0402 times 8 dw F_0_402
PW_MF0228 times 8 dw -F_0_228
PW_MF0344_F0285 times 4 dw -F_0_344, F_0_285
PW_ONE times 8 dw 1
PD_ONEHALF times 4 dd 1 << (SCALEBITS-1)
alignz 16
; --------------------------------------------------------------------------
SECTION SEG_TEXT
BITS 64
%include "jdclrss2-64.asm"
%undef RGB_RED
%undef RGB_GREEN
%undef RGB_BLUE
%undef RGB_PIXELSIZE
%define RGB_RED EXT_RGB_RED
%define RGB_GREEN EXT_RGB_GREEN
%define RGB_BLUE EXT_RGB_BLUE
%define RGB_PIXELSIZE EXT_RGB_PIXELSIZE
%define jsimd_ycc_rgb_convert_sse2 jsimd_ycc_extrgb_convert_sse2
%include "jdclrss2-64.asm"
%undef RGB_RED
%undef RGB_GREEN
%undef RGB_BLUE
%undef RGB_PIXELSIZE
%define RGB_RED EXT_RGBX_RED
%define RGB_GREEN EXT_RGBX_GREEN
%define RGB_BLUE EXT_RGBX_BLUE
%define RGB_PIXELSIZE EXT_RGBX_PIXELSIZE
%define jsimd_ycc_rgb_convert_sse2 jsimd_ycc_extrgbx_convert_sse2
%include "jdclrss2-64.asm"
%undef RGB_RED
%undef RGB_GREEN
%undef RGB_BLUE
%undef RGB_PIXELSIZE
%define RGB_RED EXT_BGR_RED
%define RGB_GREEN EXT_BGR_GREEN
%define RGB_BLUE EXT_BGR_BLUE
%define RGB_PIXELSIZE EXT_BGR_PIXELSIZE
%define jsimd_ycc_rgb_convert_sse2 jsimd_ycc_extbgr_convert_sse2
%include "jdclrss2-64.asm"
%undef RGB_RED
%undef RGB_GREEN
%undef RGB_BLUE
%undef RGB_PIXELSIZE
%define RGB_RED EXT_BGRX_RED
%define RGB_GREEN EXT_BGRX_GREEN
%define RGB_BLUE EXT_BGRX_BLUE
%define RGB_PIXELSIZE EXT_BGRX_PIXELSIZE
%define jsimd_ycc_rgb_convert_sse2 jsimd_ycc_extbgrx_convert_sse2
%include "jdclrss2-64.asm"
%undef RGB_RED
%undef RGB_GREEN
%undef RGB_BLUE
%undef RGB_PIXELSIZE
%define RGB_RED EXT_XBGR_RED
%define RGB_GREEN EXT_XBGR_GREEN
%define RGB_BLUE EXT_XBGR_BLUE
%define RGB_PIXELSIZE EXT_XBGR_PIXELSIZE
%define jsimd_ycc_rgb_convert_sse2 jsimd_ycc_extxbgr_convert_sse2
%include "jdclrss2-64.asm"
%undef RGB_RED
%undef RGB_GREEN
%undef RGB_BLUE
%undef RGB_PIXELSIZE
%define RGB_RED EXT_XRGB_RED
%define RGB_GREEN EXT_XRGB_GREEN
%define RGB_BLUE EXT_XRGB_BLUE
%define RGB_PIXELSIZE EXT_XRGB_PIXELSIZE
%define jsimd_ycc_rgb_convert_sse2 jsimd_ycc_extxrgb_convert_sse2
%include "jdclrss2-64.asm"
| wangscript/libjingle-1 | trunk/third_party/libjpeg_turbo/simd/jdcolss2-64.asm | Assembly | bsd-3-clause | 3,360 |
;code made by lioran
!speed = $0003 ;changeing this will force you to change !timer aswell dont go higher than 8
!timer = $0018 ;$0C is good for speed 5
;$10 is good for speed 4
;$18 good for speed 3,
;$20 good for 2
;$if you see samus stick out the bottom, increase the value, if stick out the top, lower the value
!freespace = $A3F320 ;get some free space from your hack need 43 bytes
!freeram = $0741 ;just some free ram that's used for the timer from bank 7E if you need to change it somehow.
lorom
org $A39581
JSL !freespace ;hijack the elevator transition code for down elevator cause just setting the speed of that one cause unwanted visual effect.
NOP #$15
org !freespace ;write your code at the free space
STZ $0799
LDA #$0008 : CMP $0998 : BNE ++ ;check game state is 08, if it is go on
STZ !freeram ;set free ram to 0
JMP +++
++
LDA #!timer : CMP !freeram : BEQ + ;if timer is not equal to !timer then increase by 1.
LDA !freeram : INC A : STA !freeram ;increase timer by 1
+++
LDA $0F7E, x ;samus y position ram position
CLC : ADC #!speed ;move samus !speed amount vertically down
STA $0F7E, x
+
RTL
;set other elevator speed to !speed aswell those dont need to have a fix to it
org $A395D2
DB !speed
org $A395EC
DB !speed
org $A395B0
DB !speed
| theonlydude/RandomMetroidSolver | patches/common/src/elevators_speed.asm | Assembly | mit | 1,291 |
Sprite:
; Character 4 plane 0 + 1 (sprite part AA)
.db $00, $00, $00, $7F, $00, $40, $00, $40, $00, $40, $00, $40, $00, $40, $00, $40
; Character 4 plane 2 + 3 (sprite part AA)
.db $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00
; Character 5 plane 0 + 1 (sprite part AB)
.db $00, $00, $7F, $7F, $01, $01, $01, $01, $01, $01, $01, $01, $81, $01, $81, $01
; Character 5 plane 2 + 3 (sprite part AB)
.db $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00
; Character 6 plane 0 + 1 (sprite part BA)
.db $00, $00, $00, $7F, $00, $40, $00, $40, $00, $40, $00, $40, $00, $40, $00, $40
; Character 6 plane 2 + 3 (sprite part BA)
.db $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00
; Character 7 plane 0 + 1 (sprite part BB)
.db $00, $00, $7F, $7F, $01, $01, $01, $01, $01, $01, $01, $01, $81, $01, $81, $01
; Character 7 plane 2 + 3 (sprite part BB)
.db $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00
; Row 2
; Character 20 plane 0 + 1 (sprite part AC)
.db $03, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00
; Character 20 plane 2 + 3 (sprite part AC)
.db $00, $00, $40, $00, $40, $00, $40, $00, $40, $00, $40, $00, $40, $00, $7F, $00
; Character 21 plane 0 + 1 (sprite part AD)
.db $E0, $00, $81, $00, $81, $00, $01, $00, $01, $00, $01, $00, $01, $00, $7F, $00
; Character 21 plane 2 + 3 (sprite part AD)
.db $00, $00, $01, $00, $01, $00, $01, $00, $01, $00, $01, $00, $01, $00, $7F, $00
; Character 22 plane 0 + 1 (sprite part BC)
.db $03, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00
; Character 22 plane 2 + 3 (sprite part BC)
.db $00, $00, $40, $00, $40, $00, $40, $00, $40, $00, $40, $00, $40, $00, $7F, $00
; Character 23 plane 0 + 1 (sprite part BD)
.db $E0, $00, $81, $00, $81, $00, $01, $00, $01, $00, $01, $00, $01, $00, $7F, $00
; Character 23 plane 2 + 3 (sprite part BD)
.db $00, $00, $01, $00, $01, $00, $01, $00, $01, $00, $01, $00, $01, $00, $7F, $00
; Row 3
; Character 4 plane 0 + 1 (sprite part AA)
.db $00, $00, $00, $7F, $00, $40, $00, $40, $00, $40, $00, $40, $00, $40, $00, $40
; Character 4 plane 2 + 3 (sprite part AA)
.db $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00
; Character 5 plane 0 + 1 (sprite part AB)
.db $00, $00, $7F, $7F, $01, $01, $01, $01, $01, $01, $01, $01, $81, $01, $81, $01
; Character 5 plane 2 + 3 (sprite part AB)
.db $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00
; Character 6 plane 0 + 1 (sprite part BA)
.db $00, $00, $00, $7F, $00, $40, $00, $40, $00, $40, $00, $40, $00, $40, $00, $40
; Character 6 plane 2 + 3 (sprite part BA)
.db $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00
; Character 7 plane 0 + 1 (sprite part BB)
.db $00, $00, $7F, $7F, $01, $01, $01, $01, $01, $01, $01, $01, $81, $01, $81, $01
; Character 7 plane 2 + 3 (sprite part BB)
.db $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00
; Row 4
; Character 20 plane 0 + 1 (sprite part AC)
.db $03, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00
; Character 20 plane 2 + 3 (sprite part AC)
.db $00, $00, $40, $00, $40, $00, $40, $00, $40, $00, $40, $00, $40, $00, $7F, $00
; Character 21 plane 0 + 1 (sprite part AD)
.db $E0, $00, $81, $00, $81, $00, $01, $00, $01, $00, $01, $00, $01, $00, $7F, $00
; Character 21 plane 2 + 3 (sprite part AD)
.db $00, $00, $01, $00, $01, $00, $01, $00, $01, $00, $01, $00, $01, $00, $7F, $00
; Character 22 plane 0 + 1 (sprite part BC)
.db $03, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00
; Character 22 plane 2 + 3 (sprite part BC)
.db $00, $00, $40, $00, $40, $00, $40, $00, $40, $00, $40, $00, $40, $00, $7F, $00
; Character 23 plane 0 + 1 (sprite part BD)
.db $E0, $00, $81, $00, $81, $00, $01, $00, $01, $00, $01, $00, $01, $00, $7F, $00
; Character 23 plane 2 + 3 (sprite part BD)
.db $00, $00, $01, $00, $01, $00, $01, $00, $01, $00, $01, $00, $01, $00, $7F, $00
| michielvoo/SNES | examples/assets/sprite.asm | Assembly | mit | 4,371 |
;Author: BinaryCounter (23-09-17)
;Uncomment one of the following 2 lines when not assembling using the buildscript.
;rOFFSET EQUS "$c486" ;OFFSET for Trade
;rOFFSET EQUS "$d280" ;OFFSET for SaveFile
;When manually assembling for SaveFile uncomment one of these linse too, to turnoff LCD (to prevent burn-in of pokemon center still frame)
;rEXTRA EQUS ".turnoff" ;Extra for Save
;rEXTRA EQUS "" ;Extra for trade
valAA EQUS "$AA"
val55 EQUS "$55"
SECTION "Program Start",ROM0[$150]
Boot::
.setup
ld a, [$ffff] ;Disable those pesky serial interrupts, ugh.
and $f7
ld [$ffff], a
;set default vars
ld a, $00
ld [$FFF1], a
;Maybe draw something to the screen here?
;After that, disable interrupts so we have full control
di
.premenu
ld a, $FF
ld [$FFF0], a
.menu
;Basic Command interface.
;Usage: GB sends $CD, Client responds with command
;Hex commands:
; $AA - Set Byte
; $55 - Run Block Transfer Routine (Read/Write blocks of memory)
; $33 - Jump to Address
ld a, $CD
call serial + rOFFSET
cp $AA
jr z, .setbyte
cp $55
jr z, .transfer
cp $33
jr z, .jump
cp $66
jr z, .turnoff
jr .menu
;Command 66, jump to address
;Usage: GB waits for Vblank and turns off LCD.
.turnoff:
ld a, [$FF40]
bit 7, a
jr z, .premenu ;Return right away if screen already off
ld a,[$FF44] ; Loop until in first part of vblank
cp 145
jr nz,.turnoff
ld hl, $FF40
res 7,[hl]
jr .premenu
;Command 33, jump to address
;Usage: GB sends $10, Client responds with High byte of address,
; GB sends $20, Client responds with low byte of address.
; GB jumps to address, return to menu with a ret instruction
.jump
call getaddress + rOFFSET
call callwrapper + rOFFSET
jr .premenu
;Command AA, set byte
;Usage: GB sends $10, Client responds with High byte of address,
; GB sends $20, Client responds with low byte of address.
; GB sends $30, Client responds with byte to be written,
; command writes byte and returns to menu
.setbyte
call getaddress + rOFFSET
ld a, $30
call serial + rOFFSET
ld [hl], a
jr .menu
;Command 55, Block transfer
;Usage: GB sends $10, Client responds with High byte of byte count,
; GB sends $20, Client responds with low byte of byte count.
; GB sends $10, Client responds with High byte of start address,
; GB sends $20, Client responds with low byte of start address.
; Command performs block transfer, returns to menu
.transfer
ld a, [$FFF1]
ld d, a ; load command Settings (See set byte for options)
call getaddress + rOFFSET
ld b, h
ld c, l
call getaddress + rOFFSET
.loop1
ld a, [hl]
call serial + rOFFSET
bit 0, d ;Is write bit set?
jr z, .skipwrite
bit 1, d ;Bootleg write set?
jr z, .skipbootleg
call bootlegwrite + rOFFSET
.skipbootleg
ld [hl], a
.skipwrite
inc hl
;------
dec bc
ld a, b
or c
jr nz, .loop1
;loopend
jr .premenu
bootlegwrite:
ld e, a
ld a, [$FFF2]
ld [$2100], a
call delay + rOFFSET
ld a, valAA
ld [$0AAA], a
nop
ld a, val55
ld [$0555], a
nop
ld a, $A0
ld [$0AAA], a
nop
ld a,e
ld [hl], a
; .waitforwrite
; ld a, [hl]
; cp b
; jr nz, .waitforwrite
call delay + rOFFSET
ret
;General-Purpose functions
getaddress: ; GB sends $10, Client responds with High byte of address,
; GB sends $20, Client responds with low byte of address.
; destroys a, returns address in hl
ld a, $10
call serial + rOFFSET
ld h, a
ld a, $20
call serial + rOFFSET
ld l, a
ret
serial: ;writes value in A to serial and puts response in A
ld [$ff01],a ;Serial Data Register
ld a, $81 ;
ld [$ff02],a ;Serial Mode
.waitloop1
ld a, [$ff02]
and $80
jr nz, .waitloop1 ;Waits for data
call delay + rOFFSET
ld a, [$ff01]
ret
callwrapper:
jp hl
delay: ;delays by value in FFF0
ld a, [$FFF0]
jr z, .skipdelay
.wastetime
dec a
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
jr nz, .wastetime
.skipdelay
ret
;loopend
| binarycounter/PkSploit | gb_asm/main.asm | Assembly | mit | 3,843 |
kp_insmap_lo
dc.b #<ins1
dc.b #<ins2
dc.b #<ins3
dc.b #<ins4
dc.b #<ins5
kp_insmap_hi
dc.b #>ins1
dc.b #>ins2
dc.b #>ins3
dc.b #>ins4
dc.b #>ins5
kp_volmap_lo
dc.b #<vol1
dc.b #<vol2
dc.b #<vol3
dc.b #<vol4
dc.b #<vol5
kp_volmap_hi
dc.b #>vol1
dc.b #>vol2
dc.b #>vol3
dc.b #>vol4
dc.b #>vol5 | kosmonautdnb/TheLandsOfZador | Musics/Global/soundfxinterface.asm | Assembly | mit | 314 |
global start
extern long_mode_start
section .text
bits 32
start:
mov esp, stack_top
mov edi, ebx
call check_multiboot
call check_cpuid
call check_long_mode
call init_page_tables
call enable_paging
call enable_SSE
lgdt [gdt64.pointer]
mov ax, gdt64.data
mov ss, ax ; stack
mov ds, ax ; data
mov es, ax ; extra
jmp gdt64.code:long_mode_start
hlt
check_multiboot:
cmp eax, 0x36d76289
jne .no_multiboot
ret
.no_multiboot:
mov al, "0"
jmp error
; magic from http://wiki.osdev.org/
check_cpuid:
pushfd ; Store the FLAGS-register.
pop eax ; Restore the A-register.
mov ecx, eax ; Set the C-register to the A-register.
xor eax, 1 << 21 ; Flip the ID-bit, which is bit 21.
push eax ; Store the A-register.
popfd ; Restore the FLAGS-register.
pushfd ; Store the FLAGS-register.
pop eax ; Restore the A-register.
push ecx ; Store the C-register.
popfd ; Restore the FLAGS-register.
xor eax, ecx ; XOR the A-register and the C-register.
jz .no_cpuid ; The zero flag is set, no CPUID.
ret ; CPUID is available for use.
.no_cpuid:
mov al, "1"
jmp error
; same lol
check_long_mode:
mov eax, 0x80000000 ; Set the A-register to 0x80000000.
cpuid ; CPU identification.
cmp eax, 0x80000001 ; Compare the A-register with 0x80000001.
jb .no_long_mode ; It is less, there is no long mode.
mov eax, 0x80000001 ; Set the A-register to 0x80000001.
cpuid ; CPU identification.
test edx, 1 << 29 ; Test if the LM-bit is set in the D-register.
jz .no_long_mode ; They aren't, there is no long mode.
ret
.no_long_mode:
mov al, "2"
jmp error
; ok this is making more sense now
; bare words are memory addresses, [] is derefernce
; so this puts address of pdp into eax register
; flips a couple option bits (present + writable)
; then... sets value of pml4 to that?
; actually hm these "labels" explicitly are just, addresses
; there's no "pml4_table" chunk of memory, not that high level...
; like C array name is just a pointer to start
; oh ok I got this so like `mov esp, stack_top`
; stack_top is my label, a memory address
; and that puts it in esp, a special register for a stack pointer
; ok sweet
; ohh wait lol so .lol is a label and lol is a function ok
; or "function" I guess, just jumps to address and ret jumps back
init_page_tables:
mov eax, pdp_table
or eax, 0b11
mov [pml4_table], eax
mov eax, pd_table
or eax, 0b11
mov [pdp_table], eax
mov ecx, 0
.map_pd_table:
mov eax, 0x200000 ; 2mib
mul ecx
or eax, 0b10000011 ; present, writable, huge
mov [pd_table + ecx * 8], eax
inc ecx
cmp ecx, 512
jne .map_pd_table
ret
enable_paging:
; cr3 just the register cpu gets page table from
mov eax, pml4_table
mov cr3, eax
; physical address extension flag
mov eax, cr4
or eax, 1 << 5
mov cr4, eax
; long mode bit
; msr: model-specific register
; efer: (model-specific) extended feature enable register
; rd/wr are just read/write
mov ecx, 0xc0000080
rdmsr
or eax, 1 << 8
wrmsr
; enable paging in cr0
mov eax, cr0
or eax, 1 << 31
mov cr0, eax
ret
enable_SSE:
; check
mov eax, 0x1
cpuid
test edx, 1 << 25
jz .no_SSE
; enable
mov eax, cr0
and ax, 0xfffb
or ax, 0x2
mov cr0, eax
mov eax, cr4
or ax, 3 << 9
mov cr4, eax
ret
.no_SSE:
mov al, "a"
jmp error
error:
mov dword [0xb8000], 0x4f524f45
mov dword [0xb8004], 0x4f3a4f52
mov dword [0xb8008], 0x4f204f20
mov byte [0xb800a], al
hlt
section .rodata
; gdt always starts with zero-entry
; 44: descriptor type (set for code or data)
; 47: present
; 41: read for data write for code
; 43: executable
; 53: 64-bit
gdt64:
dq 0;
.code: equ $ - gdt64
dq (1<<44) | (1<<47) | (1<<41) | (1<<43) | (1<<53)
.data: equ $ - gdt64
dq (1<<44) | (1<<47) | (1<<41)
.pointer:
dw $ - gdt64 - 1
dq gdt64
section .bss
align 4096
pml4_table:
resb 4096
pdp_table:
resb 4096
pd_table:
resb 4096
stack_bottom:
resb 4096
stack_top:
| alicemaz/rust-os | src/arch/x86_64/boot.asm | Assembly | mit | 4,416 |
##########################
# Name: Balazs Somfalvi
# Program: L12Q2BS.asm
##########################
#purpose: prints all numbers between a user input integer x and 1
.text
la $a0,prompt #prompts the user for a nonzero integer
li $v0,4
syscall
li $v0,5 #gets user input and moves it to $t0
syscall
move $t0,$v0
blt $t0,1,halt
move $a0,$t0 #prints positive number at least one
li $v0,1
syscall
beq $t0,1,halt #if number is one then halt the program
loop: la, $a0,dash #prints dash
li $v0,4
syscall
sub $t0,$t0,1
move $a0,$t0 #prints number
li $v0,1
syscall
bgt $t0,1,loop #if number is greter than 1 then loop
j halt #just for safety
halt: #ends the program
li $v0, 10
syscall
.data
prompt: .asciiz "Enter a non-zero integer: "
dash: .asciiz "-" | onanism/CMPT101 | L12Q2BS.asm | Assembly | mit | 795 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.