max_stars_repo_path
stringlengths
4
261
max_stars_repo_name
stringlengths
6
106
max_stars_count
int64
0
38.8k
id
stringlengths
1
6
text
stringlengths
7
1.05M
DevSound_Macros.asm
DevEd2/ScootTheBurbs
5
164873
; ================================================================ ; DevSound macros ; ================================================================ if !def(incDSMacros) incDSMacros set 1 Instrument: macro db \1 if "\2" == "_" dw DummyTable else dw vol_\2 endc if "\3" == "_" dw DummyTable else dw arp_\3 endc if "\4" == "_" dw DummyTable else dw waveseq_\4 endc if "\5" == "_" dw vib_Dummy else dw vib_\5 endc endm Drum: macro db SetInstrument,id_\1,fix,\2 endm ; Enumerate constants const_def: macro const_value = 0 endm const: macro if "\1" != "skip" \1 equ const_value endc const_value = const_value + 1 ENDM dbw: macro db \1 dw \2 endm dins: macro const id_\1 dw ins_\1 endm endc
solutions/18 - Uniqueley Disposed/size-5_speed-23.asm
behrmann/7billionhumans
45
178409
<filename>solutions/18 - Uniqueley Disposed/size-5_speed-23.asm -- 7 Billion Humans (2087) -- -- 18: Uniquely Disposed -- -- Author: landfillbaby -- Size: 5 -- Speed: 23 pickup w step sw a: step se giveto s jump a
Labs/Lab8/lab08_ex3.asm
ptr2578/CS61
1
163734
;================================================= ; Name: <NAME> ; Email: <EMAIL> ; GitHub username: ptr2578 ; ; Lab: lab 8 ; Lab section: B21 ; TA: <NAME> ; ;================================================= .ORIG x3000 ;-------------- ; Instructions ;-------------- ;------------------------------- ; INSERT CODE STARTING FROM HERE ;------------------------------- LEA R0,PROMPT PUTS LD R0,PTR_STRING LD R1,PTR_GETSTR JSRR R1 LD R0, PTR_STRING LD R1,PTR_UPPER JSRR R1 PUTS LD R0, PTR_STRING LD R1, PTR_PALINDROME JSRR R1 ADD R4, R4, #0 BRz NOT_PALIN LEA R0, IS_PALINDROME PUTS BR END_PALIN NOT_PALIN LEA R0, NOT_PALINDROME PUTS END_PALIN HALT ;------ ; Data ;------ PTR_STRING .FILL x4000 PTR_UPPER .FILL x3400 PTR_GETSTR .FILL x3200 PTR_PALINDROME .FILL x3600 PROMPT .STRINGZ "Input a string for uppercase conversion:\n" IS_PALINDROME .STRINGZ "\nThe string is a palindrome\n" NOT_PALINDROME .STRINGZ "\nThe string is NOT a palindrome\n" ;------------------------------------------------------------------------------ ; Subroutine: SUB_GET_STRING ; Parameter (R0): The address of where to start storing the string ; Postcondition: The subroutine has allowed the user to input a string, ; terminated by the [ENTER] key, and has stored it in an array ; that starts at (R0) and is NULL-terminated. ; Return Value: R5 The number of non-sentinel characters read from the user ;------------------------------------------------------------------------------- .ORIG x3200 SUB_GET_STRING ST R0, R0_BACKUP_3200 ST R1, R1_BACKUP_3200 ST R2, R2_BACKUP_3200 ST R7, R7_BACKUP_3200 ADD R6, R6, R0 AND R5, R5, #0 GETSTR_LOOP_3200 LD R1, ENTERKEY_3200 GETC OUT NOT R1, R1 ADD R1, R1, #1 ADD R1, R1, R0 BRz ENTER_PRESSED_3200 STR R0, R6, #0 ADD R6, R6, #1 ADD R5, R5, #1 BR GETSTR_LOOP_3200 ENTER_PRESSED_3200 AND R0, R0, #0 STR R0, R6, #0 END_GET_STRING LD R0, R0_BACKUP_3200 LD R1, R1_BACKUP_3200 LD R2, R2_BACKUP_3200 LD R7, R7_BACKUP_3200 RET ;---------------- ; Subroutine Data ;---------------- R0_BACKUP_3200 .BLKW #1 R1_BACKUP_3200 .BLKW #1 R2_BACKUP_3200 .BLKW #1 R7_BACKUP_3200 .BLKW #1 ENTERKEY_3200 .FILL '\n' PTR_REMOTE_STR_3200 .FILL #0 ;------------------------------------------------------------------------------ ; Subroutine: SUB_IS_A_PALINDROME ; Parameter (R0): The address of a string ; Parameter (R5): The number of characters in the array. ; Postcondition: The subroutine has determined whether the string at (R0) is ; a palindrome or not, and returned a flag to that effect. ; Return Value: R4 {1 if the string is a palindrome, 0 otherwise} ;------------------------------------------------------------------------------ .ORIG x3600 SUB_IS_A_PALINDROME ST R0, R0_BACKUP_3600 ST R1, R1_BACKUP_3600 ST R2, R2_BACKUP_3600 ST R3, R3_BACKUP_3600 ST R5, R5_BACKUP_3600 ST R6, R6_BACKUP_3600 ST R7, R7_BACKUP_3600 ADD R6, R6, #-1 ADD R1, R6, #0 AND R2, R2, #0 AND R3, R3, #0 AND R4, R4, #0 ADD R4, R4, #1 PALIN_LOOP ADD R5, R5, #-2 BRn END_IS_A_PALINDROME LDR R2, R0, #0 LDR R3, R1, #0 NOT R3, R3 ADD R3, R3, #1 ADD R0, R0, #1 ADD R1, R1, #-1 ADD R6, R2, R3 BRnp IS_NOT_PALIN BR PALIN_LOOP IS_NOT_PALIN AND R4, R4, #0 END_IS_A_PALINDROME LD R0, R0_BACKUP_3600 LD R1, R1_BACKUP_3600 LD R2, R2_BACKUP_3600 LD R3, R3_BACKUP_3600 LD R5, R5_BACKUP_3600 LD R6, R6_BACKUP_3600 LD R7, R7_BACKUP_3600 RET ;----------------- ; Subroutine Data ;----------------- R0_BACKUP_3600 .BLKW #1 R1_BACKUP_3600 .BLKW #1 R2_BACKUP_3600 .BLKW #1 R3_BACKUP_3600 .BLKW #1 R5_BACKUP_3600 .BLKW #1 R6_BACKUP_3600 .BLKW #1 R7_BACKUP_3600 .BLKW #1 ;--------------------------------------------------------------------------------- ; Subroutine: SUB_TO_UPPER ; Parameter (R0): Starting address of a null-terminated string ; Postcondition: The subroutine has converted the string to upper-case in-place ; i.e. the upper-case string has replaced the original string ; No return value. ;--------------------------------------------------------------------------------- .ORIG x3400 SUB_TO_UPPER ST R0, R0_BACKUP_3400 ST R1, R1_BACKUP_3400 ST R2, R2_BACKUP_3400 ST R7, R7_BACKUP_3400 WHILE_3400 LDR R2, R0,#0 LD R3, LOWLIMIT_3400 ADD R3, R2, R3 BRnz OUTOFRANGE_3400 LD R3, HIGHLIMIT_3400 ADD R3, R2, R3 BRzp OUTOFRANGE_3400 LD R1,CONVERT_MASK_3400 AND R2, R2, R1 STR R2, R0, #0 OUTOFRANGE_3400 ADD R0, R0, #1 ADD R2, R2, #0 BRnp WHILE_3400 END_TO_UPPER LD R0, R0_BACKUP_3400 LD R1, R1_BACKUP_3400 LD R2, R2_BACKUP_3400 LD R7, R7_BACKUP_3400 RET ;---------------- ; Subroutine Data ;---------------- R0_BACKUP_3400 .BLKW #1 R1_BACKUP_3400 .BLKW #1 R2_BACKUP_3400 .BLKW #1 R7_BACKUP_3400 .BLKW #1 CONVERT_MASK_3400 .FILL x5F LOWLIMIT_3400 .FILL -x60 HIGHLIMIT_3400 .FILL -x7B .ORIG x4000 EXAMPLE_STR .STRINGZ "hi, how are you?" .END
Library/Text/TextRegion/trLargeGState.asm
steakknife/pcgeos
504
19911
COMMENT @%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% Copyright (c) GeoWorks 1992 -- All Rights Reserved PROJECT: PC GEOS MODULE: FILE: trLargeGState.asm AUTHOR: <NAME>, Feb 25, 1992 ROUTINES: Name Description ---- ----------- REVISION HISTORY: Name Date Description ---- ---- ----------- John 2/25/92 Initial revision DESCRIPTION: GState related stuff. $Id: trLargeGState.asm,v 1.1 97/04/07 11:21:29 newdeal Exp $ %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%@ TextRegion segment resource COMMENT @%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% LargeRegionTransformGState %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% SYNOPSIS: Transform the gstate so that 0,0 falls at the upper-left corner of the region. CALLED BY: TR_RegionTransformGState via CallRegionHandlers PASS: *ds:si = Instance cx = Region dl = Draw flags RETURN: nothing DESTROYED: nothing PSEUDO CODE/STRATEGY: KNOWN BUGS/SIDE EFFECTS/IDEAS: REVISION HISTORY: Name Date Description ---- ---- ----------- jcw 2/25/92 Initial version %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%@ LargeRegionTransformGState proc far uses ax, bx, cx, dx, di, si, bp .enter class VisTextClass call TextRegion_DerefVis_DI mov di, ds:[di].VTI_gstate ; di <- gstate call GrSetDefaultTransform push dx sub sp, size PointDWord mov bp, sp call TR_RegionGetTopLeft movdw dxcx, ss:[bp].PD_x movdw bxax, ss:[bp].PD_y add sp, size PointDWord call GrApplyTranslationDWord pop dx ; now set the clip rectangle if 0 test dl, mask DF_PRINT jnz noSetClip push di call LargeRegionGetTrueHeight ;dx = height ceilwbf dxal, dx mov bx, 1 ;get width for blt-ing call LargeRegionGetTrueWidth ;ax = width pop di mov_tr cx, ax clr ax clr bx mov si, PCT_REPLACE ; Replace old clip rect call GrSetClipRect noSetClip: endif if 0 ;--------------------------------------- PrintMessage <TONY: Remove hack in LargeRegionTransformGState after graphics bugs are fixed> push ax, bx, cx, dx mov ax, -1000 mov bx, -1000 mov cx, -1000+1 mov dx, -1000+1 call GrFillRect pop ax, bx, cx, dx ;--------------------------------------- endif .leave ret LargeRegionTransformGState endp TextRegion ends
lib/i386/aesasm.asm
0xflotus/SymCrypt
1
16418
<gh_stars>1-10 ; ; AesAsm.asm Assembler code for fast AES on the x86 ; ; Copyright (c) Microsoft Corporation. Licensed under the MIT license. ; ; This code is derived from the AesFast implemenation that ; <NAME> wrote from scratch for BitLocker during Vista. ; That code is still in RSA32. ; TITLE "Advanced Encryption Standard (AES)" .586P .XMM ; ; FPO documentation: ; The .FPO provides debugging information. ; This stuff not well documented, ; but here is the information I've gathered about the arguments to .FPO ; ; In order: ; cdwLocals: Size of local variables, in DWords ; cdwParams: Size of parameters, in DWords. Given that this is all about ; stack stuff, I'm assuming this is only about parameters passed ; on the stack. ; cbProlog : Number of bytes in the prolog code. We have interleaved the ; prolog code with work for better performance. Most uses of ; .FPO seem to set this value to 0 anyway, which is what we ; will do. ; cbRegs : # registers saved in the prolog. ; fUseBP : 0 if EBP is not used as base pointer, 1 if EBP is used as base pointer ; cbFrame : Type of frame. ; 0 = FPO frame (no frame pointer) ; 1 = Trap frame (result of a CPU trap event) ; 2 = TSS frame ; ; Having looked at various occurrences of .FPO in the Windows code it ; seems to be used fairly sloppy, with lots of arguments left 0 even when ; they probably shouldn't be according to the spec. ; _TEXT SEGMENT PARA PUBLIC USE32 'CODE' ASSUME CS:_TEXT, DS:FLAT, SS:FLAT include <..\inc\symcrypt_version.inc> include symcrypt_magic.inc ; ; Structure definition that mirrors the SYMCRYPT_AES_EXPANDED_KEY structure. ; N_ROUND_KEYS_IN_AESKEY EQU 29 SYMCRYPT_AES_EXPANDED_KEY struct RoundKey db 16*N_ROUND_KEYS_IN_AESKEY dup (?) lastEncRoundKey dd ? lastDecRoundKey dd ? SYMCRYPT_MAGIC_FIELD SYMCRYPT_AES_EXPANDED_KEY ends PUBLIC @SymCryptAesEncryptAsm@12 ; PUBLIC @SymCryptAesEncryptXmm@12 PUBLIC @SymCryptAesDecryptAsm@12 ; PUBLIC @SymCryptAesDecryptXmm@12 PUBLIC @SymCryptAesCbcEncryptAsm@20 ; PUBLIC @SymCryptAesCbcEncryptXmm@20 PUBLIC @SymCryptAesCbcDecryptAsm@20 ;PUBLIC @SymCryptAesCbcDecryptXmm@20 ;PUBLIC @SymCryptAesCbcMacAsm@16 PUBLIC @SymCryptAesCtrMsb64Asm@20 ;PUBLIC @SymCryptAes4SboxXmm@8 ;PUBLIC @SymCryptAesCreateDecryptionRoundKeyXmm@8 ; PUBLIC @SymCryptAesEncryptAsmInternal@16 ; Not needed, but makes debugging easier ; PUBLIC @SymCryptAesDecryptAsmInternal@16 ; Not needed, but makes debugging easier EXTRN _SymCryptAesSboxMatrixMult:DWORD EXTRN _SymCryptAesInvSboxMatrixMult:DWORD EXTRN _SymCryptAesInvSbox:BYTE BEFORE_PROC MACRO ; ; Our current x86 compiler inserts 5 0xcc bytes before every function ; and starts every function with a 2-byte NOP. ; This supports hot-patching. ; DB 5 dup (0cch) ENDM ;===================================================================== ; AesEncrypt & AesDecrypt Macros ; ; Shorthand for the 4 tables we will use SMM0 EQU _SymCryptAesSboxMatrixMult SMM1 EQU _SymCryptAesSboxMatrixMult + 0400h SMM2 EQU _SymCryptAesSboxMatrixMult + 0800h SMM3 EQU _SymCryptAesSboxMatrixMult + 0c00h ISMM0 EQU _SymCryptAesInvSboxMatrixMult ISMM1 EQU _SymCryptAesInvSboxMatrixMult + 0400h ISMM2 EQU _SymCryptAesInvSboxMatrixMult + 0800h ISMM3 EQU _SymCryptAesInvSboxMatrixMult + 0c00h ENC_MIX MACRO load_into_esi ; ; Perform the unkeyed mixing function for encryption ; load_into_esi is the value loaded into esi by the end ; ; input block is in eax, ebx, edx, ebp ; New state ends up in ecx, edi, eax, ebp push ebp movzx ecx,al mov ecx,[SMM0 + 4 * ecx] movzx esi,ah shr eax,16 mov ebp,[SMM1 + 4 * esi] movzx edi,ah mov edi,[SMM3 + 4 * edi] movzx eax,al mov eax,[SMM2 + 4 * eax] movzx esi,bl xor edi,[SMM0 + 4 * esi] movzx esi,bh shr ebx,16 xor ecx,[SMM1 + 4 * esi] movzx esi,bl xor ebp,[SMM2 + 4 * esi] movzx ebx,bh xor eax,[SMM3 + 4 * ebx] pop ebx movzx esi,dl xor eax,[SMM0 + 4 * esi] movzx esi,dh xor edi,[SMM1 + 4 * esi] shr edx,16 movzx esi,dl xor ecx,[SMM2 + 4 * esi] movzx edx,dh xor ebp,[SMM3 + 4 * edx] mov esi,[load_into_esi] movzx edx,bl xor ebp,[SMM0 + 4 * edx] movzx edx,bh xor eax,[SMM1 + 4 * edx] shr ebx,16 movzx edx,bl xor edi,[SMM2 + 4 * edx] movzx ebx,bh xor ecx,[SMM3 + 4 * ebx] ENDM DEC_MIX MACRO load_into_esi ; ; Perform the unkeyed mixing function for decryption ; load_into_esi is the value loaded into esi by the end ; ; input block is in eax, ebx, edx, ebp ; New state ends up in ecx, edi, eax, ebp push ebp movzx ecx,al mov ecx,[ISMM0 + 4 * ecx] movzx esi,ah shr eax,16 mov edi,[ISMM1 + 4 * esi] movzx ebp,ah mov ebp,[ISMM3 + 4 * ebp] movzx eax,al mov eax,[ISMM2 + 4 * eax] movzx esi,bl xor edi,[ISMM0 + 4 * esi] movzx esi,bh shr ebx,16 xor eax,[ISMM1 + 4 * esi] movzx esi,bl xor ebp,[ISMM2 + 4 * esi] movzx ebx,bh xor ecx,[ISMM3 + 4 * ebx] pop ebx movzx esi,dl xor eax,[ISMM0 + 4 * esi] movzx esi,dh xor ebp,[ISMM1 + 4 * esi] shr edx,16 movzx esi,dl xor ecx,[ISMM2 + 4 * esi] movzx edx,dh xor edi,[ISMM3 + 4 * edx] mov esi,[load_into_esi] movzx edx,bl xor ebp,[ISMM0 + 4 * edx] movzx edx,bh xor ecx,[ISMM1 + 4 * edx] shr ebx,16 movzx edx,bl xor edi,[ISMM2 + 4 * edx] movzx ebx,bh xor eax,[ISMM3 + 4 * ebx] ENDM ADD_KEY MACRO keyptr ; ; Input is block in ecx, edi, eax, ebp ; keyptr points to the round key ; Output is in eax, ebx, edx, ebp ; mov edx, [keyptr+8] xor edx, eax mov eax, [keyptr] xor eax, ecx xor ebp, [keyptr+12] mov ebx, [keyptr+4] xor ebx, edi ENDM AES_ENC MACRO load_into_esi_offset ; ; Plaintext in eax,ebx,edx,ebp ; ecx points to first round key to use ; [key_limit] is last key to use ; [key_ptr] is temp storage area on stack ; ; Ciphertext ends up in ecx,edi,eax,ebp ; ; Loads [esp+load_into_esi_offset] into esi, except of offset = -1 ; xor eax,[ecx] xor ebx,[ecx+4] xor edx,[ecx+8] xor ebp,[ecx+12] lea ecx,[ecx+16] mov [key_ptr],ecx align 16 @@: ; Block is in eax,ebx,edx,ebp ; ecx points to next round key ENC_MIX key_ptr ADD_KEY esi add esi,16 cmp esi,[key_limit] mov [key_ptr],esi jc @B push ebp movzx ecx,al movzx ecx,byte ptr SMM0[1 + 4 * ecx] movzx esi,ah shr eax,16 movzx ebp,byte ptr SMM0[1 + 4 * esi] movzx edi,ah shl ebp,8 movzx edi,byte ptr SMM0[1 + 4 * edi] movzx eax,al shl edi,24 movzx eax,byte ptr SMM0[1 + 4 * eax] shl eax,16 movzx esi,bl movzx esi,byte ptr SMM0[1 + 4 * esi] or edi,esi movzx esi,bh shr ebx,16 movzx esi,byte ptr SMM0[1 + 4 * esi] shl esi,8 or ecx,esi movzx esi,bl movzx esi,byte ptr SMM0[1 + 4 * esi] movzx ebx,bh shl esi,16 movzx ebx,byte ptr SMM0[1 + 4 * ebx] or ebp,esi shl ebx,24 or eax,ebx movzx esi,dl movzx esi,byte ptr SMM0[1 + 4 * esi] movzx ebx,dh shr edx,16 movzx ebx,byte ptr SMM0[1 + 4 * ebx] or eax,esi shl ebx,8 movzx esi,dl movzx esi,byte ptr SMM0[1 + 4 * esi] or edi,ebx pop ebx movzx edx,dh movzx edx,byte ptr SMM0[1 + 4 * edx] shl esi,16 or ecx,esi shl edx,24 or ebp,edx movzx esi,bl movzx esi,byte ptr SMM0[1 + 4 * esi] movzx edx,bh shr ebx,16 movzx edx,byte ptr SMM0[1 + 4 * edx] or ebp,esi shl edx,8 or eax,edx mov edx,[key_ptr] movzx esi,bl movzx esi,byte ptr SMM0[1 + 4 * esi] movzx ebx,bh movzx ebx,byte ptr SMM0[1 + 4 * ebx] shl esi,16 shl ebx,24 or edi,esi IF load_into_esi_offset NE -1 mov esi,[esp+load_into_esi_offset] ENDIF or ecx,ebx xor ecx,[edx] xor edi,[edx+4] xor eax,[edx+8] xor ebp,[edx+12] ENDM AES_DEC MACRO load_into_esi_offset ; ; ; Ciphertext in eax,ebx,edx,ebp ; ecx points to first round key to use ; [key_limit] is last key to use ; [key_ptr] is temp storage area on stack ; ; Plaintext ends up in eax,ebc,edx,ebp ; xor eax,[ecx] xor ebx,[ecx+4] xor edx,[ecx+8] xor ebp,[ecx+12] lea ecx,[ecx+16] mov [key_ptr],ecx align 16 @@: ; Block is in eax,ebx,edx,ebp ; ecx points to next round key DEC_MIX key_ptr ADD_KEY esi add esi,16 cmp esi,[key_limit] mov [key_ptr],esi jc @B push ebp movzx ecx,al movzx ecx,_SymCryptAesInvSbox[ecx] movzx edi,ah shr eax,16 movzx edi,_SymCryptAesInvSbox[edi] movzx esi,ah shl edi,8 movzx ebp,_SymCryptAesInvSbox[esi] movzx eax,al shl ebp,24 movzx eax,_SymCryptAesInvSbox[eax] shl eax,16 movzx esi,bl movzx esi,_SymCryptAesInvSbox[esi] or edi,esi movzx esi,bh shr ebx,16 movzx esi,_SymCryptAesInvSbox[esi] shl esi,8 or eax,esi movzx esi,bl movzx esi,_SymCryptAesInvSbox[esi] movzx ebx,bh shl esi,16 movzx ebx,_SymCryptAesInvSbox[ebx] or ebp,esi shl ebx,24 or ecx,ebx movzx esi,dl movzx esi,_SymCryptAesInvSbox[esi] movzx ebx,dh shr edx,16 movzx ebx,_SymCryptAesInvSbox[ebx] or eax,esi shl ebx,8 movzx esi,dl movzx esi,_SymCryptAesInvSbox[esi] or ebp,ebx pop ebx movzx edx,dh movzx edx,_SymCryptAesInvSbox[edx] shl esi,16 or ecx,esi shl edx,24 or edi,edx movzx esi,bl movzx esi,_SymCryptAesInvSbox[esi] movzx edx,bh shr ebx,16 movzx edx,_SymCryptAesInvSbox[edx] or ebp,esi shl edx,8 or ecx,edx mov edx,[key_ptr] movzx esi,bl movzx esi,_SymCryptAesInvSbox[esi] movzx ebx,bh movzx ebx,_SymCryptAesInvSbox[ebx] shl esi,16 shl ebx,24 or edi,esi IF load_into_esi_offset NE -1 mov esi,[esp+load_into_esi_offset] ENDIF or eax,ebx xor ecx,[edx] xor edi,[edx+4] xor eax,[edx+8] xor ebp,[edx+12] ENDM if 0 ; We use the macro throughout, no need for the internal Enc/Dec routines ;===================================================================== ; Internal AesEncrypt & AesDecrypt ; ; ; SymCryptAesEncryptAsmInternal ; ; Internal AES encryption routine with modified calling convention. ; This is a bare-bones AES encryption routine which can only be called from assembler code ; as the calling convention is modified. ; ; Input: plaintext in eax,ebx,edx,ebp ; ecx points to first round key to use ; [esp+8] points to last round key to use (key_limit) ; [esp+4] is scratch area on stack ; ; Output: ciphertext in ecx,edi,eax,ebp ; The stack is unchanged. ; ; To call this function you push two values on the stack: the key limit and a scratch space value. ; Note that key_limit remains the same for most applications that need multiple AES encryptions. ; For example, a CBC implementation can leave key_limit and the scratch space on the stack throughout the main loop. ; ; This function uses one stack variable for temporary storage. This is located just above the return address; ; callers should wipe this area before returning as it contains keying material. ; BEFORE_PROC align 16 ; We align this function for speed reasons @SymCryptAesEncryptAsmInternal@16 PROC .FPO(0,2,0,0,0,0) key_limit equ esp+8 key_ptr equ esp+4 ; ; Plaintext in eax,ebx,edx,ebp ; ecx points to first round key to use ; [key_limit] is last key to use ; [key_ptr] is temp storage area on stack ; ; Ciphertext ends up in ecx,edi,eax,ebp ; AES_ENC -1 ret @SymCryptAesEncryptAsmInternal@16 ENDP ; ; SymCryptAesDecryptAsmInternal ; ; Internal AES decryption routine with modified calling convention. ; This is a bare-bones AES decryption routine which can only be called from assembler code ; as the calling convention is modified. ; ; Input: ciphertext in eax,ebx,edx,ebp ; ecx points to first round key to use ; [esp+8] points to last round key to use (key_limit) ; [esp+4] is scratch area on stack ; ; Output: plaintext in ecx,edi,eax,ebp ; The stack is unchanged. ; ; To call this function you push two values on the stack: the key limit and a scratch space value. ; Note that key_limit remains the same for most applications that need multiple AES encryptions. ; For example, a CBC implementation can leave key_limit and the scratch space on the stack throughout the main loop. ; ; This function uses one stack variable for temporary storage. This is located just above the return address; ; callers should wipe this area before returning as it contains keying material. ; BEFORE_PROC align 16 @SymCryptAesDecryptAsmInternal@16 PROC .FPO(0,2,0,0,0,0) key_limit equ esp+8 key_ptr equ esp+4 ; ; Ciphertext in eax,ebx,edx,ebp ; ecx points to first round key to use ; [key_limit] is last key to use ; [key_ptr] is temp storage area on stack ; [tmp_buffer] is 16-byte temp buffer ; ; Plaintext ends up in eax,ebc,edx,ebp ; AES_DEC -1 ret @SymCryptAesDecryptAsmInternal@16 ENDP endif BEFORE_PROC @SymCryptAesEncryptAsm@12 PROC ;VOID ;SYMCRYPT_CALL ;SymCryptAesEncrypt( _In_ PCSYMCRYPT_AES_EXPANDED_KEY pExpandedKey, ; _In_reads_bytes_( SYMCRYPT_AES_BLOCK_LEN ) PCBYTE pbPlaintext, ; _Out_writes_bytes_( SYMCRYPT_AES_BLOCK_LEN ) PBYTE pbCiphertext ); ; ; ; The .FPO provides debugging information. ; This stuff not well documented, ; but here is the information I've gathered about the arguments to .FPO ; ; In order: ; cdwLocals: Size of local variables, in DWords ; cdwParams: Size of parameters, in DWords. Given that this is all about ; stack stuff, I'm assuming this is only about parameters passed ; on the stack. ; cbProlog : Number of bytes in the prolog code. We have interleaved the ; prolog code with work for better performance. Most uses of ; .FPO seem to set this value to 0 anyway, which is what we ; will do. ; cbRegs : # registers saved in the prolog. 4 in our case ; fUseBP : 0 if EBP is not used as base pointer, 1 if EBP is used as base pointer ; cbFrame : Type of frame. ; 0 = FPO frame (no frame pointer) ; 1 = Trap frame (result of a CPU trap event) ; 2 = TSS frame ; ; Having looked at various occurrences of .FPO in the Windows code it ; seems to be used fairly sloppy, with lots of arguments left 0 even when ; they probably shouldn't be according to the spec. ; .FPO(6,1,0,4,0,0) AesEncryptFrame struct 4, NONUNIQUE key_pointer dd ? lastRoundKey dd ? SaveEdi dd ? SaveEsi dd ? SaveEbp dd ? SaveEbx dd ? ReturnAddress dd ? Ciphertext dd ? AesEncryptFrame ends ; ecx = AesKey ; edx = Plaintext ; [esp+4] = Ciphertext ; ; 2-byte NOP for hot patching ; This is what our current compiler does for every function, so we will follow ; that. ; mov edi,edi ; ; Set up our stack frame ; push ebx push ebp push esi push edi sub esp, 8 SYMCRYPT_CHECK_MAGIC ecx, SYMCRYPT_AES_EXPANDED_KEY ; Load the plaintext block into eax,ebx,edx,ebp mov eax,[edx] mov ebx,[edx+4] mov ebp,[edx+12] mov edx,[edx+8] ; Plaintext ptr no longer needed ; Get the address of the last round key mov esi,[ecx+SYMCRYPT_AES_EXPANDED_KEY.lastEncRoundKey] mov [esp+AesEncryptFrame.lastRoundKey],esi key_limit equ esp + AesEncryptFrame.lastRoundKey key_ptr equ esp + AesEncryptFrame.key_pointer AES_ENC AesEncryptFrame.Ciphertext ; call @SymCryptAesEncryptAsmInternal@16 ;mov esi,[esp+AesEncryptFrame.Ciphertext] mov [esi],ecx mov [esi+4],edi mov [esi+8],eax mov [esi+12],ebp ; wipe the stack location we used for temporary pushes mov [esp-8],esp add esp,8 pop edi pop esi pop ebp pop ebx ret 4 @SymCryptAesEncryptAsm@12 ENDP BEFORE_PROC @SymCryptAesDecryptAsm@12 PROC ;VOID ;AesDecrypt( _In_ PCADD_KEY AesKey, ; _In_reads_bytes_(AES_BLOCK_SIZE) PCBYTE Ciphertext, ; _Out_writes_bytes_(AES_BLOCK_SIZE) PBYTE Plaintext ; ) .FPO(6,1,0,4,0,0) AesDecryptFrame struct 4, NONUNIQUE key_pointer dd ? lastRoundKey dd ? SaveEdi dd ? SaveEsi dd ? SaveEbp dd ? SaveEbx dd ? ReturnAddress dd ? Plaintext dd ? AesDecryptFrame ends ; ecx = AesKey ; edx = Ciphertext ; [esp+4] = Plaintext ; ; 2-byte NOP for hot patching ; This is what our current compiler does for every function, so we will follow ; that. ; mov edi,edi ; ; Set up our stack frame ; push ebx push ebp push esi push edi sub esp, 8 SYMCRYPT_CHECK_MAGIC ecx, SYMCRYPT_AES_EXPANDED_KEY ; Load the ciphertext block into eax,ebx,edx,ebp mov eax,[edx] mov ebx,[edx+4] mov ebp,[edx+12] mov edx,[edx+8] ; Ciphertext ptr no longer needed ; Get the address of the last round key mov esi,[ecx+SYMCRYPT_AES_EXPANDED_KEY.lastDecRoundKey] ; esi = lastDecRoundKey mov ecx,[ecx+SYMCRYPT_AES_EXPANDED_KEY.lastEncRoundKey] ; ecx = lastEncRoundKey = first Dec round key mov [esp+AesDecryptFrame.lastRoundKey],esi key_limit equ esp + AesDecryptFrame.lastRoundKey key_ptr equ esp + AesDecryptFrame.key_pointer AES_DEC AesDecryptFrame.Plaintext mov [esi],ecx mov [esi+4],edi mov [esi+8],eax mov [esi+12],ebp mov [esp-8],esp add esp,8 pop edi pop esi pop ebp pop ebx ret 4 @SymCryptAesDecryptAsm@12 ENDP BEFORE_PROC @SymCryptAesCbcEncryptAsm@20 PROC ;VOID ;SYMCRYPT_CALL ;SymCryptAesCbcEncrypt( ; _In_ PCSYMCRYPT_AES_EXPANDED_KEY pExpandedKey, ; _In_reads_bytes_( SYMCRYPT_AES_BLOCK_SIZE ) PBYTE pbChainingValue, ; _In_reads_bytes_( cbData ) PCBYTE pbSrc, ; _Out_writes_bytes_( cbData ) PBYTE pbDst, ; SIZE_T cbData ); ; .FPO(9,3,0,4,0,0) AesCbcEncryptFrame struct 4, NONUNIQUE key_pointer dd ? lastRoundKey dd ? pbEndDst dd ? firstRoundKey dd ? pbChainingValue dd ? SaveEdi dd ? SaveEsi dd ? SaveEbp dd ? SaveEbx dd ? ReturnAddress dd ? pbSrc dd ? pbDst dd ? cbData dd ? AesCbcEncryptFrame ends ; ecx = pExpandedKey ; edx = pbChainingValue ; [esp+4...] = pbSrc, pbDst, cbData ; ; 2-byte NOP for hot patching ; This is what our current compiler does for every function, so we will follow ; that. ; mov edi,edi ; ; Set up our stack frame ; push ebx push ebp push esi push edi push edx ; pbChainingValue push ecx ; pbExpandedKey points to the first round key sub esp, 12 SYMCRYPT_CHECK_MAGIC ecx, SYMCRYPT_AES_EXPANDED_KEY mov eax,[esp + AesCbcEncryptFrame.cbData] and eax, NOT 15 jz AesCbcEncryptDoNothing ; Get & store the address of the last round key mov ebx,[ecx+SYMCRYPT_AES_EXPANDED_KEY.lastEncRoundKey] mov [esp+AesCbcEncryptFrame.lastRoundKey],ebx mov esi,[esp + AesCbcEncryptFrame.pbDst] add eax,esi mov [esp + AesCbcEncryptFrame.pbEndDst], eax ; ; Convert pbSrc to an offset from pbDst to reduce the # updates ; in a loop ; ;mov ecx,[esp + AesCbcEncryptFrame.pbSrc] ;sub ecx, esi ;mov [esp + AesCbcEncryptFrame.pbSrc], ecx ; esi = pbDst ; Load state from chaining value ; State is in ecx,edi,eax,ebp mov ecx,[edx] mov edi,[edx + 4] mov eax,[edx + 8] mov ebp,[edx + 12] AesCbcEncryptLoop: ; Invariant: ; State in (ecx, edi, eax, ebp) ; esi = pbDst for next block ; ; Change esi to point to current pbSrc pointer. pbSrc is here an offset from pbDst. ; mov esi,[esp + AesCbcEncryptFrame.pbSrc] ; ; Xor next plaintext block & move state to (eax, ebx, edx, ebp) ; We keep the reads sequentially to help the HW prefetch logic in the CPU ; xor ecx, [esi] mov ebx, [esi + 4] xor ebx, edi mov edx, [esi + 8] xor edx, eax mov eax, ecx xor ebp, [esi + 12] add esi, 16 mov [esp + AesCbcEncryptFrame.pbSrc], esi mov ecx,[esp + AesCbcEncryptFrame.firstRoundKey] key_limit equ esp + AesCbcEncryptFrame.lastRoundKey key_ptr equ esp + AesCbcEncryptFrame.key_pointer AES_ENC AesCbcEncryptFrame.pbDst ; argument is address that is loaded into esi ;call @SymCryptAesEncryptAsmInternal@16 ;mov esi,[esp + AesCbcEncryptFrame.pbDst] mov [esi], ecx mov [esi + 4], edi mov [esi + 8], eax mov [esi + 12], ebp add esi,16 cmp esi,[esp + AesCbcEncryptFrame.pbEndDst] mov [esp + AesCbcEncryptFrame.pbDst], esi jb AesCbcEncryptLoop mov edx,[esp + AesCbcEncryptFrame.pbChainingValue] mov [edx], ecx mov [edx + 4], edi mov [edx + 8], eax mov [edx + 12], ebp ; ; Wipe the one stack location that the internal encrypt routine uses ; for temporary data storage ; mov [esp - 8], esp AesCbcEncryptDoNothing: add esp, 20 pop edi pop esi pop ebp pop ebx ret 12 @SymCryptAesCbcEncryptAsm@20 ENDP BEFORE_PROC @SymCryptAesCbcDecryptAsm@20 PROC ;VOID ;SYMCRYPT_CALL ;SymCryptAesCbcDecrypt( ; _In_ PCSYMCRYPT_AES_EXPANDED_KEY pExpandedKey, ; _In_reads_bytes_( SYMCRYPT_AES_BLOCK_SIZE ) PBYTE pbChainingValue, ; _In_reads_bytes_( cbData ) PCBYTE pbSrc, ; _Out_writes_bytes_( cbData ) PBYTE pbDst, ; SIZE_T cbData ); ; .FPO(13,3,0,4,0,0) AesCbcDecryptFrame struct 4, NONUNIQUE key_pointer dd ? lastRoundKey dd ? newChainValue dd 4 dup (?) ; New chaining value after the call pbCurrentDst dd ? firstRoundKey dd ? pbChainingValue dd ? SaveEdi dd ? SaveEsi dd ? SaveEbp dd ? SaveEbx dd ? ReturnAddress dd ? pbSrc dd ? pbDst dd ? cbData dd ? AesCbcDecryptFrame ends ; ecx = pExpandedKey ; edx = pbChainingValue ; [esp+4...] = pbSrc, pbDst, cbData ; ; 2-byte NOP for hot patching ; This is what our current compiler does for every function, so we will follow ; that. ; mov edi,edi ; ; Set up our stack frame ; push ebx push ebp push esi push edi push edx ; pbChainingValue sub esp, 32 SYMCRYPT_CHECK_MAGIC ecx, SYMCRYPT_AES_EXPANDED_KEY mov eax,[esp + AesCbcDecryptFrame.cbData] and eax, NOT 15 jz AesCbcDecryptDoNothing ; Get & store the address of the first & last round key mov ebx,[ecx+SYMCRYPT_AES_EXPANDED_KEY.lastDecRoundKey] mov [esp+AesCbcDecryptFrame.lastRoundKey],ebx sub eax, 16 mov ecx,[ecx + SYMCRYPT_AES_EXPANDED_KEY.lastEncRoundKey] ; = first dec round key mov [esp + AesCbcDecryptFrame.firstRoundKey], ecx mov edi,[esp + AesCbcDecryptFrame.pbDst] add edi, eax mov [esp + AesCbcDecryptFrame.pbCurrentDst], edi ; points to last block in buffer mov esi,[esp + AesCbcDecryptFrame.pbSrc] add esi, eax mov [esp + AesCbcDecryptFrame.pbSrc], esi ; ; Load last block & store it for the chaining output ; mov eax,[esi] mov [esp + AesCbcDecryptFrame.newChainValue], eax mov ebx,[esi + 4] mov [esp + AesCbcDecryptFrame.newChainValue + 4], ebx mov edx,[esi + 8] mov [esp + AesCbcDecryptFrame.newChainValue + 8], edx mov ebp,[esi + 12] mov [esp + AesCbcDecryptFrame.newChainValue + 12], ebp jmp AesCbcDecryptLoopEnter AesCbcDecryptLoop: ; Invariant: ; State in (ecx, edi, eax, ebp) ; State is just after decrypt, but before feed-forward xor ; esi = pbCurrentDst for just decrypted state ; pbSrc = corresponding position in Src buffer mov ebx,[esp + AesCbcDecryptFrame.pbSrc] mov edx,[ebx - 16 + 8] xor eax, edx mov [esi + 16 + 8], eax mov eax,[ebx - 16 + 0] xor ecx, eax mov [esi + 16 + 0], ecx lea ecx, [ebx - 16] ; decrement + move ptr to allow register shuffle mov ebx,[ebx - 16 + 4] xor edi, ebx mov [esi + 16 + 4], edi mov edi,[ecx + 12] xor ebp, edi mov [esi + 16 + 12], ebp mov ebp, edi mov [esp + AesCbcDecryptFrame.pbSrc], ecx mov ecx,[esp + AesCbcDecryptFrame.firstRoundKey] AesCbcDecryptLoopEnter: key_limit equ esp + AesCbcDecryptFrame.lastRoundKey key_ptr equ esp + AesCbcDecryptFrame.key_pointer AES_DEC AesCbcDecryptFrame.pbCurrentDst ;call @SymCryptAesDecryptAsmInternal@16 ;mov esi,[esp + AesCbcDecryptFrame.pbCurrentDst] cmp esi,[esp + AesCbcDecryptFrame.pbDst] lea esi,[esi-16] mov [esp + AesCbcDecryptFrame.pbCurrentDst], esi ja AesCbcDecryptLoop ; ; Xor with chaining value and store last block (first in output buffer) ; mov ebx,[esp + AesCbcDecryptFrame.pbChainingValue] xor ecx,[ebx] mov [esi + 16], ecx xor edi,[ebx + 4] mov [esi + 16 + 4], edi xor eax,[ebx + 8] mov [esi + 16 + 8], eax xor ebp,[ebx + 12] mov [esi + 16+12], ebp ; ; Set the new chaining value ; mov eax,[esp + AesCbcDecryptFrame.newChainValue + 0] mov [ebx + 0], eax mov ecx,[esp + AesCbcDecryptFrame.newChainValue + 4] mov [ebx + 4], ecx mov eax,[esp + AesCbcDecryptFrame.newChainValue + 8] mov [ebx + 8], eax mov ecx,[esp + AesCbcDecryptFrame.newChainValue + 12] mov [ebx + 12], ecx ; Wipe the one stack location that the internal encrypt routine uses ; for temporary data storage ; mov [esp - 8], esp AesCbcDecryptDoNothing: add esp, 36 pop edi pop esi pop ebp pop ebx ret 12 @SymCryptAesCbcDecryptAsm@20 ENDP BEFORE_PROC @SymCryptAesCtrMsb64Asm@20 PROC ;VOID ;SYMCRYPT_CALL ;SymCryptAesCtrMsb64( ; _In_ PCSYMCRYPT_AES_EXPANDED_KEY pExpandedKey, ; _Inout_updates_bytes_( SYMCRYPT_AES_BLOCK_SIZE ) PBYTE pbChainingValue, ; _In_reads_bytes_( cbData ) PCBYTE pbSrc, ; _Out_writes_bytes_( cbData ) PBYTE pbDst, ; SIZE_T cbData ) .FPO(13,3,0,4,0,0) AesCtrMsb64Frame struct 4, NONUNIQUE key_pointer dd ? lastRoundKey dd ? chainValue dd 4 dup (?) pbEndDst dd ? firstRoundKey dd ? pbChainingValue dd ? SaveEdi dd ? SaveEsi dd ? SaveEbp dd ? SaveEbx dd ? ReturnAddress dd ? pbSrc dd ? pbDst dd ? cbData dd ? AesCtrMsb64Frame ends ; ecx = pExpandedKey ; edx = pbChainingValue ; [esp+4...] = pbSrc, pbDst, cbData ; ; 2-byte NOP for hot patching ; This is what our current compiler does for every function, so we will follow ; that. ; mov edi,edi ; ; Set up our stack frame ; push ebx push ebp push esi push edi push edx ; pbChainingValue push ecx ; pbExpandedKey points to the first round key sub esp, 28 SYMCRYPT_CHECK_MAGIC ecx, SYMCRYPT_AES_EXPANDED_KEY mov eax,[esp + AesCtrMsb64Frame.cbData] and eax, NOT 15 jz AesCtrMsb64DoNothing ; Get & store the address of the last round key mov ebx,[ecx+SYMCRYPT_AES_EXPANDED_KEY.lastEncRoundKey] mov [esp+AesCtrMsb64Frame.lastRoundKey],ebx mov esi,[esp + AesCtrMsb64Frame.pbDst] add eax,esi mov [esp + AesCtrMsb64Frame.pbEndDst], eax ; esi = pbDst ; Load state from chaining value & copy into local stack ; State is in ecx,edi,eax,ebp mov eax,[edx] mov [esp + AesCtrMsb64Frame.chainValue], eax mov ebx,[edx + 4] mov [esp + AesCtrMsb64Frame.chainValue + 4], ebx mov ebp,[edx + 12] mov edx,[edx + 8] AesCtrMsb64Loop: ; Invariant: ; counter State in (eax, ebx, edx, ebp) ; first 8 bytes of counter state in [esp+chainValue] ; ; Write the updated counter value to the local copy ; mov [esp + AesCtrMsb64Frame.chainValue + 8], edx mov ecx,[esp + AesCtrMsb64Frame.firstRoundKey] mov [esp + AesCtrMsb64Frame.chainValue + 12], ebp key_limit equ esp + AesCtrMsb64Frame.lastRoundKey key_ptr equ esp + AesCtrMsb64Frame.key_pointer AES_ENC AesCtrMsb64Frame.pbSrc ; result is in (ecx, edi, eax, ebp) ; esi = pbSrc mov ebx,[esp + AesCtrMsb64Frame.pbDst] ; ; Read the Src block, xor it with the state, and write it to Dst ; xor ecx,[esi] mov [ebx],ecx xor edi,[esi+4] mov [ebx+4],edi xor eax,[esi+8] mov [ebx+8],eax xor ebp,[esi+12] mov [ebx+12],ebp add esi, 16 mov [esp + AesCtrMsb64Frame.pbSrc], esi lea ecx,[ebx + 16] ; increment and move pointer to allow reg shuffle ; ; Load the current chain value, and do the increment ; mov ebp,[esp + AesCtrMsb64Frame.chainValue+12] bswap ebp mov edx,[esp + AesCtrMsb64Frame.chainValue+8] bswap edx add ebp,1 mov eax,[esp + AesCtrMsb64Frame.chainValue] adc edx, 0 mov ebx,[esp + AesCtrMsb64Frame.chainValue+4] bswap ebp bswap edx cmp ecx,[esp + AesCtrMsb64Frame.pbEndDst] mov [esp + AesCtrMsb64Frame.pbDst], ecx jb AesCtrMsb64Loop ; ; Write the updated chaining value; we only need to update 8 bytes ; mov ebx,[esp + AesCtrMsb64Frame.pbChainingValue] mov [ebx + 8], edx mov [ebx + 12], ebp ; ; Wipe our local copy of the chaining value ; xor eax,eax mov [esp + AesCtrMsb64Frame.chainValue], eax mov [esp + AesCtrMsb64Frame.chainValue + 4], eax mov [esp + AesCtrMsb64Frame.chainValue + 8], eax mov [esp + AesCtrMsb64Frame.chainValue + 12], eax ; ; Wipe the one stack location that the internal encrypt routine uses ; for temporary data storage ; mov [esp - 8], esp AesCtrMsb64DoNothing: add esp, 36 pop edi pop esi pop ebp pop ebx ret 12 @SymCryptAesCtrMsb64Asm@20 ENDP if 0 ; disabled while we concentrate on reaching RSA32 parity. The code below works though. BEFORE_PROC @SymCryptAesCbcMacAsm@16 PROC ;VOID ;SYMCRYPT_CALL ;SymCryptAesCbcMac( ; _In_ PCSYMCRYPT_AES_EXPANDED_KEY pExpandedKey, ; _Inout_updates_bytes_( SYMCRYPT_AES_BLOCK_SIZE ) PBYTE pbChainingValue, ; _In_reads_bytes_( cbData ) PCBYTE pbData, ; SIZE_T cbData ) ; .FPO(9,2,0,4,0,0) AesCbcMacFrame struct 4, NONUNIQUE key_pointer dd ? lastRoundKey dd ? pbEnd dd ? firstRoundKey dd ? pbChainingValue dd ? SaveEdi dd ? SaveEsi dd ? SaveEbp dd ? SaveEbx dd ? ReturnAddress dd ? pbData dd ? cbData dd ? AesCbcMacFrame ends ; ecx = pExpandedKey ; edx = pbChainingValue ; [esp+4...] = pbSrc, pbDst, cbData ; ; 2-byte NOP for hot patching ; This is what our current compiler does for every function, so we will follow ; that. ; mov edi,edi ; ; Set up our stack frame ; push ebx push ebp push esi push edi push edx ; pbChainingValue push ecx ; pbExpandedKey points to the first round key sub esp, 12 SYMCRYPT_CHECK_MAGIC ecx, SYMCRYPT_AES_EXPANDED_KEY mov eax,[esp + AesCbcMacFrame.cbData] and eax, NOT 15 jz AesCbcMacDoNothing ; Get & store the address of the last round key mov ebx,[ecx+SYMCRYPT_AES_EXPANDED_KEY.lastEncRoundKey] mov [esp+AesCbcMacFrame.lastRoundKey],ebx mov esi,[esp + AesCbcMacFrame.pbData] add eax,esi mov [esp + AesCbcMacFrame.pbEnd], eax ; esi = pbData ; Load state from chaining value ; State is in ecx,edi,eax,ebp mov ecx,[edx] mov edi,[edx + 4] mov eax,[edx + 8] mov ebp,[edx + 12] AesCbcMacLoop: ; Invariant: ; State in (ecx, edi, eax, ebp) ; esi = pbData ; ; Xor next plaintext block & move state to (eax, ebx, edx, ebp) ; We keep the reads sequentially to help the HW prefetch logic in the CPU ; xor ecx, [esi] mov ebx, [esi + 4] xor ebx, edi mov edx, [esi + 8] xor edx, eax mov eax, ecx xor ebp, [esi + 12] mov ecx,[esp + AesCbcMacFrame.firstRoundKey] key_limit equ esp + AesCbcMacFrame.lastRoundKey key_ptr equ esp + AesCbcMacFrame.key_pointer AES_ENC AesCbcMacFrame.pbData ; argument is address that is loaded into esi ;call @SymCryptAesEncryptAsmInternal@16 ;mov esi,[esp + AesCbcMacFrame.pbData] add esi, 16 cmp esi,[esp + AesCbcMacFrame.pbEnd] mov [esp + AesCbcMacFrame.pbData], esi jb AesCbcMacLoop mov edx,[esp + AesCbcMacFrame.pbChainingValue] mov [edx], ecx mov [edx + 4], edi mov [edx + 8], eax mov [edx + 12], ebp ; ; Wipe the one stack location that the internal encrypt routine uses ; for temporary data storage ; mov [esp - 8], esp AesCbcMacDoNothing: add esp, 20 pop edi pop esi pop ebp pop ebx ret 8 @SymCryptAesCbcMacAsm@16 ENDP endif ;=========================================================================== ; AES-NI code if 0 ; No longer used; replaced with intrinsic C code that can be inlined. BEFORE_PROC @SymCryptAes4SboxXmm@8 PROC ; ;VOID ;Aes4SboxAsm( _In_reads_bytes_(4) PCBYTE pIn, _Out_writes_bytes_(4) PBYTE pOut ); ; .FPO(0,0,0,0,0,0) ; ;ecx points to source ;edx points to destination ; ;We only use volatile registers so we do not have to save any registers. ; mov eax,[ecx] ; Use a register to avoid alignment issues movd xmm0, eax movsldup xmm0, xmm0 ; copy [31:0] to [63:32] aeskeygenassist xmm0, xmm0, 0 movd eax, xmm0 mov [edx], eax ret @SymCryptAes4SboxXmm@8 ENDP BEFORE_PROC @SymCryptAesCreateDecryptionRoundKeyXmm@8 PROC ; ;VOID ;AesCreateDecryptionRoundKeyAsm( _In_reads_bytes_(16) PCBYTE pEncryptionRoundKey, ; _Out_writes_bytes_(16) PBYTE pDecryptionRoundKey ); ; .FPO(0,0,0,0,0,0) ;ecx points to source ;edx points to destination movups xmm0,[ecx] aesimc xmm0, xmm0 movups [edx], xmm0 ret @SymCryptAesCreateDecryptionRoundKeyXmm@8 ENDP endif AES_ENCRYPT_XMM MACRO ; xmm0 contains the plaintext ; ecx points to first round key to use ; eax is last key to use (unchanged) ; Ciphertext ends up in xmm0, xmm1 used ; ; ; xor in first round key; round keys are 16-aligned on amd64 ; movups xmm1, [ecx] pxor xmm0, xmm1 movups xmm1, [ecx+16] aesenc xmm0, xmm1 add ecx, 32 @@: ; r9 points to next round key movups xmm1, [ecx] aesenc xmm0, xmm1 movups xmm1, [ecx + 16] aesenc xmm0, xmm1 add ecx, 32 cmp ecx, eax jc @B ; ; Now for the final round ; movups xmm1, [eax] aesenclast xmm0, xmm1 ENDM AES_DECRYPT_XMM MACRO ; xmm0 contains the plaintext ; ecx points to first round key to use ; eax is last key to use (unchanged) ; Ciphertext ends up in xmm0, xmm1 used ; ; ; xor in first round key; round keys are 16-aligned on amd64 ; movups xmm1, [ecx] pxor xmm0, xmm1 movups xmm1, [ecx+16] aesdec xmm0, xmm1 add ecx, 32 @@: ; r9 points to next round key movups xmm1, [ecx] aesdec xmm0, xmm1 movups xmm1, [ecx + 16] aesdec xmm0, xmm1 add ecx, 32 cmp ecx, eax jc @B ; ; Now for the final round ; movups xmm1, [eax] aesdeclast xmm0, xmm1 ENDM BEFORE_PROC if 0 @SymCryptAesEncryptXmm@12 PROC ; ; rcx = expanded key ; rdx = pbSrc ; [esp+4] = pbDst .FPO( 0, 1, 0, 0, 0, 0) SYMCRYPT_CHECK_MAGIC ecx, SYMCRYPT_AES_EXPANDED_KEY movups xmm0,[edx] mov eax, [ecx + SYMCRYPT_AES_EXPANDED_KEY.lastEncRoundKey] AES_ENCRYPT_XMM ; xmm0 contains the plaintext ; ecx points to first round key to use ; eax is last key to use (unchanged) ; Ciphertext ends up in xmm0 mov ecx,[esp + 4] movups [ecx],xmm0 ret 4 @SymCryptAesEncryptXmm@12 ENDP endif if 0 BEFORE_PROC @SymCryptAesDecryptXmm@12 PROC ; ; rcx = expanded key ; rdx = pbSrc ; [esp+4] = pbDst .FPO( 0, 1, 0, 0, 0, 0) SYMCRYPT_CHECK_MAGIC ecx, SYMCRYPT_AES_EXPANDED_KEY movups xmm0,[edx] mov eax, [ecx + SYMCRYPT_AES_EXPANDED_KEY.lastDecRoundKey] mov ecx, [ecx + SYMCRYPT_AES_EXPANDED_KEY.lastEncRoundKey] AES_DECRYPT_XMM ; xmm0 contains the plaintext ; ecx points to first round key to use ; eax is last key to use (unchanged) ; Ciphertext ends up in xmm0 mov ecx,[esp + 4] movups [ecx],xmm0 ret 4 @SymCryptAesDecryptXmm@12 ENDP endif if 0 BEFORE_PROC @SymCryptAesCbcEncryptXmm@20 PROC ; ecx = pExpandedKey ; edx = pbChainingValue ; [esp+4...] = pbSrc, pbDst, cbData .FPO (4, 3, 0, 4, 0, 0 ) ; locals, params, 0, regs saved, 0, 0 SymCryptAesCbcEncryptXmmFrame struct 4, NONUNIQUE SaveEdi dd ? SaveEsi dd ? SaveEbp dd ? SaveEbx dd ? ReturnAddress dd ? pbSrc dd ? pbDst dd ? cbData dd ? SymCryptAesCbcEncryptXmmFrame ends ; ; 2-byte NOP for hot patching ; This is what our current compiler does for every function, so we will follow ; that. ; mov edi,edi push ebx push ebp push esi push edi SYMCRYPT_CHECK_MAGIC ecx, SYMCRYPT_AES_EXPANDED_KEY mov ebp,[esp + SymCryptAesCbcEncryptXmmFrame.cbData] and ebp, NOT 15 jz SymCryptAesCbcEncryptXmmNoData mov esi,[esp + SymCryptAesCbcEncryptXmmFrame.pbSrc] mov edi,[esp + SymCryptAesCbcEncryptXmmFrame.pbDst] add ebp, esi ; ebp = pbSrcEnd movups xmm0,[edx] mov eax, [ecx + SYMCRYPT_AES_EXPANDED_KEY.lastEncRoundKey] mov ebx, ecx SymCryptAesCbcEncryptXmmLoop: movups xmm1, [esi] pxor xmm0, xmm1 add esi, 16 mov ecx, ebx AES_ENCRYPT_XMM movups [edi], xmm0 add edi, 16 cmp esi, ebp jc SymCryptAesCbcEncryptXmmLoop movups [edx], xmm0 SymCryptAesCbcEncryptXmmNoData: pop edi pop esi pop ebp pop ebx ret 12 @SymCryptAesCbcEncryptXmm@20 ENDP endif if 0 ; replaced with C/intrinsic code BEFORE_PROC @SymCryptAesCbcDecryptXmm@20 PROC ; ecx = pExpandedKey ; edx = pbChainingValue ; [esp+4...] = pbSrc, pbDst, cbData .FPO (4, 3, 0, 4, 0, 0 ) ; locals, params, 0, regs saved, 0, 0 SymCryptAesCbcDecryptXmmFrame struct 4, NONUNIQUE SaveEdi dd ? SaveEsi dd ? SaveEbp dd ? SaveEbx dd ? ReturnAddress dd ? pbSrc dd ? pbDst dd ? cbData dd ? SymCryptAesCbcDecryptXmmFrame ends ; ; 2-byte NOP for hot patching ; This is what our current compiler does for every function, so we will follow ; that. ; mov edi,edi push ebx push ebp push esi push edi SYMCRYPT_CHECK_MAGIC ecx, SYMCRYPT_AES_EXPANDED_KEY mov ebp,[esp + SymCryptAesCbcDecryptXmmFrame.cbData] and ebp, NOT 15 jz SymCryptAesCbcDecryptXmmNoData mov esi,[esp + SymCryptAesCbcDecryptXmmFrame.pbSrc] mov edi,[esp + SymCryptAesCbcDecryptXmmFrame.pbDst] add ebp, esi ; ebp = pbSrcEnd movups xmm3,[edx] mov eax, [ecx + SYMCRYPT_AES_EXPANDED_KEY.lastDecRoundKey] mov ebx, [ecx + SYMCRYPT_AES_EXPANDED_KEY.lastEncRoundKey] SymCryptAesCbcDecryptXmmLoop: movups xmm0, [esi] add esi, 16 movaps xmm2, xmm0 mov ecx, ebx AES_DECRYPT_XMM pxor xmm0, xmm3 movaps xmm3, xmm2 movups [edi], xmm0 add edi, 16 cmp esi, ebp jc SymCryptAesCbcDecryptXmmLoop movups [edx], xmm2 SymCryptAesCbcDecryptXmmNoData: pop edi pop esi pop ebp pop ebx ret 12 @SymCryptAesCbcDecryptXmm@20 ENDP endif; _TEXT ENDS END
2.0/cpm20_code/os1boot.asm
officialrafsan/CP-M
0
177620
title 'mds cold start loader at 3000h' ; ; MDS-800 Cold Start Loader for CP/M 2.0 ; ; Version 2.0 August, 1979 ; false equ 0 true equ not false testing equ false ;if true, then go to mon80 on errors ; if testing bias equ 03400h endif if not testing bias equ 0000h endif cpmb equ bias ;base of dos load bdos equ 806h+bias ;entry to dos for calls bdose equ 1880h+bias ;end of dos load boot equ 1600h+bias ;cold start entry point rboot equ boot+3 ;warm start entry point ; org 03000h ;loaded down from hardware boot at 3000h ; bdosl equ bdose-cpmb ntrks equ 2 ;number of tracks to read bdoss equ bdosl/128 ;number of sectors in dos bdos0 equ 25 ;number of bdos sectors on track 0 bdos1 equ bdoss-bdos0 ;number of sectors on track 1 ; mon80 equ 0f800h ;intel monitor base rmon80 equ 0ff0fh ;restart location for mon80 base equ 078h ;'base' used by controller rtype equ base+1 ;result type rbyte equ base+3 ;result byte reset equ base+7 ;reset controller ; dstat equ base ;disk status port ilow equ base+1 ;low iopb address ihigh equ base+2 ;high iopb address bsw equ 0ffh ;boot switch recal equ 3h ;recalibrate selected drive readf equ 4h ;disk read function stack equ 100h ;use end of boot for stack ; rstart: lxi sp,stack;in case of call to mon80 ; clear disk status in rtype in rbyte ; check if boot switch is off coldstart: in bsw ani 02h ;switch on? jnz coldstart ; clear the controller out reset ;logic cleared ; ; mvi b,ntrks ;number of tracks to read lxi h,iopb0 ; start: ; ; read first/next track into cpmb mov a,l out ilow mov a,h out ihigh wait0: in dstat ani 4 jz wait0 ; ; check disk status in rtype ani 11b cpi 2 ; if testing cnc rmon80 ;go to monitor if 11 or 10 endif if not testing jnc rstart ;retry the load endif ; in rbyte ;i/o complete, check status ; if not ready, then go to mon80 ral cc rmon80 ;not ready bit set rar ;restore ani 11110b ;overrun/addr err/seek/crc/xxxx ; if testing cnz rmon80 ;go to monitor endif if not testing jnz rstart ;retry the load endif ; ; lxi d,iopbl ;length of iopb dad d ;addressing next iopb dcr b ;count down tracks jnz start ; ; ; jmp to boot to print initial message, and set up jmps jmp boot ; ; parameter blocks iopb0: db 80h ;iocw, no update db readf ;read function db bdos0 ;# sectors to read on track 0 db 0 ;track 0 db 2 ;start with sector 2 on track 0 dw cpmb ;start at base of bdos iopbl equ $-iopb0 ; iopb1: db 80h db readf db bdos1 ;sectors to read on track 1 db 1 ;track 1 db 1 ;sector 1 dw cpmb+bdos0*128 ;base of second read ; end 
programs/oeis/105/A105946.asm
karttu/loda
1
11127
<gh_stars>1-10 ; A105946: C(n+5,n)*C(n+3,3). ; 1,24,210,1120,4410,14112,38808,95040,212355,440440,858858,1589952,2815540,4798080,7907040,12651264,19718181,30020760,44753170,65456160,94093230,133138720,185679000,255528000,347358375,466849656,620854794,817586560,1066825320 mov $2,5 add $2,$0 cal $0,108647 ; a(n) = (n+1)^2*(n+2)^2*(n+3)^2*(n+4)/144. mul $0,$2 add $0,6 mov $1,$0 sub $1,11 div $1,5 add $1,1
Kaleid.agda
ashinkarov/agda-extractor
1
34
<filename>Kaleid.agda open import Structures open import Data.String using (String; _≈?_) open import Data.List as L using (List; []; _∷_; [_]) open import Data.List.Categorical open import Data.Nat as ℕ using (ℕ; zero; suc; _+_) import Data.Nat.Properties as ℕ open import Data.Nat.DivMod open import Agda.Builtin.Nat using (div-helper; mod-helper) open import Data.Nat.Show using () renaming (show to showNat) open import Data.Vec as V using (Vec; []; _∷_) open import Data.Fin as F using (Fin; zero; suc; #_) open import Category.Monad open import Category.Monad.State open import Data.Product as Σ open import Data.Unit open import Data.Bool using (Bool; true; false; if_then_else_) open import Data.Maybe using (Maybe; just; nothing) open import Data.Fin using (Fin; zero; suc; fromℕ<) open import Relation.Binary.PropositionalEquality using (_≡_; refl; cong; sym; subst) open import Relation.Nullary open import Reflection hiding (return; _>>=_; _>>_) open import Reflection.Term import Reflection.Name as RN open import Function open import Strict open RawMonad ⦃ ... ⦄ Id = String data Op : Set where Plus Minus Times Divide Eq Neq And Gt Lt : Op data Expr : Set where Nat : ℕ → Expr BinOp : Op → Expr → Expr → Expr Var : String → Expr Call : Id → List Expr → Expr Function : Id → List Id → Expr → Expr Extern : Id → List Id → Expr Let : Id → Expr → Expr → Expr Assert : Expr → Expr If : Expr → Expr → Expr → Expr op-to-string : Op → String op-to-string Plus = "+" op-to-string Minus = "-" op-to-string Times = "*" op-to-string Divide = "/" op-to-string Eq = "==" op-to-string Neq = "!=" op-to-string And = "&&" op-to-string Gt = ">" op-to-string Lt = "<" indent : ℕ → String indent n = "" ++/ L.replicate n " " flatten-lets : List Expr → List (Id × Expr) × List Expr -- Lift all the assigns from the (potentially) nested let flatten-let : Expr → List (Id × Expr) × Expr flatten-let (Let x e e₁) = let a₁ , e = flatten-let e a₂ , e₁ = flatten-let e₁ in (a₁ ++ [(x , e)] ++ a₂) , e₁ flatten-let e@(Nat _) = [] , e flatten-let (BinOp x e e₁) = let a , e = flatten-let e a₁ , e₁ = flatten-let e₁ in (a ++ a₁) , BinOp x e e₁ flatten-let e@(Var _) = [] , e flatten-let (Call x es) = let as , es' = flatten-lets es in as , Call x es' flatten-let (Function x args e) = let a , e = flatten-let e in [] , (Function x args $ L.foldr (uncurry Let) e a) flatten-let e@(Extern _ _) = [] , e flatten-let (Assert e) = let a , e = flatten-let e in a , Assert e flatten-let (If e e₁ e₂) = let a , e = flatten-let e a₁ , e₁ = flatten-let e₁ a₂ , e₂ = flatten-let e₂ e₁' = L.foldr (uncurry Let) e₁ a₁ e₂' = L.foldr (uncurry Let) e₂ a₂ in a , (If e e₁' e₂') flatten-lets [] = [] , [] flatten-lets (e ∷ es) = let a , e = flatten-let e a₁ , es = flatten-lets es in (a ++ a₁) , (e ∷ es) {-# TERMINATING #-} expr-to-string : ℕ → Expr → String expr-to-string ind (Nat x) = indent ind ++ showNat x expr-to-string ind (BinOp op e e₁) = indent ind ++ "(" ++ expr-to-string 0 e ++ ") " ++ op-to-string op ++ " (" ++ expr-to-string 0 e₁ ++ ")" expr-to-string ind (Var x) = indent ind ++ x expr-to-string ind (Call f args) = indent ind ++ f ++ " (" ++ (", " ++/ L.map (expr-to-string 0) args) ++ ")" expr-to-string ind (Function n ids e) = indent ind ++ "def " ++ n ++ "(" ++ (", " ++/ ids) ++ "):\n" ++ expr-to-string (ind + 1) e expr-to-string ind (Extern n ids) = indent ind ++ "extern def " ++ n ++ " (" ++ (", " ++/ ids) ++ ")" expr-to-string ind (Let x e@(If _ _ _) e₁) = indent ind ++ "let " ++ x ++ " =\n" ++ expr-to-string (ind + 1) e ++ "\n" ++ expr-to-string ind e₁ expr-to-string ind (Let x e e₁) = indent ind ++ "let " ++ x ++ " = " ++ expr-to-string 0 e ++ "\n" ++ expr-to-string ind e₁ expr-to-string ind (Assert e) = indent ind ++ "assert (" ++ expr-to-string 0 e ++ ")" expr-to-string ind (If e e₁ e₂) = indent ind ++ "if " ++ expr-to-string 0 e ++ ":\n" ++ expr-to-string (ind + 1) e₁ ++ "\n" ++ indent ind ++ "else:\n" ++ expr-to-string (ind + 1) e₂ ++ "\n" -- Glorified sigma type for variable-assertion pairs record Assrt : Set where constructor mk field v : Id a : Expr Assrts = List Assrt -- The state used when traversing a Pi type. record PS : Set where field cnt : ℕ -- The source of unique variable names cur : Id -- Current variable name (used to collect assertions from its type) ctx : Telescope -- Names in the telscopes to resolve deBruijn indices ret : Id -- Variable that the function returns as a result. -- We assume that there is always a single variable and its name -- is known upfront. We need this to generate assertions from the -- return type. assrts : Assrts -- Assertions that we generate per each variable. kst : KS -- Compilation state (in case we have to extract some functions used in types) defaultPS : PS defaultPS = record { cnt = 1 ; cur = "" ; ctx = [] ; ret = "__ret" ; assrts = [] ; kst = defaultKS } record PatSt : Set where constructor mk field vars : List (String × ℕ) --Strings assigns : List (Id × Expr) conds : List Expr cnt : ℕ defaultPatSt : PatSt defaultPatSt = mk [] [] [] 1 SPS = State PS kompile-fun : Type → Term → Name → SKS $ Err Expr kompile-pi : Type → SPS $ Err ⊤ --{-# TERMINATING #-} kompile-cls : Clauses → (vars : Strings) → (ret : String) → SKS $ Err Expr kompile-clpats : Telescope → (pats : List $ Arg Pattern) → (exprs : List Expr) → PatSt → Err PatSt --{-# TERMINATING #-} kompile-term : Term → Telescope → SKS $ Err Expr kompile-funp : Type → Term → Name → SKS Prog kompile-funp ty te n = do (ok e) ← kompile-fun ty te n where (error x) → return $ error x let a , e = flatten-let e e = case a of λ where [] → e a → L.foldr (uncurry Let) e a return $ ok $ expr-to-string 0 e ++ "\n" private kf : String → Err Expr kf x = error $ "kompile-fun: " ++ x module R = RawMonadState (StateMonadState KS) kompile-fun ty (pat-lam [] []) n = return $ kf "got zero clauses in a lambda term" kompile-fun ty (pat-lam cs []) n = do kst ← R.get let (_ , ps) = kompile-pi ty $ record defaultPS{ kst = kst } rv = PS.ret ps ns = showName n vars = L.map proj₁ $ PS.ctx ps args = ok $ ", " ++/ vars ret-assrts = list-filter (λ where (mk v _) → v ≈? rv) $ PS.assrts ps arg-assrts = list-filter (dec-neg λ where (mk v _) → v ≈? rv) $ PS.assrts ps R.put $ PS.kst ps (ok b) ← kompile-cls cs vars rv where (error x) → return $ error x return $! ok $ Function ns vars $ flip (L.foldr (λ where (mk v a) → Let (v ++ "_assrt") $ Assert a)) arg-assrts $ Let rv b $ flip (L.foldr (λ where (mk v a) → Let (v ++ "_assrt") $ Assert a)) ret-assrts $ Var rv kompile-fun _ _ _ = return $ kf "expected pattern-matching lambda" private kp : ∀ {X} → String → SPS (Err X) kp x = return $ error $ "kompile-pi: " ++ x ke : ∀ {X} → String → SPS (Err X) ke x = return $ error x module P = RawMonadState (StateMonadState PS) infixl 10 _p+=c_ _p+=a_ _p+=c_ : PS → ℕ → PS ps p+=c n = record ps{ cnt = PS.cnt ps + n } _p+=a_ : PS → Assrt → PS ps p+=a a = record ps{ assrts = a ∷ PS.assrts ps } ps-fresh : String → SPS String ps-fresh x = do ps ← P.get P.modify (_p+=c 1) return $ x ++ showNat (PS.cnt ps) lift-ks : ∀ {X} → SKS X → SPS X lift-ks xf sps = let (x , sks) = xf (PS.kst sps) in x , record sps {kst = sks} sps-kompile-term : Term → SPS $ Err Expr sps-kompile-term t = do ps ← P.get lift-ks $ kompile-term t (PS.ctx ps) kompile-ty : Type → (pi-ok : Bool) → SPS (Err ⊤) kompile-ty (Π[ s ∶ arg i x ] y) false = kp "higher-order functions are not supported" kompile-ty (Π[ s ∶ ty@(arg i x) ] y) true = do v ← ps-fresh "x_" P.modify λ k → record k { cur = v } (ok t) ← kompile-ty x false where e → return e P.modify λ k → record k { cur = PS.ret k -- In case this is a return type ; ctx = PS.ctx k ++ L.[(v , ty)] } kompile-ty y true kompile-ty (con c args) pi-ok = kp $ "don't know how to handle `" ++ showName c ++ "` constructor" kompile-ty (def (quote ℕ) args) _ = return $ ok tt kompile-ty (def (quote Bool) args) _ = return $ ok tt kompile-ty (def (quote Fin) (arg _ x ∷ [])) _ = do ok p ← sps-kompile-term x where error x → ke x v ← PS.cur <$> P.get P.modify $ _p+=a (mk v (BinOp Lt (Var v) p)) return $ ok tt kompile-ty (def (quote _≡_) (_ ∷ arg _ ty ∷ arg _ x ∷ arg _ y ∷ [])) _ = do ok x ← sps-kompile-term x where error x → ke x ok y ← sps-kompile-term y where error x → ke x v ← PS.cur <$> P.get P.modify $ _p+=a (mk v (BinOp Eq x y)) return $ ok tt kompile-ty (def (quote Dec) (_ ∷ arg _ p ∷ [])) _ = do --_ ← kompile-ty p false return $ ok tt kompile-ty (def n _) _ = kp $ "cannot handle `" ++ showName n ++ "` type" kompile-ty t _ = kp $ "failed with the term `" ++ showTerm t ++ "`" kompile-pi x = kompile-ty x true -- The names in the telescopes very oftern are not unique, which -- would be pretty disasterous if the code generation relies on them. -- see https://github.com/agda/agda/issues/5048 for more details. -- -- This function simply ensures that variable names are unique in -- in the telescope. tel-rename : Telescope → (db : List (String × ℕ)) → Telescope tel-rename [] db = [] tel-rename ((v , ty) ∷ tel) db with list-find-el ((_≈? v) ∘ proj₁) db ... | just (_ , n) = (v ++ "_" ++ showNat n , ty) ∷ tel-rename tel (list-update-fst ((_≈? v) ∘ proj₁) db (Σ.map₂ suc)) ... | nothing = (v , ty) ∷ tel-rename tel ((v , 1) ∷ db) private kc : String → SKS $ Err Expr kc x = return $ error $ "kompile-cls: " ++ x _>>=e_ : ∀ {a}{X : Set a} → Err X → (X → SKS $ Err Expr) → SKS $ Err Expr (error s) >>=e _ = return $ error s (ok x) >>=e f = f x kompile-tel : Telescope → SPS (Err ⊤) kompile-tel [] = return $ ok tt kompile-tel ((v , t@(arg i x)) ∷ tel) = do (ok τ) ← kompile-ty x false where (error x) → return $ error x P.modify λ k → record k{ ctx = PS.ctx k ++ [( v , t )] } kompile-tel tel fold-expr : (Expr → Expr → Expr) → Expr → List Expr → Expr fold-expr f e [] = e fold-expr f _ (x ∷ []) = x fold-expr f e (x ∷ xs) = f x (fold-expr f e xs) emap : ∀ {a b}{X : Set a}{Y : Set b} → (X → Y) → Err X → Err Y emap f (error x) = error x emap f (ok x) = ok $ f x emap₂ : ∀ {a b c}{X : Set a}{Y : Set b}{Z : Set c} → (X → Y → Z) → Err X → Err Y → Err Z emap₂ f (error x) _ = error x emap₂ f _ (error x) = error x emap₂ f (ok x) (ok y) = ok (f x y) kompile-cls [] ctx ret = kc "zero clauses found" kompile-cls (clause tel ps t ∷ []) ctx ret = -- Make telscope names unique. let tel = (tel-rename $! tel) $! [] in kompile-clpats tel ps (L.map Var ctx) defaultPatSt >>=e λ pst → do let (mk vars assgns _ _) = pst --in ok t ← kompile-term t $! tel where (error x) → kc x let as = flip (L.foldr (uncurry Let)) assgns return $ ok $ as $ t --Let ret t --$ Var ret kompile-cls (absurd-clause tel ps ∷ []) ctx ret = -- Exactly the same as above -- We don't really need to make this call, but we keep it -- for sanity checks. I.e. if we'll get an error in the -- patterns, it will bubble up to the caller. kompile-clpats ((tel-rename $! tel) $! []) ps (L.map Var ctx) defaultPatSt >>=e λ pst → do return $ ok $ Assert (Nat 0) kompile-cls (absurd-clause tel ps ∷ ts@(_ ∷ _)) ctx ret = kompile-clpats ((tel-rename $! tel) $! []) ps (L.map Var ctx) defaultPatSt >>=e λ pst → do let (mk vars _ conds _) = pst cs = fold-expr (BinOp And) (Nat 1) conds ok r ← kompile-cls ts ctx ret where (error x) → kc x return $ ok $ If cs (Assert (Nat 0)) r kompile-cls (clause tel ps t ∷ ts@(_ ∷ _)) ctx ret = kompile-clpats ((tel-rename $! tel) $! []) ps (L.map Var ctx) defaultPatSt >>=e λ pst → do let (mk vars assgns conds _) = pst cs = fold-expr (BinOp And) (Nat 1) conds as = flip (L.foldr (uncurry Let)) assgns --ok t ← kompile-term t tel where (error x) → kc x --ok r ← kompile-cls ts ctx ret where (error x) → kc x --return $ ok $ If cs (as t) r t ← kompile-term t tel r ← kompile-cls ts ctx ret return $ emap₂ (If cs) (emap as t) r tel-lookup-name : Telescope → ℕ → Prog tel-lookup-name tel n with n ℕ.<? L.length (L.reverse tel) ... | yes n<l = ok $ proj₁ $ L.lookup (L.reverse tel) $ fromℕ< n<l ... | no _ = error "Variable lookup in telescope failed" private kcp : String → Err PatSt kcp x = error $ "kompile-clpats: " ++ x infixl 10 _+=c_ _+=a_ _+=v_ _+=n_ _+=c_ : PatSt → Expr → PatSt p +=c c = record p { conds = PatSt.conds p ++ [ c ] } _+=a_ : PatSt → _ → PatSt p +=a a = record p { assigns = PatSt.assigns p ++ [ a ] } _+=v_ : PatSt → String × ℕ → PatSt p +=v v = record p { vars = PatSt.vars p ++ [ v ] } _+=n_ : PatSt → ℕ → PatSt p +=n n = record p { cnt = PatSt.cnt p + 1 } pst-fresh : PatSt → String → Err $ String × PatSt pst-fresh pst x = return $ x ++ showNat (PatSt.cnt pst) , pst +=n 1 sz : List $ Arg Pattern → ℕ sz [] = 0 sz (arg i (con c ps) ∷ l) = 1 + sz ps + sz l sz (arg i _ ∷ l) = 1 + sz l sz++ : ∀ (a b : List $ Arg Pattern) → sz (a L.++ b) ≡ sz a + sz b sz++ [] b = refl sz++ (arg i (con c ps) ∷ a) b rewrite ℕ.+-assoc (sz ps) (sz a) (sz b) = cong suc (cong (sz ps +_) (sz++ a b)) sz++ (arg i (dot t) ∷ a) b = cong suc $ sz++ a b sz++ (arg i (var x₁) ∷ a) b = cong suc $ sz++ a b sz++ (arg i (lit l) ∷ a) b = cong suc $ sz++ a b sz++ (arg i (proj f) ∷ a) b = cong suc $ sz++ a b sz++ (arg i (absurd x₁) ∷ a) b = cong suc $ sz++ a b ++-strict : ∀ {X : Set} (a b : List X) → a ++ b ≡ a L.++ b ++-strict a b rewrite force′-≡ a L._++_ | force′-≡ b (L._++_ a) = refl ps++l<m : ∀ {m} ps l → suc (sz ps + sz l) ℕ.< suc m → sz (ps ++ l) ℕ.< m ps++l<m {m} ps l sz<m rewrite ++-strict ps l = subst (ℕ._< m) (sym $ sz++ ps l) (ℕ.≤-pred sz<m) a<b⇒a<1+b : ∀ {a b} → a ℕ.< b → a ℕ.< 1 + b a<b⇒a<1+b {a} {b} a<b = ℕ.s≤s (ℕ.<⇒≤ a<b) a+b<c⇒b<c : ∀ {a b c} → a + b ℕ.< c → b ℕ.< c a+b<c⇒b<c {zero} {b} {c} a+b<c = a+b<c a+b<c⇒b<c {suc a} {b} {suc c} a+b<c = a<b⇒a<1+b $ a+b<c⇒b<c (ℕ.≤-pred a+b<c) sz[l]<m : ∀ {m} ps l → suc (sz ps + sz l) ℕ.< suc m → sz l ℕ.< m sz[l]<m {m} ps l sz<m = a+b<c⇒b<c $ ℕ.≤-pred sz<m --kompile-cls : Clauses → (vars : Strings) → (ret : String) → SKS $ Err String kompile-clpats′ : ∀ {m} → Telescope → (pats : List $ Arg Pattern) → .(sz pats ℕ.< m) → (exprs : List Expr) → PatSt → Err PatSt kompile-clpats′ {suc m} tel (arg i (con (quote true) ps) ∷ l) sz<m (v ∷ ctx) pst = kompile-clpats′ tel l (sz[l]<m ps l sz<m) ctx $ pst +=c v {- != 0 -} --is true kompile-clpats′ {suc m} tel (arg i (con (quote false) ps) ∷ l) sz<m (v ∷ ctx) pst = kompile-clpats′ tel l (sz[l]<m ps l sz<m) ctx $ pst +=c BinOp Eq v (Nat 0) kompile-clpats′ {suc m} tel (arg i (con (quote ℕ.zero) ps) ∷ l) sz<m (v ∷ ctx) pst = kompile-clpats′ tel l (sz[l]<m ps l sz<m) ctx $ pst +=c BinOp Eq v (Nat 0) --(v == 0) kompile-clpats′ {suc m} tel (arg i (con (quote ℕ.suc) ps) ∷ l) sz<m (v ∷ ctx) pst = kompile-clpats′ tel (ps ++ l) (ps++l<m ps l sz<m) (BinOp Minus v (Nat 1) ∷ ctx) $ pst +=c BinOp Gt v (Nat 0) --(v > 0) kompile-clpats′ {suc m} tel (arg i (con (quote F.zero) ps) ∷ l) sz<m (v ∷ ctx) pst = kompile-clpats′ tel l (sz[l]<m ps l sz<m) ctx $ pst +=c BinOp Eq v (Nat 0) --(v ++ " == 0") kompile-clpats′ {suc m} tel (arg i (con (quote F.suc) ps@(_ ∷ _ ∷ [])) ∷ l) sz<m (v ∷ ctx) pst = do (ub , pst) ← pst-fresh pst "ub_" -- XXX here we are not using `ub` in conds. For two reasons: -- 1) as we have assertions, we should check the upper bound on function entry -- 2) typically, the value of this argument would be Pat.dot, which we ignore -- right now. It is possible to capture the value of the dot-patterns, as -- they carry the value when reconstructed. kompile-clpats′ tel (ps ++ l) (ps++l<m ps l sz<m) (Var ub ∷ (BinOp Minus v (Nat 1)) ∷ ctx) $ pst +=c BinOp Gt v (Nat 0) --(v ++ " > 0") -- For refl we don't need to generate a predicate, as refl is an element of a singleton type. kompile-clpats′ {suc m} tel (arg i (con (quote refl) ps) ∷ l) sz<m (v ∷ ctx) pst = kompile-clpats′ tel l (sz[l]<m ps l sz<m) ctx pst kompile-clpats′ {suc m} tel (arg i (con (quote _because_) ps) ∷ l) sz<m (v ∷ ctx) pst = do pf , pst ← pst-fresh pst $ "pf_" kompile-clpats′ tel (ps ++ l) (ps++l<m ps l sz<m) (v ∷ Var pf ∷ ctx) pst kompile-clpats′ {suc m} tel (arg i (con (quote Reflects.ofʸ) ps) ∷ l) sz<m (v ∷ ctx) pst = kompile-clpats′ tel (ps ++ l) (ps++l<m ps l sz<m) (Nat 1 ∷ ctx) pst kompile-clpats′ {suc m} tel (arg i (con (quote Reflects.ofⁿ) ps) ∷ l) sz<m (v ∷ ctx) pst = kompile-clpats′ tel (ps ++ l) (ps++l<m ps l sz<m) (Nat 0 ∷ ctx) pst kompile-clpats′ {suc m} tel (arg (arg-info _ r) (var i) ∷ l) sz<m (v ∷ vars) pst = do s ← tel-lookup-name tel i let pst = pst +=v (s , i) let pst = if does (s ≈? "_") then pst else pst +=a (s , v) kompile-clpats′ tel l (ℕ.≤-pred sz<m) vars pst kompile-clpats′ {suc m} tel (arg i (dot t) ∷ l) sz<m (v ∷ vars) pst = -- For now we just skip dot patterns. kompile-clpats′ tel l (ℕ.≤-pred sz<m) vars pst kompile-clpats′ {suc m} tel (arg i (absurd _) ∷ l) sz<m (v ∷ ctx) pst = -- If have met the absurd pattern, we'd still have to -- accumulate remaining conditions, as patterns are not -- linear :( For example, see test4-f in examples. kompile-clpats′ tel l (ℕ.≤-pred sz<m) ctx pst kompile-clpats′ _ [] _ [] pst = ok pst kompile-clpats′ tel ps _ ctx patst = kcp $ "failed on pattern: [" ++ (", " ++/ L.map (λ where (arg _ x) → showPattern x) ps) ++ "], ctx: [" ++ (", " ++/ (L.map (expr-to-string 0) ctx)) ++ "]" kompile-clpats tel pats ctx pst = kompile-clpats′ {m = suc (sz pats)} tel pats ℕ.≤-refl ctx pst private kt : ∀ {X} → String → SKS $ Err X kt x = return $ error $ "kompile-term: " ++ x mk-mask : (n : ℕ) → List $ Fin n mk-mask zero = [] mk-mask (suc n) = L.reverse $ go n (suc n) ℕ.≤-refl where sa<b⇒a<b : ∀ a b → suc a ℕ.< b → a ℕ.< b sa<b⇒a<b zero (suc b) _ = ℕ.s≤s ℕ.z≤n sa<b⇒a<b (suc a) (suc n) (ℕ.s≤s pf) = ℕ.s≤s $ sa<b⇒a<b a n pf go : (m n : ℕ) → m ℕ.< n → List $ Fin n go 0 (suc _) _ = zero ∷ [] go (suc m) n pf = F.fromℕ< pf ∷ go m n (sa<b⇒a<b m n pf) le-to-el : ∀ {a}{X : Set a} → List (Err X) → Err (List X) le-to-el [] = ok [] le-to-el (x ∷ l) = _∷_ <$> x ⊛ le-to-el l mk-iota-mask : ℕ → List ℕ mk-iota-mask n = L.reverse $! go n [] where go : ℕ → List ℕ → List ℕ go zero l = l go (suc n) l = n ∷ go n l {- kompile-arglist : (n : ℕ) → List $ Arg Term → List $ Fin n → Telescope → SKS $ Err (List Expr) kompile-arglist n args mask varctx with L.length args ℕ.≟ n | V.fromList args ... | yes p | vargs rewrite p = do l ← mapM (λ where (arg _ x) → kompile-term x varctx) $ L.map (V.lookup vargs) mask return $ le-to-el l where open TraversableM (StateMonad KS) ... | no ¬p | _ = kt "Incorrect argument mask" -} kompile-arglist-idx : List $ Arg Term → (idx : ℕ) → Telescope → SKS $ Err Expr kompile-arglist-idx [] _ tel = return $ error "incorrect arglist index" kompile-arglist-idx (arg _ x ∷ args) zero tel = kompile-term x tel kompile-arglist-idx (x ∷ args) (suc n) tel = kompile-arglist-idx args n tel kompile-arglist : List $ Arg Term → List ℕ → Telescope → SKS $ Err (List Expr) kompile-arglist args [] tel = return $ ok [] kompile-arglist args (x ∷ idxs) tel = do ok t ← kompile-arglist-idx args x tel where (error x) → return $ error x ok ts ← kompile-arglist args idxs tel where (error x) → return $ error x return $ ok $ t ∷ ts kompile-term (var x []) vars = return $ Var <$> tel-lookup-name vars x kompile-term (var x args@(_ ∷ _)) vars = do let f = tel-lookup-name vars x l = L.length args --args ← kompile-arglist l args (mk-mask l) vars args ← kompile-arglist args (mk-iota-mask l) vars return $ Call <$> f ⊛ args kompile-term (lit l@(nat x)) vars = return $ ok $ Nat x kompile-term (con (quote ℕ.zero) _) _ = return $ ok $ Nat 0 kompile-term (con (quote ℕ.suc) (arg _ a ∷ [])) vars = do a ← kompile-term a vars return $ BinOp <$> ok Plus ⊛ ok (Nat 1) ⊛ a kompile-term (con (quote F.zero) _) _ = return $ ok $ Nat 0 kompile-term (con (quote F.suc) (_ ∷ arg _ a ∷ [])) vars = do a ← kompile-term a vars return $ BinOp <$> ok Plus ⊛ ok (Nat 1) ⊛ a kompile-term (con (quote refl) _) _ = return $ ok $ Nat 1 kompile-term (con c _) vars = kt $ "don't know constructor " ++ (showName c) -- From Agda.Builtin.Nat: div-helper k m n j = k + (n + m - j) div (1 + m) kompile-term (def (quote div-helper) (arg _ k ∷ arg _ m ∷ arg _ n ∷ arg _ j ∷ [])) vars = do k ← kompile-term k vars m ← kompile-term m vars n ← kompile-term n vars j ← kompile-term j vars let n+m = BinOp <$> ok Plus ⊛ n ⊛ m n+m-j = BinOp <$> ok Minus ⊛ n+m ⊛ j k+[n+m-j] = BinOp <$> ok Plus ⊛ k ⊛ n+m-j 1+m = BinOp <$> ok Plus ⊛ ok (Nat 1) ⊛ m return $ BinOp <$> ok Divide ⊛ k+[n+m-j] ⊛ 1+m kompile-term (def (quote ℕ._≟_) (arg _ a ∷ arg _ b ∷ [])) vars = do a ← kompile-term a vars b ← kompile-term b vars return $ BinOp <$> ok Eq ⊛ a ⊛ b kompile-term (def (quote _+_) args@(arg _ a ∷ arg _ b ∷ [])) vars = do a ← kompile-term a vars b ← kompile-term b vars return $ BinOp <$> ok Plus ⊛ a ⊛ b kompile-term (def (quote ℕ._*_) args@(arg _ a ∷ arg _ b ∷ [])) vars = do a ← kompile-term a vars b ← kompile-term b vars return $ BinOp <$> ok Times ⊛ a ⊛ b kompile-term (def (quote F.fromℕ<) args) vars = do ok (x ∷ []) ← kompile-arglist args (0 ∷ []) vars where _ → kt "kopmile-arglist is broken" return $ ok x -- The last pattern in the list of `def` matches kompile-term (def n []) _ = kt $ "attempting to compile `" ++ showName n ++ "` as function with 0 arguments" kompile-term (def n args@(_ ∷ _)) vars = do R.modify λ k → record k { funs = KS.funs k ++ [ n ] } let n = {-nnorm $-} showName n l = L.length args --args ← kompile-arglist l args (mk-mask l) vars args ← kompile-arglist args (mk-iota-mask l) vars return $ Call <$> ok n ⊛ args kompile-term t vctx = kt $ "failed to compile term `" ++ showTerm t ++ "`"
Library/AccPnt/accpntApi.asm
steakknife/pcgeos
504
94911
COMMENT @%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% Copyright (c) Geoworks 1995 -- All Rights Reserved GEOWORKS CONFIDENTIAL PROJECT: socket MODULE: access point database FILE: accpntApi.asm AUTHOR: <NAME>, Apr 24, 1995 ROUTINES: Name Description ---- ----------- GLB AccessPointCreateEntry Create an access point GLB AccessPointDestroyEntry Destroy an access point GLB AccessPointDestroyEntryNoNotify GLB AccessPointMultiDestroyDone GLB AccessPointGetType Get the access point type GLB AccessPointSetStringProperty Set a string property on an access point GLB AccessPointSetIntegerProperty Set a integer property on an access point GLB AccessPointGetStringProperty Get a string property on an access point GLB AccessPointGetIntegerProperty Get a integer property on an access point GLB AccessPointDestroyProperty Destroy one property of an access point GLB AccessPointGetEntries Get a chunk array of entry IDs of a given type INT GetEntriesCallback Possibly copy an access point from one array to another GLB AccessPointCompareStandardProperty Compare a string to a standard property name GLB AccessPointCommit Forces changes to disk GLB AccessPointIsEntryValid Test whether an access point exists GLB AccessPointLock Lock an access point to prevent changes GLB AccessPointUnlock Unlock an access point INT AccessPointCheckLock Check if an access point is locked REVISION HISTORY: Name Date Description ---- ---- ----------- EW 4/24/95 Initial revision jwu 10/25/96 Added locking access points DESCRIPTION: $Id: accpntApi.asm,v 1.17 97/10/22 13:19:16 brianc Exp $ %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%@ Strings segment lmem LMEM_TYPE_GENERAL accpntCategory chunk.char "accpnt",0 localize not activeKey chunk.char "active0",0 localize not Strings ends ApiCode segment resource COMMENT @%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% AccessPointCreateEntry %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% SYNOPSIS: Create an access point CALLED BY: GLOBAL PASS: bx - ID of entry before which to insert new entry (0 to place at end) ax - AccessPointType RETURN: ax - new ID carry set if old entry not found DESTROYED: nothing SIDE EFFECTS: PSEUDO CODE/STRATEGY: REVISION HISTORY: Name Date Description ---- ---- ----------- EW 4/24/95 Initial version %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%@ AccessPointCreateEntry proc far uses bx,cx,dx,si,di,bp,ds .enter push bx, ax EnterDatabase bx Assert etype ax, AccessPointType ; ; read the last assigned key value from the database ; segmov ds, cs mov si, offset initCategory mov cx, cs mov dx, offset initIDKey call InitFileReadInteger ; ax=value, carry on err jnc nextValue clr ax ; ; increment the value ; if we reach 65536, wrap around, but skip over zero ; nextValue: inc ax jnz noZ inc ax ; don't use zero noZ: call CheckIfEntryExists ; carry if does not exist jnc nextValue ; ; this is the value we want to use ; valueOK:: pop bx, dx ; position, type call AllocateEntry ; carry on err jc done call GenerateCreationNotice ; ; note that we've used this ID ; mov bp, ax mov dx, offset initIDKey call InitFileWriteInteger ; carry on err EC < ERROR_C UNABLE_TO_ALLOCATE_ENTRY_POINT > ; ; commit the changes ; AccpntCommit clc done: ExitDatabase bx .leave ret AccessPointCreateEntry endp COMMENT @%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% AccessPointDestroyEntry %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% SYNOPSIS: Destroy an access point CALLED BY: GLOBAL PASS: ax - id of access point to destroy RETURN: carry - set if access point does not exist or is locked DESTROYED: nothing SIDE EFFECTS: PSEUDO CODE/STRATEGY: REVISION HISTORY: Name Date Description ---- ---- ----------- EW 4/25/95 Initial version %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%@ AccessPointDestroyEntry proc far uses ax,dx .enter call GetTypeLow call AccessPointGetActivePoint call AccessPointDestroyEntryDirect .leave ret AccessPointDestroyEntry endp AccessPointDestroyEntryDirect proc far uses ax,bx,cx,dx,si,ds,es .enter EnterDatabase bx ; ; make sure changes are allowed ; call AccessPointCheckLock jc done ; locked! ; ; remove access point from table of contents ; call FreeEntryFile ; remove from init file jc done call FreeEntryMem ; dx = entry type call BuildEntryCategory ; get category name ; ; remove it's category, and hence all of its properties ; call InitFileDeleteCategory call GenerateDeletionNotice AccpntCommit clc done: ExitDatabase bx .leave ret AccessPointDestroyEntryDirect endp COMMENT @%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% AccessPointDestroyEntryNoNotify %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% SYNOPSIS: Destroy an access point, but don't send out notifications. CALLED BY: AccessPointSelectorDeleteMulti PASS: ax = id of access point to destroy RETURN: carry set if access point does not exist or is locked dx = entry type DESTROYED: nothing PSEUDO CODE/STRATEGY: REVISION HISTORY: Name Date Description ---- ---- ----------- jwu 1/ 1/97 Initial version %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%@ AccessPointDestroyEntryNoNotify proc far uses ax, bx, cx, si, ds, es .enter EnterDatabase bx ; ; make sure changes are allowed ; call AccessPointCheckLock jc done ; locked! ; ; remove access point from table of contents ; call FreeEntryFile ; remove from init file jc done call FreeEntryMem ; dx = entry type call BuildEntryCategory ; get category name ; ; remove it's category, and hence all of its properties ; call InitFileDeleteCategory AccpntCommit clc done: ExitDatabase bx .leave ret AccessPointDestroyEntryNoNotify endp COMMENT @%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% AccessPointMultiDestroyDone %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% SYNOPSIS: Send batched notification for group of deleted access points. CALLED BY: AccessPointSelectorDeleteMulti PASS: bx = block of IDs dx = entry type RETURN: nothing DESTROYED: nothing PSEUDO CODE/STRATEGY: REVISION HISTORY: Name Date Description ---- ---- ----------- jwu 1/ 1/97 Initial version %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%@ AccessPointMultiDestroyDone proc far uses ax .enter mov ax, bx call GenerateMultiDeletionNotice .leave ret AccessPointMultiDestroyDone endp COMMENT @%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% AccessPointGetType %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% SYNOPSIS: Get the access point type CALLED BY: GLOBAL PASS: ax - access point ID RETURN: bx - AccessPointType (0 if not found) carry set if not found DESTROYED: nothing SIDE EFFECTS: PSEUDO CODE/STRATEGY: REVISION HISTORY: Name Date Description ---- ---- ----------- EW 5/ 2/95 Initial version %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%@ AccessPointGetType proc far uses ax,cx,dx,si,di,bp,ds .enter EnterDatabase bx call GetTypeLow ; dx = AccessPointType ExitDatabase bx mov bx, dx ; ; set carry if bx=0 ; tst bx lahf rcl ah rcl ah .leave ret AccessPointGetType endp COMMENT @%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% AccessPointGetActivePoint %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% SYNOPSIS: Get the active point CALLED BY: GLOBAL PASS: ax - access point ID dx - type RETURN: ax - the active accesspoint for the same type carry set if not found DESTROYED: nothing SIDE EFFECTS: PSEUDO CODE/STRATEGY: REVISION HISTORY: Name Date Description ---- ---- ----------- mzhu 2/ 2/99 Initial version %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%@ AccessPointGetActivePoint proc far uses bx,cx,dx,si,di,bp,ds,es .enter add dx, 48 ; '0' = 48 push ax segmov es, ds, bx mov bx, handle Strings call MemLock mov ds, ax mov cx, ax assume ds:Strings mov bp, ds:[activeKey] mov ds:[bp+6], dx mov dx, ds:[activeKey] ; cx:dx = key mov si, ds:[accpntCategory] ; ds:si = category assume ds:nothing pop ax call InitFileReadInteger ; ax = accpnt pushf mov bx, handle Strings call MemUnlock popf .leave ret AccessPointGetActivePoint endp COMMENT @%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% AccessPointSetActivePoint %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% SYNOPSIS: Set the active point for the type CALLED BY: GLOBAL PASS: ax - access point dx - type RETURN: carry set if error DESTROYED: nothing SIDE EFFECTS: PSEUDO CODE/STRATEGY: REVISION HISTORY: Name Date Description ---- ---- ----------- mzhu 2/ 2/99 Initial version %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%@ AccessPointSetActivePoint proc far uses ax, bx,cx,dx,si,di,bp,ds,es .enter add dx, 48 ; '0' = 48 push ax segmov es, ds, bx mov bx, handle Strings call MemLock mov ds, ax mov cx, ax assume ds:Strings mov bp, ds:[activeKey] mov ds:[bp+6], dx mov dx, ds:[activeKey] ; cx:dx = key mov si, ds:[accpntCategory] ; ds:si = category assume ds:nothing pop bp call InitFileWriteInteger pushf mov bx, handle Strings call MemUnlock popf .leave ret AccessPointSetActivePoint endp ifdef SCRAMBLED_INI_STRINGS COMMENT @%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% APCheckScrambledProperty %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% SYNOPSIS: Check if this property is to be scrambled CALLED BY: INTERNAL PASS: cx:dx - pointer to property name if cx = 0, dx = APSP_ RETURN: carry set if scrambled DESTROYED: nothing SIDE EFFECTS: PSEUDO CODE/STRATEGY: REVISION HISTORY: Name Date Description ---- ---- ----------- brianc 10/30/98 Initial version %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%@ APCheckScrambledProperty proc near jcxz checkScrambled notScrambled: clc ; only APSPs supported ret checkScrambled: cmp dx, APSP_SECRET jne notScrambled ; not scrambled stc ; APSP_SECRET, scramble ret APCheckScrambledProperty endp COMMENT @%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% APScramble, APUnscramble %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% SYNOPSIS: Scramble and unscramble .ini string CALLED BY: INTERNAL PASS: es:di - ASCIIZ string cx - num chars, 0 for null-terminated RETURN: cx - length if 0 passed in, otherwise unchanged DESTROYED: nothing SIDE EFFECTS: PSEUDO CODE/STRATEGY: REVISION HISTORY: Name Date Description ---- ---- ----------- brianc 10/30/98 Initial version %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%@ APScramble proc near uses ax, ds, si, di .enter tst cx jnz haveLength call LocalStringLength ; cx = length haveLength: jcxz done push cx segmov ds, es, si mov si, di scrambleLoop: LocalGetChar ax, dssi SBCS < xor al, 0xbc > DBCS < xor ax, 0xbcbc > LocalPutChar esdi, ax loop scrambleLoop pop cx done: .leave ret APScramble endp APUnscramble equ APScramble COMMENT @%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% APScrambleAndInitFileWrite %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% SYNOPSIS: Scramble and write .ini string CALLED BY: INTERNAL PASS: ds:si - category ASCIIZ string cx:dx - key ASCIIZ string es:di - body ASCIIZ string RETURN: nothing DESTROYED: nothing SIDE EFFECTS: PSEUDO CODE/STRATEGY: REVISION HISTORY: Name Date Description ---- ---- ----------- brianc 10/30/98 Initial version %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%@ APScrambleAndInitFileWrite proc near uses bp .enter ; ; scramble data ; push cx clr cx ; null-terminated call APScramble mov bp, cx ; bp = size for write data DBCS < shl bp, 1 > pop cx ; ; write scrambled string to .ini file ; call InitFileWriteData ; ; unscramble so user buffer is not altered ; push cx clr cx ; null-terminated call APScramble pop cx .leave ret APScrambleAndInitFileWrite endp COMMENT @%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% APInitFileReadAndUnscramble %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% SYNOPSIS: Read .ini string and unscramble CALLED BY: INTERNAL PASS: ds:si - category ASCIIZ string cx:dx - key ASCIIZ string bp - size If size = 0 Buffer will be allocated for string Else es:di - buffer to fill RETURN: carry - clear if successful cx - number of chars retrieved (excluding null terminator) cx = 0 if category / key not found bx - mem handle to block containing entry (IFRF_SIZE = 0) - or - es:di - buffer filled (IFRF_SIZE != 0) DESTROYED: nothing SIDE EFFECTS: PSEUDO CODE/STRATEGY: REVISION HISTORY: Name Date Description ---- ---- ----------- brianc 10/30/98 Initial version %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%@ APInitFileReadAndUnscramble proc near ; ; read scrambled string from .ini file ; call InitFileReadData ; ; unscramble ; jc done ; error, return it tst bp ; have buffer? jnz haveBuffer push ax, es, di call MemLock mov es, ax clr di haveBuffer: DBCS < shr cx, 1 ; bytes to chars > call APUnscramble ; pass cx = num chars tst bp jnz done call MemUnlock pop ax, es, di clc ; indicate success done: ret APInitFileReadAndUnscramble endp endif ; SCRAMBLED_INI_STRINGS COMMENT @%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% AccessPointSetStringProperty %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% SYNOPSIS: Set a string property on an access point CALLED BY: GLOBAL PASS: ax - access point id cx:dx - null terminated property name es:di - null terminated property value RETURN: carry set if access point does not exist or is locked DESTROYED: nothing SIDE EFFECTS: PSEUDO CODE/STRATEGY: REVISION HISTORY: Name Date Description ---- ---- ----------- EW 4/25/95 Initial version %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%@ AccessPointSetStringProperty proc far uses ax,dx .enter mov bx, dx call GetTypeLow call AccessPointGetActivePoint mov dx, bx call AccessPointSetStringPropertyDirect .leave ret AccessPointSetStringProperty endp AccessPointSetStringPropertyDirect proc far uses bx,cx,dx,ds,si .enter Assert fptrXIP, esdi EnterDatabase bx call ValidateEntry jc done ; ; Only allow change if accpnt not locked or if property is ; automatic. ; test dx, APSP_AUTOMATIC jz checkLock jcxz continue checkLock: call AccessPointCheckLock jc done continue: ; ; Set string property. ; ifdef SCRAMBLED_INI_STRINGS call APCheckScrambledProperty pushf ; save result endif call ParseStandardProperty ; cx:dx=key, bx=APSP call BuildEntryCategory ; ds:si = category ifdef SCRAMBLED_INI_STRINGS popf ; C set if scrambled jnc notScrambled call APScrambleAndInitFileWrite jmp afterWrite notScrambled: call InitFileWriteString afterWrite: else call InitFileWriteString endif AccpntCommit call GenerateChangeNotice clc ; indicate success done: ExitDatabase bx .leave ret AccessPointSetStringPropertyDirect endp COMMENT @%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% AccessPointSetIntegerProperty %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% SYNOPSIS: Set a integer property on an access point CALLED BY: GLOBAL PASS: ax - access point id cx:dx - null terminated property name bp - value to store RETURN: carry set if access point does not exist or is locked DESTROYED: nothing SIDE EFFECTS: PSEUDO CODE/STRATEGY: REVISION HISTORY: Name Date Description ---- ---- ----------- EW 4/25/95 Initial version %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%@ AccessPointSetIntegerProperty proc far uses ax,dx .enter mov bx, dx call GetTypeLow call AccessPointGetActivePoint mov dx, bx call AccessPointSetIntegerPropertyDirect .leave ret AccessPointSetIntegerProperty endp AccessPointSetIntegerPropertyDirect proc far uses bx,cx,dx,ds,si .enter EnterDatabase bx call ValidateEntry jc done ; ; Only allow change if accpnt not locked or if property is ; automatic. ; test dx, APSP_AUTOMATIC jz checkLock jcxz continue checkLock: call AccessPointCheckLock jc done continue: ; ; Set integer property. ; call ParseStandardProperty ; cx:dx = key, ; bx = APSP call BuildEntryCategory ; ds:si = category call InitFileWriteInteger AccpntCommit call GenerateChangeNotice clc ; indicate success done: ExitDatabase bx .leave ret AccessPointSetIntegerPropertyDirect endp COMMENT @%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% AccessPointGetStringProperty %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% SYNOPSIS: Get a string property on an access point CALLED BY: GLOBAL PASS: ax - access point id cx:dx - null terminated property name bp - size of buffer (0 to allocate block) es:di - buffer for property value (if bp != 0) RETURN: carry set on error cx - number of chars retrieved (excluding null terminator) cx = 0 if property not found bx - mem handle to block containing entry - or - es:di - buffer filled DESTROYED: bx (if not returned) SIDE EFFECTS: PSEUDO CODE/STRATEGY: REVISION HISTORY: Name Date Description ---- ---- ----------- EW 4/25/95 Initial version %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%@ AccessPointGetStringProperty proc far uses ax,dx .enter mov bx, dx call GetTypeLow call AccessPointGetActivePoint mov dx, bx call AccessPointGetStringPropertyDirect .leave ret AccessPointGetStringProperty endp AccessPointGetStringPropertyDirect proc far uses dx,bp,si,ds .enter EnterDatabase bx EC < call ValidateEntry > EC < jc done > ifdef SCRAMBLED_INI_STRINGS call APCheckScrambledProperty pushf ; save result endif call ParseStandardProperty ; cx:dx = key and bp, mask IFRF_SIZE ; get low 12 bits EC < jz ptrOK > EC < Assert fptrXIP, esdi > ptrOK:: call BuildEntryCategory ; ds:si = category ifdef SCRAMBLED_INI_STRINGS popf ; C set if scrambled jnc notScrambled call APInitFileReadAndUnscramble jmp afterRead notScrambled: call InitFileReadString afterRead: else call InitFileReadString endif done:: ExitDatabase .leave ret AccessPointGetStringPropertyDirect endp COMMENT @%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% AccessPointGetIntegerProperty %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% SYNOPSIS: Get a integer property on an access point CALLED BY: GLOBAL PASS: ax - access point id cx:dx - null terminated property name RETURN: carry set if error ax - value of property (unchanged if error) DESTROYED: nothing SIDE EFFECTS: PSEUDO CODE/STRATEGY: REVISION HISTORY: Name Date Description ---- ---- ----------- EW 4/25/95 Initial version %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%@ AccessPointGetIntegerProperty proc far uses bx, dx .enter mov bx, dx call GetTypeLow call AccessPointGetActivePoint mov dx, bx call AccessPointGetIntegerPropertyDirect .leave ret AccessPointGetIntegerProperty endp AccessPointGetIntegerPropertyDirect proc far uses bx,cx,dx,ds,si .enter EnterDatabase bx EC < call ValidateEntry > EC < jc done > call ParseStandardProperty ; cx:dx = key call BuildEntryCategory ; ds:si = category call InitFileReadInteger done:: ExitDatabase bx .leave ret AccessPointGetIntegerPropertyDirect endp COMMENT @%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% AccessPointDestroyProperty %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% SYNOPSIS: Destroy one property of an access point CALLED BY: GLOBAL PASS: ax - access point id cx:dx - null terminated property name RETURN: carry set if error (accpnt locked) DESTROYED: nothing SIDE EFFECTS: PSEUDO CODE/STRATEGY: REVISION HISTORY: Name Date Description ---- ---- ----------- EW 4/25/95 Initial version %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%@ AccessPointDestroyProperty proc far uses ax,dx .enter mov bx, dx call GetTypeLow call AccessPointGetActivePoint mov dx, bx call AccessPointDestroyPropertyDirect .leave ret AccessPointDestroyProperty endp AccessPointDestroyPropertyDirect proc far uses bx,cx,dx,si,ds .enter EnterDatabase bx EC < call ValidateEntry > EC < jc done > ; ; Only allow change if accpnt not locked or if property is ; automatic. ; test dx, APSP_AUTOMATIC jz checkLock jcxz change checkLock: call AccessPointCheckLock jc done change: ; ; Delete the property. ; call ParseStandardProperty ; cx:dx = key call BuildEntryCategory ; ds:si = category call InitFileDeleteEntry AccpntCommit call GenerateChangeNotice clc ; indicate success done:: ExitDatabase bx .leave ret AccessPointDestroyPropertyDirect endp COMMENT @%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% AccessPointGetEntries %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% SYNOPSIS: Get a chunk array of entry IDs of a given type CALLED BY: GLOBAL PASS: ds - segment in which to return data si - chunk in which to return data (0 to create one) ax - type of entries to list (APT_ALL for all types) RETURN: ds:si - chunk array of entry ID words (ds may have moved) DESTROYED: nothing SIDE EFFECTS: PSEUDO CODE/STRATEGY: REVISION HISTORY: Name Date Description ---- ---- ----------- EW 4/25/95 Initial version %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%@ AccessPointGetEntries proc far uses ax,bx,cx,dx,di,bp,es .enter EnterDatabase bx, SAVE_DS EC < cmp ax, APT_ALL > EC < je aptOK > EC < Assert etype ax, AccessPointType > aptOK:: EC < Assert segment, ds > EC < tst si > EC < jz chunkOK > EC < Assert chunk si,ds > chunkOK:: mov bp, ax ; remember type ; ; create a chunk array in target block ; mov bx, size word ; element size clr cx ; default header size clr al ; no obj flags call ChunkArrayCreate ; si = chunk push si ; save chunk handle mov cx, ds mov dx, si ; *cx:dx = target array ; ; lock down the source block ; mov bx, handle AccessTypeArray call MemLock mov ds, ax mov si, offset AccessTypeArray ; ; copy the chunk array ; mov bx, cs mov di, offset GetEntriesCallback call ChunkArrayEnum ; ; clean up and exit ; mov bx, handle AccessTypeArray call MemUnlock ; release source block ExitDatabase bx mov ds, cx pop si ; *ds:si = target array .leave ret AccessPointGetEntries endp COMMENT @%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% GetEntriesCallback %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% SYNOPSIS: Possibly copy an access point from one array to another CALLED BY: AccessPointGetEntries (via ChunkArrayEnum) PASS: *ds:si - AccessTypeArray ds:di - current entry in AccessTypeArray *cx:dx - target array bp - desired type RETURN: *cx:dx - target array (possibly moved) carry clear DESTROYED: ax, bx, si, di SIDE EFFECTS: PSEUDO CODE/STRATEGY: REVISION HISTORY: Name Date Description ---- ---- ----------- EW 5/ 2/95 Initial version %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%@ GetEntriesCallback proc far uses ds .enter ; ; if type matches, copy it ; cmp bp, ds:[di] je typeOK ; ; if bp is APT_ALL, copy it ; cmp bp, APT_ALL jne done ; ; switch to AccessPointArray and read ID from same offset ; we are at in AccessTypeArray ; typeOK: sub di, ds:[si] mov si, offset AccessPointArray add di, ds:[si] mov ax, ds:[di] ; ; store it in target array ; mov ds, cx mov si, dx call ChunkArrayAppend ; ds:di = new slot mov ds:[di], ax mov cx, ds ; save new segment value done: clc .leave ret GetEntriesCallback endp COMMENT @%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% AccessPointCompareStandardProperty %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% SYNOPSIS: Compare a string to a standard property name CALLED BY: GLOBAL PASS: es:di - null terminated string to match dx - AccessPointStandardProperty RETURN: zero flag - set if equal DESTROYED: nothing SIDE EFFECTS: PSEUDO CODE/STRATEGY: REVISION HISTORY: Name Date Description ---- ---- ----------- EW 5/17/95 Initial version %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%@ AccessPointCompareStandardProperty proc far uses bx,cx,dx,si,di,ds .enter EnterDatabase bx Assert fptrXIP, esdi ; ; get the standard property name ; clr cx call ParseStandardProperty ; cx:dx = property movdw dssi, cxdx ; ; compare it to the passed value ; clr cx ; null terminated call LocalCmpStringsNoCase ; z flag if equal ExitDatabase bx .leave ret AccessPointCompareStandardProperty endp COMMENT @%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% AccessPointCommit %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% SYNOPSIS: Force changes to disk CALLED BY: GLOBAL PASS: nothing RETURN: nothing DESTROYED: nothing SIDE EFFECTS: PSEUDO CODE/STRATEGY: REVISION HISTORY: Name Date Description ---- ---- ----------- EW 5/23/95 Initial version %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%@ AccessPointCommit proc far call InitFileCommit ret AccessPointCommit endp COMMENT @%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% AccessPointIsEntryValid %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% SYNOPSIS: Test whether an access point exists CALLED BY: GLOBAL PASS: ax - access point ID RETURN: carry set if invalid DESTROYED: nothing SIDE EFFECTS: PSEUDO CODE/STRATEGY: REVISION HISTORY: Name Date Description ---- ---- ----------- EW 11/21/95 Initial version %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%@ AccessPointIsEntryValid proc far uses ax,dx .enter call GetTypeLow call AccessPointGetActivePoint call AccessPointIsEntryValidDirect .leave ret AccessPointIsEntryValid endp AccessPointIsEntryValidDirect proc far uses bx, ds .enter EnterDatabase bx call ValidateEntry ExitDatabase .leave ret AccessPointIsEntryValidDirect endp COMMENT @%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% AccessPointLock %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% SYNOPSIS: Lock an access point. Once an access point is locked, only the automatic settings for it may be modified. CALLED BY: GLOBAL PASS: ax = access point ID RETURN: nothing DESTROYED: nothing PSEUDO CODE/STRATEGY: Writes lock entry to ini for this accpnt. REVISION HISTORY: Name Date Description ---- ---- ----------- jwu 10/25/96 Initial version jwu 01/18/97 lock stored in memory %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%@ AccessPointLock proc far uses ax,dx .enter call GetTypeLow call AccessPointGetActivePoint call AccessPointLockDirect .leave ret AccessPointLock endp AccessPointLockDirect proc far uses bx, cx, dx, di, si, ds, es .enter ; ; If access point is already locked, don't lock it again. ; EnterDatabase bx EC < call ValidateEntry > EC < jc exit > mov_tr cx, ax ; cx = accpnt id mov bx, handle AccessPointLockArray call MemLock mov ds, ax mov es, ax mov si, offset AccessPointLockArray ; *ds:si = array mov di, ds:[si] mov ax, es:[di].CAH_count add di, es:[di].CAH_offset xchg cx, ax ; ax = id, cx = count repne scasw je done ; already locked ; ; Add new lock to array and send a notification for it ; call ChunkArrayAppend mov ds:[di], ax mov dx, APT_INTERNET call GenerateLockNotice done: call MemUnlock exit: ExitDatabase bx .leave ret AccessPointLockDirect endp COMMENT @%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% AccessPointUnlock %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% SYNOPSIS: Unlock an access point. CALLED BY: GLOBAL PASS: ax = access point ID RETURN: nothing DESTROYED: nothing PSEUDO CODE/STRATEGY: Removes lock entry for this accpnt. REVISION HISTORY: Name Date Description ---- ---- ----------- jwu 10/25/96 Initial version jwu 01/18/97 lock stored in memory %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%@ AccessPointUnlock proc far uses ax,dx .enter call GetTypeLow call AccessPointGetActivePoint call AccessPointUnlockDirect .leave ret AccessPointUnlock endp AccessPointUnlockDirect proc far uses bx, cx, dx, di, si, ds, es .enter ; ; Find access point in lock array. ; EnterDatabase bx EC < call ValidateEntry > EC < jc exit > mov_tr cx, ax ; cx = accpnt id mov bx, handle AccessPointLockArray call MemLock mov ds, ax mov es, ax mov si, offset AccessPointLockArray ; *ds:si = array mov di, ds:[si] mov ax, es:[di].CAH_count add di, es:[di].CAH_offset xchg cx, ax ; ax = id, cx = count repne scasw jne done ; ; Delete entry from lock array and send a notification for it ; dec di dec di call ChunkArrayDelete mov dx, APT_INTERNET call GenerateLockNotice done: call MemUnlock exit: ExitDatabase bx .leave ret AccessPointUnlockDirect endp COMMENT @%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% AccessPointCheckLock/AccessPointInUse %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% SYNOPSIS: Check if an access point is locked. If an access point is locked, only the automatic settings may be modified. Applications use AccessPointInUse which hides the concept of locked access points. CALLED BY: EXTERNAL (AccessPointInUse) INTERNAL (AccessPointCheckLock) AccessPointDestroyEntry AccessPointSetStringProperty AccessPointSetIntegerProperty AccessPointDestroyProperty PASS: ax = access point ID RETURN: carry set if locked or in use DESTROYED: nothing PSEUDO CODE/STRATEGY: NOTE: Do not call EnterDatabase here. Caller already got exclusive access and calling it here will cause deadlock. REVISION HISTORY: Name Date Description ---- ---- ----------- jwu 10/25/96 Initial version jwu 01/18/97 locks stored in memory %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%@ AccessPointInUse proc far uses ax,dx .enter call GetTypeLow call AccessPointGetActivePoint call AccessPointInUseDirect .leave ret AccessPointInUse endp AccessPointInUseDirect proc far uses bx .enter EnterDatabase bx, SAVE_DS EC < call ValidateEntry > EC < jc exit > call AccessPointCheckLock exit: ExitDatabase bx, SAVE_DS .leave ret AccessPointInUseDirect endp AccessPointCheckLock proc near uses bx, cx, di, si, es .enter ; ; Check if access point is in lock array. ; mov_tr cx, ax mov bx, handle AccessPointLockArray call MemLock mov es, ax mov di, offset AccessPointLockArray mov di, es:[di] mov ax, es:[di].CAH_count add di, es:[di].CAH_offset xchg cx, ax ; ax = id, cx = count repne scasw call MemUnlock clc ; assume not locked jne exit stc ; it's locked exit: .leave ret AccessPointCheckLock endp dialingAreaCodeKey char "areaCode",0 dialingCallWaitingKey char "callWaiting",0 dialingOutsideLineKey char "outsideLine",0 dialingDialMethodKey char "dialMethod",0 dialTenDigitKey char "tenDigit",0 dialtoneKey char "dialtone",0 COMMENT @%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% AccessPointGetDialingOptions %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% SYNOPSIS: Returns dialing options from INI file. If a key is not present in the INI file, NULL or a default value will be used. CALLED BY: EXTERNAL/GLOBAL PASS: cx:dx = fptr to AccessPointDialingOptions structure to be filled RETURN: nothing DESTROYED: nothing SIDE EFFECTS: PSEUDO CODE/STRATEGY: REVISION HISTORY: Name Date Description ---- ---- ----------- JimG 9/03/99 Initial version %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%@ AccessPointGetDialingOptions proc far uses ax,bx,cx,dx,si,di,bp,ds,es .enter ; Use es:[di] to point to current member of structure. ; di will be moved from element to element at each step. ; mov es, cx mov di, dx add di, offset APDO_areaCode ; Set up ds:si to point to category key. Should stay the whole ; routine. ; segmov ds, cs, cx mov si, offset initCategory ; Read the area code key. ; mov dx, offset dialingAreaCodeKey mov {byte}es:[di], 0 ; default value mov bp, (size APDO_areaCode) and mask IFRF_SIZE call InitFileReadString jc checkCallWaiting ; unsuccessful cmp cx, APDO_AREA_CODE_LEN ; must be 3 digits! je checkCallWaiting mov {TCHAR}es:[di], 0 ; if not, null it! checkCallWaiting: ; Read the call waiting key. ; add di, offset APDO_callWaiting - offset APDO_areaCode mov cx, cs mov dx, offset dialingCallWaitingKey mov bp, (size APDO_callWaiting) and mask IFRF_SIZE mov {TCHAR}es:[di], 0 ; default value call InitFileReadString ; Read the outside line key. ; add di, offset APDO_outsideLine - offset APDO_callWaiting mov cx, cs mov dx, offset dialingOutsideLineKey mov bp, (size APDO_outsideLine) and mask IFRF_SIZE mov {TCHAR}es:[di], 0 ; default value call InitFileReadString ; Read the dialing method key. Here we read the string key ; onto the stack since the value in the struct is only a one ; byte enumeration. Happily, the value of the enum is either ; 'T' or 'P', the value stored in the ini file. ; pushdw esdi sub sp, 2*(size TCHAR) mov di, sp segmov es, ss, cx mov cx, cs mov dx, offset dialingDialMethodKey mov bp, 2 mov al, APDM_TONE ; default value call InitFileReadString jc useDefaultMethod ; not in INI file mov ah, es:[di] cmp ah, APDM_PULSE je gotMethod cmp ah, APDM_TONE jne useDefaultMethod ; if not valid, use al gotMethod: mov al, ah useDefaultMethod: add sp, 2*(size TCHAR) popdw esdi add di, offset APDO_dialMethod - offset APDO_outsideLine mov es:[di], al ; Read boolean ten digit key. ; add di, offset APDO_tenDigit - offset APDO_dialMethod mov cx, cs mov dx, offset dialTenDigitKey mov {byte}es:[di], FALSE ; default value call InitFileReadBoolean jc gotTenDigit ; no value, use def. mov es:[di], al gotTenDigit: ; Read boolean dialtone key. ; add di, offset APDO_waitForDialtone - offset APDO_tenDigit mov cx, cs mov dx, offset dialtoneKey mov {byte}es:[di], TRUE ; default value call InitFileReadBoolean jc gotDialtone ; no value, use def. mov es:[di], al gotDialtone: ; Whew! .leave ret AccessPointGetDialingOptions endp COMMENT @%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% AccessPointSetDialingOptions %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% SYNOPSIS: Sets dialing options in INI file. CALLED BY: EXTERNAL/GLOBAL PASS: cx:dx = fptr to AccessPointDialingOptions structure to be written to INI file. All string values must be null terminated. RETURN: nothing DESTROYED: nothing SIDE EFFECTS: PSEUDO CODE/STRATEGY: REVISION HISTORY: Name Date Description ---- ---- ----------- JimG 9/03/99 Initial version %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%@ AccessPointSetDialingOptions proc far uses ax,bx,cx,dx,si,di,bp,ds,es .enter ; Use es:[di] to point to current member of structure. ; di will be moved from element to element at each step. ; mov es, cx mov di, dx add di, offset APDO_areaCode ; Set up ds:si to point to category key. Should stay the whole ; routine. ; segmov ds, cs, cx mov si, offset initCategory ; Write the area code key. ; mov dx, offset dialingAreaCodeKey call InitFileWriteString ; Write the call waiting key. ; add di, offset APDO_callWaiting - offset APDO_areaCode mov cx, cs mov dx, offset dialingCallWaitingKey call InitFileWriteString ; Write the outside line key. ; add di, offset APDO_outsideLine - offset APDO_callWaiting mov cx, cs mov dx, offset dialingOutsideLineKey call InitFileWriteString ; Write the dialing method key. We just write out a string to ; the file whose value is the enumeration value. Those values should ; be printable ascii characters. To do this, we need to make a string ; on the stack so that we have a zero byte. ; add di, offset APDO_dialMethod - offset APDO_outsideLine sub sp, 2*(size TCHAR) mov bp, sp mov cl, es:[di] mov ss:[bp], cl mov {byte}ss:[bp+1], 0 DBCS < mov {word}ss:[bp+2], 0 > pushdw esdi mov di, bp segmov es, ss, cx mov cx, cs mov dx, offset dialingDialMethodKey call InitFileWriteString popdw esdi add sp, 2*(size TCHAR) ; Write ten digit boolean key. ; add di, offset APDO_tenDigit - offset APDO_dialMethod clr ax mov al, es:[di] ; ax != 0 ==> TRUE mov cx, cs mov dx, offset dialTenDigitKey call InitFileWriteBoolean ; Write dialtone boolean key. ; add di, offset APDO_waitForDialtone - offset APDO_tenDigit clr ax mov al, es:[di] ; ax != 0 ==> TRUE mov cx, cs mov dx, offset dialtoneKey call InitFileWriteBoolean ; Write these suckers to the disk. ; call InitFileCommit .leave ret AccessPointSetDialingOptions endp COMMENT @%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% AccessPointGetPhoneStringWithOptions %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% SYNOPSIS: Return the phone string (stored in APSP_PHONE) with dialing options applied for the currently set access point. Options will only be applied if (1) they are set (may be in INI file) and (2) if APSP_USE_DIALING_OPTIONS is set non-zero for access point. If APSP_USE_DIALING_OPTIONS is not present, the routine will behave normally but no options will be applied (i.e., output will be equal to APSP_PHONE string). CALLED BY: EXTERNAL/GLOBAL PASS: ax = access point id bx = handle to block to receive string or 0 to have block allocated. RETURN: carry: set if APSP_PHONE is defined clear if no PHONE is specified for access point. cx = length of phone string (excluding zero-byte) DESTROYED: nothing SIDE EFFECTS: PSEUDO CODE/STRATEGY: Oh, string parsing and concatenation in ASM is SO MUCH FUN! This was much shorter in C, really. REVISION HISTORY: Name Date Description ---- ---- ----------- JimG 9/03/99 Initial version %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%@ PREAMBLE_LEN equ 32 AccessPointGetPhoneStringWithOptions proc far uses ax,dx,si,di,ds,es accPntID local word push ax returnHan local hptr push bx origCX local word push cx phonePropHan local hptr preamble local PREAMBLE_LEN dup (TCHAR) areaCode local 3 dup (TCHAR) DBCS < areaCodeLen local byte > prefix local 3 dup (TCHAR) extension local 4 dup (TCHAR) dialOptions local AccessPointDialingOptions localDialOptions local AccessPointLocalDialingOptions .enter ; Get the phone number from the access point. (AX was passed in ; to be the access point ID.) ; push bp ; save locals clr cx, bp mov dx, APSP_PHONE call AccessPointGetStringProperty ; bx = block, cx = len pop bp ; restore locals cmc ; carry set = failure LONG jnc done ; no phone, E.T., clc mov ss:[phonePropHan], bx tst ss:[returnHan] jnz returnBlockAlloc mov ax, 112*(size TCHAR) ; big enuf! mov cx, ALLOC_DYNAMIC call MemAlloc LONG jc errorFreePropHan mov ss:[returnHan], bx returnBlockAlloc: mov bx, ss:[phonePropHan] call MemLock LONG jc errorFreePropHan ; may leak memory mov ds, ax clr si mov bx, ss:[returnHan] call MemLock LONG jc errorUnlockPropHan ; may leak memory mov es, ax clr di ; ds:si = original phone number ; es:di = return phone number ; ; At this point, check is APSP_USE_DIALING_OPTIONS is present for ; this access point. ; mov ax, ss:[accPntID] ; can trash ax,cx,dx clr cx mov dx, APSP_USE_DIALING_OPTIONS call AccessPointGetIntegerProperty jc skipOptions tst ax jnz useOptions skipOptions: ; OK.. we are bailing but we need to copy the phone number to the ; output string an proceed like a normal call. To do that, we simply ; need to advance ds:si to the end of the source string and pretend ; we have "garbage". ; LocalGetChar ax, dssi ; rep scasb uses es:di. LocalIsNull ax ; use lodsb loop instead jnz skipOptions jmp stuffIt useOptions: ; bl = numDigits ; bh = garbageInString ; cl = firstDigitIs1 ; ch = preambleLen clr bx, cx ; First time through, figure out how many actual digits we have ; and some things about it. Store a preamble, valid dial chars ; before the first digits, just in case. loop1: LocalGetChar ax, dssi LocalIsNull ax jz doneLoop1 inc bh ; assume garbage, but digit LocalCmpChar ax, '#' ; (which means # or *) je haveDigit1 LocalCmpChar ax, '*' je haveDigit1 dec bh ; unassume garbage LocalCmpChar ax, '0' jb noDigit1 LocalCmpChar ax, '9' ja noDigit1 haveDigit1: tst bl ; numDigits == 0 jnz alreadyHaveOneDigit1 LocalCmpChar ax, '1' ; first digit == 1 jne alreadyHaveOneDigit1 inc cl ; first digit is a 1.. note it alreadyHaveOneDigit1: inc bl ; inc count of digits jmp loop1 noDigit1: LocalCmpChar ax, '-' ; check for useless (,),- chars je loop1 ; they aren't garbage, fluff LocalCmpChar ax, '(' je loop1 LocalCmpChar ax, ')' je loop1 tst bl ; numDigits ==0 ? jnz garbageLoop1 ; nope - no preamble, garbage cmp ch, PREAMBLE_LEN ; preambleLen < PREAMBLE_LEN jae garbageLoop1 ; nope - garbage push bx ; stuff in preamble lea bx, ss:[preamble] add bl, ch DBCS < adc bh, 0 > DBCS < add bl, ch ; size TCHAR > adc bh, 0 LocalPutChar ssbx, ax, noAdvance pop bx inc ch ; preambleLen++ jmp loop1 ; no garbage garbageLoop1: inc bh ; yup, garbage jmp loop1 doneLoop1: ; Get the dialing options (in local variable).. we need to, no matter ; what, stuff the 'T' or 'P' in the output string. (We may bail below ; by stuffing the input string to the output string; however, we still ; would like the T or P present.) ; push cx mov cx, ss lea dx, ss:[dialOptions] ; dx unused so far call AccessPointGetDialingOptions pop cx ; Also get the local dialing options for this access point. ; push ax, cx, dx clr ss:[localDialOptions] ; by default, options are off mov ax, ss:[accPntID] ; can trash ax,cx,dx clr cx mov dx, APSP_LOCAL_DIALING_OPTIONS call AccessPointGetIntegerProperty jc skipLocalOptions mov ss:[localDialOptions], ax skipLocalOptions: pop ax, cx, dx ; Write dial method ('T' or 'P') out first. ; mov al, ss:[dialOptions].APDO_dialMethod DBCS < clr ah > LocalPutChar esdi, ax ; At this point, we can figure out if we are going to just stuff the ; string out as it came in because we have garbage or unparse-able ; stuff. tst bh ; garbageInString jnz stuffIt tst cl ; first digit is 1 ? jnz stuffItFDI1 cmp bl, 7 ; first dig not 1.. 7 or 10 digs je pressOn ; get to pass GO. cmp bl, 10 je pressOn stuffIt: mov cx, si ; cx=si = num chars in string clr si ; since ds:0 is byte 0 LocalCopyNString ; includes null terminator> jmp doneSuccess stuffItFDI1: cmp bl, 11 ; first dig is 1.. do we have jne stuffIt ; 11 digits? If not, garbage! pressOn: ; ds:si = original phone number ; es:di = return phone number ; bl = numDigits ; bh = numDigits2 (for second loop) (was garbage counter.. must be 0) ; cl = firstDigitIs1 ; ch = preambleLen ; ah = areaCodeLen ; dl = prefixLen ; dh = extLen EC < tst bh > EC < ERROR_NZ -1 > clr dx, si SBCS < clr ah > DBCS < clr ss:[areaCodeLen] > ; This time through, we parse out area code, prefix, and extension. ; Oh, this is fun in ASM! loop2: LocalGetChar ax, dssi LocalIsNull ax jz doneLoop2 LocalCmpChar ax, '0' ; isdigit? jb loop2 LocalCmpChar ax, '9' ja loop2 tst bh ; first digit this loop? jnz notFirst2 tst cl ; first digit should be 1? jz notFirst2 EC < LocalCmpChar ax, '1' > EC < ERROR_NE -1 > clr cl ; clear firstDigit and ; don't count this digit jmp loop2 notFirst2: cmp bl, 10 ; do we have 10 digits? jb tryPrefix2 SBCS < cmp ah, 2 ; are seeing the first 3 still?> DBCS < cmp ss:[areaCodeLen], 2 ; are seeing the first 3 still?> ja tryPrefix2 push bx ; yes.. write area code. lea bx, ss:[areaCode] SBCS < add bl, ah > DBCS < add bl, ss:[areaCodeLen] > DBCS < adc bh, 0 > DBCS < add bl, ss:[areaCodeLen] ; TCHAR size > adc bh, 0 LocalPutChar ssbx, ax, noAdvance pop bx SBCS < inc ah ; ++areaCodeLen > DBCS < inc ss:[areaCodeLen] ; ++areaCodeLen > incloop2: inc bh ; ++numDigits2 jmp loop2 tryPrefix2: cmp dl, 2 ; do we have 3 prefix yet? ja tryExt2 push bx ; no.. write in prefix. lea bx, ss:[prefix] add bl, dl DBCS < adc bh, 0 > DBCS < add bl, dl ; TCHAR size > adc bh, 0 LocalPutChar ssbx, ax, noAdvance pop bx inc dl ; ++prefixLen jmp incloop2 tryExt2: cmp dh, 3 ; have we filled ext yet? EC < ERROR_A -1 ; BAD BAD > NEC < ja doneLoop2 ; don't count anymore! > push bx ; no.. write in extension. lea bx, ss:[extension] add bl, dh DBCS < adc bh, 0 > DBCS < add bl, dh ; TCHAR size > adc bh, 0 LocalPutChar ssbx, ax, noAdvance pop bx inc dh ; ++extensionLen jmp incloop2 doneLoop2: if ERROR_CHECK cmp di, 1*(size TCHAR) ; di should be 1 ('T' or 'P') ERROR_NZ -1 cmp dl, 3 ; prefixLen == 3 ERROR_NE -1 cmp dh, 4 ; && extensionLen == 4 ERROR_NE -1 cmp bh, 7 ; numDigits2 == 7 je ecOK ; cool cmp bh, 10 ; numDigits == 10 ERROR_NE -1 ; MUST BE! SBCS < cmp ah, 3 ; areaCodeLen == 3 > DBCS < cmp ss:[areaCodeLen], 3 ; areaCodeLen == 3 > ERROR_NE -1 ecOK: endif ; Let's build the return value now! ; ; es:di = return phone number ; bl = <DONT CARE> ; bh = numDigits2 (for second loop) (was garbage counter.. must be 0) ; cl = <DONT CARE> ; ch = preambleLen ; ah = areaCodeLen ; dl = prefixLen ; ; All our source data comes from the stack now, daddy-o. ; segmov ds, ss ; Copy out the preamble, if any. ; tst ch ; preamble? jz noPreamble lea si, ss:[preamble] push ax clr cl xchg ch, cl LocalCopyNString pop ax ; cx = <DONT CARE> ; Check the outside line action. ; noPreamble: tst ss:[dialOptions].APDO_outsideLine jz noOutsideLine lea si, ss:[dialOptions].APDO_outsideLine clr bl ; pause counter olCopy: LocalGetChar ax, dssi ; 0-terminated LocalIsNull ax jz olCopyDone LocalPutChar esdi, ax LocalCmpChar ax, ',' jne olCopy inc bl jmp olCopy olCopyDone: ; Append pause ',' if none already. LocalLoadChar ax, ',' tst bl jnz noOutsideLine LocalPutChar esdi, ax ; Check the call waiting action. ; noOutsideLine: tst ss:[dialOptions].APDO_callWaiting jz noCallWaiting lea si, ss:[dialOptions].APDO_callWaiting clr bl ; pause counter cwCopy: LocalGetChar ax, dssi ; 0-terminated LocalIsNull ax jz cwCopyDone LocalPutChar esdi, ax LocalCmpChar ax, ',' jne cwCopy inc bl jmp cwCopy cwCopyDone: ; Append pause ',' if none already. LocalLoadChar ax, ',' tst bl jnz noCallWaiting LocalPutChar esdi, ax ; Do we stick out an area code? ; cx = offset to which area code to use noCallWaiting: clr cx ; no area code at first test ss:[localDialOptions], mask APLDO_ALWAYS_ADD_AREA_CODE jnz forced tst ss:[dialOptions].APDO_tenDigit jz notForced forced: cmp bh, 10 ; numDigits2 jne forcedNot10 useSupplied: lea cx, ss:[areaCode] jmp haveArea forcedNot10: ; Need 10 digits, don't have 10.. use default area code tst ss:[dialOptions].APDO_areaCode jz noAreaCode ; no default.. oh well lea cx, ss:[dialOptions].APDO_areaCode jmp haveArea notForced: ; Not forced to. Do we have 10 digits? If not, no need for ; an area code. cmp bh, 10 ; numDigits2 jne noAreaCode ; nope! done. tst ss:[dialOptions].APDO_areaCode ; no default to cmp? jz useSupplied ; use one supplied ; We have 10 digits and we have a default area code. We need ; to compare them to see if we have to dial it. push es,ds,si,di,cx segmov ds, ss, si mov es, si lea si, ss:[dialOptions].APDO_areaCode lea di, ss:[areaCode] mov cx, 3 SBCS < repe cmpsb > DBCS < repe cmpsw > pop es,ds,si,di,cx je noAreaCode ; EQUAL.. no area code needed jmp useSupplied ; otherwise, use supplied code haveArea: ; Area code required.. Write out a "1-<area code>-" ; If APLDO_OMIT_ONE_FOR_LONG_DISTANCE, skip the "1-". test ss:[localDialOptions], mask APLDO_OMIT_ONE_FOR_LONG_DISTANCE jnz skipOne LocalLoadChar ax, '1' LocalPutChar esdi, ax LocalLoadChar ax, '-' LocalPutChar esdi, ax skipOne: mov si, cx ; copy 3 byte area code. mov cx, 3 LocalCopyNString LocalLoadChar ax, '-' LocalPutChar esdi, ax noAreaCode: ; Finally, the rest of the damn thing. lea si, ss:[prefix] mov cx, 3 LocalCopyNString LocalLoadChar ax, '-' LocalPutChar esdi, ax lea si, ss:[extension] mov cx, 4 LocalCopyNString LocalClrChar ax LocalPutChar esdi, ax ; 0 terminate it doneSuccess: SBCS < stc ; success > mov cx, di ; return length in cx DBCS < shr cx, 1 ; size to length > dec cx ; don't count zero byte DBCS < stc ; success > mov bx, ss:[returnHan] call MemUnlock ; flags preserved unlockPropHan: mov bx, ss:[phonePropHan] call MemUnlock ; flags preserved freePropHan: mov bx, ss:[phonePropHan] ; may jump here pushf call MemFree popf ; Return the return handle in BX. If there was a failure, this should ; still be 0 if the handle was to be allocated. ; mov bx, ss:[returnHan] done: ; If unsuccessful, restore CX to passed CX. jc reallyDone mov cx, ss:[origCX] reallyDone: .leave ret errorUnlockPropHan: clc jmp unlockPropHan errorFreePropHan: clc jmp freePropHan AccessPointGetPhoneStringWithOptions endp ApiCode ends
src/vwf.asm
ISSOtm/gb-open-world
8
12342
INCLUDE "hardware.inc/hardware.inc" SKIP_HELD_KEYS equ PADF_B SKIP_PRESSED_KEYS equ PADF_A NB_CHARSETS equ 1 CHARSET_0 equs "res/optix.vwf" lb: MACRO assert -128 <= (\2) && (\2) <= 255, "Second argument to `lb` must be 8-bit!" assert -128 <= (\3) && (\3) <= 255, "Third argument to `lb` must be 8-bit!" ld \1, ((\2) << 8) | (\3) ENDM INCLUDE "gb-vwf/vwf.asm"
gcc-gcc-7_3_0-release/gcc/testsuite/gnat.dg/vect16.ads
best08618/asylo
7
29857
package Vect16 is type Sarray is array (1 .. 4) of Long_Float; for Sarray'Alignment use 16; procedure Add_Sub (X, Y : Sarray; R,S : out Sarray); end Vect16;
0x06.asm
0xdea/xorpd-solutions
53
8498
<filename>0x06.asm ; ; $Id: 0x06.asm,v 1.1.1.1 2016/03/27 08:40:12 raptor Exp $ ; ; 0x06 explanation - from xchg rax,rax by <EMAIL> ; Copyright (c) 2016 <NAME> <<EMAIL>> ; ; This snippet sets rax with its initial value, by doing ; the following operations: ; ; 1. bitwise not of rax (one's complement negation) ; 2. rax = rax + 1 ; 3. bitwise not of rax + 1 (two's complement negation) ; ; It is structurally equivalent to this (inverted) snippet: ; ; neg rax ; dec rax ; not rax ; ; This analysis was facilitated by the assembly REPL rappel ; by <EMAIL>: ; ; https://github.com/yrp604/rappel/ ; BITS 64 SECTION .text global main main: not rax ; one's complement negation (bitwise not) inc rax ; rax = rax + 1 neg rax ; two's complement negation (bitwise not + 1)
src/gnat/sinput.adb
My-Colaborations/dynamo
15
19895
<reponame>My-Colaborations/dynamo<filename>src/gnat/sinput.adb<gh_stars>10-100 ------------------------------------------------------------------------------ -- -- -- GNAT COMPILER COMPONENTS -- -- -- -- S I N P U T -- -- -- -- B o d y -- -- -- -- Copyright (C) 1992-2014, Free Software Foundation, Inc. -- -- -- -- GNAT is free software; you can redistribute it and/or modify it under -- -- terms of the GNU General Public License as published by the Free Soft- -- -- ware Foundation; either version 3, or (at your option) any later ver- -- -- sion. GNAT is distributed in the hope that it will be useful, but WITH- -- -- OUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY -- -- or FITNESS FOR A PARTICULAR PURPOSE. -- -- -- -- As a special exception under Section 7 of GPL version 3, you are granted -- -- additional permissions described in the GCC Runtime Library Exception, -- -- version 3.1, as published by the Free Software Foundation. -- -- -- -- You should have received a copy of the GNU General Public License and -- -- a copy of the GCC Runtime Library Exception along with this program; -- -- see the files COPYING3 and COPYING.RUNTIME respectively. If not, see -- -- <http://www.gnu.org/licenses/>. -- -- -- -- GNAT was originally developed by the GNAT team at New York University. -- -- Extensive contributions were provided by Ada Core Technologies Inc. -- -- -- ------------------------------------------------------------------------------ pragma Style_Checks (All_Checks); -- Subprograms not all in alpha order with Atree; use Atree; with Debug; use Debug; with Opt; use Opt; with Output; use Output; with Scans; use Scans; with Tree_IO; use Tree_IO; with Widechar; use Widechar; with GNAT.Byte_Order_Mark; use GNAT.Byte_Order_Mark; with System; use System; with System.Memory; with System.WCh_Con; use System.WCh_Con; with Unchecked_Conversion; with Unchecked_Deallocation; package body Sinput is use ASCII; -- Make control characters visible First_Time_Around : Boolean := True; -- This needs a comment ??? -- Routines to support conversion between types Lines_Table_Ptr, -- Logical_Lines_Table_Ptr and System.Address. pragma Warnings (Off); -- These unchecked conversions are aliasing safe, since they are never -- used to construct improperly aliased pointer values. function To_Address is new Unchecked_Conversion (Lines_Table_Ptr, Address); function To_Address is new Unchecked_Conversion (Logical_Lines_Table_Ptr, Address); function To_Pointer is new Unchecked_Conversion (Address, Lines_Table_Ptr); function To_Pointer is new Unchecked_Conversion (Address, Logical_Lines_Table_Ptr); pragma Warnings (On); --------------------------- -- Add_Line_Tables_Entry -- --------------------------- procedure Add_Line_Tables_Entry (S : in out Source_File_Record; P : Source_Ptr) is LL : Physical_Line_Number; begin -- Reallocate the lines tables if necessary -- Note: the reason we do not use the normal Table package -- mechanism is that we have several of these tables. We could -- use the new GNAT.Dynamic_Tables package and that would probably -- be a good idea ??? if S.Last_Source_Line = S.Lines_Table_Max then Alloc_Line_Tables (S, Int (S.Last_Source_Line) * ((100 + Alloc.Lines_Increment) / 100)); if Debug_Flag_D then Write_Str ("--> Reallocating lines table, size = "); Write_Int (Int (S.Lines_Table_Max)); Write_Eol; end if; end if; S.Last_Source_Line := S.Last_Source_Line + 1; LL := S.Last_Source_Line; S.Lines_Table (LL) := P; -- Deal with setting new entry in logical lines table if one is -- present. Note that there is always space (because the call to -- Alloc_Line_Tables makes sure both tables are the same length), if S.Logical_Lines_Table /= null then -- We can always set the entry from the previous one, because -- the processing for a Source_Reference pragma ensures that -- at least one entry following the pragma is set up correctly. S.Logical_Lines_Table (LL) := S.Logical_Lines_Table (LL - 1) + 1; end if; end Add_Line_Tables_Entry; ----------------------- -- Alloc_Line_Tables -- ----------------------- procedure Alloc_Line_Tables (S : in out Source_File_Record; New_Max : Nat) is subtype size_t is Memory.size_t; New_Table : Lines_Table_Ptr; New_Logical_Table : Logical_Lines_Table_Ptr; New_Size : constant size_t := size_t (New_Max * Lines_Table_Type'Component_Size / Storage_Unit); begin if S.Lines_Table = null then New_Table := To_Pointer (Memory.Alloc (New_Size)); else New_Table := To_Pointer (Memory.Realloc (To_Address (S.Lines_Table), New_Size)); end if; if New_Table = null then raise Storage_Error; else S.Lines_Table := New_Table; S.Lines_Table_Max := Physical_Line_Number (New_Max); end if; if S.Num_SRef_Pragmas /= 0 then if S.Logical_Lines_Table = null then New_Logical_Table := To_Pointer (Memory.Alloc (New_Size)); else New_Logical_Table := To_Pointer (Memory.Realloc (To_Address (S.Logical_Lines_Table), New_Size)); end if; if New_Logical_Table = null then raise Storage_Error; else S.Logical_Lines_Table := New_Logical_Table; end if; end if; end Alloc_Line_Tables; ----------------- -- Backup_Line -- ----------------- procedure Backup_Line (P : in out Source_Ptr) is Sindex : constant Source_File_Index := Get_Source_File_Index (P); Src : constant Source_Buffer_Ptr := Source_File.Table (Sindex).Source_Text; Sfirst : constant Source_Ptr := Source_File.Table (Sindex).Source_First; begin P := P - 1; if P = Sfirst then return; end if; if Src (P) = CR then if Src (P - 1) = LF then P := P - 1; end if; else -- Src (P) = LF if Src (P - 1) = CR then P := P - 1; end if; end if; -- Now find first character of the previous line while P > Sfirst and then Src (P - 1) /= LF and then Src (P - 1) /= CR loop P := P - 1; end loop; end Backup_Line; --------------------------- -- Build_Location_String -- --------------------------- procedure Build_Location_String (Loc : Source_Ptr) is Ptr : Source_Ptr; begin -- Loop through instantiations Ptr := Loc; loop Get_Name_String_And_Append (Reference_Name (Get_Source_File_Index (Ptr))); Add_Char_To_Name_Buffer (':'); Add_Nat_To_Name_Buffer (Nat (Get_Logical_Line_Number (Ptr))); Ptr := Instantiation_Location (Ptr); exit when Ptr = No_Location; Add_Str_To_Name_Buffer (" instantiated at "); end loop; Name_Buffer (Name_Len + 1) := NUL; return; end Build_Location_String; function Build_Location_String (Loc : Source_Ptr) return String is begin Name_Len := 0; Build_Location_String (Loc); return Name_Buffer (1 .. Name_Len); end Build_Location_String; ------------------- -- Check_For_BOM -- ------------------- procedure Check_For_BOM is BOM : BOM_Kind; Len : Natural; Tst : String (1 .. 5); C : Character; begin for J in 1 .. 5 loop C := Source (Scan_Ptr + Source_Ptr (J) - 1); -- Definitely no BOM if EOF character marks either end of file, or -- an illegal non-BOM character if not at the end of file. if C = EOF then return; end if; Tst (J) := C; end loop; Read_BOM (Tst, Len, BOM, False); case BOM is when UTF8_All => Scan_Ptr := Scan_Ptr + Source_Ptr (Len); Wide_Character_Encoding_Method := WCEM_UTF8; Upper_Half_Encoding := True; when UTF16_LE | UTF16_BE => Set_Standard_Error; Write_Line ("UTF-16 encoding format not recognized"); Set_Standard_Output; raise Unrecoverable_Error; when UTF32_LE | UTF32_BE => Set_Standard_Error; Write_Line ("UTF-32 encoding format not recognized"); Set_Standard_Output; raise Unrecoverable_Error; when Unknown => null; when others => raise Program_Error; end case; end Check_For_BOM; ----------------------------- -- Comes_From_Inlined_Body -- ----------------------------- function Comes_From_Inlined_Body (S : Source_Ptr) return Boolean is SIE : Source_File_Record renames Source_File.Table (Get_Source_File_Index (S)); begin return SIE.Inlined_Body; end Comes_From_Inlined_Body; ----------------------- -- Get_Column_Number -- ----------------------- function Get_Column_Number (P : Source_Ptr) return Column_Number is S : Source_Ptr; C : Column_Number; Sindex : Source_File_Index; Src : Source_Buffer_Ptr; begin -- If the input source pointer is not a meaningful value then return -- at once with column number 1. This can happen for a file not found -- condition for a file loaded indirectly by RTE, and also perhaps on -- some unknown internal error conditions. In either case we certainly -- don't want to blow up. if P < 1 then return 1; else Sindex := Get_Source_File_Index (P); Src := Source_File.Table (Sindex).Source_Text; S := Line_Start (P); C := 1; while S < P loop if Src (S) = HT then C := (C - 1) / 8 * 8 + (8 + 1); S := S + 1; -- Deal with wide character case, but don't include brackets -- notation in this circuit, since we know that this will -- display unencoded (no one encodes brackets notation). elsif Src (S) /= '[' and then Is_Start_Of_Wide_Char (Src, S) then C := C + 1; Skip_Wide (Src, S); -- Normal (non-wide) character case or brackets sequence else C := C + 1; S := S + 1; end if; end loop; return C; end if; end Get_Column_Number; ----------------------------- -- Get_Logical_Line_Number -- ----------------------------- function Get_Logical_Line_Number (P : Source_Ptr) return Logical_Line_Number is SFR : Source_File_Record renames Source_File.Table (Get_Source_File_Index (P)); L : constant Physical_Line_Number := Get_Physical_Line_Number (P); begin if SFR.Num_SRef_Pragmas = 0 then return Logical_Line_Number (L); else return SFR.Logical_Lines_Table (L); end if; end Get_Logical_Line_Number; --------------------------------- -- Get_Logical_Line_Number_Img -- --------------------------------- function Get_Logical_Line_Number_Img (P : Source_Ptr) return String is begin Name_Len := 0; Add_Nat_To_Name_Buffer (Nat (Get_Logical_Line_Number (P))); return Name_Buffer (1 .. Name_Len); end Get_Logical_Line_Number_Img; ------------------------------ -- Get_Physical_Line_Number -- ------------------------------ function Get_Physical_Line_Number (P : Source_Ptr) return Physical_Line_Number is Sfile : Source_File_Index; Table : Lines_Table_Ptr; Lo : Physical_Line_Number; Hi : Physical_Line_Number; Mid : Physical_Line_Number; Loc : Source_Ptr; begin -- If the input source pointer is not a meaningful value then return -- at once with line number 1. This can happen for a file not found -- condition for a file loaded indirectly by RTE, and also perhaps on -- some unknown internal error conditions. In either case we certainly -- don't want to blow up. if P < 1 then return 1; -- Otherwise we can do the binary search else Sfile := Get_Source_File_Index (P); Loc := P + Source_File.Table (Sfile).Sloc_Adjust; Table := Source_File.Table (Sfile).Lines_Table; Lo := 1; Hi := Source_File.Table (Sfile).Last_Source_Line; loop Mid := (Lo + Hi) / 2; if Loc < Table (Mid) then Hi := Mid - 1; else -- Loc >= Table (Mid) if Mid = Hi or else Loc < Table (Mid + 1) then return Mid; else Lo := Mid + 1; end if; end if; end loop; end if; end Get_Physical_Line_Number; --------------------------- -- Get_Source_File_Index -- --------------------------- function Get_Source_File_Index (S : Source_Ptr) return Source_File_Index is begin return Source_File_Index_Table (Int (S) / Source_Align); end Get_Source_File_Index; ---------------- -- Initialize -- ---------------- procedure Initialize is begin Source_gnat_adc := No_Source_File; First_Time_Around := True; Source_File.Init; Instances.Init; Instances.Append (No_Location); pragma Assert (Instances.Last = No_Instance_Id); end Initialize; ------------------- -- Instantiation -- ------------------- function Instantiation (S : SFI) return Source_Ptr is SIE : Source_File_Record renames Source_File.Table (S); begin if SIE.Inlined_Body then return SIE.Inlined_Call; else return Instances.Table (SIE.Instance); end if; end Instantiation; ------------------------- -- Instantiation_Depth -- ------------------------- function Instantiation_Depth (S : Source_Ptr) return Nat is Sind : Source_File_Index; Sval : Source_Ptr; Depth : Nat; begin Sval := S; Depth := 0; loop Sind := Get_Source_File_Index (Sval); Sval := Instantiation (Sind); exit when Sval = No_Location; Depth := Depth + 1; end loop; return Depth; end Instantiation_Depth; ---------------------------- -- Instantiation_Location -- ---------------------------- function Instantiation_Location (S : Source_Ptr) return Source_Ptr is begin return Instantiation (Get_Source_File_Index (S)); end Instantiation_Location; -------------------------- -- Iterate_On_Instances -- -------------------------- procedure Iterate_On_Instances is begin for J in 1 .. Instances.Last loop Process (J, Instances.Table (J)); end loop; end Iterate_On_Instances; ---------------------- -- Last_Source_File -- ---------------------- function Last_Source_File return Source_File_Index is begin return Source_File.Last; end Last_Source_File; ---------------- -- Line_Start -- ---------------- function Line_Start (P : Source_Ptr) return Source_Ptr is Sindex : constant Source_File_Index := Get_Source_File_Index (P); Src : constant Source_Buffer_Ptr := Source_File.Table (Sindex).Source_Text; Sfirst : constant Source_Ptr := Source_File.Table (Sindex).Source_First; S : Source_Ptr; begin S := P; while S > Sfirst and then Src (S - 1) /= CR and then Src (S - 1) /= LF loop S := S - 1; end loop; return S; end Line_Start; function Line_Start (L : Physical_Line_Number; S : Source_File_Index) return Source_Ptr is begin return Source_File.Table (S).Lines_Table (L); end Line_Start; ---------- -- Lock -- ---------- procedure Lock is begin Source_File.Locked := True; Source_File.Release; end Lock; ---------------------- -- Num_Source_Files -- ---------------------- function Num_Source_Files return Nat is begin return Int (Source_File.Last) - Int (Source_File.First) + 1; end Num_Source_Files; ---------------------- -- Num_Source_Lines -- ---------------------- function Num_Source_Lines (S : Source_File_Index) return Nat is begin return Nat (Source_File.Table (S).Last_Source_Line); end Num_Source_Lines; ----------------------- -- Original_Location -- ----------------------- function Original_Location (S : Source_Ptr) return Source_Ptr is Sindex : Source_File_Index; Tindex : Source_File_Index; begin if S <= No_Location then return S; else Sindex := Get_Source_File_Index (S); if Instantiation (Sindex) = No_Location then return S; else Tindex := Template (Sindex); while Instantiation (Tindex) /= No_Location loop Tindex := Template (Tindex); end loop; return S - Source_First (Sindex) + Source_First (Tindex); end if; end if; end Original_Location; ------------------------- -- Physical_To_Logical -- ------------------------- function Physical_To_Logical (Line : Physical_Line_Number; S : Source_File_Index) return Logical_Line_Number is SFR : Source_File_Record renames Source_File.Table (S); begin if SFR.Num_SRef_Pragmas = 0 then return Logical_Line_Number (Line); else return SFR.Logical_Lines_Table (Line); end if; end Physical_To_Logical; -------------------------------- -- Register_Source_Ref_Pragma -- -------------------------------- procedure Register_Source_Ref_Pragma (File_Name : File_Name_Type; Stripped_File_Name : File_Name_Type; Mapped_Line : Nat; Line_After_Pragma : Physical_Line_Number) is subtype size_t is Memory.size_t; SFR : Source_File_Record renames Source_File.Table (Current_Source_File); ML : Logical_Line_Number; begin if File_Name /= No_File then SFR.Reference_Name := Stripped_File_Name; SFR.Full_Ref_Name := File_Name; if not Debug_Generated_Code then SFR.Debug_Source_Name := Stripped_File_Name; SFR.Full_Debug_Name := File_Name; end if; SFR.Num_SRef_Pragmas := SFR.Num_SRef_Pragmas + 1; end if; if SFR.Num_SRef_Pragmas = 1 then SFR.First_Mapped_Line := Logical_Line_Number (Mapped_Line); end if; if SFR.Logical_Lines_Table = null then SFR.Logical_Lines_Table := To_Pointer (Memory.Alloc (size_t (SFR.Lines_Table_Max * Logical_Lines_Table_Type'Component_Size / Storage_Unit))); end if; SFR.Logical_Lines_Table (Line_After_Pragma - 1) := No_Line_Number; ML := Logical_Line_Number (Mapped_Line); for J in Line_After_Pragma .. SFR.Last_Source_Line loop SFR.Logical_Lines_Table (J) := ML; ML := ML + 1; end loop; end Register_Source_Ref_Pragma; --------------------------------- -- Set_Source_File_Index_Table -- --------------------------------- procedure Set_Source_File_Index_Table (Xnew : Source_File_Index) is Ind : Int; SP : Source_Ptr; SL : constant Source_Ptr := Source_File.Table (Xnew).Source_Last; begin SP := Source_File.Table (Xnew).Source_First; pragma Assert (SP mod Source_Align = 0); Ind := Int (SP) / Source_Align; while SP <= SL loop Source_File_Index_Table (Ind) := Xnew; SP := SP + Source_Align; Ind := Ind + 1; end loop; end Set_Source_File_Index_Table; --------------------------- -- Skip_Line_Terminators -- --------------------------- procedure Skip_Line_Terminators (P : in out Source_Ptr; Physical : out Boolean) is Chr : constant Character := Source (P); begin if Chr = CR then if Source (P + 1) = LF then P := P + 2; else P := P + 1; end if; elsif Chr = LF then P := P + 1; elsif Chr = FF or else Chr = VT then P := P + 1; Physical := False; return; -- Otherwise we have a wide character else Skip_Wide (Source, P); end if; -- Fall through in the physical line terminator case. First deal with -- making a possible entry into the lines table if one is needed. -- Note: we are dealing with a real source file here, this cannot be -- the instantiation case, so we need not worry about Sloc adjustment. declare S : Source_File_Record renames Source_File.Table (Current_Source_File); begin Physical := True; -- Make entry in lines table if not already made (in some scan backup -- cases, we will be rescanning previously scanned source, so the -- entry may have already been made on the previous forward scan). if Source (P) /= EOF and then P > S.Lines_Table (S.Last_Source_Line) then Add_Line_Tables_Entry (S, P); end if; end; end Skip_Line_Terminators; ---------------- -- Sloc_Range -- ---------------- procedure Sloc_Range (N : Node_Id; Min, Max : out Source_Ptr) is function Process (N : Node_Id) return Traverse_Result; -- Process function for traversing the node tree procedure Traverse is new Traverse_Proc (Process); ------------- -- Process -- ------------- function Process (N : Node_Id) return Traverse_Result is Orig : constant Node_Id := Original_Node (N); begin if Sloc (Orig) < Min then if Sloc (Orig) > No_Location then Min := Sloc (Orig); end if; elsif Sloc (Orig) > Max then if Sloc (Orig) > No_Location then Max := Sloc (Orig); end if; end if; return OK_Orig; end Process; -- Start of processing for Sloc_Range begin Min := Sloc (N); Max := Sloc (N); Traverse (N); end Sloc_Range; ------------------- -- Source_Offset -- ------------------- function Source_Offset (S : Source_Ptr) return Nat is Sindex : constant Source_File_Index := Get_Source_File_Index (S); Sfirst : constant Source_Ptr := Source_File.Table (Sindex).Source_First; begin return Nat (S - Sfirst); end Source_Offset; ------------------------ -- Top_Level_Location -- ------------------------ function Top_Level_Location (S : Source_Ptr) return Source_Ptr is Oldloc : Source_Ptr; Newloc : Source_Ptr; begin Newloc := S; loop Oldloc := Newloc; Newloc := Instantiation_Location (Oldloc); exit when Newloc = No_Location; end loop; return Oldloc; end Top_Level_Location; --------------- -- Tree_Read -- --------------- procedure Tree_Read is begin -- First we must free any old source buffer pointers if not First_Time_Around then for J in Source_File.First .. Source_File.Last loop declare S : Source_File_Record renames Source_File.Table (J); procedure Free_Ptr is new Unchecked_Deallocation (Big_Source_Buffer, Source_Buffer_Ptr); pragma Warnings (Off); -- This unchecked conversion is aliasing safe, since it is not -- used to create improperly aliased pointer values. function To_Source_Buffer_Ptr is new Unchecked_Conversion (Address, Source_Buffer_Ptr); pragma Warnings (On); Tmp1 : Source_Buffer_Ptr; begin if S.Instance /= No_Instance_Id then null; else -- Free the buffer, we use Free here, because we used malloc -- or realloc directly to allocate the tables. That is -- because we were playing the big array trick. -- We have to recreate a proper pointer to the actual array -- from the zero origin pointer stored in the source table. Tmp1 := To_Source_Buffer_Ptr (S.Source_Text (S.Source_First)'Address); Free_Ptr (Tmp1); if S.Lines_Table /= null then Memory.Free (To_Address (S.Lines_Table)); S.Lines_Table := null; end if; if S.Logical_Lines_Table /= null then Memory.Free (To_Address (S.Logical_Lines_Table)); S.Logical_Lines_Table := null; end if; end if; end; end loop; end if; -- Read in source file table and instance table Source_File.Tree_Read; Instances.Tree_Read; -- The pointers we read in there for the source buffer and lines table -- pointers are junk. We now read in the actual data that is referenced -- by these two fields. for J in Source_File.First .. Source_File.Last loop declare S : Source_File_Record renames Source_File.Table (J); begin -- For the instantiation case, we do not read in any data. Instead -- we share the data for the generic template entry. Since the -- template always occurs first, we can safely refer to its data. if S.Instance /= No_Instance_Id then declare ST : Source_File_Record renames Source_File.Table (S.Template); begin -- The lines tables are copied from the template entry S.Lines_Table := Source_File.Table (S.Template).Lines_Table; S.Logical_Lines_Table := Source_File.Table (S.Template).Logical_Lines_Table; -- In the case of the source table pointer, we share the -- same data as the generic template, but the virtual origin -- is adjusted. For example, if the first subscript of the -- template is 100, and that of the instantiation is 200, -- then the instantiation pointer is obtained by subtracting -- 100 from the template pointer. declare pragma Suppress (All_Checks); pragma Warnings (Off); -- This unchecked conversion is aliasing safe since it -- not used to create improperly aliased pointer values. function To_Source_Buffer_Ptr is new Unchecked_Conversion (Address, Source_Buffer_Ptr); pragma Warnings (On); begin S.Source_Text := To_Source_Buffer_Ptr (ST.Source_Text (ST.Source_First - S.Source_First)'Address); end; end; -- Normal case (non-instantiation) else First_Time_Around := False; S.Lines_Table := null; S.Logical_Lines_Table := null; Alloc_Line_Tables (S, Int (S.Last_Source_Line)); for J in 1 .. S.Last_Source_Line loop Tree_Read_Int (Int (S.Lines_Table (J))); end loop; if S.Num_SRef_Pragmas /= 0 then for J in 1 .. S.Last_Source_Line loop Tree_Read_Int (Int (S.Logical_Lines_Table (J))); end loop; end if; -- Allocate source buffer and read in the data and then set the -- virtual origin to point to the logical zero'th element. This -- address must be computed with subscript checks turned off. declare subtype B is Text_Buffer (S.Source_First .. S.Source_Last); type Text_Buffer_Ptr is access B; T : Text_Buffer_Ptr; pragma Suppress (All_Checks); pragma Warnings (Off); -- This unchecked conversion is aliasing safe, since it is -- never used to create improperly aliased pointer values. function To_Source_Buffer_Ptr is new Unchecked_Conversion (Address, Source_Buffer_Ptr); pragma Warnings (On); begin T := new B; Tree_Read_Data (T (S.Source_First)'Address, Int (S.Source_Last) - Int (S.Source_First) + 1); S.Source_Text := To_Source_Buffer_Ptr (T (0)'Address); end; end if; end; Set_Source_File_Index_Table (J); end loop; end Tree_Read; ---------------- -- Tree_Write -- ---------------- procedure Tree_Write is begin Source_File.Tree_Write; Instances.Tree_Write; -- The pointers we wrote out there for the source buffer and lines -- table pointers are junk, we now write out the actual data that -- is referenced by these two fields. for J in Source_File.First .. Source_File.Last loop declare S : Source_File_Record renames Source_File.Table (J); begin -- For instantiations, there is nothing to do, since the data is -- shared with the generic template. When the tree is read, the -- pointers must be set, but no extra data needs to be written. if S.Instance /= No_Instance_Id then null; -- For the normal case, write out the data of the tables else -- Lines table for J in 1 .. S.Last_Source_Line loop Tree_Write_Int (Int (S.Lines_Table (J))); end loop; -- Logical lines table if present if S.Num_SRef_Pragmas /= 0 then for J in 1 .. S.Last_Source_Line loop Tree_Write_Int (Int (S.Logical_Lines_Table (J))); end loop; end if; -- Source buffer Tree_Write_Data (S.Source_Text (S.Source_First)'Address, Int (S.Source_Last) - Int (S.Source_First) + 1); end if; end; end loop; end Tree_Write; -------------------- -- Write_Location -- -------------------- procedure Write_Location (P : Source_Ptr) is begin if P = No_Location then Write_Str ("<no location>"); elsif P <= Standard_Location then Write_Str ("<standard location>"); else declare SI : constant Source_File_Index := Get_Source_File_Index (P); begin Write_Name (Debug_Source_Name (SI)); Write_Char (':'); Write_Int (Int (Get_Logical_Line_Number (P))); Write_Char (':'); Write_Int (Int (Get_Column_Number (P))); if Instantiation (SI) /= No_Location then Write_Str (" ["); Write_Location (Instantiation (SI)); Write_Char (']'); end if; end; end if; end Write_Location; ---------------------- -- Write_Time_Stamp -- ---------------------- procedure Write_Time_Stamp (S : Source_File_Index) is T : constant Time_Stamp_Type := Time_Stamp (S); P : Natural; begin if T (1) = '9' then Write_Str ("19"); P := 0; else Write_Char (T (1)); Write_Char (T (2)); P := 2; end if; Write_Char (T (P + 1)); Write_Char (T (P + 2)); Write_Char ('-'); Write_Char (T (P + 3)); Write_Char (T (P + 4)); Write_Char ('-'); Write_Char (T (P + 5)); Write_Char (T (P + 6)); Write_Char (' '); Write_Char (T (P + 7)); Write_Char (T (P + 8)); Write_Char (':'); Write_Char (T (P + 9)); Write_Char (T (P + 10)); Write_Char (':'); Write_Char (T (P + 11)); Write_Char (T (P + 12)); end Write_Time_Stamp; ---------------------------------------------- -- Access Subprograms for Source File Table -- ---------------------------------------------- function Debug_Source_Name (S : SFI) return File_Name_Type is begin return Source_File.Table (S).Debug_Source_Name; end Debug_Source_Name; function Instance (S : SFI) return Instance_Id is begin return Source_File.Table (S).Instance; end Instance; function File_Name (S : SFI) return File_Name_Type is begin return Source_File.Table (S).File_Name; end File_Name; function File_Type (S : SFI) return Type_Of_File is begin return Source_File.Table (S).File_Type; end File_Type; function First_Mapped_Line (S : SFI) return Logical_Line_Number is begin return Source_File.Table (S).First_Mapped_Line; end First_Mapped_Line; function Full_Debug_Name (S : SFI) return File_Name_Type is begin return Source_File.Table (S).Full_Debug_Name; end Full_Debug_Name; function Full_File_Name (S : SFI) return File_Name_Type is begin return Source_File.Table (S).Full_File_Name; end Full_File_Name; function Full_Ref_Name (S : SFI) return File_Name_Type is begin return Source_File.Table (S).Full_Ref_Name; end Full_Ref_Name; function Identifier_Casing (S : SFI) return Casing_Type is begin return Source_File.Table (S).Identifier_Casing; end Identifier_Casing; function Inlined_Body (S : SFI) return Boolean is begin return Source_File.Table (S).Inlined_Body; end Inlined_Body; function Inlined_Call (S : SFI) return Source_Ptr is begin return Source_File.Table (S).Inlined_Call; end Inlined_Call; function Keyword_Casing (S : SFI) return Casing_Type is begin return Source_File.Table (S).Keyword_Casing; end Keyword_Casing; function Last_Source_Line (S : SFI) return Physical_Line_Number is begin return Source_File.Table (S).Last_Source_Line; end Last_Source_Line; function License (S : SFI) return License_Type is begin return Source_File.Table (S).License; end License; function Num_SRef_Pragmas (S : SFI) return Nat is begin return Source_File.Table (S).Num_SRef_Pragmas; end Num_SRef_Pragmas; function Reference_Name (S : SFI) return File_Name_Type is begin return Source_File.Table (S).Reference_Name; end Reference_Name; function Source_Checksum (S : SFI) return Word is begin return Source_File.Table (S).Source_Checksum; end Source_Checksum; function Source_First (S : SFI) return Source_Ptr is begin if S = Internal_Source_File then return Internal_Source'First; else return Source_File.Table (S).Source_First; end if; end Source_First; function Source_Last (S : SFI) return Source_Ptr is begin if S = Internal_Source_File then return Internal_Source'Last; else return Source_File.Table (S).Source_Last; end if; end Source_Last; function Source_Text (S : SFI) return Source_Buffer_Ptr is begin if S = Internal_Source_File then return Internal_Source_Ptr; else return Source_File.Table (S).Source_Text; end if; end Source_Text; function Template (S : SFI) return SFI is begin return Source_File.Table (S).Template; end Template; function Time_Stamp (S : SFI) return Time_Stamp_Type is begin return Source_File.Table (S).Time_Stamp; end Time_Stamp; function Unit (S : SFI) return Unit_Number_Type is begin return Source_File.Table (S).Unit; end Unit; ------------------------------------------ -- Set Procedures for Source File Table -- ------------------------------------------ procedure Set_Identifier_Casing (S : SFI; C : Casing_Type) is begin Source_File.Table (S).Identifier_Casing := C; end Set_Identifier_Casing; procedure Set_Keyword_Casing (S : SFI; C : Casing_Type) is begin Source_File.Table (S).Keyword_Casing := C; end Set_Keyword_Casing; procedure Set_License (S : SFI; L : License_Type) is begin Source_File.Table (S).License := L; end Set_License; procedure Set_Unit (S : SFI; U : Unit_Number_Type) is begin Source_File.Table (S).Unit := U; end Set_Unit; ---------------------- -- Trim_Lines_Table -- ---------------------- procedure Trim_Lines_Table (S : Source_File_Index) is Max : constant Nat := Nat (Source_File.Table (S).Last_Source_Line); begin -- Release allocated storage that is no longer needed Source_File.Table (S).Lines_Table := To_Pointer (Memory.Realloc (To_Address (Source_File.Table (S).Lines_Table), Memory.size_t (Max * (Lines_Table_Type'Component_Size / System.Storage_Unit)))); Source_File.Table (S).Lines_Table_Max := Physical_Line_Number (Max); end Trim_Lines_Table; ------------ -- Unlock -- ------------ procedure Unlock is begin Source_File.Locked := False; Source_File.Release; end Unlock; -------- -- wl -- -------- procedure wl (P : Source_Ptr) is begin Write_Location (P); Write_Eol; end wl; end Sinput;
alloy4fun_models/trashltl/models/11/99e8Hb3LPu9oeLocq.als
Kaixi26/org.alloytools.alloy
0
3751
<gh_stars>0 open main pred id99e8Hb3LPu9oeLocq_prop12 { all f: File | eventually f in Trash and after always f in Trash } pred __repair { id99e8Hb3LPu9oeLocq_prop12 } check __repair { id99e8Hb3LPu9oeLocq_prop12 <=> prop12o }
ASMFiles/printChar.asm
Undeadtaker/Assembly
0
177624
.model small .data .code mov ah, 1h ; 01h DOS interrupt for READ CHARACTER FROM STANDARD INPUT, WITH ECHO, character stored in al not ah! ah is for read only! int 21h ; execute the 21h interrupt mov dl, al ; move the character from al to dl mov ah, 2h ; 02h DOS interrupt for WRITE CHARACTER TO STANDARD OUTPUT, goes to dl register for the character, that's why we moved ; the content from al to dl int 21h ; exectue the 21h interrupt end ; end
Transynther/x86/_processed/NONE/_st_/i9-9900K_12_0xa0_notsx.log_21829_801.asm
ljhsiun2/medusa
9
175167
<reponame>ljhsiun2/medusa .global s_prepare_buffers s_prepare_buffers: push %r10 push %r15 push %r8 push %rax push %rbx push %rcx push %rdi push %rdx push %rsi lea addresses_A_ht+0x12d26, %rax nop nop dec %r8 movl $0x61626364, (%rax) nop nop nop and $28988, %rbx lea addresses_normal_ht+0x1e87c, %rsi clflush (%rsi) nop nop nop nop sub %r15, %r15 mov (%rsi), %edx nop nop xor %r8, %r8 lea addresses_WC_ht+0x6eee, %rdx nop nop cmp $29322, %rsi movb $0x61, (%rdx) sub $12075, %r8 lea addresses_D_ht+0x5e6e, %r10 nop nop nop nop nop add $49615, %rdx movups (%r10), %xmm6 vpextrq $0, %xmm6, %rsi nop nop nop nop nop inc %rbx lea addresses_A_ht+0x1a00e, %rsi clflush (%rsi) nop nop nop nop and $54244, %r15 movl $0x61626364, (%rsi) nop nop sub $56694, %rbx lea addresses_normal_ht+0x16c76, %rsi lea addresses_A_ht+0x1a20e, %rdi clflush (%rsi) nop and %r15, %r15 mov $112, %rcx rep movsl nop add $17751, %r8 lea addresses_WT_ht+0xc850, %rsi lea addresses_normal_ht+0x5c0e, %rdi and $24728, %rdx mov $67, %rcx rep movsq nop add %r15, %r15 lea addresses_A_ht+0x12a0e, %rsi lea addresses_D_ht+0x1244e, %rdi nop nop nop nop cmp $48602, %r10 mov $20, %rcx rep movsw nop nop nop nop add %r10, %r10 lea addresses_WC_ht+0x12d3a, %rdi nop nop nop add $1709, %r8 movups (%rdi), %xmm4 vpextrq $1, %xmm4, %rax nop inc %rbx pop %rsi pop %rdx pop %rdi pop %rcx pop %rbx pop %rax pop %r8 pop %r15 pop %r10 ret .global s_faulty_load s_faulty_load: push %r10 push %r11 push %r12 push %r14 push %r9 push %rbx push %rcx push %rdi push %rsi // Load lea addresses_D+0x320e, %r12 and $26524, %r14 vmovups (%r12), %ymm6 vextracti128 $1, %ymm6, %xmm6 vpextrq $0, %xmm6, %rbx nop nop sub %r9, %r9 // Store lea addresses_normal+0x1a15e, %r12 inc %r10 mov $0x5152535455565758, %r14 movq %r14, %xmm7 vmovups %ymm7, (%r12) nop nop nop nop cmp $22743, %r10 // Store lea addresses_UC+0x1608e, %rdi nop nop and %r11, %r11 movw $0x5152, (%rdi) nop nop nop dec %r12 // REPMOV lea addresses_A+0x820e, %rsi lea addresses_UC+0x17a0e, %rdi nop nop xor %r12, %r12 mov $123, %rcx rep movsl nop nop nop nop xor $4798, %r10 // Faulty Load lea addresses_UC+0x17a0e, %rcx nop cmp $44228, %rdi movb (%rcx), %r9b lea oracles, %rsi and $0xff, %r9 shlq $12, %r9 mov (%rsi,%r9,1), %r9 pop %rsi pop %rdi pop %rcx pop %rbx pop %r9 pop %r14 pop %r12 pop %r11 pop %r10 ret /* <gen_faulty_load> [REF] {'src': {'type': 'addresses_UC', 'AVXalign': False, 'size': 4, 'NT': False, 'same': False, 'congruent': 0}, 'OP': 'LOAD'} {'src': {'type': 'addresses_D', 'AVXalign': False, 'size': 32, 'NT': False, 'same': False, 'congruent': 7}, 'OP': 'LOAD'} {'OP': 'STOR', 'dst': {'type': 'addresses_normal', 'AVXalign': False, 'size': 32, 'NT': False, 'same': False, 'congruent': 3}} {'OP': 'STOR', 'dst': {'type': 'addresses_UC', 'AVXalign': False, 'size': 2, 'NT': False, 'same': False, 'congruent': 4}} {'src': {'type': 'addresses_A', 'congruent': 11, 'same': False}, 'OP': 'REPM', 'dst': {'type': 'addresses_UC', 'congruent': 0, 'same': True}} [Faulty Load] {'src': {'type': 'addresses_UC', 'AVXalign': False, 'size': 1, 'NT': False, 'same': True, 'congruent': 0}, 'OP': 'LOAD'} <gen_prepare_buffer> {'OP': 'STOR', 'dst': {'type': 'addresses_A_ht', 'AVXalign': False, 'size': 4, 'NT': False, 'same': False, 'congruent': 3}} {'src': {'type': 'addresses_normal_ht', 'AVXalign': False, 'size': 4, 'NT': False, 'same': True, 'congruent': 1}, 'OP': 'LOAD'} {'OP': 'STOR', 'dst': {'type': 'addresses_WC_ht', 'AVXalign': False, 'size': 1, 'NT': False, 'same': False, 'congruent': 5}} {'src': {'type': 'addresses_D_ht', 'AVXalign': False, 'size': 16, 'NT': False, 'same': False, 'congruent': 5}, 'OP': 'LOAD'} {'OP': 'STOR', 'dst': {'type': 'addresses_A_ht', 'AVXalign': False, 'size': 4, 'NT': False, 'same': False, 'congruent': 9}} {'src': {'type': 'addresses_normal_ht', 'congruent': 1, 'same': False}, 'OP': 'REPM', 'dst': {'type': 'addresses_A_ht', 'congruent': 10, 'same': False}} {'src': {'type': 'addresses_WT_ht', 'congruent': 1, 'same': False}, 'OP': 'REPM', 'dst': {'type': 'addresses_normal_ht', 'congruent': 8, 'same': False}} {'src': {'type': 'addresses_A_ht', 'congruent': 9, 'same': False}, 'OP': 'REPM', 'dst': {'type': 'addresses_D_ht', 'congruent': 6, 'same': False}} {'src': {'type': 'addresses_WC_ht', 'AVXalign': False, 'size': 16, 'NT': False, 'same': False, 'congruent': 1}, 'OP': 'LOAD'} {'35': 21829} 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 */
programs/oeis/047/A047343.asm
neoneye/loda
22
171191
; A047343: Numbers that are congruent to {1, 3, 4} mod 7. ; 1,3,4,8,10,11,15,17,18,22,24,25,29,31,32,36,38,39,43,45,46,50,52,53,57,59,60,64,66,67,71,73,74,78,80,81,85,87,88,92,94,95,99,101,102,106,108,109,113,115,116,120,122,123,127,129,130,134,136,137,141 add $0,8 seq $0,47266 ; Numbers that are congruent to {0, 1, 5} mod 6. add $2,$0 div $2,6 add $0,$2 sub $0,18
programs/oeis/245/A245354.asm
neoneye/loda
22
10152
<reponame>neoneye/loda<gh_stars>10-100 ; A245354: Sum of digits of n in fractional base 9/5. ; 0,1,2,3,4,5,6,7,8,5,6,7,8,9,10,11,12,13,6,7,8,9,10,11,12,13,14,11,12,13,14,15,16,17,18,19,8,9,10,11,12,13,14,15,16,13,14,15,16,17,18,19,20,21,14,15,16,17,18,19,20,21,22,19,20,21,22,23 lpb $0 add $1,530 lpb $0 dif $0,9 mul $0,5 lpe sub $0,1 lpe div $1,530 mov $0,$1
Transynther/x86/_processed/AVXALIGN/_zr_/i7-7700_9_0x48_notsx.log_21829_1080.asm
ljhsiun2/medusa
9
16135
.global s_prepare_buffers s_prepare_buffers: push %r10 push %r15 push %r9 push %rax push %rbp push %rcx push %rdi push %rsi lea addresses_WC_ht+0x74a, %r10 nop nop and %rsi, %rsi mov (%r10), %bp nop nop nop xor %r10, %r10 lea addresses_WC_ht+0x1d40a, %rsi lea addresses_UC_ht+0x13b4a, %rdi nop nop nop nop nop inc %r10 mov $115, %rcx rep movsl nop nop nop sub %rcx, %rcx lea addresses_D_ht+0x589a, %rbp nop nop nop nop cmp $50460, %rsi and $0xffffffffffffffc0, %rbp movntdqa (%rbp), %xmm5 vpextrq $1, %xmm5, %rdi nop nop nop nop cmp %r10, %r10 lea addresses_UC_ht+0x5457, %r10 nop nop nop nop nop add $7448, %r9 movb (%r10), %al nop nop nop nop nop add $17188, %rcx lea addresses_D_ht+0x7bbd, %rsi lea addresses_D_ht+0x8343, %rdi cmp %r10, %r10 mov $61, %rcx rep movsw nop sub %rbp, %rbp lea addresses_A_ht+0x18f4a, %rsi lea addresses_WC_ht+0x1396e, %rdi nop nop nop and $32412, %r15 mov $96, %rcx rep movsq nop nop nop nop nop cmp $60712, %rdi pop %rsi pop %rdi pop %rcx pop %rbp pop %rax pop %r9 pop %r15 pop %r10 ret .global s_faulty_load s_faulty_load: push %r10 push %r14 push %r15 push %r8 push %rbx push %rcx push %rdi push %rsi // REPMOV lea addresses_WT+0x1b5ca, %rsi lea addresses_PSE+0x1a7a6, %rdi nop dec %rbx mov $5, %rcx rep movsl nop xor %rdi, %rdi // REPMOV lea addresses_normal+0x1743a, %rsi lea addresses_D+0x5ae7, %rdi add $6046, %r15 mov $105, %rcx rep movsw and $35309, %r10 // Store lea addresses_D+0x93be, %r14 nop nop nop nop nop add %r10, %r10 mov $0x5152535455565758, %r15 movq %r15, (%r14) // Exception!!! nop nop mov (0), %rcx nop and $29511, %rsi // Store lea addresses_normal+0x6942, %rbx xor $52728, %r15 movl $0x51525354, (%rbx) nop nop inc %rdi // Store lea addresses_D+0x1662a, %r8 nop nop nop nop nop xor $6531, %rsi mov $0x5152535455565758, %r15 movq %r15, %xmm7 vmovups %ymm7, (%r8) nop nop nop cmp $51317, %rcx // Store lea addresses_WC+0xc5ca, %rsi nop nop nop nop nop sub %rbx, %rbx mov $0x5152535455565758, %rcx movq %rcx, (%rsi) nop xor %rcx, %rcx // Store lea addresses_A+0xac90, %rsi nop nop nop nop and %r8, %r8 mov $0x5152535455565758, %rcx movq %rcx, %xmm2 vmovups %ymm2, (%rsi) nop nop nop nop nop xor %rcx, %rcx // Store lea addresses_normal+0x122a, %rbx nop nop nop add $60905, %r14 mov $0x5152535455565758, %r15 movq %r15, %xmm2 movups %xmm2, (%rbx) nop nop cmp %rcx, %rcx // Store mov $0x60671e0000000a60, %r14 nop add %r15, %r15 movw $0x5152, (%r14) nop nop and %rsi, %rsi // Faulty Load mov $0x141b14000000074a, %r15 nop nop nop nop dec %rdi movb (%r15), %r10b lea oracles, %rbx and $0xff, %r10 shlq $12, %r10 mov (%rbx,%r10,1), %r10 pop %rsi pop %rdi pop %rcx pop %rbx pop %r8 pop %r15 pop %r14 pop %r10 ret /* <gen_faulty_load> [REF] {'OP': 'LOAD', 'src': {'same': False, 'NT': False, 'AVXalign': False, 'size': 4, 'type': 'addresses_NC', 'congruent': 0}} {'dst': {'same': False, 'congruent': 1, 'type': 'addresses_PSE'}, 'OP': 'REPM', 'src': {'same': False, 'congruent': 7, 'type': 'addresses_WT'}} {'dst': {'same': False, 'congruent': 0, 'type': 'addresses_D'}, 'OP': 'REPM', 'src': {'same': False, 'congruent': 4, 'type': 'addresses_normal'}} {'dst': {'same': False, 'NT': False, 'AVXalign': False, 'size': 8, 'type': 'addresses_D', 'congruent': 2}, 'OP': 'STOR'} {'dst': {'same': False, 'NT': False, 'AVXalign': False, 'size': 4, 'type': 'addresses_normal', 'congruent': 3}, 'OP': 'STOR'} {'dst': {'same': False, 'NT': False, 'AVXalign': False, 'size': 32, 'type': 'addresses_D', 'congruent': 2}, 'OP': 'STOR'} {'dst': {'same': False, 'NT': False, 'AVXalign': False, 'size': 8, 'type': 'addresses_WC', 'congruent': 7}, 'OP': 'STOR'} {'dst': {'same': False, 'NT': False, 'AVXalign': False, 'size': 32, 'type': 'addresses_A', 'congruent': 0}, 'OP': 'STOR'} {'dst': {'same': False, 'NT': False, 'AVXalign': False, 'size': 16, 'type': 'addresses_normal', 'congruent': 4}, 'OP': 'STOR'} {'dst': {'same': False, 'NT': False, 'AVXalign': False, 'size': 2, 'type': 'addresses_NC', 'congruent': 1}, 'OP': 'STOR'} [Faulty Load] {'OP': 'LOAD', 'src': {'same': True, 'NT': False, 'AVXalign': True, 'size': 1, 'type': 'addresses_NC', 'congruent': 0}} <gen_prepare_buffer> {'OP': 'LOAD', 'src': {'same': False, 'NT': False, 'AVXalign': False, 'size': 2, 'type': 'addresses_WC_ht', 'congruent': 7}} {'dst': {'same': False, 'congruent': 8, 'type': 'addresses_UC_ht'}, 'OP': 'REPM', 'src': {'same': True, 'congruent': 4, 'type': 'addresses_WC_ht'}} {'OP': 'LOAD', 'src': {'same': True, 'NT': True, 'AVXalign': False, 'size': 16, 'type': 'addresses_D_ht', 'congruent': 4}} {'OP': 'LOAD', 'src': {'same': False, 'NT': False, 'AVXalign': True, 'size': 1, 'type': 'addresses_UC_ht', 'congruent': 0}} {'dst': {'same': False, 'congruent': 0, 'type': 'addresses_D_ht'}, 'OP': 'REPM', 'src': {'same': True, 'congruent': 0, 'type': 'addresses_D_ht'}} {'dst': {'same': False, 'congruent': 0, 'type': 'addresses_WC_ht'}, 'OP': 'REPM', 'src': {'same': False, 'congruent': 11, 'type': 'addresses_A_ht'}} {'00': 21829} 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 */
gcc-gcc-7_3_0-release/gcc/testsuite/gnat.dg/renaming8_pkg1.ads
best08618/asylo
7
24326
with Renaming8_Pkg2; use Renaming8_Pkg2; package Renaming8_Pkg1 is B: Boolean renames F.E(1); end Renaming8_Pkg1;
src/asf-contexts-exceptions-iterate.ads
My-Colaborations/ada-asf
0
2170
----------------------------------------------------------------------- -- asf-contexts-exceptions -- Exception handlers in faces context -- Copyright (C) 2011 <NAME> -- Written by <NAME> (<EMAIL>) -- -- 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. ----------------------------------------------------------------------- with ASF.Contexts.Faces; -- Iterate over the exception events which are in the queue and execute the given procedure. -- The procedure should return True in <b>Remove</b> to indicate that the exception has been -- processed. -- -- Notes: this procedure should not be called directly (use ASF.Contexts.Faces.Iterate). -- This procedure is separate to avoid circular dependency. procedure ASF.Contexts.Exceptions.Iterate (Queue : in out Exception_Queue; Context : in out ASF.Contexts.Faces.Faces_Context'Class; Process : not null access procedure (Event : in ASF.Events.Exceptions.Exception_Event'Class; Remove : out Boolean; Context : in out ASF.Contexts.Faces.Faces_Context'Class));
src/test/ref/sizeof-arrays.asm
jbrandwood/kickc
2
12452
// Tests the sizeof() operator on arrays // Commodore 64 PRG executable file .file [name="sizeof-arrays.prg", type="prg", segments="Program"] .segmentdef Program [segments="Basic, Code, Data"] .segmentdef Basic [start=$0801] .segmentdef Code [start=$80d] .segmentdef Data [startAfter="Code"] .segment Basic :BasicUpstart(main) .const SIZEOF_CHAR = 1 .const SIZEOF_UNSIGNED_INT = 2 .label SCREEN = $400 .segment Code main: { .const sz = 7 // SCREEN[idx++] = '0'+(char)(sizeof(ba)/sizeof(byte)) lda #'0'+3*SIZEOF_CHAR/SIZEOF_CHAR sta SCREEN // SCREEN[idx++] = '0'+(char)(sizeof(wa)/sizeof(word)) lda #'0'+3*SIZEOF_UNSIGNED_INT/SIZEOF_UNSIGNED_INT sta SCREEN+1 // SCREEN[idx++] = '0'+(char)(sizeof(bb)/sizeof(byte)) lda #'0'+(sz+2)*SIZEOF_CHAR/SIZEOF_CHAR sta SCREEN+2 // SCREEN[idx++] = '0'+(char)(sizeof(wb)/sizeof(word)) lda #'0'+4*SIZEOF_UNSIGNED_INT/SIZEOF_UNSIGNED_INT sta SCREEN+3 // SCREEN[idx++] = '0'+(char)(sizeof(sa)/sizeof(byte)) lda #'0'+8*SIZEOF_CHAR/SIZEOF_CHAR sta SCREEN+4 // SCREEN[idx++] = '0'+(char)(sizeof(sb)/sizeof(byte)) lda #'0'+4*SIZEOF_CHAR/SIZEOF_CHAR sta SCREEN+5 // } rts }
wof/lcs/enemy/4E.asm
zengfr/arcade_game_romhacking_sourcecode_top_secret_data
6
3188
copyright zengfr site:http://github.com/zengfr/romhack 001590 lea ($20,A0), A0 012272 move.l (A2)+, (A3)+ [enemy+48, enemy+4A] 012274 move.l (A2)+, (A3)+ 01A75E dbra D4, $1a75c copyright zengfr site:http://github.com/zengfr/romhack
libsrc/_DEVELOPMENT/target/rc2014/device/acia/z80/__acia_data_Rx.asm
ahjelm/z88dk
640
3139
<filename>libsrc/_DEVELOPMENT/target/rc2014/device/acia/z80/__acia_data_Rx.asm INCLUDE "config_private.inc" SECTION data_driver PUBLIC aciaRxCount, aciaRxIn, aciaRxOut, aciaRxLock aciaRxCount: defb 0 ; Space for Rx Buffer Management aciaRxIn: defw aciaRxBuffer ; pointer to buffer aciaRxOut: defw aciaRxBuffer ; pointer to buffer aciaRxLock: defb 0 ; lock flag for Rx exclusion IF __IO_ACIA_RX_SIZE = 256 SECTION data_align_256 ALIGN 256 ENDIF IF __IO_ACIA_RX_SIZE = 128 SECTION data_align_128 ALIGN 128 ENDIF IF __IO_ACIA_RX_SIZE = 64 SECTION data_align_64 ALIGN 64 ENDIF IF __IO_ACIA_RX_SIZE = 32 SECTION data_align_32 ALIGN 32 ENDIF IF __IO_ACIA_RX_SIZE = 16 SECTION data_align_16 ALIGN 16 ENDIF IF __IO_ACIA_RX_SIZE = 8 SECTION data_align_8 ALIGN 8 ENDIF IF __IO_ACIA_RX_SIZE%8 != 0 ERROR "__IO_ACIA_RX_SIZE not 2^n" ENDIF PUBLIC aciaRxBuffer aciaRxBuffer: defs __IO_ACIA_RX_SIZE ; Space for the Rx Buffer ; pad to next boundary IF __IO_ACIA_RX_SIZE = 256 ALIGN 256 ENDIF IF __IO_ACIA_RX_SIZE = 128 ALIGN 128 ENDIF IF __IO_ACIA_RX_SIZE = 64 ALIGN 64 ENDIF IF __IO_ACIA_RX_SIZE = 32 ALIGN 32 ENDIF IF __IO_ACIA_RX_SIZE = 16 ALIGN 16 ENDIF IF __IO_ACIA_RX_SIZE = 8 ALIGN 8 ENDIF
3-mid/opengl/source/lean/opengl-texture.ads
charlie5/lace
20
27755
with ada.unchecked_Conversion, ada.Strings.unbounded.Hash, ada.Containers.hashed_Maps; package openGL.Texture -- -- Provides openGL textures. -- is -- Object - an openGL texture 'object' -- type Object is tagged private; type Objects is array (Positive range <>) of Object; null_Object : constant Object; subtype texture_Name is GL.GLuint; -- An openGL texture object 'Name'. subtype Dimensions is Extent_2d; --------- --- Forge -- package Forge is function to_Texture (Name : in texture_Name) return Object; function to_Texture (Dimensions : in Texture.Dimensions) return Object; function to_Texture (the_Image : in Image; use_Mipmaps : in Boolean := True) return Object; function to_Texture (the_Image : in lucid_Image; use_Mipmaps : in Boolean := True) return Object; end Forge; procedure destroy (Self : in out Object); procedure free (Self : in out Object); -------------- --- Attributes -- function is_Defined (Self : in Object) return Boolean; function is_Transparent (Self : in Object) return Boolean; procedure set_Name (Self : in out Object; To : in texture_Name); function Name (Self : in Object) return texture_Name; procedure enable (Self : in Object); procedure set_Image (Self : in out Object; To : in Image; use_Mipmaps : in Boolean := True); procedure set_Image (Self : in out Object; To : in lucid_Image; use_Mipmaps : in Boolean := True); function Size (Self : in Object) return Texture.Dimensions; ------- -- Maps -- type name_Map_of_texture is tagged private; function fetch (From : access name_Map_of_texture'Class; texture_Name : in asset_Name) return Object; -------- -- Pool -- -- For rapid allocation/deallocation of texture objects. -- TODO: Move this into a child package ? type Pool is private; type Pool_view is access all Pool; procedure destroy (the_Pool : in out Pool); function new_Texture (From : access Pool; Size : in Dimensions) return Object; -- -- Returns a texture object of the requested size. procedure free (From : in out Pool; the_Texture : in Object); -- -- Frees a texture for future use. procedure vacuum (the_Pool : in out Pool); -- -- Releases any allocated, but unused, texture objects. ----------- -- GL Enums -- -- TexFormatEnm -- type Format is (ALPHA, RGB, RGBA, LUMINANCE, LUMINANCE_ALPHA, R3_G3_B2, ALPHA4, ALPHA8, ALPHA12, ALPHA16, LUMINANCE4, LUMINANCE8, LUMINANCE12, LUMINANCE16, LUMINANCE4_ALPHA4, LUMINANCE6_ALPHA2, LUMINANCE8_ALPHA8, LUMINANCE12_ALPHA4, LUMINANCE12_ALPHA12, LUMINANCE16_ALPHA16, INTENSITY, INTENSITY4, INTENSITY8, INTENSITY12, INTENSITY16, RGB4, RGB5, RGB8, RGB10, RGB12, RGB16, RGBA2, RGBA4, RGB5_A1, RGBA8, RGB10_A2, RGBA12, RGBA16, BGR, BGRA); type pixel_Format is (COLOR_INDEX, RED, GREEN, BLUE, ALPHA, RGB, RGBA, LUMINANCE, LUMINANCE_ALPHA); function to_GL (From : in Format) return GL.GLenum; function to_GL (From : in pixel_Format) return GL.GLenum; ---------- -- Utility -- function Power_of_2_Ceiling (From : in Positive) return GL.GLsizei; private type Object is tagged record Name : aliased texture_Name := 0; Dimensions : Texture.Dimensions := (0, 0); is_Transparent : Boolean := False; Pool : access Texture.Pool; end record; ------- -- Maps -- use Ada.Strings.unbounded; package name_Maps_of_texture_id is new ada.Containers.hashed_Maps (unbounded_String, Texture.Object, Hash, "="); type name_Map_of_texture is new name_Maps_of_texture_id.Map with null record; --------------- --- Rep Clauses -- for Format use (ALPHA => 16#1906#, RGB => 16#1907#, RGBA => 16#1908#, LUMINANCE => 16#1909#, LUMINANCE_ALPHA => 16#190A#, R3_G3_B2 => 16#2A10#, ALPHA4 => 16#803B#, ALPHA8 => 16#803C#, ALPHA12 => 16#803D#, ALPHA16 => 16#803E#, LUMINANCE4 => 16#803F#, LUMINANCE8 => 16#8040#, LUMINANCE12 => 16#8041#, LUMINANCE16 => 16#8042#, LUMINANCE4_ALPHA4 => 16#8043#, LUMINANCE6_ALPHA2 => 16#8044#, LUMINANCE8_ALPHA8 => 16#8045#, LUMINANCE12_ALPHA4 => 16#8046#, LUMINANCE12_ALPHA12 => 16#8047#, LUMINANCE16_ALPHA16 => 16#8048#, INTENSITY => 16#8049#, INTENSITY4 => 16#804A#, INTENSITY8 => 16#804B#, INTENSITY12 => 16#804C#, INTENSITY16 => 16#804D#, RGB4 => 16#804F#, RGB5 => 16#8050#, RGB8 => 16#8051#, RGB10 => 16#8052#, RGB12 => 16#8053#, RGB16 => 16#8054#, RGBA2 => 16#8055#, RGBA4 => 16#8056#, RGB5_A1 => 16#8057#, RGBA8 => 16#8058#, RGB10_A2 => 16#8059#, RGBA12 => 16#805A#, RGBA16 => 16#805B#, BGR => 16#80E0#, BGRA => 16#80E1#); for Format'Size use GL.GLenum'Size; for pixel_Format use (COLOR_INDEX => 16#1900#, RED => 16#1903#, GREEN => 16#1904#, BLUE => 16#1905#, ALPHA => 16#1906#, RGB => 16#1907#, RGBA => 16#1908#, LUMINANCE => 16#1909#, LUMINANCE_ALPHA => 16#190A#); for pixel_Format'Size use GL.GLenum'Size; -------- -- Pool -- type pool_texture_List is record Textures : Objects (1 .. 5_000); Last : Natural := 0; end record; type pool_texture_List_view is access all pool_texture_List; function Hash (the_Dimensions : in Texture.Dimensions) return ada.Containers.Hash_type; package size_Maps_of_pool_texture_List is new ada.Containers.hashed_Maps (Key_Type => Dimensions, Element_Type => pool_texture_List_view, Hash => Hash, Equivalent_Keys => "="); type Pool is record Map : size_Maps_of_pool_texture_List.Map; end record; ------------- -- Constants -- null_Object : constant Object := (others => <>); --------------- -- Conversions -- function convert_1 is new Ada.Unchecked_Conversion (Format, GL.GLenum); function convert_2 is new Ada.Unchecked_Conversion (pixel_Format, GL.GLenum); function to_GL (From : in Format) return GL.GLenum renames convert_1; function to_GL (From : in pixel_Format) return GL.GLenum renames convert_2; end openGL.Texture;
misc/RecursiveDescent/Inductive/Semantics.agda
yurrriq/parser-combinators
7
10988
------------------------------------------------------------------------ -- Semantics of the parsers ------------------------------------------------------------------------ -- Currently it is only specified when a string is _accepted_ by a -- parser; semantic actions are not included. module RecursiveDescent.Inductive.Semantics where open import RecursiveDescent.Index open import RecursiveDescent.Inductive open import RecursiveDescent.Inductive.SimpleLib open import Data.List open import Data.Product.Record open import Data.Maybe infix 3 _∈⟦_⟧_ mutual _∈⟦_⟧_ : forall {tok nt i r} -> List tok -> Parser tok nt i r -> Grammar tok nt -> Set1 s ∈⟦ p ⟧ g = Semantics g s p data Semantics {tok : Set} {nt : ParserType₁} (g : Grammar tok nt) : forall {i r} -> List tok -> Parser tok nt i r -> Set1 where !-sem : forall {e c r} s (x : nt (e , c) r) -> s ∈⟦ g x ⟧ g -> s ∈⟦ ! x ⟧ g symbol-sem : forall c -> [ c ] ∈⟦ symbol ⟧ g return-sem : forall {r} (x : r) -> [] ∈⟦ return x ⟧ g -- The following rule should really describe the intended -- semantics of _>>=_, not _⊛_. _!>>=_ should also get a rule. ⊛-sem : forall {i₁ i₂ r₁ r₂ s₁ s₂} {p₁ : Parser tok nt i₁ (r₁ -> r₂)} {p₂ : Parser tok nt i₂ r₁} -> s₁ ∈⟦ p₁ ⟧ g -> s₂ ∈⟦ p₂ ⟧ g -> s₁ ++ s₂ ∈⟦ p₁ ⊛ p₂ ⟧ g ∣ˡ-sem : forall {i₁ i₂ r s} {p₁ : Parser tok nt i₁ r} {p₂ : Parser tok nt i₂ r} -> s ∈⟦ p₁ ⟧ g -> s ∈⟦ p₁ ∣ p₂ ⟧ g ∣ʳ-sem : forall {i₁ i₂ r s} {p₁ : Parser tok nt i₁ r} {p₂ : Parser tok nt i₂ r} -> s ∈⟦ p₂ ⟧ g -> s ∈⟦ p₁ ∣ p₂ ⟧ g ------------------------------------------------------------------------ -- Soundness of recognition data NonEmpty {a : Set} : List a -> Set where nonEmpty : forall x xs -> NonEmpty (x ∷ xs) postulate sound : forall {tok nt i r} (p : Parser tok nt i r) (g : Grammar tok nt) (s : List tok) -> NonEmpty (parse-complete p g s) -> s ∈⟦ p ⟧ g
include/bits_types_u_fpos_t_h.ads
docandrew/troodon
5
16579
pragma Ada_2012; pragma Style_Checks (Off); with Interfaces.C; use Interfaces.C; with bits_types_h; with bits_types_u_mbstate_t_h; package bits_types_u_fpos_t_h is -- The tag name of this struct is _G_fpos_t to preserve historic -- C++ mangled names for functions taking fpos_t arguments. -- That name should not be used in new code. type u_G_fpos_t is record uu_pos : aliased bits_types_h.uu_off_t; -- /usr/include/bits/types/__fpos_t.h:12 uu_state : aliased bits_types_u_mbstate_t_h.uu_mbstate_t; -- /usr/include/bits/types/__fpos_t.h:13 end record with Convention => C_Pass_By_Copy; -- /usr/include/bits/types/__fpos_t.h:10 subtype uu_fpos_t is u_G_fpos_t; -- /usr/include/bits/types/__fpos_t.h:14 end bits_types_u_fpos_t_h;
programs/oeis/004/A004378.asm
neoneye/loda
22
177223
; A004378: Binomial coefficient C(7n,n-10). ; 1,77,3486,121485,3612280,96560646,2392407864,56017460733,1255914977625,27212042858000,573658984353378,11825811462719982,239315973934897860,4768545345973022600,93780365051563029360 mov $1,$0 add $0,10 mul $0,7 bin $0,$1
Agda/RevRev.agda
Brethland/LEARNING-STUFF
2
3981
{-# OPTIONS --safe #-} module RevRev where open import Relation.Binary.PropositionalEquality open import Data.List open import Data.List.Properties rev : ∀ {ℓ} {A : Set ℓ} → List A → List A rev [] = [] rev (x ∷ xs) = rev xs ++ x ∷ [] lemma : ∀ {ℓ} {A : Set ℓ} (a b : List A) → rev (a ++ b) ≡ rev b ++ rev a lemma [] b rewrite ++-identityʳ (rev b) = refl lemma (x ∷ a) b rewrite lemma a b | ++-assoc (rev b) (rev a) (x ∷ []) = refl revrevid : ∀ {ℓ} {A : Set ℓ} (a : List A) → rev (rev a) ≡ a revrevid [] = refl revrevid (x ∷ a) rewrite lemma (rev a) (x ∷ []) | revrevid a = refl
programs/oeis/266/A266250.asm
karttu/loda
0
242211
; A266250: Total number of ON (black) cells after n iterations of the "Rule 9" elementary cellular automaton starting with a single ON (black) cell. ; 1,1,3,5,9,14,18,27,31,44,48,65,69,90,94,119,123,152,156,189,193,230,234,275,279,324,328,377,381,434,438,495,499,560,564,629,633,702,706,779,783,860,864,945,949,1034,1038,1127,1131,1224,1228,1325,1329,1430,1434,1539,1543,1652,1656,1769,1773,1890,1894,2015,2019,2144,2148,2277,2281,2414,2418,2555,2559,2700,2704,2849,2853,3002,3006,3159,3163,3320,3324,3485,3489,3654,3658,3827,3831,4004,4008,4185,4189,4370,4374,4559,4563,4752,4756,4949,4953,5150,5154,5355,5359,5564,5568,5777,5781,5994,5998,6215,6219,6440,6444,6669,6673,6902,6906,7139,7143,7380,7384,7625,7629,7874,7878,8127,8131,8384,8388,8645,8649,8910,8914,9179,9183,9452,9456,9729,9733,10010,10014,10295,10299,10584,10588,10877,10881,11174,11178,11475,11479,11780,11784,12089,12093,12402,12406,12719,12723,13040,13044,13365,13369,13694,13698,14027,14031,14364,14368,14705,14709,15050,15054,15399,15403,15752,15756,16109,16113,16470,16474,16835,16839,17204,17208,17577,17581,17954,17958,18335,18339,18720,18724,19109,19113,19502,19506,19899,19903,20300,20304,20705,20709,21114,21118,21527,21531,21944,21948,22365,22369,22790,22794,23219,23223,23652,23656,24089,24093,24530,24534,24975,24979,25424,25428,25877,25881,26334,26338,26795,26799,27260,27264,27729,27733,28202,28206,28679,28683,29160,29164,29645,29649,30134,30138,30627,30631,31124 mov $5,$0 mov $7,$0 add $7,1 lpb $7,1 clr $0,5 mov $0,$5 sub $7,1 sub $0,$7 add $4,$0 mul $4,2 cal $0,266251 ; Number of OFF (white) cells in the n-th iteration of the "Rule 9" elementary cellular automaton starting with a single ON (black) cell. add $4,22 sub $4,$0 mov $1,$4 sub $1,21 add $6,$1 lpe mov $1,$6
src/shaders/post_processing/gen5_6/Common/AYUV_Load_16x8.asm
tizenorg/platform.upstream.libva-intel-driver
0
84332
/* * All Video Processing kernels * 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: AYUV_Load_16x8.asm //---------------------------------------------------------------- #include "AYUV_Load_16x8.inc" // In order to load 64x8 AYUV data (16x8 pixels), we need to divide the data // into two regions and load them separately. // // 32 byte 32 byte //|----------------|----------------| //| | | //| A | B |8 //| | | //| | | //|----------------|----------------| // Load the first 32x8 data block // Packed data block should be loaded as 32x8 pixel block add (2) rMSGSRC.0<1>:d wORIX<2;2,1>:w wSRC_H_ORI_OFFSET<2;2,1>:w // Source Block origin shl (1) rMSGSRC.0<1>:d acc0:w 2:w { NoDDClr } // H. block origin need to be four times larger mov (1) rMSGSRC.2<1>:ud nDPR_BLOCK_SIZE_YUV:ud { NoDDChk } // Block width and height (32x8) mov (8) mMSGHDRY<1>:ud rMSGSRC<8;8,1>:ud send (8) udSRC_YUV(0)<1> mMSGHDRY udDUMMY_NULL nDATAPORT_READ nDPMR_MSGDSC+nDPR_MSG_SIZE_YUV+nBI_CURRENT_SRC_YUV:ud //Load the second 32x8 data block // Offset the origin X - move to next 32 colomns add (1) rMSGSRC.0<1>:d rMSGSRC.0<0;1,0>:d 32:w // Increase X origin by 8 // Size stays the same - 32x8 mov (8) mMSGHDRY<1>:ud rMSGSRC<8;8,1>:ud // Copy message description to message header send (8) udSRC_YUV(8)<1> mMSGHDRY udDUMMY_NULL nDATAPORT_READ nDPMR_MSGDSC+nDPR_MSG_SIZE_YUV+nBI_CURRENT_SRC_YUV:ud // Give AYUV region addresses to address register mov (1) SRC_YUV_OFFSET<1>:ud 0x00400038*32:ud //Address registers contain starting addresses of two halves //Directly move the data to destination $for(0; <nY_NUM_OF_ROWS; 1) { mov (16) uwDEST_Y(%1)<1> r[SRC_YUV_OFFSET,%1*32+2]<8,4>:ub mov (16) uwDEST_U(%1)<1> r[SRC_YUV_OFFSET,%1*32+1]<8,4>:ub mov (16) uwDEST_V(%1)<1> r[SRC_YUV_OFFSET,%1*32+0]<8,4>:ub }
libsrc/_DEVELOPMENT/arch/ts2068/misc/c/sccz80/tshc_visit_wc_pix.asm
jpoikela/z88dk
38
84808
; void tshc_visit_wc_pix(struct r_Rect8 *r, void *function) SECTION code_clib SECTION code_arch PUBLIC tshc_visit_wc_pix EXTERN asm_zx_visit_wc_pix tshc_visit_wc_pix: pop af pop de pop ix push de push de push af jp asm_zx_visit_wc_pix
test/Fail/Issue4775.agda
cruhland/agda
1,989
12258
<reponame>cruhland/agda<filename>test/Fail/Issue4775.agda -- Andreas, 2020-06-24, issue #4775 reported by JakobBruenker -- Non-record patterns in lets and lambdas lead to internal error -- {-# OPTIONS -v tc.term.lambda:30 #-} -- {-# OPTIONS -v tc.lhs:15 #-} -- {-# OPTIONS -v tc.term.let.pattern:30 #-} -- -- {-# OPTIONS -v tc.term.let.pattern:80 #-} open import Agda.Builtin.Nat open import Agda.Builtin.Sigma data IsSuc : Nat → Set where isSuc : ∀ y → IsSuc (suc y) test : Σ Nat IsSuc → Set test = λ (y1 , isSuc y2) → Nat -- ERROR NOW: -- Expected record pattern -- when checking the let binding y1 , isSuc y2 = .patternInTele0 -- (Talks about desugaring; could still be improved.)
gcc-gcc-7_3_0-release/gcc/testsuite/ada/acats/tests/cc/cc3106b.ada
best08618/asylo
7
27109
<filename>gcc-gcc-7_3_0-release/gcc/testsuite/ada/acats/tests/cc/cc3106b.ada -- CC3106B.ADA -- Grant of Unlimited Rights -- -- Under contracts F33600-87-D-0337, F33600-84-D-0280, MDA903-79-C-0687, -- F08630-91-C-0015, and DCA100-97-D-0025, the U.S. Government obtained -- unlimited rights in the software and documentation contained herein. -- Unlimited rights are defined in DFAR 252.227-7013(a)(19). By making -- this public release, the Government intends to confer upon all -- recipients unlimited rights equal to those held by the Government. -- These rights include rights to use, duplicate, release or disclose the -- released technical data and computer software in whole or in part, in -- any manner and for any purpose whatsoever, and to have or permit others -- to do so. -- -- DISCLAIMER -- -- ALL MATERIALS OR INFORMATION HEREIN RELEASED, MADE AVAILABLE OR -- DISCLOSED ARE AS IS. THE GOVERNMENT MAKES NO EXPRESS OR IMPLIED -- WARRANTY AS TO ANY MATTER WHATSOEVER, INCLUDING THE CONDITIONS OF THE -- SOFTWARE, DOCUMENTATION OR OTHER INFORMATION RELEASED, MADE AVAILABLE -- OR DISCLOSED, OR THE OWNERSHIP, MERCHANTABILITY, OR FITNESS FOR A -- PARTICULAR PURPOSE OF SAID MATERIAL. --* -- CHECK THAT THE FORMAL PARAMETER DENOTES THE ACTUAL -- IN AN INSTANTIATION. -- HISTORY: -- LDC 06/20/88 CREATED ORIGINAL TEST -- <NAME>, 10 AUGUST 1990 ADDED CHECKS FOR MULTI- -- DIMENSIONAL ARRAYS WITH REPORT ; PROCEDURE CC3106B IS BEGIN -- CC3106B REPORT.TEST("CC3106B","CHECK THAT THE FORMAL PARAMETER DENOTES " & "THE ACTUAL IN AN INSTANTIATION"); LOCAL_BLOCK: DECLARE SUBTYPE SM_INT IS INTEGER RANGE 0..15 ; TYPE PCK_BOL IS ARRAY (5..18) OF BOOLEAN ; PRAGMA PACK(PCK_BOL) ; SHORT_START : CONSTANT := -100 ; SHORT_END : CONSTANT := 100 ; TYPE SHORT_RANGE IS RANGE SHORT_START .. SHORT_END ; SUBTYPE REALLY_SHORT IS SHORT_RANGE RANGE -9 .. 0 ; TYPE MONTH_TYPE IS (JAN, FEB, MAR, APR, MAY, JUN, JUL, AUG, SEP, OCT, NOV, DEC) ; SUBTYPE FIRST_HALF IS MONTH_TYPE RANGE JAN .. JUN ; TYPE DAY_TYPE IS RANGE 1 .. 31 ; TYPE YEAR_TYPE IS RANGE 1904 .. 2050 ; TYPE DATE IS RECORD MONTH : MONTH_TYPE ; DAY : DAY_TYPE ; YEAR : YEAR_TYPE ; END RECORD ; TODAY : DATE := (MONTH => AUG, DAY => 8, YEAR => 1990) ; FIRST_DATE : DATE := (DAY => 6, MONTH => JUN, YEAR => 1967) ; WALL_DATE : DATE := (MONTH => NOV, DAY => 9, YEAR => 1989) ; SUBTYPE FIRST_FIVE IS CHARACTER RANGE 'A' .. 'E' ; TYPE THREE_DIMENSIONAL IS ARRAY (REALLY_SHORT, FIRST_HALF, FIRST_FIVE) OF DATE ; TD_ARRAY : THREE_DIMENSIONAL := (THREE_DIMENSIONAL'RANGE => (THREE_DIMENSIONAL'RANGE (2) => (THREE_DIMENSIONAL'RANGE (3) => TODAY))) ; TASK TYPE TSK IS ENTRY ENT_1; ENTRY ENT_2; ENTRY ENT_3; END TSK; GENERIC TYPE GEN_TYPE IS (<>); GEN_BOLARR : IN OUT PCK_BOL; GEN_TYP : IN OUT GEN_TYPE; GEN_TSK : IN OUT TSK; TEST_VALUE : IN DATE ; TEST_CUBE : IN OUT THREE_DIMENSIONAL ; PACKAGE P IS PROCEDURE GEN_PROC1 ; PROCEDURE GEN_PROC2 ; PROCEDURE GEN_PROC3 ; PROCEDURE ARRAY_TEST ; END P; ACT_BOLARR : PCK_BOL := (OTHERS => FALSE); SI : SM_INT := 0 ; T : TSK; PACKAGE BODY P IS PROCEDURE GEN_PROC1 IS BEGIN -- GEN_PROC1 GEN_BOLARR(14) := REPORT.IDENT_BOOL(TRUE); GEN_TYP := GEN_TYPE'VAL(4); IF ACT_BOLARR(14) /= TRUE OR SI /= REPORT.IDENT_INT(4) THEN REPORT.FAILED("VALUES ARE DIFFERENT THAN " & "INSTANTIATED VALUES"); END IF; END GEN_PROC1; PROCEDURE GEN_PROC2 IS BEGIN -- GEN_PROC2 IF GEN_BOLARR(9) /= REPORT.IDENT_BOOL(TRUE) OR GEN_TYPE'POS(GEN_TYP) /= REPORT.IDENT_INT(2) THEN REPORT.FAILED("VALUES ARE DIFFERENT THAN " & "VALUES ASSIGNED IN THE MAIN " & "PROCEDURE"); END IF; GEN_BOLARR(18) := TRUE; GEN_TYP := GEN_TYPE'VAL(9); END GEN_PROC2; PROCEDURE GEN_PROC3 IS BEGIN -- GEN_PROC3 GEN_TSK.ENT_2; END GEN_PROC3 ; PROCEDURE ARRAY_TEST IS BEGIN -- ARRAY_TEST TEST_CUBE (0, JUN, 'C') := TEST_VALUE ; IF (TD_ARRAY (0, JUN, 'C') /= TEST_VALUE) OR (TEST_CUBE (-5, MAR, 'A') /= WALL_DATE) THEN REPORT.FAILED ("MULTI-DIMENSIONAL ARRAY VALUES ARE " & "DIFFERENT THAN THE VALUES ASSIGNED " & "IN THE MAIN AND ARRAY_TEST PROCEDURES.") ; END IF ; END ARRAY_TEST ; END P ; TASK BODY TSK IS BEGIN -- TSK ACCEPT ENT_1 DO REPORT.COMMENT("TASK ENTRY 1 WAS CALLED"); END; ACCEPT ENT_2 DO REPORT.COMMENT("TASK ENTRY 2 WAS CALLED"); END; ACCEPT ENT_3 DO REPORT.COMMENT("TASK ENTRY 3 WAS CALLED"); END; END TSK; PACKAGE INSTA1 IS NEW P (GEN_TYPE => SM_INT, GEN_BOLARR => ACT_BOLARR, GEN_TYP => SI, GEN_TSK => T, TEST_VALUE => FIRST_DATE, TEST_CUBE => TD_ARRAY) ; BEGIN -- LOCAL_BLOCK INSTA1.GEN_PROC1; ACT_BOLARR(9) := TRUE; SI := 2; INSTA1.GEN_PROC2; IF ACT_BOLARR(18) /= REPORT.IDENT_BOOL(TRUE) OR SI /= REPORT.IDENT_INT(9) THEN REPORT.FAILED("VALUES ARE DIFFERENT THAN VALUES " & "ASSIGNED IN THE GENERIC PROCEDURE"); END IF; T.ENT_1; INSTA1.GEN_PROC3; T.ENT_3; TD_ARRAY (-5, MAR, 'A') := WALL_DATE ; INSTA1.ARRAY_TEST ; END LOCAL_BLOCK; REPORT.RESULT; END CC3106B ;
programs/oeis/185/A185906.asm
jmorken/loda
1
102952
; A185906: Weight array of A000007 (which has only one nonzero term and whose second accumulation array is the multiplication table for the positive integers), by antidiagonals. ; 1,-1,-1,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0 mov $2,$0 sub $0,3 mov $5,$2 mov $2,$0 lpb $2 mov $1,1 mov $3,$5 add $5,1 lpb $5 sub $1,1 sub $5,$3 lpe mov $0,$1 cmp $2,$4 sub $2,1 lpe mov $1,$0
lab06_skel_v2/task5(bonus).asm
andreeanec10/Calculatoare-Numerice-2
0
900
<gh_stars>0 ldi r20, 255 out 0x01, r20 ldi r19, 1 out 0x02, r19 ldi r19, 2 out 0x02, r19 ldi r19, 4 out 0x02, r19 ldi r19, 8 out 0x02, r19 ldi r19, 16 out 0x02, r19 ldi r19, 32 out 0x02, r19 ldi r19, 64 out 0x02, r19 ldi r19, 128 out 0x02, r19
programs/oeis/086/A086748.asm
karttu/loda
0
28514
; A086748: Numbers m such that when C(2k, k) == 1 (mod m) then k is necessarily even. ; 3,5,9,15,21,25,27,33,35,39,45,51,55,57,63,65,69,75,81,85,87,93,95,99,105,111,115,117,123,125,129,135,141,145,147,153,155,159,165,171,175,177,183,185,189,195,201,205,207,213,215,219,225,231,235,237,243,245 mov $7,$0 add $7,1 lpb $7,1 mov $0,$3 sub $7,1 sub $0,$7 mul $0,2 pow $0,2 mul $0,2 sub $0,1 pow $0,2 mul $0,2 mov $2,$0 mul $2,$0 mov $0,$2 mov $5,2 mov $6,2 mov $8,$2 lpb $0,1 add $0,7 div $0,2 mul $0,2 mod $0,14 sub $0,4 add $5,5 gcd $5,2 sub $0,$5 sub $6,$8 trn $6,1 add $6,$0 lpe mov $4,$6 add $4,1 add $1,$4 lpe
oeis/169/A169529.asm
neoneye/loda-programs
11
27563
; A169529: Number of reduced words of length n in Coxeter group on 36 generators S_i with relations (S_i)^2 = (S_i S_j)^34 = I. ; 1,36,1260,44100,1543500,54022500,1890787500,66177562500,2316214687500,81067514062500,2837362992187500,99307704726562500,3475769665429687500,121651938290039062500,4257817840151367187500,149023624405297851562500 add $0,1 mov $3,1 lpb $0 sub $0,1 add $2,$3 div $3,$2 mul $2,35 lpe mov $0,$2 div $0,35
pkgs/tools/yasm/src/modules/parsers/nasm/tests/long.asm
manggoguy/parsec-modified
2,151
168665
<reponame>manggoguy/parsec-modified mov [eax], long 0
chronix-server-query-language/src/main/antlr/CQLCF.g4
ChronixDB/chronix-server
275
2586
grammar CQLCF; cqlcf: chronixTypedFunctions; chronixTypedFunctions: chronixTypedFunction ((';')? chronixTypedFunction)*; chronixTypedFunction: chronixType '{' chronixfunction (';' chronixfunction)* '}'; chronixType: LOWERCASE_STRING; chronixfunction : name | name ':' parameter (',' parameter)* ; name: LOWERCASE_STRING; parameter: STRING_AND_NUMBERS_UPPERCASE; LOWERCASE_STRING : [a-z]+ ; STRING_AND_NUMBERS_UPPERCASE: [A-Z0-9.]+ ;
Transynther/x86/_processed/AVXALIGN/_ht_zr_/i9-9900K_12_0xca.log_21829_1432.asm
ljhsiun2/medusa
9
86904
.global s_prepare_buffers s_prepare_buffers: push %r10 push %r11 push %r12 push %r13 push %rax push %rbp push %rcx push %rdi push %rsi lea addresses_D_ht+0x22d4, %rax nop nop nop nop nop xor %r11, %r11 mov (%rax), %rbp nop nop and %rax, %rax lea addresses_A_ht+0x11254, %r12 clflush (%r12) sub %rax, %rax movw $0x6162, (%r12) nop nop nop nop nop add %rbp, %rbp lea addresses_UC_ht+0xe194, %r10 nop nop dec %r13 mov (%r10), %r11 nop nop sub $30750, %rbp lea addresses_UC_ht+0x1e5d4, %r11 nop nop cmp $45396, %r10 mov (%r11), %r13d nop nop add %rbp, %rbp lea addresses_normal_ht+0x3d14, %rsi lea addresses_normal_ht+0x6ad4, %rdi add $34876, %rbp mov $107, %rcx rep movsb lfence lea addresses_D_ht+0x20d4, %rsi lea addresses_D_ht+0xf238, %rdi clflush (%rsi) nop nop nop nop nop add %r12, %r12 mov $113, %rcx rep movsb nop nop nop nop add %r13, %r13 lea addresses_WT_ht+0x12dae, %rax and $64811, %rsi mov (%rax), %rdi nop nop nop nop sub %r11, %r11 lea addresses_normal_ht+0xb6c4, %rax nop nop nop nop nop cmp %r12, %r12 movl $0x61626364, (%rax) nop and $53224, %r10 lea addresses_WC_ht+0xd674, %rsi lea addresses_WC_ht+0x77c0, %rdi nop nop nop and $23244, %rax mov $76, %rcx rep movsl nop nop nop nop nop cmp $36200, %rsi pop %rsi pop %rdi pop %rcx pop %rbp pop %rax pop %r13 pop %r12 pop %r11 pop %r10 ret .global s_faulty_load s_faulty_load: push %r12 push %r13 push %r14 push %r15 push %r9 push %rax push %rbx // Store lea addresses_A+0x1e464, %r12 nop nop nop sub %r14, %r14 mov $0x5152535455565758, %r9 movq %r9, %xmm3 movups %xmm3, (%r12) nop sub $19951, %r12 // Store lea addresses_RW+0x9094, %r15 and $56661, %r13 mov $0x5152535455565758, %r9 movq %r9, %xmm4 vmovups %ymm4, (%r15) nop nop nop nop and $5958, %r13 // Store lea addresses_US+0xccd4, %r12 xor %rbx, %rbx mov $0x5152535455565758, %r14 movq %r14, (%r12) nop nop nop nop add $11504, %r12 // Store mov $0x24ad9400000000d4, %r9 nop nop nop nop add $57223, %rbx movb $0x51, (%r9) nop nop nop nop nop and %r14, %r14 // Store lea addresses_WT+0x48d4, %r14 nop nop nop add %r13, %r13 mov $0x5152535455565758, %r12 movq %r12, %xmm4 vmovups %ymm4, (%r14) and $47820, %r9 // Store lea addresses_US+0x40e7, %rbx nop cmp $14408, %rax mov $0x5152535455565758, %r15 movq %r15, (%rbx) // Exception!!! nop nop nop nop nop mov (0), %r14 nop nop nop nop xor $57550, %r14 // Faulty Load lea addresses_D+0x50d4, %rbx clflush (%rbx) dec %rax vmovntdqa (%rbx), %ymm6 vextracti128 $1, %ymm6, %xmm6 vpextrq $1, %xmm6, %r14 lea oracles, %r9 and $0xff, %r14 shlq $12, %r14 mov (%r9,%r14,1), %r14 pop %rbx pop %rax pop %r9 pop %r15 pop %r14 pop %r13 pop %r12 ret /* <gen_faulty_load> [REF] {'OP': 'LOAD', 'src': {'size': 2, 'NT': False, 'type': 'addresses_D', 'same': False, 'AVXalign': False, 'congruent': 0}} {'OP': 'STOR', 'dst': {'size': 16, 'NT': False, 'type': 'addresses_A', 'same': False, 'AVXalign': False, 'congruent': 2}} {'OP': 'STOR', 'dst': {'size': 32, 'NT': False, 'type': 'addresses_RW', 'same': False, 'AVXalign': False, 'congruent': 6}} {'OP': 'STOR', 'dst': {'size': 8, 'NT': False, 'type': 'addresses_US', 'same': False, 'AVXalign': False, 'congruent': 10}} {'OP': 'STOR', 'dst': {'size': 1, 'NT': True, 'type': 'addresses_NC', 'same': False, 'AVXalign': False, 'congruent': 9}} {'OP': 'STOR', 'dst': {'size': 32, 'NT': False, 'type': 'addresses_WT', 'same': False, 'AVXalign': False, 'congruent': 7}} {'OP': 'STOR', 'dst': {'size': 8, 'NT': False, 'type': 'addresses_US', 'same': False, 'AVXalign': False, 'congruent': 0}} [Faulty Load] {'OP': 'LOAD', 'src': {'size': 32, 'NT': True, 'type': 'addresses_D', 'same': True, 'AVXalign': False, 'congruent': 0}} <gen_prepare_buffer> {'OP': 'LOAD', 'src': {'size': 8, 'NT': False, 'type': 'addresses_D_ht', 'same': False, 'AVXalign': False, 'congruent': 9}} {'OP': 'STOR', 'dst': {'size': 2, 'NT': False, 'type': 'addresses_A_ht', 'same': False, 'AVXalign': False, 'congruent': 7}} {'OP': 'LOAD', 'src': {'size': 8, 'NT': True, 'type': 'addresses_UC_ht', 'same': False, 'AVXalign': False, 'congruent': 6}} {'OP': 'LOAD', 'src': {'size': 4, 'NT': False, 'type': 'addresses_UC_ht', 'same': False, 'AVXalign': False, 'congruent': 5}} {'OP': 'REPM', 'src': {'same': False, 'type': 'addresses_normal_ht', 'congruent': 5}, 'dst': {'same': False, 'type': 'addresses_normal_ht', 'congruent': 9}} {'OP': 'REPM', 'src': {'same': False, 'type': 'addresses_D_ht', 'congruent': 8}, 'dst': {'same': False, 'type': 'addresses_D_ht', 'congruent': 0}} {'OP': 'LOAD', 'src': {'size': 8, 'NT': False, 'type': 'addresses_WT_ht', 'same': False, 'AVXalign': False, 'congruent': 1}} {'OP': 'STOR', 'dst': {'size': 4, 'NT': False, 'type': 'addresses_normal_ht', 'same': True, 'AVXalign': False, 'congruent': 4}} {'OP': 'REPM', 'src': {'same': False, 'type': 'addresses_WC_ht', 'congruent': 4}, 'dst': {'same': False, 'type': 'addresses_WC_ht', 'congruent': 2}} {'00': 21827, '48': 2} 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 */
alchemy-core/src/main/antlr4/Filter.g4
RentTheRunway/alchemy
16
2837
<reponame>RentTheRunway/alchemy<gh_stars>10-100 grammar Filter; AND: ('&' | 'and'); OR: ('|' | 'or'); NOT: ('!' | 'not'); NUMBER: ('-' | '+')? [0-9]+; STRING: '"' ~('"')* '"'; BOOLEAN: ('true' | 'false'); IDENTIFIER: [A-Za-z_-][A-Za-z0-9_-]*; COMPARISON: ('<' | '>' | '=' | '<>' | '!=' | '<=' | '>='); WS: [ \r\n\t]+ -> skip; exp: term | exp OR term; term: factor | factor AND term; factor: '(' exp ')' | value | comparison | NOT factor; comparison: value COMPARISON value; constant: BOOLEAN | NUMBER | STRING; value: constant | IDENTIFIER;
utils/obb.adb
Lucretia/old_nehe_ada95
0
11795
<reponame>Lucretia/old_nehe_ada95<gh_stars>0 --------------------------------------------------------------------------------- -- Copyright 2004-2005 © <NAME> -- -- This code is to be used for tutorial purposes only. -- You may not redistribute this code in any form without my express permission. --------------------------------------------------------------------------------- with Ada.Unchecked_Conversion; with GL; use type GL.GLfloat; package body OBB is function Create return Object is Result : Object; begin Empty(Result); return Result; end Create; procedure Empty(Self : in out Object) is begin Self.Min := Vector3.Object'(Float'Last, Float'Last, Float'Last); Self.Max := Vector3.Object'(Float'First, Float'First, Float'First); end Empty; procedure Add(Self : in out Object; Vertex : in Vector3.Object) is begin if Vertex.X < Self.Min.X then Self.Min.X := Vertex.X; end if; if Vertex.Y < Self.Min.Y then Self.Min.Y := Vertex.Y; end if; if Vertex.Z < Self.Min.Z then Self.Min.Z := Vertex.Z; end if; if Vertex.X > Self.Max.X then Self.Max.X := Vertex.X; end if; if Vertex.Y > Self.Max.Y then Self.Max.Y := Vertex.Y; end if; if Vertex.Z > Self.Max.Z then Self.Max.Z := Vertex.Z; end if; end Add; procedure Render(Self : in Object) is subtype ColourRange is Integer range 1 .. 4; function GLint_To_GLenum is new Ada.Unchecked_Conversion(Source => GL.GLint, Target => GL.GLenum); type GLintArray is array (0 .. 1) of GL.GLint; type GLintArray_Ptr is access all GLintArray; function GLintArray_Ptr_To_GLintPtr is new Ada.Unchecked_Conversion(Source => GLintArray_Ptr, Target => GL.GLintPtr); Old_Polygon_Mode : aliased GLintArray; Old_Polygon_Mode_Ptr : GLintArray_Ptr := Old_Polygon_Mode'Unchecked_Access; begin -- Get the polygon mode. GL.glGetIntegerv(GL.GL_POLYGON_MODE, GLintArray_Ptr_To_GLintPtr(Old_Polygon_Mode_Ptr)); GL.glPolygonMode(GL.GL_FRONT_AND_BACK, GL.GL_LINE); GL.glDisable(GL.GL_LIGHTING); GL.glColor3f(0.0, 0.0, 1.0); GL.glBegin(GL.GL_QUADS); -- Back. GL.glVertex3f(GL.GLfloat(Self.Min.X), GL.GLfloat(Self.Min.Y), GL.GLfloat(Self.Min.Z)); GL.glVertex3f(GL.GLfloat(Self.Max.X), GL.GLfloat(Self.Min.Y), GL.GLfloat(Self.Min.Z)); GL.glVertex3f(GL.GLfloat(Self.Max.X), GL.GLfloat(Self.Max.Y), GL.GLfloat(Self.Min.Z)); GL.glVertex3f(GL.GLfloat(Self.Min.X), GL.GLfloat(Self.Max.Y), GL.GLfloat(Self.Min.Z)); -- Front. GL.glVertex3f(GL.GLfloat(Self.Min.X), GL.GLfloat(Self.Min.Y), GL.GLfloat(Self.Max.Z)); GL.glVertex3f(GL.GLfloat(Self.Max.X), GL.GLfloat(Self.Min.Y), GL.GLfloat(Self.Max.Z)); GL.glVertex3f(GL.GLfloat(Self.Max.X), GL.GLfloat(Self.Max.Y), GL.GLfloat(Self.Max.Z)); GL.glVertex3f(GL.GLfloat(Self.Min.X), GL.GLfloat(Self.Max.Y), GL.GLfloat(Self.Max.Z)); -- Left. GL.glVertex3f(GL.GLfloat(Self.Min.X), GL.GLfloat(Self.Min.Y), GL.GLfloat(Self.Max.Z)); GL.glVertex3f(GL.GLfloat(Self.Min.X), GL.GLfloat(Self.Max.Y), GL.GLfloat(Self.Max.Z)); GL.glVertex3f(GL.GLfloat(Self.Min.X), GL.GLfloat(Self.Max.Y), GL.GLfloat(Self.Min.Z)); GL.glVertex3f(GL.GLfloat(Self.Min.X), GL.GLfloat(Self.Min.Y), GL.GLfloat(Self.Min.Z)); -- Right. GL.glVertex3f(GL.GLfloat(Self.Max.X), GL.GLfloat(Self.Min.Y), GL.GLfloat(Self.Max.Z)); GL.glVertex3f(GL.GLfloat(Self.Max.X), GL.GLfloat(Self.Max.Y), GL.GLfloat(Self.Max.Z)); GL.glVertex3f(GL.GLfloat(Self.Max.X), GL.GLfloat(Self.Max.Y), GL.GLfloat(Self.Min.Z)); GL.glVertex3f(GL.GLfloat(Self.Max.X), GL.GLfloat(Self.Min.Y), GL.GLfloat(Self.Min.Z)); -- Top. GL.glVertex3f(GL.GLfloat(Self.Min.X), GL.GLfloat(Self.Max.Y), GL.GLfloat(Self.Max.Z)); GL.glVertex3f(GL.GLfloat(Self.Min.X), GL.GLfloat(Self.Max.Y), GL.GLfloat(Self.Min.Z)); GL.glVertex3f(GL.GLfloat(Self.Max.X), GL.GLfloat(Self.Max.Y), GL.GLfloat(Self.Min.Z)); GL.glVertex3f(GL.GLfloat(Self.Max.X), GL.GLfloat(Self.Max.Y), GL.GLfloat(Self.Max.Z)); -- Bottom. GL.glVertex3f(GL.GLfloat(Self.Min.X), GL.GLfloat(Self.Min.Y), GL.GLfloat(Self.Max.Z)); GL.glVertex3f(GL.GLfloat(Self.Min.X), GL.GLfloat(Self.Min.Y), GL.GLfloat(Self.Min.Z)); GL.glVertex3f(GL.GLfloat(Self.Max.X), GL.GLfloat(Self.Min.Y), GL.GLfloat(Self.Min.Z)); GL.glVertex3f(GL.GLfloat(Self.Max.X), GL.GLfloat(Self.Min.Y), GL.GLfloat(Self.Max.Z)); GL.glEnd; -- Restore the polygon mode. GL.glPolygonMode(GL.GL_FRONT, GLint_To_GLenum(Old_Polygon_Mode(0))); GL.glPolygonMode(GL.GL_BACK, GLint_To_GLenum(Old_Polygon_Mode(1))); GL.glEnable(GL.GL_LIGHTING); end Render; end OBB;
_tests/trconvert/antlr3/C.g4
SKalt/Domemtech.Trash
16
5380
/** ANSI C ANTLR v3 grammar Translated from Jutta Degener's 1995 ANSI C yacc grammar by <NAME> July 2006. The lexical rules were taken from the Java grammar. Jutta says: "In 1985, <NAME> published his Yacc grammar (which is accompanied by a matching Lex specification) for the April 30, 1985 draft version of the ANSI C standard. <NAME> reposted it to net.sources in 1987; that original, as mentioned in the answer to question 17.25 of the comp.lang.c FAQ, can be ftp'ed from ftp.uu.net, file usenet/net.sources/ansi.c.grammar.Z. I intend to keep this version as close to the current C Standard grammar as possible; please let me know if you discover discrepancies. Jutta Degener, 1995" Generally speaking, you need symbol table info to parse C; typedefs define types and then IDENTIFIERS are either types or plain IDs. I'm doing the min necessary here tracking only type names. This is a good example of the global scope (called Symbols). Every rule that declares its usage of Symbols pushes a new copy on the stack effectively creating a new symbol scope. Also note rule declaration declares a rule scope that lets any invoked rule see isTypedef boolean. It's much easier than passing that info down as parameters. Very clean. Rule direct_declarator can then easily determine whether the IDENTIFIER should be declared as a type name. I have only tested this on a single file, though it is 3500 lines. This grammar requires ANTLR v3.0.1 or higher. <NAME> July 2006 */ grammar C; scope Symbols { Set types; // only track types in order to get parser working } @header { import java.util.Set; import java.util.HashSet; } @members { boolean isTypeName(String name) { for (int i = Symbols_stack.size()-1; i>=0; i--) { Symbols_scope scope = (Symbols_scope)Symbols_stack.get(i); if ( scope.types.contains(name) ) { return true; } } return false; } } translation_unit // entire file is a scope @init { $Symbols::types = new HashSet(); } : external_declaration+ ; /** Either a function definition or any other kind of C decl/def. * The LL(*) analysis algorithm fails to deal with this due to * recursion in the declarator rules. I'm putting in a * manual predicate here so that we don't backtrack over * the entire function. Further, you get a better error * as errors within the function itself don't make it fail * to predict that it's a function. Weird errors previously. * Remember: the goal is to avoid backtrack like the plague * because it makes debugging, actions, and errors harder. * * Note that k=1 results in a much smaller predictor for the * fixed lookahead; k=2 made a few extra thousand lines. ;) * I'll have to optimize that in the future. */ external_declaration : function_definition | declaration ; function_definition // put parameters and locals into same scope for now @init { $Symbols::types = new HashSet(); } : declaration_specifiers? declarator ( declaration+ compound_statement // K&R style | compound_statement // ANSI style ) ; declaration @init { $declaration::isTypedef = false; } : 'typedef' declaration_specifiers? {$declaration::isTypedef=true;} init_declarator_list ';' // special case, looking for typedef | declaration_specifiers init_declarator_list? ';' ; declaration_specifiers : ( storage_class_specifier | type_specifier | type_qualifier )+ ; init_declarator_list : init_declarator (',' init_declarator)* ; init_declarator : declarator ('=' initializer)? ; storage_class_specifier : 'extern' | 'static' | 'auto' | 'register' ; type_specifier : 'void' | 'char' | 'short' | 'int' | 'long' | 'float' | 'double' | 'signed' | 'unsigned' | struct_or_union_specifier | enum_specifier | type_id ; type_id : {isTypeName(input.LT(1).getText())}? IDENTIFIER // {System.out.println($IDENTIFIER.text+" is a type");} ; struct_or_union_specifier // structs are scopes @init { $Symbols::types = new HashSet(); } : struct_or_union IDENTIFIER? '{' struct_declaration_list '}' | struct_or_union IDENTIFIER ; struct_or_union : 'struct' | 'union' ; struct_declaration_list : struct_declaration+ ; struct_declaration : specifier_qualifier_list struct_declarator_list ';' ; specifier_qualifier_list : ( type_qualifier | type_specifier )+ ; struct_declarator_list : struct_declarator (',' struct_declarator)* ; struct_declarator : declarator (':' constant_expression)? | ':' constant_expression ; enum_specifier : 'enum' '{' enumerator_list '}' | 'enum' IDENTIFIER '{' enumerator_list '}' | 'enum' IDENTIFIER ; enumerator_list : enumerator (',' enumerator)* ; enumerator : IDENTIFIER ('=' constant_expression)? ; type_qualifier : 'const' | 'volatile' ; declarator : pointer? direct_declarator | pointer ; direct_declarator : ( IDENTIFIER { if ($declaration.size()>0&&$declaration::isTypedef) { $Symbols::types.add($IDENTIFIER.text); System.out.println("define type "+$IDENTIFIER.text); } } | '(' declarator ')' ) declarator_suffix* ; declarator_suffix : '[' constant_expression ']' | '[' ']' | '(' parameter_type_list ')' | '(' identifier_list ')' | '(' ')' ; pointer : '*' type_qualifier+ pointer? | '*' pointer | '*' ; parameter_type_list : parameter_list (',' '...')? ; parameter_list : parameter_declaration (',' parameter_declaration)* ; parameter_declaration : declaration_specifiers (declarator|abstract_declarator)* ; identifier_list : IDENTIFIER (',' IDENTIFIER)* ; type_name : specifier_qualifier_list abstract_declarator? ; abstract_declarator : pointer direct_abstract_declarator? | direct_abstract_declarator ; direct_abstract_declarator : ( '(' abstract_declarator ')' | abstract_declarator_suffix ) abstract_declarator_suffix* ; abstract_declarator_suffix : '[' ']' | '[' constant_expression ']' | '(' ')' | '(' parameter_type_list ')' ; initializer : assignment_expression | '{' initializer_list ','? '}' ; initializer_list : initializer (',' initializer)* ; // E x p r e s s i o n s argument_expression_list : assignment_expression (',' assignment_expression)* ; additive_expression : (multiplicative_expression) ('+' multiplicative_expression | '-' multiplicative_expression)* ; multiplicative_expression : (cast_expression) ('*' cast_expression | '/' cast_expression | '%' cast_expression)* ; cast_expression : '(' type_name ')' cast_expression | unary_expression ; unary_expression : postfix_expression | '++' unary_expression | '--' unary_expression | unary_operator cast_expression | 'sizeof' unary_expression | 'sizeof' '(' type_name ')' ; postfix_expression : primary_expression ( '[' expression ']' | '(' ')' | '(' argument_expression_list ')' | '.' IDENTIFIER | '->' IDENTIFIER | '++' | '--' )* ; unary_operator : '&' | '*' | '+' | '-' | '~' | '!' ; primary_expression : IDENTIFIER | constant | '(' expression ')' ; constant : HEX_LITERAL | OCTAL_LITERAL | DECIMAL_LITERAL | CHARACTER_LITERAL | STRING_LITERAL | FLOATING_POINT_LITERAL ; ///// expression : assignment_expression (',' assignment_expression)* ; constant_expression : conditional_expression ; assignment_expression : lvalue assignment_operator assignment_expression | conditional_expression ; lvalue : unary_expression ; assignment_operator : '=' | '*=' | '/=' | '%=' | '+=' | '-=' | '<<=' | '>>=' | '&=' | '^=' | '|=' ; conditional_expression : logical_or_expression ('?' expression ':' conditional_expression)? ; logical_or_expression : logical_and_expression ('||' logical_and_expression)* ; logical_and_expression : inclusive_or_expression ('&&' inclusive_or_expression)* ; inclusive_or_expression : exclusive_or_expression ('|' exclusive_or_expression)* ; exclusive_or_expression : and_expression ('^' and_expression)* ; and_expression : equality_expression ('&' equality_expression)* ; equality_expression : relational_expression (('=='|'!=') relational_expression)* ; relational_expression : shift_expression (('<'|'>'|'<='|'>=') shift_expression)* ; shift_expression : additive_expression (('<<'|'>>') additive_expression)* ; // S t a t e m e n t s statement : labeled_statement | compound_statement | expression_statement | selection_statement | iteration_statement | jump_statement ; labeled_statement : IDENTIFIER ':' statement | 'case' constant_expression ':' statement | 'default' ':' statement ; compound_statement // blocks have a scope of symbols @init { $Symbols::types = new HashSet(); } : '{' declaration* statement_list? '}' ; statement_list : statement+ ; expression_statement : ';' | expression ';' ; selection_statement : 'if' '(' expression ')' statement (options { backtrack=false;}:'else' statement)? | 'switch' '(' expression ')' statement ; iteration_statement : 'while' '(' expression ')' statement | 'do' statement 'while' '(' expression ')' ';' | 'for' '(' expression_statement expression_statement expression? ')' statement ; jump_statement : 'goto' IDENTIFIER ';' | 'continue' ';' | 'break' ';' | 'return' ';' | 'return' expression ';' ; IDENTIFIER : LETTER (LETTER|'0'..'9')* ; fragment LETTER : '$' | 'A'..'Z' | 'a'..'z' | '_' ; CHARACTER_LITERAL : '\'' ( EscapeSequence | ~('\''|'\\') ) '\'' ; STRING_LITERAL : '"' ( EscapeSequence | ~('\\'|'"') )* '"' ; HEX_LITERAL : '0' ('x'|'X') HexDigit+ IntegerTypeSuffix? ; DECIMAL_LITERAL : ('0' | '1'..'9' '0'..'9'*) IntegerTypeSuffix? ; OCTAL_LITERAL : '0' ('0'..'7')+ IntegerTypeSuffix? ; fragment HexDigit : ('0'..'9'|'a'..'f'|'A'..'F') ; fragment IntegerTypeSuffix : ('u'|'U')? ('l'|'L') | ('u'|'U') ('l'|'L')? ; FLOATING_POINT_LITERAL : ('0'..'9')+ '.' ('0'..'9')* Exponent? FloatTypeSuffix? | '.' ('0'..'9')+ Exponent? FloatTypeSuffix? | ('0'..'9')+ Exponent FloatTypeSuffix? | ('0'..'9')+ Exponent? FloatTypeSuffix ; fragment Exponent : ('e'|'E') ('+'|'-')? ('0'..'9')+ ; fragment FloatTypeSuffix : ('f'|'F'|'d'|'D') ; fragment EscapeSequence : '\\' ('b'|'t'|'n'|'f'|'r'|'\"'|'\''|'\\') | OctalEscape ; fragment OctalEscape : '\\' ('0'..'3') ('0'..'7') ('0'..'7') | '\\' ('0'..'7') ('0'..'7') | '\\' ('0'..'7') ; fragment UnicodeEscape : '\\' 'u' HexDigit HexDigit HexDigit HexDigit ; WS : (' '|'\r'|'\t'|'\u000C'|'\n') {$channel=HIDDEN;} ; COMMENT : '/*' ( . ) * ? '*/' {$channel=HIDDEN;} ; LINE_COMMENT : '//' ~('\n'|'\r')* '\r'? '\n' {$channel=HIDDEN;} ; // ignore #line info for now LINE_COMMAND : '#' ~('\n'|'\r')* '\r'? '\n' {$channel=HIDDEN;} ;
nasm-8086-assembly-course/0x02-input/input.asm
ailtonbsj/buffer-overflow-studies
0
21296
segment .data LF equ 0x0a ; Line feed CR equ 0x0d ; Carriage return NULL equ 0x00 ; NULL \0 character SYS_CALL equ 0x80 ; OS interrupt vector ; On EAX SYS_EXIT equ 0x01 ; Finish program code SYS_READ equ 0x03 ; Read data code SYS_WRITE equ 0x04 ; Write data code ; On EBX RET_EXIT equ 0x00 ; Finished without error STD_IN equ 0x00 ; Standard input code STD_OUT equ 0x01 ; Standard output code section .data msg db "Entre com seu nome:", LF, CR tam equ $- msg section .bss nome resb 1 section .text global _start _start: ; print text to stdout mov eax, SYS_WRITE mov ebx, STD_OUT mov ecx, msg mov edx, tam int SYS_CALL ; get text from stdin mov eax, SYS_READ mov ebx, STD_IN mov ecx, nome mov edx, 0x0a ; length of input stream int SYS_CALL ; echo input to stdout mov eax, SYS_WRITE mov ebx, STD_OUT mov ecx, nome mov edx, 0x0a int SYS_CALL ; finish program mov eax, SYS_EXIT mov ebx, RET_EXIT int SYS_CALL
testsuite/tests/NA17-007__copyright/copyright-ok-8.adb
AdaCore/style_checker
2
21374
<reponame>AdaCore/style_checker ------------------------------------------------------------------------- -- Copyright (C) 2000-2006, Universidad de Atlantis, TIERRA package Foo is end Foo;
oeis/171/A171219.asm
neoneye/loda-programs
11
172980
<reponame>neoneye/loda-programs ; A171219: A138101(n)+A168142(n). ; Submitted by <NAME> ; 5,5,21,21,21,21,21,21,21,21,57,57,57,57,57,57,57,57,57,57,57,57,57,57,57,57,57,57,121,121,121,121,121,121,121,121,121,121,121,121,121,121,121,121,121,121,121,121,121,121,121,121,121,121,121,121,121,121,121 mov $1,$0 mul $0,2 seq $1,168142 ; Count downwards from 2, then from 8, then from 18, then from ... 2*k^2, k>=1. mul $1,2 add $0,$1 add $0,1
engine/battle/ai/move.asm
AtmaBuster/pokeplat-gen2
6
9429
<filename>engine/battle/ai/move.asm AIChooseMove: ; Score each move in wEnemyMonMoves starting from wBuffer1. Lower is better. ; Pick the move with the lowest score. ; Wildmons attack at random. ld a, [wBattleMode] dec a ret z ld a, [wLinkMode] and a ret nz ; No use picking a move if there's no choice. farcall CheckEnemyLockedIn ret nz ; The default score is 20. Unusable moves are given a score of 80. ld a, 20 ld hl, wBuffer1 ld [hli], a ld [hli], a ld [hli], a ld [hl], a ; Don't pick disabled moves. ld a, [wEnemyDisabledMove] and a jr z, .CheckTaunt ld hl, wEnemyMonMoves ld c, 0 .CheckDisabledMove: cp [hl] jr z, .ScoreDisabledMove inc c inc hl jr .CheckDisabledMove .ScoreDisabledMove: ld hl, wBuffer1 ld b, 0 add hl, bc ld [hl], 80 ; Don't pick taunted moves .CheckTaunt ld a, [wEnemySubStatus6] bit SUBSTATUS_TAUNT, a jr z, .CheckTorment ld hl, wEnemyMonMoves ld c, 0 .CheckTauntMove: ld a, c cp 4 jr z, .CheckTorment ld a, [hli] and a jr z, .CheckTorment inc c call IsStatusMove jr nc, .CheckTauntMove .ScoreTauntedMove: push hl ld hl, wBuffer1 ld b, 0 dec c add hl, bc inc c ld [hl], 80 pop hl inc c jr .CheckTauntMove .CheckTorment ld a, [wEnemySubStatus5] bit SUBSTATUS_TORMENT, a jr z, .CheckImprison ld hl, wEnemyMonMoves ld c, 0 .CheckTormentMove: ld a, c cp 4 jr z, .CheckImprison ld a, [hli] and a jr z, .CheckImprison ld b, a ld a, [wLastEnemyCounterMove] inc c cp b jr nz, .CheckTormentMove .ScoreTormentMove: push hl ld hl, wBuffer1 ld b, 0 dec c add hl, bc inc c ld [hl], 80 pop hl inc c jr .CheckTormentMove .CheckImprison ld a, [wPlayerSubStatus2] bit SUBSTATUS_IMPRISON, a jr z, .CheckPP ld hl, wEnemyMonMoves ld c, 0 .CheckImprisonMove: ld a, c cp 4 jr z, .CheckPP ld a, [hli] and a jr z, .CheckPP inc c call CheckEnemyMoveImprisoned jr nc, .CheckImprisonMove .ScoreImprisonMove: push hl ld hl, wBuffer1 ld b, 0 dec c add hl, bc inc c ld [hl], 80 pop hl inc c jr .CheckImprisonMove ; Don't pick moves with 0 PP. .CheckPP: ld hl, wBuffer1 - 1 ld de, wEnemyMonPP ld b, 0 .CheckMovePP: inc b ld a, b cp wEnemyMonMovesEnd - wEnemyMonMoves + 1 jr z, .ApplyLayers inc hl ld a, [de] inc de and PP_MASK jr nz, .CheckMovePP ld [hl], 80 jr .CheckMovePP ; Apply AI scoring layers depending on the trainer class. .ApplyLayers: ld hl, TrainerClassAttributes + TRNATTR_AI_MOVE_WEIGHTS ; If we have a battle in BattleTower just load the Attributes of the first trainer class in wTrainerClass (Falkner) ; so we have always the same AI, regardless of the loaded class of trainer ld a, [wInBattleTowerBattle] bit 0, a jr nz, .battle_tower_skip ld a, [wTrainerClass] dec a ld bc, 7 ; Trainer2AI - Trainer1AI call AddNTimes .battle_tower_skip lb bc, CHECK_FLAG, 0 push bc push hl .CheckLayer: pop hl pop bc ld a, c cp 16 ; up to 16 scoring layers jr z, .DecrementScores push bc ld d, BANK(TrainerClassAttributes) predef SmallFarFlagAction ld d, c pop bc inc c push bc push hl ld a, d and a jr z, .CheckLayer ld hl, AIScoringPointers dec c ld b, 0 add hl, bc add hl, bc ld a, [hli] ld h, [hl] ld l, a ld a, BANK(AIScoring) call FarCall_hl jr .CheckLayer ; Decrement the scores of all moves one by one until one reaches 0. .DecrementScores: ld hl, wBuffer1 ld de, wEnemyMonMoves ld c, wEnemyMonMovesEnd - wEnemyMonMoves .DecrementNextScore: ; If the enemy has no moves, this will infinite. ld a, [de] inc de and a jr z, .DecrementScores ; We are done whenever a score reaches 0 dec [hl] jr z, .PickLowestScoreMoves ; If we just decremented the fourth move's score, go back to the first move inc hl dec c jr z, .DecrementScores jr .DecrementNextScore ; In order to avoid bias towards the moves located first in memory, increment the scores ; that were decremented one more time than the rest (in case there was a tie). ; This means that the minimum score will be 1. .PickLowestScoreMoves: ld a, c .move_loop inc [hl] dec hl inc a cp NUM_MOVES + 1 jr nz, .move_loop ld hl, wBuffer1 ld de, wEnemyMonMoves ld c, NUM_MOVES ; Give a score of 0 to a blank move .loop2 ld a, [de] and a jr nz, .skip_load ld [hl], a ; Disregard the move if its score is not 1 .skip_load ld a, [hl] dec a jr z, .keep xor a ld [hli], a jr .after_toss .keep ld a, [de] ld [hli], a .after_toss inc de dec c jr nz, .loop2 ; Randomly choose one of the moves with a score of 1 .ChooseMove: ld hl, wBuffer1 call Random maskbits NUM_MOVES ld c, a ld b, 0 add hl, bc ld a, [hl] and a jr z, .ChooseMove ld [wCurEnemyMove], a ld a, c ld [wCurEnemyMoveNum], a ret AIScoringPointers: ; entries correspond to AI_* constants dw AI_Basic dw AI_Setup dw AI_Types dw AI_Offensive dw AI_Smart dw AI_Opportunist dw AI_Aggressive dw AI_Cautious dw AI_Status dw AI_Risky dw AI_None dw AI_None dw AI_None dw AI_None dw AI_None dw AI_None CheckEnemyMoveImprisoned: push hl push bc ld b, a ld c, 4 ld hl, wBattleMonMoves .loop ld a, [hli] cp b jr z, .hit dec c jr nz, .loop pop bc pop hl and a ret .hit pop bc pop hl scf ret
alloy4fun_models/trashltl/models/3/TXWGhCJrD5sSkCSrL.als
Kaixi26/org.alloytools.alloy
0
4453
open main pred idTXWGhCJrD5sSkCSrL_prop4 { some f:File | eventually f in Trash } pred __repair { idTXWGhCJrD5sSkCSrL_prop4 } check __repair { idTXWGhCJrD5sSkCSrL_prop4 <=> prop4o }
oeis/117/A117255.asm
neoneye/loda-programs
11
85806
; A117255: Column 0 of triangle A117254. ; Submitted by <NAME> ; 1,1,-6,224,-39424,30277632,-98180268032,1321338098679808,-73064711504598663168,16493270769791857518968832,-15132641904367108441083979235328,56258298143912014448000446346897129472,-845539117695226477286180063077230730209656832 mul $0,2 mov $1,1 mov $2,1 mov $3,$0 mov $4,-1 lpb $3 mul $1,$2 mul $1,$4 mul $2,4 sub $3,2 sub $5,1 div $1,$5 add $4,4 lpe mov $0,$1
programs/oeis/016/A016263.asm
neoneye/loda
22
101271
<reponame>neoneye/loda ; A016263: Expansion of 1/((1-x)(1-9x)(1-12x)). ; 1,22,355,5080,68341,886522,11236135,140214460,1731001081,21207861022,258416964715,3136307268640,37953420452221,458300644483522,5525344125314095,66535757027375620,800513732040965761 lpb $0 mov $2,$0 sub $0,1 seq $2,16191 ; Expansion of 1/((1-9x)*(1-12x)). add $1,$2 lpe add $1,1 mov $0,$1
src/test/resources/framework_specifications/TestSpecificationFactoryLexer.g4
google/polymorphicDSL
3
2977
lexer grammar TestSpecificationFactoryLexer ; import GherkinCommonLexer, PdslFrameworkSpecificationLexer ; tokens { END } GIVEN_SPECIFIC_GRAMMAR : GHERKIN_STEP_KEYWORD 'the Grammar being used is '; GIVEN_SPECIFIC_SUBGRAMMAR : GHERKIN_STEP_KEYWORD 'the Subgrammar being used is '; THEN_TEST_SPECIFICATION_FAILS_DUE_TO_MISSING_SCENARIO : GHERKIN_STEP_KEYWORD 'an error occurs because there is no scenario' END ; THEN_TEST_SPECIFICATION_FAILS_BECAUSE_OF_MISSING_STEP_BODY : GHERKIN_STEP_KEYWORD 'an error occurs because there is no step body' END ; GIVEN_NONEXISTENT_URL : GHERKIN_STEP_KEYWORD 'a URL to a resource that does not exist' END ; THEN_NO_SUCH_RESOURCE_ERROR : GHERKIN_STEP_KEYWORD 'an error occurs because there is no such resource' END ; TEST_SPECIFICATION_TOTAL_PHRASES_START : GHERKIN_STEP_KEYWORD 'the test specification has ' ; TEST_SPECIFICATION_TOTAL_PHRASES_END : ' total phrase' 's'? END ; TEST_SPECIFICATION_MAY_BE_PRODUCED : GHERKIN_STEP_KEYWORD 'a Test Specification is ' 'NOT '? 'produced' END ; TEST_SPECIFICATION_IS_PROCESSED_BY_THE_FACTORY : GHERKIN_STEP_KEYWORD 'the test resource is processed by the Test Specification Factory' END ;
_anim/obj5F.asm
NatsumiFox/AMPS-Sonic-1-2005
2
85517
<filename>_anim/obj5F.asm ; --------------------------------------------------------------------------- ; Animation script - Bomb enemy ; --------------------------------------------------------------------------- dc.w byte_11C12-Ani_obj5F dc.w byte_11C16-Ani_obj5F dc.w byte_11C1C-Ani_obj5F dc.w byte_11C20-Ani_obj5F dc.w byte_11C24-Ani_obj5F byte_11C12: dc.b $13, 1, 0, $FF byte_11C16: dc.b $13, 5, 4, 3, 2, $FF byte_11C1C: dc.b $13, 7, 6, $FF byte_11C20: dc.b 3, 8, 9, $FF byte_11C24: dc.b 3, $A, $B, $FF even
src/Categories/Category/Cartesian/Bundle.agda
Trebor-Huang/agda-categories
279
11451
<reponame>Trebor-Huang/agda-categories {-# OPTIONS --without-K --safe #-} -- Bundled version of a Cartesian Category module Categories.Category.Cartesian.Bundle where open import Level open import Categories.Category.Core using (Category) open import Categories.Category.Cartesian using (Cartesian) open import Categories.Category.Cartesian.Monoidal using (module CartesianMonoidal) open import Categories.Category.Monoidal using (MonoidalCategory) record CartesianCategory o ℓ e : Set (suc (o ⊔ ℓ ⊔ e)) where field U : Category o ℓ e -- U for underlying cartesian : Cartesian U open Category U public open Cartesian cartesian public monoidalCategory : MonoidalCategory o ℓ e monoidalCategory = record { U = U ; monoidal = CartesianMonoidal.monoidal cartesian }
adahw4/market.adb
jamalakhaligova/ADA
0
4209
<filename>adahw4/market.adb with Ada.Text_IO,Ada.Numerics.Discrete_Random,Ada.Calendar; use Ada.Text_IO; procedure Market is subtype Index is Positive range 1..10; package randomPos is new Ada.Numerics.Discrete_Random(Index); infected_count : Natural := 0; type Position is record x: Natural; y: Natural; end record; type Direction is (left,right,up,down); package randomDir is new Ada.Numerics.Discrete_Random(Direction); protected Generator is procedure Init; function GetRandPos return Position; function GetRandDir return Direction; private k:randomPos.Generator; l:randomDir.Generator; end Generator; protected body Generator is procedure Init is begin randomPos.Reset(k); randomDir.Reset(l); end Init; function GetRandPos return Position is x:Index; y:Index; begin x:=randomPos.Random(k); y:=randomPos.Random(k); return (x,y); end GetRandPos; function GetRandDir return Direction is begin return randomDir.Random(l); end GetRandDir; end Generator; protected Monitor is procedure Print(s:String); end Monitor; protected body Monitor is procedure Print(s:String) is begin Put_Line(s); end Print; end Monitor; type Barr is array (Natural range <>,Natural range <>) of Boolean; protected Area is procedure Init; function inArea(pos:Position) return Boolean; procedure infectCell(pos:Position); function isInfected(pos:Position) return Boolean; function getInfectedPerc return Natural; private a : Barr(1..10,1..10); end Area; protected body Area is procedure Init is begin for i in 1..10 loop for j in 1..10 loop a(i,j):=False; --no covid at first end loop; end loop; end Init; procedure infectCell(pos:Position) is begin a(pos.x,pos.y):=True; end infectCell; function isInfected(pos:Position) return Boolean is begin return a(pos.x,pos.y); end isInfected; function inArea(pos:Position) return Boolean is begin if (pos.x>=1 and then pos.x<=10 and then pos.y>=1 and then pos.y<=10) then return True; else return False; end if; end inArea; function getInfectedPerc return Natural is cnt : Natural:=0; begin for i in 1..10 loop for j in 1..10 loop if a(i,j) then cnt:=cnt+1; end if; end loop; end loop; return cnt; end getInfectedPerc; end Area; type Pstr is access String; task type Customer(name : Pstr ; is_infected : Boolean); task Organizer is entry Create; end Organizer; task body Customer is pos:Position:=Generator.GetRandPos; movement:Natural:=0; is_sick : Boolean := is_infected; procedure move is tmp:Position; dir:Direction; begin loop tmp:=pos; dir:=Generator.GetRandDir; case dir is when left => tmp.x:=pos.x-1; when right => tmp.x:=pos.x+1; when up => tmp.y:=pos.y-1; when down => tmp.y:=pos.y+1; end case; exit when Area.inArea(tmp); end loop; pos:=tmp; end move; begin while movement<4 loop --if not Organizer'Callable then -- exit; --end if; --Monitor.Print("Current position : " & pos.x'Image & " , "& pos.y'Image); if is_sick then Area.infectCell(pos); --Monitor.Print("One more cell infected"); end if; if Area.isInfected(pos) then is_sick := True; end if; movement:=movement+1; delay 0.5; move; end loop; if is_sick then Monitor.Print(name.all &" named customer has infected"); infected_count := infected_count + 1; end if; if Organizer'Callable then Monitor.Print( name.all &" named customer finished"); -- this means 4 movements so 2 mins done Organizer.Create; end if; end Customer; type CustomerPtr is access Customer; task body Organizer is start : Ada.Calendar.Time; a,b,c,d,e,tmp: CustomerPtr; total_customers : Natural := 5; begin Generator.Init; Area.Init; a:=new Customer(new String'("c1"),True); b:=new Customer(new String'("c2"),True); c:=new Customer(new String'("c3"),True); d:=new Customer(new String'("c4"),True); e:=new Customer(new String'("c5"),True); start:=Ada.Calendar.Clock; loop if Ada.Calendar."-"( Ada.Calendar.Clock, start ) >=60.0 then exit; end if; select accept Create do tmp:=new Customer(new String'("cus "& total_customers'Image),False); Monitor.Print("Created new customer"); total_customers := total_customers + 1; end Create; end select; end loop; Monitor.Print("Percentage of territory is infected : " & Area.getInfectedPerc'Image); --Monitor.Print("Infected customers : " & infected_count'Image); --Monitor.Print("Total customers : " & total_customers'Image); Monitor.Print("Out of "& total_customers'Image &" customers, "& infected_count'Image & " got infected."); --exit; end Organizer; begin -- Insert code here. null; end Market;
Transynther/x86/_processed/NONE/_xt_/i7-7700_9_0xca_notsx.log_2_588.asm
ljhsiun2/medusa
9
244210
.global s_prepare_buffers s_prepare_buffers: push %r14 push %r9 push %rax push %rbx push %rcx push %rdi push %rdx push %rsi lea addresses_UC_ht+0x123e, %rax and $47958, %r9 mov $0x6162636465666768, %r14 movq %r14, %xmm7 movups %xmm7, (%rax) nop nop nop sub %rsi, %rsi lea addresses_A_ht+0x11689, %rsi lea addresses_WT_ht+0x241c, %rdi clflush (%rsi) cmp %rdx, %rdx mov $68, %rcx rep movsq nop nop nop nop nop cmp %r9, %r9 lea addresses_D_ht+0x1c6b4, %rsi lea addresses_normal_ht+0x12404, %rdi nop nop nop nop nop xor %rbx, %rbx mov $75, %rcx rep movsw nop sub %r14, %r14 lea addresses_UC_ht+0x131df, %rsi lea addresses_normal_ht+0x55e8, %rdi clflush (%rdi) nop and %r14, %r14 mov $23, %rcx rep movsq nop nop nop xor $8774, %rdi lea addresses_WT_ht+0x1d3c4, %rcx clflush (%rcx) nop nop cmp %rdx, %rdx mov (%rcx), %r9 nop add $24322, %rcx pop %rsi pop %rdx pop %rdi pop %rcx pop %rbx pop %rax pop %r9 pop %r14 ret .global s_faulty_load s_faulty_load: push %r12 push %r14 push %r9 push %rbp push %rbx push %rcx push %rsi // Store mov $0x210af9000000075c, %rsi nop nop nop nop nop dec %r14 movb $0x51, (%rsi) nop and $50590, %r9 // Store lea addresses_normal+0xec04, %rcx sub %r14, %r14 mov $0x5152535455565758, %r12 movq %r12, %xmm3 movups %xmm3, (%rcx) nop nop nop xor $25679, %r14 // Load lea addresses_UC+0x1aa84, %r9 nop nop nop nop nop sub $101, %rbx vmovups (%r9), %ymm7 vextracti128 $0, %ymm7, %xmm7 vpextrq $0, %xmm7, %rsi nop and %rcx, %rcx // Store lea addresses_WC+0x17684, %rbx nop nop nop nop cmp %r12, %r12 movw $0x5152, (%rbx) xor %rcx, %rcx // Store lea addresses_US+0x2c54, %rbp nop and $61921, %rsi movw $0x5152, (%rbp) nop nop nop nop sub $33937, %rcx // Faulty Load lea addresses_PSE+0xbe84, %rbx nop xor $30441, %rsi vmovups (%rbx), %ymm2 vextracti128 $0, %ymm2, %xmm2 vpextrq $1, %xmm2, %rbp lea oracles, %rcx and $0xff, %rbp shlq $12, %rbp mov (%rcx,%rbp,1), %rbp pop %rsi pop %rcx pop %rbx pop %rbp pop %r9 pop %r14 pop %r12 ret /* <gen_faulty_load> [REF] {'src': {'NT': False, 'AVXalign': False, 'size': 16, 'congruent': 0, 'same': False, 'type': 'addresses_PSE'}, 'OP': 'LOAD'} {'dst': {'NT': False, 'AVXalign': True, 'size': 1, 'congruent': 2, 'same': False, 'type': 'addresses_NC'}, 'OP': 'STOR'} {'dst': {'NT': False, 'AVXalign': False, 'size': 16, 'congruent': 7, 'same': False, 'type': 'addresses_normal'}, 'OP': 'STOR'} {'src': {'NT': False, 'AVXalign': False, 'size': 32, 'congruent': 8, 'same': False, 'type': 'addresses_UC'}, 'OP': 'LOAD'} {'dst': {'NT': False, 'AVXalign': False, 'size': 2, 'congruent': 10, 'same': False, 'type': 'addresses_WC'}, 'OP': 'STOR'} {'dst': {'NT': False, 'AVXalign': False, 'size': 2, 'congruent': 0, 'same': False, 'type': 'addresses_US'}, 'OP': 'STOR'} [Faulty Load] {'src': {'NT': False, 'AVXalign': False, 'size': 32, 'congruent': 0, 'same': True, 'type': 'addresses_PSE'}, 'OP': 'LOAD'} <gen_prepare_buffer> {'dst': {'NT': False, 'AVXalign': False, 'size': 16, 'congruent': 1, 'same': False, 'type': 'addresses_UC_ht'}, 'OP': 'STOR'} {'src': {'congruent': 0, 'same': False, 'type': 'addresses_A_ht'}, 'dst': {'congruent': 0, 'same': True, 'type': 'addresses_WT_ht'}, 'OP': 'REPM'} {'src': {'congruent': 4, 'same': False, 'type': 'addresses_D_ht'}, 'dst': {'congruent': 7, 'same': False, 'type': 'addresses_normal_ht'}, 'OP': 'REPM'} {'src': {'congruent': 0, 'same': False, 'type': 'addresses_UC_ht'}, 'dst': {'congruent': 2, 'same': False, 'type': 'addresses_normal_ht'}, 'OP': 'REPM'} {'src': {'NT': False, 'AVXalign': False, 'size': 8, 'congruent': 6, 'same': False, 'type': 'addresses_WT_ht'}, 'OP': 'LOAD'} {'33': 2} 33 33 */
extern/gnat_sdl/gnat_sdl2/src/avxintrin_h.ads
AdaCore/training_material
15
5377
<reponame>AdaCore/training_material<filename>extern/gnat_sdl/gnat_sdl2/src/avxintrin_h.ads<gh_stars>10-100 pragma Ada_2005; pragma Style_Checks (Off); with Interfaces.C; use Interfaces.C; package avxintrin_h is -- Copyright (C) 2008-2017 Free Software Foundation, Inc. -- This file is part of GCC. -- GCC is free software; you can redistribute it and/or modify -- it under the terms of the GNU General Public License as published by -- the Free Software Foundation; either version 3, or (at your option) -- any later version. -- GCC 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. -- Under Section 7 of GPL version 3, you are granted additional -- permissions described in the GCC Runtime Library Exception, version -- 3.1, as published by the Free Software Foundation. -- You should have received a copy of the GNU General Public License and -- a copy of the GCC Runtime Library Exception along with this program; -- see the files COPYING3 and COPYING.RUNTIME respectively. If not, see -- <http://www.gnu.org/licenses/>. -- Implemented from the specification included in the Intel C++ Compiler -- User Guide and Reference, version 11.0. -- Internal data types for implementing the intrinsics. subtype uu_v4df is <vector>; -- d:\install\gpl2018\lib\gcc\x86_64-pc-mingw32\7.3.1\include\avxintrin.h:41 subtype uu_v8sf is <vector>; -- d:\install\gpl2018\lib\gcc\x86_64-pc-mingw32\7.3.1\include\avxintrin.h:42 subtype uu_v4di is <vector>; -- d:\install\gpl2018\lib\gcc\x86_64-pc-mingw32\7.3.1\include\avxintrin.h:43 subtype uu_v4du is <vector>; -- d:\install\gpl2018\lib\gcc\x86_64-pc-mingw32\7.3.1\include\avxintrin.h:44 subtype uu_v8si is <vector>; -- d:\install\gpl2018\lib\gcc\x86_64-pc-mingw32\7.3.1\include\avxintrin.h:45 subtype uu_v8su is <vector>; -- d:\install\gpl2018\lib\gcc\x86_64-pc-mingw32\7.3.1\include\avxintrin.h:46 subtype uu_v16hi is <vector>; -- d:\install\gpl2018\lib\gcc\x86_64-pc-mingw32\7.3.1\include\avxintrin.h:47 subtype uu_v16hu is <vector>; -- d:\install\gpl2018\lib\gcc\x86_64-pc-mingw32\7.3.1\include\avxintrin.h:48 subtype uu_v32qi is <vector>; -- d:\install\gpl2018\lib\gcc\x86_64-pc-mingw32\7.3.1\include\avxintrin.h:49 subtype uu_v32qu is <vector>; -- d:\install\gpl2018\lib\gcc\x86_64-pc-mingw32\7.3.1\include\avxintrin.h:50 -- The Intel API is flexible enough that we must allow aliasing with other -- vector types, and their scalar components. subtype uu_m256 is <vector>; -- d:\install\gpl2018\lib\gcc\x86_64-pc-mingw32\7.3.1\include\avxintrin.h:54 subtype uu_m256i is <vector>; -- d:\install\gpl2018\lib\gcc\x86_64-pc-mingw32\7.3.1\include\avxintrin.h:56 subtype uu_m256d is <vector>; -- d:\install\gpl2018\lib\gcc\x86_64-pc-mingw32\7.3.1\include\avxintrin.h:58 -- Unaligned version of the same types. subtype uu_m256_u is <vector>; -- d:\install\gpl2018\lib\gcc\x86_64-pc-mingw32\7.3.1\include\avxintrin.h:62 subtype uu_m256i_u is <vector>; -- d:\install\gpl2018\lib\gcc\x86_64-pc-mingw32\7.3.1\include\avxintrin.h:65 subtype uu_m256d_u is <vector>; -- d:\install\gpl2018\lib\gcc\x86_64-pc-mingw32\7.3.1\include\avxintrin.h:68 -- Compare predicates for scalar and packed compare intrinsics. -- Equal (ordered, non-signaling) -- Less-than (ordered, signaling) -- Less-than-or-equal (ordered, signaling) -- Unordered (non-signaling) -- Not-equal (unordered, non-signaling) -- Not-less-than (unordered, signaling) -- Not-less-than-or-equal (unordered, signaling) -- Ordered (nonsignaling) -- Equal (unordered, non-signaling) -- Not-greater-than-or-equal (unordered, signaling) -- Not-greater-than (unordered, signaling) -- False (ordered, non-signaling) -- Not-equal (ordered, non-signaling) -- Greater-than-or-equal (ordered, signaling) -- Greater-than (ordered, signaling) -- True (unordered, non-signaling) -- Equal (ordered, signaling) -- Less-than (ordered, non-signaling) -- Less-than-or-equal (ordered, non-signaling) -- Unordered (signaling) -- Not-equal (unordered, signaling) -- Not-less-than (unordered, non-signaling) -- Not-less-than-or-equal (unordered, non-signaling) -- Ordered (signaling) -- Equal (unordered, signaling) -- Not-greater-than-or-equal (unordered, non-signaling) -- Not-greater-than (unordered, non-signaling) -- False (ordered, signaling) -- Not-equal (ordered, signaling) -- Greater-than-or-equal (ordered, non-signaling) -- Greater-than (ordered, non-signaling) -- True (unordered, signaling) -- skipped func _mm256_add_pd -- skipped func _mm256_add_ps -- skipped func _mm256_addsub_pd -- skipped func _mm256_addsub_ps -- skipped func _mm256_and_pd -- skipped func _mm256_and_ps -- skipped func _mm256_andnot_pd -- skipped func _mm256_andnot_ps -- Double/single precision floating point blend instructions - select -- data from 2 sources using constant/variable mask. -- skipped func _mm256_blendv_pd -- skipped func _mm256_blendv_ps -- skipped func _mm256_div_pd -- skipped func _mm256_div_ps -- Dot product instructions with mask-defined summing and zeroing parts -- of result. -- skipped func _mm256_hadd_pd -- skipped func _mm256_hadd_ps -- skipped func _mm256_hsub_pd -- skipped func _mm256_hsub_ps -- skipped func _mm256_max_pd -- skipped func _mm256_max_ps -- skipped func _mm256_min_pd -- skipped func _mm256_min_ps -- skipped func _mm256_mul_pd -- skipped func _mm256_mul_ps -- skipped func _mm256_or_pd -- skipped func _mm256_or_ps -- skipped func _mm256_sub_pd -- skipped func _mm256_sub_ps -- skipped func _mm256_xor_pd -- skipped func _mm256_xor_ps -- skipped func _mm256_cvtepi32_pd -- skipped func _mm256_cvtepi32_ps -- skipped func _mm256_cvtpd_ps -- skipped func _mm256_cvtps_epi32 -- skipped func _mm256_cvtps_pd -- skipped func _mm256_cvttpd_epi32 -- skipped func _mm256_cvtpd_epi32 -- skipped func _mm256_cvttps_epi32 -- skipped func _mm256_cvtsd_f64 -- skipped func _mm256_cvtss_f32 -- skipped func _mm256_zeroall -- skipped func _mm256_zeroupper -- skipped func _mm_permutevar_pd -- skipped func _mm256_permutevar_pd -- skipped func _mm_permutevar_ps -- skipped func _mm256_permutevar_ps -- skipped func _mm_broadcast_ss -- skipped func _mm256_broadcast_sd -- skipped func _mm256_broadcast_ss -- skipped func _mm256_broadcast_pd -- skipped func _mm256_broadcast_ps -- skipped func _mm256_load_pd -- skipped func _mm256_store_pd -- skipped func _mm256_load_ps -- skipped func _mm256_store_ps -- skipped func _mm256_loadu_pd -- skipped func _mm256_storeu_pd -- skipped func _mm256_loadu_ps -- skipped func _mm256_storeu_ps -- skipped func _mm256_load_si256 -- skipped func _mm256_store_si256 -- skipped func _mm256_loadu_si256 -- skipped func _mm256_storeu_si256 -- skipped func _mm_maskload_pd -- skipped func _mm_maskstore_pd -- skipped func _mm256_maskload_pd -- skipped func _mm256_maskstore_pd -- skipped func _mm_maskload_ps -- skipped func _mm_maskstore_ps -- skipped func _mm256_maskload_ps -- skipped func _mm256_maskstore_ps -- skipped func _mm256_movehdup_ps -- skipped func _mm256_moveldup_ps -- skipped func _mm256_movedup_pd -- skipped func _mm256_lddqu_si256 -- skipped func _mm256_stream_si256 -- skipped func _mm256_stream_pd -- skipped func _mm256_stream_ps -- skipped func _mm256_rcp_ps -- skipped func _mm256_rsqrt_ps -- skipped func _mm256_sqrt_pd -- skipped func _mm256_sqrt_ps -- skipped func _mm256_unpackhi_pd -- skipped func _mm256_unpacklo_pd -- skipped func _mm256_unpackhi_ps -- skipped func _mm256_unpacklo_ps -- skipped func _mm_testz_pd -- skipped func _mm_testc_pd -- skipped func _mm_testnzc_pd -- skipped func _mm_testz_ps -- skipped func _mm_testc_ps -- skipped func _mm_testnzc_ps -- skipped func _mm256_testz_pd -- skipped func _mm256_testc_pd -- skipped func _mm256_testnzc_pd -- skipped func _mm256_testz_ps -- skipped func _mm256_testc_ps -- skipped func _mm256_testnzc_ps -- skipped func _mm256_testz_si256 -- skipped func _mm256_testc_si256 -- skipped func _mm256_testnzc_si256 -- skipped func _mm256_movemask_pd -- skipped func _mm256_movemask_ps -- skipped func _mm256_undefined_pd -- skipped func _mm256_undefined_ps -- skipped func _mm256_undefined_si256 -- skipped func _mm256_setzero_pd -- skipped func _mm256_setzero_ps -- skipped func _mm256_setzero_si256 -- Create the vector [A B C D]. -- skipped func _mm256_set_pd -- Create the vector [A B C D E F G H]. -- skipped func _mm256_set_ps -- Create the vector [A B C D E F G H]. -- skipped func _mm256_set_epi32 -- skipped func _mm256_set_epi16 -- skipped func _mm256_set_epi8 -- skipped func _mm256_set_epi64x -- Create a vector with all elements equal to A. -- skipped func _mm256_set1_pd -- Create a vector with all elements equal to A. -- skipped func _mm256_set1_ps -- Create a vector with all elements equal to A. -- skipped func _mm256_set1_epi32 -- skipped func _mm256_set1_epi16 -- skipped func _mm256_set1_epi8 -- skipped func _mm256_set1_epi64x -- Create vectors of elements in the reversed order from the -- _mm256_set_XXX functions. -- skipped func _mm256_setr_pd -- skipped func _mm256_setr_ps -- skipped func _mm256_setr_epi32 -- skipped func _mm256_setr_epi16 -- skipped func _mm256_setr_epi8 -- skipped func _mm256_setr_epi64x -- Casts between various SP, DP, INT vector types. Note that these do no -- conversion of values, they just change the type. -- skipped func _mm256_castpd_ps -- skipped func _mm256_castpd_si256 -- skipped func _mm256_castps_pd -- skipped func _mm256_castps_si256 -- skipped func _mm256_castsi256_ps -- skipped func _mm256_castsi256_pd -- skipped func _mm256_castpd256_pd128 -- skipped func _mm256_castps256_ps128 -- skipped func _mm256_castsi256_si128 -- When cast is done from a 128 to 256-bit type, the low 128 bits of -- the 256-bit result contain source parameter value and the upper 128 -- bits of the result are undefined. Those intrinsics shouldn't -- generate any extra moves. -- skipped func _mm256_castpd128_pd256 -- skipped func _mm256_castps128_ps256 -- skipped func _mm256_castsi128_si256 end avxintrin_h;
Transynther/x86/_processed/NONE/_zr_/i9-9900K_12_0xca.log_21829_297.asm
ljhsiun2/medusa
9
9416
.global s_prepare_buffers s_prepare_buffers: push %r10 push %r11 push %r14 push %r8 push %rbx push %rcx push %rdi push %rsi lea addresses_A_ht+0x7134, %r8 nop nop nop nop add $22738, %rbx mov (%r8), %r14 sub %rbx, %rbx lea addresses_A_ht+0xd89c, %rsi lea addresses_A_ht+0x10814, %rdi nop nop mfence mov $90, %rcx rep movsw nop nop nop nop dec %r8 lea addresses_WT_ht+0x173d4, %rsi lea addresses_D_ht+0x11f14, %rdi nop add %r10, %r10 mov $105, %rcx rep movsw nop nop dec %r8 lea addresses_WC_ht+0x82f4, %rsi nop nop nop nop cmp $40219, %r14 vmovups (%rsi), %ymm1 vextracti128 $1, %ymm1, %xmm1 vpextrq $0, %xmm1, %rdi and $22608, %rdi pop %rsi pop %rdi pop %rcx pop %rbx pop %r8 pop %r14 pop %r11 pop %r10 ret .global s_faulty_load s_faulty_load: push %r14 push %r8 push %r9 push %rcx push %rdi push %rdx push %rsi // Store mov $0x4fe, %r14 nop nop add $4832, %r9 movl $0x51525354, (%r14) nop nop xor %rsi, %rsi // Faulty Load lea addresses_WT+0x6a14, %r9 nop nop nop nop xor $58592, %r8 mov (%r9), %rdx lea oracles, %r14 and $0xff, %rdx shlq $12, %rdx mov (%r14,%rdx,1), %rdx pop %rsi pop %rdx pop %rdi pop %rcx pop %r9 pop %r8 pop %r14 ret /* <gen_faulty_load> [REF] {'OP': 'LOAD', 'src': {'size': 16, 'NT': False, 'type': 'addresses_WT', 'same': False, 'AVXalign': False, 'congruent': 0}} {'OP': 'STOR', 'dst': {'size': 4, 'NT': False, 'type': 'addresses_P', 'same': False, 'AVXalign': True, 'congruent': 1}} [Faulty Load] {'OP': 'LOAD', 'src': {'size': 8, 'NT': False, 'type': 'addresses_WT', 'same': True, 'AVXalign': False, 'congruent': 0}} <gen_prepare_buffer> {'OP': 'LOAD', 'src': {'size': 8, 'NT': False, 'type': 'addresses_A_ht', 'same': False, 'AVXalign': False, 'congruent': 1}} {'OP': 'REPM', 'src': {'same': False, 'type': 'addresses_A_ht', 'congruent': 3}, 'dst': {'same': False, 'type': 'addresses_A_ht', 'congruent': 8}} {'OP': 'REPM', 'src': {'same': False, 'type': 'addresses_WT_ht', 'congruent': 5}, 'dst': {'same': False, 'type': 'addresses_D_ht', 'congruent': 8}} {'OP': 'LOAD', 'src': {'size': 32, 'NT': False, 'type': 'addresses_WC_ht', 'same': False, 'AVXalign': False, 'congruent': 3}} {'00': 21829} 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 */
code/header.asm
sinusoid-studios/rhythm-land
11
245575
INCLUDE "constants/other-hardware.inc" SECTION "Entry Point", ROM0[$0100] EntryPoint: di jp Initialize ; Ensure no space is wasted ASSERT @ == $0104 SECTION "Cartridge Header", ROM0[$0104] ; Leave room for the cartridge header, filled in by RGBFIX CartridgeHeader: DS $0150 - $0104, 0 SECTION "Stack", WRAM0 DS STACK_SIZE wStackBottom:: SECTION "Keypad Variables", HRAM ; Currently pressed keys (1 = Pressed, 0 = Not pressed) hPressedKeys:: DS 1 ; Keys that were just pressed this frame hNewKeys:: DS 1 ; Keys that were just released this frame hReleasedKeys:: DS 1 SECTION "Current ROM Bank Number", HRAM ; Current ROM bank number of the $4000-$7FFF range, for restoring after ; temporarily switching banks hCurrentBank:: DS 1 SECTION "Scratch Variables", HRAM ; Temporary variables for whatever hScratch1:: DS 1 hScratch2:: DS 1 hScratch3:: DS 1 SECTION "Frame Counter", HRAM ; Increments every VBlank, used for some timing hFrameCounter:: DS 1 SECTION "Random Number Variable", HRAM ; A random-ish number, modified when Random is called hRandomNumber:: DS 1 SECTION "Hardware Register Mirrors", HRAM ; Mirrors of hardware registers, copied to the real things in the VBlank ; interrupt handler hLCDC:: DS 1 hSCX:: DS 1 hSCY:: DS 1 hBGP:: DS 1 hOBP0:: DS 1 hOBP1:: DS 1 SECTION "LYC Value Variables", HRAM ; Whether or not the current LYC interrupt is an "extra" LYC interrupt ; 0 = False, Non-zero = True hLYCFlag:: DS 1 ; Current position in LYCTable hLYCIndex:: DS 1 ; Value to reset hLYCIndex to when LYC_RESET is found at the current ; position in LYCTable hLYCResetIndex:: DS 1 SECTION "Current Screen ID", HRAM ; The ID of the current screen ; See constants/screens.inc for possible values hCurrentScreen:: DS 1
programs/oeis/117/A117591.asm
karttu/loda
0
169347
<reponame>karttu/loda ; A117591: 2^n + Fibonacci(n). ; 1,3,5,10,19,37,72,141,277,546,1079,2137,4240,8425,16761,33378,66523,132669,264728,528469,1055341,2108098,4212015,8417265,16823584,33629457,67230257,134414146,268753267,537385141,1074573864,2148829917,4297145605,8593459170,17185572071,34368965833,68734407088,137463111289,274916995113,549819059874,1099613961931,2199188835693,4398314425400,8796526516645,17592887453149,35185506992002,70370580489567,140740459570401,281479784237632,562957732163361,1125912493111649,2251820178696322,4503632578650595,9007252571032165 mov $5,$0 mov $7,2 lpb $7,1 mov $0,$5 sub $7,1 add $0,$7 sub $0,1 mov $2,1 mov $4,2 mov $6,2 lpb $0,1 sub $0,1 mov $3,$2 mul $2,2 add $3,$4 mov $4,$6 add $4,1 add $6,$3 lpe mul $6,2 sub $6,3 div $6,2 add $6,1 mov $8,$7 lpb $8,1 mov $1,$6 sub $8,1 lpe lpe lpb $5,1 sub $1,$6 mov $5,0 lpe
test/Fail/ConfluenceTypeLevelReduction.agda
hborum/agda
2
1624
<filename>test/Fail/ConfluenceTypeLevelReduction.agda -- Jesper, 2019-05-20: When checking confluence of two rewrite rules, -- we disable all reductions during unification of the left-hand -- sides. However, we should not disable reductions at the type-level, -- as shown by this (non-confluent) example. {-# OPTIONS --rewriting --confluence-check #-} open import Agda.Builtin.Unit open import Agda.Builtin.Bool open import Agda.Builtin.Equality open import Agda.Builtin.Equality.Rewrite data Unit : Set where unit : Unit A : Unit → Set A unit = ⊤ postulate a b : (u : Unit) → A u f : (u : Unit) → A u → Bool f-a : (u : Unit) → f u (a u) ≡ true f-b : (u : Unit) → f u (b u) ≡ false {-# REWRITE f-a #-} {-# REWRITE f-b #-} cong-f : (u : Unit) (x y : A u) → x ≡ y → f u x ≡ f u y cong-f u x y refl = refl boom : true ≡ false boom = cong-f unit (a unit) (b unit) refl
awa/src/model/awa-events-models.adb
twdroeger/ada-awa
0
4551
----------------------------------------------------------------------- -- AWA.Events.Models -- AWA.Events.Models ----------------------------------------------------------------------- -- File generated by ada-gen DO NOT MODIFY -- Template used: templates/model/package-body.xhtml -- Ada Generator: https://ada-gen.googlecode.com/svn/trunk Revision 1095 ----------------------------------------------------------------------- -- Copyright (C) 2019 <NAME> -- Written by <NAME> (<EMAIL>) -- -- 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. ----------------------------------------------------------------------- with Ada.Unchecked_Deallocation; with Util.Beans.Objects.Time; package body AWA.Events.Models is use type ADO.Objects.Object_Record_Access; use type ADO.Objects.Object_Ref; pragma Warnings (Off, "formal parameter * is not referenced"); function Message_Type_Key (Id : in ADO.Identifier) return ADO.Objects.Object_Key is Result : ADO.Objects.Object_Key (Of_Type => ADO.Objects.KEY_INTEGER, Of_Class => MESSAGE_TYPE_DEF'Access); begin ADO.Objects.Set_Value (Result, Id); return Result; end Message_Type_Key; function Message_Type_Key (Id : in String) return ADO.Objects.Object_Key is Result : ADO.Objects.Object_Key (Of_Type => ADO.Objects.KEY_INTEGER, Of_Class => MESSAGE_TYPE_DEF'Access); begin ADO.Objects.Set_Value (Result, Id); return Result; end Message_Type_Key; function "=" (Left, Right : Message_Type_Ref'Class) return Boolean is begin return ADO.Objects.Object_Ref'Class (Left) = ADO.Objects.Object_Ref'Class (Right); end "="; procedure Set_Field (Object : in out Message_Type_Ref'Class; Impl : out Message_Type_Access) is Result : ADO.Objects.Object_Record_Access; begin Object.Prepare_Modify (Result); Impl := Message_Type_Impl (Result.all)'Access; end Set_Field; -- Internal method to allocate the Object_Record instance procedure Allocate (Object : in out Message_Type_Ref) is Impl : Message_Type_Access; begin Impl := new Message_Type_Impl; ADO.Objects.Set_Object (Object, Impl.all'Access); end Allocate; -- ---------------------------------------- -- Data object: Message_Type -- ---------------------------------------- procedure Set_Id (Object : in out Message_Type_Ref; Value : in ADO.Identifier) is Impl : Message_Type_Access; begin Set_Field (Object, Impl); ADO.Objects.Set_Field_Key_Value (Impl.all, 1, Value); end Set_Id; function Get_Id (Object : in Message_Type_Ref) return ADO.Identifier is Impl : constant Message_Type_Access := Message_Type_Impl (Object.Get_Object.all)'Access; begin return Impl.Get_Key_Value; end Get_Id; procedure Set_Name (Object : in out Message_Type_Ref; Value : in String) is Impl : Message_Type_Access; begin Set_Field (Object, Impl); ADO.Objects.Set_Field_String (Impl.all, 2, Impl.Name, Value); end Set_Name; procedure Set_Name (Object : in out Message_Type_Ref; Value : in Ada.Strings.Unbounded.Unbounded_String) is Impl : Message_Type_Access; begin Set_Field (Object, Impl); ADO.Objects.Set_Field_Unbounded_String (Impl.all, 2, Impl.Name, Value); end Set_Name; function Get_Name (Object : in Message_Type_Ref) return String is begin return Ada.Strings.Unbounded.To_String (Object.Get_Name); end Get_Name; function Get_Name (Object : in Message_Type_Ref) return Ada.Strings.Unbounded.Unbounded_String is Impl : constant Message_Type_Access := Message_Type_Impl (Object.Get_Load_Object.all)'Access; begin return Impl.Name; end Get_Name; -- Copy of the object. procedure Copy (Object : in Message_Type_Ref; Into : in out Message_Type_Ref) is Result : Message_Type_Ref; begin if not Object.Is_Null then declare Impl : constant Message_Type_Access := Message_Type_Impl (Object.Get_Load_Object.all)'Access; Copy : constant Message_Type_Access := new Message_Type_Impl; begin ADO.Objects.Set_Object (Result, Copy.all'Access); Copy.Copy (Impl.all); Copy.Name := Impl.Name; end; end if; Into := Result; end Copy; procedure Find (Object : in out Message_Type_Ref; Session : in out ADO.Sessions.Session'Class; Query : in ADO.SQL.Query'Class; Found : out Boolean) is Impl : constant Message_Type_Access := new Message_Type_Impl; begin Impl.Find (Session, Query, Found); if Found then ADO.Objects.Set_Object (Object, Impl.all'Access); else ADO.Objects.Set_Object (Object, null); Destroy (Impl); end if; end Find; procedure Load (Object : in out Message_Type_Ref; Session : in out ADO.Sessions.Session'Class; Id : in ADO.Identifier) is Impl : constant Message_Type_Access := new Message_Type_Impl; Found : Boolean; Query : ADO.SQL.Query; begin Query.Bind_Param (Position => 1, Value => Id); Query.Set_Filter ("id = ?"); Impl.Find (Session, Query, Found); if not Found then Destroy (Impl); raise ADO.Objects.NOT_FOUND; end if; ADO.Objects.Set_Object (Object, Impl.all'Access); end Load; procedure Load (Object : in out Message_Type_Ref; Session : in out ADO.Sessions.Session'Class; Id : in ADO.Identifier; Found : out Boolean) is Impl : constant Message_Type_Access := new Message_Type_Impl; Query : ADO.SQL.Query; begin Query.Bind_Param (Position => 1, Value => Id); Query.Set_Filter ("id = ?"); Impl.Find (Session, Query, Found); if not Found then Destroy (Impl); else ADO.Objects.Set_Object (Object, Impl.all'Access); end if; end Load; procedure Save (Object : in out Message_Type_Ref; Session : in out ADO.Sessions.Master_Session'Class) is Impl : ADO.Objects.Object_Record_Access := Object.Get_Object; begin if Impl = null then Impl := new Message_Type_Impl; ADO.Objects.Set_Object (Object, Impl); end if; if not ADO.Objects.Is_Created (Impl.all) then Impl.Create (Session); else Impl.Save (Session); end if; end Save; procedure Delete (Object : in out Message_Type_Ref; Session : in out ADO.Sessions.Master_Session'Class) is Impl : constant ADO.Objects.Object_Record_Access := Object.Get_Object; begin if Impl /= null then Impl.Delete (Session); end if; end Delete; -- -------------------- -- Free the object -- -------------------- procedure Destroy (Object : access Message_Type_Impl) is type Message_Type_Impl_Ptr is access all Message_Type_Impl; procedure Unchecked_Free is new Ada.Unchecked_Deallocation (Message_Type_Impl, Message_Type_Impl_Ptr); pragma Warnings (Off, "*redundant conversion*"); Ptr : Message_Type_Impl_Ptr := Message_Type_Impl (Object.all)'Access; pragma Warnings (On, "*redundant conversion*"); begin Unchecked_Free (Ptr); end Destroy; procedure Find (Object : in out Message_Type_Impl; Session : in out ADO.Sessions.Session'Class; Query : in ADO.SQL.Query'Class; Found : out Boolean) is Stmt : ADO.Statements.Query_Statement := Session.Create_Statement (Query, MESSAGE_TYPE_DEF'Access); begin Stmt.Execute; if Stmt.Has_Elements then Object.Load (Stmt, Session); Stmt.Next; Found := not Stmt.Has_Elements; else Found := False; end if; end Find; overriding procedure Load (Object : in out Message_Type_Impl; Session : in out ADO.Sessions.Session'Class) is Found : Boolean; Query : ADO.SQL.Query; Id : constant ADO.Identifier := Object.Get_Key_Value; begin Query.Bind_Param (Position => 1, Value => Id); Query.Set_Filter ("id = ?"); Object.Find (Session, Query, Found); if not Found then raise ADO.Objects.NOT_FOUND; end if; end Load; procedure Save (Object : in out Message_Type_Impl; Session : in out ADO.Sessions.Master_Session'Class) is Stmt : ADO.Statements.Update_Statement := Session.Create_Statement (MESSAGE_TYPE_DEF'Access); begin if Object.Is_Modified (1) then Stmt.Save_Field (Name => COL_0_1_NAME, -- id Value => Object.Get_Key); Object.Clear_Modified (1); end if; if Object.Is_Modified (2) then Stmt.Save_Field (Name => COL_1_1_NAME, -- name Value => Object.Name); Object.Clear_Modified (2); end if; if Stmt.Has_Save_Fields then Stmt.Set_Filter (Filter => "id = ?"); Stmt.Add_Param (Value => Object.Get_Key); declare Result : Integer; begin Stmt.Execute (Result); if Result /= 1 then if Result /= 0 then raise ADO.Objects.UPDATE_ERROR; end if; end if; end; end if; end Save; procedure Create (Object : in out Message_Type_Impl; Session : in out ADO.Sessions.Master_Session'Class) is Query : ADO.Statements.Insert_Statement := Session.Create_Statement (MESSAGE_TYPE_DEF'Access); Result : Integer; begin Session.Allocate (Id => Object); Query.Save_Field (Name => COL_0_1_NAME, -- id Value => Object.Get_Key); Query.Save_Field (Name => COL_1_1_NAME, -- name Value => Object.Name); Query.Execute (Result); if Result /= 1 then raise ADO.Objects.INSERT_ERROR; end if; ADO.Objects.Set_Created (Object); end Create; procedure Delete (Object : in out Message_Type_Impl; Session : in out ADO.Sessions.Master_Session'Class) is Stmt : ADO.Statements.Delete_Statement := Session.Create_Statement (MESSAGE_TYPE_DEF'Access); begin Stmt.Set_Filter (Filter => "id = ?"); Stmt.Add_Param (Value => Object.Get_Key); Stmt.Execute; end Delete; -- ------------------------------ -- Get the bean attribute identified by the name. -- ------------------------------ overriding function Get_Value (From : in Message_Type_Ref; Name : in String) return Util.Beans.Objects.Object is Obj : ADO.Objects.Object_Record_Access; Impl : access Message_Type_Impl; begin if From.Is_Null then return Util.Beans.Objects.Null_Object; end if; Obj := From.Get_Load_Object; Impl := Message_Type_Impl (Obj.all)'Access; if Name = "id" then return ADO.Objects.To_Object (Impl.Get_Key); elsif Name = "name" then return Util.Beans.Objects.To_Object (Impl.Name); end if; return Util.Beans.Objects.Null_Object; end Get_Value; procedure List (Object : in out Message_Type_Vector; Session : in out ADO.Sessions.Session'Class; Query : in ADO.SQL.Query'Class) is Stmt : ADO.Statements.Query_Statement := Session.Create_Statement (Query, MESSAGE_TYPE_DEF'Access); begin Stmt.Execute; Message_Type_Vectors.Clear (Object); while Stmt.Has_Elements loop declare Item : Message_Type_Ref; Impl : constant Message_Type_Access := new Message_Type_Impl; begin Impl.Load (Stmt, Session); ADO.Objects.Set_Object (Item, Impl.all'Access); Object.Append (Item); end; Stmt.Next; end loop; end List; -- ------------------------------ -- Load the object from current iterator position -- ------------------------------ procedure Load (Object : in out Message_Type_Impl; Stmt : in out ADO.Statements.Query_Statement'Class; Session : in out ADO.Sessions.Session'Class) is pragma Unreferenced (Session); begin Object.Set_Key_Value (Stmt.Get_Identifier (0)); Object.Name := Stmt.Get_Unbounded_String (1); ADO.Objects.Set_Created (Object); end Load; function Queue_Key (Id : in ADO.Identifier) return ADO.Objects.Object_Key is Result : ADO.Objects.Object_Key (Of_Type => ADO.Objects.KEY_INTEGER, Of_Class => QUEUE_DEF'Access); begin ADO.Objects.Set_Value (Result, Id); return Result; end Queue_Key; function Queue_Key (Id : in String) return ADO.Objects.Object_Key is Result : ADO.Objects.Object_Key (Of_Type => ADO.Objects.KEY_INTEGER, Of_Class => QUEUE_DEF'Access); begin ADO.Objects.Set_Value (Result, Id); return Result; end Queue_Key; function "=" (Left, Right : Queue_Ref'Class) return Boolean is begin return ADO.Objects.Object_Ref'Class (Left) = ADO.Objects.Object_Ref'Class (Right); end "="; procedure Set_Field (Object : in out Queue_Ref'Class; Impl : out Queue_Access) is Result : ADO.Objects.Object_Record_Access; begin Object.Prepare_Modify (Result); Impl := Queue_Impl (Result.all)'Access; end Set_Field; -- Internal method to allocate the Object_Record instance procedure Allocate (Object : in out Queue_Ref) is Impl : Queue_Access; begin Impl := new Queue_Impl; Impl.Server_Id := 0; ADO.Objects.Set_Object (Object, Impl.all'Access); end Allocate; -- ---------------------------------------- -- Data object: Queue -- ---------------------------------------- procedure Set_Id (Object : in out Queue_Ref; Value : in ADO.Identifier) is Impl : Queue_Access; begin Set_Field (Object, Impl); ADO.Objects.Set_Field_Key_Value (Impl.all, 1, Value); end Set_Id; function Get_Id (Object : in Queue_Ref) return ADO.Identifier is Impl : constant Queue_Access := Queue_Impl (Object.Get_Object.all)'Access; begin return Impl.Get_Key_Value; end Get_Id; procedure Set_Server_Id (Object : in out Queue_Ref; Value : in Integer) is Impl : Queue_Access; begin Set_Field (Object, Impl); ADO.Objects.Set_Field_Integer (Impl.all, 2, Impl.Server_Id, Value); end Set_Server_Id; function Get_Server_Id (Object : in Queue_Ref) return Integer is Impl : constant Queue_Access := Queue_Impl (Object.Get_Load_Object.all)'Access; begin return Impl.Server_Id; end Get_Server_Id; procedure Set_Name (Object : in out Queue_Ref; Value : in String) is Impl : Queue_Access; begin Set_Field (Object, Impl); ADO.Objects.Set_Field_String (Impl.all, 3, Impl.Name, Value); end Set_Name; procedure Set_Name (Object : in out Queue_Ref; Value : in Ada.Strings.Unbounded.Unbounded_String) is Impl : Queue_Access; begin Set_Field (Object, Impl); ADO.Objects.Set_Field_Unbounded_String (Impl.all, 3, Impl.Name, Value); end Set_Name; function Get_Name (Object : in Queue_Ref) return String is begin return Ada.Strings.Unbounded.To_String (Object.Get_Name); end Get_Name; function Get_Name (Object : in Queue_Ref) return Ada.Strings.Unbounded.Unbounded_String is Impl : constant Queue_Access := Queue_Impl (Object.Get_Load_Object.all)'Access; begin return Impl.Name; end Get_Name; -- Copy of the object. procedure Copy (Object : in Queue_Ref; Into : in out Queue_Ref) is Result : Queue_Ref; begin if not Object.Is_Null then declare Impl : constant Queue_Access := Queue_Impl (Object.Get_Load_Object.all)'Access; Copy : constant Queue_Access := new Queue_Impl; begin ADO.Objects.Set_Object (Result, Copy.all'Access); Copy.Copy (Impl.all); Copy.Server_Id := Impl.Server_Id; Copy.Name := Impl.Name; end; end if; Into := Result; end Copy; procedure Find (Object : in out Queue_Ref; Session : in out ADO.Sessions.Session'Class; Query : in ADO.SQL.Query'Class; Found : out Boolean) is Impl : constant Queue_Access := new Queue_Impl; begin Impl.Find (Session, Query, Found); if Found then ADO.Objects.Set_Object (Object, Impl.all'Access); else ADO.Objects.Set_Object (Object, null); Destroy (Impl); end if; end Find; procedure Load (Object : in out Queue_Ref; Session : in out ADO.Sessions.Session'Class; Id : in ADO.Identifier) is Impl : constant Queue_Access := new Queue_Impl; Found : Boolean; Query : ADO.SQL.Query; begin Query.Bind_Param (Position => 1, Value => Id); Query.Set_Filter ("id = ?"); Impl.Find (Session, Query, Found); if not Found then Destroy (Impl); raise ADO.Objects.NOT_FOUND; end if; ADO.Objects.Set_Object (Object, Impl.all'Access); end Load; procedure Load (Object : in out Queue_Ref; Session : in out ADO.Sessions.Session'Class; Id : in ADO.Identifier; Found : out Boolean) is Impl : constant Queue_Access := new Queue_Impl; Query : ADO.SQL.Query; begin Query.Bind_Param (Position => 1, Value => Id); Query.Set_Filter ("id = ?"); Impl.Find (Session, Query, Found); if not Found then Destroy (Impl); else ADO.Objects.Set_Object (Object, Impl.all'Access); end if; end Load; procedure Save (Object : in out Queue_Ref; Session : in out ADO.Sessions.Master_Session'Class) is Impl : ADO.Objects.Object_Record_Access := Object.Get_Object; begin if Impl = null then Impl := new Queue_Impl; ADO.Objects.Set_Object (Object, Impl); end if; if not ADO.Objects.Is_Created (Impl.all) then Impl.Create (Session); else Impl.Save (Session); end if; end Save; procedure Delete (Object : in out Queue_Ref; Session : in out ADO.Sessions.Master_Session'Class) is Impl : constant ADO.Objects.Object_Record_Access := Object.Get_Object; begin if Impl /= null then Impl.Delete (Session); end if; end Delete; -- -------------------- -- Free the object -- -------------------- procedure Destroy (Object : access Queue_Impl) is type Queue_Impl_Ptr is access all Queue_Impl; procedure Unchecked_Free is new Ada.Unchecked_Deallocation (Queue_Impl, Queue_Impl_Ptr); pragma Warnings (Off, "*redundant conversion*"); Ptr : Queue_Impl_Ptr := Queue_Impl (Object.all)'Access; pragma Warnings (On, "*redundant conversion*"); begin Unchecked_Free (Ptr); end Destroy; procedure Find (Object : in out Queue_Impl; Session : in out ADO.Sessions.Session'Class; Query : in ADO.SQL.Query'Class; Found : out Boolean) is Stmt : ADO.Statements.Query_Statement := Session.Create_Statement (Query, QUEUE_DEF'Access); begin Stmt.Execute; if Stmt.Has_Elements then Object.Load (Stmt, Session); Stmt.Next; Found := not Stmt.Has_Elements; else Found := False; end if; end Find; overriding procedure Load (Object : in out Queue_Impl; Session : in out ADO.Sessions.Session'Class) is Found : Boolean; Query : ADO.SQL.Query; Id : constant ADO.Identifier := Object.Get_Key_Value; begin Query.Bind_Param (Position => 1, Value => Id); Query.Set_Filter ("id = ?"); Object.Find (Session, Query, Found); if not Found then raise ADO.Objects.NOT_FOUND; end if; end Load; procedure Save (Object : in out Queue_Impl; Session : in out ADO.Sessions.Master_Session'Class) is Stmt : ADO.Statements.Update_Statement := Session.Create_Statement (QUEUE_DEF'Access); begin if Object.Is_Modified (1) then Stmt.Save_Field (Name => COL_0_2_NAME, -- id Value => Object.Get_Key); Object.Clear_Modified (1); end if; if Object.Is_Modified (2) then Stmt.Save_Field (Name => COL_1_2_NAME, -- server_id Value => Object.Server_Id); Object.Clear_Modified (2); end if; if Object.Is_Modified (3) then Stmt.Save_Field (Name => COL_2_2_NAME, -- name Value => Object.Name); Object.Clear_Modified (3); end if; if Stmt.Has_Save_Fields then Stmt.Set_Filter (Filter => "id = ?"); Stmt.Add_Param (Value => Object.Get_Key); declare Result : Integer; begin Stmt.Execute (Result); if Result /= 1 then if Result /= 0 then raise ADO.Objects.UPDATE_ERROR; end if; end if; end; end if; end Save; procedure Create (Object : in out Queue_Impl; Session : in out ADO.Sessions.Master_Session'Class) is Query : ADO.Statements.Insert_Statement := Session.Create_Statement (QUEUE_DEF'Access); Result : Integer; begin Session.Allocate (Id => Object); Query.Save_Field (Name => COL_0_2_NAME, -- id Value => Object.Get_Key); Query.Save_Field (Name => COL_1_2_NAME, -- server_id Value => Object.Server_Id); Query.Save_Field (Name => COL_2_2_NAME, -- name Value => Object.Name); Query.Execute (Result); if Result /= 1 then raise ADO.Objects.INSERT_ERROR; end if; ADO.Objects.Set_Created (Object); end Create; procedure Delete (Object : in out Queue_Impl; Session : in out ADO.Sessions.Master_Session'Class) is Stmt : ADO.Statements.Delete_Statement := Session.Create_Statement (QUEUE_DEF'Access); begin Stmt.Set_Filter (Filter => "id = ?"); Stmt.Add_Param (Value => Object.Get_Key); Stmt.Execute; end Delete; -- ------------------------------ -- Get the bean attribute identified by the name. -- ------------------------------ overriding function Get_Value (From : in Queue_Ref; Name : in String) return Util.Beans.Objects.Object is Obj : ADO.Objects.Object_Record_Access; Impl : access Queue_Impl; begin if From.Is_Null then return Util.Beans.Objects.Null_Object; end if; Obj := From.Get_Load_Object; Impl := Queue_Impl (Obj.all)'Access; if Name = "id" then return ADO.Objects.To_Object (Impl.Get_Key); elsif Name = "server_id" then return Util.Beans.Objects.To_Object (Long_Long_Integer (Impl.Server_Id)); elsif Name = "name" then return Util.Beans.Objects.To_Object (Impl.Name); end if; return Util.Beans.Objects.Null_Object; end Get_Value; -- ------------------------------ -- Load the object from current iterator position -- ------------------------------ procedure Load (Object : in out Queue_Impl; Stmt : in out ADO.Statements.Query_Statement'Class; Session : in out ADO.Sessions.Session'Class) is pragma Unreferenced (Session); begin Object.Set_Key_Value (Stmt.Get_Identifier (0)); Object.Server_Id := Stmt.Get_Integer (1); Object.Name := Stmt.Get_Unbounded_String (2); ADO.Objects.Set_Created (Object); end Load; function Message_Key (Id : in ADO.Identifier) return ADO.Objects.Object_Key is Result : ADO.Objects.Object_Key (Of_Type => ADO.Objects.KEY_INTEGER, Of_Class => MESSAGE_DEF'Access); begin ADO.Objects.Set_Value (Result, Id); return Result; end Message_Key; function Message_Key (Id : in String) return ADO.Objects.Object_Key is Result : ADO.Objects.Object_Key (Of_Type => ADO.Objects.KEY_INTEGER, Of_Class => MESSAGE_DEF'Access); begin ADO.Objects.Set_Value (Result, Id); return Result; end Message_Key; function "=" (Left, Right : Message_Ref'Class) return Boolean is begin return ADO.Objects.Object_Ref'Class (Left) = ADO.Objects.Object_Ref'Class (Right); end "="; procedure Set_Field (Object : in out Message_Ref'Class; Impl : out Message_Access) is Result : ADO.Objects.Object_Record_Access; begin Object.Prepare_Modify (Result); Impl := Message_Impl (Result.all)'Access; end Set_Field; -- Internal method to allocate the Object_Record instance procedure Allocate (Object : in out Message_Ref) is Impl : Message_Access; begin Impl := new Message_Impl; Impl.Create_Date := ADO.DEFAULT_TIME; Impl.Priority := 0; Impl.Count := 0; Impl.Server_Id := 0; Impl.Task_Id := 0; Impl.Status := AWA.Events.Models.Message_Status_Type'First; Impl.Processing_Date.Is_Null := True; Impl.Version := 0; Impl.Entity_Id := ADO.NO_IDENTIFIER; Impl.Entity_Type := 0; Impl.Finish_Date.Is_Null := True; ADO.Objects.Set_Object (Object, Impl.all'Access); end Allocate; -- ---------------------------------------- -- Data object: Message -- ---------------------------------------- procedure Set_Id (Object : in out Message_Ref; Value : in ADO.Identifier) is Impl : Message_Access; begin Set_Field (Object, Impl); ADO.Objects.Set_Field_Key_Value (Impl.all, 1, Value); end Set_Id; function Get_Id (Object : in Message_Ref) return ADO.Identifier is Impl : constant Message_Access := Message_Impl (Object.Get_Object.all)'Access; begin return Impl.Get_Key_Value; end Get_Id; procedure Set_Create_Date (Object : in out Message_Ref; Value : in Ada.Calendar.Time) is Impl : Message_Access; begin Set_Field (Object, Impl); ADO.Objects.Set_Field_Time (Impl.all, 2, Impl.Create_Date, Value); end Set_Create_Date; function Get_Create_Date (Object : in Message_Ref) return Ada.Calendar.Time is Impl : constant Message_Access := Message_Impl (Object.Get_Load_Object.all)'Access; begin return Impl.Create_Date; end Get_Create_Date; procedure Set_Priority (Object : in out Message_Ref; Value : in Integer) is Impl : Message_Access; begin Set_Field (Object, Impl); ADO.Objects.Set_Field_Integer (Impl.all, 3, Impl.Priority, Value); end Set_Priority; function Get_Priority (Object : in Message_Ref) return Integer is Impl : constant Message_Access := Message_Impl (Object.Get_Load_Object.all)'Access; begin return Impl.Priority; end Get_Priority; procedure Set_Count (Object : in out Message_Ref; Value : in Integer) is Impl : Message_Access; begin Set_Field (Object, Impl); ADO.Objects.Set_Field_Integer (Impl.all, 4, Impl.Count, Value); end Set_Count; function Get_Count (Object : in Message_Ref) return Integer is Impl : constant Message_Access := Message_Impl (Object.Get_Load_Object.all)'Access; begin return Impl.Count; end Get_Count; procedure Set_Parameters (Object : in out Message_Ref; Value : in String) is Impl : Message_Access; begin Set_Field (Object, Impl); ADO.Objects.Set_Field_String (Impl.all, 5, Impl.Parameters, Value); end Set_Parameters; procedure Set_Parameters (Object : in out Message_Ref; Value : in Ada.Strings.Unbounded.Unbounded_String) is Impl : Message_Access; begin Set_Field (Object, Impl); ADO.Objects.Set_Field_Unbounded_String (Impl.all, 5, Impl.Parameters, Value); end Set_Parameters; function Get_Parameters (Object : in Message_Ref) return String is begin return Ada.Strings.Unbounded.To_String (Object.Get_Parameters); end Get_Parameters; function Get_Parameters (Object : in Message_Ref) return Ada.Strings.Unbounded.Unbounded_String is Impl : constant Message_Access := Message_Impl (Object.Get_Load_Object.all)'Access; begin return Impl.Parameters; end Get_Parameters; procedure Set_Server_Id (Object : in out Message_Ref; Value : in Integer) is Impl : Message_Access; begin Set_Field (Object, Impl); ADO.Objects.Set_Field_Integer (Impl.all, 6, Impl.Server_Id, Value); end Set_Server_Id; function Get_Server_Id (Object : in Message_Ref) return Integer is Impl : constant Message_Access := Message_Impl (Object.Get_Load_Object.all)'Access; begin return Impl.Server_Id; end Get_Server_Id; procedure Set_Task_Id (Object : in out Message_Ref; Value : in Integer) is Impl : Message_Access; begin Set_Field (Object, Impl); ADO.Objects.Set_Field_Integer (Impl.all, 7, Impl.Task_Id, Value); end Set_Task_Id; function Get_Task_Id (Object : in Message_Ref) return Integer is Impl : constant Message_Access := Message_Impl (Object.Get_Load_Object.all)'Access; begin return Impl.Task_Id; end Get_Task_Id; procedure Set_Status (Object : in out Message_Ref; Value : in AWA.Events.Models.Message_Status_Type) is procedure Set_Field_Enum is new ADO.Objects.Set_Field_Operation (Message_Status_Type); Impl : Message_Access; begin Set_Field (Object, Impl); Set_Field_Enum (Impl.all, 8, Impl.Status, Value); end Set_Status; function Get_Status (Object : in Message_Ref) return AWA.Events.Models.Message_Status_Type is Impl : constant Message_Access := Message_Impl (Object.Get_Load_Object.all)'Access; begin return Impl.Status; end Get_Status; procedure Set_Processing_Date (Object : in out Message_Ref; Value : in ADO.Nullable_Time) is Impl : Message_Access; begin Set_Field (Object, Impl); ADO.Objects.Set_Field_Time (Impl.all, 9, Impl.Processing_Date, Value); end Set_Processing_Date; function Get_Processing_Date (Object : in Message_Ref) return ADO.Nullable_Time is Impl : constant Message_Access := Message_Impl (Object.Get_Load_Object.all)'Access; begin return Impl.Processing_Date; end Get_Processing_Date; function Get_Version (Object : in Message_Ref) return Integer is Impl : constant Message_Access := Message_Impl (Object.Get_Load_Object.all)'Access; begin return Impl.Version; end Get_Version; procedure Set_Entity_Id (Object : in out Message_Ref; Value : in ADO.Identifier) is Impl : Message_Access; begin Set_Field (Object, Impl); ADO.Objects.Set_Field_Identifier (Impl.all, 11, Impl.Entity_Id, Value); end Set_Entity_Id; function Get_Entity_Id (Object : in Message_Ref) return ADO.Identifier is Impl : constant Message_Access := Message_Impl (Object.Get_Load_Object.all)'Access; begin return Impl.Entity_Id; end Get_Entity_Id; procedure Set_Entity_Type (Object : in out Message_Ref; Value : in ADO.Entity_Type) is Impl : Message_Access; begin Set_Field (Object, Impl); ADO.Objects.Set_Field_Entity_Type (Impl.all, 12, Impl.Entity_Type, Value); end Set_Entity_Type; function Get_Entity_Type (Object : in Message_Ref) return ADO.Entity_Type is Impl : constant Message_Access := Message_Impl (Object.Get_Load_Object.all)'Access; begin return Impl.Entity_Type; end Get_Entity_Type; procedure Set_Finish_Date (Object : in out Message_Ref; Value : in ADO.Nullable_Time) is Impl : Message_Access; begin Set_Field (Object, Impl); ADO.Objects.Set_Field_Time (Impl.all, 13, Impl.Finish_Date, Value); end Set_Finish_Date; function Get_Finish_Date (Object : in Message_Ref) return ADO.Nullable_Time is Impl : constant Message_Access := Message_Impl (Object.Get_Load_Object.all)'Access; begin return Impl.Finish_Date; end Get_Finish_Date; procedure Set_Queue (Object : in out Message_Ref; Value : in AWA.Events.Models.Queue_Ref'Class) is Impl : Message_Access; begin Set_Field (Object, Impl); ADO.Objects.Set_Field_Object (Impl.all, 14, Impl.Queue, Value); end Set_Queue; function Get_Queue (Object : in Message_Ref) return AWA.Events.Models.Queue_Ref'Class is Impl : constant Message_Access := Message_Impl (Object.Get_Load_Object.all)'Access; begin return Impl.Queue; end Get_Queue; procedure Set_Message_Type (Object : in out Message_Ref; Value : in AWA.Events.Models.Message_Type_Ref'Class) is Impl : Message_Access; begin Set_Field (Object, Impl); ADO.Objects.Set_Field_Object (Impl.all, 15, Impl.Message_Type, Value); end Set_Message_Type; function Get_Message_Type (Object : in Message_Ref) return AWA.Events.Models.Message_Type_Ref'Class is Impl : constant Message_Access := Message_Impl (Object.Get_Load_Object.all)'Access; begin return Impl.Message_Type; end Get_Message_Type; procedure Set_User (Object : in out Message_Ref; Value : in AWA.Users.Models.User_Ref'Class) is Impl : Message_Access; begin Set_Field (Object, Impl); ADO.Objects.Set_Field_Object (Impl.all, 16, Impl.User, Value); end Set_User; function Get_User (Object : in Message_Ref) return AWA.Users.Models.User_Ref'Class is Impl : constant Message_Access := Message_Impl (Object.Get_Load_Object.all)'Access; begin return Impl.User; end Get_User; procedure Set_Session (Object : in out Message_Ref; Value : in AWA.Users.Models.Session_Ref'Class) is Impl : Message_Access; begin Set_Field (Object, Impl); ADO.Objects.Set_Field_Object (Impl.all, 17, Impl.Session, Value); end Set_Session; function Get_Session (Object : in Message_Ref) return AWA.Users.Models.Session_Ref'Class is Impl : constant Message_Access := Message_Impl (Object.Get_Load_Object.all)'Access; begin return Impl.Session; end Get_Session; -- Copy of the object. procedure Copy (Object : in Message_Ref; Into : in out Message_Ref) is Result : Message_Ref; begin if not Object.Is_Null then declare Impl : constant Message_Access := Message_Impl (Object.Get_Load_Object.all)'Access; Copy : constant Message_Access := new Message_Impl; begin ADO.Objects.Set_Object (Result, Copy.all'Access); Copy.Copy (Impl.all); Copy.Create_Date := Impl.Create_Date; Copy.Priority := Impl.Priority; Copy.Count := Impl.Count; Copy.Parameters := Impl.Parameters; Copy.Server_Id := Impl.Server_Id; Copy.Task_Id := Impl.Task_Id; Copy.Status := Impl.Status; Copy.Processing_Date := Impl.Processing_Date; Copy.Version := Impl.Version; Copy.Entity_Id := Impl.Entity_Id; Copy.Entity_Type := Impl.Entity_Type; Copy.Finish_Date := Impl.Finish_Date; Copy.Queue := Impl.Queue; Copy.Message_Type := Impl.Message_Type; Copy.User := Impl.User; Copy.Session := Impl.Session; end; end if; Into := Result; end Copy; procedure Find (Object : in out Message_Ref; Session : in out ADO.Sessions.Session'Class; Query : in ADO.SQL.Query'Class; Found : out Boolean) is Impl : constant Message_Access := new Message_Impl; begin Impl.Find (Session, Query, Found); if Found then ADO.Objects.Set_Object (Object, Impl.all'Access); else ADO.Objects.Set_Object (Object, null); Destroy (Impl); end if; end Find; procedure Load (Object : in out Message_Ref; Session : in out ADO.Sessions.Session'Class; Id : in ADO.Identifier) is Impl : constant Message_Access := new Message_Impl; Found : Boolean; Query : ADO.SQL.Query; begin Query.Bind_Param (Position => 1, Value => Id); Query.Set_Filter ("id = ?"); Impl.Find (Session, Query, Found); if not Found then Destroy (Impl); raise ADO.Objects.NOT_FOUND; end if; ADO.Objects.Set_Object (Object, Impl.all'Access); end Load; procedure Load (Object : in out Message_Ref; Session : in out ADO.Sessions.Session'Class; Id : in ADO.Identifier; Found : out Boolean) is Impl : constant Message_Access := new Message_Impl; Query : ADO.SQL.Query; begin Query.Bind_Param (Position => 1, Value => Id); Query.Set_Filter ("id = ?"); Impl.Find (Session, Query, Found); if not Found then Destroy (Impl); else ADO.Objects.Set_Object (Object, Impl.all'Access); end if; end Load; procedure Save (Object : in out Message_Ref; Session : in out ADO.Sessions.Master_Session'Class) is Impl : ADO.Objects.Object_Record_Access := Object.Get_Object; begin if Impl = null then Impl := new Message_Impl; ADO.Objects.Set_Object (Object, Impl); end if; if not ADO.Objects.Is_Created (Impl.all) then Impl.Create (Session); else Impl.Save (Session); end if; end Save; procedure Delete (Object : in out Message_Ref; Session : in out ADO.Sessions.Master_Session'Class) is Impl : constant ADO.Objects.Object_Record_Access := Object.Get_Object; begin if Impl /= null then Impl.Delete (Session); end if; end Delete; -- -------------------- -- Free the object -- -------------------- procedure Destroy (Object : access Message_Impl) is type Message_Impl_Ptr is access all Message_Impl; procedure Unchecked_Free is new Ada.Unchecked_Deallocation (Message_Impl, Message_Impl_Ptr); pragma Warnings (Off, "*redundant conversion*"); Ptr : Message_Impl_Ptr := Message_Impl (Object.all)'Access; pragma Warnings (On, "*redundant conversion*"); begin Unchecked_Free (Ptr); end Destroy; procedure Find (Object : in out Message_Impl; Session : in out ADO.Sessions.Session'Class; Query : in ADO.SQL.Query'Class; Found : out Boolean) is Stmt : ADO.Statements.Query_Statement := Session.Create_Statement (Query, MESSAGE_DEF'Access); begin Stmt.Execute; if Stmt.Has_Elements then Object.Load (Stmt, Session); Stmt.Next; Found := not Stmt.Has_Elements; else Found := False; end if; end Find; overriding procedure Load (Object : in out Message_Impl; Session : in out ADO.Sessions.Session'Class) is Found : Boolean; Query : ADO.SQL.Query; Id : constant ADO.Identifier := Object.Get_Key_Value; begin Query.Bind_Param (Position => 1, Value => Id); Query.Set_Filter ("id = ?"); Object.Find (Session, Query, Found); if not Found then raise ADO.Objects.NOT_FOUND; end if; end Load; procedure Save (Object : in out Message_Impl; Session : in out ADO.Sessions.Master_Session'Class) is Stmt : ADO.Statements.Update_Statement := Session.Create_Statement (MESSAGE_DEF'Access); begin if Object.Is_Modified (1) then Stmt.Save_Field (Name => COL_0_3_NAME, -- id Value => Object.Get_Key); Object.Clear_Modified (1); end if; if Object.Is_Modified (2) then Stmt.Save_Field (Name => COL_1_3_NAME, -- create_date Value => Object.Create_Date); Object.Clear_Modified (2); end if; if Object.Is_Modified (3) then Stmt.Save_Field (Name => COL_2_3_NAME, -- priority Value => Object.Priority); Object.Clear_Modified (3); end if; if Object.Is_Modified (4) then Stmt.Save_Field (Name => COL_3_3_NAME, -- count Value => Object.Count); Object.Clear_Modified (4); end if; if Object.Is_Modified (5) then Stmt.Save_Field (Name => COL_4_3_NAME, -- parameters Value => Object.Parameters); Object.Clear_Modified (5); end if; if Object.Is_Modified (6) then Stmt.Save_Field (Name => COL_5_3_NAME, -- server_id Value => Object.Server_Id); Object.Clear_Modified (6); end if; if Object.Is_Modified (7) then Stmt.Save_Field (Name => COL_6_3_NAME, -- task_id Value => Object.Task_Id); Object.Clear_Modified (7); end if; if Object.Is_Modified (8) then Stmt.Save_Field (Name => COL_7_3_NAME, -- status Value => Integer (Message_Status_Type'Pos (Object.Status))); Object.Clear_Modified (8); end if; if Object.Is_Modified (9) then Stmt.Save_Field (Name => COL_8_3_NAME, -- processing_date Value => Object.Processing_Date); Object.Clear_Modified (9); end if; if Object.Is_Modified (11) then Stmt.Save_Field (Name => COL_10_3_NAME, -- entity_id Value => Object.Entity_Id); Object.Clear_Modified (11); end if; if Object.Is_Modified (12) then Stmt.Save_Field (Name => COL_11_3_NAME, -- entity_type Value => Object.Entity_Type); Object.Clear_Modified (12); end if; if Object.Is_Modified (13) then Stmt.Save_Field (Name => COL_12_3_NAME, -- finish_date Value => Object.Finish_Date); Object.Clear_Modified (13); end if; if Object.Is_Modified (14) then Stmt.Save_Field (Name => COL_13_3_NAME, -- queue_id Value => Object.Queue); Object.Clear_Modified (14); end if; if Object.Is_Modified (15) then Stmt.Save_Field (Name => COL_14_3_NAME, -- message_type_id Value => Object.Message_Type); Object.Clear_Modified (15); end if; if Object.Is_Modified (16) then Stmt.Save_Field (Name => COL_15_3_NAME, -- user_id Value => Object.User); Object.Clear_Modified (16); end if; if Object.Is_Modified (17) then Stmt.Save_Field (Name => COL_16_3_NAME, -- session_id Value => Object.Session); Object.Clear_Modified (17); end if; if Stmt.Has_Save_Fields then Object.Version := Object.Version + 1; Stmt.Save_Field (Name => "version", Value => Object.Version); Stmt.Set_Filter (Filter => "id = ? and version = ?"); Stmt.Add_Param (Value => Object.Get_Key); Stmt.Add_Param (Value => Object.Version - 1); declare Result : Integer; begin Stmt.Execute (Result); if Result /= 1 then if Result /= 0 then raise ADO.Objects.UPDATE_ERROR; else raise ADO.Objects.LAZY_LOCK; end if; end if; end; end if; end Save; procedure Create (Object : in out Message_Impl; Session : in out ADO.Sessions.Master_Session'Class) is Query : ADO.Statements.Insert_Statement := Session.Create_Statement (MESSAGE_DEF'Access); Result : Integer; begin Object.Version := 1; Session.Allocate (Id => Object); Query.Save_Field (Name => COL_0_3_NAME, -- id Value => Object.Get_Key); Query.Save_Field (Name => COL_1_3_NAME, -- create_date Value => Object.Create_Date); Query.Save_Field (Name => COL_2_3_NAME, -- priority Value => Object.Priority); Query.Save_Field (Name => COL_3_3_NAME, -- count Value => Object.Count); Query.Save_Field (Name => COL_4_3_NAME, -- parameters Value => Object.Parameters); Query.Save_Field (Name => COL_5_3_NAME, -- server_id Value => Object.Server_Id); Query.Save_Field (Name => COL_6_3_NAME, -- task_id Value => Object.Task_Id); Query.Save_Field (Name => COL_7_3_NAME, -- status Value => Integer (Message_Status_Type'Pos (Object.Status))); Query.Save_Field (Name => COL_8_3_NAME, -- processing_date Value => Object.Processing_Date); Query.Save_Field (Name => COL_9_3_NAME, -- version Value => Object.Version); Query.Save_Field (Name => COL_10_3_NAME, -- entity_id Value => Object.Entity_Id); Query.Save_Field (Name => COL_11_3_NAME, -- entity_type Value => Object.Entity_Type); Query.Save_Field (Name => COL_12_3_NAME, -- finish_date Value => Object.Finish_Date); Query.Save_Field (Name => COL_13_3_NAME, -- queue_id Value => Object.Queue); Query.Save_Field (Name => COL_14_3_NAME, -- message_type_id Value => Object.Message_Type); Query.Save_Field (Name => COL_15_3_NAME, -- user_id Value => Object.User); Query.Save_Field (Name => COL_16_3_NAME, -- session_id Value => Object.Session); Query.Execute (Result); if Result /= 1 then raise ADO.Objects.INSERT_ERROR; end if; ADO.Objects.Set_Created (Object); end Create; procedure Delete (Object : in out Message_Impl; Session : in out ADO.Sessions.Master_Session'Class) is Stmt : ADO.Statements.Delete_Statement := Session.Create_Statement (MESSAGE_DEF'Access); begin Stmt.Set_Filter (Filter => "id = ?"); Stmt.Add_Param (Value => Object.Get_Key); Stmt.Execute; end Delete; -- ------------------------------ -- Get the bean attribute identified by the name. -- ------------------------------ overriding function Get_Value (From : in Message_Ref; Name : in String) return Util.Beans.Objects.Object is Obj : ADO.Objects.Object_Record_Access; Impl : access Message_Impl; begin if From.Is_Null then return Util.Beans.Objects.Null_Object; end if; Obj := From.Get_Load_Object; Impl := Message_Impl (Obj.all)'Access; if Name = "id" then return ADO.Objects.To_Object (Impl.Get_Key); elsif Name = "create_date" then return Util.Beans.Objects.Time.To_Object (Impl.Create_Date); elsif Name = "priority" then return Util.Beans.Objects.To_Object (Long_Long_Integer (Impl.Priority)); elsif Name = "count" then return Util.Beans.Objects.To_Object (Long_Long_Integer (Impl.Count)); elsif Name = "parameters" then return Util.Beans.Objects.To_Object (Impl.Parameters); elsif Name = "server_id" then return Util.Beans.Objects.To_Object (Long_Long_Integer (Impl.Server_Id)); elsif Name = "task_id" then return Util.Beans.Objects.To_Object (Long_Long_Integer (Impl.Task_Id)); elsif Name = "status" then return AWA.Events.Models.Message_Status_Type_Objects.To_Object (Impl.Status); elsif Name = "processing_date" then if Impl.Processing_Date.Is_Null then return Util.Beans.Objects.Null_Object; else return Util.Beans.Objects.Time.To_Object (Impl.Processing_Date.Value); end if; elsif Name = "entity_id" then return Util.Beans.Objects.To_Object (Long_Long_Integer (Impl.Entity_Id)); elsif Name = "entity_type" then return Util.Beans.Objects.To_Object (Long_Long_Integer (Impl.Entity_Type)); elsif Name = "finish_date" then if Impl.Finish_Date.Is_Null then return Util.Beans.Objects.Null_Object; else return Util.Beans.Objects.Time.To_Object (Impl.Finish_Date.Value); end if; end if; return Util.Beans.Objects.Null_Object; end Get_Value; procedure List (Object : in out Message_Vector; Session : in out ADO.Sessions.Session'Class; Query : in ADO.SQL.Query'Class) is Stmt : ADO.Statements.Query_Statement := Session.Create_Statement (Query, MESSAGE_DEF'Access); begin Stmt.Execute; Message_Vectors.Clear (Object); while Stmt.Has_Elements loop declare Item : Message_Ref; Impl : constant Message_Access := new Message_Impl; begin Impl.Load (Stmt, Session); ADO.Objects.Set_Object (Item, Impl.all'Access); Object.Append (Item); end; Stmt.Next; end loop; end List; -- ------------------------------ -- Load the object from current iterator position -- ------------------------------ procedure Load (Object : in out Message_Impl; Stmt : in out ADO.Statements.Query_Statement'Class; Session : in out ADO.Sessions.Session'Class) is begin Object.Set_Key_Value (Stmt.Get_Identifier (0)); Object.Create_Date := Stmt.Get_Time (1); Object.Priority := Stmt.Get_Integer (2); Object.Count := Stmt.Get_Integer (3); Object.Parameters := Stmt.Get_Unbounded_String (4); Object.Server_Id := Stmt.Get_Integer (5); Object.Task_Id := Stmt.Get_Integer (6); Object.Status := Message_Status_Type'Val (Stmt.Get_Integer (7)); Object.Processing_Date := Stmt.Get_Nullable_Time (8); Object.Entity_Id := Stmt.Get_Identifier (10); Object.Entity_Type := ADO.Entity_Type (Stmt.Get_Integer (11)); Object.Finish_Date := Stmt.Get_Nullable_Time (12); if not Stmt.Is_Null (13) then Object.Queue.Set_Key_Value (Stmt.Get_Identifier (13), Session); end if; if not Stmt.Is_Null (14) then Object.Message_Type.Set_Key_Value (Stmt.Get_Identifier (14), Session); end if; if not Stmt.Is_Null (15) then Object.User.Set_Key_Value (Stmt.Get_Identifier (15), Session); end if; if not Stmt.Is_Null (16) then Object.Session.Set_Key_Value (Stmt.Get_Identifier (16), Session); end if; Object.Version := Stmt.Get_Integer (9); ADO.Objects.Set_Created (Object); end Load; end AWA.Events.Models;
test/Succeed/Issue857.agda
shlevy/agda
1,989
16655
module Issue857 where -- From the Agda mailing list, 2013-05-24, question raised by <NAME>. -- 2013-05-24 reported by <NAME>, test case by <NAME> {- The crucial point is that λ() is not equal to λ(), so e.g. the ones appearing in the body of main-closed-ground' don't match the ones in its own type. To be concrete we can use a simplified version of what happens in main-closed-ground': -} data ⊥ : Set where postulate X : Set P : (⊥ → X) → Set lemma : (f : ⊥ → X) → P f -- Given the context above we attempt to feed agda code using λ(): main : P λ() main = lemma λ() {- Before we can check the type of main we have to translate λ() away into toplevel definitions, because internally only those are allowed pattern-matching. But each use of λ() is translated separately, so we get: absurd1 : ⊥ → X absurd1 () absurd2 : ⊥ → X absurd2 () main : P absurd1 main = lemma absurd2 Now we can proceed typechecking and find that (lemma absurd2 : P absurd2), i.e. applications of lemma only care about the type of its argument, but for main to typecheck we need the type of the body (P absurd2) to equal the declared type (P absurd1), and so we'd need absurd2 = absurd1 which unfortunately we can't deduce because those are different definitions. -} -- 2013-05-24 example by <NAME> open import Common.Equality absurd-equality : _≡_ {A = ⊥ → ⊥} (λ()) λ() absurd-equality = refl -- λ() is not translated as λ() → () (identity with variable name ()) -- thus, these examples should type check now.
nicolai/anonymousExistence/Sec3hedberg.agda
nicolaikraus/HoTT-Agda
1
7341
<reponame>nicolaikraus/HoTT-Agda<filename>nicolai/anonymousExistence/Sec3hedberg.agda {-# OPTIONS --without-K #-} open import library.Basics hiding (Type ; Σ) open import library.types.Sigma open import Sec2preliminaries module Sec3hedberg where -- Lemma 3.2 discr→pathHasConst : {X : Type} → has-dec-eq X → pathHasConst X discr→pathHasConst dec x₁ x₂ with (dec x₁ x₂) discr→pathHasConst dec x₁ x₂ | inl p = (λ _ → p) , (λ _ _ → idp) discr→pathHasConst dec x₁ x₂ | inr np = idf _ , λ p → Empty-elim (np p) -- Lemma 3.3 pathHasConst→isSet : {X : Type} → pathHasConst X → is-set X pathHasConst→isSet {X} pc x₁ x₂ = all-paths-is-prop paths-equal where claim : (y₁ y₂ : X) → (p : y₁ == y₂) → p == ! (fst (pc _ _) idp) ∙ fst (pc _ _) p claim x₁ .x₁ idp = ! (!-inv-l (fst (pc x₁ x₁) idp)) paths-equal : (p₁ p₂ : x₁ == x₂) → p₁ == p₂ paths-equal p₁ p₂ = p₁ =⟨ claim _ _ p₁ ⟩ ! (fst (pc _ _) idp) ∙ fst (pc _ _) p₁ =⟨ ap (λ q → (! (fst (pc x₁ x₁) idp)) ∙ q) (snd (pc _ _) p₁ p₂) ⟩ -- whiskering ! (fst (pc _ _) idp) ∙ fst (pc _ _) p₂ =⟨ ! (claim _ _ p₂) ⟩ p₂ ∎ -- Theorem 3.1 hedberg : {X : Type} → has-dec-eq X → is-set X hedberg = pathHasConst→isSet ∘ discr→pathHasConst -- Definition 3.4 stable : Type → Type stable X = ¬ (¬ X) → X separated : Type → Type separated X = (x₁ x₂ : X) → stable (x₁ == x₂) -- Lemma 3.5 sep→set : {X : Type} → (separated X) → ({x₁ x₂ : X} → Funext {¬ (x₁ == x₂)} {Empty}) → is-set X sep→set {X} sep ⊥-funext = pathHasConst→isSet isPc where isPc : pathHasConst X isPc x₁ x₂ = f , c where f : x₁ == x₂ → x₁ == x₂ f = (sep x₁ x₂) ∘ (λ p np → np p) c : const f c p₁ p₂ = f p₁ =⟨ idp ⟩ (sep x₁ x₂) (λ np → np p₁) =⟨ ap (sep x₁ x₂) (⊥-funext _ _ λ np → Empty-elim {A = λ _ → np p₁ == np p₂} (np p₁)) ⟩ (sep x₁ x₂) (λ np → np p₂) =⟨ idp ⟩ f p₂ ∎ -- Definition 3.6 postulate Trunc : Type → Type h-tr : (X : Type) → is-prop (Trunc X) ∣_∣ : {X : Type} → X → Trunc X rec : {X : Type} → {P : Type} → (is-prop P) → (X → P) → Trunc X → P -- the propositional β rule is derivable: trunc-β : {X : Type} → {P : Type} → (pp : is-prop P) → (f : X → P) → (x : X) → rec pp f ∣ x ∣ == f x trunc-β pp f x = prop-has-all-paths pp _ _ -- Lemma 3.7 module _ (X : Type) (P : Trunc X → Type) (h : (z : Trunc X) → is-prop (P z)) (k : (x : X) → P(∣ x ∣)) where total : Type total = Σ (Trunc X) P j : X → total j x = ∣ x ∣ , k x total-prop : is-prop total total-prop = Σ-level (h-tr X) h total-map : Trunc X → total total-map = rec total-prop j induction : (z : Trunc X) → P z induction z = transport P (prop-has-all-paths (h-tr _) _ _) (snd (total-map z)) -- comment: Trunc is functorial trunc-functorial : {X Y : Type} → (X → Y) → (Trunc X → Trunc Y) trunc-functorial {X} {Y} f = rec (h-tr Y) (∣_∣ ∘ f) -- Theorem 3.8 impred : {X : Type} → (Trunc X ↔₀₁ ((P : Type) → (is-prop P) → (X → P) → P)) impred {X} = one , two where one : Trunc X → (P : Type) → (is-prop P) → (X → P) → P one z P p-prop f = rec p-prop f z two : ((P : Type) → (is-prop P) → (X → P) → P) → Trunc X two k = k (Trunc X) (h-tr _) ∣_∣ -- Definition 3.9 splitSup : Type → Type splitSup X = Trunc X → X hseparated : Type → Type hseparated X = (x₁ x₂ : X) → splitSup (x₁ == x₂) -- Theorem 3.10 set-characterizations : {X : Type} → (pathHasConst X → is-set X) × ((is-set X → hseparated X) × (hseparated X → pathHasConst X)) set-characterizations {X} = one , two , three where one : pathHasConst X → is-set X one = pathHasConst→isSet two : is-set X → hseparated X two h = λ x₁ x₂ → rec (h x₁ x₂) (idf _) three : hseparated X → pathHasConst X three hsep x₁ x₂ = f , c where f = (hsep _ _) ∘ ∣_∣ c = λ p₁ p₂ → f p₁ =⟨ idp ⟩ hsep _ _ (∣ p₁ ∣) =⟨ ap (hsep _ _) (prop-has-all-paths (h-tr _) _ _) ⟩ hsep _ _ (∣ p₂ ∣) =⟨ idp ⟩ f p₂ ∎ -- The rest of this section is only a replication of the arguments that we have given so far (for that reason, the proofs are not given in the article). -- They do not directly follow from the statements that we have proved before, but they directly imply them. -- Of course, replication of arguments is not a good style for a formalization - -- we chose this "disadvantageous" order purely as we believe it led to a better presentation in the article. -- Lemma 3.11 pathHasConst→isSet-local : {X : Type} → {x₀ : X} → ((y : X) → hasConst (x₀ == y)) → (y : X) → is-prop (x₀ == y) pathHasConst→isSet-local {X} {x₀} pc y = all-paths-is-prop paths-equal where claim : (y : X) → (p : x₀ == y) → p == ! (fst (pc _) idp) ∙ fst (pc _) p claim .x₀ idp = ! (!-inv-l (fst (pc _) idp)) paths-equal : (p₁ p₂ : x₀ == y) → p₁ == p₂ paths-equal p₁ p₂ = p₁ =⟨ claim _ p₁ ⟩ ! (fst (pc _) idp) ∙ fst (pc _) p₁ =⟨ ap (λ q → (! (fst (pc x₀) idp)) ∙ q) (snd (pc y) p₁ p₂) ⟩ -- whiskering ! (fst (pc _) idp) ∙ fst (pc _) p₂ =⟨ ! (claim _ p₂) ⟩ p₂ ∎ -- Theorem 3.12 hedberg-local : {X : Type} → {x₀ : X} → ((y : X) → (x₀ == y) + ¬(x₀ == y)) → (y : X) → is-prop (x₀ == y) hedberg-local {X} {x₀} dec = pathHasConst→isSet-local local-pathHasConst where local-pathHasConst : (y : X) → hasConst (x₀ == y) local-pathHasConst y with (dec y) local-pathHasConst y₁ | inl p = (λ _ → p) , (λ _ _ → idp) local-pathHasConst y₁ | inr np = idf _ , (λ p → Empty-elim (np p)) -- Lemma 3.13 sep→set-local : {X : Type} → {x₀ : X} → ((y : X) → stable (x₀ == y)) → ({y : X} → Funext {¬ (x₀ == y)} {Empty}) → (y : X) → is-prop (x₀ == y) sep→set-local {X} {x₀} sep ⊥-funext = pathHasConst→isSet-local is-pathHasConst where is-pathHasConst : (y : X) → hasConst (x₀ == y) is-pathHasConst y = f , c where f : x₀ == y → x₀ == y f = (sep y) ∘ (λ p np → np p) c : const f c p₁ p₂ = f p₁ =⟨ idp ⟩ (sep _) (λ np → np p₁) =⟨ ap (sep _) (⊥-funext _ _ λ np → Empty-elim {A = λ _ → np p₁ == np p₂} (np p₁)) ⟩ (sep _) (λ np → np p₂) =⟨ idp ⟩ f p₂ ∎ -- Theorem 3.14 set-characterizations-local : {X : Type} → {x₀ : X} → (((y : X) → hasConst (x₀ == y)) → (y : X) → is-prop (x₀ == y)) × ((((y : X) → is-prop (x₀ == y)) → (y : X) → splitSup (x₀ == y)) × (((y : X) → splitSup (x₀ == y)) → (y : X) → hasConst (x₀ == y))) set-characterizations-local {X} {x₀} = one , two , three where one = pathHasConst→isSet-local two : ((y : X) → is-prop (x₀ == y)) → (y : X) → splitSup (x₀ == y) two h y = rec (h y) (idf _) three : ((y : X) → splitSup (x₀ == y)) → (y : X) → hasConst (x₀ == y) three hsep y = f , c where f = (hsep _) ∘ ∣_∣ c = λ p₁ p₂ → f p₁ =⟨ idp ⟩ (hsep _) ∣ p₁ ∣ =⟨ ap (hsep _) (prop-has-all-paths (h-tr _) _ _) ⟩ (hsep _) ∣ p₂ ∣ =⟨ idp ⟩ f p₂ ∎
src/test/ref/assignment-chained.asm
jbrandwood/kickc
2
13953
// Tests that chained assignments work as intended // Commodore 64 PRG executable file .file [name="assignment-chained.prg", type="prg", segments="Program"] .segmentdef Program [segments="Basic, Code, Data"] .segmentdef Basic [start=$0801] .segmentdef Code [start=$80d] .segmentdef Data [startAfter="Code"] .segment Basic :BasicUpstart(main) .segment Code main: { .label screen = $400 // screen[0] = a = 'c' lda #'c' sta screen // screen[40] = a sta screen+$28 // screen[1] = 'm' lda #'m' sta screen+1 // a = screen[1] = 'm' // screen[41] = a sta screen+$29 // screen[2] = 1 + (a = 'l') lda #1+'l' sta screen+2 // screen[42] = a // Chained assignment with a modification of the result lda #'l' sta screen+$2a // } rts }
learyouanagda/IPL.agda
shouya/thinking-dumps
24
3300
<gh_stars>10-100 module IPL where data _∧_ (P : Set) (Q : Set) : Set where ∧-intro : P → Q → (P ∧ Q) proof₁ : {P Q : Set} → (P ∧ Q) → P proof₁ (∧-intro p q) = p proof₂ : {P Q : Set} → (P ∧ Q) → Q proof₂ (∧-intro p q) = q _⇔_ : (P : Set) → (Q : Set) → Set a ⇔ b = (a → b) ∧ (b → a) ∧-comm′ : (P Q : Set) → (P ∧ Q) → (Q ∧ P) ∧-comm′ _ _ (∧-intro p q) = ∧-intro q p ∧-comm : (P Q : Set) → (P ∧ Q) ⇔ (Q ∧ P) ∧-comm P Q = ∧-intro (∧-comm′ P Q) (∧-comm′ Q P) ∧-comm1′ : {P Q : Set} → (P ∧ Q) → (Q ∧ P) ∧-comm1′ (∧-intro p q) = ∧-intro q p data _∨_ (P Q : Set) : Set where ∨-intro₁ : P → P ∨ Q ∨-intro₂ : Q → P ∨ Q ∨-elim : {A B C : Set} → (A → C) → (B → C) → (A ∨ B) → C ∨-elim ac bc (∨-intro₁ a) = ac a ∨-elim ac bc (∨-intro₂ b) = bc b ∨-comm′ : {A B : Set} → (A ∨ B) → (B ∨ A) ∨-comm′ (∨-intro₁ a) = ∨-intro₂ a ∨-comm′ (∨-intro₂ b) = ∨-intro₁ b ∨-comm : {A B : Set} → (A ∨ B) ⇔ (B ∨ A) ∨-comm = ∧-intro ∨-comm′ ∨-comm′ data ⊥ : Set where ¬ : Set → Set ¬ A = A → ⊥
scripts/music/en/nextTrack.applescript
dnedry2/vscode-itunes
16
3604
tell application "Music" next track end tell
programs/oeis/081/A081910.asm
karttu/loda
0
242200
; A081910: 4^n*(n^2-n+32)/32. ; 1,4,17,76,352,1664,7936,37888,180224,851968,3997696,18612224,85983232,394264576,1795162112,8120172544,36507222016,163208757248,725849473024,3212635537408,14156212207616,62122406969344,271579372060672,1183074511486976,5136918324969472 mov $4,$0 mul $0,2 bin $4,2 mov $3,$4 add $3,4 add $4,8 mov $5,$4 lpb $0,1 sub $0,1 add $3,10 mul $3,2 mul $5,2 lpe mov $1,$3 add $2,$5 add $1,$2 div $1,32 add $1,1
validation.adb
annexi-strayline/AURA
13
9922
------------------------------------------------------------------------------ -- -- -- Ada User Repository Annex (AURA) -- -- ANNEXI-STRAYLINE Reference Implementation -- -- -- -- Command Line Interface -- -- -- -- ------------------------------------------------------------------------ -- -- -- -- Copyright (C) 2020, ANNEXI-STRAYLINE Trans-Human Ltd. -- -- All rights reserved. -- -- -- -- Original Contributors: -- -- * <NAME> (ANNEXI-STRAYLINE) -- -- -- -- 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 the copyright holder 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. -- -- -- ------------------------------------------------------------------------------ with Workers; with Repositories; with Registrar.Queries; with Registrar.Subsystems; package body Validation is package VSD_Orders is type Validate_Subsystem_Dependencies_Order is new Workers.Work_Order with record Target: Registrar.Subsystems.Subsystem; end record; overriding function Image (Order: Validate_Subsystem_Dependencies_Order) return String; overriding procedure Execute (Order: in out Validate_Subsystem_Dependencies_Order); end VSD_Orders; package body VSD_Orders is separate; ------------------------------------- -- Validate_Subsystem_Dependencies -- ------------------------------------- procedure Validate_Subsystem_Dependencies is use VSD_Orders; use Repositories; use Registrar.Subsystems; Avail_Subsys: constant Subsystem_Sets.Set := Registrar.Queries.Available_Subsystems; Order: Validate_Subsystem_Dependencies_Order; begin -- Note that if we get to validation, there should be no subsystems that -- are not "Available" -- Find all the subsystems we need to check now so that we can set the -- tracker appropriately for SS of Avail_Subsys loop if Extract_Repository (SS.Source_Repository).Format = System then Check_Subset.Insert (SS); end if; end loop; if Check_Subset.Is_Empty then return; end if; Validate_Subsystem_Dependencies_Progress.Increase_Total_Items_By (Natural (Check_Subset.Length)); for SS of Check_Subset loop Order.Target := SS; Workers.Enqueue_Order (Order); end loop; -- Not much point in freeing Avail_Subsys if we get an exception, since -- getting an exception here will definately end the program shortly -- after end Validate_Subsystem_Dependencies; end Validation;
chrome/browser/ui/cocoa/applescript/examples/tab_navigation.applescript
zealoussnow/chromium
14,668
375
<reponame>zealoussnow/chromium<filename>chrome/browser/ui/cocoa/applescript/examples/tab_navigation.applescript -- Copyright (c) 2010 The Chromium Authors. All rights reserved. -- Use of this source code is governed by a BSD-style license that can be -- found in the LICENSE file. tell application "Chromium" tell window 1 -- creates a new tab and navigates to a particular URL. make new tab with properties {URL:"http://google.com"} -- Duplicate a tab. set var to URL of tab 2 make new tab with properties {URL:var} end tell end tell
gnu/usr.bin/binutils/gdb/testsuite/gdb.ada/null_record.adb
ArrogantWombatics/openbsd-src
105
8471
-- Copyright 2004 Free Software Foundation, Inc. -- -- 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. with Bar; use Bar; procedure Null_Record is begin Do_Nothing; end Null_Record;
Task/Create-a-file/AppleScript/create-a-file-3.applescript
LaudateCorpus1/RosettaCodeData
1
2980
<gh_stars>1-10 tell application "Finder" to set wd to target of window 1 as string close (open for access wd & "output.txt")
models/amalgam/tests/test_ordering.als
transclosure/Amalgam
4
279
<gh_stars>1-10 /* Test bounds recovery on ordering. This specification is fully constrained, and has only one model. 0->0->0->0 */ open util/ordering[Node] sig Node {edges: set Node} fact orderingEdges { all n: Node | { -- first node has no inflow (un-necessary with equality in 2nd constraint) -- first not in Node.edges -- each node flows into its next (and nothing more) n.next = n.edges } } run {} for 4
contrib/ayacc/src/parse_table.adb
faelys/gela-asis
4
6401
-- Copyright (c) 1990 Regents of the University of California. -- All rights reserved. -- -- The primary authors of ayacc were <NAME> and <NAME>. -- Enhancements were made by <NAME>. -- -- Send requests for ayacc information to <EMAIL> -- Send bug reports for ayacc to <EMAIL> -- -- Redistribution and use in source and binary forms are permitted -- provided that the above copyright notice and this paragraph are -- duplicated in all such forms and that any documentation, -- advertising materials, and other materials related to such -- distribution and use acknowledge that the software was developed -- by the University of California, Irvine. The name of the -- University may not be used to endorse or promote products derived -- from this software without specific prior written permission. -- THIS SOFTWARE IS PROVIDED ``AS IS'' AND WITHOUT ANY EXPRESS OR -- IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED -- WARRANTIES OF MERCHANTIBILITY AND FITNESS FOR A PARTICULAR PURPOSE. -- Module : parse_table_body.ada -- Component of : ayacc -- Version : 1.2 -- Date : 11/21/86 12:33:16 -- SCCS File : disk21~/rschm/hasee/sccs/ayacc/sccs/sxparse_table_body.ada -- $Header: parse_table_body.a,v 0.1 86/04/01 15:08:38 ada Exp $ -- $Log: parse_table_body.a,v $ -- Revision 0.1 86/04/01 15:08:38 ada -- This version fixes some minor bugs with empty grammars -- and $$ expansion. It also uses vads5.1b enhancements -- such as pragma inline. -- -- -- Revision 0.0 86/02/19 18:39:53 ada -- -- These files comprise the initial version of Ayacc -- designed and implemented by <NAME> and <NAME>. -- Ayacc has been compiled and tested under the Verdix Ada compiler -- version 4.06 on a vax 11/750 running Unix 4.2BSD. -- with LALR_Symbol_Info, LR0_Machine, Symbol_Table, Rule_Table, Text_IO, Symbol_Info, Verbose_File, Options, Goto_File, Shift_Reduce_File; use LALR_Symbol_Info, LR0_Machine, Symbol_Table, Rule_Table, Text_IO, Symbol_Info, Options; package body Parse_Table is SCCS_ID : constant String := "@(#) parse_table_body.ada, Version 1.2"; Rcs_ID : constant String := "$Header: parse_table_body.a,v 0.1 86/04/01 15:08:38 ada Exp $"; Show_Verbose : Boolean; -- Set to options.verbose -- -- The following declarations are for the "action" table. -- type Action_Type is (Undefined, Error, Shift, Reduce, Accept_Input); -- UNDEFINED and ERROR are the same accept you cannot replace -- ERROR entries by a default reduction. type Action_Table_Entry(Action : Action_Type := Undefined) is record case Action is when Shift => State_ID : Parse_State; when Reduce => Rule_ID : Rule; when Accept_Input | Error | Undefined => null; end case; end record; type Action_Table_Array is array(Grammar_Symbol range <>) of Action_Table_Entry; type Action_Table_Array_Pointer is access Action_Table_Array; Action_Table_Row : Action_Table_Array_Pointer; Default_Action : Action_Table_Entry; -- -- The following declarations are for the "goto" table -- type Goto_Table_Array is array(Grammar_Symbol range <>) of Parse_State; type Goto_Table_Array_Pointer is access Goto_Table_Array; Goto_Table_Row : Goto_Table_Array_Pointer; -- type Goto_Offset_Array is array(Parse_State range <>) of Integer; type Goto_Offset_Array_Pointer is access Goto_Offset_Array; Goto_Offset : Goto_Offset_Array_Pointer; type Action_Offset_Array is array(Parse_State range <>) of Integer; type Action_Offset_Array_Pointer is access Action_Offset_Array; Action_Offset : Action_Offset_Array_Pointer; -- Error_Code : constant := -3000; -- generated parser must use these Accept_Code : constant := -3001; Num_of_Goto_Entries : Integer := 0; Num_of_Action_Entries : Integer := 0; Num_Shift_Reduce_Conflicts : Natural := 0; Num_Reduce_Reduce_Conflicts : Natural := 0; function Shift_Reduce_Conflicts return Natural is begin return Num_Shift_Reduce_Conflicts; end; function Reduce_Reduce_Conflicts return Natural is begin return Num_Reduce_Reduce_Conflicts; end; function Number_of_States return Natural is begin return Natural(LR0_Machine.Last_Parse_State + 1); end; function Size_of_Goto_Table return Natural is begin return Num_of_Goto_Entries; end; function Size_of_Action_Table return Natural is begin return Num_of_Action_Entries; end; procedure Print_Goto_Row_Verbose is begin for Sym in Goto_Table_Row.all'range loop if Goto_Table_Row(Sym) /= Null_Parse_State then Verbose_File.Write(Ascii.Ht); Verbose_File.Print_Grammar_Symbol(Sym); Verbose_File.Write(" " & Ascii.Ht); Verbose_File.Write_Line ("goto " & Parse_State'Image(Goto_Table_Row(Sym))); end if; end loop; end Print_Goto_Row_Verbose; procedure Print_Goto_Row(State: in Parse_State) is S: Parse_State; begin Goto_Offset(State) := Num_of_Goto_Entries; Goto_File.Write_Line ("-- State " & Parse_State'Image(State)); for I in Goto_Table_Row.all'range loop S := Goto_Table_Row(I); if S /= -1 then Goto_File.Write(","); Goto_File.Write("(" & Grammar_Symbol'Image(I) & "," & Parse_State'Image(S) & ")" ); Num_of_Goto_Entries := Num_of_Goto_Entries + 1; if Num_of_Goto_Entries mod 4 = 0 then Goto_File.Write_Line(""); end if; end if; end loop; Goto_File.Write_Line(""); end Print_Goto_Row; ----------------------------------------------------------------------- procedure Print_Action_Row(State: in Parse_State) is Temp : Action_Table_Entry; X : Integer; Default : Integer; function Get_Default_Entry return Integer is begin for I in Action_Table_Row.all'range loop if Action_Table_Row(I).Action = Reduce then return -Integer(Action_Table_Row(I).Rule_ID); end if; end loop; return Error_Code; end Get_Default_Entry; begin Action_Offset(State) := Num_of_Action_Entries; Shift_Reduce_File.Write_Line ("-- state " & Parse_State'Image(State)); Default := Get_Default_Entry; for I in Action_Table_Row.all'range loop Temp := Action_Table_Row(I); case Temp.Action is when Undefined => X := Default; when Shift => X := Integer(Temp.State_ID); when Reduce => X := - Integer(Temp.Rule_ID); when Accept_Input => X := Accept_Code; when Error => X := Error_Code; end case; if X /= Default then Shift_Reduce_File.Write(","); Shift_Reduce_File.Write("(" & Grammar_Symbol'Image(I) & ","); Shift_Reduce_File.Write(Integer'Image(X) & ")" ); Num_of_Action_Entries := Num_of_Action_Entries + 1; if Num_of_Action_Entries mod 4 = 0 then Shift_Reduce_File.Write_Line(""); end if; if Show_Verbose then Verbose_File.Write(" " & Ascii.Ht); Verbose_File.Print_Grammar_Symbol(I); Verbose_File.Write(" " & Ascii.Ht); if X = Accept_Code then Verbose_File.Write_Line("accept"); elsif X = Error_Code then Verbose_File.Write_Line("error"); elsif X > 0 then -- SHIFT Verbose_File.Write_Line("shift " & Integer'Image(X)); else -- REDUCE Verbose_File.Write_Line("reduce " & Integer'Image(-X)); end if; end if; end if; end loop; if Show_Verbose then Verbose_File.Write(" " & Ascii.Ht); Verbose_File.Write("default " & Ascii.Ht); if Default = Accept_Code then Verbose_File.Write_Line("accept"); elsif Default = Error_Code then Verbose_File.Write_Line("error"); else -- reduce. never shift Verbose_File.Write_Line("reduce " & Integer'Image(-Default)); end if; end if; Shift_Reduce_File.Write(","); Shift_Reduce_File.Write("(" & Grammar_Symbol'Image(-1) & ","); Shift_Reduce_File.Write(Integer'Image(Default) & ")" ); Num_of_Action_Entries := Num_of_Action_Entries + 1; if Num_of_Action_Entries mod 4 = 0 then Shift_Reduce_File.Write_Line(""); end if; Shift_Reduce_File.Write_Line(""); end Print_Action_Row; ----------------------------------------------------------------------- procedure Init_Table_Files is begin Goto_Offset := new Goto_Offset_Array (First_Parse_State..Last_Parse_State); Action_Offset := new Action_Offset_Array (First_Parse_State..Last_Parse_State); Goto_File.Open_Write; Shift_Reduce_File.Open_Write; end Init_Table_Files; procedure Finish_Table_Files is begin Goto_File.Write_Line(");"); Goto_File.Write_Line("-- The offset vector"); Goto_File.Write("GOTO_OFFSET : array (0.."); Goto_File.Write(Parse_State'Image(Goto_Offset.all'Last) & ')'); Goto_File.Write_Line(" of Integer :="); Goto_File.Write("("); for I in Goto_Offset.all'First .. Goto_Offset.all'Last-1 loop Goto_File.Write(Integer'Image(Goto_Offset(I)) & ","); if I mod 10 = 0 then Goto_File.Write_Line(""); end if; end loop; Goto_File.Write (Integer'Image(Goto_Offset(Goto_Offset.all'Last))); Goto_File.Write_Line(");"); Goto_File.Close_Write; Shift_Reduce_File.Write_Line(");"); Shift_Reduce_File.Write_Line("-- The offset vector"); Shift_Reduce_File.Write("SHIFT_REDUCE_OFFSET : array (0.."); Shift_Reduce_File.Write (Parse_State'Image(Action_Offset.all'Last) & ')'); Shift_Reduce_File.Write_Line(" of Integer :="); Shift_Reduce_File.Write("("); for I in Action_Offset.all'First..Action_Offset.all'Last-1 loop Shift_Reduce_File.Write (Integer'Image(Action_Offset(I)) & ","); if I mod 10 = 0 then Shift_Reduce_File.Write_Line(""); end if; end loop; Shift_Reduce_File.Write (Integer'Image(Action_Offset(Action_Offset.all'Last))); Shift_Reduce_File.Write_Line(");"); Shift_Reduce_File.Close_Write; end Finish_Table_Files; procedure Compute_Parse_Table is use Transition_Set_Pack; use Item_Set_Pack; use Grammar_Symbol_Set_Pack; Trans : Transition; Nonterm_Iter : Nt_Transition_Iterator; Term_Iter : T_Transition_Iterator; Item_Set_1 : Item_Set; Item_Iter : Item_Iterator; Temp_Item : Item; Lookahead_Set : Grammar_Symbol_Set; Sym_Iter : Grammar_Symbol_Iterator; Sym : Grammar_Symbol; -- these variables are used for resolving conflicts Sym_Prec : Precedence; Rule_Prec : Precedence; Sym_Assoc : Associativity; -- recduce by r or action in action_table_row(sym); procedure Report_Conflict(R: Rule; Sym : in Grammar_Symbol) is begin if Show_Verbose then Verbose_File.Write("*** Conflict on input "); Verbose_File.Print_Grammar_Symbol(Sym); Verbose_File.Write_Line; Verbose_File.Write(Ascii.Ht); Verbose_File.Write("Reduce " & Rule'Image(R)); Verbose_File.Write(Ascii.Ht); Verbose_File.Write("or"); Verbose_File.Write(Ascii.Ht); end if; case Action_Table_Row(Sym).Action is when Shift => Num_Shift_Reduce_Conflicts := Num_Shift_Reduce_Conflicts + 1; if Show_Verbose then Verbose_File.Write("Shift "); Verbose_File.Write_Line (Parse_State'Image(Action_Table_Row(Sym).State_ID)); end if; when Reduce => Num_Reduce_Reduce_Conflicts := Num_Reduce_Reduce_Conflicts + 1; if Show_Verbose then Verbose_File.Write("Reduce "); Verbose_File.Write_Line (Rule'Image(Action_Table_Row(Sym).Rule_ID)); end if; when Accept_Input => if Show_Verbose then Verbose_File.Write("Accept???"); -- won't happen end if; Put_Line("Ayacc: Internal Error in Report Conflict!"); when Error => if Show_Verbose then Verbose_File.Write_Line("Error???"); -- won't happen end if; Put_Line("Ayacc: Internal Error in Report Conflict!"); when Undefined => Put_Line("Ayacc: Internal Error in Report Conflict!"); end case; if Show_Verbose then Verbose_File.Write_Line; end if; end; begin Action_Table_Row := new Action_Table_Array (First_Symbol(Terminal)..Last_Symbol(Terminal)); Goto_Table_Row := new Goto_Table_Array (First_Symbol(Nonterminal)..Last_Symbol(Nonterminal)); Init_Table_Files; for S in First_Parse_State..Last_Parse_State loop --& The verdix compiler apparently ALOCATES more memory for the following --& assignments. We commented them out and replaced these statements by --& the for loops --& action_table_row.all := --& (action_table_row.all'range => (action => undefined)); --& goto_table_row.all := --& (goto_table_row.all'range => null_parse_state); for I in Action_Table_Row.all'range loop Action_Table_Row(I) := (Action => Undefined); end loop; for I in Goto_Table_Row.all'range loop Goto_Table_Row(I) := Null_Parse_State; end loop; Make_Null(Item_Set_1); Get_Kernel(S, Item_Set_1); if Show_Verbose then Verbose_File.Write_Line("------------------"); Verbose_File.Write_Line("State " & Parse_State'Image(S)); Verbose_File.Write_Line; Verbose_File.Write_Line("Kernel"); Verbose_File.Print_Item_Set(Item_Set_1); end if; Closure(Item_Set_1); if Show_Verbose then Verbose_File.Write_Line; Verbose_File.Write_Line("Closure"); Verbose_File.Print_Item_Set(Item_Set_1); Verbose_File.Write_Line; Verbose_File.Write_Line; end if; -- Make Shift Entries -- Initialize(Term_Iter, S); while More(Term_Iter) loop Next(Term_Iter, Trans); if Trans.Symbol = End_Symbol then Action_Table_Row(Trans.Symbol) := (Action => Accept_Input); else Action_Table_Row(Trans.Symbol) := (Action => Shift, State_ID => Trans.State_ID); end if; end loop; -- Make Goto Entries -- Initialize(Nonterm_Iter, S); while More(Nonterm_Iter) loop Next(Nonterm_Iter, Trans); Goto_Table_Row(Trans.Symbol) := Trans.State_ID; end loop; -- Make Reduce Entries ---- Initialize(Item_Iter, Item_Set_1); -- check for degenerate reduce -- if Size_of(Item_Set_1) = 1 then Next(Item_Iter, Temp_Item); if Temp_Item.Dot_Position = Length_of(Temp_Item.Rule_ID) and then Temp_Item.Rule_ID /= First_Rule then Action_Table_Row(First_Symbol(Terminal)) := (Action => Reduce, Rule_ID => Temp_Item.Rule_ID); end if; goto Continue_Loop; end if; -- The following is really messy. It used to be ok before -- we added precedence. Some day we should rewrite it. while More(Item_Iter) loop Next(Item_Iter, Temp_Item); if Temp_Item.Dot_Position = Length_of(Temp_Item.Rule_ID) and then Temp_Item.Rule_ID /= First_Rule then Make_Null(Lookahead_Set); Get_LA(S, Temp_Item, Lookahead_Set); Initialize(Sym_Iter, Lookahead_Set); while More(Sym_Iter) loop Next(Sym_Iter, Sym); case Action_Table_Row(Sym).Action is when Undefined => Action_Table_Row(Sym) := (Action => Reduce, Rule_ID => Temp_Item.Rule_ID); when Shift => Sym_Prec := Get_Precedence(Sym); Rule_Prec := Get_Rule_Precedence(Temp_Item.Rule_ID); if Sym_Prec = 0 or else Rule_Prec = 0 then Report_Conflict(Temp_Item.Rule_ID, Sym); elsif Rule_Prec > Sym_Prec then Action_Table_Row(Sym) := (Action => Reduce, Rule_ID => Temp_Item.Rule_ID); elsif Sym_Prec > Rule_Prec then null; -- already ok else Sym_Assoc := Get_Associativity(Sym); if Sym_Assoc = Left_Associative then Action_Table_Row(Sym) := (Action => Reduce, Rule_ID => Temp_Item.Rule_ID); elsif Sym_Assoc = Right_Associative then null; elsif Sym_Assoc = Nonassociative then Action_Table_Row(Sym) := (Action => Error); else Put_Line("Ayacc: Possible Error in " & "Conflict Resolution."); end if; end if; when Reduce => Report_Conflict(Temp_Item.Rule_ID, Sym); when Error => Put_Line("Ayacc: Internal Error in Conflict!!!"); Put_Line("Ayacc: Use Verbose Option!"); Report_Conflict(Temp_Item.Rule_ID, Sym); when Accept_Input => Put_Line("Ayacc: Internal Error in Conflict!!!"); Put_Line("Ayacc: Use Verbose Option!"); Report_Conflict(Temp_Item.Rule_ID, Sym); end case; end loop; end if; end loop; <<Continue_Loop>> if Show_Verbose then Print_Goto_Row_Verbose; end if; Print_Goto_Row(S); Print_Action_Row(S); end loop; Finish_Table_Files; end Compute_Parse_Table; procedure Make_Parse_Table is begin Show_Verbose := Options.Verbose; if Show_Verbose then Verbose_File.Open; end if; Symbol_Info.Initialize; if Options.Loud then Put_Line("Ayacc: Making LR(0) Machine."); end if; LR0_Machine.LR0_Initialize; if Options.Loud then Put_Line("Ayacc: Making Follow Sets."); end if; Make_LALR_Sets; if Options.Loud then Put_Line("Ayacc: Making Parse Table."); end if; Compute_Parse_Table; if Show_Verbose then Verbose_File.Close; end if; end Make_Parse_Table; end Parse_Table;
src/Data/FingerTree/Split/Point.agda
oisdk/agda-indexed-fingertree
1
14261
<reponame>oisdk/agda-indexed-fingertree<gh_stars>1-10 {-# OPTIONS --without-K --safe #-} open import Algebra open import Relation.Unary open import Relation.Binary hiding (Decidable) module Data.FingerTree.Split.Point {r m} (ℳ : Monoid r m) {s} {ℙ : Pred (Monoid.Carrier ℳ) s} (ℙ-resp : ℙ Respects (Monoid._≈_ ℳ)) (ℙ? : Decidable ℙ) where open import Relation.Nullary using (¬_; yes; no; Dec) open import Level using (_⊔_) open import Data.Product open import Function open import Data.List as List using (List; _∷_; []) open import Data.FingerTree.Measures ℳ open import Data.FingerTree.Reasoning ℳ open import Relation.Nullary using (Dec; yes; no) open import Relation.Nullary.Decidable using (True; toWitness; False; toWitnessFalse) open σ ⦃ ... ⦄ open Monoid ℳ renaming (Carrier to 𝓡) open import Data.FingerTree.Relation.Binary.Reasoning.FasterInference.Setoid setoid infixr 5 _∣_ record _∣_ (left focus : 𝓡) : Set s where constructor ¬[_]ℙ[_] field ¬ℙ : ¬ ℙ left !ℙ : ℙ (left ∙ focus) open _∣_ public _∣?_ : ∀ x y → Dec (x ∣ y) x ∣? y with ℙ? x ... | yes p = no λ c → ¬ℙ c p ... | no ¬p with ℙ? (x ∙ y) ... | no ¬c = no (¬c ∘ !ℙ) ... | yes p = yes ¬[ ¬p ]ℙ[ p ] infixl 2 _≈◄⟅_⟆ _≈▻⟅_⟆ _≈⟅_∣_⟆ _◄_ _▻_ _◄_ : ∀ {l f₁ f₂} → l ∣ f₁ ∙ f₂ → ¬ ℙ (l ∙ f₁) → (l ∙ f₁) ∣ f₂ !ℙ (p ◄ ¬ℙf) = ℙ-resp (sym (assoc _ _ _)) (!ℙ p) ¬ℙ (p ◄ ¬ℙf) = ¬ℙf _▻_ : ∀ {l f₁ f₂} → l ∣ f₁ ∙ f₂ → ℙ (l ∙ f₁) → l ∣ f₁ !ℙ (p ▻ ℙf) = ℙf ¬ℙ (p ▻ ℙf) = ¬ℙ p _≈◄⟅_⟆ : ∀ {x y z} → x ∣ y → x ≈ z → z ∣ y ¬ℙ (x⟅y⟆ ≈◄⟅ x≈z ⟆) = ¬ℙ x⟅y⟆ ∘ ℙ-resp (sym x≈z) !ℙ (x⟅y⟆ ≈◄⟅ x≈z ⟆) = ℙ-resp (≪∙ x≈z) (!ℙ x⟅y⟆) _≈▻⟅_⟆ : ∀ {x y z} → x ∣ y → y ≈ z → x ∣ z ¬ℙ (x⟅y⟆ ≈▻⟅ y≈z ⟆) = ¬ℙ x⟅y⟆ !ℙ (x⟅y⟆ ≈▻⟅ y≈z ⟆) = ℙ-resp (∙≫ y≈z) (!ℙ x⟅y⟆) _≈⟅_∣_⟆ : ∀ {x₁ y₁ x₂ y₂} → x₁ ∣ y₁ → x₁ ≈ x₂ → y₁ ≈ y₂ → x₂ ∣ y₂ ¬ℙ (x⟅y⟆ ≈⟅ x≈ ∣ y≈ ⟆) = ¬ℙ x⟅y⟆ ∘ ℙ-resp (sym x≈) !ℙ (x⟅y⟆ ≈⟅ x≈ ∣ y≈ ⟆) = ℙ-resp (∙-cong x≈ y≈) (!ℙ x⟅y⟆) ¬∄ℙ : ∀ {i} → ¬ (i ∣ ε) ¬∄ℙ i⟅ε⟆ = ¬ℙ i⟅ε⟆ (ℙ-resp (identityʳ _) (!ℙ i⟅ε⟆))
Transynther/x86/_processed/NONE/_xt_/i7-8650U_0xd2.log_4594_1473.asm
ljhsiun2/medusa
9
1535
<filename>Transynther/x86/_processed/NONE/_xt_/i7-8650U_0xd2.log_4594_1473.asm .global s_prepare_buffers s_prepare_buffers: push %r10 push %r11 push %r12 push %r9 push %rbp push %rcx push %rsi lea addresses_normal_ht+0xadd0, %rbp dec %r11 mov $0x6162636465666768, %rcx movq %rcx, %xmm1 vmovups %ymm1, (%rbp) nop nop add $10680, %rsi lea addresses_WC_ht+0x64e8, %r12 nop nop nop nop add %r10, %r10 mov $0x6162636465666768, %r9 movq %r9, (%r12) dec %r12 lea addresses_normal_ht+0x3e68, %r9 nop nop cmp $31629, %r11 mov $0x6162636465666768, %r10 movq %r10, %xmm7 and $0xffffffffffffffc0, %r9 vmovaps %ymm7, (%r9) nop nop nop nop cmp $33961, %rsi lea addresses_WC_ht+0x1e46a, %r9 nop nop sub $45277, %r12 mov (%r9), %r10 nop nop nop nop nop xor %rsi, %rsi lea addresses_D_ht+0x16968, %r9 nop nop nop add %r12, %r12 movw $0x6162, (%r9) nop nop nop xor %rbp, %rbp lea addresses_D_ht+0x8ce8, %r11 and $28338, %r10 movups (%r11), %xmm7 vpextrq $0, %xmm7, %rsi nop nop nop cmp $39768, %r11 lea addresses_WT_ht+0x160e8, %r11 nop nop nop nop nop dec %rcx mov (%r11), %ebp nop nop add $9766, %rsi lea addresses_WT_ht+0x19ce8, %r10 nop nop cmp %rbp, %rbp mov (%r10), %ecx nop nop nop nop sub %r12, %r12 lea addresses_normal_ht+0x16edc, %r12 nop cmp %r10, %r10 mov $0x6162636465666768, %r11 movq %r11, (%r12) nop nop nop nop nop add $53181, %rsi pop %rsi pop %rcx pop %rbp pop %r9 pop %r12 pop %r11 pop %r10 ret .global s_faulty_load s_faulty_load: push %r10 push %r14 push %r8 push %r9 push %rcx push %rdx // Store mov $0x49c84500000008a8, %r9 nop add $56075, %rdx movw $0x5152, (%r9) and %r10, %r10 // Faulty Load lea addresses_normal+0x16ce8, %r8 clflush (%r8) xor %rcx, %rcx movb (%r8), %r9b lea oracles, %r14 and $0xff, %r9 shlq $12, %r9 mov (%r14,%r9,1), %r9 pop %rdx pop %rcx pop %r9 pop %r8 pop %r14 pop %r10 ret /* <gen_faulty_load> [REF] {'OP': 'LOAD', 'src': {'type': 'addresses_normal', 'size': 16, 'AVXalign': False, 'NT': False, 'congruent': 0, 'same': False}} {'OP': 'STOR', 'dst': {'type': 'addresses_NC', 'size': 2, 'AVXalign': False, 'NT': False, 'congruent': 5, 'same': False}} [Faulty Load] {'OP': 'LOAD', 'src': {'type': 'addresses_normal', 'size': 1, 'AVXalign': False, 'NT': False, 'congruent': 0, 'same': True}} <gen_prepare_buffer> {'OP': 'STOR', 'dst': {'type': 'addresses_normal_ht', 'size': 32, 'AVXalign': False, 'NT': False, 'congruent': 3, 'same': False}} {'OP': 'STOR', 'dst': {'type': 'addresses_WC_ht', 'size': 8, 'AVXalign': False, 'NT': False, 'congruent': 11, 'same': False}} {'OP': 'STOR', 'dst': {'type': 'addresses_normal_ht', 'size': 32, 'AVXalign': True, 'NT': False, 'congruent': 7, 'same': True}} {'OP': 'LOAD', 'src': {'type': 'addresses_WC_ht', 'size': 8, 'AVXalign': False, 'NT': False, 'congruent': 0, 'same': False}} {'OP': 'STOR', 'dst': {'type': 'addresses_D_ht', 'size': 2, 'AVXalign': False, 'NT': False, 'congruent': 6, 'same': False}} {'OP': 'LOAD', 'src': {'type': 'addresses_D_ht', 'size': 16, 'AVXalign': False, 'NT': False, 'congruent': 10, 'same': False}} {'OP': 'LOAD', 'src': {'type': 'addresses_WT_ht', 'size': 4, 'AVXalign': False, 'NT': False, 'congruent': 8, 'same': False}} {'OP': 'LOAD', 'src': {'type': 'addresses_WT_ht', 'size': 4, 'AVXalign': False, 'NT': True, 'congruent': 10, 'same': False}} {'OP': 'STOR', 'dst': {'type': 'addresses_normal_ht', 'size': 8, 'AVXalign': False, 'NT': False, 'congruent': 2, 'same': False}} {'34': 4594} 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 */
Numeral/Natural/LinearSearch.agda
Lolirofle/stuff-in-agda
6
11726
<reponame>Lolirofle/stuff-in-agda module Numeral.Natural.LinearSearch where open import Data.Boolean open import Data.Boolean.Stmt open import Data.List import Data.List.Functions as List open import Data.List.Relation.Membership using (_∈_) open import Data.List.Relation.Membership.Proofs open import Data.List.Relation.Quantification open import Data.List.Relation.Quantification.Proofs open import Data.List.Sorting open import Functional open import Logic.Propositional open import Numeral.Finite import Numeral.Finite.LinearSearch as 𝕟 open import Numeral.Natural open import Numeral.Natural.Oper open import Numeral.Natural.Oper.Comparisons open import Numeral.Natural.Relation.Order open import Relator.Equals open import Relator.Equals.Proofs.Equiv open import Structure.Function private variable a b n i j : ℕ private variable f : ℕ → Bool {- findBoundedMin : ℕ → ℕ → (ℕ → Bool) → Option(ℕ) findBoundedMin a b f = Option.map 𝕟-to-ℕ (𝕟.findMin{b −₀ a}(f ∘ (_+ a) ∘ 𝕟-to-ℕ)) findBoundedMin-None-correctness : (a < b) → (findBoundedMin a b f ≡ None) ↔ (∀{i} → (a ≤ i) → (i < b) → IsFalse(f(i))) findBoundedMin-None-correctness{a}{b}{f} ab with [↔]-intro l r ← 𝕟.findMin-None-correctness{b −₀ a}{f ∘ (_+ a) ∘ 𝕟-to-ℕ} = [↔]-intro (\p → congruence₁(Option.map 𝕟-to-ℕ) (l (\{i} → p ([≤]-of-[+]ᵣ {𝕟-to-ℕ i}) {![<]-with-[+]-weak ([∨]-introₗ ([∧]-intro ? ?))!}))) (\p{i} ai ib → {!r ? {?}!}) -} findBoundedAll : ℕ → ℕ → (ℕ → Bool) → List(ℕ) findBoundedAll a b f = List.map ((_+ a) ∘ 𝕟-to-ℕ) (𝕟.findAll{b −₀ a} (f ∘ (_+ a) ∘ 𝕟-to-ℕ)) findBoundedAll-correctness : AllElements(IsTrue ∘ f)(findBoundedAll a b f) findBoundedAll-correctness {f} {a} {b} with 𝕟.findAll{b −₀ a} (f ∘ (_+ a) ∘ 𝕟-to-ℕ) | 𝕟.findAll-correctness{b −₀ a}{f ∘ (_+ a) ∘ 𝕟-to-ℕ} ... | ∅ | ∅ = ∅ ... | _ ⊰ _ | p ⊰ ps = p ⊰ AllElements-mapᵣ ((_+ a) ∘ 𝕟-to-ℕ) id ps postulate findBoundedAll-completeness : IsTrue(f(i)) → (a ≤ i) → (i < b) → (i ∈ findBoundedAll a b f) -- findBoundedAll-completeness {f}{i}{a}{b} ai ib fi = {![∈]-map {f = 𝕟-to-ℕ} (𝕟.findAll-completeness{b −₀ a}{f ∘ (_+ a) ∘ 𝕟-to-ℕ}{ℕ-to-𝕟 (i −₀ a) ⦃ ? ⦄} ?)!} postulate findBoundedAll-emptyness : (∀{i} → (a ≤ i) → (i < b) → IsFalse(f(i))) ↔ (findBoundedAll a b f ≡ ∅) postulate findBoundedAll-sorted : Sorted(_≤?_)(findBoundedAll a b f) postulate findBoundedAll-membership : (i ∈ findBoundedAll a b f) ↔ ((a ≤ i) ∧ (i < b) ∧ IsTrue(f(i)))
oeis/018/A018806.asm
neoneye/loda-programs
11
84909
; A018806: Sum of gcd(x, y) for 1 <= x, y <= n. ; Submitted by <NAME> ; 1,5,12,24,37,61,80,112,145,189,220,288,325,389,464,544,593,701,756,880,989,1093,1160,1336,1441,1565,1700,1880,1965,2205,2296,2488,2665,2829,3028,3328,3437,3621,3832,4152,4273,4621,4748,5040,5373,5597,5736,6168,6385,6725,7004,7352,7509,7941,8264,8728,9041,9325,9500,10160,10341,10645,11128,11576,11961,12525,12724,13184,13565,14197,14408,15176,15393,15757,16332,16848,17317,17989,18224,19008,19521,19925,20172,21128,21637,22061,22544,23296,23561,24605,25164,25792,26309,26773,27344,28368,28657,29357 mov $3,$0 mov $5,$0 lpb $3 mov $0,$5 sub $3,1 sub $0,$3 mov $2,$0 seq $0,18804 ; Pillai's arithmetical function: Sum_{k=1..n} gcd(k, n). sub $2,$0 sub $0,$2 sub $0,1 add $4,$0 lpe mov $0,$4 add $0,1
audio/music/lookpokemaniac.asm
Dev727/ancientplatinum
28
29201
<reponame>Dev727/ancientplatinum Music_LookPokemaniac: musicheader 3, 1, Music_LookPokemaniac_Ch1 musicheader 1, 2, Music_LookPokemaniac_Ch2 musicheader 1, 3, Music_LookPokemaniac_Ch3 Music_LookPokemaniac_Ch1: stereopanning $f tempo 144 volume $77 vibrato $2, $33 tone $0002 notetype $c, $b3 note __, 8 Music_LookPokemaniac_branch_ebdfb: note __, 4 octave 3 note A#, 1 note __, 3 note A#, 1 note __, 3 loopchannel 4, Music_LookPokemaniac_branch_ebdfb note __, 4 note G_, 1 note __, 3 note G_, 1 note __, 3 loopchannel 4, Music_LookPokemaniac_branch_ebdfb loopchannel 0, Music_LookPokemaniac_branch_ebdfb Music_LookPokemaniac_Ch2: stereopanning $ff vibrato $2, $33 tone $0001 notetype $c, $b3 octave 2 note A_, 1 note F#, 1 note D#, 1 note C_, 1 octave 1 note A_, 4 Music_LookPokemaniac_branch_ebe24: octave 2 note C_, 2 note __, 2 octave 3 note F#, 1 note __, 3 note A_, 1 note __, 3 octave 1 note G_, 2 note __, 2 octave 3 note C_, 1 note __, 3 note D#, 1 note __, 3 loopchannel 2, Music_LookPokemaniac_branch_ebe24 Music_LookPokemaniac_branch_ebe38: octave 1 note A_, 2 note __, 2 octave 3 note D#, 1 note __, 3 note F#, 1 note __, 3 octave 1 note E_, 2 note __, 2 octave 2 note A_, 1 note __, 3 octave 3 note C_, 1 note __, 3 loopchannel 2, Music_LookPokemaniac_branch_ebe38 loopchannel 0, Music_LookPokemaniac_branch_ebe24 Music_LookPokemaniac_Ch3: stereopanning $f0 vibrato $6, $33 notetype $c, $15 octave 4 note C_, 1 note D#, 1 note F#, 1 note A_, 1 octave 5 note C_, 4 intensity $10 Music_LookPokemaniac_branch_ebe62: callchannel Music_LookPokemaniac_branch_ebe70 intensity $14 callchannel Music_LookPokemaniac_branch_ebe70 intensity $10 loopchannel 0, Music_LookPokemaniac_branch_ebe62 Music_LookPokemaniac_branch_ebe70: note A#, 6 note A_, 2 note G#, 2 note G_, 2 note F#, 6 note F_, 2 note F#, 2 note A_, 2 octave 4 note D#, 4 note C_, 1 note __, 1 note D#, 1 note __, 1 note C_, 1 note __, 1 note D#, 1 note __, 1 octave 5 note F#, 4 note C_, 1 note __, 1 note F#, 1 note __, 1 note C_, 1 note __, 1 note F#, 1 note __, 1 note G_, 6 note F#, 2 note F_, 2 note E_, 2 note D#, 6 note D_, 2 note D#, 2 note F#, 2 note C_, 4 octave 4 note A_, 1 note __, 1 octave 5 note C_, 1 note __, 1 note D#, 1 note __, 1 note C_, 1 note __, 1 note D#, 4 octave 4 note A_, 1 note __, 1 octave 5 note D#, 1 note __, 1 note F#, 1 note __, 1 note C_, 1 note __, 1 endchannel
agda-stdlib/src/Data/Product/N-ary.agda
DreamLinuxer/popl21-artifact
5
14693
------------------------------------------------------------------------ -- The Agda standard library -- -- This module is DEPRECATED. Please use Data.Vec.Recursive instead. ------------------------------------------------------------------------ {-# OPTIONS --without-K --safe #-} module Data.Product.N-ary where {-# WARNING_ON_IMPORT "Data.Product.N-ary was deprecated in v1.1. Use Data.Vec.Recursive instead." #-} open import Data.Vec.Recursive public
MSX/rddev.asm
Konamiman/NestorDevice
1
105100
; USB keyboard reporter for MSX using a CH372/5/6 ; By Konamiman, 7/2021 ; ; Configures the CH372 in internal firmware mode and checks ; the keyboard status continuously, if there's any change ; it sends two bytes (row number + row data) to interrupt ; endpoint 81h. ; ; A circular queue is used in case keyboard status changes ; happen faster than the USB host reads them from the endpoint. ;************* ;* Constants * ;************* ;* Configuration ;Device identification ;NOTE! If you change these, update INFO_S too VID_LOW: equ 09h VID_HIGH: equ 12h PID_LOW: equ 07h PID_HIGH: equ 00h ;0: Generate .BIN file ;1: Generate ROM file ROM: equ 1 ;How many keyboard rows to scan ROWS_COUNT: equ 12 ;1: Print bytes sent as well as SUSPEND and WAKEUP eventts DEBUG_LOG: equ 0 ;* MSX BIOS and work area INITXT: equ 006Ch CHGET: equ 009Fh CHPUT: equ 00A2h ERAFNK: equ 00CCh SNSMAT: equ 0141h KILBUF: equ 0156h LINL40: equ 0F3AEh ;* Z80 ports where the CH372 ports are mapped CH_DATA_PORT: equ 20h CH_COMMAND_PORT: equ 21h ;* CH372 commands GET_IC_VER: equ 01h ENTER_SLEEP: equ 03h RESET_ALL: equ 05h CHECK_EXIST: equ 06h CHK_SUSPEND: equ 0Bh SET_USB_ID: equ 12h SET_USB_MODE: equ 15h GET_STATUS: equ 22h UNLOCK_USB: equ 23h RD_USB_DATA0: equ 27h RD_USB_DATA: equ 28h WR_USB_DATA5_1: equ 2Ah WR_USB_DATA7_2: equ 2Bh ;* CH372 operation status CMD_RET_SUCCESS: equ 51h CMD_RET_ABORT: equ 5Fh ;* CH372 interruption status INT_EP1_OUT: equ 01h INT_EP1_IN: equ 09h INT_EP2_OUT: equ 02h INT_EP2_IN: equ 0Ah INT_USB_SUSP: equ 05h INT_WAKE_UP: equ 06h ;************************* ;* Startup and main loop * ;************************* if ROM=1 org 4000h db 41h,42h dw PROG_START ds 12 else org 0C010h-7 db 0FEh dw PROG_START dw PROG_END dw PROG_START endif PROG_START: ld hl,0 add hl,sp ld (SAVE_SP),hl di call CH_INIT ld a,40 ld (LINL40),a call INITXT call ERAFNK ld hl,INFO_S call PRINT LOOP: ld a,(OLD_KEYS+7) and 10010100b jp z,EXIT ;ENTER+STOP+ESC pressed in a,(CH_COMMAND_PORT) and 80h call z,HANDLE_CH_INT ;* Check keys, if there are changes send them ld hl,OLD_KEYS ld de,NEW_KEYS ld b,0 SNSLOOP: ld a,b call SNSMAT cp (hl) jr z,SNSLOOP_END ld (de),a ld c,a if DEBUG_LOG = 1 push bc ld a,b call PRINTHEX ld a,' ' call CHPUT ld a,c call PRINTHEX push hl push de ld hl,CRLF_S call PRINT pop de pop hl pop bc endif ld a,b call QUEUE_WR ld a,c call QUEUE_WR SNSLOOP_END: inc hl inc de inc b ld a,b cp ROWS_COUNT jr c,SNSLOOP ld hl,NEW_KEYS ld de,OLD_KEYS ld bc,ROWS_COUNT ldir call SEND_EP1_DATA jr LOOP ;**************************** ;* CH372 and variables init * ;**************************** CH_INIT: ld a,RESET_ALL out (CH_COMMAND_PORT),a ei halt halt di ld a,CHECK_EXIST out (CH_COMMAND_PORT),a ld a,0A8h out (CH_DATA_PORT),a in a,(CH_DATA_PORT) cp 57h ld hl,NO_CH_S jp nz,PREXIT ei halt halt di ld a,SET_USB_ID out (CH_COMMAND_PORT),a ld a,VID_LOW out (CH_DATA_PORT),a ld a,VID_HIGH out (CH_DATA_PORT),a ld a,PID_LOW out (CH_DATA_PORT),a ld a,PID_HIGH out (CH_DATA_PORT),a ld a,SET_USB_MODE out (CH_COMMAND_PORT),a xor a ;Invalid device mode out (CH_DATA_PORT),a ei halt halt di in a,(CH_DATA_PORT) cp CMD_RET_SUCCESS ld hl,CH_MODE_ERR_S jp nz,PREXIT ld a,SET_USB_MODE out (CH_COMMAND_PORT),a ld a,2 ;Internal firmware mode out (CH_DATA_PORT),a ei halt halt di in a,(CH_DATA_PORT) cp CMD_RET_SUCCESS ld hl,CH_MODE_ERR_S jp nz,PREXIT ld a,CHK_SUSPEND out (CH_COMMAND_PORT),a ld a,10h out (CH_DATA_PORT),a ld a,04h out (CH_DATA_PORT),a call CLEAR_VARS ret CLEAR_VARS: ld a,0FFh ld (OLD_KEYS),a ld hl,OLD_KEYS ld de,OLD_KEYS+1 ld bc,ROWS_COUNT-1 ldir ld hl,OLD_KEYS ld de,NEW_KEYS ld bc,ROWS_COUNT ldir call QUEUE_INIT ret ;*************************** ;* Handle CH372 interrupts * ;*************************** HANDLE_CH_INT: ld a,GET_STATUS out (CH_COMMAND_PORT),a in a,(CH_DATA_PORT) cp INT_USB_SUSP jp z,HANDLE_SUSPEND ;All interrupts except SUSPEND ;require UNLOCK_USB execution at the end ld hl,DO_UNLOCK push hl cp INT_WAKE_UP jp z,HANDLE_WAKEUP cp INT_EP1_IN jp z,HANDLE_EP1_IN if DEBUG_LOG = 1 ld hl,UNK_INT_S push af call PRINT pop af call PRINTHEX ld hl,CRLF_S call PRINT endif ret DO_UNLOCK: ld a,UNLOCK_USB out (CH_COMMAND_PORT),a ret ;--- Handle SUSPEND, WAKE UP interrupts HANDLE_SUSPEND: ld a,ENTER_SLEEP out (CH_COMMAND_PORT),a if DEBUG_LOG=1 ld hl,SUSPEND_S call PRINT endif ret HANDLE_WAKEUP: if DEBUG_LOG=1 ld hl,WAKEUP_S call PRINT endif ret ;--- Handle EP1 IN token received interrupt HANDLE_EP1_IN: call SEND_EP1_DATA ret ;--- Send interrupt endpoint data SEND_EP1_DATA: ld a,(QUEUE_LEN) or a ret z cp 8+1 jr c,SEND_EP1_DATA2 ld a,8 SEND_EP1_DATA2: ld b,a ;B = amount of bytes to send ld a,WR_USB_DATA5_1 out (CH_COMMAND_PORT),a ld a,b out (CH_DATA_PORT),a ld c,CH_DATA_PORT SEND_EP1_LOOP: call QUEUE_RD out (c),a djnz SEND_EP1_LOOP ret ;**************** ;* MSX specific * ;**************** ;--- Print string passed in HL, then exit PREXIT: call PRINT if ROM=1 ld hl,PRESSK_S call PRINT call CHGET endif ;--- Exit program EXIT: ld a,SET_USB_MODE out (CH_COMMAND_PORT),a xor a ;Invalid device mode out (CH_DATA_PORT),a call KILBUF ld hl,(SAVE_SP) ld sp,hl ret ;--- Print zero-terminated string passed in HL PRINT: ld a,(hl) or a ret z call CHPUT di inc hl jr PRINT if DEBUG_LOG = 1 ;--- Print byte passed in A in hex PRINTHEX: push af call _PRINTHEX_1 pop af push af call _PRINTHEX_2 pop af ret _PRINTHEX_1: rra rra rra rra _PRINTHEX_2: or 0F0h daa add a,0A0h adc a,40h call CHPUT ret endif ;****************** ;* Circular queue * ;****************** ;Queue size is 256 bytes (actually only 254 are used) ;--- Initialize queue QUEUE_INIT: ld hl,QUEUE ld (QUEUE_RDPNT),hl ld (QUEUE_WRPNT),hl xor a ld (QUEUE_LEN),a ret ;--- Write one byte to the queue, except if it's full ; Input: A = byte ; Output: Cy = 1 if queue is full QUEUE_WR: push hl push bc ld b,a ld a,(QUEUE_LEN) inc a cp 255 scf jr z,QUEUE_WR_END ld (QUEUE_LEN),a ld hl,(QUEUE_WRPNT) ld (hl),b inc l ld (QUEUE_WRPNT),hl or a QUEUE_WR_END: pop bc pop hl ret ;--- Read one byte from the queue ; Output: A = byte ; Cy = 1 if queue is empty QUEUE_RD: push hl ld a,(QUEUE_LEN) or a scf jr z,QUEUE_RD_END dec a ld (QUEUE_LEN),a ld hl,(QUEUE_RDPNT) ld a,(hl) inc l ld (QUEUE_RDPNT),hl or a QUEUE_RD_END: pop hl DO_RET: ret ;*********** ;* Strings * ;*********** INFO_S: db "I'm an USB device, VID=1209h, PID=0007h",13,10 db 13,10 db "I'll send changes in keyboard status",13,10 db "to endpoint 81h (max length: 8 bytes)",13,10 db "as byte pairs: row number, row data",13,10 db 13,10 db "Exit: ESC + ENTER + STOP",13,10 if ROM=0 db " (press STOP last)",13,10 endif db 27,120,53 ;Hide the cursor db 0 NO_CH_S: db "*** CH732 not found" CRLF_S: db 13,10,0 CH_MODE_ERR_S: db "*** Error setting USB mode",13,10,0 UNK_INT_S: db "*** Unknown interrupt received: ",0 if ROM = 1 PRESSK_S: db 13,10,"Press any key to exit ",0 endif if DEBUG_LOG = 1 SUSPEND_S: db "SUSPEND",13,10,0 WAKEUP_S: db "WAKEUP",13,10,0 endif PROG_END: ;************* ;* Variables * ;************* if ROM=1 VAR_START: equ 0C400h else VAR_START: endif ;Stack pointer at program start time, ;used to restore it at exit time SAVE_SP: equ VAR_START ;Previous state of keyboard, one byte per row OLD_KEYS: equ SAVE_SP+2 ;Current state of keyboard, one byte per row NEW_KEYS: equ OLD_KEYS+ROWS_COUNT ;Circular queue address, pointers and length QUEUE_WRPNT: equ NEW_KEYS+ROWS_COUNT QUEUE_RDPNT: equ QUEUE_WRPNT+2 QUEUE_LEN: equ QUEUE_RDPNT+2 QUEUE: equ 0C500h if ROM=1 ;Force ROM size to be 16K to make emulators and flash loaders happy ds 8000h-$,0FFh endif
programs/oeis/192/A192376.asm
neoneye/loda
22
85410
; A192376: Constant term of the reduction by x^2->x+2 of the polynomial p(n,x) defined below in Comments. ; 1,0,7,16,73,256,975,3616,13521,50432,188247,702512,2621849,9784832,36517535,136285248,508623521,1898208768,7084211623,26438637648,98670339049,368242718464,1374300534895,5128959421024,19141537149297,71437189176064 mov $5,2 mov $14,$0 lpb $5 mov $0,$14 sub $5,1 add $0,$5 sub $0,1 mov $10,$0 mov $11,0 mov $12,2 lpb $12 mov $0,$10 mov $7,0 sub $12,1 add $0,$12 sub $0,1 mov $6,$0 mov $8,2 lpb $8 mov $0,$6 mov $3,0 sub $8,1 add $0,$8 lpb $0 mov $2,$0 trn $0,2 max $2,0 seq $2,109437 ; a(-1) = a(0) = 0, a(1) = 1; a(n) = 5a(n-1) - 5a(n-2) + a(n-3) + 2*(-1)^(n+1), alternatively a(n) = 3a(n-1) + 3a(n-2) - a(n-3). add $3,$2 lpe mov $9,$8 mul $9,$3 add $7,$9 mov $15,$3 lpe min $6,1 mul $6,$15 mov $13,$12 mov $15,$7 sub $15,$6 mul $15,2 mul $13,$15 add $11,$13 lpe mov $4,$5 min $10,1 mul $10,$15 mov $15,$11 sub $15,$10 mul $4,$15 add $1,$4 lpe min $14,1 mul $14,$15 sub $1,$14 div $1,2 mov $0,$1
src/test/ref/typedef-1.asm
jbrandwood/kickc
2
15182
// Commodore 64 PRG executable file .file [name="typedef-1.prg", type="prg", segments="Program"] .segmentdef Program [segments="Basic, Code, Data"] .segmentdef Basic [start=$0801] .segmentdef Code [start=$80d] .segmentdef Data [startAfter="Code"] .segment Basic :BasicUpstart(main) .const OFFSET_STRUCT_POINTDEF_Y = 1 .segment Code main: { .const p_x = 4 .const p_y = 7 .label SCREEN = $400 // *SCREEN = p lda #p_x sta SCREEN lda #p_y sta SCREEN+OFFSET_STRUCT_POINTDEF_Y // } rts }
src/fltk-widgets-valuators-value_inputs.adb
micahwelf/FLTK-Ada
1
1405
with Ada.Unchecked_Deallocation, Interfaces.C.Strings, System; use type Interfaces.C.int, System.Address; package body FLTK.Widgets.Valuators.Value_Inputs is procedure value_input_set_draw_hook (W, D : in System.Address); pragma Import (C, value_input_set_draw_hook, "value_input_set_draw_hook"); pragma Inline (value_input_set_draw_hook); procedure value_input_set_handle_hook (W, H : in System.Address); pragma Import (C, value_input_set_handle_hook, "value_input_set_handle_hook"); pragma Inline (value_input_set_handle_hook); function new_fl_value_input (X, Y, W, H : in Interfaces.C.int; Text : in Interfaces.C.char_array) return System.Address; pragma Import (C, new_fl_value_input, "new_fl_value_input"); pragma Inline (new_fl_value_input); procedure free_fl_value_input (A : in System.Address); pragma Import (C, free_fl_value_input, "free_fl_value_input"); pragma Inline (free_fl_value_input); function fl_value_input_get_input (V : in System.Address) return System.Address; pragma Import (C, fl_value_input_get_input, "fl_value_input_get_input"); pragma Inline (fl_value_input_get_input); function fl_value_input_get_cursor_color (TD : in System.Address) return Interfaces.C.unsigned; pragma Import (C, fl_value_input_get_cursor_color, "fl_value_input_get_cursor_color"); pragma Inline (fl_value_input_get_cursor_color); procedure fl_value_input_set_cursor_color (TD : in System.Address; C : in Interfaces.C.unsigned); pragma Import (C, fl_value_input_set_cursor_color, "fl_value_input_set_cursor_color"); pragma Inline (fl_value_input_set_cursor_color); function fl_value_input_get_shortcut (B : in System.Address) return Interfaces.C.int; pragma Import (C, fl_value_input_get_shortcut, "fl_value_input_get_shortcut"); pragma Inline (fl_value_input_get_shortcut); procedure fl_value_input_set_shortcut (B : in System.Address; T : in Interfaces.C.int); pragma Import (C, fl_value_input_set_shortcut, "fl_value_input_set_shortcut"); pragma Inline (fl_value_input_set_shortcut); function fl_value_input_is_soft (A : in System.Address) return Interfaces.C.int; pragma Import (C, fl_value_input_is_soft, "fl_value_input_is_soft"); pragma Inline (fl_value_input_is_soft); procedure fl_value_input_set_soft (A : in System.Address; T : in Interfaces.C.int); pragma Import (C, fl_value_input_set_soft, "fl_value_input_set_soft"); pragma Inline (fl_value_input_set_soft); function fl_value_input_get_text_color (TD : in System.Address) return Interfaces.C.unsigned; pragma Import (C, fl_value_input_get_text_color, "fl_value_input_get_text_color"); pragma Inline (fl_value_input_get_text_color); procedure fl_value_input_set_text_color (TD : in System.Address; C : in Interfaces.C.unsigned); pragma Import (C, fl_value_input_set_text_color, "fl_value_input_set_text_color"); pragma Inline (fl_value_input_set_text_color); function fl_value_input_get_text_font (TD : in System.Address) return Interfaces.C.int; pragma Import (C, fl_value_input_get_text_font, "fl_value_input_get_text_font"); pragma Inline (fl_value_input_get_text_font); procedure fl_value_input_set_text_font (TD : in System.Address; F : in Interfaces.C.int); pragma Import (C, fl_value_input_set_text_font, "fl_value_input_set_text_font"); pragma Inline (fl_value_input_set_text_font); function fl_value_input_get_text_size (TD : in System.Address) return Interfaces.C.int; pragma Import (C, fl_value_input_get_text_size, "fl_value_input_get_text_size"); pragma Inline (fl_value_input_get_text_size); procedure fl_value_input_set_text_size (TD : in System.Address; S : in Interfaces.C.int); pragma Import (C, fl_value_input_set_text_size, "fl_value_input_set_text_size"); pragma Inline (fl_value_input_set_text_size); procedure fl_value_input_draw (W : in System.Address); pragma Import (C, fl_value_input_draw, "fl_value_input_draw"); pragma Inline (fl_value_input_draw); function fl_value_input_handle (W : in System.Address; E : in Interfaces.C.int) return Interfaces.C.int; pragma Import (C, fl_value_input_handle, "fl_value_input_handle"); pragma Inline (fl_value_input_handle); procedure Free is new Ada.Unchecked_Deallocation (INP.Input, Input_Access); procedure Finalize (This : in out Value_Input) is begin if This.Void_Ptr /= System.Null_Address and then This in Value_Input'Class then free_fl_value_input (This.Void_Ptr); Free (This.My_Input); This.Void_Ptr := System.Null_Address; end if; Finalize (Valuator (This)); end Finalize; package body Forge is function Create (X, Y, W, H : in Integer; Text : in String) return Value_Input is begin return This : Value_Input do This.Void_Ptr := new_fl_value_input (Interfaces.C.int (X), Interfaces.C.int (Y), Interfaces.C.int (W), Interfaces.C.int (H), Interfaces.C.To_C (Text)); fl_widget_set_user_data (This.Void_Ptr, Widget_Convert.To_Address (This'Unchecked_Access)); value_input_set_draw_hook (This.Void_Ptr, Draw_Hook'Address); value_input_set_handle_hook (This.Void_Ptr, Handle_Hook'Address); This.My_Input := new INP.Input; Wrapper (This.My_Input.all).Void_Ptr := fl_value_input_get_input (This.Void_Ptr); Wrapper (This.My_Input.all).Needs_Dealloc := False; end return; end Create; end Forge; function Input (This : in Value_Input) return FLTK.Widgets.Inputs.Input_Reference is begin return (Data => This.My_Input); end Input; function Get_Cursor_Color (This : in Value_Input) return Color is begin return Color (fl_value_input_get_cursor_color (This.Void_Ptr)); end Get_Cursor_Color; procedure Set_Cursor_Color (This : in out Value_Input; Col : in Color) is begin fl_value_input_set_cursor_color (This.Void_Ptr, Interfaces.C.unsigned (Col)); end Set_Cursor_Color; function Get_Shortcut (This : in Value_Input) return Key_Combo is begin return To_Ada (Interfaces.C.unsigned_long (fl_value_input_get_shortcut (This.Void_Ptr))); end Get_Shortcut; procedure Set_Shortcut (This : in out Value_Input; Key : in Key_Combo) is begin fl_value_input_set_shortcut (This.Void_Ptr, Interfaces.C.int (To_C (Key))); end Set_Shortcut; function Is_Soft (This : in Value_Input) return Boolean is begin return fl_value_input_is_soft (This.Void_Ptr) /= 0; end Is_Soft; procedure Set_Soft (This : in out Value_Input; To : in Boolean) is begin fl_value_input_set_soft (This.Void_Ptr, Boolean'Pos (To)); end Set_Soft; function Get_Text_Color (This : in Value_Input) return Color is begin return Color (fl_value_input_get_text_color (This.Void_Ptr)); end Get_Text_Color; procedure Set_Text_Color (This : in out Value_Input; Col : in Color) is begin fl_value_input_set_text_color (This.Void_Ptr, Interfaces.C.unsigned (Col)); end Set_Text_Color; function Get_Text_Font (This : in Value_Input) return Font_Kind is begin return Font_Kind'Val (fl_value_input_get_text_font (This.Void_Ptr)); end Get_Text_Font; procedure Set_Text_Font (This : in out Value_Input; Font : in Font_Kind) is begin fl_value_input_set_text_font (This.Void_Ptr, Font_Kind'Pos (Font)); end Set_Text_Font; function Get_Text_Size (This : in Value_Input) return Font_Size is begin return Font_Size (fl_value_input_get_text_size (This.Void_Ptr)); end Get_Text_Size; procedure Set_Text_Size (This : in out Value_Input; Size : in Font_Size) is begin fl_value_input_set_text_size (This.Void_Ptr, Interfaces.C.int (Size)); end Set_Text_Size; procedure Draw (This : in out Value_Input) is begin fl_value_input_draw (This.Void_Ptr); end Draw; function Handle (This : in out Value_Input; Event : in Event_Kind) return Event_Outcome is begin return Event_Outcome'Val (fl_value_input_handle (This.Void_Ptr, Event_Kind'Pos (Event))); end Handle; end FLTK.Widgets.Valuators.Value_Inputs;
src/instruction-test/hex-immediates.asm
brgmnn/uob-cpu-simulator
0
101929
<reponame>brgmnn/uob-cpu-simulator<filename>src/instruction-test/hex-immediates.asm<gh_stars>0 # tests the assembler and not the simulator. mov r0,#0xff mov r1,#0xaa mov r2,#0b110
alloy4fun_models/trainstlt/models/4/DhStsWnAmGW9oMKMA.als
Kaixi26/org.alloytools.alloy
0
1396
<filename>alloy4fun_models/trainstlt/models/4/DhStsWnAmGW9oMKMA.als open main pred idDhStsWnAmGW9oMKMA_prop5 { always all t : Train { ((t.pos = Exit) implies (no t.pos')) or (t.pos' in t.pos.prox) } } pred __repair { idDhStsWnAmGW9oMKMA_prop5 } check __repair { idDhStsWnAmGW9oMKMA_prop5 <=> prop5o }
dartagnan/src/main/antlr4/LitmusAssertions.g4
3dik/Dat3M
36
2945
grammar LitmusAssertions; import BaseLexer; @header{ import com.dat3m.dartagnan.expression.op.COpBin; } assertionFilter : AssertionFilter a = assertion Semi? ; assertionList : AssertionExists a = assertion Semi? | AssertionNot AssertionExists a = assertion Semi? | AssertionForall a = assertion Semi? | AssertionFinal a = assertion Semi? assertionListExpectationList ; assertion : LPar assertion RPar # assertionParenthesis | AssertionNot assertion # assertionNot | assertion AssertionAnd assertion # assertionAnd | assertion AssertionOr assertion # assertionOr | assertionValue assertionCompare assertionValue # assertionBasic ; assertionValue : varName LBracket DigitSequence RBracket | varName | threadId Colon varName | constant ; varName : Underscore* Identifier (Identifier | DigitSequence | Underscore)* ; constant : Minus? DigitSequence ; assertionListExpectationList : AssertionWith (assertionListExpectation)+ ; assertionListExpectation : AssertionListExpectationTest Colon AssertionNot? AssertionExists Semi ; assertionCompare returns [COpBin op] : (Equals | EqualsEquals) {$op = COpBin.EQ;} | NotEquals {$op = COpBin.NEQ;} | GreaterEquals {$op = COpBin.GTE;} | LessEquals {$op = COpBin.LTE;} | Less {$op = COpBin.LT;} | Greater {$op = COpBin.GT;} ; threadId returns [int id] : t = ThreadIdentifier {$id = Integer.parseInt($t.text.replace("P", ""));} | t = DigitSequence {$id = Integer.parseInt($t.text);} ; AssertionListExpectationTest : 'tso' | 'cc' | 'optic' | 'default' ; AssertionAnd : '/\\' ; AssertionOr : '\\/' ; AssertionExists : 'exists' ; AssertionFinal : 'final' ; AssertionForall : 'forall' ; AssertionFilter : 'filter' ; AssertionNot : Tilde | 'not' ; AssertionWith : 'with' ; ThreadIdentifier : 'P' DigitSequence ; EqualsEquals : '==' ; NotEquals : '!=' ; LessEquals : '<=' ; GreaterEquals : '>=' ; Identifier : Underscore* Letter+ (Letter | Digit | Underscore)* ; DigitSequence : Digit+ ; fragment Digit : [0-9] ; fragment Letter : [A-Za-z] ; Whitespace : [ \t]+ -> skip ; Newline : ( '\r' '\n'? | '\n' ) -> skip ; BlockComment : '(*' .*? '*)' -> skip ; ExecConfig : '<<' .*? '>>' -> skip ;
example/src/example_2.adb
Heziode/ada-dotenv
6
20860
with Ada.Environment_Variables; with Dotenv; with Print_Variable; procedure Example_2 is begin Dotenv.Config (Path => "bin/.env.interpolation", File_Form => "wcem=8", Overwrite => True, Debug => True, Interpolate => True); Ada.Environment_Variables.Iterate (Print_Variable'Access); end Example_2;
programs/oeis/098/A098378.asm
karttu/loda
1
92503
; A098378: Number of characters needed to write number n in the traditional Ethiopic (Geez) number system. ; 1,1,1,1,1,1,1,1,1,1,2,2,2,2,2,2,2,2,2,1,2,2,2,2,2,2,2,2,2,1,2,2,2,2,2,2,2,2,2,1,2,2,2,2,2,2,2,2,2,1,2,2,2,2,2,2,2,2,2,1,2,2,2,2,2,2,2,2,2,1,2,2,2,2,2,2,2,2,2,1,2,2,2,2,2,2,2,2,2,1,2,2,2,2,2,2,2,2,2,1,2,2,2,2 add $0,1 lpb $0,$0 mod $0,10 add $1,1 lpe add $1,1
project/ntstub/amd64/6_3_9600_sp0_ssdt_sysenter.asm
mehrdad-shokri/windows-syscall-table
372
15442
<gh_stars>100-1000 ; DO NOT MODIFY THIS FILE DIRECTLY! ; author: @TinySecEx ; ssdt asm stub for 6.3.9600-sp0-windows-8.1 amd64 option casemap:none option prologue:none option epilogue:none .code ; ULONG64 __stdcall NtWorkerFactoryWorkerReady( ULONG64 arg_01 ); _6_3_9600_sp0_windows_8_1_NtWorkerFactoryWorkerReady PROC STDCALL mov r10 , rcx mov eax , 0 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtWorkerFactoryWorkerReady ENDP ; ULONG64 __stdcall NtAcceptConnectPort( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 , ULONG64 arg_06 ); _6_3_9600_sp0_windows_8_1_NtAcceptConnectPort PROC STDCALL mov r10 , rcx mov eax , 1 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtAcceptConnectPort ENDP ; ULONG64 __stdcall NtMapUserPhysicalPagesScatter( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 ); _6_3_9600_sp0_windows_8_1_NtMapUserPhysicalPagesScatter PROC STDCALL mov r10 , rcx mov eax , 2 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtMapUserPhysicalPagesScatter ENDP ; ULONG64 __stdcall NtWaitForSingleObject( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 ); _6_3_9600_sp0_windows_8_1_NtWaitForSingleObject PROC STDCALL mov r10 , rcx mov eax , 3 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtWaitForSingleObject ENDP ; ULONG64 __stdcall NtCallbackReturn( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 ); _6_3_9600_sp0_windows_8_1_NtCallbackReturn PROC STDCALL mov r10 , rcx mov eax , 4 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtCallbackReturn ENDP ; ULONG64 __stdcall NtReadFile( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 , ULONG64 arg_06 , ULONG64 arg_07 , ULONG64 arg_08 , ULONG64 arg_09 ); _6_3_9600_sp0_windows_8_1_NtReadFile PROC STDCALL mov r10 , rcx mov eax , 5 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtReadFile ENDP ; ULONG64 __stdcall NtDeviceIoControlFile( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 , ULONG64 arg_06 , ULONG64 arg_07 , ULONG64 arg_08 , ULONG64 arg_09 , ULONG64 arg_10 ); _6_3_9600_sp0_windows_8_1_NtDeviceIoControlFile PROC STDCALL mov r10 , rcx mov eax , 6 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtDeviceIoControlFile ENDP ; ULONG64 __stdcall NtWriteFile( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 , ULONG64 arg_06 , ULONG64 arg_07 , ULONG64 arg_08 , ULONG64 arg_09 ); _6_3_9600_sp0_windows_8_1_NtWriteFile PROC STDCALL mov r10 , rcx mov eax , 7 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtWriteFile ENDP ; ULONG64 __stdcall NtRemoveIoCompletion( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 ); _6_3_9600_sp0_windows_8_1_NtRemoveIoCompletion PROC STDCALL mov r10 , rcx mov eax , 8 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtRemoveIoCompletion ENDP ; ULONG64 __stdcall NtReleaseSemaphore( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 ); _6_3_9600_sp0_windows_8_1_NtReleaseSemaphore PROC STDCALL mov r10 , rcx mov eax , 9 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtReleaseSemaphore ENDP ; ULONG64 __stdcall NtReplyWaitReceivePort( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 ); _6_3_9600_sp0_windows_8_1_NtReplyWaitReceivePort PROC STDCALL mov r10 , rcx mov eax , 10 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtReplyWaitReceivePort ENDP ; ULONG64 __stdcall NtReplyPort( ULONG64 arg_01 , ULONG64 arg_02 ); _6_3_9600_sp0_windows_8_1_NtReplyPort PROC STDCALL mov r10 , rcx mov eax , 11 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtReplyPort ENDP ; ULONG64 __stdcall NtSetInformationThread( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 ); _6_3_9600_sp0_windows_8_1_NtSetInformationThread PROC STDCALL mov r10 , rcx mov eax , 12 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtSetInformationThread ENDP ; ULONG64 __stdcall NtSetEvent( ULONG64 arg_01 , ULONG64 arg_02 ); _6_3_9600_sp0_windows_8_1_NtSetEvent PROC STDCALL mov r10 , rcx mov eax , 13 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtSetEvent ENDP ; ULONG64 __stdcall NtClose( ULONG64 arg_01 ); _6_3_9600_sp0_windows_8_1_NtClose PROC STDCALL mov r10 , rcx mov eax , 14 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtClose ENDP ; ULONG64 __stdcall NtQueryObject( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 ); _6_3_9600_sp0_windows_8_1_NtQueryObject PROC STDCALL mov r10 , rcx mov eax , 15 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtQueryObject ENDP ; ULONG64 __stdcall NtQueryInformationFile( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 ); _6_3_9600_sp0_windows_8_1_NtQueryInformationFile PROC STDCALL mov r10 , rcx mov eax , 16 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtQueryInformationFile ENDP ; ULONG64 __stdcall NtOpenKey( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 ); _6_3_9600_sp0_windows_8_1_NtOpenKey PROC STDCALL mov r10 , rcx mov eax , 17 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtOpenKey ENDP ; ULONG64 __stdcall NtEnumerateValueKey( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 , ULONG64 arg_06 ); _6_3_9600_sp0_windows_8_1_NtEnumerateValueKey PROC STDCALL mov r10 , rcx mov eax , 18 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtEnumerateValueKey ENDP ; ULONG64 __stdcall NtFindAtom( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 ); _6_3_9600_sp0_windows_8_1_NtFindAtom PROC STDCALL mov r10 , rcx mov eax , 19 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtFindAtom ENDP ; ULONG64 __stdcall NtQueryDefaultLocale( ULONG64 arg_01 , ULONG64 arg_02 ); _6_3_9600_sp0_windows_8_1_NtQueryDefaultLocale PROC STDCALL mov r10 , rcx mov eax , 20 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtQueryDefaultLocale ENDP ; ULONG64 __stdcall NtQueryKey( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 ); _6_3_9600_sp0_windows_8_1_NtQueryKey PROC STDCALL mov r10 , rcx mov eax , 21 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtQueryKey ENDP ; ULONG64 __stdcall NtQueryValueKey( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 , ULONG64 arg_06 ); _6_3_9600_sp0_windows_8_1_NtQueryValueKey PROC STDCALL mov r10 , rcx mov eax , 22 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtQueryValueKey ENDP ; ULONG64 __stdcall NtAllocateVirtualMemory( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 , ULONG64 arg_06 ); _6_3_9600_sp0_windows_8_1_NtAllocateVirtualMemory PROC STDCALL mov r10 , rcx mov eax , 23 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtAllocateVirtualMemory ENDP ; ULONG64 __stdcall NtQueryInformationProcess( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 ); _6_3_9600_sp0_windows_8_1_NtQueryInformationProcess PROC STDCALL mov r10 , rcx mov eax , 24 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtQueryInformationProcess ENDP ; ULONG64 __stdcall NtWaitForMultipleObjects32( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 ); _6_3_9600_sp0_windows_8_1_NtWaitForMultipleObjects32 PROC STDCALL mov r10 , rcx mov eax , 25 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtWaitForMultipleObjects32 ENDP ; ULONG64 __stdcall NtWriteFileGather( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 , ULONG64 arg_06 , ULONG64 arg_07 , ULONG64 arg_08 , ULONG64 arg_09 ); _6_3_9600_sp0_windows_8_1_NtWriteFileGather PROC STDCALL mov r10 , rcx mov eax , 26 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtWriteFileGather ENDP ; ULONG64 __stdcall NtSetInformationProcess( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 ); _6_3_9600_sp0_windows_8_1_NtSetInformationProcess PROC STDCALL mov r10 , rcx mov eax , 27 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtSetInformationProcess ENDP ; ULONG64 __stdcall NtCreateKey( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 , ULONG64 arg_06 , ULONG64 arg_07 ); _6_3_9600_sp0_windows_8_1_NtCreateKey PROC STDCALL mov r10 , rcx mov eax , 28 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtCreateKey ENDP ; ULONG64 __stdcall NtFreeVirtualMemory( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 ); _6_3_9600_sp0_windows_8_1_NtFreeVirtualMemory PROC STDCALL mov r10 , rcx mov eax , 29 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtFreeVirtualMemory ENDP ; ULONG64 __stdcall NtImpersonateClientOfPort( ULONG64 arg_01 , ULONG64 arg_02 ); _6_3_9600_sp0_windows_8_1_NtImpersonateClientOfPort PROC STDCALL mov r10 , rcx mov eax , 30 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtImpersonateClientOfPort ENDP ; ULONG64 __stdcall NtReleaseMutant( ULONG64 arg_01 , ULONG64 arg_02 ); _6_3_9600_sp0_windows_8_1_NtReleaseMutant PROC STDCALL mov r10 , rcx mov eax , 31 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtReleaseMutant ENDP ; ULONG64 __stdcall NtQueryInformationToken( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 ); _6_3_9600_sp0_windows_8_1_NtQueryInformationToken PROC STDCALL mov r10 , rcx mov eax , 32 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtQueryInformationToken ENDP ; ULONG64 __stdcall NtRequestWaitReplyPort( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 ); _6_3_9600_sp0_windows_8_1_NtRequestWaitReplyPort PROC STDCALL mov r10 , rcx mov eax , 33 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtRequestWaitReplyPort ENDP ; ULONG64 __stdcall NtQueryVirtualMemory( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 , ULONG64 arg_06 ); _6_3_9600_sp0_windows_8_1_NtQueryVirtualMemory PROC STDCALL mov r10 , rcx mov eax , 34 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtQueryVirtualMemory ENDP ; ULONG64 __stdcall NtOpenThreadToken( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 ); _6_3_9600_sp0_windows_8_1_NtOpenThreadToken PROC STDCALL mov r10 , rcx mov eax , 35 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtOpenThreadToken ENDP ; ULONG64 __stdcall NtQueryInformationThread( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 ); _6_3_9600_sp0_windows_8_1_NtQueryInformationThread PROC STDCALL mov r10 , rcx mov eax , 36 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtQueryInformationThread ENDP ; ULONG64 __stdcall NtOpenProcess( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 ); _6_3_9600_sp0_windows_8_1_NtOpenProcess PROC STDCALL mov r10 , rcx mov eax , 37 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtOpenProcess ENDP ; ULONG64 __stdcall NtSetInformationFile( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 ); _6_3_9600_sp0_windows_8_1_NtSetInformationFile PROC STDCALL mov r10 , rcx mov eax , 38 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtSetInformationFile ENDP ; ULONG64 __stdcall NtMapViewOfSection( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 , ULONG64 arg_06 , ULONG64 arg_07 , ULONG64 arg_08 , ULONG64 arg_09 , ULONG64 arg_10 ); _6_3_9600_sp0_windows_8_1_NtMapViewOfSection PROC STDCALL mov r10 , rcx mov eax , 39 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtMapViewOfSection ENDP ; ULONG64 __stdcall NtAccessCheckAndAuditAlarm( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 , ULONG64 arg_06 , ULONG64 arg_07 , ULONG64 arg_08 , ULONG64 arg_09 , ULONG64 arg_10 , ULONG64 arg_11 ); _6_3_9600_sp0_windows_8_1_NtAccessCheckAndAuditAlarm PROC STDCALL mov r10 , rcx mov eax , 40 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtAccessCheckAndAuditAlarm ENDP ; ULONG64 __stdcall NtUnmapViewOfSection( ULONG64 arg_01 , ULONG64 arg_02 ); _6_3_9600_sp0_windows_8_1_NtUnmapViewOfSection PROC STDCALL mov r10 , rcx mov eax , 41 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtUnmapViewOfSection ENDP ; ULONG64 __stdcall NtReplyWaitReceivePortEx( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 ); _6_3_9600_sp0_windows_8_1_NtReplyWaitReceivePortEx PROC STDCALL mov r10 , rcx mov eax , 42 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtReplyWaitReceivePortEx ENDP ; ULONG64 __stdcall NtTerminateProcess( ULONG64 arg_01 , ULONG64 arg_02 ); _6_3_9600_sp0_windows_8_1_NtTerminateProcess PROC STDCALL mov r10 , rcx mov eax , 43 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtTerminateProcess ENDP ; ULONG64 __stdcall NtSetEventBoostPriority( ULONG64 arg_01 ); _6_3_9600_sp0_windows_8_1_NtSetEventBoostPriority PROC STDCALL mov r10 , rcx mov eax , 44 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtSetEventBoostPriority ENDP ; ULONG64 __stdcall NtReadFileScatter( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 , ULONG64 arg_06 , ULONG64 arg_07 , ULONG64 arg_08 , ULONG64 arg_09 ); _6_3_9600_sp0_windows_8_1_NtReadFileScatter PROC STDCALL mov r10 , rcx mov eax , 45 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtReadFileScatter ENDP ; ULONG64 __stdcall NtOpenThreadTokenEx( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 ); _6_3_9600_sp0_windows_8_1_NtOpenThreadTokenEx PROC STDCALL mov r10 , rcx mov eax , 46 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtOpenThreadTokenEx ENDP ; ULONG64 __stdcall NtOpenProcessTokenEx( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 ); _6_3_9600_sp0_windows_8_1_NtOpenProcessTokenEx PROC STDCALL mov r10 , rcx mov eax , 47 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtOpenProcessTokenEx ENDP ; ULONG64 __stdcall NtQueryPerformanceCounter( ULONG64 arg_01 , ULONG64 arg_02 ); _6_3_9600_sp0_windows_8_1_NtQueryPerformanceCounter PROC STDCALL mov r10 , rcx mov eax , 48 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtQueryPerformanceCounter ENDP ; ULONG64 __stdcall NtEnumerateKey( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 , ULONG64 arg_06 ); _6_3_9600_sp0_windows_8_1_NtEnumerateKey PROC STDCALL mov r10 , rcx mov eax , 49 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtEnumerateKey ENDP ; ULONG64 __stdcall NtOpenFile( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 , ULONG64 arg_06 ); _6_3_9600_sp0_windows_8_1_NtOpenFile PROC STDCALL mov r10 , rcx mov eax , 50 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtOpenFile ENDP ; ULONG64 __stdcall NtDelayExecution( ULONG64 arg_01 , ULONG64 arg_02 ); _6_3_9600_sp0_windows_8_1_NtDelayExecution PROC STDCALL mov r10 , rcx mov eax , 51 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtDelayExecution ENDP ; ULONG64 __stdcall NtQueryDirectoryFile( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 , ULONG64 arg_06 , ULONG64 arg_07 , ULONG64 arg_08 , ULONG64 arg_09 , ULONG64 arg_10 , ULONG64 arg_11 ); _6_3_9600_sp0_windows_8_1_NtQueryDirectoryFile PROC STDCALL mov r10 , rcx mov eax , 52 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtQueryDirectoryFile ENDP ; ULONG64 __stdcall NtQuerySystemInformation( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 ); _6_3_9600_sp0_windows_8_1_NtQuerySystemInformation PROC STDCALL mov r10 , rcx mov eax , 53 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtQuerySystemInformation ENDP ; ULONG64 __stdcall NtOpenSection( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 ); _6_3_9600_sp0_windows_8_1_NtOpenSection PROC STDCALL mov r10 , rcx mov eax , 54 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtOpenSection ENDP ; ULONG64 __stdcall NtQueryTimer( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 ); _6_3_9600_sp0_windows_8_1_NtQueryTimer PROC STDCALL mov r10 , rcx mov eax , 55 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtQueryTimer ENDP ; ULONG64 __stdcall NtFsControlFile( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 , ULONG64 arg_06 , ULONG64 arg_07 , ULONG64 arg_08 , ULONG64 arg_09 , ULONG64 arg_10 ); _6_3_9600_sp0_windows_8_1_NtFsControlFile PROC STDCALL mov r10 , rcx mov eax , 56 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtFsControlFile ENDP ; ULONG64 __stdcall NtWriteVirtualMemory( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 ); _6_3_9600_sp0_windows_8_1_NtWriteVirtualMemory PROC STDCALL mov r10 , rcx mov eax , 57 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtWriteVirtualMemory ENDP ; ULONG64 __stdcall NtCloseObjectAuditAlarm( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 ); _6_3_9600_sp0_windows_8_1_NtCloseObjectAuditAlarm PROC STDCALL mov r10 , rcx mov eax , 58 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtCloseObjectAuditAlarm ENDP ; ULONG64 __stdcall NtDuplicateObject( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 , ULONG64 arg_06 , ULONG64 arg_07 ); _6_3_9600_sp0_windows_8_1_NtDuplicateObject PROC STDCALL mov r10 , rcx mov eax , 59 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtDuplicateObject ENDP ; ULONG64 __stdcall NtQueryAttributesFile( ULONG64 arg_01 , ULONG64 arg_02 ); _6_3_9600_sp0_windows_8_1_NtQueryAttributesFile PROC STDCALL mov r10 , rcx mov eax , 60 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtQueryAttributesFile ENDP ; ULONG64 __stdcall NtClearEvent( ULONG64 arg_01 ); _6_3_9600_sp0_windows_8_1_NtClearEvent PROC STDCALL mov r10 , rcx mov eax , 61 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtClearEvent ENDP ; ULONG64 __stdcall NtReadVirtualMemory( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 ); _6_3_9600_sp0_windows_8_1_NtReadVirtualMemory PROC STDCALL mov r10 , rcx mov eax , 62 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtReadVirtualMemory ENDP ; ULONG64 __stdcall NtOpenEvent( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 ); _6_3_9600_sp0_windows_8_1_NtOpenEvent PROC STDCALL mov r10 , rcx mov eax , 63 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtOpenEvent ENDP ; ULONG64 __stdcall NtAdjustPrivilegesToken( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 , ULONG64 arg_06 ); _6_3_9600_sp0_windows_8_1_NtAdjustPrivilegesToken PROC STDCALL mov r10 , rcx mov eax , 64 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtAdjustPrivilegesToken ENDP ; ULONG64 __stdcall NtDuplicateToken( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 , ULONG64 arg_06 ); _6_3_9600_sp0_windows_8_1_NtDuplicateToken PROC STDCALL mov r10 , rcx mov eax , 65 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtDuplicateToken ENDP ; ULONG64 __stdcall NtContinue( ULONG64 arg_01 , ULONG64 arg_02 ); _6_3_9600_sp0_windows_8_1_NtContinue PROC STDCALL mov r10 , rcx mov eax , 66 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtContinue ENDP ; ULONG64 __stdcall NtQueryDefaultUILanguage( ULONG64 arg_01 ); _6_3_9600_sp0_windows_8_1_NtQueryDefaultUILanguage PROC STDCALL mov r10 , rcx mov eax , 67 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtQueryDefaultUILanguage ENDP ; ULONG64 __stdcall NtQueueApcThread( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 ); _6_3_9600_sp0_windows_8_1_NtQueueApcThread PROC STDCALL mov r10 , rcx mov eax , 68 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtQueueApcThread ENDP ; ULONG64 __stdcall NtYieldExecution( ); _6_3_9600_sp0_windows_8_1_NtYieldExecution PROC STDCALL mov r10 , rcx mov eax , 69 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtYieldExecution ENDP ; ULONG64 __stdcall NtAddAtom( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 ); _6_3_9600_sp0_windows_8_1_NtAddAtom PROC STDCALL mov r10 , rcx mov eax , 70 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtAddAtom ENDP ; ULONG64 __stdcall NtCreateEvent( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 ); _6_3_9600_sp0_windows_8_1_NtCreateEvent PROC STDCALL mov r10 , rcx mov eax , 71 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtCreateEvent ENDP ; ULONG64 __stdcall NtQueryVolumeInformationFile( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 ); _6_3_9600_sp0_windows_8_1_NtQueryVolumeInformationFile PROC STDCALL mov r10 , rcx mov eax , 72 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtQueryVolumeInformationFile ENDP ; ULONG64 __stdcall NtCreateSection( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 , ULONG64 arg_06 , ULONG64 arg_07 ); _6_3_9600_sp0_windows_8_1_NtCreateSection PROC STDCALL mov r10 , rcx mov eax , 73 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtCreateSection ENDP ; ULONG64 __stdcall NtFlushBuffersFile( ULONG64 arg_01 , ULONG64 arg_02 ); _6_3_9600_sp0_windows_8_1_NtFlushBuffersFile PROC STDCALL mov r10 , rcx mov eax , 74 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtFlushBuffersFile ENDP ; ULONG64 __stdcall NtApphelpCacheControl( ULONG64 arg_01 , ULONG64 arg_02 ); _6_3_9600_sp0_windows_8_1_NtApphelpCacheControl PROC STDCALL mov r10 , rcx mov eax , 75 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtApphelpCacheControl ENDP ; ULONG64 __stdcall NtCreateProcessEx( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 , ULONG64 arg_06 , ULONG64 arg_07 , ULONG64 arg_08 , ULONG64 arg_09 ); _6_3_9600_sp0_windows_8_1_NtCreateProcessEx PROC STDCALL mov r10 , rcx mov eax , 76 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtCreateProcessEx ENDP ; ULONG64 __stdcall NtCreateThread( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 , ULONG64 arg_06 , ULONG64 arg_07 , ULONG64 arg_08 ); _6_3_9600_sp0_windows_8_1_NtCreateThread PROC STDCALL mov r10 , rcx mov eax , 77 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtCreateThread ENDP ; ULONG64 __stdcall NtIsProcessInJob( ULONG64 arg_01 , ULONG64 arg_02 ); _6_3_9600_sp0_windows_8_1_NtIsProcessInJob PROC STDCALL mov r10 , rcx mov eax , 78 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtIsProcessInJob ENDP ; ULONG64 __stdcall NtProtectVirtualMemory( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 ); _6_3_9600_sp0_windows_8_1_NtProtectVirtualMemory PROC STDCALL mov r10 , rcx mov eax , 79 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtProtectVirtualMemory ENDP ; ULONG64 __stdcall NtQuerySection( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 ); _6_3_9600_sp0_windows_8_1_NtQuerySection PROC STDCALL mov r10 , rcx mov eax , 80 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtQuerySection ENDP ; ULONG64 __stdcall NtResumeThread( ULONG64 arg_01 , ULONG64 arg_02 ); _6_3_9600_sp0_windows_8_1_NtResumeThread PROC STDCALL mov r10 , rcx mov eax , 81 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtResumeThread ENDP ; ULONG64 __stdcall NtTerminateThread( ULONG64 arg_01 , ULONG64 arg_02 ); _6_3_9600_sp0_windows_8_1_NtTerminateThread PROC STDCALL mov r10 , rcx mov eax , 82 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtTerminateThread ENDP ; ULONG64 __stdcall NtReadRequestData( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 , ULONG64 arg_06 ); _6_3_9600_sp0_windows_8_1_NtReadRequestData PROC STDCALL mov r10 , rcx mov eax , 83 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtReadRequestData ENDP ; ULONG64 __stdcall NtCreateFile( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 , ULONG64 arg_06 , ULONG64 arg_07 , ULONG64 arg_08 , ULONG64 arg_09 , ULONG64 arg_10 , ULONG64 arg_11 ); _6_3_9600_sp0_windows_8_1_NtCreateFile PROC STDCALL mov r10 , rcx mov eax , 84 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtCreateFile ENDP ; ULONG64 __stdcall NtQueryEvent( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 ); _6_3_9600_sp0_windows_8_1_NtQueryEvent PROC STDCALL mov r10 , rcx mov eax , 85 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtQueryEvent ENDP ; ULONG64 __stdcall NtWriteRequestData( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 , ULONG64 arg_06 ); _6_3_9600_sp0_windows_8_1_NtWriteRequestData PROC STDCALL mov r10 , rcx mov eax , 86 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtWriteRequestData ENDP ; ULONG64 __stdcall NtOpenDirectoryObject( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 ); _6_3_9600_sp0_windows_8_1_NtOpenDirectoryObject PROC STDCALL mov r10 , rcx mov eax , 87 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtOpenDirectoryObject ENDP ; ULONG64 __stdcall NtAccessCheckByTypeAndAuditAlarm( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 , ULONG64 arg_06 , ULONG64 arg_07 , ULONG64 arg_08 , ULONG64 arg_09 , ULONG64 arg_10 , ULONG64 arg_11 , ULONG64 arg_12 , ULONG64 arg_13 , ULONG64 arg_14 , ULONG64 arg_15 , ULONG64 arg_16 ); _6_3_9600_sp0_windows_8_1_NtAccessCheckByTypeAndAuditAlarm PROC STDCALL mov r10 , rcx mov eax , 88 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtAccessCheckByTypeAndAuditAlarm ENDP ; ULONG64 __stdcall NtQuerySystemTime( ULONG64 arg_01 ); _6_3_9600_sp0_windows_8_1_NtQuerySystemTime PROC STDCALL mov r10 , rcx mov eax , 89 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtQuerySystemTime ENDP ; ULONG64 __stdcall NtWaitForMultipleObjects( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 ); _6_3_9600_sp0_windows_8_1_NtWaitForMultipleObjects PROC STDCALL mov r10 , rcx mov eax , 90 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtWaitForMultipleObjects ENDP ; ULONG64 __stdcall NtSetInformationObject( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 ); _6_3_9600_sp0_windows_8_1_NtSetInformationObject PROC STDCALL mov r10 , rcx mov eax , 91 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtSetInformationObject ENDP ; ULONG64 __stdcall NtCancelIoFile( ULONG64 arg_01 , ULONG64 arg_02 ); _6_3_9600_sp0_windows_8_1_NtCancelIoFile PROC STDCALL mov r10 , rcx mov eax , 92 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtCancelIoFile ENDP ; ULONG64 __stdcall NtTraceEvent( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 ); _6_3_9600_sp0_windows_8_1_NtTraceEvent PROC STDCALL mov r10 , rcx mov eax , 93 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtTraceEvent ENDP ; ULONG64 __stdcall NtPowerInformation( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 ); _6_3_9600_sp0_windows_8_1_NtPowerInformation PROC STDCALL mov r10 , rcx mov eax , 94 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtPowerInformation ENDP ; ULONG64 __stdcall NtSetValueKey( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 , ULONG64 arg_06 ); _6_3_9600_sp0_windows_8_1_NtSetValueKey PROC STDCALL mov r10 , rcx mov eax , 95 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtSetValueKey ENDP ; ULONG64 __stdcall NtCancelTimer( ULONG64 arg_01 , ULONG64 arg_02 ); _6_3_9600_sp0_windows_8_1_NtCancelTimer PROC STDCALL mov r10 , rcx mov eax , 96 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtCancelTimer ENDP ; ULONG64 __stdcall NtSetTimer( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 , ULONG64 arg_06 , ULONG64 arg_07 ); _6_3_9600_sp0_windows_8_1_NtSetTimer PROC STDCALL mov r10 , rcx mov eax , 97 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtSetTimer ENDP ; ULONG64 __stdcall NtAccessCheck( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 , ULONG64 arg_06 , ULONG64 arg_07 , ULONG64 arg_08 ); _6_3_9600_sp0_windows_8_1_NtAccessCheck PROC STDCALL mov r10 , rcx mov eax , 98 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtAccessCheck ENDP ; ULONG64 __stdcall NtAccessCheckByType( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 , ULONG64 arg_06 , ULONG64 arg_07 , ULONG64 arg_08 , ULONG64 arg_09 , ULONG64 arg_10 , ULONG64 arg_11 ); _6_3_9600_sp0_windows_8_1_NtAccessCheckByType PROC STDCALL mov r10 , rcx mov eax , 99 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtAccessCheckByType ENDP ; ULONG64 __stdcall NtAccessCheckByTypeResultList( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 , ULONG64 arg_06 , ULONG64 arg_07 , ULONG64 arg_08 , ULONG64 arg_09 , ULONG64 arg_10 , ULONG64 arg_11 ); _6_3_9600_sp0_windows_8_1_NtAccessCheckByTypeResultList PROC STDCALL mov r10 , rcx mov eax , 100 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtAccessCheckByTypeResultList ENDP ; ULONG64 __stdcall NtAccessCheckByTypeResultListAndAuditAlarm( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 , ULONG64 arg_06 , ULONG64 arg_07 , ULONG64 arg_08 , ULONG64 arg_09 , ULONG64 arg_10 , ULONG64 arg_11 , ULONG64 arg_12 , ULONG64 arg_13 , ULONG64 arg_14 , ULONG64 arg_15 , ULONG64 arg_16 ); _6_3_9600_sp0_windows_8_1_NtAccessCheckByTypeResultListAndAuditAlarm PROC STDCALL mov r10 , rcx mov eax , 101 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtAccessCheckByTypeResultListAndAuditAlarm ENDP ; ULONG64 __stdcall NtAccessCheckByTypeResultListAndAuditAlarmByHandle( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 , ULONG64 arg_06 , ULONG64 arg_07 , ULONG64 arg_08 , ULONG64 arg_09 , ULONG64 arg_10 , ULONG64 arg_11 , ULONG64 arg_12 , ULONG64 arg_13 , ULONG64 arg_14 , ULONG64 arg_15 , ULONG64 arg_16 , ULONG64 arg_17 ); _6_3_9600_sp0_windows_8_1_NtAccessCheckByTypeResultListAndAuditAlarmByHandle PROC STDCALL mov r10 , rcx mov eax , 102 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtAccessCheckByTypeResultListAndAuditAlarmByHandle ENDP ; ULONG64 __stdcall NtAddAtomEx( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 ); _6_3_9600_sp0_windows_8_1_NtAddAtomEx PROC STDCALL mov r10 , rcx mov eax , 103 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtAddAtomEx ENDP ; ULONG64 __stdcall NtAddBootEntry( ULONG64 arg_01 , ULONG64 arg_02 ); _6_3_9600_sp0_windows_8_1_NtAddBootEntry PROC STDCALL mov r10 , rcx mov eax , 104 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtAddBootEntry ENDP ; ULONG64 __stdcall NtAddDriverEntry( ULONG64 arg_01 , ULONG64 arg_02 ); _6_3_9600_sp0_windows_8_1_NtAddDriverEntry PROC STDCALL mov r10 , rcx mov eax , 105 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtAddDriverEntry ENDP ; ULONG64 __stdcall NtAdjustGroupsToken( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 , ULONG64 arg_06 ); _6_3_9600_sp0_windows_8_1_NtAdjustGroupsToken PROC STDCALL mov r10 , rcx mov eax , 106 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtAdjustGroupsToken ENDP ; ULONG64 __stdcall NtAdjustTokenClaimsAndDeviceGroups( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 , ULONG64 arg_06 , ULONG64 arg_07 , ULONG64 arg_08 , ULONG64 arg_09 , ULONG64 arg_10 , ULONG64 arg_11 , ULONG64 arg_12 , ULONG64 arg_13 , ULONG64 arg_14 , ULONG64 arg_15 , ULONG64 arg_16 ); _6_3_9600_sp0_windows_8_1_NtAdjustTokenClaimsAndDeviceGroups PROC STDCALL mov r10 , rcx mov eax , 107 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtAdjustTokenClaimsAndDeviceGroups ENDP ; ULONG64 __stdcall NtAlertResumeThread( ULONG64 arg_01 , ULONG64 arg_02 ); _6_3_9600_sp0_windows_8_1_NtAlertResumeThread PROC STDCALL mov r10 , rcx mov eax , 108 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtAlertResumeThread ENDP ; ULONG64 __stdcall NtAlertThread( ULONG64 arg_01 ); _6_3_9600_sp0_windows_8_1_NtAlertThread PROC STDCALL mov r10 , rcx mov eax , 109 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtAlertThread ENDP ; ULONG64 __stdcall NtAlertThreadByThreadId( ULONG64 arg_01 ); _6_3_9600_sp0_windows_8_1_NtAlertThreadByThreadId PROC STDCALL mov r10 , rcx mov eax , 110 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtAlertThreadByThreadId ENDP ; ULONG64 __stdcall NtAllocateLocallyUniqueId( ULONG64 arg_01 ); _6_3_9600_sp0_windows_8_1_NtAllocateLocallyUniqueId PROC STDCALL mov r10 , rcx mov eax , 111 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtAllocateLocallyUniqueId ENDP ; ULONG64 __stdcall NtAllocateReserveObject( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 ); _6_3_9600_sp0_windows_8_1_NtAllocateReserveObject PROC STDCALL mov r10 , rcx mov eax , 112 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtAllocateReserveObject ENDP ; ULONG64 __stdcall NtAllocateUserPhysicalPages( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 ); _6_3_9600_sp0_windows_8_1_NtAllocateUserPhysicalPages PROC STDCALL mov r10 , rcx mov eax , 113 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtAllocateUserPhysicalPages ENDP ; ULONG64 __stdcall NtAllocateUuids( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 ); _6_3_9600_sp0_windows_8_1_NtAllocateUuids PROC STDCALL mov r10 , rcx mov eax , 114 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtAllocateUuids ENDP ; ULONG64 __stdcall NtAlpcAcceptConnectPort( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 , ULONG64 arg_06 , ULONG64 arg_07 , ULONG64 arg_08 , ULONG64 arg_09 ); _6_3_9600_sp0_windows_8_1_NtAlpcAcceptConnectPort PROC STDCALL mov r10 , rcx mov eax , 115 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtAlpcAcceptConnectPort ENDP ; ULONG64 __stdcall NtAlpcCancelMessage( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 ); _6_3_9600_sp0_windows_8_1_NtAlpcCancelMessage PROC STDCALL mov r10 , rcx mov eax , 116 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtAlpcCancelMessage ENDP ; ULONG64 __stdcall NtAlpcConnectPort( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 , ULONG64 arg_06 , ULONG64 arg_07 , ULONG64 arg_08 , ULONG64 arg_09 , ULONG64 arg_10 , ULONG64 arg_11 ); _6_3_9600_sp0_windows_8_1_NtAlpcConnectPort PROC STDCALL mov r10 , rcx mov eax , 117 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtAlpcConnectPort ENDP ; ULONG64 __stdcall NtAlpcConnectPortEx( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 , ULONG64 arg_06 , ULONG64 arg_07 , ULONG64 arg_08 , ULONG64 arg_09 , ULONG64 arg_10 , ULONG64 arg_11 ); _6_3_9600_sp0_windows_8_1_NtAlpcConnectPortEx PROC STDCALL mov r10 , rcx mov eax , 118 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtAlpcConnectPortEx ENDP ; ULONG64 __stdcall NtAlpcCreatePort( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 ); _6_3_9600_sp0_windows_8_1_NtAlpcCreatePort PROC STDCALL mov r10 , rcx mov eax , 119 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtAlpcCreatePort ENDP ; ULONG64 __stdcall NtAlpcCreatePortSection( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 , ULONG64 arg_06 ); _6_3_9600_sp0_windows_8_1_NtAlpcCreatePortSection PROC STDCALL mov r10 , rcx mov eax , 120 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtAlpcCreatePortSection ENDP ; ULONG64 __stdcall NtAlpcCreateResourceReserve( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 ); _6_3_9600_sp0_windows_8_1_NtAlpcCreateResourceReserve PROC STDCALL mov r10 , rcx mov eax , 121 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtAlpcCreateResourceReserve ENDP ; ULONG64 __stdcall NtAlpcCreateSectionView( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 ); _6_3_9600_sp0_windows_8_1_NtAlpcCreateSectionView PROC STDCALL mov r10 , rcx mov eax , 122 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtAlpcCreateSectionView ENDP ; ULONG64 __stdcall NtAlpcCreateSecurityContext( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 ); _6_3_9600_sp0_windows_8_1_NtAlpcCreateSecurityContext PROC STDCALL mov r10 , rcx mov eax , 123 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtAlpcCreateSecurityContext ENDP ; ULONG64 __stdcall NtAlpcDeletePortSection( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 ); _6_3_9600_sp0_windows_8_1_NtAlpcDeletePortSection PROC STDCALL mov r10 , rcx mov eax , 124 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtAlpcDeletePortSection ENDP ; ULONG64 __stdcall NtAlpcDeleteResourceReserve( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 ); _6_3_9600_sp0_windows_8_1_NtAlpcDeleteResourceReserve PROC STDCALL mov r10 , rcx mov eax , 125 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtAlpcDeleteResourceReserve ENDP ; ULONG64 __stdcall NtAlpcDeleteSectionView( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 ); _6_3_9600_sp0_windows_8_1_NtAlpcDeleteSectionView PROC STDCALL mov r10 , rcx mov eax , 126 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtAlpcDeleteSectionView ENDP ; ULONG64 __stdcall NtAlpcDeleteSecurityContext( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 ); _6_3_9600_sp0_windows_8_1_NtAlpcDeleteSecurityContext PROC STDCALL mov r10 , rcx mov eax , 127 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtAlpcDeleteSecurityContext ENDP ; ULONG64 __stdcall NtAlpcDisconnectPort( ULONG64 arg_01 , ULONG64 arg_02 ); _6_3_9600_sp0_windows_8_1_NtAlpcDisconnectPort PROC STDCALL mov r10 , rcx mov eax , 128 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtAlpcDisconnectPort ENDP ; ULONG64 __stdcall NtAlpcImpersonateClientOfPort( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 ); _6_3_9600_sp0_windows_8_1_NtAlpcImpersonateClientOfPort PROC STDCALL mov r10 , rcx mov eax , 129 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtAlpcImpersonateClientOfPort ENDP ; ULONG64 __stdcall NtAlpcOpenSenderProcess( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 , ULONG64 arg_06 ); _6_3_9600_sp0_windows_8_1_NtAlpcOpenSenderProcess PROC STDCALL mov r10 , rcx mov eax , 130 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtAlpcOpenSenderProcess ENDP ; ULONG64 __stdcall NtAlpcOpenSenderThread( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 , ULONG64 arg_06 ); _6_3_9600_sp0_windows_8_1_NtAlpcOpenSenderThread PROC STDCALL mov r10 , rcx mov eax , 131 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtAlpcOpenSenderThread ENDP ; ULONG64 __stdcall NtAlpcQueryInformation( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 ); _6_3_9600_sp0_windows_8_1_NtAlpcQueryInformation PROC STDCALL mov r10 , rcx mov eax , 132 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtAlpcQueryInformation ENDP ; ULONG64 __stdcall NtAlpcQueryInformationMessage( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 , ULONG64 arg_06 ); _6_3_9600_sp0_windows_8_1_NtAlpcQueryInformationMessage PROC STDCALL mov r10 , rcx mov eax , 133 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtAlpcQueryInformationMessage ENDP ; ULONG64 __stdcall NtAlpcRevokeSecurityContext( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 ); _6_3_9600_sp0_windows_8_1_NtAlpcRevokeSecurityContext PROC STDCALL mov r10 , rcx mov eax , 134 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtAlpcRevokeSecurityContext ENDP ; ULONG64 __stdcall NtAlpcSendWaitReceivePort( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 , ULONG64 arg_06 , ULONG64 arg_07 , ULONG64 arg_08 ); _6_3_9600_sp0_windows_8_1_NtAlpcSendWaitReceivePort PROC STDCALL mov r10 , rcx mov eax , 135 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtAlpcSendWaitReceivePort ENDP ; ULONG64 __stdcall NtAlpcSetInformation( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 ); _6_3_9600_sp0_windows_8_1_NtAlpcSetInformation PROC STDCALL mov r10 , rcx mov eax , 136 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtAlpcSetInformation ENDP ; ULONG64 __stdcall NtAreMappedFilesTheSame( ULONG64 arg_01 , ULONG64 arg_02 ); _6_3_9600_sp0_windows_8_1_NtAreMappedFilesTheSame PROC STDCALL mov r10 , rcx mov eax , 137 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtAreMappedFilesTheSame ENDP ; ULONG64 __stdcall NtAssignProcessToJobObject( ULONG64 arg_01 , ULONG64 arg_02 ); _6_3_9600_sp0_windows_8_1_NtAssignProcessToJobObject PROC STDCALL mov r10 , rcx mov eax , 138 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtAssignProcessToJobObject ENDP ; ULONG64 __stdcall NtAssociateWaitCompletionPacket( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 , ULONG64 arg_06 , ULONG64 arg_07 , ULONG64 arg_08 ); _6_3_9600_sp0_windows_8_1_NtAssociateWaitCompletionPacket PROC STDCALL mov r10 , rcx mov eax , 139 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtAssociateWaitCompletionPacket ENDP ; ULONG64 __stdcall NtCancelIoFileEx( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 ); _6_3_9600_sp0_windows_8_1_NtCancelIoFileEx PROC STDCALL mov r10 , rcx mov eax , 140 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtCancelIoFileEx ENDP ; ULONG64 __stdcall NtCancelSynchronousIoFile( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 ); _6_3_9600_sp0_windows_8_1_NtCancelSynchronousIoFile PROC STDCALL mov r10 , rcx mov eax , 141 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtCancelSynchronousIoFile ENDP ; ULONG64 __stdcall NtCancelTimer2( ULONG64 arg_01 , ULONG64 arg_02 ); _6_3_9600_sp0_windows_8_1_NtCancelTimer2 PROC STDCALL mov r10 , rcx mov eax , 142 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtCancelTimer2 ENDP ; ULONG64 __stdcall NtCancelWaitCompletionPacket( ULONG64 arg_01 , ULONG64 arg_02 ); _6_3_9600_sp0_windows_8_1_NtCancelWaitCompletionPacket PROC STDCALL mov r10 , rcx mov eax , 143 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtCancelWaitCompletionPacket ENDP ; ULONG64 __stdcall NtCommitComplete( ULONG64 arg_01 , ULONG64 arg_02 ); _6_3_9600_sp0_windows_8_1_NtCommitComplete PROC STDCALL mov r10 , rcx mov eax , 144 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtCommitComplete ENDP ; ULONG64 __stdcall NtCommitEnlistment( ULONG64 arg_01 , ULONG64 arg_02 ); _6_3_9600_sp0_windows_8_1_NtCommitEnlistment PROC STDCALL mov r10 , rcx mov eax , 145 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtCommitEnlistment ENDP ; ULONG64 __stdcall NtCommitTransaction( ULONG64 arg_01 , ULONG64 arg_02 ); _6_3_9600_sp0_windows_8_1_NtCommitTransaction PROC STDCALL mov r10 , rcx mov eax , 146 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtCommitTransaction ENDP ; ULONG64 __stdcall NtCompactKeys( ULONG64 arg_01 , ULONG64 arg_02 ); _6_3_9600_sp0_windows_8_1_NtCompactKeys PROC STDCALL mov r10 , rcx mov eax , 147 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtCompactKeys ENDP ; ULONG64 __stdcall NtCompareTokens( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 ); _6_3_9600_sp0_windows_8_1_NtCompareTokens PROC STDCALL mov r10 , rcx mov eax , 148 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtCompareTokens ENDP ; ULONG64 __stdcall NtCompleteConnectPort( ULONG64 arg_01 ); _6_3_9600_sp0_windows_8_1_NtCompleteConnectPort PROC STDCALL mov r10 , rcx mov eax , 149 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtCompleteConnectPort ENDP ; ULONG64 __stdcall NtCompressKey( ULONG64 arg_01 ); _6_3_9600_sp0_windows_8_1_NtCompressKey PROC STDCALL mov r10 , rcx mov eax , 150 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtCompressKey ENDP ; ULONG64 __stdcall NtConnectPort( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 , ULONG64 arg_06 , ULONG64 arg_07 , ULONG64 arg_08 ); _6_3_9600_sp0_windows_8_1_NtConnectPort PROC STDCALL mov r10 , rcx mov eax , 151 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtConnectPort ENDP ; ULONG64 __stdcall NtCreateDebugObject( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 ); _6_3_9600_sp0_windows_8_1_NtCreateDebugObject PROC STDCALL mov r10 , rcx mov eax , 152 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtCreateDebugObject ENDP ; ULONG64 __stdcall NtCreateDirectoryObject( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 ); _6_3_9600_sp0_windows_8_1_NtCreateDirectoryObject PROC STDCALL mov r10 , rcx mov eax , 153 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtCreateDirectoryObject ENDP ; ULONG64 __stdcall NtCreateDirectoryObjectEx( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 ); _6_3_9600_sp0_windows_8_1_NtCreateDirectoryObjectEx PROC STDCALL mov r10 , rcx mov eax , 154 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtCreateDirectoryObjectEx ENDP ; ULONG64 __stdcall NtCreateEnlistment( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 , ULONG64 arg_06 , ULONG64 arg_07 , ULONG64 arg_08 ); _6_3_9600_sp0_windows_8_1_NtCreateEnlistment PROC STDCALL mov r10 , rcx mov eax , 155 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtCreateEnlistment ENDP ; ULONG64 __stdcall NtCreateEventPair( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 ); _6_3_9600_sp0_windows_8_1_NtCreateEventPair PROC STDCALL mov r10 , rcx mov eax , 156 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtCreateEventPair ENDP ; ULONG64 __stdcall NtCreateIRTimer( ULONG64 arg_01 , ULONG64 arg_02 ); _6_3_9600_sp0_windows_8_1_NtCreateIRTimer PROC STDCALL mov r10 , rcx mov eax , 157 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtCreateIRTimer ENDP ; ULONG64 __stdcall NtCreateIoCompletion( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 ); _6_3_9600_sp0_windows_8_1_NtCreateIoCompletion PROC STDCALL mov r10 , rcx mov eax , 158 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtCreateIoCompletion ENDP ; ULONG64 __stdcall NtCreateJobObject( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 ); _6_3_9600_sp0_windows_8_1_NtCreateJobObject PROC STDCALL mov r10 , rcx mov eax , 159 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtCreateJobObject ENDP ; ULONG64 __stdcall NtCreateJobSet( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 ); _6_3_9600_sp0_windows_8_1_NtCreateJobSet PROC STDCALL mov r10 , rcx mov eax , 160 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtCreateJobSet ENDP ; ULONG64 __stdcall NtCreateKeyTransacted( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 , ULONG64 arg_06 , ULONG64 arg_07 , ULONG64 arg_08 ); _6_3_9600_sp0_windows_8_1_NtCreateKeyTransacted PROC STDCALL mov r10 , rcx mov eax , 161 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtCreateKeyTransacted ENDP ; ULONG64 __stdcall NtCreateKeyedEvent( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 ); _6_3_9600_sp0_windows_8_1_NtCreateKeyedEvent PROC STDCALL mov r10 , rcx mov eax , 162 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtCreateKeyedEvent ENDP ; ULONG64 __stdcall NtCreateLowBoxToken( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 , ULONG64 arg_06 , ULONG64 arg_07 , ULONG64 arg_08 , ULONG64 arg_09 ); _6_3_9600_sp0_windows_8_1_NtCreateLowBoxToken PROC STDCALL mov r10 , rcx mov eax , 163 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtCreateLowBoxToken ENDP ; ULONG64 __stdcall NtCreateMailslotFile( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 , ULONG64 arg_06 , ULONG64 arg_07 , ULONG64 arg_08 ); _6_3_9600_sp0_windows_8_1_NtCreateMailslotFile PROC STDCALL mov r10 , rcx mov eax , 164 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtCreateMailslotFile ENDP ; ULONG64 __stdcall NtCreateMutant( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 ); _6_3_9600_sp0_windows_8_1_NtCreateMutant PROC STDCALL mov r10 , rcx mov eax , 165 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtCreateMutant ENDP ; ULONG64 __stdcall NtCreateNamedPipeFile( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 , ULONG64 arg_06 , ULONG64 arg_07 , ULONG64 arg_08 , ULONG64 arg_09 , ULONG64 arg_10 , ULONG64 arg_11 , ULONG64 arg_12 , ULONG64 arg_13 , ULONG64 arg_14 ); _6_3_9600_sp0_windows_8_1_NtCreateNamedPipeFile PROC STDCALL mov r10 , rcx mov eax , 166 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtCreateNamedPipeFile ENDP ; ULONG64 __stdcall NtCreatePagingFile( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 ); _6_3_9600_sp0_windows_8_1_NtCreatePagingFile PROC STDCALL mov r10 , rcx mov eax , 167 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtCreatePagingFile ENDP ; ULONG64 __stdcall NtCreatePort( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 ); _6_3_9600_sp0_windows_8_1_NtCreatePort PROC STDCALL mov r10 , rcx mov eax , 168 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtCreatePort ENDP ; ULONG64 __stdcall NtCreatePrivateNamespace( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 ); _6_3_9600_sp0_windows_8_1_NtCreatePrivateNamespace PROC STDCALL mov r10 , rcx mov eax , 169 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtCreatePrivateNamespace ENDP ; ULONG64 __stdcall NtCreateProcess( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 , ULONG64 arg_06 , ULONG64 arg_07 , ULONG64 arg_08 ); _6_3_9600_sp0_windows_8_1_NtCreateProcess PROC STDCALL mov r10 , rcx mov eax , 170 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtCreateProcess ENDP ; ULONG64 __stdcall NtCreateProfile( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 , ULONG64 arg_06 , ULONG64 arg_07 , ULONG64 arg_08 , ULONG64 arg_09 ); _6_3_9600_sp0_windows_8_1_NtCreateProfile PROC STDCALL mov r10 , rcx mov eax , 171 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtCreateProfile ENDP ; ULONG64 __stdcall NtCreateProfileEx( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 , ULONG64 arg_06 , ULONG64 arg_07 , ULONG64 arg_08 , ULONG64 arg_09 , ULONG64 arg_10 ); _6_3_9600_sp0_windows_8_1_NtCreateProfileEx PROC STDCALL mov r10 , rcx mov eax , 172 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtCreateProfileEx ENDP ; ULONG64 __stdcall NtCreateResourceManager( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 , ULONG64 arg_06 , ULONG64 arg_07 ); _6_3_9600_sp0_windows_8_1_NtCreateResourceManager PROC STDCALL mov r10 , rcx mov eax , 173 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtCreateResourceManager ENDP ; ULONG64 __stdcall NtCreateSemaphore( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 ); _6_3_9600_sp0_windows_8_1_NtCreateSemaphore PROC STDCALL mov r10 , rcx mov eax , 174 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtCreateSemaphore ENDP ; ULONG64 __stdcall NtCreateSymbolicLinkObject( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 ); _6_3_9600_sp0_windows_8_1_NtCreateSymbolicLinkObject PROC STDCALL mov r10 , rcx mov eax , 175 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtCreateSymbolicLinkObject ENDP ; ULONG64 __stdcall NtCreateThreadEx( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 , ULONG64 arg_06 , ULONG64 arg_07 , ULONG64 arg_08 , ULONG64 arg_09 , ULONG64 arg_10 , ULONG64 arg_11 ); _6_3_9600_sp0_windows_8_1_NtCreateThreadEx PROC STDCALL mov r10 , rcx mov eax , 176 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtCreateThreadEx ENDP ; ULONG64 __stdcall NtCreateTimer( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 ); _6_3_9600_sp0_windows_8_1_NtCreateTimer PROC STDCALL mov r10 , rcx mov eax , 177 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtCreateTimer ENDP ; ULONG64 __stdcall NtCreateTimer2( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 ); _6_3_9600_sp0_windows_8_1_NtCreateTimer2 PROC STDCALL mov r10 , rcx mov eax , 178 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtCreateTimer2 ENDP ; ULONG64 __stdcall NtCreateToken( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 , ULONG64 arg_06 , ULONG64 arg_07 , ULONG64 arg_08 , ULONG64 arg_09 , ULONG64 arg_10 , ULONG64 arg_11 , ULONG64 arg_12 , ULONG64 arg_13 ); _6_3_9600_sp0_windows_8_1_NtCreateToken PROC STDCALL mov r10 , rcx mov eax , 179 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtCreateToken ENDP ; ULONG64 __stdcall NtCreateTokenEx( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 , ULONG64 arg_06 , ULONG64 arg_07 , ULONG64 arg_08 , ULONG64 arg_09 , ULONG64 arg_10 , ULONG64 arg_11 , ULONG64 arg_12 , ULONG64 arg_13 , ULONG64 arg_14 , ULONG64 arg_15 , ULONG64 arg_16 , ULONG64 arg_17 ); _6_3_9600_sp0_windows_8_1_NtCreateTokenEx PROC STDCALL mov r10 , rcx mov eax , 180 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtCreateTokenEx ENDP ; ULONG64 __stdcall NtCreateTransaction( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 , ULONG64 arg_06 , ULONG64 arg_07 , ULONG64 arg_08 , ULONG64 arg_09 , ULONG64 arg_10 ); _6_3_9600_sp0_windows_8_1_NtCreateTransaction PROC STDCALL mov r10 , rcx mov eax , 181 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtCreateTransaction ENDP ; ULONG64 __stdcall NtCreateTransactionManager( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 , ULONG64 arg_06 ); _6_3_9600_sp0_windows_8_1_NtCreateTransactionManager PROC STDCALL mov r10 , rcx mov eax , 182 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtCreateTransactionManager ENDP ; ULONG64 __stdcall NtCreateUserProcess( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 , ULONG64 arg_06 , ULONG64 arg_07 , ULONG64 arg_08 , ULONG64 arg_09 , ULONG64 arg_10 , ULONG64 arg_11 ); _6_3_9600_sp0_windows_8_1_NtCreateUserProcess PROC STDCALL mov r10 , rcx mov eax , 183 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtCreateUserProcess ENDP ; ULONG64 __stdcall NtCreateWaitCompletionPacket( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 ); _6_3_9600_sp0_windows_8_1_NtCreateWaitCompletionPacket PROC STDCALL mov r10 , rcx mov eax , 184 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtCreateWaitCompletionPacket ENDP ; ULONG64 __stdcall NtCreateWaitablePort( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 ); _6_3_9600_sp0_windows_8_1_NtCreateWaitablePort PROC STDCALL mov r10 , rcx mov eax , 185 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtCreateWaitablePort ENDP ; ULONG64 __stdcall NtCreateWnfStateName( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 , ULONG64 arg_06 , ULONG64 arg_07 ); _6_3_9600_sp0_windows_8_1_NtCreateWnfStateName PROC STDCALL mov r10 , rcx mov eax , 186 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtCreateWnfStateName ENDP ; ULONG64 __stdcall NtCreateWorkerFactory( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 , ULONG64 arg_06 , ULONG64 arg_07 , ULONG64 arg_08 , ULONG64 arg_09 , ULONG64 arg_10 ); _6_3_9600_sp0_windows_8_1_NtCreateWorkerFactory PROC STDCALL mov r10 , rcx mov eax , 187 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtCreateWorkerFactory ENDP ; ULONG64 __stdcall NtDebugActiveProcess( ULONG64 arg_01 , ULONG64 arg_02 ); _6_3_9600_sp0_windows_8_1_NtDebugActiveProcess PROC STDCALL mov r10 , rcx mov eax , 188 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtDebugActiveProcess ENDP ; ULONG64 __stdcall NtDebugContinue( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 ); _6_3_9600_sp0_windows_8_1_NtDebugContinue PROC STDCALL mov r10 , rcx mov eax , 189 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtDebugContinue ENDP ; ULONG64 __stdcall NtDeleteAtom( ULONG64 arg_01 ); _6_3_9600_sp0_windows_8_1_NtDeleteAtom PROC STDCALL mov r10 , rcx mov eax , 190 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtDeleteAtom ENDP ; ULONG64 __stdcall NtDeleteBootEntry( ULONG64 arg_01 ); _6_3_9600_sp0_windows_8_1_NtDeleteBootEntry PROC STDCALL mov r10 , rcx mov eax , 191 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtDeleteBootEntry ENDP ; ULONG64 __stdcall NtDeleteDriverEntry( ULONG64 arg_01 ); _6_3_9600_sp0_windows_8_1_NtDeleteDriverEntry PROC STDCALL mov r10 , rcx mov eax , 192 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtDeleteDriverEntry ENDP ; ULONG64 __stdcall NtDeleteFile( ULONG64 arg_01 ); _6_3_9600_sp0_windows_8_1_NtDeleteFile PROC STDCALL mov r10 , rcx mov eax , 193 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtDeleteFile ENDP ; ULONG64 __stdcall NtDeleteKey( ULONG64 arg_01 ); _6_3_9600_sp0_windows_8_1_NtDeleteKey PROC STDCALL mov r10 , rcx mov eax , 194 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtDeleteKey ENDP ; ULONG64 __stdcall NtDeleteObjectAuditAlarm( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 ); _6_3_9600_sp0_windows_8_1_NtDeleteObjectAuditAlarm PROC STDCALL mov r10 , rcx mov eax , 195 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtDeleteObjectAuditAlarm ENDP ; ULONG64 __stdcall NtDeletePrivateNamespace( ULONG64 arg_01 ); _6_3_9600_sp0_windows_8_1_NtDeletePrivateNamespace PROC STDCALL mov r10 , rcx mov eax , 196 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtDeletePrivateNamespace ENDP ; ULONG64 __stdcall NtDeleteValueKey( ULONG64 arg_01 , ULONG64 arg_02 ); _6_3_9600_sp0_windows_8_1_NtDeleteValueKey PROC STDCALL mov r10 , rcx mov eax , 197 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtDeleteValueKey ENDP ; ULONG64 __stdcall NtDeleteWnfStateData( ULONG64 arg_01 , ULONG64 arg_02 ); _6_3_9600_sp0_windows_8_1_NtDeleteWnfStateData PROC STDCALL mov r10 , rcx mov eax , 198 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtDeleteWnfStateData ENDP ; ULONG64 __stdcall NtDeleteWnfStateName( ULONG64 arg_01 ); _6_3_9600_sp0_windows_8_1_NtDeleteWnfStateName PROC STDCALL mov r10 , rcx mov eax , 199 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtDeleteWnfStateName ENDP ; ULONG64 __stdcall NtDisableLastKnownGood( ); _6_3_9600_sp0_windows_8_1_NtDisableLastKnownGood PROC STDCALL mov r10 , rcx mov eax , 200 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtDisableLastKnownGood ENDP ; ULONG64 __stdcall NtDisplayString( ULONG64 arg_01 ); _6_3_9600_sp0_windows_8_1_NtDisplayString PROC STDCALL mov r10 , rcx mov eax , 201 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtDisplayString ENDP ; ULONG64 __stdcall NtDrawText( ULONG64 arg_01 ); _6_3_9600_sp0_windows_8_1_NtDrawText PROC STDCALL mov r10 , rcx mov eax , 202 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtDrawText ENDP ; ULONG64 __stdcall NtEnableLastKnownGood( ); _6_3_9600_sp0_windows_8_1_NtEnableLastKnownGood PROC STDCALL mov r10 , rcx mov eax , 203 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtEnableLastKnownGood ENDP ; ULONG64 __stdcall NtEnumerateBootEntries( ULONG64 arg_01 , ULONG64 arg_02 ); _6_3_9600_sp0_windows_8_1_NtEnumerateBootEntries PROC STDCALL mov r10 , rcx mov eax , 204 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtEnumerateBootEntries ENDP ; ULONG64 __stdcall NtEnumerateDriverEntries( ULONG64 arg_01 , ULONG64 arg_02 ); _6_3_9600_sp0_windows_8_1_NtEnumerateDriverEntries PROC STDCALL mov r10 , rcx mov eax , 205 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtEnumerateDriverEntries ENDP ; ULONG64 __stdcall NtEnumerateSystemEnvironmentValuesEx( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 ); _6_3_9600_sp0_windows_8_1_NtEnumerateSystemEnvironmentValuesEx PROC STDCALL mov r10 , rcx mov eax , 206 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtEnumerateSystemEnvironmentValuesEx ENDP ; ULONG64 __stdcall NtEnumerateTransactionObject( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 ); _6_3_9600_sp0_windows_8_1_NtEnumerateTransactionObject PROC STDCALL mov r10 , rcx mov eax , 207 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtEnumerateTransactionObject ENDP ; ULONG64 __stdcall NtExtendSection( ULONG64 arg_01 , ULONG64 arg_02 ); _6_3_9600_sp0_windows_8_1_NtExtendSection PROC STDCALL mov r10 , rcx mov eax , 208 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtExtendSection ENDP ; ULONG64 __stdcall NtFilterBootOption( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 ); _6_3_9600_sp0_windows_8_1_NtFilterBootOption PROC STDCALL mov r10 , rcx mov eax , 209 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtFilterBootOption ENDP ; ULONG64 __stdcall NtFilterToken( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 , ULONG64 arg_06 ); _6_3_9600_sp0_windows_8_1_NtFilterToken PROC STDCALL mov r10 , rcx mov eax , 210 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtFilterToken ENDP ; ULONG64 __stdcall NtFilterTokenEx( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 , ULONG64 arg_06 , ULONG64 arg_07 , ULONG64 arg_08 , ULONG64 arg_09 , ULONG64 arg_10 , ULONG64 arg_11 , ULONG64 arg_12 , ULONG64 arg_13 , ULONG64 arg_14 ); _6_3_9600_sp0_windows_8_1_NtFilterTokenEx PROC STDCALL mov r10 , rcx mov eax , 211 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtFilterTokenEx ENDP ; ULONG64 __stdcall NtFlushBuffersFileEx( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 ); _6_3_9600_sp0_windows_8_1_NtFlushBuffersFileEx PROC STDCALL mov r10 , rcx mov eax , 212 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtFlushBuffersFileEx ENDP ; ULONG64 __stdcall NtFlushInstallUILanguage( ULONG64 arg_01 , ULONG64 arg_02 ); _6_3_9600_sp0_windows_8_1_NtFlushInstallUILanguage PROC STDCALL mov r10 , rcx mov eax , 213 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtFlushInstallUILanguage ENDP ; ULONG64 __stdcall NtFlushInstructionCache( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 ); _6_3_9600_sp0_windows_8_1_NtFlushInstructionCache PROC STDCALL mov r10 , rcx mov eax , 214 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtFlushInstructionCache ENDP ; ULONG64 __stdcall NtFlushKey( ULONG64 arg_01 ); _6_3_9600_sp0_windows_8_1_NtFlushKey PROC STDCALL mov r10 , rcx mov eax , 215 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtFlushKey ENDP ; ULONG64 __stdcall NtFlushProcessWriteBuffers( ); _6_3_9600_sp0_windows_8_1_NtFlushProcessWriteBuffers PROC STDCALL mov r10 , rcx mov eax , 216 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtFlushProcessWriteBuffers ENDP ; ULONG64 __stdcall NtFlushVirtualMemory( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 ); _6_3_9600_sp0_windows_8_1_NtFlushVirtualMemory PROC STDCALL mov r10 , rcx mov eax , 217 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtFlushVirtualMemory ENDP ; ULONG64 __stdcall NtFlushWriteBuffer( ); _6_3_9600_sp0_windows_8_1_NtFlushWriteBuffer PROC STDCALL mov r10 , rcx mov eax , 218 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtFlushWriteBuffer ENDP ; ULONG64 __stdcall NtFreeUserPhysicalPages( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 ); _6_3_9600_sp0_windows_8_1_NtFreeUserPhysicalPages PROC STDCALL mov r10 , rcx mov eax , 219 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtFreeUserPhysicalPages ENDP ; ULONG64 __stdcall NtFreezeRegistry( ULONG64 arg_01 ); _6_3_9600_sp0_windows_8_1_NtFreezeRegistry PROC STDCALL mov r10 , rcx mov eax , 220 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtFreezeRegistry ENDP ; ULONG64 __stdcall NtFreezeTransactions( ULONG64 arg_01 , ULONG64 arg_02 ); _6_3_9600_sp0_windows_8_1_NtFreezeTransactions PROC STDCALL mov r10 , rcx mov eax , 221 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtFreezeTransactions ENDP ; ULONG64 __stdcall NtGetCachedSigningLevel( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 , ULONG64 arg_06 ); _6_3_9600_sp0_windows_8_1_NtGetCachedSigningLevel PROC STDCALL mov r10 , rcx mov eax , 222 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtGetCachedSigningLevel ENDP ; ULONG64 __stdcall NtGetCompleteWnfStateSubscription( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 , ULONG64 arg_06 ); _6_3_9600_sp0_windows_8_1_NtGetCompleteWnfStateSubscription PROC STDCALL mov r10 , rcx mov eax , 223 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtGetCompleteWnfStateSubscription ENDP ; ULONG64 __stdcall NtGetContextThread( ULONG64 arg_01 , ULONG64 arg_02 ); _6_3_9600_sp0_windows_8_1_NtGetContextThread PROC STDCALL mov r10 , rcx mov eax , 224 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtGetContextThread ENDP ; ULONG64 __stdcall NtGetCurrentProcessorNumber( ); _6_3_9600_sp0_windows_8_1_NtGetCurrentProcessorNumber PROC STDCALL mov r10 , rcx mov eax , 225 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtGetCurrentProcessorNumber ENDP ; ULONG64 __stdcall NtGetDevicePowerState( ULONG64 arg_01 , ULONG64 arg_02 ); _6_3_9600_sp0_windows_8_1_NtGetDevicePowerState PROC STDCALL mov r10 , rcx mov eax , 226 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtGetDevicePowerState ENDP ; ULONG64 __stdcall NtGetMUIRegistryInfo( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 ); _6_3_9600_sp0_windows_8_1_NtGetMUIRegistryInfo PROC STDCALL mov r10 , rcx mov eax , 227 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtGetMUIRegistryInfo ENDP ; ULONG64 __stdcall NtGetNextProcess( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 ); _6_3_9600_sp0_windows_8_1_NtGetNextProcess PROC STDCALL mov r10 , rcx mov eax , 228 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtGetNextProcess ENDP ; ULONG64 __stdcall NtGetNextThread( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 , ULONG64 arg_06 ); _6_3_9600_sp0_windows_8_1_NtGetNextThread PROC STDCALL mov r10 , rcx mov eax , 229 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtGetNextThread ENDP ; ULONG64 __stdcall NtGetNlsSectionPtr( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 ); _6_3_9600_sp0_windows_8_1_NtGetNlsSectionPtr PROC STDCALL mov r10 , rcx mov eax , 230 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtGetNlsSectionPtr ENDP ; ULONG64 __stdcall NtGetNotificationResourceManager( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 , ULONG64 arg_06 , ULONG64 arg_07 ); _6_3_9600_sp0_windows_8_1_NtGetNotificationResourceManager PROC STDCALL mov r10 , rcx mov eax , 231 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtGetNotificationResourceManager ENDP ; ULONG64 __stdcall NtGetWriteWatch( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 , ULONG64 arg_06 , ULONG64 arg_07 ); _6_3_9600_sp0_windows_8_1_NtGetWriteWatch PROC STDCALL mov r10 , rcx mov eax , 232 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtGetWriteWatch ENDP ; ULONG64 __stdcall NtImpersonateAnonymousToken( ULONG64 arg_01 ); _6_3_9600_sp0_windows_8_1_NtImpersonateAnonymousToken PROC STDCALL mov r10 , rcx mov eax , 233 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtImpersonateAnonymousToken ENDP ; ULONG64 __stdcall NtImpersonateThread( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 ); _6_3_9600_sp0_windows_8_1_NtImpersonateThread PROC STDCALL mov r10 , rcx mov eax , 234 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtImpersonateThread ENDP ; ULONG64 __stdcall NtInitializeNlsFiles( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 ); _6_3_9600_sp0_windows_8_1_NtInitializeNlsFiles PROC STDCALL mov r10 , rcx mov eax , 235 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtInitializeNlsFiles ENDP ; ULONG64 __stdcall NtInitializeRegistry( ULONG64 arg_01 ); _6_3_9600_sp0_windows_8_1_NtInitializeRegistry PROC STDCALL mov r10 , rcx mov eax , 236 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtInitializeRegistry ENDP ; ULONG64 __stdcall NtInitiatePowerAction( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 ); _6_3_9600_sp0_windows_8_1_NtInitiatePowerAction PROC STDCALL mov r10 , rcx mov eax , 237 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtInitiatePowerAction ENDP ; ULONG64 __stdcall NtIsSystemResumeAutomatic( ); _6_3_9600_sp0_windows_8_1_NtIsSystemResumeAutomatic PROC STDCALL mov r10 , rcx mov eax , 238 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtIsSystemResumeAutomatic ENDP ; ULONG64 __stdcall NtIsUILanguageComitted( ); _6_3_9600_sp0_windows_8_1_NtIsUILanguageComitted PROC STDCALL mov r10 , rcx mov eax , 239 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtIsUILanguageComitted ENDP ; ULONG64 __stdcall NtListenPort( ULONG64 arg_01 , ULONG64 arg_02 ); _6_3_9600_sp0_windows_8_1_NtListenPort PROC STDCALL mov r10 , rcx mov eax , 240 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtListenPort ENDP ; ULONG64 __stdcall NtLoadDriver( ULONG64 arg_01 ); _6_3_9600_sp0_windows_8_1_NtLoadDriver PROC STDCALL mov r10 , rcx mov eax , 241 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtLoadDriver ENDP ; ULONG64 __stdcall NtLoadKey( ULONG64 arg_01 , ULONG64 arg_02 ); _6_3_9600_sp0_windows_8_1_NtLoadKey PROC STDCALL mov r10 , rcx mov eax , 242 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtLoadKey ENDP ; ULONG64 __stdcall NtLoadKey2( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 ); _6_3_9600_sp0_windows_8_1_NtLoadKey2 PROC STDCALL mov r10 , rcx mov eax , 243 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtLoadKey2 ENDP ; ULONG64 __stdcall NtLoadKeyEx( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 , ULONG64 arg_06 , ULONG64 arg_07 , ULONG64 arg_08 ); _6_3_9600_sp0_windows_8_1_NtLoadKeyEx PROC STDCALL mov r10 , rcx mov eax , 244 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtLoadKeyEx ENDP ; ULONG64 __stdcall NtLockFile( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 , ULONG64 arg_06 , ULONG64 arg_07 , ULONG64 arg_08 , ULONG64 arg_09 , ULONG64 arg_10 ); _6_3_9600_sp0_windows_8_1_NtLockFile PROC STDCALL mov r10 , rcx mov eax , 245 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtLockFile ENDP ; ULONG64 __stdcall NtLockProductActivationKeys( ULONG64 arg_01 , ULONG64 arg_02 ); _6_3_9600_sp0_windows_8_1_NtLockProductActivationKeys PROC STDCALL mov r10 , rcx mov eax , 246 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtLockProductActivationKeys ENDP ; ULONG64 __stdcall NtLockRegistryKey( ULONG64 arg_01 ); _6_3_9600_sp0_windows_8_1_NtLockRegistryKey PROC STDCALL mov r10 , rcx mov eax , 247 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtLockRegistryKey ENDP ; ULONG64 __stdcall NtLockVirtualMemory( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 ); _6_3_9600_sp0_windows_8_1_NtLockVirtualMemory PROC STDCALL mov r10 , rcx mov eax , 248 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtLockVirtualMemory ENDP ; ULONG64 __stdcall NtMakePermanentObject( ULONG64 arg_01 ); _6_3_9600_sp0_windows_8_1_NtMakePermanentObject PROC STDCALL mov r10 , rcx mov eax , 249 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtMakePermanentObject ENDP ; ULONG64 __stdcall NtMakeTemporaryObject( ULONG64 arg_01 ); _6_3_9600_sp0_windows_8_1_NtMakeTemporaryObject PROC STDCALL mov r10 , rcx mov eax , 250 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtMakeTemporaryObject ENDP ; ULONG64 __stdcall NtMapCMFModule( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 , ULONG64 arg_06 ); _6_3_9600_sp0_windows_8_1_NtMapCMFModule PROC STDCALL mov r10 , rcx mov eax , 251 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtMapCMFModule ENDP ; ULONG64 __stdcall NtMapUserPhysicalPages( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 ); _6_3_9600_sp0_windows_8_1_NtMapUserPhysicalPages PROC STDCALL mov r10 , rcx mov eax , 252 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtMapUserPhysicalPages ENDP ; ULONG64 __stdcall NtModifyBootEntry( ULONG64 arg_01 ); _6_3_9600_sp0_windows_8_1_NtModifyBootEntry PROC STDCALL mov r10 , rcx mov eax , 253 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtModifyBootEntry ENDP ; ULONG64 __stdcall NtModifyDriverEntry( ULONG64 arg_01 ); _6_3_9600_sp0_windows_8_1_NtModifyDriverEntry PROC STDCALL mov r10 , rcx mov eax , 254 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtModifyDriverEntry ENDP ; ULONG64 __stdcall NtNotifyChangeDirectoryFile( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 , ULONG64 arg_06 , ULONG64 arg_07 , ULONG64 arg_08 , ULONG64 arg_09 ); _6_3_9600_sp0_windows_8_1_NtNotifyChangeDirectoryFile PROC STDCALL mov r10 , rcx mov eax , 255 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtNotifyChangeDirectoryFile ENDP ; ULONG64 __stdcall NtNotifyChangeKey( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 , ULONG64 arg_06 , ULONG64 arg_07 , ULONG64 arg_08 , ULONG64 arg_09 , ULONG64 arg_10 ); _6_3_9600_sp0_windows_8_1_NtNotifyChangeKey PROC STDCALL mov r10 , rcx mov eax , 256 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtNotifyChangeKey ENDP ; ULONG64 __stdcall NtNotifyChangeMultipleKeys( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 , ULONG64 arg_06 , ULONG64 arg_07 , ULONG64 arg_08 , ULONG64 arg_09 , ULONG64 arg_10 , ULONG64 arg_11 , ULONG64 arg_12 ); _6_3_9600_sp0_windows_8_1_NtNotifyChangeMultipleKeys PROC STDCALL mov r10 , rcx mov eax , 257 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtNotifyChangeMultipleKeys ENDP ; ULONG64 __stdcall NtNotifyChangeSession( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 , ULONG64 arg_06 , ULONG64 arg_07 , ULONG64 arg_08 ); _6_3_9600_sp0_windows_8_1_NtNotifyChangeSession PROC STDCALL mov r10 , rcx mov eax , 258 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtNotifyChangeSession ENDP ; ULONG64 __stdcall NtOpenEnlistment( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 ); _6_3_9600_sp0_windows_8_1_NtOpenEnlistment PROC STDCALL mov r10 , rcx mov eax , 259 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtOpenEnlistment ENDP ; ULONG64 __stdcall NtOpenEventPair( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 ); _6_3_9600_sp0_windows_8_1_NtOpenEventPair PROC STDCALL mov r10 , rcx mov eax , 260 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtOpenEventPair ENDP ; ULONG64 __stdcall NtOpenIoCompletion( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 ); _6_3_9600_sp0_windows_8_1_NtOpenIoCompletion PROC STDCALL mov r10 , rcx mov eax , 261 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtOpenIoCompletion ENDP ; ULONG64 __stdcall NtOpenJobObject( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 ); _6_3_9600_sp0_windows_8_1_NtOpenJobObject PROC STDCALL mov r10 , rcx mov eax , 262 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtOpenJobObject ENDP ; ULONG64 __stdcall NtOpenKeyEx( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 ); _6_3_9600_sp0_windows_8_1_NtOpenKeyEx PROC STDCALL mov r10 , rcx mov eax , 263 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtOpenKeyEx ENDP ; ULONG64 __stdcall NtOpenKeyTransacted( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 ); _6_3_9600_sp0_windows_8_1_NtOpenKeyTransacted PROC STDCALL mov r10 , rcx mov eax , 264 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtOpenKeyTransacted ENDP ; ULONG64 __stdcall NtOpenKeyTransactedEx( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 ); _6_3_9600_sp0_windows_8_1_NtOpenKeyTransactedEx PROC STDCALL mov r10 , rcx mov eax , 265 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtOpenKeyTransactedEx ENDP ; ULONG64 __stdcall NtOpenKeyedEvent( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 ); _6_3_9600_sp0_windows_8_1_NtOpenKeyedEvent PROC STDCALL mov r10 , rcx mov eax , 266 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtOpenKeyedEvent ENDP ; ULONG64 __stdcall NtOpenMutant( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 ); _6_3_9600_sp0_windows_8_1_NtOpenMutant PROC STDCALL mov r10 , rcx mov eax , 267 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtOpenMutant ENDP ; ULONG64 __stdcall NtOpenObjectAuditAlarm( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 , ULONG64 arg_06 , ULONG64 arg_07 , ULONG64 arg_08 , ULONG64 arg_09 , ULONG64 arg_10 , ULONG64 arg_11 , ULONG64 arg_12 ); _6_3_9600_sp0_windows_8_1_NtOpenObjectAuditAlarm PROC STDCALL mov r10 , rcx mov eax , 268 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtOpenObjectAuditAlarm ENDP ; ULONG64 __stdcall NtOpenPrivateNamespace( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 ); _6_3_9600_sp0_windows_8_1_NtOpenPrivateNamespace PROC STDCALL mov r10 , rcx mov eax , 269 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtOpenPrivateNamespace ENDP ; ULONG64 __stdcall NtOpenProcessToken( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 ); _6_3_9600_sp0_windows_8_1_NtOpenProcessToken PROC STDCALL mov r10 , rcx mov eax , 270 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtOpenProcessToken ENDP ; ULONG64 __stdcall NtOpenResourceManager( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 ); _6_3_9600_sp0_windows_8_1_NtOpenResourceManager PROC STDCALL mov r10 , rcx mov eax , 271 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtOpenResourceManager ENDP ; ULONG64 __stdcall NtOpenSemaphore( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 ); _6_3_9600_sp0_windows_8_1_NtOpenSemaphore PROC STDCALL mov r10 , rcx mov eax , 272 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtOpenSemaphore ENDP ; ULONG64 __stdcall NtOpenSession( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 ); _6_3_9600_sp0_windows_8_1_NtOpenSession PROC STDCALL mov r10 , rcx mov eax , 273 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtOpenSession ENDP ; ULONG64 __stdcall NtOpenSymbolicLinkObject( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 ); _6_3_9600_sp0_windows_8_1_NtOpenSymbolicLinkObject PROC STDCALL mov r10 , rcx mov eax , 274 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtOpenSymbolicLinkObject ENDP ; ULONG64 __stdcall NtOpenThread( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 ); _6_3_9600_sp0_windows_8_1_NtOpenThread PROC STDCALL mov r10 , rcx mov eax , 275 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtOpenThread ENDP ; ULONG64 __stdcall NtOpenTimer( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 ); _6_3_9600_sp0_windows_8_1_NtOpenTimer PROC STDCALL mov r10 , rcx mov eax , 276 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtOpenTimer ENDP ; ULONG64 __stdcall NtOpenTransaction( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 ); _6_3_9600_sp0_windows_8_1_NtOpenTransaction PROC STDCALL mov r10 , rcx mov eax , 277 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtOpenTransaction ENDP ; ULONG64 __stdcall NtOpenTransactionManager( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 , ULONG64 arg_06 ); _6_3_9600_sp0_windows_8_1_NtOpenTransactionManager PROC STDCALL mov r10 , rcx mov eax , 278 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtOpenTransactionManager ENDP ; ULONG64 __stdcall NtPlugPlayControl( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 ); _6_3_9600_sp0_windows_8_1_NtPlugPlayControl PROC STDCALL mov r10 , rcx mov eax , 279 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtPlugPlayControl ENDP ; ULONG64 __stdcall NtPrePrepareComplete( ULONG64 arg_01 , ULONG64 arg_02 ); _6_3_9600_sp0_windows_8_1_NtPrePrepareComplete PROC STDCALL mov r10 , rcx mov eax , 280 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtPrePrepareComplete ENDP ; ULONG64 __stdcall NtPrePrepareEnlistment( ULONG64 arg_01 , ULONG64 arg_02 ); _6_3_9600_sp0_windows_8_1_NtPrePrepareEnlistment PROC STDCALL mov r10 , rcx mov eax , 281 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtPrePrepareEnlistment ENDP ; ULONG64 __stdcall NtPrepareComplete( ULONG64 arg_01 , ULONG64 arg_02 ); _6_3_9600_sp0_windows_8_1_NtPrepareComplete PROC STDCALL mov r10 , rcx mov eax , 282 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtPrepareComplete ENDP ; ULONG64 __stdcall NtPrepareEnlistment( ULONG64 arg_01 , ULONG64 arg_02 ); _6_3_9600_sp0_windows_8_1_NtPrepareEnlistment PROC STDCALL mov r10 , rcx mov eax , 283 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtPrepareEnlistment ENDP ; ULONG64 __stdcall NtPrivilegeCheck( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 ); _6_3_9600_sp0_windows_8_1_NtPrivilegeCheck PROC STDCALL mov r10 , rcx mov eax , 284 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtPrivilegeCheck ENDP ; ULONG64 __stdcall NtPrivilegeObjectAuditAlarm( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 , ULONG64 arg_06 ); _6_3_9600_sp0_windows_8_1_NtPrivilegeObjectAuditAlarm PROC STDCALL mov r10 , rcx mov eax , 285 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtPrivilegeObjectAuditAlarm ENDP ; ULONG64 __stdcall NtPrivilegedServiceAuditAlarm( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 ); _6_3_9600_sp0_windows_8_1_NtPrivilegedServiceAuditAlarm PROC STDCALL mov r10 , rcx mov eax , 286 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtPrivilegedServiceAuditAlarm ENDP ; ULONG64 __stdcall NtPropagationComplete( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 ); _6_3_9600_sp0_windows_8_1_NtPropagationComplete PROC STDCALL mov r10 , rcx mov eax , 287 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtPropagationComplete ENDP ; ULONG64 __stdcall NtPropagationFailed( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 ); _6_3_9600_sp0_windows_8_1_NtPropagationFailed PROC STDCALL mov r10 , rcx mov eax , 288 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtPropagationFailed ENDP ; ULONG64 __stdcall NtPulseEvent( ULONG64 arg_01 , ULONG64 arg_02 ); _6_3_9600_sp0_windows_8_1_NtPulseEvent PROC STDCALL mov r10 , rcx mov eax , 289 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtPulseEvent ENDP ; ULONG64 __stdcall NtQueryBootEntryOrder( ULONG64 arg_01 , ULONG64 arg_02 ); _6_3_9600_sp0_windows_8_1_NtQueryBootEntryOrder PROC STDCALL mov r10 , rcx mov eax , 290 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtQueryBootEntryOrder ENDP ; ULONG64 __stdcall NtQueryBootOptions( ULONG64 arg_01 , ULONG64 arg_02 ); _6_3_9600_sp0_windows_8_1_NtQueryBootOptions PROC STDCALL mov r10 , rcx mov eax , 291 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtQueryBootOptions ENDP ; ULONG64 __stdcall NtQueryDebugFilterState( ULONG64 arg_01 , ULONG64 arg_02 ); _6_3_9600_sp0_windows_8_1_NtQueryDebugFilterState PROC STDCALL mov r10 , rcx mov eax , 292 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtQueryDebugFilterState ENDP ; ULONG64 __stdcall NtQueryDirectoryObject( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 , ULONG64 arg_06 , ULONG64 arg_07 ); _6_3_9600_sp0_windows_8_1_NtQueryDirectoryObject PROC STDCALL mov r10 , rcx mov eax , 293 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtQueryDirectoryObject ENDP ; ULONG64 __stdcall NtQueryDriverEntryOrder( ULONG64 arg_01 , ULONG64 arg_02 ); _6_3_9600_sp0_windows_8_1_NtQueryDriverEntryOrder PROC STDCALL mov r10 , rcx mov eax , 294 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtQueryDriverEntryOrder ENDP ; ULONG64 __stdcall NtQueryEaFile( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 , ULONG64 arg_06 , ULONG64 arg_07 , ULONG64 arg_08 , ULONG64 arg_09 ); _6_3_9600_sp0_windows_8_1_NtQueryEaFile PROC STDCALL mov r10 , rcx mov eax , 295 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtQueryEaFile ENDP ; ULONG64 __stdcall NtQueryFullAttributesFile( ULONG64 arg_01 , ULONG64 arg_02 ); _6_3_9600_sp0_windows_8_1_NtQueryFullAttributesFile PROC STDCALL mov r10 , rcx mov eax , 296 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtQueryFullAttributesFile ENDP ; ULONG64 __stdcall NtQueryInformationAtom( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 ); _6_3_9600_sp0_windows_8_1_NtQueryInformationAtom PROC STDCALL mov r10 , rcx mov eax , 297 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtQueryInformationAtom ENDP ; ULONG64 __stdcall NtQueryInformationEnlistment( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 ); _6_3_9600_sp0_windows_8_1_NtQueryInformationEnlistment PROC STDCALL mov r10 , rcx mov eax , 298 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtQueryInformationEnlistment ENDP ; ULONG64 __stdcall NtQueryInformationJobObject( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 ); _6_3_9600_sp0_windows_8_1_NtQueryInformationJobObject PROC STDCALL mov r10 , rcx mov eax , 299 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtQueryInformationJobObject ENDP ; ULONG64 __stdcall NtQueryInformationPort( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 ); _6_3_9600_sp0_windows_8_1_NtQueryInformationPort PROC STDCALL mov r10 , rcx mov eax , 300 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtQueryInformationPort ENDP ; ULONG64 __stdcall NtQueryInformationResourceManager( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 ); _6_3_9600_sp0_windows_8_1_NtQueryInformationResourceManager PROC STDCALL mov r10 , rcx mov eax , 301 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtQueryInformationResourceManager ENDP ; ULONG64 __stdcall NtQueryInformationTransaction( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 ); _6_3_9600_sp0_windows_8_1_NtQueryInformationTransaction PROC STDCALL mov r10 , rcx mov eax , 302 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtQueryInformationTransaction ENDP ; ULONG64 __stdcall NtQueryInformationTransactionManager( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 ); _6_3_9600_sp0_windows_8_1_NtQueryInformationTransactionManager PROC STDCALL mov r10 , rcx mov eax , 303 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtQueryInformationTransactionManager ENDP ; ULONG64 __stdcall NtQueryInformationWorkerFactory( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 ); _6_3_9600_sp0_windows_8_1_NtQueryInformationWorkerFactory PROC STDCALL mov r10 , rcx mov eax , 304 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtQueryInformationWorkerFactory ENDP ; ULONG64 __stdcall NtQueryInstallUILanguage( ULONG64 arg_01 ); _6_3_9600_sp0_windows_8_1_NtQueryInstallUILanguage PROC STDCALL mov r10 , rcx mov eax , 305 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtQueryInstallUILanguage ENDP ; ULONG64 __stdcall NtQueryIntervalProfile( ULONG64 arg_01 , ULONG64 arg_02 ); _6_3_9600_sp0_windows_8_1_NtQueryIntervalProfile PROC STDCALL mov r10 , rcx mov eax , 306 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtQueryIntervalProfile ENDP ; ULONG64 __stdcall NtQueryIoCompletion( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 ); _6_3_9600_sp0_windows_8_1_NtQueryIoCompletion PROC STDCALL mov r10 , rcx mov eax , 307 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtQueryIoCompletion ENDP ; ULONG64 __stdcall NtQueryLicenseValue( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 ); _6_3_9600_sp0_windows_8_1_NtQueryLicenseValue PROC STDCALL mov r10 , rcx mov eax , 308 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtQueryLicenseValue ENDP ; ULONG64 __stdcall NtQueryMultipleValueKey( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 , ULONG64 arg_06 ); _6_3_9600_sp0_windows_8_1_NtQueryMultipleValueKey PROC STDCALL mov r10 , rcx mov eax , 309 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtQueryMultipleValueKey ENDP ; ULONG64 __stdcall NtQueryMutant( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 ); _6_3_9600_sp0_windows_8_1_NtQueryMutant PROC STDCALL mov r10 , rcx mov eax , 310 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtQueryMutant ENDP ; ULONG64 __stdcall NtQueryOpenSubKeys( ULONG64 arg_01 , ULONG64 arg_02 ); _6_3_9600_sp0_windows_8_1_NtQueryOpenSubKeys PROC STDCALL mov r10 , rcx mov eax , 311 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtQueryOpenSubKeys ENDP ; ULONG64 __stdcall NtQueryOpenSubKeysEx( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 ); _6_3_9600_sp0_windows_8_1_NtQueryOpenSubKeysEx PROC STDCALL mov r10 , rcx mov eax , 312 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtQueryOpenSubKeysEx ENDP ; ULONG64 __stdcall NtQueryPortInformationProcess( ); _6_3_9600_sp0_windows_8_1_NtQueryPortInformationProcess PROC STDCALL mov r10 , rcx mov eax , 313 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtQueryPortInformationProcess ENDP ; ULONG64 __stdcall NtQueryQuotaInformationFile( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 , ULONG64 arg_06 , ULONG64 arg_07 , ULONG64 arg_08 , ULONG64 arg_09 ); _6_3_9600_sp0_windows_8_1_NtQueryQuotaInformationFile PROC STDCALL mov r10 , rcx mov eax , 314 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtQueryQuotaInformationFile ENDP ; ULONG64 __stdcall NtQuerySecurityAttributesToken( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 , ULONG64 arg_06 ); _6_3_9600_sp0_windows_8_1_NtQuerySecurityAttributesToken PROC STDCALL mov r10 , rcx mov eax , 315 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtQuerySecurityAttributesToken ENDP ; ULONG64 __stdcall NtQuerySecurityObject( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 ); _6_3_9600_sp0_windows_8_1_NtQuerySecurityObject PROC STDCALL mov r10 , rcx mov eax , 316 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtQuerySecurityObject ENDP ; ULONG64 __stdcall NtQuerySemaphore( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 ); _6_3_9600_sp0_windows_8_1_NtQuerySemaphore PROC STDCALL mov r10 , rcx mov eax , 317 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtQuerySemaphore ENDP ; ULONG64 __stdcall NtQuerySymbolicLinkObject( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 ); _6_3_9600_sp0_windows_8_1_NtQuerySymbolicLinkObject PROC STDCALL mov r10 , rcx mov eax , 318 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtQuerySymbolicLinkObject ENDP ; ULONG64 __stdcall NtQuerySystemEnvironmentValue( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 ); _6_3_9600_sp0_windows_8_1_NtQuerySystemEnvironmentValue PROC STDCALL mov r10 , rcx mov eax , 319 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtQuerySystemEnvironmentValue ENDP ; ULONG64 __stdcall NtQuerySystemEnvironmentValueEx( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 ); _6_3_9600_sp0_windows_8_1_NtQuerySystemEnvironmentValueEx PROC STDCALL mov r10 , rcx mov eax , 320 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtQuerySystemEnvironmentValueEx ENDP ; ULONG64 __stdcall NtQuerySystemInformationEx( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 , ULONG64 arg_06 ); _6_3_9600_sp0_windows_8_1_NtQuerySystemInformationEx PROC STDCALL mov r10 , rcx mov eax , 321 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtQuerySystemInformationEx ENDP ; ULONG64 __stdcall NtQueryTimerResolution( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 ); _6_3_9600_sp0_windows_8_1_NtQueryTimerResolution PROC STDCALL mov r10 , rcx mov eax , 322 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtQueryTimerResolution ENDP ; ULONG64 __stdcall NtQueryWnfStateData( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 , ULONG64 arg_06 ); _6_3_9600_sp0_windows_8_1_NtQueryWnfStateData PROC STDCALL mov r10 , rcx mov eax , 323 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtQueryWnfStateData ENDP ; ULONG64 __stdcall NtQueryWnfStateNameInformation( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 ); _6_3_9600_sp0_windows_8_1_NtQueryWnfStateNameInformation PROC STDCALL mov r10 , rcx mov eax , 324 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtQueryWnfStateNameInformation ENDP ; ULONG64 __stdcall NtQueueApcThreadEx( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 , ULONG64 arg_06 ); _6_3_9600_sp0_windows_8_1_NtQueueApcThreadEx PROC STDCALL mov r10 , rcx mov eax , 325 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtQueueApcThreadEx ENDP ; ULONG64 __stdcall NtRaiseException( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 ); _6_3_9600_sp0_windows_8_1_NtRaiseException PROC STDCALL mov r10 , rcx mov eax , 326 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtRaiseException ENDP ; ULONG64 __stdcall NtRaiseHardError( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 , ULONG64 arg_06 ); _6_3_9600_sp0_windows_8_1_NtRaiseHardError PROC STDCALL mov r10 , rcx mov eax , 327 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtRaiseHardError ENDP ; ULONG64 __stdcall NtReadOnlyEnlistment( ULONG64 arg_01 , ULONG64 arg_02 ); _6_3_9600_sp0_windows_8_1_NtReadOnlyEnlistment PROC STDCALL mov r10 , rcx mov eax , 328 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtReadOnlyEnlistment ENDP ; ULONG64 __stdcall NtRecoverEnlistment( ULONG64 arg_01 , ULONG64 arg_02 ); _6_3_9600_sp0_windows_8_1_NtRecoverEnlistment PROC STDCALL mov r10 , rcx mov eax , 329 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtRecoverEnlistment ENDP ; ULONG64 __stdcall NtRecoverResourceManager( ULONG64 arg_01 ); _6_3_9600_sp0_windows_8_1_NtRecoverResourceManager PROC STDCALL mov r10 , rcx mov eax , 330 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtRecoverResourceManager ENDP ; ULONG64 __stdcall NtRecoverTransactionManager( ULONG64 arg_01 ); _6_3_9600_sp0_windows_8_1_NtRecoverTransactionManager PROC STDCALL mov r10 , rcx mov eax , 331 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtRecoverTransactionManager ENDP ; ULONG64 __stdcall NtRegisterProtocolAddressInformation( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 ); _6_3_9600_sp0_windows_8_1_NtRegisterProtocolAddressInformation PROC STDCALL mov r10 , rcx mov eax , 332 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtRegisterProtocolAddressInformation ENDP ; ULONG64 __stdcall NtRegisterThreadTerminatePort( ULONG64 arg_01 ); _6_3_9600_sp0_windows_8_1_NtRegisterThreadTerminatePort PROC STDCALL mov r10 , rcx mov eax , 333 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtRegisterThreadTerminatePort ENDP ; ULONG64 __stdcall NtReleaseKeyedEvent( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 ); _6_3_9600_sp0_windows_8_1_NtReleaseKeyedEvent PROC STDCALL mov r10 , rcx mov eax , 334 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtReleaseKeyedEvent ENDP ; ULONG64 __stdcall NtReleaseWorkerFactoryWorker( ULONG64 arg_01 ); _6_3_9600_sp0_windows_8_1_NtReleaseWorkerFactoryWorker PROC STDCALL mov r10 , rcx mov eax , 335 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtReleaseWorkerFactoryWorker ENDP ; ULONG64 __stdcall NtRemoveIoCompletionEx( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 , ULONG64 arg_06 ); _6_3_9600_sp0_windows_8_1_NtRemoveIoCompletionEx PROC STDCALL mov r10 , rcx mov eax , 336 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtRemoveIoCompletionEx ENDP ; ULONG64 __stdcall NtRemoveProcessDebug( ULONG64 arg_01 , ULONG64 arg_02 ); _6_3_9600_sp0_windows_8_1_NtRemoveProcessDebug PROC STDCALL mov r10 , rcx mov eax , 337 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtRemoveProcessDebug ENDP ; ULONG64 __stdcall NtRenameKey( ULONG64 arg_01 , ULONG64 arg_02 ); _6_3_9600_sp0_windows_8_1_NtRenameKey PROC STDCALL mov r10 , rcx mov eax , 338 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtRenameKey ENDP ; ULONG64 __stdcall NtRenameTransactionManager( ULONG64 arg_01 , ULONG64 arg_02 ); _6_3_9600_sp0_windows_8_1_NtRenameTransactionManager PROC STDCALL mov r10 , rcx mov eax , 339 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtRenameTransactionManager ENDP ; ULONG64 __stdcall NtReplaceKey( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 ); _6_3_9600_sp0_windows_8_1_NtReplaceKey PROC STDCALL mov r10 , rcx mov eax , 340 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtReplaceKey ENDP ; ULONG64 __stdcall NtReplacePartitionUnit( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 ); _6_3_9600_sp0_windows_8_1_NtReplacePartitionUnit PROC STDCALL mov r10 , rcx mov eax , 341 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtReplacePartitionUnit ENDP ; ULONG64 __stdcall NtReplyWaitReplyPort( ULONG64 arg_01 , ULONG64 arg_02 ); _6_3_9600_sp0_windows_8_1_NtReplyWaitReplyPort PROC STDCALL mov r10 , rcx mov eax , 342 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtReplyWaitReplyPort ENDP ; ULONG64 __stdcall NtRequestPort( ULONG64 arg_01 , ULONG64 arg_02 ); _6_3_9600_sp0_windows_8_1_NtRequestPort PROC STDCALL mov r10 , rcx mov eax , 343 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtRequestPort ENDP ; ULONG64 __stdcall NtResetEvent( ULONG64 arg_01 , ULONG64 arg_02 ); _6_3_9600_sp0_windows_8_1_NtResetEvent PROC STDCALL mov r10 , rcx mov eax , 344 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtResetEvent ENDP ; ULONG64 __stdcall NtResetWriteWatch( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 ); _6_3_9600_sp0_windows_8_1_NtResetWriteWatch PROC STDCALL mov r10 , rcx mov eax , 345 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtResetWriteWatch ENDP ; ULONG64 __stdcall NtRestoreKey( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 ); _6_3_9600_sp0_windows_8_1_NtRestoreKey PROC STDCALL mov r10 , rcx mov eax , 346 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtRestoreKey ENDP ; ULONG64 __stdcall NtResumeProcess( ULONG64 arg_01 ); _6_3_9600_sp0_windows_8_1_NtResumeProcess PROC STDCALL mov r10 , rcx mov eax , 347 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtResumeProcess ENDP ; ULONG64 __stdcall NtRollbackComplete( ULONG64 arg_01 , ULONG64 arg_02 ); _6_3_9600_sp0_windows_8_1_NtRollbackComplete PROC STDCALL mov r10 , rcx mov eax , 348 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtRollbackComplete ENDP ; ULONG64 __stdcall NtRollbackEnlistment( ULONG64 arg_01 , ULONG64 arg_02 ); _6_3_9600_sp0_windows_8_1_NtRollbackEnlistment PROC STDCALL mov r10 , rcx mov eax , 349 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtRollbackEnlistment ENDP ; ULONG64 __stdcall NtRollbackTransaction( ULONG64 arg_01 , ULONG64 arg_02 ); _6_3_9600_sp0_windows_8_1_NtRollbackTransaction PROC STDCALL mov r10 , rcx mov eax , 350 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtRollbackTransaction ENDP ; ULONG64 __stdcall NtRollforwardTransactionManager( ULONG64 arg_01 , ULONG64 arg_02 ); _6_3_9600_sp0_windows_8_1_NtRollforwardTransactionManager PROC STDCALL mov r10 , rcx mov eax , 351 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtRollforwardTransactionManager ENDP ; ULONG64 __stdcall NtSaveKey( ULONG64 arg_01 , ULONG64 arg_02 ); _6_3_9600_sp0_windows_8_1_NtSaveKey PROC STDCALL mov r10 , rcx mov eax , 352 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtSaveKey ENDP ; ULONG64 __stdcall NtSaveKeyEx( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 ); _6_3_9600_sp0_windows_8_1_NtSaveKeyEx PROC STDCALL mov r10 , rcx mov eax , 353 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtSaveKeyEx ENDP ; ULONG64 __stdcall NtSaveMergedKeys( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 ); _6_3_9600_sp0_windows_8_1_NtSaveMergedKeys PROC STDCALL mov r10 , rcx mov eax , 354 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtSaveMergedKeys ENDP ; ULONG64 __stdcall NtSecureConnectPort( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 , ULONG64 arg_06 , ULONG64 arg_07 , ULONG64 arg_08 , ULONG64 arg_09 ); _6_3_9600_sp0_windows_8_1_NtSecureConnectPort PROC STDCALL mov r10 , rcx mov eax , 355 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtSecureConnectPort ENDP ; ULONG64 __stdcall NtSerializeBoot( ); _6_3_9600_sp0_windows_8_1_NtSerializeBoot PROC STDCALL mov r10 , rcx mov eax , 356 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtSerializeBoot ENDP ; ULONG64 __stdcall NtSetBootEntryOrder( ULONG64 arg_01 , ULONG64 arg_02 ); _6_3_9600_sp0_windows_8_1_NtSetBootEntryOrder PROC STDCALL mov r10 , rcx mov eax , 357 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtSetBootEntryOrder ENDP ; ULONG64 __stdcall NtSetBootOptions( ULONG64 arg_01 , ULONG64 arg_02 ); _6_3_9600_sp0_windows_8_1_NtSetBootOptions PROC STDCALL mov r10 , rcx mov eax , 358 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtSetBootOptions ENDP ; ULONG64 __stdcall NtSetCachedSigningLevel( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 ); _6_3_9600_sp0_windows_8_1_NtSetCachedSigningLevel PROC STDCALL mov r10 , rcx mov eax , 359 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtSetCachedSigningLevel ENDP ; ULONG64 __stdcall NtSetContextThread( ULONG64 arg_01 , ULONG64 arg_02 ); _6_3_9600_sp0_windows_8_1_NtSetContextThread PROC STDCALL mov r10 , rcx mov eax , 360 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtSetContextThread ENDP ; ULONG64 __stdcall NtSetDebugFilterState( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 ); _6_3_9600_sp0_windows_8_1_NtSetDebugFilterState PROC STDCALL mov r10 , rcx mov eax , 361 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtSetDebugFilterState ENDP ; ULONG64 __stdcall NtSetDefaultHardErrorPort( ULONG64 arg_01 ); _6_3_9600_sp0_windows_8_1_NtSetDefaultHardErrorPort PROC STDCALL mov r10 , rcx mov eax , 362 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtSetDefaultHardErrorPort ENDP ; ULONG64 __stdcall NtSetDefaultLocale( ULONG64 arg_01 , ULONG64 arg_02 ); _6_3_9600_sp0_windows_8_1_NtSetDefaultLocale PROC STDCALL mov r10 , rcx mov eax , 363 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtSetDefaultLocale ENDP ; ULONG64 __stdcall NtSetDefaultUILanguage( ULONG64 arg_01 ); _6_3_9600_sp0_windows_8_1_NtSetDefaultUILanguage PROC STDCALL mov r10 , rcx mov eax , 364 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtSetDefaultUILanguage ENDP ; ULONG64 __stdcall NtSetDriverEntryOrder( ULONG64 arg_01 , ULONG64 arg_02 ); _6_3_9600_sp0_windows_8_1_NtSetDriverEntryOrder PROC STDCALL mov r10 , rcx mov eax , 365 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtSetDriverEntryOrder ENDP ; ULONG64 __stdcall NtSetEaFile( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 ); _6_3_9600_sp0_windows_8_1_NtSetEaFile PROC STDCALL mov r10 , rcx mov eax , 366 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtSetEaFile ENDP ; ULONG64 __stdcall NtSetHighEventPair( ULONG64 arg_01 ); _6_3_9600_sp0_windows_8_1_NtSetHighEventPair PROC STDCALL mov r10 , rcx mov eax , 367 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtSetHighEventPair ENDP ; ULONG64 __stdcall NtSetHighWaitLowEventPair( ULONG64 arg_01 ); _6_3_9600_sp0_windows_8_1_NtSetHighWaitLowEventPair PROC STDCALL mov r10 , rcx mov eax , 368 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtSetHighWaitLowEventPair ENDP ; ULONG64 __stdcall NtSetIRTimer( ULONG64 arg_01 , ULONG64 arg_02 ); _6_3_9600_sp0_windows_8_1_NtSetIRTimer PROC STDCALL mov r10 , rcx mov eax , 369 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtSetIRTimer ENDP ; ULONG64 __stdcall NtSetInformationDebugObject( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 ); _6_3_9600_sp0_windows_8_1_NtSetInformationDebugObject PROC STDCALL mov r10 , rcx mov eax , 370 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtSetInformationDebugObject ENDP ; ULONG64 __stdcall NtSetInformationEnlistment( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 ); _6_3_9600_sp0_windows_8_1_NtSetInformationEnlistment PROC STDCALL mov r10 , rcx mov eax , 371 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtSetInformationEnlistment ENDP ; ULONG64 __stdcall NtSetInformationJobObject( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 ); _6_3_9600_sp0_windows_8_1_NtSetInformationJobObject PROC STDCALL mov r10 , rcx mov eax , 372 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtSetInformationJobObject ENDP ; ULONG64 __stdcall NtSetInformationKey( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 ); _6_3_9600_sp0_windows_8_1_NtSetInformationKey PROC STDCALL mov r10 , rcx mov eax , 373 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtSetInformationKey ENDP ; ULONG64 __stdcall NtSetInformationResourceManager( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 ); _6_3_9600_sp0_windows_8_1_NtSetInformationResourceManager PROC STDCALL mov r10 , rcx mov eax , 374 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtSetInformationResourceManager ENDP ; ULONG64 __stdcall NtSetInformationToken( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 ); _6_3_9600_sp0_windows_8_1_NtSetInformationToken PROC STDCALL mov r10 , rcx mov eax , 375 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtSetInformationToken ENDP ; ULONG64 __stdcall NtSetInformationTransaction( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 ); _6_3_9600_sp0_windows_8_1_NtSetInformationTransaction PROC STDCALL mov r10 , rcx mov eax , 376 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtSetInformationTransaction ENDP ; ULONG64 __stdcall NtSetInformationTransactionManager( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 ); _6_3_9600_sp0_windows_8_1_NtSetInformationTransactionManager PROC STDCALL mov r10 , rcx mov eax , 377 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtSetInformationTransactionManager ENDP ; ULONG64 __stdcall NtSetInformationVirtualMemory( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 , ULONG64 arg_06 ); _6_3_9600_sp0_windows_8_1_NtSetInformationVirtualMemory PROC STDCALL mov r10 , rcx mov eax , 378 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtSetInformationVirtualMemory ENDP ; ULONG64 __stdcall NtSetInformationWorkerFactory( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 ); _6_3_9600_sp0_windows_8_1_NtSetInformationWorkerFactory PROC STDCALL mov r10 , rcx mov eax , 379 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtSetInformationWorkerFactory ENDP ; ULONG64 __stdcall NtSetIntervalProfile( ULONG64 arg_01 , ULONG64 arg_02 ); _6_3_9600_sp0_windows_8_1_NtSetIntervalProfile PROC STDCALL mov r10 , rcx mov eax , 380 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtSetIntervalProfile ENDP ; ULONG64 __stdcall NtSetIoCompletion( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 ); _6_3_9600_sp0_windows_8_1_NtSetIoCompletion PROC STDCALL mov r10 , rcx mov eax , 381 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtSetIoCompletion ENDP ; ULONG64 __stdcall NtSetIoCompletionEx( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 , ULONG64 arg_06 ); _6_3_9600_sp0_windows_8_1_NtSetIoCompletionEx PROC STDCALL mov r10 , rcx mov eax , 382 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtSetIoCompletionEx ENDP ; ULONG64 __stdcall NtSetLdtEntries( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 , ULONG64 arg_06 ); _6_3_9600_sp0_windows_8_1_NtSetLdtEntries PROC STDCALL mov r10 , rcx mov eax , 383 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtSetLdtEntries ENDP ; ULONG64 __stdcall NtSetLowEventPair( ULONG64 arg_01 ); _6_3_9600_sp0_windows_8_1_NtSetLowEventPair PROC STDCALL mov r10 , rcx mov eax , 384 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtSetLowEventPair ENDP ; ULONG64 __stdcall NtSetLowWaitHighEventPair( ULONG64 arg_01 ); _6_3_9600_sp0_windows_8_1_NtSetLowWaitHighEventPair PROC STDCALL mov r10 , rcx mov eax , 385 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtSetLowWaitHighEventPair ENDP ; ULONG64 __stdcall NtSetQuotaInformationFile( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 ); _6_3_9600_sp0_windows_8_1_NtSetQuotaInformationFile PROC STDCALL mov r10 , rcx mov eax , 386 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtSetQuotaInformationFile ENDP ; ULONG64 __stdcall NtSetSecurityObject( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 ); _6_3_9600_sp0_windows_8_1_NtSetSecurityObject PROC STDCALL mov r10 , rcx mov eax , 387 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtSetSecurityObject ENDP ; ULONG64 __stdcall NtSetSystemEnvironmentValue( ULONG64 arg_01 , ULONG64 arg_02 ); _6_3_9600_sp0_windows_8_1_NtSetSystemEnvironmentValue PROC STDCALL mov r10 , rcx mov eax , 388 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtSetSystemEnvironmentValue ENDP ; ULONG64 __stdcall NtSetSystemEnvironmentValueEx( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 ); _6_3_9600_sp0_windows_8_1_NtSetSystemEnvironmentValueEx PROC STDCALL mov r10 , rcx mov eax , 389 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtSetSystemEnvironmentValueEx ENDP ; ULONG64 __stdcall NtSetSystemInformation( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 ); _6_3_9600_sp0_windows_8_1_NtSetSystemInformation PROC STDCALL mov r10 , rcx mov eax , 390 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtSetSystemInformation ENDP ; ULONG64 __stdcall NtSetSystemPowerState( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 ); _6_3_9600_sp0_windows_8_1_NtSetSystemPowerState PROC STDCALL mov r10 , rcx mov eax , 391 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtSetSystemPowerState ENDP ; ULONG64 __stdcall NtSetSystemTime( ULONG64 arg_01 , ULONG64 arg_02 ); _6_3_9600_sp0_windows_8_1_NtSetSystemTime PROC STDCALL mov r10 , rcx mov eax , 392 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtSetSystemTime ENDP ; ULONG64 __stdcall NtSetThreadExecutionState( ULONG64 arg_01 , ULONG64 arg_02 ); _6_3_9600_sp0_windows_8_1_NtSetThreadExecutionState PROC STDCALL mov r10 , rcx mov eax , 393 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtSetThreadExecutionState ENDP ; ULONG64 __stdcall NtSetTimer2( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 ); _6_3_9600_sp0_windows_8_1_NtSetTimer2 PROC STDCALL mov r10 , rcx mov eax , 394 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtSetTimer2 ENDP ; ULONG64 __stdcall NtSetTimerEx( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 ); _6_3_9600_sp0_windows_8_1_NtSetTimerEx PROC STDCALL mov r10 , rcx mov eax , 395 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtSetTimerEx ENDP ; ULONG64 __stdcall NtSetTimerResolution( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 ); _6_3_9600_sp0_windows_8_1_NtSetTimerResolution PROC STDCALL mov r10 , rcx mov eax , 396 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtSetTimerResolution ENDP ; ULONG64 __stdcall NtSetUuidSeed( ULONG64 arg_01 ); _6_3_9600_sp0_windows_8_1_NtSetUuidSeed PROC STDCALL mov r10 , rcx mov eax , 397 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtSetUuidSeed ENDP ; ULONG64 __stdcall NtSetVolumeInformationFile( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 ); _6_3_9600_sp0_windows_8_1_NtSetVolumeInformationFile PROC STDCALL mov r10 , rcx mov eax , 398 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtSetVolumeInformationFile ENDP ; ULONG64 __stdcall NtSetWnfProcessNotificationEvent( ULONG64 arg_01 ); _6_3_9600_sp0_windows_8_1_NtSetWnfProcessNotificationEvent PROC STDCALL mov r10 , rcx mov eax , 399 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtSetWnfProcessNotificationEvent ENDP ; ULONG64 __stdcall NtShutdownSystem( ULONG64 arg_01 ); _6_3_9600_sp0_windows_8_1_NtShutdownSystem PROC STDCALL mov r10 , rcx mov eax , 400 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtShutdownSystem ENDP ; ULONG64 __stdcall NtShutdownWorkerFactory( ULONG64 arg_01 , ULONG64 arg_02 ); _6_3_9600_sp0_windows_8_1_NtShutdownWorkerFactory PROC STDCALL mov r10 , rcx mov eax , 401 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtShutdownWorkerFactory ENDP ; ULONG64 __stdcall NtSignalAndWaitForSingleObject( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 ); _6_3_9600_sp0_windows_8_1_NtSignalAndWaitForSingleObject PROC STDCALL mov r10 , rcx mov eax , 402 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtSignalAndWaitForSingleObject ENDP ; ULONG64 __stdcall NtSinglePhaseReject( ULONG64 arg_01 , ULONG64 arg_02 ); _6_3_9600_sp0_windows_8_1_NtSinglePhaseReject PROC STDCALL mov r10 , rcx mov eax , 403 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtSinglePhaseReject ENDP ; ULONG64 __stdcall NtStartProfile( ULONG64 arg_01 ); _6_3_9600_sp0_windows_8_1_NtStartProfile PROC STDCALL mov r10 , rcx mov eax , 404 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtStartProfile ENDP ; ULONG64 __stdcall NtStopProfile( ULONG64 arg_01 ); _6_3_9600_sp0_windows_8_1_NtStopProfile PROC STDCALL mov r10 , rcx mov eax , 405 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtStopProfile ENDP ; ULONG64 __stdcall NtSubscribeWnfStateChange( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 ); _6_3_9600_sp0_windows_8_1_NtSubscribeWnfStateChange PROC STDCALL mov r10 , rcx mov eax , 406 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtSubscribeWnfStateChange ENDP ; ULONG64 __stdcall NtSuspendProcess( ULONG64 arg_01 ); _6_3_9600_sp0_windows_8_1_NtSuspendProcess PROC STDCALL mov r10 , rcx mov eax , 407 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtSuspendProcess ENDP ; ULONG64 __stdcall NtSuspendThread( ULONG64 arg_01 , ULONG64 arg_02 ); _6_3_9600_sp0_windows_8_1_NtSuspendThread PROC STDCALL mov r10 , rcx mov eax , 408 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtSuspendThread ENDP ; ULONG64 __stdcall NtSystemDebugControl( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 , ULONG64 arg_06 ); _6_3_9600_sp0_windows_8_1_NtSystemDebugControl PROC STDCALL mov r10 , rcx mov eax , 409 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtSystemDebugControl ENDP ; ULONG64 __stdcall NtTerminateJobObject( ULONG64 arg_01 , ULONG64 arg_02 ); _6_3_9600_sp0_windows_8_1_NtTerminateJobObject PROC STDCALL mov r10 , rcx mov eax , 410 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtTerminateJobObject ENDP ; ULONG64 __stdcall NtTestAlert( ); _6_3_9600_sp0_windows_8_1_NtTestAlert PROC STDCALL mov r10 , rcx mov eax , 411 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtTestAlert ENDP ; ULONG64 __stdcall NtThawRegistry( ); _6_3_9600_sp0_windows_8_1_NtThawRegistry PROC STDCALL mov r10 , rcx mov eax , 412 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtThawRegistry ENDP ; ULONG64 __stdcall NtThawTransactions( ); _6_3_9600_sp0_windows_8_1_NtThawTransactions PROC STDCALL mov r10 , rcx mov eax , 413 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtThawTransactions ENDP ; ULONG64 __stdcall NtTraceControl( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 , ULONG64 arg_06 ); _6_3_9600_sp0_windows_8_1_NtTraceControl PROC STDCALL mov r10 , rcx mov eax , 414 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtTraceControl ENDP ; ULONG64 __stdcall NtTranslateFilePath( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 ); _6_3_9600_sp0_windows_8_1_NtTranslateFilePath PROC STDCALL mov r10 , rcx mov eax , 415 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtTranslateFilePath ENDP ; ULONG64 __stdcall NtUmsThreadYield( ULONG64 arg_01 ); _6_3_9600_sp0_windows_8_1_NtUmsThreadYield PROC STDCALL mov r10 , rcx mov eax , 416 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtUmsThreadYield ENDP ; ULONG64 __stdcall NtUnloadDriver( ULONG64 arg_01 ); _6_3_9600_sp0_windows_8_1_NtUnloadDriver PROC STDCALL mov r10 , rcx mov eax , 417 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtUnloadDriver ENDP ; ULONG64 __stdcall NtUnloadKey( ULONG64 arg_01 ); _6_3_9600_sp0_windows_8_1_NtUnloadKey PROC STDCALL mov r10 , rcx mov eax , 418 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtUnloadKey ENDP ; ULONG64 __stdcall NtUnloadKey2( ULONG64 arg_01 , ULONG64 arg_02 ); _6_3_9600_sp0_windows_8_1_NtUnloadKey2 PROC STDCALL mov r10 , rcx mov eax , 419 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtUnloadKey2 ENDP ; ULONG64 __stdcall NtUnloadKeyEx( ULONG64 arg_01 , ULONG64 arg_02 ); _6_3_9600_sp0_windows_8_1_NtUnloadKeyEx PROC STDCALL mov r10 , rcx mov eax , 420 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtUnloadKeyEx ENDP ; ULONG64 __stdcall NtUnlockFile( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 ); _6_3_9600_sp0_windows_8_1_NtUnlockFile PROC STDCALL mov r10 , rcx mov eax , 421 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtUnlockFile ENDP ; ULONG64 __stdcall NtUnlockVirtualMemory( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 ); _6_3_9600_sp0_windows_8_1_NtUnlockVirtualMemory PROC STDCALL mov r10 , rcx mov eax , 422 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtUnlockVirtualMemory ENDP ; ULONG64 __stdcall NtUnmapViewOfSectionEx( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 ); _6_3_9600_sp0_windows_8_1_NtUnmapViewOfSectionEx PROC STDCALL mov r10 , rcx mov eax , 423 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtUnmapViewOfSectionEx ENDP ; ULONG64 __stdcall NtUnsubscribeWnfStateChange( ULONG64 arg_01 ); _6_3_9600_sp0_windows_8_1_NtUnsubscribeWnfStateChange PROC STDCALL mov r10 , rcx mov eax , 424 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtUnsubscribeWnfStateChange ENDP ; ULONG64 __stdcall NtUpdateWnfStateData( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 , ULONG64 arg_06 , ULONG64 arg_07 ); _6_3_9600_sp0_windows_8_1_NtUpdateWnfStateData PROC STDCALL mov r10 , rcx mov eax , 425 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtUpdateWnfStateData ENDP ; ULONG64 __stdcall NtVdmControl( ULONG64 arg_01 , ULONG64 arg_02 ); _6_3_9600_sp0_windows_8_1_NtVdmControl PROC STDCALL mov r10 , rcx mov eax , 426 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtVdmControl ENDP ; ULONG64 __stdcall NtWaitForAlertByThreadId( ULONG64 arg_01 , ULONG64 arg_02 ); _6_3_9600_sp0_windows_8_1_NtWaitForAlertByThreadId PROC STDCALL mov r10 , rcx mov eax , 427 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtWaitForAlertByThreadId ENDP ; ULONG64 __stdcall NtWaitForDebugEvent( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 ); _6_3_9600_sp0_windows_8_1_NtWaitForDebugEvent PROC STDCALL mov r10 , rcx mov eax , 428 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtWaitForDebugEvent ENDP ; ULONG64 __stdcall NtWaitForKeyedEvent( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 ); _6_3_9600_sp0_windows_8_1_NtWaitForKeyedEvent PROC STDCALL mov r10 , rcx mov eax , 429 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtWaitForKeyedEvent ENDP ; ULONG64 __stdcall NtWaitForWorkViaWorkerFactory( ULONG64 arg_01 , ULONG64 arg_02 , ULONG64 arg_03 , ULONG64 arg_04 , ULONG64 arg_05 ); _6_3_9600_sp0_windows_8_1_NtWaitForWorkViaWorkerFactory PROC STDCALL mov r10 , rcx mov eax , 430 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtWaitForWorkViaWorkerFactory ENDP ; ULONG64 __stdcall NtWaitHighEventPair( ULONG64 arg_01 ); _6_3_9600_sp0_windows_8_1_NtWaitHighEventPair PROC STDCALL mov r10 , rcx mov eax , 431 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtWaitHighEventPair ENDP ; ULONG64 __stdcall NtWaitLowEventPair( ULONG64 arg_01 ); _6_3_9600_sp0_windows_8_1_NtWaitLowEventPair PROC STDCALL mov r10 , rcx mov eax , 432 ;syscall db 0Fh , 05h ret _6_3_9600_sp0_windows_8_1_NtWaitLowEventPair ENDP
oeis/140/A140472.asm
neoneye/loda-programs
11
240996
<gh_stars>10-100 ; A140472: Chaotic sequence related to A004001: a(n) = a(n - a(n-1)) + a(floor(n/2)). ; 0,1,2,2,4,3,4,4,8,5,6,6,8,7,8,8,16,9,10,10,12,11,12,12,16,13,14,14,16,15,16,16,32,17,18,18,20,19,20,20,24,21,22,22,24,23,24,24,32,25,26,26,28,27,28,28,32,29,30,30,32,31,32,32,64,33,34,34,36,35,36,36,40,37,38,38,40,39,40,40,48,41,42,42,44,43,44,44,48,45,46,46,48,47,48,48,64,49,50,50 mov $2,2 pow $2,$0 gcd $2,$0 add $0,$2 div $0,2
x86-64/Algebra64.asm
Luis-D/libLDM
0
91461
<gh_stars>0 ; <NAME>. 2019 ; To be used with NASM-Compatible Assemblers ; For x86-64 architecture. ; System V AMD64 ABI Convention (*nix) ; Function parameters are passed this way: ; Interger values: RDI, RSI, RDX, RCX, R8, R9 ; Floating Point values: XMM0, XMM1, XMM2, XMM3, XMM4, XMM5, XMM6, XMM7 ; Extra arguments are pushed on the stack starting from the most left argument ; Function return value is returned this way: ; Integer value: RAX:RDX ; Floating point value: XMM0:XMM1 ; RAX, R10 and R11 are volatile ; Microsoft x64 calling convention (Windows) ; Function parameters are passed this way: ; Interger values: RCX, RDX, R8, R9 ; Floating point values: XMM0, XMM1, XMM2, XMM3 ; Both kind of arguments are counted together ; e.g. if the second argument is a float, it will be in arg2f, if Interger, then RDX ; Extra arguments are pushed on the stack ; Function return value is returned this way: ; Integer value: RAX ; Floating point value: XMM0 ; XMM4, XMM5, RAX, R10 and R11 are volatile ; SSE, SSE2, SSE3, FPU ; Format = ; INSTRUCTION(Destiny, Operand1, Operand2, Operand3, ... , OperandN) ; Original Source code from Luis-D/Boring-NASM-Code. ; Collection of mathematical functions and MACROS, very useful for algebra. ;January 11, 2019: Code writing started. ;January 21, 2019: 2x2 Matrix Math added. ;February 05,2019: 2D Norm fixed ;February 28,2019: Projection and view matrix operations added. ;March 02, 2019: Many errors fixed. ;March 14, 2019: Windows routines prologues fixed. ;April 02, 2019: Quaternion Normalized LERP added. ;April 14, 2019: MADSS and SSMAD Operations added. ;June 03, 2019: Inversion instructions added. Absolute value instruction added. ;April 01, 2020: Orthogonal projection redone. ;TODO: ;July 27, 2020: Complete SLERP. ;July 27, 2020: Interleave instructions to gain performance. ;July 31, 2020: Rewrite in GAS ;Notes: ; - Matrices are COLUMN MAJOR. ; - "LEGACY MACROS" are pieces of code from Boring-NASM-Code ; - V2ANGLE does not have a MACRO version. This routine uses FPU. ; - V2V2ANGLE does not have a MACRO version. This routine uses FPU. ; - ANGLEROTV2 does not have a MACRO version. This routine uses FPU. ; - EULERTOQUAT does not have a MACRO version. This routine uses FPU. ; - QUATTOM4 does not have a MACRO version. This routine uses FPU. ; - None of the 4x4 matrices operations have MACROS versions due to their complexity. ; - "AM4" stands for "Affine transformation of Mat4", refering to it's upper 3x3 submatrix. ; - Some of the 2x2 matrices operations doesn't have MACROS versions due to their simplicity. %ifndef _LD_Algebra_64_ASM_ %define _LD_Algebra_64_ASM_ %include "LDM_MACROS.asm" ; Compile with -i ;***************************** ;MACROS ;***************************** args_reset ;<--Sets arguments definitions to normal, as it's definitions can change. %macro TRANS44 0 ; *** LEGACY MACRO *** ; Result in XMM0:XMM2:XMM4:XMM5 movaps xmm4, xmm0 movaps xmm6, xmm2 punpckldq xmm0,xmm1 punpckldq xmm2,xmm3 punpckhdq xmm4,xmm1 punpckhdq xmm6,xmm3 movaps xmm1,xmm0 movaps xmm5,xmm4 punpcklqdq xmm0,xmm2 punpckhqdq xmm1,xmm2 punpcklqdq xmm4,xmm6 punpckhqdq xmm5,xmm6 %endmacro %macro MULVEC4VEC4 3 ; *** LEGACY MACRO *** ;Multiplies XMM0:XMM1:XMM4:XMM5 by XMM2:XMM3:XMM6:XMM7 movups arg3f,[%1+%3] movaps xmm7,arg3f mulps arg3f,arg1f movshdup arg4f, arg3f addps arg3f, arg4f movaps xmm6,xmm7 movhlps arg4f, arg3f addss arg3f, arg4f movss [%2+%3], arg3f;//<--- Important mulps xmm6,arg2f movshdup arg4f, xmm6 addps xmm6, arg4f movaps arg3f,xmm7 movhlps arg4f, xmm6 addss xmm6, arg4f movss [%2+4+%3], xmm6;//<--- Important mulps arg3f,xmm4 movshdup arg4f, arg3f addps arg3f, arg4f movaps xmm6,xmm7 movhlps arg4f, arg3f addss arg3f, arg4f movss [%2+8+%3], arg3f;<--- Important mulps xmm6,xmm5 movshdup arg4f, xmm6 addps xmm6, arg4f movhlps arg4f, xmm6 addss xmm6, arg4f movss [%2+8+4+%3], xmm6;<--- Important %endmacro section .data ;***Constants loads***; ;***** Constants *****; fc_360f: equ 0x43b40000 ;32-bits 360.f fc_2f: equ 01000000000000000000000000000000b ;32-bits 2.f fc_m_1f: equ 0xbf800000 ;32-bits -1.f fc_1f: equ 0x3f800000 ;32-bits +1.f SignChange32bits: equ 10000000000000000000000000000000b ;It can change the sign if XOR'd fc_180f: equ 0x43340000 ;32-bits 180.f fc_PIdiv180f: equ 0x3c8efa35 ;32-bits (PI/180.f) fc_180fdivPI: equ 0x42652ee1 ;32-bits (180.f/PI) ;*********************; section .text ;*** Simple float MATH ***; global SSABS; float ABSSS(float Operand); SSABS: _enter_ pcmpeqw xmm4,xmm4 psrld xmm4,1 pand xmm0,xmm4 _leave_ ret global SSCLAMP; float CLAMPSS(float Value,float Min, float Max) SSCLAMP: _enter_ ucomiss xmm0,xmm1 ja CLAMPSS_NO_MIN movss xmm0,xmm1 CLAMPSS_NO_MIN: ucomiss xmm0,xmm2 jb CLAMPSS_END movss xmm0,xmm2 CLAMPSS_END: _leave_ ret ;***VECTOR 4 MATH***; %macro _V4MATH_ARITHMETIC_ROUTINE 1 ;%1 = operation movups xmm0,[arg2] ; <- Unaligned %1 xmm0,[arg3] movntps [arg1],xmm0 %endmacro %macro _V4MATH_SCALAR_ROUTINE 1 ;%1 = operation movups arg2f,[arg2] shufps arg1f,arg1f,0 %1 arg2f,arg1f movntps [arg1],arg2f %endmacro global V4ADD; void V4ADD( void * Result, void * A, void * B) ;************************************ ; V4 Result = (A.x + B.x , X.y + B.y, A.z + B.z , A.w + B.w) ;************************************ V4ADD: _enter_ _V4MATH_ARITHMETIC_ROUTINE addps _leave_ ret global V4SUB; void V4SUB(void * Result, void * A, void * B) ;************************************ ; V4 Result = (A.x - B.x , X.y - B.y, A.z - B.z , A.w - B.w) ;************************************ V4SUB: _enter_ _V4MATH_ARITHMETIC_ROUTINE subps _leave_ ret global V4MUL; void V4MUL(void * Result, void * A, void * B) ;************************************ ; V4 Result = (A.x * B.x , X.y * B.y, A.z * B.z , A.w * B.w) ;************************************ V4MUL: _enter_ _V4MATH_ARITHMETIC_ROUTINE mulps _leave_ ret global V4DIV; void V4DIV(void * Result, void * A, void * B) ;************************************ ; V4 Result = (A.x / B.x , X.y / B.y, A.z / B.z , A.w / B.w) ;************************************ V4DIV: _enter_ _V4MATH_ARITHMETIC_ROUTINE divps _leave_ ret global V4MULSS; void V4MULSS (void * result, void * Vector, float FLOAT) ;************************************ ; V4 Result = (A.x * FLOAT , X.y * FLOAT, A.z * FLOAT , A.w * FLOAT) ;************************************ V4MULSS: %ifidn __OUTPUT_FORMAT__, win64 %define arg1f XMM2 %define arg2f XMM3 %endif _enter_ _V4MATH_SCALAR_ROUTINE mulps _leave_ ret %ifidn __OUTPUT_FORMAT__, win64 args_reset %endif global V4DIVSS; void V4DIVSS (void * result, void * Vector, float FLOAT) ;************************************ ; V2 Result = (A.x / FLOAT , X.y / FLOAT, A.z / FLOAT , A.w / FLOAT) ;************************************ V4DIVSS: %ifidn __OUTPUT_FORMAT__, win64 %define arg1f XMM2 %define arg2f XMM3 %endif _enter_ _V4MATH_SCALAR_ROUTINE divps _leave_ ret %ifidn __OUTPUT_FORMAT__, win64 args_reset %endif global V4MADSS ;void V4MADSS(void * Result, void * A, void * B, float C) ;************************************ ;V4 Resul = (A + (B*C)) ;************************************ V4MADSS: %ifidn __OUTPUT_FORMAT__, win64 %define arg1f XMM3 %endif _enter_ movups xmm5,[arg3] pshufd arg1f,arg1f,0 movups xmm4,[arg2] mulps xmm5,arg1f addps xmm4,xmm5 movups [arg1],xmm4 %ifidn __OUTPUT_FORMAT__, win64 args_reset %endif _leave_ ret ;*** VECTOR 4 ALGEBRA***/ %macro _V4NORMALIZE_ 4 ;%1 = Destination Operand ;%2 = Source Operand ;%3 = Temporal Operand (Trasheable) ;%4 = Temporal Operand (Trasheable) movaps %4,%2 movaps %1,%2 mulps %4,%4 movshdup %3,%4 addps %4,%3 movhlps %3,%4 addss %4,%3 sqrtss %4,%4 pshufd %4,%4,0 divps %1,%4 %endmacro global V4NORMALIZE; void V4NORMALIZE (void * result,void * Vector) ;*************************************************************************** ; Given a vector (Vector), this algorithm returns a normalized version of it. ;*************************************************************************** V4NORMALIZE: _enter_ movups xmm1,[arg2] _V4NORMALIZE_ xmm0,xmm1,xmm2,xmm3 movntps [arg1],xmm0 _leave_ ret %macro DotProductXMM 4 ;%1 and %2 are registers to proccess ;%3 is the result ;Result stored in the first 32-bits ;%4 is a temporal register movaps %3, %1 mulps %3, %2 movshdup %4,%3 addps %3,%4 movhlps %4,%3 addss %3,%4 %endmacro %macro _V4DOT_ 4 ;%1 is the Destiny Operand. The result is stored in the first 32-bits ;%2 and %3 are registers to proccess ;%4 is a temporal register DotProductXMM %2,%3,%1,%4 %endmacro global V4DOT; float V4DOT(void * A, void * B) ;******************************************************************************* ; Given a vector (Vector), this algorithm returns the dot product version of it. ;******************************************************************************* V4DOT: movups xmm1,[arg1] pxor xmm0,xmm0 movups xmm2,[arg2] _V4DOT_ xmm0,xmm1,xmm2,xmm3 ret %macro _V4Lerp_ 4 ;%1 Is the First Operand Vector (A) ;%2 Is the Second Operand Vector (B) ;%3 Is the Factor Operand Vector (t) (Previously pshufd' by itself with 0) ;%4 Is the Destiny Vector (C) ;All operands must be different movaps %4,%2 subps %4,%1 ;B-A mulps %4,%3 ;(B-A)*t addps %4,%1 ;C = A+((B-A)*t) %endmacro %macro _V4LERP_ 4 ;%1 Is the Destiny Operand ;%2 Is the First Operand Vector ;%3 Is the Second Operand Vector ;%4 Is the Factor Operand Vector (Previously pshufd' by itself with 0) ;All operands must be different _V4Lerp_ %2, %3, %4, %1 %endmacro global V4LERP; void V4LERP(void * Result, void * A, void * B, float factor) ;******************************************************** ;Given two 4D vectors (A and B) and a scalar factor, ;this algorithm does a Linear Interpolation ;The result, a 4D vector, is stored in QR ;******************************************************** V4LERP: %ifidn __OUTPUT_FORMAT__, win64 %define arg1f XMM3 ;The fourth argument is a float, Factor. %define argrf XMM0 ;The result will be stored here. %elifidn __OUTPUT_FORMAT__, elf64 %define argrf XMM3 ;The result will be stored here. %endif _enter_ movups XMM1,[arg2] pshufd arg1f,arg1f,0 movups XMM2,[arg3] _V4Lerp_ XMM1,XMM2,arg1f,argrf movntps [arg1],argrf _leave_ ret %ifidn __OUTPUT_FORMAT__, win64 args_reset %endif %macro _V4NORM_ 3 ;%1 Is the Destiny Operand. ;%2 Is the Vector. ;%3 Is a temporal Operand (trasheable). movaps %3,%2 mulps %3,%3 movshdup %1,%3 addps %1,%3 movhlps %3,%1 addss %1,%3 sqrtss %1,%1 %endmacro global V4NORM; float V4NORM(void * A) V4NORM: _enter_ movups xmm1,[arg1] pxor xmm0,xmm0 _V4NORM_ xmm0,xmm1,xmm2 _leave_ ret %macro _V4DISTANCE_ 4 ;%1 Is the Destiny Operand. ;%2 Is the Vector A. ;%3 Is the Vector B. ;%4 Is a temporal Operand (trasheable). movaps %4,%3 subps %4,%2 _V4NORM_ %1,%4,%3 %endmacro global V4DISTANCE; float V4NORM(void * A, void * B) ;******************************************************************** ;Given two vectors, this algorithm returns the distance between them. ;******************************************************************** V4DISTANCE: _enter_ movups xmm1,[arg1] pxor xmm0,xmm0 movups xmm2,[arg2] _V4DISTANCE_ xmm0,xmm1,xmm2,xmm3 _leave_ ret global V4INV; void V4INV(void * Result, void * Operand) ;************************************* ;V4 Result = -Operand ;************************************ V4INV: _enter_ movups xmm1,[arg2] pcmpeqw xmm0,xmm0 pslld xmm0,31 pxor xmm1,xmm0 movups [arg1],xmm1 _leave_ ret ;***VECTOR 2 MATH***; %macro _V2MATH_ARITHMETIC_ROUTINE 1 ;%1 = operation movlps xmm0,[arg2] movlps xmm1,[arg3] %1 xmm0,xmm1 movsd [arg1],xmm0 %endmacro %macro _V2MATH_SCALAR_ROUTINE 1 ;%1 = operation movlps arg2f,[arg2] shufps arg1f,arg1f,0 %1 arg2f,arg1f movsd [arg1],arg2f %endmacro global V2ADD; ;************************************ ; V2 Result = (A.x + B.x , A.y + B.y) ;************************************ V2ADD: _enter_ _V2MATH_ARITHMETIC_ROUTINE addps _leave_ ret global V2SUB; ;************************************ ; V2 Result = (A.x - B.x , A.y - B.y) ;************************************ V2SUB: _enter_ _V2MATH_ARITHMETIC_ROUTINE subps _leave_ ret global V2MUL; ;************************************ ; V2 Result = (A.x * B.x , A.y * B.y) ;************************************ V2MUL: _enter_ _V2MATH_ARITHMETIC_ROUTINE mulps _leave_ ret global V2DIV; ;************************************ ; V2 Result = (A.x / B.x , A.y / B.y) ;************************************ V2DIV: _enter_ _V2MATH_ARITHMETIC_ROUTINE divps _leave_ ret global V2MULSS; ;************************************ ; V2 Result = (A.x * FLOAT , A.y * FLOAT) ;************************************ V2MULSS: %ifidn __OUTPUT_FORMAT__, win64 %define arg1f XMM2 %define arg2f XMM3 %endif _enter_ _V2MATH_SCALAR_ROUTINE mulps _leave_ ret %ifidn __OUTPUT_FORMAT__, win64 args_reset %endif global V2DIVSS; ;************************************ ; V2 Result = (A.x / FLOAT , A.y / FLOAT) ;************************************ V2DIVSS: %ifidn __OUTPUT_FORMAT__, win64 %define arg1f XMM2 %define arg2f XMM3 %endif _enter_ _V2MATH_SCALAR_ROUTINE divps _leave_ ret %ifidn __OUTPUT_FORMAT__, win64 args_reset %endif global V2MADSS ;void V2MADSS(void * Result, void * A, void * B, float C) ;************************************ ;V2 Result = (A + (B*C)) ;************************************ V2MADSS: %ifidn __OUTPUT_FORMAT__, win64 %define arg1f XMM3 %endif _enter_ movsd xmm5,[arg3] pshufd arg1f,arg1f,0 movsd xmm4,[arg2] mulps xmm5,arg1f addps xmm4,xmm5 movsd [arg1],xmm4 %ifidn __OUTPUT_FORMAT__, win64 args_reset %endif _leave_ ret global V2INV; void V2INV(void * Result, void * Operand) ;************************************* ;V2 Result = -Operand ;************************************ V2INV: _enter_ movsd xmm1,[arg2] pcmpeqw xmm0,xmm0 pslld xmm0,31 pxor xmm1,xmm0 movsd [arg1],xmm1 _leave_ ret ;***VECTOR 2 ALGEBRA***; %macro DotProductXMMV2 4 ;%1 and %2 are registers to proccess ;%3 is the result ;Result stored in the first 32-bits ;%4 is a temporal register movsd %3, %1 mulps %3, %2 movshdup %4,%3 addss %3,%4 %endmacro %macro _V2DOT_ 4 ;%1 is the result ;Result stored in the first 32-bits ;%2 and %3 are registers to proccess ;%4 is a temporal register DotProductXMMV2 %2, %3, %1, %4 %endmacro global V2DOT; float V2DOT(void * A, void * B) V2DOT: _enter_ movlps xmm1,[arg1] pxor xmm0,xmm0 movlps xmm2,[arg2] _V2DOT_ xmm0,xmm1,xmm2,xmm3 _leave_ ret %macro CROSSPRODUCTV2 4 ;*** LEGACY MACRO ***; ;%1 and %2 Registers to operate with ;%3 Register where to store the result ;%4 Temporal register ;v = %1; w = %2 pshufd %4,%2,00000001b movsd %3,%1 mulps %3,%4 movshdup %4, %3 subss %3,%4 %endmacro %macro _V2CROSS_ 4 ;%1 Destiny Operand ;%2 First Operand ;%3 Second Operand ;%4 Temporal Operand ;v = %2; w = %3 CROSSPRODUCTV2 %2,%3,%1,%4 %endmacro global V2CROSS; float V2CROSS(void * A, void * B) V2CROSS: _enter_ movsd xmm2,[arg2] movsd xmm3,[arg3] _V2CROSS_ xmm1,xmm2,xmm3,xmm0 movss xmm0,xmm1 _leave_ ret global V2TRANSPOSE; void V2TRANSPOSE(void * Result, void * Vector) ;*************************************** ;Result = { Vector.Y , Vector.X } ;*************************************** V2TRANSPOSE: _enter_ movsd xmm0,[arg2] pshufd xmm0,xmm0,1 movsd [arg1],xmm0 _leave_ ret %macro _V2NORMALIZE_ 4 ;%1 = Destination Operand ;%2 = Source Operand ;%3 = Temporal Operand (Trasheable) ;%4 = Temporal Operand (Trasheable) movaps %4,%2 movaps %1,%2 mulps %4,%4 movshdup %3,%4 addss %4,%3 sqrtss %4,%4 movsldup %4,%4, divps %1,%4 %endmacro global V2NORMALIZE V2NORMALIZE: _enter_ movlps xmm1,[arg2] _V2NORMALIZE_ xmm0,xmm1,xmm2,xmm3 movsd [arg1],xmm0 _leave_ ret %macro ____V2Lerp____ 4 ;%1 Is the First Operand Vector (A) ;%2 Is the Second Operand Vector (B) ;%3 Is the Factor Operand Vector (t) (Previously pshufd' by itself with 0) ;%4 Is the Destiny Vector (C) ;All operands must be different movsd %4,%2 subps %4,%1 ;B-A mulps %4,%3 ;(B-A)*t addps %4,%1 ;C = A+((B-A)*t) %endmacro %macro _V2LERP_ 4 ;%1 Is the Destiny Vector (C) ;%2 Is the First Operand Vector (A) ;%3 Is the Second Operand Vector (B) ;%4 Is the Factor Operand Vector (t) (Previously pshufd' by itself with 0) ;All operands must be different ____V2Lerp____ %2,%3,%1,%4 %endmacro global V2LERP; void V2LERP(void * Result, void * vec2_A, void * vec2_B, float factor) ;******************************************************** ;Given two 2D vectors and a scalar factor, ;this algorithm does a Linear Interpolation ;The result, a 2D vector, is stored in QR ;******************************************************** V2LERP: %ifidn __OUTPUT_FORMAT__, win64 %define arg1f XMM3 ;The fourth argument is a float, Factor. %define argrf XMM0 ;The result will be stored here. %elifidn __OUTPUT_FORMAT__, elf64 %define argrf XMM3 ;The result will be stored here. %endif _enter_ movsd XMM3,[arg2] pshufd arg1f,arg1f,0 movsd XMM1,[arg3] ____V2Lerp____ XMM3,XMM1,arg1f,argrf movsd [arg1],argrf _leave_ ret %ifidn __OUTPUT_FORMAT__, win64 args_reset %endif %macro _V2NORM_imm 2 ;%1 Destiny/Source Operand (float) ;%2 Temporal Operand (2D vector of floats) mulps %1,%1 movshdup %2,%1 addss %1,%2 sqrtss %1,%1 %endmacro global V2NORM; float V2NORM(void * A) ;************************************************************ ;Given a 2D vector, this algorithm returns its length (norm). ;************************************************************ V2NORM: _enter_ movsd xmm0,[arg1] _V2NORM_imm xmm0,xmm1 _leave_ ret global V2DISTANCE; float V2DISTANCE(void * A, void * B) ;************************************************************ ;Given two 2D points, this algorithm returns the distance. ;************************************************************ V2DISTANCE: _enter_ movsd xmm1,[arg1] movsd xmm0,[arg2] subps xmm0,xmm1 _V2NORM_imm xmm0,xmm1 _leave_ ret global V2ANGLE; (RADIANS) float V2ANGLE(void * Vector) ;****************************************************************** ;Given a 2D Vector, this algorithm returns its angle (in radians). ;****************************************************************** V2ANGLE: _enter_ sub rsp, 8 fld dword [arg1+4] fld dword [arg1] fpatan ;fchs fstp dword [rsp] movss xmm0, [rsp] add rsp, 8 _leave_ ret global V2V2ANGLE; (RADIANS) float V2V2ANGLE(void * A, void * B) ;****************************************************************** ;Given a line segment formed by the two 2D points A and B. ;This algorimth calculates the angle of the line segment. ;****************************************************************** V2V2ANGLE: _enter_ sub rsp, 8 fld dword[arg1+4];A.y fld dword[arg2+4];B.y fsubp fld dword[arg1];A.x fld dword[arg2];B.x fsubp fpatan ;fchs fstp dword[rsp] movss xmm0, [rsp] add rsp, 8 _leave_ ret global ANGLEROTV2; (RADIANS) void ANGLEROTV2(void * Destiny, void * Source, float Radians) ;****************************************************************** ;Given a 2D vector (Source) and an angle in Radians, ;this algorithm transforms the 2D vector by the angle. ;The result is stored in Destiny. ;****************************************************************** %ifidn __OUTPUT_FORMAT__, win64 %define arg1f XMM2 %define arg2f xmm0 %define arg3f xmm1 %define arg4f xmm3 %endif ANGLEROTV2: _enter_ sub rsp,8 movss [rsp],arg1f pxor xmm4,xmm4 pxor arg4f,arg4f fld dword [rsp] pxor xmm5,xmm5 pcmpeqd xmm4,xmm4 ;xmm4[0] = [11111111111111111111111111111111] fld st0 fcos fstp dword [rsp] psllq xmm4,31 ;xmm4[0] = [10000000000000000000000000000000] fsin fstp dword [rsp+4] movss xmm5,xmm4 movsd arg1f,[rsp] ;arg1f [][][sin][cos] pshufd arg2f,arg1f,11_10_00_01b ;arg2f [][][cos][sin] movsd arg3f,[arg2] movsldup xmm4,arg3f ;xmm4 [][][x][x] movshdup arg4f,arg3f ;arg4f [][][y][y] pxor arg4f,xmm5 ;arg4f [][][y][-y] ;xmm4 [][] [x][x] ;arg1f [][][sin][cos] ;arg4f [][][y][-y] ;arg2f [][][cos][sin] mulps arg1f,xmm4 mulps arg2f,arg4f addps arg1f,arg2f movsd [arg1],arg1f add rsp,8 _leave_ ret %ifidn __OUTPUT_FORMAT__, win64 args_reset %endif ;***VECTOR 3 MATH***; ;(It is slow as it consist of Scalar and VECTOR 2 Math) %macro _V3MATH_ARITHMETIC_ROUTINE 1 ;%1 = operation _loadvec3_ xmm0,arg2,xmm2 _loadvec3_ xmm1,arg3,xmm2 %1 xmm0,xmm1 _storevec3_ arg1,xmm0,xmm2 %endmacro %macro _loadvec3_ 3 ;%1 = Destiny Operand ;%2 = Source Memory ;%3 = temporal Operand (Trasheable) movlps %1,[%2] movss %3,[%2+8] movlhps %1,%3 %endmacro %define _LOADVEC3_ _loadvec3_ %macro _storevec3_ 3 ;%1 = Destiny Memory ;%2 = Source Operand ;%3 = temporal Operand (Trasheable) movhlps %3,%2 movsd [%1],%2 movss [%1+8],%3 %endmacro %define _STOREVEC3_ _storevec3_ %macro _V3MATH_SCALAR_ROUTINE 1 ;%1 = operation _loadvec3_ arg2f,arg2,arg3f shufps arg1f,arg1f,0 %1 arg2f,arg1f _storevec3_ arg1,arg2f,arg3f %endmacro global V3ADD; void V3ADD(, void * Result, void * A, void * B) ;************************************ ; V3 Result = (A.x + B.x , X.y + B.y, A.z + B.z) ;************************************ V3ADD: _enter_ _V3MATH_ARITHMETIC_ROUTINE addps _leave_ ret global V3SUB; void V3SUB(void * Result,void * A, void * B) ;************************************ ; V3 Result = (A.x - B.x , X.y - B.y, A.z - B.z) ;************************************ V3SUB: _enter_ _V3MATH_ARITHMETIC_ROUTINE subps _leave_ ret global V3MUL; void V3MUL(void * Result, void * A, void * B) ;************************************ ; V4 Result = (A.x * B.x , X.y * B.y, A.z * B.z) ;************************************ V3MUL: _enter_ _V3MATH_ARITHMETIC_ROUTINE mulps _leave_ ret global V3DIV; void V3DIV(void * Result, void * A, void * B) ;************************************ ; V3 Result = (A.x / B.x , X.y / B.y, A.z / B.z) ;************************************ V3DIV: _enter_ _V3MATH_ARITHMETIC_ROUTINE divps _leave_ ret global V3MULSS; void V3MULSS (void * result, void * Vector, float FLOAT ) ;************************************ ; V3 Result = (A.x * FLOAT , X.y * FLOAT, A.z * FLOAT) ;************************************ %ifidn __OUTPUT_FORMAT__, win64 %define arg1f XMM2 %define arg2f XMM3 %define arg3f XMM4 %endif V3MULSS: _enter_ _V3MATH_SCALAR_ROUTINE mulps _leave_ ret %ifidn __OUTPUT_FORMAT__, win64 args_reset %endif global V3DIVSS; void V3DIVSS (void * result, void * Vector, float FLOAT) ;************************************ ; V2 Result = (A.x / FLOAT , X.y / FLOAT, A.z / FLOAT) ;************************************ %ifidn __OUTPUT_FORMAT__, win64 %define arg1f XMM2 %define arg2f XMM3 %define arg3f XMM4 %endif V3DIVSS: _enter_ _V3MATH_SCALAR_ROUTINE divps _leave_ ret %ifidn __OUTPUT_FORMAT__, win64 args_reset %endif global V3MADSS ;void V3MADSS(void * Result, void * A, void * B, float C) ;************************************ ;V2 Resul = (A + (B*C)) ;************************************ V3MADSS: %ifidn __OUTPUT_FORMAT__, win64 %define arg1f XMM3 %define arg4f XMM0 %endif _enter_ _loadvec3_ xmm5,arg3,arg4f pshufd arg1f,arg1f,0 _loadvec3_ xmm4,arg2,arg4f mulps xmm5,arg1f addps xmm4,xmm5 _storevec3_ arg1,xmm4,arg4f %ifidn __OUTPUT_FORMAT__, win64 args_reset %endif _leave_ ret %macro DotProductXMMV3 4 ;**LEGACY MACRO** ;%1 and %2 are registers to proccess ;%3 is the result ;Result stored in the first 32-bits ;%4 is a temporal register movaps %3, %1 ;%3[?][z1][y1][z1] mulps %3, %2 ;%3[?][z1*z2][y1*y2][x1*x2] movshdup %4,%3 ;%4[?][?] [y1*y2][y1*y2] addps %4,%3 ;%4[?][?] [?] [(x1*x2)+(y1*y2)] movhlps %3,%3 ;%3[?][z1*z2][?] [z1*z2] addss %3,%4 ;%3[?][?] [?] [(x1*x2)+(y1*y2)+(z1*z2)] %endmacro %macro _V3DOT_ 4 ;%1 is the result Operand, the result stored in the first 32-bits ;%2 and %3 are registers to proccess ;%4 is a temporal register DotProductXMMV3 %2,%3,%1,%4 %endmacro global V3DOT; float V3DOT(void * A, void * B) V3DOT: _enter_ _loadvec3_ xmm1,arg1,xmm3 _loadvec3_ xmm2,arg2,xmm3 _V3DOT_ xmm0,xmm1,xmm2,xmm3 _leave_ ret %macro NORMALIZEVEC3MACRO 4 ;%1 Register with the vector about to normalize ;%2, %3 y %4 temporal registers movaps %3,%1 ;%3 [][z][y][x] mulps %3,%1 ;%3 [][z*z][y*y][x*x] movhlps %2,%3 ;%2 [][][][z*z] pshufd %4,%3,1 ;%4 [][][][y*y] addss %3,%4 addss %3,%2 ;%3 [][][][(x*x)+(y*y)+(z*z)] sqrtss %3,%3 ;%3 [][][][sqrt((x*x)+(y*y)+(z*z))] pshufd %3,%3,0 divps %1,%3 %endmacro %define _V3NORMALIZE_imm NORMALIZEVEC3MACRO global V3NORMALIZE; void V3NORMALIZE(void * Result, void * A) V3NORMALIZE: _enter_ _loadvec3_ xmm0,arg2,xmm3 _V3NORMALIZE_imm xmm0,xmm1,xmm2,xmm3 _storevec3_ arg1,xmm0,xmm3 _leave_ ret %macro CROSSPRODUCTMACRO 6 ;**LEGACY MACROS** ;%1 First register to use ;%2 Second register to use ;%3 Register to store result ;%4, %5, %6 temporal registers movups %3,%1 ;%3 [?][Az][Ay][Ax] movups %4,%2 ;%4 [?][Bz][By][Bx] pshufd %5,%3,11010010b pshufd %6,%4,11001001b pshufd %3,%3,11001001b pshufd %4,%4,11010010b ;%3 [?][Ax][Az][Ay] ;%4 [?][By][Bx][Bz] ;%5 [?][Ay][Ax][Az] ;%6 [?][Bx][Bz][By] mulps %3,%4 mulps %5,%6 subps %3,%5 ;%3 [?][Rz][Ry][Rx] %endmacro %macro _V3CROSS_ 5 ;%1 = Destiny Operand ;%2 = First Operand (A) ;%3 = Second Operand (B) ;%4 = Temporal Operand (Trasheable) ;%5 = Temporal Operand (Trasheable) pshufd %5,%2,11010010b ;%5 [?][Ay][Ax][Az] pshufd %4,%3,11001001b ;%4 [?][Bx][Bz][By] mulps %5,%4 pshufd %1,%2,11001001b ;%1 [?][Ax][Az][Ay] pshufd %4,%3,11010010b ;%4 [?][By][Bx][Bz] mulps %1,%4 subps %1,%5 ;%1 [?][Rz][Ry][Rx] %endmacro global V3CROSS; void V3CROSS (void * Result, void * A, void * B) ;***************************** ; V3 result = A x B ;***************************** V3CROSS: _enter_ _loadvec3_ xmm0,arg2,xmm3 _loadvec3_ xmm1,arg3,xmm3 _V3CROSS_ xmm3,xmm0,xmm1,xmm2,xmm4 _storevec3_ arg1,xmm3,xmm2 _leave_ ret global V3LERP; void V3LERP(void * Result, void * vec3_A, void * vec3_B, float factor) ;******************************************************** ;Given two 3D vectors and a scalar factor, ;this algorithm does a Linear Interpolation ;The result, a 3D vector, is stored in Result ;******************************************************** V3LERP: %ifidn __OUTPUT_FORMAT__, win64 %define arg1f XMM3 ;The fourth argument is a float, Factor. %define argrf XMM0 ;The result will be stored here. %elifidn __OUTPUT_FORMAT__, elf64 %define argrf XMM3 ;The result will be stored here. %endif _enter_ _loadvec3_ xmm1,arg2,xmm4 _loadvec3_ xmm2,arg3,xmm4 pshufd arg1f,arg1f,0 _V4Lerp_ XMM1,XMM2,arg1f,argrf _storevec3_ arg1,argrf,xmm4 _leave_ ret %ifidn __OUTPUT_FORMAT__, win64 args_reset %endif %macro _V3NORM_ 3 ;%1 Destiny Operand (float) ;%2 Source Operand ;%3 Temporal Operand _V4NORM_ %1,%2,%3 %endmacro global V3NORM; float V3NORM(void * Vector) V3NORM: _enter_ _loadvec3_ xmm1,arg1,xmm2 pxor xmm0,xmm0 _V3NORM_ xmm0,xmm1,xmm2 _leave_ ret %macro _V3DISTANCE_ 4 ;%1 Destiny Operand (float) ;%2 First Operand ;%3 Second Operand ;%4 Temporal Operand _V4DISTANCE_ %1,%2,%3,%4 %endmacro global V3DISTANCE V3DISTANCE: _enter_ _loadvec3_ xmm1,arg1,xmm3 pxor xmm0,xmm0 _loadvec3_ xmm2,arg2,xmm3 _V3DISTANCE_ xmm0,xmm1,xmm2,xmm3 _leave_ ret global V3INV; void V3INV(void * Result, void * Operand) ;************************************* ;V3 Result = -Operand ;************************************ V3INV: _enter_ _loadvec3_ xmm1,arg2,xmm2 pcmpeqw xmm0,xmm0 pslld xmm0,31 pxor xmm1,xmm0 _storevec3_ arg1,xmm1,xmm2 _leave_ ret args_reset global SSMAD; float SSMAD(float A,float B, float C); ;*********************** ; It returns A + (B*C) ;*********************** SSMAD: _enter_ mulss arg2f,arg3f addss arg1f,arg2f _leave_ ret %macro _SSLERP_ 4 ;%1 Is the Destiny ;%2 Is the First float ;%3 Is the Second float ;%4 Is the Factor float movss %1,%3 subss %1,%2 ;B-A mulss %1,%4 ;(B-A)*t addss %1,%2 ;C = A+((B-A)*t) %endmacro global SSLERP; float SSLERP(float A, float B,float Factor) ;****************************************************************************** ;Given two single precision floats (both scalars, A and B) and a scalar factor, ;this algorithm does a Linear Interpolation ;The result is stored in Result ;****************************************************************************** SSLERP: _enter_ _SSLERP_ arg4f,arg1f,arg2f,arg3f movss arg1f,arg4f _leave_ ret global SDMAD; float SDMAD(float A,float B, float C); ;*********************** ; It returns A + (B*C) ;*********************** SDMAD: _enter_ mulsd arg2f,arg3f addsd arg1f,arg2f _leave_ ret %macro _SDLERP_ 4 ;%1 Is the Destiny ;%2 Is the First double ;%3 Is the Second double ;%4 Is the Factor double movsd %1,%3 subsd %1,%2 ;B-A mulsd %1,%4 ;(B-A)*t addsd %1,%2 ;C = A+((B-A)*t) %endmacro global SDLERP; double SDLERP(double A, double B,double Factor) ;************************************************************************************* ;Given two double precision doubles (both scalars, A and B) and a double scalar factor, ;this algorithm does a Linear Interpolation ;The result is stored in Result ;************************************************************************************* SDLERP: _enter_ _SDLERP_ arg4f,arg1f,arg2f,arg3f movsd arg1f,arg4f _leave_ ret %macro _ANGCONV_imm 4 ;%1 Source and Destiny Operand ;%2 Conversion multiplier ;%3 Temporal Operand ;%4 Temporal Operand (Integer register) _loadimm32_ %3,%2,%4 mulss %1,%3 %endmacro %macro _RADTODEG_imm 3 ;%1 Source and Destiny Operand ;%2 Temporal Operand ;%3 Temporal Operand (Integer register) _ANGCONV_imm %1,fc_180fdivPI,%2,%3 %endmacro global RADTODEG; float RADTODEG(float Radian) ;*************************************************************** ;Given a measure in radians, this algorithm returns the degrees ;*************************************************************** RADTODEG: _enter_ _RADTODEG_imm xmm0,xmm1,eax _leave_ ret %macro _DEGTORAD_imm 3 ;%1 Source and Destiny Operand ;%2 Temporal Operand ;%3 Temporal Operand (Integer register) _ANGCONV_imm %1,fc_PIdiv180f,%2,%3 %endmacro global DEGTORAD; float DEGTORAD(float Degrees) ;*************************************************************** ;Given a measure in degrees, this algorithm returns the radians ;*************************************************************** DEGTORAD: _enter_ _DEGTORAD_imm xmm0,xmm1,eax _leave_ ret ;/** QUATERNION MATH **/ %macro _QUATMUL_ 8 ;%1 Destiny Operand (C) ;%2 First Source Operand (A) ;%3 Second Source Operand (B) ;%4 Temporal Operand ;%5 Temporal Operand ;%6 Temporal Operand ;%7 Temporal Operand ;%8 Temporal Operand (Integer Register) ;All Operands must be different pshufd %1,%2,0 ;%1 = [Ax][Ax][Ax][Ax] pxor %4,%4 _loadimm32_ %4, SignChange32bits,%8 ;%4 = [][][][SC] pshufd %5,%3,00_01_10_11b ;%5 = [Bx][By][Bz][Bw] pshufd %6,%3,01_00_11_10b ;%6 = [By][Bx][Bw][Bz] pshufd %7,%2,01_01_01_01b ;%7 = [Ay][Ay][Ay][Ay] pshufd %4,%4, 00_11_00_11b ;%4 = [SC][][SC][] mulps %1,%5 ;%1 = [Ax*Bx][Ax*By][Ax*Bz][Ax*Bw] mulps %7,%6 ;%7 = [Ay*By][Ay*Bx][Ay*Bw][Ay*Bz] pxor %1,%4 ;%1 = [-Ax*Bx][Ax*By][-Ax*Bz][Ax*Bw] pshufd %5,%3,10_11_00_01b ;%5 = [Bz][Bw][Bx][By] pshufd %6,%2,10_10_10_10b ;%6 = [Az][Az][Az][Az] pshufd %4,%4, 11_11_00_00b ;%4 = [SC][SC][][] mulps %5,%6 ;%5 = [Az*Bz][Az*Bw][Az*Bx][Az*By] pxor %7,%4 ;%7 = [-Ay*By][-Ay*Bx][Ay*Bw][Ay*Bz] pshufd %6,%2,11_11_11_11b ;%6 = [Aw][Aw][Aw][Aw] pshufd %4,%4,11_00_01_11b ;%4 = [SC][][][SC] addps %1,%7 ;%1 = [-(Ax*Bx)-(Ay*By)][(Ax*By)-(Ay*Bx)][-(Ax*Bz)+(Ay*Bw)][(Ax*Bw)+(Ay*Bz)] pxor %5,%4 ;%5 = [-(Az*Bz)][(Az*Bw)][(Az*Bx)][-(Az*By)] mulps %6,%3 ;%6 = [Aw*Bw][Aw*Bz][Aw*By][Aw*Bx] addps %1,%5 ;%1 = [-(Ax*Bx)-(Ay*By)-(Az*Bz)] ; [(Ax*By)-(Ay*Bx)+(Az*Bw)] ; [-(Ax*Bz)+(Ay*Bw)+(Az*Bx)] ; [(Ax*Bw)+(Ay*Bz)-(Az*By)] addps %1,%6 ;%1 = [-(Ax*Bx)-(Ay*By)-(Az*Bz)+(Aw*Bw)] qw ; [(Ax*By)-(Ay*Bx)+(Az*Bw)+(Aw*Bz)] qk ; [-(Ax*Bz)+(Ay*Bw)+(Az*Bx)+(Aw*By)] qj ; [(Ax*Bw)+(Ay*Bz)-(Az*By)+(Aw*Bx)] qi %endmacro global QUATMUL; void QUATMUL (float * Result, float * A, float * B); ;********************************** ; Given A and B (both Quaternions), ; Quaternion Result = A * B; ;********************************** QUATMUL: _enter_ %ifidn __OUTPUT_FORMAT__, win64 sub rsp,16; movups [rsp], xmm6 ;movups [rsp+(16)], xmm7 %endif movups xmm1,[arg2] ;<- Quaternion A movups xmm2,[arg3] ;<- Quaternion B _QUATMUL_ xmm0,xmm1,xmm2,xmm3,xmm4,xmm5,xmm6,eax ;movntps [arg1],xmm0 movups [arg1],xmm0 %ifidn __OUTPUT_FORMAT__, win64 movups xmm6, [rsp] ;movups xmm7, [rsp+(16)] add rsp,16; args_reset %endif _leave_ ret global QUATROTV3; void QUATROTV3(void * Result, void * V3, void * Quaternion ) ;******************************************************************** ;Given a Quaternion and a 3D Vector, ;this algoritm rotates the 3D vector around origin by the quaternion ;******************************************************************** QUATROTV3: _enter_ %ifidn __OUTPUT_FORMAT__, win64 sub rsp,16*2; movups [rsp], xmm6 movups [rsp+(16)], xmm7 %endif movups xmm0, [arg2] ;<- xmm0 stores the imaginary part of the Quaternion movss xmm1,[arg2+4+4+4] ;<- xmm1 stores the real part of the Quaternion movsd xmm2,[arg3] movss xmm3,[arg3+4+4] movlhps xmm2,xmm3 ;<- xmm2 stores the 3D vector DotProductXMMV3 xmm0,xmm2,xmm3,xmm4; <-xmm3 stores xmm0 . xmm2 addss xmm3,xmm3 ;<- xmm3 * 2.f movaps xmm6,xmm0 DotProductXMMV3 xmm0,xmm6,xmm5,xmm4; <-xmm5 stores xmm0 . xmm0 movss xmm4,xmm1 mulss xmm4,xmm4 subss xmm4,xmm5 ;<- (xmm1*xmm1) - xmm5 pshufd xmm3,xmm3,0 mulps xmm3,xmm0 pshufd xmm4,xmm4,0 mulps xmm4,xmm2 addps xmm4,xmm3 CROSSPRODUCTMACRO xmm0,xmm2,xmm3,xmm5,xmm6,xmm7 ;<- xmm3 stores xmm0 x xmm2 addss xmm1,xmm1 ;<- xmm1 * 2 pshufd xmm1,xmm1,0 mulps xmm1,xmm3 addps xmm4,xmm1 movhlps xmm1,xmm4 movsd [arg1],xmm4 movss [arg1+4+4],xmm1 %ifidn __OUTPUT_FORMAT__, win64 movups xmm6, [rsp] movups xmm7, [rsp+(16)] add rsp,16*2; args_reset %endif _leave_ ret global QUATTOM4; void QUATTOM4(void * Matrix, void * Quaternion) ;******************************************** ;Given a Quaternion, this function generates a 4x4 Matrix. ;This algorithm is an implementation of a method by <NAME> (2008) ;Source: https://sourceforge.net/p/mjbworld/discussion/122133/thread/c59339da/ ;******************************************** QUATTOM4: _enter_ %ifidn __OUTPUT_FORMAT__, win64 sub rsp,16*2 movups [rsp],xmm6 movups [rsp+16],xmm7 %define arg1 rdx %define arg2 rcx %elifidn __OUTPUT_FORMAT__, elf64 %define arg1 rsi %define arg2 rdi %endif _loadimm32_ xmm7,SignChange32bits,eax ;xmm7 [0][0][0][0x800000] movaps xmm6,xmm7 ;xmm6 [0][0][0][0x800000] pshufd xmm5,xmm7,01_00_01_01b ;xmm5 [0][0x800000][0][0] pshufd xmm4,xmm7,01_01_00_01b ;xmm4 [0][0][0x800000][0] sub rsp,16 pshufd arg1f,xmm7,00_11_11_11b movups arg4f,[arg1] movups arg2f,arg4f ;xmm3 [w][z][y][x] movups [rsp],arg4f pshufd xmm7,xmm7,11000000b ;xmm7 [0][0x800000][0x800000][0x800000] mov arg3,rsp ;rsp=x ;rsp+4=y ;rsp+8=z ;rsp+12=w movups arg4f,arg2f ;xmm3 [w][z][y][x] fld dword[arg3] add arg3,4 fld dword[arg3] pxor xmm7,arg4f ;xmm7 [w][-z][-y][-x] add arg3,4 fld dword[arg3] add arg3,4 fld dword[arg3] ;Stack: ST0= -w; ST1=z; ST2=y; ST3=x ;xmm3= [w][z][y][x] ;xmm7= [w][-z][-y][-x] movups [arg2+16+16+16],xmm3 pshufd xmm0,xmm3,00011011b pxor xmm0,xmm5 ;xmm0 = [x][-y][z][w] pshufd xmm1,xmm3,01001110b pxor xmm1,xmm6 ;xmm1 = [y][x][w][-z] mov eax,fc_1f pshufd xmm2,xmm3,10110001b pxor xmm2,xmm4 ;xmm2 = [z][w][-x][y] movaps xmm3,xmm7 ;xmm3 = [w][-z][-y][-x] movups [arg2],xmm0 movups [arg2+16],xmm1 movups [arg2+16+16],xmm2 movups [arg2+16+16+16],xmm3 fstp dword [arg2+16+16+16+12] fchs fstp dword [arg2+16+16+16+12-16] fchs fstp dword [arg2+16+16+16+12-16-16] fchs fstp dword [arg2+16+16+16+12-16-16-16] TRANS44 mov arg1,arg2 xor arg3,arg3 mov arg4,arg2 Mmullabelqua: MULVEC4VEC4 arg1,arg4,arg3 add arg3,16 cmp arg3,64 jne Mmullabelqua pxor xmm3,xmm3 movups [arg2+16+16+16],xmm3 mov [arg2+16+16+16+12],eax add rsp,16 %ifidn __OUTPUT_FORMAT__, win64 movups xmm6,[rsp] movups xmm7,[rsp+16] add rsp,16*2 %endif _leave_ ret args_reset global EULERTOQUAT; void EULERTOQUAT( void * Quaternion,void * Axis, float Degree) ;********************************************************************* ;Given a 3D Vector describing an Axis and a angle given in Radians, ;This function calculates the respective quaternion. ;********************************************************************* %ifidn __OUTPUT_FORMAT__, win64 %define arg1f XMM2 %endif EULERTOQUAT: _enter_ sub rsp,8 movss [rsp],arg1f fld dword [rsp] fld1 add rsp,8 fld1 faddp fdivp fld st0 movups arg1f,[arg2] fcos fxch fsin fstp dword[arg1] movss XMM3,[arg1] pshufd XMM3,XMM3,0h mulps arg1f,XMM3 movups [arg1],arg1f fstp dword[arg1+4+4+4] _leave_ ret %ifidn __OUTPUT_FORMAT__, win64 args_reset %endif %macro _UQUATINV_ 3 ;%1 Destiny Operand ;%2 Source Operand ;%3 Temporal Operand _loadsignbit32_ %3 ;xmm1 [sb][sb][sb][sb] movaps %1,%2 pslldq %3,4 ;xmm1 [sb][sb][sb][0] pxor %1,%2 %endmacro global UQUATINV; void UQUATINV(void * Result, void * Unit_Quaternion); ;********************************************************************* ;Given an unit Quaternion, this algoritm return its inverse. ;********************************************************************* UQUATINV: _enter_ _loadsignbit32_ xmm0 ;xmm0 [sb][sb][sb][sb] movups xmm1,[arg2] psrldq xmm0,4 ;xmm0 [0][sb][sb][sb] pxor xmm1,xmm0 movups [arg1],xmm1 _leave_ ret global UQUATNLERP; void UQUATNLERP(void * Result, void * UQuaternionA,void * UQuaternionB,float Factor) ;*************************************************************************************** ;Given two quaternions, this algorithm returns the Normalized Linear Interpolation by a ;given factor. ;*************************************************************************************** UQUATNLERP: _enter_ %ifidn __OUTPUT_FORMAT__, win64 movaps xmm0,xmm3 %endif movups xmm4,[arg2] pshufd xmm0,xmm0,0 movups xmm5,[arg3] _V4Lerp_ xmm1,xmm4,xmm5,xmm0 _V4NORMALIZE_ xmm2,xmm1,xmm3,xmm4 movups [arg1],xmm2 _leave_ ret global UQUATSLERP; void UQUATSLERP(void * Result, void * A, void * B, float Factor) ;*************************************************************************************** ;Given two quaternions, this algorithm returns the Spherical Linear Interpolation by a ;given factor. ;*************************************************************************************** UQUATSLERP: %ifidn __OUTPUT_FORMAT__, win64 movaps xmm0,xmm3 %endif _enter_ movups xmm4,[arg2] pshufd xmm0,xmm0,0 movups xmm5,[arg3] _leave_ ret global UQUATDIFF; void UQUATDIFF(void * Result, void * A, void * B); ;********************************************************************* ; Given Two Unit Quaternions A and B, ; This algorithm returns the rotational difference. ;********************************************************************* UQUATDIFF: _enter_ %ifidn __OUTPUT_FORMAT__, win64 sub rsp,16; movups [rsp], xmm6 %endif movups xmm2,[arg3] _loadsignbit32_ xmm1 ;xmm1 [sb][sb][sb][sb] movups xmm0,[arg2] psrldq xmm1,4 ;xmm1 [0][sb][sb][sb] pxor xmm1,xmm0 ;xmm1 = -A; ;-- Calculate B * -A _QUATMUL_ xmm0,xmm2,xmm1,xmm3,xmm4,xmm5,xmm6,eax ;xmm0 = B * -A = A - B movntps [arg1],xmm0 %ifidn __OUTPUT_FORMAT__, win64 movups xmm6, [rsp] add rsp,16; args_reset %endif _leave_ ret ;** 2x2 MATRIX MATH **; global M2MAKE; void M2MAKE(void * Destiny, float Scale) M2MAKE: _enter_ %ifidn __OUTPUT_FORMAT__, win64 movaps arg1f,arg2f %endif pshufd arg1f,arg1f,00_11_11_00b movups [arg1],arg1f _leave_ ret %ifidn __OUTPUT_FORMAT__, win64 args_reset %endif global ANGLETOM2; void ANGLETOM2(void * Destiny, float Radians); ANGLETOM2: _enter_ %ifidn __OUTPUT_FORMAT__, win64 movaps arg1f,arg2f %endif sub rsp,8 movss [rsp],arg1f fld dword [rsp] fld st0 fcos fst dword [arg1] fstp dword [arg1+4+4+4] fsin fst dword [arg1+4] fchs fstp dword [arg1+8] add rsp,8 _leave_ ret %ifidn __OUTPUT_FORMAT__, win64 args_reset %endif %macro _M2MUL_ 5 ; %1 Destiny ; %2 First Operand ; %3 Second Operand ; %4 Temporal Operand ; %5 Temporal Operand ; All operands must be different movups %1,%2 movlhps %1,%2 movsldup %4,%3 mulps %1,%4 movups %5,%2 movhlps %5,%2 movshdup %4,%3 mulps %4,%5 addps %1,%4 %endmacro global M2MUL; void M2MUL(void * Destiny, void * A, void * B); M2MUL: _enter_ movups xmm2,[arg2] movups xmm3,[arg3] _M2MUL_ xmm1,xmm2,xmm3,xmm4,xmm5 movups [arg1],xmm1 _leave_ ret %macro _M2MULV2_ 4 ;%1 Destiny ;%2 Matrix Operand ;%3 Vector Operand ;%4 Temporal Operand pshufd %4,%3,01_01_00_00b mulps %4,%2 movhlps %1,%4 addps %1,%4 %endmacro global M2MULV2; void M2MULV2(void * V2_Destiny, void * Matrix, void * Vector); M2MULV2: _enter_ movups xmm1,[arg2] movsd xmm2,[arg3] _M2MULV2_ xmm0,xmm1,xmm2,xmm3 movsd [arg1],xmm0 _leave_ ret %macro _M2DET_ 3 ; %1 Destiny ; %2 Operand ; %3 Temporal Operand ; All operands must be different pshufd %1,%2, 00_00_10_00b pshufd %3,%2, 00_00_01_11b mulps %1,%3 movshdup %3,%1 subss %1,%3 %endmacro global M2DET; float M2DET(void * Matrix); M2DET: _enter_ movups xmm1,[arg1] _M2DET_ xmm0,xmm1,xmm2 _leave_ ret %macro _M2INV_ 3 ;%1 Destiny Operand ;%2 Source Operand ;%3 Temporal Operand pcmpeqw %3,%3 pslld %3,31 ;%3 = [SB][SB][SB][SB] pslldq %3,8 psrldq %3,4 ;%3 = [0][SB][SB][0] pshufd %1,%2,00_10_01_11b pxor %1,%3 %endmacro global M2INV; void M2INV(void * Destiny, void * Matrix) ;************************************************************ ;Given a 2x2 Matrix, this algorithm will compute its inverse, ;The Inverse will be stored in Destiny. ;************************************************************ M2INV: _enter_ _M2INV_ xmm0,[arg2],xmm2 movntps [arg1],xmm0 _leave_ ret global M2TRANSPOSE; void M2TRANSPOSE(void * Destiny, void * Origin) M2TRANSPOSE: _enter_ movups xmm0,[arg2] pshufd xmm0,xmm0, 11011000b movups [arg1],xmm0 _leave_ ret %if 0 ;** 4x4 MATRIX MATH **; global M4LERP; M4LERP(float * Result, float * MatrixA, float * MatrixB, float Factor) ;*************************************************************** ;Given two 4x4 Matrices A and B and a scalar factor, ;This function will return a linear interpolation between them ;*************************************************************** M4LERP: %ifidn __OUTPUT_FORMAT__, win64 %define arg1f XMM3 ;The fourth argument is a float, Factor. %define argrf XMM0 ;The result will be stored here. %elifidn __OUTPUT_FORMAT__, elf64 %define argrf XMM3 ;The result will be stored here. %endif _enter_ ;XMM4 - XMM7 OUTPUT MATRIX (one at a time) ;XMM1 MATRIX A COLUMNS (one at a time) ;XMM2 MATRIX B COLUMNS (one at a time) ;XMM4 movups XMM1,[arg2] pshufd arg1f,arg1f,0 MOVUPS XMM2,[arg3] add arg2,4*4 _V4Lerp_ XMM1, XMM2,arg1f,XMM4 add arg3,4*4 ;XMM5 movups XMM1,[arg2] movups XMM2,[arg3] add arg2,4*4 ;UPDATING A MATRIX POINTER movups [arg1],XMM4 ;OUTPUTING FIRST COLUMN add arg3,4*4;UPDATING B MATRIX POINTER _V4Lerp_ XMM1, XMM2,arg1f, XMM5 add arg1,4*4;UPDATING DESTINY POINTER ;XMM6 movups XMM1,[arg2] movups XMM2,[arg3] add arg2,4*4 ;UPDATING A MATRIX POINTER movups [arg1],XMM5 ;OUTPUTING SECOND COLUMN add arg3,4*4 ;UPDATING B MATRIX POINTER _V4Lerp_ XMM1, XMM2,arg1f, XMM6 add arg1,4*4 ;UPDATING DESTINY POINTER ;XMM7 movups XMM1,[arg2] movups XMM2,[arg3] add arg2,4*4; UPDATING A MATRIX POINTER movups [arg1],XMM6 ;OUTPUTING THIRD COLUMN add arg3,4*4 ; UPDATING B MATRIX POINTER _V4Lerp_ XMM1, XMM2,arg1f, XMM7 add arg1,4*4 ; UPDATING DESTINY POINTER movups [arg1],XMM7;OUTPUTING FOURTH COLUMN _leave_ ret %ifidn __OUTPUT_FORMAT__, win64 args_reset %endif %endif %macro M4x4MULMACRO 2 ;When used, registers should be 0'd ;**LEGACY MACRO**; DotProductXMM arg4f,%1,xmm8,xmm9 pshufd xmm10,xmm8,0 DotProductXMM arg3f,%1,xmm8,xmm9 movss xmm10,xmm8 DotProductXMM arg2f,%1,xmm8,xmm9 pshufd %2,xmm8,0 DotProductXMM arg1f,%1,xmm8,xmm9 movss %2,xmm8 movlhps %2,xmm10 %endmacro %if 0 global M4MULV4;M4MULV4(float * Result, float * MatrixA, float *VectorB); ;****************************************************** ; Given a 4x4 Matrix MatrixA and a 4D Vector VectorB, ; 4D Vector Result = MatrixA * VectorB; ;****************************************************** M4MULV4: _enter_ %ifidn __OUTPUT_FORMAT__, win64 sub rsp,16*2 movups [rsp],xmm6 movups [rsp+16],xmm7 %define arg1 rdx %define arg2 r8 %define arg3 rcx %elifidn __OUTPUT_FORMAT__, elf64 %define arg1 rsi %define arg2 rdx %define arg3 rdi %endif sub rsp, 16*4 movups [rsp],xmm8 movups [rsp+16],xmm9 movups [rsp+16+16],xmm10 movups [rsp+16+16+16],xmm11 movups arg1f, [arg1] movups arg2f, [arg1+16] movups arg3f, [arg1+32] movups arg4f, [arg1+16+32] TRANS44 movups xmm7,[arg2] movaps arg3f,xmm4 movaps arg4f,xmm5 M4x4MULMACRO xmm7,xmm11 movups [arg3],xmm11 movups xmm8,[rsp] movups xmm9,[rsp+16] movups xmm10,[rsp+16+16] movups xmm11,[rsp+16+16+16] add rsp, 16*4 %ifidn __OUTPUT_FORMAT__, win64 movups xmm6,[rsp] movups xmm7,[rsp+16] add rsp, 16*2 %endif _leave_ ret args_reset %endif %if 0 global M4MUL ;void M4MUL (void * Result, float * A, float *B); ;********************************************** ;Given A and B (both 4x4 Matrices), ;4x4 Matrix Result = A * B; ;********************************************** M4MUL: _enter_ %ifidn __OUTPUT_FORMAT__, win64 sub rsp,16*2 movups [rsp],xmm6 movups [rsp+16],xmm7 %define arg1 rdx %define arg2 r8 %define arg3 rcx %elifidn __OUTPUT_FORMAT__, elf64 %define arg1 rsi %define arg2 rdx %define arg3 rdi %endif sub rsp, 16*8 movups [rsp],xmm8 movups [rsp+16],xmm9 movups [rsp+16+16],xmm10 movups [rsp+16+16+16],xmm11 movups [rsp+16+16+16+16],xmm12 movups [rsp+16+16+16+16+16],xmm13 movups [rsp+16+16+16+16+16+16],xmm14 movups [rsp+16+16+16+16+16+16+16],xmm15 movups arg1f, [arg1] movups arg2f, [arg1+16] movups arg3f, [arg1+32] movups arg4f, [arg1+16+32] TRANS44; Matrix A (rows) in 0,1,4 and 5 movaps arg3f,xmm4 movaps arg4f,xmm5 ;Matriz A (rows) in 0,1,2,3 movups xmm4, [arg2] movups xmm5, [arg2+16] movups xmm6, [arg2+32] movups xmm7, [arg2+16+32] ;Matriz B (Columns) in 4,5,6,7 M4x4MULMACRO xmm4,xmm12 M4x4MULMACRO xmm5,xmm13 M4x4MULMACRO xmm6,xmm14 M4x4MULMACRO xmm7,xmm15 movups [arg3],xmm12 movups [arg3+16],xmm13 movups [arg3+32],xmm14 movups [arg3+16+32],xmm15 movups xmm8,[rsp] movups xmm9,[rsp+16] movups xmm10,[rsp+16+16] movups xmm11,[rsp+16+16+16] movups xmm12,[rsp+16+16+16+16] movups xmm13,[rsp+16+16+16+16+16] movups xmm14,[rsp+16+16+16+16+16+16] movups xmm15,[rsp+16+16+16+16+16+16+16] add rsp, 16*8 %ifidn __OUTPUT_FORMAT__, win64 movups xmm6,[rsp] movups xmm7,[rsp+16] add rsp, 16*2 %endif _leave_ ret %endif args_reset %if 0 global M4MAKE; void M4MAKE(void * Destiny,float Scale) //FIXME ;************************************************************** ;This algorithm fills a matrix buffer with a scaling constant ;Using 1.0 as the constant is equal to the Identity ;************************************************************** M4MAKE: _enter_ %ifidn __OUTPUT_FORMAT__, win64 movaps arg1f,arg2f %endif movups [arg1],arg1f pslldq arg1f,4 add arg1,16 movups [arg1],arg1f pslldq arg1f,4 add arg1,16 movups [arg1],arg1f pslldq arg1f,4 add arg1,16 movups [arg1],arg1f _leave_ ret %ifidn __OUTPUT_FORMAT__, win64 args_reset %endif %endif %macro _M4INVERSE_Submatrices_L_ 3 ; %1 Destiny ; %2 Low Source ; %3 High Source ; All operands must be different movaps %1,%2 movlhps %1,%3 %endmacro %macro _M4INVERSE_Submatrices_H_ 3 ; %1 Destiny ; %2 First Source ; %3 Second Source ; All operands must be different movaps %1,%3 movhlps %1,%2 %endmacro %macro _M4INVERSE_ADJMULM2 5 ; %1 Destiny ; %2 First Operand ; %3 Second Operand ; %4 Temporal Operand ; %5 Temporal Operand ; All operands must be different pshufd %1,%2,00_11_00_11b mulps %1,%3 pshufd %4,%2, 01_10_01_10b pshufd %5,%3, 10_11_00_01b mulps %4,%5 subps %1,%4 %endmacro %macro _M4INVERSE_M2MULADJ 5 ; %1 Destiny ; %2 First Operand ; %3 Second Operand ; %4 Temporal Operand ; %5 Temporal Operand ; All operands must be different pshufd %1,%3,00_00_11_11b mulps %1,%2 pshufd %4,%3,10_10_01_01b pshufd %5,%2,01_00_11_10b mulps %4,%5 subps %1,%4 %endmacro %if 0 global M4INV; void M4INV(void * Result, void * Matrix); ;**************************************************************************************** ; This function returns the inverse of a given 4x4 Matrix (A). ; It is an implementation of <NAME>'s Fast 4x4 Matrix Inverse. ; Source: ; https://lxjk.github.io/2017/09/03/Fast-4x4-Matrix-Inverse-with-SSE-SIMD-Explained.html ;**************************************************************************************** M4INV: _enter_ %ifidn __OUTPUT_FORMAT__, win64 sub rsp,16*2 movups [rsp],xmm6 movups [rsp+16],xmm7 %endif sub rsp,16*6 movups [rsp],xmm8 movups [rsp+16],xmm9 movups [rsp+16+16],xmm10 movups [rsp+16+16+16],xmm15 movups [rsp+16+16+16+16],xmm11 movups [rsp+16+16+16+16+16],xmm12 movups xmm4,[arg2] movups xmm5,[arg2+16] movups xmm6,[arg2+16+16] movups xmm7,[arg2+16+16+16] ;-- Get submatrices --; _M4INVERSE_Submatrices_L_ xmm0,xmm4,xmm5 ;A; <----- _M4INVERSE_Submatrices_L_ xmm1,xmm6,xmm7 ;B; <----- _M4INVERSE_Submatrices_H_ xmm2,xmm4,xmm5 ;C; <----- _M4INVERSE_Submatrices_H_ xmm3,xmm6,xmm7 ;D; <----- ;-- Submatrices OK--; ;-- Get D Determinant _M2DET_ xmm5,xmm3,xmm6 pshufd xmm5,xmm5,0 ; xmm5 = |D| ;-- Get A Determinant --; _M2DET_ xmm15,xmm0,xmm6 pshufd xmm15,xmm15,0 ; xmm15 = |A| ;--Determinants OK; ;-- D#C _M4INVERSE_ADJMULM2 xmm4,xmm3,xmm2,xmm6,xmm7;xmm4 = D#C <----- ;-- OK ;-- Calculate X# = |D|A - B(D#C) movaps xmm6,xmm0 mulps xmm6,xmm5 ;xmm6 = |D|A _M2MUL_ xmm7,xmm1,xmm4,xmm8,xmm9 ;xmm7 = B(D#C) subps xmm6,xmm7 ; xmm6 = X# <----- ;-- X# Ok movaps xmm9,xmm15 ;<- Saving |A| ;-- Start Calculating |M| (@ xmm15[0:31])--; mulss xmm15,xmm5; |M| = |A|*|D| + ... <----- ;-- A#B _M4INVERSE_ADJMULM2 xmm5,xmm0,xmm1,xmm7,xmm8;xmm5 = A#B <----- ;-- Calculate W# = |A|D - C(A#B) movaps xmm7,xmm3 mulps xmm7,xmm9 ;xmm7 = |A|D _M2MUL_ xmm8,xmm2,xmm5,xmm9,xmm10 ;xmm8 = C(A#B) subps xmm7, xmm8 ; xmm7 = W# <----- ; -- W# OK ;-- Get B Determinant _M2DET_ xmm9,xmm1,xmm10 pshufd xmm9,xmm9,0 ; xmm9 = |B| ;-- Get C Determinant _M2DET_ xmm11,xmm2,xmm10 pshufd xmm11,xmm11,0 ; xmm11 = |C| ;--Determinants OK; ;-- Continue Calculating |M| (@ xmm15[0:31])--; movss xmm10,xmm9 mulss xmm10,xmm11 addss xmm15,xmm10; |M| = |A|*|D| + |B|*|C| + ... <----- ;-- Calculate Y# = |B|C - D(A#B)# movaps xmm8,xmm2 mulps xmm8,xmm9 ;xmm8 = |B|C _M4INVERSE_M2MULADJ xmm10,xmm3,xmm5,xmm9,xmm12 ;xmm10 = D(A#B)# subps xmm8,xmm10 ; xmm8 = Y# <----- ;-- Calculate Z# = |C|B - A(D#C)# movaps xmm9,xmm1 mulps xmm9,xmm11 ;xmm9 = |C|B _M4INVERSE_M2MULADJ xmm10,xmm0,xmm4,xmm11,xmm12 ;xmm10 = A(D#C)# subps xmm9,xmm10 ; xmm9 = Z# <----- ;-- Z# OK ;-- Calculate tr((A#B)(D#C)) pshufd xmm10,xmm4,11_01_10_00b mulps xmm10, xmm5 movshdup xmm11,xmm10 addps xmm10,xmm11 movhlps xmm11,xmm10 addss xmm10,xmm11 ; xmm10 = tr((A#B)(D#C)) <----- pcmpeqw xmm4,xmm4 pslld xmm4,25 psrld xmm4,2 ;xmm4 = [1][1][1][1] ;-- Calculate |M| (@ xmm15[0:31])--; subss xmm15,xmm10; |M| = |A|*|D| + |B|*|C| - tr((A#B)(D#C)) <----- pshufd xmm15,xmm15,0 ;xmm15 = [|M|] [|M|] [|M|] [|M|] pcmpeqw xmm5,xmm5 pslld xmm5,31 ;xmm5 = [SB][SB][SB][SB] pslldq xmm5,8 psrldq xmm5,4 ;xmm5 = [0][SB][SB][0] pxor xmm5,xmm4 ;xmm5 = [1][-1][-1][1] divps xmm5,xmm15 ;xmm5 = [1/|M|] [-1/|M|] [-1/|M|] [1/|M|] mulps xmm6,xmm5 mulps xmm7,xmm5 mulps xmm8,xmm5 mulps xmm9,xmm5 ;xmm6 (X) ;xmm8 (Y) ;xmm9 (Z) ;xmm7 (W) ;-- Submatrices needs to be adjugated-- ;-- Submatrices are already partially adjugated-- ;Final matrix is: ; X# Y# ; Z# W# ;Each Submatrix is Collum Mayor: ; +X0 -X2 ; -X1 +X3 ;-- Adjugating submatrices and ordering final matrix ;First Collumn (most left one) movaps xmm0,xmm6 shufps xmm0,xmm9,01_11_01_11b ;Second Collumn movaps xmm1,xmm6 shufps xmm1,xmm9,00_10_00_10b ;Third Collumn movaps xmm2,xmm8 shufps xmm2,xmm7,01_11_01_11b ;Fourth Collumn (most right one) movaps xmm3,xmm8 shufps xmm3,xmm7,00_10_00_10b ;-- Storing final matrix %if 1 movntps [arg1],XMM0 movntps [arg1+16],XMM1 movntps [arg1+16+16],XMM2 movntps [arg1+16+16+16],XMM3 %endif movups xmm8,[rsp] movups xmm9,[rsp+16] movups xmm10,[rsp+16+16] movups xmm15,[rsp+16+16+16] movups xmm11,[rsp+16+16+16+16] movups xmm12,[rsp+16+16+16+16+16] add rsp,16*6 %ifidn __OUTPUT_FORMAT__, win64 movups xmm6,[rsp] movups xmm7,[rsp+16] add rsp,16*2 args_reset %endif _leave_ ret %endif %unmacro _M4INVERSE_M2MULADJ 5 %unmacro _M4INVERSE_ADJMULM2 5 %unmacro _M4INVERSE_Submatrices_L_ 3 %unmacro _M4INVERSE_Submatrices_H_ 3 %if 0 global M4MULV3 ; M4MULV3(void * Result, void * Matrix, void * Vector); ;******************************************************************************************* ; Given a 4x4 Matrix and a 3D Vector, ; 3D Vector Result = MatrixA * VectorB, BUT: ; - In order for the operation to be possible, a 4th element (1.f) is added to Vector ;******************************************************************************************* M4MULV3: _enter_ %ifidn __OUTPUT_FORMAT__, win64 sub rsp,16*2 movups [rsp],xmm6 movups [rsp+16],xmm7 %endif sub rsp,16*4 movups [rsp],xmm8 movups [rsp+16],xmm9 movups [rsp+16+16],xmm10 movups [rsp+16+16+16],xmm15 movups xmm4,[arg2] movups xmm5,[arg2+16] movups xmm6,[arg2+16+16] movups xmm7,[arg2+16+16+16] movups arg1f, [arg2] movups arg2f, [arg2+16] movups arg3f, [arg2+32] movups arg4f, [arg2+16+32] TRANS44 _loadvec3_ xmm7,arg3,xmm15 movaps arg3f,xmm4 movaps arg4f,xmm5 pxor xmm4,xmm4 pcmpeqd xmm4,xmm4 ;xmm4[0] = [11111111111111111111111111111111] psrld xmm4,25 ;xmm4[0] = [00000000000000000000000001111111] pslld xmm4,23 ;xmm4[0] = [00111111100000000000000000000000] = 1.f ;xmm4 = [1.f][1.f][1.f][1.f] movhlps xmm5,xmm7 ;xmm5 = [?][?][W][Z] movss xmm4,xmm5 ;xmm4 = [1.f][1.f][1.f][Z] movlhps xmm7,xmm4 ;xmm7 = [1.f][Z][Y][X] movlhps xmm5,xmm5 ;xmm5 = [W][Z][?][?] M4x4MULMACRO xmm7,xmm15 movhlps xmm5,xmm15 ;xmm5 = [W][Z][Rw][Rz] pshufd xmm5,xmm5,11_10_11_00b ;xmm5 = [W][Z][W][Rz] movlhps xmm15,xmm5 ;xmm15 = [W][Rz][Ry][Rx] _storevec3_ arg1,xmm15,xmm10 movups xmm8,[rsp] movups xmm9,[rsp+16] movups xmm10,[rsp+16+16] movups xmm15,[rsp+16+16+16] add rsp,16*4 %ifidn __OUTPUT_FORMAT__, win64 movups xmm6,[rsp] movups xmm7,[rsp+16] add rsp, 16*2 %endif _leave_ ret %endif args_reset %if 0 global AM4MULV3; void AM4MULV3(void * Vec3_Destiny, void * Matrix, void * Vector); ;**************************************************************************************** ; Given a 4x4 Matrix and a 3D Vector, ; 3D Vector Result = Matrix * Vector, BUT: ; - In order for the operation to be possible, a 4th element (1.f) is added to Vector ; - The last row and column of the matrix are temporarily replaced both with (0,0,0,1.f) ; - This function calculates only the affine transformation. ;**************************************************************************************** AM4MULV3: _enter_ %ifidn __OUTPUT_FORMAT__, win64 sub rsp,16*2 movups [rsp],xmm6 movups [rsp+16],xmm7 %endif sub rsp,16*5 movups [rsp],xmm8 movups [rsp+16],xmm9 movups [rsp+16+16],xmm10 movups [rsp+16+16+16],xmm15 movups [rsp+16+16+16+16],xmm14 movups arg1f, [arg2] movups arg2f, [arg2+16] movups arg3f, [arg2+32] pxor xmm14,xmm14 pcmpeqd xmm14,xmm14 ;xmm14[0] = [11111111111111111111111111111111] psrld xmm14,25 ;xmm14[0] = [00000000000000000000000001111111] pslld xmm14,23 ;xmm14[0] = [00111111100000000000000000000000] = 1.f ;xmm14 = [1.f][1.f][1.f][1.f] pxor arg4f,arg4f movss arg4f,xmm14 pshufd arg4f,arg4f, 00_10_01_11b TRANS44 _loadvec3_ xmm7,arg3,xmm15 movaps arg3f,xmm4 pxor arg4f,arg4f movss arg4f,xmm14 movhlps xmm5,xmm7 ;xmm5 = [?][?][W][Z] movss xmm14,xmm5 ;xmm14 = [1.f][1.f][1.f][Z] movlhps xmm7,xmm14 ;xmm7 = [1.f][Z][Y][X] movlhps xmm5,xmm5 ;xmm5 = [W][Z][?][?] M4x4MULMACRO xmm7,xmm15 movhlps xmm5,xmm15 ;xmm5 = [W][Z][Rw][Rz] pshufd xmm5,xmm5,11_10_11_00b ;xmm5 = [W][Z][W][Rz] movlhps xmm15,xmm5 ;xmm15 = [W][Rz][Ry][Rx] _storevec3_ arg1,xmm15,xmm10 movups xmm8,[rsp] movups xmm9,[rsp+16] movups xmm10,[rsp+16+16] movups xmm15,[rsp+16+16+16] movups xmm14,[rsp+16+16+16+16] add rsp,16*5 %ifidn __OUTPUT_FORMAT__, win64 movups xmm6,[rsp] movups xmm7,[rsp+16] add rsp, 16*2 %endif _leave_ ret %endif args_reset global M4PERSPECTIVE ;void M4PERSPECTIVE ;(float *matrix, float fovyInDegrees, float aspectRatio,float znear, float zfar); ;********************************************************************* ;It's an implementation of gluPerspective ;********************************************************************* M4PERSPECTIVE: %ifidn __OUTPUT_FORMAT__, win64 %define arg1f XMM1 %define arg2f XMM2 %define arg3f XMM3 %define arg4f XMM4 ;zfar is in the stack, so it must be move to XMM4 movss arg4f,[rsp+40] %endif _enter_ %ifidn __OUTPUT_FORMAT__, win64 sub rsp,16*2 movups [rsp],xmm6 movups [rsp+16],xmm7 %endif sub rsp,16*6 movups [rsp],xmm9 movups [rsp+16],xmm10 movups [rsp+16+16],xmm11 movups [rsp+16+16+16],xmm12 movups [rsp+16+16+16+16],xmm13 movups [rsp+16+16+16+16+16],xmm14 mov rax, fc_360f pxor xmm12,xmm12 movaps xmm11,arg4f push rax mov rax, fc_m_1f pxor xmm10,xmm10 fldpi sub rsp,8 fstp dword[rsp] movss xmm12,arg3f pxor xmm9,xmm9 movss xmm13,[rsp] addss xmm12,xmm12 subss xmm11,arg3f movss xmm14,[rsp+8] mulss arg1f,xmm13 subss xmm10,xmm12 divss arg1f,xmm14 movss [rsp],arg1f mulss xmm10,arg4f movss xmm9,xmm11 fld dword [rsp] divss xmm10,xmm11 subss xmm9,arg4f fptan fstp st0 fstp dword [rsp] subss xmm9,arg4f divss xmm9,xmm11 pxor xmm5,xmm5 ;XMM11 = temp4 = ZFAR - ZNEAR ;XMM9 = (-ZFAR - ZNEAR)/temp4 ;XMM10 = (-temp * ZFAR) / temp4 ;XMM12 = temp =2.0 * ZNEAR pshufd xmm7,xmm10,11_00_11_11b movss arg1f, [rsp] pshufd xmm6,xmm9, 11_00_11_11b mulss arg1f, arg3f mulss arg2f, arg1f addss arg1f,arg1f ;arg1f = temp3 movss xmm5,xmm12 divss xmm5,arg1f pshufd xmm5,xmm5,11_11_00_11b addss arg2f,arg2f ;arg2f = temp2 divss xmm12,arg2f ;Resulting matrix in XMM12,XMM5,XMM6,XMM7 movups [arg1],XMM12 movups [arg1+16],XMM5 movups [arg1+16+16],XMM6 movups [arg1+16+16+16],XMM7 mov [arg1+16+16+12],rax add rsp,16 movups xmm9,[rsp] movups xmm10,[rsp+16] movups xmm11,[rsp+16+16] movups xmm12,[rsp+16+16+16] movups xmm13,[rsp+16+16+16+16] movups xmm14,[rsp+16+16+16+16+16] add rsp,16*6 %ifidn __OUTPUT_FORMAT__, win64 movups xmm6,[rsp] movups xmm7,[rsp+16] add rsp, 16*2 args_reset %endif _leave_ ret global M4TRANSPOSE; void M4TRANSPOSE(void * Destiny, void * Origin) M4TRANSPOSE: _enter_ movups xmm0,[arg2] movups xmm1,[arg2+16] movups xmm2,[arg2+16+16] movups xmm3,[arg2+16+16+16] TRANS44 movups [arg1],xmm0 movups [arg1+16],xmm2 movups [arg1+16+16],xmm4 movups [arg1+16+16+16],xmm5 _leave_ ret %if 0 global M4ORTHO; ; void M4ORTHO ; (float *matrix, float L, float R, float T,float B, float znear, float zfar); ;********************************************************* M4ORTHO: %define arg5f XMM4 %ifidn __OUTPUT_FORMAT__, win64 %define arg1f XMM1 ;L %define arg2f XMM2 ;R %define arg3f XMM3 ;T %define arg4f XMM4 ;B (in stack) %define arg5f XMM5 ;znear (in stack) %define arg6f XMM0 ;zfar (in stack) ;B is in the stack, so it have to be moved to XMM4 movss arg4f,[rsp+32+8] ;znear is in the stack, so it have to be moved to XMM5 movss arg5f,[rsp+32+8+4] ;zfar is in the stack, so it have to be moved to XMM0 movss arg6f,[rsp+32+8+4+4] %endif _enter_ %ifidn __OUTPUT_FORMAT__, win64 sub rsp,16*2 movups [rsp],xmm6 movups [rsp+16],xmm7 %endif movss xmm6,arg1f addss arg1f,arg2f subss arg2f,xmm6 movss xmm6,arg3f addss arg3f,arg4f subss arg4f,xmm6 movss xmm6,arg5f addss arg5f,arg6f subss arg6f,xmm6 pcmpeqw xmm7,xmm7 pslld xmm7,25 psrld xmm7,2 pcmpeqw xmm6,xmm6 pslld xmm6,31 pxor xmm7,xmm6 ;arg1f = r+l ;arg2f = r-l ;arg3f = t+b ;arg4f = t-b ;arg5f = f+n ;arg6f = f-n ;xmm6 = [SC][SC][SC][SC] ;xmm7 = [-1][-1][-1][-1] divss arg5f,arg6f divss arg3f,arg4f divss arg1f,arg2f movss xmm7,arg5f pslldq xmm7,4 movss xmm7,arg3f pslldq xmm7,4 movss xmm7,arg1f pxor xmm7,xmm6 ;xmm7 = [1][-(f+n/f-n)][-(t+b/t-b)][-(r+l/r-l)] pcmpeqw arg1f,arg1f pslld arg1f,31 psrld arg1f,1 movss arg3f,arg1f movss arg5f,arg1f divss arg1f,arg2f divss arg3f,arg4f divss arg5f,arg6f pxor arg5f,xmm6 pslldq arg1f,12 psrldq arg1f,12 pslldq arg3f,12 psrldq arg3f,8 pslldq arg5f,12 psrldq arg5f,4 movups [arg1],arg1f movups [arg1+16],arg3f movups [arg1+16+16],arg5f movups [arg1+16+16+16],xmm7 %ifidn __OUTPUT_FORMAT__, win64 movups xmm6,[rsp] movups xmm7,[rsp+16] add rsp, 16*2 %endif _leave_ ret %endif args_reset global OLD_M4ORTHO; ; void M4ORTHO ; (float *matrix, float Width, float Height, float znear, float zfar); ;********************************************************* OLD_M4ORTHO: %define arg5f XMM4 %ifidn __OUTPUT_FORMAT__, win64 %define arg1f XMM1 %define arg2f XMM2 %define arg3f XMM3 %define arg4f XMM4 %define arg5f XMM0 ;zfar is in the stack, so it have to be moved to XMM4 movss arg4f,[rsp+32+8] %endif _enter_ %ifidn __OUTPUT_FORMAT__, win64 sub rsp,16*2 movups [rsp],xmm6 movups [rsp+16],xmm7 %endif ; movss [arg1],arg4f mov arg2,fc_2f movss arg5f,arg4f subss arg5f,arg3f push arg2 addss arg4f,arg3f divss arg4f,arg5f movss arg3f,[rsp] pxor xmm5,xmm5 pxor xmm6,xmm6 movss xmm7,arg3f mov rax,fc_1f divss arg3f,arg1f movss arg1f,xmm7 divss xmm7,arg2f subss xmm6,arg1f subss xmm5,arg4f divss xmm6,arg5f ;arg3f = 2/Width ;arg4f = (zfar+znear)/(zfar-znear) ;arg5f = zfar-znear ;xmm5 = -((zfar+znear)/(zfar-znear)) ;xmm6 = -2 / ((zfar+znear)/(zfar-znear)) ;xmm7 = 2/Height %if 1 pxor arg1f,arg1f movss arg1f,arg3f ;arg1f = [0][0][0][2/Width] movups [arg1],arg1f pxor arg2f,arg2f movss arg2f,xmm7 pslldq arg2f,4 ;arg2f = [0][0][2/Height][0] movups [arg1+ (4*4)],arg2f pxor arg3f,arg3f movss arg3f,xmm6 pslldq arg3f,4+4 ;arg3f = [0][xmm6][0][0] movups [arg1+ (4*4*2)],arg3f pxor arg1f,arg1f movss arg1f,xmm5 pslldq arg1f,4+4 ;arg1f = [0][xmm5][0][0] movups [arg1+ (4*4*3)],arg1f mov [arg1+16+16+16+12],eax %endif pop rax %ifidn __OUTPUT_FORMAT__, win64 movups xmm6,[rsp] movups xmm7,[rsp+16] add rsp, 16*2 args_reset %endif _leave_ ret %undef arg5f args_reset global M4LOOKAT ; M4LOOKAT(float * matrix, float * Vec3From_EYE, float * Vec3To_CENTER, float * Vec3Up); ;********************************************************* ;It's an implementation of glm::LookAt ;********************************************************* M4LOOKAT: _enter_ %ifidn __OUTPUT_FORMAT__, win64 sub rsp,16*2 movups [rsp],xmm6 movups [rsp+16],xmm7 %endif sub rsp,16*6 movups [rsp],xmm8 movups [rsp+16],xmm11 movups [rsp+16+16],xmm12 movups [rsp+16+16+16],xmm13 movups [rsp+16+16+16+16],xmm14 movups [rsp+16+16+16+16+16],xmm15 push rax xor eax,eax mov eax,fc_m_1f push rax pxor arg4f,arg4f movups xmm7, [arg2] ;EYE movups xmm15, [arg3] ;CENTER subps xmm15,xmm7 ;xmm15 = f = CENTER - EYE movups xmm14, [arg4] ;---Normalize f----; NORMALIZEVEC3MACRO xmm15,arg1f,arg2f,arg3f ;-------------------; ;---Normalize up----; NORMALIZEVEC3MACRO xmm14,arg1f,arg2f,arg3f ;-------------------; ;Resumen: ;xmm15 = f ;xmm14 = up movss xmm8, [rsp] ;Cross Product s = f x up; CROSSPRODUCTMACRO xmm15,xmm14,xmm13,arg1f,arg2f,arg3f ;--------------------------; ;Normalize s-----; NORMALIZEVEC3MACRO xmm13,arg1f,arg2f,arg3f ;-----------------; ;Resume: ;xmm7 = eye ;xmm15 = f ;xmm14 = up ;xmm13 = s pshufd xmm8,xmm8,0 ;xmm8 [-1.f][-1.f][-1.f][-1.f] add rsp,8 ;Cross Product u = s x f; CROSSPRODUCTMACRO xmm13,xmm15,xmm14,arg1f,arg2f,arg3f ;-------------------------; ;Resume: ;xmm7 = eye ;xmm15 = f ;xmm14 = u ;xmm13 = s ;calculate -( s . eye ) DotProductXMMV3 xmm13,xmm7,xmm12,arg1f mulss xmm12,xmm8 ;------------------------------; pop rax ;calculate -( u . eye ) DotProductXMMV3 xmm14,xmm7,xmm11,arg1f mulss xmm11,xmm8 ;------------------------------; ;calculate ( f . eye ) DotProductXMMV3 xmm15,xmm7,xmm6,arg1f ;------------------------------; ;do f=-f; mulps xmm15,xmm8 ;----------; ;Resume: ;xmm8 = [-1][-1][-1][-1] ;xmm7 = eye ;xmm15 = -f ;xmm14 = u ;xmm13 = s ;xmm12 = -dot (s,eye) ;xmm11 = -dot (u,eye) ;xmm6 = +dot (f,eye) mulps xmm8,xmm8 ;xmm8 = [1.f][1.f][1.f][1.f] movss xmm8,xmm6 ;xmm8 = [1.f][1.f][1.f][+dot(f,eye)] movlhps xmm8,xmm8 ;xmm8 = [1.f][+dot(f,eye)][1.f][+dot(f,eye)] unpcklps xmm12,xmm11 ;xmm12 = [-dot (u,eye)][-dot (s,eye)][-dot (u,eye)][-dot (s,eye)] movsd xmm8,xmm12 ;xmm8 [1.f][+dot(f,eye)][-dot (u,eye)][-dot (s,eye)] movaps arg1f,xmm13 movaps arg2f,xmm14 movaps arg3f,xmm15 TRANS44 movaps [arg1],arg1f add arg1,16 movaps [arg1],arg2f add arg1,16 movaps [arg1],xmm4 add arg1,16 movaps [arg1],xmm8 movups xmm8,[rsp] movups xmm11,[rsp+16] movups xmm12,[rsp+16+16] movups xmm13,[rsp+16+16+16] movups xmm14,[rsp+16+16+16+16] movups xmm15,[rsp+16+16+16+16+16] add rsp,16*6 %ifidn __OUTPUT_FORMAT__, win64 movups xmm6,[rsp] movups xmm7,[rsp+16] add rsp, 16*2 args_reset %endif _leave_ ret %unmacro DotProductXMMV2 4 %unmacro M4x4MULMACRO 2 %unmacro TRANS44 0 %unmacro MULVEC4VEC4 3 %unmacro CROSSPRODUCTV2 4 %unmacro _V4Lerp_ 4 %endif
test/Succeed/Issue2034.agda
alhassy/agda
3
7831
<reponame>alhassy/agda module _ where open import Agda.Builtin.Nat postulate T : Set C₁ : Set instance I₁ : C₁ C₂ : Nat → Set instance I₂ : ∀ {n} → C₂ n it : {A : Set} {{_ : A}} → A it {{x}} = x postulate f₁ : {{_ : Nat → C₁}} → T f₂ : {{_ : ∀ n → C₂ n}} → T works₁ : T works₁ = f₁ -- f₁ {{λ _ → I₁}} fails₁ : T fails₁ = f₁ {{it}} -- internal error works₂ : T works₂ = f₂ -- f₂ {{λ n → I₂ {n}}} fails₂ : T fails₂ = f₂ {{it}} -- internal error
libsrc/_DEVELOPMENT/arch/zx/display/c/sccz80/zx_saddrpdown.asm
Frodevan/z88dk
640
240896
<reponame>Frodevan/z88dk ; void *zx_saddrpdown(void *saddr) SECTION code_clib SECTION code_arch PUBLIC zx_saddrpdown EXTERN asm_zx_saddrpdown defc zx_saddrpdown = asm_zx_saddrpdown ; SDCC bridge for Classic IF __CLASSIC PUBLIC _zx_saddrpdown defc _zx_saddrpdown = zx_saddrpdown ENDIF
tests/resources/incomplete/SharedRules.g4
baniuk/setuptools-antlr
1
6683
<reponame>baniuk/setuptools-antlr<gh_stars>1-10 grammar SharedRules; import CommonTerminals; sub_rule_foo : 'foo' IDENTIFIER ; sub_rule_bar : 'bar' IDENTIFIER (SEPARATOR IDENTIFIER)* ;
alloy4fun_models/trashltl/models/3/XwG8Gfezbf8C2X8Xk.als
Kaixi26/org.alloytools.alloy
0
4306
open main pred idXwG8Gfezbf8C2X8Xk_prop4 { some f:File | eventually f in Trash } pred __repair { idXwG8Gfezbf8C2X8Xk_prop4 } check __repair { idXwG8Gfezbf8C2X8Xk_prop4 <=> prop4o }
win/macosx/NetHackGuidebook.applescript
timdetering/NetHack-VisualStudio
2
3026
<filename>win/macosx/NetHackGuidebook.applescript #!/usr/bin/osascript # NetHack 3.6.1 NetHackGuidebook.applescript $NHDT-Date: 1524684596 2018/04/25 19:29:56 $ $NHDT-Branch: NetHack-3.6.0 $:$NHDT-Revision: 1.8 $ # Copyright (c) <NAME>, Kensington, Maryland, 2011 # NetHack may be freely redistributed. See license for details. # Display the Guidebook from the GUI. tell application "Finder" open location "file:///Library/Nethack/doc/NetHackGuidebook.pdf" delay 5 end tell
oeis/135/A135484.asm
neoneye/loda-programs
11
27911
; A135484: a(n) = Sum_{i=1..n} i^prime(i), where prime(i) denotes i-th prime number. ; 1,9,252,16636,48844761,13109538777,232643623525984,144347831699381856,8863082467484200477785,100000008863082467484200477785,192043424966613562971631041769596,8505622691864527111189694655745871704188,4695460930721600661616082599032077780947833001,19213729855389681385536662696880853982373955506345,18892508108960954260893468704510292058444829389336365720,6582018248177332277580830991122870724441235520979148842730801816,3948992983058564303985294394886379086461973464903657108398064386772618569 lpb $0 mov $2,$0 sub $0,1 seq $2,62481 ; a(n) = n^prime(n). add $3,$2 lpe mov $0,$3 add $0,1
cpm2/RomWBW/Source/HBIOS/asci.asm
grancier/z180
0
245240
<gh_stars>0 ; ;================================================================================================== ; ASCI DRIVER (Z180 SERIAL PORTS) ;================================================================================================== ; ; SETUP PARAMETER WORD: ; +-------+---+-------------------+ +---+---+-----------+---+-------+ ; | |RTS| ENCODED BAUD RATE | |DTR|XON| PARITY |STP| 8/7/6 | ; +-------+---+---+---------------+ ----+---+-----------+---+-------+ ; F E D C B A 9 8 7 6 5 4 3 2 1 0 ; -- MSB (D REGISTER) -- -- LSB (E REGISTER) -- ; ; STAT: ; 7 6 5 4 3 2 1 0 ; R O P F R C T T ; 0 0 0 0 0 0 0 0 DEFAULT VALUES ; | | | | | | | | ; | | | | | | | +-- TIE: TRANSMIT INTERRUPT ENABLE ; | | | | | | +---- TDRE: TRANSMIT DATA REGISTER EMPTY ; | | | | | +------ DCD0/CTS1E: CH0 CARRIER DETECT, CH1 CTS ENABLE ; | | | | +-------- RIE: RECEIVE INTERRUPT ENABLE ; | | | +---------- FE: FRAMING ERROR ; | | +------------ PE: PARITY ERROR ; | +-------------- OVRN: OVERRUN ERROR ; +---------------- RDRF: RECEIVE DATA REGISTER FULL ; ; CNTLA: ; 7 6 5 4 3 2 1 0 ; M R T R E M M M ; 0 1 1 0 0 1 0 0 DEFAULT VALUES ; | | | | | | | | ; | | | | | | | +-- MOD0: STOP BITS: 0=1 BIT, 1=2 BITS ; | | | | | | +---- MOD1: PARITY: 0=NONE, 1=ENABLED ; | | | | | +------ MOD2: DATA BITS: 0=7 BITS, 1=8 BITS ; | | | | +-------- MPBR/EFR: MULTIPROCESSOR BIT RECEIVE / ERROR FLAG RESET ; | | | +---------- RTS0/CKA1D: CH0 RTS, CH1 CLOCK DISABLE ; | | +------------ TE: TRANSMITTER ENABLE ; | +-------------- RE: RECEIVER ENABLE ; +---------------- MPE: MULTI-PROCESSOR MODE ENABLE ; ; CNTLB: ; 7 6 5 4 3 2 1 0 ; T M P R D S S S ; 0 0 X 0 X X X X DEFAULT VALUES ; | | | | | | | | ; | | | | | + + +-- SS: SOURCE/SPEED SELECT (R/W) ; | | | | +-------- DR: DIVIDE RATIO (R/W) ; | | | +---------- PEO: PARITY EVEN ODD (R/W) ; | | +------------ PS: ~CTS/PS: CLEAR TO SEND(R) / PRESCALE(W) ; | +-------------- MP: MULTIPROCESSOR MODE (R/W) ; +---------------- MPBT: MULTIPROCESSOR BIT TRANSMIT (R/W) ; ; ASEXT: ; 7 6 5 4 3 2 1 0 ; R D C X B F D S ; 0 1 1 0 0 1 1 0 DEFAULT VALUES ; | | | | | | | | ; | | | | | | | +-- SEND BREAK ; | | | | | | +---- BREAK DETECT (RO) ; | | | | | +------ BREAK FEATURE ENABLE ; | | | | +-------- BRG MODE ; | | | +---------- X1 BIT CLK ASCI ; | | +------------ CTS0 DISABLE ; | +-------------- DCD0 DISABLE ; +---------------- RDRF INT INHIBIT ; ASCI_PREINIT: ; ; SETUP THE DISPATCH TABLE ENTRIES ; ; LD B,2 ; ALWAYS 2 ASCI UNITS ON Z180 ; LD C,0 ; PHYSICAL UNIT INDEX ;ASCI_PREINIT1: ; PUSH BC ; SAVE LOOP CONTROL ; LD D,C ; PHYSICAL UNIT ; LD E,CIODEV_ASCI ; DEVICE TYPE ; LD BC,ASCI_FNTBL ; BC := FUNCTION TABLE ADDRESS ; CALL CIO_ADDENT ; ADD ENTRY, BC IS NOT DESTROYED ; POP BC ; RESTORE LOOP CONTROL ; INC C ; NEXT PHYSICAL UNIT ; DJNZ ASCI_PREINIT1 ; LOOP UNTIL DONE ; ; ASCI0 CHANNEL LD D,0 ; DEVICE ID LD E,CIODEV_ASCI ; DEVICE TYPE LD BC,ASCI0_FNTBL ; ASCI0 FUNCTION TABLE PTR CALL CIO_ADDENT LD DE,-1 ; DE := -1 TO INIT DEFAULT CONFIG CALL ASCI0_INITDEV ; INIT DEVICE ; ; ASCI1 CHANNEL LD D,1 ; DEVICE ID LD E,CIODEV_ASCI ; DEVICE TYPE LD BC,ASCI1_FNTBL ; ASCI1 FUNCTION TABLE PTR CALL CIO_ADDENT LD DE,-1 ; DE := -1 TO INIT DEFAULT CONFIG CALL ASCI1_INITDEV ; INIT DEVICE ; XOR A ; SIGNAL SUCCESS RET ; ; ; ASCI_INIT: ; ; ASCI0 CALL NEWLINE ; FORMATTING PRTS("ASCI0: IO=0x$") ; PREFIX LD A,Z180_TDR0 ; LOAD TDR PORT ADDRESS CALL PRTHEXBYTE ; PRINT IT CALL PC_COMMA ; FORMATTING LD A,Z180_RDR0 ; LOAD RDR PORT ADDRESS CALL PRTHEXBYTE ; PRINT IT PRTS(" MODE=$") ; FORMATTING LD DE,(ASCI0_CONFIG) ; LOAD CONFIG CALL PS_PRTSC0 ; PRINT IT ; ; ASCI1 CALL NEWLINE ; FORMATTING PRTS("ASCI1: IO=0x$") ; PREFIX LD A,Z180_TDR1 ; LOAD TDR PORT ADDRESS CALL PRTHEXBYTE ; PRINT IT CALL PC_COMMA ; FORMATTING LD A,Z180_RDR1 ; LOAD RDR PORT ADDRESS CALL PRTHEXBYTE ; PRINT IT PRTS(" MODE=$") ; FORMATTING LD DE,(ASCI1_CONFIG) ; LOAD CONFIG CALL PS_PRTSC0 ; PRINT IT ; XOR A RET ; ; DRIVER ASCI0 FUNCTION TABLE ; ASCI0_FNTBL: .DW ASCI0_IN .DW ASCI0_OUT .DW ASCI0_IST .DW ASCI0_OST .DW ASCI0_INITDEV .DW ASCI0_QUERY .DW ASCI0_DEVICE #IF (($ - ASCI0_FNTBL) != (CIO_FNCNT * 2)) .ECHO "*** INVALID ASCI0 FUNCTION TABLE ***\n" #ENDIF ; ASCI0_IN: CALL ASCI0_IST OR A JR Z,ASCI0_IN IN0 A,(Z180_RDR0) ; READ THE CHAR LD E,A RET ; ASCI0_IST: ; CHECK FOR ERROR FLAGS IN0 A,(Z180_STAT0) AND 70H ; PARITY, FRAMING, OR OVERRUN ERROR JR Z,ASCI0_IST1 ; ALL IS WELL, CHECK FOR DATA ; ; CLEAR ERROR(S) OR NOTHING FURTHER CAN BE RECEIVED!!! IN0 A,(Z180_CNTLA0) RES 3,A ; CLEAR EFR (ERROR FLAG RESET) OUT0 (Z180_CNTLA0),A ; ASCI0_IST1: ; CHECK FOR STAT0.RDRF (DATA READY) IN0 A,(Z180_STAT0) ; READ LINE STATUS REGISTER AND $80 ; TEST IF DATA IN RECEIVE BUFFER JP Z,CIO_IDLE ; DO IDLE PROCESSING AND RETURN XOR A INC A ; SIGNAL CHAR READY, A = 1 RET ; ASCI0_OUT: CALL ASCI0_OST OR A JR Z,ASCI0_OUT LD A,E OUT0 (Z180_TDR0),A RET ; ASCI0_OST: IN0 A,(Z180_STAT0) AND $02 JP Z,CIO_IDLE ; DO IDLE PROCESSING AND RETURN XOR A INC A ; SIGNAL BUFFER EMPTY, A = 1 RET ; ASCI0_INITDEV: ; TEST FOR -1 WHICH MEANS USE CURRENT CONFIG (JUST REINIT) LD A,D ; TEST DE FOR AND E ; ... VALUE OF -1 INC A ; ... SO Z SET IF -1 JR NZ,ASCI0_INITDEV1 ; IF NEW CONFIG (NOT -1), IMPLEMENT IT LD DE,(ASCI0_CONFIG) ; OTHERWISE, LOAD EXISTING CONFIG ; ASCI0_INITDEV1: ; DETERMINE APPROPRIATE CNTLB VALUE (BASED ON BAUDRATE & CPU SPEED) LD A,D ; BYTE W/ ENCODED BAUD RATE AND $1F ; ISOLATE BITS LD L,A ; MOVE TO L LD H,0 ; CLEAR MSB PUSH DE ; SAVE CONFIG CALL ASCI_CNTLB ; DERIVE CNTLB VALUE IN C POP DE ; RESTORE CONFIG ;CALL TSTPT RET NZ ; ABORT ON ERROR ; LD B,$64 ; B := DEFAULT CNTLB VALUE ; DATA BITS LD A,E ; LOAD CONFIG BYTE AND $03 ; ISOLATE DATA BITS CP $03 ; 8 DATA BITS? JR Z,ASCI0_INITDEV2 ; IF SO, NO CHG, CONTINUE RES 2,B ; RESET CNTLA BIT 2 FOR 7 DATA BITS ASCI0_INITDEV2: ; STOP BITS BIT 2,E ; TEST STOP BITS CONFIG BIT JR Z,ASCI0_INITDEV3 ; IF CLEAR, NO CHG, CONTINUE SET 0,B ; SET CNTLA BIT 0 FOR 2 STOP BITS ASCI0_INITDEV3: ; PARITY ENABLE BIT 3,E ; TEST PARITY ENABLE CONFIG BIT JR Z,ASCI0_INITDEV4 ; NO PARITY, SKIP ALL PARITY CHGS SET 1,B ; SET CNTLA BIT 1 FOR PARITY ENABLE ; PARITY EVEN/ODD BIT 4,E ; TEST EVEN PARITY CONFIG BIT JR NZ,ASCI0_INITDEV4 ; EVEN PARITY, NO CHG, CONTINUE SET 4,C ; SET CNTLB BIT 4 FOR ODD PARITY ASCI0_INITDEV4: ; IMPLEMENT CONFIGURATION LD A,$66 ; LOAD DEFAULT ASEXT VALUE OUT0 (Z180_ASEXT0),A ; SET IT LD A,B ; FINAL CNTLA VALUE TO ACCUM OUT0 (Z180_CNTLA0),A ; WRITE TO CNTLA REGISTER LD A,C ; FINAL CNTLB VALUE TO ACCUM OUT0 (Z180_CNTLB0),A ; WRITE TO CNTLA REGISTER ; LD (ASCI0_CONFIG),DE ; RECORD UPDATED CONFIG XOR A ; SIGNAL SUCCESS RET ; DONE ; ASCI0_QUERY: LD DE,(ASCI0_CONFIG) XOR A RET ; ASCI0_DEVICE: LD D,CIODEV_ASCI ; D := DEVICE TYPE LD E,0 ; E := PHYSICAL UNIT XOR A ; SIGNAL SUCCESS RET ; ; DRIVER ASCI1 FUNCTION TABLE ; ASCI1_FNTBL: .DW ASCI1_IN .DW ASCI1_OUT .DW ASCI1_IST .DW ASCI1_OST .DW ASCI1_INITDEV .DW ASCI1_QUERY .DW ASCI1_DEVICE #IF (($ - ASCI1_FNTBL) != (CIO_FNCNT * 2)) .ECHO "*** INVALID ASCI1 FUNCTION TABLE ***\n" #ENDIF ASCI1: LD A,B ; GET REQUESTED FUNCTION AND $0F ; ISOLATE SUB-FUNCTION JR Z,ASCI1_IN DEC A JR Z,ASCI1_OUT DEC A JR Z,ASCI1_IST DEC A JR Z,ASCI1_OST DEC A JP Z,ASCI1_INITDEV DEC A JP Z,ASCI1_QUERY DEC A JP Z,ASCI1_DEVICE CALL PANIC ; ASCI1_IN: CALL ASCI1_IST OR A JR Z,ASCI1_IN IN0 A,(Z180_RDR1) ; READ THE CHAR LD E,A RET ; ASCI1_IST: ; CHECK FOR ERROR FLAGS IN0 A,(Z180_STAT1) AND 70H ; PARITY, FRAMING, OR OVERRUN ERROR JR Z,ASCI1_IST1 ; ALL IS WELL, CHECK FOR DATA ; ; CLEAR ERROR(S) OR NOTHING FURTHER CAN BE RECEIVED!!! IN0 A,(Z180_CNTLA1) RES 3,A ; CLEAR EFR (ERROR FLAG RESET) OUT0 (Z180_CNTLA1),A ; ASCI1_IST1: ; CHECK FOR STAT0.RDRF (DATA READY) IN0 A,(Z180_STAT1) ; READ LINE STATUS REGISTER AND $80 ; TEST IF DATA IN RECEIVE BUFFER JP Z,CIO_IDLE ; DO IDLE PROCESSING AND RETURN XOR A INC A ; SIGNAL CHAR READY, A = 1 RET ; ASCI1_OUT: CALL ASCI1_OST OR A JR Z,ASCI1_OUT LD A,E OUT0 (Z180_TDR1),A RET ; ASCI1_OST: IN0 A,(Z180_STAT1) AND $02 JR Z,ASCI1_OST JP Z,CIO_IDLE ; DO IDLE PROCESSING AND RETURN XOR A INC A ; SIGNAL BUFFER EMPTY, A = 1 RET ; ASCI1_INITDEV: ; TEST FOR -1 WHICH MEANS USE CURRENT CONFIG (JUST REINIT) LD A,D ; TEST DE FOR AND E ; ... VALUE OF -1 INC A ; ... SO Z SET IF -1 JR NZ,ASCI1_INITDEV1 ; IF NEW CONFIG (NOT -1), IMPLEMENT IT LD DE,(ASCI1_CONFIG) ; OTHERWISE, LOAD EXISTING CONFIG ; ASCI1_INITDEV1: ; DETERMINE APPROPRIATE CNTLB VALUE (BASED ON BAUDRATE & CPU SPEED) LD A,D ; BYTE W/ ENCODED BAUD RATE AND $1F ; ISOLATE BITS LD L,A ; MOVE TO L LD H,0 ; CLEAR MSB PUSH DE ; SAVE CONFIG CALL ASCI_CNTLB ; DERIVE CNTLB VALUE POP DE ; RESTORE CONFIG ;CALL TSTPT RET NZ ; ABORT ON ERROR ; LD B,$64 ; B := DEFAULT CNTLB VALUE ; DATA BITS LD A,E ; LOAD CONFIG BYTE AND $03 ; ISOLATE DATA BITS CP $03 ; 8 DATA BITS? JR Z,ASCI1_INITDEV2 ; IF SO, NO CHG, CONTINUE RES 2,B ; RESET CNTLA BIT 2 FOR 7 DATA BITS ASCI1_INITDEV2: ; STOP BITS BIT 2,E ; TEST STOP BITS CONFIG BIT JR Z,ASCI1_INITDEV3 ; IF CLEAR, NO CHG, CONTINUE SET 0,B ; SET CNTLA BIT 0 FOR 2 STOP BITS ASCI1_INITDEV3: ; PARITY ENABLE BIT 3,E ; TEST PARITY ENABLE CONFIG BIT JR Z,ASCI1_INITDEV4 ; NO PARITY, SKIP ALL PARITY CHGS SET 1,B ; SET CNTLA BIT 1 FOR PARITY ENABLE ; PARITY EVEN/ODD BIT 4,E ; TEST EVEN PARITY CONFIG BIT JR NZ,ASCI1_INITDEV4 ; EVEN PARITY, NO CHG, CONTINUE SET 4,C ; SET CNTLB BIT 4 FOR ODD PARITY ASCI1_INITDEV4: ; IMPLEMENT CONFIGURATION LD A,$66 ; LOAD DEFAULT ASEXT VALUE OUT0 (Z180_ASEXT1),A ; SET IT LD A,B ; FINAL CNTLA VALUE TO ACCUM OUT0 (Z180_CNTLA1),A ; WRITE TO CNTLA REGISTER LD A,C ; FINAL CNTLB VALUE TO ACCUM OUT0 (Z180_CNTLB1),A ; WRITE TO CNTLA REGISTER ; LD (ASCI1_CONFIG),DE ; RECORD UPDATED CONFIG XOR A ; SIGNAL SUCCESS RET ; DONE ; ASCI1_QUERY: LD DE,(ASCI1_CONFIG) XOR A RET ; ASCI1_DEVICE: LD D,CIODEV_ASCI ; D := DEVICE TYPE LD E,1 ; E := PHYSICAL UNIT XOR A ; SIGNAL SUCCESS RET ; ; LOCAL DATA ; ASCI0_CONFIG .DW DEFSERCFG ; SAVED CONFIG FOR ASCI0 ASCI1_CONFIG .DW DEFSERCFG ; SAVED CONFIG FOR ASCI1 ; ; DERIVE A CNTLB VALUE BASED ON AN ENCODED BAUD RATE AND CURRENT CPU SPEED ; ENTRY: HL = ENCODED BAUD RATE ; EXIT: C = CNTLB VALUE, A=0/Z IFF SUCCESS ; ; DESIRED DIVISOR == CPUHZ / BAUD ; DUE TO ENCODING BAUD IS ALWAYS DIVISIBLE BY 75 ; Z180 DIVISOR IS ALWAYS A FACTOR OF 160 ; ; X = CPU_HZ / 160 / 75 ==> SIMPLIFIED ==> X = CPU_KHZ / 12 ; X = X / (BAUD / 75) ; IF X % 3 == 0, THEN (PS=1, X := X / 3) ELSE PS=0 ; IF X % 4 == 0, THEN (DR=1, X := X / 4) ELSE DR=0 ; SS := LOG2(X) ; ASCI_CNTLB: LD DE,1 ; USE DECODE CONSTANT OF 1 TO GET BAUD RATE ALREADY DIVIDED BY 75 CALL DECODE ; DECODE THE BAUDATE INTO DE:HL, DE IS DISCARDED ;CALL TSTPT RET NZ ; ABORT ON ERROR PUSH HL ; HL HAS (BAUD / 75), SAVE IT LD HL,(CB_CPUKHZ) ; GET CPU CLK IN KHZ ;LD HL,CPUKHZ ; CPU CLK IN KHZ ;LD HL,9216 ; *DEBUG* ; DUE TO THE LIMITED DIVISORS POSSIBLE WITH CNTLB, YOU PRETTY MUCH ; NEED TO USE A CPU SPEED THAT IS A MULTIPLE OF 128KHZ. BELOW, WE ; ATTEMPT TO ROUND THE CPU SPEED DETECTED TO A MULTIPLE OF 128KHZ ; WITH ROUNDING. THIS JUST MAXIMIZES POSSIBILITY OF SUCCESS COMPUTING ; THE DIVISOR. LD DE,$0040 ; HALF OF 128 IS 64 ADD HL,DE ; ADD FOR ROUNDING LD A,L ; MOVE TO ACCUM AND $80 ; STRIP LOW ORDER 7 BITS LD L,A ; ... AND PUT IT BACK LD DE,12 ; PREPARE TO DIVIDE BY 12 CALL DIV16 ; BC := (CPU_KHZ / 12), REM IN HL, ZF ;CALL TSTPT POP DE ; RESTORE (BAUD / 75) RET NZ ; ABORT IF REMAINDER PUSH BC ; MOVE WORKING VALUE POP HL ; ... BACK TO HL CALL DIV16 ; BC := X / (BAUD / 75) ;CALL TSTPT RET NZ ; ABORT IF REMAINDER ; ; DETERMINE PS BIT BY ATTEMPTING DIVIDE BY 3 PUSH BC ; SAVE WORKING VALUE ON STACK PUSH BC ; MOVE WORKING VALUE POP HL ; ... TO HL LD DE,3 ; SETUP TO DIVIDE BY 3 CALL DIV16 ; BC := X / 3, REM IN HL, ZF ;CALL TSTPT POP HL ; HL := PRIOR WORKING VALUE LD E,0 ; INIT E := 0 AS WORKING CNTLB VALUE JR NZ,ASCI_CNTLB1 ; DID NOT WORK, LEAVE PS==0, SKIP AHEAD SET 5,E ; SET PS BIT PUSH BC ; MOVE NEW WORKING POP HL ; ... VALUE TO HL ; ASCI_CNTLB1: ;CALL TSTPT ; DETERMINE DR BIT BY ATTEMPTING DIVIDE BY 4 LD A,L ; LOAD LSB OF WORKING VALUE AND $03 ; ISOLATE LOW ORDER BITS JR NZ,ASCI_CNTLB2 ; NOT DIVISIBLE BY 4, SKIP AHEAD SET 3,E ; SET PS BIT SRL H ; DIVIDE HL BY 4 RR L ; ... SRL H ; ... RR L ; ... ; ASCI_CNTLB2: ;CALL TSTPT ; DETERMINE SS BITS BY RIGHT SHIFTING AND INCREMENTING LD B,7 ; LOOP COUNTER, MAX VALUE OF SS IS 7 LD C,E ; MOVE WORKING CNTLB VALUE TO C ASCI_CNTLB3: BIT 0,L ; CAN WE SHIFT AGAIN? JR NZ,ASCI_CNTLB4 ; NOPE, DONE SRL H ; IMPLEMENT THE RR L ; ... SHIFT OPERATION INC C ; INCREMENT SS BITS DJNZ ASCI_CNTLB3 ; LOOP IF MORE SHIFTING POSSIBLE ; ; AT THIS POINT HL MUST BE EQUAL TO 1 OR WE FAILED! DEC HL ; IF HL == 1, SHOULD BECOME ZERO LD A,H ; TEST HL OR L ; ... FOR ZERO RET NZ ; ABORT IF NOT ZERO ; ASCI_CNTLB4: ;CALL TSTPT XOR A RET ;
firmware/bin/main.asm
bidhata/phison-2307-BadUSB
14
96124
;-------------------------------------------------------- ; File Created by SDCC : free open source ANSI-C Compiler ; Version 3.7.1 #10443 (MINGW64) ;-------------------------------------------------------- .module main .optsdcc -mmcs51 --model-small ;-------------------------------------------------------- ; Public variables in this module ;-------------------------------------------------------- .globl _SendKey_PARM_2 .globl _main .globl _SendKey .globl _DoUSBRelatedInit .globl _InitHardware .globl _HandleUSBEvents .globl _InitUSB .globl _InitTicks .globl _LEDBlink .globl _InitLED .globl _RI .globl _TI .globl _RB8 .globl _TB8 .globl _REN .globl _SM2 .globl _SM1 .globl _SM0 .globl _RXD .globl _TXD .globl _INT0 .globl _INT1 .globl _T0 .globl _T1 .globl _WR .globl _RD .globl _PX0 .globl _PT0 .globl _PX1 .globl _PT1 .globl _PS .globl _EX0 .globl _ET0 .globl _EX1 .globl _ET1 .globl _ES .globl _EA .globl _IT0 .globl _IE0 .globl _IT1 .globl _IE1 .globl _TR0 .globl _TF0 .globl _TR1 .globl _TF1 .globl _P .globl _OV .globl _RS0 .globl _RS1 .globl _F0 .globl _AC .globl _CY .globl _SBUF .globl _SCON .globl _IP .globl _IE .globl _TH1 .globl _TH0 .globl _TL1 .globl _TL0 .globl _TMOD .globl _TCON .globl _PCON .globl _DPH .globl _DPL .globl _SP .globl _B .globl _ACC .globl _PSW .globl _P3 .globl _P2 .globl _P1 .globl _P0 .globl _PRAMCTL .globl _BANK2PAH .globl _BANK2PAL .globl _BANK2VA .globl _BANK1PAH .globl _BANK1PAL .globl _BANK1VA .globl _BANK0PAH .globl _BANK0PAL .globl _WARMSTATUS .globl _GPIO0OUT .globl _GPIO0DIR .globl _DMACMD .globl _DMAFILL3 .globl _DMAFILL2 .globl _DMAFILL1 .globl _DMAFILL0 .globl _DMASIZEH .globl _DMASIZEM .globl _DMASIZEL .globl _DMADSTH .globl _DMADSTM .globl _DMADSTL .globl _DMASRCH .globl _DMASRCM .globl _DMASRCL .globl _NANDCSDIR .globl _NANDCSOUT .globl _EP4 .globl _EP3 .globl _EP2 .globl _EP1 .globl _EP0 .globl _SETUPDAT .globl _EP0CS .globl _EPIE .globl _EPIRQ .globl _USBIRQ .globl _USBSTAT .globl _USBCTL .globl _REGBANK .globl _wait_tick .globl _wait_counter .globl _send_keys_enabled .globl _key_index ;-------------------------------------------------------- ; special function registers ;-------------------------------------------------------- .area RSEG (ABS,DATA) .org 0x0000 _P0 = 0x0080 _P1 = 0x0090 _P2 = 0x00a0 _P3 = 0x00b0 _PSW = 0x00d0 _ACC = 0x00e0 _B = 0x00f0 _SP = 0x0081 _DPL = 0x0082 _DPH = 0x0083 _PCON = 0x0087 _TCON = 0x0088 _TMOD = 0x0089 _TL0 = 0x008a _TL1 = 0x008b _TH0 = 0x008c _TH1 = 0x008d _IE = 0x00a8 _IP = 0x00b8 _SCON = 0x0098 _SBUF = 0x0099 ;-------------------------------------------------------- ; special function bits ;-------------------------------------------------------- .area RSEG (ABS,DATA) .org 0x0000 _CY = 0x00d7 _AC = 0x00d6 _F0 = 0x00d5 _RS1 = 0x00d4 _RS0 = 0x00d3 _OV = 0x00d2 _P = 0x00d0 _TF1 = 0x008f _TR1 = 0x008e _TF0 = 0x008d _TR0 = 0x008c _IE1 = 0x008b _IT1 = 0x008a _IE0 = 0x0089 _IT0 = 0x0088 _EA = 0x00af _ES = 0x00ac _ET1 = 0x00ab _EX1 = 0x00aa _ET0 = 0x00a9 _EX0 = 0x00a8 _PS = 0x00bc _PT1 = 0x00bb _PX1 = 0x00ba _PT0 = 0x00b9 _PX0 = 0x00b8 _RD = 0x00b7 _WR = 0x00b6 _T1 = 0x00b5 _T0 = 0x00b4 _INT1 = 0x00b3 _INT0 = 0x00b2 _TXD = 0x00b1 _RXD = 0x00b0 _SM0 = 0x009f _SM1 = 0x009e _SM2 = 0x009d _REN = 0x009c _TB8 = 0x009b _RB8 = 0x009a _TI = 0x0099 _RI = 0x0098 ;-------------------------------------------------------- ; overlayable register banks ;-------------------------------------------------------- .area REG_BANK_0 (REL,OVR,DATA) .ds 8 ;-------------------------------------------------------- ; internal ram data ;-------------------------------------------------------- .area DSEG (DATA) _key_index:: .ds 2 _send_keys_enabled:: .ds 1 _wait_counter:: .ds 4 _wait_tick:: .ds 4 ;-------------------------------------------------------- ; overlayable items in internal ram ;-------------------------------------------------------- .area OSEG (OVR,DATA) _SendKey_PARM_2: .ds 1 ;-------------------------------------------------------- ; Stack segment in internal ram ;-------------------------------------------------------- .area SSEG __start__stack: .ds 1 ;-------------------------------------------------------- ; 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) _REGBANK = 0xf000 _USBCTL = 0xf008 _USBSTAT = 0xf009 _USBIRQ = 0xf027 _EPIRQ = 0xf020 _EPIE = 0xf030 _EP0CS = 0xf048 _SETUPDAT = 0xf0b8 _EP0 = 0xf1c0 _EP1 = 0xf200 _EP2 = 0xf240 _EP3 = 0xf280 _EP4 = 0xf2c0 _NANDCSOUT = 0xf608 _NANDCSDIR = 0xf618 _DMASRCL = 0xf900 _DMASRCM = 0xf901 _DMASRCH = 0xf902 _DMADSTL = 0xf904 _DMADSTM = 0xf905 _DMADSTH = 0xf906 _DMASIZEL = 0xf908 _DMASIZEM = 0xf909 _DMASIZEH = 0xf90a _DMAFILL0 = 0xf90c _DMAFILL1 = 0xf90d _DMAFILL2 = 0xf90e _DMAFILL3 = 0xf90f _DMACMD = 0xf930 _GPIO0DIR = 0xfa14 _GPIO0OUT = 0xfa15 _WARMSTATUS = 0xfa38 _BANK0PAL = 0xfa40 _BANK0PAH = 0xfa41 _BANK1VA = 0xfa42 _BANK1PAL = 0xfa43 _BANK1PAH = 0xfa44 _BANK2VA = 0xfa45 _BANK2PAL = 0xfa46 _BANK2PAH = 0xfa47 _PRAMCTL = 0xfa48 ;-------------------------------------------------------- ; 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) ;-------------------------------------------------------- ; interrupt vector ;-------------------------------------------------------- .area HOME (CODE) __interrupt_vect: ljmp __sdcc_gsinit_startup ljmp _usb_isr .ds 5 ljmp _tmr0isr .ds 5 ljmp _ep_isr .ds 5 ljmp _tmr1isr .ds 5 ljmp _com0isr ;-------------------------------------------------------- ; global & static initialisations ;-------------------------------------------------------- .area HOME (CODE) .area GSINIT (CODE) .area GSFINAL (CODE) .area GSINIT (CODE) .globl __sdcc_gsinit_startup .globl __sdcc_program_startup .globl __start__stack .globl __mcs51_genXINIT .globl __mcs51_genXRAMCLEAR .globl __mcs51_genRAMCLEAR ; main.c:20: int key_index = 0; clr a mov _key_index,a mov (_key_index + 1),a ; main.c:21: volatile BYTE send_keys_enabled = 0; ; 1-genFromRTrack replaced mov _send_keys_enabled,#0x00 mov _send_keys_enabled,a ; main.c:22: DWORD wait_counter = KEY_DELAY; mov _wait_counter,a mov (_wait_counter + 1),#0x20 mov (_wait_counter + 2),a mov (_wait_counter + 3),a .area GSFINAL (CODE) ljmp __sdcc_program_startup ;-------------------------------------------------------- ; Home ;-------------------------------------------------------- .area HOME (CODE) .area HOME (CODE) __sdcc_program_startup: ljmp _main ; return from main will return to caller ;-------------------------------------------------------- ; code ;-------------------------------------------------------- .area CSEG (CODE) ;------------------------------------------------------------ ;Allocation info for local variables in function 'InitHardware' ;------------------------------------------------------------ ; main.c:25: void InitHardware() ; ----------------------------------------- ; function InitHardware ; ----------------------------------------- _InitHardware: ar7 = 0x07 ar6 = 0x06 ar5 = 0x05 ar4 = 0x04 ar3 = 0x03 ar2 = 0x02 ar1 = 0x01 ar0 = 0x00 ; main.c:28: BANK0PAL = BANK0_PA>>9; mov dptr,#_BANK0PAL mov a,#0x40 movx @dptr,a ; main.c:29: BANK0PAH = BANK0_PA>>17; mov dptr,#_BANK0PAH clr a movx @dptr,a ; main.c:30: BANK1VA = BANK1_VA>>8; mov dptr,#_BANK1VA mov a,#0x40 movx @dptr,a ; main.c:31: BANK1PAL = BANK1_PA>>9; mov dptr,#_BANK1PAL mov a,#0x60 movx @dptr,a ; main.c:32: BANK1PAH = BANK1_PA>>17; mov dptr,#_BANK1PAH clr a movx @dptr,a ; main.c:33: BANK2VA = BANK2_VA>>8; mov dptr,#_BANK2VA mov a,#0x60 movx @dptr,a ; main.c:34: BANK2PAL = BANK2_PA>>9; mov dptr,#_BANK2PAL mov a,#0x70 movx @dptr,a ; main.c:35: BANK2PAH = BANK2_PA>>17; mov dptr,#_BANK2PAH clr a movx @dptr,a ; main.c:208: __endasm; .db 0x90 .db 0xF8 .db 0x0A .db 0x74 .db 0x1F .db 0xF0 .db 0x90 .db 0xF8 .db 0x0E .db 0xE4 .db 0xF0 .db 0x90 .db 0xF8 .db 0x09 .db 0x74 .db 0x2C .db 0xF0 .db 0x90 .db 0xF8 .db 0x10 .db 0x74 .db 0x80 .db 0xF0 .db 0xA3 .db 0xE4 .db 0xF0 .db 0x90 .db 0xF0 .db 0x09 .db 0xE0 .db 0x54 .db 0x07 .db 0x64 .db 0x04 jnz HELL .db 0x90 .db 0xFA .db 0x60 .db 0xE4 .db 0xF0 .db 0xA3 .db 0x74 .db 0x0F .db 0xF0 .db 0xA3 .db 0xF0 .db 0x90 .db 0xFA .db 0x64 .db 0x74 .db 0x08 .db 0xF0 .db 0xA3 .db 0x04 .db 0xF0 .db 0xA3 .db 0x14 .db 0xF0 .db 0xA3 .db 0x04 .db 0xF0 sjmp HEAVEN HELL: .db 0x90 .db 0xFA .db 0x60 .db 0xE4 .db 0xF0 .db 0xA3 .db 0x74 .db 0x0F .db 0xF0 .db 0xA3 .db 0xF0 .db 0x90 .db 0xFA .db 0x64 .db 0x74 .db 0x02 .db 0xF0 .db 0xA3 .db 0xF0 .db 0xA3 .db 0xF0 .db 0xA3 .db 0xF0 HEAVEN: .db 0x90 .db 0xFF .db 0x00 .db 0xE0 .db 0x54 .db 0xFB .db 0xF0 .db 0xE0 .db 0x44 .db 0x04 .db 0xF0 .db 0xE0 .db 0x44 .db 0x10 .db 0xF0 .db 0xE0 .db 0x54 .db 0xFC .db 0xF0 .db 0x90 .db 0xFF .db 0x03 .db 0x74 .db 0xC1 .db 0xF0 .db 0x90 .db 0xFF .db 0x0C .db 0xE0 .db 0x30 .db 0xE0 .db 0xF9 .db 0x90 .db 0xFF .db 0x13 .db 0xE0 .db 0x54 .db 0xFE .db 0xF0 .db 0x90 .db 0xFF .db 0x0C .db 0xE0 .db 0x20 .db 0xE1 .db 0x07 .db 0x90 .db 0xFF .db 0x13 .db 0xE0 .db 0x44 .db 0x10 .db 0xF0 .db 0x90 .db 0xFA .db 0x6F .db 0xE0 .db 0x44 .db 0x1D .db 0xF0 .db 0x90 .db 0xFA .db 0x14 .db 0xE0 .db 0x54 .db 0xFD .db 0xF0 .db 0xA3 .db 0xE0 .db 0x44 .db 0x02 .db 0xF0 .db 0x90 .db 0xFA .db 0x21 .db 0x74 .db 0x07 .db 0xF0 .db 0x90 .db 0xFA .db 0x20 .db 0xE4 .db 0xF0 ; main.c:210: XVAL(0xFA68) &= 0xF7; mov dptr,#0xfa68 movx a,@dptr anl a,#0xf7 movx @dptr,a ; main.c:211: XVAL(0xFA69) &= 0xF7; mov dptr,#0xfa69 movx a,@dptr anl a,#0xf7 movx @dptr,a ; main.c:212: XVAL(0xFA6A) &= 0xF7; mov dptr,#0xfa6a movx a,@dptr anl a,#0xf7 movx @dptr,a ; main.c:213: XVAL(0xFA6B) &= 0xF7; mov dptr,#0xfa6b movx a,@dptr anl a,#0xf7 movx @dptr,a ; main.c:215: TMOD = 0x11; mov _TMOD,#0x11 ; main.c:216: TH0 = 0xF0; mov _TH0,#0xf0 ; main.c:217: TL0 = 0x5F; mov _TL0,#0x5f ; main.c:218: TH1 = 0xF0; mov _TH1,#0xf0 ; main.c:219: TL1 = 0x5F; mov _TL1,#0x5f ; main.c:220: IP = 1; mov _IP,#0x01 ; main.c:221: TCON = 0x10; mov _TCON,#0x10 ; main.c:222: SCON = 0; mov _SCON,#0x00 ; main.c:223: IE = 0x80; mov _IE,#0x80 ; main.c:224: } ret ;------------------------------------------------------------ ;Allocation info for local variables in function 'DoUSBRelatedInit' ;------------------------------------------------------------ ; main.c:226: void DoUSBRelatedInit() ; ----------------------------------------- ; function DoUSBRelatedInit ; ----------------------------------------- _DoUSBRelatedInit: ; main.c:228: if (WARMSTATUS & 2) mov dptr,#_WARMSTATUS movx a,@dptr jnb acc.1,00102$ ; main.c:230: return; ret 00102$: ; main.c:233: REGBANK = 5; mov dptr,#_REGBANK mov a,#0x05 movx @dptr,a ; main.c:419: __endasm; .db 0x90 .db 0xF2 .db 0x00 .db 0xE0 .db 0x54 .db 0xFE .db 0xF0 .db 0x90 .db 0xF0 .db 0x00 .db 0x74 .db 0x05 .db 0xF0 .db 0x90 .db 0xF2 .db 0x13 .db 0x74 .db 0x30 .db 0xF0 .db 0x90 .db 0x6C .db 0xD1 .db 0xE0 .db 0xFF .db 0x70 .db 0x0C .db 0x90 .db 0x6C .db 0xD0 .db 0xE0 .db 0x70 .db 0x06 .db 0x90 .db 0x6C .db 0xD2 .db 0xE0 .db 0x60 .db 0x1B .db 0x90 .db 0x6C .db 0xD2 .db 0xE0 .db 0x90 .db 0xF2 .db 0x14 .db 0xF0 .db 0x90 .db 0x6C .db 0xD0 .db 0xE0 .db 0x90 .db 0xF2 .db 0x15 .db 0xF0 .db 0xA3 .db 0xE0 .db 0x4F .db 0xF0 .db 0x90 .db 0xF2 .db 0x13 .db 0xE0 .db 0x54 .db 0xEF .db 0xF0 .db 0x90 .db 0x6C .db 0xD4 .db 0xE0 .db 0xFF .db 0x70 .db 0x0C .db 0x90 .db 0x6C .db 0xD3 .db 0xE0 .db 0x70 .db 0x06 .db 0x90 .db 0x6C .db 0xD5 .db 0xE0 .db 0x60 .db 0x36 .db 0x90 .db 0xF2 .db 0x13 .db 0xE0 .db 0x4F .db 0xF0 .db 0x90 .db 0x6C .db 0xD3 .db 0xE0 .db 0xFE .db 0x90 .db 0xF2 .db 0x12 .db 0xF0 .db 0x90 .db 0x6C .db 0xD5 .db 0xE0 .db 0x90 .db 0xF2 .db 0x11 .db 0xF0 .db 0xEE .db 0x24 .db 0x9A .db 0x90 .db 0xF2 .db 0x17 .db 0xF0 .db 0xA3 .db 0xE0 .db 0x54 .db 0xF0 .db 0xF0 .db 0xE0 .db 0x4F .db 0xF0 .db 0x90 .db 0x6C .db 0xD3 .db 0xE0 .db 0xC3 .db 0x94 .db 0x66 .db 0x50 .db 0x07 .db 0x90 .db 0xF2 .db 0x18 .db 0xE0 .db 0x44 .db 0x0F .db 0xF0 .db 0x90 .db 0xF2 .db 0x28 .db 0x74 .db 0x24 .db 0xF0 .db 0x90 .db 0xF2 .db 0x10 .db 0xE0 .db 0x54 .db 0xF7 .db 0xF0 .db 0x90 .db 0xF0 .db 0x00 .db 0xE4 .db 0xF0 .db 0x90 .db 0xF0 .db 0x14 .db 0xE0 .db 0x54 .db 0xBF .db 0xF0 .db 0x90 .db 0xFA .db 0x6F .db 0xE0 .db 0x44 .db 0x10 .db 0xF0 .db 0x90 .db 0xF0 .db 0x14 .db 0xE0 .db 0x54 .db 0x03 .db 0x60 .db 0xF8 .db 0x90 .db 0xFA .db 0x6B .db 0x74 .db 0xFF .db 0xF0 ; main.c:420: } ret ;------------------------------------------------------------ ;Allocation info for local variables in function 'SendKey' ;------------------------------------------------------------ ;modifiers Allocated with name '_SendKey_PARM_2' ;code Allocated to registers r7 ;i Allocated to registers r6 r7 ;------------------------------------------------------------ ; main.c:422: void SendKey(BYTE code, BYTE modifiers) ; ----------------------------------------- ; function SendKey ; ----------------------------------------- _SendKey: mov r7,dpl ; main.c:426: EP3.cs = 0; mov dptr,#(_EP3 + 0x0013) clr a movx @dptr,a ; main.c:427: while (EP3.cs & 0x40); 00101$: mov dptr,#(_EP3 + 0x0013) movx a,@dptr mov r6,a jb acc.6,00101$ ; main.c:429: EP3.fifo = modifiers; ; main.c:430: EP3.fifo = 0; ; main.c:431: EP3.fifo = code; mov dptr,#(_EP3 + 0x001c) mov a,_SendKey_PARM_2 movx @dptr,a clr a movx @dptr,a mov a,r7 movx @dptr,a ; main.c:432: for (i = 0; i < 5; i++) mov r6,#0x00 mov r7,#0x00 00105$: ; main.c:434: EP3.fifo = 0; mov dptr,#(_EP3 + 0x001c) clr a movx @dptr,a ; main.c:432: for (i = 0; i < 5; i++) inc r6 cjne r6,#0x00,00127$ inc r7 00127$: clr c mov a,r6 subb a,#0x05 mov a,r7 xrl a,#0x80 subb a,#0x80 jc 00105$ ; main.c:437: EP3.len_l = 8; mov dptr,#(_EP3 + 0x000c) mov a,#0x08 movx @dptr,a ; main.c:438: EP3.len_m = 0; mov dptr,#(_EP3 + 0x000d) clr a movx @dptr,a ; main.c:439: EP3.len_h = 0; mov dptr,#(_EP3 + 0x000e) movx @dptr,a ; main.c:440: EP3.cs = 0x40; mov dptr,#(_EP3 + 0x0013) mov a,#0x40 movx @dptr,a ; main.c:441: } ret ;------------------------------------------------------------ ;Allocation info for local variables in function 'main' ;------------------------------------------------------------ ; main.c:443: void main() ; ----------------------------------------- ; function main ; ----------------------------------------- _main: ; main.c:445: InitHardware(); lcall _InitHardware ; main.c:446: DoUSBRelatedInit(); lcall _DoUSBRelatedInit ; main.c:447: InitUSB(); lcall _InitUSB ; main.c:448: InitTicks(); lcall _InitTicks ; main.c:449: InitLED(); lcall _InitLED ; main.c:450: LEDBlink(); lcall _LEDBlink ; main.c:452: while (1) 00114$: ; main.c:454: HandleUSBEvents(); lcall _HandleUSBEvents ; main.c:456: if (wait_tick++ >= KEY_DELAY) mov r4,_wait_tick mov r5,(_wait_tick + 1) mov r6,(_wait_tick + 2) mov r7,(_wait_tick + 3) inc _wait_tick clr a cjne a,_wait_tick,00146$ inc (_wait_tick + 1) cjne a,(_wait_tick + 1),00146$ inc (_wait_tick + 2) cjne a,(_wait_tick + 2),00146$ inc (_wait_tick + 3) 00146$: clr c mov a,r5 subb a,#0x20 mov a,r6 subb a,#0x00 mov a,r7 subb a,#0x00 ; main.c:458: if (wait_counter < KEY_DELAY) jc 00104$ mov a,(_wait_counter + 1) subb a,#0x20 mov a,(_wait_counter + 2) subb a,#0x00 mov a,(_wait_counter + 3) subb a,#0x00 jnc 00104$ ; main.c:460: wait_counter++; inc _wait_counter clr a cjne a,_wait_counter,00149$ inc (_wait_counter + 1) cjne a,(_wait_counter + 1),00149$ inc (_wait_counter + 2) cjne a,(_wait_counter + 2),00149$ inc (_wait_counter + 3) 00149$: 00104$: ; main.c:464: if (send_keys_enabled && wait_counter >= KEY_DELAY) mov a,_send_keys_enabled jz 00114$ clr c mov a,(_wait_counter + 1) subb a,#0x20 mov a,(_wait_counter + 2) subb a,#0x00 mov a,(_wait_counter + 3) subb a,#0x00 jc 00114$ ; main.c:466: if (keyData[key_index]) mov a,_key_index add a,#_keyData mov r6,a mov a,(_key_index + 1) addc a,#(_keyData >> 8) mov r7,a mov dpl,r6 mov dph,r7 clr a movc a,@a+dptr jz 00106$ ; main.c:469: SendKey(0x00, 0x00); mov _SendKey_PARM_2,#0x00 mov dpl,#0x00 lcall _SendKey ; main.c:470: SendKey(0x00, 0x00); mov _SendKey_PARM_2,#0x00 mov dpl,#0x00 lcall _SendKey ; main.c:471: SendKey(0x00, 0x00); mov _SendKey_PARM_2,#0x00 mov dpl,#0x00 lcall _SendKey ; main.c:472: SendKey(0x00, 0x00); mov _SendKey_PARM_2,#0x00 mov dpl,#0x00 lcall _SendKey ; main.c:473: SendKey(keyData[key_index], keyData[key_index + 1]); mov a,_key_index add a,#_keyData mov dpl,a mov a,(_key_index + 1) addc a,#(_keyData >> 8) mov dph,a clr a movc a,@a+dptr mov r7,a mov a,#0x01 add a,_key_index mov r5,a clr a addc a,(_key_index + 1) mov r6,a mov a,r5 add a,#_keyData mov dpl,a mov a,r6 addc a,#(_keyData >> 8) mov dph,a clr a movc a,@a+dptr mov _SendKey_PARM_2,a mov dpl,r7 lcall _SendKey ; main.c:474: SendKey(0x00, 0x00); mov _SendKey_PARM_2,#0x00 mov dpl,#0x00 lcall _SendKey sjmp 00107$ 00106$: ; main.c:479: wait_counter = 0; clr a mov _wait_counter,a mov (_wait_counter + 1),a mov (_wait_counter + 2),a mov (_wait_counter + 3),a ; main.c:480: wait_tick = 0; mov _wait_tick,a mov (_wait_tick + 1),a mov (_wait_tick + 2),a mov (_wait_tick + 3),a 00107$: ; main.c:484: key_index += 2; mov a,#0x02 add a,_key_index mov _key_index,a clr a addc a,(_key_index + 1) ; main.c:487: if (key_index >= sizeof(keyData)) mov (_key_index + 1),a clr c xrl a,#0x80 subb a,#0xa0 jnc 00153$ ljmp 00114$ 00153$: ; main.c:489: send_keys_enabled = 0; mov _send_keys_enabled,#0x00 ; main.c:493: } ljmp 00114$ .area CSEG (CODE) .area CONST (CODE) _keyData: .db #0x12 ; 18 .db #0x34 ; 52 '4' .db #0x56 ; 86 'V' .db #0x78 ; 120 'x' .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .db 0x00 .area XINIT (CODE) .area CABS (ABS,CODE)