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 |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
73b8aa1222d9b6175eb735ea8f69bad7639ddd87 | 8,923 | asm | Assembly | Transynther/x86/_processed/NC/_st_zr_un_/i3-7100_9_0x84_notsx.log_21829_1227.asm | ljhsiun2/medusa | 67d769b8a2fb42c538f10287abaf0e6dbb463f0c | [
"MIT"
] | 9 | 2020-08-13T19:41:58.000Z | 2022-03-30T12:22:51.000Z | Transynther/x86/_processed/NC/_st_zr_un_/i3-7100_9_0x84_notsx.log_21829_1227.asm | ljhsiun2/medusa | 67d769b8a2fb42c538f10287abaf0e6dbb463f0c | [
"MIT"
] | 1 | 2021-04-29T06:29:35.000Z | 2021-05-13T21:02:30.000Z | Transynther/x86/_processed/NC/_st_zr_un_/i3-7100_9_0x84_notsx.log_21829_1227.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 %r9
push %rcx
push %rdi
push %rdx
push %rsi
lea addresses_A_ht+0x67e6, %rsi
lea addresses_UC_ht+0x8e46, %rdi
clflush (%rdi)
xor %r9, %r9
mov $123, %rcx
rep movsl
nop
and %rdi, %rdi
lea addresses_normal_ht+0x2752, %rdx
nop
nop
nop
nop
sub %r11, %r11
movb $0x61, (%rdx)
nop
and %rdx, %rdx
lea addresses_WT_ht+0xb112, %rsi
lea addresses_A_ht+0xf746, %rdi
nop
nop
sub %r15, %r15
mov $20, %rcx
rep movsw
nop
nop
nop
sub $14494, %rsi
lea addresses_normal_ht+0x13c36, %rsi
lea addresses_normal_ht+0x146, %rdi
nop
xor %r12, %r12
mov $59, %rcx
rep movsw
nop
nop
nop
nop
nop
and %r9, %r9
lea addresses_WC_ht+0xea06, %rsi
lea addresses_UC_ht+0x1fe6, %rdi
nop
nop
nop
nop
nop
add $30361, %r11
mov $42, %rcx
rep movsw
sub $24762, %rcx
lea addresses_normal_ht+0x1b606, %r11
cmp $7466, %r15
vmovups (%r11), %ymm2
vextracti128 $1, %ymm2, %xmm2
vpextrq $1, %xmm2, %rdx
nop
add %r15, %r15
lea addresses_WC_ht+0x4b36, %rsi
lea addresses_WC_ht+0xf346, %rdi
nop
inc %r12
mov $64, %rcx
rep movsq
nop
add %r11, %r11
lea addresses_A_ht+0xe572, %rsi
lea addresses_A_ht+0x3486, %rdi
cmp %r11, %r11
mov $105, %rcx
rep movsb
nop
nop
nop
nop
xor $33632, %rdx
lea addresses_A_ht+0x1ad17, %rsi
lea addresses_normal_ht+0xdb46, %rdi
nop
nop
nop
nop
cmp $27645, %r12
mov $29, %rcx
rep movsl
nop
nop
nop
nop
add $61047, %rdx
lea addresses_A_ht+0xcd46, %rcx
clflush (%rcx)
nop
nop
add %r15, %r15
mov $0x6162636465666768, %rsi
movq %rsi, (%rcx)
nop
cmp %r12, %r12
lea addresses_WC_ht+0x104e6, %rsi
clflush (%rsi)
nop
nop
nop
nop
xor $53309, %r9
movw $0x6162, (%rsi)
nop
xor %rsi, %rsi
lea addresses_WC_ht+0xe86, %rdi
nop
nop
and %rsi, %rsi
movb $0x61, (%rdi)
nop
nop
and $15082, %r12
lea addresses_A_ht+0xea36, %rsi
lea addresses_WC_ht+0x16346, %rdi
clflush (%rsi)
nop
nop
nop
cmp $13716, %r11
mov $36, %rcx
rep movsb
sub %rsi, %rsi
lea addresses_A_ht+0x1bc96, %rsi
lea addresses_A_ht+0x946, %rdi
nop
nop
nop
nop
nop
xor %r12, %r12
mov $93, %rcx
rep movsq
nop
nop
nop
nop
nop
add $57736, %rcx
lea addresses_WC_ht+0x13346, %rdx
nop
nop
nop
nop
nop
sub %r15, %r15
mov (%rdx), %r9d
nop
nop
nop
nop
nop
add $64348, %r12
pop %rsi
pop %rdx
pop %rdi
pop %rcx
pop %r9
pop %r15
pop %r12
pop %r11
ret
.global s_faulty_load
s_faulty_load:
push %r11
push %r8
push %rax
push %rbp
push %rcx
push %rdi
push %rsi
// Store
lea addresses_D+0x1c19a, %r11
nop
nop
add %rdi, %rdi
mov $0x5152535455565758, %rax
movq %rax, (%r11)
nop
nop
nop
nop
nop
and %r8, %r8
// REPMOV
lea addresses_WC+0x3531, %rsi
lea addresses_A+0x42c6, %rdi
nop
nop
nop
nop
nop
add $42663, %r11
mov $102, %rcx
rep movsl
nop
nop
inc %r11
// Store
mov $0x26a, %r11
nop
nop
cmp $24666, %r8
mov $0x5152535455565758, %rax
movq %rax, (%r11)
// Exception!!!
mov (0), %rcx
nop
add %r8, %r8
// Faulty Load
mov $0xd340e0000000346, %r8
nop
nop
nop
add %rbp, %rbp
mov (%r8), %rsi
lea oracles, %r11
and $0xff, %rsi
shlq $12, %rsi
mov (%r11,%rsi,1), %rsi
pop %rsi
pop %rdi
pop %rcx
pop %rbp
pop %rax
pop %r8
pop %r11
ret
/*
<gen_faulty_load>
[REF]
{'src': {'type': 'addresses_NC', 'same': False, 'size': 2, 'congruent': 0, 'NT': False, 'AVXalign': False}, 'OP': 'LOAD'}
{'dst': {'type': 'addresses_D', 'same': False, 'size': 8, 'congruent': 1, 'NT': True, 'AVXalign': False}, 'OP': 'STOR'}
{'src': {'type': 'addresses_WC', 'congruent': 0, 'same': False}, 'dst': {'type': 'addresses_A', 'congruent': 6, 'same': False}, 'OP': 'REPM'}
{'dst': {'type': 'addresses_P', 'same': False, 'size': 8, 'congruent': 2, 'NT': False, 'AVXalign': False}, 'OP': 'STOR'}
[Faulty Load]
{'src': {'type': 'addresses_NC', 'same': True, 'size': 8, 'congruent': 0, 'NT': False, 'AVXalign': False}, 'OP': 'LOAD'}
<gen_prepare_buffer>
{'src': {'type': 'addresses_A_ht', 'congruent': 2, 'same': False}, 'dst': {'type': 'addresses_UC_ht', 'congruent': 7, 'same': False}, 'OP': 'REPM'}
{'dst': {'type': 'addresses_normal_ht', 'same': True, 'size': 1, 'congruent': 0, 'NT': False, 'AVXalign': False}, 'OP': 'STOR'}
{'src': {'type': 'addresses_WT_ht', 'congruent': 1, 'same': False}, 'dst': {'type': 'addresses_A_ht', 'congruent': 10, 'same': False}, 'OP': 'REPM'}
{'src': {'type': 'addresses_normal_ht', 'congruent': 4, 'same': False}, 'dst': {'type': 'addresses_normal_ht', 'congruent': 7, 'same': False}, 'OP': 'REPM'}
{'src': {'type': 'addresses_WC_ht', 'congruent': 6, 'same': False}, 'dst': {'type': 'addresses_UC_ht', 'congruent': 4, 'same': False}, 'OP': 'REPM'}
{'src': {'type': 'addresses_normal_ht', 'same': False, 'size': 32, 'congruent': 5, 'NT': False, 'AVXalign': False}, 'OP': 'LOAD'}
{'src': {'type': 'addresses_WC_ht', 'congruent': 3, 'same': True}, 'dst': {'type': 'addresses_WC_ht', 'congruent': 7, 'same': False}, 'OP': 'REPM'}
{'src': {'type': 'addresses_A_ht', 'congruent': 2, 'same': True}, 'dst': {'type': 'addresses_A_ht', 'congruent': 5, 'same': False}, 'OP': 'REPM'}
{'src': {'type': 'addresses_A_ht', 'congruent': 0, 'same': False}, 'dst': {'type': 'addresses_normal_ht', 'congruent': 11, 'same': False}, 'OP': 'REPM'}
{'dst': {'type': 'addresses_A_ht', 'same': True, 'size': 8, 'congruent': 9, 'NT': False, 'AVXalign': False}, 'OP': 'STOR'}
{'dst': {'type': 'addresses_WC_ht', 'same': False, 'size': 2, 'congruent': 3, 'NT': False, 'AVXalign': False}, 'OP': 'STOR'}
{'dst': {'type': 'addresses_WC_ht', 'same': False, 'size': 1, 'congruent': 6, 'NT': False, 'AVXalign': False}, 'OP': 'STOR'}
{'src': {'type': 'addresses_A_ht', 'congruent': 4, 'same': False}, 'dst': {'type': 'addresses_WC_ht', 'congruent': 10, 'same': False}, 'OP': 'REPM'}
{'src': {'type': 'addresses_A_ht', 'congruent': 4, 'same': False}, 'dst': {'type': 'addresses_A_ht', 'congruent': 9, 'same': False}, 'OP': 'REPM'}
{'src': {'type': 'addresses_WC_ht', 'same': False, 'size': 4, 'congruent': 11, 'NT': False, 'AVXalign': False}, 'OP': 'LOAD'}
{'ec': 1, '1a': 1106, 'd0': 1, '28': 2, '0a': 1, 'e0': 4, 'b8': 2, '55': 1, '00': 20675, '58': 4, '38': 24, 'be': 8}
00 00 00 00 00 00 00 00 00 1a 00 00 00 00 00 00 00 1a 00 00 00 00 00 00 00 00 00 1a 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 1a 00 00 00 00 1a 00 00 00 00 1a 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 1a 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 1a 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 1a 00 00 00 00 1a 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 1a 00 00 00 00 1a 00 00 00 00 00 00 00 1a 00 00 00 00 00 00 00 00 00 00 1a 00 00 00 00 00 00 00 1a 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 1a 00 00 00 00 00 00 00 00 00 00 1a 00 00 00 00 00 00 00 00 00 00 1a 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 1a 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 1a 00 00 00 00 1a 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 1a 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 1a 00 1a 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 1a 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 1a 00 00 00 00 00 00 00 00 00 00 00 00 00 00 1a 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 1a 00 00 00 00 00 00 00 1a 00 1a 00 00 00 00 1a 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 1a 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 1a 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 1a 00 1a 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 1a 00 00 00 00 00 00 00 1a 00 00 00 00 00 00 00 1a 00 00 1a 00 00 00 00 00 00 00 1a 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 1a 00 00 00 00 00 00 00 1a 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 1a 00 00 00 00 00 00 00 00 00 1a 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 1a 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 1a 00 00 00 00 00 00 00 1a 00 00 00 00 00 00 00 1a 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 1a 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 1a 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 1a 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 1a 00 00 00 00 00 00 00 1a 00 00 00 00 00 00 00 1a 00 00 00 00 00 00 00 00 00 00 1a 00 00 00 00 00 00 00 00
*/
| 32.097122 | 2,999 | 0.653256 |
6165554bd132635b7e73b325ee8c4834448b5c49 | 600 | asm | Assembly | 8BitSub.asm | MBadriNarayanan/MASM | e81b5821695c42fa2904e6c877f24d1135c648b3 | [
"MIT"
] | null | null | null | 8BitSub.asm | MBadriNarayanan/MASM | e81b5821695c42fa2904e6c877f24d1135c648b3 | [
"MIT"
] | null | null | null | 8BitSub.asm | MBadriNarayanan/MASM | e81b5821695c42fa2904e6c877f24d1135c648b3 | [
"MIT"
] | null | null | null | CR EQU 0DH
LF EQU 0AH
DATA SEGMENT
TABLE DB '0123456789ABCDEF'
NUMBER1 DB 099H
NUMBER2 DB 099H
RESULT DB 00H
MESSAGE DB ' THE RESULT IS'
ASCIIRESULT DB 2 DUP(?)
DB CR, LF, '$'
DATA ENDS
CODE SEGMENT
ASSUME CS:CODE, DS: DATA
START: MOV AX, DATA
MOV DS, AX
MOV AL, NUMBER1
SUB AL, NUMBER2
DAS
MOV RESULT, AL
LEA BX,TABLE
LEA SI, ASCIIRESULT
INC SI
MOV AL, RESULT
AND AL,00FH
XLAT
MOV [SI], AL
DEC SI
MOV AL, RESULT
AND AL,0F0H
MOV CL,04H
SHR AL, CL
XLAT
MOV [SI], AL
MOV AH,09H
LEA DX, ASCIIRESULT
INT 21H
QUIT: MOV AL,0
MOV AH,04CH
INT 21H
CODE ENDS
END START
| 14.285714 | 28 | 0.683333 |
548d3e51d3819da9d5ab02c359cf9576d0605d53 | 547 | asm | Assembly | programs/oeis/001/A001816.asm | jmorken/loda | 99c09d2641e858b074f6344a352d13bc55601571 | [
"Apache-2.0"
] | 1 | 2021-03-15T11:38:20.000Z | 2021-03-15T11:38:20.000Z | programs/oeis/001/A001816.asm | jmorken/loda | 99c09d2641e858b074f6344a352d13bc55601571 | [
"Apache-2.0"
] | null | null | null | programs/oeis/001/A001816.asm | jmorken/loda | 99c09d2641e858b074f6344a352d13bc55601571 | [
"Apache-2.0"
] | null | null | null | ; A001816: Coefficients of x^n in Hermite polynomial H_{n+4}
; 12,120,720,3360,13440,48384,161280,506880,1520640,4392960,12300288,33546240,89456640,233963520,601620480,1524105216,3810263040,9413591040,23011000320,55710842880,133706022912,318347673600,752458137600,1766640844800,4122161971200,9563415773184,22069421015040,50677929738240,115835267973120,263625092628480,597550209957888,1349306925711360,3035940582850560,6807866761543680
add $0,4
mov $3,2
pow $3,$0
bin $0,4
mov $2,$3
lpb $2
mul $0,$2
mod $2,5
lpe
mov $1,$0
div $1,16
mul $1,12
| 34.1875 | 373 | 0.809872 |
5c39fa418f361725b771074aa38999bdbc278423 | 5,485 | asm | Assembly | Transynther/x86/_processed/NONE/_zr_/i9-9900K_12_0xca.log_21829_330.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_0xca.log_21829_330.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_0xca.log_21829_330.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 %r13
push %r14
push %r8
push %rcx
push %rdi
lea addresses_WC_ht+0x1ac32, %r11
xor $16210, %rcx
movups (%r11), %xmm4
vpextrq $1, %xmm4, %r8
nop
nop
add %rdi, %rdi
lea addresses_WT_ht+0x1e122, %r14
clflush (%r14)
nop
nop
lfence
movl $0x61626364, (%r14)
cmp $24400, %r11
lea addresses_WC_ht+0x2772, %r12
nop
nop
add %rdi, %rdi
movups (%r12), %xmm3
vpextrq $1, %xmm3, %r11
nop
nop
add $30016, %rdi
lea addresses_D_ht+0x1a522, %r14
nop
nop
nop
nop
dec %r13
movw $0x6162, (%r14)
nop
nop
nop
nop
sub $33619, %r11
lea addresses_WC_ht+0x3732, %r13
nop
xor %rcx, %rcx
movups (%r13), %xmm0
vpextrq $0, %xmm0, %r11
and $37819, %r13
lea addresses_WC_ht+0xee66, %r13
nop
nop
nop
nop
cmp $46228, %r8
movl $0x61626364, (%r13)
nop
nop
add %r14, %r14
pop %rdi
pop %rcx
pop %r8
pop %r14
pop %r13
pop %r12
pop %r11
ret
.global s_faulty_load
s_faulty_load:
push %r11
push %r8
push %r9
push %rax
push %rdx
// Load
lea addresses_UC+0x6562, %r11
sub $19506, %r9
movups (%r11), %xmm5
vpextrq $0, %xmm5, %rdx
cmp %rdx, %rdx
// Faulty Load
lea addresses_UC+0x10032, %rdx
nop
nop
nop
nop
and $47807, %r11
movb (%rdx), %al
lea oracles, %r9
and $0xff, %rax
shlq $12, %rax
mov (%r9,%rax,1), %rax
pop %rdx
pop %rax
pop %r9
pop %r8
pop %r11
ret
/*
<gen_faulty_load>
[REF]
{'OP': 'LOAD', 'src': {'size': 1, 'NT': False, 'type': 'addresses_UC', 'same': False, 'AVXalign': False, 'congruent': 0}}
{'OP': 'LOAD', 'src': {'size': 16, 'NT': False, 'type': 'addresses_UC', 'same': False, 'AVXalign': False, 'congruent': 4}}
[Faulty Load]
{'OP': 'LOAD', 'src': {'size': 1, 'NT': False, 'type': 'addresses_UC', 'same': True, 'AVXalign': False, 'congruent': 0}}
<gen_prepare_buffer>
{'OP': 'LOAD', 'src': {'size': 16, 'NT': False, 'type': 'addresses_WC_ht', 'same': True, 'AVXalign': False, 'congruent': 10}}
{'OP': 'STOR', 'dst': {'size': 4, 'NT': False, 'type': 'addresses_WT_ht', 'same': False, 'AVXalign': False, 'congruent': 1}}
{'OP': 'LOAD', 'src': {'size': 16, 'NT': False, 'type': 'addresses_WC_ht', 'same': False, 'AVXalign': False, 'congruent': 6}}
{'OP': 'STOR', 'dst': {'size': 2, 'NT': False, 'type': 'addresses_D_ht', 'same': False, 'AVXalign': False, 'congruent': 4}}
{'OP': 'LOAD', 'src': {'size': 16, 'NT': False, 'type': 'addresses_WC_ht', 'same': False, 'AVXalign': False, 'congruent': 8}}
{'OP': 'STOR', 'dst': {'size': 4, 'NT': True, 'type': 'addresses_WC_ht', 'same': False, 'AVXalign': True, 'congruent': 2}}
{'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
*/
| 45.330579 | 2,999 | 0.654695 |
cb01cac21154501bf3309608a1c4f283fcf9af72 | 4,775 | asm | Assembly | coverage/IN_CTS/0571-COVERAGE-basic-alias-analysis-327/work/variant/1_spirv_asm/shader.frag.asm | asuonpaa/ShaderTests | 6a3672040dcfa0d164d313224446496d1775a15e | [
"Apache-2.0"
] | null | null | null | coverage/IN_CTS/0571-COVERAGE-basic-alias-analysis-327/work/variant/1_spirv_asm/shader.frag.asm | asuonpaa/ShaderTests | 6a3672040dcfa0d164d313224446496d1775a15e | [
"Apache-2.0"
] | 47 | 2021-03-11T07:42:51.000Z | 2022-03-14T06:30:14.000Z | coverage/IN_CTS/0571-COVERAGE-basic-alias-analysis-327/work/variant/1_spirv_asm/shader.frag.asm | asuonpaa/ShaderTests | 6a3672040dcfa0d164d313224446496d1775a15e | [
"Apache-2.0"
] | 4 | 2021-03-09T13:37:19.000Z | 2022-02-25T07:32:11.000Z | ; SPIR-V
; Version: 1.0
; Generator: Khronos Glslang Reference Front End; 10
; Bound: 97
; Schema: 0
OpCapability Shader
%1 = OpExtInstImport "GLSL.std.450"
OpMemoryModel Logical GLSL450
OpEntryPoint Fragment %4 "main" %78
OpExecutionMode %4 OriginUpperLeft
OpSource ESSL 320
OpName %4 "main"
OpName %8 "a"
OpName %12 "buf0"
OpMemberName %12 0 "_GLF_uniform_int_values"
OpName %14 ""
OpName %24 "arr"
OpName %78 "_GLF_color"
OpDecorate %11 ArrayStride 16
OpMemberDecorate %12 0 Offset 0
OpDecorate %12 Block
OpDecorate %14 DescriptorSet 0
OpDecorate %14 Binding 0
OpDecorate %78 Location 0
%2 = OpTypeVoid
%3 = OpTypeFunction %2
%6 = OpTypeInt 32 1
%7 = OpTypePointer Function %6
%9 = OpTypeInt 32 0
%10 = OpConstant %9 3
%11 = OpTypeArray %6 %10
%12 = OpTypeStruct %11
%13 = OpTypePointer Uniform %12
%14 = OpVariable %13 Uniform
%15 = OpConstant %6 0
%16 = OpConstant %6 1
%17 = OpTypePointer Uniform %6
%21 = OpConstant %9 10
%22 = OpTypeArray %6 %21
%23 = OpTypePointer Function %22
%56 = OpTypeBool
%69 = OpConstant %6 2
%75 = OpTypeFloat 32
%76 = OpTypeVector %75 4
%77 = OpTypePointer Output %76
%78 = OpVariable %77 Output
%4 = OpFunction %2 None %3
%5 = OpLabel
%8 = OpVariable %7 Function
%24 = OpVariable %23 Function
%18 = OpAccessChain %17 %14 %15 %16
%19 = OpLoad %6 %18
%20 = OpBitwiseOr %6 %19 %16
OpStore %8 %20
%25 = OpAccessChain %17 %14 %15 %15
%26 = OpLoad %6 %25
%27 = OpAccessChain %17 %14 %15 %15
%28 = OpLoad %6 %27
%29 = OpAccessChain %17 %14 %15 %15
%30 = OpLoad %6 %29
%31 = OpAccessChain %17 %14 %15 %15
%32 = OpLoad %6 %31
%33 = OpAccessChain %17 %14 %15 %15
%34 = OpLoad %6 %33
%35 = OpAccessChain %17 %14 %15 %15
%36 = OpLoad %6 %35
%37 = OpAccessChain %17 %14 %15 %15
%38 = OpLoad %6 %37
%39 = OpAccessChain %17 %14 %15 %15
%40 = OpLoad %6 %39
%41 = OpAccessChain %17 %14 %15 %15
%42 = OpLoad %6 %41
%43 = OpAccessChain %17 %14 %15 %15
%44 = OpLoad %6 %43
%45 = OpCompositeConstruct %22 %26 %28 %30 %32 %34 %36 %38 %40 %42 %44
OpStore %24 %45
%46 = OpLoad %6 %8
%47 = OpAccessChain %7 %24 %46
%48 = OpLoad %6 %47
%49 = OpIAdd %6 %48 %16
OpStore %47 %49
%50 = OpAccessChain %17 %14 %15 %16
%51 = OpLoad %6 %50
%52 = OpAccessChain %7 %24 %51
%53 = OpLoad %6 %52
%54 = OpAccessChain %17 %14 %15 %16
%55 = OpLoad %6 %54
%57 = OpIEqual %56 %53 %55
OpSelectionMerge %59 None
OpBranchConditional %57 %58 %59
%58 = OpLabel
%60 = OpAccessChain %17 %14 %15 %16
%61 = OpLoad %6 %60
%62 = OpAccessChain %7 %24 %61
%63 = OpLoad %6 %62
%64 = OpIAdd %6 %63 %16
OpStore %62 %64
OpBranch %59
%59 = OpLabel
%65 = OpAccessChain %17 %14 %15 %16
%66 = OpLoad %6 %65
%67 = OpAccessChain %7 %24 %66
%68 = OpLoad %6 %67
%70 = OpAccessChain %17 %14 %15 %69
%71 = OpLoad %6 %70
%72 = OpIEqual %56 %68 %71
OpSelectionMerge %74 None
OpBranchConditional %72 %73 %92
%73 = OpLabel
%79 = OpAccessChain %17 %14 %15 %16
%80 = OpLoad %6 %79
%81 = OpConvertSToF %75 %80
%82 = OpAccessChain %17 %14 %15 %15
%83 = OpLoad %6 %82
%84 = OpConvertSToF %75 %83
%85 = OpAccessChain %17 %14 %15 %15
%86 = OpLoad %6 %85
%87 = OpConvertSToF %75 %86
%88 = OpAccessChain %17 %14 %15 %16
%89 = OpLoad %6 %88
%90 = OpConvertSToF %75 %89
%91 = OpCompositeConstruct %76 %81 %84 %87 %90
OpStore %78 %91
OpBranch %74
%92 = OpLabel
%93 = OpAccessChain %17 %14 %15 %15
%94 = OpLoad %6 %93
%95 = OpConvertSToF %75 %94
%96 = OpCompositeConstruct %76 %95 %95 %95 %95
OpStore %78 %96
OpBranch %74
%74 = OpLabel
OpReturn
OpFunctionEnd
| 35.37037 | 79 | 0.477277 |
56227eb801c247192e0d3842841ac7ad00d20171 | 5,255 | asm | Assembly | plugins/mvtools/src/asm/Variance.asm | darcyg/vapoursynth-plugins | 5aaf090d3523cb8c53841949f2da286688ba33bb | [
"BSD-2-Clause"
] | null | null | null | plugins/mvtools/src/asm/Variance.asm | darcyg/vapoursynth-plugins | 5aaf090d3523cb8c53841949f2da286688ba33bb | [
"BSD-2-Clause"
] | null | null | null | plugins/mvtools/src/asm/Variance.asm | darcyg/vapoursynth-plugins | 5aaf090d3523cb8c53841949f2da286688ba33bb | [
"BSD-2-Clause"
] | 1 | 2020-04-06T16:52:59.000Z | 2020-04-06T16:52:59.000Z | %include "include/x86inc.asm"
SECTION_TEXT
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
%macro VAR4x4 0
movd m0, [srcpq] ; first line
movd m1, [srcpq + strideq] ; second line
movd m4, [srcpq + strideq * 2] ; third line
movd m5, [srcpq + stride3q] ; fourth line
psadbw m0, m7
psadbw m1, m6
psadbw m4, m7
psadbw m5, m6
paddw m0, m4
paddw m1, m5
paddw m0, m1
%endmacro
INIT_XMM
cglobal Luma4x4_sse2, 2, 3, 8, srcp, stride, stride3
lea stride3q, [strideq * 3]
pxor m6, m6
pxor m7, m7
VAR4x4
movd eax, m0
RET
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
%macro VAR8x4 0
movq m0, [srcpq] ; first line
movq m1, [srcpq + strideq] ; second line
movq m4, [srcpq + strideq * 2] ; third line
movq m5, [srcpq + stride3q] ; fourth line
psadbw m0, m7
psadbw m1, m6
psadbw m4, m7
psadbw m5, m6
paddw m0, m4
paddw m1, m5
paddw m0, m1
%endmacro
INIT_XMM
cglobal Luma8x4_sse2, 2, 3, 8, srcp, stride, stride3
lea stride3q, [strideq * 3]
pxor m6, m6
pxor m7, m7
VAR8x4
movd eax, m0
RET
; mm7 and mm6 must be times 8 db mean
; mm0 will be the var
; mm0..mm7 are used
%macro VAR8x8 0
movq m0, [srcpq] ; first line
movq m1, [srcpq + strideq] ; second line
movq m4, [srcpq + strideq * 2] ; third line
movq m5, [srcpq + stride3q] ; fourth line
psadbw m0, m7
psadbw m1, m6
psadbw m4, m7
psadbw m5, m6
paddw m0, m4
paddw m1, m5
lea srcpq, [srcpq + strideq * 4] ;
movq m2, [srcpq] ; fifth line
movq m3, [srcpq + strideq] ; sixth line
movq m4, [srcpq + strideq * 2] ; seventh line
movq m5, [srcpq + stride3q] ; eighth line
psadbw m2, m7
psadbw m3, m6
psadbw m4, m7
psadbw m5, m6
paddw m0, m2
paddw m1, m3
paddw m0, m4
paddw m1, m5
paddw m0, m1
%endmacro
INIT_XMM
cglobal Luma8x8_sse2, 2, 3, 8, srcp, stride, stride3
lea stride3q, [strideq * 3]
pxor m6, m6
pxor m7, m7
VAR8x8
movd eax, m0
RET
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
%macro VAR16x2 0
movdqu m0, [srcpq]
movdqu m1, [srcpq + strideq]
psadbw m0, m6
psadbw m1, m7
paddd m0, m1
movdqa m1, m0
psrldq m1, 8
paddd m0, m1
%endmacro
INIT_XMM
cglobal Luma16x2_sse2, 2, 2, 8, srcp, stride
pxor m6, m6
pxor m7, m7
VAR16x2
movd eax, m0
RET
%macro VAR16x4 0
movdqu m2, [srcpq]
movdqu m3, [srcpq + strideq]
movdqu m4, [srcpq + strideq * 2]
movdqu m5, [srcpq + stride3q]
psadbw m2, m6
psadbw m3, m7
psadbw m4, m6
psadbw m5, m7
lea srcpq, [srcpq + strideq * 4]
paddd m0, m2
paddd m1, m3
paddd m0, m4
paddd m1, m5
%endmacro
%macro VAR16x8 0
pxor m0, m0
pxor m1, m1
VAR16x4
VAR16x4
paddd m0, m1
movdqa m1, m0
psrldq m1, 8
paddd m0, m1
%endmacro
INIT_XMM
cglobal Luma16x8_sse2, 2, 3, 8, srcp, stride, stride3
lea stride3q, [strideq * 3]
pxor m6, m6
pxor m7, m7
VAR16x8
movd eax, m0
RET
%macro VAR16x16 0
pxor m0, m0
pxor m1, m1
VAR16x4
VAR16x4
VAR16x4
VAR16x4
paddd m0, m1
movdqa m1, m0
psrldq m1, 8
paddd m0, m1
%endmacro
INIT_XMM
cglobal Luma16x16_sse2, 2, 3, 8, srcp, stride, stride3
lea stride3q, [strideq * 3]
pxor m6, m6
pxor m7, m7
VAR16x16
movd eax, m0
RET
%macro VAR16x32 0
pxor m0, m0
pxor m1, m1
VAR16x4
VAR16x4
VAR16x4
VAR16x4
VAR16x4
VAR16x4
VAR16x4
VAR16x4
paddd m0, m1
movdqa m1, m0
psrldq m1, 8
paddd m0, m1
%endmacro
INIT_XMM
cglobal Luma16x32_sse2, 2, 3, 8, srcp, stride, stride3
lea stride3q, [strideq * 3]
pxor m6, m6
pxor m7, m7
VAR16x32
movd eax, m0
RET
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
%macro VAR32x2 0
movdqu m2, [srcpq]
movdqu m3, [srcpq + 16]
movdqu m4, [srcpq + strideq]
movdqu m5, [srcpq + strideq + 16]
psadbw m2, m6
psadbw m3, m7
psadbw m4, m6
psadbw m5, m7
lea srcpq, [srcpq + strideq * 2]
paddd m0, m2
paddd m1, m3
paddd m0, m4
paddd m1, m5
%endmacro
%macro VAR32x16 0
pxor m0, m0
pxor m1, m1
VAR32x2
VAR32x2
VAR32x2
VAR32x2
VAR32x2
VAR32x2
VAR32x2
VAR32x2
paddd m0, m1
movdqa m1, m0
psrldq m1, 8
paddd m0, m1
%endmacro
INIT_XMM
cglobal Luma32x16_sse2, 2, 3, 8, srcp, stride, stride3
lea stride3q, [strideq * 3]
pxor m6, m6
pxor m7, m7
VAR32x16
movd eax, m0
RET
%macro VAR32x32 0
pxor m0, m0
pxor m1, m1
VAR32x2
VAR32x2
VAR32x2
VAR32x2
VAR32x2
VAR32x2
VAR32x2
VAR32x2
VAR32x2
VAR32x2
VAR32x2
VAR32x2
VAR32x2
VAR32x2
VAR32x2
VAR32x2
paddd m0, m1
movdqa m1, m0
psrldq m1, 8
paddd m0, m1
%endmacro
INIT_XMM
cglobal Luma32x32_sse2, 2, 3, 8, srcp, stride, stride3
lea stride3q, [strideq * 3]
pxor m6, m6
pxor m7, m7
VAR32x32
movd eax, m0
RET
| 14.202703 | 54 | 0.550904 |
2d9fc4cbf1fe259a53ea23a12e968c5041817e8f | 370 | asm | Assembly | programs/oeis/010/A010124.asm | neoneye/loda | afe9559fb53ee12e3040da54bd6aa47283e0d9ec | [
"Apache-2.0"
] | 22 | 2018-02-06T19:19:31.000Z | 2022-01-17T21:53:31.000Z | programs/oeis/010/A010124.asm | neoneye/loda | afe9559fb53ee12e3040da54bd6aa47283e0d9ec | [
"Apache-2.0"
] | 41 | 2021-02-22T19:00:34.000Z | 2021-08-28T10:47:47.000Z | programs/oeis/010/A010124.asm | neoneye/loda | afe9559fb53ee12e3040da54bd6aa47283e0d9ec | [
"Apache-2.0"
] | 5 | 2021-02-24T21:14:16.000Z | 2021-08-09T19:48:05.000Z | ; A010124: Continued fraction for sqrt(19).
; 4,2,1,3,1,2,8,2,1,3,1,2,8,2,1,3,1,2,8,2,1,3,1,2,8,2,1,3,1,2,8,2,1,3,1,2,8,2,1,3,1,2,8,2,1,3,1,2,8,2,1,3,1,2,8,2,1,3,1,2,8,2,1,3,1,2,8,2,1,3,1,2,8,2,1,3,1,2,8,2,1,3,1,2,8,2,1,3,1,2,8,2,1,3,1,2,8,2,1,3
mov $1,1
sub $1,$0
seq $0,10125 ; Continued fraction for sqrt(21).
add $0,1
gcd $1,2
add $1,5
add $1,$0
sub $1,7
mov $0,$1
| 28.461538 | 201 | 0.562162 |
81edffd2949f7ca025225eadb494aa29af2a1a08 | 51,899 | asm | Assembly | Palmtree.Math.Core.Implements/vs_build/x86_Release/pmc_bitwiseor.asm | rougemeilland/Palmtree.Math.Core.Implements | 52f4f6c765d16c9b0baf1fd212c61a33daae138c | [
"MIT"
] | null | null | null | Palmtree.Math.Core.Implements/vs_build/x86_Release/pmc_bitwiseor.asm | rougemeilland/Palmtree.Math.Core.Implements | 52f4f6c765d16c9b0baf1fd212c61a33daae138c | [
"MIT"
] | null | null | null | Palmtree.Math.Core.Implements/vs_build/x86_Release/pmc_bitwiseor.asm | rougemeilland/Palmtree.Math.Core.Implements | 52f4f6c765d16c9b0baf1fd212c61a33daae138c | [
"MIT"
] | null | null | null | ; Listing generated by Microsoft (R) Optimizing Compiler Version 19.16.27026.1
TITLE Z:\Sources\Lunor\Repos\rougemeilland\Palmtree.Math.Core.Implements\Palmtree.Math.Core.Implements\pmc_bitwiseor.c
.686P
.XMM
include listing.inc
.model flat
INCLUDELIB MSVCRT
INCLUDELIB OLDNAMES
PUBLIC _Initialize_BitwiseOr
PUBLIC _PMC_BitwiseOr_I_X@12
PUBLIC _PMC_BitwiseOr_L_X@16
PUBLIC _PMC_BitwiseOr_X_I@12
PUBLIC _PMC_BitwiseOr_X_L@16
PUBLIC _PMC_BitwiseOr_X_X@12
EXTRN _CheckBlockLight:PROC
EXTRN _AllocateNumber:PROC
EXTRN _CommitNumber:PROC
EXTRN _CheckNumber:PROC
EXTRN _DuplicateNumber:PROC
EXTRN _From_I_Imp:PROC
EXTRN _From_L_Imp:PROC
EXTRN _number_zero:BYTE
; Function compile flags: /Ogtp
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_bitwiseor.c
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_inline_func.h
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_bitwiseor.c
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_inline_func.h
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_bitwiseor.c
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_inline_func.h
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_bitwiseor.c
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_inline_func.h
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_bitwiseor.c
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_inline_func.h
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_bitwiseor.c
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_inline_func.h
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_bitwiseor.c
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_inline_func.h
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_bitwiseor.c
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_inline_func.h
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_bitwiseor.c
; COMDAT _PMC_BitwiseOr_X_L_Imp
_TEXT SEGMENT
_w_light_check_code$1 = -4 ; size = 4
_w_light_check_code$2 = 8 ; size = 4
_u$ = 8 ; size = 4
_v$ = 12 ; size = 8
_w$ = 20 ; size = 4
_PMC_BitwiseOr_X_L_Imp PROC ; COMDAT
; 275 : {
push ebp
mov ebp, esp
push ecx
push ebx
push esi
; 276 : PMC_STATUS_CODE result;
; 277 : if (u->IS_ZERO)
mov esi, DWORD PTR _u$[ebp]
push edi
test BYTE PTR [esi+24], 2
je SHORT $LN2@PMC_Bitwis
; 278 : {
; 279 : // u が 0 である場合
; 280 : if (v == 0)
mov ecx, DWORD PTR _v$[ebp]
mov eax, ecx
mov edx, DWORD PTR _v$[ebp+4]
or eax, edx
jne SHORT $LN4@PMC_Bitwis
; 281 : {
; 282 : // v が 0 である場合
; 283 : *w = &number_zero;
mov eax, DWORD PTR _w$[ebp]
pop edi
; 350 : }
pop esi
pop ebx
mov DWORD PTR [eax], OFFSET _number_zero
xor eax, eax
mov esp, ebp
pop ebp
ret 0
$LN4@PMC_Bitwis:
; 284 : }
; 285 : else
; 286 : {
; 287 : // v が 0 でない場合
; 288 : if ((result = From_L_Imp(v, w)) != PMC_STATUS_OK)
push DWORD PTR _w$[ebp]
push edx
push ecx
call _From_L_Imp
add esp, 12 ; 0000000cH
test eax, eax
je $LN11@PMC_Bitwis
; 350 : }
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0
$LN2@PMC_Bitwis:
; 289 : return (result);
; 290 : }
; 291 : }
; 292 : else if (v == 0)
mov edi, DWORD PTR _v$[ebp]
mov eax, edi
mov ecx, DWORD PTR _v$[ebp+4]
or eax, ecx
jne SHORT $LN7@PMC_Bitwis
; 293 : {
; 294 : // v が 0 である場合
; 295 : if ((result = DuplicateNumber(u, w)) != PMC_STATUS_OK)
push DWORD PTR _w$[ebp]
push esi
call _DuplicateNumber
add esp, 8
test eax, eax
je $LN11@PMC_Bitwis
; 350 : }
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0
$LN7@PMC_Bitwis:
; 296 : return (result);
; 297 : }
; 298 : else
; 299 : {
; 300 : // u と v がともに 0 ではない場合
; 301 : if (__UNIT_TYPE_BIT_COUNT < sizeof(v) * 8)
; 302 : {
; 303 : // _UINT64_T が 1 ワードで表現しきれない場合
; 304 : __UNIT_TYPE u_bit_count = u->UNIT_BIT_COUNT;
mov edx, DWORD PTR [esi+12]
; 305 : _UINT32_T v_hi;
; 306 : _UINT32_T v_lo = _FROMDWORDTOWORD(v, &v_hi);
; 307 : if (v_hi == 0)
test ecx, ecx
jne SHORT $LN12@PMC_Bitwis
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_inline_func.h
; 597 : if (x == 0)
test edi, edi
jne SHORT $LN24@PMC_Bitwis
; 598 : return (sizeof(x) * 8);
lea ecx, DWORD PTR [edi+32]
jmp SHORT $LN23@PMC_Bitwis
$LN24@PMC_Bitwis:
; 601 : _BitScanReverse(&pos, x);
bsr eax, edi
; 607 : return (sizeof(x) * 8 - 1 - pos);
mov ecx, 31 ; 0000001fH
sub ecx, eax
$LN23@PMC_Bitwis:
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_bitwiseor.c
; 313 : if ((result = AllocateNumber(w, w_bit_count, &w_light_check_code)) != PMC_STATUS_OK)
mov ebx, DWORD PTR _w$[ebp]
mov eax, 32 ; 00000020H
sub eax, ecx
lea ecx, DWORD PTR _w_light_check_code$2[ebp]
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_inline_func.h
; 204 : return (x >= y ? x : y);
cmp edx, eax
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_bitwiseor.c
; 313 : if ((result = AllocateNumber(w, w_bit_count, &w_light_check_code)) != PMC_STATUS_OK)
push ecx
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_inline_func.h
; 204 : return (x >= y ? x : y);
cmovae eax, edx
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_bitwiseor.c
; 313 : if ((result = AllocateNumber(w, w_bit_count, &w_light_check_code)) != PMC_STATUS_OK)
push eax
push ebx
call _AllocateNumber
add esp, 12 ; 0000000cH
test eax, eax
jne $LN1@PMC_Bitwis
; 314 : return (result);
; 315 : BitwiseOr_X_1W(u->BLOCK, u->UNIT_WORD_COUNT, v_lo, (*w)->BLOCK);
mov eax, DWORD PTR [ebx]
push DWORD PTR [eax+32]
push edi
push DWORD PTR [esi+8]
push DWORD PTR [esi+32]
call _BitwiseOr_X_1W
; 316 : if ((result = CheckBlockLight((*w)->BLOCK, w_light_check_code)) != PMC_STATUS_OK)
mov eax, DWORD PTR [ebx]
push DWORD PTR _w_light_check_code$2[ebp]
push DWORD PTR [eax+32]
call _CheckBlockLight
add esp, 24 ; 00000018H
test eax, eax
je SHORT $LN17@PMC_Bitwis
; 350 : }
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0
$LN12@PMC_Bitwis:
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_inline_func.h
; 601 : _BitScanReverse(&pos, x);
bsr eax, ecx
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_bitwiseor.c
; 325 : if ((result = AllocateNumber(w, w_bit_count, &w_light_check_code)) != PMC_STATUS_OK)
mov ebx, DWORD PTR _w$[ebp]
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_inline_func.h
; 607 : return (sizeof(x) * 8 - 1 - pos);
mov ecx, 31 ; 0000001fH
sub ecx, eax
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_bitwiseor.c
; 322 : __UNIT_TYPE v_bit_count = sizeof(v) * 8 - _LZCNT_ALT_32(v_hi);
mov eax, 64 ; 00000040H
sub eax, ecx
; 325 : if ((result = AllocateNumber(w, w_bit_count, &w_light_check_code)) != PMC_STATUS_OK)
lea ecx, DWORD PTR _w_light_check_code$1[ebp]
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_inline_func.h
; 204 : return (x >= y ? x : y);
cmp edx, eax
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_bitwiseor.c
; 325 : if ((result = AllocateNumber(w, w_bit_count, &w_light_check_code)) != PMC_STATUS_OK)
push ecx
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_inline_func.h
; 204 : return (x >= y ? x : y);
cmovae eax, edx
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_bitwiseor.c
; 325 : if ((result = AllocateNumber(w, w_bit_count, &w_light_check_code)) != PMC_STATUS_OK)
push eax
push ebx
call _AllocateNumber
add esp, 12 ; 0000000cH
test eax, eax
jne SHORT $LN1@PMC_Bitwis
; 326 : return (result);
; 327 : BitwiseOr_X_2W(u->BLOCK, u->UNIT_WORD_COUNT, v_hi, v_lo, (*w)->BLOCK);
mov eax, DWORD PTR [ebx]
mov ecx, DWORD PTR [esi+8]
mov esi, DWORD PTR [esi+32]
mov edx, DWORD PTR [eax+32]
mov eax, DWORD PTR [esi]
or eax, edi
; 53 : if (u_count == 1)
mov DWORD PTR [edx], eax
cmp ecx, 1
jne SHORT $LN34@PMC_Bitwis
; 54 : {
; 55 : w[0] = u[0] | v_lo;
; 56 : w[1] = v_hi;
mov ecx, DWORD PTR _v$[ebp+4]
mov DWORD PTR [edx+4], ecx
; 57 : }
jmp SHORT $LN39@PMC_Bitwis
$LN34@PMC_Bitwis:
; 58 : else if (u_count == 2)
mov eax, DWORD PTR [esi+4]
or eax, DWORD PTR _v$[ebp+4]
mov DWORD PTR [edx+4], eax
cmp ecx, 2
je SHORT $LN39@PMC_Bitwis
; 59 : {
; 60 : w[0] = u[0] | v_lo;
; 61 : w[1] = u[1] | v_hi;
; 62 : }
; 63 : else
; 64 : {
; 65 : w[0] = u[0] | v_lo;
; 66 : w[1] = u[1] | v_hi;
; 67 : _COPY_MEMORY_UNIT(w + 2, u + 2, u_count - 2);
add ecx, -2 ; fffffffeH
lea edi, DWORD PTR [edx+8]
add esi, 8
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_inline_func.h
; 68 : __movsd((unsigned long *)d, (unsigned long *)s, (unsigned long)count);
rep movsd
$LN39@PMC_Bitwis:
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_bitwiseor.c
; 328 : if ((result = CheckBlockLight((*w)->BLOCK, w_light_check_code)) != PMC_STATUS_OK)
mov eax, DWORD PTR [ebx]
push DWORD PTR _w_light_check_code$1[ebp]
push DWORD PTR [eax+32]
call _CheckBlockLight
add esp, 8
test eax, eax
jne SHORT $LN1@PMC_Bitwis
$LN17@PMC_Bitwis:
; 329 : return (result);
; 330 : }
; 331 : CommitNumber(*w);
push DWORD PTR [ebx]
call _CommitNumber
add esp, 4
$LN11@PMC_Bitwis:
; 332 : }
; 333 : else
; 334 : {
; 335 : // _UINT64_T が 1 ワードで表現できる場合
; 336 :
; 337 : __UNIT_TYPE u_bit_count = u->UNIT_BIT_COUNT;
; 338 : __UNIT_TYPE v_bit_count = sizeof(v) * 8 - _LZCNT_ALT_UNIT((__UNIT_TYPE)v);
; 339 : __UNIT_TYPE w_bit_count = _MAXIMUM_UNIT(u_bit_count, v_bit_count) + 1;
; 340 : __UNIT_TYPE nw_light_check_code;
; 341 : if ((result = AllocateNumber(w, w_bit_count, &nw_light_check_code)) != PMC_STATUS_OK)
; 342 : return (result);
; 343 : BitwiseOr_X_1W(u->BLOCK, u->UNIT_WORD_COUNT, (__UNIT_TYPE)v, (*w)->BLOCK);
; 344 : if ((result = CheckBlockLight((*w)->BLOCK, nw_light_check_code)) != PMC_STATUS_OK)
; 345 : return (result);
; 346 : CommitNumber(*w);
; 347 : }
; 348 : }
; 349 : return (PMC_STATUS_OK);
xor eax, eax
$LN1@PMC_Bitwis:
pop edi
; 350 : }
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0
_PMC_BitwiseOr_X_L_Imp ENDP
_TEXT ENDS
; Function compile flags: /Ogtp
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_bitwiseor.c
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_inline_func.h
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_bitwiseor.c
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_inline_func.h
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_bitwiseor.c
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_inline_func.h
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_bitwiseor.c
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_inline_func.h
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_bitwiseor.c
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_inline_func.h
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_bitwiseor.c
; COMDAT _PMC_BitwiseOr_X_I_Imp
_TEXT SEGMENT
_nz_check_code$1 = 8 ; size = 4
_u$ = 8 ; size = 4
_v$ = 12 ; size = 4
_w$ = 16 ; size = 4
_PMC_BitwiseOr_X_I_Imp PROC ; COMDAT
; 188 : {
push ebp
mov ebp, esp
push ebx
push esi
mov esi, DWORD PTR _v$[ebp]
push edi
; 189 : PMC_STATUS_CODE result;
; 190 : if (u->IS_ZERO)
mov edi, DWORD PTR _u$[ebp]
test BYTE PTR [edi+24], 2
je SHORT $LN2@PMC_Bitwis
; 191 : {
; 192 : // u が 0 である場合
; 193 : if (v == 0)
test esi, esi
jne SHORT $LN4@PMC_Bitwis
; 194 : {
; 195 : // v が 0 である場合
; 196 : *w = &number_zero;
mov eax, DWORD PTR _w$[ebp]
pop edi
; 226 : }
pop esi
pop ebx
mov DWORD PTR [eax], OFFSET _number_zero
xor eax, eax
pop ebp
ret 0
$LN4@PMC_Bitwis:
; 197 : }
; 198 : else
; 199 : {
; 200 : // v が 0 でない場合
; 201 : if ((result = From_I_Imp(v, w)) != PMC_STATUS_OK)
push DWORD PTR _w$[ebp]
push esi
call _From_I_Imp
add esp, 8
test eax, eax
je $LN8@PMC_Bitwis
; 226 : }
pop edi
pop esi
pop ebx
pop ebp
ret 0
$LN2@PMC_Bitwis:
; 202 : return (result);
; 203 : }
; 204 : }
; 205 : else if (v == 0)
test esi, esi
jne SHORT $LN7@PMC_Bitwis
; 206 : {
; 207 : // v が 0 である場合
; 208 : if ((result = DuplicateNumber(u, w)) != PMC_STATUS_OK)
push DWORD PTR _w$[ebp]
push edi
call _DuplicateNumber
add esp, 8
test eax, eax
je SHORT $LN8@PMC_Bitwis
; 226 : }
pop edi
pop esi
pop ebx
pop ebp
ret 0
$LN7@PMC_Bitwis:
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_inline_func.h
; 601 : _BitScanReverse(&pos, x);
bsr eax, esi
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_bitwiseor.c
; 218 : if ((result = AllocateNumber(w, w_bit_count, &nz_check_code)) != PMC_STATUS_OK)
mov ebx, DWORD PTR _w$[ebp]
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_inline_func.h
; 607 : return (sizeof(x) * 8 - 1 - pos);
mov ecx, 31 ; 0000001fH
sub ecx, eax
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_bitwiseor.c
; 215 : __UNIT_TYPE v_bit_count = sizeof(v) * 8 - _LZCNT_ALT_32(v);
mov eax, 32 ; 00000020H
sub eax, ecx
; 218 : if ((result = AllocateNumber(w, w_bit_count, &nz_check_code)) != PMC_STATUS_OK)
lea ecx, DWORD PTR _nz_check_code$1[ebp]
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_inline_func.h
; 204 : return (x >= y ? x : y);
cmp DWORD PTR [edi+12], eax
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_bitwiseor.c
; 218 : if ((result = AllocateNumber(w, w_bit_count, &nz_check_code)) != PMC_STATUS_OK)
push ecx
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_inline_func.h
; 204 : return (x >= y ? x : y);
cmovae eax, DWORD PTR [edi+12]
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_bitwiseor.c
; 216 : __UNIT_TYPE w_bit_count = _MAXIMUM_UNIT(u_bit_count, v_bit_count) + 1;
inc eax
; 218 : if ((result = AllocateNumber(w, w_bit_count, &nz_check_code)) != PMC_STATUS_OK)
push eax
push ebx
call _AllocateNumber
add esp, 12 ; 0000000cH
test eax, eax
jne SHORT $LN1@PMC_Bitwis
; 219 : return (result);
; 220 : BitwiseOr_X_1W(u->BLOCK, u->UNIT_WORD_COUNT, v, (*w)->BLOCK);
mov eax, DWORD PTR [ebx]
mov ecx, DWORD PTR [edi+8]
mov edi, DWORD PTR [edi+32]
mov edx, DWORD PTR [eax+32]
mov eax, DWORD PTR [edi]
or eax, esi
mov DWORD PTR [edx], eax
; 41 : if (u_count == 1)
cmp ecx, 1
je SHORT $LN22@PMC_Bitwis
; 42 : w[0] = u[0] | v;
; 43 : else
; 44 : {
; 45 : w[0] = u[0] | v;
; 46 : _COPY_MEMORY_UNIT(w + 1, u + 1, u_count - 1);
lea esi, DWORD PTR [edi+4]
dec ecx
lea edi, DWORD PTR [edx+4]
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_inline_func.h
; 68 : __movsd((unsigned long *)d, (unsigned long *)s, (unsigned long)count);
rep movsd
$LN22@PMC_Bitwis:
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_bitwiseor.c
; 221 : if ((result = CheckBlockLight((*w)->BLOCK, nz_check_code)) != PMC_STATUS_OK)
mov eax, DWORD PTR [ebx]
push DWORD PTR _nz_check_code$1[ebp]
push DWORD PTR [eax+32]
call _CheckBlockLight
add esp, 8
test eax, eax
jne SHORT $LN1@PMC_Bitwis
; 222 : return (result);
; 223 : CommitNumber(*w);
push DWORD PTR [ebx]
call _CommitNumber
add esp, 4
$LN8@PMC_Bitwis:
; 224 : }
; 225 : return (PMC_STATUS_OK);
xor eax, eax
$LN1@PMC_Bitwis:
pop edi
; 226 : }
pop esi
pop ebx
pop ebp
ret 0
_PMC_BitwiseOr_X_I_Imp ENDP
_TEXT ENDS
; Function compile flags: /Ogtp
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_bitwiseor.c
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_inline_func.h
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_bitwiseor.c
; COMDAT _BitwiseOr_X_X
_TEXT SEGMENT
tv2458 = -32 ; size = 4
tv2453 = -32 ; size = 4
tv2455 = -28 ; size = 4
tv2454 = -28 ; size = 4
tv2456 = -24 ; size = 4
tv2459 = -20 ; size = 4
_count$1$ = -16 ; size = 4
_v$1$ = -12 ; size = 4
tv2460 = -8 ; size = 4
tv2457 = -8 ; size = 4
_w$1$ = -8 ; size = 4
_u$1$ = -4 ; size = 4
_u$ = 8 ; size = 4
_u_count$ = 12 ; size = 4
_v$ = 16 ; size = 4
_v_count$ = 20 ; size = 4
_w$ = 24 ; size = 4
_BitwiseOr_X_X PROC ; COMDAT
; 73 : {
push ebp
mov ebp, esp
sub esp, 32 ; 00000020H
; 74 : __UNIT_TYPE or_count = v_count;
; 75 : __UNIT_TYPE cp_count = u_count - v_count;
; 76 :
; 77 : __UNIT_TYPE count = or_count >> 5;
; 78 : while (count > 0)
mov edx, DWORD PTR _v$[ebp]
push ebx
mov ebx, DWORD PTR _v_count$[ebp]
mov eax, ebx
sub DWORD PTR _u_count$[ebp], ebx
push esi
mov esi, DWORD PTR _u$[ebp]
shr eax, 5
mov DWORD PTR _count$1$[ebp], eax
mov DWORD PTR _u$1$[ebp], esi
push edi
mov edi, DWORD PTR _w$[ebp]
mov DWORD PTR _w$1$[ebp], edi
test eax, eax
je $LN3@BitwiseOr_
mov DWORD PTR _v$1$[ebp], edx
$LL2@BitwiseOr_:
; 79 : {
; 80 : w[0] = u[0] | v[0];
lea ecx, DWORD PTR [edx+16]
xor ebx, ebx
lea eax, DWORD PTR [ecx+108]
cmp edi, eax
ja SHORT $LN29@BitwiseOr_
lea eax, DWORD PTR [edi+124]
cmp eax, edx
jae SHORT $LN69@BitwiseOr_
$LN29@BitwiseOr_:
lea eax, DWORD PTR [esi+48]
mov DWORD PTR tv2453[ebp], eax
add eax, 76 ; 0000004cH
cmp edi, eax
ja SHORT $LN30@BitwiseOr_
lea eax, DWORD PTR [edi+124]
cmp eax, esi
jb SHORT $LN30@BitwiseOr_
$LN69@BitwiseOr_:
mov DWORD PTR tv2460[ebp], esi
mov ecx, edi
sub esi, edx
mov eax, edx
sub ecx, edx
mov ebx, 32 ; 00000020H
mov DWORD PTR tv2457[ebp], ecx
mov edx, ecx
npad 3
$LL67@BitwiseOr_:
mov ecx, DWORD PTR [eax+esi]
lea eax, DWORD PTR [eax+4]
or ecx, DWORD PTR [eax-4]
mov DWORD PTR [eax+edx-4], ecx
sub ebx, 1
jne SHORT $LL67@BitwiseOr_
mov esi, DWORD PTR _u$1$[ebp]
jmp $LN73@BitwiseOr_
$LN30@BitwiseOr_:
lea eax, DWORD PTR [edi+32]
mov edi, esi
mov esi, DWORD PTR _w$1$[ebp]
sub edi, edx
sub esi, edx
mov DWORD PTR tv2459[ebp], edi
mov DWORD PTR tv2456[ebp], esi
mov esi, DWORD PTR _u$1$[ebp]
mov edx, esi
sub edx, DWORD PTR _w$1$[ebp]
mov DWORD PTR tv2454[ebp], edx
mov edx, edi
mov edi, DWORD PTR tv2456[ebp]
npad 4
$LL14@BitwiseOr_:
movups xmm1, XMMWORD PTR [esi+ebx*4]
mov esi, DWORD PTR tv2454[ebp]
lea ecx, DWORD PTR [ecx+64]
movups xmm0, XMMWORD PTR [ecx-80]
lea eax, DWORD PTR [eax+64]
por xmm1, xmm0
movups xmm0, XMMWORD PTR [ecx-64]
movups XMMWORD PTR [eax-96], xmm1
movups xmm1, XMMWORD PTR [edx+ecx-64]
por xmm1, xmm0
movups xmm0, XMMWORD PTR [ecx-48]
movups XMMWORD PTR [edi+ecx-64], xmm1
movups xmm1, XMMWORD PTR [esi+eax-64]
mov esi, DWORD PTR tv2453[ebp]
por xmm1, xmm0
movups xmm0, XMMWORD PTR [ecx-32]
movups XMMWORD PTR [eax-64], xmm1
movups xmm1, XMMWORD PTR [esi+ebx*4]
mov esi, DWORD PTR _u$1$[ebp]
add ebx, 16 ; 00000010H
por xmm1, xmm0
movups XMMWORD PTR [eax-48], xmm1
cmp ebx, 32 ; 00000020H
jl SHORT $LL14@BitwiseOr_
mov edi, DWORD PTR _w$1$[ebp]
$LN73@BitwiseOr_:
; 81 : w[1] = u[1] | v[1];
; 82 : w[2] = u[2] | v[2];
; 83 : w[3] = u[3] | v[3];
; 84 : w[4] = u[4] | v[4];
; 85 : w[5] = u[5] | v[5];
; 86 : w[6] = u[6] | v[6];
; 87 : w[7] = u[7] | v[7];
; 88 : w[8] = u[8] | v[8];
; 89 : w[9] = u[9] | v[9];
; 90 : w[10] = u[10] | v[10];
; 91 : w[11] = u[11] | v[11];
; 92 : w[12] = u[12] | v[12];
; 93 : w[13] = u[13] | v[13];
; 94 : w[14] = u[14] | v[14];
; 95 : w[15] = u[15] | v[15];
; 96 : w[16] = u[16] | v[16];
; 97 : w[17] = u[17] | v[17];
; 98 : w[18] = u[18] | v[18];
; 99 : w[19] = u[19] | v[19];
; 100 : w[20] = u[20] | v[20];
; 101 : w[21] = u[21] | v[21];
; 102 : w[22] = u[22] | v[22];
; 103 : w[23] = u[23] | v[23];
; 104 : w[24] = u[24] | v[24];
; 105 : w[25] = u[25] | v[25];
; 106 : w[26] = u[26] | v[26];
; 107 : w[27] = u[27] | v[27];
; 108 : w[28] = u[28] | v[28];
; 109 : w[29] = u[29] | v[29];
; 110 : w[30] = u[30] | v[30];
; 111 : w[31] = u[31] | v[31];
; 112 : u += 32;
mov edx, DWORD PTR _v$1$[ebp]
sub esi, -128 ; ffffff80H
; 113 : v += 32;
sub edx, -128 ; ffffff80H
mov DWORD PTR _u$1$[ebp], esi
; 114 : w += 32;
sub edi, -128 ; ffffff80H
mov DWORD PTR _v$1$[ebp], edx
; 115 : --count;
sub DWORD PTR _count$1$[ebp], 1
mov DWORD PTR _w$1$[ebp], edi
jne $LL2@BitwiseOr_
; 74 : __UNIT_TYPE or_count = v_count;
; 75 : __UNIT_TYPE cp_count = u_count - v_count;
; 76 :
; 77 : __UNIT_TYPE count = or_count >> 5;
; 78 : while (count > 0)
mov ebx, DWORD PTR _v_count$[ebp]
$LN3@BitwiseOr_:
; 116 : }
; 117 :
; 118 : if (or_count & 0x10)
test bl, 16 ; 00000010H
je $LN4@BitwiseOr_
; 119 : {
; 120 : w[0] = u[0] | v[0];
lea eax, DWORD PTR [edx+60]
lea ecx, DWORD PTR [edi+60]
cmp edi, eax
ja SHORT $LN33@BitwiseOr_
cmp ecx, edx
jae SHORT $LN71@BitwiseOr_
$LN33@BitwiseOr_:
lea eax, DWORD PTR [esi+60]
cmp edi, eax
ja SHORT $LN34@BitwiseOr_
cmp ecx, esi
jb SHORT $LN34@BitwiseOr_
$LN71@BitwiseOr_:
mov eax, esi
mov ecx, edx
sub eax, edx
mov ebx, 16 ; 00000010H
mov DWORD PTR tv2458[ebp], eax
mov eax, edi
mov edi, DWORD PTR tv2458[ebp]
sub eax, edx
mov DWORD PTR tv2455[ebp], eax
mov esi, eax
npad 5
$LL68@BitwiseOr_:
mov eax, DWORD PTR [edi+ecx]
lea ecx, DWORD PTR [ecx+4]
or eax, DWORD PTR [ecx-4]
mov DWORD PTR [esi+ecx-4], eax
sub ebx, 1
jne SHORT $LL68@BitwiseOr_
mov edi, DWORD PTR _w$1$[ebp]
mov esi, DWORD PTR _u$1$[ebp]
mov ebx, DWORD PTR _v_count$[ebp]
jmp SHORT $LN17@BitwiseOr_
$LN34@BitwiseOr_:
movups xmm0, XMMWORD PTR [edx]
movups xmm1, XMMWORD PTR [esi]
por xmm1, xmm0
movups xmm0, XMMWORD PTR [edx+16]
movups XMMWORD PTR [edi], xmm1
movups xmm1, XMMWORD PTR [esi+16]
por xmm1, xmm0
movups xmm0, XMMWORD PTR [edx+32]
movups XMMWORD PTR [edi+16], xmm1
movups xmm1, XMMWORD PTR [esi+32]
por xmm1, xmm0
movups xmm0, XMMWORD PTR [edx+48]
movups XMMWORD PTR [edi+32], xmm1
movups xmm1, XMMWORD PTR [esi+48]
por xmm1, xmm0
movups XMMWORD PTR [edi+48], xmm1
$LN17@BitwiseOr_:
; 121 : w[1] = u[1] | v[1];
; 122 : w[2] = u[2] | v[2];
; 123 : w[3] = u[3] | v[3];
; 124 : w[4] = u[4] | v[4];
; 125 : w[5] = u[5] | v[5];
; 126 : w[6] = u[6] | v[6];
; 127 : w[7] = u[7] | v[7];
; 128 : w[8] = u[8] | v[8];
; 129 : w[9] = u[9] | v[9];
; 130 : w[10] = u[10] | v[10];
; 131 : w[11] = u[11] | v[11];
; 132 : w[12] = u[12] | v[12];
; 133 : w[13] = u[13] | v[13];
; 134 : w[14] = u[14] | v[14];
; 135 : w[15] = u[15] | v[15];
; 136 : u += 16;
add esi, 64 ; 00000040H
; 137 : v += 16;
add edx, 64 ; 00000040H
; 138 : w += 16;
add edi, 64 ; 00000040H
$LN4@BitwiseOr_:
; 139 : }
; 140 :
; 141 : if (or_count & 0x8)
test bl, 8
je SHORT $LN5@BitwiseOr_
; 142 : {
; 143 : w[0] = u[0] | v[0];
mov eax, DWORD PTR [esi]
or eax, DWORD PTR [edx]
mov DWORD PTR [edi], eax
mov eax, DWORD PTR [esi+4]
or eax, DWORD PTR [edx+4]
mov DWORD PTR [edi+4], eax
mov eax, DWORD PTR [esi+8]
or eax, DWORD PTR [edx+8]
mov DWORD PTR [edi+8], eax
mov eax, DWORD PTR [esi+12]
or eax, DWORD PTR [edx+12]
mov DWORD PTR [edi+12], eax
mov eax, DWORD PTR [esi+16]
or eax, DWORD PTR [edx+16]
mov DWORD PTR [edi+16], eax
mov eax, DWORD PTR [esi+20]
or eax, DWORD PTR [edx+20]
mov DWORD PTR [edi+20], eax
mov eax, DWORD PTR [esi+24]
or eax, DWORD PTR [edx+24]
mov DWORD PTR [edi+24], eax
mov eax, DWORD PTR [esi+28]
; 144 : w[1] = u[1] | v[1];
; 145 : w[2] = u[2] | v[2];
; 146 : w[3] = u[3] | v[3];
; 147 : w[4] = u[4] | v[4];
; 148 : w[5] = u[5] | v[5];
; 149 : w[6] = u[6] | v[6];
; 150 : w[7] = u[7] | v[7];
; 151 : u += 8;
add esi, 32 ; 00000020H
or eax, DWORD PTR [edx+28]
; 152 : v += 8;
add edx, 32 ; 00000020H
mov DWORD PTR [edi+28], eax
; 153 : w += 8;
add edi, 32 ; 00000020H
$LN5@BitwiseOr_:
; 154 : }
; 155 :
; 156 : if (or_count & 0x4)
test bl, 4
je SHORT $LN6@BitwiseOr_
; 157 : {
; 158 : w[0] = u[0] | v[0];
mov eax, DWORD PTR [esi]
or eax, DWORD PTR [edx]
mov DWORD PTR [edi], eax
mov eax, DWORD PTR [esi+4]
or eax, DWORD PTR [edx+4]
mov DWORD PTR [edi+4], eax
mov eax, DWORD PTR [esi+8]
or eax, DWORD PTR [edx+8]
mov DWORD PTR [edi+8], eax
mov eax, DWORD PTR [esi+12]
; 159 : w[1] = u[1] | v[1];
; 160 : w[2] = u[2] | v[2];
; 161 : w[3] = u[3] | v[3];
; 162 : u += 4;
add esi, 16 ; 00000010H
or eax, DWORD PTR [edx+12]
; 163 : v += 4;
add edx, 16 ; 00000010H
mov DWORD PTR [edi+12], eax
; 164 : w += 4;
add edi, 16 ; 00000010H
$LN6@BitwiseOr_:
; 165 : }
; 166 :
; 167 : if (or_count & 0x2)
test bl, 2
je SHORT $LN7@BitwiseOr_
; 168 : {
; 169 : w[0] = u[0] | v[0];
mov eax, DWORD PTR [esi]
or eax, DWORD PTR [edx]
mov DWORD PTR [edi], eax
; 170 : w[1] = u[1] | v[1];
mov eax, DWORD PTR [esi+4]
; 171 : u += 2;
add esi, 8
or eax, DWORD PTR [edx+4]
; 172 : v += 2;
add edx, 8
mov DWORD PTR [edi+4], eax
; 173 : w += 2;
add edi, 8
$LN7@BitwiseOr_:
; 174 : }
; 175 :
; 176 : if (or_count & 0x1)
test bl, 1
je SHORT $LN8@BitwiseOr_
; 177 : {
; 178 : w[0] = u[0] | v[0];
mov eax, DWORD PTR [esi]
; 179 : u += 1;
add esi, 4
or eax, DWORD PTR [edx]
mov DWORD PTR [edi], eax
; 180 : v += 1;
; 181 : w += 1;
add edi, 4
$LN8@BitwiseOr_:
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_inline_func.h
; 68 : __movsd((unsigned long *)d, (unsigned long *)s, (unsigned long)count);
mov ecx, DWORD PTR _u_count$[ebp]
rep movsd
pop edi
pop esi
pop ebx
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_bitwiseor.c
; 185 : }
mov esp, ebp
pop ebp
ret 0
_BitwiseOr_X_X ENDP
_TEXT ENDS
; Function compile flags: /Ogtp
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_bitwiseor.c
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_inline_func.h
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_bitwiseor.c
; COMDAT _BitwiseOr_X_2W
_TEXT SEGMENT
_u$ = 8 ; size = 4
_u_count$ = 12 ; size = 4
_v_hi$ = 16 ; size = 4
_v_lo$ = 20 ; size = 4
_w$ = 24 ; size = 4
_BitwiseOr_X_2W PROC ; COMDAT
; 52 : {
push ebp
mov ebp, esp
; 53 : if (u_count == 1)
mov edx, DWORD PTR _u_count$[ebp]
mov ecx, DWORD PTR _v_hi$[ebp]
push esi
mov esi, DWORD PTR _u$[ebp]
push edi
mov edi, DWORD PTR _w$[ebp]
mov eax, DWORD PTR [esi]
or eax, DWORD PTR _v_lo$[ebp]
mov DWORD PTR [edi], eax
cmp edx, 1
jne SHORT $LN2@BitwiseOr_
; 54 : {
; 55 : w[0] = u[0] | v_lo;
; 56 : w[1] = v_hi;
mov DWORD PTR [edi+4], ecx
pop edi
; 69 : }
pop esi
pop ebp
ret 0
$LN2@BitwiseOr_:
; 57 : }
; 58 : else if (u_count == 2)
mov eax, DWORD PTR [esi+4]
or eax, ecx
mov DWORD PTR [edi+4], eax
cmp edx, 2
je SHORT $LN7@BitwiseOr_
; 59 : {
; 60 : w[0] = u[0] | v_lo;
; 61 : w[1] = u[1] | v_hi;
; 62 : }
; 63 : else
; 64 : {
; 65 : w[0] = u[0] | v_lo;
; 66 : w[1] = u[1] | v_hi;
; 67 : _COPY_MEMORY_UNIT(w + 2, u + 2, u_count - 2);
add esi, 8
lea ecx, DWORD PTR [edx-2]
add edi, 8
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_inline_func.h
; 68 : __movsd((unsigned long *)d, (unsigned long *)s, (unsigned long)count);
rep movsd
$LN7@BitwiseOr_:
pop edi
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_bitwiseor.c
; 69 : }
pop esi
pop ebp
ret 0
_BitwiseOr_X_2W ENDP
_TEXT ENDS
; Function compile flags: /Ogtp
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_bitwiseor.c
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_inline_func.h
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_bitwiseor.c
; COMDAT _BitwiseOr_X_1W
_TEXT SEGMENT
_u$ = 8 ; size = 4
_u_count$ = 12 ; size = 4
_v$ = 16 ; size = 4
_w$ = 20 ; size = 4
_BitwiseOr_X_1W PROC ; COMDAT
; 40 : {
push ebp
mov ebp, esp
; 41 : if (u_count == 1)
mov ecx, DWORD PTR _u_count$[ebp]
push esi
mov esi, DWORD PTR _u$[ebp]
push edi
mov edi, DWORD PTR _w$[ebp]
mov eax, DWORD PTR [esi]
or eax, DWORD PTR _v$[ebp]
mov DWORD PTR [edi], eax
cmp ecx, 1
je SHORT $LN5@BitwiseOr_
; 42 : w[0] = u[0] | v;
; 43 : else
; 44 : {
; 45 : w[0] = u[0] | v;
; 46 : _COPY_MEMORY_UNIT(w + 1, u + 1, u_count - 1);
dec ecx
add esi, 4
add edi, 4
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_inline_func.h
; 68 : __movsd((unsigned long *)d, (unsigned long *)s, (unsigned long)count);
rep movsd
$LN5@BitwiseOr_:
pop edi
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_bitwiseor.c
; 48 : }
pop esi
pop ebp
ret 0
_BitwiseOr_X_1W ENDP
_TEXT ENDS
; Function compile flags: /Ogtp
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_inline_func.h
; COMDAT __LZCNT_ALT_UNIT
_TEXT SEGMENT
_x$ = 8 ; size = 4
__LZCNT_ALT_UNIT PROC ; COMDAT
; 629 : {
push ebp
mov ebp, esp
; 630 : if (x == 0)
mov eax, DWORD PTR _x$[ebp]
test eax, eax
jne SHORT $LN2@LZCNT_ALT_
; 631 : return (sizeof(x) * 8);
mov eax, 32 ; 00000020H
; 655 : }
pop ebp
ret 0
$LN2@LZCNT_ALT_:
; 632 : #ifdef _M_IX86
; 633 : _UINT32_T pos;
; 634 : #ifdef _MSC_VER
; 635 : _BitScanReverse(&pos, x);
bsr ecx, eax
; 636 : #elif defined(__GNUC__)
; 637 : __asm__("bsrl %1, %0" : "=r"(pos) : "rm"(x));
; 638 : #else
; 639 : #error unknown compiler
; 640 : #endif
; 641 : #elif defined(_M_X64)
; 642 : #ifdef _MSC_VER
; 643 : _UINT32_T pos;
; 644 : _BitScanReverse64(&pos, x);
; 645 : #elif defined(__GNUC__)
; 646 : _UINT64_T pos;
; 647 : __asm__("bsrq %1, %0" : "=r"(pos) : "rm"(x));
; 648 : #else
; 649 : #error unknown compiler
; 650 : #endif
; 651 : #else
; 652 : #error unknown platform
; 653 : #endif
; 654 : return (sizeof(x) * 8 - 1 - pos);
mov eax, 31 ; 0000001fH
sub eax, ecx
; 655 : }
pop ebp
ret 0
__LZCNT_ALT_UNIT ENDP
_TEXT ENDS
; Function compile flags: /Ogtp
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_inline_func.h
; COMDAT __LZCNT_ALT_32
_TEXT SEGMENT
_x$ = 8 ; size = 4
__LZCNT_ALT_32 PROC ; COMDAT
; 596 : {
push ebp
mov ebp, esp
; 597 : if (x == 0)
mov eax, DWORD PTR _x$[ebp]
test eax, eax
jne SHORT $LN2@LZCNT_ALT_
; 598 : return (sizeof(x) * 8);
mov eax, 32 ; 00000020H
; 608 : }
pop ebp
ret 0
$LN2@LZCNT_ALT_:
; 599 : _UINT32_T pos;
; 600 : #ifdef _MSC_VER
; 601 : _BitScanReverse(&pos, x);
bsr ecx, eax
; 602 : #elif defined(__GNUC__)
; 603 : __asm__("bsrl %1, %0" : "=r"(pos) : "rm"(x));
; 604 : #else
; 605 : #error unknown compiler
; 606 : #endif
; 607 : return (sizeof(x) * 8 - 1 - pos);
mov eax, 31 ; 0000001fH
sub eax, ecx
; 608 : }
pop ebp
ret 0
__LZCNT_ALT_32 ENDP
_TEXT ENDS
; Function compile flags: /Ogtp
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_inline_func.h
; COMDAT __MAXIMUM_UNIT
_TEXT SEGMENT
_x$ = 8 ; size = 4
_y$ = 12 ; size = 4
__MAXIMUM_UNIT PROC ; COMDAT
; 203 : {
push ebp
mov ebp, esp
; 204 : return (x >= y ? x : y);
mov eax, DWORD PTR _y$[ebp]
cmp DWORD PTR _x$[ebp], eax
cmovae eax, DWORD PTR _x$[ebp]
; 205 : }
pop ebp
ret 0
__MAXIMUM_UNIT ENDP
_TEXT ENDS
; Function compile flags: /Ogtp
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_inline_func.h
; COMDAT __FROMDWORDTOWORD
_TEXT SEGMENT
_value$ = 8 ; size = 8
_result_high$ = 16 ; size = 4
__FROMDWORDTOWORD PROC ; COMDAT
; 182 : {
push ebp
mov ebp, esp
; 183 : *result_high = (_UINT32_T)(value >> 32);
mov eax, DWORD PTR _result_high$[ebp]
mov ecx, DWORD PTR _value$[ebp+4]
mov DWORD PTR [eax], ecx
; 184 : return ((_UINT32_T)value);
mov eax, DWORD PTR _value$[ebp]
; 185 : }
pop ebp
ret 0
__FROMDWORDTOWORD ENDP
_TEXT ENDS
; Function compile flags: /Ogtp
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_inline_func.h
; COMDAT __COPY_MEMORY_UNIT
_TEXT SEGMENT
_d$ = 8 ; size = 4
_s$ = 12 ; size = 4
_count$ = 16 ; size = 4
__COPY_MEMORY_UNIT PROC ; COMDAT
; 66 : {
push ebp
mov ebp, esp
; 67 : #ifdef _M_IX86
; 68 : __movsd((unsigned long *)d, (unsigned long *)s, (unsigned long)count);
mov ecx, DWORD PTR _count$[ebp]
push esi
mov esi, DWORD PTR _s$[ebp]
push edi
mov edi, DWORD PTR _d$[ebp]
rep movsd
pop edi
pop esi
; 69 : #elif defined(_M_X64)
; 70 : __movsq(d, s, count);
; 71 : #else
; 72 : #error unknown platform
; 73 : #endif
; 74 : }
pop ebp
ret 0
__COPY_MEMORY_UNIT ENDP
_TEXT ENDS
; Function compile flags: /Ogtp
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_bitwiseor.c
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_inline_func.h
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_bitwiseor.c
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_inline_func.h
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_bitwiseor.c
; COMDAT _PMC_BitwiseOr_X_X@12
_TEXT SEGMENT
tv263 = 8 ; size = 4
_u$ = 8 ; size = 4
_nw$ = 12 ; size = 4
_v$ = 12 ; size = 4
_nw_light_check_code$1 = 16 ; size = 4
_w$ = 16 ; size = 4
_PMC_BitwiseOr_X_X@12 PROC ; COMDAT
; 399 : {
push ebp
mov ebp, esp
push ebx
push esi
mov esi, DWORD PTR _v$[ebp]
push edi
mov edi, DWORD PTR _u$[ebp]
; 400 : if (u == NULL)
test edi, edi
je $LN19@PMC_Bitwis
; 401 : return (PMC_STATUS_ARGUMENT_ERROR);
; 402 : if (v == NULL)
test esi, esi
je $LN19@PMC_Bitwis
; 403 : return (PMC_STATUS_ARGUMENT_ERROR);
; 404 : if (w == NULL)
mov ebx, DWORD PTR _w$[ebp]
test ebx, ebx
je $LN19@PMC_Bitwis
; 406 : NUMBER_HEADER* nu = (NUMBER_HEADER*)u;
; 407 : NUMBER_HEADER* nv = (NUMBER_HEADER*)v;
; 408 : PMC_STATUS_CODE result;
; 409 : if ((result = CheckNumber(nu)) != PMC_STATUS_OK)
push edi
call _CheckNumber
add esp, 4
test eax, eax
jne $LN1@PMC_Bitwis
; 410 : return (result);
; 411 : if ((result = CheckNumber(nv)) != PMC_STATUS_OK)
push esi
call _CheckNumber
add esp, 4
test eax, eax
jne $LN1@PMC_Bitwis
; 412 : return (result);
; 413 : NUMBER_HEADER* nw;
; 414 : if (nu->IS_ZERO)
test BYTE PTR [edi+24], 2
lea eax, DWORD PTR _nw$[ebp]
je SHORT $LN7@PMC_Bitwis
; 415 : {
; 416 : if ((result = DuplicateNumber(nv, &nw)) != PMC_STATUS_OK)
push eax
push esi
$LN20@PMC_Bitwis:
; 449 : }
call _DuplicateNumber
add esp, 8
test eax, eax
je SHORT $LN11@PMC_Bitwis
pop edi
pop esi
pop ebx
pop ebp
ret 12 ; 0000000cH
$LN7@PMC_Bitwis:
; 417 : return (result);
; 418 : }
; 419 : else if (nv->IS_ZERO)
test BYTE PTR [esi+24], 2
je SHORT $LN10@PMC_Bitwis
; 420 : {
; 421 : if ((result = DuplicateNumber(nu, &nw)) != PMC_STATUS_OK)
push eax
push edi
; 422 : return (result);
jmp SHORT $LN20@PMC_Bitwis
$LN10@PMC_Bitwis:
; 423 : }
; 424 : else
; 425 : {
; 426 : if (nu->UNIT_WORD_COUNT < nv->UNIT_WORD_COUNT)
mov ecx, DWORD PTR [edi+8]
; 427 : {
; 428 : NUMBER_HEADER* t = nu;
; 429 : nu = nv;
; 430 : nv = t;
; 431 : }
; 432 : __UNIT_TYPE u_bit_count = nu->UNIT_BIT_COUNT;
mov edx, edi
cmp ecx, DWORD PTR [esi+8]
cmovae edx, esi
cmovae esi, edi
mov DWORD PTR tv263[ebp], edx
; 433 : __UNIT_TYPE v_bit_count = nv->UNIT_BIT_COUNT;
mov ecx, DWORD PTR [edx+12]
; 436 : if ((result = AllocateNumber(&nw, w_bit_count, &nw_light_check_code)) != PMC_STATUS_OK)
lea edx, DWORD PTR _nw_light_check_code$1[ebp]
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_inline_func.h
; 204 : return (x >= y ? x : y);
cmp DWORD PTR [esi+12], ecx
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_bitwiseor.c
; 436 : if ((result = AllocateNumber(&nw, w_bit_count, &nw_light_check_code)) != PMC_STATUS_OK)
push edx
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_inline_func.h
; 204 : return (x >= y ? x : y);
cmovae ecx, DWORD PTR [esi+12]
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_bitwiseor.c
; 436 : if ((result = AllocateNumber(&nw, w_bit_count, &nw_light_check_code)) != PMC_STATUS_OK)
push ecx
push eax
call _AllocateNumber
add esp, 12 ; 0000000cH
test eax, eax
jne SHORT $LN1@PMC_Bitwis
; 437 : return (result);
; 438 : BitwiseOr_X_X(nu->BLOCK, nu->UNIT_WORD_COUNT, nv->BLOCK, nv->UNIT_WORD_COUNT, nw->BLOCK);
mov eax, DWORD PTR _nw$[ebp]
push DWORD PTR [eax+32]
mov eax, DWORD PTR tv263[ebp]
push DWORD PTR [eax+8]
push DWORD PTR [eax+32]
push DWORD PTR [esi+8]
push DWORD PTR [esi+32]
call _BitwiseOr_X_X
; 439 : if ((result = CheckBlockLight(nw->BLOCK, nw_light_check_code)) != PMC_STATUS_OK)
mov eax, DWORD PTR _nw$[ebp]
push DWORD PTR _nw_light_check_code$1[ebp]
push DWORD PTR [eax+32]
call _CheckBlockLight
add esp, 28 ; 0000001cH
test eax, eax
jne SHORT $LN1@PMC_Bitwis
; 440 : return (result);
; 441 : CommitNumber(nw);
push DWORD PTR _nw$[ebp]
call _CommitNumber
add esp, 4
$LN11@PMC_Bitwis:
; 442 : }
; 443 : *w = nw;
mov eax, DWORD PTR _nw$[ebp]
pop edi
mov DWORD PTR [ebx], eax
; 444 : #ifdef _DEBUG
; 445 : if ((result = CheckNumber(*w)) != PMC_STATUS_OK)
; 446 : return (result);
; 447 : #endif
; 448 : return (PMC_STATUS_OK);
xor eax, eax
; 449 : }
pop esi
pop ebx
pop ebp
ret 12 ; 0000000cH
$LN19@PMC_Bitwis:
; 405 : return (PMC_STATUS_ARGUMENT_ERROR);
or eax, -1
$LN1@PMC_Bitwis:
pop edi
; 449 : }
pop esi
pop ebx
pop ebp
ret 12 ; 0000000cH
_PMC_BitwiseOr_X_X@12 ENDP
_TEXT ENDS
; Function compile flags: /Ogtp
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_bitwiseor.c
; COMDAT _PMC_BitwiseOr_X_L@16
_TEXT SEGMENT
_u$ = 8 ; size = 4
_v$ = 12 ; size = 8
_w$ = 20 ; size = 4
_PMC_BitwiseOr_X_L@16 PROC ; COMDAT
; 376 : {
push ebp
mov ebp, esp
push esi
; 377 : if (__UNIT_TYPE_BIT_COUNT * 2 < sizeof(v) * 8)
; 378 : {
; 379 : // _UINT64_T が 2 ワードで表現しきれない処理系には対応しない
; 380 : return (PMC_STATUS_INTERNAL_ERROR);
; 381 : }
; 382 : if (u == NULL)
mov esi, DWORD PTR _u$[ebp]
test esi, esi
je SHORT $LN8@PMC_Bitwis
; 383 : return (PMC_STATUS_ARGUMENT_ERROR);
; 384 : if (w == NULL)
cmp DWORD PTR _w$[ebp], 0
je SHORT $LN8@PMC_Bitwis
; 386 : PMC_STATUS_CODE result;
; 387 : if ((result = CheckNumber((NUMBER_HEADER*)u)) != PMC_STATUS_OK)
push esi
call _CheckNumber
add esp, 4
test eax, eax
jne SHORT $LN6@PMC_Bitwis
; 388 : return (result);
; 389 : if ((result = PMC_BitwiseOr_X_L_Imp((NUMBER_HEADER*)u, v, (NUMBER_HEADER**)w)) != PMC_STATUS_OK)
push DWORD PTR _w$[ebp]
push DWORD PTR _v$[ebp+4]
push DWORD PTR _v$[ebp]
push esi
call _PMC_BitwiseOr_X_L_Imp
add esp, 16 ; 00000010H
pop esi
; 390 : return (result);
; 391 : #ifdef _DEBUG
; 392 : if ((result = CheckNumber(*w)) != PMC_STATUS_OK)
; 393 : return (result);
; 394 : #endif
; 395 : return (PMC_STATUS_OK);
; 396 : }
pop ebp
ret 16 ; 00000010H
$LN8@PMC_Bitwis:
; 385 : return (PMC_STATUS_ARGUMENT_ERROR);
or eax, -1
$LN6@PMC_Bitwis:
pop esi
; 390 : return (result);
; 391 : #ifdef _DEBUG
; 392 : if ((result = CheckNumber(*w)) != PMC_STATUS_OK)
; 393 : return (result);
; 394 : #endif
; 395 : return (PMC_STATUS_OK);
; 396 : }
pop ebp
ret 16 ; 00000010H
_PMC_BitwiseOr_X_L@16 ENDP
_TEXT ENDS
; Function compile flags: /Ogtp
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_bitwiseor.c
; COMDAT _PMC_BitwiseOr_X_I@12
_TEXT SEGMENT
_u$ = 8 ; size = 4
_v$ = 12 ; size = 4
_w$ = 16 ; size = 4
_PMC_BitwiseOr_X_I@12 PROC ; COMDAT
; 252 : {
push ebp
mov ebp, esp
push esi
; 253 : if (__UNIT_TYPE_BIT_COUNT < sizeof(v) * 8)
; 254 : {
; 255 : // _UINT32_T が 1 ワードで表現しきれない処理系には対応しない
; 256 : return (PMC_STATUS_INTERNAL_ERROR);
; 257 : }
; 258 : if (u == NULL)
mov esi, DWORD PTR _u$[ebp]
test esi, esi
je SHORT $LN8@PMC_Bitwis
; 259 : return (PMC_STATUS_ARGUMENT_ERROR);
; 260 : if (w == NULL)
cmp DWORD PTR _w$[ebp], 0
je SHORT $LN8@PMC_Bitwis
; 262 : PMC_STATUS_CODE result;
; 263 : if ((result = CheckNumber((NUMBER_HEADER*)u)) != PMC_STATUS_OK)
push esi
call _CheckNumber
add esp, 4
test eax, eax
jne SHORT $LN6@PMC_Bitwis
; 264 : return (result);
; 265 : if ((result = PMC_BitwiseOr_X_I_Imp((NUMBER_HEADER*)u, v, (NUMBER_HEADER**)w)) != PMC_STATUS_OK)
push DWORD PTR _w$[ebp]
push DWORD PTR _v$[ebp]
push esi
call _PMC_BitwiseOr_X_I_Imp
add esp, 12 ; 0000000cH
pop esi
; 266 : return (result);
; 267 : #ifdef _DEBUG
; 268 : if ((result = CheckNumber(*w)) != PMC_STATUS_OK)
; 269 : return (result);
; 270 : #endif
; 271 : return (PMC_STATUS_OK);
; 272 : }
pop ebp
ret 12 ; 0000000cH
$LN8@PMC_Bitwis:
; 261 : return (PMC_STATUS_ARGUMENT_ERROR);
or eax, -1
$LN6@PMC_Bitwis:
pop esi
; 266 : return (result);
; 267 : #ifdef _DEBUG
; 268 : if ((result = CheckNumber(*w)) != PMC_STATUS_OK)
; 269 : return (result);
; 270 : #endif
; 271 : return (PMC_STATUS_OK);
; 272 : }
pop ebp
ret 12 ; 0000000cH
_PMC_BitwiseOr_X_I@12 ENDP
_TEXT ENDS
; Function compile flags: /Ogtp
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_bitwiseor.c
; COMDAT _PMC_BitwiseOr_L_X@16
_TEXT SEGMENT
_u$ = 8 ; size = 8
_v$ = 16 ; size = 4
_w$ = 20 ; size = 4
_PMC_BitwiseOr_L_X@16 PROC ; COMDAT
; 353 : {
push ebp
mov ebp, esp
push esi
; 354 : if (__UNIT_TYPE_BIT_COUNT * 2 < sizeof(u) * 8)
; 355 : {
; 356 : // _UINT64_T が 2 ワードで表現しきれない処理系には対応しない
; 357 : return (PMC_STATUS_INTERNAL_ERROR);
; 358 : }
; 359 : if (v == NULL)
mov esi, DWORD PTR _v$[ebp]
test esi, esi
je SHORT $LN8@PMC_Bitwis
; 360 : return (PMC_STATUS_ARGUMENT_ERROR);
; 361 : if (w == NULL)
cmp DWORD PTR _w$[ebp], 0
je SHORT $LN8@PMC_Bitwis
; 363 : PMC_STATUS_CODE result;
; 364 : if ((result = CheckNumber((NUMBER_HEADER*)v)) != PMC_STATUS_OK)
push esi
call _CheckNumber
add esp, 4
test eax, eax
jne SHORT $LN6@PMC_Bitwis
; 365 : return (result);
; 366 : if ((result = PMC_BitwiseOr_X_L_Imp((NUMBER_HEADER*)v, u, (NUMBER_HEADER**)w)) != PMC_STATUS_OK)
push DWORD PTR _w$[ebp]
push DWORD PTR _u$[ebp+4]
push DWORD PTR _u$[ebp]
push esi
call _PMC_BitwiseOr_X_L_Imp
add esp, 16 ; 00000010H
pop esi
; 367 : return (result);
; 368 : #ifdef _DEBUG
; 369 : if ((result = CheckNumber(*w)) != PMC_STATUS_OK)
; 370 : return (result);
; 371 : #endif
; 372 : return (PMC_STATUS_OK);
; 373 : }
pop ebp
ret 16 ; 00000010H
$LN8@PMC_Bitwis:
; 362 : return (PMC_STATUS_ARGUMENT_ERROR);
or eax, -1
$LN6@PMC_Bitwis:
pop esi
; 367 : return (result);
; 368 : #ifdef _DEBUG
; 369 : if ((result = CheckNumber(*w)) != PMC_STATUS_OK)
; 370 : return (result);
; 371 : #endif
; 372 : return (PMC_STATUS_OK);
; 373 : }
pop ebp
ret 16 ; 00000010H
_PMC_BitwiseOr_L_X@16 ENDP
_TEXT ENDS
; Function compile flags: /Ogtp
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_bitwiseor.c
; COMDAT _PMC_BitwiseOr_I_X@12
_TEXT SEGMENT
_u$ = 8 ; size = 4
_v$ = 12 ; size = 4
_w$ = 16 ; size = 4
_PMC_BitwiseOr_I_X@12 PROC ; COMDAT
; 229 : {
push ebp
mov ebp, esp
push esi
; 230 : if (__UNIT_TYPE_BIT_COUNT < sizeof(u) * 8)
; 231 : {
; 232 : // _UINT32_T が 1 ワードで表現しきれない処理系には対応しない
; 233 : return (PMC_STATUS_INTERNAL_ERROR);
; 234 : }
; 235 : if (v == NULL)
mov esi, DWORD PTR _v$[ebp]
test esi, esi
je SHORT $LN8@PMC_Bitwis
; 236 : return (PMC_STATUS_ARGUMENT_ERROR);
; 237 : if (w == NULL)
cmp DWORD PTR _w$[ebp], 0
je SHORT $LN8@PMC_Bitwis
; 239 : PMC_STATUS_CODE result;
; 240 : if ((result = CheckNumber((NUMBER_HEADER*)v)) != PMC_STATUS_OK)
push esi
call _CheckNumber
add esp, 4
test eax, eax
jne SHORT $LN6@PMC_Bitwis
; 241 : return (result);
; 242 : if ((result = PMC_BitwiseOr_X_I_Imp((NUMBER_HEADER*)v, u, (NUMBER_HEADER**)w)) != PMC_STATUS_OK)
push DWORD PTR _w$[ebp]
push DWORD PTR _u$[ebp]
push esi
call _PMC_BitwiseOr_X_I_Imp
add esp, 12 ; 0000000cH
pop esi
; 243 : return (result);
; 244 : #ifdef _DEBUG
; 245 : if ((result = CheckNumber(*w)) != PMC_STATUS_OK)
; 246 : return (result);
; 247 : #endif
; 248 : return (PMC_STATUS_OK);
; 249 : }
pop ebp
ret 12 ; 0000000cH
$LN8@PMC_Bitwis:
; 238 : return (PMC_STATUS_ARGUMENT_ERROR);
or eax, -1
$LN6@PMC_Bitwis:
pop esi
; 243 : return (result);
; 244 : #ifdef _DEBUG
; 245 : if ((result = CheckNumber(*w)) != PMC_STATUS_OK)
; 246 : return (result);
; 247 : #endif
; 248 : return (PMC_STATUS_OK);
; 249 : }
pop ebp
ret 12 ; 0000000cH
_PMC_BitwiseOr_I_X@12 ENDP
_TEXT ENDS
; Function compile flags: /Ogtp
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_bitwiseor.c
; COMDAT _Initialize_BitwiseOr
_TEXT SEGMENT
_feature$ = 8 ; size = 4
_Initialize_BitwiseOr PROC ; COMDAT
; 453 : return (PMC_STATUS_OK);
xor eax, eax
; 454 : }
ret 0
_Initialize_BitwiseOr ENDP
_TEXT ENDS
END
| 25.654474 | 121 | 0.625735 |
0ddfb0530f1fbf94f984c9bdc4de2567dcefb1b0 | 277 | asm | Assembly | oeis/292/A292432.asm | neoneye/loda-programs | 84790877f8e6c2e821b183d2e334d612045d29c0 | [
"Apache-2.0"
] | 11 | 2021-08-22T19:44:55.000Z | 2022-03-20T16:47:57.000Z | oeis/292/A292432.asm | neoneye/loda-programs | 84790877f8e6c2e821b183d2e334d612045d29c0 | [
"Apache-2.0"
] | 9 | 2021-08-29T13:15:54.000Z | 2022-03-09T19:52:31.000Z | oeis/292/A292432.asm | neoneye/loda-programs | 84790877f8e6c2e821b183d2e334d612045d29c0 | [
"Apache-2.0"
] | 3 | 2021-08-22T20:56:47.000Z | 2021-09-29T06:26:12.000Z | ; A292432: Number of normal multisets that cannot be expressed as the multiset-union of a set of sets.
; Submitted by Jamie Morken(s4)
; 0,1,1,3,5,9,16,27,46,76
mov $1,7
mov $2,1
mov $3,1
lpb $0
sub $0,1
div $1,7
add $1,$3
add $3,$2
mov $2,$1
lpe
mov $0,$2
sub $0,1
| 16.294118 | 102 | 0.635379 |
78ec7f56bd0e0e90239a65b07d251f318401ef67 | 301 | asm | Assembly | libsrc/graphics/vg5k/swapgfxbk.asm | teknoplop/z88dk | bb03fbfd6b2ab0f397a1358559089f9cd3706485 | [
"ClArtistic"
] | null | null | null | libsrc/graphics/vg5k/swapgfxbk.asm | teknoplop/z88dk | bb03fbfd6b2ab0f397a1358559089f9cd3706485 | [
"ClArtistic"
] | null | null | null | libsrc/graphics/vg5k/swapgfxbk.asm | teknoplop/z88dk | bb03fbfd6b2ab0f397a1358559089f9cd3706485 | [
"ClArtistic"
] | null | null | null | ;
; Philips VG-5000 Graphics Functions
;
; swapgfxbk () -- foo routine for fake swapping
;
; Stefano Bodrato - 2015
;
;
; $Id: swapgfxbk.asm,v 1.1 2015/10/09 13:02:43 stefano Exp $
;
PUBLIC swapgfxbk
PUBLIC swapgfxbk1
.swapgfxbk
ld ix,$47FA
ret
.swapgfxbk1
ret
| 10.37931 | 60 | 0.621262 |
414d8b81770ee3d891c4e5d43732a555ba318853 | 711 | asm | Assembly | oeis/115/A115113.asm | neoneye/loda-programs | 84790877f8e6c2e821b183d2e334d612045d29c0 | [
"Apache-2.0"
] | 11 | 2021-08-22T19:44:55.000Z | 2022-03-20T16:47:57.000Z | oeis/115/A115113.asm | neoneye/loda-programs | 84790877f8e6c2e821b183d2e334d612045d29c0 | [
"Apache-2.0"
] | 9 | 2021-08-29T13:15:54.000Z | 2022-03-09T19:52:31.000Z | oeis/115/A115113.asm | neoneye/loda-programs | 84790877f8e6c2e821b183d2e334d612045d29c0 | [
"Apache-2.0"
] | 3 | 2021-08-22T20:56:47.000Z | 2021-09-29T06:26:12.000Z | ; A115113: a(n) = 3*a(n-1) + 4*a(n-2), with a(0) = 2, a(1) = 6.
; Submitted by Jamie Morken(s4)
; 2,6,10,54,202,822,3274,13110,52426,209718,838858,3355446,13421770,53687094,214748362,858993462,3435973834,13743895350,54975581386,219902325558,879609302218,3518437208886,14073748835530,56294995342134,225179981368522,900719925474102,3602879701896394,14411518807585590,57646075230342346,230584300921369398,922337203685477578,3689348814741910326,14757395258967641290,59029581035870565174,236118324143482260682,944473296573929042742,3777893186295716170954,15111572745182864683830,60446290980731458735306
mov $1,4
mov $2,4
pow $2,$0
sub $1,$2
gcd $1,5
mul $1,2
add $2,$1
mov $0,$2
sub $0,6
div $0,5
mul $0,4
add $0,2
| 41.823529 | 501 | 0.804501 |
ac68f3bf90de6c5dbd16b729cfe23c475200159f | 4,246 | asm | Assembly | Transynther/x86/_processed/NONE/_xt_/i9-9900K_12_0xa0_notsx.log_21829_963.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_0xa0_notsx.log_21829_963.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_0xa0_notsx.log_21829_963.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:
ret
.global s_faulty_load
s_faulty_load:
push %r11
push %r13
push %r15
push %r9
push %rcx
push %rdi
push %rsi
// REPMOV
lea addresses_PSE+0x4911, %rsi
lea addresses_PSE+0x15a41, %rdi
nop
and %r13, %r13
mov $32, %rcx
rep movsw
nop
nop
nop
nop
nop
cmp $51583, %rcx
// Store
lea addresses_UC+0x131e1, %rdi
nop
nop
xor %rcx, %rcx
movl $0x51525354, (%rdi)
nop
nop
nop
nop
sub $65399, %rcx
// Faulty Load
lea addresses_PSE+0x15a41, %r15
xor %rcx, %rcx
mov (%r15), %rsi
lea oracles, %r13
and $0xff, %rsi
shlq $12, %rsi
mov (%r13,%rsi,1), %rsi
pop %rsi
pop %rdi
pop %rcx
pop %r9
pop %r15
pop %r13
pop %r11
ret
/*
<gen_faulty_load>
[REF]
{'src': {'type': 'addresses_PSE', 'AVXalign': True, 'size': 32, 'NT': False, 'same': False, 'congruent': 0}, 'OP': 'LOAD'}
{'src': {'type': 'addresses_PSE', 'congruent': 4, 'same': False}, 'OP': 'REPM', 'dst': {'type': 'addresses_PSE', 'congruent': 0, 'same': True}}
{'OP': 'STOR', 'dst': {'type': 'addresses_UC', 'AVXalign': False, 'size': 4, 'NT': False, 'same': False, 'congruent': 3}}
[Faulty Load]
{'src': {'type': 'addresses_PSE', 'AVXalign': False, 'size': 8, 'NT': False, 'same': True, 'congruent': 0}, 'OP': 'LOAD'}
<gen_prepare_buffer>
{'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
*/
| 60.657143 | 2,999 | 0.660857 |
b35f9295c79e985fee55d0a008e82919663a8470 | 578 | asm | Assembly | programs/oeis/171/A171089.asm | karttu/loda | 9c3b0fc57b810302220c044a9d17db733c76a598 | [
"Apache-2.0"
] | 1 | 2021-03-15T11:38:20.000Z | 2021-03-15T11:38:20.000Z | programs/oeis/171/A171089.asm | karttu/loda | 9c3b0fc57b810302220c044a9d17db733c76a598 | [
"Apache-2.0"
] | null | null | null | programs/oeis/171/A171089.asm | karttu/loda | 9c3b0fc57b810302220c044a9d17db733c76a598 | [
"Apache-2.0"
] | null | null | null | ; A171089: a(n) = 2*(Lucas(n)^2 - (-1)^n)).
; 6,4,16,34,96,244,646,1684,4416,11554,30256,79204,207366,542884,1421296,3720994,9741696,25504084,66770566,174807604,457652256,1198149154,3136795216,8212236484,21499914246,56287506244,147362604496,385800307234,1010038317216,2644314644404,6922905616006,18124402203604,47450300994816,124226500780834,325229201347696,851461103262244,2229154108439046,5836001222054884
mov $2,$0
cal $0,240926 ; a(n) = 2 + L(2*n) = 2 + A005248(n), n >= 0, with the Lucas numbers (A000032).
mov $1,$0
gcd $2,2
mul $2,2
add $1,$2
sub $1,7
mul $1,2
add $1,4
| 44.461538 | 363 | 0.754325 |
27dd80b85889263777b5a167b354d2d2d031b08a | 124 | asm | Assembly | code/4-S-1.asm | gdzhang2012/Assembly-Language-by-Wangshuang | 7c53cfc60d83c19165e674d66015759f49663985 | [
"Apache-2.0"
] | null | null | null | code/4-S-1.asm | gdzhang2012/Assembly-Language-by-Wangshuang | 7c53cfc60d83c19165e674d66015759f49663985 | [
"Apache-2.0"
] | null | null | null | code/4-S-1.asm | gdzhang2012/Assembly-Language-by-Wangshuang | 7c53cfc60d83c19165e674d66015759f49663985 | [
"Apache-2.0"
] | null | null | null | assume cs:codesg
codesg segment
mov ax,0123h
mov bx,0456h
add ax,bx
add ax,ax
mov ax,4c00h
int 21h
codesg ends
end
| 8.857143 | 16 | 0.725806 |
9e31b9cc20742843d9dbf4b3d2571f49c59e23b2 | 59 | asm | Assembly | libsrc/target/zx/_zx_printf.asm | Frodevan/z88dk | f27af9fe840ff995c63c80a73673ba7ee33fffac | [
"ClArtistic"
] | 640 | 2017-01-14T23:33:45.000Z | 2022-03-30T11:28:42.000Z | libsrc/target/zx/_zx_printf.asm | Frodevan/z88dk | f27af9fe840ff995c63c80a73673ba7ee33fffac | [
"ClArtistic"
] | 1,600 | 2017-01-15T16:12:02.000Z | 2022-03-31T12:11:12.000Z | libsrc/target/zx/_zx_printf.asm | Frodevan/z88dk | f27af9fe840ff995c63c80a73673ba7ee33fffac | [
"ClArtistic"
] | 215 | 2017-01-17T10:43:03.000Z | 2022-03-23T17:25:02.000Z | PUBLIC _zx_printf
EXTERN _printk
defc _zx_printf = _printk
| 14.75 | 25 | 0.847458 |
6ce49ee34d28fce91818172177b8ceeed20fb2eb | 449 | asm | Assembly | _maps/obj51.asm | NatsumiFox/AMPS-Sonic-1-2005 | ac8730799f1b96291358c77a4b64529de94ce8a4 | [
"Apache-2.0"
] | 2 | 2020-04-09T19:36:35.000Z | 2021-01-05T14:20:17.000Z | _maps/obj51.asm | NatsumiFox/AMPS-Sonic-1-2005 | ac8730799f1b96291358c77a4b64529de94ce8a4 | [
"Apache-2.0"
] | null | null | null | _maps/obj51.asm | NatsumiFox/AMPS-Sonic-1-2005 | ac8730799f1b96291358c77a4b64529de94ce8a4 | [
"Apache-2.0"
] | 1 | 2020-06-17T14:16:35.000Z | 2020-06-17T14:16:35.000Z | ; ---------------------------------------------------------------------------
; Sprite mappings - smashable green block (MZ)
; ---------------------------------------------------------------------------
dc.w byte_FDD8-Map_obj51
dc.w byte_FDE3-Map_obj51
byte_FDD8: dc.b 2
dc.b $F0, $D, 0, 0, $F0
dc.b 0, $D, 0, 0, $F0
byte_FDE3: dc.b 4
dc.b $F0, 5, $80, 0, $F0
dc.b 0, 5, $80, 0, $F0
dc.b $F0, 5, $80, 0, 0
dc.b 0, 5, $80, 0, 0
even | 32.071429 | 77 | 0.36971 |
5cb6fbadc4b7054a6045e94ebc38323dc5136763 | 1,210 | asm | Assembly | programs/oeis/298/A298364.asm | karttu/loda | 9c3b0fc57b810302220c044a9d17db733c76a598 | [
"Apache-2.0"
] | 1 | 2021-03-15T11:38:20.000Z | 2021-03-15T11:38:20.000Z | programs/oeis/298/A298364.asm | karttu/loda | 9c3b0fc57b810302220c044a9d17db733c76a598 | [
"Apache-2.0"
] | null | null | null | programs/oeis/298/A298364.asm | karttu/loda | 9c3b0fc57b810302220c044a9d17db733c76a598 | [
"Apache-2.0"
] | null | null | null | ; A298364: Permutation of the natural numbers partitioned into quadruples [4k-2, 4k-1, 4k-3, 4k] for k > 0.
; 2,3,1,4,6,7,5,8,10,11,9,12,14,15,13,16,18,19,17,20,22,23,21,24,26,27,25,28,30,31,29,32,34,35,33,36,38,39,37,40,42,43,41,44,46,47,45,48,50,51,49,52,54,55,53,56,58,59,57,60,62,63,61,64,66,67,65,68,70,71,69,72,74,75,73,76,78,79,77,80,82,83,81,84,86,87,85,88,90,91,89,92,94,95,93,96,98,99,97,100,102,103,101,104,106,107,105,108,110,111,109,112,114,115,113,116,118,119,117,120,122,123,121,124,126,127,125,128,130,131,129,132,134,135,133,136,138,139,137,140,142,143,141,144,146,147,145,148,150,151,149,152,154,155,153,156,158,159,157,160,162,163,161,164,166,167,165,168,170,171,169,172,174,175,173,176,178,179,177,180,182,183,181,184,186,187,185,188,190,191,189,192,194,195,193,196,198,199,197,200,202,203,201,204,206,207,205,208,210,211,209,212,214,215,213,216,218,219,217,220,222,223,221,224,226,227,225,228,230,231,229,232,234,235,233,236,238,239,237,240,242,243,241,244,246,247,245,248,250,251
mov $2,13
mov $10,1
lpb $2,6
add $0,$10
mov $2,$10
mov $4,2
mul $4,$1
add $1,9
mod $3,2
add $4,$0
add $4,5
add $3,$4
mod $3,4
mod $4,4
lpe
mul $0,2
mov $1,$0
sub $1,6
div $1,2
add $1,1
| 50.416667 | 893 | 0.679339 |
1f0a2636e1619015da00f713ef2cf7c3ca237ec0 | 5,585 | asm | Assembly | Transynther/x86/_processed/P/_zr_/i9-9900K_12_0xa0_notsx.log_128_1061.asm | ljhsiun2/medusa | 67d769b8a2fb42c538f10287abaf0e6dbb463f0c | [
"MIT"
] | 9 | 2020-08-13T19:41:58.000Z | 2022-03-30T12:22:51.000Z | Transynther/x86/_processed/P/_zr_/i9-9900K_12_0xa0_notsx.log_128_1061.asm | ljhsiun2/medusa | 67d769b8a2fb42c538f10287abaf0e6dbb463f0c | [
"MIT"
] | 1 | 2021-04-29T06:29:35.000Z | 2021-05-13T21:02:30.000Z | Transynther/x86/_processed/P/_zr_/i9-9900K_12_0xa0_notsx.log_128_1061.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 %r12
push %r13
push %r8
push %rax
push %rcx
push %rdi
push %rdx
push %rsi
lea addresses_UC_ht+0x14e3b, %rdx
nop
nop
nop
nop
nop
xor $2552, %r12
mov $0x6162636465666768, %r10
movq %r10, (%rdx)
nop
nop
nop
xor %r8, %r8
lea addresses_WT_ht+0x1393b, %rcx
nop
nop
nop
nop
nop
cmp %rax, %rax
mov (%rcx), %r13d
nop
nop
nop
sub %r8, %r8
lea addresses_A_ht+0x17c43, %r13
and $5998, %rax
movups (%r13), %xmm6
vpextrq $0, %xmm6, %r8
nop
nop
nop
and %r12, %r12
lea addresses_WT_ht+0xd6bb, %r12
nop
nop
nop
cmp $11750, %r8
mov $0x6162636465666768, %rcx
movq %rcx, (%r12)
nop
and %r12, %r12
lea addresses_A_ht+0x193b5, %r12
nop
nop
dec %rdx
movl $0x61626364, (%r12)
nop
sub %rax, %rax
lea addresses_D_ht+0x14f3b, %rsi
lea addresses_UC_ht+0x1976f, %rdi
nop
nop
nop
cmp %rax, %rax
mov $53, %rcx
rep movsq
nop
nop
nop
nop
nop
sub $6485, %rax
lea addresses_WC_ht+0x243b, %r8
nop
nop
nop
nop
add $56240, %r12
mov $0x6162636465666768, %rdi
movq %rdi, (%r8)
nop
nop
and $47508, %r13
lea addresses_A_ht+0x19e83, %rsi
lea addresses_normal_ht+0x10dfb, %rdi
nop
and $23334, %rdx
mov $107, %rcx
rep movsw
nop
nop
nop
nop
nop
and %r13, %r13
lea addresses_normal_ht+0x6d3b, %r10
clflush (%r10)
nop
nop
nop
sub $27408, %rsi
mov $0x6162636465666768, %r13
movq %r13, %xmm3
and $0xffffffffffffffc0, %r10
vmovaps %ymm3, (%r10)
nop
nop
nop
nop
nop
sub %r10, %r10
lea addresses_A_ht+0xa93b, %rsi
lea addresses_WT_ht+0x185fb, %rdi
clflush (%rsi)
nop
nop
nop
nop
mfence
mov $10, %rcx
rep movsb
nop
nop
inc %r10
lea addresses_UC_ht+0xb87b, %r12
nop
nop
cmp $59547, %rdx
movups (%r12), %xmm7
vpextrq $0, %xmm7, %r8
nop
nop
nop
nop
nop
and $46404, %r8
lea addresses_D_ht+0x8eb, %rcx
xor %rdi, %rdi
mov (%rcx), %r12
nop
nop
and $40241, %r12
lea addresses_D_ht+0xa8bb, %rsi
and $7707, %r12
movl $0x61626364, (%rsi)
nop
nop
nop
nop
nop
cmp %r12, %r12
lea addresses_D_ht+0x1953b, %r13
nop
nop
nop
sub %r10, %r10
mov (%r13), %rsi
sub %rcx, %rcx
pop %rsi
pop %rdx
pop %rdi
pop %rcx
pop %rax
pop %r8
pop %r13
pop %r12
pop %r10
ret
.global s_faulty_load
s_faulty_load:
push %r11
push %r12
push %r13
push %r14
push %r8
push %rsi
// Store
lea addresses_D+0x4e3b, %r13
nop
nop
nop
nop
add $55113, %r8
movw $0x5152, (%r13)
xor %r12, %r12
// Store
lea addresses_D+0x176b, %r12
nop
and %rsi, %rsi
mov $0x5152535455565758, %r13
movq %r13, (%r12)
nop
nop
add $10924, %r8
// Load
lea addresses_D+0x14420, %rsi
nop
nop
nop
nop
cmp %r12, %r12
mov (%rsi), %r14w
nop
nop
nop
sub $41422, %rsi
// Faulty Load
mov $0x93b, %r12
nop
nop
cmp %rsi, %rsi
mov (%r12), %r8
lea oracles, %r12
and $0xff, %r8
shlq $12, %r8
mov (%r12,%r8,1), %r8
pop %rsi
pop %r8
pop %r14
pop %r13
pop %r12
pop %r11
ret
/*
<gen_faulty_load>
[REF]
{'src': {'type': 'addresses_P', 'AVXalign': False, 'size': 4, 'NT': False, 'same': False, 'congruent': 0}, 'OP': 'LOAD'}
{'OP': 'STOR', 'dst': {'type': 'addresses_D', 'AVXalign': False, 'size': 2, 'NT': False, 'same': False, 'congruent': 6}}
{'OP': 'STOR', 'dst': {'type': 'addresses_D', 'AVXalign': False, 'size': 8, 'NT': False, 'same': False, 'congruent': 2}}
{'src': {'type': 'addresses_D', 'AVXalign': False, 'size': 2, 'NT': False, 'same': False, 'congruent': 0}, 'OP': 'LOAD'}
[Faulty Load]
{'src': {'type': 'addresses_P', 'AVXalign': False, 'size': 8, 'NT': False, 'same': True, 'congruent': 0}, 'OP': 'LOAD'}
<gen_prepare_buffer>
{'OP': 'STOR', 'dst': {'type': 'addresses_UC_ht', 'AVXalign': False, 'size': 8, 'NT': False, 'same': False, 'congruent': 8}}
{'src': {'type': 'addresses_WT_ht', 'AVXalign': False, 'size': 4, 'NT': False, 'same': False, 'congruent': 9}, 'OP': 'LOAD'}
{'src': {'type': 'addresses_A_ht', 'AVXalign': False, 'size': 16, 'NT': False, 'same': False, 'congruent': 2}, 'OP': 'LOAD'}
{'OP': 'STOR', 'dst': {'type': 'addresses_WT_ht', 'AVXalign': False, 'size': 8, 'NT': False, 'same': False, 'congruent': 5}}
{'OP': 'STOR', 'dst': {'type': 'addresses_A_ht', 'AVXalign': False, 'size': 4, 'NT': True, 'same': False, 'congruent': 1}}
{'src': {'type': 'addresses_D_ht', 'congruent': 7, 'same': False}, 'OP': 'REPM', 'dst': {'type': 'addresses_UC_ht', 'congruent': 2, 'same': False}}
{'OP': 'STOR', 'dst': {'type': 'addresses_WC_ht', 'AVXalign': False, 'size': 8, 'NT': True, 'same': False, 'congruent': 4}}
{'src': {'type': 'addresses_A_ht', 'congruent': 1, 'same': False}, 'OP': 'REPM', 'dst': {'type': 'addresses_normal_ht', 'congruent': 6, 'same': False}}
{'OP': 'STOR', 'dst': {'type': 'addresses_normal_ht', 'AVXalign': True, 'size': 32, 'NT': True, 'same': False, 'congruent': 9}}
{'src': {'type': 'addresses_A_ht', 'congruent': 11, 'same': False}, 'OP': 'REPM', 'dst': {'type': 'addresses_WT_ht', 'congruent': 6, 'same': False}}
{'src': {'type': 'addresses_UC_ht', 'AVXalign': False, 'size': 16, 'NT': False, 'same': False, 'congruent': 6}, 'OP': 'LOAD'}
{'src': {'type': 'addresses_D_ht', 'AVXalign': False, 'size': 8, 'NT': False, 'same': True, 'congruent': 2}, 'OP': 'LOAD'}
{'OP': 'STOR', 'dst': {'type': 'addresses_D_ht', 'AVXalign': False, 'size': 4, 'NT': False, 'same': False, 'congruent': 7}}
{'src': {'type': 'addresses_D_ht', 'AVXalign': False, 'size': 8, 'NT': False, 'same': False, 'congruent': 10}, 'OP': 'LOAD'}
{'00': 128}
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
*/
| 21.563707 | 383 | 0.646553 |
9b92e311b0227532f767ebc1dd050b4ffdaad4e1 | 450 | asm | Assembly | 07/test.asm | InversionSpaces/nand2tetrisSolutions | 5cebf69aea2d25950890b16c6c8b5b409fc685fc | [
"MIT"
] | null | null | null | 07/test.asm | InversionSpaces/nand2tetrisSolutions | 5cebf69aea2d25950890b16c6c8b5b409fc685fc | [
"MIT"
] | null | null | null | 07/test.asm | InversionSpaces/nand2tetrisSolutions | 5cebf69aea2d25950890b16c6c8b5b409fc685fc | [
"MIT"
] | null | null | null | @256
D=A
@SP
M=D
@111
D=A
@SP
A=M
M=D
@SP
M=M+1
@333
D=A
@SP
A=M
M=D
@SP
M=M+1
@888
D=A
@SP
A=M
M=D
@SP
M=M+1
@STATIC8
D=A
@R13
M=D
@SP
M=M-1
A=M
D=M
@R13
A=M
M=D
@STATIC3
D=A
@R13
M=D
@SP
M=M-1
A=M
D=M
@R13
A=M
M=D
@STATIC1
D=A
@R13
M=D
@SP
M=M-1
A=M
D=M
@R13
A=M
M=D
@STATIC3
D=M
@SP
A=M
M=D
@SP
M=M+1
@STATIC1
D=M
@SP
A=M
M=D
@SP
M=M+1
@SP
M=M-1
A=M
D=M
@SP
A=M
A=A-1
M=M-D
@STATIC8
D=M
@SP
A=M
M=D
@SP
M=M+1
@SP
M=M-1
A=M
D=M
@SP
A=M
A=A-1
M=D+M
| 4.6875 | 8 | 0.544444 |
ae761949903925cbb2fa8a11abefb1cf21f0b1a2 | 958 | asm | Assembly | oeis/208/A208388.asm | neoneye/loda-programs | 84790877f8e6c2e821b183d2e334d612045d29c0 | [
"Apache-2.0"
] | 11 | 2021-08-22T19:44:55.000Z | 2022-03-20T16:47:57.000Z | oeis/208/A208388.asm | neoneye/loda-programs | 84790877f8e6c2e821b183d2e334d612045d29c0 | [
"Apache-2.0"
] | 9 | 2021-08-29T13:15:54.000Z | 2022-03-09T19:52:31.000Z | oeis/208/A208388.asm | neoneye/loda-programs | 84790877f8e6c2e821b183d2e334d612045d29c0 | [
"Apache-2.0"
] | 3 | 2021-08-22T20:56:47.000Z | 2021-09-29T06:26:12.000Z | ; A208388: Number of n X 4 0..2 arrays with new values 0..2 introduced in row major order and no element equal to more than two of its immediate leftward or upward or right-upward antidiagonal neighbors.
; Submitted by Christian Krause
; 14,1017,76806,5800644,438083928,33085555344,2498731184736,188712490047552,14252194920963456,1076373164351510784,81291281473560135168,6139387958073915884544,463666998680569442359296,35017673933232616647462912,2644651206973178365282246656,199732855468365181562142081024,15084489572144719377572637278208,1139230824686137526159283318226944,86038501051549242090512917243232256,6497913770229041447937247511029481472,490744060499551377327972345817484230656,37062623702237659184800157371731740196864
mul $0,2
add $0,1
seq $0,208393 ; Number of 2 X n 0..2 arrays with new values 0..2 introduced in row major order and no element equal to more than two of its immediate leftward or upward or right-upward antidiagonal neighbors.
| 119.75 | 493 | 0.865344 |
9cd66f5dceae1076d92b6d68c6f2697b76ec096c | 261 | asm | Assembly | SystemsProgramming/p3.asm | aaiijmrtt/JUCSE | 3413b7280bc4883c056a9444e8dc56144b692e32 | [
"MIT"
] | 6 | 2016-04-21T15:07:02.000Z | 2020-11-26T14:47:13.000Z | SystemsProgramming/p3.asm | aaiijmrtt/JUCSEsem2 | 3413b7280bc4883c056a9444e8dc56144b692e32 | [
"MIT"
] | null | null | null | SystemsProgramming/p3.asm | aaiijmrtt/JUCSEsem2 | 3413b7280bc4883c056a9444e8dc56144b692e32 | [
"MIT"
] | 5 | 2015-08-09T17:31:10.000Z | 2018-03-19T10:45:38.000Z | %include "util.mac"
extern buffer, store, newline, newlinesize
section .text
global _start
_start:
mov ecx, 26
again:
mov [buffer], byte 40h
add [buffer], cl
mov [store], cl
write buffer, 1
mov cl, [store]
loop again
write newline, newlinesize
exit
| 14.5 | 42 | 0.712644 |
e5367f63e40fe6ac8c4051208082aec0bb6f8625 | 68,544 | asm | Assembly | game.asm | eightbitjim/spaceship-minus-one | 1041f05837d18d9ed6d9782c38ce6328f00a2a00 | [
"MIT"
] | 1 | 2018-09-05T07:02:51.000Z | 2018-09-05T07:02:51.000Z | game.asm | eightbitjim/spaceship-minus-one | 1041f05837d18d9ed6d9782c38ce6328f00a2a00 | [
"MIT"
] | 3 | 2017-11-24T07:37:59.000Z | 2017-11-24T08:04:39.000Z | game.asm | eightbitjim/viccy-spaceship | 1041f05837d18d9ed6d9782c38ce6328f00a2a00 | [
"MIT"
] | null | null | null | ; MIT License
; Copyright (c) 2017 James Lean
; Permission is hereby granted, free of charge, to any person obtaining a copy
; of this software and associated documentation files (the "Software"), to deal
; in the Software without restriction, including without limitation the rights
; to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
; copies of the Software, and to permit persons to whom the Software is
; furnished to do so, subject to the following conditions:
; The above copyright notice and this permission notice shall be included in all
; copies or substantial portions of the Software.
; THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
; IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
; FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
; AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
; LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
; OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
; SOFTWARE.
processor 6502
org $1200
; zero bytes padding to make an empty basic program
dc.b 0,0,0,0
start subroutine
jsr onceOnlyInit
jsr init
restart
jsr startScreen
jsr init
jsr thrust ; give the ship a short thrust to start off
jsr drawline
jsr scrollNow
jmp smoothScrollLoop
welcome dc.b 147,31, 18, "----------------000000",146,0
startMessage dc.b 19,17,17,17,17,17,17,18, 5,29, 29, 29, " SPACE SHIP -1 ", 13
dc.b 17,17,17,17, 159, 29, 29, 29, 18, " SPACE OR FIRE ",13,0
welcometerminator dc 0
enabled equ 1
disabled equ 4
ntscOrPalLocation equ $9000
isNtsc equ 5
rasterline equ $9004
borderPaper equ $900f
joystickDDR1 equ $9113
joystickDDR2 equ $9122
joystickIn1 equ $9111
joystickIn2 equ $9120
colorstart equ $9400
directionUp equ $ff
directionDown equ $01
screenMemoryPage equ 648 ; screen memory page for operating system
CHROUT equ $ffd2 ; ROM routine
screenstart equ $1000 ; $1e00 for unexpanded VIC, $1000 for expanded
screenstarthigh equ $10 ; $1e for unexpanded VIC, $10 for expanded
colorstarthigh equ $94 ; $94 for expanded VIC, $96 for unexpanded VIC
screenwidth equ 22
screenheight equ 23
fuelIncreaseAmount equ 10
shipYImpulsePAL equ 100
shipYImpulseNTSC equ 85
shipXImpulsePAL equ 30
shipXImpulseNTSC equ 25
rasterTriggerLinePAL equ 130
rasterTriggerLineNTSC equ 95
gravity equ 5
keypress equ 197 ; zero page location
keyspace equ 32
nokey equ 64
charDefinitionPointer equ 36869
nextLineLength equ 22 ; 22 positions in all
amountToIncreaseSpeedBy equ 20
; zero page variables
shipy equ 254
shipMinorY equ 253
cursor equ 251 ; also 252
colorcursor equ 243
shipdy equ 207
jetSound equ 205
scrollCounter equ 204
lastkey equ 179
fuel equ 178
shipdx equ 177
shipMinorX equ 176
shipx equ 171
shipDirection equ 170
;ntscOrPal equ 169
diff equ 166
charReplaced equ 165
character equ 164 ; put in zero page ; Every 1 and 8 frames during refresh * speed up. Maybe even self modifying code.
charReplaced2 equ 151
towerTopCharacter equ 150
towerMiddleCharacter equ 147
distanceBetweenTowers equ 146
gapWidth equ 143
minShipDx equ 142
;physicsCountdownInitialValue equ 141
progressCounterLo equ 140
progressCounterHi equ 139
topTowerEdgeCharacter equ 138
topTowerMiddleCharacter equ 137
shipToBeDrawnAt1 equ 23 ; +1
shipToBeDrawnAt2 equ 25 ; +1
nextLine equ 0 ; put at start of zero page
towercharacters equ 27; 4 bytes
towerTopCharacters equ 31; 4 bytes
topTowerCharacters equ 35; 4 bytes
topTowerEdgeCharacters equ 39; 4 bytes
;framesSinceLastScroll equ 43
lastFrameWasScroll equ 43
; non zero page variables
levelNumber dc.b 0 ; infrequent
randseed dc 234, 17 ; Occasionally
shipReplaceCharacter dc 0 ; either 'spacePrintable' if OK or 'explodePrintable' if crashing
rocketProbability dc 1
horizontalScreenPosition equ $9000 ; bottom 6 bits only
verticalScreenPosition equ $9001
initialHorizontalScreenPosition dc.b 0
initialVerticalScreenPosition dc.b 0
.outOfFuel
jmp restart
collision subroutine
; if end of game, return with zero flag not set
; what have we collided with?
cmp #fuelLeftPrintable
beq .collectFuelLeft
cmp #fuelRightPrintable
beq .collectFuelRight
; explosion?
cmp #explodePrintable
beq .finishedNotFatal
; collided with something. Draw an explosion
dec shipToBeDrawnAt1
dec shipToBeDrawnAt1
dec shipToBeDrawnAt2
dec shipToBeDrawnAt2
lda #explodePrintable
ldy #5
.explosionLoop
sta (shipToBeDrawnAt1),y
sta (shipToBeDrawnAt2),y
dey
bne .explosionLoop
jsr explosionEffect
jsr updateBonuses
lda #0
sta shipdy
dec fuel
lda fuel
cmp #255 ; wrapped around, i.e. no fuel left
bne .explosionDone
lda #explodePrintable
sta shipReplaceCharacter
lda #0
sta fuel
.explosionDone
rts ; zero flag set, indicates fatal
.collectFuelLeft
lda #spacePrintable
ldy #1
sta (shipToBeDrawnAt1),y
sta (shipToBeDrawnAt2),y
jmp .increaseFuelNow
.collectFuelRight
lda #spacePrintable
ldy #0
dec shipToBeDrawnAt1
dec shipToBeDrawnAt2
sta (shipToBeDrawnAt1),y
sta (shipToBeDrawnAt2),y
inc shipToBeDrawnAt1
inc shipToBeDrawnAt2
jmp .increaseFuelNow
.increaseFuelNow
jsr increaseScoreBy100
;lda #128
;sta fuelSoundCount
jsr bonusSound1
lda #fuelIncreaseAmount
jsr increaseFuel
.finishedNotFatal
lda #1 ; clear zero flag to indicate non-fatal
rts
endGame
; End of game
jsr explode
jsr stopSound
jmp restart
smoothScrollLoop
lda lastFrameWasScroll
cmp #0
beq .normal
lda #0
sta lastFrameWasScroll
jmp dontdrawship
.normal
jsr clearship
jsr workOutShipPosition
jsr drawship
dontdrawship
lda charReplaced
cmp #spacePrintable
beq .doneCollision1
jsr collision ; deal with the collision. Returns with zero flag not set if fatal
.doneCollision1
lda charReplaced2
cmp #spacePrintable
beq .doneCollision2
; move cursor up one line so collected object is cleared
lda #22 ; screen width
jsr subcursor
lda charReplaced2
jsr collision ; deal with the collision. Returns with zero flag set if fatal
.doneCollision2
jsr control
jsr updateSound
jsr physics
beq endGame
jmp smoothScrollLoop
scrollNow
jsr clearship
jsr workOutShipPosition
jsr scroll
lda #8
sta scrollCounter
sta lastFrameWasScroll
rts
prepareLine
jsr drawline
jmp donePrepareLine
smoothScroll subroutine
; first scroll the double character scollables
ldx #8 * numberOfScrollableCharacters
.loop
dex
clc
rol rightEdges,x
rol leftEdges,x
cpx #0
bne .loop
; next scroll the single character scrollables
ldx #8 * numberOfSingleScrollableChars
.singleLoop
dex
lda singleScrollable,x
asl
bcc .noWrapAround
ora #1 ; set bottom bit if it fell off the top
.noWrapAround
sta singleScrollable,x
cpx #0
bne .singleLoop
.finished
lda scrollCounter
cmp #1
bne .finishedSmoothScroll
.resetScroll
ldx #8 * numberOfScrollableCharacters ; 8 bytes per character
.loop2
dex
; copy back from left to right and clear the left
lda leftEdges,x
sta rightEdges,x
lda #0
sta leftEdges,x
cpx #0
bne .loop2
.finishedSmoothScroll
rts
handleFullScroll
dec scrollCounter
beq scrollNow
lda scrollCounter
cmp #5
beq updatePeriodicNow
cmp #6
beq prepareLine
cmp #7
beq updateFrame
donePrepareLine
rts
updatePeriodicNow
jmp updatePeriodic
updateFrame subroutine
; update positions of characters. Happens out of phase with full character scrolling
lda #screenHeight - 4
sta temp2
ldx #screenstarthigh ; put start of screen hi in cursor position
ldy #0 ; screen scroll start lo
stx.z colorcursor + 1
sty.z colorcursor
ldy #22 ; current offset from cursor
ldx #22 ; 22-x position
.loop
lda (colorcursor),y
cmp #spacePrintable
beq .space
cmp #explodePrintable
beq .explosion
cmp #baddyLeftPrintable
beq .baddy
.space
.doneChange
inc colorcursor
beq .pageJump
.donePageJump
dex
beq .resetx
.doneResetX
jmp .loop
.done
jmp donePrepareLine
.resetx
ldx #22
dec temp2
lda #255
cmp temp2
beq .done ; end of screen?
jmp .loop
.pageJump
inc colorcursor + 1
jmp .donePageJump
.explosion
jsr random
and #3
beq .explosionPropogate
jmp .doneChange
.explosionPropogate
lda temp2
cmp #0
beq .doneChange
lda #spacePrintable
sta (colorcursor),y
ldy #23 + 22
lda #explodePrintable
sta (colorcursor),y
ldy #22
jmp .doneChange
.baddy
; if we are at the far end of the screen, don't move, as only half of the
; baddy will have been drawn
cpx #1;21
beq .doneChange
; if on the ground (1 above ground, as 2 high), randomly launch
lda temp2
cmp #1
bne .flying
jsr random
and #$7
beq .flying
ldy #22 + 22
jmp .drawBottomOnly
.flying
; clear space below the rocket
lda #spacePrintable
ldy #23 + 22
sta (colorcursor),y
dey
sta (colorcursor),y
; have we reached the top of the screen?
ldy temp2
cpy #screenHeight - 4
beq .notDrawNextBaddy
; draw whole rocket
; first the top
ldy #0
lda #baddyLeftPrintable
sta (colorcursor),y
lda #baddyRightPrintable
iny
sta (colorcursor),y
; then the bottom
ldy #22
.drawBottomOnly
lda #baddyBottomLeftPrintable
sta (colorcursor),y
lda #baddyBottomRightPrintable
iny
sta (colorcursor),y
.notDrawNextBaddy
ldy #22
jmp .doneChange
updateBonuses subroutine
; update the fuel and bonus indicator
ldx fuel
cpx #0
beq .zero
cpx #16
bmi .gotValue
ldx #16 ; max value printable
.gotValue
lda #disabled
sta colorstart,x
lda #enabled
.loop
dex
.zero
sta colorstart,x
cpx #0
bne .loop
rts
decreaseFuel subroutine
lda #0
cmp fuel
beq .doneIncrease2
dec fuel
jmp .doneIncrease
increaseFuel
; draw fuel on screen
ldx #8 ; digit number 3, plus "SCORE" text
lda #255
cmp fuel
beq .doneIncrease ; already full
inc fuel
.doneIncrease
jsr updateBonuses
.doneIncrease2
rts
; Increase score by one and update the onscreen counter
updatePeriodic subroutine
; now decrease progress counter. If reached zero, move to next level before returning
ldx progressCounterLo
dex
stx progressCounterLo
cpx #35 ; near end of level?
bne .notNearEnd
lda progressCounterHi
cmp #1
bne .notNearEnd
; near end of level. Set gap length between towers
lda #41 ; more than a screen
sta distanceBetweenTowers
.notNearEnd
cpx #0
bne .doneProgress
dec progressCounterHi
bne .doneProgress
jsr increaseLevel
.doneProgress
increaseScore
; now increase score
; increase the digits on screen
lda #58 + 128; '9' + 1
ldx #21 ; position of score digits from the start of screen memory
increaseDigits
inc screenstart,x
cmp screenstart,x
bne .doneIncreaseDigits
lda #48 + 128 ; '0'
sta screenstart,x
lda #58 + 128; '9' + 1
dex
cpx #21 - 5 ; reached the last digit?
bne increaseDigits
.doneIncreaseDigits
rts
increaseScoreBy10
lda #58 + 128
ldx #20
jmp increaseDigits
increaseScoreBy100
lda #58 + 128
ldx #19
jmp increaseDigits
increaseLevel subroutine
jsr powerUp
ldx levelNumber
inx
cpx #maxLevel
bne .doneIncrease
ldx #0 ; back to first level, but increase speed
; Increase speed
lda minShipDx
clc
adc #amountToIncreaseSpeedBy
bcc .notSpeedWrapAround
lda #255
.notSpeedWrapAround
sta minShipDx
; increase rocket frequency
inc rocketProbability
inc rocketProbability
.doneIncrease
stx levelNumber
jsr setUpLevel
jsr updateBonuses
rts
onceOnlyInit subroutine
sei ; don't need maskable interrupts
lda #$7f
sta $912e ; disable interrupts
sta $912d
sta $911e ; disable non maskable interrupts from restore key
lda $912e
lda $912d
; detect NTSC or PAL
lda ntscOrPalLocation
cmp #isNtsc
bne .doneNtscOrPal
; set up default NTSC values
lda #rasterTriggerLineNTSC + 1
sta rasterTriggerLineMinusOne + 1
lda #rasterTriggerLineNTSC
sta rasterNextLineMinusOne + 1
lda #shipYImpulseNTSC
sta thrustYAmountMinusOne + 1
lda #shipXImpulseNTSC
sta thrustXAmountMinusOne + 1
.doneNtscOrPal
; remember the screen x and y position as it will move later
lda horizontalScreenPosition
sta initialHorizontalScreenPosition
lda verticalScreenPosition
sta initialVerticalScreenPosition
lda #8
sta scrollCounter
sta lastFrameWasScroll
; make sure the screen memory is in the right place
lda #22 ; 22 for expanded VIC, 150 for unexpanded
sta 36866
lda #192+1+2+4+8 ; 192+1+2+4+8 for expanded VIC, 240 normally for unexpanded, 255 for unexpanded with chars at 7168
sta 36869
lda #$10 ; default screen page. dec 30 for unexpanded vic
sta screenMemoryPage ; tell the kernel where the screen is. Must match the above.
lda #80
sta $291 ; disable case change
lda #0
sta levelNumber
sta joystickDDR1 ; prepare for joystick input
jsr prepareTowerPositions
rts
init subroutine
jsr resetScroll;
jsr setUpSound
lda #6 ; set ship start position
sta shipx
lda #10
sta shipy
; clear screen and display score
lda #<welcome
sta.z cursor;
lda #>welcome
sta.z cursor + 1
jsr printline
jsr createBottomOfScreen
lda #0
sta shipdy
sta towerheight
lda #0 ; start with no fuel
sta fuel
lda #spacePrintable
sta shipReplaceCharacter
lda #8
sta scrollCounter
sta lastFrameWasScroll
lda #4
sta fuelColumn
lda #16 ; give some space at the start of the level
sta towercolumnsleft
lda #fuelLeftPrintable
sta fuelChar
; Set up current level
setUpLevel
ldx levelNumber
jsr setupTowerCharacters ; also sets up constants
lda #spacePrintable ; ship hasn't collided with anything yet
sta charReplaced
ldx #<tune3
ldy #>tune3
jsr startTune
rts
defaultBackground equ 3
lowerBackground equ 5
changeNormalColor equ 255
changeBackgroundColor equ 254
; Local variables to backgroundMap, and don't need to be in zero page as they are
; only used infrequently
ycoord dc 0
xcoord dc 0
color0 dc 0 ; written for a 0 bit in the background map
color1 dc 0 ; written for a 1 bit in the background map
bgOrfg dc 0 ; bg = 0; fg = 1
; sets up background colours
; start by loading x with the index of the colour map, starting at zero
prepareColors subroutine
lda #<backgroundMap ; use cursor to point to backgroundMap position
sta.z cursor
lda #>backgroundMap
sta.z cursor + 1
ldy #0 ; start at the beginning of the maps
.findLoop
; seek to the right map
cpx #0
beq .foundMap
jsr .nextInstruction
cmp #253 ; end of map?
bne .findLoop
dex ; found end of current map
jmp .findLoop
.foundMap
lda #colorstarthigh ; use colorcursor to point to screen position in colour map
sta.z colorcursor + 1
lda #0
sta.z colorcursor
ldx #1
stx bgOrfg
.switchbgfg
lda bgOrfg
eor #1
sta bgOrfg
.readloop
jsr .nextInstruction
cmp #255
bne .not1
jsr .nextInstruction
sta color0 ; store as background color
jmp .readloop
.not1
cmp #254
bne .not2
jsr .nextInstruction
sta color1 ; store as foreground color
jmp .readloop
.not2
cmp #253 ; end marker
beq .finished
tax
lda #0
cmp bgOrfg
bne .fg
lda color0
jmp .outloop
.fg
lda color1
.outloop
cpx #0
beq .switchbgfg ; swap background and foreground, and get next instruction
sta (colorcursor),y ; y = 0
; colorcursor+=1
inc.z colorcursor
bne .doneIncColorCursor
inc.z colorcursor + 1
.doneIncColorCursor
dex
jmp .outloop
.finished:
rts
.nextInstruction
lda (cursor),y
; cursor+=1
inc.z cursor
bne .doneIncCursor
inc.z cursor + 1
.doneIncCursor
rts
createBottomOfScreen subroutine
ldx #22
ldy #22
lda #bottomBlockPrintable
sta character
jsr drawchar ; draw the first one
ldy #22 ; number left to go
lda #1 ; number of spaces to subtract
sta diff
.loop
dey
jsr subcursor
jsr storechar
cpy #0
bne .loop
rts
printline subroutine
ldy #0
.loop
lda (cursor),y
cmp #0
beq .done
jsr CHROUT
iny
jmp .loop
.done
rts
scroll subroutine
; not yet drawn ship. Indicate this by setting the replacedChar with 255 (invalid value it will never encounter)
lda #255
sta charReplaced
clc
ldx #screenstarthigh ; put start of screen hi in cursor position
ldy #22 ; screen scroll start lo
stx.z cursor + 1
sty.z cursor
ldy #0 ; current *X* position
ldx #0 ; number of current line
.lineLoop
iny ; (2) cycles. Gain 4
lda (cursor),y ; (5+) get existing character. Absolute addressing would be (4)
dey ; (2)
sta (cursor),y ; (6) store in previous location. Absolute addressing would be (4)
iny ; (2)
cpy #21 ; (2)
.2 ; .1 to .2 : 19+ originally
bne .lineLoop ; (2) continue within line
; copy in the next line from the buffer
lda nextLine,x
sta (cursor),y
; is it time to draw the ship?
cpx shipy
bmi .notDrawShip
lda charReplaced
cmp #255
bne .notDrawShip ; already drawn it
txa
pha
tya
pha
jsr drawship
pla
tay
pla
tax
.notDrawShip
; move to next line
ldy #0 ; (2) reset back to start of line counter
inx ; (2) next line
cpx #screenHeight - 3
beq .finished ; (3) or (4) if page boundary crossed
lda.z cursor ; (3)
clc ; (2)
adc #22 ; (2)
sta.z cursor ; (3)
bcc .lineLoop ; (3) or (4) continue with next line
inc.z cursor + 1 ; (5)
jmp .lineLoop ; (3) continue with next line
.finished
rts ; done
;;;; Draw a character at the given x and y coordinates
; x coord x
; y coord y
drawchar subroutine
;; initialise values
lda #screenstarthigh
sta.z cursor + 1
lda #colorstarthigh
sta.z colorcursor + 1
clc
txa ; x coord to screen low byte
.1 bcs .2 ; overflowed page?
.1ret cpy #$00 ; no further y offset?
beq .3
adc #screenwidth - 1 ; not sure why I need this -1
dey
jmp .1 ;
.2 clc
inc.z cursor + 1 ; next screen page
inc.z colorcursor + 1 ; and color cursor
jmp .1ret
.3 sta.z cursor ; got final low byte value
sta.z colorcursor ; and the color cursor
storeCharSaveReplaced
ldx #0
lda (cursor),x ; get character about to be replaced
sta charReplaced
storechar ldx #0 ; offset to allow indirect addressing -- should really use zero page
lda character ; char to print
; if it's 255, don't draw
cmp #255
beq .done
sta (cursor),x
.done
rts
addcursor subroutine
clc
adc.z cursor
sta.z cursor
bcc .1
inc.z cursor + 1
.1 rts
subcursor subroutine
sec
lda.z cursor
sbc diff
sta.z cursor
bcs .1
dec.z cursor + 1
.1 rts
;;;; Draw a tower at the right hand side of the screen
towerheight dc 0
fuelColumn dc 128 + 4 ; set MSB to indicate will not be drawn. Reset bit when drawing next tower
fuelRow dc 10 ; height above the ground or tower
fuelChar dc 3
towercolumnsleft dc 16
prepareTowerPositions subroutine
ldy #nextLineLength - 1
lda #spacePrintable
.loop
sta nextLine,y
cpy #0
beq .done
dey
jmp .loop
.done
rts
; color and colorcharacter already set
; towerMiddleCharacter already set for the non-top/bottom character, and also in a
; towerTopCharacter already set
; prepares nextLine with a line to copy in during the next scroll
drawtowerScope subroutine
.shortTower
cpy #0
bne .not0
lda #spacePrintable
sta towerMiddleCharacter
jmp .draw
.not0
lda towerTopCharacter
jmp .draw
.switchToTopCharacter
lda towerTopCharacter ; use this next
sta character
dey
bne .1
jmp .drawnBottom
drawtower
;; If the tower is zero height, draw a space at the bottom and then draw a gap full height
;; if the screen
sta character
ldy towerheight
cpy #3 ; One high, so print the top character instead of the middle
bmi .shortTower
.draw
;; draw first block at bottom right, then build up from there
ldx #nextLineLength - 1
ldy towerheight
cpy #0
beq .drawnBottom
dey ; subtract one from tower height as bottom character is never drawn
beq .drawnBottom ; finished drawing bottom of tower?
.1 dex
.subfinished
sta nextLine,x
.storecharcomplete1
cpy #2 ;[2]
beq .switchToTopCharacter ;[2,3]
dey ;[2]
bne .1 ;[3,2]
.drawnBottom ; now draw the gap
ldy gapWidth
lda towerheight ; if tower height is zero, don't draw the top
cmp #0
bne .readyToDrawGap
ldy #screenheight - 2
.readyToDrawGap
lda #spacePrintable
sta character
cpy #0
.3 beq .drawnGap
dex ; one line up
.subfinished2
lda character ; TODO, see if we can remove the need to do this
sta nextLine,x
cpx #0
beq .doneTower
.storecharcomplete2
lda towercolumnsleft
cmp fuelColumn
bne .305
; is this the row to print the fuel at?
cpy fuelRow
bne .305 ; not yet right height to print fuel
; print fuel
lda fuelChar; this is variable, as we may be drawing the first or second character
sta nextLine,x
.storecharcomplete3
; do we need to print the second edge?
lda fuelChar
cmp #fuelLeftPrintable
beq .switchToRight1
cmp #baddyLeftPrintable
beq .switchToRight2
; switch to printing the left edge again and choose the position for
; the next fuel character
; work out the row
jsr random
and #$0f
clc
adc #$3
sta fuelRow
jsr random
and #$7
cmp rocketProbability
bpl .nextIsFuel
lda #screenHeight - 4
sta fuelRow
lda #baddyLeftPrintable
jmp .gotNext
.nextIsFuel
lda #fuelLeftPrintable
.gotNext
sta fuelChar
; jsr random
lda #6
and #$7 ; random number 0 to 7
ora #$80 ; set MSB to delay drawing until after next tower
cmp #$87
bne .not7
lda #3 ; replace a 0 with a 3 to put the fuel between towers not just before a tower
.not7
sta fuelColumn
.305
dey
jmp .3
.switchToRight1
lda #fuelRightPrintable
sta fuelChar
dec fuelColumn ; set to print the right hand edge next column
jmp .305
.switchToRight2
lda #baddyRightPrintable
sta fuelChar
dec fuelColumn ; set to print the right hand edge next column
jmp .305
.drawnGap
; now draw the the top part
ldy #1 ; draw 1 top character then switch to middle
lda topTowerEdgeCharacter
.4
sta nextLine,x
cpx #0
beq .5
dex
dey
bne .4
lda topTowerMiddleCharacter
jmp .4
.5
.doneTower
rts
defaulttowerwidth equ 4
bottomscreencharacter equ 4
fuelcharacter equ 6
;;;; Draw next right hand line of screen
drawline subroutine
lda #0
cmp towercolumnsleft
bne .drawit
; work out next tower height
lda towerheight
cmp #0
bne .gap
; if we are nearly at the end of the level, draw no more towers, so just
; have a big gap
lda progressCounterHi
cmp #0
bne .doneCheckEndLevel
lda progressCounterLo
cmp #50 ; one screen worth left?
bmi .doneCheckEndLevel
lda #0 ; tower height zero, i.e. no tower as at end of level
jmp .chosenTowerHeight
.doneCheckEndLevel
jsr random
and #$0f
.chosenTowerHeight
sta towerheight
cmp #$0f
bne .notdec
dec towerheight
.notdec
lda #defaulttowerwidth
sta towercolumnsleft
.drawit
dec towercolumnsleft
lda towerheight
cmp #0
beq .drawit1
ldx towercolumnsleft
lda towerTopCharacters,x ; character to draw at top edge of towers (around the gap)
sta towerTopCharacter
lda towercharacters,x ;
sta towerMiddleCharacter
lda topTowerEdgeCharacters,x ; character to draw at bottom edge of towers (around the gap)
sta topTowerEdgeCharacter
lda topTowerCharacters,x ;
sta topTowerMiddleCharacter
.drawit1 jsr drawtower
rts
.gap lda distanceBetweenTowers
sta towercolumnsleft
lda #0
sta towerheight
; allow fuel to be drawn from now on
lda fuelColumn
and #$7f
sta fuelColumn
jmp .drawit
;;;; Random number generator
random subroutine
lda randseed
ror
ror
ror
eor randseed
sbc randseed + 1
rol
rol
rol
sta randseed + 1
rol
eor randseed
adc randseed + 1
inc randseed
sta randseed
rts
; wait for raster to enter border
rasterdelay
; lda #4
; sta borderPaper
.rasterloop
lda rasterline
rasterTriggerLineMinusOne
cmp #rasterTriggerLinePAL + 1; gets overwritten with NTSC value if running on NTSC
bpl .rasterloop
; lda #0
; sta borderPaper
.rasterLowerLoop
lda rasterline
rasterNextLineMinusOne
cmp #rasterTriggerLinePAL ; gets overwritten with NTSC value if running on NTSC
bmi .rasterloop
; lda #1
; sta borderPaper
rts
workOutShipPosition
ldx shipx
ldy shipy
lda #255 ; don't draw
sta character
jsr drawchar
lda cursor
sta shipToBeDrawnAt1
lda cursor + 1
sta shipToBeDrawnAt1 + 1
lda #screenwidth
sta diff
jsr addcursor
lda cursor
sta shipToBeDrawnAt2
lda cursor + 1
sta shipToBeDrawnAt2 + 1
rts
drawship ; work out ship offset in pixels from 0 to 7. Take top 3 bits of minor Y value
lda shipMinorY
lsr
lsr
lsr
lsr
lsr
clc
ldx shipDirection
cpx #directionUp
beq .goingUp
adc #shipTopPrintable
sta character
jmp drawshipchar
.goingUp
sta character
lda #7
sec
sbc character
clc
adc #shipTopPrintable
sta character
drawshipchar
ldx #0
lda (shipToBeDrawnAt1),x
sta charReplaced2 ; store this for collision detection later
lda character
sta (shipToBeDrawnAt1),x
cmp #spacePrintable
beq .keepSpace
clc
adc #8 ; bottom set are 8 bytes further on
sta character
.keepSpace
lda (shipToBeDrawnAt2),x
sta charReplaced
lda character
sta (shipToBeDrawnAt2),x
rts
clearship
ldx #0
lda (shipToBeDrawnAt1),x
cmp #shipTopPrintable
bmi .doneReplace1
;lda #spacePrintable
lda shipReplaceCharacter
sta (shipToBeDrawnAt1),x
.doneReplace1
lda (shipToBeDrawnAt2),x
cmp #shipTopPrintable
bmi .doneReplace2
lda #spacePrintable
sta (shipToBeDrawnAt2),x
.doneReplace2
rts
control subroutine
; if crashing, no control
lda shipReplaceCharacter
cmp #spacePrintable
bne .controlDone
; scan keyboard for key presses or joystick
lda #0
sta $9120 ; reset keyboard state
lda joystickIn1
ora #255 - 32 ; set all other bits. Only care about fire button
and $9121 ; get any 0 bits from keyboard state (indicates a key is pressed)
ldx lastkey
sta lastkey
cpx #255 ; 255 indicates nothing is pressed
bne .notpress
cmp #255
beq .notpress
; something just pressed
jmp thrust
.controlDone
; ignore
rts
thrust
lda #255
sta jetSound
thrustYAmountMinusOne
lda #shipYImpulsePAL ; gets overwritten with a different value if NTSC
sta shipdy
clc
thrustXAmountMinusOne
lda #shipXImpulsePAL;
adc shipdx
bcc .storedx
lda #255
.storedx
sta shipdx
lda shipDirection
cmp #directionUp
beq .alreadyGoingUp
lda #directionUp
sta shipDirection
jsr swapMinorY
.alreadyGoingUp
.notpress
controlDone
rts
temp dc.b 0
temp2 dc.b 0
physics subroutine
; returns with zero flag set if end of game
jsr rasterdelay
; update horizontal position
lda #4 ; number of times to add the speed
sta temp
.impulseLoop
lda shipMinorX
clc
adc shipdx
sta shipMinorX
bcc .notSmoothScroll
jsr smoothScroll
jsr handleFullScroll
.notSmoothScroll
dec temp
bne .impulseLoop
; update ship x speed
ldy #1 ; amount to reduce by
ldx shipdx
.dxloop
cpx minShipDx
beq .donedx
; speed up or slow down?
inx
cpx minShipDx
bpl .doneDecrease
dex
dex
.doneDecrease
stx shipdx
dey
bne .dxloop
.donedx
; update ship y position. First the minor position
lda shipMinorY
clc
adc shipdy
sta shipMinorY
bcc .doneShipPosition
; need to update major position, depending on the direction
lda shipy
clc
adc shipDirection
; check if hit top of screen, in which case we bounce
cmp #1
bpl .notTopBounce
lda #directionDown
sta shipDirection
lda #1
sta shipMinorY
jmp .doneBounce
.notTopBounce
cmp #20 ; hit bottom of screen?
bmi .doneBounce
; if we are crashing, now it's the end of the game
lda shipReplaceCharacter
cmp #spacePrintable
bne donePhysicsEndOfGame
lda #directionUp
sta shipDirection
lda #1
sta shipMinorY
lda #20
jmp .doneBounce
.doneBounce
sta shipy
.doneShipPosition
; update ship velocity
; are we currently going up or down?
lda shipDirection
cmp #directionUp
beq .goingUp
.goingDown
lda shipdy
cmp #255 - #gravity
bmi .maxVelocity
; increase velocity
clc
adc #gravity
sta shipdy
.maxVelocity
jmp donePhysicsNotEndOfGame
.goingUp
lda jetSound
cmp #0
beq .notjet
dec jetSound
.notjet
lda shipdy
; decrease velocity
sec
sbc #gravity
bcc .switchToDown
sta shipdy
jmp donePhysicsNotEndOfGame
.switchToDown
lda #0
sta shipdy
lda #directionDown
sta shipDirection
jmp swapMinorY
swapMinorY
; swap the minor y value around
lda #255
sec
sbc shipMinorY
sta shipMinorY
jmp donePhysicsNotEndOfGame
donePhysicsNotEndOfGame
lda #0 ; clear zero flag to indicate not end of game
cmp #1
rts
donePhysicsEndOfGame
lda #0 ; set zero flag to indicate end of game
cmp #0
rts
soundVolume equ 36878
voice0 equ 36874
voice1 equ 36875
voice2 equ 36876
voice3 equ 36877 ; noise
setUpSound
lda #15
sta soundVolume ; volume = 15
lda #0
sta voice0 ; voice 0
sta voice1 ; voice 1
sta voice2 ; voice 2
sta voice3 ; voice 3 : noise
rts
stopSound
lda #0
sta voice0
sta voice1
sta voice2
sta voice3
sta soundVolume
sta explosionEffectCount
rts
updateSound subroutine
jsr playTune
ldx explosionEffectCount
cpx #0
beq .engineSound
dec explosionEffectCount
beq .restoreScreen
; shake the screen
jsr random
and #7
clc
adc initialVerticalScreenPosition
sta verticalScreenPosition
jsr random
ora #128 ; set top bit so will actually make a sound
sta voice2
tax
and #1
clc
adc initialHorizontalScreenPosition
sta horizontalScreenPosition
jmp .makeSound
.restoreScreen
lda initialVerticalScreenPosition
sta verticalScreenPosition
lda initialHorizontalScreenPosition
sta horizontalScreenPosition
lda #0
sta voice2
jmp .engineSound
.crashSound
ldx #shipy
jmp .makeSound
.engineSound
lda shipReplaceCharacter
cmp #spacePrintable
bne .crashSound
ldx shipdx
.makeSound
stx voice3
.doneEffect
rts
explosionEffectCount dc.b 0
explosionEffect subroutine
lda #10
sta explosionEffectCount
rts
bonusSound1 subroutine
ldx #<tune2
ldy #>tune2
jsr startTune
rts
powerUp subroutine
ldx #<tune1
ldy #>tune1
jsr startTune
rts
musicNotes
dc.b 0 ; 0 off
dc.b 195 ; c1
dc.b 201 ; d2
dc.b 207 ; e3
dc.b 209 ; f4
dc.b 215 ; g5
dc.b 219 ; a6
dc.b 223 ; b7
dc.b 225 ; c8
dc.b 228 ; d9
dc.b 231 ; e10
dc.b 232 ; f11
dc.b 235 ; g12
dc.b 237 ; a13
dc.b 239 ; b14
dc.b 240 ; c15
dc.b 242 ; d16
dc.b
;;;;;;
startTune
; self modifying code!! set the position to read tune data from
stx currentTuneMinusOne + 1
sty currentTuneMinusOne + 2
; set the position to start reading tune data for voice 0
ldx #1
stx tunePositionVoice0
; now get the offset to the second voice's data
ldx #0
jsr .getNextTuneByte
sta tunePositionVoice1
lda #1 ; when tune starts, the counters will be decremented to zero and the next (i.e. first)
; note will be played
sta tuneCounterVoice0
sta tuneCounterVoice1
rts
playTune
; first voice 0
dec tuneCounterVoice0
beq .doneCountdownVoice0
.doVoice1
; now voice 1
dec tuneCounterVoice1
beq .doneCountdownVoice1
.doVoice2
; no voice2
rts
.doneCountdownVoice0
ldx tunePositionVoice0
beq .doVoice1 ; if zero, voice has finished
jsr .getNextTuneByte ; get note
cmp #255 ; end?
beq .finishedVoice0
tay
lda musicNotes,y
sta voice0
inx
jsr .getNextTuneByte ; get duration
sta tuneCounterVoice0
inx
stx tunePositionVoice0
jmp .doVoice1
.finishedVoice0
lda #0
sta tunePositionVoice0
jmp .doVoice1
.doneCountdownVoice1
ldx tunePositionVoice1
beq .doVoice2 ; if zero, voice has finished
jsr .getNextTuneByte ; get note
cmp #255 ; end?
beq .finishedVoice1
tay
lda musicNotes,y
sta voice1
inx
jsr .getNextTuneByte ; get duration
sta tuneCounterVoice1
inx
stx tunePositionVoice1
jmp .doVoice2
.finishedVoice1
lda #0
sta tunePositionVoice1
jmp .doVoice2
.getNextTuneByte
currentTuneMinusOne
lda 1234,x
rts
screenWidth equ 23
screenHeight equ 24
explode subroutine
ldy #255
ldx #255
.loop
stx borderPaper
dex
bne .loop
dey
sty voice2
sty voice1
sty voice0
bne .loop
lda #3
sta borderPaper
rts
startScreen subroutine
jsr stopSound
jsr setUpSound
; start the title jingle
ldx #<tune1
ldy #>tune1
jsr startTune
; clear screen and display score
lda #<startMessage
sta.z cursor;
lda #>startMessage
sta.z cursor + 1
jsr printline
jsr waitForStartKey
rts
waitForStartKey subroutine
jsr random
; wait for the raster to provide some timing
jsr rasterdelay
jsr playTune
lda #0
sta $9120 ; reset keyboard state
lda $9121
cmp #254 ; space key
beq .restart
lda joystickIn1
and #32 ; set all other bits. Only care about fire button
cmp #32
beq waitForStartKey
; jmp .restart
.restart
lda #0
sta levelNumber ; reset level to start
lda #0
sta shipMinorX
lda #2
sta rocketProbability
lda #100
sta shipdx
rts
;;;; Set up characters to use when drawing towers. X should have tower set number, 0 being the first
;;;; Every odd numbered level will be level 1. Otherwise, it's the level number divided by 2
setupTowerCharacters subroutine
lda #<startOfLevelDefinitions
sta cursor
lda #>startOfLevelDefinitions
sta cursor + 1
ldy #0
.levelFindLoop
lda levelOrder,y
cmp #finishedLevels
beq .endOfLevels
.endOfLevelsReturn
cpx #0
beq .foundLevel
dex
iny
jmp .levelFindLoop
.foundLevel
tax
; x now holds the number of the level description
.xloop
lda #23 ; number of positions to skip over to get next set of characters
cpx #0 ; use this character set?
beq .useThis
jsr addcursor
dex
jmp .xloop
.useThis
ldy #0
lda #<towercharacters
sta colorcursor
lda #>towercharacters
sta colorcursor + 1
.yloop
lda (cursor),y
sta (colorcursor),y
iny
cpy #16
bne .yloop
.done
jsr .getNext
sta distanceBetweenTowers
jsr .getNext
sta gapWidth
jsr .getNext
sta borderPaper
jsr .getNext
sta progressCounterLo
jsr .getNext
sta progressCounterHi
jsr .getNext
sta minShipDx
jsr .getNext
tax
jsr prepareColors
rts
.getNext lda (cursor),y
iny
rts
.endOfLevels
ldy #0 ; reset back to start
.doneSpeedup
jmp .endOfLevelsReturn
resetScroll subroutine
; reset smooth scrolling back to the start
lda scrollCounter
cmp #8
beq .scrollDone
cmp #0
.scrollLoop
beq .scrollDone
jsr smoothScroll
dec scrollCounter
jmp .scrollLoop
.scrollDone
lda #8
sta scrollCounter
sta lastFrameWasScroll
rts
; store some of the music here
tune2voice1Start equ tune2voice1 - tune2voice0
tune2
tune2voice0 dc.b tune2voice1Start, 15,2, 14,2, 10,2, 11,2, 12,2, 13,2, 13,2, 13,2, 0,1, 255
tune2voice1 dc.b 9,4,0,4,12,16, 0,1,255
programEnd
dc.b 0
; now for the graphics
org 7168
startOfChars
scrollable
; first the scrollable characters. All the left hand edges, then right hand
leftEdges
solidLeftChar dc.b 0,0,0,0,0,0,0,0
towerLeftChar dc.b 0,0,0,0,0,0,0,0
starLeftChar dc.b 0,0,0,0,0,0,0,0
blackLeftChar dc.b 0,0,0,0,0,0,0,0
fuelLeftChar dc.b 0,0,0,0,0,0,0,0
baddyLeftChar dc.b 0,0,0,0,0,0,0,0
baddyBottomLeftChar dc.b 0,0,0,0,0,0,0,0
rightEdges
solidRightChar dc.b 255,255,0,255,255,0,255,255
towerRightChar dc.b 145,137,197,163,145,137,197,163
starRightChar dc.b 16,16,56,254,56,16,16,16
blackRightChar dc.b 223,223,223,0,251,251,251,0
fuelRightChar dc.b 126,66,223,199,223,223,94,126
baddyRightChar dc.b 16,16,56,56,40,40,40,40
baddyBottomRightChar dc.b 40,40,124,198,254,254,198,130
numberOfScrollableCharacters equ (rightEdges - leftEdges) / 8
fuelLeftPrintable equ (fuelLeftChar - startOfChars) / 8
fuelRightPrintable equ (fuelRightChar - startOfChars) / 8
baddyLeftPrintable equ (baddyLeftChar - startOfChars) / 8
baddyRightPrintable equ (baddyRightChar - startOfChars) / 8
baddyBottomLeftPrintable equ (baddyBottomLeftChar - startOfChars) / 8
baddyBottomRightPrintable equ (baddyBottomRightChar - startOfChars) / 8
towerLeftPrintable equ (towerLeftChar - startOfChars) / 8
towerRightPrintable equ (towerRightChar - startOfChars) / 8
solidLeftPrintable equ (solidLeftChar - startOfChars) / 8
solidRightPrintable equ (solidRightChar - startOfChars) / 8
starLeftPrintable equ (starLeftChar - startOfChars) / 8
starRightPrintable equ (starRightChar - startOfChars) / 8
blackLeftPrintable equ (blackLeftChar - startOfChars) / 8
blackRightPrintable equ (blackRightChar - startOfChars) / 8
nonscrollable
; now the non scrollble characters
; striped block, not scrollable
solidChar dc.b 255,255,0,255,255,0,255,255
solidPrintable equ (solidChar - startOfChars) / 8
goingUpChar dc.b 255,0,0,0,0,0,0,0
goingUpPrintable equ (goingUpChar - startOfChars) / 8
goingDownChar dc.b 0,0,0,0,0,0,0,255
goingDownPrintable equ (goingDownChar - startOfChars) / 8
singleScrollable
numberOfSingleScrollableChars equ (endOfScenery - singleScrollable) / 8
; now the single character rotational scrolling blocks
; wavy block at bottom of screen
bottomBlockChar dc.b 128+64, 32+16, 8+4, 2+1, 2+1, 8+4, 32+16, 128+64
explodeChar dc.b 88,91,1,45,185,231,0,233
blackChar dc.b 223,223,223,0,251,251,251,0
bottomBlockPrintable equ (bottomBlockChar - startOfChars) / 8
explodePrintable equ (explodeChar - startOfChars) / 8
blackPrintable equ (blackChar - startOfChars) / 8
bottomBlockASCIIChar equ 64 + bottomBlockPrintable
endOfScenery
; now for the space
org startOfChars + 32 *8
spaceChar dc.b 0, 0, 0, 0, 0, 0, 0, 0
spacePrintable equ (spaceChar - startOfChars) / 8
; now for the pre-computed space ship characters, first the top half, then the bottom half
shipBottomPrintable equ (shipBottom - startOfChars / 8)
shipTopPrintable equ (shipTop - startOfChars) / 8
shipTop
dc.b 131, 194, 230, 121, 249, 254, 68, 102
dc.b 0, 131, 194, 230, 121, 249, 254, 68
dc.b 0, 0, 131, 194, 230, 121, 249, 254
dc.b 0, 0, 0, 131, 194, 230, 121, 249
dc.b 0, 0, 0, 0, 131, 194, 230, 121
dc.b 0, 0, 0, 0, 0, 131, 194, 230
dc.b 0, 0, 0, 0, 0, 0, 131, 194
dc.b 0, 0, 0, 0, 0, 0, 0, 131
shipBottom
dc.b 0, 0, 0, 0, 0, 0, 0, 0
dc.b 102, 0, 0, 0, 0, 0, 0, 0
dc.b 68, 102, 0, 0, 0, 0, 0, 0
dc.b 254, 68, 102, 0, 0, 0, 0, 0
dc.b 249, 254, 68, 102, 0, 0, 0, 0
dc.b 121, 249, 254, 68, 102, 0, 0, 0
dc.b 230, 121, 249, 254, 68, 102, 0, 0
dc.b 194, 230, 121, 249, 254, 68, 102, 0
enfOfChars
; background map format is:
; starts in backbround mode (i.e. space)
; [instruction][instruction][instruction], etc
;
; where:
; instruction = 253: continue to end of screen
; instruction < 253: number of characters in run before inverting (i.e. background to foreground)
; instruction = 254, x: change background color to following byte
; instruction = 255, x: change foreground color to following byte
backgroundMap
; map 0
dc 255, 4, 254, 0, 22 ; title
dc 254, 3, 255, 1 ; change colours to clouds
dc 70,1,20,2,1,2,16,7,7,1,1,2,4,7,6,6,16,6,115
dc 255, 6 ; change colour to buildings
dc 1,3,1,15,1,1,1,3,1,15,3,1,1,1,1,6,1,7,4,1,5,3,2,7,11,2,3,5
dc 255, 5 ; change colour to grass
dc 110
dc 253 ; end
; map 1
dc 255, 4, 254, 0, 22 ; title
dc 254, 1, 255, 2, 44, 44
dc 254, 7, 255, 1, 44, 44
dc 254, 4, 255, 7, 44, 44
dc 254, 2, 255, 1, 44, 44
dc 254, 7, 255, 4, 44, 44
dc 253 ; end
; map 2
dc 255, 4, 254, 0, 22 ; title
dc 254, 0, 255,3
dc 82, 2, 19, 4, 18, 4, 19, 2
dc 255, 1
dc 225, 1, 9, 1, 6, 1, 4, 2, 1, 2, 5
dc 2, 3, 3, 3, 7, 2, 4, 2, 5, 2, 22, 22
dc 253 ; end
; map 3
dc 255, 4, 254, 0, 22 ; title
dc 254, 4, 255,4
dc 242, 4 * 22
dc 255,2
dc 3,5,2,4, 5, 3
dc 255, 2, 254, 2
dc 6 * 22
dc 253 ; end
; level format:
; Bytes 0 - 3: front, middle, middle, back edge characters for mid-way through tower on top
; 4 - 7: front, middle, middle, back edge characters for edges of tower on top
; 8 - 11: front, middle, middle, back edge characters for mid-way through tower on bottom
; 12 - 15: front, middle, middle, back edge characters for edges of tower on bottom
; 16 : horizontal gap between towers
; 17 : vertical gap between towers
; 18 : border and paper colour
; 19-20: number of moves before switching to next level (lo,hi)
; 21 ; minimum horizontal speed
; 22 ; background map number
fuelActiveFlag equ #1
; specify the order of levels. 255 instructs to wrap around
finishedLevels equ 255
levelOrder dc.b 1,2,0,5,3,0,4,0,0,5,finishedLevels
startOfLevelDefinitions
; 0: stars, fast
dc.b spacePrintable,spacePrintable,spacePrintable,spacePrintable
dc.b spacePrintable,spacePrintable,starRightPrintable,starLeftPrintable
dc.b spacePrintable,spacePrintable,spacePrintable,spacePrintable
dc.b starRightPrintable,starLeftPrintable,spacePrintable,spacePrintable
dc.b 5,14,8 ; black border, black paper
dc.b 250,2
dc.b 80, 1
; 1: brick towers
dc.b blackRightPrintable,blackPrintable,blackPrintable,blackLeftPrintable
dc.b blackRightPrintable,blackPrintable,blackPrintable,blackLeftPrintable
dc.b blackRightPrintable,blackPrintable,blackPrintable,blackLeftPrintable
dc.b blackRightPrintable,blackPrintable,blackPrintable,blackLeftPrintable
dc.b 8,24,3
dc.b 1,2
dc.b 10, 0
; 2: gantry towers top and bottom, medium spacing
dc.b spacePrintable,towerRightPrintable,towerLeftPrintable,spacePrintable
dc.b solidRightPrintable,solidPrintable,solidPrintable,solidLeftPrintable
dc.b spacePrintable,towerRightPrintable,towerLeftPrintable,spacePrintable
dc.b solidRightPrintable,solidPrintable,solidPrintable,solidLeftPrintable
dc.b 10,10,3
dc.b 1,3
dc.b 10, 0
; 3: gantry towers top and bottom, narrow, large horizontal gaps
dc.b spacePrintable,towerRightPrintable,towerLeftPrintable,spacePrintable
dc.b solidRightPrintable,solidPrintable,solidPrintable,solidLeftPrintable
dc.b towerRightPrintable,towerLeftPrintable,towerRightPrintable,towerLeftPrintable
dc.b solidRightPrintable,solidPrintable,solidPrintable,solidLeftPrintable
dc.b 20,7,136 - 8
dc.b 150,3
dc.b 15, 2
; 4: floating obstacles
dc.b spacePrintable,spacePrintable,spacePrintable,spacePrintable
dc.b solidRightPrintable,solidPrintable,solidPrintable,solidLeftPrintable
dc.b spacePrintable,spacePrintable,spacePrintable,spacePrintable
dc.b solidRightPrintable,solidPrintable,solidPrintable,solidLeftPrintable
dc.b 1,15,28 - 8
dc.b 150,4
dc.b 15, 3
; 5: fuel and rockets, fast
dc.b spacePrintable,spacePrintable,spacePrintable,spacePrintable
dc.b spacePrintable,spacePrintable,fuelRightPrintable,fuelLeftPrintable
dc.b spacePrintable,spacePrintable,spacePrintable,spacePrintable
dc.b fuelRightPrintable,fuelLeftPrintable,spacePrintable,spacePrintable
dc.b 7,14,8
dc.b 250,1
dc.b 80, 1
; tunes are stored in a list of items of the following format:
; [noteIndex,timeOn,timeSilence],...
; noteIndex of 255 indicates end of the tune
tune1voice1Start equ tune1voice1 - tune1voice0
tune1
tune1voice0 dc.b tune1voice1Start, 16,4, 14,12, 15,4, 13,12, 12,4, 13,4, 14,4, 15,4, 16,16, 0,1, 255
tune1voice1 dc.b 5,16, 6,16, 0,16, 12,16, 0,1,255
tune3voice1Start equ tune3voice1 - tune3voice0
tune3
tune3voice0 dc.b tune3voice1Start, 9,4,10,4,11,4,12,4,13,4,14,4,15,4,16,4,0,1,255
tune3voice1 dc.b 2,4,3,4,4,4,5,4,6,4,7,4,8,4,9,4,0,1,255
tunePositionVoice0 dc.b 0 ; set to 0 when finished
tuneCounterVoice0 dc.b 0
tunePositionVoice1 dc.b 0 ; set to 0 when finished
tuneCounterVoice1 dc.b 0
maxLevel equ 7
dataEnd
dc.b 0
IFNCONST printedCompilationDetails
printedCompilationDetails SET 1
echo "To run: SYS ", start
echo "Total length ", dataEnd - start
echo "Code space left ", 7168 - programEnd
echo "Characters left ", (spaceChar - endOfScenery) / 8
echo "End ", dataEnd
END
| 33.46875 | 132 | 0.466182 |
ac092600e02892d23a21e54ac56cd15aee283e44 | 1,781 | asm | Assembly | lab5pb7B.asm | Codrin18/CSA | 0aa253fefcc6d8d00cc64fb8066153435d1f70d5 | [
"MIT"
] | null | null | null | lab5pb7B.asm | Codrin18/CSA | 0aa253fefcc6d8d00cc64fb8066153435d1f70d5 | [
"MIT"
] | null | null | null | lab5pb7B.asm | Codrin18/CSA | 0aa253fefcc6d8d00cc64fb8066153435d1f70d5 | [
"MIT"
] | null | null | null | bits 32 ; assembling for the 32 bits architecture
; declare the EntryPoint (a label defining the very first instruction of the program)
global start
; declare external functions needed by our program
extern exit,printf,gets,scanf ; tell nasm that exit exists even if we won't be defining it
import exit msvcrt.dll ; exit is a function that ends the calling process. It is defined in msvcrt.dll
import printf msvcrt.dll
import gets msvcrt.dll
import scanf msvcrt.dll ; msvcrt.dll contains exit, printf and all the other important C-runtime specific functions
; our data is declared here (the variables needed by our program)
segment data use32 class=data
; ...
s resb 20
S db 0
format db '%s', 0
formatcharacter db '%c', 0
printformatcharacter db 'S=', 0
; our code starts here
segment code use32 class=code
start:
; ...
push dword s
call [gets]
add esp, 4*1
push dword S
push formatcharacter
call [scanf]
add esp, 4*2
mov ecx, 20
mov esi, 0
repeta:
mov al, [s+esi]
cmp al, ' '
je space
jne notSpace
space:
mov bl, [S]
mov [s+esi], bl
inc esi
jmp end_repeta
notSpace:
inc esi
end_repeta:
loop repeta
push dword s
push dword format
call [printf]
add esp, 4*2
; exit(0)
push dword 0 ; push the parameter for exit onto the stack
call [exit] ; call exit to terminate the program
| 29.683333 | 138 | 0.541269 |
12bc9b4c39d07050107b0f5c930efa8e0bd3c7a6 | 53 | asm | Assembly | test/invalid-datalab.asm | kspalaiologos/asmbf | c98a51d61724a46855de291a27d68a49a034810b | [
"MIT"
] | 67 | 2020-08-03T06:26:35.000Z | 2022-03-24T19:50:51.000Z | test/invalid-datalab.asm | pyautogui/asmbf | 37c54a8a62df2fc4bab28bdeb43237b4905cbecd | [
"MIT"
] | 55 | 2019-10-02T19:37:08.000Z | 2020-06-12T19:40:53.000Z | test/invalid-datalab.asm | pyautogui/asmbf | 37c54a8a62df2fc4bab28bdeb43237b4905cbecd | [
"MIT"
] | 9 | 2019-05-18T11:59:41.000Z | 2020-06-21T20:40:25.000Z | txt "&something"
txt "*something"
mov r1, *undefined
| 13.25 | 18 | 0.716981 |
d2165c2537d61f30c77cc496a98461781f7e12b6 | 512 | asm | Assembly | programs/oeis/302/A302332.asm | neoneye/loda | afe9559fb53ee12e3040da54bd6aa47283e0d9ec | [
"Apache-2.0"
] | 22 | 2018-02-06T19:19:31.000Z | 2022-01-17T21:53:31.000Z | programs/oeis/302/A302332.asm | neoneye/loda | afe9559fb53ee12e3040da54bd6aa47283e0d9ec | [
"Apache-2.0"
] | 41 | 2021-02-22T19:00:34.000Z | 2021-08-28T10:47:47.000Z | programs/oeis/302/A302332.asm | neoneye/loda | afe9559fb53ee12e3040da54bd6aa47283e0d9ec | [
"Apache-2.0"
] | 5 | 2021-02-24T21:14:16.000Z | 2021-08-09T19:48:05.000Z | ; A302332: a(0)=1, a(1)=193; for n>1, a(n) = 194*a(n-1) - a(n-2).
; 1,193,37441,7263361,1409054593,273349327681,53028360515521,10287228590683393,1995669318232062721,387149560508429484481,75105019069317087926593,14569986549887006628274561,2826502285659009968797338241,548326873431298046940055344193,106372586943386162096401939435201,20635733540143484148655036195084801
seq $0,82841 ; a(n) = 4*a(n-1) - a(n-2) for n>1, a(0)=3, a(1)=9.
pow $0,2
sub $0,81
div $0,3
add $0,26
pow $0,2
div $0,672
mul $0,192
add $0,1
| 39.384615 | 301 | 0.761719 |
1bc250d34e81b5977e6446619a0477b0431ed39d | 468 | asm | Assembly | programs/oeis/229/A229144.asm | neoneye/loda | afe9559fb53ee12e3040da54bd6aa47283e0d9ec | [
"Apache-2.0"
] | 22 | 2018-02-06T19:19:31.000Z | 2022-01-17T21:53:31.000Z | programs/oeis/229/A229144.asm | neoneye/loda | afe9559fb53ee12e3040da54bd6aa47283e0d9ec | [
"Apache-2.0"
] | 41 | 2021-02-22T19:00:34.000Z | 2021-08-28T10:47:47.000Z | programs/oeis/229/A229144.asm | neoneye/loda | afe9559fb53ee12e3040da54bd6aa47283e0d9ec | [
"Apache-2.0"
] | 5 | 2021-02-24T21:14:16.000Z | 2021-08-09T19:48:05.000Z | ; A229144: Partial sums of (Fibonacci numbers mod 3).
; 0,1,2,4,4,6,8,9,9,10,11,13,13,15,17,18,18,19,20,22,22,24,26,27,27,28,29,31,31,33,35,36,36,37,38,40,40,42,44,45,45,46,47,49,49,51,53,54,54,55,56,58,58,60,62,63,63,64,65,67,67,69,71,72,72,73,74,76,76,78,80,81,81,82,83,85,85,87,89
mov $2,$0
mov $3,$0
lpb $2
mov $0,$3
sub $2,1
sub $0,$2
seq $0,45 ; Fibonacci numbers: F(n) = F(n-1) + F(n-2) with F(0) = 0 and F(1) = 1.
mod $0,3
add $1,$0
lpe
mov $0,$1
| 31.2 | 229 | 0.596154 |
79b643fb8248f5a3f27e341e1753852e22a273ed | 5,912 | asm | Assembly | Transynther/x86/_processed/NC/_zr_/i7-8650U_0xd2.log_16822_869.asm | ljhsiun2/medusa | 67d769b8a2fb42c538f10287abaf0e6dbb463f0c | [
"MIT"
] | 9 | 2020-08-13T19:41:58.000Z | 2022-03-30T12:22:51.000Z | Transynther/x86/_processed/NC/_zr_/i7-8650U_0xd2.log_16822_869.asm | ljhsiun2/medusa | 67d769b8a2fb42c538f10287abaf0e6dbb463f0c | [
"MIT"
] | 1 | 2021-04-29T06:29:35.000Z | 2021-05-13T21:02:30.000Z | Transynther/x86/_processed/NC/_zr_/i7-8650U_0xd2.log_16822_869.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 %r13
push %r8
push %r9
push %rbx
push %rcx
push %rdi
push %rsi
lea addresses_UC_ht+0x2979, %r9
nop
and $30852, %r13
movb (%r9), %r12b
nop
inc %rbx
lea addresses_WC_ht+0x102f9, %rsi
lea addresses_WT_ht+0x1e479, %rdi
nop
nop
nop
nop
inc %r8
mov $35, %rcx
rep movsb
nop
nop
mfence
lea addresses_normal_ht+0x14359, %r9
and $11483, %rdi
movl $0x61626364, (%r9)
nop
nop
xor %r8, %r8
lea addresses_A_ht+0x1a379, %rsi
lea addresses_WT_ht+0x1a441, %rdi
nop
dec %rbx
mov $55, %rcx
rep movsq
nop
nop
nop
nop
sub %r8, %r8
lea addresses_UC_ht+0x1f89, %rsi
lea addresses_WC_ht+0xb479, %rdi
nop
nop
nop
nop
add %r12, %r12
mov $118, %rcx
rep movsq
cmp %rbx, %rbx
lea addresses_WT_ht+0x8679, %rsi
inc %r9
vmovups (%rsi), %ymm4
vextracti128 $1, %ymm4, %xmm4
vpextrq $0, %xmm4, %r13
nop
nop
and $1139, %r8
lea addresses_normal_ht+0xff79, %rsi
nop
nop
nop
nop
nop
sub %r12, %r12
mov (%rsi), %edi
nop
nop
nop
cmp %r13, %r13
pop %rsi
pop %rdi
pop %rcx
pop %rbx
pop %r9
pop %r8
pop %r13
pop %r12
ret
.global s_faulty_load
s_faulty_load:
push %r10
push %r12
push %r14
push %r15
push %r8
push %rbx
push %rsi
// Store
lea addresses_normal+0x13439, %r12
nop
nop
nop
nop
add %r15, %r15
movl $0x51525354, (%r12)
nop
nop
nop
nop
sub %r10, %r10
// Faulty Load
mov $0x50f8010000000079, %r15
nop
nop
nop
nop
inc %rbx
mov (%r15), %r12
lea oracles, %rsi
and $0xff, %r12
shlq $12, %r12
mov (%rsi,%r12,1), %r12
pop %rsi
pop %rbx
pop %r8
pop %r15
pop %r14
pop %r12
pop %r10
ret
/*
<gen_faulty_load>
[REF]
{'OP': 'LOAD', 'src': {'type': 'addresses_NC', 'size': 1, 'AVXalign': False, 'NT': False, 'congruent': 0, 'same': False}}
{'OP': 'STOR', 'dst': {'type': 'addresses_normal', 'size': 4, 'AVXalign': True, 'NT': False, 'congruent': 6, 'same': False}}
[Faulty Load]
{'OP': 'LOAD', 'src': {'type': 'addresses_NC', 'size': 8, 'AVXalign': False, 'NT': False, 'congruent': 0, 'same': True}}
<gen_prepare_buffer>
{'OP': 'LOAD', 'src': {'type': 'addresses_UC_ht', 'size': 1, 'AVXalign': False, 'NT': False, 'congruent': 7, 'same': False}}
{'OP': 'REPM', 'src': {'type': 'addresses_WC_ht', 'congruent': 7, 'same': False}, 'dst': {'type': 'addresses_WT_ht', 'congruent': 10, 'same': False}}
{'OP': 'STOR', 'dst': {'type': 'addresses_normal_ht', 'size': 4, 'AVXalign': False, 'NT': False, 'congruent': 5, 'same': False}}
{'OP': 'REPM', 'src': {'type': 'addresses_A_ht', 'congruent': 8, 'same': False}, 'dst': {'type': 'addresses_WT_ht', 'congruent': 3, 'same': False}}
{'OP': 'REPM', 'src': {'type': 'addresses_UC_ht', 'congruent': 4, 'same': False}, 'dst': {'type': 'addresses_WC_ht', 'congruent': 10, 'same': False}}
{'OP': 'LOAD', 'src': {'type': 'addresses_WT_ht', 'size': 32, 'AVXalign': False, 'NT': False, 'congruent': 6, 'same': False}}
{'OP': 'LOAD', 'src': {'type': 'addresses_normal_ht', 'size': 4, 'AVXalign': False, 'NT': False, 'congruent': 7, 'same': False}}
{'00': 16822}
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
*/
| 39.677852 | 2,999 | 0.659675 |
ff8453ba6e98bde2b327a21cd75c3bfc16f1415d | 2,953 | asm | Assembly | test_pic_got_plt.asm | gau-veldt/Godot-GDGD | 503320982a115b6832b480c9332229bae454c58c | [
"MIT"
] | 2 | 2019-04-26T12:28:04.000Z | 2021-10-14T21:26:29.000Z | test_pic_got_plt.asm | gau-veldt/Godot-GDGD | 503320982a115b6832b480c9332229bae454c58c | [
"MIT"
] | null | null | null | test_pic_got_plt.asm | gau-veldt/Godot-GDGD | 503320982a115b6832b480c9332229bae454c58c | [
"MIT"
] | null | null | null | cpu ia64
bits 64
default rel
;typedef struct {
; godot_bool in_editor;
; uint64_t core_api_hash;
; uint64_t editor_api_hash;
; uint64_t no_api_hash;
; void (*report_version_mismatch)(const godot_object *p_library, const char *p_what, godot_gdnative_api_version p_want, godot_gdnative_api_version p_have);
; void (*report_loading_error)(const godot_object *p_library, const char *p_what);
; godot_object *gd_native_library; // pointer to GDNativeLibrary that is being initialized
; const struct godot_gdnative_core_api_struct *api_struct;
; const godot_string *active_library_path;
;} godot_gdnative_init_options;
; assuming 8-byte alignment
gdnopt_in_editor equ 0x00
gdnopt_core_api_hash equ 0x08
gdnopt_editor_api_hash equ 0x10
gdnopt_no_api_hash equ 0x18
gdnopt_pf_report_version_mismatch equ 0x20
gdnopt_pf_report_loading_error equ 0x28
gdnopt_p_gd_native_library equ 0x30
gdnopt_p_api_struct equ 0x38
gdnopt_p_active_library_path equ 0x40
section .text
api dq 0
api_nativescript dq 0
global dllMain
export dllMain
dllMain:
; dllMain is a win64 thing so the three args,
; should they be needed, will be in rcx,rdx,r8
xor rax,rax
ret
; win64 param order: (rcx,rdx,r8,r9,... rest via stack...)
; mungeable: rcx,rdx,r8,r9,rax,r10,r11
; return value: int/ptr via RAX
; linux param order: (rdi,rsi,rdx,rcx,r8,r9,... rest via stack...)
; mungeable: rdi,rsi,rdx,rcx,r8,r9,rax,r10,r11
; return value: int/ptr via RAX,RDX
global godot_gdnative_init
export godot_gdnative_init
godot_gdnative_init:
; win64: godot_gdnative_init(godot_gdnative_options *p_options_volarg@rcx)
; lin64: godot_gdnative_init(godot_gdnative_options *p_options_volarg@rdi)
; returns: void
; prologue (rsp mod 16=8 due to return address)
push r15
push r14
push r13
push r12 ; save to allow use as localvars (save pairs to stay alignment-neutral)
push rbp ; rsp mod 16=0 (now aligned)
mov rbp,rsp
; allocate a minimum of 32 bytes (4 registers) in multiples of 16
sub rsp,0x40
; var p_options@r15=p_options_volarg@rcx (@rdi in linux64)
mov r15,rcx
; api=p_options->api_struct
mov rax,[abs r15+gdnopt_p_api_struct]
mov [rel api],rax
; epilogue
leave
pop r12
pop r13
pop r14
pop r15
ret
global godot_gdnative_terminate
export godot_gdnative_terminate
godot_gdnative_terminate:
; win64: godot_gdnative_terminate(godot_gdnative_terminate_options *p_options_volarg@rcx)
; lin64: godot_gdnative_terminate(godot_gdnative_terminate_options *p_options_volarg@rdi)
; returns: void
xor rax,rax
mov [rel api],rax
mov [rel api_nativescript],rax
ret
global godot_nativescript_init
export godot_nativescript_init
godot_nativescript_init:
; win64: godot_nativescript_init(void *p_handle@rcx)
; lin64: godot_nativescript_init(void *p_handle@rdi)
; returns: void
; nothing for now
ret
| 29.828283 | 156 | 0.752794 |
9c79ecf9f38c9911e1097b8c37f4539158da1bce | 5,284 | asm | Assembly | src/util/oli/qdos/sbchan.asm | olifink/qspread | d6403d210bdad9966af5d2a0358d4eed3f1e1c02 | [
"MIT"
] | null | null | null | src/util/oli/qdos/sbchan.asm | olifink/qspread | d6403d210bdad9966af5d2a0358d4eed3f1e1c02 | [
"MIT"
] | null | null | null | src/util/oli/qdos/sbchan.asm | olifink/qspread | d6403d210bdad9966af5d2a0358d4eed3f1e1c02 | [
"MIT"
] | null | null | null | * SuperBASIC channel stuff July 1989 J.R.Oakley QView
* (mod. for SMS2 keys.. O.Fink)
section utility
*
include win1_keys_bv
include win1_keys_chn
include win1_keys_err
include win1_keys_qdos_ioa
include win1_keys_qlv
ch.lench equ $28
ch.id equ $00
*
xdef sb_getch
xdef sb_numtoid
*+++
* Get a channel number and/or ID from first SuperBASIC parameter
* -> sb_getch
*
* Registers:
* Entry Exit
* D0 +ve no channel, -ve error, 0 channel OK
* D1 n if #n coded, else -1
* A0 channel ID if \device, else -1
* A3 first parameter updated if channel present
*---
sb_getch
get_ch
move.b 1(a6,a3.l),d0 ; hash?
bmi.s gc_chnum ; yes, it's a number
and.b #$70,d0 ; mask out separator
cmp.b #$30,d0 ; backslash?
beq.s gc_devic ; yes, it's a device
moveq #1,d0 ; no, no channel
exit
rts
chnumreg reg a2/a5
gc_chnum
movem.l chnumreg,-(sp)
lea 8(a3),a5 ; get just one parameter
move.w sb.gtint,a2 ; it's an integer
jsr (a2)
tst.l d0
bne.s gcn_exit ; ...oops
move.l a5,a3 ; remove parameter
move.l bv_rip(a6),a2
move.w 0(a6,a2.l),d1 ; this is channel number
sub.l a0,a0
subq.l #1,a0 ; no channel ID
gcn_exit
tst.l d0
movem.l (sp)+,chnumreg
rts
*
* Come here if first parameter followed by backslash: one after that is
* string or name: open this and return channel ID
*
gc_devic
addq.l #8,a3 ; skip first null parameter
bsr.s get_name ; and get a name to RI stack
bne.s gcd_exit
move.l a1,a0 ; it's here
moveq #-1,d1 ; for me
moveq #ioa.knew,d3 ; new (exclusive) file
moveq #ioa.open,d0
trap #4 ; A6-relative
trap #2 ; open it
tst.l d0
bne.s gcd_exit ; ...oops
moveq #-1,d1
gcd_exit
tst.l d0
rts
*
* Come here to get a string or name
*
gtnreg reg d1-d5/a0/a2/a5
get_name
movem.l gtnreg,-(sp)
move.b 1(a6,a3.l),d0 ; get type byte
and.b #$0F,d0 ; just the type
cmp.b #$01,d0 ; string?
beq.s gtn_gstr ; yes, get it
move.w 2(a6,a3.l),d0 ; no, get name pointer
bmi.s gtn_exbp ; bad is just -1 really...
*
* Come here if it was a name without quotes
*
ext.l d0
lsl.l #3,d0 ; index into name table
add.l bv_ntbas(a6),d0 ; which starts here
move.w 2(a6,d0.l),d0 ; so name is here is name list
ext.l d0
add.l bv_nlbas(a6),d0 ; i.e. here!
move.l d0,a2 ; keep it safe
moveq #0,d1
move.b (a6,a2.l),d1 ; name is this long
move.w d1,d4 ; keep it safe
addq.l #3,d1
bclr #0,d1 ; space for length
move.w d1,d5 ; keep that too
move.w qa.resri,a1 ; ensure...
jsr (a1) ; ...there'll be space for it all
move.l bv_rip(a6),a1
sub.w d5,a1 ; where string goes
move.l a1,a0 ; smashable copy
move.w d4,0(a6,a1.l) ; length to stack
bra.s gtn_cpne
gtn_cpnl
move.b 1(a6,a2.l),2(a6,a0.l) ; copy name characters
addq.l #1,a2
addq.l #1,a0
gtn_cpne
dbra d4,gtn_cpnl ; until they're all done
gtn_exok
addq.l #8,a3 ; knock parameter off list
moveq #0,d0
gtn_exit
movem.l (sp)+,gtnreg
rts
gtn_exbp
moveq #err.ipar,d0
bra.s gtn_exit
*
* Come here if the user put quotes on his device
*
gtn_gstr
move.w sb.gtstr,a1 ; get a string
jsr (a1)
move.l bv_rip(a6),a1 ; point to it
bra.s gtn_exit
*+++
* Convert SuperBASIC channel number into an ID
* -> sb_numtoid
*
* Entry: Exit:
* D0.w channel number A0 channel id
*---
sb_numtoid
numtoid
mulu #ch.lench,d0 ; SB channels are this big
add.l bv_chbas(a6),d0 ; and start here
cmp.l bv_chp(a6),d0 ; too high?
bge.s nti_exno ; yes, not open
move.l ch.id(a6,d0.l),d0 ; get ID
bmi.s nti_exno
move.l d0,a0
moveq #0,d0
nti_exit
rts
nti_exno
moveq #err.ichn,d0
bra.s nti_exit
*
end
| 33.443038 | 79 | 0.449659 |
df4459d8c02af85bd21390dc7fd5afa05f5d2537 | 1,341 | asm | Assembly | Python/examples/divi.asm | tomxp411/8080Asm | 0c11923933b0c12db109a8356b880fcc7f861d63 | [
"MIT"
] | null | null | null | Python/examples/divi.asm | tomxp411/8080Asm | 0c11923933b0c12db109a8356b880fcc7f861d63 | [
"MIT"
] | null | null | null | Python/examples/divi.asm | tomxp411/8080Asm | 0c11923933b0c12db109a8356b880fcc7f861d63 | [
"MIT"
] | null | null | null | ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;
; NAME: divi.asm
; EDITOR: Kevin Cole ("The Ubuntourist") <kevin.cole@novawebdevelopment.org>
; LASTMOD: 2020.11.22 (kjc)
;
; DESCRIPTION:
;
; Divide the contents of register pair BC by D.
; C will contain the quotient; B will contain the remainder.
;
; See Intel 8080 Assembly Prograamming Manual, pages 53-56.
;
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
ORG 000h
MVI B,00h
MVI C,63h ; dividend (BC) = 99 decimal
MVI D,00h
MVI E,09h ; divisor (DE) = 9 decimal
DIVI: MOV A,D ; Negate the divisor
CMA ; " " "
MOV D,A ; " " "
MOV A,E ; " " "
CMA ; " " "
MOV E,A ; " " "
INX D ; For two's complement
LXI H,00h ; Initial value for remainder
MVI A,11h ; Initialize loop counter
DV0: PUSH H ; Save remainder
DAD D ; Subtract divisor (add negative)
JNC DV1 ; Underflow. Restore register pair HL
XTHL
DV1: POP H
PUSH PSW ; Save loop counter
MOV A,C
RAL ; 4 register left shift?
MOV C,A ; CY->C->B->L->H?
MOV A,B
RAL
MOV B,A
MOV A,L
RAL
MOV L,A
MOV A,H
RAL
MOV H,A
POP PSW
DCR A
JNZ DV0
; Post-divide clean-up:
; Shift remainder right and return in DE
ORA A
MOV A,H
RAR
MOV D,A
MOV A,L
RAR
MOV E,A
HLT
END ; End
| 19.720588 | 78 | 0.541387 |
662d257d23b88968888aaf28dfc26d2ac37da21d | 274 | asm | Assembly | ffight/lcs/weapon/88.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/weapon/88.asm | zengfr/arcade_game_romhacking_sourcecode_top_secret_data | a4a0c86c200241494b3f1834cd0aef8dc02f7683 | [
"Apache-2.0"
] | null | null | null | ffight/lcs/weapon/88.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
009ACA dbra D5, $9ac8
057B34 move.b #$5, ($8a,A6)
057B54 jsr $440c.w [weapon+88]
058AF6 clr.b ($88,A6) [weapon+86]
058AFA move.b #$1, ($4a,A6)
copyright zengfr site:http://github.com/zengfr/romhack
| 27.4 | 54 | 0.664234 |
34a184319fad2e26c862d00983cb35596fcf5374 | 7,172 | asm | Assembly | src/new.asm | cmounce/all-purpose-tsr | 196ad7912a425bb9d2a785af5339970a53ad735a | [
"MIT"
] | null | null | null | src/new.asm | cmounce/all-purpose-tsr | 196ad7912a425bb9d2a785af5339970a53ad735a | [
"MIT"
] | null | null | null | src/new.asm | cmounce/all-purpose-tsr | 196ad7912a425bb9d2a785af5339970a53ad735a | [
"MIT"
] | null | null | null | ; Functionality for creating new TSRs
%include 'system.asm'
;-------------------------------------------------------------------------------
; Code
;-------------------------------------------------------------------------------
section .text
; Write a new TSR to a file.
create_new_tsr:
push bx
push si
; General flow:
; - For each option on command line, add that item to the bundle in memory
; - Open file as new file for writing
; - Copy from memory to file
; Before we begin, make sure we have an output file
cmp word [parsed_options.output], 0
begin_if e
die EXIT_BAD_ARGS, "Output file not provided"
end_if
; Build our bundle
call build_new_bundle
mov si, cx
; Create new file and save handle in BX
mov dx, [parsed_options.output]
call dos_create_new_file
begin_if c
die EXIT_ERROR, "Couldn't create file"
end_if
mov bx, ax ; BX = file handle
; Write program code to file
mov ah, 40h
; TODO: Create a global file with memory layout defines?
mov dx, 100h ; End of PSP
mov cx, start_of_bundle - 100h ; Copy program code up to bundle
int 21h
; TODO: It would be slightly more correct to check AX == CX as well
begin_if c
die EXIT_ERROR, "Couldn't write to file"
end_if
; Write bundle data to file
mov ah, 40h
mov dx, global_buffer ; DX = start of bundle to write
mov cx, si ; CX = size of bundle
int 21h
begin_if c
; TODO: Combine error messages/move this to a helper function
die EXIT_ERROR, "Couldn't write to file"
end_if
; Close file
call dos_close_file
begin_if c
die EXIT_ERROR, "Couldn't close file"
end_if
pop si
pop bx
ret
;-------------------------------------------------------------------------------
; Internal helpers
;-------------------------------------------------------------------------------
section .text
; Build a new bundle in global_buffer based on the parsed command-line args.
;
; Returns CX = size of the bundle in bytes
build_new_bundle:
push bx
push di
push si
mov di, global_buffer
; Add palette to the buffer, if specified
mov dx, [parsed_options.palette]
cmp dx, 0
begin_if ne
; Copy key "PALETTE" to buffer
mov si, bundle_keys.palette
call copy_wstring
next_wstring di
; Copy palette data to buffer
mov si, [parsed_options.palette]
mov cx, 48 + 1 ; Read extra byte to detect too-large palettes
mov dx, si ; DX = path to palette file
call read_wstring_from_path
begin_if c
die EXIT_ERROR, "Error reading %s", si
end_if
; Validate palette data
mov si, di
call validate_palette_wstring
begin_if c
die EXIT_ERROR, "Invalid palette: %s", word [parsed_options.palette]
end_if
next_wstring di
end_if
; Add font to the buffer, if specified
mov dx, [parsed_options.font]
cmp dx, 0
begin_if ne
; Copy key "FONT" to buffer
mov si, bundle_keys.font
call copy_wstring
next_wstring di
; Copy font data to buffer
mov dx, [parsed_options.font]
call read_font_from_path
next_wstring di
end_if
; Add secondary font to the buffer, if specified
mov dx, [parsed_options.font2]
cmp dx, 0
begin_if ne
; Verify that a primary font was specified
cmp word [parsed_options.font], 0
begin_if e
die EXIT_ERROR, "Can't use /F2 without /F"
end_if
; Copy key "FONT2" to buffer
mov si, bundle_keys.font2
call copy_wstring
next_wstring di
; Copy font data to buffer
mov dx, [parsed_options.font2]
call read_font_from_path
next_wstring di
end_if
; Set blink mode
mov dx, [parsed_options.blink]
cmp dx, 0
begin_if ne
; Copy key "BLINK" to buffer
mov si, bundle_keys.blink
call copy_wstring
next_wstring di
; Write boolean to buffer
mov si, [parsed_options.blink]
call parse_blink_mode
begin_if c
die EXIT_BAD_ARGS, "/B must be either ON or OFF"
end_if
mov word [di], 0 ; Write header for empty wstring
call concat_byte_wstring ; Append boolean byte
next_wstring di
end_if
; Terminate wstring list
mov word [di], 0
lea cx, [di + 2] ; CX = end of buffer - start of buffer
sub cx, global_buffer
pop si
pop di
pop bx
ret
; Read a font file into memory as a wstring
;
; DX = path to font file
; DI = location to write font data
read_font_from_path:
push bx
push si
; Save path so we can reference it multiple times
mov bx, dx
; Read font data
mov cx, 32*256 + 1 ; Max font size is at 32 bytes/character
call read_wstring_from_path
begin_if c
die EXIT_ERROR, "Error reading %s", bx
end_if
; Validate font data
mov si, di
call validate_font_wstring
begin_if c
die EXIT_ERROR, "Invalid font: %s", bx
end_if
pop si
pop bx
ret
; Open a file and read its contents into a wstring
;
; CX = maximum bytes to read
; DX = wstring containing a path to a file
; DI = location to write the result
; Sets CF on failure.
read_wstring_from_path:
push bx
; Open file and set BX = handle
push cx ; Don't overwrite our argument CX
call dos_open_existing_file
pop cx
jc .ret ; Open failed: forward CF to caller
mov bx, ax
; Read CX bytes from handle
call read_wstring_from_handle
begin_if c
; Read failed
call dos_close_file ; Attempt to clean up, but make sure
stc ; we still return failure.
else
; Read succeeded: clean up
call dos_close_file
end_if
.ret:
pop bx
ret
; Read bytes from a file into a wstring
;
; BX = file handle to read from
; CX = maximum number of bytes to read
; DI = location to write the wstring
; Sets CF on failure.
read_wstring_from_handle:
mov ah, 3fh ; DOS read from handle
lea dx, [di + 2] ; DX = pointer to wstring data
int 21h
begin_if c
ret ; Error: forward CF to caller
end_if
mov [di], ax ; Write actual number of bytes to wstring header
; Return successful.
; We don't need `clc` because CF should still be clear from the DOS call.
ret
; Translates a blink-mode string into a boolean value.
;
; SI = blink-mode wstring ("off" or "on")
; Returns AL = 0 or 1.
; Sets CF on failure.
parse_blink_mode:
push di
mov di, arg_option_values.off
call icmp_wstring
begin_if e
mov al, 0
else
mov di, arg_option_values.on
call icmp_wstring
if e
mov al, 1
else
stc ; Neither "on" nor "off": return an error
jmp .ret
end_if
.ret:
pop di
ret
| 25.076923 | 80 | 0.584635 |
bb77455f1951af8534547bb5151d4abd4fc627ef | 335 | asm | Assembly | oeis/341/A341413.asm | neoneye/loda-programs | 84790877f8e6c2e821b183d2e334d612045d29c0 | [
"Apache-2.0"
] | 11 | 2021-08-22T19:44:55.000Z | 2022-03-20T16:47:57.000Z | oeis/341/A341413.asm | neoneye/loda-programs | 84790877f8e6c2e821b183d2e334d612045d29c0 | [
"Apache-2.0"
] | 9 | 2021-08-29T13:15:54.000Z | 2022-03-09T19:52:31.000Z | oeis/341/A341413.asm | neoneye/loda-programs | 84790877f8e6c2e821b183d2e334d612045d29c0 | [
"Apache-2.0"
] | 3 | 2021-08-22T20:56:47.000Z | 2021-09-29T06:26:12.000Z | ; A341413: a(n) = (Sum_{k=1..7} k^n) mod n.
; Submitted by Jon Maiga
; 0,0,1,0,3,2,0,4,1,0,6,8,2,0,4,4,11,14,9,16,7,8,5,20,8,10,1,0,28,20,28,4,25,4,14,32,28,26,4,36,28,20,28,12,28,2,28,20,0,0,19,48,28,32,34,28,43,24,28,56,28,16,28,4,18,20,28,52,25,0,28,68,28,66,19,40
add $0,1
mov $2,$0
seq $0,1554 ; 1^n + 2^n + ... + 7^n.
mod $0,$2
| 37.222222 | 198 | 0.570149 |
09f81835b70a16f91b36e373ad2374cf70edbe8f | 463 | asm | Assembly | oeis/076/A076690.asm | neoneye/loda-programs | 84790877f8e6c2e821b183d2e334d612045d29c0 | [
"Apache-2.0"
] | 11 | 2021-08-22T19:44:55.000Z | 2022-03-20T16:47:57.000Z | oeis/076/A076690.asm | neoneye/loda-programs | 84790877f8e6c2e821b183d2e334d612045d29c0 | [
"Apache-2.0"
] | 9 | 2021-08-29T13:15:54.000Z | 2022-03-09T19:52:31.000Z | oeis/076/A076690.asm | neoneye/loda-programs | 84790877f8e6c2e821b183d2e334d612045d29c0 | [
"Apache-2.0"
] | 3 | 2021-08-22T20:56:47.000Z | 2021-09-29T06:26:12.000Z | ; A076690: Nearest integer to average of the smallest and largest prime factors of n (0.5 is rounded to 1).
; Submitted by Christian Krause
; 2,3,2,5,3,7,2,3,4,11,3,13,5,4,2,17,3,19,4,5,7,23,3,5,8,3,5,29,4,31,2,7,10,6,3,37,11,8,4,41,5,43,7,4,13,47,3,7,4,10,8,53,3,8,5,11,16,59,4,61,17,5,2,9,7,67,10,13,5,71,3,73,20,4,11,9,8,79,4,3,22,83,5,11,23,16
add $0,1
seq $0,74320 ; a(n) = sum of smallest and largest prime factors of n, for n>1; a(1)=2.
add $0,1
div $0,2
| 51.444444 | 207 | 0.647948 |
997a9aeabf8a92c890f2d957a0232d4643965bdf | 501 | asm | Assembly | programs/oeis/115/A115561.asm | neoneye/loda | afe9559fb53ee12e3040da54bd6aa47283e0d9ec | [
"Apache-2.0"
] | 22 | 2018-02-06T19:19:31.000Z | 2022-01-17T21:53:31.000Z | programs/oeis/115/A115561.asm | neoneye/loda | afe9559fb53ee12e3040da54bd6aa47283e0d9ec | [
"Apache-2.0"
] | 41 | 2021-02-22T19:00:34.000Z | 2021-08-28T10:47:47.000Z | programs/oeis/115/A115561.asm | neoneye/loda | afe9559fb53ee12e3040da54bd6aa47283e0d9ec | [
"Apache-2.0"
] | 5 | 2021-02-24T21:14:16.000Z | 2021-08-09T19:48:05.000Z | ; A115561: a(n) = lpf((n/lpf(n))/lpf(n/lpf(n))), where lpf=A020639, least prime factor.
; 1,1,1,1,1,1,1,2,1,1,1,3,1,1,1,2,1,3,1,5,1,1,1,2,1,1,3,7,1,5,1,2,1,1,1,3,1,1,1,2,1,7,1,11,5,1,1,2,1,5,1,13,1,3,1,2,1,1,1,3,1,1,7,2,1,11,1,17,1,7,1,2,1,1,5,19,1,13,1,2,3,1,1,3,1,1,1,2,1,3,1,23,1,1,1,2,1,7,11,5
mov $2,54
lpb $2
mov $1,$0
seq $1,20639 ; Lpf(n): least prime dividing n (when n > 1); a(1) = 1. Or, smallest prime factor of n, or smallest prime divisor of n.
div $0,$1
div $2,6
lpe
mov $0,$1
| 41.75 | 209 | 0.572854 |
fb1248b2764ac5feceee3f12003d2f7eaa8d0c39 | 5,605 | asm | Assembly | c2nasm/library.asm | TimerChen/MxCompiler | 656c751fc460026dabb551d938ea0991f57050e4 | [
"MIT"
] | 2 | 2018-05-16T08:14:55.000Z | 2018-05-29T11:22:06.000Z | c2nasm/library.asm | TimerChen/MxCompiler | 656c751fc460026dabb551d938ea0991f57050e4 | [
"MIT"
] | null | null | null | c2nasm/library.asm | TimerChen/MxCompiler | 656c751fc460026dabb551d938ea0991f57050e4 | [
"MIT"
] | null | null | null |
default rel
global __array_array
global __array_new
global __string_string
global _print
global _println
global __string_length
global __string_substring
global __string_parseInt
global __string_ord
global __string__plus
global __string__less
global __string__lessEqual
global __string__equal
global __array_size
extern strcmp
extern strcpy
extern strtol
extern puts
extern _IO_putc
extern stdout
extern malloc
extern _GLOBAL_OFFSET_TABLE_
SECTION .text 6
__array_array:
push rbx
mov ebx, edi
lea edi, [rdi*8]
movsxd rdi, edi
add rdi, 4
call malloc
mov dword [rax], ebx
add rax, 4
pop rbx
ret
ALIGN 8
__array_new:
push r15
push r14
mov r14d, edx
push r13
push r12
mov r13d, esi
push rbp
push rbx
mov rbx, rdi
mov r12, rcx
sub rsp, 24
mov r15, qword [rdi]
lea edi, [r15*8]
movsxd rdi, edi
add rdi, 4
call malloc
mov rbp, rax
add rax, 4
test r15, r15
mov qword [rsp], rax
mov dword [rbp], r15d
jle L_003
lea eax, [r13-1H]
mov r15d, 1
mov dword [rsp+0CH], eax
L_001: cmp r13d, 1
jg L_004
test r12, r12
jz L_002
movsxd rdi, r14d
call malloc
mov qword [rbp+r15*8-4H], rax
mov rdi, rax
call r12
L_002: mov rax, r15
add r15, 1
cmp rax, qword [rbx]
jl L_001
L_003: mov rax, qword [rsp]
add rsp, 24
pop rbx
pop rbp
pop r12
pop r13
pop r14
pop r15
ret
L_004: mov esi, dword [rsp+0CH]
lea rdi, [rbx+8H]
mov rcx, r12
mov edx, r14d
call __array_new
mov qword [rbp+r15*8-4H], rax
jmp L_002
ALIGN 8
__string_string:
push rbx
movsxd rbx, edi
lea edi, [rbx+1H]
movsxd rdi, edi
add rdi, 4
call malloc
mov rdx, rax
lea rax, [rax+4H]
mov dword [rdx], ebx
mov byte [rdx+rbx+4H], 0
pop rbx
ret
ALIGN 16
_print:
push rbx
mov rbx, rdi
movzx edi, byte [rdi]
test dil, dil
jz L_006
ALIGN 8
L_005: mov rsi, qword [rel stdout]
add rbx, 1
call _IO_putc
movzx edi, byte [rbx]
test dil, dil
jnz L_005
L_006: pop rbx
ret
ALIGN 8
_println:
jmp puts
nop
ALIGN 16
__string_length:
mov eax, dword [rdi-4H]
ret
ALIGN 16
__string_substring:
push r13
push r12
mov r13, rsi
push rbp
push rbx
mov ebx, edx
sub ebx, esi
mov rbp, rdi
lea edi, [rbx+2H]
lea r12d, [rbx+1H]
sub rsp, 8
movsxd rdi, edi
add rdi, 4
call malloc
movsxd rdx, r12d
mov rdi, rax
add rax, 4
test r12d, r12d
mov dword [rdi], r12d
mov byte [rdi+rdx+4H], 0
jle L_008
mov ecx, ebx
lea r8, [rbp+r13]
xor edx, edx
add rcx, 1
ALIGN 8
L_007: movzx esi, byte [r8+rdx]
mov byte [rdi+rdx+4H], sil
add rdx, 1
cmp rdx, rcx
jnz L_007
L_008: add rsp, 8
pop rbx
pop rbp
pop r12
pop r13
ret
ALIGN 8
__string_parseInt:
sub rsp, 8
mov edx, 10
xor esi, esi
call strtol
add rsp, 8
ret
nop
ALIGN 16
__string_ord:
movsxd rsi, esi
movzx eax, byte [rdi+rsi]
ret
ALIGN 16
__string__plus:
push r14
push r13
mov r14, rdi
push r12
push rbp
mov r13, rsi
push rbx
mov ebx, dword [rdi-4H]
mov ebp, dword [rsi-4H]
add ebp, ebx
lea edi, [rbp+1H]
movsxd rdi, edi
add rdi, 4
call malloc
lea r12, [rax+4H]
mov dword [rax], ebp
movsxd rbp, ebp
mov rsi, r14
mov byte [rax+rbp+4H], 0
mov rdi, r12
call strcpy
movsxd rdi, ebx
mov rsi, r13
add rdi, r12
call strcpy
pop rbx
mov rax, r12
pop rbp
pop r12
pop r13
pop r14
ret
ALIGN 16
__string__less:
sub rsp, 8
call strcmp
cmp eax, -1
sete al
add rsp, 8
ret
ALIGN 16
__string__lessEqual:
sub rsp, 8
call strcmp
test eax, eax
setle al
add rsp, 8
ret
ALIGN 16
__string__equal:
sub rsp, 8
call strcmp
test eax, eax
sete al
add rsp, 8
ret
ALIGN 16
__array_size:
mov eax, dword [rdi-4H]
ret
SECTION .data
SECTION .bss
| 15.067204 | 41 | 0.444246 |
3d50d181ba25ab9ba588bdc3048be3315c2effec | 489 | asm | Assembly | hw5/add_N_terms_to_polynomial_test.asm | Cyfurion/CSE220 | 81dba7e7557e4812104f4b605819732e321bd58a | [
"Unlicense"
] | null | null | null | hw5/add_N_terms_to_polynomial_test.asm | Cyfurion/CSE220 | 81dba7e7557e4812104f4b605819732e321bd58a | [
"Unlicense"
] | null | null | null | hw5/add_N_terms_to_polynomial_test.asm | Cyfurion/CSE220 | 81dba7e7557e4812104f4b605819732e321bd58a | [
"Unlicense"
] | null | null | null | .data
pair: .word 6 10
terms: .word 2 12 4 -14 5 11 0 -1
p: .word 0
N: .word 2
.text:
main:
la $a0, p
la $a1, pair
jal init_polynomial
la $a0, p
la $a1, terms
lw $a2, N
jal add_N_terms_to_polynomial
#write test code
li $v0, 1
la $s0, p
lw $s0, 0($s0)
lw $a0, 0($s0)
syscall
lw $a0, 4($s0)
syscall
lw $s0, 8($s0)
lw $a0, 0($s0)
syscall
lw $a0, 4($s0)
syscall
li $v0, 10
syscall
.include "hw5.asm"
| 13.583333 | 33 | 0.515337 |
cf26c1c322625e6588b1b5a1b902027175098a90 | 8,259 | asm | Assembly | Transynther/x86/_processed/NC/_zr_/i3-7100_9_0xca_notsx.log_21829_99.asm | ljhsiun2/medusa | 67d769b8a2fb42c538f10287abaf0e6dbb463f0c | [
"MIT"
] | 9 | 2020-08-13T19:41:58.000Z | 2022-03-30T12:22:51.000Z | Transynther/x86/_processed/NC/_zr_/i3-7100_9_0xca_notsx.log_21829_99.asm | ljhsiun2/medusa | 67d769b8a2fb42c538f10287abaf0e6dbb463f0c | [
"MIT"
] | 1 | 2021-04-29T06:29:35.000Z | 2021-05-13T21:02:30.000Z | Transynther/x86/_processed/NC/_zr_/i3-7100_9_0xca_notsx.log_21829_99.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 %r14
push %r15
push %r9
push %rax
push %rbp
push %rcx
push %rdi
push %rsi
lea addresses_WT_ht+0xa5b1, %r9
nop
dec %r15
mov (%r9), %r14
nop
nop
nop
nop
and $31567, %r13
lea addresses_A_ht+0x19511, %rax
sub $23111, %rbp
movl $0x61626364, (%rax)
nop
nop
nop
dec %r13
lea addresses_normal_ht+0x16631, %rsi
lea addresses_D_ht+0x1d883, %rdi
clflush (%rdi)
nop
nop
nop
add %r9, %r9
mov $121, %rcx
rep movsl
nop
nop
nop
nop
cmp %rsi, %rsi
lea addresses_normal_ht+0xf431, %rsi
lea addresses_WC_ht+0x122f1, %rdi
nop
cmp %r9, %r9
mov $76, %rcx
rep movsq
nop
nop
nop
nop
nop
and $34192, %rdi
lea addresses_UC_ht+0x6f61, %r9
add $51928, %rax
mov (%r9), %di
nop
and $63795, %r9
lea addresses_D_ht+0x15ad1, %rsi
lea addresses_A_ht+0x5931, %rdi
nop
add $58346, %r14
mov $22, %rcx
rep movsl
lfence
lea addresses_normal_ht+0x13ee8, %rcx
nop
nop
add $31002, %rax
mov (%rcx), %r14d
nop
xor %r15, %r15
lea addresses_WT_ht+0x118b1, %rsi
lea addresses_UC_ht+0x9db1, %rdi
nop
xor %r14, %r14
mov $14, %rcx
rep movsq
nop
nop
dec %rcx
pop %rsi
pop %rdi
pop %rcx
pop %rbp
pop %rax
pop %r9
pop %r15
pop %r14
pop %r13
ret
.global s_faulty_load
s_faulty_load:
push %r13
push %r15
push %rax
push %rbx
push %rcx
push %rdi
push %rdx
push %rsi
// Store
lea addresses_A+0xe771, %r13
nop
nop
nop
inc %rcx
movw $0x5152, (%r13)
xor $20115, %rdx
// REPMOV
lea addresses_A+0x37b1, %rsi
lea addresses_D+0x8fb1, %rdi
nop
nop
nop
nop
cmp $39883, %rax
mov $126, %rcx
rep movsw
nop
nop
nop
nop
dec %rbx
// Store
lea addresses_D+0xf5b1, %r13
nop
nop
nop
nop
add $30355, %rsi
mov $0x5152535455565758, %rax
movq %rax, %xmm7
movups %xmm7, (%r13)
nop
nop
nop
nop
add $31003, %rdx
// REPMOV
lea addresses_WC+0xeb91, %rsi
lea addresses_normal+0xb4bd, %rdi
xor %r13, %r13
mov $38, %rcx
rep movsq
nop
nop
inc %rbx
// REPMOV
lea addresses_RW+0x1b1f1, %rsi
lea addresses_PSE+0x1f7f1, %rdi
nop
nop
cmp $42737, %r13
mov $112, %rcx
rep movsb
nop
sub %rdx, %rdx
// Store
lea addresses_RW+0x129b1, %r15
nop
nop
nop
dec %rcx
movb $0x51, (%r15)
nop
nop
nop
nop
nop
cmp $38399, %rbx
// Load
lea addresses_UC+0x14431, %rsi
nop
xor $24496, %rdi
movaps (%rsi), %xmm3
vpextrq $0, %xmm3, %rbx
nop
nop
nop
inc %rsi
// Load
lea addresses_normal+0xe89a, %rdi
nop
nop
nop
nop
nop
dec %rbx
mov (%rdi), %r13w
add %rdi, %rdi
// Store
lea addresses_WC+0x19fb1, %rdx
nop
dec %rsi
movb $0x51, (%rdx)
nop
nop
nop
nop
and %r13, %r13
// Faulty Load
mov $0x2a29290000000db1, %rsi
nop
nop
nop
nop
sub $25326, %rcx
mov (%rsi), %bx
lea oracles, %rdx
and $0xff, %rbx
shlq $12, %rbx
mov (%rdx,%rbx,1), %rbx
pop %rsi
pop %rdx
pop %rdi
pop %rcx
pop %rbx
pop %rax
pop %r15
pop %r13
ret
/*
<gen_faulty_load>
[REF]
{'src': {'same': False, 'congruent': 0, 'NT': True, 'type': 'addresses_NC', 'size': 2, 'AVXalign': False}, 'OP': 'LOAD'}
{'OP': 'STOR', 'dst': {'same': False, 'congruent': 4, 'NT': False, 'type': 'addresses_A', 'size': 2, 'AVXalign': False}}
{'src': {'type': 'addresses_A', 'congruent': 9, 'same': False}, 'OP': 'REPM', 'dst': {'type': 'addresses_D', 'congruent': 9, 'same': False}}
{'OP': 'STOR', 'dst': {'same': True, 'congruent': 11, 'NT': False, 'type': 'addresses_D', 'size': 16, 'AVXalign': False}}
{'src': {'type': 'addresses_WC', 'congruent': 4, 'same': True}, 'OP': 'REPM', 'dst': {'type': 'addresses_normal', 'congruent': 2, 'same': False}}
{'src': {'type': 'addresses_RW', 'congruent': 5, 'same': False}, 'OP': 'REPM', 'dst': {'type': 'addresses_PSE', 'congruent': 6, 'same': False}}
{'OP': 'STOR', 'dst': {'same': False, 'congruent': 8, 'NT': False, 'type': 'addresses_RW', 'size': 1, 'AVXalign': False}}
{'src': {'same': False, 'congruent': 7, 'NT': False, 'type': 'addresses_UC', 'size': 16, 'AVXalign': True}, 'OP': 'LOAD'}
{'src': {'same': False, 'congruent': 0, 'NT': False, 'type': 'addresses_normal', 'size': 2, 'AVXalign': False}, 'OP': 'LOAD'}
{'OP': 'STOR', 'dst': {'same': False, 'congruent': 9, 'NT': False, 'type': 'addresses_WC', 'size': 1, 'AVXalign': False}}
[Faulty Load]
{'src': {'same': True, 'congruent': 0, 'NT': False, 'type': 'addresses_NC', 'size': 2, 'AVXalign': False}, 'OP': 'LOAD'}
<gen_prepare_buffer>
{'src': {'same': False, 'congruent': 5, 'NT': False, 'type': 'addresses_WT_ht', 'size': 8, 'AVXalign': True}, 'OP': 'LOAD'}
{'OP': 'STOR', 'dst': {'same': False, 'congruent': 5, 'NT': False, 'type': 'addresses_A_ht', 'size': 4, 'AVXalign': False}}
{'src': {'type': 'addresses_normal_ht', 'congruent': 7, 'same': False}, 'OP': 'REPM', 'dst': {'type': 'addresses_D_ht', 'congruent': 0, 'same': False}}
{'src': {'type': 'addresses_normal_ht', 'congruent': 7, 'same': False}, 'OP': 'REPM', 'dst': {'type': 'addresses_WC_ht', 'congruent': 6, 'same': False}}
{'src': {'same': False, 'congruent': 4, 'NT': False, 'type': 'addresses_UC_ht', 'size': 2, 'AVXalign': False}, 'OP': 'LOAD'}
{'src': {'type': 'addresses_D_ht', 'congruent': 1, 'same': False}, 'OP': 'REPM', 'dst': {'type': 'addresses_A_ht', 'congruent': 6, 'same': False}}
{'src': {'same': False, 'congruent': 0, 'NT': False, 'type': 'addresses_normal_ht', 'size': 4, 'AVXalign': False}, 'OP': 'LOAD'}
{'src': {'type': 'addresses_WT_ht', 'congruent': 8, 'same': True}, 'OP': 'REPM', 'dst': {'type': 'addresses_UC_ht', 'congruent': 9, 'same': False}}
{'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
*/
| 31.522901 | 2,999 | 0.653469 |
421179610df10c361b95fa6daec4e6c798313c77 | 409 | asm | Assembly | oeis/087/A087206.asm | neoneye/loda-programs | 84790877f8e6c2e821b183d2e334d612045d29c0 | [
"Apache-2.0"
] | 11 | 2021-08-22T19:44:55.000Z | 2022-03-20T16:47:57.000Z | oeis/087/A087206.asm | neoneye/loda-programs | 84790877f8e6c2e821b183d2e334d612045d29c0 | [
"Apache-2.0"
] | 9 | 2021-08-29T13:15:54.000Z | 2022-03-09T19:52:31.000Z | oeis/087/A087206.asm | neoneye/loda-programs | 84790877f8e6c2e821b183d2e334d612045d29c0 | [
"Apache-2.0"
] | 3 | 2021-08-22T20:56:47.000Z | 2021-09-29T06:26:12.000Z | ; A087206: a(n) = 2*a(n-1) + 4*a(n-2); with a(0)=1, a(1)=4.
; Submitted by Jamie Morken(s2)
; 1,4,12,40,128,416,1344,4352,14080,45568,147456,477184,1544192,4997120,16171008,52330496,169345024,548012032,1773404160,5738856448,18571329536,60098084864,194481487872,629355315200,2036636581888
mov $1,2
pow $1,$0
add $0,2
seq $0,45 ; Fibonacci numbers: F(n) = F(n-1) + F(n-2) with F(0) = 0 and F(1) = 1.
mul $0,$1
| 40.9 | 195 | 0.691932 |
f58293c6267e70f3b68cc4eb32a2e85d868fd561 | 874 | asm | Assembly | oeis/186/A186244.asm | neoneye/loda-programs | 84790877f8e6c2e821b183d2e334d612045d29c0 | [
"Apache-2.0"
] | 11 | 2021-08-22T19:44:55.000Z | 2022-03-20T16:47:57.000Z | oeis/186/A186244.asm | neoneye/loda-programs | 84790877f8e6c2e821b183d2e334d612045d29c0 | [
"Apache-2.0"
] | 9 | 2021-08-29T13:15:54.000Z | 2022-03-09T19:52:31.000Z | oeis/186/A186244.asm | neoneye/loda-programs | 84790877f8e6c2e821b183d2e334d612045d29c0 | [
"Apache-2.0"
] | 3 | 2021-08-22T20:56:47.000Z | 2021-09-29T06:26:12.000Z | ; A186244: Number of ternary strings of length n containing 00.
; Submitted by Jon Maiga
; 0,0,1,5,21,79,281,963,3217,10547,34089,108955,345137,1085331,3392377,10549739,32667201,100782787,309946697,950599131,2908512145,8880484019,27064776729,82350874699,250212362465,759269653155,2301393567721,6968615051195,21081883066161,63726593719699,192493746026681,581071056857643,1753020737863297,5285856985725827,15930775636030089,47992325810067355,144523384591861457,435062965902857331,1309267336286436697,3938944510269585419,11847275410785036321,35624994995128219747,107102206270883440937
mov $1,1
mov $2,1
lpb $0
mov $3,1
lpb $3
add $2,1
sub $2,$3
mod $2,2
mov $4,$1
cmp $4,1
cmp $4,0
sub $3,$4
mul $7,2
add $7,$6
add $7,$1
lpe
sub $0,1
add $2,2
mul $1,$2
mul $7,$5
mov $5,-1
sub $6,$7
add $7,$6
lpe
mov $0,$6
div $0,3
| 28.193548 | 492 | 0.73341 |
1290dd837787ea59c65dadfc82394f79b0fece0e | 228 | asm | Assembly | pkgs/tools/yasm/src/modules/preprocs/nasm/tests/ifcritical-err.asm | manggoguy/parsec-modified | d14edfb62795805c84a4280d67b50cca175b95af | [
"BSD-3-Clause"
] | 2,151 | 2020-04-18T07:31:17.000Z | 2022-03-31T08:39:18.000Z | pkgs/tools/yasm/src/modules/preprocs/nasm/tests/ifcritical-err.asm | manggoguy/parsec-modified | d14edfb62795805c84a4280d67b50cca175b95af | [
"BSD-3-Clause"
] | 395 | 2020-04-18T08:22:18.000Z | 2021-12-08T13:04:49.000Z | pkgs/tools/yasm/src/modules/preprocs/nasm/tests/ifcritical-err.asm | manggoguy/parsec-modified | d14edfb62795805c84a4280d67b50cca175b95af | [
"BSD-3-Clause"
] | 338 | 2020-04-18T08:03:10.000Z | 2022-03-29T12:33:22.000Z | ; This worked under NASM. Due to the once-parse model used by YASM, this no
; longer works. However, it should error, not crash!
teststring db "Hello, world"
teststringlen equ $-teststring
%if teststringlen>100
db '5'
%endif
| 28.5 | 76 | 0.745614 |
3628d38718188d017582e41a0fb3e03198d2a599 | 6,172 | asm | Assembly | loader/fixed_loader_x86.asm | AntiRootkit/Amber | a331b344bf33aa1a4c14b33da36fb7273e30c987 | [
"MIT"
] | 461 | 2017-10-24T13:22:13.000Z | 2020-11-19T18:17:40.000Z | loader/fixed_loader_x86.asm | AntiRootkit/Amber | a331b344bf33aa1a4c14b33da36fb7273e30c987 | [
"MIT"
] | 12 | 2020-11-25T16:08:07.000Z | 2022-02-14T16:24:48.000Z | loader/fixed_loader_x86.asm | AntiRootkit/Amber | a331b344bf33aa1a4c14b33da36fb7273e30c987 | [
"MIT"
] | 133 | 2017-10-24T17:53:56.000Z | 2020-09-03T15:40:00.000Z | ;#==================================================#
;# x86 Fixed Address Reflective Stub (no relocation)#
;# Author: Ege Balcı <egebalci@pm.me> #
;# Version: 2.0 #
;#==================================================#
[BITS 32]
[ORG 0]
call start ; Get the address of pre-mapped PE image to stack
incbin "pemap.bin" ; Pre-mapped PE image
start: ;
cld ; Clear direction flags
pop esi ; Get the address of image to esi
call $+5 ; Push the current EIP to stack
sub [esp],esi ; Subtract &PE from EIP and get image_size
mov eax,[esi+0x3C] ; Get the offset of "PE" to eax
mov ebx,[eax+esi+0x34] ; Get the image base address to ebx
mov eax,[eax+esi+0x28] ; Get the address of entry point to eax
push eax ; Save the address of entry to stack
push ebx ; Save image base to stack
push 0x00000000 ; Allocate a DWORD variable inside stack
push esp ; lpflOldProtect
push 0x40 ; PAGE_EXECUTE_READWRITE
push dword [esp+0x14] ; dwSize
push ebx ; lpAddress
push 0x80886EF1 ; crc32( "kernel32.dll", "VirtualProtect" )
call api_call ; VirtualProtect( ImageBase, image_size, PAGE_EXECUTE_READWRITE, lpflOldProtect)
pop eax ; Fix the stack
mov eax,[esi+0x3C] ; Offset to IMAGE_NT_HEADER ("PE")
mov eax,[eax+esi+0x80] ; Import table RVA
add eax,esi ; Import table memory address (first image import descriptor)
push eax ; Save the address of import descriptor to stack
get_modules:
cmp dword [eax],0x00 ; Check if the import names table RVA is NULL
jz complete ; If yes building process is done
mov eax,[eax+0x0C] ; Get RVA of dll name to eax
add eax,esi ; Get the dll name address
call LoadLibraryA ; Load the library
mov ebx,eax ; Move the dll handle to ebx
mov eax,[esp] ; Move the address of current _IMPORT_DESCRIPTOR to eax
call get_procs ; Resolve all windows API function addresses
add dword [esp],0x14 ; Move to the next import descriptor
mov eax,[esp] ; Set the new import descriptor address to eax
jmp get_modules
get_procs:
push ecx ; Save ecx to stack
push dword [eax+0x10] ; Save the current import descriptor IAT RVA
add [esp],esi ; Get the IAT memory address
mov eax,[eax] ; Set the import names table RVA to eax
add eax,esi ; Get the current import descriptor's import names table address
push eax ; Save it to stack
resolve:
cmp dword [eax],0x00 ; Check if end of the import names table
jz all_resolved ; If yes resolving process is done
mov eax,[eax] ; Get the RVA of function hint to eax
cmp eax,0x80000000 ; Check if the high order bit is set
js name_resolve ; If high order bit is not set resolve with INT entry
sub eax,0x80000000 ; Zero out the high bit
call GetProcAddress ; Get the API address with hint
jmp insert_iat ; Insert the address of API tı IAT
name_resolve:
add eax,esi ; Set the address of function hint
add eax,0x02 ; Move to function name
call GetProcAddress ; Get the function address to eax
insert_iat:
mov ecx,[esp+4] ; Move the IAT address to ecx
mov [ecx],eax ; Insert the function address to IAT
add dword [esp],0x04 ; Increase the import names table index
add dword [esp+4],0x04 ; Increase the IAT index
mov eax,[esp] ; Set the address of import names table address to eax
jmp resolve ; Loop
all_resolved:
mov ecx,[esp+4] ; Move the IAT address to ecx
mov dword [ecx],0x00 ; Insert a NULL dword
pop ecx ; Deallocate index values
pop ecx ; ...
pop ecx ; Put back the ecx value
ret ; <-
LoadLibraryA:
push ecx ; Save ecx to stack
push edx ; Save edx to stack
push eax ; Push the address of linrary name string
push 0xE2E6A091 ; ror13( "kernel32.dll", "LoadLibraryA" )
call api_call ; LoadLibraryA([esp+4])
pop edx ; Retreive edx
pop ecx ; Retreive ecx
ret ; <-
GetProcAddress:
push ecx ; Save ecx to stack
push edx ; Save edx to stack
push eax ; Push the address of proc name string
push ebx ; Push the dll handle
push 0xA18B0B38 ; ror13( "kernel32.dll", "GetProcAddress" )
call api_call ; GetProcAddress(ebx,[esp+4])
pop edx ; Retrieve edx
pop ecx ; Retrieve ecx
ret ; <-
complete:
pop eax ; Clean out the stack
pop edi ; ..
mov edx,edi ; Copy the address of new base to EDX
pop eax ; Pop the address_of_entry to EAX
add edi,eax ; Add the address of entry to new image base
pop ecx ; Pop the image_size to ECX
memcpy:
mov al,[esi] ; Move 1 byte of PE image to AL register
mov byte [edx],al ; Move 1 byte of PE image to image base
mov byte [esi],0 ; Overwrite copied byte (for less memory footprint)
inc esi ; Increase PE image index
inc edx ; Increase image base index
loop memcpy ; Loop until ECX = 0
jmp PE_start
; ========== API ==========
%include "CRC32_API/x86_crc32_api.asm"
PE_start:
mov ecx,wipe ; Get the number of bytes until wipe label
call wipe_start ; Call wipe_start
wipe_start:
pop eax ; Get EIP to EAX
wipe:
mov byte [eax],0 ; Wipe 1 byte at a time
dec eax ; Decraise EAX
loop wipe ; Loop until ECX = 0
ret ; Return to AOE | 48.21875 | 106 | 0.562541 |
450e6e7305e0f2f368373b20057b9262f89e542d | 5,599 | asm | Assembly | Transynther/x86/_processed/NONE/_xt_/i7-8650U_0xd2_notsx.log_31_403.asm | ljhsiun2/medusa | 67d769b8a2fb42c538f10287abaf0e6dbb463f0c | [
"MIT"
] | 9 | 2020-08-13T19:41:58.000Z | 2022-03-30T12:22:51.000Z | Transynther/x86/_processed/NONE/_xt_/i7-8650U_0xd2_notsx.log_31_403.asm | ljhsiun2/medusa | 67d769b8a2fb42c538f10287abaf0e6dbb463f0c | [
"MIT"
] | 1 | 2021-04-29T06:29:35.000Z | 2021-05-13T21:02:30.000Z | Transynther/x86/_processed/NONE/_xt_/i7-8650U_0xd2_notsx.log_31_403.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 %r12
push %r13
push %r14
push %rbx
push %rcx
push %rdi
push %rsi
lea addresses_WT_ht+0x13bbb, %rdi
nop
nop
nop
nop
xor %rbx, %rbx
movw $0x6162, (%rdi)
nop
nop
nop
nop
and $34997, %r12
lea addresses_UC_ht+0xb3bb, %rbx
xor %r13, %r13
mov $0x6162636465666768, %rsi
movq %rsi, (%rbx)
nop
nop
nop
nop
nop
xor %r12, %r12
lea addresses_A_ht+0x1efbb, %r12
nop
inc %r14
mov $0x6162636465666768, %rsi
movq %rsi, %xmm3
movups %xmm3, (%r12)
nop
add %rdi, %rdi
lea addresses_A_ht+0x10dbb, %r14
clflush (%r14)
cmp $37968, %rsi
mov $0x6162636465666768, %rbx
movq %rbx, (%r14)
nop
nop
nop
sub %r10, %r10
lea addresses_UC_ht+0xaf3b, %r12
nop
nop
nop
nop
add $54310, %rsi
movb (%r12), %r10b
nop
nop
sub $18726, %r10
lea addresses_A_ht+0xf1bb, %rsi
nop
nop
nop
nop
xor %rdi, %rdi
movl $0x61626364, (%rsi)
nop
inc %rdi
lea addresses_A_ht+0xa41f, %r10
nop
and $39297, %r14
vmovups (%r10), %ymm6
vextracti128 $1, %ymm6, %xmm6
vpextrq $1, %xmm6, %rbx
nop
nop
sub %rbx, %rbx
lea addresses_D_ht+0x8fbb, %r14
nop
nop
nop
nop
inc %rdi
mov $0x6162636465666768, %r12
movq %r12, %xmm1
movups %xmm1, (%r14)
nop
nop
nop
cmp $57554, %rdi
lea addresses_A_ht+0x15877, %r10
nop
nop
nop
nop
cmp %rbx, %rbx
movl $0x61626364, (%r10)
and %rdi, %rdi
lea addresses_UC_ht+0x8bad, %rbx
nop
nop
nop
nop
nop
cmp $30863, %r10
mov (%rbx), %r12w
nop
nop
nop
cmp %rsi, %rsi
lea addresses_D_ht+0x1c01b, %rsi
lea addresses_WT_ht+0x1517b, %rdi
inc %r12
mov $14, %rcx
rep movsw
nop
nop
nop
nop
xor $42529, %rdi
lea addresses_D_ht+0x127bb, %rsi
lea addresses_normal_ht+0xdaa7, %rdi
clflush (%rdi)
nop
nop
cmp %r14, %r14
mov $68, %rcx
rep movsb
nop
xor $55504, %r13
lea addresses_WT_ht+0x4465, %r12
nop
nop
nop
nop
mfence
mov (%r12), %si
nop
sub $40821, %r13
lea addresses_normal_ht+0x15a5b, %rsi
lea addresses_D_ht+0x63bb, %rdi
nop
nop
nop
add $28251, %rbx
mov $49, %rcx
rep movsl
cmp %rsi, %rsi
lea addresses_A_ht+0x129ab, %r14
nop
nop
add $50678, %r12
mov $0x6162636465666768, %rdi
movq %rdi, (%r14)
sub %r13, %r13
pop %rsi
pop %rdi
pop %rcx
pop %rbx
pop %r14
pop %r13
pop %r12
pop %r10
ret
.global s_faulty_load
s_faulty_load:
push %r11
push %r12
push %r14
push %r8
push %rax
push %rbx
push %rcx
// Store
lea addresses_normal+0x253b, %r12
clflush (%r12)
sub $7489, %r14
movl $0x51525354, (%r12)
nop
nop
add %rcx, %rcx
// Store
lea addresses_A+0x90c1, %r8
nop
nop
nop
nop
dec %rcx
movl $0x51525354, (%r8)
// Exception!!!
nop
nop
nop
nop
mov (0), %rax
nop
xor %rax, %rax
// Store
lea addresses_PSE+0x18bbb, %rax
nop
nop
nop
nop
nop
and %r14, %r14
mov $0x5152535455565758, %rbx
movq %rbx, (%rax)
nop
nop
nop
nop
cmp %r8, %r8
// Faulty Load
lea addresses_WT+0x19bbb, %rbx
nop
nop
cmp $39561, %r11
movb (%rbx), %cl
lea oracles, %r12
and $0xff, %rcx
shlq $12, %rcx
mov (%r12,%rcx,1), %rcx
pop %rcx
pop %rbx
pop %rax
pop %r8
pop %r14
pop %r12
pop %r11
ret
/*
<gen_faulty_load>
[REF]
{'OP': 'LOAD', 'src': {'type': 'addresses_WT', 'size': 1, 'AVXalign': False, 'NT': False, 'congruent': 0, 'same': False}}
{'OP': 'STOR', 'dst': {'type': 'addresses_normal', 'size': 4, 'AVXalign': False, 'NT': False, 'congruent': 6, 'same': False}}
{'OP': 'STOR', 'dst': {'type': 'addresses_A', 'size': 4, 'AVXalign': False, 'NT': True, 'congruent': 1, 'same': False}}
{'OP': 'STOR', 'dst': {'type': 'addresses_PSE', 'size': 8, 'AVXalign': False, 'NT': True, 'congruent': 11, 'same': False}}
[Faulty Load]
{'OP': 'LOAD', 'src': {'type': 'addresses_WT', 'size': 1, 'AVXalign': False, 'NT': False, 'congruent': 0, 'same': True}}
<gen_prepare_buffer>
{'OP': 'STOR', 'dst': {'type': 'addresses_WT_ht', 'size': 2, 'AVXalign': False, 'NT': True, 'congruent': 11, 'same': False}}
{'OP': 'STOR', 'dst': {'type': 'addresses_UC_ht', 'size': 8, 'AVXalign': False, 'NT': False, 'congruent': 11, 'same': False}}
{'OP': 'STOR', 'dst': {'type': 'addresses_A_ht', 'size': 16, 'AVXalign': False, 'NT': False, 'congruent': 10, 'same': False}}
{'OP': 'STOR', 'dst': {'type': 'addresses_A_ht', 'size': 8, 'AVXalign': False, 'NT': False, 'congruent': 8, 'same': True}}
{'OP': 'LOAD', 'src': {'type': 'addresses_UC_ht', 'size': 1, 'AVXalign': False, 'NT': False, 'congruent': 7, 'same': False}}
{'OP': 'STOR', 'dst': {'type': 'addresses_A_ht', 'size': 4, 'AVXalign': False, 'NT': False, 'congruent': 9, 'same': False}}
{'OP': 'LOAD', 'src': {'type': 'addresses_A_ht', 'size': 32, 'AVXalign': False, 'NT': False, 'congruent': 2, 'same': False}}
{'OP': 'STOR', 'dst': {'type': 'addresses_D_ht', 'size': 16, 'AVXalign': False, 'NT': False, 'congruent': 8, 'same': False}}
{'OP': 'STOR', 'dst': {'type': 'addresses_A_ht', 'size': 4, 'AVXalign': False, 'NT': False, 'congruent': 1, 'same': False}}
{'OP': 'LOAD', 'src': {'type': 'addresses_UC_ht', 'size': 2, 'AVXalign': False, 'NT': False, 'congruent': 1, 'same': False}}
{'OP': 'REPM', 'src': {'type': 'addresses_D_ht', 'congruent': 3, 'same': False}, 'dst': {'type': 'addresses_WT_ht', 'congruent': 6, 'same': False}}
{'OP': 'REPM', 'src': {'type': 'addresses_D_ht', 'congruent': 7, 'same': False}, 'dst': {'type': 'addresses_normal_ht', 'congruent': 2, 'same': False}}
{'OP': 'LOAD', 'src': {'type': 'addresses_WT_ht', 'size': 2, 'AVXalign': False, 'NT': False, 'congruent': 1, 'same': False}}
{'OP': 'REPM', 'src': {'type': 'addresses_normal_ht', 'congruent': 0, 'same': False}, 'dst': {'type': 'addresses_D_ht', 'congruent': 11, 'same': False}}
{'OP': 'STOR', 'dst': {'type': 'addresses_A_ht', 'size': 8, 'AVXalign': False, 'NT': False, 'congruent': 4, 'same': False}}
{'39': 31}
39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39
*/
| 21.048872 | 152 | 0.648151 |
d23a62350c1ff564a0d1cdf76bcbba9cc11ae17f | 6,201 | asm | Assembly | Driver/IFS/GEOS/Common/gfsUtils.asm | steakknife/pcgeos | 95edd7fad36df400aba9bab1d56e154fc126044a | [
"Apache-2.0"
] | 504 | 2018-11-18T03:35:53.000Z | 2022-03-29T01:02:51.000Z | Driver/IFS/GEOS/Common/gfsUtils.asm | steakknife/pcgeos | 95edd7fad36df400aba9bab1d56e154fc126044a | [
"Apache-2.0"
] | 96 | 2018-11-19T21:06:50.000Z | 2022-03-06T10:26:48.000Z | Driver/IFS/GEOS/Common/gfsUtils.asm | steakknife/pcgeos | 95edd7fad36df400aba9bab1d56e154fc126044a | [
"Apache-2.0"
] | 73 | 2018-11-19T20:46:53.000Z | 2022-03-29T00:59:26.000Z | COMMENT @%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
Copyright (c) GeoWorks 1993 -- All Rights Reserved
PROJECT:
MODULE:
FILE: gfsUtils.asm
AUTHOR: Adam de Boor, Apr 14, 1993
ROUTINES:
Name Description
---- -----------
REVISION HISTORY:
Name Date Description
---- ---- -----------
Adam 4/14/93 Initial revision
DESCRIPTION:
Device-independent utility routines.
$Id: gfsUtils.asm,v 1.1 97/04/18 11:46:31 newdeal Exp $
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%@
Movable segment resource
COMMENT @%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
GFSReadEntireLink
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
SYNOPSIS: Read the full contents of a link into memory.
CALLED BY: EXTERNAL
GFSMPReadLink
PASS: es:di = GFSDirEntry
RETURN: carry clear if ok:
ds, ^hbx= GFSLinkData, followed by saved disk,
target path, and extra data. Block locked
once
ax = destroyed
carry set on error:
ax = FileError
DESTROYED: nothing
SIDE EFFECTS:
PSEUDO CODE/STRATEGY:
REVISION HISTORY:
Name Date Description
---- ---- -----------
ardeb 4/14/93 Initial version
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%@
GFSReadEntireLink proc near
uses es, di, si, cx
.enter
;
; Allocate room to hold the whole file.
;
mov ax, es:[di].GDE_size.low
mov cx, ALLOC_DYNAMIC_LOCK
call MemAlloc
jnc readData
mov ax, ERROR_INSUFFICIENT_MEMORY
jmp err
readData:
movdw dxsi, es:[di].GDE_data
mov cx, es:[di].GDE_size.low
mov es, ax
mov ds, ax
clr di ; es:di <- destination
mov_tr ax, si ; dxax <- read offset
call GFSDevRead
jnc done
call MemFree
err:
stc
done:
.leave
ret
GFSReadEntireLink endp
Movable ends
Resident segment
COMMENT @%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
GFSCallPrimary
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
SYNOPSIS: Call the primary FSD to do something for us.
CALLED BY: INTERNAL
PASS: di = DOSPrimaryFSFunction to call
etc.
RETURN: whatever
DESTROYED: bp before the call is made
PSEUDO CODE/STRATEGY:
KNOWN BUGS/SIDE EFFECTS/IDEAS:
REVISION HISTORY:
Name Date Description
---- ---- -----------
ardeb 3/29/92 Initial version
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%@
GFSCPFrame struct
GCPF_ds sptr
GCPF_vector fptr.far
GFSCPFrame ends
GFSCallPrimary proc far
.enter
push bx, ax, ds
mov bp, sp
segmov ds, dgroup, ax
mov bx, ds:[gfsPrimaryStrat].segment
mov ax, ds:[gfsPrimaryStrat].offset
xchg ax, ss:[bp].GCPF_vector.offset
xchg bx, ss:[bp].GCPF_vector.segment
mov ds, ss:[bp].GCPF_ds
call ss:[bp].GCPF_vector
mov bp, sp
lea sp, ss:[bp+size GFSCPFrame]
.leave
ret
GFSCallPrimary endp
COMMENT @%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
GFSNotifyIfNecessary
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
SYNOPSIS: Send open/close notification if required.
CALLED BY: EXTERNAL (GFSAllocOp, GFSHandleOp)
PASS: cxdx = file ID
ax = FileChangeNotificationType
RETURN: FILESYSTEM IS UNLOCKED
DESTROYED: cx (flags preserved)
SIDE EFFECTS:
PSEUDO CODE/STRATEGY:
REVISION HISTORY:
Name Date Description
---- ---- -----------
ardeb 4/16/93 Initial version
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%@
GFSNotifyIfNecessary proc far
uses es, bx, si, ds, di
.enter
pushf
call FSDCheckOpenCloseNotifyEnabled
jnc unlockDone
;
; Count the number of references there are now to the file so we can
; decide whether to notify or not.
;
call LoadVarSegDS
segmov es, ds
mov si, offset gfsFileTable - offset GFTB_next
mov di, cx
clr bx, cx ; no references so far
countRefBlockLoop:
tst es:[si].GFTB_next
jz checkRefCount
mov es, es:[si].GFTB_next
mov cx, length GFTB_entries
mov si, offset GFTB_entries
entryLoop:
cmp es:[si].GFE_refCount, 0
je nextEntry
cmpdw didx, es:[si].GFE_extAttrs
jne nextEntry
add bl, es:[si].GFE_refCount
nextEntry:
add si, size GFSFileEntry
loop entryLoop
clr si
jmp countRefBlockLoop
checkRefCount:
;
; Release the filesystem now so the code for FSDGenerateNotify
; can be faulted in, if necessary.
;
call GFSDevUnlock
;
; bl = # references to the file
; cx = 0
;
cmp ax, FCNT_CLOSE
je compareToGoal ; => need 0 references to notify
inc cx ; is open, so need 1 and only 1
; reference
compareToGoal:
cmp cx, bx
jne done ; => no notification required
;
; Now locate the disk registered for our drive.
;
mov cx, di
mov si, ds:[gfsDisk]
tst si
jz findDisk
haveDisk::
call FSDGenerateNotify
done:
popf
.leave
ret
unlockDone:
call GFSDevUnlock
jmp done
findDisk:
PCMCIAEC < ERROR CANNOT_FIND_GFS_DISK >
if not _PCMCIA
push ax
call FSDLockInfoShared
mov es, ax
mov si, offset FIH_diskList - offset DD_next
mov bx, ds:[gfsDrive]
findDiskLoop:
mov si, es:[si].DD_next
EC < tst si >
EC < ERROR_Z CANNOT_FIND_GFS_DISK >
cmp es:[si].DD_drive, bx
jne findDiskLoop
call FSDUnlockInfoShared
pop ax
mov ds:[gfsDisk], si
jmp haveDisk
endif
GFSNotifyIfNecessary endp
COMMENT @%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
LoadVarSegDS
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
SYNOPSIS:
CALLED BY:
PASS:
RETURN:
DESTROYED:
SIDE EFFECTS:
PSEUDO CODE/STRATEGY:
REVISION HISTORY:
Name Date Description
---- ---- -----------
ardeb 4/14/93 Initial version
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%@
dgroupSeg sptr dgroup
LoadVarSegDS proc near
.enter
mov ds, cs:[dgroupSeg]
.leave
ret
LoadVarSegDS endp
Resident ends
| 21.911661 | 79 | 0.547976 |
8dbe49a3c910689c4b4570db56dd17271b989be2 | 1,023 | asm | Assembly | programs/oeis/172/A172272.asm | karttu/loda | 9c3b0fc57b810302220c044a9d17db733c76a598 | [
"Apache-2.0"
] | null | null | null | programs/oeis/172/A172272.asm | karttu/loda | 9c3b0fc57b810302220c044a9d17db733c76a598 | [
"Apache-2.0"
] | null | null | null | programs/oeis/172/A172272.asm | karttu/loda | 9c3b0fc57b810302220c044a9d17db733c76a598 | [
"Apache-2.0"
] | null | null | null | ; A172272: a(n) = floor(n*(sqrt(11)-sqrt(3))).
; 0,1,3,4,6,7,9,11,12,14,15,17,19,20,22,23,25,26,28,30,31,33,34,36,38,39,41,42,44,45,47,49,50,52,53,55,57,58,60,61,63,64,66,68,69,71,72,74,76,77,79,80,82,83,85,87,88,90,91,93,95,96,98,99,101,102,104,106,107,109,110,112,114,115,117,118,120,122,123,125,126,128,129,131,133,134,136,137,139,141,142,144,145,147,148,150,152,153,155,156,158,160,161,163,164,166,167,169,171,172,174,175,177,179,180,182,183,185,186,188,190,191,193,194,196,198,199,201,202,204,205,207,209,210,212,213,215,217,218,220,221,223,225,226,228,229,231,232,234,236,237,239,240,242,244,245,247,248,250,251,253,255,256,258,259,261,263,264,266,267,269,270,272,274,275,277,278,280,282,283,285,286,288,289,291,293,294,296,297,299,301,302,304,305,307,308,310,312,313,315,316,318,320,321,323,324,326,328,329,331,332,334,335,337,339,340,342,343,345,347,348,350,351,353,354,356,358,359,361,362,364,366,367,369,370,372,373,375,377,378,380,381,383,385,386,388,389,391,392,394
mov $1,4096
mul $1,$0
div $1,7007
add $1,$0
| 127.875 | 930 | 0.714565 |
8c529358e4ba239047e5d32df9ae5ca7c4130f01 | 1,245 | asm | Assembly | programs/oeis/188/A188161.asm | neoneye/loda | afe9559fb53ee12e3040da54bd6aa47283e0d9ec | [
"Apache-2.0"
] | 22 | 2018-02-06T19:19:31.000Z | 2022-01-17T21:53:31.000Z | programs/oeis/188/A188161.asm | neoneye/loda | afe9559fb53ee12e3040da54bd6aa47283e0d9ec | [
"Apache-2.0"
] | 41 | 2021-02-22T19:00:34.000Z | 2021-08-28T10:47:47.000Z | programs/oeis/188/A188161.asm | neoneye/loda | afe9559fb53ee12e3040da54bd6aa47283e0d9ec | [
"Apache-2.0"
] | 5 | 2021-02-24T21:14:16.000Z | 2021-08-09T19:48:05.000Z | ; A188161: 2*4^n + 3.
; 5,11,35,131,515,2051,8195,32771,131075,524291,2097155,8388611,33554435,134217731,536870915,2147483651,8589934595,34359738371,137438953475,549755813891,2199023255555,8796093022211,35184372088835,140737488355331,562949953421315,2251799813685251,9007199254740995,36028797018963971,144115188075855875,576460752303423491,2305843009213693955,9223372036854775811,36893488147419103235,147573952589676412931,590295810358705651715,2361183241434822606851,9444732965739290427395,37778931862957161709571,151115727451828646838275,604462909807314587353091,2417851639229258349412355,9671406556917033397649411,38685626227668133590597635,154742504910672534362390531,618970019642690137449562115,2475880078570760549798248451,9903520314283042199192993795,39614081257132168796771975171,158456325028528675187087900675,633825300114114700748351602691,2535301200456458802993406410755,10141204801825835211973625643011,40564819207303340847894502572035,162259276829213363391578010288131,649037107316853453566312041152515,2596148429267413814265248164610051,10384593717069655257060992658440195,41538374868278621028243970633760771,166153499473114484112975882535043075,664613997892457936451903530140172291
mov $1,4
pow $1,$0
mul $1,2
add $1,3
mov $0,$1
| 138.333333 | 1,174 | 0.922892 |
f6153dcd8fb8d7665a69dde522f4d5c2999753ba | 696 | asm | Assembly | oeis/018/A018069.asm | neoneye/loda-programs | 84790877f8e6c2e821b183d2e334d612045d29c0 | [
"Apache-2.0"
] | 11 | 2021-08-22T19:44:55.000Z | 2022-03-20T16:47:57.000Z | oeis/018/A018069.asm | neoneye/loda-programs | 84790877f8e6c2e821b183d2e334d612045d29c0 | [
"Apache-2.0"
] | 9 | 2021-08-29T13:15:54.000Z | 2022-03-09T19:52:31.000Z | oeis/018/A018069.asm | neoneye/loda-programs | 84790877f8e6c2e821b183d2e334d612045d29c0 | [
"Apache-2.0"
] | 3 | 2021-08-22T20:56:47.000Z | 2021-09-29T06:26:12.000Z | ; A018069: Expansion of 1/((1-3x)(1-8x)(1-10x)).
; Submitted by Jamie Morken(s4)
; 1,21,307,3873,45235,504633,5465323,58007361,606913219,6283868745,64556638939,659310178449,6703052628403,67910134629657,686138217844555,6917677165178337,69627131588692387,699874195511336169,7027564992496080571,70506234225184818225,706907016657127066771,7083827561823962097081,70956334780292533465387,710507821099442777789313,7112633997366849752513155,71186786264648720610701193,712351432974331532657397403,7127382892366077564574542801,71304777424642896426542433139,713295362254285999142177737305
add $0,1
mov $3,1
lpb $0
sub $0,1
add $2,$3
add $1,$2
mul $1,8
mul $2,10
mul $3,3
lpe
mov $0,$1
div $0,8
| 40.941176 | 496 | 0.827586 |
636d286cc0d0880906f5be705abc54c6e4ec00dd | 20 | asm | Assembly | release/src-rt-6.x.4708/router/nettle/ecc-256-redc.asm | zaion520/ATtomato | 4d48bb79f8d147f89a568cf18da9e0edc41f93fb | [
"FSFAP"
] | 2 | 2019-01-13T09:19:10.000Z | 2019-02-15T01:21:02.000Z | release/src-rt-6.x.4708/router/nettle/ecc-256-redc.asm | zaion520/ATtomato | 4d48bb79f8d147f89a568cf18da9e0edc41f93fb | [
"FSFAP"
] | null | null | null | release/src-rt-6.x.4708/router/nettle/ecc-256-redc.asm | zaion520/ATtomato | 4d48bb79f8d147f89a568cf18da9e0edc41f93fb | [
"FSFAP"
] | 2 | 2020-03-08T01:58:25.000Z | 2020-12-20T10:34:54.000Z | arm/ecc-256-redc.asm | 20 | 20 | 0.8 |
caa26d052de77d690c627e5f5086d8f4903e12cb | 498 | asm | Assembly | programs/oeis/316/A316320.asm | karttu/loda | 9c3b0fc57b810302220c044a9d17db733c76a598 | [
"Apache-2.0"
] | null | null | null | programs/oeis/316/A316320.asm | karttu/loda | 9c3b0fc57b810302220c044a9d17db733c76a598 | [
"Apache-2.0"
] | null | null | null | programs/oeis/316/A316320.asm | karttu/loda | 9c3b0fc57b810302220c044a9d17db733c76a598 | [
"Apache-2.0"
] | null | null | null | ; A316320: Coordination sequence for a hexavalent node in a chamfered version of the 3^6 triangular tiling of the plane.
; 1,6,15,27,39,51,63,75,87,99,111,123,135,147,159,171,183,195,207,219,231,243,255,267,279,291,303,315,327,339,351,363,375,387,399,411,423,435,447,459,471,483,495,507,519,531,543,555,567,579,591,603,615,627,639
mov $2,$0
add $2,1
mov $3,$0
lpb $2,1
mov $0,$3
sub $2,1
sub $0,$2
mov $4,$0
mov $0,1
mul $4,4
add $0,$4
lpb $0,1
mov $0,12
lpe
add $1,$0
lpe
| 24.9 | 209 | 0.656627 |
d2c024897c01a0d5d86960d5f616d76a4924c76b | 2,365 | asm | Assembly | lib/c128_crt0.asm | grancier/z180 | e83f35e36c9b4d1457e40585019430e901c86ed9 | [
"ClArtistic"
] | null | null | null | lib/c128_crt0.asm | grancier/z180 | e83f35e36c9b4d1457e40585019430e901c86ed9 | [
"ClArtistic"
] | null | null | null | lib/c128_crt0.asm | grancier/z180 | e83f35e36c9b4d1457e40585019430e901c86ed9 | [
"ClArtistic"
] | 1 | 2019-12-03T23:57:48.000Z | 2019-12-03T23:57:48.000Z | ; Commodore 128 (Z80 mode) CRT0 stub
;
; Stefano Bodrato - 22/08/2001
;
; $Id: c128_crt0.asm,v 1.28 2016/07/15 21:03:25 dom Exp $
;
MODULE c128_crt0
;--------
; Include zcc_opt.def to find out some info
;--------
defc crt0 = 1
INCLUDE "zcc_opt.def"
; Only the ANSI terminal is available
defc NEED_ansiterminal = 1
;--------
; Some scope definitions
;--------
EXTERN _main ;main() is always external to crt0 code
PUBLIC cleanup ;jp'd to by exit()
PUBLIC l_dcal ;jp(hl)
; Now, getting to the real stuff now!
IF !DEFINED_CRT_ORG_CODE
defc CRT_ORG_CODE = $3000
ENDIF
org CRT_ORG_CODE
start:
di
;ld bc,$d030
;ld a,1
;out (c),a ; high speed clock
;ld bc,$d018
;ld a,$45
;out (c),a ; 40 columns text at $2000
ld bc,$d018
;ld a,$17 ; Standard display address ($400)..
ld a,$87 ; Display addres at $2000...
out (c),a ; ...and alternate (upper+lower) char set
ld a,11 ;dark grey
ld bc,$d020
out (c),a ;border
inc c
out (c),a ;& background
ld hl,0
add hl,sp
ld (start1+1),hl
ld hl,-64
add hl,sp
ld sp,hl
call crt0_init_bss
ld (exitsp),sp
; Optional definition for auto MALLOC init
; it assumes we have free space between the end of
; the compiled program and the stack pointer
IF DEFINED_USING_amalloc
INCLUDE "amalloc.def"
ENDIF
call _main
; Loop border color and wait for the RUNSTOP key
;brdloop: ld bc,$d020 ;border colour
; in a,(c)
; inc a
; out (c),a
; ld bc,$dc01 ;key in
; in a,(c)
; ??? inc bc ?
; in b,(c)
; cp b
; jr z,brdloop ;no key pressed
cleanup:
;
; Deallocate memory which has been allocated here!
;
IF !DEFINED_nostreams
EXTERN closeall
call closeall
ENDIF
;ld bc,$d030
;xor a
;out (c),a ; back to slow speed clock
start1:
ld sp,0
jp $FFE0
l_dcal:
jp (hl)
defm "Small C+ C128"
defb 0
INCLUDE "crt0_runtime_selection.asm"
INCLUDE "crt0_section.asm"
SECTION code_crt_init
ld hl,$2000
ld (base_graphics),hl
PUBLIC _vdcDispMem
defc _vdcDispMem = base_graphics
| 18.622047 | 74 | 0.55518 |
4c6a61a9ecfa991ddeb9297f5f3045b731687e21 | 8,558 | asm | Assembly | Transynther/x86/_processed/NONE/_zr_/i7-8650U_0xd2.log_21829_408.asm | ljhsiun2/medusa | 67d769b8a2fb42c538f10287abaf0e6dbb463f0c | [
"MIT"
] | 9 | 2020-08-13T19:41:58.000Z | 2022-03-30T12:22:51.000Z | Transynther/x86/_processed/NONE/_zr_/i7-8650U_0xd2.log_21829_408.asm | ljhsiun2/medusa | 67d769b8a2fb42c538f10287abaf0e6dbb463f0c | [
"MIT"
] | 1 | 2021-04-29T06:29:35.000Z | 2021-05-13T21:02:30.000Z | Transynther/x86/_processed/NONE/_zr_/i7-8650U_0xd2.log_21829_408.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 %r13
push %r14
push %r15
push %rbx
push %rcx
push %rdi
push %rsi
lea addresses_A_ht+0x4395, %r14
clflush (%r14)
nop
nop
sub %rdi, %rdi
movb (%r14), %bl
nop
sub %rsi, %rsi
lea addresses_normal_ht+0x656d, %rsi
lea addresses_A_ht+0xed, %rdi
nop
sub $13888, %r13
mov $82, %rcx
rep movsq
nop
nop
sub $41398, %r14
lea addresses_WT_ht+0x9d15, %rsi
lea addresses_WC_ht+0x3d6d, %rdi
nop
nop
nop
nop
nop
dec %r12
mov $70, %rcx
rep movsb
nop
nop
nop
nop
nop
add %rsi, %rsi
lea addresses_WT_ht+0x162e1, %rbx
nop
nop
nop
inc %r12
and $0xffffffffffffffc0, %rbx
movntdqa (%rbx), %xmm3
vpextrq $0, %xmm3, %r13
inc %rdi
lea addresses_D_ht+0x18acc, %r14
nop
nop
nop
nop
cmp %rsi, %rsi
mov $0x6162636465666768, %rcx
movq %rcx, (%r14)
nop
nop
nop
and $17351, %rbx
lea addresses_normal_ht+0x13fdd, %rdi
dec %rcx
movl $0x61626364, (%rdi)
nop
and $26555, %rbx
lea addresses_A_ht+0xad0d, %rsi
lea addresses_UC_ht+0x1276d, %rdi
nop
nop
xor $63308, %r15
mov $5, %rcx
rep movsb
nop
nop
sub $62121, %rsi
lea addresses_normal_ht+0x1accd, %rdi
nop
nop
sub $50714, %r15
mov (%rdi), %r14
nop
nop
cmp $14736, %rcx
lea addresses_WC_ht+0x1976d, %rbx
nop
nop
inc %r12
mov (%rbx), %r14d
nop
nop
nop
nop
nop
xor $38121, %r14
lea addresses_WT_ht+0xbddd, %rsi
lea addresses_UC_ht+0x266d, %rdi
clflush (%rsi)
nop
dec %r14
mov $11, %rcx
rep movsw
nop
nop
nop
cmp $23839, %rdi
lea addresses_D_ht+0xb76d, %rsi
lea addresses_UC_ht+0x1376d, %rdi
nop
cmp %r13, %r13
mov $68, %rcx
rep movsl
nop
nop
inc %rcx
lea addresses_WT_ht+0x142f9, %r15
nop
nop
nop
nop
nop
sub $51713, %rcx
mov (%r15), %r14w
nop
sub $2850, %r15
lea addresses_D_ht+0x18f6d, %rbx
and %r15, %r15
and $0xffffffffffffffc0, %rbx
movntdqa (%rbx), %xmm0
vpextrq $1, %xmm0, %r13
nop
nop
nop
add $9758, %r13
pop %rsi
pop %rdi
pop %rcx
pop %rbx
pop %r15
pop %r14
pop %r13
pop %r12
ret
.global s_faulty_load
s_faulty_load:
push %r10
push %r11
push %r14
push %r15
push %rbp
push %rcx
push %rdi
// Store
lea addresses_US+0x16b25, %r10
nop
nop
nop
nop
nop
and $21193, %rbp
movw $0x5152, (%r10)
nop
nop
add $27924, %r10
// Store
lea addresses_WC+0xef6d, %rdi
and %r11, %r11
mov $0x5152535455565758, %r15
movq %r15, %xmm5
vmovups %ymm5, (%rdi)
nop
nop
inc %rbp
// Store
lea addresses_UC+0x17f6d, %r14
nop
nop
nop
nop
add $35363, %rbp
mov $0x5152535455565758, %r15
movq %r15, (%r14)
add %rcx, %rcx
// Store
lea addresses_WT+0x8250, %r15
nop
nop
nop
nop
nop
add $9041, %rbp
movl $0x51525354, (%r15)
nop
inc %r10
// Store
lea addresses_US+0x18c6d, %r11
nop
nop
nop
sub $28179, %rdi
movb $0x51, (%r11)
cmp $452, %rbp
// Faulty Load
lea addresses_WC+0xef6d, %r15
nop
nop
sub %r11, %r11
vmovups (%r15), %ymm7
vextracti128 $1, %ymm7, %xmm7
vpextrq $1, %xmm7, %r14
lea oracles, %r15
and $0xff, %r14
shlq $12, %r14
mov (%r15,%r14,1), %r14
pop %rdi
pop %rcx
pop %rbp
pop %r15
pop %r14
pop %r11
pop %r10
ret
/*
<gen_faulty_load>
[REF]
{'OP': 'LOAD', 'src': {'type': 'addresses_WC', 'size': 8, 'AVXalign': False, 'NT': True, 'congruent': 0, 'same': True}}
{'OP': 'STOR', 'dst': {'type': 'addresses_US', 'size': 2, 'AVXalign': False, 'NT': False, 'congruent': 3, 'same': False}}
{'OP': 'STOR', 'dst': {'type': 'addresses_WC', 'size': 32, 'AVXalign': False, 'NT': False, 'congruent': 0, 'same': True}}
{'OP': 'STOR', 'dst': {'type': 'addresses_UC', 'size': 8, 'AVXalign': False, 'NT': False, 'congruent': 8, 'same': False}}
{'OP': 'STOR', 'dst': {'type': 'addresses_WT', 'size': 4, 'AVXalign': False, 'NT': False, 'congruent': 0, 'same': False}}
{'OP': 'STOR', 'dst': {'type': 'addresses_US', 'size': 1, 'AVXalign': True, 'NT': False, 'congruent': 7, 'same': False}}
[Faulty Load]
{'OP': 'LOAD', 'src': {'type': 'addresses_WC', 'size': 32, 'AVXalign': False, 'NT': False, 'congruent': 0, 'same': True}}
<gen_prepare_buffer>
{'OP': 'LOAD', 'src': {'type': 'addresses_A_ht', 'size': 1, 'AVXalign': False, 'NT': False, 'congruent': 3, 'same': False}}
{'OP': 'REPM', 'src': {'type': 'addresses_normal_ht', 'congruent': 6, 'same': False}, 'dst': {'type': 'addresses_A_ht', 'congruent': 6, 'same': False}}
{'OP': 'REPM', 'src': {'type': 'addresses_WT_ht', 'congruent': 2, 'same': False}, 'dst': {'type': 'addresses_WC_ht', 'congruent': 9, 'same': False}}
{'OP': 'LOAD', 'src': {'type': 'addresses_WT_ht', 'size': 16, 'AVXalign': False, 'NT': True, 'congruent': 2, 'same': False}}
{'OP': 'STOR', 'dst': {'type': 'addresses_D_ht', 'size': 8, 'AVXalign': False, 'NT': False, 'congruent': 0, 'same': False}}
{'OP': 'STOR', 'dst': {'type': 'addresses_normal_ht', 'size': 4, 'AVXalign': False, 'NT': False, 'congruent': 4, 'same': False}}
{'OP': 'REPM', 'src': {'type': 'addresses_A_ht', 'congruent': 4, 'same': False}, 'dst': {'type': 'addresses_UC_ht', 'congruent': 10, 'same': False}}
{'OP': 'LOAD', 'src': {'type': 'addresses_normal_ht', 'size': 8, 'AVXalign': False, 'NT': False, 'congruent': 3, 'same': False}}
{'OP': 'LOAD', 'src': {'type': 'addresses_WC_ht', 'size': 4, 'AVXalign': False, 'NT': False, 'congruent': 7, 'same': False}}
{'OP': 'REPM', 'src': {'type': 'addresses_WT_ht', 'congruent': 3, 'same': False}, 'dst': {'type': 'addresses_UC_ht', 'congruent': 3, 'same': False}}
{'OP': 'REPM', 'src': {'type': 'addresses_D_ht', 'congruent': 9, 'same': False}, 'dst': {'type': 'addresses_UC_ht', 'congruent': 9, 'same': False}}
{'OP': 'LOAD', 'src': {'type': 'addresses_WT_ht', 'size': 2, 'AVXalign': False, 'NT': False, 'congruent': 2, 'same': False}}
{'OP': 'LOAD', 'src': {'type': 'addresses_D_ht', 'size': 16, 'AVXalign': False, 'NT': True, 'congruent': 7, 'same': False}}
{'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
*/
| 32.664122 | 2,999 | 0.655527 |
a32621c1f8820039e81a83cf45971670f74159ab | 19,296 | asm | Assembly | Library/Spline/Spline/splineEndSelect.asm | steakknife/pcgeos | 95edd7fad36df400aba9bab1d56e154fc126044a | [
"Apache-2.0"
] | 504 | 2018-11-18T03:35:53.000Z | 2022-03-29T01:02:51.000Z | Library/Spline/Spline/splineEndSelect.asm | steakknife/pcgeos | 95edd7fad36df400aba9bab1d56e154fc126044a | [
"Apache-2.0"
] | 96 | 2018-11-19T21:06:50.000Z | 2022-03-06T10:26:48.000Z | Library/Spline/Spline/splineEndSelect.asm | steakknife/pcgeos | 95edd7fad36df400aba9bab1d56e154fc126044a | [
"Apache-2.0"
] | 73 | 2018-11-19T20:46:53.000Z | 2022-03-29T00:59:26.000Z | COMMENT @%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
Copyright (c) GeoWorks 1992 -- All Rights Reserved
PROJECT: PC GEOS
MODULE:
FILE: splineEndSelect.asm
AUTHOR: Chris Boyke
ROUTINES:
Name Description
---- -----------
REVISION HISTORY:
Name Date Description
---- ---- -----------
chrisb 10/ 5/92 Initial version.
DESCRIPTION:
Routines for dealing with MSG_META_END_SELECT
$Id: splineEndSelect.asm,v 1.1 97/04/07 11:09:33 newdeal Exp $
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%@
SplineSelectCode segment resource
COMMENT @%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
METHOD: SplineEndSelect, MSG_META_END_SELECT
DESCRIPTION:
PASS: *ds:si - VisSpline object
ds:bx - "" ""
ds:di - VisSPline instance data
cx - mouse x position
dx - mouse y position
bp - mouse flags
RETURN: ax = MRF_PROCESSED
DESTROYED: nothing
REGISTER/STACK USAGE: none
PSEUDO CODE/STRATEGY:
KNOWN BUGS/SIDE EFFECTS/CAVEATS/IDEAS: none
REVISION HISTORY:
Name Date Description
---- ---- -----------
CDB 3/91 Initial version
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%@
SplineEndSelect method dynamic VisSplineClass, MSG_META_END_SELECT
uses cx, dx, bp
.enter
call SplineMouseMethodCommon
CallTable bx, SplineEndSelectCalls, SplineMode
call SplineRecalcVisBounds
call CheckChangeInSelectionState
call SplineEndmCommon
mov ax, mask MRF_PROCESSED
.leave
ret
SplineEndSelect endm
COMMENT @%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
CheckChangeInSelectionState
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
SYNOPSIS: See if the "select state changed" bit is set, and if
send out notifications for the UI
CALLED BY: SplineEndSelect
PASS: es:bp - vis spline
ds - data block segment
RETURN: nothing
DESTROYED: nothing
PSEUDO CODE/STRATEGY:
KNOWN BUGS/SIDE EFFECTS/IDEAS:
REVISION HISTORY:
Name Date Description
---- ---- -----------
cdb 6/11/92 Initial version.
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%@
CheckChangeInSelectionState proc near
uses si
class VisSplineClass
.enter
EC < call ECSplineInstanceAndLMemBlock >
test es:[bp].VSI_editState, mask SES_SELECT_STATE_CHANGED
jz done
andnf es:[bp].VSI_editState, not mask SES_SELECT_STATE_CHANGED
mov cx, UPDATE_ALL
call SplineUpdateUI
done:
.leave
ret
CheckChangeInSelectionState endp
COMMENT @%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
SplineESEditModes
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
SYNOPSIS: Handle END SELECT in edit modes
CALLED BY: SplineEndSelect
PASS: es:bp - VisSpline
*ds:si -points
RETURN: nothing
DESTROYED: ax,bx,cx,dx
PSEUDO CODE/STRATEGY:
KNOWN BUGS/SIDE EFFECTS/IDEAS:
REVISION HISTORY:
Name Date Description
---- ---- -----------
CDB 4/15/92 Initial version.
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%@
SplineESEditModes proc near
class VisSplineClass
uses di, si
.enter
call SplineEndMoveCommon
SplineDerefScratchChunk di
mov si, ds:[di].SD_splineChunkHandle
push ds:[LMBH_handle]
segxchg ds, es
call VisReleaseMouse
segmov es, ds
call MemDerefStackDS
.leave
ret
SplineESEditModes endp
COMMENT @%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
SplineESAdvancedCreateMode
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
SYNOPSIS: Process END-SELECT in the create modes
CALLED BY: SplineEndSelect
PASS: es:bp - VisSplineInstance data
cx, dx - mouse position
RETURN: nothing
DESTROYED: ax,bx,cx,dx,di
PSEUDO CODE/STRATEGY:
KNOWN BUGS/SIDE EFFECTS/IDEAS:
REVISION HISTORY:
Name Date Description
---- ---- -----------
CDB 10/ 7/91 Initial version.
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%@
SplineESAdvancedCreateMode proc near
class VisSplineClass
.enter
;
; If we're in AT_CREATE_MODE_MOUSE_UP, then this is a spurious
; end-select, so ignore it.
;
GetActionType al
cmp al, AT_CREATE_MODE_MOUSE_UP
je done
;
; store mouse position
;
SplineDerefScratchChunk di
movP ds:[di].SD_mouse, cxdx
;
; if move-control, then erase control lines, reset temp flags, etc.
;
cmp al, AT_MOVE_CONTROL
jne afterCall
call SplineESAdvancedCreateMoveControls
afterCall:
call SplineCompleteAnchorPlacement
done:
.leave
ret
SplineESAdvancedCreateMode endp
COMMENT @%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
SplineCompleteAnchorPlacement
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
SYNOPSIS: Finish visual update after anchor placement. For
SPLINE CREATE mode, this occurs on END SELECT. For
POLYLINE MODE, this occurs on START SELECT.
CALLED BY: SplineESAdvancedCreateMode,
SplineSSPolylineCreateMode
PASS: es:bp - vis spline instance
*ds:si - points
RETURN: nothing
DESTROYED: ax,bx,cx,dx
PSEUDO CODE/STRATEGY:
KNOWN BUGS/SIDE EFFECTS/IDEAS:
REVISION HISTORY:
Name Date Description
---- ---- -----------
cdb 6/12/92 Initial version.
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%@
SplineCompleteAnchorPlacement proc near
class VisSplineClass
.enter
mov ax, es:[bp].VSI_actionPoint
;
; Draw "normal mode" curve for the previous anchor
;
call SplineSetNormalAttributes
movHL bx, <mask SDF_CURVE>, <SOT_DRAW>
mov dx, SWP_BOTH_CURVES
call SplineOperateOnCurrentPointFar
call SplineCompleteAnchorPlacementCommon
.leave
ret
SplineCompleteAnchorPlacement endp
COMMENT @%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
SplineCompleteAnchorPlacementCommon
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
SYNOPSIS: Common routine for completing anchor placement
CALLED BY: SplineCompleteAnchorPlacement,
SplineCompleteAnchorPlacementBeginnerSplineEdit
PASS: es:bp - vis spline instance
*ds:si - points
RETURN: nothing
DESTROYED: nothing
PSEUDO CODE/STRATEGY:
KNOWN BUGS/SIDE EFFECTS/IDEAS:
REVISION HISTORY:
Name Date Description
---- ---- -----------
chrisb 10/ 8/92 Initial version.
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%@
SplineCompleteAnchorPlacementCommon proc near
class VisSplineClass
.enter
; draw mouse-up sprite if we're still in create mode (we might
; have gone into inactive mode)
call SplineAreWeInCreateMode?
jnc done
SetActionType AT_CREATE_MODE_MOUSE_UP
call SplineDrawFromLastAnchorToMouse
done:
.leave
ret
SplineCompleteAnchorPlacementCommon endp
COMMENT @%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
SplineCompleteAnchorPlacementBeginnerSplineCreate
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
SYNOPSIS: Finish anchor placement visual display in
SM_BEGINNER_SPLINE_CREATE mode
CALLED BY: SplineSSBeginnerSplineEdit
PASS: es:bp - vis spline instance
*ds:si - points
ax - action point
RETURN: nothing
DESTROYED: ax,bx,cx,dx,di
PSEUDO CODE/STRATEGY:
In this procedure, we've just placed an anchor point, so erase
the IM_CURVE for the 2nd prev anchor, and draw the
IM_CURVE for the previous anchor
KNOWN BUGS/SIDE EFFECTS/IDEAS:
REVISION HISTORY:
Name Date Description
---- ---- -----------
chrisb 10/ 8/92 Initial version.
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%@
SplineCompleteAnchorPlacementBeginnerSplineCreate proc near
class VisSplineClass
.enter
call SplineSetInvertModeFar
;
; Erase IM curve for 2nd prev anchor
;
movHL bx, <mask SDF_IM_CURVE>, <SOT_ERASE>
mov dx, mask SWPF_2ND_PREV_ANCHOR
call SplineOperateOnCurrentPointFar
;
; Draw IM curve for prev anchor
;
movHL bx, <mask SDF_IM_CURVE>, <SOT_DRAW>
mov dx, mask SWPF_PREV_ANCHOR
call SplineOperateOnCurrentPointFar
;
; Draw 2nd PREV curve.
;
call SplineSetNormalAttributes
mov dx, mask SWPF_2ND_PREV_ANCHOR
movHL bx, <mask SDF_CURVE>, <SOT_DRAW>
call SplineOperateOnCurrentPointFar
call SplineCompleteAnchorPlacementCommon
.leave
ret
SplineCompleteAnchorPlacementBeginnerSplineCreate endp
COMMENT @%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
SplineESAdvancedCreateMoveControls
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
SYNOPSIS: End a "MOVE-CONTROLS" operation during advanced
create mode.
CALLED BY: SplineESAdvancedCreateMode
PASS: *ds:si - points array
es:bp - VisSplineInstance data
RETURN: nothing
DESTROYED: bx
PSEUDO CODE/STRATEGY:
KNOWN BUGS/SIDE EFFECTS/IDEAS:
REVISION HISTORY:
Name Date Description
---- ---- -----------
CDB 6/21/91 Initial version.
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%@
SplineESAdvancedCreateMoveControls proc near
uses cx, dx
class VisSplineClass
.enter
EC < call ECSplineInstanceAndPoints >
;
; The action point is currently a control point -- move the
; action point to this control's ANCHOR instead.
;
mov ax, es:[bp].VSI_actionPoint
call SplineGotoAnchor
mov es:[bp].VSI_actionPoint, ax
;
; Erase IM curves:
;
movHL bx, <mask SDF_IM_CURVE>, <SOT_ERASE>
mov dx, SWP_BOTH_CURVES
call SplineOperateOnCurrentPointFar
;
; Erase control lines
;
mov bh, mask SDF_CONTROL_LINES
mov dx, SWP_ALL_CONTROLS
call SplineOperateOnCurrentPointFar
; See if control points are close enough to their anchor to be deleted.
mov bl, SOT_REMOVE_EXTRA_CONTROLS
mov dx, mask SWPF_NEXT_CONTROL or \
mask SWPF_PREV_CONTROL
mov cx, SPLINE_POINT_MOUSE_TOLERANCE
call SplineOperateOnCurrentPointFar
.leave
ret
SplineESAdvancedCreateMoveControls endp
COMMENT @%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
SplineEndMoveCommon
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
SYNOPSIS: End a move operation. Set the Action Type to a
"Select" back from a "move"
CALLED BY: SplineESEditModes
PASS: es:bp - vis spline instance
*ds:si - points
RETURN: nothing
DESTROYED: bx
PSEUDO CODE/STRATEGY:
KNOWN BUGS/SIDE EFFECTS/IDEAS:
REVISION HISTORY:
Name Date Description
---- ---- -----------
CDB 10/ 7/91 Initial version.
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%@
SplineEndMoveCommon proc near
class VisSplineClass
uses ax
.enter
GetActionType bx
EC < cmp bl, AT_MOVE_RECTANGLE >
EC < ERROR_G ILLEGAL_ACTION_TYPE >
push bx
sub bl, AT_MOVE_ANCHOR
js popAndDone
CallTable bx, SplineEndMoveCalls
pop bx
sub bl, (AT_MOVE_ANCHOR - AT_SELECT_ANCHOR)
SetActionType bl
call SplineRecalcVisBounds
done:
.leave
ret
popAndDone:
pop bx
jmp done
SplineEndMoveCommon endp
COMMENT @%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
SplineEndMoveSegment
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
SYNOPSIS: End a "move-segment" operation.
CALLED BY: SplineEndMoveCommon
PASS: es:bp - VisSplineInstance data
*ds:si - points array
RETURN: nothing
DESTROYED: bx
PSEUDO CODE/STRATEGY:
KNOWN BUGS/SIDE EFFECTS/IDEAS:
REVISION HISTORY:
Name Date Description
---- ---- -----------
CDB 6/21/91 Initial version.
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%@
SplineEndMoveSegment proc near
mov bx, mask SWPF_ANCHOR_POINT or \
mask SWPF_NEXT_CONTROL or \
mask SWPF_NEXT_FAR_CONTROL or \
mask SWPF_NEXT_ANCHOR
GOTO SplineEndMoveSegmentOrAnchor
SplineEndMoveSegment endp
COMMENT @%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
SplineEndMoveAnchor
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
SYNOPSIS: Handle end move anchor in edit modes.
CALLED BY: SplineEndMoveAnchor
PASS: es:bp - vis spline instance
*ds:si - points
RETURN: nothing
DESTROYED: nothing
PSEUDO CODE/STRATEGY:
KNOWN BUGS/SIDE EFFECTS/IDEAS:
REVISION HISTORY:
Name Date Description
---- ---- -----------
chrisb 10/ 7/92 Initial version.
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%@
SplineEndMoveAnchor proc near
class VisSplineClass
mov bx, SWP_ANCHOR_ALL_CONTROLS_AND_CURVES or \
mask SWPF_NEXT_ANCHOR
GetEtypeFromRecord al, SS_MODE, es:[bp].VSI_state
cmp al, SM_BEGINNER_EDIT
jne gotFlags
ornf bx, mask SWPF_2ND_PREV_ANCHOR OR \
mask SWPF_2ND_PREV_FAR_CONTROL or \
mask SWPF_2ND_PREV_CONTROL or \
mask SWPF_2ND_NEXT_ANCHOR or \
mask SWPF_2ND_NEXT_CONTROL or \
mask SWPF_2ND_NEXT_FAR_CONTROL
gotFlags:
FALL_THRU SplineEndMoveSegmentOrAnchor
SplineEndMoveAnchor endp
COMMENT @%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
SplineEndMoveSegmentOrAnchor
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
SYNOPSIS: End the move of either segments or anchors
CALLED BY: SplineEndMoveAnchor, SplineEndMoveSegment
PASS: bl - SplineWhichPointFlags -- these are the points
that need to be added to the region to be invalidated
RETURN: nothing
DESTROYED: ax
PSEUDO CODE/STRATEGY:
Inval the undo and new curves, set drawn flags so MSG_VIS_DRAW
will draw everything correctly.
KNOWN BUGS/SIDE EFFECTS/IDEAS:
REVISION HISTORY:
Name Date Description
---- ---- -----------
CDB 10/24/91 Initial version.
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%@
SplineEndMoveSegmentOrAnchor proc near
class VisSplineClass
.enter
; Get a bounding box that includes both the UNDO curves and
; the NEW curves
call SplineGetBoundingBoxIncrementFar ; cx <- increment
SplineDerefScratchChunk di
andnf ds:[di].SD_flags, not mask SDF_BOUNDING_BOX_INITIALIZED
; Add the "UNDO" curves to bounding box
movHL ax, <mask SDF_USE_UNDO_INSTEAD_OF_TEMP>, \
<SOT_ADD_TO_BOUNDING_BOX>
call SplineOperateOnSelectedPointsFar
; add the new curves to the bounding box
clr ah
call SplineOperateOnSelectedPointsFar
; Inval the bounding box
push bx ; SplineWhichPointFlags
SplineDerefScratchChunk di
mov ax, ds:[di].SD_boundingBox.R_left
mov bx, ds:[di].SD_boundingBox.R_top
mov cx, ds:[di].SD_boundingBox.R_right
mov dx, ds:[di].SD_boundingBox.R_bottom
mov di, es:[bp].VSI_gstate
call GrInvalRect
pop bx ; SplineWhichPointFlags
; Reset TEMP flags for all points involved. Do this AFTER we
; got the bounding box, as the temp flags were used to
; determine which UNDO points to use.
mov al, SOT_MODIFY_INFO_FLAGS
movL cx, <mask PIF_TEMP>
call SplineOperateOnSelectedPointsFar
; Reset IM_CURVE flags for anchors
mov cl, mask APIF_IM_CURVE
call SplineOperateOnSelectedPointsFar
;
; Draw selected points -- this won't do much because the area
; just got invalidated, but it will draw next time we get a
; redraw event
;
call SplineDrawSelectedPoints
.leave
ret
SplineEndMoveSegmentOrAnchor endp
COMMENT @%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
SplineEndMoveControl
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
SYNOPSIS: End a "control move" operation
CALLED BY: SplineEndSelect, SplineEndMove
PASS: es:bp - VisSplineInstance data
*ds:si - points array
RETURN: nothing
DESTROYED: ax, bx, cx, dx
PSEUDO CODE/STRATEGY:
KNOWN BUGS/SIDE EFFECTS/IDEAS:
REVISION HISTORY:
Name Date Description
---- ---- -----------
CDB 6/21/91 Initial version.
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%@
SplineEndMoveControl proc near
class VisSplineClass
GetEtypeFromRecord bx, SS_MODE, es:[bp].VSI_state
CallTable bx, SplineEndMoveControlTable
.leave
ret
SplineEndMoveControl endp
COMMENT @%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
SplineEndMoveControlCreate
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
SYNOPSIS: Handle end-move control in (advanced) create mode
CALLED BY: SplineEndMoveControl
PASS: es:bp - vis spline instance
*ds:si - points
RETURN: nothing
DESTROYED: nothing
PSEUDO CODE/STRATEGY:
KNOWN BUGS/SIDE EFFECTS/IDEAS:
REVISION HISTORY:
Name Date Description
---- ---- -----------
chrisb 10/ 7/92 Initial version.
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%@
SplineEndMoveControlCreate proc near
class VisSplineClass
.enter
mov ax, es:[bp].VSI_actionPoint
; See if control points are close enough to their anchor to be deleted.
mov bl, SOT_REMOVE_EXTRA_CONTROLS
mov dx, mask SWPF_NEXT_CONTROL or \
mask SWPF_PREV_CONTROL
mov cx, SPLINE_POINT_MOUSE_TOLERANCE
call SplineOperateOnCurrentPointFar
.leave
ret
SplineEndMoveControlCreate endp
COMMENT @%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
SplineEndMoveControlEdit
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
SYNOPSIS: Handle an end-move control in advanced edit mode.
This requires invalidation
CALLED BY: SplineEndMoveControl
PASS: es:bp - vis spline instance
*ds:si - points
ax - current anchor point
RETURN: nothing
DESTROYED: ax,bx,cx,dx
PSEUDO CODE/STRATEGY:
KNOWN BUGS/SIDE EFFECTS/IDEAS:
REVISION HISTORY:
Name Date Description
---- ---- -----------
chrisb 10/ 7/92 Initial version.
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%@
SplineEndMoveControlEdit proc near
class VisSplineClass
.enter
mov ax, es:[bp].VSI_actionPoint
; Inval the "undo" curves
movHL bx, <mask SDF_USE_UNDO_INSTEAD_OF_TEMP>, SOT_INVALIDATE
mov dx, SWP_BOTH_CURVES
call SplineOperateOnCurrentPointFar
; inval the new curves
movL bx, SOT_INVALIDATE
mov dx, SWP_BOTH_CURVES
call SplineOperateOnCurrentPointFar
; set filled handle flags, reset temp flags for anchor and controls,
mov bl, SOT_MODIFY_INFO_FLAGS
mov dx, SWP_ANCHOR_AND_CONTROLS
movHL cx, <mask PIF_FILLED_HANDLE>, <mask PIF_TEMP>
call SplineOperateOnCurrentPointFar
; Reset IM_CURVE flags for anchor and prev anchor
movL cx, <mask APIF_IM_CURVE>
mov dx, SWP_BOTH_CURVES
call SplineOperateOnCurrentPointFar
; See if control points are close enough to their anchor to be deleted.
mov bl, SOT_REMOVE_EXTRA_CONTROLS
mov dx, mask SWPF_NEXT_CONTROL or \
mask SWPF_PREV_CONTROL
mov cx, SPLINE_POINT_MOUSE_TOLERANCE
call SplineOperateOnCurrentPointFar
.leave
ret
SplineEndMoveControlEdit endp
SplineSelectCode ends
| 21.778781 | 76 | 0.596445 |
124a766b9faf9d0c9e1575cd00238668ebce4486 | 490 | asm | Assembly | base/atari/vbxeput.asm | zbyti/Mad-Pascal | 546cae9724828f93047080109488be7d0d07d47e | [
"MIT"
] | 7 | 2020-05-02T15:37:57.000Z | 2021-02-17T01:59:41.000Z | base/atari/vbxeput.asm | michalkolodziejski/Mad-Pascal | 0a7a1e2f379e50b0a23878b0d881ff3407269ed6 | [
"MIT"
] | 14 | 2020-05-03T02:02:35.000Z | 2020-08-10T08:41:19.000Z | base/atari/vbxeput.asm | michalkolodziejski/Mad-Pascal | 0a7a1e2f379e50b0a23878b0d881ff3407269ed6 | [
"MIT"
] | 5 | 2020-06-02T18:34:14.000Z | 2020-07-09T18:13:44.000Z |
; VBXE put char
; input:
; A - char
.proc @vbxe_put (.byte a) .reg
pha
cmp #eol
beq stop
cmp #$7d ; clrscr
bne skp
jsr @vbxe_init.cmapini
jmp stop
skp lda rowcrs
pha
:4 lsr @
add #$80+MAIN.SYSTEM.VBXE_MAPADR/$1000
fxsa FX_MEMS
pla
and #$0f
add >MAIN.SYSTEM.VBXE_WINDOW
sta bp+1
lda colcrs
asl @
asl @
tay
mva colpf0s (bp),y
iny
mva colpf1s (bp),y
iny
mva colpf2s (bp),y
fxs FX_MEMS #$00
stop pla
rts
.endp
| 10.652174 | 40 | 0.585714 |
80e4925f1e1a3a6245daedb407f7c882985d8d7d | 52,422 | asm | Assembly | wc.asm | PieMyth/cs333 | 85b46a2f677ed49065504aa051f918b3f803e294 | [
"MIT-0"
] | null | null | null | wc.asm | PieMyth/cs333 | 85b46a2f677ed49065504aa051f918b3f803e294 | [
"MIT-0"
] | null | null | null | wc.asm | PieMyth/cs333 | 85b46a2f677ed49065504aa051f918b3f803e294 | [
"MIT-0"
] | null | null | null |
_wc: file format elf32-i386
Disassembly of section .text:
00000000 <wc>:
char buf[512];
void
wc(int fd, char *name)
{
0: 55 push %ebp
1: 89 e5 mov %esp,%ebp
3: 83 ec 28 sub $0x28,%esp
int i, n;
int l, w, c, inword;
l = w = c = 0;
6: c7 45 e8 00 00 00 00 movl $0x0,-0x18(%ebp)
d: 8b 45 e8 mov -0x18(%ebp),%eax
10: 89 45 ec mov %eax,-0x14(%ebp)
13: 8b 45 ec mov -0x14(%ebp),%eax
16: 89 45 f0 mov %eax,-0x10(%ebp)
inword = 0;
19: c7 45 e4 00 00 00 00 movl $0x0,-0x1c(%ebp)
while((n = read(fd, buf, sizeof(buf))) > 0){
20: eb 69 jmp 8b <wc+0x8b>
for(i=0; i<n; i++){
22: c7 45 f4 00 00 00 00 movl $0x0,-0xc(%ebp)
29: eb 58 jmp 83 <wc+0x83>
c++;
2b: 83 45 e8 01 addl $0x1,-0x18(%ebp)
if(buf[i] == '\n')
2f: 8b 45 f4 mov -0xc(%ebp),%eax
32: 05 80 0d 00 00 add $0xd80,%eax
37: 0f b6 00 movzbl (%eax),%eax
3a: 3c 0a cmp $0xa,%al
3c: 75 04 jne 42 <wc+0x42>
l++;
3e: 83 45 f0 01 addl $0x1,-0x10(%ebp)
if(strchr(" \r\t\n\v", buf[i]))
42: 8b 45 f4 mov -0xc(%ebp),%eax
45: 05 80 0d 00 00 add $0xd80,%eax
4a: 0f b6 00 movzbl (%eax),%eax
4d: 0f be c0 movsbl %al,%eax
50: 83 ec 08 sub $0x8,%esp
53: 50 push %eax
54: 68 74 0a 00 00 push $0xa74
59: e8 35 02 00 00 call 293 <strchr>
5e: 83 c4 10 add $0x10,%esp
61: 85 c0 test %eax,%eax
63: 74 09 je 6e <wc+0x6e>
inword = 0;
65: c7 45 e4 00 00 00 00 movl $0x0,-0x1c(%ebp)
6c: eb 11 jmp 7f <wc+0x7f>
else if(!inword){
6e: 83 7d e4 00 cmpl $0x0,-0x1c(%ebp)
72: 75 0b jne 7f <wc+0x7f>
w++;
74: 83 45 ec 01 addl $0x1,-0x14(%ebp)
inword = 1;
78: c7 45 e4 01 00 00 00 movl $0x1,-0x1c(%ebp)
int l, w, c, inword;
l = w = c = 0;
inword = 0;
while((n = read(fd, buf, sizeof(buf))) > 0){
for(i=0; i<n; i++){
7f: 83 45 f4 01 addl $0x1,-0xc(%ebp)
83: 8b 45 f4 mov -0xc(%ebp),%eax
86: 3b 45 e0 cmp -0x20(%ebp),%eax
89: 7c a0 jl 2b <wc+0x2b>
int i, n;
int l, w, c, inword;
l = w = c = 0;
inword = 0;
while((n = read(fd, buf, sizeof(buf))) > 0){
8b: 83 ec 04 sub $0x4,%esp
8e: 68 00 02 00 00 push $0x200
93: 68 80 0d 00 00 push $0xd80
98: ff 75 08 pushl 0x8(%ebp)
9b: e8 5f 04 00 00 call 4ff <read>
a0: 83 c4 10 add $0x10,%esp
a3: 89 45 e0 mov %eax,-0x20(%ebp)
a6: 83 7d e0 00 cmpl $0x0,-0x20(%ebp)
aa: 0f 8f 72 ff ff ff jg 22 <wc+0x22>
w++;
inword = 1;
}
}
}
if(n < 0){
b0: 83 7d e0 00 cmpl $0x0,-0x20(%ebp)
b4: 79 17 jns cd <wc+0xcd>
printf(1, "wc: read error\n");
b6: 83 ec 08 sub $0x8,%esp
b9: 68 7a 0a 00 00 push $0xa7a
be: 6a 01 push $0x1
c0: e8 f9 05 00 00 call 6be <printf>
c5: 83 c4 10 add $0x10,%esp
exit();
c8: e8 1a 04 00 00 call 4e7 <exit>
}
printf(1, "%d %d %d %s\n", l, w, c, name);
cd: 83 ec 08 sub $0x8,%esp
d0: ff 75 0c pushl 0xc(%ebp)
d3: ff 75 e8 pushl -0x18(%ebp)
d6: ff 75 ec pushl -0x14(%ebp)
d9: ff 75 f0 pushl -0x10(%ebp)
dc: 68 8a 0a 00 00 push $0xa8a
e1: 6a 01 push $0x1
e3: e8 d6 05 00 00 call 6be <printf>
e8: 83 c4 20 add $0x20,%esp
}
eb: 90 nop
ec: c9 leave
ed: c3 ret
000000ee <main>:
int
main(int argc, char *argv[])
{
ee: 8d 4c 24 04 lea 0x4(%esp),%ecx
f2: 83 e4 f0 and $0xfffffff0,%esp
f5: ff 71 fc pushl -0x4(%ecx)
f8: 55 push %ebp
f9: 89 e5 mov %esp,%ebp
fb: 53 push %ebx
fc: 51 push %ecx
fd: 83 ec 10 sub $0x10,%esp
100: 89 cb mov %ecx,%ebx
int fd, i;
if(argc <= 1){
102: 83 3b 01 cmpl $0x1,(%ebx)
105: 7f 17 jg 11e <main+0x30>
wc(0, "");
107: 83 ec 08 sub $0x8,%esp
10a: 68 97 0a 00 00 push $0xa97
10f: 6a 00 push $0x0
111: e8 ea fe ff ff call 0 <wc>
116: 83 c4 10 add $0x10,%esp
exit();
119: e8 c9 03 00 00 call 4e7 <exit>
}
for(i = 1; i < argc; i++){
11e: c7 45 f4 01 00 00 00 movl $0x1,-0xc(%ebp)
125: e9 83 00 00 00 jmp 1ad <main+0xbf>
if((fd = open(argv[i], 0)) < 0){
12a: 8b 45 f4 mov -0xc(%ebp),%eax
12d: 8d 14 85 00 00 00 00 lea 0x0(,%eax,4),%edx
134: 8b 43 04 mov 0x4(%ebx),%eax
137: 01 d0 add %edx,%eax
139: 8b 00 mov (%eax),%eax
13b: 83 ec 08 sub $0x8,%esp
13e: 6a 00 push $0x0
140: 50 push %eax
141: e8 e1 03 00 00 call 527 <open>
146: 83 c4 10 add $0x10,%esp
149: 89 45 f0 mov %eax,-0x10(%ebp)
14c: 83 7d f0 00 cmpl $0x0,-0x10(%ebp)
150: 79 29 jns 17b <main+0x8d>
printf(1, "wc: cannot open %s\n", argv[i]);
152: 8b 45 f4 mov -0xc(%ebp),%eax
155: 8d 14 85 00 00 00 00 lea 0x0(,%eax,4),%edx
15c: 8b 43 04 mov 0x4(%ebx),%eax
15f: 01 d0 add %edx,%eax
161: 8b 00 mov (%eax),%eax
163: 83 ec 04 sub $0x4,%esp
166: 50 push %eax
167: 68 98 0a 00 00 push $0xa98
16c: 6a 01 push $0x1
16e: e8 4b 05 00 00 call 6be <printf>
173: 83 c4 10 add $0x10,%esp
exit();
176: e8 6c 03 00 00 call 4e7 <exit>
}
wc(fd, argv[i]);
17b: 8b 45 f4 mov -0xc(%ebp),%eax
17e: 8d 14 85 00 00 00 00 lea 0x0(,%eax,4),%edx
185: 8b 43 04 mov 0x4(%ebx),%eax
188: 01 d0 add %edx,%eax
18a: 8b 00 mov (%eax),%eax
18c: 83 ec 08 sub $0x8,%esp
18f: 50 push %eax
190: ff 75 f0 pushl -0x10(%ebp)
193: e8 68 fe ff ff call 0 <wc>
198: 83 c4 10 add $0x10,%esp
close(fd);
19b: 83 ec 0c sub $0xc,%esp
19e: ff 75 f0 pushl -0x10(%ebp)
1a1: e8 69 03 00 00 call 50f <close>
1a6: 83 c4 10 add $0x10,%esp
if(argc <= 1){
wc(0, "");
exit();
}
for(i = 1; i < argc; i++){
1a9: 83 45 f4 01 addl $0x1,-0xc(%ebp)
1ad: 8b 45 f4 mov -0xc(%ebp),%eax
1b0: 3b 03 cmp (%ebx),%eax
1b2: 0f 8c 72 ff ff ff jl 12a <main+0x3c>
exit();
}
wc(fd, argv[i]);
close(fd);
}
exit();
1b8: e8 2a 03 00 00 call 4e7 <exit>
000001bd <stosb>:
"cc");
}
static inline void
stosb(void *addr, int data, int cnt)
{
1bd: 55 push %ebp
1be: 89 e5 mov %esp,%ebp
1c0: 57 push %edi
1c1: 53 push %ebx
asm volatile("cld; rep stosb" :
1c2: 8b 4d 08 mov 0x8(%ebp),%ecx
1c5: 8b 55 10 mov 0x10(%ebp),%edx
1c8: 8b 45 0c mov 0xc(%ebp),%eax
1cb: 89 cb mov %ecx,%ebx
1cd: 89 df mov %ebx,%edi
1cf: 89 d1 mov %edx,%ecx
1d1: fc cld
1d2: f3 aa rep stos %al,%es:(%edi)
1d4: 89 ca mov %ecx,%edx
1d6: 89 fb mov %edi,%ebx
1d8: 89 5d 08 mov %ebx,0x8(%ebp)
1db: 89 55 10 mov %edx,0x10(%ebp)
"=D" (addr), "=c" (cnt) :
"0" (addr), "1" (cnt), "a" (data) :
"memory", "cc");
}
1de: 90 nop
1df: 5b pop %ebx
1e0: 5f pop %edi
1e1: 5d pop %ebp
1e2: c3 ret
000001e3 <strcpy>:
#include "user.h"
#include "x86.h"
char*
strcpy(char *s, char *t)
{
1e3: 55 push %ebp
1e4: 89 e5 mov %esp,%ebp
1e6: 83 ec 10 sub $0x10,%esp
char *os;
os = s;
1e9: 8b 45 08 mov 0x8(%ebp),%eax
1ec: 89 45 fc mov %eax,-0x4(%ebp)
while((*s++ = *t++) != 0)
1ef: 90 nop
1f0: 8b 45 08 mov 0x8(%ebp),%eax
1f3: 8d 50 01 lea 0x1(%eax),%edx
1f6: 89 55 08 mov %edx,0x8(%ebp)
1f9: 8b 55 0c mov 0xc(%ebp),%edx
1fc: 8d 4a 01 lea 0x1(%edx),%ecx
1ff: 89 4d 0c mov %ecx,0xc(%ebp)
202: 0f b6 12 movzbl (%edx),%edx
205: 88 10 mov %dl,(%eax)
207: 0f b6 00 movzbl (%eax),%eax
20a: 84 c0 test %al,%al
20c: 75 e2 jne 1f0 <strcpy+0xd>
;
return os;
20e: 8b 45 fc mov -0x4(%ebp),%eax
}
211: c9 leave
212: c3 ret
00000213 <strcmp>:
int
strcmp(const char *p, const char *q)
{
213: 55 push %ebp
214: 89 e5 mov %esp,%ebp
while(*p && *p == *q)
216: eb 08 jmp 220 <strcmp+0xd>
p++, q++;
218: 83 45 08 01 addl $0x1,0x8(%ebp)
21c: 83 45 0c 01 addl $0x1,0xc(%ebp)
}
int
strcmp(const char *p, const char *q)
{
while(*p && *p == *q)
220: 8b 45 08 mov 0x8(%ebp),%eax
223: 0f b6 00 movzbl (%eax),%eax
226: 84 c0 test %al,%al
228: 74 10 je 23a <strcmp+0x27>
22a: 8b 45 08 mov 0x8(%ebp),%eax
22d: 0f b6 10 movzbl (%eax),%edx
230: 8b 45 0c mov 0xc(%ebp),%eax
233: 0f b6 00 movzbl (%eax),%eax
236: 38 c2 cmp %al,%dl
238: 74 de je 218 <strcmp+0x5>
p++, q++;
return (uchar)*p - (uchar)*q;
23a: 8b 45 08 mov 0x8(%ebp),%eax
23d: 0f b6 00 movzbl (%eax),%eax
240: 0f b6 d0 movzbl %al,%edx
243: 8b 45 0c mov 0xc(%ebp),%eax
246: 0f b6 00 movzbl (%eax),%eax
249: 0f b6 c0 movzbl %al,%eax
24c: 29 c2 sub %eax,%edx
24e: 89 d0 mov %edx,%eax
}
250: 5d pop %ebp
251: c3 ret
00000252 <strlen>:
uint
strlen(char *s)
{
252: 55 push %ebp
253: 89 e5 mov %esp,%ebp
255: 83 ec 10 sub $0x10,%esp
int n;
for(n = 0; s[n]; n++)
258: c7 45 fc 00 00 00 00 movl $0x0,-0x4(%ebp)
25f: eb 04 jmp 265 <strlen+0x13>
261: 83 45 fc 01 addl $0x1,-0x4(%ebp)
265: 8b 55 fc mov -0x4(%ebp),%edx
268: 8b 45 08 mov 0x8(%ebp),%eax
26b: 01 d0 add %edx,%eax
26d: 0f b6 00 movzbl (%eax),%eax
270: 84 c0 test %al,%al
272: 75 ed jne 261 <strlen+0xf>
;
return n;
274: 8b 45 fc mov -0x4(%ebp),%eax
}
277: c9 leave
278: c3 ret
00000279 <memset>:
void*
memset(void *dst, int c, uint n)
{
279: 55 push %ebp
27a: 89 e5 mov %esp,%ebp
stosb(dst, c, n);
27c: 8b 45 10 mov 0x10(%ebp),%eax
27f: 50 push %eax
280: ff 75 0c pushl 0xc(%ebp)
283: ff 75 08 pushl 0x8(%ebp)
286: e8 32 ff ff ff call 1bd <stosb>
28b: 83 c4 0c add $0xc,%esp
return dst;
28e: 8b 45 08 mov 0x8(%ebp),%eax
}
291: c9 leave
292: c3 ret
00000293 <strchr>:
char*
strchr(const char *s, char c)
{
293: 55 push %ebp
294: 89 e5 mov %esp,%ebp
296: 83 ec 04 sub $0x4,%esp
299: 8b 45 0c mov 0xc(%ebp),%eax
29c: 88 45 fc mov %al,-0x4(%ebp)
for(; *s; s++)
29f: eb 14 jmp 2b5 <strchr+0x22>
if(*s == c)
2a1: 8b 45 08 mov 0x8(%ebp),%eax
2a4: 0f b6 00 movzbl (%eax),%eax
2a7: 3a 45 fc cmp -0x4(%ebp),%al
2aa: 75 05 jne 2b1 <strchr+0x1e>
return (char*)s;
2ac: 8b 45 08 mov 0x8(%ebp),%eax
2af: eb 13 jmp 2c4 <strchr+0x31>
}
char*
strchr(const char *s, char c)
{
for(; *s; s++)
2b1: 83 45 08 01 addl $0x1,0x8(%ebp)
2b5: 8b 45 08 mov 0x8(%ebp),%eax
2b8: 0f b6 00 movzbl (%eax),%eax
2bb: 84 c0 test %al,%al
2bd: 75 e2 jne 2a1 <strchr+0xe>
if(*s == c)
return (char*)s;
return 0;
2bf: b8 00 00 00 00 mov $0x0,%eax
}
2c4: c9 leave
2c5: c3 ret
000002c6 <gets>:
char*
gets(char *buf, int max)
{
2c6: 55 push %ebp
2c7: 89 e5 mov %esp,%ebp
2c9: 83 ec 18 sub $0x18,%esp
int i, cc;
char c;
for(i=0; i+1 < max; ){
2cc: c7 45 f4 00 00 00 00 movl $0x0,-0xc(%ebp)
2d3: eb 42 jmp 317 <gets+0x51>
cc = read(0, &c, 1);
2d5: 83 ec 04 sub $0x4,%esp
2d8: 6a 01 push $0x1
2da: 8d 45 ef lea -0x11(%ebp),%eax
2dd: 50 push %eax
2de: 6a 00 push $0x0
2e0: e8 1a 02 00 00 call 4ff <read>
2e5: 83 c4 10 add $0x10,%esp
2e8: 89 45 f0 mov %eax,-0x10(%ebp)
if(cc < 1)
2eb: 83 7d f0 00 cmpl $0x0,-0x10(%ebp)
2ef: 7e 33 jle 324 <gets+0x5e>
break;
buf[i++] = c;
2f1: 8b 45 f4 mov -0xc(%ebp),%eax
2f4: 8d 50 01 lea 0x1(%eax),%edx
2f7: 89 55 f4 mov %edx,-0xc(%ebp)
2fa: 89 c2 mov %eax,%edx
2fc: 8b 45 08 mov 0x8(%ebp),%eax
2ff: 01 c2 add %eax,%edx
301: 0f b6 45 ef movzbl -0x11(%ebp),%eax
305: 88 02 mov %al,(%edx)
if(c == '\n' || c == '\r')
307: 0f b6 45 ef movzbl -0x11(%ebp),%eax
30b: 3c 0a cmp $0xa,%al
30d: 74 16 je 325 <gets+0x5f>
30f: 0f b6 45 ef movzbl -0x11(%ebp),%eax
313: 3c 0d cmp $0xd,%al
315: 74 0e je 325 <gets+0x5f>
gets(char *buf, int max)
{
int i, cc;
char c;
for(i=0; i+1 < max; ){
317: 8b 45 f4 mov -0xc(%ebp),%eax
31a: 83 c0 01 add $0x1,%eax
31d: 3b 45 0c cmp 0xc(%ebp),%eax
320: 7c b3 jl 2d5 <gets+0xf>
322: eb 01 jmp 325 <gets+0x5f>
cc = read(0, &c, 1);
if(cc < 1)
break;
324: 90 nop
buf[i++] = c;
if(c == '\n' || c == '\r')
break;
}
buf[i] = '\0';
325: 8b 55 f4 mov -0xc(%ebp),%edx
328: 8b 45 08 mov 0x8(%ebp),%eax
32b: 01 d0 add %edx,%eax
32d: c6 00 00 movb $0x0,(%eax)
return buf;
330: 8b 45 08 mov 0x8(%ebp),%eax
}
333: c9 leave
334: c3 ret
00000335 <stat>:
int
stat(char *n, struct stat *st)
{
335: 55 push %ebp
336: 89 e5 mov %esp,%ebp
338: 83 ec 18 sub $0x18,%esp
int fd;
int r;
fd = open(n, O_RDONLY);
33b: 83 ec 08 sub $0x8,%esp
33e: 6a 00 push $0x0
340: ff 75 08 pushl 0x8(%ebp)
343: e8 df 01 00 00 call 527 <open>
348: 83 c4 10 add $0x10,%esp
34b: 89 45 f4 mov %eax,-0xc(%ebp)
if(fd < 0)
34e: 83 7d f4 00 cmpl $0x0,-0xc(%ebp)
352: 79 07 jns 35b <stat+0x26>
return -1;
354: b8 ff ff ff ff mov $0xffffffff,%eax
359: eb 25 jmp 380 <stat+0x4b>
r = fstat(fd, st);
35b: 83 ec 08 sub $0x8,%esp
35e: ff 75 0c pushl 0xc(%ebp)
361: ff 75 f4 pushl -0xc(%ebp)
364: e8 d6 01 00 00 call 53f <fstat>
369: 83 c4 10 add $0x10,%esp
36c: 89 45 f0 mov %eax,-0x10(%ebp)
close(fd);
36f: 83 ec 0c sub $0xc,%esp
372: ff 75 f4 pushl -0xc(%ebp)
375: e8 95 01 00 00 call 50f <close>
37a: 83 c4 10 add $0x10,%esp
return r;
37d: 8b 45 f0 mov -0x10(%ebp),%eax
}
380: c9 leave
381: c3 ret
00000382 <atoi>:
int
atoi(const char *s)
{
382: 55 push %ebp
383: 89 e5 mov %esp,%ebp
385: 83 ec 10 sub $0x10,%esp
int n, sign;
n = 0;
388: c7 45 fc 00 00 00 00 movl $0x0,-0x4(%ebp)
while (*s == ' ') s++;
38f: eb 04 jmp 395 <atoi+0x13>
391: 83 45 08 01 addl $0x1,0x8(%ebp)
395: 8b 45 08 mov 0x8(%ebp),%eax
398: 0f b6 00 movzbl (%eax),%eax
39b: 3c 20 cmp $0x20,%al
39d: 74 f2 je 391 <atoi+0xf>
sign = (*s == '-') ? -1 : 1;
39f: 8b 45 08 mov 0x8(%ebp),%eax
3a2: 0f b6 00 movzbl (%eax),%eax
3a5: 3c 2d cmp $0x2d,%al
3a7: 75 07 jne 3b0 <atoi+0x2e>
3a9: b8 ff ff ff ff mov $0xffffffff,%eax
3ae: eb 05 jmp 3b5 <atoi+0x33>
3b0: b8 01 00 00 00 mov $0x1,%eax
3b5: 89 45 f8 mov %eax,-0x8(%ebp)
if (*s == '+' || *s == '-')
3b8: 8b 45 08 mov 0x8(%ebp),%eax
3bb: 0f b6 00 movzbl (%eax),%eax
3be: 3c 2b cmp $0x2b,%al
3c0: 74 0a je 3cc <atoi+0x4a>
3c2: 8b 45 08 mov 0x8(%ebp),%eax
3c5: 0f b6 00 movzbl (%eax),%eax
3c8: 3c 2d cmp $0x2d,%al
3ca: 75 2b jne 3f7 <atoi+0x75>
s++;
3cc: 83 45 08 01 addl $0x1,0x8(%ebp)
while('0' <= *s && *s <= '9')
3d0: eb 25 jmp 3f7 <atoi+0x75>
n = n*10 + *s++ - '0';
3d2: 8b 55 fc mov -0x4(%ebp),%edx
3d5: 89 d0 mov %edx,%eax
3d7: c1 e0 02 shl $0x2,%eax
3da: 01 d0 add %edx,%eax
3dc: 01 c0 add %eax,%eax
3de: 89 c1 mov %eax,%ecx
3e0: 8b 45 08 mov 0x8(%ebp),%eax
3e3: 8d 50 01 lea 0x1(%eax),%edx
3e6: 89 55 08 mov %edx,0x8(%ebp)
3e9: 0f b6 00 movzbl (%eax),%eax
3ec: 0f be c0 movsbl %al,%eax
3ef: 01 c8 add %ecx,%eax
3f1: 83 e8 30 sub $0x30,%eax
3f4: 89 45 fc mov %eax,-0x4(%ebp)
n = 0;
while (*s == ' ') s++;
sign = (*s == '-') ? -1 : 1;
if (*s == '+' || *s == '-')
s++;
while('0' <= *s && *s <= '9')
3f7: 8b 45 08 mov 0x8(%ebp),%eax
3fa: 0f b6 00 movzbl (%eax),%eax
3fd: 3c 2f cmp $0x2f,%al
3ff: 7e 0a jle 40b <atoi+0x89>
401: 8b 45 08 mov 0x8(%ebp),%eax
404: 0f b6 00 movzbl (%eax),%eax
407: 3c 39 cmp $0x39,%al
409: 7e c7 jle 3d2 <atoi+0x50>
n = n*10 + *s++ - '0';
return sign*n;
40b: 8b 45 f8 mov -0x8(%ebp),%eax
40e: 0f af 45 fc imul -0x4(%ebp),%eax
}
412: c9 leave
413: c3 ret
00000414 <atoo>:
int
atoo(const char *s)
{
414: 55 push %ebp
415: 89 e5 mov %esp,%ebp
417: 83 ec 10 sub $0x10,%esp
int n, sign;
n = 0;
41a: c7 45 fc 00 00 00 00 movl $0x0,-0x4(%ebp)
while (*s == ' ') s++;
421: eb 04 jmp 427 <atoo+0x13>
423: 83 45 08 01 addl $0x1,0x8(%ebp)
427: 8b 45 08 mov 0x8(%ebp),%eax
42a: 0f b6 00 movzbl (%eax),%eax
42d: 3c 20 cmp $0x20,%al
42f: 74 f2 je 423 <atoo+0xf>
sign = (*s == '-') ? -1 : 1;
431: 8b 45 08 mov 0x8(%ebp),%eax
434: 0f b6 00 movzbl (%eax),%eax
437: 3c 2d cmp $0x2d,%al
439: 75 07 jne 442 <atoo+0x2e>
43b: b8 ff ff ff ff mov $0xffffffff,%eax
440: eb 05 jmp 447 <atoo+0x33>
442: b8 01 00 00 00 mov $0x1,%eax
447: 89 45 f8 mov %eax,-0x8(%ebp)
if (*s == '+' || *s == '-')
44a: 8b 45 08 mov 0x8(%ebp),%eax
44d: 0f b6 00 movzbl (%eax),%eax
450: 3c 2b cmp $0x2b,%al
452: 74 0a je 45e <atoo+0x4a>
454: 8b 45 08 mov 0x8(%ebp),%eax
457: 0f b6 00 movzbl (%eax),%eax
45a: 3c 2d cmp $0x2d,%al
45c: 75 27 jne 485 <atoo+0x71>
s++;
45e: 83 45 08 01 addl $0x1,0x8(%ebp)
while('0' <= *s && *s <= '7')
462: eb 21 jmp 485 <atoo+0x71>
n = n*8 + *s++ - '0';
464: 8b 45 fc mov -0x4(%ebp),%eax
467: 8d 0c c5 00 00 00 00 lea 0x0(,%eax,8),%ecx
46e: 8b 45 08 mov 0x8(%ebp),%eax
471: 8d 50 01 lea 0x1(%eax),%edx
474: 89 55 08 mov %edx,0x8(%ebp)
477: 0f b6 00 movzbl (%eax),%eax
47a: 0f be c0 movsbl %al,%eax
47d: 01 c8 add %ecx,%eax
47f: 83 e8 30 sub $0x30,%eax
482: 89 45 fc mov %eax,-0x4(%ebp)
n = 0;
while (*s == ' ') s++;
sign = (*s == '-') ? -1 : 1;
if (*s == '+' || *s == '-')
s++;
while('0' <= *s && *s <= '7')
485: 8b 45 08 mov 0x8(%ebp),%eax
488: 0f b6 00 movzbl (%eax),%eax
48b: 3c 2f cmp $0x2f,%al
48d: 7e 0a jle 499 <atoo+0x85>
48f: 8b 45 08 mov 0x8(%ebp),%eax
492: 0f b6 00 movzbl (%eax),%eax
495: 3c 37 cmp $0x37,%al
497: 7e cb jle 464 <atoo+0x50>
n = n*8 + *s++ - '0';
return sign*n;
499: 8b 45 f8 mov -0x8(%ebp),%eax
49c: 0f af 45 fc imul -0x4(%ebp),%eax
}
4a0: c9 leave
4a1: c3 ret
000004a2 <memmove>:
void*
memmove(void *vdst, void *vsrc, int n)
{
4a2: 55 push %ebp
4a3: 89 e5 mov %esp,%ebp
4a5: 83 ec 10 sub $0x10,%esp
char *dst, *src;
dst = vdst;
4a8: 8b 45 08 mov 0x8(%ebp),%eax
4ab: 89 45 fc mov %eax,-0x4(%ebp)
src = vsrc;
4ae: 8b 45 0c mov 0xc(%ebp),%eax
4b1: 89 45 f8 mov %eax,-0x8(%ebp)
while(n-- > 0)
4b4: eb 17 jmp 4cd <memmove+0x2b>
*dst++ = *src++;
4b6: 8b 45 fc mov -0x4(%ebp),%eax
4b9: 8d 50 01 lea 0x1(%eax),%edx
4bc: 89 55 fc mov %edx,-0x4(%ebp)
4bf: 8b 55 f8 mov -0x8(%ebp),%edx
4c2: 8d 4a 01 lea 0x1(%edx),%ecx
4c5: 89 4d f8 mov %ecx,-0x8(%ebp)
4c8: 0f b6 12 movzbl (%edx),%edx
4cb: 88 10 mov %dl,(%eax)
{
char *dst, *src;
dst = vdst;
src = vsrc;
while(n-- > 0)
4cd: 8b 45 10 mov 0x10(%ebp),%eax
4d0: 8d 50 ff lea -0x1(%eax),%edx
4d3: 89 55 10 mov %edx,0x10(%ebp)
4d6: 85 c0 test %eax,%eax
4d8: 7f dc jg 4b6 <memmove+0x14>
*dst++ = *src++;
return vdst;
4da: 8b 45 08 mov 0x8(%ebp),%eax
}
4dd: c9 leave
4de: c3 ret
000004df <fork>:
name: \
movl $SYS_ ## name, %eax; \
int $T_SYSCALL; \
ret
SYSCALL(fork)
4df: b8 01 00 00 00 mov $0x1,%eax
4e4: cd 40 int $0x40
4e6: c3 ret
000004e7 <exit>:
SYSCALL(exit)
4e7: b8 02 00 00 00 mov $0x2,%eax
4ec: cd 40 int $0x40
4ee: c3 ret
000004ef <wait>:
SYSCALL(wait)
4ef: b8 03 00 00 00 mov $0x3,%eax
4f4: cd 40 int $0x40
4f6: c3 ret
000004f7 <pipe>:
SYSCALL(pipe)
4f7: b8 04 00 00 00 mov $0x4,%eax
4fc: cd 40 int $0x40
4fe: c3 ret
000004ff <read>:
SYSCALL(read)
4ff: b8 05 00 00 00 mov $0x5,%eax
504: cd 40 int $0x40
506: c3 ret
00000507 <write>:
SYSCALL(write)
507: b8 10 00 00 00 mov $0x10,%eax
50c: cd 40 int $0x40
50e: c3 ret
0000050f <close>:
SYSCALL(close)
50f: b8 15 00 00 00 mov $0x15,%eax
514: cd 40 int $0x40
516: c3 ret
00000517 <kill>:
SYSCALL(kill)
517: b8 06 00 00 00 mov $0x6,%eax
51c: cd 40 int $0x40
51e: c3 ret
0000051f <exec>:
SYSCALL(exec)
51f: b8 07 00 00 00 mov $0x7,%eax
524: cd 40 int $0x40
526: c3 ret
00000527 <open>:
SYSCALL(open)
527: b8 0f 00 00 00 mov $0xf,%eax
52c: cd 40 int $0x40
52e: c3 ret
0000052f <mknod>:
SYSCALL(mknod)
52f: b8 11 00 00 00 mov $0x11,%eax
534: cd 40 int $0x40
536: c3 ret
00000537 <unlink>:
SYSCALL(unlink)
537: b8 12 00 00 00 mov $0x12,%eax
53c: cd 40 int $0x40
53e: c3 ret
0000053f <fstat>:
SYSCALL(fstat)
53f: b8 08 00 00 00 mov $0x8,%eax
544: cd 40 int $0x40
546: c3 ret
00000547 <link>:
SYSCALL(link)
547: b8 13 00 00 00 mov $0x13,%eax
54c: cd 40 int $0x40
54e: c3 ret
0000054f <mkdir>:
SYSCALL(mkdir)
54f: b8 14 00 00 00 mov $0x14,%eax
554: cd 40 int $0x40
556: c3 ret
00000557 <chdir>:
SYSCALL(chdir)
557: b8 09 00 00 00 mov $0x9,%eax
55c: cd 40 int $0x40
55e: c3 ret
0000055f <dup>:
SYSCALL(dup)
55f: b8 0a 00 00 00 mov $0xa,%eax
564: cd 40 int $0x40
566: c3 ret
00000567 <getpid>:
SYSCALL(getpid)
567: b8 0b 00 00 00 mov $0xb,%eax
56c: cd 40 int $0x40
56e: c3 ret
0000056f <sbrk>:
SYSCALL(sbrk)
56f: b8 0c 00 00 00 mov $0xc,%eax
574: cd 40 int $0x40
576: c3 ret
00000577 <sleep>:
SYSCALL(sleep)
577: b8 0d 00 00 00 mov $0xd,%eax
57c: cd 40 int $0x40
57e: c3 ret
0000057f <uptime>:
SYSCALL(uptime)
57f: b8 0e 00 00 00 mov $0xe,%eax
584: cd 40 int $0x40
586: c3 ret
00000587 <halt>:
SYSCALL(halt)
587: b8 16 00 00 00 mov $0x16,%eax
58c: cd 40 int $0x40
58e: c3 ret
0000058f <date>:
SYSCALL(date)
58f: b8 17 00 00 00 mov $0x17,%eax
594: cd 40 int $0x40
596: c3 ret
00000597 <getuid>:
SYSCALL(getuid)
597: b8 18 00 00 00 mov $0x18,%eax
59c: cd 40 int $0x40
59e: c3 ret
0000059f <getgid>:
SYSCALL(getgid)
59f: b8 19 00 00 00 mov $0x19,%eax
5a4: cd 40 int $0x40
5a6: c3 ret
000005a7 <getppid>:
SYSCALL(getppid)
5a7: b8 1a 00 00 00 mov $0x1a,%eax
5ac: cd 40 int $0x40
5ae: c3 ret
000005af <setuid>:
SYSCALL(setuid)
5af: b8 1b 00 00 00 mov $0x1b,%eax
5b4: cd 40 int $0x40
5b6: c3 ret
000005b7 <setgid>:
SYSCALL(setgid)
5b7: b8 1c 00 00 00 mov $0x1c,%eax
5bc: cd 40 int $0x40
5be: c3 ret
000005bf <getprocs>:
SYSCALL(getprocs)
5bf: b8 1d 00 00 00 mov $0x1d,%eax
5c4: cd 40 int $0x40
5c6: c3 ret
000005c7 <setpriority>:
SYSCALL(setpriority)
5c7: b8 1e 00 00 00 mov $0x1e,%eax
5cc: cd 40 int $0x40
5ce: c3 ret
000005cf <chmod>:
SYSCALL(chmod)
5cf: b8 1f 00 00 00 mov $0x1f,%eax
5d4: cd 40 int $0x40
5d6: c3 ret
000005d7 <chown>:
SYSCALL(chown)
5d7: b8 20 00 00 00 mov $0x20,%eax
5dc: cd 40 int $0x40
5de: c3 ret
000005df <chgrp>:
SYSCALL(chgrp)
5df: b8 21 00 00 00 mov $0x21,%eax
5e4: cd 40 int $0x40
5e6: c3 ret
000005e7 <putc>:
#include "stat.h"
#include "user.h"
static void
putc(int fd, char c)
{
5e7: 55 push %ebp
5e8: 89 e5 mov %esp,%ebp
5ea: 83 ec 18 sub $0x18,%esp
5ed: 8b 45 0c mov 0xc(%ebp),%eax
5f0: 88 45 f4 mov %al,-0xc(%ebp)
write(fd, &c, 1);
5f3: 83 ec 04 sub $0x4,%esp
5f6: 6a 01 push $0x1
5f8: 8d 45 f4 lea -0xc(%ebp),%eax
5fb: 50 push %eax
5fc: ff 75 08 pushl 0x8(%ebp)
5ff: e8 03 ff ff ff call 507 <write>
604: 83 c4 10 add $0x10,%esp
}
607: 90 nop
608: c9 leave
609: c3 ret
0000060a <printint>:
static void
printint(int fd, int xx, int base, int sgn)
{
60a: 55 push %ebp
60b: 89 e5 mov %esp,%ebp
60d: 53 push %ebx
60e: 83 ec 24 sub $0x24,%esp
static char digits[] = "0123456789ABCDEF";
char buf[16];
int i, neg;
uint x;
neg = 0;
611: c7 45 f0 00 00 00 00 movl $0x0,-0x10(%ebp)
if(sgn && xx < 0){
618: 83 7d 14 00 cmpl $0x0,0x14(%ebp)
61c: 74 17 je 635 <printint+0x2b>
61e: 83 7d 0c 00 cmpl $0x0,0xc(%ebp)
622: 79 11 jns 635 <printint+0x2b>
neg = 1;
624: c7 45 f0 01 00 00 00 movl $0x1,-0x10(%ebp)
x = -xx;
62b: 8b 45 0c mov 0xc(%ebp),%eax
62e: f7 d8 neg %eax
630: 89 45 ec mov %eax,-0x14(%ebp)
633: eb 06 jmp 63b <printint+0x31>
} else {
x = xx;
635: 8b 45 0c mov 0xc(%ebp),%eax
638: 89 45 ec mov %eax,-0x14(%ebp)
}
i = 0;
63b: c7 45 f4 00 00 00 00 movl $0x0,-0xc(%ebp)
do{
buf[i++] = digits[x % base];
642: 8b 4d f4 mov -0xc(%ebp),%ecx
645: 8d 41 01 lea 0x1(%ecx),%eax
648: 89 45 f4 mov %eax,-0xc(%ebp)
64b: 8b 5d 10 mov 0x10(%ebp),%ebx
64e: 8b 45 ec mov -0x14(%ebp),%eax
651: ba 00 00 00 00 mov $0x0,%edx
656: f7 f3 div %ebx
658: 89 d0 mov %edx,%eax
65a: 0f b6 80 40 0d 00 00 movzbl 0xd40(%eax),%eax
661: 88 44 0d dc mov %al,-0x24(%ebp,%ecx,1)
}while((x /= base) != 0);
665: 8b 5d 10 mov 0x10(%ebp),%ebx
668: 8b 45 ec mov -0x14(%ebp),%eax
66b: ba 00 00 00 00 mov $0x0,%edx
670: f7 f3 div %ebx
672: 89 45 ec mov %eax,-0x14(%ebp)
675: 83 7d ec 00 cmpl $0x0,-0x14(%ebp)
679: 75 c7 jne 642 <printint+0x38>
if(neg)
67b: 83 7d f0 00 cmpl $0x0,-0x10(%ebp)
67f: 74 2d je 6ae <printint+0xa4>
buf[i++] = '-';
681: 8b 45 f4 mov -0xc(%ebp),%eax
684: 8d 50 01 lea 0x1(%eax),%edx
687: 89 55 f4 mov %edx,-0xc(%ebp)
68a: c6 44 05 dc 2d movb $0x2d,-0x24(%ebp,%eax,1)
while(--i >= 0)
68f: eb 1d jmp 6ae <printint+0xa4>
putc(fd, buf[i]);
691: 8d 55 dc lea -0x24(%ebp),%edx
694: 8b 45 f4 mov -0xc(%ebp),%eax
697: 01 d0 add %edx,%eax
699: 0f b6 00 movzbl (%eax),%eax
69c: 0f be c0 movsbl %al,%eax
69f: 83 ec 08 sub $0x8,%esp
6a2: 50 push %eax
6a3: ff 75 08 pushl 0x8(%ebp)
6a6: e8 3c ff ff ff call 5e7 <putc>
6ab: 83 c4 10 add $0x10,%esp
buf[i++] = digits[x % base];
}while((x /= base) != 0);
if(neg)
buf[i++] = '-';
while(--i >= 0)
6ae: 83 6d f4 01 subl $0x1,-0xc(%ebp)
6b2: 83 7d f4 00 cmpl $0x0,-0xc(%ebp)
6b6: 79 d9 jns 691 <printint+0x87>
putc(fd, buf[i]);
}
6b8: 90 nop
6b9: 8b 5d fc mov -0x4(%ebp),%ebx
6bc: c9 leave
6bd: c3 ret
000006be <printf>:
// Print to the given fd. Only understands %d, %x, %p, %s.
void
printf(int fd, char *fmt, ...)
{
6be: 55 push %ebp
6bf: 89 e5 mov %esp,%ebp
6c1: 83 ec 28 sub $0x28,%esp
char *s;
int c, i, state;
uint *ap;
state = 0;
6c4: c7 45 ec 00 00 00 00 movl $0x0,-0x14(%ebp)
ap = (uint*)(void*)&fmt + 1;
6cb: 8d 45 0c lea 0xc(%ebp),%eax
6ce: 83 c0 04 add $0x4,%eax
6d1: 89 45 e8 mov %eax,-0x18(%ebp)
for(i = 0; fmt[i]; i++){
6d4: c7 45 f0 00 00 00 00 movl $0x0,-0x10(%ebp)
6db: e9 59 01 00 00 jmp 839 <printf+0x17b>
c = fmt[i] & 0xff;
6e0: 8b 55 0c mov 0xc(%ebp),%edx
6e3: 8b 45 f0 mov -0x10(%ebp),%eax
6e6: 01 d0 add %edx,%eax
6e8: 0f b6 00 movzbl (%eax),%eax
6eb: 0f be c0 movsbl %al,%eax
6ee: 25 ff 00 00 00 and $0xff,%eax
6f3: 89 45 e4 mov %eax,-0x1c(%ebp)
if(state == 0){
6f6: 83 7d ec 00 cmpl $0x0,-0x14(%ebp)
6fa: 75 2c jne 728 <printf+0x6a>
if(c == '%'){
6fc: 83 7d e4 25 cmpl $0x25,-0x1c(%ebp)
700: 75 0c jne 70e <printf+0x50>
state = '%';
702: c7 45 ec 25 00 00 00 movl $0x25,-0x14(%ebp)
709: e9 27 01 00 00 jmp 835 <printf+0x177>
} else {
putc(fd, c);
70e: 8b 45 e4 mov -0x1c(%ebp),%eax
711: 0f be c0 movsbl %al,%eax
714: 83 ec 08 sub $0x8,%esp
717: 50 push %eax
718: ff 75 08 pushl 0x8(%ebp)
71b: e8 c7 fe ff ff call 5e7 <putc>
720: 83 c4 10 add $0x10,%esp
723: e9 0d 01 00 00 jmp 835 <printf+0x177>
}
} else if(state == '%'){
728: 83 7d ec 25 cmpl $0x25,-0x14(%ebp)
72c: 0f 85 03 01 00 00 jne 835 <printf+0x177>
if(c == 'd'){
732: 83 7d e4 64 cmpl $0x64,-0x1c(%ebp)
736: 75 1e jne 756 <printf+0x98>
printint(fd, *ap, 10, 1);
738: 8b 45 e8 mov -0x18(%ebp),%eax
73b: 8b 00 mov (%eax),%eax
73d: 6a 01 push $0x1
73f: 6a 0a push $0xa
741: 50 push %eax
742: ff 75 08 pushl 0x8(%ebp)
745: e8 c0 fe ff ff call 60a <printint>
74a: 83 c4 10 add $0x10,%esp
ap++;
74d: 83 45 e8 04 addl $0x4,-0x18(%ebp)
751: e9 d8 00 00 00 jmp 82e <printf+0x170>
} else if(c == 'x' || c == 'p'){
756: 83 7d e4 78 cmpl $0x78,-0x1c(%ebp)
75a: 74 06 je 762 <printf+0xa4>
75c: 83 7d e4 70 cmpl $0x70,-0x1c(%ebp)
760: 75 1e jne 780 <printf+0xc2>
printint(fd, *ap, 16, 0);
762: 8b 45 e8 mov -0x18(%ebp),%eax
765: 8b 00 mov (%eax),%eax
767: 6a 00 push $0x0
769: 6a 10 push $0x10
76b: 50 push %eax
76c: ff 75 08 pushl 0x8(%ebp)
76f: e8 96 fe ff ff call 60a <printint>
774: 83 c4 10 add $0x10,%esp
ap++;
777: 83 45 e8 04 addl $0x4,-0x18(%ebp)
77b: e9 ae 00 00 00 jmp 82e <printf+0x170>
} else if(c == 's'){
780: 83 7d e4 73 cmpl $0x73,-0x1c(%ebp)
784: 75 43 jne 7c9 <printf+0x10b>
s = (char*)*ap;
786: 8b 45 e8 mov -0x18(%ebp),%eax
789: 8b 00 mov (%eax),%eax
78b: 89 45 f4 mov %eax,-0xc(%ebp)
ap++;
78e: 83 45 e8 04 addl $0x4,-0x18(%ebp)
if(s == 0)
792: 83 7d f4 00 cmpl $0x0,-0xc(%ebp)
796: 75 25 jne 7bd <printf+0xff>
s = "(null)";
798: c7 45 f4 ac 0a 00 00 movl $0xaac,-0xc(%ebp)
while(*s != 0){
79f: eb 1c jmp 7bd <printf+0xff>
putc(fd, *s);
7a1: 8b 45 f4 mov -0xc(%ebp),%eax
7a4: 0f b6 00 movzbl (%eax),%eax
7a7: 0f be c0 movsbl %al,%eax
7aa: 83 ec 08 sub $0x8,%esp
7ad: 50 push %eax
7ae: ff 75 08 pushl 0x8(%ebp)
7b1: e8 31 fe ff ff call 5e7 <putc>
7b6: 83 c4 10 add $0x10,%esp
s++;
7b9: 83 45 f4 01 addl $0x1,-0xc(%ebp)
} else if(c == 's'){
s = (char*)*ap;
ap++;
if(s == 0)
s = "(null)";
while(*s != 0){
7bd: 8b 45 f4 mov -0xc(%ebp),%eax
7c0: 0f b6 00 movzbl (%eax),%eax
7c3: 84 c0 test %al,%al
7c5: 75 da jne 7a1 <printf+0xe3>
7c7: eb 65 jmp 82e <printf+0x170>
putc(fd, *s);
s++;
}
} else if(c == 'c'){
7c9: 83 7d e4 63 cmpl $0x63,-0x1c(%ebp)
7cd: 75 1d jne 7ec <printf+0x12e>
putc(fd, *ap);
7cf: 8b 45 e8 mov -0x18(%ebp),%eax
7d2: 8b 00 mov (%eax),%eax
7d4: 0f be c0 movsbl %al,%eax
7d7: 83 ec 08 sub $0x8,%esp
7da: 50 push %eax
7db: ff 75 08 pushl 0x8(%ebp)
7de: e8 04 fe ff ff call 5e7 <putc>
7e3: 83 c4 10 add $0x10,%esp
ap++;
7e6: 83 45 e8 04 addl $0x4,-0x18(%ebp)
7ea: eb 42 jmp 82e <printf+0x170>
} else if(c == '%'){
7ec: 83 7d e4 25 cmpl $0x25,-0x1c(%ebp)
7f0: 75 17 jne 809 <printf+0x14b>
putc(fd, c);
7f2: 8b 45 e4 mov -0x1c(%ebp),%eax
7f5: 0f be c0 movsbl %al,%eax
7f8: 83 ec 08 sub $0x8,%esp
7fb: 50 push %eax
7fc: ff 75 08 pushl 0x8(%ebp)
7ff: e8 e3 fd ff ff call 5e7 <putc>
804: 83 c4 10 add $0x10,%esp
807: eb 25 jmp 82e <printf+0x170>
} else {
// Unknown % sequence. Print it to draw attention.
putc(fd, '%');
809: 83 ec 08 sub $0x8,%esp
80c: 6a 25 push $0x25
80e: ff 75 08 pushl 0x8(%ebp)
811: e8 d1 fd ff ff call 5e7 <putc>
816: 83 c4 10 add $0x10,%esp
putc(fd, c);
819: 8b 45 e4 mov -0x1c(%ebp),%eax
81c: 0f be c0 movsbl %al,%eax
81f: 83 ec 08 sub $0x8,%esp
822: 50 push %eax
823: ff 75 08 pushl 0x8(%ebp)
826: e8 bc fd ff ff call 5e7 <putc>
82b: 83 c4 10 add $0x10,%esp
}
state = 0;
82e: c7 45 ec 00 00 00 00 movl $0x0,-0x14(%ebp)
int c, i, state;
uint *ap;
state = 0;
ap = (uint*)(void*)&fmt + 1;
for(i = 0; fmt[i]; i++){
835: 83 45 f0 01 addl $0x1,-0x10(%ebp)
839: 8b 55 0c mov 0xc(%ebp),%edx
83c: 8b 45 f0 mov -0x10(%ebp),%eax
83f: 01 d0 add %edx,%eax
841: 0f b6 00 movzbl (%eax),%eax
844: 84 c0 test %al,%al
846: 0f 85 94 fe ff ff jne 6e0 <printf+0x22>
putc(fd, c);
}
state = 0;
}
}
}
84c: 90 nop
84d: c9 leave
84e: c3 ret
0000084f <free>:
static Header base;
static Header *freep;
void
free(void *ap)
{
84f: 55 push %ebp
850: 89 e5 mov %esp,%ebp
852: 83 ec 10 sub $0x10,%esp
Header *bp, *p;
bp = (Header*)ap - 1;
855: 8b 45 08 mov 0x8(%ebp),%eax
858: 83 e8 08 sub $0x8,%eax
85b: 89 45 f8 mov %eax,-0x8(%ebp)
for(p = freep; !(bp > p && bp < p->s.ptr); p = p->s.ptr)
85e: a1 68 0d 00 00 mov 0xd68,%eax
863: 89 45 fc mov %eax,-0x4(%ebp)
866: eb 24 jmp 88c <free+0x3d>
if(p >= p->s.ptr && (bp > p || bp < p->s.ptr))
868: 8b 45 fc mov -0x4(%ebp),%eax
86b: 8b 00 mov (%eax),%eax
86d: 3b 45 fc cmp -0x4(%ebp),%eax
870: 77 12 ja 884 <free+0x35>
872: 8b 45 f8 mov -0x8(%ebp),%eax
875: 3b 45 fc cmp -0x4(%ebp),%eax
878: 77 24 ja 89e <free+0x4f>
87a: 8b 45 fc mov -0x4(%ebp),%eax
87d: 8b 00 mov (%eax),%eax
87f: 3b 45 f8 cmp -0x8(%ebp),%eax
882: 77 1a ja 89e <free+0x4f>
free(void *ap)
{
Header *bp, *p;
bp = (Header*)ap - 1;
for(p = freep; !(bp > p && bp < p->s.ptr); p = p->s.ptr)
884: 8b 45 fc mov -0x4(%ebp),%eax
887: 8b 00 mov (%eax),%eax
889: 89 45 fc mov %eax,-0x4(%ebp)
88c: 8b 45 f8 mov -0x8(%ebp),%eax
88f: 3b 45 fc cmp -0x4(%ebp),%eax
892: 76 d4 jbe 868 <free+0x19>
894: 8b 45 fc mov -0x4(%ebp),%eax
897: 8b 00 mov (%eax),%eax
899: 3b 45 f8 cmp -0x8(%ebp),%eax
89c: 76 ca jbe 868 <free+0x19>
if(p >= p->s.ptr && (bp > p || bp < p->s.ptr))
break;
if(bp + bp->s.size == p->s.ptr){
89e: 8b 45 f8 mov -0x8(%ebp),%eax
8a1: 8b 40 04 mov 0x4(%eax),%eax
8a4: 8d 14 c5 00 00 00 00 lea 0x0(,%eax,8),%edx
8ab: 8b 45 f8 mov -0x8(%ebp),%eax
8ae: 01 c2 add %eax,%edx
8b0: 8b 45 fc mov -0x4(%ebp),%eax
8b3: 8b 00 mov (%eax),%eax
8b5: 39 c2 cmp %eax,%edx
8b7: 75 24 jne 8dd <free+0x8e>
bp->s.size += p->s.ptr->s.size;
8b9: 8b 45 f8 mov -0x8(%ebp),%eax
8bc: 8b 50 04 mov 0x4(%eax),%edx
8bf: 8b 45 fc mov -0x4(%ebp),%eax
8c2: 8b 00 mov (%eax),%eax
8c4: 8b 40 04 mov 0x4(%eax),%eax
8c7: 01 c2 add %eax,%edx
8c9: 8b 45 f8 mov -0x8(%ebp),%eax
8cc: 89 50 04 mov %edx,0x4(%eax)
bp->s.ptr = p->s.ptr->s.ptr;
8cf: 8b 45 fc mov -0x4(%ebp),%eax
8d2: 8b 00 mov (%eax),%eax
8d4: 8b 10 mov (%eax),%edx
8d6: 8b 45 f8 mov -0x8(%ebp),%eax
8d9: 89 10 mov %edx,(%eax)
8db: eb 0a jmp 8e7 <free+0x98>
} else
bp->s.ptr = p->s.ptr;
8dd: 8b 45 fc mov -0x4(%ebp),%eax
8e0: 8b 10 mov (%eax),%edx
8e2: 8b 45 f8 mov -0x8(%ebp),%eax
8e5: 89 10 mov %edx,(%eax)
if(p + p->s.size == bp){
8e7: 8b 45 fc mov -0x4(%ebp),%eax
8ea: 8b 40 04 mov 0x4(%eax),%eax
8ed: 8d 14 c5 00 00 00 00 lea 0x0(,%eax,8),%edx
8f4: 8b 45 fc mov -0x4(%ebp),%eax
8f7: 01 d0 add %edx,%eax
8f9: 3b 45 f8 cmp -0x8(%ebp),%eax
8fc: 75 20 jne 91e <free+0xcf>
p->s.size += bp->s.size;
8fe: 8b 45 fc mov -0x4(%ebp),%eax
901: 8b 50 04 mov 0x4(%eax),%edx
904: 8b 45 f8 mov -0x8(%ebp),%eax
907: 8b 40 04 mov 0x4(%eax),%eax
90a: 01 c2 add %eax,%edx
90c: 8b 45 fc mov -0x4(%ebp),%eax
90f: 89 50 04 mov %edx,0x4(%eax)
p->s.ptr = bp->s.ptr;
912: 8b 45 f8 mov -0x8(%ebp),%eax
915: 8b 10 mov (%eax),%edx
917: 8b 45 fc mov -0x4(%ebp),%eax
91a: 89 10 mov %edx,(%eax)
91c: eb 08 jmp 926 <free+0xd7>
} else
p->s.ptr = bp;
91e: 8b 45 fc mov -0x4(%ebp),%eax
921: 8b 55 f8 mov -0x8(%ebp),%edx
924: 89 10 mov %edx,(%eax)
freep = p;
926: 8b 45 fc mov -0x4(%ebp),%eax
929: a3 68 0d 00 00 mov %eax,0xd68
}
92e: 90 nop
92f: c9 leave
930: c3 ret
00000931 <morecore>:
static Header*
morecore(uint nu)
{
931: 55 push %ebp
932: 89 e5 mov %esp,%ebp
934: 83 ec 18 sub $0x18,%esp
char *p;
Header *hp;
if(nu < 4096)
937: 81 7d 08 ff 0f 00 00 cmpl $0xfff,0x8(%ebp)
93e: 77 07 ja 947 <morecore+0x16>
nu = 4096;
940: c7 45 08 00 10 00 00 movl $0x1000,0x8(%ebp)
p = sbrk(nu * sizeof(Header));
947: 8b 45 08 mov 0x8(%ebp),%eax
94a: c1 e0 03 shl $0x3,%eax
94d: 83 ec 0c sub $0xc,%esp
950: 50 push %eax
951: e8 19 fc ff ff call 56f <sbrk>
956: 83 c4 10 add $0x10,%esp
959: 89 45 f4 mov %eax,-0xc(%ebp)
if(p == (char*)-1)
95c: 83 7d f4 ff cmpl $0xffffffff,-0xc(%ebp)
960: 75 07 jne 969 <morecore+0x38>
return 0;
962: b8 00 00 00 00 mov $0x0,%eax
967: eb 26 jmp 98f <morecore+0x5e>
hp = (Header*)p;
969: 8b 45 f4 mov -0xc(%ebp),%eax
96c: 89 45 f0 mov %eax,-0x10(%ebp)
hp->s.size = nu;
96f: 8b 45 f0 mov -0x10(%ebp),%eax
972: 8b 55 08 mov 0x8(%ebp),%edx
975: 89 50 04 mov %edx,0x4(%eax)
free((void*)(hp + 1));
978: 8b 45 f0 mov -0x10(%ebp),%eax
97b: 83 c0 08 add $0x8,%eax
97e: 83 ec 0c sub $0xc,%esp
981: 50 push %eax
982: e8 c8 fe ff ff call 84f <free>
987: 83 c4 10 add $0x10,%esp
return freep;
98a: a1 68 0d 00 00 mov 0xd68,%eax
}
98f: c9 leave
990: c3 ret
00000991 <malloc>:
void*
malloc(uint nbytes)
{
991: 55 push %ebp
992: 89 e5 mov %esp,%ebp
994: 83 ec 18 sub $0x18,%esp
Header *p, *prevp;
uint nunits;
nunits = (nbytes + sizeof(Header) - 1)/sizeof(Header) + 1;
997: 8b 45 08 mov 0x8(%ebp),%eax
99a: 83 c0 07 add $0x7,%eax
99d: c1 e8 03 shr $0x3,%eax
9a0: 83 c0 01 add $0x1,%eax
9a3: 89 45 ec mov %eax,-0x14(%ebp)
if((prevp = freep) == 0){
9a6: a1 68 0d 00 00 mov 0xd68,%eax
9ab: 89 45 f0 mov %eax,-0x10(%ebp)
9ae: 83 7d f0 00 cmpl $0x0,-0x10(%ebp)
9b2: 75 23 jne 9d7 <malloc+0x46>
base.s.ptr = freep = prevp = &base;
9b4: c7 45 f0 60 0d 00 00 movl $0xd60,-0x10(%ebp)
9bb: 8b 45 f0 mov -0x10(%ebp),%eax
9be: a3 68 0d 00 00 mov %eax,0xd68
9c3: a1 68 0d 00 00 mov 0xd68,%eax
9c8: a3 60 0d 00 00 mov %eax,0xd60
base.s.size = 0;
9cd: c7 05 64 0d 00 00 00 movl $0x0,0xd64
9d4: 00 00 00
}
for(p = prevp->s.ptr; ; prevp = p, p = p->s.ptr){
9d7: 8b 45 f0 mov -0x10(%ebp),%eax
9da: 8b 00 mov (%eax),%eax
9dc: 89 45 f4 mov %eax,-0xc(%ebp)
if(p->s.size >= nunits){
9df: 8b 45 f4 mov -0xc(%ebp),%eax
9e2: 8b 40 04 mov 0x4(%eax),%eax
9e5: 3b 45 ec cmp -0x14(%ebp),%eax
9e8: 72 4d jb a37 <malloc+0xa6>
if(p->s.size == nunits)
9ea: 8b 45 f4 mov -0xc(%ebp),%eax
9ed: 8b 40 04 mov 0x4(%eax),%eax
9f0: 3b 45 ec cmp -0x14(%ebp),%eax
9f3: 75 0c jne a01 <malloc+0x70>
prevp->s.ptr = p->s.ptr;
9f5: 8b 45 f4 mov -0xc(%ebp),%eax
9f8: 8b 10 mov (%eax),%edx
9fa: 8b 45 f0 mov -0x10(%ebp),%eax
9fd: 89 10 mov %edx,(%eax)
9ff: eb 26 jmp a27 <malloc+0x96>
else {
p->s.size -= nunits;
a01: 8b 45 f4 mov -0xc(%ebp),%eax
a04: 8b 40 04 mov 0x4(%eax),%eax
a07: 2b 45 ec sub -0x14(%ebp),%eax
a0a: 89 c2 mov %eax,%edx
a0c: 8b 45 f4 mov -0xc(%ebp),%eax
a0f: 89 50 04 mov %edx,0x4(%eax)
p += p->s.size;
a12: 8b 45 f4 mov -0xc(%ebp),%eax
a15: 8b 40 04 mov 0x4(%eax),%eax
a18: c1 e0 03 shl $0x3,%eax
a1b: 01 45 f4 add %eax,-0xc(%ebp)
p->s.size = nunits;
a1e: 8b 45 f4 mov -0xc(%ebp),%eax
a21: 8b 55 ec mov -0x14(%ebp),%edx
a24: 89 50 04 mov %edx,0x4(%eax)
}
freep = prevp;
a27: 8b 45 f0 mov -0x10(%ebp),%eax
a2a: a3 68 0d 00 00 mov %eax,0xd68
return (void*)(p + 1);
a2f: 8b 45 f4 mov -0xc(%ebp),%eax
a32: 83 c0 08 add $0x8,%eax
a35: eb 3b jmp a72 <malloc+0xe1>
}
if(p == freep)
a37: a1 68 0d 00 00 mov 0xd68,%eax
a3c: 39 45 f4 cmp %eax,-0xc(%ebp)
a3f: 75 1e jne a5f <malloc+0xce>
if((p = morecore(nunits)) == 0)
a41: 83 ec 0c sub $0xc,%esp
a44: ff 75 ec pushl -0x14(%ebp)
a47: e8 e5 fe ff ff call 931 <morecore>
a4c: 83 c4 10 add $0x10,%esp
a4f: 89 45 f4 mov %eax,-0xc(%ebp)
a52: 83 7d f4 00 cmpl $0x0,-0xc(%ebp)
a56: 75 07 jne a5f <malloc+0xce>
return 0;
a58: b8 00 00 00 00 mov $0x0,%eax
a5d: eb 13 jmp a72 <malloc+0xe1>
nunits = (nbytes + sizeof(Header) - 1)/sizeof(Header) + 1;
if((prevp = freep) == 0){
base.s.ptr = freep = prevp = &base;
base.s.size = 0;
}
for(p = prevp->s.ptr; ; prevp = p, p = p->s.ptr){
a5f: 8b 45 f4 mov -0xc(%ebp),%eax
a62: 89 45 f0 mov %eax,-0x10(%ebp)
a65: 8b 45 f4 mov -0xc(%ebp),%eax
a68: 8b 00 mov (%eax),%eax
a6a: 89 45 f4 mov %eax,-0xc(%ebp)
return (void*)(p + 1);
}
if(p == freep)
if((p = morecore(nunits)) == 0)
return 0;
}
a6d: e9 6d ff ff ff jmp 9df <malloc+0x4e>
}
a72: c9 leave
a73: c3 ret
| 34.375082 | 60 | 0.42093 |
660217671cd6385ee73628c9cc60512457e0a23a | 5,619 | asm | Assembly | Transynther/x86/_processed/NONE/_xt_/i7-8650U_0xd2.log_912_1479.asm | ljhsiun2/medusa | 67d769b8a2fb42c538f10287abaf0e6dbb463f0c | [
"MIT"
] | 9 | 2020-08-13T19:41:58.000Z | 2022-03-30T12:22:51.000Z | Transynther/x86/_processed/NONE/_xt_/i7-8650U_0xd2.log_912_1479.asm | ljhsiun2/medusa | 67d769b8a2fb42c538f10287abaf0e6dbb463f0c | [
"MIT"
] | 1 | 2021-04-29T06:29:35.000Z | 2021-05-13T21:02:30.000Z | Transynther/x86/_processed/NONE/_xt_/i7-8650U_0xd2.log_912_1479.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 %rax
push %rbp
push %rbx
push %rcx
push %rdi
push %rdx
push %rsi
lea addresses_A_ht+0xf68e, %rsi
lea addresses_WC_ht+0x2b7e, %rdi
nop
nop
dec %rbx
mov $99, %rcx
rep movsw
nop
sub $9242, %rdx
lea addresses_normal_ht+0x7afe, %rbx
nop
nop
cmp %rax, %rax
movl $0x61626364, (%rbx)
nop
mfence
lea addresses_WC_ht+0x17366, %rsi
lea addresses_UC_ht+0x54fe, %rdi
nop
nop
nop
nop
nop
cmp %rbp, %rbp
mov $45, %rcx
rep movsq
and %rbp, %rbp
lea addresses_normal_ht+0x8fe, %rbp
nop
nop
nop
nop
and %rcx, %rcx
movb (%rbp), %dl
nop
nop
nop
dec %rsi
lea addresses_A_ht+0xf098, %rcx
nop
nop
sub $4985, %rbp
mov (%rcx), %rdi
nop
sub $15014, %rsi
lea addresses_D_ht+0xd1de, %rcx
nop
sub $19591, %rax
mov $0x6162636465666768, %rdx
movq %rdx, %xmm0
movups %xmm0, (%rcx)
nop
nop
nop
nop
nop
add %rsi, %rsi
lea addresses_D_ht+0x197e, %rbx
cmp %rcx, %rcx
mov (%rbx), %bp
nop
nop
nop
nop
nop
sub %rbp, %rbp
pop %rsi
pop %rdx
pop %rdi
pop %rcx
pop %rbx
pop %rbp
pop %rax
ret
.global s_faulty_load
s_faulty_load:
push %r10
push %r11
push %r12
push %r14
push %r9
push %rbx
push %rdi
// Store
lea addresses_PSE+0xdd58, %rdi
nop
nop
nop
nop
nop
inc %r11
movb $0x51, (%rdi)
// Exception!!!
nop
nop
nop
nop
mov (0), %r14
nop
nop
nop
nop
xor %r11, %r11
// Faulty Load
lea addresses_D+0x1e4fe, %rbx
nop
nop
nop
nop
nop
sub $15924, %r9
mov (%rbx), %di
lea oracles, %rbx
and $0xff, %rdi
shlq $12, %rdi
mov (%rbx,%rdi,1), %rdi
pop %rdi
pop %rbx
pop %r9
pop %r14
pop %r12
pop %r11
pop %r10
ret
/*
<gen_faulty_load>
[REF]
{'OP': 'LOAD', 'src': {'type': 'addresses_D', 'size': 2, 'AVXalign': False, 'NT': False, 'congruent': 0, 'same': False}}
{'OP': 'STOR', 'dst': {'type': 'addresses_PSE', 'size': 1, 'AVXalign': False, 'NT': False, 'congruent': 1, 'same': False}}
[Faulty Load]
{'OP': 'LOAD', 'src': {'type': 'addresses_D', 'size': 2, 'AVXalign': False, 'NT': False, 'congruent': 0, 'same': True}}
<gen_prepare_buffer>
{'OP': 'REPM', 'src': {'type': 'addresses_A_ht', 'congruent': 4, 'same': False}, 'dst': {'type': 'addresses_WC_ht', 'congruent': 5, 'same': False}}
{'OP': 'STOR', 'dst': {'type': 'addresses_normal_ht', 'size': 4, 'AVXalign': False, 'NT': False, 'congruent': 6, 'same': False}}
{'OP': 'REPM', 'src': {'type': 'addresses_WC_ht', 'congruent': 3, 'same': False}, 'dst': {'type': 'addresses_UC_ht', 'congruent': 9, 'same': False}}
{'OP': 'LOAD', 'src': {'type': 'addresses_normal_ht', 'size': 1, 'AVXalign': False, 'NT': False, 'congruent': 7, 'same': False}}
{'OP': 'LOAD', 'src': {'type': 'addresses_A_ht', 'size': 8, 'AVXalign': False, 'NT': False, 'congruent': 0, 'same': False}}
{'OP': 'STOR', 'dst': {'type': 'addresses_D_ht', 'size': 16, 'AVXalign': False, 'NT': False, 'congruent': 5, 'same': False}}
{'OP': 'LOAD', 'src': {'type': 'addresses_D_ht', 'size': 2, 'AVXalign': False, 'NT': False, 'congruent': 5, 'same': False}}
{'36': 912}
36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36 36
*/
| 35.789809 | 2,735 | 0.656878 |
53412257a8cee3297b64dfc14ece486b8d6ff9be | 6,488 | asm | Assembly | Transynther/x86/_processed/AVXALIGN/_st_/i7-7700_9_0xca.log_725_1441.asm | ljhsiun2/medusa | 67d769b8a2fb42c538f10287abaf0e6dbb463f0c | [
"MIT"
] | 9 | 2020-08-13T19:41:58.000Z | 2022-03-30T12:22:51.000Z | Transynther/x86/_processed/AVXALIGN/_st_/i7-7700_9_0xca.log_725_1441.asm | ljhsiun2/medusa | 67d769b8a2fb42c538f10287abaf0e6dbb463f0c | [
"MIT"
] | 1 | 2021-04-29T06:29:35.000Z | 2021-05-13T21:02:30.000Z | Transynther/x86/_processed/AVXALIGN/_st_/i7-7700_9_0xca.log_725_1441.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 %r13
push %r14
push %r8
push %rbp
push %rcx
push %rdi
push %rsi
lea addresses_UC_ht+0xf23a, %rsi
lea addresses_A_ht+0x142f5, %rdi
clflush (%rsi)
nop
nop
nop
nop
add $11349, %r13
mov $43, %rcx
rep movsq
nop
nop
nop
nop
xor $54398, %rcx
lea addresses_WT_ht+0x123f2, %rsi
lea addresses_A_ht+0x5c60, %rdi
nop
nop
nop
xor $53728, %r12
mov $1, %rcx
rep movsw
nop
nop
nop
nop
nop
inc %rcx
lea addresses_normal_ht+0x14d9e, %rbp
dec %r8
mov $0x6162636465666768, %rsi
movq %rsi, %xmm2
vmovups %ymm2, (%rbp)
nop
nop
nop
nop
and %rcx, %rcx
lea addresses_A_ht+0x2a3a, %rsi
clflush (%rsi)
nop
nop
nop
nop
nop
xor $53823, %rbp
mov $0x6162636465666768, %r12
movq %r12, %xmm6
movups %xmm6, (%rsi)
nop
nop
nop
nop
xor %rdi, %rdi
lea addresses_UC_ht+0x1de3a, %r13
nop
nop
sub $1072, %rsi
movb (%r13), %cl
nop
dec %rdi
lea addresses_A_ht+0x1d83a, %rdi
nop
nop
nop
nop
nop
inc %r13
mov $0x6162636465666768, %r12
movq %r12, (%rdi)
nop
xor %r8, %r8
lea addresses_WC_ht+0x1ba3a, %rsi
lea addresses_UC_ht+0xf9bc, %rdi
nop
nop
nop
add $41764, %r14
mov $60, %rcx
rep movsw
nop
dec %r8
lea addresses_WT_ht+0xbdba, %r13
nop
nop
nop
nop
cmp %r14, %r14
movw $0x6162, (%r13)
nop
nop
dec %rsi
lea addresses_D_ht+0x1ea1a, %r13
nop
xor %r14, %r14
mov (%r13), %edi
nop
nop
sub $60603, %rbp
lea addresses_UC_ht+0x17ada, %rsi
lea addresses_normal_ht+0x1764, %rdi
clflush (%rsi)
nop
add %r14, %r14
mov $106, %rcx
rep movsl
nop
and $58487, %r8
pop %rsi
pop %rdi
pop %rcx
pop %rbp
pop %r8
pop %r14
pop %r13
pop %r12
ret
.global s_faulty_load
s_faulty_load:
push %r10
push %r12
push %r14
push %rbx
push %rcx
push %rdi
push %rsi
// REPMOV
mov $0x7da, %rsi
lea addresses_WT+0x1a82a, %rdi
nop
sub %rbx, %rbx
mov $88, %rcx
rep movsw
nop
nop
cmp %r12, %r12
// Store
lea addresses_PSE+0x2c3a, %r12
nop
nop
nop
inc %rcx
mov $0x5152535455565758, %rbx
movq %rbx, %xmm0
movaps %xmm0, (%r12)
nop
nop
nop
and %r14, %r14
// Store
lea addresses_US+0x283a, %r12
cmp $11716, %rbx
movl $0x51525354, (%r12)
cmp $49525, %r10
// Faulty Load
lea addresses_PSE+0xbe3a, %rbx
cmp $43768, %rcx
mov (%rbx), %r12d
lea oracles, %rcx
and $0xff, %r12
shlq $12, %r12
mov (%rcx,%r12,1), %r12
pop %rsi
pop %rdi
pop %rcx
pop %rbx
pop %r14
pop %r12
pop %r10
ret
/*
<gen_faulty_load>
[REF]
{'src': {'congruent': 0, 'AVXalign': False, 'same': False, 'size': 32, 'NT': False, 'type': 'addresses_PSE'}, 'OP': 'LOAD'}
{'src': {'congruent': 5, 'same': False, 'type': 'addresses_P'}, 'OP': 'REPM', 'dst': {'congruent': 4, 'same': False, 'type': 'addresses_WT'}}
{'OP': 'STOR', 'dst': {'congruent': 9, 'AVXalign': True, 'same': False, 'size': 16, 'NT': False, 'type': 'addresses_PSE'}}
{'OP': 'STOR', 'dst': {'congruent': 9, 'AVXalign': False, 'same': False, 'size': 4, 'NT': False, 'type': 'addresses_US'}}
[Faulty Load]
{'src': {'congruent': 0, 'AVXalign': True, 'same': True, 'size': 4, 'NT': False, 'type': 'addresses_PSE'}, 'OP': 'LOAD'}
<gen_prepare_buffer>
{'src': {'congruent': 9, 'same': True, 'type': 'addresses_UC_ht'}, 'OP': 'REPM', 'dst': {'congruent': 0, 'same': False, 'type': 'addresses_A_ht'}}
{'src': {'congruent': 3, 'same': False, 'type': 'addresses_WT_ht'}, 'OP': 'REPM', 'dst': {'congruent': 1, 'same': False, 'type': 'addresses_A_ht'}}
{'OP': 'STOR', 'dst': {'congruent': 1, 'AVXalign': False, 'same': True, 'size': 32, 'NT': False, 'type': 'addresses_normal_ht'}}
{'OP': 'STOR', 'dst': {'congruent': 7, 'AVXalign': False, 'same': False, 'size': 16, 'NT': False, 'type': 'addresses_A_ht'}}
{'src': {'congruent': 10, 'AVXalign': True, 'same': False, 'size': 1, 'NT': False, 'type': 'addresses_UC_ht'}, 'OP': 'LOAD'}
{'OP': 'STOR', 'dst': {'congruent': 8, 'AVXalign': False, 'same': False, 'size': 8, 'NT': False, 'type': 'addresses_A_ht'}}
{'src': {'congruent': 10, 'same': False, 'type': 'addresses_WC_ht'}, 'OP': 'REPM', 'dst': {'congruent': 1, 'same': False, 'type': 'addresses_UC_ht'}}
{'OP': 'STOR', 'dst': {'congruent': 7, 'AVXalign': False, 'same': False, 'size': 2, 'NT': False, 'type': 'addresses_WT_ht'}}
{'src': {'congruent': 5, 'AVXalign': False, 'same': False, 'size': 4, 'NT': True, 'type': 'addresses_D_ht'}, 'OP': 'LOAD'}
{'src': {'congruent': 5, 'same': False, 'type': 'addresses_UC_ht'}, 'OP': 'REPM', 'dst': {'congruent': 1, 'same': False, 'type': 'addresses_normal_ht'}}
{'33': 725}
33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33
*/
| 30.748815 | 2,174 | 0.656443 |
cadab3adf860d6ddd99ed3144edcb6ea0cee3c24 | 3,971 | asm | Assembly | release/src/router/gmp/source/mpn/powerpc64/mode64/addmul_1.asm | zhoutao0712/rtn11pb1 | 09e6b6c7ef4b91be0a9374daeacc3ac9f2fa3a05 | [
"Apache-2.0"
] | 184 | 2020-04-15T14:28:37.000Z | 2020-09-22T15:57:55.000Z | release/src/router/gmp/source/mpn/powerpc64/mode64/addmul_1.asm | zhoutao0712/rtn11pb1 | 09e6b6c7ef4b91be0a9374daeacc3ac9f2fa3a05 | [
"Apache-2.0"
] | 8 | 2019-12-19T19:34:56.000Z | 2022-03-10T10:11:28.000Z | release/src/router/gmp/source/mpn/powerpc64/mode64/addmul_1.asm | zhoutao0712/rtn11pb1 | 09e6b6c7ef4b91be0a9374daeacc3ac9f2fa3a05 | [
"Apache-2.0"
] | 5 | 2020-04-21T19:50:23.000Z | 2020-09-22T10:58:02.000Z | dnl PowerPC-64 mpn_addmul_1 -- Multiply a limb vector with a limb and add
dnl the result to a second limb vector.
dnl Copyright 1999, 2000, 2001, 2003, 2004, 2005, 2006 Free Software
dnl Foundation, Inc.
dnl This file is part of the GNU MP Library.
dnl The GNU MP Library is free software; you can redistribute it and/or modify
dnl it under the terms of the GNU Lesser General Public License as published
dnl by the Free Software Foundation; either version 3 of the License, or (at
dnl your option) any later version.
dnl The GNU MP Library is distributed in the hope that it will be useful, but
dnl WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
dnl or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public
dnl License for more details.
dnl You should have received a copy of the GNU Lesser General Public License
dnl along with the GNU MP Library. If not, see http://www.gnu.org/licenses/.
include(`../config.m4')
C cycles/limb
C POWER3/PPC630: 6-18
C POWER4/PPC970: 8
C POWER5: 8
C TODO
C * Reduce the number of registers used. Some mul destination registers could
C be coalesced.
C * Delay std for preserving registers, and suppress them for n=1.
C * Write faster feed-in code. If nothing else, avoid one or two up updates.
C INPUT PARAMETERS
define(`rp', `r3')
define(`up', `r4')
define(`n', `r5')
define(`vl', `r6')
ASM_START()
PROLOGUE(mpn_addmul_1)
std r31, -8(r1)
std r30, -16(r1)
std r29, -24(r1)
std r28, -32(r1)
std r27, -40(r1)
std r26, -48(r1)
rldicl. r0, n, 0,62 C r0 = n & 3, set cr0
cmpdi cr6, r0, 2
addi n, n, 3 C compute count...
srdi n, n, 2 C ...for ctr
mtctr n C copy count into ctr
beq cr0, L(b00)
blt cr6, L(b01)
beq cr6, L(b10)
L(b11): ld r26, 0(up)
ld r28, 0(rp)
addi up, up, 8
nop
mulld r0, r26, r6
mulhdu r12, r26, r6
addc r0, r0, r28
std r0, 0(rp)
addi rp, rp, 8
b L(fic)
L(b00): ld r26, 0(up)
ld r27, 8(up)
ld r28, 0(rp)
ld r29, 8(rp)
addi up, up, 16
nop
mulld r0, r26, r6
mulhdu r5, r26, r6
mulld r7, r27, r6
mulhdu r8, r27, r6
addc r7, r7, r5
addze r12, r8
addc r0, r0, r28
std r0, 0(rp)
adde r7, r7, r29
std r7, 8(rp)
addi rp, rp, 16
b L(fic)
L(b01): bdnz L(gt1)
ld r26, 0(up)
ld r28, 0(rp)
mulld r0, r26, r6
mulhdu r8, r26, r6
addc r0, r0, r28
std r0, 0(rp)
b L(ret)
L(gt1): ld r26, 0(up)
ld r27, 8(up)
mulld r0, r26, r6
mulhdu r5, r26, r6
ld r26, 16(up)
ld r28, 0(rp)
mulld r7, r27, r6
mulhdu r8, r27, r6
ld r29, 8(rp)
ld r30, 16(rp)
mulld r9, r26, r6
mulhdu r10, r26, r6
addc r7, r7, r5
adde r9, r9, r8
addze r12, r10
addc r0, r0, r28
std r0, 0(rp)
adde r7, r7, r29
std r7, 8(rp)
adde r9, r9, r30
std r9, 16(rp)
addi up, up, 24
addi rp, rp, 24
b L(fic)
L(b10): addic r0, r0, 0
li r12, 0 C cy_limb = 0
L(fic): ld r26, 0(up)
ld r27, 8(up)
addi up, up, 16
bdz L(end)
C registers dying
L(top): mulld r0, r26, r6 C
mulhdu r5, r26, r6 C 26
ld r26, 0(up) C
ld r28, 0(rp) C
mulld r7, r27, r6 C
mulhdu r8, r27, r6 C 27
ld r27, 8(up) C
ld r29, 8(rp) C
adde r0, r0, r12 C 0 12
adde r7, r7, r5 C 5 7
mulld r9, r26, r6 C
mulhdu r10, r26, r6 C 26
ld r26, 16(up) C
ld r30, 16(rp) C
mulld r11, r27, r6 C
mulhdu r12, r27, r6 C 27
ld r27, 24(up) C
ld r31, 24(rp) C
adde r9, r9, r8 C 8 9
adde r11, r11, r10 C 10 11
addze r12, r12 C 12
addc r0, r0, r28 C 0 28
std r0, 0(rp) C 0
adde r7, r7, r29 C 7 29
std r7, 8(rp) C 7
adde r9, r9, r30 C 9 30
std r9, 16(rp) C 9
adde r11, r11, r31 C 11 31
std r11, 24(rp) C 11
addi up, up, 32 C
addi rp, rp, 32 C
bdnz L(top) C
L(end): mulld r0, r26, r6
mulhdu r5, r26, r6
ld r28, 0(rp)
nop
mulld r7, r27, r6
mulhdu r8, r27, r6
ld r29, 8(rp)
nop
adde r0, r0, r12
adde r7, r7, r5
addze r8, r8
addc r0, r0, r28
std r0, 0(rp)
adde r7, r7, r29
std r7, 8(rp)
L(ret): addze r3, r8
ld r31, -8(r1)
ld r30, -16(r1)
ld r29, -24(r1)
ld r28, -32(r1)
ld r27, -40(r1)
ld r26, -48(r1)
blr
EPILOGUE()
| 21.349462 | 79 | 0.641904 |
981f4db0a588f9786b2f0a87f43e6d135f7e15bd | 399 | asm | Assembly | programs/oeis/107/A107239.asm | neoneye/loda | afe9559fb53ee12e3040da54bd6aa47283e0d9ec | [
"Apache-2.0"
] | 22 | 2018-02-06T19:19:31.000Z | 2022-01-17T21:53:31.000Z | programs/oeis/107/A107239.asm | neoneye/loda | afe9559fb53ee12e3040da54bd6aa47283e0d9ec | [
"Apache-2.0"
] | 41 | 2021-02-22T19:00:34.000Z | 2021-08-28T10:47:47.000Z | programs/oeis/107/A107239.asm | neoneye/loda | afe9559fb53ee12e3040da54bd6aa47283e0d9ec | [
"Apache-2.0"
] | 5 | 2021-02-24T21:14:16.000Z | 2021-08-09T19:48:05.000Z | ; A107239: Sum of squares of tribonacci numbers (A000073).
; 0,0,1,2,6,22,71,240,816,2752,9313,31514,106590,360606,1219935,4126960,13961456,47231280,159782161,540539330,1828631430,6186215574,20927817799,70798300288,239508933824,810252920400,2741065994769
lpb $0
mov $2,$0
sub $0,1
seq $2,85697 ; a(n) = T(n)^2, where T(n) = A000073(n) is the n-th tribonacci number.
add $1,$2
lpe
mov $0,$1
| 36.272727 | 195 | 0.73183 |
63f8af29b3759472a584ba395e7448bc0831b835 | 13,861 | asm | Assembly | P6/data_P6_2/beq_bne_test7.asm | alxzzhou/BUAA_CO_2020 | b54bf367081a5a11701ebc3fc78a23494aecca9e | [
"Apache-2.0"
] | 1 | 2022-01-23T09:24:47.000Z | 2022-01-23T09:24:47.000Z | P6/data_P6_2/beq_bne_test7.asm | alxzzhou/BUAA_CO_2020 | b54bf367081a5a11701ebc3fc78a23494aecca9e | [
"Apache-2.0"
] | null | null | null | P6/data_P6_2/beq_bne_test7.asm | alxzzhou/BUAA_CO_2020 | b54bf367081a5a11701ebc3fc78a23494aecca9e | [
"Apache-2.0"
] | null | null | null | lui $1,28668
ori $1,$1,42926
lui $2,52815
ori $2,$2,36460
lui $3,42933
ori $3,$3,18879
lui $4,51096
ori $4,$4,60937
lui $5,23017
ori $5,$5,48169
lui $6,8033
ori $6,$6,35819
mthi $1
mtlo $2
sec0:
nop
nop
nop
bne $3,$2,yes0
nop
no0:addiu $k1,$k1,1
yes0:addiu $k0,$k0,1
sec1:
nop
nop
sltu $2,$3,$3
bne $3,$2,yes1
nop
no1:addiu $k1,$k1,1
yes1:addiu $k0,$k0,1
sec2:
nop
nop
lui $2,7143
bne $3,$2,yes2
nop
no2:addiu $k1,$k1,1
yes2:addiu $k0,$k0,1
sec3:
nop
nop
mflo $2
bne $3,$2,yes3
nop
no3:addiu $k1,$k1,1
yes3:addiu $k0,$k0,1
sec4:
nop
nop
lh $2,2($0)
bne $3,$2,yes4
nop
no4:addiu $k1,$k1,1
yes4:addiu $k0,$k0,1
sec5:
nop
addu $2,$1,$4
nop
bne $3,$2,yes5
nop
no5:addiu $k1,$k1,1
yes5:addiu $k0,$k0,1
sec6:
nop
nor $2,$0,$3
subu $2,$4,$4
bne $3,$2,yes6
nop
no6:addiu $k1,$k1,1
yes6:addiu $k0,$k0,1
sec7:
nop
or $2,$2,$3
slti $2,$3,22155
bne $3,$2,yes7
nop
no7:addiu $k1,$k1,1
yes7:addiu $k0,$k0,1
sec8:
nop
nor $2,$0,$4
mfhi $2
bne $3,$2,yes8
nop
no8:addiu $k1,$k1,1
yes8:addiu $k0,$k0,1
sec9:
nop
nor $2,$1,$1
lhu $2,8($0)
bne $3,$2,yes9
nop
no9:addiu $k1,$k1,1
yes9:addiu $k0,$k0,1
sec10:
nop
ori $2,$5,60579
nop
bne $3,$2,yes10
nop
no10:addiu $k1,$k1,1
yes10:addiu $k0,$k0,1
sec11:
nop
ori $2,$6,33265
addu $2,$0,$3
bne $3,$2,yes11
nop
no11:addiu $k1,$k1,1
yes11:addiu $k0,$k0,1
sec12:
nop
andi $2,$4,10937
addiu $2,$1,19685
bne $3,$2,yes12
nop
no12:addiu $k1,$k1,1
yes12:addiu $k0,$k0,1
sec13:
nop
sltiu $2,$2,-31661
mflo $2
bne $3,$2,yes13
nop
no13:addiu $k1,$k1,1
yes13:addiu $k0,$k0,1
sec14:
nop
andi $2,$3,25605
lb $2,1($0)
bne $3,$2,yes14
nop
no14:addiu $k1,$k1,1
yes14:addiu $k0,$k0,1
sec15:
nop
mfhi $2
nop
bne $3,$2,yes15
nop
no15:addiu $k1,$k1,1
yes15:addiu $k0,$k0,1
sec16:
nop
mfhi $2
or $2,$2,$6
bne $3,$2,yes16
nop
no16:addiu $k1,$k1,1
yes16:addiu $k0,$k0,1
sec17:
nop
mflo $2
slti $2,$3,-19869
bne $3,$2,yes17
nop
no17:addiu $k1,$k1,1
yes17:addiu $k0,$k0,1
sec18:
nop
mflo $2
mflo $2
bne $3,$2,yes18
nop
no18:addiu $k1,$k1,1
yes18:addiu $k0,$k0,1
sec19:
nop
mfhi $2
lhu $2,10($0)
bne $3,$2,yes19
nop
no19:addiu $k1,$k1,1
yes19:addiu $k0,$k0,1
sec20:
nop
lhu $2,10($0)
nop
bne $3,$2,yes20
nop
no20:addiu $k1,$k1,1
yes20:addiu $k0,$k0,1
sec21:
nop
lb $2,10($0)
addu $2,$1,$3
bne $3,$2,yes21
nop
no21:addiu $k1,$k1,1
yes21:addiu $k0,$k0,1
sec22:
nop
lhu $2,2($0)
xori $2,$0,17326
bne $3,$2,yes22
nop
no22:addiu $k1,$k1,1
yes22:addiu $k0,$k0,1
sec23:
nop
lbu $2,4($0)
mflo $2
bne $3,$2,yes23
nop
no23:addiu $k1,$k1,1
yes23:addiu $k0,$k0,1
sec24:
nop
lb $2,10($0)
lw $2,12($0)
bne $3,$2,yes24
nop
no24:addiu $k1,$k1,1
yes24:addiu $k0,$k0,1
sec25:
addu $3,$0,$0
nop
nop
bne $3,$2,yes25
nop
no25:addiu $k1,$k1,1
yes25:addiu $k0,$k0,1
sec26:
xor $3,$3,$2
nop
nor $2,$3,$3
bne $3,$2,yes26
nop
no26:addiu $k1,$k1,1
yes26:addiu $k0,$k0,1
sec27:
sltu $3,$2,$4
nop
lui $2,37321
bne $3,$2,yes27
nop
no27:addiu $k1,$k1,1
yes27:addiu $k0,$k0,1
sec28:
xor $3,$0,$3
nop
mfhi $2
bne $3,$2,yes28
nop
no28:addiu $k1,$k1,1
yes28:addiu $k0,$k0,1
sec29:
xor $3,$5,$2
nop
lbu $2,1($0)
bne $3,$2,yes29
nop
no29:addiu $k1,$k1,1
yes29:addiu $k0,$k0,1
sec30:
addu $3,$4,$4
subu $2,$3,$4
nop
bne $3,$2,yes30
nop
no30:addiu $k1,$k1,1
yes30:addiu $k0,$k0,1
sec31:
nor $3,$5,$5
xor $2,$2,$5
or $2,$3,$3
bne $3,$2,yes31
nop
no31:addiu $k1,$k1,1
yes31:addiu $k0,$k0,1
sec32:
or $3,$3,$3
xor $2,$3,$2
sltiu $2,$5,-19995
bne $3,$2,yes32
nop
no32:addiu $k1,$k1,1
yes32:addiu $k0,$k0,1
sec33:
addu $3,$5,$4
and $2,$5,$3
mfhi $2
bne $3,$2,yes33
nop
no33:addiu $k1,$k1,1
yes33:addiu $k0,$k0,1
sec34:
subu $3,$1,$4
xor $2,$4,$5
lb $2,5($0)
bne $3,$2,yes34
nop
no34:addiu $k1,$k1,1
yes34:addiu $k0,$k0,1
sec35:
nor $3,$2,$4
andi $2,$2,58779
nop
bne $3,$2,yes35
nop
no35:addiu $k1,$k1,1
yes35:addiu $k0,$k0,1
sec36:
addu $3,$3,$6
sltiu $2,$4,14698
nor $2,$5,$4
bne $3,$2,yes36
nop
no36:addiu $k1,$k1,1
yes36:addiu $k0,$k0,1
sec37:
addu $3,$1,$4
addiu $2,$3,-30197
xori $2,$3,5542
bne $3,$2,yes37
nop
no37:addiu $k1,$k1,1
yes37:addiu $k0,$k0,1
sec38:
sltu $3,$3,$5
andi $2,$4,13740
mfhi $2
bne $3,$2,yes38
nop
no38:addiu $k1,$k1,1
yes38:addiu $k0,$k0,1
sec39:
subu $3,$5,$2
ori $2,$5,33116
lb $2,8($0)
bne $3,$2,yes39
nop
no39:addiu $k1,$k1,1
yes39:addiu $k0,$k0,1
sec40:
slt $3,$3,$4
mflo $2
nop
bne $3,$2,yes40
nop
no40:addiu $k1,$k1,1
yes40:addiu $k0,$k0,1
sec41:
and $3,$2,$4
mflo $2
sltu $2,$2,$5
bne $3,$2,yes41
nop
no41:addiu $k1,$k1,1
yes41:addiu $k0,$k0,1
sec42:
addu $3,$0,$2
mfhi $2
ori $2,$3,48386
bne $3,$2,yes42
nop
no42:addiu $k1,$k1,1
yes42:addiu $k0,$k0,1
sec43:
nor $3,$1,$3
mflo $2
mfhi $2
bne $3,$2,yes43
nop
no43:addiu $k1,$k1,1
yes43:addiu $k0,$k0,1
sec44:
xor $3,$6,$4
mflo $2
lw $2,0($0)
bne $3,$2,yes44
nop
no44:addiu $k1,$k1,1
yes44:addiu $k0,$k0,1
sec45:
slt $3,$1,$4
lw $2,4($0)
nop
bne $3,$2,yes45
nop
no45:addiu $k1,$k1,1
yes45:addiu $k0,$k0,1
sec46:
slt $3,$2,$4
lbu $2,16($0)
or $2,$1,$2
bne $3,$2,yes46
nop
no46:addiu $k1,$k1,1
yes46:addiu $k0,$k0,1
sec47:
or $3,$2,$2
lh $2,6($0)
addiu $2,$3,8779
bne $3,$2,yes47
nop
no47:addiu $k1,$k1,1
yes47:addiu $k0,$k0,1
sec48:
nor $3,$3,$3
lhu $2,0($0)
mflo $2
bne $3,$2,yes48
nop
no48:addiu $k1,$k1,1
yes48:addiu $k0,$k0,1
sec49:
or $3,$6,$3
lw $2,16($0)
lh $2,0($0)
bne $3,$2,yes49
nop
no49:addiu $k1,$k1,1
yes49:addiu $k0,$k0,1
sec50:
xori $3,$3,53196
nop
nop
bne $3,$2,yes50
nop
no50:addiu $k1,$k1,1
yes50:addiu $k0,$k0,1
sec51:
sltiu $3,$1,-180
nop
and $2,$3,$1
bne $3,$2,yes51
nop
no51:addiu $k1,$k1,1
yes51:addiu $k0,$k0,1
sec52:
addiu $3,$4,-19244
nop
slti $2,$0,1403
bne $3,$2,yes52
nop
no52:addiu $k1,$k1,1
yes52:addiu $k0,$k0,1
sec53:
ori $3,$2,35678
nop
mfhi $2
bne $3,$2,yes53
nop
no53:addiu $k1,$k1,1
yes53:addiu $k0,$k0,1
sec54:
sltiu $3,$4,-24052
nop
lbu $2,7($0)
bne $3,$2,yes54
nop
no54:addiu $k1,$k1,1
yes54:addiu $k0,$k0,1
sec55:
andi $3,$3,16467
slt $2,$3,$4
nop
bne $3,$2,yes55
nop
no55:addiu $k1,$k1,1
yes55:addiu $k0,$k0,1
sec56:
sltiu $3,$0,-9865
addu $2,$4,$2
or $2,$4,$4
bne $3,$2,yes56
nop
no56:addiu $k1,$k1,1
yes56:addiu $k0,$k0,1
sec57:
ori $3,$1,37825
or $2,$4,$4
lui $2,30583
bne $3,$2,yes57
nop
no57:addiu $k1,$k1,1
yes57:addiu $k0,$k0,1
sec58:
xori $3,$4,47633
nor $2,$5,$3
mflo $2
bne $3,$2,yes58
nop
no58:addiu $k1,$k1,1
yes58:addiu $k0,$k0,1
sec59:
ori $3,$0,10666
addu $2,$5,$5
lbu $2,2($0)
bne $3,$2,yes59
nop
no59:addiu $k1,$k1,1
yes59:addiu $k0,$k0,1
sec60:
lui $3,15670
andi $2,$2,7668
nop
bne $3,$2,yes60
nop
no60:addiu $k1,$k1,1
yes60:addiu $k0,$k0,1
sec61:
ori $3,$5,37131
xori $2,$3,60303
and $2,$3,$5
bne $3,$2,yes61
nop
no61:addiu $k1,$k1,1
yes61:addiu $k0,$k0,1
sec62:
sltiu $3,$1,-21921
sltiu $2,$4,-6808
lui $2,11128
bne $3,$2,yes62
nop
no62:addiu $k1,$k1,1
yes62:addiu $k0,$k0,1
sec63:
sltiu $3,$2,26137
xori $2,$1,28451
mfhi $2
bne $3,$2,yes63
nop
no63:addiu $k1,$k1,1
yes63:addiu $k0,$k0,1
sec64:
andi $3,$3,54664
andi $2,$4,24447
lh $2,4($0)
bne $3,$2,yes64
nop
no64:addiu $k1,$k1,1
yes64:addiu $k0,$k0,1
sec65:
addiu $3,$1,13150
mflo $2
nop
bne $3,$2,yes65
nop
no65:addiu $k1,$k1,1
yes65:addiu $k0,$k0,1
sec66:
addiu $3,$0,-22290
mflo $2
xor $2,$1,$4
bne $3,$2,yes66
nop
no66:addiu $k1,$k1,1
yes66:addiu $k0,$k0,1
sec67:
slti $3,$4,22887
mflo $2
andi $2,$0,11298
bne $3,$2,yes67
nop
no67:addiu $k1,$k1,1
yes67:addiu $k0,$k0,1
sec68:
sltiu $3,$2,-28824
mflo $2
mfhi $2
bne $3,$2,yes68
nop
no68:addiu $k1,$k1,1
yes68:addiu $k0,$k0,1
sec69:
xori $3,$1,12073
mflo $2
lhu $2,10($0)
bne $3,$2,yes69
nop
no69:addiu $k1,$k1,1
yes69:addiu $k0,$k0,1
sec70:
andi $3,$2,58337
lw $2,12($0)
nop
bne $3,$2,yes70
nop
no70:addiu $k1,$k1,1
yes70:addiu $k0,$k0,1
sec71:
slti $3,$6,-30530
lb $2,8($0)
sltu $2,$2,$3
bne $3,$2,yes71
nop
no71:addiu $k1,$k1,1
yes71:addiu $k0,$k0,1
sec72:
slti $3,$6,14749
lb $2,13($0)
addiu $2,$0,21782
bne $3,$2,yes72
nop
no72:addiu $k1,$k1,1
yes72:addiu $k0,$k0,1
sec73:
xori $3,$6,25242
lw $2,12($0)
mfhi $2
bne $3,$2,yes73
nop
no73:addiu $k1,$k1,1
yes73:addiu $k0,$k0,1
sec74:
sltiu $3,$3,-21304
lw $2,12($0)
lh $2,16($0)
bne $3,$2,yes74
nop
no74:addiu $k1,$k1,1
yes74:addiu $k0,$k0,1
sec75:
mfhi $3
nop
nop
bne $3,$2,yes75
nop
no75:addiu $k1,$k1,1
yes75:addiu $k0,$k0,1
sec76:
mfhi $3
nop
and $2,$0,$6
bne $3,$2,yes76
nop
no76:addiu $k1,$k1,1
yes76:addiu $k0,$k0,1
sec77:
mflo $3
nop
slti $2,$3,6579
bne $3,$2,yes77
nop
no77:addiu $k1,$k1,1
yes77:addiu $k0,$k0,1
sec78:
mflo $3
nop
mfhi $2
bne $3,$2,yes78
nop
no78:addiu $k1,$k1,1
yes78:addiu $k0,$k0,1
sec79:
mflo $3
nop
lw $2,8($0)
bne $3,$2,yes79
nop
no79:addiu $k1,$k1,1
yes79:addiu $k0,$k0,1
sec80:
mflo $3
nor $2,$3,$1
nop
bne $3,$2,yes80
nop
no80:addiu $k1,$k1,1
yes80:addiu $k0,$k0,1
sec81:
mflo $3
sltu $2,$5,$2
slt $2,$0,$3
bne $3,$2,yes81
nop
no81:addiu $k1,$k1,1
yes81:addiu $k0,$k0,1
sec82:
mfhi $3
slt $2,$0,$3
sltiu $2,$4,20591
bne $3,$2,yes82
nop
no82:addiu $k1,$k1,1
yes82:addiu $k0,$k0,1
sec83:
mfhi $3
sltu $2,$1,$3
mfhi $2
bne $3,$2,yes83
nop
no83:addiu $k1,$k1,1
yes83:addiu $k0,$k0,1
sec84:
mflo $3
subu $2,$3,$3
lbu $2,2($0)
bne $3,$2,yes84
nop
no84:addiu $k1,$k1,1
yes84:addiu $k0,$k0,1
sec85:
mfhi $3
lui $2,42561
nop
bne $3,$2,yes85
nop
no85:addiu $k1,$k1,1
yes85:addiu $k0,$k0,1
sec86:
mflo $3
ori $2,$3,53174
subu $2,$2,$2
bne $3,$2,yes86
nop
no86:addiu $k1,$k1,1
yes86:addiu $k0,$k0,1
sec87:
mflo $3
xori $2,$4,8991
andi $2,$6,38820
bne $3,$2,yes87
nop
no87:addiu $k1,$k1,1
yes87:addiu $k0,$k0,1
sec88:
mflo $3
sltiu $2,$0,17670
mfhi $2
bne $3,$2,yes88
nop
no88:addiu $k1,$k1,1
yes88:addiu $k0,$k0,1
sec89:
mflo $3
sltiu $2,$4,-4805
lhu $2,0($0)
bne $3,$2,yes89
nop
no89:addiu $k1,$k1,1
yes89:addiu $k0,$k0,1
sec90:
mflo $3
mflo $2
nop
bne $3,$2,yes90
nop
no90:addiu $k1,$k1,1
yes90:addiu $k0,$k0,1
sec91:
mfhi $3
mflo $2
slt $2,$5,$2
bne $3,$2,yes91
nop
no91:addiu $k1,$k1,1
yes91:addiu $k0,$k0,1
sec92:
mflo $3
mflo $2
slti $2,$5,-11720
bne $3,$2,yes92
nop
no92:addiu $k1,$k1,1
yes92:addiu $k0,$k0,1
sec93:
mflo $3
mflo $2
mflo $2
bne $3,$2,yes93
nop
no93:addiu $k1,$k1,1
yes93:addiu $k0,$k0,1
sec94:
mflo $3
mflo $2
lh $2,16($0)
bne $3,$2,yes94
nop
no94:addiu $k1,$k1,1
yes94:addiu $k0,$k0,1
sec95:
mflo $3
lbu $2,9($0)
nop
bne $3,$2,yes95
nop
no95:addiu $k1,$k1,1
yes95:addiu $k0,$k0,1
sec96:
mfhi $3
lw $2,8($0)
nor $2,$5,$4
bne $3,$2,yes96
nop
no96:addiu $k1,$k1,1
yes96:addiu $k0,$k0,1
sec97:
mflo $3
lw $2,16($0)
ori $2,$2,4610
bne $3,$2,yes97
nop
no97:addiu $k1,$k1,1
yes97:addiu $k0,$k0,1
sec98:
mflo $3
lw $2,4($0)
mfhi $2
bne $3,$2,yes98
nop
no98:addiu $k1,$k1,1
yes98:addiu $k0,$k0,1
sec99:
mflo $3
lbu $2,9($0)
lb $2,7($0)
bne $3,$2,yes99
nop
no99:addiu $k1,$k1,1
yes99:addiu $k0,$k0,1
sec100:
lh $3,10($0)
nop
nop
bne $3,$2,yes100
nop
no100:addiu $k1,$k1,1
yes100:addiu $k0,$k0,1
sec101:
lbu $3,8($0)
nop
addu $2,$1,$2
bne $3,$2,yes101
nop
no101:addiu $k1,$k1,1
yes101:addiu $k0,$k0,1
sec102:
lb $3,5($0)
nop
sltiu $2,$4,10138
bne $3,$2,yes102
nop
no102:addiu $k1,$k1,1
yes102:addiu $k0,$k0,1
sec103:
lbu $3,14($0)
nop
mflo $2
bne $3,$2,yes103
nop
no103:addiu $k1,$k1,1
yes103:addiu $k0,$k0,1
sec104:
lhu $3,0($0)
nop
lbu $2,12($0)
bne $3,$2,yes104
nop
no104:addiu $k1,$k1,1
yes104:addiu $k0,$k0,1
sec105:
lhu $3,10($0)
xor $2,$1,$2
nop
bne $3,$2,yes105
nop
no105:addiu $k1,$k1,1
yes105:addiu $k0,$k0,1
sec106:
lb $3,2($0)
or $2,$2,$5
and $2,$4,$3
bne $3,$2,yes106
nop
no106:addiu $k1,$k1,1
yes106:addiu $k0,$k0,1
sec107:
lbu $3,10($0)
sltu $2,$6,$0
ori $2,$3,40397
bne $3,$2,yes107
nop
no107:addiu $k1,$k1,1
yes107:addiu $k0,$k0,1
sec108:
lb $3,1($0)
or $2,$1,$3
mflo $2
bne $3,$2,yes108
nop
no108:addiu $k1,$k1,1
yes108:addiu $k0,$k0,1
sec109:
lbu $3,11($0)
slt $2,$1,$3
lh $2,12($0)
bne $3,$2,yes109
nop
no109:addiu $k1,$k1,1
yes109:addiu $k0,$k0,1
sec110:
lb $3,2($0)
slti $2,$2,24722
nop
bne $3,$2,yes110
nop
no110:addiu $k1,$k1,1
yes110:addiu $k0,$k0,1
sec111:
lw $3,8($0)
xori $2,$2,15077
and $2,$4,$6
bne $3,$2,yes111
nop
no111:addiu $k1,$k1,1
yes111:addiu $k0,$k0,1
sec112:
lb $3,6($0)
ori $2,$1,42826
lui $2,17004
bne $3,$2,yes112
nop
no112:addiu $k1,$k1,1
yes112:addiu $k0,$k0,1
sec113:
lh $3,0($0)
ori $2,$3,55351
mfhi $2
bne $3,$2,yes113
nop
no113:addiu $k1,$k1,1
yes113:addiu $k0,$k0,1
sec114:
lb $3,2($0)
slti $2,$3,-6091
lbu $2,11($0)
bne $3,$2,yes114
nop
no114:addiu $k1,$k1,1
yes114:addiu $k0,$k0,1
sec115:
lh $3,16($0)
mflo $2
nop
bne $3,$2,yes115
nop
no115:addiu $k1,$k1,1
yes115:addiu $k0,$k0,1
sec116:
lbu $3,1($0)
mflo $2
and $2,$5,$0
bne $3,$2,yes116
nop
no116:addiu $k1,$k1,1
yes116:addiu $k0,$k0,1
sec117:
lh $3,4($0)
mfhi $2
sltiu $2,$1,-9535
bne $3,$2,yes117
nop
no117:addiu $k1,$k1,1
yes117:addiu $k0,$k0,1
sec118:
lh $3,8($0)
mfhi $2
mfhi $2
bne $3,$2,yes118
nop
no118:addiu $k1,$k1,1
yes118:addiu $k0,$k0,1
sec119:
lbu $3,3($0)
mflo $2
lw $2,4($0)
bne $3,$2,yes119
nop
no119:addiu $k1,$k1,1
yes119:addiu $k0,$k0,1
sec120:
lw $3,4($0)
lbu $2,12($0)
nop
bne $3,$2,yes120
nop
no120:addiu $k1,$k1,1
yes120:addiu $k0,$k0,1
sec121:
lh $3,4($0)
lh $2,14($0)
subu $2,$1,$1
bne $3,$2,yes121
nop
no121:addiu $k1,$k1,1
yes121:addiu $k0,$k0,1
sec122:
lh $3,10($0)
lbu $2,12($0)
ori $2,$1,45629
bne $3,$2,yes122
nop
no122:addiu $k1,$k1,1
yes122:addiu $k0,$k0,1
sec123:
lhu $3,14($0)
lhu $2,14($0)
mflo $2
bne $3,$2,yes123
nop
no123:addiu $k1,$k1,1
yes123:addiu $k0,$k0,1
sec124:
lb $3,7($0)
lhu $2,4($0)
lbu $2,13($0)
bne $3,$2,yes124
nop
no124:addiu $k1,$k1,1
yes124:addiu $k0,$k0,1
| 12.158772 | 22 | 0.603564 |
4faf35aecc69e6c9b458451a80575445c4d14978 | 691 | asm | Assembly | oeis/042/A042414.asm | neoneye/loda-programs | 84790877f8e6c2e821b183d2e334d612045d29c0 | [
"Apache-2.0"
] | 11 | 2021-08-22T19:44:55.000Z | 2022-03-20T16:47:57.000Z | oeis/042/A042414.asm | neoneye/loda-programs | 84790877f8e6c2e821b183d2e334d612045d29c0 | [
"Apache-2.0"
] | 9 | 2021-08-29T13:15:54.000Z | 2022-03-09T19:52:31.000Z | oeis/042/A042414.asm | neoneye/loda-programs | 84790877f8e6c2e821b183d2e334d612045d29c0 | [
"Apache-2.0"
] | 3 | 2021-08-22T20:56:47.000Z | 2021-09-29T06:26:12.000Z | ; A042414: Numerators of continued fraction convergents to sqrt(735).
; Submitted by Jon Maiga
; 27,244,13203,119071,6443037,58106404,3144188853,28355806081,1534357717227,13837575261124,748763421817923,6752708371622431,365395015489429197,3295307847776485204,178312018795419630213,1608103477006553157121,87015899777149290114747,784751201471350164189844,42463580779230058156366323,382956978214541873571486751,20722140404364491231016650877,186882220617494962952721344644,10112362053749092490677969261653,91198140704359327379054444699521,4934811960089152770959617983035787
add $0,1
mov $3,1
lpb $0
sub $0,1
add $2,$3
mov $3,$1
mov $1,$2
dif $2,6
mul $2,27
add $3,$2
lpe
mov $0,$3
| 40.647059 | 473 | 0.839363 |
fdcf61de118fd7874eca242f272f7356b3e840e4 | 353 | asm | Assembly | programs/oeis/047/A047300.asm | neoneye/loda | afe9559fb53ee12e3040da54bd6aa47283e0d9ec | [
"Apache-2.0"
] | 22 | 2018-02-06T19:19:31.000Z | 2022-01-17T21:53:31.000Z | programs/oeis/047/A047300.asm | neoneye/loda | afe9559fb53ee12e3040da54bd6aa47283e0d9ec | [
"Apache-2.0"
] | 41 | 2021-02-22T19:00:34.000Z | 2021-08-28T10:47:47.000Z | programs/oeis/047/A047300.asm | neoneye/loda | afe9559fb53ee12e3040da54bd6aa47283e0d9ec | [
"Apache-2.0"
] | 5 | 2021-02-24T21:14:16.000Z | 2021-08-09T19:48:05.000Z | ; A047300: Numbers that are congruent to {2, 3, 4, 6} mod 7.
; 2,3,4,6,9,10,11,13,16,17,18,20,23,24,25,27,30,31,32,34,37,38,39,41,44,45,46,48,51,52,53,55,58,59,60,62,65,66,67,69,72,73,74,76,79,80,81,83,86,87,88,90,93,94,95,97,100,101,102,104,107,108,109,111
mul $0,7
add $0,7
mov $1,$0
div $1,2
sub $0,$1
div $0,2
mod $1,2
add $1,$0
mov $0,$1
sub $0,1
| 25.214286 | 196 | 0.626062 |
3d5ed7333243b9c50da61667c3c501aafa95cce6 | 678 | asm | Assembly | oeis/246/A246831.asm | neoneye/loda-programs | 84790877f8e6c2e821b183d2e334d612045d29c0 | [
"Apache-2.0"
] | 11 | 2021-08-22T19:44:55.000Z | 2022-03-20T16:47:57.000Z | oeis/246/A246831.asm | neoneye/loda-programs | 84790877f8e6c2e821b183d2e334d612045d29c0 | [
"Apache-2.0"
] | 9 | 2021-08-29T13:15:54.000Z | 2022-03-09T19:52:31.000Z | oeis/246/A246831.asm | neoneye/loda-programs | 84790877f8e6c2e821b183d2e334d612045d29c0 | [
"Apache-2.0"
] | 3 | 2021-08-22T20:56:47.000Z | 2021-09-29T06:26:12.000Z | ; A246831: a(n) is the concatenation of n and 3n in binary.
; Submitted by Jon Maiga
; 0,7,22,57,76,95,210,245,280,315,350,737,804,871,938,1005,1072,1139,1206,1273,1340,1407,2882,3013,3144,3275,3406,3537,3668,3799,3930,4061,4192,4323,4454,4585,4716,4847,4978,5109,5240,5371,5502,11137,11396,11655,11914,12173,12432,12691,12950,13209,13468,13727,13986,14245,14504,14763,15022,15281,15540,15799,16058,16317,16576,16835,17094,17353,17612,17871,18130,18389,18648,18907,19166,19425,19684,19943,20202,20461,20720,20979,21238,21497,21756,22015,44290,44805,45320,45835,46350,46865,47380,47895
mov $2,$0
mul $0,3
mov $3,$0
lpb $0
div $0,2
mul $2,2
lpe
add $1,$2
add $1,$3
mov $0,$1
| 45.2 | 499 | 0.756637 |
4c2dbb17f64eb7758bbf84f596e25213feb4a9b7 | 488 | asm | Assembly | u7bg/suppressBarks.asm | JohnGlassmyer/UltimaHacks | f9a114e00c4a1edf1ac7792b465feff2c9b88ced | [
"MIT"
] | 68 | 2018-03-04T22:34:22.000Z | 2022-03-10T15:18:32.000Z | u7bg/suppressBarks.asm | ptrie/UltimaHacks | 2c3557a86d94ad8b54b26bc395b9aed1604f8be1 | [
"MIT"
] | 19 | 2018-11-20T04:06:49.000Z | 2021-11-08T16:37:10.000Z | u7bg/suppressBarks.asm | ptrie/UltimaHacks | 2c3557a86d94ad8b54b26bc395b9aed1604f8be1 | [
"MIT"
] | 4 | 2020-09-01T17:57:36.000Z | 2022-01-04T20:51:11.000Z | %include "include/u7bg-all-includes.asm"
%define barkWithoutDialogs_ibo di
defineAddress 212, 0x0258, barkWithoutDialogs_getItemZ
defineAddress 212, 0x0279, barkWithoutDialogs_getItemZ_end
defineAddress 212, 0x027F, barkWithoutDialogs_dontBark
%define barkWithDialogs_ibo [di]
defineAddress 340, 0x1A83, barkWithDialogs_getItemZ
defineAddress 340, 0x1A9E, barkWithDialogs_getItemZ_end
defineAddress 340, 0x1B27, barkWithDialogs_dontBark
%include "../u7-common/patch-suppressBarks.asm"
| 34.857143 | 58 | 0.856557 |
8d7114e931930d145bba1680af7f0330a82a02d6 | 5,581 | asm | Assembly | Transynther/x86/_processed/NONE/_xt_/i9-9900K_12_0xca_notsx.log_21829_1676.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_notsx.log_21829_1676.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_notsx.log_21829_1676.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 %rbp
push %rbx
push %rcx
push %rdi
push %rdx
push %rsi
lea addresses_UC_ht+0x2370, %rsi
lea addresses_WC_ht+0x60a8, %rdi
nop
nop
nop
nop
xor %r12, %r12
mov $126, %rcx
rep movsw
nop
nop
nop
nop
nop
and %rbp, %rbp
lea addresses_UC_ht+0xcf70, %rbx
nop
and $20545, %rdx
mov (%rbx), %bp
cmp $35355, %rdx
lea addresses_normal_ht+0xd1ac, %r12
nop
nop
nop
sub %rdx, %rdx
mov $0x6162636465666768, %rdi
movq %rdi, (%r12)
nop
nop
cmp %rbx, %rbx
pop %rsi
pop %rdx
pop %rdi
pop %rcx
pop %rbx
pop %rbp
pop %r12
ret
.global s_faulty_load
s_faulty_load:
push %r10
push %r12
push %r13
push %rax
push %rbx
push %rdx
push %rsi
// Load
lea addresses_US+0x14f9d, %rbx
cmp $19310, %rax
mov (%rbx), %r12w
nop
nop
nop
nop
add $55634, %rbx
// Store
lea addresses_US+0x6fb0, %rbx
nop
nop
nop
nop
nop
add %rsi, %rsi
movb $0x51, (%rbx)
nop
cmp %r13, %r13
// Store
lea addresses_RW+0x2290, %rbx
clflush (%rbx)
nop
xor %rsi, %rsi
movw $0x5152, (%rbx)
nop
nop
nop
nop
nop
and $32026, %rdx
// Store
lea addresses_WC+0x70, %rsi
dec %r13
mov $0x5152535455565758, %r12
movq %r12, (%rsi)
nop
xor $22153, %r12
// Faulty Load
lea addresses_PSE+0x1a370, %rax
nop
add %rbx, %rbx
mov (%rax), %dx
lea oracles, %r10
and $0xff, %rdx
shlq $12, %rdx
mov (%r10,%rdx,1), %rdx
pop %rsi
pop %rdx
pop %rbx
pop %rax
pop %r13
pop %r12
pop %r10
ret
/*
<gen_faulty_load>
[REF]
{'OP': 'LOAD', 'src': {'same': False, 'type': 'addresses_PSE', 'NT': False, 'AVXalign': False, 'size': 4, 'congruent': 0}}
{'OP': 'LOAD', 'src': {'same': False, 'type': 'addresses_US', 'NT': False, 'AVXalign': False, 'size': 2, 'congruent': 0}}
{'OP': 'STOR', 'dst': {'same': False, 'type': 'addresses_US', 'NT': False, 'AVXalign': False, 'size': 1, 'congruent': 5}}
{'OP': 'STOR', 'dst': {'same': False, 'type': 'addresses_RW', 'NT': False, 'AVXalign': False, 'size': 2, 'congruent': 3}}
{'OP': 'STOR', 'dst': {'same': False, 'type': 'addresses_WC', 'NT': False, 'AVXalign': False, 'size': 8, 'congruent': 8}}
[Faulty Load]
{'OP': 'LOAD', 'src': {'same': True, 'type': 'addresses_PSE', 'NT': False, 'AVXalign': False, 'size': 2, 'congruent': 0}}
<gen_prepare_buffer>
{'OP': 'REPM', 'src': {'same': False, 'congruent': 8, 'type': 'addresses_UC_ht'}, 'dst': {'same': False, 'congruent': 3, 'type': 'addresses_WC_ht'}}
{'OP': 'LOAD', 'src': {'same': True, 'type': 'addresses_UC_ht', 'NT': False, 'AVXalign': False, 'size': 2, 'congruent': 10}}
{'OP': 'STOR', 'dst': {'same': False, 'type': 'addresses_normal_ht', 'NT': False, 'AVXalign': False, 'size': 8, 'congruent': 2}}
{'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
*/
| 40.737226 | 2,999 | 0.655617 |
32e7fbedd1e40e259587dc4bdf8c5bfa14034339 | 12,239 | asm | Assembly | engine/graphics-text.asm | richard42/dynosprite | 0b83f640a63656087653266baa2ec2499a39538d | [
"BSD-2-Clause"
] | 10 | 2015-04-16T20:48:06.000Z | 2021-09-07T02:08:30.000Z | engine/graphics-text.asm | jamieleecho/space-bandits | b0f45c4d6e8a2bbf8d1653b7b3c10059fa9ff13d | [
"BSD-2-Clause"
] | 1 | 2016-12-04T23:18:42.000Z | 2016-12-05T01:17:49.000Z | engine/graphics-text.asm | jamieleecho/space-bandits | b0f45c4d6e8a2bbf8d1653b7b3c10059fa9ff13d | [
"BSD-2-Clause"
] | 8 | 2015-01-04T17:05:42.000Z | 2021-01-31T01:46:13.000Z | *********************************************************************************
* DynoSprite - graphics-text.asm
* Copyright (c) 2013, Richard Goedeken
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met:
*
* * Redistributions of source code must retain the above copyright notice, this
* list of conditions and the following disclaimer.
*
* * Redistributions in binary form must reproduce the above copyright notice,
* this list of conditions and the following disclaimer in the documentation
* and/or other materials provided with the distribution.
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
* AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
* IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
* DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE
* FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
* DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
* SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
* CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
* OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
* OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*********************************************************************************
***********************************************************
* Gfx_DrawTextLine:
*
* - IN: A=Y coordinate in rows (0-199)
* B=X coordinate in bytes (pixel pairs, 0-159)
* X=pointer to NULL-terminated string
* U=color (4 bits)
* - OUT: N/A
* - Trashed: A,B,X,Y,U
***********************************************************
*
Gfx_DrawTextLine_Back
pshs x
jsr Gfx_GetPixelAddress_Back * start by getting starting memory location
bra MapScreenWindow@
Gfx_DrawTextLine
pshs x
jsr Gfx_GetPixelAddress_Front * start by getting starting memory location
MapScreenWindow@
tfr a,b
incb
std $FFA3 * map screen buffer to $6000-$9FFF
leay $6000,y * Y now points to starting destination byte
tfr u,d * color is in 4 low bits of B
stb ColorMaskVal@+3
lslb
lslb
lslb
lslb
stb ColorMaskVal@+5
orb ColorMaskVal@+3
stb ColorMaskVal@+7
LetterLoop@
puls u
ldb ,u+ * get next character
bne > * if non-0 character, continue forward
rts * otherwise we're done
*
* Locals
ColorMaskVal@ fcb $ff,$00,$f0,$00,$0f,$00,$00,$00
RowCounter@ rmb 1
*
! pshs u
subb #$20 * first printable character map is 32
ldx #Gfx_FontData
ldu #ColorMaskVal@
lda #13
mul
ADD_D_TO_X * X is pointer to 8x13 bitmap for current character
lda #13
sta RowCounter@
RowLoop@
lda ,x
anda #$c0
beq SkipByte0@ * skip this byte
lsla
rola
rola
rola
ldb ,y
andb a,u
inca
orb a,u
stb ,y
SkipByte0@
lda ,x
anda #$30
beq SkipByte1@ * skip this byte
lsra
lsra
lsra
ldb 1,y
andb a,u
inca
orb a,u
stb 1,y
SkipByte1@
lda ,x
anda #$0c
beq SkipByte2@ * skip this byte
lsra
ldb 2,y
andb a,u
inca
orb a,u
stb 2,y
SkipByte2@
lda ,x
anda #$03
beq SkipByte3@ * skip this byte
lsla
ldb 3,y
andb a,u
inca
orb a,u
! stb 3,y
SkipByte3@
leax 1,x * advance bitmap pointer to next row
leay 256,y * advance destination pixel pointer to next line
dec RowCounter@
bne RowLoop@
leay -3324,y * move pixel pointer up 13 rows and right 8 pixels (4 bytes)
bra LetterLoop@ * do next character in line
* font data were generated with: hexdump -e '" fcb " 16/1 "$%02X," "\n"' ~/Desktop/pgcfont.bin > ../font.asm
Gfx_FontData
fcb $00,$00,$00,$00,$00,$00,$00,$00,$00,$00,$00,$00,$00
fcb $00,$00,$18,$3C,$3C,$3C,$18,$18,$00,$18,$18,$00,$00
fcb $00,$66,$66,$66,$24,$00,$00,$00,$00,$00,$00,$00,$00
fcb $00,$00,$6C,$6C,$FE,$6C,$6C,$6C,$FE,$6C,$6C,$00,$00
fcb $18,$18,$7C,$C6,$C2,$C0,$7C,$06,$86,$C6,$7C,$18,$18
fcb $00,$00,$00,$00,$C2,$C6,$0C,$18,$30,$66,$C6,$00,$00
fcb $00,$00,$38,$6C,$6C,$38,$76,$DC,$CC,$CC,$76,$00,$00
fcb $00,$30,$30,$30,$60,$00,$00,$00,$00,$00,$00,$00,$00
fcb $00,$00,$0C,$18,$30,$30,$30,$30,$30,$18,$0C,$00,$00
fcb $00,$00,$30,$18,$0C,$0C,$0C,$0C,$0C,$18,$30,$00,$00
fcb $00,$00,$00,$00,$66,$3C,$FF,$3C,$66,$00,$00,$00,$00
fcb $00,$00,$00,$00,$18,$18,$7E,$18,$18,$00,$00,$00,$00
fcb $00,$00,$00,$00,$00,$00,$00,$00,$18,$18,$18,$30,$00
fcb $00,$00,$00,$00,$00,$00,$FE,$00,$00,$00,$00,$00,$00
fcb $00,$00,$00,$00,$00,$00,$00,$00,$00,$18,$18,$00,$00
fcb $00,$00,$02,$06,$0C,$18,$30,$60,$C0,$80,$00,$00,$00
fcb $00,$00,$7C,$C6,$CE,$DE,$F6,$E6,$C6,$C6,$7C,$00,$00
fcb $00,$00,$18,$38,$78,$18,$18,$18,$18,$18,$7E,$00,$00
fcb $00,$00,$7C,$C6,$06,$0C,$18,$30,$60,$C6,$FE,$00,$00
fcb $00,$00,$7C,$C6,$06,$06,$3C,$06,$06,$C6,$7C,$00,$00
fcb $00,$00,$0C,$1C,$3C,$6C,$CC,$FE,$0C,$0C,$1E,$00,$00
fcb $00,$00,$FE,$C0,$C0,$C0,$FC,$06,$06,$C6,$7C,$00,$00
fcb $00,$00,$38,$60,$C0,$C0,$FC,$C6,$C6,$C6,$7C,$00,$00
fcb $00,$00,$FE,$C6,$06,$0C,$18,$30,$30,$30,$30,$00,$00
fcb $00,$00,$7C,$C6,$C6,$C6,$7C,$C6,$C6,$C6,$7C,$00,$00
fcb $00,$00,$7C,$C6,$C6,$C6,$7E,$06,$06,$0C,$78,$00,$00
fcb $00,$00,$00,$18,$18,$00,$00,$00,$18,$18,$00,$00,$00
fcb $00,$00,$00,$18,$18,$00,$00,$00,$18,$18,$30,$00,$00
fcb $00,$00,$06,$0C,$18,$30,$60,$30,$18,$0C,$06,$00,$00
fcb $00,$00,$00,$00,$00,$7E,$00,$00,$7E,$00,$00,$00,$00
fcb $00,$00,$60,$30,$18,$0C,$06,$0C,$18,$30,$60,$00,$00
fcb $00,$00,$7C,$C6,$C6,$0C,$18,$18,$00,$18,$18,$00,$00
fcb $00,$00,$7C,$C6,$C6,$DE,$DE,$DE,$DC,$C0,$7C,$00,$00
fcb $00,$00,$10,$38,$6C,$C6,$C6,$FE,$C6,$C6,$C6,$00,$00
fcb $00,$00,$FC,$66,$66,$66,$7C,$66,$66,$66,$FC,$00,$00
fcb $00,$00,$3C,$66,$C2,$C0,$C0,$C0,$C2,$66,$3C,$00,$00
fcb $00,$00,$F8,$6C,$66,$66,$66,$66,$66,$6C,$F8,$00,$00
fcb $00,$00,$FE,$66,$62,$68,$78,$68,$62,$66,$FE,$00,$00
fcb $00,$00,$FE,$66,$62,$68,$78,$68,$60,$60,$F0,$00,$00
fcb $00,$00,$3C,$66,$C2,$C0,$C0,$DE,$C6,$66,$3A,$00,$00
fcb $00,$00,$C6,$C6,$C6,$C6,$FE,$C6,$C6,$C6,$C6,$00,$00
fcb $00,$00,$3C,$18,$18,$18,$18,$18,$18,$18,$3C,$00,$00
fcb $00,$00,$1E,$0C,$0C,$0C,$0C,$0C,$CC,$CC,$78,$00,$00
fcb $00,$00,$E6,$66,$6C,$6C,$78,$6C,$6C,$66,$E6,$00,$00
fcb $00,$00,$F0,$60,$60,$60,$60,$60,$62,$66,$FE,$00,$00
fcb $00,$00,$C6,$EE,$FE,$FE,$D6,$C6,$C6,$C6,$C6,$00,$00
fcb $00,$00,$C6,$E6,$F6,$FE,$DE,$CE,$C6,$C6,$C6,$00,$00
fcb $00,$00,$38,$6C,$C6,$C6,$C6,$C6,$C6,$6C,$38,$00,$00
fcb $00,$00,$FC,$66,$66,$66,$7C,$60,$60,$60,$F0,$00,$00
fcb $00,$00,$7C,$C6,$C6,$C6,$C6,$D6,$DE,$7C,$0C,$0E,$00
fcb $00,$00,$FC,$66,$66,$66,$7C,$6C,$66,$66,$E6,$00,$00
fcb $00,$00,$7C,$C6,$C6,$60,$38,$0C,$C6,$C6,$7C,$00,$00
fcb $00,$00,$7E,$7E,$5A,$18,$18,$18,$18,$18,$3C,$00,$00
fcb $00,$00,$C6,$C6,$C6,$C6,$C6,$C6,$C6,$C6,$7C,$00,$00
fcb $00,$00,$C6,$C6,$C6,$C6,$C6,$C6,$6C,$38,$10,$00,$00
fcb $00,$00,$C6,$C6,$C6,$C6,$D6,$D6,$FE,$7C,$6C,$00,$00
fcb $00,$00,$C6,$C6,$6C,$38,$38,$38,$6C,$C6,$C6,$00,$00
fcb $00,$00,$66,$66,$66,$66,$3C,$18,$18,$18,$3C,$00,$00
fcb $00,$00,$FE,$C6,$8C,$18,$30,$60,$C2,$C6,$FE,$00,$00
fcb $00,$00,$3C,$30,$30,$30,$30,$30,$30,$30,$3C,$00,$00
fcb $00,$00,$80,$C0,$E0,$70,$38,$1C,$0E,$06,$02,$00,$00
fcb $00,$00,$3C,$0C,$0C,$0C,$0C,$0C,$0C,$0C,$3C,$00,$00
fcb $10,$38,$6C,$C6,$00,$00,$00,$00,$00,$00,$00,$00,$00
fcb $00,$00,$00,$00,$00,$00,$00,$00,$00,$00,$00,$00,$FF
fcb $30,$30,$18,$00,$00,$00,$00,$00,$00,$00,$00,$00,$00
fcb $00,$00,$00,$00,$00,$78,$0C,$7C,$CC,$CC,$76,$00,$00
fcb $00,$00,$E0,$60,$60,$78,$6C,$66,$66,$66,$7C,$00,$00
fcb $00,$00,$00,$00,$00,$7C,$C6,$C0,$C0,$C6,$7C,$00,$00
fcb $00,$00,$1C,$0C,$0C,$3C,$6C,$CC,$CC,$CC,$76,$00,$00
fcb $00,$00,$00,$00,$00,$7C,$C6,$FE,$C0,$C6,$7C,$00,$00
fcb $00,$00,$38,$6C,$64,$60,$F0,$60,$60,$60,$F0,$00,$00
fcb $00,$00,$00,$00,$00,$76,$CC,$CC,$CC,$7C,$0C,$CC,$78
fcb $00,$00,$E0,$60,$60,$6C,$76,$66,$66,$66,$E6,$00,$00
fcb $00,$00,$18,$18,$00,$38,$18,$18,$18,$18,$3C,$00,$00
fcb $00,$00,$06,$06,$00,$0E,$06,$06,$06,$06,$66,$66,$3C
fcb $00,$00,$E0,$60,$60,$66,$6C,$78,$6C,$66,$E6,$00,$00
fcb $00,$00,$38,$18,$18,$18,$18,$18,$18,$18,$3C,$00,$00
fcb $00,$00,$00,$00,$00,$EC,$FE,$D6,$D6,$D6,$C6,$00,$00
fcb $00,$00,$00,$00,$00,$DC,$66,$66,$66,$66,$66,$00,$00
fcb $00,$00,$00,$00,$00,$7C,$C6,$C6,$C6,$C6,$7C,$00,$00
fcb $00,$00,$00,$00,$00,$DC,$66,$66,$66,$7C,$60,$60,$F0
fcb $00,$00,$00,$00,$00,$76,$CC,$CC,$CC,$7C,$0C,$0C,$1E
fcb $00,$00,$00,$00,$00,$DC,$76,$66,$60,$60,$F0,$00,$00
fcb $00,$00,$00,$00,$00,$7C,$C6,$70,$1C,$C6,$7C,$00,$00
fcb $00,$00,$10,$30,$30,$FC,$30,$30,$30,$36,$1C,$00,$00
fcb $00,$00,$00,$00,$00,$CC,$CC,$CC,$CC,$CC,$76,$00,$00
fcb $00,$00,$00,$00,$00,$66,$66,$66,$66,$3C,$18,$00,$00
fcb $00,$00,$00,$00,$00,$C6,$C6,$D6,$D6,$FE,$6C,$00,$00
fcb $00,$00,$00,$00,$00,$C6,$6C,$38,$38,$6C,$C6,$00,$00
fcb $00,$00,$00,$00,$00,$C6,$C6,$C6,$C6,$7E,$06,$0C,$F8
fcb $00,$00,$00,$00,$00,$FE,$CC,$18,$30,$66,$FE,$00,$00
fcb $00,$00,$0E,$18,$18,$18,$70,$18,$18,$18,$0E,$00,$00
fcb $00,$00,$18,$18,$18,$18,$00,$18,$18,$18,$18,$00,$00
fcb $00,$00,$70,$18,$18,$18,$0E,$18,$18,$18,$70,$00,$00
fcb $00,$00,$76,$DC,$00,$00,$00,$00,$00,$00,$00,$00,$00
fcb $00,$00,$00,$00,$10,$38,$6C,$C6,$C6,$FE,$00,$00,$00
| 52.982684 | 135 | 0.430264 |
9be25efa6eadcce7fd6c956c8ba5ff4c189e471e | 4,571 | asm | Assembly | Transynther/x86/_processed/NC/_st_4k_sm_/i7-8650U_0xd2_notsx.log_2_1377.asm | ljhsiun2/medusa | 67d769b8a2fb42c538f10287abaf0e6dbb463f0c | [
"MIT"
] | 9 | 2020-08-13T19:41:58.000Z | 2022-03-30T12:22:51.000Z | Transynther/x86/_processed/NC/_st_4k_sm_/i7-8650U_0xd2_notsx.log_2_1377.asm | ljhsiun2/medusa | 67d769b8a2fb42c538f10287abaf0e6dbb463f0c | [
"MIT"
] | 1 | 2021-04-29T06:29:35.000Z | 2021-05-13T21:02:30.000Z | Transynther/x86/_processed/NC/_st_4k_sm_/i7-8650U_0xd2_notsx.log_2_1377.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 %r14
push %r15
push %rcx
push %rdi
push %rdx
push %rsi
lea addresses_UC_ht+0x1994a, %rsi
lea addresses_WT_ht+0x3012, %rdi
clflush (%rsi)
xor $6509, %r12
mov $77, %rcx
rep movsq
nop
nop
nop
nop
nop
sub $43801, %r14
lea addresses_UC_ht+0x8412, %rsi
lea addresses_WT_ht+0xe2d2, %rdi
clflush (%rsi)
nop
nop
xor $53550, %rdx
mov $50, %rcx
rep movsq
and %r14, %r14
lea addresses_D_ht+0xe5ca, %r12
nop
nop
nop
nop
cmp $47296, %r15
mov $0x6162636465666768, %r14
movq %r14, %xmm6
movups %xmm6, (%r12)
nop
nop
nop
nop
cmp $17175, %rdx
lea addresses_normal_ht+0x17892, %rsi
lea addresses_A_ht+0x1e082, %rdi
nop
nop
nop
nop
nop
xor $24834, %r14
mov $89, %rcx
rep movsb
nop
nop
and %r12, %r12
lea addresses_UC_ht+0x1a02c, %r12
add $56896, %rsi
movb $0x61, (%r12)
nop
nop
and %rsi, %rsi
lea addresses_A_ht+0x151f2, %rsi
lea addresses_WT_ht+0x1d812, %rdi
nop
nop
nop
add $1377, %r15
mov $67, %rcx
rep movsb
nop
nop
nop
cmp %rdi, %rdi
lea addresses_A_ht+0x5332, %r12
nop
nop
nop
nop
nop
inc %rdx
mov $0x6162636465666768, %r15
movq %r15, (%r12)
nop
nop
nop
nop
nop
and %rdx, %rdx
lea addresses_UC_ht+0x11a2, %rdx
nop
nop
nop
dec %rcx
mov (%rdx), %r14d
nop
nop
nop
nop
inc %rdx
lea addresses_A_ht+0x1de6a, %rdx
nop
add %r15, %r15
mov (%rdx), %edi
nop
nop
nop
xor $51153, %r15
pop %rsi
pop %rdx
pop %rdi
pop %rcx
pop %r15
pop %r14
pop %r12
ret
.global s_faulty_load
s_faulty_load:
push %r10
push %r12
push %r13
push %r8
push %r9
push %rbp
push %rbx
// Store
mov $0x60e2870000000e12, %r9
nop
nop
nop
nop
dec %r10
mov $0x5152535455565758, %rbp
movq %rbp, %xmm5
vmovups %ymm5, (%r9)
nop
nop
nop
nop
xor %r13, %r13
// Store
lea addresses_US+0x1257e, %r12
nop
nop
nop
inc %r8
movl $0x51525354, (%r12)
add %r13, %r13
// Store
lea addresses_normal+0xbdfa, %r10
nop
nop
nop
xor $38596, %rbp
mov $0x5152535455565758, %r9
movq %r9, %xmm1
movups %xmm1, (%r10)
nop
nop
xor %r13, %r13
// Store
lea addresses_normal+0x1c492, %r10
nop
nop
nop
xor $63043, %r8
mov $0x5152535455565758, %r13
movq %r13, (%r10)
nop
nop
nop
nop
nop
xor %r13, %r13
// Store
lea addresses_WT+0x2e12, %r9
nop
nop
and %r13, %r13
movw $0x5152, (%r9)
add %rbx, %rbx
// Faulty Load
mov $0x60e2870000000e12, %r10
nop
nop
nop
nop
nop
sub %r8, %r8
mov (%r10), %ebp
lea oracles, %r10
and $0xff, %rbp
shlq $12, %rbp
mov (%r10,%rbp,1), %rbp
pop %rbx
pop %rbp
pop %r9
pop %r8
pop %r13
pop %r12
pop %r10
ret
/*
<gen_faulty_load>
[REF]
{'OP': 'LOAD', 'src': {'type': 'addresses_NC', 'size': 1, 'AVXalign': False, 'NT': False, 'congruent': 0, 'same': False}}
{'OP': 'STOR', 'dst': {'type': 'addresses_NC', 'size': 32, 'AVXalign': False, 'NT': False, 'congruent': 0, 'same': True}}
{'OP': 'STOR', 'dst': {'type': 'addresses_US', 'size': 4, 'AVXalign': False, 'NT': False, 'congruent': 2, 'same': False}}
{'OP': 'STOR', 'dst': {'type': 'addresses_normal', 'size': 16, 'AVXalign': False, 'NT': False, 'congruent': 3, 'same': False}}
{'OP': 'STOR', 'dst': {'type': 'addresses_normal', 'size': 8, 'AVXalign': False, 'NT': False, 'congruent': 5, 'same': False}}
{'OP': 'STOR', 'dst': {'type': 'addresses_WT', 'size': 2, 'AVXalign': False, 'NT': False, 'congruent': 11, 'same': False}}
[Faulty Load]
{'OP': 'LOAD', 'src': {'type': 'addresses_NC', 'size': 4, 'AVXalign': False, 'NT': False, 'congruent': 0, 'same': True}}
<gen_prepare_buffer>
{'OP': 'REPM', 'src': {'type': 'addresses_UC_ht', 'congruent': 2, 'same': False}, 'dst': {'type': 'addresses_WT_ht', 'congruent': 8, 'same': True}}
{'OP': 'REPM', 'src': {'type': 'addresses_UC_ht', 'congruent': 8, 'same': False}, 'dst': {'type': 'addresses_WT_ht', 'congruent': 5, 'same': False}}
{'OP': 'STOR', 'dst': {'type': 'addresses_D_ht', 'size': 16, 'AVXalign': False, 'NT': False, 'congruent': 3, 'same': False}}
{'OP': 'REPM', 'src': {'type': 'addresses_normal_ht', 'congruent': 7, 'same': False}, 'dst': {'type': 'addresses_A_ht', 'congruent': 2, 'same': False}}
{'OP': 'STOR', 'dst': {'type': 'addresses_UC_ht', 'size': 1, 'AVXalign': False, 'NT': False, 'congruent': 1, 'same': True}}
{'OP': 'REPM', 'src': {'type': 'addresses_A_ht', 'congruent': 5, 'same': False}, 'dst': {'type': 'addresses_WT_ht', 'congruent': 9, 'same': False}}
{'OP': 'STOR', 'dst': {'type': 'addresses_A_ht', 'size': 8, 'AVXalign': False, 'NT': False, 'congruent': 5, 'same': False}}
{'OP': 'LOAD', 'src': {'type': 'addresses_UC_ht', 'size': 4, 'AVXalign': True, 'NT': False, 'congruent': 4, 'same': False}}
{'OP': 'LOAD', 'src': {'type': 'addresses_A_ht', 'size': 4, 'AVXalign': False, 'NT': False, 'congruent': 3, 'same': False}}
{'58': 2}
58 58
*/
| 19.368644 | 151 | 0.64953 |
8c7f2b28fdadc28d465604e333d081145e9cd207 | 747 | asm | Assembly | oeis/094/A094649.asm | neoneye/loda-programs | 84790877f8e6c2e821b183d2e334d612045d29c0 | [
"Apache-2.0"
] | 11 | 2021-08-22T19:44:55.000Z | 2022-03-20T16:47:57.000Z | oeis/094/A094649.asm | neoneye/loda-programs | 84790877f8e6c2e821b183d2e334d612045d29c0 | [
"Apache-2.0"
] | 9 | 2021-08-29T13:15:54.000Z | 2022-03-09T19:52:31.000Z | oeis/094/A094649.asm | neoneye/loda-programs | 84790877f8e6c2e821b183d2e334d612045d29c0 | [
"Apache-2.0"
] | 3 | 2021-08-22T20:56:47.000Z | 2021-09-29T06:26:12.000Z | ; A094649: An accelerator sequence for Catalan's constant.
; Submitted by Jamie Morken(s4)
; 4,1,7,4,19,16,58,64,187,247,622,925,2110,3394,7252,12289,25147,44116,87727,157492,307294,560200,1079371,1987891,3798310,7043041,13382818,24927430,47191492,88165105,166501903,311686804,587670811,1101562312,2074699234,3892357744,7325660011,13751772463,25869337774,48580977397,91359785782,171612269962,322660334740,606196595665,1139593274179,2141250121732,4024976418199,7563343639372,14216179376326,26715007336312,50211881768347,94361201385259,177350652641350,333295485924121,626413159309306
mov $1,1
lpb $0
sub $0,1
add $2,$1
sub $3,1
sub $3,$1
add $3,1
add $1,$3
add $1,$3
add $1,$3
add $1,2
add $3,$2
lpe
mov $0,$1
mul $0,3
add $0,1
| 35.571429 | 490 | 0.779116 |
73f13a1b30ea2bb635a56a228339bf45c8e6a884 | 1,972 | asm | Assembly | exampl07/slickhuh/slickhuh.asm | AlexRogalskiy/Masm | d39498878f140696b299c76436f209156961429e | [
"MIT"
] | null | null | null | exampl07/slickhuh/slickhuh.asm | AlexRogalskiy/Masm | d39498878f140696b299c76436f209156961429e | [
"MIT"
] | null | null | null | exampl07/slickhuh/slickhuh.asm | AlexRogalskiy/Masm | d39498878f140696b299c76436f209156961429e | [
"MIT"
] | null | null | null | .686p
.model flat, stdcall
option casemap :none
externdef _imp__DispatchMessageA@4:PTR pr1
m2wp equ <_imp__DispatchMessageA@4>
externdef _imp__GetMessageA@16:PTR pr4
gms equ <_imp__GetMessageA@16>
externdef _imp__DefWindowProcA@16:PTR pr4
dpro equ <_imp__DefWindowProcA@16>
externdef _imp__PostQuitMessage@4:PTR pr1
pqm equ <_imp__PostQuitMessage@4>
externdef _imp__RegisterClassExA@4:PTR pr1
scln equ <_imp__RegisterClassExA@4>
externdef _imp__ShowWindow@8:PTR pr2
wshw equ <_imp__ShowWindow@8>
externdef _imp__LoadCursorA@8:PTR pr2
lsc equ <_imp__LoadCursorA@8>
externdef _imp__CreateWindowExA@48:PTR pr12
crwe equ <_imp__CreateWindowExA@48>
includelib \masm32\lib\user32.lib
.code
ims db "Slick Huh ?", 0
pcl dd ims
slick_huh:
push ebp
mov ebp, esp
sub esp, 96
push 32512
xor edi, edi
push edi
mov esi, 4194304
mov ebx, pcl
call lsc
mov DWORD PTR [ebp-96], 48
mov DWORD PTR [ebp-92], 3
mov DWORD PTR [ebp-88], OFFSET wpep
mov DWORD PTR [ebp-84], edi
mov DWORD PTR [ebp-80], edi
mov DWORD PTR [ebp-76], esi
mov DWORD PTR [ebp-72], edi
mov DWORD PTR [ebp-68], eax
mov DWORD PTR [ebp-64], 10h
mov DWORD PTR [ebp-60], edi
mov DWORD PTR [ebp-56], ebx
mov DWORD PTR [ebp-52], edi
lea eax, [ebp-96]
push eax
call scln
mov ecx, -2147483648
push 1
push edi
push esi
push edi
push edi
push edi
push ecx
push edi
push ecx
push 13565952
push ebx
push ebx
push edi
call crwe
push eax
call wshw
lea ebx, [ebp-48]
push edi
push edi
push edi
push ebx
jmp mlep
@@: push edi
push edi
push edi
push ebx
push ebx
call m2wp
mlep: call gms
test al, al
jnz @B
leave
retn
wpep: cmp DWORD PTR [esp+8], 2
jne @F
push 0
call pqm
@@: jmp dpro
end slick_huh
| 22.157303 | 47 | 0.635396 |
02327941b3d59c58c4729fa66172f1b3223d9800 | 663 | asm | Assembly | model/apple_impl.asm | jacmba/neske | e2e45da767563f73de3b349ed9e40171cd92e010 | [
"MIT"
] | null | null | null | model/apple_impl.asm | jacmba/neske | e2e45da767563f73de3b349ed9e40171cd92e010 | [
"MIT"
] | null | null | null | model/apple_impl.asm | jacmba/neske | e2e45da767563f73de3b349ed9e40171cd92e010 | [
"MIT"
] | null | null | null | ;===========================================================
; apple_impl.asm
;
; Apple model implementation routines
;===========================================================
;-----------------------------------------------------------
; Initialize apple object
;-----------------------------------------------------------
InitApple:
ldx #$E0
ldy #$20
stx AppleX
sty AppleY
rts
;-----------------------------------------------------------
; Set screen opposite position for apple
;-----------------------------------------------------------
RespawnApple:
lda AppleX
clc
adc #$80
sta AppleX
lda AppleY
clc
adc #$80
sta AppleY
rts
| 22.1 | 60 | 0.310709 |
dcf45219b02d2958e5d768f007078c9949b01ec6 | 1,763 | asm | Assembly | Lab Work/5th-semester/assembly-language/book/CH-07/7_11.asm | akazad13/bsc-academic-work | c9a1df5948ed93ce54822bb0a3f1972a9201e9f9 | [
"MIT"
] | null | null | null | Lab Work/5th-semester/assembly-language/book/CH-07/7_11.asm | akazad13/bsc-academic-work | c9a1df5948ed93ce54822bb0a3f1972a9201e9f9 | [
"MIT"
] | null | null | null | Lab Work/5th-semester/assembly-language/book/CH-07/7_11.asm | akazad13/bsc-academic-work | c9a1df5948ed93ce54822bb0a3f1972a9201e9f9 | [
"MIT"
] | null | null | null | .MODEL SMALL
.STACK 100H
.DATA
MSG1 DB 0AH,'TYPE A BINARY NUMBER, UP TO 16 DIGITS: $'
MSG2 DB 0AH,'ILLEGAL BINARY DIGIT, TRY AGAIN: $';
MSG3 DB 'IN HEX IT IS $'
I DB 0
.CODE
MAIN PROC
; initializing data segment
MOV AX,@DATA
MOV DS,AX
LEA DX,MSG1 ; getting offset of 1st message
MOV AH,9 ; string print function
INT 21H ; printing 1st message
JMP _TOP ; jump to TOP
_ILLIGAL: ; for printing illegal error message
LEA DX,MSG2 ; getting offset of 2nd message
MOV AH,9 ; string print function
INT 21H ; printing 2nd message
_TOP:
XOR BX,BX ; reset BX
MOV AH,1 ; single char function
_WHILE:
INT 21H ; single char input
CMP AL,0DH ; check whether AL = carriage return or not
JE _PRINT ; if yes jump to _PRINT
CMP AL,'0' ; check if AL<0
JL _ILLIGAL ; if yes, jump to _ILLIGAL
CMP AL,'1' ; check if AL>1
JG _ILLIGAL ; if yes, jump to _ILLIGAL
AND AL,0FH ; getting the digit
SHL BX,1 ; shift 1 bit to left
OR BL,AL
JMP _WHILE
_PRINT:
LEA DX,MSG3 ; getting offset of 1st message
MOV AH,9 ; string print function
INT 21H ; printing 1st message
XOR DX,DX ; Clear DX
MOV CL,4 ; CL = 4
MOV I,0
MOV AH,2 ; single char output function
_WHILE1:
CMP I,4
JE _EXIT
MOV DL,BH ; DL = BH
SHR DL,CL ; shift DL , 4 time to right
ROL BX,CL ; shift BX to 1 bit left
CMP DL,9 ; if it is digit
JLE _DIGIT ; yes, then go to _DIGIT
ADD DL,55D ; else make it a letter
JMP _OUTPUT ;output function
_DIGIT:
ADD DL,30H ; conver number to ascii character
_OUTPUT:
INT 21H ; print the char
INC I ; I= I+1
JMP _WHILE1 ; jump to _LOOP
_EXIT:
MOV AH,4CH ; dos return function
INT 21H ; return from the dos
MAIN ENDP
END MAIN ; terminate programme
| 20.264368 | 55 | 0.663074 |
075895a2553dd7dec71897d4345ac5f6f3378427 | 2,575 | asm | Assembly | MSDOS/Virus.MSDOS.Unknown.zigzag.asm | fengjixuchui/Family | 2abe167082817d70ff2fd6567104ce4bcf0fe304 | [
"MIT"
] | 3 | 2021-05-15T15:57:13.000Z | 2022-03-16T09:11:05.000Z | MSDOS/Virus.MSDOS.Unknown.zigzag.asm | fengjixuchui/Family | 2abe167082817d70ff2fd6567104ce4bcf0fe304 | [
"MIT"
] | null | null | null | MSDOS/Virus.MSDOS.Unknown.zigzag.asm | fengjixuchui/Family | 2abe167082817d70ff2fd6567104ce4bcf0fe304 | [
"MIT"
] | 3 | 2021-05-15T15:57:15.000Z | 2022-01-08T20:51:04.000Z |
code segment
assume cs:code, ds:code, es:code, ss:nothing
org 0100h
start: db 8Bh,0DBh
mov ah,4Eh ;find a file
mov cx,0000h ;
mov dx,offset filemask ;load searchmask, .COM
loopy: int 21h
jb effect ;no files, do effect
call infect
jnz exit
mov ah,4Fh ;find next file
jmp short loopy
;keep looping around
exit: mov ax,4C00h
int 21h
effect: mov ax,0040h ;no files to infect
mov es,ax ;slant the text on the screen
mov di,004Ah
mov al,51h
stosb
int 20h ;and exit
infect: mov ax,3D02h ;open host, r/w with handle
mov dx,009Eh
int 21h
xchg ax,bx ;exchange handle to ax
mov ah,3Fh ;read from file
mov cx,0002h ;two bytes
mov dx,offset ID ;put them in ID buffer
int 21h
cmp Word Ptr ds:[016Dh],0DB8Bh
;compare with virus ID
pushf
jz close_file
cwd
mov cx,dx ;
mov ax,4200h ;reset file pointer
;to beginning of file
int 21h
mov al,00h ;
mov ah,57h ;get file date/time
int 21h ;
push cx ;store them
push dx ;
mov ah,40h ;write virus
mov cx,007Fh ;to file
mov dx,0100h ;start at beginning
int 21h ;
mov al,01h ;restore file date/time
pop dx ;from the stack
pop cx ;
mov ah,57h ;
int 21h ;
close_file:
mov ah,3Eh ;close file
int 21h ;
popf ;
ret ;exit
ID: dw 0000h
filemask: db "*.COM" ;searchmask
db 00h
db "*ZZ* v 1.0"
code ends
end start
| 29.94186 | 67 | 0.352233 |
ca099c65e256d122d18dc343a4dfa0700c2f9138 | 735 | asm | Assembly | oeis/006/A006152.asm | neoneye/loda-programs | 84790877f8e6c2e821b183d2e334d612045d29c0 | [
"Apache-2.0"
] | 11 | 2021-08-22T19:44:55.000Z | 2022-03-20T16:47:57.000Z | oeis/006/A006152.asm | neoneye/loda-programs | 84790877f8e6c2e821b183d2e334d612045d29c0 | [
"Apache-2.0"
] | 9 | 2021-08-29T13:15:54.000Z | 2022-03-09T19:52:31.000Z | oeis/006/A006152.asm | neoneye/loda-programs | 84790877f8e6c2e821b183d2e334d612045d29c0 | [
"Apache-2.0"
] | 3 | 2021-08-22T20:56:47.000Z | 2021-09-29T06:26:12.000Z | ; A006152: Exponential generating function x*exp(x/(1-x)).
; Submitted by Jon Maiga
; 1,2,9,52,365,3006,28357,301064,3549177,45965530,648352001,9888877692,162112109029,2841669616982,53025262866045,1049180850990736,21937381717388657,483239096122434354,11184035897992673017,271287473871771163460,6881656485607798743261,182185366874848913979502,5024498372948847847451189,144111542172674220191169432,4291986813748642380761182825,132540945809371632049270556426,4238364943902600403876197998577,140174433368679079763743122719884,4789209304548979732019142449723477
mov $1,$0
add $0,1
seq $1,262 ; Number of "sets of lists": number of partitions of {1,...,n} into any number of lists, where a list means an ordered subset.
mul $1,$0
mov $0,$1
| 73.5 | 472 | 0.846259 |
c3d97a6b7fb909f105e3c75dcb07f66a9e170fff | 662 | asm | Assembly | oeis/076/A076006.asm | neoneye/loda-programs | 84790877f8e6c2e821b183d2e334d612045d29c0 | [
"Apache-2.0"
] | 11 | 2021-08-22T19:44:55.000Z | 2022-03-20T16:47:57.000Z | oeis/076/A076006.asm | neoneye/loda-programs | 84790877f8e6c2e821b183d2e334d612045d29c0 | [
"Apache-2.0"
] | 9 | 2021-08-29T13:15:54.000Z | 2022-03-09T19:52:31.000Z | oeis/076/A076006.asm | neoneye/loda-programs | 84790877f8e6c2e821b183d2e334d612045d29c0 | [
"Apache-2.0"
] | 3 | 2021-08-22T20:56:47.000Z | 2021-09-29T06:26:12.000Z | ; A076006: Sixth column of triangle A075503.
; Submitted by Christian Krause
; 1,168,17024,1354752,93499392,5881430016,346987429888,19548208103424,1064285732077568,56464495286943744,2936605030892961792,150373246607730671616,7606369972746352328704,381025640076812853706752,18938335262382167410343936,935400438453715177127804928,45966366588922981827320217600,2249480140084210033346677309440,109711938970834623755581936107520,5336069049730417348477648329768960,258940620893664695740420371362349056,12541953452165996488944802740157022208,606539726541533238177664993558731423744
mov $2,8
pow $2,$0
seq $0,770 ; Stirling numbers of the second kind, S(n,6).
mul $0,$2
| 73.555556 | 496 | 0.888218 |
12d1e37a97180f66b28dafa791ee4f43f1b12be4 | 703 | asm | Assembly | LAB06/TASK03.asm | PrabalChowdhury/CSE-341-MICROPROCESSOR | 88f0dea914890c5aa5bc10d0131233b2ebd27586 | [
"MIT"
] | null | null | null | LAB06/TASK03.asm | PrabalChowdhury/CSE-341-MICROPROCESSOR | 88f0dea914890c5aa5bc10d0131233b2ebd27586 | [
"MIT"
] | null | null | null | LAB06/TASK03.asm | PrabalChowdhury/CSE-341-MICROPROCESSOR | 88f0dea914890c5aa5bc10d0131233b2ebd27586 | [
"MIT"
] | null | null | null | .MODEL SMALL
.STACK 100H
.DATA
A DB 5 dup(?)
Y dw $-A
.CODE
MAIN PROC
MOV AX,@DATA
MOV DS,AX
mov ax,data
mov ds,ax
mov si,0
INPUT:
cmp si,5
je CHECKIN
mov ah,1
int 21h
sub al,30h
mov a[si],al
add si,1
loop INPUT
CHECKIN:
mov si,0
mov dl,0ah
mov ah,2
int 21h
mov dl,0dh
mov ah,2
int 21h
mov cx,Y-1
mov si,0
AA:
lea si,A
mov bx,0
AB:
add bx,1
mov al,a[si]
add si,1
cmp al,A[si]
jb AC
xchg al,A[si]
mov A[si-1],al
AC:
cmp bx,cx
jl AB
loop AA
mov si,0
print_:
cmp si,5h
je EXIT
mov dl,A[si]
add dl,30h
mov ah,2
int 21h
add si,1
loop print_
EXIT:
MOV AX,4C00H
INT 21H
MAIN ENDP
END MAIN
| 8.369048 | 15 | 0.571835 |
d2fe98f197b5ee980999fa2994759d0a5fa2550e | 1,459 | asm | Assembly | programs/oeis/002/A002232.asm | neoneye/loda | afe9559fb53ee12e3040da54bd6aa47283e0d9ec | [
"Apache-2.0"
] | 22 | 2018-02-06T19:19:31.000Z | 2022-01-17T21:53:31.000Z | programs/oeis/002/A002232.asm | neoneye/loda | afe9559fb53ee12e3040da54bd6aa47283e0d9ec | [
"Apache-2.0"
] | 41 | 2021-02-22T19:00:34.000Z | 2021-08-28T10:47:47.000Z | programs/oeis/002/A002232.asm | neoneye/loda | afe9559fb53ee12e3040da54bd6aa47283e0d9ec | [
"Apache-2.0"
] | 5 | 2021-02-24T21:14:16.000Z | 2021-08-09T19:48:05.000Z | ; A002232: 8th powers written backwards.
; 0,1,652,1656,63556,526093,6169761,1084675,61277761,12764034,1,188853412,696189924,127037518,6509875741,5260982652,6927694924,1447575796,67506991011,14036538961,652,16395822873,63537857845,18258901387,671413570011,526098785251,675460728802,184635924282,633899108773,169214642005,1656,144730198258,6777261159901,1428168046041,6984093975871,5260935781522,6547099011282,1293549742153,6948312977434,1840629002535,63556,1219225294897,6146991562869,10677200288611,61252632284041,52609352151861,63913221674002,16716668211832,65092408297182,10696503923233,526093,10407544976754,65413582795435,16311409695226,63193316910327,52609873933738,61047511371769,100211751924111,610817180360821,123406734038641,6169761,182799213707191,698485501043812,125762087551842,656017679474182,526098218446813,696962606040063,146655776760604,673356932361754,146824473897315,1084675,167542135357546,637803631402227,180498190064608,677302047491998,5260930519211001,6794547874303111,1867451926375321,6313860734110731,1656099088017151,61277761,1481588810203581,6794568580414402,1409312322922522,6942801198578742,5260930525094272,6585601729712992,1217345176112823,6925508425436953,1802075088856393,12764034,1251516725252074,6165731378812315,1040566908185955,6180145839865906,5260982134024366,6338389875983127,1696734953347387,6587185220367058,1029724496447229
pow $0,8
lpb $0
mul $1,10
mov $2,$0
div $0,10
mod $2,10
add $1,$2
lpe
mov $0,$1
| 112.230769 | 1,326 | 0.892392 |
5c3ff10a345af60db3252ca53f3b28e0b78ccea2 | 490 | asm | Assembly | oeis/152/A152090.asm | neoneye/loda-programs | 84790877f8e6c2e821b183d2e334d612045d29c0 | [
"Apache-2.0"
] | 11 | 2021-08-22T19:44:55.000Z | 2022-03-20T16:47:57.000Z | oeis/152/A152090.asm | neoneye/loda-programs | 84790877f8e6c2e821b183d2e334d612045d29c0 | [
"Apache-2.0"
] | 9 | 2021-08-29T13:15:54.000Z | 2022-03-09T19:52:31.000Z | oeis/152/A152090.asm | neoneye/loda-programs | 84790877f8e6c2e821b183d2e334d612045d29c0 | [
"Apache-2.0"
] | 3 | 2021-08-22T20:56:47.000Z | 2021-09-29T06:26:12.000Z | ; A152090: a(n) = 2^n*Product_{k=1..floor((n-1)/2)} (1 + 2*cos(k*Pi/n)^2 + 4*cos(k*Pi/n)^4).
; Submitted by Christian Krause
; 1,1,1,3,7,16,39,91,217,513,1216,2881,6825,16171,38311,90768,215047,509491,1207089,2859841,6775552,16052673,38032081,90105811,213479175,505776016,1198287271,2838988683,6726147337,15935624641,37754768064
mov $5,1
lpb $0
sub $0,1
max $0,1
sub $3,$4
add $1,$3
sub $3,$2
add $1,$3
mov $4,$2
mov $2,$3
add $4,$1
add $5,$4
mov $3,$5
lpe
mov $0,$5
| 24.5 | 203 | 0.646939 |
0295ae8b6b1cf000a1d5f5c6c7e52ddc6346d2a4 | 156 | asm | Assembly | Kernel/asm/systemTime.asm | Smonjeau/TPE2-SO | 9ff6dff3a1d1e0344d8e4092bf38a4098e74aa4e | [
"BSD-3-Clause"
] | null | null | null | Kernel/asm/systemTime.asm | Smonjeau/TPE2-SO | 9ff6dff3a1d1e0344d8e4092bf38a4098e74aa4e | [
"BSD-3-Clause"
] | null | null | null | Kernel/asm/systemTime.asm | Smonjeau/TPE2-SO | 9ff6dff3a1d1e0344d8e4092bf38a4098e74aa4e | [
"BSD-3-Clause"
] | null | null | null |
GLOBAL get_Time
SECTION .text
get_Time:
push rbp
mov rbp,rsp
mov rax, 0
mov rax, rdi
out 70h, al
in al, 71h
mov rsp,rbp
pop rbp
ret
| 8.210526 | 15 | 0.628205 |
ad01f6116ddad3b3f677684a3bf6dde802658d54 | 617 | asm | Assembly | src/bswap32.asm | shines77/base64_fast | 3661aa1dd89d3e2b97bdd6f2d83f0abb68b904e3 | [
"MIT"
] | null | null | null | src/bswap32.asm | shines77/base64_fast | 3661aa1dd89d3e2b97bdd6f2d83f0abb68b904e3 | [
"MIT"
] | null | null | null | src/bswap32.asm | shines77/base64_fast | 3661aa1dd89d3e2b97bdd6f2d83f0abb68b904e3 | [
"MIT"
] | null | null | null | page ,132
title ByteSwap32 (bswap32.asm)
;
; See: http://www.cppblog.com/luqingfei/archive/2010/08/11/123078.aspx
; See: https://msdn.microsoft.com/en-us/library/ss9fh0d6.aspx
;
ifndef X64
.586
;.686p
;.mmx
;.XMM
.model flat, C
option casemap : none
endif
.xlist
;include base64_fast.inc
.list
;.stack 100h
.data
; user data
;.data ?
.const
page
.code
; user code
assume ds : FLAT
assume es : FLAT
assume ss : FLAT
align 16
public __byteswap32_
__byteswap32_ proc val:dword
;OPTION PROLOGUE:NONE, EPILOGUE:NONE
mov eax, val
bswap eax
ret
__byteswap32_ endp
end
| 11.017857 | 70 | 0.680713 |
aef8348932914e66996e06219224760bbdf5c112 | 309 | asm | Assembly | oeis/139/A139217.asm | neoneye/loda-programs | 84790877f8e6c2e821b183d2e334d612045d29c0 | [
"Apache-2.0"
] | 11 | 2021-08-22T19:44:55.000Z | 2022-03-20T16:47:57.000Z | oeis/139/A139217.asm | neoneye/loda-programs | 84790877f8e6c2e821b183d2e334d612045d29c0 | [
"Apache-2.0"
] | 9 | 2021-08-29T13:15:54.000Z | 2022-03-09T19:52:31.000Z | oeis/139/A139217.asm | neoneye/loda-programs | 84790877f8e6c2e821b183d2e334d612045d29c0 | [
"Apache-2.0"
] | 3 | 2021-08-22T20:56:47.000Z | 2021-09-29T06:26:12.000Z | ; A139217: Smallest positive integer of the form 3k+1 such that all subsets of {a(1),...,a(n)} have a different sum.
; Submitted by Jon Maiga
; 1,4,7,13,22,49,97,190,385,769,1534,3073,6145,12286
sub $0,1
mov $1,$0
pow $0,2
mod $0,3
mov $2,$1
cmp $2,0
add $1,$2
mov $3,2
pow $3,$1
add $0,$3
mul $0,3
sub $0,2
| 18.176471 | 116 | 0.644013 |
531b587891dc54557de6a0130723fa6635a4cb49 | 218 | asm | Assembly | tests/data/src/test_ld_iyn.asm | protoCall7/PZ80emu | 2ff78d206bda4a173bfca0700462cd5f1cb3d637 | [
"BSD-3-Clause"
] | 1 | 2016-03-07T23:18:59.000Z | 2016-03-07T23:18:59.000Z | tests/data/src/test_ld_iyn.asm | protoCall7/PZ80emu | 2ff78d206bda4a173bfca0700462cd5f1cb3d637 | [
"BSD-3-Clause"
] | 3 | 2015-12-13T00:27:06.000Z | 2017-10-20T18:39:25.000Z | tests/data/src/test_ld_iyn.asm | protoCall7/PZ80emu | 2ff78d206bda4a173bfca0700462cd5f1cb3d637 | [
"BSD-3-Clause"
] | null | null | null | ld iy,0x0070
ld (iy+0),0x00
ld (iy+1),0x01
ld (iy+2),0x02
ld (iy+3),0x03
ld (iy+4),0x04
ld (iy+5),0x05
ld (iy+6),0x06
ld (iy+7),0x07
ld a,(iy+1)
ld b,(iy+2)
ld c,(iy+3)
ld d,(iy+4)
ld e,(iy+5)
ld h,(iy+6)
ld l,(iy+7)
| 12.111111 | 14 | 0.568807 |
6bfbe8b013d79a2a09155c14c9f2f0751b28ab05 | 2,020 | asm | Assembly | software/minol/source/commands/goto_run.asm | paulscottrobson/retrochallenge-jan-2016 | 8bd340efc85969fa6f2fecc788aa21b27123a4db | [
"MIT"
] | null | null | null | software/minol/source/commands/goto_run.asm | paulscottrobson/retrochallenge-jan-2016 | 8bd340efc85969fa6f2fecc788aa21b27123a4db | [
"MIT"
] | null | null | null | software/minol/source/commands/goto_run.asm | paulscottrobson/retrochallenge-jan-2016 | 8bd340efc85969fa6f2fecc788aa21b27123a4db | [
"MIT"
] | null | null | null | ; ****************************************************************************************************************
; ****************************************************************************************************************
;
; GOTO and RUN
;
; ****************************************************************************************************************
; ****************************************************************************************************************
jmp CRG_Over ; Skip over this command.
; ****************************************************************************************************************
; GOTO command
; ****************************************************************************************************************
CMD_Goto:
xppc p3 ; evaluate the line number to GOTO, in E
jp CRG_Over ; exit if error occurred
lde ; get line number
st -1(p2) ; save below TOS.
lpi p1,ProgramBase ; point P1 to program Base.
CRG_Find:
ld 0(p1) ; look at offset
jp CRG_NotEnd ; if -ve then end of program.
ldi ERRC_Label ; return label error
xae
ccl ; set error flag
jmp CRG_Over
;
CRG_NotEnd:
xae ; offset in E
ld 1(p1) ; get line number
xor -1(p2) ; go back if not required one.
jz CRG_ExecuteFromP1 ; if found, run from P1.
ld @-0x80(p1) ; go to next line
jmp CRG_Find ; keep trying.
;
; ****************************************************************************************************************
; RUN command
; ****************************************************************************************************************
CMD_Run:
lpi p1,ProgramBase ; start from first line of program
CRG_ExecuteFromP1:
jmp CheckLastCommandThenExecute ; check if the last command and if not execute.
CRG_Over:
| 42.978723 | 114 | 0.298515 |
420495cccaba9a428f696f635620dbaaf49fd906 | 531 | asm | Assembly | oeis/292/A292631.asm | neoneye/loda-programs | 84790877f8e6c2e821b183d2e334d612045d29c0 | [
"Apache-2.0"
] | 11 | 2021-08-22T19:44:55.000Z | 2022-03-20T16:47:57.000Z | oeis/292/A292631.asm | neoneye/loda-programs | 84790877f8e6c2e821b183d2e334d612045d29c0 | [
"Apache-2.0"
] | 9 | 2021-08-29T13:15:54.000Z | 2022-03-09T19:52:31.000Z | oeis/292/A292631.asm | neoneye/loda-programs | 84790877f8e6c2e821b183d2e334d612045d29c0 | [
"Apache-2.0"
] | 3 | 2021-08-22T20:56:47.000Z | 2021-09-29T06:26:12.000Z | ; A292631: a(n) = n! * [x^n] exp(n*x)*(BesselI(0,2*x) + BesselI(1,2*x)).
; Submitted by Christian Krause
; 1,2,10,75,758,9660,148772,2688420,55784710,1307378358,34158527852,984547901051,31034429035260,1062081192039140,39218355263626632,1554260970293874135,65803396940022289734,2964120950479432183950,141548149894016562758300,7143010414313948156920665,379821534884560034711455956
mov $1,1
mov $2,1
mov $3,$0
mov $4,2
lpb $3
mul $1,$3
mul $2,$0
sub $3,1
cmp $4,2
add $5,$4
div $1,$5
add $2,$1
add $4,2
lpe
mov $0,$2
| 26.55 | 273 | 0.72693 |
6e50e632b55c94cdacf1b7adb27f5bb88083e095 | 90 | asm | Assembly | kernel/devices/video/font.asm | lixk28/emerald | 12b46cdcf906473f230978d74cddcbc1321437f3 | [
"MIT"
] | 378 | 2020-11-04T13:50:12.000Z | 2022-03-29T07:29:22.000Z | kernel/devices/video/font.asm | lixk28/emerald | 12b46cdcf906473f230978d74cddcbc1321437f3 | [
"MIT"
] | 30 | 2020-11-05T01:19:57.000Z | 2021-12-09T22:45:15.000Z | kernel/devices/video/font.asm | lixk28/emerald | 12b46cdcf906473f230978d74cddcbc1321437f3 | [
"MIT"
] | 48 | 2020-11-04T13:43:03.000Z | 2022-03-12T03:27:01.000Z | global fb_font
section .data
align 8
fb_font:
incbin "kernel/devices/video/fb_font.psf"
| 12.857143 | 42 | 0.788889 |
37e2130be9cf1cacb6b0f358be4b6fb82ff15d98 | 261,135 | asm | Assembly | disassemble/mrtnt.asm | BleuLlama/GameDocs | 7f542ae50a2d0c7045c3ed826497b32941eafa0a | [
"MIT"
] | 14 | 2015-09-04T02:30:43.000Z | 2022-02-19T10:31:14.000Z | disassemble/mrtnt.asm | BleuLlama/GameDocs | 7f542ae50a2d0c7045c3ed826497b32941eafa0a | [
"MIT"
] | null | null | null | disassemble/mrtnt.asm | BleuLlama/GameDocs | 7f542ae50a2d0c7045c3ed826497b32941eafa0a | [
"MIT"
] | 2 | 2021-01-09T23:45:45.000Z | 2022-03-08T12:57:58.000Z | ; Mr. TNT
;
; preliminary disassembly, for when I added this in to a menu system
;
Starting address: 0
Ending address: 16383
Output file: (none)
Pass 1 of 1
0000 f3 di
0001 af xor a
0002 0608 ld b,#08
0004 210050 ld hl,#5000
0007 77 ld (hl),a
0008 23 inc hl
0009 10fc djnz #0007 ; (-4)
000b ed56 im 1
000d 31f14f ld sp,#4ff1
0010 c3c702 jp #02c7
; subroutine
0013 3aa64c ld a,(#4ca6)
0016 fe00 cp #00
0018 c8 ret z
0019 47 ld b,a
001a 3e18 ld a,#18
001c 211d40 ld hl,#401d
001f 77 ld (hl),a
0020 2b dec hl
0021 10fc djnz #001f ; (-4)
0023 c9 ret
0024 3aa74c ld a,(#4ca7)
0027 fe00 cp #00
0029 c8 ret z
002a 47 ld b,a
002b 3e18 ld a,#18
002d 210240 ld hl,#4002
0030 77 ld (hl),a
0031 23 inc hl
0032 10fc djnz #0030 ; (-4)
0034 c9 ret
0035 40 ld b,b
0036 00 nop
0037 00 nop
0038 08 ex af,af'
0039 d9 exx
003a dde5 push ix
003c fde5 push iy
003e af xor a
003f 320050 ld (#5000),a
0042 2a0c4c ld hl,(#4c0c)
0045 3a0e4c ld a,(#4c0e)
0048 77 ld (hl),a
0049 2a0f4c ld hl,(#4c0f)
004c 3a114c ld a,(#4c11)
004f 77 ld (hl),a
0050 2a144c ld hl,(#4c14)
0053 3a164c ld a,(#4c16)
0056 77 ld (hl),a
0057 2a174c ld hl,(#4c17)
005a 3a194c ld a,(#4c19)
005d 77 ld (hl),a
005e 2a1c4c ld hl,(#4c1c)
0061 3a1e4c ld a,(#4c1e)
0064 77 ld (hl),a
0065 2a1f4c ld hl,(#4c1f)
0068 3a214c ld a,(#4c21)
006b 77 ld (hl),a
006c 2a244c ld hl,(#4c24)
006f 3a264c ld a,(#4c26)
0072 77 ld (hl),a
0073 2a274c ld hl,(#4c27)
0076 3a294c ld a,(#4c29)
0079 77 ld (hl),a
007a 2a2c4c ld hl,(#4c2c)
007d 3a2e4c ld a,(#4c2e)
0080 77 ld (hl),a
0081 2a2f4c ld hl,(#4c2f)
0084 3a314c ld a,(#4c31)
0087 77 ld (hl),a
0088 2a344c ld hl,(#4c34)
008b 3a364c ld a,(#4c36)
008e 77 ld (hl),a
008f 2a374c ld hl,(#4c37)
0092 3a394c ld a,(#4c39)
0095 77 ld (hl),a
0096 2a3c4c ld hl,(#4c3c)
0099 3a3e4c ld a,(#4c3e)
009c 77 ld (hl),a
009d 2a3f4c ld hl,(#4c3f)
00a0 3a414c ld a,(#4c41)
00a3 77 ld (hl),a
00a4 2a444c ld hl,(#4c44)
00a7 3a464c ld a,(#4c46)
00aa 77 ld (hl),a
00ab 2a474c ld hl,(#4c47)
00ae 3a494c ld a,(#4c49)
00b1 77 ld (hl),a
00b2 2a4c4c ld hl,(#4c4c)
00b5 3a4e4c ld a,(#4c4e)
00b8 77 ld (hl),a
00b9 2a4f4c ld hl,(#4c4f)
00bc 3a514c ld a,(#4c51)
00bf 77 ld (hl),a
00c0 2a544c ld hl,(#4c54)
00c3 3a564c ld a,(#4c56)
00c6 77 ld (hl),a
00c7 2a574c ld hl,(#4c57)
00ca 3a594c ld a,(#4c59)
00cd 77 ld (hl),a
00ce 21964c ld hl,#4c96
00d1 cb7e bit 7,(hl)
00d3 2831 jr z,#0106 ; (49)
00d5 cb6e bit 5,(hl)
00d7 202d jr nz,#0106 ; (45)
00d9 0606 ld b,#06
00db 21644c ld hl,#4c64
00de 116250 ld de,#5062
00e1 3e06 ld a,#06
00e3 0e02 ld c,#02
00e5 eda0 ldi
00e7 eda0 ldi
00e9 cdb015 call #15b0
00ec 10f3 djnz #00e1 ; (-13)
00ee 0606 ld b,#06
00f0 21664c ld hl,#4c66
00f3 11f24f ld de,#4ff2
00f6 3e06 ld a,#06
00f8 0e02 ld c,#02
00fa eda0 ldi
00fc eda0 ldi
00fe cdb015 call #15b0
0101 10f3 djnz #00f6 ; (-13)
0103 c37e01 jp #017e
0106 ed5b644c ld de,(#4c64)
010a cd480f call #0f48
010d ed536250 ld (#5062),de
0111 ed5b6c4c ld de,(#4c6c)
0115 cd480f call #0f48
0118 ed536450 ld (#5064),de
011c ed5b744c ld de,(#4c74)
0120 cd480f call #0f48
0123 ed536650 ld (#5066),de
0127 ed5b7c4c ld de,(#4c7c)
012b cd480f call #0f48
012e ed536850 ld (#5068),de
0132 ed5b844c ld de,(#4c84)
0136 cd480f call #0f48
0139 ed536a50 ld (#506a),de
013d ed5b8c4c ld de,(#4c8c)
0141 cd480f call #0f48
0144 ed536c50 ld (#506c),de
0148 2a664c ld hl,(#4c66)
014b cd610f call #0f61
014e 22f24f ld (#4ff2),hl
0151 2a6e4c ld hl,(#4c6e)
0154 cd610f call #0f61
0157 22f44f ld (#4ff4),hl
015a 2a764c ld hl,(#4c76)
015d cd610f call #0f61
0160 22f64f ld (#4ff6),hl
0163 2a7e4c ld hl,(#4c7e)
0166 cd610f call #0f61
0169 22f84f ld (#4ff8),hl
016c 2a864c ld hl,(#4c86)
016f cd610f call #0f61
0172 22fa4f ld (#4ffa),hl
0175 2a8e4c ld hl,(#4c8e)
0178 cd610f call #0f61
017b 22fc4f ld (#4ffc),hl
017e 2a934c ld hl,(#4c93)
0181 23 inc hl
0182 22934c ld (#4c93),hl
0185 7e ld a,(hl)
0186 feff cp #ff
0188 2006 jr nz,#0190 ; (6)
018a 21a539 ld hl,#39a5
018d 22934c ld (#4c93),hl
0190 21954c ld hl,#4c95 ; 4c95? - debouncing
0193 cb46 bit 0,(hl)
0195 2056 jr nz,#01ed ; (86)
0197 3a0050 ld a,(#5000) ; XXX in0
019a cb6f bit 5,a ; coin 1
019c ca2a02 jp z,#022a
019f cb8e res 1,(hl)
01a1 cb56 bit 2,(hl)
01a3 203d jr nz,#01e2 ; (61)
01a5 3a0050 ld a,(#5000) ; XXX in0
01a8 cb7f bit 7,a ; coin 2
01aa ca3802 jp z,#0238
01ad 3a984c ld a,(#4c98) ; some kind of counter
01b0 fe06 cp #06
01b2 2807 jr z,#01bb ; (7)
01b4 3c inc a
01b5 32984c ld (#4c98),a
01b8 c33d02 jp #023d
01bb af xor a
01bc 32984c ld (#4c98),a
01bf cb5e bit 3,(hl)
01c1 200a jr nz,#01cd ; (10)
01c3 3a994c ld a,(#4c99)
01c6 fe00 cp #00
01c8 200b jr nz,#01d5 ; (11)
01ca c33d02 jp #023d
01cd af xor a
01ce 320750 ld (#5007),a
01d1 cb9e res 3,(hl)
01d3 1868 jr #023d ; (104)
01d5 3d dec a
01d6 32994c ld (#4c99),a
01d9 3e01 ld a,#01
01db 320750 ld (#5007),a
01de cbde set 3,(hl)
01e0 185b jr #023d ; (91)
01e2 3a0050 ld a,(#5000) ; XXX in0
01e5 cb7f bit 7,a ; coin 2
01e7 28c4 jr z,#01ad ; (-60)
01e9 cb96 res 2,(hl)
01eb 1810 jr #01fd ; (16)
01ed 3a0050 ld a,(#5000) ; XXX in0
01f0 cb6f bit 5,a ; coin 1
01f2 28ad jr z,#01a1 ; (-83)
4c9a = credits * 2?
01f4 cb86 res 0,(hl)
01f6 3a994c ld a,(#4c99)
01f9 3c inc a
01fa 32994c ld (#4c99),a
01fd 3a9a4c ld a,(#4c9a)
0200 fe14 cp #14 ; max of 10 credits!
0202 301a jr nc,#021e ; (26)
0204 47 ld b,a
0205 3a9c4c ld a,(#4c9c)
0208 80 add a,b
0209 329a4c ld (#4c9a),a
020c cb3f srl a
020e 0600 ld b,#00
0210 80 add a,b
0211 27 daa
0212 329d4c ld (#4c9d),a
0215 cd1d15 call #151d
0218 cb66 bit 4,(hl)
021a 2002 jr nz,#021e ; (2)
021c cbee set 5,(hl)
021e 3a054d ld a,(#4d05)
0221 cbc7 set 0,a
0223 32054d ld (#4d05),a
0226 cbf6 set 6,(hl)
0228 1883 jr #01ad ; (-125)
; something with credits.
022a cb4e bit 1,(hl)
022c 2005 jr nz,#0233 ; (5)
022e cbce set 1,(hl)
0230 c3a101 jp #01a1
0233 cbc6 set 0,(hl)
0235 c39f01 jp #019f
0238 cbd6 set 2,(hl)
023a c3ad01 jp #01ad
023d 00 nop
023e 21964c ld hl,#4c96
0241 cb46 bit 0,(hl)
0243 2816 jr z,#025b ; (22)
0245 cd3f16 call #163f
0248 21964c ld hl,#4c96
024b cb7e bit 7,(hl)
024d 2804 jr z,#0253 ; (4)
024f cb6e bit 5,(hl)
0251 2805 jr z,#0258 ; (5)
0253 cd1f16 call #161f
0256 1803 jr #025b ; (3)
0258 cd2f16 call #162f
025b 3a9f4c ld a,(#4c9f)
025e 3c inc a
025f 329f4c ld (#4c9f),a
0262 3a9e4c ld a,(#4c9e)
0265 3c inc a
0266 329e4c ld (#4c9e),a
0269 fe3c cp #3c
026b 200b jr nz,#0278 ; (11)
026d af xor a
026e 329e4c ld (#4c9e),a
0271 3aa04c ld a,(#4ca0)
0274 3c inc a
0275 32a04c ld (#4ca0),a
0278 21954c ld hl,#4c95
027b cbbe res 7,(hl)
027d 3a0050 ld a,(#5000) ; XXX in0
0280 cb77 bit 6,a ; TILT
0282 2035 jr nz,#02b9 ; (53)
0284 af xor a
0285 320150 ld (#5001),a
0288 216250 ld hl,#5062
028b 060c ld b,#0c
028d 3600 ld (hl),#00
028f 23 inc hl
0290 10fb djnz #028d ; (-5)
0292 3e40 ld a,#40
0294 cdfd14 call #14fd
0297 3e09 ld a,#09
0299 cd0d15 call #150d
029c 11d041 ld de,#41d0
029f 219219 ld hl,#1992 ; SLAM
02a2 3e01 ld a,#01 ; color 1?
02a4 0604 ld b,#04 ; 4 characters long
02a6 cdd515 call #15d5 ; DRAW TEXT
02a9 06ff ld b,#ff
02ab 21ffff ld hl,#ffff
02ae 2b dec hl
02af 7d ld a,l
02b0 bc cp h
02b1 32c050 ld (#50c0),a
02b4 20f8 jr nz,#02ae ; (-8)
02b6 10f3 djnz #02ab ; (-13)
02b8 76 halt
02b9 fb ei
02ba 3e01 ld a,#01
02bc 320050 ld (#5000),a
02bf fde1 pop iy
02c1 dde1 pop ix
02c3 d9 exx
02c4 08 ex af,af'
02c5 ed4d reti
; startup continuation
02c7 3a0050 ld a,(#5000) ; XXX in0
02ca cb67 bit 4,a ; SERVICE
02cc c28f05 jp nz,#058f
; diagnostics follow here
02cf af xor a
02d0 0608 ld b,#08
02d2 210050 ld hl,#5000
02d5 77 ld (hl),a
02d6 23 inc hl
02d7 10fc djnz #02d5 ; (-4)
02d9 3e00 ld a,#00
02db 320350 ld (#5003),a
02de 31f14f ld sp,#4ff1
02e1 cd0a16 call #160a
02e4 f3 di
02e5 08 ex af,af'
02e6 af xor a
02e7 08 ex af,af'
02e8 210040 ld hl,#4000
02eb cd1605 call #0516
02ee 08 ex af,af'
02ef cb47 bit 0,a
02f1 2802 jr z,#02f5 ; (2)
02f3 cbd7 set 2,a
02f5 cb4f bit 1,a
02f7 2802 jr z,#02fb ; (2)
02f9 cbdf set 3,a
02fb 08 ex af,af'
02fc 210044 ld hl,#4400
02ff cd1605 call #0516
0302 08 ex af,af'
0303 cb47 bit 0,a
0305 2802 jr z,#0309 ; (2)
0307 cbe7 set 4,a
0309 cb4f bit 1,a
030b 2802 jr z,#030f ; (2)
030d cbef set 5,a
030f 08 ex af,af'
0310 31fd43 ld sp,#43fd
0313 21004c ld hl,#4c00
0316 cd1605 call #0516
0319 08 ex af,af'
031a cb47 bit 0,a
031c 2802 jr z,#0320 ; (2)
031e cbf7 set 6,a
0320 cb4f bit 1,a
0322 2802 jr z,#0326 ; (2)
0324 cbff set 7,a
0326 08 ex af,af'
0327 3e01 ld a,#01
0329 cd0d15 call #150d
032c 210040 ld hl,#4000
032f 110140 ld de,#4001
0332 01fe03 ld bc,#03fe
0335 3640 ld (hl),#40
0337 edb0 ldir
0339 116641 ld de,#4166
033c 21571a ld hl,#1a57 ; DIAGNOSTICS
033f 3e01 ld a,#01
0341 060b ld b,#0b
0343 cdd515 call #15d5 ; DRAW TEXT
0346 118a40 ld de,#408a
0349 21621a ld hl,#1a62 ; LOCATION CONDITION
034c 3e01 ld a,#01
034e 0618 ld b,#18
0350 cdd515 call #15d5 ; DRAW TEXT
0353 11ec40 ld de,#40ec
0356 217a1a ld hl,#1a7a ; GOOD
0359 3e01 ld a,#01
035b 0614 ld b,#14
035d cdd515 call #15d5 ; DRAW TEXT
0360 11ed40 ld de,#40ed
0363 218e1a ld hl,#1a8e ; GOOD
0366 3e01 ld a,#01
0368 0614 ld b,#14
036a cdd515 call #15d5 ; DRAW TEXT
036d 11ee40 ld de,#40ee
0370 21a21a ld hl,#1aa2
0373 3e01 ld a,#01
0375 0614 ld b,#14
0377 cdd515 call #15d5 ; DRAW TEXT
037a 11ef40 ld de,#40ef
037d 21b61a ld hl,#1ab6
0380 3e01 ld a,#01
0382 0614 ld b,#14
0384 cdd515 call #15d5 ; DRAW TEXT
0387 119340 ld de,#4093
038a 21461b ld hl,#1b46
038d 3e01 ld a,#01
038f 0618 ld b,#18
0391 cdd515 call #15d5 ; DRAW TEXT
0394 11f540 ld de,#40f5
0397 21ca1a ld hl,#1aca
039a 3e01 ld a,#01
039c 0614 ld b,#14
039e cdd515 call #15d5 ; DRAW TEXT
03a1 11f640 ld de,#40f6
03a4 21de1a ld hl,#1ade
03a7 3e01 ld a,#01
03a9 0614 ld b,#14
03ab cdd515 call #15d5 ; DRAW TEXT
03ae 11f740 ld de,#40f7
03b1 21f21a ld hl,#1af2
03b4 3e01 ld a,#01
03b6 0614 ld b,#14
03b8 cdd515 call #15d5 ; DRAW TEXT
03bb 11f840 ld de,#40f8
03be 21061b ld hl,#1b06 ; GOOD 3
03c1 3e01 ld a,#01
03c3 0614 ld b,#14
03c5 cdd515 call #15d5 ; DRAW TEXT
03c8 11f940 ld de,#40f9
03cb 211a1b ld hl,#1b1a
03ce 3e01 ld a,#01
03d0 0614 ld b,#14
03d2 cdd515 call #15d5 ; DRAW TEXT
03d5 11fa40 ld de,#40fa
03d8 212e1b ld hl,#1b2e
03db 3e01 ld a,#01
03dd 0614 ld b,#14
03df cdd515 call #15d5 ; DRAW TEXT
03e2 08 ex af,af'
03e3 32fe4c ld (#4cfe),a
03e6 08 ex af,af'
03e7 3afe4c ld a,(#4cfe)
03ea cb57 bit 2,a
03ec 280d jr z,#03fb ; (13)
03ee 11f540 ld de,#40f5
03f1 21421b ld hl,#1b42 ; BAD
03f4 3e01 ld a,#01
03f6 0604 ld b,#04
03f8 cdd515 call #15d5 ; DRAW TEXT
03fb 3afe4c ld a,(#4cfe)
03fe cb5f bit 3,a
0400 280d jr z,#040f ; (13)
0402 11f640 ld de,#40f6
0405 21421b ld hl,#1b42
0408 3e01 ld a,#01
040a 0604 ld b,#04
040c cdd515 call #15d5 ; DRAW TEXT
040f 3afe4c ld a,(#4cfe)
0412 cb67 bit 4,a
0414 280d jr z,#0423 ; (13)
0416 11f740 ld de,#40f7
0419 21421b ld hl,#1b42
041c 3e01 ld a,#01
041e 0604 ld b,#04
0420 cdd515 call #15d5 ; DRAW TEXT
0423 3afe4c ld a,(#4cfe)
0426 cb6f bit 5,a
0428 280d jr z,#0437 ; (13)
042a 11f840 ld de,#40f8
042d 21421b ld hl,#1b42
0430 3e01 ld a,#01
0432 0604 ld b,#04
0434 cdd515 call #15d5 ; DRAW TEXT
0437 3afe4c ld a,(#4cfe)
043a cb77 bit 6,a
043c 280d jr z,#044b ; (13)
043e 11f940 ld de,#40f9
0441 21421b ld hl,#1b42
0444 3e01 ld a,#01
0446 0604 ld b,#04
0448 cdd515 call #15d5 ; DRAW TEXT
044b 3afe4c ld a,(#4cfe)
044e cb7f bit 7,a
0450 280d jr z,#045f ; (13)
0452 11fa40 ld de,#40fa
0455 21421b ld hl,#1b42
0458 3e01 ld a,#01
045a 0604 ld b,#04
045c cdd515 call #15d5 ; DRAW TEXT
045f 1e00 ld e,#00
0461 210000 ld hl,#0000
0464 cdfd04 call #04fd
0467 3002 jr nc,#046b ; (2)
0469 cbc3 set 0,e
046b 210010 ld hl,#1000
046e cdfd04 call #04fd
0471 3002 jr nc,#0475 ; (2)
0473 cbcb set 1,e
0475 210020 ld hl,#2000
0478 cdfd04 call #04fd
047b 3002 jr nc,#047f ; (2)
047d cbd3 set 2,e
047f 210030 ld hl,#3000
0482 cdfd04 call #04fd
0485 3002 jr nc,#0489 ; (2)
0487 cbdb set 3,e
0489 3afe4c ld a,(#4cfe)
048c fe00 cp #00
048e 2802 jr z,#0492 ; (2)
0490 3e80 ld a,#80
0492 b3 or e
0493 32fe4c ld (#4cfe),a
0496 cb47 bit 0,a
0498 280d jr z,#04a7 ; (13)
049a 11ec40 ld de,#40ec
049d 21421b ld hl,#1b42
04a0 3e01 ld a,#01
04a2 0604 ld b,#04
04a4 cdd515 call #15d5 ; DRAW TEXT
04a7 3afe4c ld a,(#4cfe)
04aa cb4f bit 1,a
04ac 280d jr z,#04bb ; (13)
04ae 11ed40 ld de,#40ed
04b1 21421b ld hl,#1b42 ; BAD
04b4 3e01 ld a,#01
04b6 0604 ld b,#04
04b8 cdd515 call #15d5 ; DRAW TEXT
04bb 3afe4c ld a,(#4cfe)
04be cb57 bit 2,a
04c0 280d jr z,#04cf ; (13)
04c2 11ee40 ld de,#40ee
04c5 21421b ld hl,#1b42
04c8 3e01 ld a,#01
04ca 0604 ld b,#04
04cc cdd515 call #15d5 ; DRAW TEXT
04cf 3afe4c ld a,(#4cfe)
04d2 cb5f bit 3,a
04d4 280d jr z,#04e3 ; (13)
04d6 11ef40 ld de,#40ef
04d9 21421b ld hl,#1b42
04dc 3e01 ld a,#01
04de 0604 ld b,#04
04e0 cdd515 call #15d5 ; DRAW TEXT
04e3 3afe4c ld a,(#4cfe)
04e6 fe00 cp #00
04e8 200e jr nz,#04f8 ; (14)
04ea fb ei
04eb 3e01 ld a,#01
04ed 320050 ld (#5000),a
04f0 3e02 ld a,#02
04f2 cd4f15 call #154f
04f5 c3d902 jp #02d9
04f8 32c050 ld (#50c0),a
04fb 18fb jr #04f8 ; (-5)
04fd 010010 ld bc,#1000
0500 af xor a
0501 32c050 ld (#50c0),a
0504 86 add a,(hl)
0505 23 inc hl
0506 57 ld d,a
0507 0b dec bc
0508 79 ld a,c
0509 b0 or b
050a 7a ld a,d
050b 20f7 jr nz,#0504 ; (-9)
050d feff cp #ff
050f 2802 jr z,#0513 ; (2)
0511 37 scf
0512 c9 ret
0513 37 scf
0514 3f ccf
0515 c9 ret
0516 08 ex af,af'
0517 e6fc and #fc
0519 08 ex af,af'
051a e5 push hl
051b 3e11 ld a,#11
051d cd3505 call #0535
0520 e1 pop hl
0521 e5 push hl
0522 3e22 ld a,#22
0524 cd3505 call #0535
0527 e1 pop hl
0528 e5 push hl
0529 3e44 ld a,#44
052b cd3505 call #0535
052e e1 pop hl
052f 3e88 ld a,#88
0531 cd3505 call #0535
0534 c9 ret
0535 32c050 ld (#50c0),a
0538 e5 push hl
0539 e5 push hl
053a d1 pop de
053b 13 inc de
053c 01ff03 ld bc,#03ff
053f 77 ld (hl),a
0540 edb0 ldir
0542 e1 pop hl
0543 010004 ld bc,#0400
0546 be cp (hl)
0547 c45305 call nz,#0553
054a 23 inc hl
054b 5f ld e,a
054c 0b dec bc
054d 79 ld a,c
054e b0 or b
054f 7b ld a,e
0550 20f4 jr nz,#0546 ; (-12)
0552 c9 ret
0553 5f ld e,a
0554 7e ld a,(hl)
0555 e60f and #0f
0557 57 ld d,a
0558 7b ld a,e
0559 e60f and #0f
055b ba cp d
055c 2804 jr z,#0562 ; (4)
055e 08 ex af,af'
055f cbcf set 1,a
0561 08 ex af,af'
0562 7e ld a,(hl)
0563 e6f0 and #f0
0565 57 ld d,a
0566 7b ld a,e
0567 e6f0 and #f0
0569 ba cp d
056a c8 ret z
056b 08 ex af,af'
056c cbc7 set 0,a
056e 08 ex af,af'
056f 7b ld a,e
0570 c9 ret
00000570 c9 4d 52 20 54 4e 54 2c 43 4f 50 59 52 49 47 48 |.MR TNT,COPYRIGH|
00000580 54 20 31 39 38 33 54 45 4c 4b 4f 20 49 4e 43 32 |T 1983TELKO INC2|
; game initialization
058f 32c050 ld (#50c0),a
0592 210040 ld hl,#4000
0595 110140 ld de,#4001
0598 01fe07 ld bc,#07fe
059b 3640 ld (hl),#40
059d edb0 ldir ; clear screen
059f 32c050 ld (#50c0),a
05a2 21004c ld hl,#4c00
05a5 11014c ld de,#4c01
05a8 01fe03 ld bc,#03fe
05ab 3600 ld (hl),#00
05ad edb0 ldir ; clear ram
05af 32c050 ld (#50c0),a
05b2 216050 ld hl,#5060
05b5 116150 ld de,#5061
05b8 010f00 ld bc,#000f
05bb 3600 ld (hl),#00
05bd edb0 ldir ; clear sprite coords
05bf 32c050 ld (#50c0),a
05c2 21f04f ld hl,#4ff0
05c5 11f14f ld de,#4ff1
05c8 010f00 ld bc,#000f
05cb 3600 ld (hl),#00
05cd edb0 ldir ; clear sprite definitions
05cf 32c050 ld (#50c0),a
05d2 214050 ld hl,#5040
05d5 114150 ld de,#5041
05d8 011f00 ld bc,#001f
05db 3600 ld (hl),#00
05dd edb0 ldir ; clear sound registers
05df 210c4c ld hl,#4c0c
05e2 110d4c ld de,#4c0d
05e5 014f00 ld bc,#004f
05e8 36ff ld (hl),#ff
05ea edb0 ldir ; screen mirror ram?
05ec 21a539 ld hl,#39a5
05ef 22934c ld (#4c93),hl
05f2 3a8050 ld a,(#5080)
05f5 47 ld b,a
05f6 e603 and #03
05f8 329b4c ld (#4c9b),a
05fb 219c1b ld hl,#1b9c
05fe cdb015 call #15b0
0601 7e ld a,(hl)
0602 329c4c ld (#4c9c),a
0605 78 ld a,b
0606 e60c and #0c
0608 cb3f srl a
060a cb3f srl a
060c 21a139 ld hl,#39a1
060f cdb015 call #15b0
0612 7e ld a,(hl)
0613 32a24c ld (#4ca2),a
0616 78 ld a,b
0617 e630 and #30
0619 216139 ld hl,#3961
061c cdb015 call #15b0
061f 22a34c ld (#4ca3),hl
0622 78 ld a,b
0623 e630 and #30
0625 cb3f srl a
0627 cb3f srl a
0629 cb3f srl a
062b cb3f srl a
062d 32a54c ld (#4ca5),a
0630 78 ld a,b
0631 cb77 bit 6,a
0633 2005 jr nz,#063a ; (5)
0635 21964c ld hl,#4c96
0638 cbfe set 7,(hl)
063a fb ei
063b 3e01 ld a,#01
063d 320050 ld (#5000),a
0640 cd0434 call #3404
0643 21c243 ld hl,#43c2
0646 11c343 ld de,#43c3
0649 013c00 ld bc,#003c
064c 3640 ld (hl),#40
064e edb0 ldir
0650 21c247 ld hl,#47c2
0653 11c347 ld de,#47c3
0656 011c00 ld bc,#001c
0659 3605 ld (hl),#05
065b edb0 ldir
065d 32c050 ld (#50c0),a
0660 21e247 ld hl,#47e2
0663 11e347 ld de,#47e3
0666 011c00 ld bc,#001c
0669 3609 ld (hl),#09
066b edb0 ldir
066d 32c050 ld (#50c0),a
0670 218b18 ld hl,#188b ; load top bad into the screen
0673 11c343 ld de,#43c3
0676 011a00 ld bc,#001a
0679 edb0 ldir
067b af xor a
067c 32e443 ld (#43e4),a
067f 32ed43 ld (#43ed),a
0682 32f643 ld (#43f6),a
0685 21ba39 ld hl,#39ba ; high score defaults table
0688 11b34c ld de,#4cb3 ; ram location for high score table
068b 013c00 ld bc,#003c ; 6 bytes
068e edb0 ldir ; copy it
0690 21b84c ld hl,#4cb8 ; high score ram
0693 11f243 ld de,#43f2
0696 cd2610 call #1026
0699 210240 ld hl,#4002
069c 110340 ld de,#4003
069f 013c00 ld bc,#003c
06a2 3640 ld (hl),#40
06a4 edb0 ldir
06a6 32c050 ld (#50c0),a
06a9 210244 ld hl,#4402
06ac 110344 ld de,#4403
06af 011c00 ld bc,#001c
06b2 3609 ld (hl),#09
06b4 edb0 ldir
06b6 212244 ld hl,#4422
06b9 112344 ld de,#4423
06bc 011c00 ld bc,#001c
06bf 3611 ld (hl),#11
06c1 edb0 ldir
06c3 32c050 ld (#50c0),a
06c6 21a518 ld hl,#18a5 ; CREDIT
06c9 110f40 ld de,#400f
06cc 010600 ld bc,#0006
06cf edb0 ldir
06d1 af xor a
06d2 320c40 ld (#400c),a ; 0 credits. to screen
06d5 3a9b4c ld a,(#4c9b)
06d8 fe00 cp #00
06da 200b jr nz,#06e7 ; (11)
06dc 21ab18 ld hl,#18ab ; FREE PLAY ?
06df 110c40 ld de,#400c
06e2 010900 ld bc,#0009
06e5 edb0 ldir
06e7 32c050 ld (#50c0),a
06ea 21054d ld hl,#4d05
06ed 11064d ld de,#4d06
06f0 01ff00 ld bc,#00ff
06f3 3600 ld (hl),#00 ; clear some ram?
06f5 edb0 ldir
06f7 217435 ld hl,#3574
06fa 221e4d ld (#4d1e),hl
06fd 22064d ld (#4d06),hl
0700 211d4d ld hl,#4d1d
0703 220d4d ld (#4d0d),hl
0706 21a235 ld hl,#35a2
0709 22394d ld (#4d39),hl
070c 22214d ld (#4d21),hl
070f 21384d ld hl,#4d38
0712 22284d ld (#4d28),hl
0715 21b935 ld hl,#35b9
0718 22544d ld (#4d54),hl
071b 223c4d ld (#4d3c),hl
071e 21534d ld hl,#4d53
0721 22434d ld (#4d43),hl
0724 21eb35 ld hl,#35eb
0727 226f4d ld (#4d6f),hl
072a 22574d ld (#4d57),hl
072d 216e4d ld hl,#4d6e
0730 225e4d ld (#4d5e),hl
0733 219836 ld hl,#3698
0736 228a4d ld (#4d8a),hl
0739 22724d ld (#4d72),hl
073c 21894d ld hl,#4d89
073f 22794d ld (#4d79),hl
0742 21ca36 ld hl,#36ca
0745 22a54d ld (#4da5),hl
0748 228d4d ld (#4d8d),hl
074b 21a44d ld hl,#4da4
074e 22944d ld (#4d94),hl
0751 210438 ld hl,#3804
0754 22c04d ld (#4dc0),hl
0757 22a84d ld (#4da8),hl
075a 21bf4d ld hl,#4dbf
075d 22af4d ld (#4daf),hl
0760 211938 ld hl,#3819
0763 22db4d ld (#4ddb),hl
0766 22c34d ld (#4dc3),hl
0769 21da4d ld hl,#4dda
076c 22ca4d ld (#4dca),hl
076f 0620 ld b,#20
0771 214050 ld hl,#5040
0774 3600 ld (hl),#00
0776 23 inc hl
0777 10fb djnz #0774 ; (-5)
0779 3e00 ld a,#00
077b 320350 ld (#5003),a
077e 21964c ld hl,#4c96
0781 cbee set 5,(hl)
0783 3a9b4c ld a,(#4c9b)
0786 fe00 cp #00
0788 ca3909 jp z,#0939
078b 3a9a4c ld a,(#4c9a)
078e fe00 cp #00
0790 c23909 jp nz,#0939
0793 21954c ld hl,#4c95
0796 cba6 res 4,(hl)
0798 af xor a
0799 320150 ld (#5001),a
079c 21964c ld hl,#4c96
079f cb86 res 0,(hl)
07a1 cd0a16 call #160a
07a4 32c050 ld (#50c0),a
07a7 cdd131 call #31d1
07aa 3e01 ld a,#01
07ac cd4f15 call #154f
07af 21954c ld hl,#4c95
07b2 cb6e bit 5,(hl)
07b4 c23909 jp nz,#0939
07b7 cd7c10 call #107c
07ba 3e07 ld a,#07
07bc cd4f15 call #154f
07bf 21954c ld hl,#4c95
07c2 cb6e bit 5,(hl)
07c4 c23909 jp nz,#0939
07c7 3e40 ld a,#40
07c9 cdfd14 call #14fd
07cc 114444 ld de,#4444
07cf 21f639 ld hl,#39f6
07d2 3e01 ld a,#01
07d4 061c ld b,#1c
07d6 cdeb15 call #15eb
07d9 114944 ld de,#4449
07dc 21f839 ld hl,#39f8
07df 3e03 ld a,#03
07e1 061c ld b,#1c
07e3 cdeb15 call #15eb
07e6 115044 ld de,#4450
07e9 21f739 ld hl,#39f7
07ec 3e03 ld a,#03
07ee 061c ld b,#1c
07f0 cdeb15 call #15eb
07f3 115844 ld de,#4458
07f6 21f839 ld hl,#39f8
07f9 3e03 ld a,#03
07fb 061c ld b,#1c
07fd cdeb15 call #15eb
0800 115b44 ld de,#445b
0803 21f939 ld hl,#39f9
0806 3e03 ld a,#03
0808 061c ld b,#1c
080a cdeb15 call #15eb
; Print instructions/scoring screen
080d 11c440 ld de,#40c4
0810 219619 ld hl,#1996 ;MR TNT SCORE ADVANCE
0813 3e01 ld a,#01
0815 0614 ld b,#14
0817 cdd515 call #15d5 ; DRAW TEXT
081a 11c940 ld de,#40c9
081d 21ab19 ld hl,#19ab
0820 3e01 ld a,#01
0822 0614 ld b,#14
0824 cdd515 call #15d5 ; DRAW TEXT
0827 118b40 ld de,#408b
082a 21bf19 ld hl,#19bf
082d 3e01 ld a,#01
082f 0618 ld b,#18
0831 cdd515 call #15d5 ; DRAW TEXT
0834 11b040 ld de,#40b0
0837 21d719 ld hl,#19d7
083a 3e01 ld a,#01
083c 0616 ld b,#16
083e cdd515 call #15d5 ; DRAW TEXT
0841 115241 ld de,#4152
0844 21ed19 ld hl,#19ed
0847 3e01 ld a,#01
0849 060c ld b,#0c
084b cdd515 call #15d5 ; DRAW TEXT
084e 3a9b4c ld a,(#4c9b)
0851 fe01 cp #01
0853 200f jr nz,#0864 ; (15)
0855 111941 ld de,#4119
0858 21f919 ld hl,#19f9
085b 3e01 ld a,#01
085d 060f ld b,#0f
085f cdd515 call #15d5 ; DRAW TEXT
0862 1820 jr #0884 ; (32)
0864 fe02 cp #02
0866 200f jr nz,#0877 ; (15)
0868 111941 ld de,#4119
086b 21081a ld hl,#1a08
086e 3e01 ld a,#01
0870 060f ld b,#0f
0872 cdd515 call #15d5 ; DRAW TEXT
0875 180d jr #0884 ; (13)
0877 111941 ld de,#4119
087a 21171a ld hl,#1a17
087d 3e01 ld a,#01
087f 060f ld b,#0f
0881 cdd515 call #15d5 ; DRAW TEXT
0884 119c40 ld de,#409c
0887 21261a ld hl,#1a26
088a 3e01 ld a,#01
088c 0619 ld b,#19
088e cdd515 call #15d5 ; DRAW TEXT
0891 3aa54c ld a,(#4ca5)
0894 fe00 cp #00
0896 200f jr nz,#08a7 ; (15)
0898 117c41 ld de,#417c
089b 213f1a ld hl,#1a3f
089e 3e01 ld a,#01
08a0 0606 ld b,#06
08a2 cdd515 call #15d5 ; DRAW TEXT
08a5 1833 jr #08da ; (51)
08a7 fe01 cp #01
08a9 200f jr nz,#08ba ; (15)
08ab 117c41 ld de,#417c
08ae 21451a ld hl,#1a45
08b1 3e01 ld a,#01
08b3 0606 ld b,#06
08b5 cdd515 call #15d5 ; DRAW TEXT
08b8 1820 jr #08da ; (32)
08ba fe02 cp #02
08bc 200f jr nz,#08cd ; (15)
08be 117c41 ld de,#417c
08c1 214b1a ld hl,#1a4b
08c4 3e01 ld a,#01
08c6 0606 ld b,#06
08c8 cdd515 call #15d5 ; DRAW TEXT
08cb 180d jr #08da ; (13)
08cd 117c41 ld de,#417c
08d0 21511a ld hl,#1a51
08d3 3e01 ld a,#01
08d5 0606 ld b,#06
08d7 cdd515 call #15d5 ; DRAW TEXT
08da 3e04 ld a,#04
08dc cd4f15 call #154f
08df 21954c ld hl,#4c95
08e2 cb6e bit 5,(hl)
08e4 2053 jr nz,#0939 ; (83)
08e6 cd0534 call #3405
08e9 af xor a
08ea 32ff4c ld (#4cff),a
08ed 32014d ld (#4d01),a
08f0 32034d ld (#4d03),a
08f3 32004d ld (#4d00),a
08f6 32024d ld (#4d02),a
08f9 32044d ld (#4d04),a
08fc cd0734 call #3407
08ff cdfa0e call #0efa
0902 cd1434 call #3414
0905 cdbc1b call #1bbc
0908 af xor a
0909 32204d ld (#4d20),a
090c 323b4d ld (#4d3b),a
090f 32564d ld (#4d56),a
0912 32714d ld (#4d71),a
0915 328c4d ld (#4d8c),a
0918 32a74d ld (#4da7),a
091b 32c24d ld (#4dc2),a
091e cd1516 call #1615
0921 32c050 ld (#50c0),a
0924 21954c ld hl,#4c95
0927 cb6e bit 5,(hl)
0929 200e jr nz,#0939 ; (14)
092b 21964c ld hl,#4c96
092e cb4e bit 1,(hl)
0930 2002 jr nz,#0934 ; (2)
0932 18ce jr #0902 ; (-50)
0934 cb8e res 1,(hl)
0936 c3a107 jp #07a1
; clear flags for a new game ????
0939 cd0a16 call #160a
093c 21954c ld hl,#4c95
093f cbe6 set 4,(hl)
0941 cbae res 5,(hl)
0943 21964c ld hl,#4c96
0946 cb8e res 1,(hl)
0948 cb96 res 2,(hl)
094a cb9e res 3,(hl)
094c 21974c ld hl,#4c97
094f cb96 res 2,(hl)
0951 21964c ld hl,#4c96
0954 cbc6 set 0,(hl)
0956 210c4c ld hl,#4c0c
0959 110d4c ld de,#4c0d
095c 014f00 ld bc,#004f
095f 36ff ld (hl),#ff
0961 edb0 ldir
0963 3eff ld a,#ff
0965 320150 ld (#5001),a
0968 21974c ld hl,#4c97
096b cb56 bit 2,(hl)
096d 200f jr nz,#097e ; (15)
096f 3afd4c ld a,(#4cfd)
0972 3c inc a
0973 32fd4c ld (#4cfd),a
0976 fe14 cp #14
0978 2004 jr nz,#097e ; (4)
097a cbd6 set 2,(hl)
097c cbde set 3,(hl)
097e 00 nop
097f 32c050 ld (#50c0),a
0982 3e40 ld a,#40
0984 cdfd14 call #14fd
0987 3e03 ld a,#03
0989 cd0d15 call #150d
098c 3a9b4c ld a,(#4c9b) ; check credits?
098f fe00 cp #00
0991 ca140a jp z,#0a14 ; 1 or 2 player start
; hook
0994 3a9a4c ld a,(#4c9a) ; check for credits
0997 fe02 cp #02
0999 304c jr nc,#09e7 ; (76) ; 2 credits; jump...
099b 117041 ld de,#4170
099e 21b418 ld hl,#18b4 ; INSERT COIN
09a1 3e01 ld a,#01
09a3 060b ld b,#0b
09a5 cdd515 call #15d5 ; DRAW TEXT
09a8 3a4050 ld a,(#5040) ; in1
09ab cb6f bit 5,a ; START-1
09ad 2074 jr nz,#0a23 ; (116) ; nop nop to instaplay
09af 3a9b4c ld a,(#4c9b)
09b2 fe00 cp #00
09b4 2815 jr z,#09cb ; (21)
09b6 3a9a4c ld a,(#4c9a)
09b9 fe02 cp #02
09bb 3866 jr c,#0a23 ; (102)
09bd d602 sub #02
09bf 329a4c ld (#4c9a),a
09c2 3a9d4c ld a,(#4c9d)
09c5 d601 sub #01
09c7 27 daa
09c8 329d4c ld (#4c9d),a
09cb 21964c ld hl,#4c96
09ce cbe6 set 4,(hl)
09d0 3aa24c ld a,(#4ca2)
09d3 32a64c ld (#4ca6),a
09d6 cd1300 call #0013
09d9 3a9b4c ld a,(#4c9b)
09dc fe00 cp #00
09de ca6f0a jp z,#0a6f
09e1 cd1d15 call #151d
09e4 c36f0a jp #0a6f
; 1 player only credits
09e7 fe04 cp #04
09e9 3029 jr nc,#0a14 ; (41)
09eb 110e41 ld de,#410e
09ee 21bf18 ld hl,#18bf ; SELECT ONE PLAYER
09f1 3e01 ld a,#01
09f3 0611 ld b,#11
09f5 cdd515 call #15d5 ; DRAW TEXT
09f8 111042 ld de,#4210
09fb 21d018 ld hl,#18d0 ; OR
09fe 3e01 ld a,#01
0a00 0602 ld b,#02
0a02 cdd515 call #15d5 ; DRAW TEXT
0a05 117241 ld de,#4172
0a08 21b418 ld hl,#18b4 ; INSERT COIN
0a0b 3e01 ld a,#01
0a0d 060b ld b,#0b
0a0f cdd515 call #15d5 ; DRAW TEXT
0a12 1894 jr #09a8 ; (-108)
0a14 119040 ld de,#4090
0a17 21d218 ld hl,#18d2 ; SELECT ONE OR TWO PLAYERS
0a1a 3e01 ld a,#01
0a1c 0619 ld b,#19
0a1e cdd515 call #15d5 ; DRAW TEXT
0a21 1885 jr #09a8 ; (-123)
; check for player 2 start
0a23 3a4050 ld a,(#5040)
0a26 cb77 bit 6,a ; START-2
0a28 2033 jr nz,#0a5d ; (51) ; nop nop for instaplay
0a2a 3a9b4c ld a,(#4c9b)
0a2d fe00 cp #00
0a2f 2815 jr z,#0a46 ; (21)
0a31 3a9a4c ld a,(#4c9a)
0a34 fe04 cp #04
0a36 3825 jr c,#0a5d ; (37)
0a38 d604 sub #04
0a3a 329a4c ld (#4c9a),a
0a3d 3a9d4c ld a,(#4c9d)
0a40 d602 sub #02
0a42 27 daa
0a43 329d4c ld (#4c9d),a
0a46 21964c ld hl,#4c96
0a49 cba6 res 4,(hl)
0a4b 3aa24c ld a,(#4ca2)
0a4e 32a64c ld (#4ca6),a
0a51 32a74c ld (#4ca7),a
0a54 cd1300 call #0013
0a57 cd2400 call #0024
0a5a c3d909 jp #09d9
; continue?
0a5d 32c050 ld (#50c0),a
0a60 21954c ld hl,#4c95
0a63 cb76 bit 6,(hl)
0a65 2003 jr nz,#0a6a ; (3)
0a67 c3a809 jp #09a8
0a6a cbb6 res 6,(hl)
0a6c c37f09 jp #097f
0a6f af xor a
0a70 21a84c ld hl,#4ca8
0a73 11a94c ld de,#4ca9
0a76 010500 ld bc,#0005
0a79 77 ld (hl),a
0a7a edb0 ldir
0a7c 32b14c ld (#4cb1),a
0a7f 32b24c ld (#4cb2),a
0a82 3e40 ld a,#40
0a84 21e443 ld hl,#43e4
0a87 11e543 ld de,#43e5
0a8a 010500 ld bc,#0005
0a8d 77 ld (hl),a
0a8e edb0 ldir
0a90 21f643 ld hl,#43f6
0a93 11f743 ld de,#43f7
0a96 010500 ld bc,#0005
0a99 77 ld (hl),a
0a9a edb0 ldir
0a9c af xor a
0a9d 32e443 ld (#43e4),a
0aa0 32f643 ld (#43f6),a
0aa3 af xor a
0aa4 32ff4c ld (#4cff),a
0aa7 32014d ld (#4d01),a
0aaa 32034d ld (#4d03),a
0aad 32004d ld (#4d00),a
0ab0 32024d ld (#4d02),a
0ab3 32044d ld (#4d04),a
0ab6 cd0634 call #3406
0ab9 cd1334 call #3413
0abc 21974c ld hl,#4c97
0abf cbce set 1,(hl)
0ac1 21964c ld hl,#4c96
0ac4 cb66 bit 4,(hl)
0ac6 2802 jr z,#0aca ; (2)
0ac8 181a jr #0ae4 ; (26)
0aca 3e00 ld a,#00
0acc 320350 ld (#5003),a
0acf cd4415 call #1544
0ad2 115041 ld de,#4150
0ad5 21eb18 ld hl,#18eb ; Select 1 or 2 player
0ad8 3e01 ld a,#01
0ada 060d ld b,#0d
0adc cdd515 call #15d5 ; DRAW TEXT
0adf 3e03 ld a,#03
0ae1 cd4f15 call #154f
0ae4 21964c ld hl,#4c96
0ae7 cbee set 5,(hl)
0ae9 3aa64c ld a,(#4ca6)
0aec 3d dec a
0aed 32a64c ld (#4ca6),a
0af0 3e40 ld a,#40
0af2 211640 ld hl,#4016
0af5 111740 ld de,#4017
0af8 010800 ld bc,#0008
0afb 77 ld (hl),a
0afc edb0 ldir
0afe cd1300 call #0013
0b01 3aff4c ld a,(#4cff)
0b04 32034d ld (#4d03),a
0b07 3a004d ld a,(#4d00)
0b0a 32044d ld (#4d04),a
0b0d cd6b34 call #346b
0b10 c39b0b jp #0b9b
0b13 21964c ld hl,#4c96
0b16 cb66 bit 4,(hl)
0b18 20ca jr nz,#0ae4 ; (-54)
0b1a cb6e bit 5,(hl)
0b1c 28ac jr z,#0aca ; (-84)
0b1e 3a964c ld a,(#4c96)
0b21 cb7f bit 7,a
0b23 2043 jr nz,#0b68 ; (67)
0b25 cd4415 call #1544
0b28 115041 ld de,#4150
0b2b 21f818 ld hl,#18f8
0b2e 3e01 ld a,#01
0b30 060d ld b,#0d
0b32 cdd515 call #15d5 ; DRAW TEXT
0b35 3e03 ld a,#03
0b37 cd4f15 call #154f
0b3a 21964c ld hl,#4c96
0b3d cbae res 5,(hl)
0b3f 3aa74c ld a,(#4ca7)
0b42 3d dec a
0b43 32a74c ld (#4ca7),a
0b46 3e40 ld a,#40
0b48 210240 ld hl,#4002
0b4b 110340 ld de,#4003
0b4e 010800 ld bc,#0008
0b51 77 ld (hl),a
0b52 edb0 ldir
0b54 cd2400 call #0024
0b57 3a014d ld a,(#4d01)
0b5a 32034d ld (#4d03),a
0b5d 3a024d ld a,(#4d02)
0b60 32044d ld (#4d04),a
0b63 cd6d34 call #346d
0b66 1833 jr #0b9b ; (51)
0b68 3e01 ld a,#01
0b6a 320350 ld (#5003),a
0b6d 18b6 jr #0b25 ; (-74)
0b6f cd4415 call #1544
0b72 21964c ld hl,#4c96
0b75 cb66 bit 4,(hl)
0b77 c2e90a jp nz,#0ae9
0b7a 111041 ld de,#4110
0b7d 210519 ld hl,#1905
0b80 3e01 ld a,#01
0b82 0611 ld b,#11
0b84 cdd515 call #15d5 ; DRAW TEXT
0b87 21204d ld hl,#4d20
0b8a cbc6 set 0,(hl)
0b8c 3e01 ld a,#01
0b8e cd4f15 call #154f
0b91 21964c ld hl,#4c96
0b94 cb6e bit 5,(hl)
0b96 28a7 jr z,#0b3f ; (-89)
0b98 c3e90a jp #0ae9
0b9b cdfa0e call #0efa
0b9e 21974c ld hl,#4c97
0ba1 cb4e bit 1,(hl)
0ba3 2813 jr z,#0bb8 ; (19)
0ba5 cb8e res 1,(hl)
0ba7 21c24d ld hl,#4dc2
0baa cbc6 set 0,(hl)
0bac 32c050 ld (#50c0),a
0baf 3ac24d ld a,(#4dc2)
0bb2 fe00 cp #00
0bb4 20f6 jr nz,#0bac ; (-10)
0bb6 1805 jr #0bbd ; (5)
0bb8 3e02 ld a,#02
0bba cd4f15 call #154f
0bbd 21a74d ld hl,#4da7
0bc0 cbc6 set 0,(hl)
0bc2 21714d ld hl,#4d71
0bc5 cbc6 set 0,(hl)
0bc7 cdbc1b call #1bbc
0bca ed5bae4c ld de,(#4cae)
0bce 7b ld a,e
0bcf b2 or d
0bd0 2809 jr z,#0bdb ; (9)
0bd2 210000 ld hl,#0000
0bd5 22ae4c ld (#4cae),hl
0bd8 cd660f call #0f66
0bdb 32c050 ld (#50c0),a
0bde cd1516 call #1615
0be1 21964c ld hl,#4c96
0be4 cb4e bit 1,(hl)
0be6 28df jr z,#0bc7 ; (-33)
0be8 cb8e res 1,(hl)
0bea cd0a16 call #160a
0bed 21964c ld hl,#4c96
0bf0 cb56 bit 2,(hl)
0bf2 200f jr nz,#0c03 ; (15)
0bf4 cd7134 call #3471
0bf7 cd0a16 call #160a
0bfa 21964c ld hl,#4c96
0bfd cb5e bit 3,(hl)
0bff 2009 jr nz,#0c0a ; (9)
0c01 1867 jr #0c6a ; (103)
0c03 cb96 res 2,(hl)
0c05 cd7034 call #3470
0c08 18ea jr #0bf4 ; (-22)
0c0a cb9e res 3,(hl)
0c0c 21974c ld hl,#4c97
0c0f cbce set 1,(hl)
0c11 21964c ld hl,#4c96
0c14 cb6e bit 5,(hl)
0c16 2029 jr nz,#0c41 ; (41)
0c18 3a014d ld a,(#4d01)
0c1b 3c inc a
0c1c fe0c cp #0c
0c1e 2002 jr nz,#0c22 ; (2)
0c20 3e0b ld a,#0b
0c22 32014d ld (#4d01),a
0c25 32034d ld (#4d03),a
0c28 3a024d ld a,(#4d02)
0c2b 3c inc a
0c2c fe19 cp #19
0c2e 2002 jr nz,#0c32 ; (2)
0c30 3e18 ld a,#18
0c32 32024d ld (#4d02),a
0c35 32044d ld (#4d04),a
0c38 cd7234 call #3472
0c3b cd6f34 call #346f
0c3e c39b0b jp #0b9b
0c41 3aff4c ld a,(#4cff)
0c44 3c inc a
0c45 fe0c cp #0c
0c47 2002 jr nz,#0c4b ; (2)
0c49 3e0b ld a,#0b
0c4b 32ff4c ld (#4cff),a
0c4e 32034d ld (#4d03),a
0c51 3a004d ld a,(#4d00)
0c54 3c inc a
0c55 fe19 cp #19
0c57 2002 jr nz,#0c5b ; (2)
0c59 3e18 ld a,#18
0c5b 32004d ld (#4d00),a
0c5e 32044d ld (#4d04),a
0c61 cd7234 call #3472
0c64 cd6e34 call #346e
0c67 c39b0b jp #0b9b
0c6a 3ab04c ld a,(#4cb0)
0c6d fe00 cp #00
0c6f 202e jr nz,#0c9f ; (46)
0c71 21964c ld hl,#4c96
0c74 cb6e bit 5,(hl)
0c76 202f jr nz,#0ca7 ; (47)
0c78 3aa74c ld a,(#4ca7)
0c7b fe00 cp #00
0c7d 204e jr nz,#0ccd ; (78)
0c7f cd4415 call #1544
0c82 119041 ld de,#4190
0c85 211619 ld hl,#1916 ; GAME OVER - hook
0c88 3e01 ld a,#01
0c8a 0609 ld b,#09
0c8c cdd515 call #15d5 ; DRAW TEXT
0c8f 3e02 ld a,#02
0c91 cd4f15 call #154f
0c94 cdee11 call #11ee
0c97 21954c ld hl,#4c95
0c9a cbf6 set 6,(hl)
0c9c c37907 jp #0779
0c9f d601 sub #01
0ca1 32b04c ld (#4cb0),a
0ca4 c36f0b jp #0b6f
0ca7 3aa64c ld a,(#4ca6)
0caa fe00 cp #00
0cac 2025 jr nz,#0cd3 ; (37)
0cae 21964c ld hl,#4c96
0cb1 cb66 bit 4,(hl)
0cb3 20ca jr nz,#0c7f ; (-54)
0cb5 cd4415 call #1544
0cb8 11f040 ld de,#40f0
0cbb 211f19 ld hl,#191f
0cbe 3e01 ld a,#01
0cc0 0614 ld b,#14
0cc2 cdd515 call #15d5 ; DRAW TEXT
0cc5 3e03 ld a,#03
0cc7 cd4f15 call #154f
0cca c31e0b jp #0b1e
0ccd cd6c34 call #346c
0cd0 c3130b jp #0b13
0cd3 cd6a34 call #346a
0cd6 c3130b jp #0b13
0cd9 2a914c ld hl,(#4c91)
0cdc eb ex de,hl
0cdd dd210000 ld ix,#0000
0ce1 dd19 add ix,de
0ce3 dd7e01 ld a,(ix+#01)
0ce6 dd8602 add a,(ix+#02)
0ce9 47 ld b,a
0cea e60f and #0f
0cec dd7702 ld (ix+#02),a
0cef cb38 srl b
0cf1 cb38 srl b
0cf3 cb38 srl b
0cf5 cb38 srl b
0cf7 dd7e00 ld a,(ix+#00)
0cfa 21070d ld hl,#0d07
0cfd cb27 sla a
0cff cdb015 call #15b0
0d02 5e ld e,(hl)
0d03 23 inc hl
0d04 56 ld d,(hl)
0d05 eb ex de,hl
0d06 e9 jp (hl)
0d07 13 inc de
0d08 0d dec c
0d09 13 inc de
0d0a 0d dec c
0d0b 14 inc d
0d0c 0d dec c
0d0d 1c inc e
0d0e 0d dec c
0d0f 24 inc h
0d10 0d dec c
0d11 2c inc l
0d12 0d dec c
0d13 c9 ret
0d14 dd7e04 ld a,(ix+#04)
0d17 90 sub b
0d18 dd7704 ld (ix+#04),a
0d1b c9 ret
0d1c dd7e04 ld a,(ix+#04)
0d1f 80 add a,b
0d20 dd7704 ld (ix+#04),a
0d23 c9 ret
0d24 dd7e03 ld a,(ix+#03)
0d27 80 add a,b
0d28 dd7703 ld (ix+#03),a
0d2b c9 ret
0d2c dd7e03 ld a,(ix+#03)
0d2f 90 sub b
0d30 dd7703 ld (ix+#03),a
0d33 c9 ret
0d34 2a5e4c ld hl,(#4c5e)
0d37 eb ex de,hl
0d38 dd210000 ld ix,#0000
0d3c dd19 add ix,de
0d3e eb ex de,hl
0d3f 01004c ld bc,#4c00
0d42 37 scf
0d43 3f ccf
0d44 ed42 sbc hl,bc
0d46 e5 push hl
0d47 dd7e00 ld a,(ix+#00)
0d4a 21570d ld hl,#0d57
0d4d cb27 sla a
0d4f cdb015 call #15b0
0d52 5e ld e,(hl)
0d53 23 inc hl
0d54 56 ld d,(hl)
0d55 eb ex de,hl
0d56 e9 jp (hl)
0d57 27 daa
0d58 0e63 ld c,#63
0d5a 0d dec c
0d5b a6 and (hl)
0d5c 0d dec c
0d5d 360e ld (hl),#0e
0d5f 40 ld b,b
0d60 0e53 ld c,#53
0d62 0edd ld c,#dd
0d64 7e ld a,(hl)
0d65 03 inc bc
0d66 325c4c ld (#4c5c),a
0d69 dd7e04 ld a,(ix+#04)
0d6c 325d4c ld (#4c5d),a
0d6f cdbd0e call #0ebd
0d72 dd7e06 ld a,(ix+#06)
0d75 12 ld (de),a
0d76 3a0a4c ld a,(#4c0a)
0d79 fe00 cp #00
0d7b 2017 jr nz,#0d94 ; (23)
0d7d 3a0b4c ld a,(#4c0b)
0d80 fe00 cp #00
0d82 2017 jr nz,#0d9b ; (23)
0d84 c1 pop bc
0d85 210c4c ld hl,#4c0c
0d88 09 add hl,bc
0d89 e5 push hl
0d8a d1 pop de
0d8b 13 inc de
0d8c 010500 ld bc,#0005
0d8f 36ff ld (hl),#ff
0d91 edb0 ldir
0d93 c9 ret
0d94 dd7e06 ld a,(ix+#06)
0d97 13 inc de
0d98 12 ld (de),a
0d99 18e9 jr #0d84 ; (-23)
0d9b dd7e06 ld a,(ix+#06)
0d9e 212000 ld hl,#0020
0da1 19 add hl,de
0da2 eb ex de,hl
0da3 12 ld (de),a
0da4 18de jr #0d84 ; (-34)
0da6 cde50e call #0ee5
0da9 dd7e03 ld a,(ix+#03)
0dac 90 sub b
0dad 325c4c ld (#4c5c),a
0db0 dd7e04 ld a,(ix+#04)
0db3 325d4c ld (#4c5d),a
0db6 cdbd0e call #0ebd
0db9 3a0a4c ld a,(#4c0a)
0dbc fe00 cp #00
0dbe 2832 jr z,#0df2 ; (50)
0dc0 3a0a4c ld a,(#4c0a)
0dc3 cb27 sla a
0dc5 dd4605 ld b,(ix+#05)
0dc8 80 add a,b
0dc9 3d dec a
0dca c1 pop bc
0dcb fd210c4c ld iy,#4c0c
0dcf fd09 add iy,bc
0dd1 fd7300 ld (iy+#00),e
0dd4 fd7201 ld (iy+#01),d
0dd7 fd7702 ld (iy+#02),a
0dda 3c inc a
0ddb 13 inc de
0ddc fd7303 ld (iy+#03),e
0ddf fd7204 ld (iy+#04),d
0de2 fd7705 ld (iy+#05),a
0de5 3a5c4c ld a,(#4c5c)
0de8 dd7703 ld (ix+#03),a
0deb 3a5d4c ld a,(#4c5d)
0dee dd7704 ld (ix+#04),a
0df1 c9 ret
0df2 3a0b4c ld a,(#4c0b)
0df5 fe00 cp #00
0df7 ca5c0e jp z,#0e5c
0dfa 3a0b4c ld a,(#4c0b)
0dfd cb27 sla a
0dff c60f add a,#0f
0e01 dd4605 ld b,(ix+#05)
0e04 80 add a,b
0e05 c1 pop bc
0e06 fd210c4c ld iy,#4c0c
0e0a fd09 add iy,bc
0e0c fd7300 ld (iy+#00),e
0e0f fd7201 ld (iy+#01),d
0e12 fd7702 ld (iy+#02),a
0e15 3c inc a
0e16 212000 ld hl,#0020
0e19 19 add hl,de
0e1a eb ex de,hl
0e1b fd7303 ld (iy+#03),e
0e1e fd7204 ld (iy+#04),d
0e21 fd7705 ld (iy+#05),a
0e24 c3e50d jp #0de5
0e27 dd7e03 ld a,(ix+#03)
0e2a 325c4c ld (#4c5c),a
0e2d dd7e04 ld a,(ix+#04)
0e30 325d4c ld (#4c5d),a
0e33 c3b60d jp #0db6
0e36 cde50e call #0ee5
0e39 dd7e03 ld a,(ix+#03)
0e3c 80 add a,b
0e3d c3ad0d jp #0dad
0e40 cde50e call #0ee5
0e43 dd7e04 ld a,(ix+#04)
0e46 90 sub b
0e47 325d4c ld (#4c5d),a
0e4a dd7e03 ld a,(ix+#03)
0e4d 325c4c ld (#4c5c),a
0e50 c3b60d jp #0db6
0e53 cde50e call #0ee5
0e56 dd7e04 ld a,(ix+#04)
0e59 80 add a,b
0e5a 18eb jr #0e47 ; (-21)
0e5c dd7e05 ld a,(ix+#05)
0e5f c1 pop bc
0e60 fd210c4c ld iy,#4c0c
0e64 fd09 add iy,bc
0e66 fd7300 ld (iy+#00),e
0e69 fd7201 ld (iy+#01),d
0e6c fd7702 ld (iy+#02),a
0e6f 3a5c4c ld a,(#4c5c)
0e72 dd7703 ld (ix+#03),a
0e75 3a5d4c ld a,(#4c5d)
0e78 dd7704 ld (ix+#04),a
0e7b dd7e00 ld a,(ix+#00)
0e7e 21900e ld hl,#0e90
0e81 cb27 sla a
0e83 cdb015 call #15b0
0e86 d5 push de
0e87 5e ld e,(hl)
0e88 23 inc hl
0e89 56 ld d,(hl)
0e8a eb ex de,hl
0e8b d1 pop de
0e8c dd7e06 ld a,(ix+#06)
0e8f e9 jp (hl)
0e90 9c sbc a,h
0e91 0e9c ld c,#9c
0e93 0e9d ld c,#9d
0e95 0ea8 ld c,#a8
0e97 0eab ld c,#ab
0e99 0eb2 ld c,#b2
0e9b 0ec9 ld c,#c9
0e9d 13 inc de
0e9e fd7303 ld (iy+#03),e
0ea1 fd7204 ld (iy+#04),d
0ea4 fd7705 ld (iy+#05),a
0ea7 c9 ret
0ea8 1b dec de
0ea9 18f3 jr #0e9e ; (-13)
0eab 212000 ld hl,#0020
0eae 19 add hl,de
0eaf eb ex de,hl
0eb0 18ec jr #0e9e ; (-20)
0eb2 eb ex de,hl
0eb3 112000 ld de,#0020
0eb6 37 scf
0eb7 3f ccf
0eb8 ed52 sbc hl,de
0eba eb ex de,hl
0ebb 18e1 jr #0e9e ; (-31)
0ebd 3a5c4c ld a,(#4c5c)
0ec0 e607 and #07
0ec2 320a4c ld (#4c0a),a
0ec5 3a5d4c ld a,(#4c5d)
0ec8 e607 and #07
0eca 320b4c ld (#4c0b),a
0ecd 3a5c4c ld a,(#4c5c)
0ed0 cb3f srl a
0ed2 cb3f srl a
0ed4 cb3f srl a
0ed6 57 ld d,a
0ed7 3a5d4c ld a,(#4c5d)
0eda cb3f srl a
0edc cb3f srl a
0ede cb3f srl a
0ee0 5f ld e,a
0ee1 cddf14 call #14df
0ee4 c9 ret
0ee5 dd7e01 ld a,(ix+#01)
0ee8 dd8602 add a,(ix+#02)
0eeb 47 ld b,a
0eec e60f and #0f
0eee dd7702 ld (ix+#02),a
0ef1 cb38 srl b
0ef3 cb38 srl b
0ef5 cb38 srl b
0ef7 cb38 srl b
0ef9 c9 ret
0efa 3a034d ld a,(#4d03)
0efd 21080f ld hl,#0f08
0f00 cb27 sla a
0f02 cb27 sla a
0f04 cdb015 call #15b0
0f07 e9 jp (hl)
0f08 cd2b28 call #282b
0f0b c9 ret
0f0c cd6528 call #2865
0f0f c9 ret
0f10 cd9f28 call #289f
0f13 c9 ret
0f14 cdd928 call #28d9
0f17 c9 ret
0f18 cd1329 call #2913
0f1b c9 ret
0f1c cd4d29 call #294d
0f1f c9 ret
0f20 cd8729 call #2987
0f23 c9 ret
0f24 cdc129 call #29c1
0f27 c9 ret
0f28 cdfb29 call #29fb
0f2b c9 ret
0f2c cd352a call #2a35
0f2f c9 ret
0f30 cd6f2a call #2a6f
0f33 c9 ret
0f34 cda92a call #2aa9
0f37 c9 ret
0f38 cde32a call #2ae3
0f3b c9 ret
0f3c cde42a call #2ae4
0f3f c9 ret
0f40 cde52a call #2ae5
0f43 c9 ret
0f44 cde62a call #2ae6
0f47 c9 ret
0f48 d5 push de
0f49 37 scf
0f4a 3f ccf
0f4b 210e01 ld hl,#010e
0f4e 1600 ld d,#00
0f50 ed52 sbc hl,de
0f52 7d ld a,l
0f53 37 scf
0f54 3f ccf
0f55 211001 ld hl,#0110
0f58 d1 pop de
0f59 5a ld e,d
0f5a 1600 ld d,#00
0f5c ed52 sbc hl,de
0f5e 55 ld d,l
0f5f 5f ld e,a
0f60 c9 ret
0f61 7d ld a,l
0f62 ee03 xor #03
0f64 6f ld l,a
0f65 c9 ret
0f66 21964c ld hl,#4c96
0f69 cb46 bit 0,(hl)
0f6b c8 ret z
0f6c cb6e bit 5,(hl)
0f6e 2843 jr z,#0fb3 ; (67)
0f70 21a84c ld hl,#4ca8
0f73 7b ld a,e
0f74 86 add a,(hl)
0f75 27 daa
0f76 77 ld (hl),a
0f77 23 inc hl
0f78 7a ld a,d
0f79 8e adc a,(hl)
0f7a 27 daa
0f7b 77 ld (hl),a
0f7c 23 inc hl
0f7d 3e00 ld a,#00
0f7f 8e adc a,(hl)
0f80 27 daa
0f81 77 ld (hl),a
0f82 3802 jr c,#0f86 ; (2)
0f84 1832 jr #0fb8 ; (50)
0f86 21964c ld hl,#4c96
0f89 cb6e bit 5,(hl)
0f8b 2813 jr z,#0fa0 ; (19)
0f8d 21f643 ld hl,#43f6
0f90 11f743 ld de,#43f7
0f93 010500 ld bc,#0005
0f96 3640 ld (hl),#40
0f98 edb0 ldir
0f9a af xor a
0f9b 32f643 ld (#43f6),a
0f9e 1818 jr #0fb8 ; (24)
0fa0 21e443 ld hl,#43e4
0fa3 11e543 ld de,#43e5
0fa6 010500 ld bc,#0005
0fa9 3640 ld (hl),#40
0fab edb0 ldir
0fad af xor a
0fae 32e443 ld (#43e4),a
0fb1 1805 jr #0fb8 ; (5)
0fb3 21ab4c ld hl,#4cab
0fb6 18bb jr #0f73 ; (-69)
0fb8 21964c ld hl,#4c96
0fbb cb6e bit 5,(hl)
0fbd 285c jr z,#101b ; (92)
0fbf 21aa4c ld hl,#4caa
0fc2 11fb43 ld de,#43fb
0fc5 3ab14c ld a,(#4cb1)
0fc8 f5 push af
0fc9 cd2610 call #1026
0fcc 23 inc hl
0fcd 23 inc hl
0fce 23 inc hl
0fcf eb ex de,hl
0fd0 2aa34c ld hl,(#4ca3)
0fd3 f1 pop af
0fd4 fe04 cp #04
0fd6 d0 ret nc
0fd7 cb27 sla a
0fd9 cb27 sla a
0fdb 3c inc a
0fdc 3c inc a
0fdd cdb015 call #15b0
0fe0 cdaa11 call #11aa
0fe3 d0 ret nc
0fe4 3ab04c ld a,(#4cb0)
0fe7 3c inc a
0fe8 32b04c ld (#4cb0),a
0feb 21204d ld hl,#4d20
0fee cbc6 set 0,(hl)
0ff0 21964c ld hl,#4c96
0ff3 cb6e bit 5,(hl)
0ff5 2812 jr z,#1009 ; (18)
0ff7 3ab14c ld a,(#4cb1)
0ffa 3c inc a
0ffb 32b14c ld (#4cb1),a
0ffe 3aa64c ld a,(#4ca6)
1001 3c inc a
1002 32a64c ld (#4ca6),a
1005 cd1300 call #0013
1008 c9 ret
1009 3ab24c ld a,(#4cb2)
100c 3c inc a
100d 32b24c ld (#4cb2),a
1010 3aa74c ld a,(#4ca7)
1013 3c inc a
1014 32a74c ld (#4ca7),a
1017 cd2400 call #0024
101a c9 ret
101b 21ad4c ld hl,#4cad
101e 11e943 ld de,#43e9
1021 3ab24c ld a,(#4cb2)
1024 18a2 jr #0fc8 ; (-94)
; draw the score out to the screen...
1026 3e03 ld a,#03
1028 f5 push af
1029 7e ld a,(hl)
102a e6f0 and #f0
102c cb3f srl a
102e cb3f srl a
1030 cb3f srl a
1032 cb3f srl a
1034 47 ld b,a
1035 3a964c ld a,(#4c96)
1038 cb77 bit 6,a
103a 2822 jr z,#105e ; (34)
103c 78 ld a,b
103d 12 ld (de),a
103e 1b dec de
103f 7e ld a,(hl)
1040 e60f and #0f
1042 47 ld b,a
1043 3a964c ld a,(#4c96)
1046 cb77 bit 6,a
1048 32964c ld (#4c96),a
104b 2820 jr z,#106d ; (32)
104d 78 ld a,b
104e 12 ld (de),a
104f 2b dec hl
1050 1b dec de
1051 f1 pop af
1052 3d dec a
1053 20d3 jr nz,#1028 ; (-45)
1055 3a964c ld a,(#4c96)
1058 cbb7 res 6,a
105a 32964c ld (#4c96),a
105d c9 ret
105e 78 ld a,b
105f fe00 cp #00
1061 28db jr z,#103e ; (-37)
1063 3a964c ld a,(#4c96)
1066 cbf7 set 6,a
1068 32964c ld (#4c96),a
106b 18cf jr #103c ; (-49)
106d 78 ld a,b
106e fe00 cp #00
1070 28dd jr z,#104f ; (-35)
1072 3a964c ld a,(#4c96)
1075 cbf7 set 6,a
1077 32964c ld (#4c96),a
107a 18d1 jr #104d ; (-47)
107c 21974c ld hl,#4c97
107f cb5e bit 3,(hl)
1081 282c jr z,#10af ; (44)
1083 cb9e res 3,(hl)
1085 214040 ld hl,#4040
1088 cda110 call #10a1
108b fe3a cp #3a
108d 200c jr nz,#109b ; (12)
108f 214044 ld hl,#4440
1092 cda110 call #10a1
1095 fe9c cp #9c
1097 2002 jr nz,#109b ; (2)
1099 1814 jr #10af ; (20)
109b af xor a
109c 329b4c ld (#4c9b),a
109f 180e jr #10af ; (14)
10a1 af xor a
10a2 118003 ld de,#0380
10a5 86 add a,(hl)
10a6 23 inc hl
10a7 1b dec de
10a8 47 ld b,a
10a9 7a ld a,d
10aa b3 or e
10ab 78 ld a,b
10ac 20f7 jr nz,#10a5 ; (-9)
10ae c9 ret
10af 00 nop
10b0 3e40 ld a,#40
10b2 cdfd14 call #14fd
10b5 3e09 ld a,#09
10b7 cd0d15 call #150d
10ba 112945 ld de,#4529
10bd 21ee10 ld hl,#10ee
10c0 3e15 ld a,#15
10c2 060b ld b,#0b
10c4 cdeb15 call #15eb
10c7 114541 ld de,#4145
10ca 213319 ld hl,#1933
10cd 3e01 ld a,#01
10cf 060c ld b,#0c
10d1 cdd515 call #15d5 ; DRAW TEXT
10d4 215f1b ld hl,#1b5f
10d7 11ca42 ld de,#42ca
10da 01ff09 ld bc,#09ff
10dd eda0 ldi
10df 13 inc de
10e0 10fb djnz #10dd ; (-5)
10e2 af xor a
10e3 12 ld (de),a
10e4 cd0216 call #1602
10e7 3e01 ld a,#01
10e9 12 ld (de),a
10ea cdef10 call #10ef
10ed c9 ret
10ee 03 inc bc
10ef 21b34c ld hl,#4cb3
10f2 116a42 ld de,#426a
10f5 cd2f11 call #112f
10f8 116c42 ld de,#426c
10fb cd2f11 call #112f
10fe 116e42 ld de,#426e
1101 cd2f11 call #112f
1104 117042 ld de,#4270
1107 cd2f11 call #112f
110a 117242 ld de,#4272
110d cd2f11 call #112f
1110 117442 ld de,#4274
1113 cd2f11 call #112f
1116 117642 ld de,#4276
1119 cd2f11 call #112f
111c 117842 ld de,#4278
111f cd2f11 call #112f
1122 117a42 ld de,#427a
1125 cd2f11 call #112f
1128 117c42 ld de,#427c
112b cd2f11 call #112f
112e c9 ret
112f 0603 ld b,#03
1131 0e0f ld c,#0f
1133 3e21 ld a,#21
1135 eda0 ldi
1137 cdc915 call #15c9
113a 10f7 djnz #1133 ; (-9)
113c 23 inc hl
113d 23 inc hl
113e 3e40 ld a,#40
1140 cdc915 call #15c9
1143 cd4c11 call #114c
1146 3e04 ld a,#04
1148 cdb015 call #15b0
114b c9 ret
; sets up something with the scores...
114c 3e03 ld a,#03
114e f5 push af
114f 7e ld a,(hl)
1150 e6f0 and #f0
1152 cb3f srl a
1154 cb3f srl a
1156 cb3f srl a
1158 cb3f srl a
115a 47 ld b,a
115b 3a964c ld a,(#4c96)
115e cb77 bit 6,a
1160 282a jr z,#118c ; (42)
1162 78 ld a,b
1163 12 ld (de),a
1164 3e20 ld a,#20
1166 cdc915 call #15c9
1169 7e ld a,(hl)
116a e60f and #0f
116c 47 ld b,a
116d 3a964c ld a,(#4c96)
1170 cb77 bit 6,a
1172 32964c ld (#4c96),a
1175 2824 jr z,#119b ; (36)
1177 78 ld a,b
1178 12 ld (de),a
1179 2b dec hl
117a 3e20 ld a,#20
117c cdc915 call #15c9
117f f1 pop af
1180 3d dec a
1181 20cb jr nz,#114e ; (-53)
1183 3a964c ld a,(#4c96)
1186 cbb7 res 6,a
1188 32964c ld (#4c96),a
118b c9 ret
118c 78 ld a,b
118d fe00 cp #00
118f 28d3 jr z,#1164 ; (-45)
1191 3a964c ld a,(#4c96)
1194 cbf7 set 6,a
1196 32964c ld (#4c96),a
1199 18c7 jr #1162 ; (-57)
119b 78 ld a,b
119c fe00 cp #00
119e 28d9 jr z,#1179 ; (-39)
11a0 3a964c ld a,(#4c96)
11a3 cbf7 set 6,a
11a5 32964c ld (#4c96),a
11a8 18cd jr #1177 ; (-51)
11aa 0603 ld b,#03
11ac 1a ld a,(de)
11ad be cp (hl)
11ae 3808 jr c,#11b8 ; (8)
11b0 200e jr nz,#11c0 ; (14)
11b2 2b dec hl
11b3 1b dec de
11b4 10f6 djnz #11ac ; (-10)
11b6 1806 jr #11be ; (6)
11b8 cdc511 call #11c5
11bb 37 scf
11bc 3f ccf
11bd c9 ret
11be 37 scf
11bf c9 ret
11c0 cdc511 call #11c5
11c3 37 scf
11c4 c9 ret
11c5 78 ld a,b
11c6 fe00 cp #00
11c8 c8 ret z
11c9 2b dec hl
11ca 1b dec de
11cb 3d dec a
11cc 20fb jr nz,#11c9 ; (-5)
11ce c9 ret
11cf 4b ld c,e
000011d0 4d 52 20 54 4e 54 2c 43 4f 50 59 52 49 47 48 54 |MR TNT,COPYRIGHT|
000011e0 20 31 39 38 33 54 45 4c 4b 4f 20 49 4e 43 21 96 | 1983TELKO INC!.|
11ee 21964c ld hl,#4c96
11f1 cbee set 5,(hl)
11f3 21a84c ld hl,#4ca8
11f6 11f54c ld de,#4cf5
11f9 010300 ld bc,#0003
11fc edb0 ldir
11fe cd1812 call #1218
1201 21964c ld hl,#4c96
1204 cb66 bit 4,(hl)
1206 c0 ret nz
1207 cbae res 5,(hl)
1209 21ab4c ld hl,#4cab
120c 11f54c ld de,#4cf5
120f 010300 ld bc,#0003
1212 edb0 ldir
1214 cd1812 call #1218
1217 c9 ret
1218 01000a ld bc,#0a00
121b 21f14c ld hl,#4cf1
121e 11f74c ld de,#4cf7
1221 2b dec hl
1222 2b dec hl
1223 2b dec hl
1224 c5 push bc
1225 cdaa11 call #11aa
1228 c1 pop bc
1229 300a jr nc,#1235 ; (10)
122b 3e06 ld a,#06
122d 81 add a,c
122e 4f ld c,a
122f 10ed djnz #121e ; (-19)
1231 2b dec hl
1232 2b dec hl
1233 1808 jr #123d ; (8)
1235 79 ld a,c
1236 fe00 cp #00
1238 c8 ret z
1239 23 inc hl
123a 23 inc hl
123b 23 inc hl
123c 23 inc hl
123d c5 push bc
123e e5 push hl
123f 0600 ld b,#00
1241 21ee4c ld hl,#4cee
1244 11f44c ld de,#4cf4
1247 edb8 lddr
1249 3e40 ld a,#40
124b cdfd14 call #14fd
124e 21964c ld hl,#4c96
1251 cb6e bit 5,(hl)
1253 201b jr nz,#1270 ; (27)
1255 116241 ld de,#4162
1258 21fb18 ld hl,#18fb
125b 3e01 ld a,#01
125d 060a ld b,#0a
125f cdd515 call #15d5 ; DRAW TEXT
1262 21964c ld hl,#4c96
1265 cb7e bit 7,(hl)
1267 2819 jr z,#1282 ; (25)
1269 3e01 ld a,#01
126b 320350 ld (#5003),a
126e 1812 jr #1282 ; (18)
1270 116241 ld de,#4162
1273 21ee18 ld hl,#18ee
1276 3e01 ld a,#01
1278 060a ld b,#0a
127a cdd515 call #15d5 ; DRAW TEXT
127d 3e00 ld a,#00
127f 320350 ld (#5003),a
1282 114044 ld de,#4440
1285 21db14 ld hl,#14db
1288 3e0b ld a,#0b
128a 061c ld b,#1c
128c cdeb15 call #15eb
128f 114c44 ld de,#444c
1292 21dc14 ld hl,#14dc
1295 3e03 ld a,#03
1297 061c ld b,#1c
1299 cdeb15 call #15eb
129c 115144 ld de,#4451
129f 21dd14 ld hl,#14dd
12a2 3e10 ld a,#10
12a4 061c ld b,#1c
12a6 cdeb15 call #15eb
12a9 115044 ld de,#4450
12ac 21de14 ld hl,#14de
12af 3e02 ld a,#02
12b1 061c ld b,#1c
12b3 cdeb15 call #15eb
12b6 d1 pop de
12b7 d5 push de
12b8 3e40 ld a,#40
k
12ba d5 push de
12bb e1 pop hl
12bc 13 inc de
12bd 010300 ld bc,#0003
12c0 77 ld (hl),a
12c1 edb0 ldir
12c3 3600 ld (hl),#00
12c5 010200 ld bc,#0002
12c8 edb0 ldir
12ca d1 pop de
12cb c1 pop bc
12cc d5 push de
12cd 78 ld a,b
12ce 21a01b ld hl,#1ba0
12d1 cb27 sla a
12d3 cdb015 call #15b0
12d6 4e ld c,(hl)
12d7 23 inc hl
12d8 46 ld b,(hl)
12d9 c5 push bc
12da 218004 ld hl,#0480 ; dest for hs ram?
12dd 09 add hl,bc
12de 0e01 ld c,#01
12e0 060f ld b,#0f
12e2 71 ld (hl),c ; setup ram for user input
12e3 3e20 ld a,#20
12e5 cdbf15 call #15bf
12e8 10f8 djnz #12e2 ; (-8)
12ea 11c340 ld de,#40c3
12ed 213f19 ld hl,#193f ; YOUR SCORE IS IN THE
12f0 3e01 ld a,#01
12f2 0614 ld b,#14
12f4 cdd515 call #15d5 ; DRAW TEXT
12f7 11a541 ld de,#41a5
12fa 215319 ld hl,#1953 ; TOP TEN - hook
12fd 3e01 ld a,#01
12ff 0607 ld b,#07
1301 cdd515 call #15d5 ; DRAW TEXT
1304 11a740 ld de,#40a7
1307 215a19 ld hl,#195a
130a 3e01 ld a,#01
130c 0616 ld b,#16
130e cdd515 call #15d5 ; DRAW TEXT
1311 118840 ld de,#4088
1314 217019 ld hl,#1970
1317 3e01 ld a,#01
1319 0617 ld b,#17
131b cdd515 call #15d5 ; DRAW TEXT
131e 116942 ld de,#4269
1321 218719 ld hl,#1987
1324 3e01 ld a,#01
1326 0608 ld b,#08
1328 cdd515 call #15d5 ; DRAW TEXT
132b 114c40 ld de,#404c
132e 218f19 ld hl,#198f
1331 3e03 ld a,#03
1333 0601 ld b,#01
1335 cdd515 call #15d5 ; DRAW TEXT
1338 118d40 ld de,#408d
133b 21821b ld hl,#1b82
133e 3e01 ld a,#01
1340 061a ld b,#1a
1342 cdd515 call #15d5 ; DRAW TEXT
1345 3e01 ld a,#01
1347 11ad47 ld de,#47ad
134a 12 ld (de),a
134b af xor a
134c 32f94c ld (#4cf9),a
134f 32fa4c ld (#4cfa),a
1352 21ad47 ld hl,#47ad
1355 22fb4c ld (#4cfb),hl
1358 117141 ld de,#4171
135b 213319 ld hl,#1933
135e 3e01 ld a,#01
1360 060c ld b,#0c
1362 cdd515 call #15d5 ; DRAW TEXT
1365 215f1b ld hl,#1b5f
1368 11f442 ld de,#42f4
136b 010900 ld bc,#0009
136e edb0 ldir
1370 af xor a
1371 12 ld (de),a
1372 cd0216 call #1602
1375 3e01 ld a,#01
1377 12 ld (de),a
1378 21b34c ld hl,#4cb3 ; perhaps the thing that shifts scores?
137b 119442 ld de,#4294
137e cd2f11 call #112f
1381 119542 ld de,#4295
1384 cd2f11 call #112f
1387 119642 ld de,#4296
138a cd2f11 call #112f
138d 119742 ld de,#4297
1390 cd2f11 call #112f
1393 119842 ld de,#4298
1396 cd2f11 call #112f
1399 119942 ld de,#4299
139c cd2f11 call #112f
139f 119a42 ld de,#429a
13a2 cd2f11 call #112f
13a5 119b42 ld de,#429b
13a8 cd2f11 call #112f
13ab 119c42 ld de,#429c
13ae cd2f11 call #112f
13b1 119d42 ld de,#429d
13b4 cd2f11 call #112f
13b7 3af84c ld a,(#4cf8) ; user input stuff?
13ba cb4f bit 1,a
13bc ca4314 jp z,#1443
13bf cb57 bit 2,a
13c1 ca7b14 jp z,#147b
13c4 3af84c ld a,(#4cf8)
13c7 cb67 bit 4,a
13c9 c2bc14 jp nz,#14bc
13cc 3af94c ld a,(#4cf9) ; fire?
13cf fe1b cp #1b
13d1 281f jr z,#13f2 ; (31)
13d3 21681b ld hl,#1b68
13d6 cdb015 call #15b0
13d9 7e ld a,(hl)
13da e1 pop hl
13db d1 pop de
13dc 12 ld (de),a
13dd 13 inc de
13de 77 ld (hl),a
13df 3e20 ld a,#20
13e1 cdbf15 call #15bf
13e4 d5 push de
13e5 e5 push hl
13e6 3afa4c ld a,(#4cfa)
13e9 3c inc a
13ea 32fa4c ld (#4cfa),a
13ed fe03 cp #03
13ef c2cf14 jp nz,#14cf
13f2 21b41b ld hl,#1bb4 ; XXXX
13f5 3afa4c ld a,(#4cfa)
13f8 cdb015 call #15b0
13fb 7e ld a,(hl)
13fc e1 pop hl
13fd d1 pop de
13fe e5 push hl
13ff cdb515 call #15b5
1402 21f54c ld hl,#4cf5
1405 010300 ld bc,#0003
1408 edb0 ldir
140a 3afa4c ld a,(#4cfa)
140d fe00 cp #00
140f 2825 jr z,#1436 ; (37)
1411 21b81b ld hl,#1bb8
1414 cdb015 call #15b0
1417 7e ld a,(hl)
1418 d1 pop de
1419 cdc915 call #15c9
141c 21f74c ld hl,#4cf7
141f cd4c11 call #114c
1422 21b84c ld hl,#4cb8 ; top score redraw (high score edit)
1425 11f243 ld de,#43f2
1428 cd2610 call #1026
142b 21974c ld hl,#4c97
142e cb86 res 0,(hl)
1430 3e01 ld a,#01
1432 cd4f15 call #154f
1435 c9 ret
1436 d1 pop de
1437 3e80 ld a,#80
1439 cdc915 call #15c9
143c 3e20 ld a,#20
143e cdc915 call #15c9
1441 18d9 jr #141c ; (-39)
;user input for hs entry
1443 3af94c ld a,(#4cf9)
1446 fe00 cp #00
1448 cac413 jp z,#13c4
144b 3d dec a
144c 32f94c ld (#4cf9),a
144f fe1a cp #1a
1451 2814 jr z,#1467 ; (20)
1453 3e05 ld a,#05
1455 2afb4c ld hl,(#4cfb)
1458 77 ld (hl),a
1459 3e20 ld a,#20
145b cdb015 call #15b0
145e 22fb4c ld (#4cfb),hl
1461 3e01 ld a,#01
1463 77 ld (hl),a
1464 c3c413 jp #13c4
1467 3d dec a
1468 32f94c ld (#4cf9),a
146b 3e05 ld a,#05
146d 2afb4c ld hl,(#4cfb)
1470 2b dec hl
1471 77 ld (hl),a
1472 23 inc hl
1473 77 ld (hl),a
1474 23 inc hl
1475 77 ld (hl),a
1476 2b dec hl
1477 3e40 ld a,#40
1479 18e0 jr #145b ; (-32)
147b 3af94c ld a,(#4cf9)
147e fe1b cp #1b
1480 cac413 jp z,#13c4
1483 3c inc a
1484 32f94c ld (#4cf9),a
1487 fe1a cp #1a
1489 2814 jr z,#149f ; (20)
148b 3e05 ld a,#05
148d 2afb4c ld hl,(#4cfb)
1490 77 ld (hl),a
1491 3e20 ld a,#20
1493 cdbf15 call #15bf
1496 22fb4c ld (#4cfb),hl
1499 3e01 ld a,#01
149b 77 ld (hl),a
149c c3c413 jp #13c4
149f 3c inc a
14a0 32f94c ld (#4cf9),a
14a3 3e05 ld a,#05
14a5 2afb4c ld hl,(#4cfb)
14a8 77 ld (hl),a
14a9 3e40 ld a,#40
14ab cdbf15 call #15bf
14ae 22fb4c ld (#4cfb),hl
14b1 3e01 ld a,#01
14b3 2b dec hl
14b4 77 ld (hl),a
14b5 23 inc hl
14b6 77 ld (hl),a
14b7 23 inc hl
14b8 77 ld (hl),a
14b9 c3c413 jp #13c4
14bc 3e08 ld a,#08
14be cd9b15 call #159b
14c1 32c050 ld (#50c0),a
14c4 0614 ld b,#14
14c6 cd6715 call #1567
14c9 daf213 jp c,#13f2
14cc c3b713 jp #13b7
14cf 3af84c ld a,(#4cf8)
14d2 cb67 bit 4,a
14d4 32c050 ld (#50c0),a
14d7 28f6 jr z,#14cf ; (-10)
14d9 18e6 jr #14c1 ; (-26)
14db 09 add hl,bc
14dc 05 dec b
14dd 1001 djnz #14e0 ; (1)
14df d5 push de
14e0 af xor a
14e1 cb23 sla e
14e3 17 rla
14e4 cb23 sla e
14e6 17 rla
14e7 cb23 sla e
14e9 17 rla
14ea cb23 sla e
14ec 17 rla
14ed cb23 sla e
14ef 17 rla
14f0 57 ld d,a
14f1 eb ex de,hl
14f2 014040 ld bc,#4040
14f5 09 add hl,bc
14f6 0600 ld b,#00
14f8 d1 pop de
14f9 4a ld c,d
14fa 09 add hl,bc
14fb eb ex de,hl
14fc c9 ret
14fd 214040 ld hl,#4040
1500 114140 ld de,#4041
1503 017f03 ld bc,#037f
1506 77 ld (hl),a
1507 edb0 ldir
1509 32c050 ld (#50c0),a
150c c9 ret
150d 214044 ld hl,#4440
1510 114144 ld de,#4441
1513 017f03 ld bc,#037f
1516 77 ld (hl),a
1517 edb0 ldir
1519 32c050 ld (#50c0),a
151c c9 ret
151d 3a9b4c ld a,(#4c9b)
1520 fe00 cp #00
1522 c8 ret z
; CREDIT count drawn to screen...
1523 3a9d4c ld a,(#4c9d)
1526 e6f0 and #f0
1528 cb3f srl a
152a cb3f srl a
152c cb3f srl a
152e cb3f srl a
1530 fe00 cp #00
1532 280c jr z,#1540 ; (12)
1534 320d40 ld (#400d),a
1537 3a9d4c ld a,(#4c9d)
153a e60f and #0f
153c 320c40 ld (#400c),a
153f c9 ret
1540 3e40 ld a,#40
1542 18f0 jr #1534 ; (-16)
1544 3e09 ld a,#09
1546 cd0d15 call #150d
1549 3e40 ld a,#40
154b cdfd14 call #14fd
154e c9 ret
154f 47 ld b,a
1550 af xor a
1551 329e4c ld (#4c9e),a
1554 32a04c ld (#4ca0),a
1557 3aa04c ld a,(#4ca0)
155a b8 cp b
155b c8 ret z
155c 21954c ld hl,#4c95
155f cb6e bit 5,(hl)
1561 c0 ret nz
1562 32c050 ld (#50c0),a
1565 18f0 jr #1557 ; (-16)
1567 3a974c ld a,(#4c97)
156a cb47 bit 0,a
156c 280d jr z,#157b ; (13)
156e 3aa14c ld a,(#4ca1)
1571 47 ld b,a
1572 3aa04c ld a,(#4ca0)
1575 b8 cp b
1576 3019 jr nc,#1591 ; (25)
1578 37 scf
1579 3f ccf
157a c9 ret
157b 78 ld a,b
157c 32a14c ld (#4ca1),a
157f 3a974c ld a,(#4c97)
1582 cbc7 set 0,a
1584 32974c ld (#4c97),a
1587 af xor a
1588 32a04c ld (#4ca0),a
158b 329e4c ld (#4c9e),a
158e 37 scf
158f 3f ccf
1590 c9 ret
1591 3a974c ld a,(#4c97)
1594 cb87 res 0,a
1596 32974c ld (#4c97),a
1599 37 scf
159a c9 ret
159b 47 ld b,a
159c af xor a
159d 329f4c ld (#4c9f),a
15a0 3a9f4c ld a,(#4c9f)
15a3 b8 cp b
15a4 c8 ret z
15a5 21954c ld hl,#4c95
15a8 cb6e bit 5,(hl)
15aa c0 ret nz
15ab 32c050 ld (#50c0),a
15ae 18f0 jr #15a0 ; (-16)
15b0 85 add a,l
15b1 6f ld l,a
15b2 d0 ret nc
15b3 24 inc h
15b4 c9 ret
15b5 83 add a,e
15b6 5f ld e,a
15b7 d0 ret nc
15b8 14 inc d
15b9 c9 ret
15ba 81 add a,c
15bb 4f ld c,a
15bc d0 ret nc
15bd 04 inc b
15be c9 ret
15bf d5 push de
15c0 1600 ld d,#00
15c2 5f ld e,a
15c3 37 scf
15c4 3f ccf
15c5 ed52 sbc hl,de
15c7 d1 pop de
15c8 c9 ret
15c9 e5 push hl
15ca eb ex de,hl
15cb 1600 ld d,#00
15cd 5f ld e,a
15ce 37 scf
15cf 3f ccf
15d0 ed52 sbc hl,de
15d2 eb ex de,hl
15d3 e1 pop hl
15d4 c9 ret
; draw text to the screen
15d5 32604c ld (#4c60),a
15d8 d5 push de
15d9 3a604c ld a,(#4c60)
15dc 4f ld c,a
15dd eda0 ldi
15df 79 ld a,c
15e0 fe00 cp #00
15e2 20f9 jr nz,#15dd ; (-7)
15e4 d1 pop de
15e5 cd0216 call #1602
15e8 10ee djnz #15d8 ; (-18)
15ea c9 ret
15eb 32604c ld (#4c60),a
15ee d5 push de
15ef 3a604c ld a,(#4c60)
15f2 4f ld c,a
15f3 eda0 ldi
15f5 2b dec hl
15f6 79 ld a,c
15f7 fe00 cp #00
15f9 20f8 jr nz,#15f3 ; (-8)
15fb d1 pop de
15fc cd0216 call #1602
15ff 10ed djnz #15ee ; (-19)
1601 c9 ret
1602 e5 push hl
1603 212000 ld hl,#0020
1606 19 add hl,de
1607 eb ex de,hl
1608 e1 pop hl
1609 c9 ret
160a 21614c ld hl,#4c61
160d 062f ld b,#2f
160f 3600 ld (hl),#00
1611 23 inc hl
1612 10fb djnz #160f ; (-5)
1614 c9 ret
1615 21954c ld hl,#4c95
1618 cbfe set 7,(hl)
161a cb7e bit 7,(hl)
161c c8 ret z
161d 18fb jr #161a ; (-5)
161f 3a0050 ld a,(#5000) ; XXX in0
1622 e60f and #0f ; movement p1
1624 47 ld b,a
1625 3a4050 ld a,(#5040) ; buttons
1628 e6f0 and #f0 ; buttons, start
162a b0 or b
162b 32f84c ld (#4cf8),a
162e c9 ret
162f 3a4050 ld a,(#5040) ; movement
1632 47 ld b,a
1633 e60f and #0f
1635 cb78 bit 7,b ; button 2
1637 2802 jr z,#163b ; (2)
1639 cbe7 set 4,a ; button 1
163b 32f84c ld (#4cf8),a
163e c9 ret
163f dd21054d ld ix,#4d05
1643 ddcb0046 bit 0,(ix+#00)
1647 c47017 call nz,#1770
164a ddcb0056 bit 2,(ix+#00)
164e 2810 jr z,#1660 ; (16)
1650 cd7817 call #1778
1653 fd215150 ld iy,#5051
1657 cd4717 call #1747
165a dd7e06 ld a,(ix+#06)
165d 324550 ld (#5045),a
1660 dd21204d ld ix,#4d20
1664 ddcb0046 bit 0,(ix+#00)
1668 c47017 call nz,#1770
166b ddcb0056 bit 2,(ix+#00)
166f 2810 jr z,#1681 ; (16)
1671 cd7817 call #1778
1674 fd215150 ld iy,#5051
1678 cd4717 call #1747
167b dd7e06 ld a,(ix+#06)
167e 324550 ld (#5045),a
1681 dd213b4d ld ix,#4d3b
1685 ddcb0046 bit 0,(ix+#00)
1689 c47017 call nz,#1770
168c ddcb0056 bit 2,(ix+#00)
1690 2810 jr z,#16a2 ; (16)
1692 cd7817 call #1778
1695 fd215150 ld iy,#5051
1699 cd4717 call #1747
169c dd7e06 ld a,(ix+#06)
169f 324550 ld (#5045),a
16a2 dd21564d ld ix,#4d56
16a6 ddcb0046 bit 0,(ix+#00)
16aa c47017 call nz,#1770
16ad ddcb0056 bit 2,(ix+#00)
16b1 2810 jr z,#16c3 ; (16)
16b3 cd7817 call #1778
16b6 fd215650 ld iy,#5056
16ba cd4717 call #1747
16bd dd7e06 ld a,(ix+#06)
16c0 324a50 ld (#504a),a
16c3 dd21714d ld ix,#4d71
16c7 ddcb0046 bit 0,(ix+#00)
16cb c47017 call nz,#1770
16ce ddcb0056 bit 2,(ix+#00)
16d2 2810 jr z,#16e4 ; (16)
16d4 cd7817 call #1778
16d7 fd215650 ld iy,#5056
16db cd4717 call #1747
16de dd7e06 ld a,(ix+#06)
16e1 324a50 ld (#504a),a
16e4 dd218c4d ld ix,#4d8c
16e8 ddcb0046 bit 0,(ix+#00)
16ec c47017 call nz,#1770
16ef ddcb0056 bit 2,(ix+#00)
16f3 2810 jr z,#1705 ; (16)
16f5 cd7817 call #1778
16f8 fd215650 ld iy,#5056
16fc cd4717 call #1747
16ff dd7e06 ld a,(ix+#06)
1702 324a50 ld (#504a),a
1705 dd21a74d ld ix,#4da7
1709 ddcb0046 bit 0,(ix+#00)
170d c47017 call nz,#1770
1710 ddcb0056 bit 2,(ix+#00)
1714 2810 jr z,#1726 ; (16)
1716 cd7817 call #1778
1719 fd215b50 ld iy,#505b
171d cd4717 call #1747
1720 dd7e06 ld a,(ix+#06)
1723 324f50 ld (#504f),a
1726 dd21c24d ld ix,#4dc2
172a ddcb0046 bit 0,(ix+#00)
172e c47017 call nz,#1770
1731 ddcb0056 bit 2,(ix+#00)
1735 c8 ret z
1736 cd7817 call #1778
1739 fd215b50 ld iy,#505b
173d cd4717 call #1747
1740 dd7e06 ld a,(ix+#06)
1743 324f50 ld (#504f),a
1746 c9 ret
1747 dd7e03 ld a,(ix+#03)
174a fd7700 ld (iy+#00),a
174d cb3f srl a
174f cb3f srl a
1751 cb3f srl a
1753 cb3f srl a
1755 fd7701 ld (iy+#01),a
1758 dd7e04 ld a,(ix+#04)
175b fd7702 ld (iy+#02),a
175e cb3f srl a
1760 cb3f srl a
1762 cb3f srl a
1764 cb3f srl a
1766 fd7703 ld (iy+#03),a
1769 dd7e05 ld a,(ix+#05)
176c fd7704 ld (iy+#04),a
176f c9 ret
1770 cd4c18 call #184c
1773 ddcb00d6 set 2,(ix+#00)
1777 c9 ret
1778 ddcb004e bit 1,(ix+#00)
177c c24c18 jp nz,#184c
177f dd6e01 ld l,(ix+#01)
1782 dd6602 ld h,(ix+#02)
1785 7e ld a,(hl)
1786 cb27 sla a
1788 119617 ld de,#1796
178b cdb515 call #15b5
178e 23 inc hl
178f e5 push hl
1790 1a ld a,(de)
1791 6f ld l,a
1792 13 inc de
1793 1a ld a,(de)
1794 67 ld h,a
1795 e9 jp (hl)
1796 b0 or b
1797 17 rla
1798 b4 or h
1799 17 rla
179a c217cb jp nz,#cb17
179d 17 rla
179e e1 pop hl
179f 17 rla
17a0 ee17 xor #17
17a2 08 ex af,af'
17a3 1821 jr #17c6 ; (33)
17a5 1843 jr #17ea ; (67)
17a7 184b jr #17f4 ; (75)
17a9 186a jr #1815 ; (106)
17ab 1876 jr #1823 ; (118)
17ad 1882 jr #1731 ; (-126)
17af 18e1 jr #1792 ; (-31)
17b1 c38517 jp #1785
17b4 e1 pop hl
17b5 7e ld a,(hl)
17b6 dd7703 ld (ix+#03),a
17b9 23 inc hl
17ba 7e ld a,(hl)
17bb 23 inc hl
17bc dd7704 ld (ix+#04),a
17bf c38517 jp #1785
17c2 e1 pop hl
17c3 7e ld a,(hl)
17c4 dd7705 ld (ix+#05),a
17c7 23 inc hl
17c8 c38517 jp #1785
17cb e1 pop hl
17cc 7e ld a,(hl)
17cd dd4603 ld b,(ix+#03)
17d0 80 add a,b
17d1 dd7703 ld (ix+#03),a
17d4 23 inc hl
17d5 7e ld a,(hl)
17d6 23 inc hl
17d7 dd4604 ld b,(ix+#04)
17da 88 adc a,b
17db dd7704 ld (ix+#04),a
17de c38517 jp #1785
17e1 e1 pop hl
17e2 7e ld a,(hl)
17e3 dd4605 ld b,(ix+#05)
17e6 80 add a,b
17e7 dd7705 ld (ix+#05),a
17ea 23 inc hl
17eb c38517 jp #1785
17ee e1 pop hl
17ef 7e ld a,(hl)
17f0 ddbe07 cp (ix+#07)
17f3 280b jr z,#1800 ; (11)
17f5 dd3407 inc (ix+#07)
17f8 2b dec hl
17f9 dd7501 ld (ix+#01),l
17fc dd7402 ld (ix+#02),h
17ff c9 ret
1800 dd360700 ld (ix+#07),#00
1804 23 inc hl
1805 c38517 jp #1785
1808 dd6e08 ld l,(ix+#08)
180b dd6609 ld h,(ix+#09)
180e d1 pop de
180f d5 push de
1810 2b dec hl
1811 72 ld (hl),d
1812 2b dec hl
1813 73 ld (hl),e
1814 2b dec hl
1815 3600 ld (hl),#00
1817 dd7508 ld (ix+#08),l
181a dd7409 ld (ix+#09),h
181d e1 pop hl
181e c38517 jp #1785
1821 d1 pop de
1822 1a ld a,(de)
1823 dd6e08 ld l,(ix+#08)
1826 dd6609 ld h,(ix+#09)
1829 be cp (hl)
182a 2809 jr z,#1835 ; (9)
182c 34 inc (hl)
182d 23 inc hl
182e 5e ld e,(hl)
182f 23 inc hl
1830 56 ld d,(hl)
1831 eb ex de,hl
1832 c38517 jp #1785
1835 23 inc hl
1836 23 inc hl
1837 23 inc hl
1838 dd7508 ld (ix+#08),l
183b dd7409 ld (ix+#09),h
183e 13 inc de
183f eb ex de,hl
1840 c38517 jp #1785
1843 e1 pop hl
1844 5e ld e,(hl)
1845 23 inc hl
1846 56 ld d,(hl)
1847 eb ex de,hl
1848 c38517 jp #1785
184b e1 pop hl
184c dde5 push ix
184e dde5 push ix
1850 e1 pop hl
1851 d1 pop de
1852 13 inc de
1853 3600 ld (hl),#00
1855 011800 ld bc,#0018
1858 edb0 ldir
185a 1a ld a,(de)
185b dd7701 ld (ix+#01),a
185e 13 inc de
185f 1a ld a,(de)
1860 dd7702 ld (ix+#02),a
1863 dd7508 ld (ix+#08),l
1866 dd7409 ld (ix+#09),h
1869 c9 ret
186a e1 pop hl
186b dd7501 ld (ix+#01),l
186e dd7402 ld (ix+#02),h
1871 dd360000 ld (ix+#00),#00
1875 c9 ret
1876 e1 pop hl
1877 5e ld e,(hl)
1878 23 inc hl
1879 56 ld d,(hl)
187a eb ex de,hl
187b 3606 ld (hl),#06
187d 13 inc de
187e eb ex de,hl
187f c38517 jp #1785
1882 e1 pop hl
1883 7e ld a,(hl)
1884 dd7706 ld (ix+#06),a
1887 23 inc hl
1888 c38517 jp #1785
00001880 85 17 e1 7e dd 77 06 23 c3 85 17 32 40 52 45 59 |...~.w.#...2@REY|
00001890 41 4c 50 40 45 52 4f 43 53 50 4f 54 40 31 40 52 |ALP@EROCSPOT@1@R|
000018a0 45 59 41 4c 50 54 49 44 45 52 43 59 41 4c 50 45 |EYALPTIDERCYALPE|
000018b0 45 52 46 40 4e 49 4f 43 40 54 52 45 53 4e 49 52 |ERF@NIOC@TRESNIR|
000018c0 45 59 41 4c 50 40 45 4e 4f 40 54 43 45 4c 45 53 |EYALP@ENO@TCELES|
000018d0 52 4f 53 52 45 59 41 4c 50 40 4f 57 54 40 52 4f |ROSREYALP@OWT@RO|
000018e0 40 45 4e 4f 40 54 43 45 4c 45 53 50 55 40 45 4e |@ENO@TCELESPU@EN|
000018f0 4f 40 52 45 59 41 4c 50 50 55 40 4f 57 54 40 52 |O@REYALPPU@OWT@R|
00001900 45 59 41 4c 50 4e 49 41 47 41 40 52 45 59 41 4c |EYALPNIAGA@REYAL|
00001910 50 40 45 4d 41 53 52 45 56 4f 40 45 4d 41 47 52 |P@EMASREVO@EMAGR|
00001920 45 56 4f 40 45 4d 41 47 40 45 4e 4f 40 52 45 59 |EVO@EMAG@ENO@REY|
00001930 41 4c 50 45 4d 41 46 40 46 4f 40 4c 4c 41 48 45 |ALPEMAF@FO@LLAHE|
00001940 48 54 40 4e 49 40 53 49 40 45 52 4f 43 53 40 52 |HT@NI@SI@EROCS@R|
00001950 55 4f 59 4e 45 54 40 50 4f 54 54 43 45 4c 45 53 |UOYNET@POTTCELES|
00001960 40 4f 54 40 4b 43 49 54 53 59 4f 4a 40 45 53 55 |@OT@KCITSYOJ@ESU|
00001970 4e 4f 54 54 55 42 40 44 45 45 50 53 40 44 4e 41 |NOTTUB@DEEPS@DNA|
00001980 40 52 45 54 54 45 4c 54 4e 49 52 50 40 4f 54 45 |@RETTELTNIRP@OTE|
00001990 4e 44 4d 41 4c 53 45 43 4e 41 56 44 41 40 45 52 |NDMALSECNAVDA@ER|
000019a0 4f 43 53 40 54 4e 54 40 52 4d 40 45 52 4f 43 53 |OCS@TNT@RM@EROCS|
000019b0 40 40 53 4e 4f 49 54 43 45 53 52 45 54 4e 49 52 |@@SNOITCESRETNIR|
000019c0 45 42 4d 55 4e 40 45 4d 41 52 46 40 58 40 53 54 |EBMUN@EMARF@X@ST|
000019d0 4e 49 4f 50 40 30 31 53 4e 4f 49 54 43 45 53 52 |NIOP@01SNOITCESR|
000019e0 45 54 4e 49 40 40 4c 41 49 43 45 50 53 64 64 64 |ETNI@@LAICEPSddd|
000019f0 64 40 40 40 45 52 4f 43 53 40 59 41 4c 50 40 31 |d@@@EROCS@YALP@1|
00001a00 40 53 4e 49 4f 43 40 32 53 59 41 4c 50 40 32 40 |@SNIOC@2SYALP@2@|
00001a10 40 4e 49 4f 43 40 31 40 59 41 4c 50 40 31 40 40 |@NIOC@1@YALP@1@@|
00001a20 4e 49 4f 43 40 31 53 54 4e 49 4f 50 40 40 40 40 |NIOC@1STNIOP@@@@|
00001a30 40 40 40 40 59 52 45 56 45 40 53 55 4e 4f 42 30 |@@@@YREVE@SUNOB0|
00001a40 30 30 30 35 31 30 30 30 35 32 31 30 30 30 30 30 |0005100052100000|
00001a50 31 40 30 30 30 35 37 53 43 49 54 53 4f 4e 47 41 |1@00057SCITSONGA|
00001a60 49 44 4e 4f 49 54 49 44 4e 4f 43 40 40 4e 4f 49 |IDNOITIDNOC@@NOI|
00001a70 54 41 43 4f 4c 40 40 4d 4f 52 44 4f 4f 47 40 40 |TACOL@@MORDOOG@@|
00001a80 40 40 40 40 40 44 37 40 40 40 40 40 40 31 44 4f |@@@@@D7@@@@@@1DO|
00001a90 4f 47 40 40 40 40 40 40 40 46 37 40 40 40 40 40 |OG@@@@@@@F7@@@@@|
00001aa0 40 32 44 4f 4f 47 40 40 40 40 40 40 40 48 37 40 |@2DOOG@@@@@@@H7@|
00001ab0 40 40 40 40 40 33 44 4f 4f 47 40 40 40 40 40 40 |@@@@@3DOOG@@@@@@|
00001ac0 40 4a 37 40 40 40 40 40 40 34 44 4f 4f 47 40 40 |@J7@@@@@@4DOOG@@|
00001ad0 40 40 40 40 40 48 34 40 40 40 40 40 40 31 44 4f |@@@@@H4@@@@@@1DO|
00001ae0 4f 47 40 40 40 40 40 40 40 4c 34 40 40 40 40 40 |OG@@@@@@@L4@@@@@|
00001af0 40 32 44 4f 4f 47 40 40 40 40 40 40 40 4a 34 40 |@2DOOG@@@@@@@J4@|
00001b00 40 40 40 40 40 33 44 4f 4f 47 40 40 40 40 40 40 |@@@@@3DOOG@@@@@@|
00001b10 40 4d 34 40 40 40 40 40 40 34 44 4f 4f 47 40 40 |@M4@@@@@@4DOOG@@|
00001b20 40 40 40 40 40 4b 34 40 40 40 40 40 40 35 44 4f |@@@@@K4@@@@@@5DO|
00001b30 4f 47 40 40 40 40 40 40 40 4e 34 40 40 40 40 40 |OG@@@@@@@N4@@@@@|
00001b40 40 36 44 41 42 40 4e 4f 49 54 49 44 4e 4f 43 40 |@6DAB@NOITIDNOC@|
00001b50 40 4e 4f 49 54 41 43 4f 4c 40 40 4d 41 52 00 01 |@NOITACOL@@MAR..|
00001b60 02 03 04 05 06 07 08 09 41 42 43 44 45 46 47 48 |........ABCDEFGH|
00001b70 49 4a 4b 4c 4d 4e 4f 50 51 52 53 54 55 56 57 58 |IJKLMNOPQRSTUVWX|
00001b80 59 5a 5a 59 58 57 56 55 54 53 52 51 50 4f 4e 4d |YZZYXWVUTSRQPONM|
00001b90 4c 4b 4a 49 48 47 46 45 44 43 42 41 00 01 04 02 |LKJIHGFEDCBA....|
1b9d 010402 ld bc,#0204
1ba0 94 sub h
1ba1 42 ld b,d
1ba2 95 sub l
1ba3 42 ld b,d
1ba4 96 sub (hl)
1ba5 42 ld b,d
1ba6 97 sub a
1ba7 42 ld b,d
1ba8 98 sbc a,b
1ba9 42 ld b,d
1baa 99 sbc a,c
1bab 42 ld b,d
1bac 9a sbc a,d
1bad 42 ld b,d
1bae 9b sbc a,e
1baf 42 ld b,d
1bb0 9c sbc a,h
1bb1 42 ld b,d
1bb2 9d sbc a,l
1bb3 42 ld b,d
1bb4 03 inc bc
1bb5 02 ld (bc),a
1bb6 010000 ld bc,#0000
1bb9 80 add a,b
1bba 60 ld h,b
1bbb 40 ld b,b
1bbc 21dd4d ld hl,#4ddd
1bbf cb46 bit 0,(hl)
1bc1 2011 jr nz,#1bd4 ; (17)
1bc3 cbc6 set 0,(hl)
1bc5 3a2c4e ld a,(#4e2c)
1bc8 2a274e ld hl,(#4e27)
1bcb 0610 ld b,#10
1bcd 5e ld e,(hl)
1bce 23 inc hl
1bcf 56 ld d,(hl)
1bd0 12 ld (de),a
1bd1 23 inc hl
1bd2 10f9 djnz #1bcd ; (-7)
1bd4 00 nop
1bd5 3e04 ld a,#04
1bd7 32154e ld (#4e15),a
1bda 3a294e ld a,(#4e29)
1bdd 32164e ld (#4e16),a
1be0 21f226 ld hl,#26f2
1be3 11174e ld de,#4e17
1be6 010400 ld bc,#0004
1be9 edb0 ldir
1beb fd21894c ld iy,#4c89
1bef fd7e07 ld a,(iy+#07)
1bf2 e6e0 and #e0
1bf4 47 ld b,a
1bf5 3af84c ld a,(#4cf8)
1bf8 e61f and #1f
1bfa b0 or b
1bfb fd7707 ld (iy+#07),a
1bfe 2a114e ld hl,(#4e11)
1c01 220f4e ld (#4e0f),hl
1c04 21f84d ld hl,#4df8
1c07 cd3f1f call #1f3f
1c0a 210000 ld hl,#0000
1c0d 220f4e ld (#4e0f),hl
1c10 3a134e ld a,(#4e13)
1c13 32154e ld (#4e15),a
1c16 3a144e ld a,(#4e14)
1c19 32164e ld (#4e16),a
1c1c 21f626 ld hl,#26f6
1c1f 11174e ld de,#4e17
1c22 010400 ld bc,#0004
1c25 edb0 ldir
1c27 3a1b4e ld a,(#4e1b)
1c2a feb5 cp #b5
1c2c 2825 jr z,#1c53 ; (37)
1c2e fe3c cp #3c
1c30 280a jr z,#1c3c ; (10)
1c32 fe78 cp #78
1c34 280d jr z,#1c43 ; (13)
1c36 feb4 cp #b4
1c38 2810 jr z,#1c4a ; (16)
1c3a 1813 jr #1c4f ; (19)
1c3c 21704c ld hl,#4c70
1c3f cbf6 set 6,(hl)
1c41 180c jr #1c4f ; (12)
1c43 21784c ld hl,#4c78
1c46 cbf6 set 6,(hl)
1c48 1805 jr #1c4f ; (5)
1c4a 21804c ld hl,#4c80
1c4d cbf6 set 6,(hl)
1c4f 3c inc a
1c50 321b4e ld (#4e1b),a
1c53 00 nop
1c54 dd21894c ld ix,#4c89
1c58 fd21614c ld iy,#4c61
1c5c cd0a27 call #270a
1c5f 21fb4d ld hl,#4dfb
1c62 cd3f1f call #1f3f
1c65 dd21894c ld ix,#4c89
1c69 fd21694c ld iy,#4c69
1c6d cd0a27 call #270a
1c70 21fe4d ld hl,#4dfe
1c73 cd3f1f call #1f3f
1c76 dd21894c ld ix,#4c89
1c7a fd21714c ld iy,#4c71
1c7e cd0a27 call #270a
1c81 21014e ld hl,#4e01
1c84 cd3f1f call #1f3f
1c87 dd21894c ld ix,#4c89
1c8b fd21794c ld iy,#4c79
1c8f cd0a27 call #270a
1c92 21044e ld hl,#4e04
1c95 cd3f1f call #1f3f
1c98 dd21894c ld ix,#4c89
1c9c fd21814c ld iy,#4c81
1ca0 cd0a27 call #270a
1ca3 21074e ld hl,#4e07
1ca6 cd3f1f call #1f3f
1ca9 3a2b4e ld a,(#4e2b)
1cac 3c inc a
1cad 322b4e ld (#4e2b),a
1cb0 fe04 cp #04
1cb2 202c jr nz,#1ce0 ; (44)
1cb4 af xor a
1cb5 322b4e ld (#4e2b),a
1cb8 3a2a4e ld a,(#4e2a)
1cbb 47 ld b,a
1cbc fe02 cp #02
1cbe 281d jr z,#1cdd ; (29)
1cc0 3c inc a
1cc1 322a4e ld (#4e2a),a
1cc4 3a2c4e ld a,(#4e2c)
1cc7 80 add a,b
1cc8 4f ld c,a
1cc9 2a274e ld hl,(#4e27)
1ccc 0610 ld b,#10
1cce 5e ld e,(hl)
1ccf 23 inc hl
1cd0 56 ld d,(hl)
1cd1 23 inc hl
1cd2 1a ld a,(de)
1cd3 fe66 cp #66
1cd5 3802 jr c,#1cd9 ; (2)
1cd7 79 ld a,c
1cd8 12 ld (de),a
1cd9 10f3 djnz #1cce ; (-13)
1cdb 1803 jr #1ce0 ; (3)
1cdd af xor a
1cde 18e1 jr #1cc1 ; (-31)
1ce0 00 nop
1ce1 3a844c ld a,(#4c84)
1ce4 fe00 cp #00
1ce6 2812 jr z,#1cfa ; (18)
1ce8 3a264e ld a,(#4e26)
1ceb 3c inc a
1cec 32264e ld (#4e26),a
1cef fe32 cp #32
1cf1 2007 jr nz,#1cfa ; (7)
1cf3 af xor a
1cf4 32844c ld (#4c84),a
1cf7 32264e ld (#4e26),a
1cfa 3a224e ld a,(#4e22)
1cfd fe04 cp #04
1cff 2022 jr nz,#1d23 ; (34)
1d01 af xor a
1d02 32224e ld (#4e22),a
1d05 3a3040 ld a,(#4030)
1d08 47 ld b,a
1d09 3a2f40 ld a,(#402f)
1d0c 4f ld c,a
1d0d 3a234e ld a,(#4e23)
1d10 323040 ld (#4030),a
1d13 3a244e ld a,(#4e24)
1d16 322f40 ld (#402f),a
1d19 78 ld a,b
1d1a 32234e ld (#4e23),a
1d1d 79 ld a,c
1d1e 32244e ld (#4e24),a
1d21 1804 jr #1d27 ; (4)
1d23 3c inc a
1d24 32224e ld (#4e22),a
1d27 3a254e ld a,(#4e25)
1d2a feff cp #ff
1d2c ca0e1e jp z,#1e0e
1d2f fe10 cp #10
1d31 c2291e jp nz,#1e29
1d34 3c inc a
1d35 32254e ld (#4e25),a
1d38 3a644c ld a,(#4c64)
1d3b 322f4e ld (#4e2f),a
1d3e 3a6c4c ld a,(#4c6c)
1d41 32304e ld (#4e30),a
1d44 3a744c ld a,(#4c74)
1d47 32314e ld (#4e31),a
1d4a 3a7c4c ld a,(#4c7c)
1d4d 32324e ld (#4e32),a
1d50 3a844c ld a,(#4c84)
1d53 32334e ld (#4e33),a
1d56 3a8c4c ld a,(#4c8c)
1d59 32344e ld (#4e34),a
1d5c af xor a
1d5d 32644c ld (#4c64),a
1d60 326c4c ld (#4c6c),a
1d63 32744c ld (#4c74),a
1d66 327c4c ld (#4c7c),a
1d69 32844c ld (#4c84),a
1d6c 328c4c ld (#4c8c),a
1d6f 061c ld b,#1c
1d71 214e40 ld hl,#404e
1d74 11354e ld de,#4e35
1d77 c5 push bc
1d78 010500 ld bc,#0005
1d7b edb0 ldir
1d7d 3e1b ld a,#1b
1d7f cdb015 call #15b0
1d82 c1 pop bc
1d83 10f2 djnz #1d77 ; (-14)
1d85 3a4044 ld a,(#4440)
1d88 32c14e ld (#4ec1),a
1d8b 114e40 ld de,#404e
1d8e 21e31e ld hl,#1ee3
1d91 3e05 ld a,#05
1d93 061c ld b,#1c
1d95 cdeb15 call #15eb
1d98 114e44 ld de,#444e
1d9b 213e1f ld hl,#1f3e
1d9e 3e05 ld a,#05
1da0 061c ld b,#1c
1da2 cdeb15 call #15eb
1da5 116f40 ld de,#406f
1da8 21e41e ld hl,#1ee4
1dab 3e01 ld a,#01
1dad 061a ld b,#1a
1daf cdd515 call #15d5 ; DRAW TEXT
1db2 111141 ld de,#4111
1db5 21fe1e ld hl,#1efe
1db8 3e01 ld a,#01
1dba 0610 ld b,#10
1dbc cdd515 call #15d5 ; DRAW TEXT
1dbf 3e78 ld a,#78
1dc1 cd9b15 call #159b
1dc4 114e44 ld de,#444e
1dc7 21c14e ld hl,#4ec1
1dca 3e05 ld a,#05
1dcc 061c ld b,#1c
1dce cdeb15 call #15eb
1dd1 061c ld b,#1c
1dd3 21354e ld hl,#4e35
1dd6 114e40 ld de,#404e
1dd9 c5 push bc
1dda 010500 ld bc,#0005
1ddd edb0 ldir
1ddf 3e1b ld a,#1b
1de1 cdb515 call #15b5
1de4 c1 pop bc
1de5 10f2 djnz #1dd9 ; (-14)
1de7 3a2f4e ld a,(#4e2f)
1dea 32644c ld (#4c64),a
1ded 3a304e ld a,(#4e30)
1df0 326c4c ld (#4c6c),a
1df3 3a314e ld a,(#4e31)
1df6 32744c ld (#4c74),a
1df9 3a324e ld a,(#4e32)
1dfc 327c4c ld (#4c7c),a
1dff 3a334e ld a,(#4e33)
1e02 32844c ld (#4c84),a
1e05 3a344e ld a,(#4e34)
1e08 328c4c ld (#4c8c),a
1e0b c3291e jp #1e29
1e0e af xor a
1e0f 32624c ld (#4c62),a
1e12 326a4c ld (#4c6a),a
1e15 32724c ld (#4c72),a
1e18 327a4c ld (#4c7a),a
1e1b 32824c ld (#4c82),a
1e1e 328a4c ld (#4c8a),a
1e21 21714d ld hl,#4d71
1e24 cbce set 1,(hl)
1e26 c3c81e jp #1ec8
1e29 3a904c ld a,(#4c90)
1e2c cb6f bit 5,a
1e2e c2e21e jp nz,#1ee2
1e31 cb77 bit 6,a
1e33 2010 jr nz,#1e45 ; (16)
1e35 21964c ld hl,#4c96
1e38 cbce set 1,(hl)
1e3a 3e40 ld a,#40
1e3c 322f40 ld (#402f),a
1e3f 323040 ld (#4030),a
1e42 c3e21e jp #1ee2
1e45 3a684c ld a,(#4c68)
1e48 47 ld b,a
1e49 3a704c ld a,(#4c70)
1e4c b0 or b
1e4d 47 ld b,a
1e4e 3a784c ld a,(#4c78)
1e51 b0 or b
1e52 47 ld b,a
1e53 3a804c ld a,(#4c80)
1e56 b0 or b
1e57 47 ld b,a
1e58 3a884c ld a,(#4c88)
1e5b b0 or b
1e5c cb77 bit 6,a
1e5e c2e21e jp nz,#1ee2
1e61 47 ld b,a
1e62 af xor a
1e63 328a4c ld (#4c8a),a
1e66 21714d ld hl,#4d71
1e69 cbce set 1,(hl)
1e6b 218c4d ld hl,#4d8c
1e6e cbce set 1,(hl)
1e70 cb68 bit 5,b
1e72 206e jr nz,#1ee2 ; (110)
1e74 af xor a
1e75 328c4c ld (#4c8c),a
1e78 3a4044 ld a,(#4440)
1e7b 32c14e ld (#4ec1),a
1e7e 114e40 ld de,#404e
1e81 21e31e ld hl,#1ee3
1e84 3e05 ld a,#05
1e86 061c ld b,#1c
1e88 cdeb15 call #15eb
1e8b 114e44 ld de,#444e
1e8e 213e1f ld hl,#1f3e
1e91 3e05 ld a,#05
1e93 061c ld b,#1c
1e95 cdeb15 call #15eb
1e98 112f41 ld de,#412f
1e9b 210e1f ld hl,#1f0e
1e9e 3e01 ld a,#01
1ea0 060f ld b,#0f
1ea2 cdd515 call #15d5 ; DRAW TEXT
1ea5 11d140 ld de,#40d1
1ea8 211d1f ld hl,#1f1d
1eab 3e01 ld a,#01
1ead 0614 ld b,#14
1eaf cdd515 call #15d5 ; DRAW TEXT
1eb2 3e78 ld a,#78
1eb4 cd9b15 call #159b
1eb7 114e44 ld de,#444e
1eba 21c14e ld hl,#4ec1
1ebd 3e05 ld a,#05
1ebf 061c ld b,#1c
1ec1 cdeb15 call #15eb
1ec4 af xor a
1ec5 32844c ld (#4c84),a
1ec8 3a844c ld a,(#4c84)
1ecb fe00 cp #00
1ecd 2013 jr nz,#1ee2 ; (19)
1ecf 21964c ld hl,#4c96
1ed2 cbde set 3,(hl)
1ed4 cbce set 1,(hl)
1ed6 af xor a
1ed7 321b4e ld (#4e1b),a
1eda 3e40 ld a,#40
1edc 322f40 ld (#402f),a
1edf 323040 ld (#4030),a
1ee2 c9 ret
1ee3 40 ld b,b
1ee4 45 ld b,l
1ee5 53 ld d,e
1ee6 55 ld d,l
1ee7 46 ld b,(hl)
1ee8 40 ld b,b
1ee9 59 ld e,c
1eea 42 ld b,d
1eeb 40 ld b,b
1eec 44 ld b,h
1eed 45 ld b,l
1eee 4e ld c,(hl)
1eef 52 ld d,d
1ef0 55 ld d,l
1ef1 42 ld b,d
1ef2 40 ld b,b
1ef3 54 ld d,h
1ef4 45 ld b,l
1ef5 47 ld b,a
1ef6 52 ld d,d
1ef7 41 ld b,c
1ef8 54 ld d,h
1ef9 40 ld b,b
1efa 54 ld d,h
1efb 53 ld d,e
1efc 41 ld b,c
1efd 4c ld c,h
1efe 4e ld c,(hl)
1eff 55 ld d,l
1f00 52 ld d,d
1f01 40 ld b,b
1f02 54 ld d,h
1f03 53 ld d,e
1f04 55 ld d,l
1f05 4d ld c,l
1f06 40 ld b,b
1f07 55 ld d,l
1f08 4f ld c,a
1f09 59 ld e,c
1f0a 40 ld b,b
1f0b 57 ld d,a
1f0c 4f ld c,a
1f0d 4e ld c,(hl)
1f0e 53 ld d,e
1f0f 4e ld c,(hl)
1f10 4f ld c,a
1f11 49 ld c,c
1f12 54 ld d,h
1f13 41 ld b,c
1f14 4c ld c,h
1f15 55 ld d,l
1f16 54 ld d,h
1f17 41 ld b,c
1f18 52 ld d,d
1f19 47 ld b,a
1f1a 4e ld c,(hl)
1f1b 4f ld c,a
1f1c 43 ld b,e
1f1d 54 ld d,h
1f1e 55 ld d,l
1f1f 4f ld c,a
1f20 40 ld b,b
1f21 44 ld b,h
1f22 45 ld b,l
1f23 4e ld c,(hl)
1f24 52 ld d,d
1f25 55 ld d,l
1f26 42 ld b,d
1f27 40 ld b,b
1f28 53 ld d,e
1f29 45 ld b,l
1f2a 53 ld d,e
1f2b 55 ld d,l
1f2c 46 ld b,(hl)
1f2d 40 ld b,b
1f2e 4c ld c,h
1f2f 4c ld c,h
1f30 41 ld b,c
1f31 59 ld e,c
1f32 52 ld d,d
1f33 52 ld d,d
1f34 4f ld c,a
1f35 53 ld d,e
1f36 44 ld b,h
1f37 4e ld c,(hl)
1f38 45 ld b,l
1f39 40 ld b,b
1f3a 44 ld b,h
1f3b 41 ld b,c
1f3c 45 ld b,l
1f3d 44 ld b,h
1f3e 09 add hl,bc
1f3f dd2af64d ld ix,(#4df6)
1f43 fdcb076e bit 5,(iy+#07)
1f47 c27323 jp nz,#2373
1f4a fdcb0776 bit 6,(iy+#07)
1f4e c8 ret z
1f4f 7e ld a,(hl)
1f50 cbbf res 7,a
1f52 cbb7 res 6,a
1f54 fe03 cp #03
1f56 ca2723 jp z,#2327
1f59 3c inc a
1f5a 47 ld b,a
1f5b 7e ld a,(hl)
1f5c e6c0 and #c0
1f5e b0 or b
1f5f 77 ld (hl),a
1f60 3ef3 ld a,#f3
1f62 fd4603 ld b,(iy+#03)
1f65 90 sub b
1f66 325d4c ld (#4c5d),a
1f69 fd7e04 ld a,(iy+#04)
1f6c d60c sub #0c
1f6e 325c4c ld (#4c5c),a
1f71 e5 push hl
1f72 cdbd0e call #0ebd
1f75 e1 pop hl
1f76 3a0a4c ld a,(#4c0a)
1f79 fe00 cp #00
1f7b c20823 jp nz,#2308
1f7e 3a0b4c ld a,(#4c0b)
1f81 fe00 cp #00
1f83 c20823 jp nz,#2308
1f86 cb76 bit 6,(hl)
1f88 c20023 jp nz,#2300
1f8b cbf6 set 6,(hl)
1f8d 1a ld a,(de)
1f8e 320a4e ld (#4e0a),a
1f91 d5 push de
1f92 1b dec de
1f93 1a ld a,(de)
1f94 320b4e ld (#4e0b),a
1f97 13 inc de
1f98 13 inc de
1f99 1a ld a,(de)
1f9a 320c4e ld (#4e0c),a
1f9d 3e21 ld a,#21
1f9f cdc915 call #15c9
1fa2 1a ld a,(de)
1fa3 320d4e ld (#4e0d),a
1fa6 3e40 ld a,#40
1fa8 cdb515 call #15b5
1fab 1a ld a,(de)
1fac 320e4e ld (#4e0e),a
1faf d1 pop de
1fb0 cb7e bit 7,(hl)
1fb2 c29f20 jp nz,#209f
1fb5 3ac24e ld a,(#4ec2)
1fb8 fe00 cp #00
1fba ca9f20 jp z,#209f
1fbd fe01 cp #01
1fbf 2802 jr z,#1fc3 ; (2)
1fc1 1856 jr #2019 ; (86)
1fc3 3a904c ld a,(#4c90)
1fc6 cb47 bit 0,a
1fc8 2807 jr z,#1fd1 ; (7)
1fca cb5f bit 3,a
1fcc 2827 jr z,#1ff5 ; (39)
1fce cbb6 res 6,(hl)
1fd0 c9 ret
1fd1 fd4600 ld b,(iy+#00)
1fd4 fd360002 ld (iy+#00),#02
1fd8 3a184e ld a,(#4e18)
1fdb fd7705 ld (iy+#05),a
1fde af xor a
1fdf 32c24e ld (#4ec2),a
1fe2 78 ld a,b
1fe3 fe04 cp #04
1fe5 2807 jr z,#1fee ; (7)
1fe7 dd7e02 ld a,(ix+#02)
1fea 12 ld (de),a
1feb c36b22 jp #226b
1fee dd7e03 ld a,(ix+#03)
1ff1 12 ld (de),a
1ff2 c36b22 jp #226b
1ff5 fd4600 ld b,(iy+#00)
1ff8 fd360003 ld (iy+#00),#03
1ffc 3a174e ld a,(#4e17)
1fff fd7705 ld (iy+#05),a
2002 af xor a
2003 32c24e ld (#4ec2),a
2006 78 ld a,b
2007 fe04 cp #04
2009 2807 jr z,#2012 ; (7)
200b dd7e04 ld a,(ix+#04)
200e 12 ld (de),a
200f c36b22 jp #226b
2012 dd7e05 ld a,(ix+#05)
2015 12 ld (de),a
2016 c36b22 jp #226b
2019 3a904c ld a,(#4c90)
201c cb4f bit 1,a
201e 2807 jr z,#2027 ; (7)
2020 cb57 bit 2,a
2022 2827 jr z,#204b ; (39)
2024 cbb6 res 6,(hl)
2026 c9 ret
2027 fd4600 ld b,(iy+#00)
202a fd360005 ld (iy+#00),#05
202e 3a194e ld a,(#4e19)
2031 fd7705 ld (iy+#05),a
2034 af xor a
2035 32c24e ld (#4ec2),a
2038 78 ld a,b
2039 fe02 cp #02
203b 2807 jr z,#2044 ; (7)
203d dd7e03 ld a,(ix+#03)
2040 12 ld (de),a
2041 c34121 jp #2141
2044 dd7e05 ld a,(ix+#05)
2047 12 ld (de),a
2048 c34121 jp #2141
204b fd4600 ld b,(iy+#00)
204e fd360004 ld (iy+#00),#04
2052 3a1a4e ld a,(#4e1a)
2055 fd7705 ld (iy+#05),a
2058 af xor a
2059 32c24e ld (#4ec2),a
205c 78 ld a,b
205d fe02 cp #02
205f 2807 jr z,#2068 ; (7)
2061 dd7e02 ld a,(ix+#02)
2064 12 ld (de),a
2065 c34121 jp #2141
2068 dd7e04 ld a,(ix+#04)
206b 12 ld (de),a
206c c34121 jp #2141
206f fdcb0746 bit 0,(iy+#07)
2073 c0 ret nz
2074 af xor a
2075 32c24e ld (#4ec2),a
2078 c36b22 jp #226b
207b fdcb075e bit 3,(iy+#07)
207f c0 ret nz
2080 af xor a
2081 32c24e ld (#4ec2),a
2084 c36b22 jp #226b
2087 fdcb0756 bit 2,(iy+#07)
208b c0 ret nz
208c af xor a
208d 32c24e ld (#4ec2),a
2090 c34121 jp #2141
2093 fdcb074e bit 1,(iy+#07)
2097 c0 ret nz
2098 af xor a
2099 32c24e ld (#4ec2),a
209c c34121 jp #2141
209f fd7e00 ld a,(iy+#00)
20a2 fe02 cp #02
20a4 cad621 jp z,#21d6
20a7 fe03 cp #03
20a9 cad621 jp z,#21d6
20ac fdcb0746 bit 0,(iy+#07)
20b0 202f jr nz,#20e1 ; (47)
20b2 3a0a4e ld a,(#4e0a)
20b5 ddbe01 cp (ix+#01)
20b8 cac320 jp z,#20c3
20bb fe66 cp #66
20bd da5221 jp c,#2152
20c0 cdc927 call #27c9
20c3 cd1b28 call #281b
20c6 fd7e00 ld a,(iy+#00)
20c9 fe05 cp #05
20cb 280a jr z,#20d7 ; (10)
20cd dd7e03 ld a,(ix+#03)
20d0 320a4e ld (#4e0a),a
20d3 12 ld (de),a
20d4 c3b121 jp #21b1
20d7 dd7e02 ld a,(ix+#02)
20da 320a4e ld (#4e0a),a
20dd 12 ld (de),a
20de c3b121 jp #21b1
20e1 fdcb075e bit 3,(iy+#07)
20e5 ca0621 jp z,#2106
20e8 3a0a4e ld a,(#4e0a)
20eb ddbe01 cp (ix+#01)
20ee caf920 jp z,#20f9
20f1 fe66 cp #66
20f3 da5221 jp c,#2152
20f6 cdc927 call #27c9
20f9 cd1b28 call #281b
20fc dd7e07 ld a,(ix+#07)
20ff 320a4e ld (#4e0a),a
2102 12 ld (de),a
2103 c38321 jp #2183
2106 3a0a4e ld a,(#4e0a)
2109 ddbe01 cp (ix+#01)
210c 2808 jr z,#2116 ; (8)
210e fe66 cp #66
2110 da5221 jp c,#2152
2113 cdc927 call #27c9
2116 cd1b28 call #281b
2119 fd7e00 ld a,(iy+#00)
211c fe05 cp #05
211e 2829 jr z,#2149 ; (41)
2120 dd7e05 ld a,(ix+#05)
2123 320a4e ld (#4e0a),a
2126 12 ld (de),a
2127 3a174e ld a,(#4e17)
212a fd7705 ld (iy+#05),a
212d fd360003 ld (iy+#00),#03
2131 3a0c4e ld a,(#4e0c)
2134 ddbe00 cp (ix+#00)
2137 caec24 jp z,#24ec
213a c33925 jp #2539
213d fdcb07fe set 7,(iy+#07)
2141 fd22914c ld (#4c91),iy
2145 cdd90c call #0cd9
2148 c9 ret
2149 dd7e04 ld a,(ix+#04)
214c 320a4e ld (#4e0a),a
214f 12 ld (de),a
2150 18d5 jr #2127 ; (-43)
2152 fd7e00 ld a,(iy+#00)
2155 fe05 cp #05
2157 2811 jr z,#216a ; (17)
2159 3a0a4e ld a,(#4e0a)
215c ddbe02 cp (ix+#02)
215f 2013 jr nz,#2174 ; (19)
2161 dd7e08 ld a,(ix+#08)
2164 320a4e ld (#4e0a),a
2167 12 ld (de),a
2168 18bd jr #2127 ; (-67)
216a 3a0a4e ld a,(#4e0a)
216d ddbe03 cp (ix+#03)
2170 2002 jr nz,#2174 ; (2)
2172 18ed jr #2161 ; (-19)
2174 3a0a4e ld a,(#4e0a)
2177 ddbe06 cp (ix+#06)
217a 201f jr nz,#219b ; (31)
217c dd7e08 ld a,(ix+#08)
217f 320a4e ld (#4e0a),a
2182 12 ld (de),a
2183 fd7e00 ld a,(iy+#00)
2186 fe05 cp #05
2188 280c jr z,#2196 ; (12)
218a 3a0d4e ld a,(#4e0d)
218d ddbe00 cp (ix+#00)
2190 cad624 jp z,#24d6
2193 c34121 jp #2141
2196 3a0e4e ld a,(#4e0e)
2199 18f2 jr #218d ; (-14)
219b fd7e00 ld a,(iy+#00)
219e fe05 cp #05
21a0 2825 jr z,#21c7 ; (37)
21a2 3a0a4e ld a,(#4e0a)
21a5 ddbe04 cp (ix+#04)
21a8 2027 jr nz,#21d1 ; (39)
21aa dd7e08 ld a,(ix+#08)
21ad 320a4e ld (#4e0a),a
21b0 12 ld (de),a
21b1 3a184e ld a,(#4e18)
21b4 fd7705 ld (iy+#05),a
21b7 fd360002 ld (iy+#00),#02
21bb 3a0b4e ld a,(#4e0b)
21be ddbe00 cp (ix+#00)
21c1 caa624 jp z,#24a6
21c4 c31c25 jp #251c
21c7 3a0a4e ld a,(#4e0a)
21ca ddbe05 cp (ix+#05)
21cd 2002 jr nz,#21d1 ; (2)
21cf 18d9 jr #21aa ; (-39)
21d1 fdcb07ee set 5,(iy+#07)
21d5 c9 ret
21d6 fdcb0756 bit 2,(iy+#07)
21da 202f jr nz,#220b ; (47)
21dc 3a0a4e ld a,(#4e0a)
21df ddbe01 cp (ix+#01)
21e2 caed21 jp z,#21ed
21e5 fe66 cp #66
21e7 da7c22 jp c,#227c
21ea cdc927 call #27c9
21ed cd1b28 call #281b
21f0 fd7e00 ld a,(iy+#00)
21f3 fe03 cp #03
21f5 280a jr z,#2201 ; (10)
21f7 dd7e04 ld a,(ix+#04)
21fa 320a4e ld (#4e0a),a
21fd 12 ld (de),a
21fe c3db22 jp #22db
2201 dd7e02 ld a,(ix+#02)
2204 320a4e ld (#4e0a),a
2207 12 ld (de),a
2208 c3db22 jp #22db
220b fdcb074e bit 1,(iy+#07)
220f ca3022 jp z,#2230
2212 3a0a4e ld a,(#4e0a)
2215 ddbe01 cp (ix+#01)
2218 ca2322 jp z,#2223
221b fe66 cp #66
221d da7c22 jp c,#227c
2220 cdc927 call #27c9
2223 cd1b28 call #281b
2226 dd7e06 ld a,(ix+#06)
2229 320a4e ld (#4e0a),a
222c 12 ld (de),a
222d c3ad22 jp #22ad
2230 3a0a4e ld a,(#4e0a)
2233 ddbe01 cp (ix+#01)
2236 2808 jr z,#2240 ; (8)
2238 fe66 cp #66
223a da7c22 jp c,#227c
223d cdc927 call #27c9
2240 cd1b28 call #281b
2243 fd7e00 ld a,(iy+#00)
2246 fe03 cp #03
2248 2829 jr z,#2273 ; (41)
224a dd7e05 ld a,(ix+#05)
224d 320a4e ld (#4e0a),a
2250 12 ld (de),a
2251 3a194e ld a,(#4e19)
2254 fd7705 ld (iy+#05),a
2257 fd360005 ld (iy+#00),#05
225b 3a0e4e ld a,(#4e0e)
225e ddbe00 cp (ix+#00)
2261 ca9c25 jp z,#259c
2264 c3e925 jp #25e9
2267 fdcb07fe set 7,(iy+#07)
226b fd22914c ld (#4c91),iy
226f cdd90c call #0cd9
2272 c9 ret
2273 dd7e03 ld a,(ix+#03)
2276 320a4e ld (#4e0a),a
2279 12 ld (de),a
227a 18d5 jr #2251 ; (-43)
227c fd7e00 ld a,(iy+#00)
227f fe03 cp #03
2281 2811 jr z,#2294 ; (17)
2283 3a0a4e ld a,(#4e0a)
2286 ddbe02 cp (ix+#02)
2289 2013 jr nz,#229e ; (19)
228b dd7e08 ld a,(ix+#08)
228e 320a4e ld (#4e0a),a
2291 12 ld (de),a
2292 18bd jr #2251 ; (-67)
2294 3a0a4e ld a,(#4e0a)
2297 ddbe04 cp (ix+#04)
229a 2002 jr nz,#229e ; (2)
229c 18ed jr #228b ; (-19)
229e 3a0a4e ld a,(#4e0a)
22a1 ddbe07 cp (ix+#07)
22a4 201f jr nz,#22c5 ; (31)
22a6 dd7e08 ld a,(ix+#08)
22a9 320a4e ld (#4e0a),a
22ac 12 ld (de),a
22ad fd7e00 ld a,(iy+#00)
22b0 fe03 cp #03
22b2 280c jr z,#22c0 ; (12)
22b4 3a0b4e ld a,(#4e0b)
22b7 ddbe00 cp (ix+#00)
22ba ca8625 jp z,#2586
22bd c36b22 jp #226b
22c0 3a0c4e ld a,(#4e0c)
22c3 18f2 jr #22b7 ; (-14)
22c5 fd7e00 ld a,(iy+#00)
22c8 fe03 cp #03
22ca 2825 jr z,#22f1 ; (37)
22cc 3a0a4e ld a,(#4e0a)
22cf ddbe03 cp (ix+#03)
22d2 2027 jr nz,#22fb ; (39)
22d4 dd7e08 ld a,(ix+#08)
22d7 320a4e ld (#4e0a),a
22da 12 ld (de),a
22db 3a1a4e ld a,(#4e1a)
22de fd7705 ld (iy+#05),a
22e1 fd360004 ld (iy+#00),#04
22e5 3a0d4e ld a,(#4e0d)
22e8 ddbe00 cp (ix+#00)
22eb ca5625 jp z,#2556
22ee c3cc25 jp #25cc
22f1 3a0a4e ld a,(#4e0a)
22f4 ddbe05 cp (ix+#05)
22f7 2002 jr nz,#22fb ; (2)
22f9 18d9 jr #22d4 ; (-39)
22fb fdcb07ee set 5,(iy+#07)
22ff c9 ret
2300 fd22914c ld (#4c91),iy
2304 cdd90c call #0cd9
2307 c9 ret
2308 cbb6 res 6,(hl)
230a cb7e bit 7,(hl)
230c 20f2 jr nz,#2300 ; (-14)
230e 3ac24e ld a,(#4ec2)
2311 fe00 cp #00
2313 28eb jr z,#2300 ; (-21)
2315 fe03 cp #03
2317 ca6f20 jp z,#206f
231a fe04 cp #04
231c ca7b20 jp z,#207b
231f fe05 cp #05
2321 ca8720 jp z,#2087
2324 c39320 jp #2093
2327 3ec0 ld a,#c0
2329 a6 and (hl)
232a 77 ld (hl),a
232b cb7f bit 7,a
232d 201e jr nz,#234d ; (30)
232f fd7e01 ld a,(iy+#01)
2332 fe00 cp #00
2334 c8 ret z
2335 fdcb0766 bit 4,(iy+#07)
2339 c25623 jp nz,#2356
233c 3a154e ld a,(#4e15)
233f fd4601 ld b,(iy+#01)
2342 b8 cp b
2343 ca601f jp z,#1f60
2346 05 dec b
2347 fd7001 ld (iy+#01),b
234a c3601f jp #1f60
234d cdb827 call #27b8
2350 fdcb077e bit 7,(iy+#07)
2354 2011 jr nz,#2367 ; (17)
2356 3a164e ld a,(#4e16)
2359 fd4601 ld b,(iy+#01)
235c b8 cp b
235d ca601f jp z,#1f60
2360 04 inc b
2361 fd7001 ld (iy+#01),b
2364 c3601f jp #1f60
2367 fdcb07be res 7,(iy+#07)
236b 3a154e ld a,(#4e15)
236e fd7701 ld (iy+#01),a
2371 18e3 jr #2356 ; (-29)
2373 23 inc hl
2374 7e ld a,(hl)
2375 fe02 cp #02
2377 2019 jr nz,#2392 ; (25)
2379 3600 ld (hl),#00
237b 23 inc hl
237c 7e ld a,(hl)
237d fe00 cp #00
237f 2813 jr z,#2394 ; (19)
2381 fe0f cp #0f
2383 cae726 jp z,#26e7
2386 34 inc (hl)
2387 21fa26 ld hl,#26fa
238a cdb015 call #15b0
238d 7e ld a,(hl)
238e fd7705 ld (iy+#05),a
2391 c9 ret
2392 34 inc (hl)
2393 c9 ret
2394 34 inc (hl)
2395 2b dec hl
2396 2b dec hl
2397 fdcb07b6 res 6,(iy+#07)
239b cb7e bit 7,(hl)
239d 280e jr z,#23ad ; (14)
239f 3a204d ld a,(#4d20)
23a2 fe00 cp #00
23a4 20e1 jr nz,#2387 ; (-31)
23a6 213b4d ld hl,#4d3b
23a9 cbc6 set 0,(hl)
23ab 18da jr #2387 ; (-38)
23ad 21564d ld hl,#4d56
23b0 cbc6 set 0,(hl)
23b2 21684c ld hl,#4c68
23b5 cbb6 res 6,(hl)
23b7 21704c ld hl,#4c70
23ba cbb6 res 6,(hl)
23bc 21784c ld hl,#4c78
23bf cbb6 res 6,(hl)
23c1 21804c ld hl,#4c80
23c4 cbb6 res 6,(hl)
23c6 21884c ld hl,#4c88
23c9 cbb6 res 6,(hl)
23cb 21904c ld hl,#4c90
23ce cbae res 5,(hl)
23d0 cbb6 res 6,(hl)
23d2 3eb5 ld a,#b5
23d4 321b4e ld (#4e1b),a
23d7 cd0a16 call #160a
23da 3e17 ld a,#17
23dc cdfd14 call #14fd
23df 3e14 ld a,#14
23e1 cd0d15 call #150d
23e4 3e02 ld a,#02
23e6 cd9b15 call #159b
23e9 3e14 ld a,#14
23eb cdfd14 call #14fd
23ee 3e03 ld a,#03
23f0 cd9b15 call #159b
23f3 3e17 ld a,#17
23f5 cdfd14 call #14fd
23f8 3e02 ld a,#02
23fa cd9b15 call #159b
23fd 3e14 ld a,#14
23ff cdfd14 call #14fd
2402 3e03 ld a,#03
2404 cd9b15 call #159b
2407 3e17 ld a,#17
2409 cdfd14 call #14fd
240c 3e02 ld a,#02
240e cd9b15 call #159b
2411 3e14 ld a,#14
2413 cdfd14 call #14fd
2416 21964c ld hl,#4c96
2419 cb46 bit 0,(hl)
241b c8 ret z
241c 3e90 ld a,#90
241e cd9b15 call #159b
2421 c37824 jp #2478
2424 218726 ld hl,#2687
2427 cd312c call #2c31
242a 3e01 ld a,#01
242c cd9b15 call #159b
242f cd8124 call #2481
2432 3a644c ld a,(#4c64)
2435 fe00 cp #00
2437 20f1 jr nz,#242a ; (-15)
2439 3ab04c ld a,(#4cb0)
243c fe00 cp #00
243e 2010 jr nz,#2450 ; (16)
2440 3aa64c ld a,(#4ca6)
2443 fe00 cp #00
2445 2009 jr nz,#2450 ; (9)
2447 3aa74c ld a,(#4ca7)
244a fe00 cp #00
244c 2002 jr nz,#2450 ; (2)
244e 1828 jr #2478 ; (40)
2450 218c4d ld hl,#4d8c
2453 cbc6 set 0,(hl)
2455 3e30 ld a,#30
2457 cd9b15 call #159b
245a 21b726 ld hl,#26b7
245d cd312c call #2c31
2460 3e01 ld a,#01
2462 cd9b15 call #159b
2465 cd8124 call #2481
2468 21814c ld hl,#4c81
246b 22914c ld (#4c91),hl
246e cdd90c call #0cd9
2471 3a644c ld a,(#4c64)
2474 feec cp #ec
2476 20e8 jr nz,#2460 ; (-24)
2478 cd0a16 call #160a
247b 21904c ld hl,#4c90
247e cbae res 5,(hl)
2480 c9 ret
2481 21614c ld hl,#4c61
2484 22914c ld (#4c91),hl
2487 cdd90c call #0cd9
248a 21694c ld hl,#4c69
248d 22914c ld (#4c91),hl
2490 cdd90c call #0cd9
2493 21714c ld hl,#4c71
2496 22914c ld (#4c91),hl
2499 cdd90c call #0cd9
249c 21794c ld hl,#4c79
249f 22914c ld (#4c91),hl
24a2 cdd90c call #0cd9
24a5 c9 ret
24a6 cb7e bit 7,(hl)
24a8 c2d121 jp nz,#21d1
24ab 3a0a4e ld a,(#4e0a)
24ae ddbe08 cp (ix+#08)
24b1 ca3926 jp z,#2639
24b4 ddbe03 cp (ix+#03)
24b7 2011 jr nz,#24ca ; (17)
24b9 3a1a4e ld a,(#4e1a)
24bc fd7705 ld (iy+#05),a
24bf fd360004 ld (iy+#00),#04
24c3 dd7e07 ld a,(ix+#07)
24c6 12 ld (de),a
24c7 c34121 jp #2141
24ca 3a194e ld a,(#4e19)
24cd fd7705 ld (iy+#05),a
24d0 fd360005 ld (iy+#00),#05
24d4 18ed jr #24c3 ; (-19)
24d6 cb7e bit 7,(hl)
24d8 c2d121 jp nz,#21d1
24db 3a0a4e ld a,(#4e0a)
24de ddbe08 cp (ix+#08)
24e1 ca3926 jp z,#2639
24e4 3e01 ld a,#01
24e6 32c24e ld (#4ec2),a
24e9 cbb6 res 6,(hl)
24eb c9 ret
24ec cb7e bit 7,(hl)
24ee c2d121 jp nz,#21d1
24f1 3a0a4e ld a,(#4e0a)
24f4 ddbe08 cp (ix+#08)
24f7 ca3926 jp z,#2639
24fa ddbe05 cp (ix+#05)
24fd 2011 jr nz,#2510 ; (17)
24ff 3a1a4e ld a,(#4e1a)
2502 fd7705 ld (iy+#05),a
2505 fd360004 ld (iy+#00),#04
2509 dd7e07 ld a,(ix+#07)
250c 12 ld (de),a
250d c34121 jp #2141
2510 3a194e ld a,(#4e19)
2513 fd7705 ld (iy+#05),a
2516 fd360005 ld (iy+#00),#05
251a 18ed jr #2509 ; (-19)
251c cb7e bit 7,(hl)
251e c23d21 jp nz,#213d
2521 3a0a4e ld a,(#4e0a)
2524 ddbe08 cp (ix+#08)
2527 c24121 jp nz,#2141
252a fdcb0746 bit 0,(iy+#07)
252e ca4121 jp z,#2141
2531 3e03 ld a,#03
2533 32c24e ld (#4ec2),a
2536 c34121 jp #2141
2539 cb7e bit 7,(hl)
253b c23d21 jp nz,#213d
253e 3a0a4e ld a,(#4e0a)
2541 ddbe08 cp (ix+#08)
2544 c24121 jp nz,#2141
2547 fdcb075e bit 3,(iy+#07)
254b ca4121 jp z,#2141
254e 3e04 ld a,#04
2550 32c24e ld (#4ec2),a
2553 c34121 jp #2141
2556 cb7e bit 7,(hl)
2558 c2fb22 jp nz,#22fb
255b 3a0a4e ld a,(#4e0a)
255e ddbe08 cp (ix+#08)
2561 ca3926 jp z,#2639
2564 ddbe04 cp (ix+#04)
2567 2011 jr nz,#257a ; (17)
2569 3a184e ld a,(#4e18)
256c fd7705 ld (iy+#05),a
256f fd360002 ld (iy+#00),#02
2573 dd7e06 ld a,(ix+#06)
2576 12 ld (de),a
2577 c36b22 jp #226b
257a 3a174e ld a,(#4e17)
257d fd7705 ld (iy+#05),a
2580 fd360003 ld (iy+#00),#03
2584 18ed jr #2573 ; (-19)
2586 cb7e bit 7,(hl)
2588 c2fb22 jp nz,#22fb
258b 3a0a4e ld a,(#4e0a)
258e ddbe08 cp (ix+#08)
2591 ca3926 jp z,#2639
2594 3e02 ld a,#02
2596 32c24e ld (#4ec2),a
2599 cbb6 res 6,(hl)
259b c9 ret
259c cb7e bit 7,(hl)
259e c2fb22 jp nz,#22fb
25a1 3a0a4e ld a,(#4e0a)
25a4 ddbe08 cp (ix+#08)
25a7 ca3926 jp z,#2639
25aa ddbe05 cp (ix+#05)
25ad 2011 jr nz,#25c0 ; (17)
25af 3a184e ld a,(#4e18)
25b2 fd7705 ld (iy+#05),a
25b5 fd360002 ld (iy+#00),#02
25b9 dd7e06 ld a,(ix+#06)
25bc 12 ld (de),a
25bd c36b22 jp #226b
25c0 3a174e ld a,(#4e17)
25c3 fd7705 ld (iy+#05),a
25c6 fd360003 ld (iy+#00),#03
25ca 18ed jr #25b9 ; (-19)
25cc cb7e bit 7,(hl)
25ce c26722 jp nz,#2267
25d1 3a0a4e ld a,(#4e0a)
25d4 ddbe08 cp (ix+#08)
25d7 c26b22 jp nz,#226b
25da fdcb0756 bit 2,(iy+#07)
25de ca6b22 jp z,#226b
25e1 3e05 ld a,#05
25e3 32c24e ld (#4ec2),a
25e6 c36b22 jp #226b
25e9 cb7e bit 7,(hl)
25eb c26722 jp nz,#2267
25ee 3a0a4e ld a,(#4e0a)
25f1 ddbe08 cp (ix+#08)
25f4 c26b22 jp nz,#226b
25f7 fdcb074e bit 1,(iy+#07)
25fb ca6b22 jp z,#226b
25fe 3e06 ld a,#06
2600 32c24e ld (#4ec2),a
2603 c36b22 jp #226b
2606 fd7e07 ld a,(iy+#07)
2609 47 ld b,a
260a fd7e00 ld a,(iy+#00)
260d fe02 cp #02
260f 2810 jr z,#2621 ; (16)
2611 fe03 cp #03
2613 2814 jr z,#2629 ; (20)
2615 fe05 cp #05
2617 2818 jr z,#2631 ; (24)
2619 cb48 bit 1,b
261b ca3c23 jp z,#233c
261e c35623 jp #2356
2621 cb58 bit 3,b
2623 ca3c23 jp z,#233c
2626 c35623 jp #2356
2629 cb40 bit 0,b
262b ca3c23 jp z,#233c
262e c35623 jp #2356
2631 cb50 bit 2,b
2633 ca3c23 jp z,#233c
2636 c35623 jp #2356
2639 112e41 ld de,#412e
263c 21e31e ld hl,#1ee3
263f 3e05 ld a,#05
2641 060e ld b,#0e
2643 cdeb15 call #15eb
2646 112e45 ld de,#452e
2649 213e1f ld hl,#1f3e
264c 3e05 ld a,#05
264e 060e ld b,#0e
2650 cdeb15 call #15eb
2653 af xor a
2654 32644c ld (#4c64),a
2657 326c4c ld (#4c6c),a
265a 32744c ld (#4c74),a
265d 327c4c ld (#4c7c),a
2660 32844c ld (#4c84),a
2663 11cf41 ld de,#41cf
2666 21311f ld hl,#1f31
2669 3e01 ld a,#01
266b 0605 ld b,#05
266d cdd515 call #15d5 ; DRAW TEXT
2670 119141 ld de,#4191
2673 21361f ld hl,#1f36
2676 3e01 ld a,#01
2678 0608 ld b,#08
267a cdd515 call #15d5 ; DRAW TEXT
267d 3e78 ld a,#78
267f cd9b15 call #159b
2682 fdcb07ee set 5,(iy+#07)
2686 c9 ret
2687 05 dec b
2688 2000 jr nz,#268a ; (0)
268a e0 ret po
268b 70 ld (hl),b
268c 42 ld b,d
268d 09 add hl,bc
268e 00 nop
268f 05 dec b
2690 2000 jr nz,#2692 ; (0)
2692 f0 ret p
2693 70 ld (hl),b
2694 3e09 ld a,#09
2696 00 nop
2697 05 dec b
2698 2000 jr nz,#269a ; (0)
269a df rst #18
269b 60 ld h,b
269c 3a0900 ld a,(#0009)
269f 05 dec b
26a0 2000 jr nz,#26a2 ; (0)
26a2 ef rst #28
26a3 60 ld h,b
26a4 3609 ld (hl),#09
26a6 00 nop
26a7 00 nop
26a8 00 nop
26a9 00 nop
26aa 00 nop
26ab 00 nop
26ac 00 nop
26ad 00 nop
26ae 00 nop
26af 00 nop
26b0 00 nop
26b1 00 nop
26b2 00 nop
26b3 00 nop
26b4 00 nop
26b5 00 nop
26b6 00 nop
26b7 04 inc b
26b8 2000 jr nz,#26ba ; (0)
26ba 02 ld (bc),a
26bb 70 ld (hl),b
26bc 2e09 ld l,#09
26be 00 nop
26bf 04 inc b
26c0 2000 jr nz,#26c2 ; (0)
26c2 12 ld (de),a
26c3 70 ld (hl),b
26c4 2a0900 ld hl,(#0009)
26c7 04 inc b
26c8 2000 jr nz,#26ca ; (0)
26ca 016026 ld bc,#2660
26cd 09 add hl,bc
26ce 00 nop
26cf 04 inc b
26d0 2000 jr nz,#26d2 ; (0)
26d2 116022 ld de,#2260
26d5 09 add hl,bc
26d6 00 nop
26d7 04 inc b
26d8 2000 jr nz,#26da ; (0)
26da fa8032 jp m,#3280
26dd 09 add hl,bc
26de 00 nop
26df 00 nop
26e0 00 nop
26e1 00 nop
26e2 00 nop
26e3 00 nop
26e4 00 nop
26e5 00 nop
26e6 00 nop
26e7 3600 ld (hl),#00
26e9 fdcb07ae res 5,(iy+#07)
26ed fd360300 ld (iy+#03),#00
26f1 c9 ret
26f2 14 inc d
26f3 100c djnz #2701 ; (12)
26f5 0e18 ld c,#18
26f7 1818 jr #2711 ; (24)
26f9 1818 jr #2713 ; (24)
26fb 1c inc e
26fc 181c jr #271a ; (28)
26fe 181c jr #271c ; (28)
2700 181c jr #271e ; (28)
2702 181c jr #2720 ; (28)
2704 181c jr #2722 ; (28)
2706 181c jr #2724 ; (28)
2708 181c jr #2726 ; (28)
270a fdcb0776 bit 6,(iy+#07)
270e c8 ret z
270f fd7e00 ld a,(iy+#00)
2712 fe04 cp #04
2714 da7b27 jp c,#277b
2717 dd7e03 ld a,(ix+#03)
271a fdbe03 cp (iy+#03)
271d da6827 jp c,#2768
2720 ca7b27 jp z,#277b
2723 fd7e00 ld a,(iy+#00)
2726 fe05 cp #05
2728 ca9a27 jp z,#279a
272b fd7e07 ld a,(iy+#07)
272e f61f or #1f
2730 e6fb and #fb
2732 fd7707 ld (iy+#07),a
2735 dd7e03 ld a,(ix+#03)
2738 fd4603 ld b,(iy+#03)
273b 90 sub b
273c fe05 cp #05
273e 3805 jr c,#2745 ; (5)
2740 fefb cp #fb
2742 3001 jr nc,#2745 ; (1)
2744 c9 ret
2745 dd7e04 ld a,(ix+#04)
2748 fd4604 ld b,(iy+#04)
274b 90 sub b
274c fe05 cp #05
274e 3805 jr c,#2755 ; (5)
2750 fefb cp #fb
2752 3001 jr nc,#2755 ; (1)
2754 c9 ret
2755 ddcb07ee set 5,(ix+#07)
2759 fdcb07ee set 5,(iy+#07)
275d c9 ret
275e fd7e03 ld a,(iy+#03)
2761 ddbe03 cp (ix+#03)
2764 38c5 jr c,#272b ; (-59)
2766 1807 jr #276f ; (7)
2768 fd7e00 ld a,(iy+#00)
276b fe04 cp #04
276d 282b jr z,#279a ; (43)
276f fd7e07 ld a,(iy+#07)
2772 f61f or #1f
2774 e6fd and #fd
2776 fd7707 ld (iy+#07),a
2779 18ba jr #2735 ; (-70)
277b dd7e04 ld a,(ix+#04)
277e fdbe04 cp (iy+#04)
2781 3821 jr c,#27a4 ; (33)
2783 ca1727 jp z,#2717
2786 fd7e00 ld a,(iy+#00)
2789 fe02 cp #02
278b 28d1 jr z,#275e ; (-47)
278d fd7e07 ld a,(iy+#07)
2790 f61f or #1f
2792 e6f7 and #f7
2794 fd7707 ld (iy+#07),a
2797 c33527 jp #2735
279a fd7e04 ld a,(iy+#04)
279d ddbe04 cp (ix+#04)
27a0 38eb jr c,#278d ; (-21)
27a2 1807 jr #27ab ; (7)
27a4 fd7e00 ld a,(iy+#00)
27a7 fe03 cp #03
27a9 28b3 jr z,#275e ; (-77)
27ab fd7e07 ld a,(iy+#07)
27ae f61f or #1f
27b0 e6fe and #fe
27b2 fd7707 ld (iy+#07),a
27b5 c33527 jp #2735
27b8 fd7e05 ld a,(iy+#05)
27bb fe18 cp #18
27bd 2805 jr z,#27c4 ; (5)
27bf fd360518 ld (iy+#05),#18
27c3 c9 ret
27c4 fd36051c ld (iy+#05),#1c
27c8 c9 ret
27c9 3a254e ld a,(#4e25)
27cc 3c inc a
27cd 32254e ld (#4e25),a
27d0 cb7e bit 7,(hl)
27d2 c0 ret nz
27d3 2a934c ld hl,(#4c93)
27d6 7e ld a,(hl)
27d7 210f28 ld hl,#280f
27da cdb015 call #15b0
27dd 7e ld a,(hl)
27de 32864c ld (#4c86),a
27e1 3a8c4c ld a,(#4c8c)
27e4 32844c ld (#4c84),a
27e7 3a8d4c ld a,(#4c8d)
27ea 32854c ld (#4c85),a
27ed d5 push de
27ee 23 inc hl
27ef 5e ld e,(hl)
27f0 23 inc hl
27f1 56 ld d,(hl)
27f2 2aae4c ld hl,(#4cae)
27f5 19 add hl,de
27f6 22ae4c ld (#4cae),hl
27f9 d1 pop de
27fa 21a74d ld hl,#4da7
27fd cbc6 set 0,(hl)
27ff af xor a
2800 32264e ld (#4e26),a
2803 3a254e ld a,(#4e25)
2806 fe10 cp #10
2808 c0 ret nz
2809 3eff ld a,#ff
280b 32254e ld (#4e25),a
280e c9 ret
280f 44 ld b,h
2810 00 nop
2811 1048 djnz #285b ; (72)
2813 00 nop
2814 204c jr nz,#2862 ; (76)
2816 00 nop
2817 40 ld b,b
2818 50 ld d,b
2819 00 nop
281a 80 add a,b
281b d5 push de
281c e5 push hl
281d 2a0f4e ld hl,(#4e0f)
2820 ed5bae4c ld de,(#4cae)
2824 19 add hl,de
2825 22ae4c ld (#4cae),hl
2828 e1 pop hl
2829 d1 pop de
282a c9 ret
282b dd21fc2d ld ix,#2dfc
282f dd22f64d ld (#4df6),ix
2833 216a2f ld hl,#2f6a
2836 3e1a ld a,#1a
2838 cdc62b call #2bc6
283b cdb730 call #30b7
283e 3e84 ld a,#84
2840 21062b ld hl,#2b06
2843 cdd52c call #2cd5
2846 211000 ld hl,#0010
2849 22114e ld (#4e11),hl
284c 3e02 ld a,#02
284e 32134e ld (#4e13),a
2851 3e05 ld a,#05
2853 32144e ld (#4e14),a
2856 3e0e ld a,#0e
2858 32294e ld (#4e29),a
285b 21dc2c ld hl,#2cdc
285e cd312c call #2c31
2861 cd3a2c call #2c3a
2864 c9 ret
2865 dd21052e ld ix,#2e05
2869 dd22f64d ld (#4df6),ix
286d 21602e ld hl,#2e60
2870 3e19 ld a,#19
2872 cdc62b call #2bc6
2875 cd1031 call #3110
2878 3e87 ld a,#87
287a 21262b ld hl,#2b26
287d cdd52c call #2cd5
2880 212000 ld hl,#0020
2883 22114e ld (#4e11),hl
2886 3e04 ld a,#04
2888 32134e ld (#4e13),a
288b 3e07 ld a,#07
288d 32144e ld (#4e14),a
2890 3e0e ld a,#0e
2892 32294e ld (#4e29),a
2895 210c2d ld hl,#2d0c
2898 cd312c call #2c31
289b cd3a2c call #2c3a
289e c9 ret
289f dd21052e ld ix,#2e05
28a3 dd22f64d ld (#4df6),ix
28a7 21f72e ld hl,#2ef7
28aa 3e11 ld a,#11
28ac cdc62b call #2bc6
28af cd3931 call #3139
28b2 3e6c ld a,#6c
28b4 21462b ld hl,#2b46
28b7 cdd52c call #2cd5
28ba 213000 ld hl,#0030
28bd 22114e ld (#4e11),hl
28c0 3e06 ld a,#06
28c2 32134e ld (#4e13),a
28c5 3e09 ld a,#09
28c7 32144e ld (#4e14),a
28ca 3e0e ld a,#0e
28cc 32294e ld (#4e29),a
28cf 213c2d ld hl,#2d3c
28d2 cd312c call #2c31
28d5 cd3a2c call #2c3a
28d8 c9 ret
28d9 dd21052e ld ix,#2e05
28dd dd22f64d ld (#4df6),ix
28e1 219530 ld hl,#3095
28e4 3e0e ld a,#0e
28e6 cdc62b call #2bc6
28e9 cd8631 call #3186
28ec 3e78 ld a,#78
28ee 21662b ld hl,#2b66
28f1 cdd52c call #2cd5
28f4 214000 ld hl,#0040
28f7 22114e ld (#4e11),hl
28fa 3e08 ld a,#08
28fc 32134e ld (#4e13),a
28ff 3e0c ld a,#0c
2901 32144e ld (#4e14),a
2904 3e0f ld a,#0f
2906 32294e ld (#4e29),a
2909 216c2d ld hl,#2d6c
290c cd312c call #2c31
290f cd3a2c call #2c3a
2912 c9 ret
2913 dd21052e ld ix,#2e05
2917 dd22f64d ld (#4df6),ix
291b 213730 ld hl,#3037
291e 3e1f ld a,#1f
2920 cdc62b call #2bc6
2923 cd9531 call #3195
2926 3e72 ld a,#72
2928 21862b ld hl,#2b86
292b cdd52c call #2cd5
292e 215000 ld hl,#0050
2931 22114e ld (#4e11),hl
2934 3e08 ld a,#08
2936 32134e ld (#4e13),a
2939 3e0c ld a,#0c
293b 32144e ld (#4e14),a
293e 3e0f ld a,#0f
2940 32294e ld (#4e29),a
2943 219c2d ld hl,#2d9c
2946 cd312c call #2c31
2949 cd3a2c call #2c3a
294c c9 ret
294d dd21fc2d ld ix,#2dfc
2951 dd22f64d ld (#4df6),ix
2955 210e2e ld hl,#2e0e
2958 3e1a ld a,#1a
295a cdc62b call #2bc6
295d cdb631 call #31b6
2960 3e6f ld a,#6f
2962 21a62b ld hl,#2ba6
2965 cdd52c call #2cd5
2968 216000 ld hl,#0060
296b 22114e ld (#4e11),hl
296e 3e08 ld a,#08
2970 32134e ld (#4e13),a
2973 3e0c ld a,#0c
2975 32144e ld (#4e14),a
2978 3e0f ld a,#0f
297a 32294e ld (#4e29),a
297d 21cc2d ld hl,#2dcc
2980 cd312c call #2c31
2983 cd3a2c call #2c3a
2986 c9 ret
2987 dd21052e ld ix,#2e05
298b dd22f64d ld (#4df6),ix
298f 216a2f ld hl,#2f6a
2992 3e19 ld a,#19
2994 cdc62b call #2bc6
2997 cdb730 call #30b7
299a 3e81 ld a,#81
299c 21062b ld hl,#2b06
299f cdd52c call #2cd5
29a2 217000 ld hl,#0070
29a5 22114e ld (#4e11),hl
29a8 3e08 ld a,#08
29aa 32134e ld (#4e13),a
29ad 3e0c ld a,#0c
29af 32144e ld (#4e14),a
29b2 3e0f ld a,#0f
29b4 32294e ld (#4e29),a
29b7 21dc2c ld hl,#2cdc
29ba cd312c call #2c31
29bd cd3a2c call #2c3a
29c0 c9 ret
29c1 dd21052e ld ix,#2e05
29c5 dd22f64d ld (#4df6),ix
29c9 21602e ld hl,#2e60
29cc 3e11 ld a,#11
29ce cdc62b call #2bc6
29d1 cd1031 call #3110
29d4 3e75 ld a,#75
29d6 21262b ld hl,#2b26
29d9 cdd52c call #2cd5
29dc 218000 ld hl,#0080
29df 22114e ld (#4e11),hl
29e2 3e09 ld a,#09
29e4 32134e ld (#4e13),a
29e7 3e0d ld a,#0d
29e9 32144e ld (#4e14),a
29ec 3e0f ld a,#0f
29ee 32294e ld (#4e29),a
29f1 210c2d ld hl,#2d0c
29f4 cd312c call #2c31
29f7 cd3a2c call #2c3a
29fa c9 ret
29fb dd21052e ld ix,#2e05
29ff dd22f64d ld (#4df6),ix
2a03 21f72e ld hl,#2ef7
2a06 3e0e ld a,#0e
2a08 cdc62b call #2bc6
2a0b cd3931 call #3139
2a0e 3e69 ld a,#69
2a10 21462b ld hl,#2b46
2a13 cdd52c call #2cd5
2a16 219000 ld hl,#0090
2a19 22114e ld (#4e11),hl
2a1c 3e09 ld a,#09
2a1e 32134e ld (#4e13),a
2a21 3e0d ld a,#0d
2a23 32144e ld (#4e14),a
2a26 3e0f ld a,#0f
2a28 32294e ld (#4e29),a
2a2b 213c2d ld hl,#2d3c
2a2e cd312c call #2c31
2a31 cd3a2c call #2c3a
2a34 c9 ret
2a35 dd21052e ld ix,#2e05
2a39 dd22f64d ld (#4df6),ix
2a3d 219530 ld hl,#3095
2a40 3e1f ld a,#1f
2a42 cdc62b call #2bc6
2a45 cd8631 call #3186
2a48 3e7b ld a,#7b
2a4a 21662b ld hl,#2b66
2a4d cdd52c call #2cd5
2a50 210001 ld hl,#0100
2a53 22114e ld (#4e11),hl
2a56 3e0a ld a,#0a
2a58 32134e ld (#4e13),a
2a5b 3e0e ld a,#0e
2a5d 32144e ld (#4e14),a
2a60 3e0f ld a,#0f
2a62 32294e ld (#4e29),a
2a65 216c2d ld hl,#2d6c
2a68 cd312c call #2c31
2a6b cd3a2c call #2c3a
2a6e c9 ret
2a6f dd21fc2d ld ix,#2dfc
2a73 dd22f64d ld (#4df6),ix
2a77 213730 ld hl,#3037
2a7a 3e1a ld a,#1a
2a7c cdc62b call #2bc6
2a7f cd9531 call #3195
2a82 3e7e ld a,#7e
2a84 21862b ld hl,#2b86
2a87 cdd52c call #2cd5
2a8a 211001 ld hl,#0110
2a8d 22114e ld (#4e11),hl
2a90 3e0c ld a,#0c
2a92 32134e ld (#4e13),a
2a95 3e0f ld a,#0f
2a97 32144e ld (#4e14),a
2a9a 3e0e ld a,#0e
2a9c 32294e ld (#4e29),a
2a9f 219c2d ld hl,#2d9c
2aa2 cd312c call #2c31
2aa5 cd3a2c call #2c3a
2aa8 c9 ret
2aa9 dd21052e ld ix,#2e05
2aad dd22f64d ld (#4df6),ix
2ab1 210e2e ld hl,#2e0e
2ab4 3e19 ld a,#19
2ab6 cdc62b call #2bc6
2ab9 cdb631 call #31b6
2abc 3e66 ld a,#66
2abe 21a62b ld hl,#2ba6
2ac1 cdd52c call #2cd5
2ac4 212001 ld hl,#0120
2ac7 22114e ld (#4e11),hl
2aca 3e0d ld a,#0d
2acc 32134e ld (#4e13),a
2acf 3e10 ld a,#10
2ad1 32144e ld (#4e14),a
2ad4 3e0e ld a,#0e
2ad6 32294e ld (#4e29),a
2ad9 21cc2d ld hl,#2dcc
2adc cd312c call #2c31
2adf cd3a2c call #2c3a
2ae2 c9 ret
2ae3 c9 ret
2ae4 c9 ret
2ae5 c9 ret
2ae6 c9 ret
2ae7 0f rrca
2ae8 4d ld c,l
2ae9 52 ld d,d
2aea 2054 jr nz,#2b40 ; (84)
2aec 4e ld c,(hl)
2aed 54 ld d,h
2aee 2c inc l
2aef 43 ld b,e
2af0 4f ld c,a
2af1 50 ld d,b
2af2 59 ld e,c
2af3 52 ld d,d
2af4 49 ld c,c
2af5 47 ld b,a
2af6 48 ld c,b
2af7 54 ld d,h
2af8 2031 jr nz,#2b2b ; (49)
2afa 39 add hl,sp
2afb 3833 jr c,#2b30 ; (51)
2afd 54 ld d,h
2afe 45 ld b,l
2aff 4c ld c,h
2b00 4b ld c,e
2b01 4f ld c,a
2b02 2049 jr nz,#2b4d ; (73)
2b04 4e ld c,(hl)
2b05 43 ld b,e
2b06 a3 and e
2b07 40 ld b,b
2b08 bc cp h
2b09 40 ld b,b
2b0a 8c adc a,h
2b0b 41 ld b,c
2b0c 93 sub e
2b0d 41 ld b,c
2b0e 6c ld l,h
2b0f 42 ld b,d
2b10 73 ld (hl),e
2b11 42 ld b,d
2b12 43 ld b,e
2b13 43 ld b,e
2b14 5c ld e,h
2b15 43 ld b,e
2b16 8b adc a,e
2b17 40 ld b,b
2b18 94 sub h
2b19 40 ld b,b
2b1a a4 and h
2b1b 41 ld b,c
2b1c bb cp e
2b1d 41 ld b,c
2b1e 44 ld b,h
2b1f 42 ld b,d
2b20 5b ld e,e
2b21 42 ld b,d
2b22 6b ld l,e
2b23 43 ld b,e
2b24 74 ld (hl),h
2b25 43 ld b,e
2b26 ac xor h
2b27 40 ld b,b
2b28 b3 or e
2b29 40 ld b,b
2b2a 29 add hl,hl
2b2b 41 ld b,c
2b2c 3641 ld (hl),#41
2b2e c9 ret
2b2f 42 ld b,d
2b30 d642 sub #42
2b32 4c ld c,h
2b33 43 ld b,e
2b34 53 ld d,e
2b35 43 ld b,e
2b36 23 inc hl
2b37 41 ld b,c
2b38 3c inc a
2b39 41 ld b,c
2b3a 8d adc a,l
2b3b 41 ld b,c
2b3c 92 sub d
2b3d 41 ld b,c
2b3e 6d ld l,l
2b3f 42 ld b,d
2b40 72 ld (hl),d
2b41 42 ld b,d
2b42 c342dc jp #dc42
2b45 42 ld b,d
2b46 cd40d2 call #d240
2b49 40 ld b,b
2b4a 46 ld b,(hl)
2b4b 41 ld b,c
2b4c 59 ld e,c
2b4d 41 ld b,c
2b4e a6 and (hl)
2b4f 42 ld b,d
2b50 b9 cp c
2b51 42 ld b,d
2b52 2d dec l
2b53 43 ld b,e
2b54 3243a3 ld (#a343),a
2b57 40 ld b,b
2b58 bc cp h
2b59 40 ld b,b
2b5a 8a adc a,d
2b5b 41 ld b,c
2b5c 95 sub l
2b5d 41 ld b,c
2b5e 6a ld l,d
2b5f 42 ld b,d
2b60 75 ld (hl),l
2b61 42 ld b,d
2b62 43 ld b,e
2b63 43 ld b,e
2b64 5c ld e,h
2b65 43 ld b,e
2b66 ab xor e
2b67 40 ld b,b
2b68 b4 or h
2b69 40 ld b,b
2b6a 2c inc l
2b6b 41 ld b,c
2b6c 33 inc sp
2b6d 41 ld b,c
2b6e cc42d3 call z,#d342
2b71 42 ld b,d
2b72 4b ld c,e
2b73 43 ld b,e
2b74 54 ld d,h
2b75 43 ld b,e
2b76 cd41d2 call #d241
2b79 41 ld b,c
2b7a 88 adc a,b
2b7b 41 ld b,c
2b7c 97 sub a
2b7d 41 ld b,c
2b7e 68 ld l,b
2b7f 42 ld b,d
2b80 77 ld (hl),a
2b81 42 ld b,d
2b82 2d dec l
2b83 42 ld b,d
2b84 3242c5 ld (#c542),a
2b87 40 ld b,b
2b88 da408b jp c,#8b40
2b8b 41 ld b,c
2b8c 94 sub h
2b8d 41 ld b,c
2b8e 6b ld l,e
2b8f 42 ld b,d
2b90 74 ld (hl),h
2b91 42 ld b,d
2b92 25 dec h
2b93 43 ld b,e
2b94 3a43ec ld a,(#ec43)
2b97 40 ld b,b
2b98 f3 di
2b99 40 ld b,b
2b9a 2841 jr z,#2bdd ; (65)
2b9c 37 scf
2b9d 41 ld b,c
2b9e c8 ret z
2b9f 42 ld b,d
2ba0 d7 rst #10
2ba1 42 ld b,d
2ba2 0c inc c
2ba3 43 ld b,e
2ba4 13 inc de
2ba5 43 ld b,e
2ba6 c440db call nz,#db40
2ba9 40 ld b,b
2baa 2c inc l
2bab 41 ld b,c
2bac 33 inc sp
2bad 41 ld b,c
2bae cc42d3 call z,#d342
2bb1 42 ld b,d
2bb2 24 inc h
2bb3 43 ld b,e
2bb4 3b dec sp
2bb5 43 ld b,e
2bb6 89 adc a,c
2bb7 40 ld b,b
2bb8 96 sub (hl)
2bb9 40 ld b,b
2bba a8 xor b
2bbb 41 ld b,c
2bbc b7 or a
2bbd 41 ld b,c
2bbe 48 ld c,b
2bbf 42 ld b,d
2bc0 57 ld d,a
2bc1 42 ld b,d
2bc2 69 ld l,c
2bc3 43 ld b,e
2bc4 76 halt
2bc5 43 ld b,e
2bc6 e5 push hl
2bc7 cd0d15 call #150d
2bca 114040 ld de,#4040
2bcd e1 pop hl
2bce d5 push de
2bcf 11df4d ld de,#4ddf
2bd2 eda0 ldi
2bd4 eda0 ldi
2bd6 eda0 ldi
2bd8 7e ld a,(hl)
2bd9 fe0f cp #0f
2bdb 38f5 jr c,#2bd2 ; (-11)
2bdd eda0 ldi
2bdf 2b dec hl
2be0 d1 pop de
2be1 e5 push hl
2be2 21df4d ld hl,#4ddf
2be5 23 inc hl
2be6 46 ld b,(hl)
2be7 dd7e00 ld a,(ix+#00)
2bea 12 ld (de),a
2beb 13 inc de
2bec 10fc djnz #2bea ; (-4)
2bee 7e ld a,(hl)
2bef 23 inc hl
2bf0 86 add a,(hl)
2bf1 2b dec hl
2bf2 77 ld (hl),a
2bf3 23 inc hl
2bf4 23 inc hl
2bf5 7e ld a,(hl)
2bf6 fef0 cp #f0
2bf8 3018 jr nc,#2c12 ; (24)
2bfa 12 ld (de),a
2bfb 13 inc de
2bfc 23 inc hl
2bfd 46 ld b,(hl)
2bfe dd7e01 ld a,(ix+#01)
2c01 12 ld (de),a
2c02 13 inc de
2c03 10fc djnz #2c01 ; (-4)
2c05 7e ld a,(hl)
2c06 23 inc hl
2c07 86 add a,(hl)
2c08 2b dec hl
2c09 77 ld (hl),a
2c0a 23 inc hl
2c0b 23 inc hl
2c0c 7e ld a,(hl)
2c0d 12 ld (de),a
2c0e 13 inc de
2c0f c3e52b jp #2be5
2c12 21df4d ld hl,#4ddf
2c15 3af54d ld a,(#4df5)
2c18 3c inc a
2c19 32f54d ld (#4df5),a
2c1c fe1c cp #1c
2c1e 280b jr z,#2c2b ; (11)
2c20 7e ld a,(hl)
2c21 3d dec a
2c22 77 ld (hl),a
2c23 fef1 cp #f1
2c25 d2e52b jp nc,#2be5
2c28 c3cd2b jp #2bcd
2c2b e1 pop hl
2c2c af xor a
2c2d 32f54d ld (#4df5),a
2c30 c9 ret
2c31 11614c ld de,#4c61
2c34 013000 ld bc,#0030
2c37 edb0 ldir
2c39 c9 ret
2c3a 21f84d ld hl,#4df8
2c3d 11f94d ld de,#4df9
2c40 3600 ld (hl),#00
2c42 011100 ld bc,#0011
2c45 edb0 ldir
2c47 21fb4d ld hl,#4dfb
2c4a cbfe set 7,(hl)
2c4c 21fe4d ld hl,#4dfe
2c4f cbfe set 7,(hl)
2c51 21014e ld hl,#4e01
2c54 cbfe set 7,(hl)
2c56 21044e ld hl,#4e04
2c59 cbfe set 7,(hl)
2c5b 21074e ld hl,#4e07
2c5e cbfe set 7,(hl)
2c60 af xor a
2c61 321b4e ld (#4e1b),a
2c64 32254e ld (#4e25),a
2c67 32264e ld (#4e26),a
2c6a 322a4e ld (#4e2a),a
2c6d 322b4e ld (#4e2b),a
2c70 3a044d ld a,(#4d04)
2c73 17 rla
2c74 219d2c ld hl,#2c9d
2c77 cdb015 call #15b0
2c7a 7e ld a,(hl)
2c7b 323040 ld (#4030),a
2c7e 23 inc hl
2c7f 7e ld a,(hl)
2c80 322f40 ld (#402f),a
2c83 3e01 ld a,#01
2c85 323044 ld (#4430),a
2c88 322f44 ld (#442f),a
2c8b 3e40 ld a,#40
2c8d 32234e ld (#4e23),a
2c90 32244e ld (#4e24),a
2c93 21dd4d ld hl,#4ddd
2c96 cb86 res 0,(hl)
2c98 af xor a
2c99 32c24e ld (#4ec2),a
2c9c c9 ret
2c9d 40 ld b,b
2c9e 014002 ld bc,#0240
2ca1 40 ld b,b
2ca2 03 inc bc
2ca3 40 ld b,b
2ca4 04 inc b
2ca5 40 ld b,b
2ca6 05 dec b
2ca7 40 ld b,b
2ca8 0640 ld b,#40
2caa 07 rlca
2cab 40 ld b,b
2cac 08 ex af,af'
2cad 40 ld b,b
2cae 09 add hl,bc
2caf 010001 ld bc,#0100
2cb2 010102 ld bc,#0201
2cb5 010301 ld bc,#0103
2cb8 04 inc b
2cb9 010501 ld bc,#0105
2cbc 0601 ld b,#01
2cbe 07 rlca
2cbf 010801 ld bc,#0108
2cc2 09 add hl,bc
2cc3 02 ld (bc),a
2cc4 00 nop
2cc5 02 ld (bc),a
2cc6 010202 ld bc,#0202
2cc9 02 ld (bc),a
2cca 03 inc bc
2ccb 02 ld (bc),a
2ccc 04 inc b
2ccd 02 ld (bc),a
2cce 05 dec b
2ccf 02 ld (bc),a
2cd0 0602 ld b,#02
2cd2 07 rlca
2cd3 02 ld (bc),a
2cd4 08 ex af,af'
2cd5 322c4e ld (#4e2c),a
2cd8 22274e ld (#4e27),hl
2cdb c9 ret
2cdc 03 inc bc
2cdd 02 ld (bc),a
2cde 00 nop
2cdf 3b dec sp
2ce0 14 inc d
2ce1 1809 jr #2cec ; (9)
2ce3 5f ld e,a
2ce4 03 inc bc
2ce5 02 ld (bc),a
2ce6 00 nop
2ce7 63 ld h,e
2ce8 14 inc d
2ce9 1809 jr #2cf4 ; (9)
2ceb 1f rra
2cec 03 inc bc
2ced 02 ld (bc),a
2cee 00 nop
2cef ab xor e
2cf0 14 inc d
2cf1 1809 jr #2cfc ; (9)
2cf3 1f rra
2cf4 03 inc bc
2cf5 02 ld (bc),a
2cf6 00 nop
2cf7 d314 out (#14),a
2cf9 1809 jr #2d04 ; (9)
2cfb 1f rra
2cfc 00 nop
2cfd 00 nop
2cfe 00 nop
2cff 00 nop
2d00 00 nop
2d01 00 nop
2d02 09 add hl,bc
2d03 00 nop
2d04 02 ld (bc),a
2d05 04 inc b
2d06 00 nop
2d07 8b adc a,e
2d08 e41009 call po,#0910
2d0b 40 ld b,b
2d0c 03 inc bc
2d0d 02 ld (bc),a
2d0e 00 nop
2d0f 63 ld h,e
2d10 14 inc d
2d11 1809 jr #2d1c ; (9)
2d13 5f ld e,a
2d14 03 inc bc
2d15 02 ld (bc),a
2d16 00 nop
2d17 7b ld a,e
2d18 14 inc d
2d19 1809 jr #2d24 ; (9)
2d1b 1f rra
2d1c 03 inc bc
2d1d 02 ld (bc),a
2d1e 00 nop
2d1f 93 sub e
2d20 14 inc d
2d21 1809 jr #2d2c ; (9)
2d23 1f rra
2d24 03 inc bc
2d25 02 ld (bc),a
2d26 00 nop
2d27 ab xor e
2d28 14 inc d
2d29 1809 jr #2d34 ; (9)
2d2b 1f rra
2d2c 00 nop
2d2d 00 nop
2d2e 00 nop
2d2f 00 nop
2d30 00 nop
2d31 00 nop
2d32 09 add hl,bc
2d33 00 nop
2d34 02 ld (bc),a
2d35 04 inc b
2d36 00 nop
2d37 8b adc a,e
2d38 fc1009 call m,#0910
2d3b 40 ld b,b
2d3c 03 inc bc
2d3d 02 ld (bc),a
2d3e 00 nop
2d3f 4b ld c,e
2d40 24 inc h
2d41 1809 jr #2d4c ; (9)
2d43 5f ld e,a
2d44 03 inc bc
2d45 02 ld (bc),a
2d46 00 nop
2d47 73 ld (hl),e
2d48 24 inc h
2d49 1809 jr #2d54 ; (9)
2d4b 1f rra
2d4c 03 inc bc
2d4d 02 ld (bc),a
2d4e 00 nop
2d4f 9b sbc a,e
2d50 24 inc h
2d51 1809 jr #2d5c ; (9)
2d53 1f rra
2d54 03 inc bc
2d55 02 ld (bc),a
2d56 00 nop
2d57 c32418 jp #1824
2d5a 09 add hl,bc
2d5b 1f rra
2d5c 00 nop
2d5d 00 nop
2d5e 00 nop
2d5f 00 nop
2d60 00 nop
2d61 00 nop
2d62 09 add hl,bc
2d63 00 nop
2d64 02 ld (bc),a
2d65 04 inc b
2d66 00 nop
2d67 8b adc a,e
2d68 ec1009 call pe,#0910
2d6b 40 ld b,b
2d6c 03 inc bc
2d6d 02 ld (bc),a
2d6e 00 nop
2d6f 43 ld b,e
2d70 44 ld b,h
2d71 1809 jr #2d7c ; (9)
2d73 5f ld e,a
2d74 03 inc bc
2d75 02 ld (bc),a
2d76 00 nop
2d77 53 ld d,e
2d78 34 inc (hl)
2d79 1809 jr #2d84 ; (9)
2d7b 1f rra
2d7c 03 inc bc
2d7d 02 ld (bc),a
2d7e 00 nop
2d7f bb cp e
2d80 34 inc (hl)
2d81 1809 jr #2d8c ; (9)
2d83 1f rra
2d84 03 inc bc
2d85 02 ld (bc),a
2d86 00 nop
2d87 cb44 bit 0,h
2d89 1809 jr #2d94 ; (9)
2d8b 1f rra
2d8c 00 nop
2d8d 00 nop
2d8e 00 nop
2d8f 00 nop
2d90 00 nop
2d91 00 nop
2d92 09 add hl,bc
2d93 00 nop
2d94 02 ld (bc),a
2d95 04 inc b
2d96 00 nop
2d97 8b adc a,e
2d98 fc1009 call m,#0910
2d9b 40 ld b,b
2d9c 03 inc bc
2d9d 02 ld (bc),a
2d9e 00 nop
2d9f 5b ld e,e
2da0 2c inc l
2da1 1809 jr #2dac ; (9)
2da3 5f ld e,a
2da4 03 inc bc
2da5 02 ld (bc),a
2da6 00 nop
2da7 73 ld (hl),e
2da8 2c inc l
2da9 1809 jr #2db4 ; (9)
2dab 1f rra
2dac 03 inc bc
2dad 02 ld (bc),a
2dae 00 nop
2daf 9b sbc a,e
2db0 2c inc l
2db1 1809 jr #2dbc ; (9)
2db3 1f rra
2db4 03 inc bc
2db5 02 ld (bc),a
2db6 00 nop
2db7 b3 or e
2db8 2c inc l
2db9 1809 jr #2dc4 ; (9)
2dbb 1f rra
2dbc 00 nop
2dbd 00 nop
2dbe 00 nop
2dbf 00 nop
2dc0 00 nop
2dc1 00 nop
2dc2 09 add hl,bc
2dc3 00 nop
2dc4 02 ld (bc),a
2dc5 04 inc b
2dc6 00 nop
2dc7 8b adc a,e
2dc8 e41009 call po,#0910
2dcb 40 ld b,b
2dcc 03 inc bc
2dcd 02 ld (bc),a
2dce 00 nop
2dcf 43 ld b,e
2dd0 14 inc d
2dd1 1809 jr #2ddc ; (9)
2dd3 5f ld e,a
2dd4 03 inc bc
2dd5 02 ld (bc),a
2dd6 00 nop
2dd7 5b ld e,e
2dd8 14 inc d
2dd9 1809 jr #2de4 ; (9)
2ddb 1f rra
2ddc 03 inc bc
2ddd 02 ld (bc),a
2dde 00 nop
2ddf b3 or e
2de0 14 inc d
2de1 1809 jr #2dec ; (9)
2de3 1f rra
2de4 03 inc bc
2de5 02 ld (bc),a
2de6 00 nop
2de7 cb14 rl h
2de9 1809 jr #2df4 ; (9)
2deb 1f rra
2dec 00 nop
2ded 00 nop
2dee 00 nop
2def 00 nop
2df0 00 nop
2df1 00 nop
2df2 09 add hl,bc
2df3 00 nop
2df4 02 ld (bc),a
2df5 04 inc b
2df6 00 nop
2df7 8b adc a,e
2df8 dc1009 call c,#0910
2dfb 40 ld b,b
2dfc 65 ld h,l
2dfd 0a ld a,(bc)
2dfe 0b dec bc
2dff 0c inc c
2e00 0d dec c
2e01 0e0f ld c,#0f
2e03 1014 djnz #2e19 ; (20)
2e05 65 ld h,l
2e06 0a ld a,(bc)
2e07 0b dec bc
2e08 0c inc c
2e09 0d dec c
2e0a 0e0f ld c,#0f
2e0c 1016 djnz #2e24 ; (22)
2e0e f1 pop af
2e0f 2000 jr nz,#2e11 ; (0)
2e11 f404ff call p,#ff04
2e14 0b dec bc
2e15 0602 ld b,#02
2e17 0d dec c
2e18 08 ex af,af'
2e19 fe0b cp #0b
2e1b 0602 ld b,#02
2e1d 0d dec c
2e1e 04 inc b
2e1f ff rst #38
2e20 f40100 call p,#0001
2e23 0a ld a,(bc)
2e24 1c inc e
2e25 00 nop
2e26 0a ld a,(bc)
2e27 0100f4 ld bc,#f400
2e2a 01010c ld bc,#0c01
2e2d 1c inc e
2e2e fe0e cp #0e
2e30 0101f2 ld bc,#f201
2e33 05 dec b
2e34 00 nop
2e35 0a ld a,(bc)
2e36 14 inc d
2e37 00 nop
2e38 0a ld a,(bc)
2e39 05 dec b
2e3a 00 nop
2e3b f404ff call p,#ff04
2e3e 0b dec bc
2e3f 1602 ld d,#02
2e41 0d dec c
2e42 04 inc b
2e43 ff rst #38
2e44 f40100 call p,#0001
2e47 0a ld a,(bc)
2e48 1c inc e
2e49 00 nop
2e4a 0a ld a,(bc)
2e4b 0100f4 ld bc,#f400
2e4e 01010c ld bc,#0c01
2e51 0c inc c
2e52 fe0e cp #0e
2e54 02 ld (bc),a
2e55 02 ld (bc),a
2e56 0c inc c
2e57 0c inc c
2e58 fe0e cp #0e
2e5a 0101f1 ld bc,#f101
2e5d 2000 jr nz,#2e5f ; (0)
2e5f ff rst #38
2e60 f1 pop af
2e61 2000 jr nz,#2e63 ; (0)
2e63 f3 di
2e64 07 rlca
2e65 010c10 ld bc,#100c
2e68 fe0e cp #0e
2e6a 07 rlca
2e6b 01f10a ld bc,#0af1
2e6e 00 nop
2e6f 0a ld a,(bc)
2e70 0a ld a,(bc)
2e71 00 nop
2e72 0a ld a,(bc)
2e73 0a ld a,(bc)
2e74 00 nop
2e75 f1 pop af
2e76 09 add hl,bc
2e77 00 nop
2e78 0b dec bc
2e79 0c inc c
2e7a 00 nop
2e7b 0d dec c
2e7c 09 add hl,bc
2e7d 00 nop
2e7e f20100 jp p,#0001
2e81 0a ld a,(bc)
2e82 02 ld (bc),a
2e83 010d03 ld bc,#030d
2e86 fe0b cp #0b
2e88 0e02 ld c,#02
2e8a 0d dec c
2e8b 03 inc bc
2e8c fe0b cp #0b
2e8e 02 ld (bc),a
2e8f 010a01 ld bc,#010a
2e92 00 nop
2e93 f40100 call p,#0001
2e96 0a ld a,(bc)
2e97 1c inc e
2e98 00 nop
2e99 0a ld a,(bc)
2e9a 0100f2 ld bc,#f200
2e9d 01000a ld bc,#0a00
2ea0 0c inc c
2ea1 ff rst #38
2ea2 0e02 ld c,#02
2ea4 02 ld (bc),a
2ea5 0c inc c
2ea6 0c inc c
2ea7 ff rst #38
2ea8 0a ld a,(bc)
2ea9 0100f2 ld bc,#f200
2eac 01000a ld bc,#0a00
2eaf 0b dec bc
2eb0 010d04 ld bc,#040d
2eb3 fe0b cp #0b
2eb5 0b dec bc
2eb6 010a01 ld bc,#010a
2eb9 00 nop
2eba f40100 call p,#0001
2ebd 0a ld a,(bc)
2ebe 1c inc e
2ebf 00 nop
2ec0 0a ld a,(bc)
2ec1 0100f2 ld bc,#f200
2ec4 01000a ld bc,#0a00
2ec7 03 inc bc
2ec8 ff rst #38
2ec9 0e01 ld c,#01
2ecb 02 ld (bc),a
2ecc 0c inc c
2ecd 10fe djnz #2ecd ; (-2)
2ecf 0e01 ld c,#01
2ed1 02 ld (bc),a
2ed2 0c inc c
2ed3 03 inc bc
2ed4 ff rst #38
2ed5 0a ld a,(bc)
2ed6 0100f1 ld bc,#f100
2ed9 09 add hl,bc
2eda 00 nop
2edb 0c inc c
2edc 0c inc c
2edd 00 nop
2ede 0e09 ld c,#09
2ee0 00 nop
2ee1 f1 pop af
2ee2 0a ld a,(bc)
2ee3 00 nop
2ee4 0a ld a,(bc)
2ee5 0a ld a,(bc)
2ee6 00 nop
2ee7 0a ld a,(bc)
2ee8 0a ld a,(bc)
2ee9 00 nop
2eea f3 di
2eeb 09 add hl,bc
2eec ff rst #38
2eed 0b dec bc
2eee 0c inc c
2eef 02 ld (bc),a
2ef0 0d dec c
2ef1 09 add hl,bc
2ef2 ff rst #38
2ef3 f1 pop af
2ef4 2000 jr nz,#2ef6 ; (0)
2ef6 ff rst #38
2ef7 f1 pop af
2ef8 2000 jr nz,#2efa ; (0)
2efa f40100 call p,#0001
2efd 0a ld a,(bc)
2efe 02 ld (bc),a
2eff 010d08 ld bc,#080d
2f02 fe0b cp #0b
2f04 04 inc b
2f05 02 ld (bc),a
2f06 0d dec c
2f07 08 ex af,af'
2f08 fe0b cp #0b
2f0a 02 ld (bc),a
2f0b 010a01 ld bc,#010a
2f0e 00 nop
2f0f f1 pop af
2f10 02 ld (bc),a
2f11 00 nop
2f12 0c inc c
2f13 1a ld a,(de)
2f14 00 nop
2f15 0e02 ld c,#02
2f17 00 nop
2f18 f5 push af
2f19 03 inc bc
2f1a 00 nop
2f1b 0a ld a,(bc)
2f1c 1800 jr #2f1e ; (0)
2f1e 0a ld a,(bc)
2f1f 03 inc bc
2f20 00 nop
2f21 f3 di
2f22 03 inc bc
2f23 00 nop
2f24 0a ld a,(bc)
2f25 0a ld a,(bc)
2f26 ff rst #38
2f27 0e02 ld c,#02
2f29 02 ld (bc),a
2f2a 0c inc c
2f2b 0a ld a,(bc)
2f2c ff rst #38
2f2d 0a ld a,(bc)
2f2e 03 inc bc
2f2f 00 nop
2f30 f3 di
2f31 03 inc bc
2f32 00 nop
2f33 0a ld a,(bc)
2f34 08 ex af,af'
2f35 010d06 ld bc,#060d
2f38 fe0b cp #0b
2f3a 08 ex af,af'
2f3b 010a03 ld bc,#030a
2f3e 00 nop
2f3f f5 push af
2f40 03 inc bc
2f41 00 nop
2f42 0a ld a,(bc)
2f43 1800 jr #2f45 ; (0)
2f45 0a ld a,(bc)
2f46 03 inc bc
2f47 00 nop
2f48 f1 pop af
2f49 02 ld (bc),a
2f4a 00 nop
2f4b 0b dec bc
2f4c 1a ld a,(de)
2f4d 00 nop
2f4e 0d dec c
2f4f 02 ld (bc),a
2f50 00 nop
2f51 f40100 call p,#0001
2f54 0a ld a,(bc)
2f55 05 dec b
2f56 ff rst #38
2f57 0e02 ld c,#02
2f59 02 ld (bc),a
2f5a 0c inc c
2f5b 0a ld a,(bc)
2f5c fe0e cp #0e
2f5e 02 ld (bc),a
2f5f 02 ld (bc),a
2f60 0c inc c
2f61 05 dec b
2f62 ff rst #38
2f63 0a ld a,(bc)
2f64 0100f1 ld bc,#f100
2f67 2000 jr nz,#2f69 ; (0)
2f69 ff rst #38
2f6a f1 pop af
2f6b 2000 jr nz,#2f6d ; (0)
2f6d f3 di
2f6e 03 inc bc
2f6f ff rst #38
2f70 0b dec bc
2f71 08 ex af,af'
2f72 02 ld (bc),a
2f73 0d dec c
2f74 06fe ld b,#fe
2f76 0b dec bc
2f77 08 ex af,af'
2f78 02 ld (bc),a
2f79 0d dec c
2f7a 03 inc bc
2f7b ff rst #38
2f7c f1 pop af
2f7d 01000a ld bc,#0a00
2f80 1c inc e
2f81 00 nop
2f82 0a ld a,(bc)
2f83 0100f2 ld bc,#f200
2f86 01000a ld bc,#0a00
2f89 04 inc b
2f8a ff rst #38
2f8b 0e02 ld c,#02
2f8d 02 ld (bc),a
2f8e 0c inc c
2f8f 0c inc c
2f90 fe0e cp #0e
2f92 02 ld (bc),a
2f93 02 ld (bc),a
2f94 0c inc c
2f95 04 inc b
2f96 ff rst #38
2f97 0a ld a,(bc)
2f98 0100f2 ld bc,#f200
2f9b 01000a ld bc,#0a00
2f9e 03 inc bc
2f9f 010d04 ld bc,#040d
2fa2 fe0b cp #0b
2fa4 0a ld a,(bc)
2fa5 02 ld (bc),a
2fa6 0d dec c
2fa7 04 inc b
2fa8 fe0b cp #0b
2faa 03 inc bc
2fab 010a01 ld bc,#010a
2fae 00 nop
2faf f1 pop af
2fb0 01000a ld bc,#0a00
2fb3 1c inc e
2fb4 00 nop
2fb5 0a ld a,(bc)
2fb6 0100f2 ld bc,#f200
2fb9 01010c ld bc,#0c01
2fbc 1c inc e
2fbd fe0e cp #0e
2fbf 0101f2 ld bc,#f201
2fc2 03 inc bc
2fc3 010c0a ld bc,#0a0c
2fc6 fe0e cp #0e
2fc8 02 ld (bc),a
2fc9 02 ld (bc),a
2fca 0c inc c
2fcb 0a ld a,(bc)
2fcc fe0e cp #0e
2fce 03 inc bc
2fcf 01f204 ld bc,#04f2
2fd2 ff rst #38
2fd3 0b dec bc
2fd4 08 ex af,af'
2fd5 02 ld (bc),a
2fd6 0d dec c
2fd7 04 inc b
2fd8 fe0b cp #0b
2fda 08 ex af,af'
2fdb 02 ld (bc),a
2fdc 0d dec c
2fdd 04 inc b
2fde ff rst #38
2fdf f202ff jp p,#ff02
2fe2 0b dec bc
2fe3 1a ld a,(de)
2fe4 02 ld (bc),a
2fe5 0d dec c
2fe6 02 ld (bc),a
2fe7 ff rst #38
2fe8 f1 pop af
2fe9 01000a ld bc,#0a00
2fec 1c inc e
2fed 00 nop
2fee 0a ld a,(bc)
2fef 0100f2 ld bc,#f200
2ff2 01000a ld bc,#0a00
2ff5 04 inc b
2ff6 ff rst #38
2ff7 0e02 ld c,#02
2ff9 02 ld (bc),a
2ffa 0c inc c
2ffb 0c inc c
2ffc fe0e cp #0e
2ffe 02 ld (bc),a
2fff 02 ld (bc),a
3000 0c inc c
3001 04 inc b
3002 ff rst #38
3003 0a ld a,(bc)
3004 0100f2 ld bc,#f200
3007 01000a ld bc,#0a00
300a 03 inc bc
300b 010d04 ld bc,#040d
300e fe0b cp #0b
3010 0a ld a,(bc)
3011 02 ld (bc),a
3012 0d dec c
3013 04 inc b
3014 fe0b cp #0b
3016 03 inc bc
3017 010a01 ld bc,#010a
301a 00 nop
301b f1 pop af
301c 01000a ld bc,#0a00
301f 1c inc e
3020 00 nop
3021 0a ld a,(bc)
3022 0100f3 ld bc,#f300
3025 01010c ld bc,#0c01
3028 0c inc c
3029 fe0e cp #0e
302b 02 ld (bc),a
302c 02 ld (bc),a
302d 0c inc c
302e 0c inc c
302f fe0e cp #0e
3031 0101f1 ld bc,#f101
3034 2000 jr nz,#3036 ; (0)
3036 ff rst #38
3037 f1 pop af
3038 2000 jr nz,#303a ; (0)
303a f3 di
303b 05 dec b
303c ff rst #38
303d 0b dec bc
303e 01020d ld bc,#0d02
3041 06fe ld b,#fe
3043 0b dec bc
3044 02 ld (bc),a
3045 02 ld (bc),a
3046 0d dec c
3047 06fe ld b,#fe
3049 0b dec bc
304a 01020d ld bc,#0d02
304d 05 dec b
304e ff rst #38
304f f1 pop af
3050 02 ld (bc),a
3051 00 nop
3052 0b dec bc
3053 1a ld a,(de)
3054 00 nop
3055 0d dec c
3056 02 ld (bc),a
3057 00 nop
3058 f3 di
3059 01010c ld bc,#0c01
305c 1c inc e
305d fe0e cp #0e
305f 0101fc ld bc,#fc01
3062 04 inc b
3063 00 nop
3064 0a ld a,(bc)
3065 1600 ld d,#00
3067 0a ld a,(bc)
3068 04 inc b
3069 00 nop
306a f3 di
306b 03 inc bc
306c ff rst #38
306d 0b dec bc
306e 1802 jr #3072 ; (2)
3070 0d dec c
3071 03 inc bc
3072 ff rst #38
3073 f1 pop af
3074 02 ld (bc),a
3075 00 nop
3076 0c inc c
3077 1a ld a,(de)
3078 00 nop
3079 0e02 ld c,#02
307b 00 nop
307c f3 di
307d 03 inc bc
307e 010c05 ld bc,#050c
3081 fe0e cp #0e
3083 02 ld (bc),a
3084 02 ld (bc),a
3085 0c inc c
3086 06fe ld b,#fe
3088 0e02 ld c,#02
308a 02 ld (bc),a
308b 0c inc c
308c 05 dec b
308d fe0e cp #0e
308f 03 inc bc
3090 01f120 ld bc,#20f1
3093 00 nop
3094 ff rst #38
3095 f1 pop af
3096 2000 jr nz,#3098 ; (0)
3098 fb ei
3099 0b dec bc
309a ff rst #38
309b 0b dec bc
309c 08 ex af,af'
309d 02 ld (bc),a
309e 0d dec c
309f 0b dec bc
30a0 ff rst #38
30a1 f40100 call p,#0001
30a4 0a ld a,(bc)
30a5 1c inc e
30a6 00 nop
30a7 0a ld a,(bc)
30a8 0100fb ld bc,#fb00
30ab 01010c ld bc,#0c01
30ae 1c inc e
30af fe0e cp #0e
30b1 0101f1 ld bc,#f101
30b4 2000 jr nz,#30b6 ; (0)
30b6 ff rst #38
30b7 3e0e ld a,#0e
30b9 32c740 ld (#40c7),a
30bc 32d740 ld (#40d7),a
30bf 32af41 ld (#41af),a
30c2 328742 ld (#4287),a
30c5 329742 ld (#4297),a
30c8 322f43 ld (#432f),a
30cb 3e0c ld a,#0c
30cd 32c840 ld (#40c8),a
30d0 32d840 ld (#40d8),a
30d3 32b041 ld (#41b0),a
30d6 328842 ld (#4288),a
30d9 329842 ld (#4298),a
30dc 323043 ld (#4330),a
30df 3e0d ld a,#0d
30e1 32cf40 ld (#40cf),a
30e4 326741 ld (#4167),a
30e7 327741 ld (#4177),a
30ea 324f42 ld (#424f),a
30ed 322743 ld (#4327),a
30f0 323743 ld (#4337),a
30f3 3e0b ld a,#0b
30f5 32d040 ld (#40d0),a
30f8 326841 ld (#4168),a
30fb 327841 ld (#4178),a
30fe 325042 ld (#4250),a
3101 322843 ld (#4328),a
3104 323843 ld (#4338),a
3107 3e0a ld a,#0a
3109 32fb41 ld (#41fb),a
310c 321b42 ld (#421b),a
310f c9 ret
3110 3e0e ld a,#0e
3112 32af41 ld (#41af),a
3115 3e0c ld a,#0c
3117 32b041 ld (#41b0),a
311a 3e0d ld a,#0d
311c 324f42 ld (#424f),a
311f 3e0b ld a,#0b
3121 325042 ld (#4250),a
3124 3e0c ld a,#0c
3126 32e142 ld (#42e1),a
3129 3e0b ld a,#0b
312b 320141 ld (#4101),a
312e 3e0d ld a,#0d
3130 321e41 ld (#411e),a
3133 3e0e ld a,#0e
3135 32fe42 ld (#42fe),a
3138 c9 ret
3139 3e0d ld a,#0d
313b 32e840 ld (#40e8),a
313e 32f640 ld (#40f6),a
3141 326f42 ld (#426f),a
3144 3e0b ld a,#0b
3146 32e940 ld (#40e9),a
3149 32f740 ld (#40f7),a
314c 327042 ld (#4270),a
314f 3e0e ld a,#0e
3151 328f41 ld (#418f),a
3154 320843 ld (#4308),a
3157 321643 ld (#4316),a
315a 3e0c ld a,#0c
315c 329041 ld (#4190),a
315f 320943 ld (#4309),a
3162 321743 ld (#4317),a
3165 3e0c ld a,#0c
3167 328143 ld (#4381),a
316a 32c140 ld (#40c1),a
316d 3e0b ld a,#0b
316f 322143 ld (#4321),a
3172 326140 ld (#4061),a
3175 3e0e ld a,#0e
3177 329e43 ld (#439e),a
317a 32de40 ld (#40de),a
317d 3e0d ld a,#0d
317f 323e43 ld (#433e),a
3182 327e40 ld (#407e),a
3185 c9 ret
3186 3e0a ld a,#0a
3188 322541 ld (#4125),a
318b 32e740 ld (#40e7),a
318e 32c542 ld (#42c5),a
3191 320743 ld (#4307),a
3194 c9 ret
3195 3e0d ld a,#0d
3197 32ca40 ld (#40ca),a
319a 32d440 ld (#40d4),a
319d 3e0b ld a,#0b
319f 32cb40 ld (#40cb),a
31a2 32d540 ld (#40d5),a
31a5 3e0e ld a,#0e
31a7 322a43 ld (#432a),a
31aa 323443 ld (#4334),a
31ad 3e0c ld a,#0c
31af 322b43 ld (#432b),a
31b2 323543 ld (#4335),a
31b5 c9 ret
31b6 3e0d ld a,#0d
31b8 32ef40 ld (#40ef),a
31bb 3e0b ld a,#0b
31bd 32f040 ld (#40f0),a
31c0 320542 ld (#4205),a
31c3 3e0c ld a,#0c
31c5 32e541 ld (#41e5),a
31c8 321043 ld (#4310),a
31cb 3e0e ld a,#0e
31cd 320f43 ld (#430f),a
31d0 c9 ret
31d1 3e16 ld a,#16
31d3 cdfd14 call #14fd
31d6 3e09 ld a,#09
31d8 cd0d15 call #150d
31db 11c144 ld de,#44c1
31de 210334 ld hl,#3403
31e1 3e05 ld a,#05
31e3 0615 ld b,#15
31e5 cdeb15 call #15eb
31e8 117b44 ld de,#447b
31eb 210334 ld hl,#3403
31ee 3e05 ld a,#05
31f0 0610 ld b,#10
31f2 cdeb15 call #15eb
31f5 11c140 ld de,#40c1
31f8 213932 ld hl,#3239
31fb 3e05 ld a,#05
31fd 0615 ld b,#15
31ff cdd515 call #15d5 ; DRAW TEXT
3202 114941 ld de,#4149
3205 21a232 ld hl,#32a2
3208 3e07 ld a,#07
320a 0611 ld b,#11
320c cdd515 call #15d5 ; DRAW TEXT
320f 3e90 ld a,#90
3211 32ee40 ld (#40ee),a
3214 3e8e ld a,#8e
3216 32ef40 ld (#40ef),a
3219 11b240 ld de,#40b2
321c 211933 ld hl,#3319
321f 3e07 ld a,#07
3221 0616 ld b,#16
3223 cdd515 call #15d5 ; DRAW TEXT
3226 117b40 ld de,#407b
3229 21b333 ld hl,#33b3
322c 3e05 ld a,#05
322e 0610 ld b,#10
3230 cdd515 call #15d5 ; DRAW TEXT
3233 3e78 ld a,#78
3235 cd9b15 call #159b
3238 c9 ret
3239 19 add hl,de
323a 19 add hl,de
323b 19 add hl,de
323c 19 add hl,de
323d 19 add hl,de
323e 19 add hl,de
323f 40 ld b,b
3240 40 ld b,b
3241 40 ld b,b
3242 19 add hl,de
3243 19 add hl,de
3244 40 ld b,b
3245 53 ld d,e
3246 40 ld b,b
3247 19 add hl,de
3248 19 add hl,de
3249 40 ld b,b
324a 54 ld d,h
324b 40 ld b,b
324c 19 add hl,de
324d 19 add hl,de
324e 40 ld b,b
324f 4e ld c,(hl)
3250 40 ld b,b
3251 19 add hl,de
3252 19 add hl,de
3253 40 ld b,b
3254 45 ld b,l
3255 40 ld b,b
3256 19 add hl,de
3257 19 add hl,de
3258 40 ld b,b
3259 53 ld d,e
325a 40 ld b,b
325b 19 add hl,de
325c 19 add hl,de
325d 40 ld b,b
325e 45 ld b,l
325f 40 ld b,b
3260 19 add hl,de
3261 19 add hl,de
3262 40 ld b,b
3263 52 ld d,d
3264 40 ld b,b
3265 19 add hl,de
3266 19 add hl,de
3267 40 ld b,b
3268 50 ld d,b
3269 40 ld b,b
326a 19 add hl,de
326b 19 add hl,de
326c 40 ld b,b
326d 40 ld b,b
326e 40 ld b,b
326f 19 add hl,de
3270 19 add hl,de
3271 40 ld b,b
3272 40 ld b,b
3273 40 ld b,b
3274 19 add hl,de
3275 19 add hl,de
3276 40 ld b,b
3277 5a ld e,d
3278 40 ld b,b
3279 19 add hl,de
327a 19 add hl,de
327b 40 ld b,b
327c 45 ld b,l
327d 40 ld b,b
327e 19 add hl,de
327f 19 add hl,de
3280 40 ld b,b
3281 48 ld c,b
3282 40 ld b,b
3283 19 add hl,de
3284 19 add hl,de
3285 40 ld b,b
3286 43 ld b,e
3287 40 ld b,b
3288 19 add hl,de
3289 19 add hl,de
328a 40 ld b,b
328b 4e ld c,(hl)
328c 40 ld b,b
328d 19 add hl,de
328e 19 add hl,de
328f 40 ld b,b
3290 41 ld b,c
3291 40 ld b,b
3292 19 add hl,de
3293 19 add hl,de
3294 40 ld b,b
3295 53 ld d,e
3296 40 ld b,b
3297 19 add hl,de
3298 19 add hl,de
3299 40 ld b,b
329a 40 ld b,b
329b 40 ld b,b
329c 19 add hl,de
329d 19 add hl,de
329e 19 add hl,de
329f 19 add hl,de
32a0 19 add hl,de
32a1 19 add hl,de
32a2 1616 ld d,#16
32a4 8d adc a,l
32a5 168a ld d,#8a
32a7 8b adc a,e
32a8 8e adc a,(hl)
32a9 8b adc a,e
32aa 8b adc a,e
32ab 8f adc a,a
32ac 8c adc a,h
32ad 8b adc a,e
32ae 8f adc a,a
32af 8e adc a,(hl)
32b0 8f adc a,a
32b1 1616 ld d,#16
32b3 8f adc a,a
32b4 168f ld d,#8f
32b6 8e adc a,(hl)
32b7 8f adc a,a
32b8 1616 ld d,#16
32ba 8f adc a,a
32bb 1616 ld d,#16
32bd 168f ld d,#8f
32bf 8d adc a,l
32c0 8d adc a,l
32c1 8f adc a,a
32c2 8d adc a,l
32c3 8d adc a,l
32c4 168f ld d,#8f
32c6 8f adc a,a
32c7 8f adc a,a
32c8 8f adc a,a
32c9 8f adc a,a
32ca 8f adc a,a
32cb 8e adc a,(hl)
32cc 8f adc a,a
32cd 1616 ld d,#16
32cf 1616 ld d,#16
32d1 8f adc a,a
32d2 8e adc a,(hl)
32d3 1616 ld d,#16
32d5 1616 ld d,#16
32d7 168f ld d,#8f
32d9 8e adc a,(hl)
32da 1616 ld d,#16
32dc 1616 ld d,#16
32de 1616 ld d,#16
32e0 168d ld d,#8d
32e2 168d ld d,#8d
32e4 8d adc a,l
32e5 8d adc a,l
32e6 8d adc a,l
32e7 168f ld d,#8f
32e9 8b adc a,e
32ea 8f adc a,a
32eb 8f adc a,a
32ec 8f adc a,a
32ed 8f adc a,a
32ee 8e adc a,(hl)
32ef 8f adc a,a
32f0 8c adc a,h
32f1 1616 ld d,#16
32f3 168f ld d,#8f
32f5 8e adc a,(hl)
32f6 1690 ld d,#90
32f8 8c adc a,h
32f9 1616 ld d,#16
32fb 1616 ld d,#16
32fd 168b ld d,#8b
32ff 91 sub c
3300 1616 ld d,#16
3302 1616 ld d,#16
3304 8f adc a,a
3305 91 sub c
3306 168d ld d,#8d
3308 8d adc a,l
3309 8d adc a,l
330a 168f ld d,#8f
330c 90 sub b
330d 8f adc a,a
330e 8f adc a,a
330f 8f adc a,a
3310 8f adc a,a
3311 8e adc a,(hl)
3312 1616 ld d,#16
3314 1616 ld d,#16
3316 168f ld d,#8f
3318 8e adc a,(hl)
3319 8d adc a,l
331a 8d adc a,l
331b 1616 ld d,#16
331d 1616 ld d,#16
331f 168f ld d,#8f
3321 91 sub c
3322 1616 ld d,#16
3324 1616 ld d,#16
3326 168f ld d,#8f
3328 8e adc a,(hl)
3329 168d ld d,#8d
332b 8d adc a,l
332c 8d adc a,l
332d 168f ld d,#8f
332f 8f adc a,a
3330 8f adc a,a
3331 8f adc a,a
3332 8f adc a,a
3333 8f adc a,a
3334 8e adc a,(hl)
3335 8f adc a,a
3336 8e adc a,(hl)
3337 1616 ld d,#16
3339 1616 ld d,#16
333b 168f ld d,#8f
333d 8c adc a,h
333e 1616 ld d,#16
3340 1616 ld d,#16
3342 1616 ld d,#16
3344 1616 ld d,#16
3346 1616 ld d,#16
3348 1616 ld d,#16
334a 1616 ld d,#16
334c 8d adc a,l
334d 8d adc a,l
334e 8d adc a,l
334f 8d adc a,l
3350 168f ld d,#8f
3352 90 sub b
3353 8f adc a,a
3354 8f adc a,a
3355 8f adc a,a
3356 8f adc a,a
3357 8e adc a,(hl)
3358 8f adc a,a
3359 1616 ld d,#16
335b 8b adc a,e
335c 91 sub c
335d 1616 ld d,#16
335f 1616 ld d,#16
3361 8b adc a,e
3362 91 sub c
3363 8a adc a,d
3364 1616 ld d,#16
3366 168b ld d,#8b
3368 91 sub c
3369 8a adc a,d
336a 1616 ld d,#16
336c 168f ld d,#8f
336e 91 sub c
336f 168d ld d,#8d
3371 8d adc a,l
3372 8d adc a,l
3373 168f ld d,#8f
3375 90 sub b
3376 8f adc a,a
3377 8f adc a,a
3378 8f adc a,a
3379 8f adc a,a
337a 8e adc a,(hl)
337b 1616 ld d,#16
337d 1616 ld d,#16
337f 168f ld d,#8f
3381 8e adc a,(hl)
3382 1616 ld d,#16
3384 1616 ld d,#16
3386 1616 ld d,#16
3388 168d ld d,#8d
338a 8d adc a,l
338b 1616 ld d,#16
338d 1616 ld d,#16
338f 168f ld d,#8f
3391 91 sub c
3392 1616 ld d,#16
3394 1616 ld d,#16
3396 168f ld d,#8f
3398 8e adc a,(hl)
3399 168d ld d,#8d
339b 8d adc a,l
339c 8d adc a,l
339d 168f ld d,#8f
339f 8f adc a,a
33a0 8f adc a,a
33a1 8f adc a,a
33a2 8f adc a,a
33a3 8f adc a,a
33a4 8e adc a,(hl)
33a5 8f adc a,a
33a6 8e adc a,(hl)
33a7 1616 ld d,#16
33a9 1616 ld d,#16
33ab 168f ld d,#8f
33ad 8c adc a,h
33ae 1616 ld d,#16
33b0 1616 ld d,#16
33b2 1619 ld d,#19
33b4 19 add hl,de
33b5 19 add hl,de
33b6 19 add hl,de
33b7 19 add hl,de
33b8 19 add hl,de
33b9 40 ld b,b
33ba 40 ld b,b
33bb 40 ld b,b
33bc 19 add hl,de
33bd 19 add hl,de
33be 40 ld b,b
33bf 4f ld c,a
33c0 40 ld b,b
33c1 19 add hl,de
33c2 19 add hl,de
33c3 40 ld b,b
33c4 4b ld c,e
33c5 40 ld b,b
33c6 19 add hl,de
33c7 19 add hl,de
33c8 40 ld b,b
33c9 4c ld c,h
33ca 40 ld b,b
33cb 19 add hl,de
33cc 19 add hl,de
33cd 40 ld b,b
33ce 45 ld b,l
33cf 40 ld b,b
33d0 19 add hl,de
33d1 19 add hl,de
33d2 40 ld b,b
33d3 54 ld d,h
33d4 40 ld b,b
33d5 19 add hl,de
33d6 19 add hl,de
33d7 40 ld b,b
33d8 40 ld b,b
33d9 40 ld b,b
33da 19 add hl,de
33db 19 add hl,de
33dc 40 ld b,b
33dd 03 inc bc
33de 40 ld b,b
33df 19 add hl,de
33e0 19 add hl,de
33e1 40 ld b,b
33e2 08 ex af,af'
33e3 40 ld b,b
33e4 19 add hl,de
33e5 19 add hl,de
33e6 40 ld b,b
33e7 09 add hl,bc
33e8 40 ld b,b
33e9 19 add hl,de
33ea 19 add hl,de
33eb 40 ld b,b
33ec 014019 ld bc,#1940
33ef 19 add hl,de
33f0 40 ld b,b
33f1 40 ld b,b
33f2 40 ld b,b
33f3 19 add hl,de
33f4 19 add hl,de
33f5 40 ld b,b
33f6 1a ld a,(de)
33f7 40 ld b,b
33f8 19 add hl,de
33f9 19 add hl,de
33fa 40 ld b,b
33fb 40 ld b,b
33fc 40 ld b,b
33fd 19 add hl,de
33fe 19 add hl,de
33ff 19 add hl,de
3400 19 add hl,de
3401 19 add hl,de
3402 19 add hl,de
3403 05 dec b
3404 c9 ret
3405 c9 ret
3406 c9 ret
3407 21e434 ld hl,#34e4
340a 222d4e ld (#4e2d),hl
340d 3eef ld a,#ef
340f 32f84c ld (#4cf8),a
3412 c9 ret
3413 c9 ret
3414 2a2d4e ld hl,(#4e2d)
3417 e5 push hl
3418 21e434 ld hl,#34e4
341b 7d ld a,l
341c e1 pop hl
341d bd cp l
341e cc4c34 call z,#344c
3421 7e ld a,(hl)
3422 fe00 cp #00
3424 280e jr z,#3434 ; (14)
3426 23 inc hl
3427 46 ld b,(hl)
3428 3a8c4c ld a,(#4c8c)
342b b8 cp b
342c 2814 jr z,#3442 ; (20)
342e 2b dec hl
342f 222d4e ld (#4e2d),hl
3432 1817 jr #344b ; (23)
3434 23 inc hl
3435 46 ld b,(hl)
3436 3a8d4c ld a,(#4c8d)
3439 b8 cp b
343a 2806 jr z,#3442 ; (6)
343c 2b dec hl
343d 222d4e ld (#4e2d),hl
3440 1809 jr #344b ; (9)
3442 23 inc hl
3443 7e ld a,(hl)
3444 32f84c ld (#4cf8),a
3447 23 inc hl
3448 222d4e ld (#4e2d),hl
344b c9 ret
344c 3e10 ld a,#10
344e 32294e ld (#4e29),a
3451 3e04 ld a,#04
3453 32134e ld (#4e13),a
3456 3e0a ld a,#0a
3458 32144e ld (#4e14),a
345b 3e07 ld a,#07
345d 32624c ld (#4c62),a
3460 326a4c ld (#4c6a),a
3463 32724c ld (#4c72),a
3466 327a4c ld (#4c7a),a
3469 c9 ret
346a c9 ret
346b c9 ret
346c c9 ret
346d c9 ret
346e c9 ret
346f c9 ret
3470 c9 ret
3471 c9 ret
3472 3e40 ld a,#40
3474 cdfd14 call #14fd
3477 3e09 ld a,#09
3479 cd0d15 call #150d
347c 3e19 ld a,#19
347e 321c4e ld (#4e1c),a
3481 cd9234 call #3492
3484 3e0f ld a,#0f
3486 cd9b15 call #159b
3489 3e14 ld a,#14
348b 321c4e ld (#4e1c),a
348e cd9234 call #3492
3491 c9 ret
3492 214040 ld hl,#4040
3495 221d4e ld (#4e1d),hl
3498 217f40 ld hl,#407f
349b 221f4e ld (#4e1f),hl
349e 3e20 ld a,#20
34a0 32214e ld (#4e21),a
34a3 cdb534 call #34b5
34a6 3e01 ld a,#01
34a8 cd9b15 call #159b
34ab 3a214e ld a,(#4e21)
34ae 3d dec a
34af 32214e ld (#4e21),a
34b2 20ef jr nz,#34a3 ; (-17)
34b4 c9 ret
34b5 060e ld b,#0e
34b7 ed5b1d4e ld de,(#4e1d)
34bb 13 inc de
34bc ed531d4e ld (#4e1d),de
34c0 1b dec de
34c1 3a1c4e ld a,(#4e1c)
34c4 12 ld (de),a
34c5 3e40 ld a,#40
34c7 cdb515 call #15b5
34ca 10f5 djnz #34c1 ; (-11)
34cc 060e ld b,#0e
34ce ed5b1f4e ld de,(#4e1f)
34d2 1b dec de
34d3 ed531f4e ld (#4e1f),de
34d7 13 inc de
34d8 3a1c4e ld a,(#4e1c)
34db 12 ld (de),a
34dc 3e40 ld a,#40
34de cdb515 call #15b5
34e1 10f5 djnz #34d8 ; (-11)
34e3 c9 ret
34e4 00 nop
34e5 e4fb01 call po,#01fb
34e8 9b sbc a,e
34e9 f7 rst #30
34ea 00 nop
34eb ecfb01 call pe,#01fb
34ee e3 ex (sp),hl
34ef fe00 cp #00
34f1 9c sbc a,h
34f2 fd01cbfe ld bc,#fecb
34f6 00 nop
34f7 64 ld h,h
34f8 fb ei
34f9 01e3fe ld bc,#fee3
34fc 00 nop
34fd 24 inc h
34fe fd019bf7 ld bc,#f79b
3502 00 nop
3503 84 add a,h
3504 fb ei
3505 01d3fe ld bc,#fed3
3508 00 nop
3509 5c ld e,h
350a fd01c3f7 ld bc,#f7c3
350e 00 nop
350f b4 or h
3510 fb ei
3511 01ebf7 ld bc,#f7eb
3514 00 nop
3515 ecfd01 call pe,#01fd
3518 e3 ex (sp),hl
3519 f7 rst #30
351a 00 nop
351b f4fd01 call p,#01fd
351e 9b sbc a,e
351f fe00 cp #00
3521 ecfd01 call pe,#01fd
3524 93 sub e
3525 fe00 cp #00
3527 a4 and h
3528 fd0123f7 ld bc,#f723
352c 00 nop
352d ecfb01 call pe,#01fb
3530 73 ld (hl),e
3531 fe00 cp #00
3533 8c adc a,h
3534 fd0143fe ld bc,#fe43
3538 00 nop
3539 64 ld h,h
353a fd012bfe ld bc,#fe2b
353e 00 nop
353f 1c inc e
3540 fb ei
3541 0173f7 ld bc,#f773
3544 00 nop
3545 5c ld e,h
3546 fb ei
3547 01bbf7 ld bc,#f7bb
354a 00 nop
354b 8c adc a,h
354c fb ei
354d 01d3f7 ld bc,#f7d3
3550 00 nop
3551 c4fb01 call nz,#01fb
3554 dbf7 in a,(#f7)
3556 00 nop
3557 fcfd01 call m,#01fd
355a ab xor e
355b fe00 cp #00
355d ccfd01 call z,#01fd
3560 7b ld a,e
3561 f7 rst #30
3562 00 nop
3563 ecfd01 call pe,#01fd
3566 73 ld (hl),e
3567 f7 rst #30
3568 00 nop
3569 f4fd01 call p,#01fd
356c 2b dec hl
356d fe00 cp #00
356f 9c sbc a,h
3570 fb ei
3571 0183f7 ld bc,#f783
3574 0b dec bc
3575 204d jr nz,#35c4 ; (77)
3577 0b dec bc
3578 3b dec sp
3579 4d ld c,l
357a 0c inc c
357b 02 ld (bc),a
357c 014300 ld bc,#0043
357f 02 ld (bc),a
3580 08 ex af,af'
3581 05 dec b
3582 04 inc b
3583 015400 ld bc,#0054
3586 05 dec b
3587 04 inc b
3588 013200 ld bc,#0032
358b 05 dec b
358c 04 inc b
358d 018500 ld bc,#0085
3590 05 dec b
3591 04 inc b
3592 01a700 ld bc,#00a7
3595 05 dec b
3596 04 inc b
3597 016400 ld bc,#0064
359a 05 dec b
359b 04 inc b
359c 010b01 ld bc,#010b
359f 05 dec b
35a0 04 inc b
35a1 09 add hl,bc
35a2 0b dec bc
35a3 05 dec b
35a4 4d ld c,l
35a5 0b dec bc
35a6 3b dec sp
35a7 4d ld c,l
35a8 01f000 ld bc,#00f0
35ab 0c inc c
35ac 02 ld (bc),a
35ad 0602 ld b,#02
35af 08 ex af,af'
35b0 05 dec b
35b1 03 inc bc
35b2 02 ld (bc),a
35b3 00 nop
35b4 05 dec b
35b5 03 inc bc
35b6 07 rlca
35b7 0f rrca
35b8 09 add hl,bc
35b9 0b dec bc
35ba 05 dec b
35bb 4d ld c,l
35bc 0c inc c
35bd 02 ld (bc),a
35be 010002 ld bc,#0200
35c1 02 ld (bc),a
35c2 05 dec b
35c3 0604 ld b,#04
35c5 05 dec b
35c6 0605 ld b,#05
35c8 0104ff ld bc,#ff04
35cb 07 rlca
35cc 0607 ld b,#07
35ce 04 inc b
35cf 09 add hl,bc
35d0 ae xor (hl)
35d1 4c ld c,h
35d2 f8 ret m
35d3 2e46 ld l,#46
35d5 53 ld d,e
35d6 43 ld b,e
35d7 4f ld c,a
35d8 52 ld d,d
35d9 45 ld b,l
35da 2020 jr nz,#35fc ; (32)
35dc 05 dec b
35dd 00 nop
35de 95 sub l
35df 2b dec hl
35e0 a8 xor b
35e1 2b dec hl
35e2 b0 or b
35e3 4c ld c,h
35e4 f23446 jp p,#4634
35e7 4d ld c,l
35e8 45 ld b,l
35e9 4e ld c,(hl)
35ea 52 ld d,d
35eb 0b dec bc
35ec 3b dec sp
35ed 4d ld c,l
35ee 0b dec bc
35ef 71 ld (hl),c
35f0 4d ld c,l
35f1 0b dec bc
35f2 8c adc a,h
35f3 4d ld c,l
35f4 0b dec bc
35f5 a7 and a
35f6 4d ld c,l
35f7 0c inc c
35f8 02 ld (bc),a
35f9 012000 ld bc,#0020
35fc 02 ld (bc),a
35fd 0f rrca
35fe 0605 ld b,#05
3600 010330 ld bc,#3003
3603 00 nop
3604 07 rlca
3605 14 inc d
3606 0604 ld b,#04
3608 ff rst #38
3609 05 dec b
360a 04 inc b
360b 07 rlca
360c 07 rlca
360d 01b100 ld bc,#00b1
3610 02 ld (bc),a
3611 0e06 ld c,#06
3613 04 inc b
3614 fe05 cp #05
3616 02 ld (bc),a
3617 07 rlca
3618 04 inc b
3619 05 dec b
361a 04 inc b
361b 018500 ld bc,#0085
361e 02 ld (bc),a
361f 0e06 ld c,#06
3621 04 inc b
3622 fe05 cp #05
3624 02 ld (bc),a
3625 07 rlca
3626 04 inc b
3627 05 dec b
3628 04 inc b
3629 017d00 ld bc,#007d
362c 02 ld (bc),a
362d 0e06 ld c,#06
362f 04 inc b
3630 fe05 cp #05
3632 02 ld (bc),a
3633 07 rlca
3634 04 inc b
3635 05 dec b
3636 04 inc b
3637 017600 ld bc,#0076
363a 02 ld (bc),a
363b 0e06 ld c,#06
363d 04 inc b
363e fe05 cp #05
3640 02 ld (bc),a
3641 07 rlca
3642 02 ld (bc),a
3643 05 dec b
3644 010169 ld bc,#6901
3647 00 nop
3648 02 ld (bc),a
3649 0e06 ld c,#06
364b 04 inc b
364c fe05 cp #05
364e 02 ld (bc),a
364f 07 rlca
3650 04 inc b
3651 05 dec b
3652 02 ld (bc),a
3653 015800 ld bc,#0058
3656 02 ld (bc),a
3657 0e06 ld c,#06
3659 04 inc b
365a fe05 cp #05
365c 02 ld (bc),a
365d 07 rlca
365e 02 ld (bc),a
365f 05 dec b
3660 010169 ld bc,#6901
3663 00 nop
3664 02 ld (bc),a
3665 0e06 ld c,#06
3667 04 inc b
3668 fe05 cp #05
366a 02 ld (bc),a
366b 07 rlca
366c 02 ld (bc),a
366d 05 dec b
366e 02 ld (bc),a
366f 016400 ld bc,#0064
3672 02 ld (bc),a
3673 0e06 ld c,#06
3675 04 inc b
3676 fe05 cp #05
3678 02 ld (bc),a
3679 07 rlca
367a 02 ld (bc),a
367b 05 dec b
367c 010169 ld bc,#6901
367f 00 nop
3680 02 ld (bc),a
3681 0e06 ld c,#06
3683 04 inc b
3684 fe05 cp #05
3686 02 ld (bc),a
3687 07 rlca
3688 02 ld (bc),a
3689 05 dec b
368a 02 ld (bc),a
368b 015800 ld bc,#0058
368e 02 ld (bc),a
368f 0e06 ld c,#06
3691 04 inc b
3692 fe05 cp #05
3694 02 ld (bc),a
3695 07 rlca
3696 0609 ld b,#09
3698 0c inc c
3699 010201 ld bc,#0102
369c 0601 ld b,#01
369e 80 add a,b
369f 00 nop
36a0 0605 ld b,#05
36a2 02 ld (bc),a
36a3 03 inc bc
36a4 1000 djnz #36a6 ; (0)
36a6 07 rlca
36a7 05 dec b
36a8 04 inc b
36a9 02 ld (bc),a
36aa 07 rlca
36ab 0608 ld b,#08
36ad 98 sbc a,b
36ae 3652 ld (hl),#52
36b0 41 ld b,c
36b1 4d ld c,l
36b2 35 dec (hl)
36b3 2005 jr nz,#36ba ; (5)
36b5 00 nop
36b6 95 sub l
36b7 2b dec hl
36b8 a8 xor b
36b9 2b dec hl
36ba a7 and a
36bb 4d ld c,l
36bc c636 add a,#36
36be 53 ld d,e
36bf 4f ld c,a
36c0 55 ld d,l
36c1 52 ld d,d
36c2 41 ld b,c
36c3 4d ld c,l
36c4 3620 ld (hl),#20
36c6 05 dec b
36c7 00 nop
36c8 95 sub l
36c9 2b dec hl
36ca 0c inc c
36cb 02 ld (bc),a
36cc 01b100 ld bc,#00b1
36cf 02 ld (bc),a
36d0 0e06 ld c,#06
36d2 04 inc b
36d3 fe05 cp #05
36d5 02 ld (bc),a
36d6 07 rlca
36d7 02 ld (bc),a
36d8 05 dec b
36d9 02 ld (bc),a
36da 01b100 ld bc,#00b1
36dd 02 ld (bc),a
36de 0e06 ld c,#06
36e0 04 inc b
36e1 fe05 cp #05
36e3 02 ld (bc),a
36e4 07 rlca
36e5 02 ld (bc),a
36e6 05 dec b
36e7 0101b1 ld bc,#b101
36ea 00 nop
36eb 02 ld (bc),a
36ec 0e06 ld c,#06
36ee 04 inc b
36ef fe05 cp #05
36f1 02 ld (bc),a
36f2 07 rlca
36f3 02 ld (bc),a
36f4 05 dec b
36f5 0101b1 ld bc,#b101
36f8 00 nop
36f9 02 ld (bc),a
36fa 0e06 ld c,#06
36fc 04 inc b
36fd fe05 cp #05
36ff 02 ld (bc),a
3700 07 rlca
3701 02 ld (bc),a
3702 05 dec b
3703 0101b1 ld bc,#b101
3706 00 nop
3707 02 ld (bc),a
3708 0e06 ld c,#06
370a 04 inc b
370b fe05 cp #05
370d 02 ld (bc),a
370e 07 rlca
370f 02 ld (bc),a
3710 05 dec b
3711 010185 ld bc,#8501
3714 00 nop
3715 02 ld (bc),a
3716 0e06 ld c,#06
3718 04 inc b
3719 fe05 cp #05
371b 02 ld (bc),a
371c 07 rlca
371d 02 ld (bc),a
371e 05 dec b
371f 02 ld (bc),a
3720 01b100 ld bc,#00b1
3723 02 ld (bc),a
3724 0e06 ld c,#06
3726 04 inc b
3727 fe05 cp #05
3729 02 ld (bc),a
372a 07 rlca
372b 02 ld (bc),a
372c 05 dec b
372d 02 ld (bc),a
372e 01e000 ld bc,#00e0
3731 02 ld (bc),a
3732 0e06 ld c,#06
3734 04 inc b
3735 fe05 cp #05
3737 02 ld (bc),a
3738 07 rlca
3739 02 ld (bc),a
373a 05 dec b
373b 02 ld (bc),a
373c 01e000 ld bc,#00e0
373f 02 ld (bc),a
3740 0e06 ld c,#06
3742 04 inc b
3743 fe05 cp #05
3745 02 ld (bc),a
3746 07 rlca
3747 02 ld (bc),a
3748 05 dec b
3749 0101e0 ld bc,#e001
374c 00 nop
374d 02 ld (bc),a
374e 0e06 ld c,#06
3750 04 inc b
3751 fe05 cp #05
3753 02 ld (bc),a
3754 07 rlca
3755 02 ld (bc),a
3756 05 dec b
3757 0101e0 ld bc,#e001
375a 00 nop
375b 02 ld (bc),a
375c 0e06 ld c,#06
375e 04 inc b
375f fe05 cp #05
3761 02 ld (bc),a
3762 07 rlca
3763 02 ld (bc),a
3764 05 dec b
3765 0101e0 ld bc,#e001
3768 00 nop
3769 02 ld (bc),a
376a 0e06 ld c,#06
376c 04 inc b
376d fe05 cp #05
376f 02 ld (bc),a
3770 07 rlca
3771 02 ld (bc),a
3772 05 dec b
3773 0101b1 ld bc,#b101
3776 00 nop
3777 02 ld (bc),a
3778 0e06 ld c,#06
377a 04 inc b
377b fe05 cp #05
377d 02 ld (bc),a
377e 07 rlca
377f 02 ld (bc),a
3780 05 dec b
3781 02 ld (bc),a
3782 01e000 ld bc,#00e0
3785 02 ld (bc),a
3786 0e06 ld c,#06
3788 04 inc b
3789 fe05 cp #05
378b 02 ld (bc),a
378c 07 rlca
378d 02 ld (bc),a
378e 05 dec b
378f 02 ld (bc),a
3790 010b01 ld bc,#010b
3793 02 ld (bc),a
3794 0e06 ld c,#06
3796 04 inc b
3797 fe05 cp #05
3799 02 ld (bc),a
379a 07 rlca
379b 02 ld (bc),a
379c 05 dec b
379d 02 ld (bc),a
379e 010b01 ld bc,#010b
37a1 02 ld (bc),a
37a2 0e06 ld c,#06
37a4 04 inc b
37a5 fe05 cp #05
37a7 02 ld (bc),a
37a8 07 rlca
37a9 02 ld (bc),a
37aa 05 dec b
37ab 01010b ld bc,#0b01
37ae 01020e ld bc,#0e02
37b1 0604 ld b,#04
37b3 fe05 cp #05
37b5 02 ld (bc),a
37b6 07 rlca
37b7 02 ld (bc),a
37b8 05 dec b
37b9 01010b ld bc,#0b01
37bc 01020e ld bc,#0e02
37bf 0604 ld b,#04
37c1 fe05 cp #05
37c3 02 ld (bc),a
37c4 07 rlca
37c5 02 ld (bc),a
37c6 05 dec b
37c7 01010b ld bc,#0b01
37ca 01020e ld bc,#0e02
37cd 0604 ld b,#04
37cf fe05 cp #05
37d1 02 ld (bc),a
37d2 07 rlca
37d3 02 ld (bc),a
37d4 05 dec b
37d5 0101e0 ld bc,#e001
37d8 00 nop
37d9 02 ld (bc),a
37da 0e06 ld c,#06
37dc 04 inc b
37dd fe05 cp #05
37df 02 ld (bc),a
37e0 07 rlca
37e1 02 ld (bc),a
37e2 05 dec b
37e3 02 ld (bc),a
37e4 010b01 ld bc,#010b
37e7 02 ld (bc),a
37e8 0e06 ld c,#06
37ea 04 inc b
37eb fe05 cp #05
37ed 02 ld (bc),a
37ee 07 rlca
37ef 03 inc bc
37f0 016401 ld bc,#0164
37f3 02 ld (bc),a
37f4 0e06 ld c,#06
37f6 04 inc b
37f7 fe05 cp #05
37f9 02 ld (bc),a
37fa 07 rlca
37fb 02 ld (bc),a
37fc 0605 ld b,#05
37fe 07 rlca
37ff 04 inc b
3800 fe07 cp #07
3802 04 inc b
3803 09 add hl,bc
3804 0c inc c
3805 01020f ld bc,#0f02
3808 0601 ld b,#01
380a c0 ret nz
380b 00 nop
380c 0605 ld b,#05
380e 010310 ld bc,#1003
3811 00 nop
3812 07 rlca
3813 05 dec b
3814 04 inc b
3815 fe07 cp #07
3817 0609 ld b,#09
3819 0b dec bc
381a a7 and a
381b 4d ld c,l
381c 0c inc c
381d 02 ld (bc),a
381e 014300 ld bc,#0043
3821 02 ld (bc),a
3822 0e06 ld c,#06
3824 04 inc b
3825 fe05 cp #05
3827 02 ld (bc),a
3828 07 rlca
3829 04 inc b
382a 05 dec b
382b 010158 ld bc,#5801
382e 00 nop
382f 02 ld (bc),a
3830 0e06 ld c,#06
3832 04 inc b
3833 fe05 cp #05
3835 02 ld (bc),a
3836 07 rlca
3837 04 inc b
3838 05 dec b
3839 02 ld (bc),a
383a 017000 ld bc,#0070
383d 02 ld (bc),a
383e 0e06 ld c,#06
3840 04 inc b
3841 fe05 cp #05
3843 02 ld (bc),a
3844 07 rlca
3845 02 ld (bc),a
3846 018500 ld bc,#0085
3849 02 ld (bc),a
384a 0e06 ld c,#06
384c 04 inc b
384d fe05 cp #05
384f 02 ld (bc),a
3850 07 rlca
3851 02 ld (bc),a
3852 05 dec b
3853 010170 ld bc,#7001
3856 00 nop
3857 02 ld (bc),a
3858 0e06 ld c,#06
385a 04 inc b
385b fe05 cp #05
385d 02 ld (bc),a
385e 07 rlca
385f 04 inc b
3860 017600 ld bc,#0076
3863 02 ld (bc),a
3864 0e06 ld c,#06
3866 04 inc b
3867 fe05 cp #05
3869 02 ld (bc),a
386a 07 rlca
386b 04 inc b
386c 05 dec b
386d 02 ld (bc),a
386e 019500 ld bc,#0095
3871 02 ld (bc),a
3872 0e06 ld c,#06
3874 04 inc b
3875 fe05 cp #05
3877 02 ld (bc),a
3878 07 rlca
3879 02 ld (bc),a
387a 01b100 ld bc,#00b1
387d 02 ld (bc),a
387e 0e06 ld c,#06
3880 04 inc b
3881 fe05 cp #05
3883 02 ld (bc),a
3884 07 rlca
3885 02 ld (bc),a
3886 05 dec b
3887 010195 ld bc,#9501
388a 00 nop
388b 02 ld (bc),a
388c 0e06 ld c,#06
388e 04 inc b
388f fe05 cp #05
3891 02 ld (bc),a
3892 07 rlca
3893 04 inc b
3894 018500 ld bc,#0085
3897 02 ld (bc),a
3898 0e06 ld c,#06
389a 04 inc b
389b fe05 cp #05
389d 02 ld (bc),a
389e 07 rlca
389f 04 inc b
38a0 05 dec b
38a1 02 ld (bc),a
38a2 01a700 ld bc,#00a7
38a5 02 ld (bc),a
38a6 0e06 ld c,#06
38a8 04 inc b
38a9 fe05 cp #05
38ab 02 ld (bc),a
38ac 07 rlca
38ad 02 ld (bc),a
38ae 01c700 ld bc,#00c7
38b1 02 ld (bc),a
38b2 0e06 ld c,#06
38b4 04 inc b
38b5 fe05 cp #05
38b7 02 ld (bc),a
38b8 07 rlca
38b9 02 ld (bc),a
38ba 05 dec b
38bb 0101a7 ld bc,#a701
38be 00 nop
38bf 02 ld (bc),a
38c0 0e06 ld c,#06
38c2 04 inc b
38c3 fe05 cp #05
38c5 02 ld (bc),a
38c6 07 rlca
38c7 04 inc b
38c8 01b100 ld bc,#00b1
38cb 02 ld (bc),a
38cc 0e06 ld c,#06
38ce 04 inc b
38cf fe05 cp #05
38d1 02 ld (bc),a
38d2 07 rlca
38d3 02 ld (bc),a
38d4 01b100 ld bc,#00b1
38d7 02 ld (bc),a
38d8 0e06 ld c,#06
38da 04 inc b
38db fe05 cp #05
38dd 02 ld (bc),a
38de 07 rlca
38df 02 ld (bc),a
38e0 019500 ld bc,#0095
38e3 02 ld (bc),a
38e4 0e06 ld c,#06
38e6 04 inc b
38e7 fe05 cp #05
38e9 02 ld (bc),a
38ea 07 rlca
38eb 04 inc b
38ec 01b100 ld bc,#00b1
38ef 02 ld (bc),a
38f0 0e06 ld c,#06
38f2 04 inc b
38f3 fe05 cp #05
38f5 02 ld (bc),a
38f6 07 rlca
38f7 0605 ld b,#05
38f9 02 ld (bc),a
38fa 018500 ld bc,#0085
38fd 02 ld (bc),a
38fe 0e06 ld c,#06
3900 04 inc b
3901 fe05 cp #05
3903 02 ld (bc),a
3904 07 rlca
3905 04 inc b
3906 05 dec b
3907 03 inc bc
3908 01b100 ld bc,#00b1
390b 02 ld (bc),a
390c 0e06 ld c,#06
390e 04 inc b
390f fe05 cp #05
3911 02 ld (bc),a
3912 07 rlca
3913 02 ld (bc),a
3914 01b100 ld bc,#00b1
3917 02 ld (bc),a
3918 0e06 ld c,#06
391a 04 inc b
391b fe05 cp #05
391d 02 ld (bc),a
391e 07 rlca
391f 02 ld (bc),a
3920 01b100 ld bc,#00b1
3923 02 ld (bc),a
3924 0e06 ld c,#06
3926 04 inc b
3927 fe05 cp #05
3929 02 ld (bc),a
392a 07 rlca
392b 02 ld (bc),a
392c 018d00 ld bc,#008d
392f 02 ld (bc),a
3930 0e06 ld c,#06
3932 04 inc b
3933 fe05 cp #05
3935 02 ld (bc),a
3936 07 rlca
3937 02 ld (bc),a
3938 019500 ld bc,#0095
393b 02 ld (bc),a
393c 0e06 ld c,#06
393e 04 inc b
393f fe05 cp #05
3941 02 ld (bc),a
3942 07 rlca
3943 02 ld (bc),a
3944 05 dec b
3945 010176 ld bc,#7601
3948 00 nop
3949 02 ld (bc),a
394a 0e06 ld c,#06
394c 04 inc b
394d fe05 cp #05
394f 02 ld (bc),a
3950 07 rlca
3951 0605 ld b,#05
3953 04 inc b
3954 01ec00 ld bc,#00ec
3957 02 ld (bc),a
3958 0e06 ld c,#06
395a 04 inc b
395b fe05 cp #05
395d 02 ld (bc),a
395e 07 rlca
395f 0609 ld b,#09
3961 00 nop
3962 00 nop
3963 15 dec d
3964 00 nop
3965 00 nop
3966 00 nop
3967 3000 jr nc,#3969 ; (0)
3969 00 nop
396a 00 nop
396b 45 ld b,l
396c 00 nop
396d 00 nop
396e 00 nop
396f 60 ld h,b
3970 00 nop
3971 00 nop
3972 50 ld d,b
3973 12 ld (de),a
3974 00 nop
3975 00 nop
3976 00 nop
3977 25 dec h
3978 00 nop
3979 00 nop
397a 50 ld d,b
397b 37 scf
397c 00 nop
397d 00 nop
397e 00 nop
397f 50 ld d,b
3980 00 nop
3981 00 nop
3982 00 nop
3983 1000 djnz #3985 ; (0)
3985 00 nop
3986 00 nop
3987 2000 jr nz,#3989 ; (0)
3989 00 nop
398a 00 nop
398b 3000 jr nc,#398d ; (0)
398d 00 nop
398e 00 nop
398f 40 ld b,b
3990 00 nop
3991 00 nop
3992 50 ld d,b
3993 07 rlca
3994 00 nop
3995 00 nop
3996 00 nop
3997 15 dec d
3998 00 nop
3999 00 nop
399a 50 ld d,b
399b 220000 ld (#0000),hl
399e 00 nop
399f 3000 jr nc,#39a1 ; (0)
39a1 05 dec b
39a2 04 inc b
39a3 03 inc bc
39a4 02 ld (bc),a
39a5 00 nop
39a6 03 inc bc
39a7 0609 ld b,#09
39a9 00 nop
39aa 03 inc bc
39ab 00 nop
39ac 00 nop
39ad 0603 ld b,#03
39af 00 nop
39b0 03 inc bc
39b1 00 nop
39b2 00 nop
39b3 0603 ld b,#03
39b5 00 nop
39b6 00 nop
39b7 09 add hl,bc
39b8 00 nop
39b9 ff rst #38
; starting RAM values
39ba 4c ld c,h ; initials 1
39bb 52 ld d,d
39bc 53 ld d,e
39bd 50 ld d,b ; high score 1
39be 42 ld b,d
39bf 03 inc bc
39c0 4d ld c,l ; initials 2
39c1 43 ld b,e
39c2 53 ld d,e
39c3 60 ld h,b ; high score 2
39c4 17 rla
39c5 03 inc bc
39c6 4a ld c,d
39c7 4d ld c,l
39c8 53 ld d,e
39c9 2085 jr nz,#3950 ; (-123)
39cb 02 ld (bc),a
39cc 42 ld b,d
39cd 4f ld c,a
39ce 40 ld b,b
39cf 90 sub b
39d0 76 halt
39d1 02 ld (bc),a
39d2 4a ld c,d
39d3 53 ld d,e
39d4 40 ld b,b
39d5 50 ld d,b
39d6 31024a ld sp,#4a02
39d9 46 ld b,(hl)
39da 53 ld d,e
39db 90 sub b
39dc 1002 djnz #39e0 ; (2)
39de 46 ld b,(hl)
39df 53 ld d,e
39e0 4d ld c,l
39e1 00 nop
39e2 05 dec b
39e3 02 ld (bc),a
39e4 43 ld b,e
39e5 53 ld d,e
39e6 4d ld c,l
39e7 60 ld h,b
39e8 010243 ld bc,#4302
39eb 44 ld b,h
39ec 40 ld b,b
39ed 80 add a,b
39ee 98 sbc a,b
39ef 014844 ld bc,#4448
39f2 43 ld b,e
39f3 40 ld b,b
39f4 86 add a,(hl)
39f5 010710 ld bc,#1007
39f8 03 inc bc
39f9 12 ld (de),a
39fa 97 sub a
39fb 4d ld c,l
39fc 52 ld d,d
000039f0 48 44 43 40 86 01 07 10 03 12 97 4d 52 20 54 4e |HDC@.......MR TN|
00003a00 54 2c 43 4f 50 59 52 49 47 48 54 20 31 39 38 33 |T,COPYRIGHT 1983|
00003a10 54 45 4c 4b 4f 20 49 4e 43 3a 2d 4e 4b 33 41 43 |TELKO INC:-NK3AC|
3a19 3a2d4e ld a,(#4e2d)
3a1c 4b ld c,e
3a1d 33 inc sp
3a1e 41 ld b,c
3a1f 43 ld b,e
3a20 41 ld b,c
3a21 44 ld b,h
3a22 44 ld b,h
3a23 2020 jr nz,#3a45 ; (32)
3a25 2005 jr nz,#3a2c ; (5)
3a27 00 nop
3a28 a5 and l
3a29 39 add hl,sp
3a2a b8 cp b
3a2b 39 add hl,sp
3a2c e4343a call po,#3a34
3a2f 2c inc l
3a30 41 ld b,c
3a31 53 ld d,e
3a32 54 ld d,h
3a33 45 ld b,l
3a34 54 ld d,h
3a35 41 ld b,c
3a36 2020 jr nz,#3a58 ; (32)
3a38 49 ld c,c
3a39 2b dec hl
3a3a 5f ld e,a
3a3b 3a032a ld a,(#2a03)
3a3e 4e ld c,(hl)
3a3f 4f ld c,a
3a40 4e ld c,(hl)
3a41 41 ld b,c
3a42 4d ld c,l
3a43 45 ld b,l
3a44 2a0500 ld hl,(#0005)
3a47 00 nop
3a48 00 nop
3a49 00 nop
3a4a 00 nop
3a4b 4d ld c,l
3a4c 3a8608 ld a,(#0886)
3a4f b7 or a
3a50 00 nop
3a51 61 ld h,c
3a52 39 add hl,sp
3a53 183a jr #3a8f ; (58)
3a55 15 dec d
3a56 39 add hl,sp
3a57 54 ld d,h
3a58 41 ld b,c
3a59 42 ld b,d
3a5a 4c ld c,h
3a5b 45 ld b,l
3a5c 53 ld d,e
3a5d 2020 jr nz,#3a7f ; (32)
3a5f 57 ld d,a
3a60 2b dec hl
3a61 86 add a,(hl)
3a62 3a032a ld a,(#2a03)
3a65 4e ld c,(hl)
3a66 4f ld c,a
3a67 4e ld c,(hl)
3a68 41 ld b,c
3a69 4d ld c,l
3a6a 45 ld b,l
3a6b 2a0600 ld hl,(#0006)
3a6e 00 nop
3a6f 00 nop
3a70 00 nop
3a71 00 nop
3a72 74 ld (hl),h
3a73 3a8608 ld a,(#0886)
3a76 0f rrca
3a77 00 nop
3a78 04 inc b
3a79 34 inc (hl)
3a7a 13 inc de
3a7b 34 inc (hl)
3a7c b2 or d
3a7d 32494e ld (#4e49),a
3a80 49 ld c,c
3a81 54 ld d,h
3a82 53 ld d,e
3a83 2020 jr nz,#3aa5 ; (32)
3a85 2065 jr nz,#3aec ; (101)
3a87 2b dec hl
3a88 bf cp a
3a89 3a032a ld a,(#2a03)
3a8c 4e ld c,(hl)
3a8d 4f ld c,a
3a8e 4e ld c,(hl)
3a8f 41 ld b,c
3a90 4d ld c,l
3a91 45 ld b,l
3a92 2a0700 ld hl,(#0007)
3a95 00 nop
3a96 00 nop
3a97 00 nop
3a98 00 nop
3a99 e62e and #2e
3a9b 05 dec b
3a9c 00 nop
3a9d d43ae7 call nc,#e73a
3aa0 3adf4d ld a,(#4ddf)
3aa3 ee2c xor #2c
3aa5 53 ld d,e
3aa6 42 ld b,d
3aa7 55 ld d,l
3aa8 46 ld b,(hl)
3aa9 46 ld b,(hl)
3aaa 45 ld b,l
3aab 52 ld d,d
3aac 2005 jr nz,#3ab3 ; (5)
3aae 00 nop
3aaf d43ae7 call nc,#e73a
3ab2 3af54d ld a,(#4df5)
3ab5 80 add a,b
3ab6 314c43 ld sp,#434c
3ab9 4e ld c,(hl)
3aba 54 ld d,h
3abb 2020 jr nz,#3add ; (32)
3abd 2020 jr nz,#3adf ; (32)
3abf 73 ld (hl),e
3ac0 2b dec hl
3ac1 d43a03 call nc,#033a
3ac4 2a4e4f ld hl,(#4f4e)
3ac7 4e ld c,(hl)
3ac8 41 ld b,c
3ac9 4d ld c,l
3aca 45 ld b,l
3acb 2a0800 ld hl,(#0008)
3ace 00 nop
3acf 00 nop
3ad0 00 nop
3ad1 00 nop
3ad2 b4 or h
3ad3 2d dec l
3ad4 81 add a,c
3ad5 2b dec hl
3ad6 00 nop
3ad7 00 nop
3ad8 03 inc bc
3ad9 2a4e4f ld hl,(#4f4e)
3adc 4e ld c,(hl)
3add 41 ld b,c
3ade 4d ld c,l
3adf 45 ld b,l
3ae0 2a0900 ld hl,(#0009)
3ae3 00 nop
3ae4 00 nop
3ae5 00 nop
3ae6 00 nop
3ae7 e9 jp (hl)
3ae8 3a8600 ld a,(#0086)
3aeb c24edd jp nz,#dd4e
3aee 4d ld c,l
3aef c24e4f jp nz,#4f4e
3af2 3850 jr c,#3b44 ; (80)
3af4 52 ld d,d
3af5 4f ld c,a
3af6 52 ld d,d
3af7 41 ld b,c
3af8 4d ld c,l
3af9 2020 jr nz,#3b1b ; (32)
3afb dd4d ld c,ixl
3afd c24ee9 jp nz,#e94e
3b00 3a0000 ld a,(#0000)
3b03 00 nop
3b04 3600 ld (hl),#00
3b06 37 scf
3b07 00 nop
3b08 0a ld a,(bc)
3b09 3b dec sp
3b0a 19 add hl,de
3b0b 3aff4b ld a,(#4bff)
3b0e 8f adc a,a
3b0f 2b dec hl
3b10 bc cp h
3b11 1b dec de
3b12 2a28f8 ld hl,(#f828)
3b15 2e19 ld l,#19
3b17 3b dec sp
3b18 00 nop
3b19 2b dec hl
3b1a 28d0 jr z,#3aec ; (-48)
3b1c 31e62e ld sp,#2ee6
3b1f 223b00 ld (#003b),hl
3b22 d1 pop de
3b23 310334 ld sp,#3403
3b26 b4 or h
3b27 2d dec l
3b28 2b dec hl
3b29 3b dec sp
3b2a 00 nop
3b2b 04 inc b
3b2c 34 inc (hl)
3b2d 13 inc de
3b2e 34 inc (hl)
3b2f 74 ld (hl),h
3b30 3a343b ld a,(#3b34)
3b33 00 nop
3b34 14 inc d
3b35 34 inc (hl)
3b36 73 ld (hl),e
3b37 35 dec (hl)
3b38 ba cp d
3b39 39 add hl,sp
3b3a 3d dec a
3b3b 3b dec sp
3b3c 00 nop
3b3d 74 ld (hl),h
3b3e 35 dec (hl)
3b3f 60 ld h,b
3b40 39 add hl,sp
3b41 f636 or #36
3b43 46 ld b,(hl)
3b44 3b dec sp
3b45 00 nop
3b46 61 ld h,c
3b47 39 add hl,sp
3b48 183a jr #3b84 ; (58)
3b4a 4d ld c,l
3b4b 3ad836 ld a,(#36d8)
3b4e 00 nop
3b4f fe8d cp #8d
3b51 08 ex af,af'
3b52 0a ld a,(bc)
3b53 07 rlca
3b54 07 rlca
3b55 0a ld a,(bc)
3b56 29 add hl,hl
3b57 6f ld l,a
3b58 09 add hl,bc
3b59 fd04 inc b
3b5b 01300b ld bc,#0b30
3b5e fb ei
3b5f 85 add a,l
3b60 08 ex af,af'
3b61 0b dec bc
3b62 01700b ld bc,#0b70
3b65 fa8508 jp m,#0885
3b68 0c inc c
3b69 016902 ld bc,#0269
3b6c b1 or c
3b6d 88 adc a,b
3b6e 02 ld (bc),a
3b6f ba cp d
3b70 6a ld l,d
3b71 08 ex af,af'
3b72 0d dec c
3b73 015f02 ld bc,#025f
3b76 a5 and l
3b77 63 ld h,e
3b78 0b dec bc
3b79 29 add hl,hl
3b7a 5e ld e,(hl)
3b7b 05 dec b
3b7c 2c inc l
3b7d 85 add a,l
3b7e 018601 ld bc,#0186
3b81 03 inc bc
3b82 05 dec b
3b83 0d dec c
3b84 86 add a,(hl)
3b85 08 ex af,af'
3b86 0e07 ld c,#07
3b88 07 rlca
3b89 03 inc bc
3b8a 07 rlca
3b8b 0607 ld b,#07
3b8d 07 rlca
3b8e 02 ld (bc),a
3b8f 8c adc a,h
3b90 4a ld c,d
3b91 08 ex af,af'
3b92 0f rrca
3b93 03 inc bc
3b94 0a ld a,(bc)
3b95 f684 or #84
3b97 0b dec bc
3b98 f5 push af
3b99 41 ld b,c
3b9a 03 inc bc
3b9b 0d dec c
3b9c 08 ex af,af'
3b9d 0b dec bc
3b9e fd84 add a,iyh
3ba0 07 rlca
3ba1 01030b ld bc,#0b03
3ba4 fc3507 call m,#0735
3ba7 02 ld (bc),a
3ba8 03 inc bc
3ba9 0b dec bc
3baa 2b dec hl
3bab 87 add a,a
3bac 02 ld (bc),a
3bad f4923d call p,#3d92
3bb0 018a0b ld bc,#0b8a
3bb3 2d dec l
3bb4 8c adc a,h
3bb5 02 ld (bc),a
3bb6 eb ex de,hl
3bb7 89 adc a,c
3bb8 3d dec a
3bb9 13 inc de
3bba 00 nop
3bbb 07 rlca
3bbc 04 inc b
3bbd 07 rlca
3bbe 08 ex af,af'
3bbf 03 inc bc
3bc0 09 add hl,bc
3bc1 fc040b call m,#0b04
3bc4 de92 sbc a,#92
3bc6 210b20 ld hl,#200b
3bc9 81 add a,c
3bca 0b dec bc
3bcb f9 ld sp,hl
3bcc 86 add a,(hl)
3bcd 08 ex af,af'
3bce 07 rlca
3bcf 060a ld b,#0a
3bd1 03 inc bc
3bd2 02 ld (bc),a
3bd3 08 ex af,af'
3bd4 2c inc l
3bd5 01790b ld bc,#0b79
3bd8 df rst #18
3bd9 89 adc a,c
3bda 02 ld (bc),a
3bdb c624 add a,#24
3bdd 060b ld b,#0b
3bdf 03 inc bc
3be0 01330b ld bc,#0b33
3be3 e0 ret po
3be4 c5 push bc
3be5 210b20 ld hl,#200b
3be8 81 add a,c
3be9 0b dec bc
3bea f7 rst #30
3beb a0 and b
3bec 0b dec bc
3bed 2c inc l
3bee 12 ld (de),a
3bef 0b dec bc
3bf0 280f jr z,#3c01 ; (15)
3bf2 0b dec bc
3bf3 f687 or #87
3bf5 1f rra
3bf6 07 rlca
3bf7 01a101 ld bc,#01a1
3bfa 061f ld b,#1f
3bfc db02 in a,(#02)
3bfe a3 and e
3bff 7a ld a,d
3c00 0b dec bc
3c01 29 add hl,hl
3c02 77 ld (hl),a
3c03 3d dec a
3c04 07 rlca
3c05 04 inc b
3c06 0601 ld b,#01
3c08 03 inc bc
3c09 01130b ld bc,#0b13
3c0c f9 ld sp,hl
3c0d 96 sub (hl)
3c0e 1f rra
3c0f 060b ld b,#0b
3c11 2c inc l
3c12 67 ld h,a
3c13 0b dec bc
3c14 2864 jr z,#3c7a ; (100)
3c16 0b dec bc
3c17 f661 or #61
3c19 0b dec bc
3c1a 29 add hl,hl
3c1b 5e ld e,(hl)
3c1c 07 rlca
3c1d 03 inc bc
3c1e 060c ld b,#0c
3c20 03 inc bc
3c21 0d dec c
3c22 08 ex af,af'
3c23 02 ld (bc),a
3c24 3c inc a
3c25 54 ld d,h
3c26 210168 ld hl,#6801
3c29 0b dec bc
3c2a e1 pop hl
3c2b a9 xor c
3c2c 210b28 ld hl,#280b
3c2f 4a ld c,d
3c30 0a ld a,(bc)
3c31 f691 or #91
3c33 1f rra
3c34 d302 out (#02),a
3c36 6b ld l,e
3c37 42 ld b,d
3c38 0b dec bc
3c39 29 add hl,hl
3c3a 3f ccf
3c3b 0b dec bc
3c3c 2c inc l
3c3d 3c inc a
3c3e 0b dec bc
3c3f f7 rst #30
3c40 39 add hl,sp
3c41 01410b ld bc,#0b41
3c44 29 add hl,hl
3c45 34 inc (hl)
3c46 0b dec bc
3c47 2c inc l
3c48 310af7 ld sp,#f70a
3c4b 84 add a,h
3c4c 02 ld (bc),a
3c4d 13 inc de
3c4e 2b dec hl
3c4f 21014b ld hl,#4b01
3c52 01260b ld bc,#0b26
3c55 e2b20b jp po,#0bb2
3c58 2081 jr nz,#3bdb ; (-127)
3c5a 0b dec bc
3c5b fa8c0b jp m,#0b8c
3c5e 2c inc l
3c5f 73 ld (hl),e
3c60 1f rra
3c61 eb ex de,hl
3c62 0b dec bc
3c63 fe6e cp #6e
3c65 0601 ld b,#01
3c67 03 inc bc
3c68 0b dec bc
3c69 f9 ld sp,hl
3c6a 8b adc a,e
3c6b 0b dec bc
3c6c 2c inc l
3c6d 65 ld h,l
3c6e 0b dec bc
3c6f f9 ld sp,hl
3c70 62 ld h,d
3c71 1f rra
3c72 08 ex af,af'
3c73 01710b ld bc,#0b71
3c76 285b jr z,#3cd3 ; (91)
3c78 0b dec bc
3c79 f8 ret m
3c7a 58 ld e,b
3c7b 0b dec bc
3c7c 29 add hl,hl
3c7d 55 ld d,l
3c7e 0b dec bc
3c7f 2c inc l
3c80 52 ld d,d
3c81 1f rra
3c82 e3 ex (sp),hl
3c83 02 ld (bc),a
3c84 05 dec b
3c85 5d ld e,l
3c86 015e0b ld bc,#0b5e
3c89 e3 ex (sp),hl
3c8a 8a adc a,d
3c8b 02 ld (bc),a
3c8c 15 dec d
3c8d 45 ld b,l
3c8e 3d dec a
3c8f 07 rlca
3c90 03 inc bc
3c91 060d ld b,#0d
3c93 03 inc bc
3c94 04 inc b
3c95 00 nop
3c96 00 nop
3c97 00 nop
3c98 00 nop
3c99 69 ld l,c
3c9a 60 ld h,b
3c9b 4e ld c,(hl)
3c9c 23 inc hl
3c9d 46 ld b,(hl)
3c9e 1a ld a,(de)
3c9f 81 add a,c
3ca0 6f ld l,a
3ca1 13 inc de
3ca2 1a ld a,(de)
3ca3 88 adc a,b
3ca4 67 ld h,a
3ca5 c9 ret
3ca6 eb ex de,hl
3ca7 5f ld e,a
3ca8 1600 ld d,#00
3caa eb ex de,hl
3cab 1a ld a,(de)
3cac 85 add a,l
3cad 6f ld l,a
3cae 13 inc de
3caf 1a ld a,(de)
3cb0 8c adc a,h
3cb1 67 ld h,a
3cb2 c9 ret
3cb3 eb ex de,hl
3cb4 5f ld e,a
3cb5 1600 ld d,#00
3cb7 eb ex de,hl
3cb8 1a ld a,(de)
3cb9 a5 and l
3cba 6f ld l,a
3cbb 13 inc de
3cbc 1a ld a,(de)
3cbd a4 and h
3cbe 67 ld h,a
3cbf c9 ret
3cc0 44 ld b,h
3cc1 4d ld c,l
3cc2 210000 ld hl,#0000
3cc5 3e10 ld a,#10
3cc7 f5 push af
3cc8 29 add hl,hl
3cc9 eb ex de,hl
3cca 97 sub a
3ccb 29 add hl,hl
3ccc eb ex de,hl
3ccd 8d adc a,l
3cce 91 sub c
3ccf 6f ld l,a
3cd0 7c ld a,h
3cd1 98 sbc a,b
3cd2 67 ld h,a
3cd3 13 inc de
3cd4 d2d93c jp nc,#3cd9
3cd7 09 add hl,bc
3cd8 1b dec de
3cd9 f1 pop af
3cda 3d dec a
3cdb c2c73c jp nz,#3cc7
3cde c9 ret
3cdf 5e ld e,(hl)
3ce0 23 inc hl
3ce1 56 ld d,(hl)
3ce2 eb ex de,hl
3ce3 29 add hl,hl
3ce4 e5 push hl
3ce5 29 add hl,hl
3ce6 29 add hl,hl
3ce7 c1 pop bc
3ce8 09 add hl,bc
3ce9 c9 ret
3cea 44 ld b,h
3ceb 4d ld c,l
3cec 210000 ld hl,#0000
3cef 3e10 ld a,#10
3cf1 29 add hl,hl
3cf2 eb ex de,hl
3cf3 29 add hl,hl
3cf4 eb ex de,hl
3cf5 d2f93c jp nc,#3cf9
3cf8 09 add hl,bc
3cf9 3d dec a
3cfa c2f13c jp nz,#3cf1
3cfd c9 ret
3cfe 59 ld e,c
3cff 50 ld d,b
3d00 eb ex de,hl
3d01 97 sub a
3d02 95 sub l
3d03 6f ld l,a
3d04 3e00 ld a,#00
3d06 9c sbc a,h
3d07 67 ld h,a
3d08 c9 ret
3d09 eb ex de,hl
3d0a 5f ld e,a
3d0b 1600 ld d,#00
3d0d eb ex de,hl
3d0e 1a ld a,(de)
3d0f b5 or l
3d10 6f ld l,a
3d11 13 inc de
3d12 1a ld a,(de)
3d13 b4 or h
3d14 67 ld h,a
3d15 c9 ret
3d16 5f ld e,a
3d17 1600 ld d,#00
3d19 7b ld a,e
3d1a 95 sub l
3d1b 6f ld l,a
3d1c 7a ld a,d
3d1d 9c sbc a,h
3d1e 67 ld h,a
3d1f c9 ret
3d20 4f ld c,a
3d21 0600 ld b,#00
3d23 7b ld a,e
3d24 91 sub c
3d25 6f ld l,a
3d26 7a ld a,d
3d27 98 sbc a,b
3d28 67 ld h,a
3d29 c9 ret
3d2a 69 ld l,c
3d2b 60 ld h,b
3d2c 4e ld c,(hl)
3d2d 23 inc hl
3d2e 46 ld b,(hl)
3d2f 1a ld a,(de)
3d30 91 sub c
3d31 6f ld l,a
3d32 13 inc de
3d33 1a ld a,(de)
3d34 98 sbc a,b
3d35 67 ld h,a
3d36 c9 ret
3d37 6f ld l,a
3d38 2600 ld h,#00
3d3a 1a ld a,(de)
3d3b 95 sub l
3d3c 6f ld l,a
3d3d 13 inc de
3d3e 1a ld a,(de)
3d3f 9c sbc a,h
3d40 67 ld h,a
3d41 c9 ret
3d42 5f ld e,a
3d43 1600 ld d,#00
3d45 7b ld a,e
3d46 96 sub (hl)
3d47 5f ld e,a
3d48 7a ld a,d
3d49 23 inc hl
3d4a 9e sbc a,(hl)
3d4b 57 ld d,a
3d4c eb ex de,hl
3d4d c9 ret
3d4e 00 nop
3d4f 00 nop
3d50 00 nop
3d51 00 nop
3d52 00 nop
3d53 00 nop
3d54 00 nop
3d55 00 nop
3d56 00 nop
3d57 00 nop
3d58 00 nop
3d59 00 nop
3d5a 00 nop
3d5b 00 nop
3d5c 00 nop
3d5d 00 nop
3d5e 00 nop
3d5f 00 nop
3d60 00 nop
3d61 00 nop
3d62 00 nop
3d63 00 nop
3d64 00 nop
3d65 00 nop
3d66 00 nop
3d67 00 nop
3d68 00 nop
3d69 00 nop
3d6a 00 nop
3d6b 00 nop
3d6c 00 nop
3d6d 00 nop
3d6e 00 nop
3d6f 00 nop
3d70 00 nop
3d71 00 nop
3d72 00 nop
3d73 00 nop
3d74 00 nop
3d75 00 nop
3d76 00 nop
3d77 00 nop
3d78 00 nop
3d79 00 nop
3d7a 00 nop
3d7b 00 nop
3d7c 00 nop
3d7d 00 nop
3d7e 00 nop
3d7f 00 nop
3d80 00 nop
3d81 00 nop
3d82 00 nop
3d83 00 nop
3d84 00 nop
3d85 00 nop
3d86 00 nop
3d87 00 nop
3d88 00 nop
3d89 00 nop
3d8a 00 nop
3d8b 00 nop
3d8c 00 nop
3d8d 00 nop
3d8e 00 nop
3d8f 00 nop
3d90 93 sub e
3d91 33 inc sp
3d92 93 sub e
3d93 33 inc sp
3d94 70 ld (hl),b
3d95 260c ld h,#0c
3d97 2a9c03 ld hl,(#039c)
3d9a f8 ret m
3d9b 29 add hl,hl
3d9c ec2e60 call pe,#602e
3d9f 2f cpl
3da0 00 nop
3da1 00 nop
3da2 d9 exx
3da3 13 inc de
3da4 b5 or l
3da5 24 inc h
3da6 4d ld c,l
3da7 26ff ld h,#ff
3da9 7f ld a,a
3daa 2f cpl
3dab 03 inc bc
3dac ba cp d
3dad 0600 ld b,#00
3daf 04 inc b
3db0 fc03df call m,#df03
3db3 12 ld (de),a
3db4 a7 and a
3db5 03 inc bc
3db6 d5 push de
3db7 03 inc bc
3db8 db03 in a,(#03)
3dba 8d adc a,l
3dbb 0f rrca
3dbc ea03f7 jp pe,#f703
3dbf 03 inc bc
3dc0 8a adc a,d
3dc1 03 inc bc
3dc2 00 nop
3dc3 12 ld (de),a
3dc4 0d dec c
3dc5 12 ld (de),a
3dc6 1a ld a,(de)
3dc7 12 ld (de),a
3dc8 cf rst #8
3dc9 16e2 ld d,#e2
3dcb 03 inc bc
3dcc 09 add hl,bc
3dcd 13 inc de
3dce 33 inc sp
3dcf 13 inc de
3dd0 dacf16 jp c,#16cf
3dd3 f208d2 jp p,#d208
3dd6 4f ld c,a
3dd7 58 ld e,b
3dd8 8a adc a,d
3dd9 03 inc bc
3dda daa8c4 jp c,#c4a8
3ddd 52 ld d,d
3dde 4f ld c,a
3ddf 57 ld d,a
3de0 8d adc a,l
3de1 0f rrca
3de2 85 add a,l
3de3 c7 rst #0
3de4 4e ld c,(hl)
3de5 49 ld c,c
3de6 4e ld c,(hl)
3de7 52 ld d,d
3de8 41 ld b,c
3de9 57 ld d,a
3dea 00 nop
3deb 12 ld (de),a
3dec 97 sub a
3ded cd5254 call #5452
3df0 a5 and l
3df1 19 add hl,de
3df2 96 sub (hl)
3df3 10c5 djnz #3dba ; (-59)
3df5 4c ld c,h
3df6 54 ld d,h
3df7 49 ld c,c
3df8 54 ld d,h
3df9 56 ld d,(hl)
3dfa 1a ld a,(de)
3dfb 8b adc a,e
3dfc cd5953 call #5359
3dff ad xor l
3e00 13 inc de
3e01 96 sub (hl)
3e02 40 ld b,b
3e03 c25553 jp nz,#5355
3e06 b0 or b
3e07 14 inc d
3e08 da90c7 jp c,#c790
3e0b 4e ld c,(hl)
3e0c 49 ld c,c
3e0d 52 ld d,d
3e0e 54 ld d,h
3e0f 53 ld d,e
3e10 d319 out (#19),a
3e12 95 sub l
3e13 c5 push bc
3e14 4c ld c,h
3e15 54 ld d,h
3e16 49 ld c,c
3e17 54 ld d,h
3e18 53 ld d,e
3e19 061c ld b,#1c
3e1b 8c adc a,h
3e1c cc5253 call z,#5352
3e1f 34 inc (hl)
3e20 12 ld (de),a
3e21 d9 exx
3e22 38c1 jr c,#3de5 ; (-63)
3e24 52 ld d,d
3e25 53 ld d,e
3e26 a1 and c
3e27 14 inc d
3e28 d9 exx
3e29 28c5 jr z,#3df0 ; (-59)
3e2b 43 ld b,e
3e2c 41 ld b,c
3e2d 50 ld d,b
3e2e 53 ld d,e
3e2f 2e16 ld l,#16
3e31 89 adc a,c
3e32 d0 ret nc
3e33 53 ld d,e
3e34 78 ld a,b
3e35 00 nop
3e36 f8 ret m
3e37 30c1 jr nc,#3dfa ; (-63)
3e39 4c ld c,h
3e3a 53 ld d,e
3e3b b2 or d
3e3c 1c inc e
3e3d d9 exx
3e3e 20d2 jr nz,#3e12 ; (-46)
3e40 48 ld c,b
3e41 53 ld d,e
3e42 a1 and c
3e43 12 ld (de),a
3e44 9f sbc a,a
3e45 cc4853 call z,#5348
3e48 c1 pop bc
3e49 12 ld (de),a
3e4a 9e sbc a,(hl)
3e4b d44553 call nc,#5345
3e4e f7 rst #30
3e4f 1c inc e
3e50 d8 ret c
3e51 c0 ret nz
3e52 c7 rst #0
3e53 45 ld b,l
3e54 53 ld d,e
3e55 94 sub h
3e56 00 nop
3e57 9a sbc a,d
3e58 ce4f adc a,#4f
3e5a 49 ld c,c
3e5b 54 ld d,h
3e5c 43 ld b,e
3e5d 45 ld b,l
3e5e 53 ld d,e
3e5f 27 daa
3e60 12 ld (de),a
3e61 a2 and d
3e62 00 nop
3e63 c643 add a,#43
3e65 53 ld d,e
3e66 0e1d ld c,#1d
3e68 d1 pop de
3e69 37 scf
3e6a d2414c jp nc,#4c41
3e6d 41 ld b,c
3e6e 43 ld b,e
3e6f 53 ld d,e
3e70 6b ld l,e
3e71 1d dec e
3e72 a7 and a
3e73 c34253 jp #5342
3e76 78 ld a,b
3e77 18dc jr #3e55 ; (-36)
3e79 98 sbc a,b
3e7a 42 ld b,d
3e7b d45352 call nc,#5253
3e7e 77 ld (hl),a
3e7f 15 dec d
3e80 df rst #18
3e81 c45252 call nz,#5252
3e84 d1 pop de
3e85 12 ld (de),a
3e86 d267c1 jp nc,#c167
3e89 43 ld b,e
3e8a 52 ld d,d
3e8b 52 ld d,d
3e8c b8 cp b
3e8d 00 nop
3e8e d1 pop de
3e8f 0f rrca
3e90 c35252 jp #5252
3e93 71 ld (hl),c
3e94 16d9 ld d,#d9
3e96 08 ex af,af'
3e97 c1 pop bc
3e98 52 ld d,d
3e99 52 ld d,d
3e9a c200d1 jp nz,#d100
3e9d 1f rra
3e9e d252e5 jp nc,#e552
3ea1 00 nop
3ea2 d9 exx
3ea3 18c4 jr #3e69 ; (-60)
3ea5 4c ld c,h
3ea6 52 ld d,d
3ea7 de00 sbc a,#00
3ea9 d26fc1 jp nc,#c16f
3eac 43 ld b,e
3ead 4c ld c,h
3eae 52 ld d,d
3eaf 65 ld h,l
3eb0 16d1 ld d,#d1
3eb2 07 rlca
3eb3 c34c52 jp #524c
3eb6 61 ld h,c
3eb7 12 ld (de),a
3eb8 d9 exx
3eb9 00 nop
3eba c1 pop bc
3ebb 4c ld c,h
3ebc 52 ld d,d
3ebd f200d1 jp p,#d100
3ec0 17 rla
3ec1 cc5208 call z,#0852
3ec4 01d910 ld bc,#10d9
3ec7 ce54 adc a,#54
3ec9 45 ld b,l
3eca 52 ld d,d
3ecb d0 ret nc
3ecc 00 nop
3ecd d245c9 jp nc,#c945
3ed0 54 ld d,h
3ed1 45 ld b,l
3ed2 52 ld d,d
3ed3 91 sub c
3ed4 12 ld (de),a
3ed5 d24dd4 jp nc,#d44d
3ed8 45 ld b,l
3ed9 52 ld d,d
3eda 15 dec d
3edb 01d7c9 ld bc,#c9d7
3ede c5 push bc
3edf 4d ld c,l
3ee0 55 ld d,l
3ee1 53 ld d,e
3ee2 45 ld b,l
3ee3 52 ld d,d
3ee4 0101a5 ld bc,#a501
3ee7 c5 push bc
3ee8 56 ld d,(hl)
3ee9 52 ld d,d
3eea 45 ld b,l
3eeb 53 ld d,e
3eec 45 ld b,l
3eed 52 ld d,d
3eee 7d ld a,l
3eef 16a4 ld d,#a4
3ef1 01d345 ld bc,#45d3
3ef4 52 ld d,d
3ef5 d600 sub #00
3ef7 d8 ret c
3ef8 80 add a,b
3ef9 d44145 call nc,#4541
3efc 50 ld d,b
3efd 45 ld b,l
3efe 52 ld d,d
3eff 40 ld b,b
3f00 018fd2 ld bc,#d28f
3f03 0f rrca
3f04 01f3c8 ld bc,#c8f3
3f07 53 ld d,e
3f08 55 ld d,l
3f09 50 ld d,b
3f0a 51 ld d,c
3f0b 01dec5 ld bc,#c5de
3f0e d0 ret nc
3f0f 4f ld c,a
3f10 50 ld d,b
3f11 2c inc l
3f12 01dec1 ld bc,#c1de
3f15 cf rst #8
3f16 50 ld d,b
3f17 25 dec h
3f18 01f220 ld bc,#20f2
3f1b c5 push bc
3f1c 50 ld d,b
3f1d f9 ld sp,hl
3f1e 00 nop
3f1f f228c5 jp p,#c528
3f22 47 ld b,a
3f23 41 ld b,c
3f24 50 ld d,b
3f25 0e17 ld c,#17
3f27 88 adc a,b
3f28 18d0 jr #3efa ; (-48)
3f2a 4b ld c,e
3f2b 16f2 ld d,#f2
3f2d 30c9 jr nc,#3ef8 ; (-55)
3f2f 54 ld d,h
3f30 55 ld d,l
3f31 4f ld c,a
3f32 77 ld (hl),a
3f33 01d2a3 ld bc,#a3d2
3f36 c45455 call nz,#5554
3f39 4f ld c,a
3f3a 4e ld c,(hl)
3f3b 15 dec d
3f3c d2abd4 jp nc,#d4ab
3f3f 55 ld d,l
3f40 4f ld c,a
3f41 8c adc a,h
3f42 01e141 ld bc,#41e1
3f45 d24954 jp nc,#5449
3f48 4f ld c,a
3f49 59 ld e,c
3f4a 16d2 ld d,#d2
3f4c b3 or e
3f4d d24454 jp nc,#5444
3f50 4f ld c,a
3f51 7c ld a,h
3f52 01d2bb ld bc,#bbd2
3f55 c7 rst #0
3f56 52 ld d,d
3f57 4f ld c,a
3f58 cf rst #8
3f59 14 inc d
3f5a 81 add a,c
3f5b d24f85 jp nc,#854f
3f5e 15 dec d
3f5f dab0da jp c,#dab0
3f62 4e ld c,(hl)
3f63 43 ld b,e
3f64 12 ld (de),a
3f65 f200d0 jp p,#d000
3f68 4f ld c,a
3f69 4e ld c,(hl)
3f6a 7f ld a,a
3f6b 19 add hl,de
3f6c d1 pop de
3f6d 00 nop
3f6e d45349 call nc,#4953
3f71 4c ld c,h
3f72 4f ld c,a
3f73 4e ld c,(hl)
3f74 a0 and b
3f75 00 nop
3f76 87 add a,a
3f77 c7 rst #0
3f78 45 ld b,l
3f79 4e ld c,(hl)
3f7a 45 ld b,l
3f7b 1d dec e
3f7c d244d2 jp nc,#d244
3f7f 48 ld c,b
3f80 43 ld b,e
3f81 4e ld c,(hl)
3f82 a3 and e
3f83 019cc3 ld bc,#c39c
3f86 4e ld c,(hl)
3f87 03 inc bc
3f88 1b dec de
3f89 f210c5 jp p,#c510
3f8c 4d ld c,l
3f8d 41 ld b,c
3f8e 4e ld c,(hl)
3f8f d401ab call nc,#ab01
3f92 c44f4d call nz,#4d4f
3f95 78 ld a,b
3f96 1c inc e
3f97 9d sbc a,l
3f98 c7 rst #0
3f99 45 ld b,l
3f9a 4d ld c,l
3f9b a6 and (hl)
3f9c 17 rla
3f9d 96 sub (hl)
3f9e f0 ret p
3f9f c5 push bc
3fa0 4d ld c,l
3fa1 381d jr c,#3fc0 ; (29)
3fa3 96 sub (hl)
3fa4 ff rst #38
3fa5 cf rst #8
3fa6 52 ld d,d
3fa7 43 ld b,e
3fa8 41 ld b,c
3fa9 4d ld c,l
3faa dd1a ld a,(de)
3fac 91 sub c
3fad cd6f17 call #176f
3fb0 f238cf jp p,#cf38
3fb3 4c ld c,h
3fb4 ea1a99 jp pe,#991a
3fb7 d45349 call nc,#4953
3fba 4c ld c,h
3fbb 311586 ld sp,#8615
3fbe d24944 jp nc,#4449
3fc1 4c ld c,h
3fc2 8a adc a,d
3fc3 17 rla
3fc4 d2b0c9 jp nc,#c9b0
3fc7 44 ld b,h
3fc8 4c ld c,h
3fc9 df rst #18
3fca 14 inc d
3fcb d2a0d2 jp nc,#d2a0
3fce 44 ld b,h
3fcf 44 ld b,h
3fd0 4c ld c,h
3fd1 93 sub e
3fd2 17 rla
3fd3 d2b8c4 jp nc,#c4b8
3fd6 44 ld b,h
3fd7 4c ld c,h
3fd8 0602 ld b,#02
3fda d2a8c4 jp nc,#c4a8
3fdd 4c ld c,h
3fde 14 inc d
3fdf 02 ld (bc),a
3fe0 d0 ret nc
3fe1 cc1b02 call z,#021b
3fe4 f5 push af
3fe5 05 dec b
3fe6 d24ae2 jp nc,#e24a
3fe9 15 dec d
3fea d318 out (#18),a
3fec d0 ret nc
3fed 4a ld c,d
3fee 34 inc (hl)
3fef 02 ld (bc),a
3ff0 d5 push de
3ff1 c3d949 jp #49d9
3ff4 3002 jr nc,#3ff8 ; (2)
3ff6 fc20d8 call m,#d820
3ff9 49 ld c,c
3ffa 81 add a,c
3ffb 17 rla
3ffc fd20c5 jr nz,#3fc4 ; (-59)
3fff 47 ld b,a
Disassembled 9077 instructions.
; pacman
; 0x03 2 coins 1 credit
; 0x02 1 coin 2 credit
; 0x01 1 coin 1 credit
; 0x00 freeplay
; lives: 1,2,3,5 -> 0x00, 0x04, 0x08, 0x0c
; bonus: 10k, 15k, 20k, none -> 0, 10, 20, 30
; norm/hard -> 0x40, 0x00
; in 1 0x80 -> cocktail
; mrtnt's dipswitch (0x5080)
; dsw1
; 0x01 2 coins 1 credit
; 0x02 1 coin 2 credits
; 0x03 1 coin 1 credit
; 0x00 freeplay
; lives: 2,3,4,5 -> 0x0c, 0x08, 0x04, 0x00 (lizwiz)
; bonus: 75k 100k 125k 150k -> 30, 20, 10, 0
; 0x40 : upright (SET)
; 0x80 : clear?
| 30.297598 | 78 | 0.44588 |
53e8228d6841c9a9735424c078889f839d12d177 | 2,134 | nasm | Assembly | fio.nasm | fasync/Syndicate | e206c600bf811aa3e30ba60d305728dd8bebfbf0 | [
"BSD-2-Clause"
] | 1 | 2021-03-02T23:29:32.000Z | 2021-03-02T23:29:32.000Z | fio.nasm | fasync/Syndicate | e206c600bf811aa3e30ba60d305728dd8bebfbf0 | [
"BSD-2-Clause"
] | null | null | null | fio.nasm | fasync/Syndicate | e206c600bf811aa3e30ba60d305728dd8bebfbf0 | [
"BSD-2-Clause"
] | null | null | null | ;; Copyright (c) 2020, Florian Büstgens
;; All rights reserved.
;;
;; Redistribution and use in source and binary forms, with or without
;; modification, are permitted provided that the following conditions are met:
;; 1. Redistributions of source code must retain the above copyright
;; notice, this list of conditions and the following disclaimer.
;;
;; 2. Redistributions in binary form must reproduce the above copyright notice,
;; this list of conditions and the following disclaimer in the
;; documentation and/or other materials provided with the distribution.
;;
;; THIS SOFTWARE IS PROVIDED BY <copyright holder> ''AS IS'' AND ANY
;; EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
;; WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
;; DISCLAIMED. IN NO EVENT SHALL <copyright holder> BE LIABLE FOR ANY
;; DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
;; (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
;; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
;; ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
;; (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
;; SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
;; fio.inc
;; Routines to find the kernel on a FAT32 partition
%include "fat32.nasm"
;; ----------------------------------------------------------
;; Find the kernel on a FAT32 drive
;; ----------------------------------------------------------
detect_kern:
push ax
push bx
push cx
call prepare_fs ; Preparing the bootloader to read the FAT32 drive
;; Getting file informations
mov di, 0x0200 + 0x20 ; Get first file entry
mov dx, WORD[di + 0x001A] ; Offset of the file entry
mov WORD[__cluster], dx
;; Preparing kernel location
mov ax, 0x0100 ; Location
mov es, ax ; Setting extra segment
xor bx, bx
;; Reading kernel cluster
mov cx, 0x0008
mov ax, WORD[__cluster]
call _lba_conv
call _read_disk_sectors
pop cx
pop bx
pop ax
ret
__cluster: dw 0x0000
| 34.419355 | 83 | 0.701968 |
dc254d055222b34a8707f04e6b26022c9c0af9ed | 1,893 | asm | Assembly | programs/oeis/005/A005970.asm | neoneye/loda | afe9559fb53ee12e3040da54bd6aa47283e0d9ec | [
"Apache-2.0"
] | 22 | 2018-02-06T19:19:31.000Z | 2022-01-17T21:53:31.000Z | programs/oeis/005/A005970.asm | neoneye/loda | afe9559fb53ee12e3040da54bd6aa47283e0d9ec | [
"Apache-2.0"
] | 41 | 2021-02-22T19:00:34.000Z | 2021-08-28T10:47:47.000Z | programs/oeis/005/A005970.asm | neoneye/loda | afe9559fb53ee12e3040da54bd6aa47283e0d9ec | [
"Apache-2.0"
] | 5 | 2021-02-24T21:14:16.000Z | 2021-08-09T19:48:05.000Z | ; A005970: Partial sums of squares of Lucas numbers.
; 1,10,26,75,196,520,1361,3570,9346,24475,64076,167760,439201,1149850,3010346,7881195,20633236,54018520,141422321,370248450,969323026,2537720635,6643838876,17393796000,45537549121,119218851370,312119004986,817138163595,2139295485796,5600748293800,14662949395601,38388099893010,100501350283426,263115950957275,688846502588396,1803423556807920,4721424167835361,12360848946698170,32361122672259146,84722519070079275,221806434537978676,580696784543856760,1520283919093591601,3980154972736918050,10420180999117162546,27280388024614569595,71420983074726546236,186982561199565069120,489526700523968661121,1281597540372340914250,3355265920593054081626,8784200221406821330635,22997334743627409910276,60207804009475408400200,157626077284798815290321,412670427844921037470770,1080385206249964297121986,2828485190904971853895195,7405070366464951264563596,19386725908489881939795600,50755107359004694554823201,132878596168524201724674010,347880681146567910619198826,910763447271179530132922475,2384409660666970679779568596,6242465534729732509205783320,16342986943522226847837781361,42786495295836948034307560770,112016498943988617255084900946,293263001536128903730947142075,767772505664398093937756525276,2010054515457065378082322433760,5262391040706798040309210776001,13777118606663328742845309894250,36068964779283188188226718906746,94429775731186235821834846825995,247220362414275519277277821571236,647231311511640322009998617887720,1694473572120645446752718032091921,4436189404850296018248155478388050,11614094642430242607991748403072226,30406094522440431805727089730828635,79604188924891052809189520789413676,208406472252232726621841472637412400,545615227831807127056334897122823521
add $0,1
seq $0,2878 ; Bisection of Lucas sequence: a(n) = L(2*n+1).
mov $1,$0
sub $0,1
sub $1,2
lpb $1
sub $1,2
mod $1,5
sub $1,2
add $0,$1
trn $1,1
lpe
| 118.3125 | 1,674 | 0.908082 |
8bbac80e71ad25f7e15e000effc72b0bade058fe | 3,996 | asm | Assembly | Transynther/x86/_processed/NONE/_xt_/i3-7100_9_0x84_notsx.log_21829_522.asm | ljhsiun2/medusa | 67d769b8a2fb42c538f10287abaf0e6dbb463f0c | [
"MIT"
] | 9 | 2020-08-13T19:41:58.000Z | 2022-03-30T12:22:51.000Z | Transynther/x86/_processed/NONE/_xt_/i3-7100_9_0x84_notsx.log_21829_522.asm | ljhsiun2/medusa | 67d769b8a2fb42c538f10287abaf0e6dbb463f0c | [
"MIT"
] | 1 | 2021-04-29T06:29:35.000Z | 2021-05-13T21:02:30.000Z | Transynther/x86/_processed/NONE/_xt_/i3-7100_9_0x84_notsx.log_21829_522.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:
ret
.global s_faulty_load
s_faulty_load:
push %r12
push %r13
push %r8
push %r9
push %rbp
push %rbx
push %rsi
// Store
mov $0x7ca, %rbp
cmp $48087, %r13
mov $0x5152535455565758, %rsi
movq %rsi, %xmm4
movups %xmm4, (%rbp)
nop
nop
cmp %rsi, %rsi
// Faulty Load
lea addresses_PSE+0x1ada1, %r9
nop
nop
nop
and $41992, %rbx
movups (%r9), %xmm4
vpextrq $1, %xmm4, %r8
lea oracles, %r12
and $0xff, %r8
shlq $12, %r8
mov (%r12,%r8,1), %r8
pop %rsi
pop %rbx
pop %rbp
pop %r9
pop %r8
pop %r13
pop %r12
ret
/*
<gen_faulty_load>
[REF]
{'src': {'type': 'addresses_PSE', 'same': False, 'size': 16, 'congruent': 0, 'NT': False, 'AVXalign': False}, 'OP': 'LOAD'}
{'dst': {'type': 'addresses_P', 'same': False, 'size': 16, 'congruent': 0, 'NT': False, 'AVXalign': False}, 'OP': 'STOR'}
[Faulty Load]
{'src': {'type': 'addresses_PSE', 'same': True, 'size': 16, 'congruent': 0, 'NT': False, 'AVXalign': False}, 'OP': 'LOAD'}
<gen_prepare_buffer>
{'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
*/
| 70.105263 | 2,999 | 0.660661 |
db872395685561094701e72ed9c471a9d5444356 | 604 | asm | Assembly | oeis/006/A006342.asm | neoneye/loda-programs | 84790877f8e6c2e821b183d2e334d612045d29c0 | [
"Apache-2.0"
] | 11 | 2021-08-22T19:44:55.000Z | 2022-03-20T16:47:57.000Z | oeis/006/A006342.asm | neoneye/loda-programs | 84790877f8e6c2e821b183d2e334d612045d29c0 | [
"Apache-2.0"
] | 9 | 2021-08-29T13:15:54.000Z | 2022-03-09T19:52:31.000Z | oeis/006/A006342.asm | neoneye/loda-programs | 84790877f8e6c2e821b183d2e334d612045d29c0 | [
"Apache-2.0"
] | 3 | 2021-08-22T20:56:47.000Z | 2021-09-29T06:26:12.000Z | ; A006342: Coloring a circuit with 4 colors.
; 1,1,4,10,31,91,274,820,2461,7381,22144,66430,199291,597871,1793614,5380840,16142521,48427561,145282684,435848050,1307544151,3922632451,11767897354,35303692060,105911076181,317733228541,953199685624,2859599056870,8578797170611,25736391511831,77209174535494,231627523606480,694882570819441,2084647712458321,6253943137374964,18761829412124890,56285488236374671,168856464709124011,506569394127372034,1519708182382116100,4559124547146348301,13677373641439044901,41032120924317134704,123096362772951404110
mov $1,3
pow $1,$0
div $1,8
mul $1,3
add $1,1
mov $0,$1
| 60.4 | 501 | 0.860927 |
4630028e1a6300ecd7c180b20f4fc90c9e78cac7 | 55 | asm | Assembly | Sistemi e reti/Assembly/add.asm | Gabri3445/EquazioneSecondoGrado | 63d64812e6bb0d2d3733a37537c11b425ebbff8f | [
"CC0-1.0"
] | null | null | null | Sistemi e reti/Assembly/add.asm | Gabri3445/EquazioneSecondoGrado | 63d64812e6bb0d2d3733a37537c11b425ebbff8f | [
"CC0-1.0"
] | null | null | null | Sistemi e reti/Assembly/add.asm | Gabri3445/EquazioneSecondoGrado | 63d64812e6bb0d2d3733a37537c11b425ebbff8f | [
"CC0-1.0"
] | null | null | null | LDA #2
LDB #4
ADD
STA 1337
LDB #6
ADD
STA 1338
OUT
HLT
| 5.5 | 8 | 0.690909 |
e73f861baf23061c4ac84a3fc653c8a160dde536 | 1,703 | asm | Assembly | Sim/tests/08_test_conditional_jump.asm | ericsims/16B | d0921ae55e2b830531dd7dd5e71ea1fd2bdb10bc | [
"MIT"
] | null | null | null | Sim/tests/08_test_conditional_jump.asm | ericsims/16B | d0921ae55e2b830531dd7dd5e71ea1fd2bdb10bc | [
"MIT"
] | null | null | null | Sim/tests/08_test_conditional_jump.asm | ericsims/16B | d0921ae55e2b830531dd7dd5e71ea1fd2bdb10bc | [
"MIT"
] | null | null | null | #include "../CPU.asm"
#bank rom
; tests jmz, jmc, jnz. does not test jnc, jmn, jnn
; ** jmz tests ***
; first test case
test1:
load a, #0xAA
assert a, #0xAA
add a, #0x00
; jump if zero. should evaluate to false
jmz .b
; assert a reg is still correct
assert a, #0xAA
; go to next test case
jmp test2
; if we jump here, we should error out
.b:
load a, #0x00
assert a, #0xBB;
; second test case
test2:
load a, #0x00
assert a, #0x00
add a, #0x00
; jump if zero. should evaluate to true
jmz .b
; we should error out if we end up here
assert a, #0xFF
halt
; jump here is correct
.b:
load a, #0xCC
assert a, #0xCC
; ** JMC tests ***
; third test case
test3:
load a, #0xAA
assert a, #0xAA
add a, #0x00
; jump if carry. should evaluate to false
jmc .b
; assert a reg is still correct
assert a, #0xAA
; go to next test case
jmp test4
; if we jump here, we should error out
.b:
load a, #0x00
assert a, #0xBB;
; fourth test case
test4:
load a, #0xFF
assert a, #0xFF
add a, #0x01
; jump if carry. should evaluate to true
jmc .b
; we should error out if we end up here
assert a, #0x12
halt
; jump here is correct
.b:
load a, #0xDD
assert a, #0xDD
; ** JNZ tests ***
; fifth test case
test5:
load a, #0x00
assert a, #0x00
add a, #0x00
; jump if not zero. should evaluate to false
jnz .b
; assert a reg is still correct
assert a, #0x00
; go to next test case
jmp test6
; if we jump here, we should error out
.b:
load a, #0x00
assert a, #0x05;
; sixth test case
test6:
load a, #0x01
assert a, #0x01
add a, #0x00
; jump if not zero. should evaluate to true
jnz .b
; we should error out if we end up here
assert a, #0x06
halt
; jump here is correct
.b:
load a, #0x06
assert a, #0x06
halt | 13.20155 | 50 | 0.672343 |
d192c27b1f4595c036cb716e5ff08c6513df543b | 3,852 | asm | Assembly | src/include.asm | ViGrey/iss-nes | 3ca87be0f7590893d0f6f9d8b5d5e77463de7792 | [
"Unlicense"
] | 23 | 2020-08-09T05:18:44.000Z | 2021-04-24T23:37:12.000Z | src/include.asm | ViGrey/iss-nes | 3ca87be0f7590893d0f6f9d8b5d5e77463de7792 | [
"Unlicense"
] | null | null | null | src/include.asm | ViGrey/iss-nes | 3ca87be0f7590893d0f6f9d8b5d5e77463de7792 | [
"Unlicense"
] | null | null | null | ; Copyright (C) 2020, Vi Grey
; All rights reserved.
;
; Redistribution and use in source and binary forms, with or without
; modification, are permitted provided that the following conditions
; are met:
;
; 1. Redistributions of source code must retain the above copyright
; notice, this list of conditions and the following disclaimer.
; 2. Redistributions in binary form must reproduce the above copyright
; notice, this list of conditions and the following disclaimer in the
; documentation and/or other materials provided with the distribution.
;
; THIS SOFTWARE IS PROVIDED BY AUTHOR AND CONTRIBUTORS ``AS IS'' AND
; ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
; IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
; ARE DISCLAIMED. IN NO EVENT SHALL AUTHOR OR CONTRIBUTORS BE LIABLE
; FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
; DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
; OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
; HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
; LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
; OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
; SUCH DAMAGE.
Palettes:
.byte $0F, $11, $2A, $30
.byte $0F, $11, $30, $30
.byte $0F, $0F, $0F, $30
.byte $0F, $0F, $0F, $30
.byte $0F, $2D, $2C, $30
.byte $0F, $0F, $0F, $0F
.byte $0F, $0F, $0F, $0F
.byte $0F, $0F, $0F, $0F
West:
.incbin "graphics/west.nam"
.incbin "graphics/west.atr"
East:
.incbin "graphics/east.nam"
.incbin "graphics/east.atr"
Months:
.byte $F3, $EB, $F6
.byte $F0, $EF, $EC
.byte $F5, $EB, $F9
.byte $EB, $F8, $F9
.byte $F5, $EB, $FF
.byte $F3, $FC, $F6
.byte $F3, $FC, $F4
.byte $EB, $FC, $F1
.byte $FA, $EF, $F8
.byte $F7, $ED, $FB
.byte $F6, $F7, $FD
.byte $EE, $EF, $ED
NorthSouth:
.byte $F6, $FA
EastWest:
.byte $EF, $FE
Latitudes:
.byte $28, $29, $2a, $2b, $2c, $2d, $2e, $2f, $30, $32, $33, $34, $35, $36, $37, $38, $39, $3a, $3b, $3c, $3d, $3e, $3f, $40, $41, $43, $44, $45, $46, $47, $48, $49, $4a, $4b, $4c, $4d, $4e, $4f, $50, $51, $52, $53, $55, $56, $57, $58, $59, $5a, $5b, $5c, $5d, $5e, $5f, $60, $61, $62, $63, $64, $66, $67, $68, $69, $6a, $6b, $6c, $6d, $6e, $6f, $70, $71, $72, $73, $74, $75, $76, $78, $79, $7a, $7b, $7c, $7d, $7e, $7f, $80, $81, $82, $83, $84, $85, $86, $87, $89, $8a, $8b, $8c, $8d, $8e, $8f, $90, $91, $92, $93, $94, $95, $96, $97, $98, $9a, $9b, $9c, $9d, $9e, $9f, $a0, $a1, $a2, $a3, $a4, $a5, $a6, $a7, $a8, $a9, $aa, $ac, $ad, $ae, $af, $b0, $b1, $b2, $b3, $b4, $b5, $b6, $b7, $b8, $b9, $ba, $bb, $bd, $be, $bf, $c0, $c1, $c2, $c3, $c4, $c5, $c6, $c7, $c8, $c9, $ca, $cb, $cc, $cd, $cf, $d0, $d1, $d2, $d3, $d4, $d5, $d6, $d7, $d8, $d9, $da, $db, $dc, $dd, $de, $e0, $e1, $e2, $e3, $e4, $e5, $e6, $e7
Longitudes:
.byte $00, $01, $03, $04, $06, $07, $09, $0a, $0b, $0d, $0e, $10, $11, $12, $14, $15, $17, $18, $1a, $1b, $1c, $1e, $1f, $21, $22, $24, $25, $26, $28, $29, $2b, $2c, $2e, $2f, $30, $32, $33, $35, $36, $37, $39, $3a, $3c, $3d, $3f, $40, $41, $43, $44, $46, $47, $49, $4a, $4b, $4d, $4e, $50, $51, $52, $54, $55, $57, $58, $5a, $5b, $5c, $5e, $5f, $61, $62, $64, $65, $66, $68, $69, $6b, $6c, $6e, $6f, $70, $72, $73, $75, $76, $77, $79, $7a, $7c, $7d, $7f, $80, $81, $83, $84, $86, $87, $89, $8a, $8b, $8d, $8e, $90, $91, $92, $94, $95, $97, $98, $9a, $9b, $9c, $9e, $9f, $a1, $a2, $a4, $a5, $a6, $a8, $a9, $ab, $ac, $ae, $af, $b0, $b2, $b3, $b5, $b6, $b7, $b9, $ba, $bc, $bd, $bf, $c0, $c1, $c3, $c4, $c6, $c7, $c9, $ca, $cb, $cd, $ce, $d0, $d1, $d2, $d4, $d5, $d7, $d8, $da, $db, $dc, $de, $df, $e1, $e2, $e4, $e5, $e6, $e8, $e9, $eb, $ec, $ee, $ef, $f0, $f2, $f3, $f5, $f6, $f7, $f9, $fa, $fc, $fd, $ff, $ff
| 56.647059 | 911 | 0.553219 |
32a0221690ebc9c04eda2eba4666491cb7e6d495 | 1,446 | asm | Assembly | src/firmware-tests/Platform/Motor/EnableDisable/IsEnabledTest.asm | pete-restall/Cluck2Sesame-Prototype | 99119b6748847a7b6aeadc4bee42cbed726f7fdc | [
"MIT"
] | 1 | 2019-12-12T09:07:08.000Z | 2019-12-12T09:07:08.000Z | src/firmware-tests/Platform/Motor/EnableDisable/IsEnabledTest.asm | pete-restall/Cluck2Sesame-Prototype | 99119b6748847a7b6aeadc4bee42cbed726f7fdc | [
"MIT"
] | null | null | null | src/firmware-tests/Platform/Motor/EnableDisable/IsEnabledTest.asm | pete-restall/Cluck2Sesame-Prototype | 99119b6748847a7b6aeadc4bee42cbed726f7fdc | [
"MIT"
] | null | null | null | #include "Platform.inc"
#include "FarCalls.inc"
#include "Motor.inc"
#include "../../Smps/IsSmpsEnabledStub.inc"
#include "TestFixture.inc"
radix decimal
udata
global stubIsSmpsEnabled
global numberOfEnableCalls
global numberOfDisableCalls
global expectedIsMotorVddEnabled
stubIsSmpsEnabled res 1
numberOfEnableCalls res 1
numberOfDisableCalls res 1
expectedIsMotorVddEnabled res 1
IsEnabledTest code
global testArrange
testArrange:
banksel stubIsSmpsEnabled
movf stubIsSmpsEnabled, W
fcall initialiseIsSmpsEnabledStub
fcall initialiseMotor
testAct:
banksel numberOfEnableCalls
movf numberOfEnableCalls
btfsc STATUS, Z
goto callDisableMotorVdd
callEnableMotorVdd:
fcall enableMotorVdd
banksel numberOfEnableCalls
decfsz numberOfEnableCalls
goto testAct
callDisableMotorVdd:
banksel numberOfDisableCalls
movf numberOfDisableCalls
btfsc STATUS, Z
goto callIsMotorVddEnabled
callDisableMotorVddInLoop:
fcall disableMotorVdd
banksel numberOfDisableCalls
decfsz numberOfDisableCalls
goto callDisableMotorVddInLoop
callIsMotorVddEnabled:
fcall isMotorVddEnabled
testAssert:
banksel expectedIsMotorVddEnabled
movf expectedIsMotorVddEnabled
btfss STATUS, Z
goto testAssertForMotorVddEnabled
testAssertForMotorVddDisabled:
.assert "W == 0, 'Expected that isMotorVddEnabled() is false.'"
return
testAssertForMotorVddEnabled:
.assert "W != 0, 'Expected that isMotorVddEnabled() is true.'"
return
end
| 20.083333 | 64 | 0.834025 |
fc333cffde8e77667d9d8b603f4d004d3c98de1e | 789 | asm | Assembly | oeis/192/A192921.asm | neoneye/loda-programs | 84790877f8e6c2e821b183d2e334d612045d29c0 | [
"Apache-2.0"
] | 11 | 2021-08-22T19:44:55.000Z | 2022-03-20T16:47:57.000Z | oeis/192/A192921.asm | neoneye/loda-programs | 84790877f8e6c2e821b183d2e334d612045d29c0 | [
"Apache-2.0"
] | 9 | 2021-08-29T13:15:54.000Z | 2022-03-09T19:52:31.000Z | oeis/192/A192921.asm | neoneye/loda-programs | 84790877f8e6c2e821b183d2e334d612045d29c0 | [
"Apache-2.0"
] | 3 | 2021-08-22T20:56:47.000Z | 2021-09-29T06:26:12.000Z | ; A192921: Constant term in the reduction by (x^2->x+1) of the polynomial p(n,x) defined below at Comments.
; Submitted by Jamie Morken(s2)
; 1,2,2,7,16,44,113,298,778,2039,5336,13972,36577,95762,250706,656359,1718368,4498748,11777873,30834874,80726746,211345367,553309352,1448582692,3792438721,9928733474,25993761698,68052551623,178163893168,466439127884,1221153490481,3197021343562,8369910540202,21912710277047,57368220290936,150191950595764,393207631496353,1029430943893298,2695085200183538,7055824656657319,18472388769788416,48361341652707932,126611636188335377,331473566912298202,867809064548559226,2271953626733379479
mov $1,2
mov $3,2
lpb $0
sub $0,1
mov $2,$4
mov $4,$1
mov $1,$3
add $1,$2
sub $1,3
sub $4,1
add $3,$4
add $1,$3
add $3,1
lpe
mov $0,$4
add $0,1
| 37.571429 | 483 | 0.780735 |
97a822b2082e65a9178b89157477c359fdbcd4ca | 1,700 | asm | Assembly | programs/oeis/173/A173308.asm | karttu/loda | 9c3b0fc57b810302220c044a9d17db733c76a598 | [
"Apache-2.0"
] | 1 | 2021-03-15T11:38:20.000Z | 2021-03-15T11:38:20.000Z | programs/oeis/173/A173308.asm | karttu/loda | 9c3b0fc57b810302220c044a9d17db733c76a598 | [
"Apache-2.0"
] | null | null | null | programs/oeis/173/A173308.asm | karttu/loda | 9c3b0fc57b810302220c044a9d17db733c76a598 | [
"Apache-2.0"
] | null | null | null | ; A173308: 17*n*(n+1).
; 0,34,102,204,340,510,714,952,1224,1530,1870,2244,2652,3094,3570,4080,4624,5202,5814,6460,7140,7854,8602,9384,10200,11050,11934,12852,13804,14790,15810,16864,17952,19074,20230,21420,22644,23902,25194,26520,27880,29274,30702,32164,33660,35190,36754,38352,39984,41650,43350,45084,46852,48654,50490,52360,54264,56202,58174,60180,62220,64294,66402,68544,70720,72930,75174,77452,79764,82110,84490,86904,89352,91834,94350,96900,99484,102102,104754,107440,110160,112914,115702,118524,121380,124270,127194,130152,133144,136170,139230,142324,145452,148614,151810,155040,158304,161602,164934,168300,171700,175134,178602,182104,185640,189210,192814,196452,200124,203830,207570,211344,215152,218994,222870,226780,230724,234702,238714,242760,246840,250954,255102,259284,263500,267750,272034,276352,280704,285090,289510,293964,298452,302974,307530,312120,316744,321402,326094,330820,335580,340374,345202,350064,354960,359890,364854,369852,374884,379950,385050,390184,395352,400554,405790,411060,416364,421702,427074,432480,437920,443394,448902,454444,460020,465630,471274,476952,482664,488410,494190,500004,505852,511734,517650,523600,529584,535602,541654,547740,553860,560014,566202,572424,578680,584970,591294,597652,604044,610470,616930,623424,629952,636514,643110,649740,656404,663102,669834,676600,683400,690234,697102,704004,710940,717910,724914,731952,739024,746130,753270,760444,767652,774894,782170,789480,796824,804202,811614,819060,826540,834054,841602,849184,856800,864450,872134,879852,887604,895390,903210,911064,918952,926874,934830,942820,950844,958902,966994,975120,983280,991474,999702,1007964,1016260,1024590,1032954,1041352,1049784,1058250
sub $1,$0
bin $1,2
mul $1,34
| 242.857143 | 1,646 | 0.837059 |
311d7a34f2c71c9628671b6a9ca300e12be37552 | 23,349 | asm | Assembly | jsrc/openssl/sha/asm/sha1-586-nasm.asm | jsoftware/j-playground | fec7be5a9dc92d45c7326556b6058e63fb4f979a | [
"MIT"
] | 4 | 2022-01-19T04:23:49.000Z | 2022-03-28T18:55:38.000Z | jsrc/openssl/sha/asm/sha1-586-nasm.asm | jsoftware/j-playground | fec7be5a9dc92d45c7326556b6058e63fb4f979a | [
"MIT"
] | 15 | 2022-02-28T13:09:29.000Z | 2022-03-11T01:15:39.000Z | jsrc/openssl/sha/asm/sha1-586-nasm.asm | jsoftware/j-playground | fec7be5a9dc92d45c7326556b6058e63fb4f979a | [
"MIT"
] | 2 | 2022-01-29T13:26:27.000Z | 2022-02-23T02:43:31.000Z | %ifidn __OUTPUT_FORMAT__,obj
section code use32 class=code align=64
; %elifidn __OUTPUT_FORMAT__,win32
$@feat.00 equ 1
section .text code align=64
%else
section .text code
%endif
global _sha1_block_data_order
align 16
_sha1_block_data_order:
L$_sha1_block_data_order_begin:
push ebp
push ebx
push esi
push edi
mov ebp,DWORD [20+esp]
mov esi,DWORD [24+esp]
mov eax,DWORD [28+esp]
sub esp,76
shl eax,6
add eax,esi
mov DWORD [104+esp],eax
mov edi,DWORD [16+ebp]
jmp NEAR L$000loop
align 16
L$000loop:
mov eax,DWORD [esi]
mov ebx,DWORD [4+esi]
mov ecx,DWORD [8+esi]
mov edx,DWORD [12+esi]
bswap eax
bswap ebx
bswap ecx
bswap edx
mov DWORD [esp],eax
mov DWORD [4+esp],ebx
mov DWORD [8+esp],ecx
mov DWORD [12+esp],edx
mov eax,DWORD [16+esi]
mov ebx,DWORD [20+esi]
mov ecx,DWORD [24+esi]
mov edx,DWORD [28+esi]
bswap eax
bswap ebx
bswap ecx
bswap edx
mov DWORD [16+esp],eax
mov DWORD [20+esp],ebx
mov DWORD [24+esp],ecx
mov DWORD [28+esp],edx
mov eax,DWORD [32+esi]
mov ebx,DWORD [36+esi]
mov ecx,DWORD [40+esi]
mov edx,DWORD [44+esi]
bswap eax
bswap ebx
bswap ecx
bswap edx
mov DWORD [32+esp],eax
mov DWORD [36+esp],ebx
mov DWORD [40+esp],ecx
mov DWORD [44+esp],edx
mov eax,DWORD [48+esi]
mov ebx,DWORD [52+esi]
mov ecx,DWORD [56+esi]
mov edx,DWORD [60+esi]
bswap eax
bswap ebx
bswap ecx
bswap edx
mov DWORD [48+esp],eax
mov DWORD [52+esp],ebx
mov DWORD [56+esp],ecx
mov DWORD [60+esp],edx
mov DWORD [100+esp],esi
mov eax,DWORD [ebp]
mov ebx,DWORD [4+ebp]
mov ecx,DWORD [8+ebp]
mov edx,DWORD [12+ebp]
; 00_15 0
mov esi,ecx
mov ebp,eax
rol ebp,5
xor esi,edx
add ebp,edi
mov edi,DWORD [esp]
and esi,ebx
ror ebx,2
xor esi,edx
lea ebp,[1518500249+edi*1+ebp]
add ebp,esi
; 00_15 1
mov edi,ebx
mov esi,ebp
rol ebp,5
xor edi,ecx
add ebp,edx
mov edx,DWORD [4+esp]
and edi,eax
ror eax,2
xor edi,ecx
lea ebp,[1518500249+edx*1+ebp]
add ebp,edi
; 00_15 2
mov edx,eax
mov edi,ebp
rol ebp,5
xor edx,ebx
add ebp,ecx
mov ecx,DWORD [8+esp]
and edx,esi
ror esi,2
xor edx,ebx
lea ebp,[1518500249+ecx*1+ebp]
add ebp,edx
; 00_15 3
mov ecx,esi
mov edx,ebp
rol ebp,5
xor ecx,eax
add ebp,ebx
mov ebx,DWORD [12+esp]
and ecx,edi
ror edi,2
xor ecx,eax
lea ebp,[1518500249+ebx*1+ebp]
add ebp,ecx
; 00_15 4
mov ebx,edi
mov ecx,ebp
rol ebp,5
xor ebx,esi
add ebp,eax
mov eax,DWORD [16+esp]
and ebx,edx
ror edx,2
xor ebx,esi
lea ebp,[1518500249+eax*1+ebp]
add ebp,ebx
; 00_15 5
mov eax,edx
mov ebx,ebp
rol ebp,5
xor eax,edi
add ebp,esi
mov esi,DWORD [20+esp]
and eax,ecx
ror ecx,2
xor eax,edi
lea ebp,[1518500249+esi*1+ebp]
add ebp,eax
; 00_15 6
mov esi,ecx
mov eax,ebp
rol ebp,5
xor esi,edx
add ebp,edi
mov edi,DWORD [24+esp]
and esi,ebx
ror ebx,2
xor esi,edx
lea ebp,[1518500249+edi*1+ebp]
add ebp,esi
; 00_15 7
mov edi,ebx
mov esi,ebp
rol ebp,5
xor edi,ecx
add ebp,edx
mov edx,DWORD [28+esp]
and edi,eax
ror eax,2
xor edi,ecx
lea ebp,[1518500249+edx*1+ebp]
add ebp,edi
; 00_15 8
mov edx,eax
mov edi,ebp
rol ebp,5
xor edx,ebx
add ebp,ecx
mov ecx,DWORD [32+esp]
and edx,esi
ror esi,2
xor edx,ebx
lea ebp,[1518500249+ecx*1+ebp]
add ebp,edx
; 00_15 9
mov ecx,esi
mov edx,ebp
rol ebp,5
xor ecx,eax
add ebp,ebx
mov ebx,DWORD [36+esp]
and ecx,edi
ror edi,2
xor ecx,eax
lea ebp,[1518500249+ebx*1+ebp]
add ebp,ecx
; 00_15 10
mov ebx,edi
mov ecx,ebp
rol ebp,5
xor ebx,esi
add ebp,eax
mov eax,DWORD [40+esp]
and ebx,edx
ror edx,2
xor ebx,esi
lea ebp,[1518500249+eax*1+ebp]
add ebp,ebx
; 00_15 11
mov eax,edx
mov ebx,ebp
rol ebp,5
xor eax,edi
add ebp,esi
mov esi,DWORD [44+esp]
and eax,ecx
ror ecx,2
xor eax,edi
lea ebp,[1518500249+esi*1+ebp]
add ebp,eax
; 00_15 12
mov esi,ecx
mov eax,ebp
rol ebp,5
xor esi,edx
add ebp,edi
mov edi,DWORD [48+esp]
and esi,ebx
ror ebx,2
xor esi,edx
lea ebp,[1518500249+edi*1+ebp]
add ebp,esi
; 00_15 13
mov edi,ebx
mov esi,ebp
rol ebp,5
xor edi,ecx
add ebp,edx
mov edx,DWORD [52+esp]
and edi,eax
ror eax,2
xor edi,ecx
lea ebp,[1518500249+edx*1+ebp]
add ebp,edi
; 00_15 14
mov edx,eax
mov edi,ebp
rol ebp,5
xor edx,ebx
add ebp,ecx
mov ecx,DWORD [56+esp]
and edx,esi
ror esi,2
xor edx,ebx
lea ebp,[1518500249+ecx*1+ebp]
add ebp,edx
; 00_15 15
mov ecx,esi
mov edx,ebp
rol ebp,5
xor ecx,eax
add ebp,ebx
mov ebx,DWORD [60+esp]
and ecx,edi
ror edi,2
xor ecx,eax
lea ebp,[1518500249+ebx*1+ebp]
mov ebx,DWORD [esp]
add ecx,ebp
; 16_19 16
mov ebp,edi
xor ebx,DWORD [8+esp]
xor ebp,esi
xor ebx,DWORD [32+esp]
and ebp,edx
xor ebx,DWORD [52+esp]
rol ebx,1
xor ebp,esi
add eax,ebp
mov ebp,ecx
ror edx,2
mov DWORD [esp],ebx
rol ebp,5
lea ebx,[1518500249+eax*1+ebx]
mov eax,DWORD [4+esp]
add ebx,ebp
; 16_19 17
mov ebp,edx
xor eax,DWORD [12+esp]
xor ebp,edi
xor eax,DWORD [36+esp]
and ebp,ecx
xor eax,DWORD [56+esp]
rol eax,1
xor ebp,edi
add esi,ebp
mov ebp,ebx
ror ecx,2
mov DWORD [4+esp],eax
rol ebp,5
lea eax,[1518500249+esi*1+eax]
mov esi,DWORD [8+esp]
add eax,ebp
; 16_19 18
mov ebp,ecx
xor esi,DWORD [16+esp]
xor ebp,edx
xor esi,DWORD [40+esp]
and ebp,ebx
xor esi,DWORD [60+esp]
rol esi,1
xor ebp,edx
add edi,ebp
mov ebp,eax
ror ebx,2
mov DWORD [8+esp],esi
rol ebp,5
lea esi,[1518500249+edi*1+esi]
mov edi,DWORD [12+esp]
add esi,ebp
; 16_19 19
mov ebp,ebx
xor edi,DWORD [20+esp]
xor ebp,ecx
xor edi,DWORD [44+esp]
and ebp,eax
xor edi,DWORD [esp]
rol edi,1
xor ebp,ecx
add edx,ebp
mov ebp,esi
ror eax,2
mov DWORD [12+esp],edi
rol ebp,5
lea edi,[1518500249+edx*1+edi]
mov edx,DWORD [16+esp]
add edi,ebp
; 20_39 20
mov ebp,esi
xor edx,DWORD [24+esp]
xor ebp,eax
xor edx,DWORD [48+esp]
xor ebp,ebx
xor edx,DWORD [4+esp]
rol edx,1
add ecx,ebp
ror esi,2
mov ebp,edi
rol ebp,5
mov DWORD [16+esp],edx
lea edx,[1859775393+ecx*1+edx]
mov ecx,DWORD [20+esp]
add edx,ebp
; 20_39 21
mov ebp,edi
xor ecx,DWORD [28+esp]
xor ebp,esi
xor ecx,DWORD [52+esp]
xor ebp,eax
xor ecx,DWORD [8+esp]
rol ecx,1
add ebx,ebp
ror edi,2
mov ebp,edx
rol ebp,5
mov DWORD [20+esp],ecx
lea ecx,[1859775393+ebx*1+ecx]
mov ebx,DWORD [24+esp]
add ecx,ebp
; 20_39 22
mov ebp,edx
xor ebx,DWORD [32+esp]
xor ebp,edi
xor ebx,DWORD [56+esp]
xor ebp,esi
xor ebx,DWORD [12+esp]
rol ebx,1
add eax,ebp
ror edx,2
mov ebp,ecx
rol ebp,5
mov DWORD [24+esp],ebx
lea ebx,[1859775393+eax*1+ebx]
mov eax,DWORD [28+esp]
add ebx,ebp
; 20_39 23
mov ebp,ecx
xor eax,DWORD [36+esp]
xor ebp,edx
xor eax,DWORD [60+esp]
xor ebp,edi
xor eax,DWORD [16+esp]
rol eax,1
add esi,ebp
ror ecx,2
mov ebp,ebx
rol ebp,5
mov DWORD [28+esp],eax
lea eax,[1859775393+esi*1+eax]
mov esi,DWORD [32+esp]
add eax,ebp
; 20_39 24
mov ebp,ebx
xor esi,DWORD [40+esp]
xor ebp,ecx
xor esi,DWORD [esp]
xor ebp,edx
xor esi,DWORD [20+esp]
rol esi,1
add edi,ebp
ror ebx,2
mov ebp,eax
rol ebp,5
mov DWORD [32+esp],esi
lea esi,[1859775393+edi*1+esi]
mov edi,DWORD [36+esp]
add esi,ebp
; 20_39 25
mov ebp,eax
xor edi,DWORD [44+esp]
xor ebp,ebx
xor edi,DWORD [4+esp]
xor ebp,ecx
xor edi,DWORD [24+esp]
rol edi,1
add edx,ebp
ror eax,2
mov ebp,esi
rol ebp,5
mov DWORD [36+esp],edi
lea edi,[1859775393+edx*1+edi]
mov edx,DWORD [40+esp]
add edi,ebp
; 20_39 26
mov ebp,esi
xor edx,DWORD [48+esp]
xor ebp,eax
xor edx,DWORD [8+esp]
xor ebp,ebx
xor edx,DWORD [28+esp]
rol edx,1
add ecx,ebp
ror esi,2
mov ebp,edi
rol ebp,5
mov DWORD [40+esp],edx
lea edx,[1859775393+ecx*1+edx]
mov ecx,DWORD [44+esp]
add edx,ebp
; 20_39 27
mov ebp,edi
xor ecx,DWORD [52+esp]
xor ebp,esi
xor ecx,DWORD [12+esp]
xor ebp,eax
xor ecx,DWORD [32+esp]
rol ecx,1
add ebx,ebp
ror edi,2
mov ebp,edx
rol ebp,5
mov DWORD [44+esp],ecx
lea ecx,[1859775393+ebx*1+ecx]
mov ebx,DWORD [48+esp]
add ecx,ebp
; 20_39 28
mov ebp,edx
xor ebx,DWORD [56+esp]
xor ebp,edi
xor ebx,DWORD [16+esp]
xor ebp,esi
xor ebx,DWORD [36+esp]
rol ebx,1
add eax,ebp
ror edx,2
mov ebp,ecx
rol ebp,5
mov DWORD [48+esp],ebx
lea ebx,[1859775393+eax*1+ebx]
mov eax,DWORD [52+esp]
add ebx,ebp
; 20_39 29
mov ebp,ecx
xor eax,DWORD [60+esp]
xor ebp,edx
xor eax,DWORD [20+esp]
xor ebp,edi
xor eax,DWORD [40+esp]
rol eax,1
add esi,ebp
ror ecx,2
mov ebp,ebx
rol ebp,5
mov DWORD [52+esp],eax
lea eax,[1859775393+esi*1+eax]
mov esi,DWORD [56+esp]
add eax,ebp
; 20_39 30
mov ebp,ebx
xor esi,DWORD [esp]
xor ebp,ecx
xor esi,DWORD [24+esp]
xor ebp,edx
xor esi,DWORD [44+esp]
rol esi,1
add edi,ebp
ror ebx,2
mov ebp,eax
rol ebp,5
mov DWORD [56+esp],esi
lea esi,[1859775393+edi*1+esi]
mov edi,DWORD [60+esp]
add esi,ebp
; 20_39 31
mov ebp,eax
xor edi,DWORD [4+esp]
xor ebp,ebx
xor edi,DWORD [28+esp]
xor ebp,ecx
xor edi,DWORD [48+esp]
rol edi,1
add edx,ebp
ror eax,2
mov ebp,esi
rol ebp,5
mov DWORD [60+esp],edi
lea edi,[1859775393+edx*1+edi]
mov edx,DWORD [esp]
add edi,ebp
; 20_39 32
mov ebp,esi
xor edx,DWORD [8+esp]
xor ebp,eax
xor edx,DWORD [32+esp]
xor ebp,ebx
xor edx,DWORD [52+esp]
rol edx,1
add ecx,ebp
ror esi,2
mov ebp,edi
rol ebp,5
mov DWORD [esp],edx
lea edx,[1859775393+ecx*1+edx]
mov ecx,DWORD [4+esp]
add edx,ebp
; 20_39 33
mov ebp,edi
xor ecx,DWORD [12+esp]
xor ebp,esi
xor ecx,DWORD [36+esp]
xor ebp,eax
xor ecx,DWORD [56+esp]
rol ecx,1
add ebx,ebp
ror edi,2
mov ebp,edx
rol ebp,5
mov DWORD [4+esp],ecx
lea ecx,[1859775393+ebx*1+ecx]
mov ebx,DWORD [8+esp]
add ecx,ebp
; 20_39 34
mov ebp,edx
xor ebx,DWORD [16+esp]
xor ebp,edi
xor ebx,DWORD [40+esp]
xor ebp,esi
xor ebx,DWORD [60+esp]
rol ebx,1
add eax,ebp
ror edx,2
mov ebp,ecx
rol ebp,5
mov DWORD [8+esp],ebx
lea ebx,[1859775393+eax*1+ebx]
mov eax,DWORD [12+esp]
add ebx,ebp
; 20_39 35
mov ebp,ecx
xor eax,DWORD [20+esp]
xor ebp,edx
xor eax,DWORD [44+esp]
xor ebp,edi
xor eax,DWORD [esp]
rol eax,1
add esi,ebp
ror ecx,2
mov ebp,ebx
rol ebp,5
mov DWORD [12+esp],eax
lea eax,[1859775393+esi*1+eax]
mov esi,DWORD [16+esp]
add eax,ebp
; 20_39 36
mov ebp,ebx
xor esi,DWORD [24+esp]
xor ebp,ecx
xor esi,DWORD [48+esp]
xor ebp,edx
xor esi,DWORD [4+esp]
rol esi,1
add edi,ebp
ror ebx,2
mov ebp,eax
rol ebp,5
mov DWORD [16+esp],esi
lea esi,[1859775393+edi*1+esi]
mov edi,DWORD [20+esp]
add esi,ebp
; 20_39 37
mov ebp,eax
xor edi,DWORD [28+esp]
xor ebp,ebx
xor edi,DWORD [52+esp]
xor ebp,ecx
xor edi,DWORD [8+esp]
rol edi,1
add edx,ebp
ror eax,2
mov ebp,esi
rol ebp,5
mov DWORD [20+esp],edi
lea edi,[1859775393+edx*1+edi]
mov edx,DWORD [24+esp]
add edi,ebp
; 20_39 38
mov ebp,esi
xor edx,DWORD [32+esp]
xor ebp,eax
xor edx,DWORD [56+esp]
xor ebp,ebx
xor edx,DWORD [12+esp]
rol edx,1
add ecx,ebp
ror esi,2
mov ebp,edi
rol ebp,5
mov DWORD [24+esp],edx
lea edx,[1859775393+ecx*1+edx]
mov ecx,DWORD [28+esp]
add edx,ebp
; 20_39 39
mov ebp,edi
xor ecx,DWORD [36+esp]
xor ebp,esi
xor ecx,DWORD [60+esp]
xor ebp,eax
xor ecx,DWORD [16+esp]
rol ecx,1
add ebx,ebp
ror edi,2
mov ebp,edx
rol ebp,5
mov DWORD [28+esp],ecx
lea ecx,[1859775393+ebx*1+ecx]
mov ebx,DWORD [32+esp]
add ecx,ebp
; 40_59 40
mov ebp,edi
xor ebx,DWORD [40+esp]
xor ebp,esi
xor ebx,DWORD [esp]
and ebp,edx
xor ebx,DWORD [20+esp]
rol ebx,1
add ebp,eax
ror edx,2
mov eax,ecx
rol eax,5
mov DWORD [32+esp],ebx
lea ebx,[2400959708+ebp*1+ebx]
mov ebp,edi
add ebx,eax
and ebp,esi
mov eax,DWORD [36+esp]
add ebx,ebp
; 40_59 41
mov ebp,edx
xor eax,DWORD [44+esp]
xor ebp,edi
xor eax,DWORD [4+esp]
and ebp,ecx
xor eax,DWORD [24+esp]
rol eax,1
add ebp,esi
ror ecx,2
mov esi,ebx
rol esi,5
mov DWORD [36+esp],eax
lea eax,[2400959708+ebp*1+eax]
mov ebp,edx
add eax,esi
and ebp,edi
mov esi,DWORD [40+esp]
add eax,ebp
; 40_59 42
mov ebp,ecx
xor esi,DWORD [48+esp]
xor ebp,edx
xor esi,DWORD [8+esp]
and ebp,ebx
xor esi,DWORD [28+esp]
rol esi,1
add ebp,edi
ror ebx,2
mov edi,eax
rol edi,5
mov DWORD [40+esp],esi
lea esi,[2400959708+ebp*1+esi]
mov ebp,ecx
add esi,edi
and ebp,edx
mov edi,DWORD [44+esp]
add esi,ebp
; 40_59 43
mov ebp,ebx
xor edi,DWORD [52+esp]
xor ebp,ecx
xor edi,DWORD [12+esp]
and ebp,eax
xor edi,DWORD [32+esp]
rol edi,1
add ebp,edx
ror eax,2
mov edx,esi
rol edx,5
mov DWORD [44+esp],edi
lea edi,[2400959708+ebp*1+edi]
mov ebp,ebx
add edi,edx
and ebp,ecx
mov edx,DWORD [48+esp]
add edi,ebp
; 40_59 44
mov ebp,eax
xor edx,DWORD [56+esp]
xor ebp,ebx
xor edx,DWORD [16+esp]
and ebp,esi
xor edx,DWORD [36+esp]
rol edx,1
add ebp,ecx
ror esi,2
mov ecx,edi
rol ecx,5
mov DWORD [48+esp],edx
lea edx,[2400959708+ebp*1+edx]
mov ebp,eax
add edx,ecx
and ebp,ebx
mov ecx,DWORD [52+esp]
add edx,ebp
; 40_59 45
mov ebp,esi
xor ecx,DWORD [60+esp]
xor ebp,eax
xor ecx,DWORD [20+esp]
and ebp,edi
xor ecx,DWORD [40+esp]
rol ecx,1
add ebp,ebx
ror edi,2
mov ebx,edx
rol ebx,5
mov DWORD [52+esp],ecx
lea ecx,[2400959708+ebp*1+ecx]
mov ebp,esi
add ecx,ebx
and ebp,eax
mov ebx,DWORD [56+esp]
add ecx,ebp
; 40_59 46
mov ebp,edi
xor ebx,DWORD [esp]
xor ebp,esi
xor ebx,DWORD [24+esp]
and ebp,edx
xor ebx,DWORD [44+esp]
rol ebx,1
add ebp,eax
ror edx,2
mov eax,ecx
rol eax,5
mov DWORD [56+esp],ebx
lea ebx,[2400959708+ebp*1+ebx]
mov ebp,edi
add ebx,eax
and ebp,esi
mov eax,DWORD [60+esp]
add ebx,ebp
; 40_59 47
mov ebp,edx
xor eax,DWORD [4+esp]
xor ebp,edi
xor eax,DWORD [28+esp]
and ebp,ecx
xor eax,DWORD [48+esp]
rol eax,1
add ebp,esi
ror ecx,2
mov esi,ebx
rol esi,5
mov DWORD [60+esp],eax
lea eax,[2400959708+ebp*1+eax]
mov ebp,edx
add eax,esi
and ebp,edi
mov esi,DWORD [esp]
add eax,ebp
; 40_59 48
mov ebp,ecx
xor esi,DWORD [8+esp]
xor ebp,edx
xor esi,DWORD [32+esp]
and ebp,ebx
xor esi,DWORD [52+esp]
rol esi,1
add ebp,edi
ror ebx,2
mov edi,eax
rol edi,5
mov DWORD [esp],esi
lea esi,[2400959708+ebp*1+esi]
mov ebp,ecx
add esi,edi
and ebp,edx
mov edi,DWORD [4+esp]
add esi,ebp
; 40_59 49
mov ebp,ebx
xor edi,DWORD [12+esp]
xor ebp,ecx
xor edi,DWORD [36+esp]
and ebp,eax
xor edi,DWORD [56+esp]
rol edi,1
add ebp,edx
ror eax,2
mov edx,esi
rol edx,5
mov DWORD [4+esp],edi
lea edi,[2400959708+ebp*1+edi]
mov ebp,ebx
add edi,edx
and ebp,ecx
mov edx,DWORD [8+esp]
add edi,ebp
; 40_59 50
mov ebp,eax
xor edx,DWORD [16+esp]
xor ebp,ebx
xor edx,DWORD [40+esp]
and ebp,esi
xor edx,DWORD [60+esp]
rol edx,1
add ebp,ecx
ror esi,2
mov ecx,edi
rol ecx,5
mov DWORD [8+esp],edx
lea edx,[2400959708+ebp*1+edx]
mov ebp,eax
add edx,ecx
and ebp,ebx
mov ecx,DWORD [12+esp]
add edx,ebp
; 40_59 51
mov ebp,esi
xor ecx,DWORD [20+esp]
xor ebp,eax
xor ecx,DWORD [44+esp]
and ebp,edi
xor ecx,DWORD [esp]
rol ecx,1
add ebp,ebx
ror edi,2
mov ebx,edx
rol ebx,5
mov DWORD [12+esp],ecx
lea ecx,[2400959708+ebp*1+ecx]
mov ebp,esi
add ecx,ebx
and ebp,eax
mov ebx,DWORD [16+esp]
add ecx,ebp
; 40_59 52
mov ebp,edi
xor ebx,DWORD [24+esp]
xor ebp,esi
xor ebx,DWORD [48+esp]
and ebp,edx
xor ebx,DWORD [4+esp]
rol ebx,1
add ebp,eax
ror edx,2
mov eax,ecx
rol eax,5
mov DWORD [16+esp],ebx
lea ebx,[2400959708+ebp*1+ebx]
mov ebp,edi
add ebx,eax
and ebp,esi
mov eax,DWORD [20+esp]
add ebx,ebp
; 40_59 53
mov ebp,edx
xor eax,DWORD [28+esp]
xor ebp,edi
xor eax,DWORD [52+esp]
and ebp,ecx
xor eax,DWORD [8+esp]
rol eax,1
add ebp,esi
ror ecx,2
mov esi,ebx
rol esi,5
mov DWORD [20+esp],eax
lea eax,[2400959708+ebp*1+eax]
mov ebp,edx
add eax,esi
and ebp,edi
mov esi,DWORD [24+esp]
add eax,ebp
; 40_59 54
mov ebp,ecx
xor esi,DWORD [32+esp]
xor ebp,edx
xor esi,DWORD [56+esp]
and ebp,ebx
xor esi,DWORD [12+esp]
rol esi,1
add ebp,edi
ror ebx,2
mov edi,eax
rol edi,5
mov DWORD [24+esp],esi
lea esi,[2400959708+ebp*1+esi]
mov ebp,ecx
add esi,edi
and ebp,edx
mov edi,DWORD [28+esp]
add esi,ebp
; 40_59 55
mov ebp,ebx
xor edi,DWORD [36+esp]
xor ebp,ecx
xor edi,DWORD [60+esp]
and ebp,eax
xor edi,DWORD [16+esp]
rol edi,1
add ebp,edx
ror eax,2
mov edx,esi
rol edx,5
mov DWORD [28+esp],edi
lea edi,[2400959708+ebp*1+edi]
mov ebp,ebx
add edi,edx
and ebp,ecx
mov edx,DWORD [32+esp]
add edi,ebp
; 40_59 56
mov ebp,eax
xor edx,DWORD [40+esp]
xor ebp,ebx
xor edx,DWORD [esp]
and ebp,esi
xor edx,DWORD [20+esp]
rol edx,1
add ebp,ecx
ror esi,2
mov ecx,edi
rol ecx,5
mov DWORD [32+esp],edx
lea edx,[2400959708+ebp*1+edx]
mov ebp,eax
add edx,ecx
and ebp,ebx
mov ecx,DWORD [36+esp]
add edx,ebp
; 40_59 57
mov ebp,esi
xor ecx,DWORD [44+esp]
xor ebp,eax
xor ecx,DWORD [4+esp]
and ebp,edi
xor ecx,DWORD [24+esp]
rol ecx,1
add ebp,ebx
ror edi,2
mov ebx,edx
rol ebx,5
mov DWORD [36+esp],ecx
lea ecx,[2400959708+ebp*1+ecx]
mov ebp,esi
add ecx,ebx
and ebp,eax
mov ebx,DWORD [40+esp]
add ecx,ebp
; 40_59 58
mov ebp,edi
xor ebx,DWORD [48+esp]
xor ebp,esi
xor ebx,DWORD [8+esp]
and ebp,edx
xor ebx,DWORD [28+esp]
rol ebx,1
add ebp,eax
ror edx,2
mov eax,ecx
rol eax,5
mov DWORD [40+esp],ebx
lea ebx,[2400959708+ebp*1+ebx]
mov ebp,edi
add ebx,eax
and ebp,esi
mov eax,DWORD [44+esp]
add ebx,ebp
; 40_59 59
mov ebp,edx
xor eax,DWORD [52+esp]
xor ebp,edi
xor eax,DWORD [12+esp]
and ebp,ecx
xor eax,DWORD [32+esp]
rol eax,1
add ebp,esi
ror ecx,2
mov esi,ebx
rol esi,5
mov DWORD [44+esp],eax
lea eax,[2400959708+ebp*1+eax]
mov ebp,edx
add eax,esi
and ebp,edi
mov esi,DWORD [48+esp]
add eax,ebp
; 20_39 60
mov ebp,ebx
xor esi,DWORD [56+esp]
xor ebp,ecx
xor esi,DWORD [16+esp]
xor ebp,edx
xor esi,DWORD [36+esp]
rol esi,1
add edi,ebp
ror ebx,2
mov ebp,eax
rol ebp,5
mov DWORD [48+esp],esi
lea esi,[3395469782+edi*1+esi]
mov edi,DWORD [52+esp]
add esi,ebp
; 20_39 61
mov ebp,eax
xor edi,DWORD [60+esp]
xor ebp,ebx
xor edi,DWORD [20+esp]
xor ebp,ecx
xor edi,DWORD [40+esp]
rol edi,1
add edx,ebp
ror eax,2
mov ebp,esi
rol ebp,5
mov DWORD [52+esp],edi
lea edi,[3395469782+edx*1+edi]
mov edx,DWORD [56+esp]
add edi,ebp
; 20_39 62
mov ebp,esi
xor edx,DWORD [esp]
xor ebp,eax
xor edx,DWORD [24+esp]
xor ebp,ebx
xor edx,DWORD [44+esp]
rol edx,1
add ecx,ebp
ror esi,2
mov ebp,edi
rol ebp,5
mov DWORD [56+esp],edx
lea edx,[3395469782+ecx*1+edx]
mov ecx,DWORD [60+esp]
add edx,ebp
; 20_39 63
mov ebp,edi
xor ecx,DWORD [4+esp]
xor ebp,esi
xor ecx,DWORD [28+esp]
xor ebp,eax
xor ecx,DWORD [48+esp]
rol ecx,1
add ebx,ebp
ror edi,2
mov ebp,edx
rol ebp,5
mov DWORD [60+esp],ecx
lea ecx,[3395469782+ebx*1+ecx]
mov ebx,DWORD [esp]
add ecx,ebp
; 20_39 64
mov ebp,edx
xor ebx,DWORD [8+esp]
xor ebp,edi
xor ebx,DWORD [32+esp]
xor ebp,esi
xor ebx,DWORD [52+esp]
rol ebx,1
add eax,ebp
ror edx,2
mov ebp,ecx
rol ebp,5
mov DWORD [esp],ebx
lea ebx,[3395469782+eax*1+ebx]
mov eax,DWORD [4+esp]
add ebx,ebp
; 20_39 65
mov ebp,ecx
xor eax,DWORD [12+esp]
xor ebp,edx
xor eax,DWORD [36+esp]
xor ebp,edi
xor eax,DWORD [56+esp]
rol eax,1
add esi,ebp
ror ecx,2
mov ebp,ebx
rol ebp,5
mov DWORD [4+esp],eax
lea eax,[3395469782+esi*1+eax]
mov esi,DWORD [8+esp]
add eax,ebp
; 20_39 66
mov ebp,ebx
xor esi,DWORD [16+esp]
xor ebp,ecx
xor esi,DWORD [40+esp]
xor ebp,edx
xor esi,DWORD [60+esp]
rol esi,1
add edi,ebp
ror ebx,2
mov ebp,eax
rol ebp,5
mov DWORD [8+esp],esi
lea esi,[3395469782+edi*1+esi]
mov edi,DWORD [12+esp]
add esi,ebp
; 20_39 67
mov ebp,eax
xor edi,DWORD [20+esp]
xor ebp,ebx
xor edi,DWORD [44+esp]
xor ebp,ecx
xor edi,DWORD [esp]
rol edi,1
add edx,ebp
ror eax,2
mov ebp,esi
rol ebp,5
mov DWORD [12+esp],edi
lea edi,[3395469782+edx*1+edi]
mov edx,DWORD [16+esp]
add edi,ebp
; 20_39 68
mov ebp,esi
xor edx,DWORD [24+esp]
xor ebp,eax
xor edx,DWORD [48+esp]
xor ebp,ebx
xor edx,DWORD [4+esp]
rol edx,1
add ecx,ebp
ror esi,2
mov ebp,edi
rol ebp,5
mov DWORD [16+esp],edx
lea edx,[3395469782+ecx*1+edx]
mov ecx,DWORD [20+esp]
add edx,ebp
; 20_39 69
mov ebp,edi
xor ecx,DWORD [28+esp]
xor ebp,esi
xor ecx,DWORD [52+esp]
xor ebp,eax
xor ecx,DWORD [8+esp]
rol ecx,1
add ebx,ebp
ror edi,2
mov ebp,edx
rol ebp,5
mov DWORD [20+esp],ecx
lea ecx,[3395469782+ebx*1+ecx]
mov ebx,DWORD [24+esp]
add ecx,ebp
; 20_39 70
mov ebp,edx
xor ebx,DWORD [32+esp]
xor ebp,edi
xor ebx,DWORD [56+esp]
xor ebp,esi
xor ebx,DWORD [12+esp]
rol ebx,1
add eax,ebp
ror edx,2
mov ebp,ecx
rol ebp,5
mov DWORD [24+esp],ebx
lea ebx,[3395469782+eax*1+ebx]
mov eax,DWORD [28+esp]
add ebx,ebp
; 20_39 71
mov ebp,ecx
xor eax,DWORD [36+esp]
xor ebp,edx
xor eax,DWORD [60+esp]
xor ebp,edi
xor eax,DWORD [16+esp]
rol eax,1
add esi,ebp
ror ecx,2
mov ebp,ebx
rol ebp,5
mov DWORD [28+esp],eax
lea eax,[3395469782+esi*1+eax]
mov esi,DWORD [32+esp]
add eax,ebp
; 20_39 72
mov ebp,ebx
xor esi,DWORD [40+esp]
xor ebp,ecx
xor esi,DWORD [esp]
xor ebp,edx
xor esi,DWORD [20+esp]
rol esi,1
add edi,ebp
ror ebx,2
mov ebp,eax
rol ebp,5
mov DWORD [32+esp],esi
lea esi,[3395469782+edi*1+esi]
mov edi,DWORD [36+esp]
add esi,ebp
; 20_39 73
mov ebp,eax
xor edi,DWORD [44+esp]
xor ebp,ebx
xor edi,DWORD [4+esp]
xor ebp,ecx
xor edi,DWORD [24+esp]
rol edi,1
add edx,ebp
ror eax,2
mov ebp,esi
rol ebp,5
mov DWORD [36+esp],edi
lea edi,[3395469782+edx*1+edi]
mov edx,DWORD [40+esp]
add edi,ebp
; 20_39 74
mov ebp,esi
xor edx,DWORD [48+esp]
xor ebp,eax
xor edx,DWORD [8+esp]
xor ebp,ebx
xor edx,DWORD [28+esp]
rol edx,1
add ecx,ebp
ror esi,2
mov ebp,edi
rol ebp,5
mov DWORD [40+esp],edx
lea edx,[3395469782+ecx*1+edx]
mov ecx,DWORD [44+esp]
add edx,ebp
; 20_39 75
mov ebp,edi
xor ecx,DWORD [52+esp]
xor ebp,esi
xor ecx,DWORD [12+esp]
xor ebp,eax
xor ecx,DWORD [32+esp]
rol ecx,1
add ebx,ebp
ror edi,2
mov ebp,edx
rol ebp,5
mov DWORD [44+esp],ecx
lea ecx,[3395469782+ebx*1+ecx]
mov ebx,DWORD [48+esp]
add ecx,ebp
; 20_39 76
mov ebp,edx
xor ebx,DWORD [56+esp]
xor ebp,edi
xor ebx,DWORD [16+esp]
xor ebp,esi
xor ebx,DWORD [36+esp]
rol ebx,1
add eax,ebp
ror edx,2
mov ebp,ecx
rol ebp,5
mov DWORD [48+esp],ebx
lea ebx,[3395469782+eax*1+ebx]
mov eax,DWORD [52+esp]
add ebx,ebp
; 20_39 77
mov ebp,ecx
xor eax,DWORD [60+esp]
xor ebp,edx
xor eax,DWORD [20+esp]
xor ebp,edi
xor eax,DWORD [40+esp]
rol eax,1
add esi,ebp
ror ecx,2
mov ebp,ebx
rol ebp,5
lea eax,[3395469782+esi*1+eax]
mov esi,DWORD [56+esp]
add eax,ebp
; 20_39 78
mov ebp,ebx
xor esi,DWORD [esp]
xor ebp,ecx
xor esi,DWORD [24+esp]
xor ebp,edx
xor esi,DWORD [44+esp]
rol esi,1
add edi,ebp
ror ebx,2
mov ebp,eax
rol ebp,5
lea esi,[3395469782+edi*1+esi]
mov edi,DWORD [60+esp]
add esi,ebp
; 20_39 79
mov ebp,eax
xor edi,DWORD [4+esp]
xor ebp,ebx
xor edi,DWORD [28+esp]
xor ebp,ecx
xor edi,DWORD [48+esp]
rol edi,1
add edx,ebp
ror eax,2
mov ebp,esi
rol ebp,5
lea edi,[3395469782+edx*1+edi]
add edi,ebp
mov ebp,DWORD [96+esp]
mov edx,DWORD [100+esp]
add edi,DWORD [ebp]
add esi,DWORD [4+ebp]
add eax,DWORD [8+ebp]
add ebx,DWORD [12+ebp]
add ecx,DWORD [16+ebp]
mov DWORD [ebp],edi
add edx,64
mov DWORD [4+ebp],esi
cmp edx,DWORD [104+esp]
mov DWORD [8+ebp],eax
mov edi,ecx
mov DWORD [12+ebp],ebx
mov esi,edx
mov DWORD [16+ebp],ecx
jb NEAR L$000loop
add esp,76
pop edi
pop esi
pop ebx
pop ebp
ret
db 83,72,65,49,32,98,108,111,99,107,32,116,114,97,110,115
db 102,111,114,109,32,102,111,114,32,120,56,54,44,32,67,82
db 89,80,84,79,71,65,77,83,32,98,121,32,60,97,112,112
db 114,111,64,111,112,101,110,115,115,108,46,111,114,103,62,0
| 16.858484 | 61 | 0.676003 |
4d6853be64b44867b486a9131a3d7b6d63644c5f | 2,386 | asm | Assembly | scripts/bikeshop.asm | etdv-thevoid/pokemon-rgb-enhanced | 5b244c1cf46aab98b9c820d1b7888814eb7fa53f | [
"MIT"
] | 1 | 2022-01-09T05:28:52.000Z | 2022-01-09T05:28:52.000Z | scripts/bikeshop.asm | ETDV-TheVoid/pokemon-rgb-enhanced | 5b244c1cf46aab98b9c820d1b7888814eb7fa53f | [
"MIT"
] | null | null | null | scripts/bikeshop.asm | ETDV-TheVoid/pokemon-rgb-enhanced | 5b244c1cf46aab98b9c820d1b7888814eb7fa53f | [
"MIT"
] | null | null | null | BikeShopScript:
jp EnableAutoTextBoxDrawing
BikeShopTextPointers:
dw BikeShopText1
dw BikeShopText2
dw BikeShopText3
BikeShopText1:
TX_ASM
CheckEvent EVENT_GOT_BICYCLE
jr z, .asm_260d4
ld hl, BikeShopText_1d82f
call PrintText
jp .Done
.asm_260d4
ld b, BIKE_VOUCHER
call IsItemInBag
jr z, .asm_41190
ld hl, BikeShopText_1d81f
call PrintText
lb bc, BICYCLE, 1
call GiveItem
jr nc, .BagFull
ld a, BIKE_VOUCHER
ld [$ffdb], a
callba RemoveItemByID
SetEvent EVENT_GOT_BICYCLE
ld hl, BikeShopText_1d824
call PrintText
jr .Done
.BagFull
ld hl, BikeShopText_1d834
call PrintText
jr .Done
.asm_41190
ld hl, BikeShopText_1d810
call PrintText
xor a
ld [wCurrentMenuItem], a
ld [wLastMenuItem], a
ld a, A_BUTTON | B_BUTTON
ld [wMenuWatchedKeys], a
ld a, $1
ld [wMaxMenuItem], a
ld a, $2
ld [wTopMenuItemY], a
ld a, $1
ld [wTopMenuItemX], a
ld hl, wd730
set 6, [hl]
coord hl, 0, 0
ld b, $4
ld c, $f
call TextBoxBorder
call UpdateSprites
coord hl, 2, 2
ld de, BikeShopMenuText
call PlaceString
coord hl, 8, 3
ld de, BikeShopMenuPrice
call PlaceString
ld hl, BikeShopText_1d815
call PrintText
call HandleMenuInput
bit 1, a
jr nz, .cancel
ld hl, wd730
res 6, [hl]
ld a, [wCurrentMenuItem]
and a
jr nz, .cancel
ld hl, BikeShopCantAffordText
call PrintText
.cancel
ld hl, BikeShopComeAgainText
call PrintText
.Done
jp TextScriptEnd
BikeShopMenuText:
db "BICYCLE"
next "CANCEL@"
BikeShopMenuPrice:
db "¥1000000@"
BikeShopText_1d810:
TX_FAR _BikeShopText_1d810
db "@"
BikeShopText_1d815:
TX_FAR _BikeShopText_1d815
db "@"
BikeShopCantAffordText:
TX_FAR _BikeShopCantAffordText
db "@"
BikeShopText_1d81f:
TX_FAR _BikeShopText_1d81f
db "@"
BikeShopText_1d824:
TX_FAR _BikeShopText_1d824
TX_SFX_KEY_ITEM
db "@"
BikeShopComeAgainText:
TX_FAR _BikeShopComeAgainText
db "@"
BikeShopText_1d82f:
TX_FAR _BikeShopText_1d82f
db "@"
BikeShopText_1d834:
TX_FAR _BikeShopText_1d834
db "@"
BikeShopText2:
TX_ASM
ld hl, BikeShopText_1d843
call PrintText
jp TextScriptEnd
BikeShopText_1d843:
TX_FAR _BikeShopText_1d843
db "@"
BikeShopText3:
TX_ASM
CheckEvent EVENT_GOT_BICYCLE
ld hl, BikeShopText_1d861
jr nz, .asm_34d2d
ld hl, BikeShopText_1d85c
.asm_34d2d
call PrintText
jp TextScriptEnd
BikeShopText_1d85c:
TX_FAR _BikeShopText_1d85c
db "@"
BikeShopText_1d861:
TX_FAR _BikeShopText_1d861
db "@"
| 16.121622 | 31 | 0.766555 |
bf579c8735e5b0cf15417559bd3fcd564cdaa5fa | 2,110 | asm | Assembly | dv3/hd/fchk.asm | olifink/smsqe | c546d882b26566a46d71820d1539bed9ea8af108 | [
"BSD-2-Clause"
] | null | null | null | dv3/hd/fchk.asm | olifink/smsqe | c546d882b26566a46d71820d1539bed9ea8af108 | [
"BSD-2-Clause"
] | null | null | null | dv3/hd/fchk.asm | olifink/smsqe | c546d882b26566a46d71820d1539bed9ea8af108 | [
"BSD-2-Clause"
] | null | null | null | ; Hard Disk Format Check V2.00 1990 Tony Tebby QJUMP
section dv3
xdef hd_fchk
xref cv_upcas
include 'dev8_keys_err'
include 'dev8_keys_msg8'
include 'dev8_keys_sys'
include 'dev8_keys_k'
include 'dev8_keys_qdos_io'
include 'dev8_keys_qdos_sms'
include 'dev8_dv3_keys'
include 'dev8_dv3_hd_keys'
;+++
; This checks the whether it is sensible to format the hard disk
;
; d7 c p msw drive number
; a3 c p linkahge block
; status return 0 or err.accd
;---
hd_fchk
hfc.reg reg d1/d3/d4/a0/a1
frame equ 4
movem.l hfc.reg,-(sp)
subq.l #frame,sp
lea -1(a3,d7.w),a0
tst.b hdl_wprt(a0) ; positive for formattable
ble.s hfc_accd ; not formattable
sub.l a0,a0 ; use channel 0
move.w #0,d3 ; no wait
moveq #0,d1 ; d1
moveq #0,d2
moveq #iop.pick,d0
trap #do.io
move.w #msg8.fmtq,a1 ; format query message
moveq #sms.mptr,d0
trap #do.sms2
bsr.s hfc_wstrg
move.w sys_rand(a6),d0 ; get two character key
divu #26,d0
move.l d0,(sp)
ext.l d0
divu #26,d0
swap d0
move.b d0,(sp)
add.w #'AA',(sp)
move.w #'> ',2(sp)
move.l sp,a1 ; write it
moveq #4,d2 ; four characters
bsr.s hfc_wmul
bsr.s hfc_rchar ; get first key
bsr.s hfc_rchar ; and second
bsr.s hfc_nl ; newline
cmp.w (sp),d2
beq.s hfc_ok
hfc_accd
moveq #err.accd,d0
bra.s hfc_exit
hfc_fdnf
moveq #err.fdnf,d0
bra.s hfc_exit
hfc_ok
moveq #0,d0
hfc_exit
addq.l #frame,sp
movem.l (sp)+,hfc.reg
rts
hfc_rnum
moveq #0,d2
bsr.s hfc_rchar ; read character
sub.w #'0',d2 ; make it a digit
blt.s hfc_rts
cmp.w #9,d2 ; ... 0-9
bgt.s hfc_rts
hfc_nl
moveq #k.nl,d1
hfc_wchar
moveq #iob.sbyt,d0
bra.s hfc_io
hfc_rchar
moveq #iow.ecur,d0 ; enable cursor
bsr.s hfc_io
moveq #iob.fbyt,d0
bsr.s hfc_io
jsr cv_upcas ; upper case
lsl.w #8,d2
move.b d1,d2 ; save in d2
bsr.s hfc_wchar
moveq #iow.dcur,d0
bra.s hfc_io
hfc_wstrg
move.w (a1)+,d2
hfc_wmul
moveq #iob.smul,d0
bra.s hfc_io
hfc_retry
move.l (sp)+,d0
hfc_io
move.l d0,-(sp)
trap #do.io
addq.l #-err.nc,d0
beq.s hfc_retry
subq.l #-err.nc,d0
addq.l #4,sp
hfc_rts
rts
end
| 16.88 | 64 | 0.671564 |
fcafd9c48f665f4caed6552bc48035749ec77f97 | 20,990 | asm | Assembly | components/x264/x264-snapshot-20181221-2245-stable/common/x86/cabac-a.asm | plkumar/esp32-homekit-camera | 9ae7bf0482bfa08eec7a7e52a920a2664e19f7d6 | [
"MIT"
] | 286 | 2019-01-09T14:33:32.000Z | 2022-03-29T00:18:28.000Z | components/x264/x264-snapshot-20181221-2245-stable/common/x86/cabac-a.asm | jangolen/esp32-homekit-camera | 8a2f6e5e92c148853f681b427cd7c73e30ec3f57 | [
"MIT"
] | 95 | 2019-01-13T13:14:12.000Z | 2022-03-26T16:15:50.000Z | components/x264/x264-snapshot-20181221-2245-stable/common/x86/cabac-a.asm | jangolen/esp32-homekit-camera | 8a2f6e5e92c148853f681b427cd7c73e30ec3f57 | [
"MIT"
] | 71 | 2019-01-07T22:56:17.000Z | 2022-03-03T19:53:37.000Z | ;*****************************************************************************
;* cabac-a.asm: x86 cabac
;*****************************************************************************
;* Copyright (C) 2008-2018 x264 project
;*
;* Authors: Loren Merritt <lorenm@u.washington.edu>
;* Fiona Glaser <fiona@x264.com>
;* Holger Lubitz <holger@lubitz.org>
;*
;* This program is free software; you can redistribute it and/or modify
;* it under the terms of the GNU General Public License as published by
;* the Free Software Foundation; either version 2 of the License, or
;* (at your option) any later version.
;*
;* This program is distributed in the hope that it will be useful,
;* but WITHOUT ANY WARRANTY; without even the implied warranty of
;* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
;* GNU General Public License for more details.
;*
;* You should have received a copy of the GNU General Public License
;* along with this program; if not, write to the Free Software
;* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02111, USA.
;*
;* This program is also available under a commercial proprietary license.
;* For more information, contact us at licensing@x264.com.
;*****************************************************************************
%include "x86inc.asm"
%include "x86util.asm"
SECTION_RODATA 64
%if ARCH_X86_64
%macro COEFF_LAST_TABLE 4-18 16, 15, 16, 4, 15, 64, 16, 15, 16, 64, 16, 15, 16, 64
%xdefine %%funccpu1 %2 ; last4
%xdefine %%funccpu2 %3 ; last64
%xdefine %%funccpu3 %4 ; last15/last16
coeff_last_%1:
%ifdef PIC
%xdefine %%base coeff_last_%1 ; offset relative to the start of the table
%else
%xdefine %%base 0 ; absolute address
%endif
%rep 14
%ifidn %5, 4
dd mangle(private_prefix %+ _coeff_last%5_ %+ %%funccpu1) - %%base
%elifidn %5, 64
dd mangle(private_prefix %+ _coeff_last%5_ %+ %%funccpu2) - %%base
%else
dd mangle(private_prefix %+ _coeff_last%5_ %+ %%funccpu3) - %%base
%endif
%rotate 1
%endrep
dd 0, 0 ; 64-byte alignment padding
%endmacro
cextern coeff_last4_mmx2
cextern coeff_last4_lzcnt
%if HIGH_BIT_DEPTH
cextern coeff_last4_avx512
%endif
cextern coeff_last15_sse2
cextern coeff_last15_lzcnt
cextern coeff_last15_avx512
cextern coeff_last16_sse2
cextern coeff_last16_lzcnt
cextern coeff_last16_avx512
cextern coeff_last64_sse2
cextern coeff_last64_lzcnt
cextern coeff_last64_avx2
cextern coeff_last64_avx512
COEFF_LAST_TABLE sse2, mmx2, sse2, sse2
COEFF_LAST_TABLE lzcnt, lzcnt, lzcnt, lzcnt
COEFF_LAST_TABLE avx2, lzcnt, avx2, lzcnt
%if HIGH_BIT_DEPTH
COEFF_LAST_TABLE avx512, avx512, avx512, avx512
%else
COEFF_LAST_TABLE avx512, lzcnt, avx512, avx512
%endif
%endif
coeff_abs_level1_ctx: db 1, 2, 3, 4, 0, 0, 0, 0
coeff_abs_levelgt1_ctx: db 5, 5, 5, 5, 6, 7, 8, 9
coeff_abs_level_transition: db 1, 2, 3, 3, 4, 5, 6, 7
db 4, 4, 4, 4, 5, 6, 7, 7
SECTION .text
cextern_common cabac_range_lps
cextern_common cabac_transition
cextern_common cabac_renorm_shift
cextern_common cabac_entropy
cextern cabac_size_unary
cextern cabac_transition_unary
cextern_common significant_coeff_flag_offset
cextern_common significant_coeff_flag_offset_8x8
cextern_common last_coeff_flag_offset
cextern_common last_coeff_flag_offset_8x8
cextern_common coeff_abs_level_m1_offset
cextern_common count_cat_m1
cextern cabac_encode_ue_bypass
%if ARCH_X86_64
%define pointer resq
%else
%define pointer resd
%endif
struc cb
.low: resd 1
.range: resd 1
.queue: resd 1
.bytes_outstanding: resd 1
.start: pointer 1
.p: pointer 1
.end: pointer 1
align 64, resb 1
.bits_encoded: resd 1
.state: resb 1024
endstruc
%macro LOAD_GLOBAL 3-5 0 ; dst, base, off1, off2, tmp
%ifdef PIC
%ifidn %4, 0
movzx %1, byte [%2+%3+r7-$$]
%else
lea %5, [r7+%4]
movzx %1, byte [%2+%3+%5-$$]
%endif
%else
movzx %1, byte [%2+%3+%4]
%endif
%endmacro
%macro CABAC 1
; t3 must be ecx, since it's used for shift.
%if WIN64
DECLARE_REG_TMP 3,1,2,0,5,6,4,4
%elif ARCH_X86_64
DECLARE_REG_TMP 0,1,2,3,4,5,6,6
%else
DECLARE_REG_TMP 0,4,2,1,3,5,6,2
%endif
cglobal cabac_encode_decision_%1, 1,7
movifnidn t1d, r1m
mov t5d, [r0+cb.range]
movzx t6d, byte [r0+cb.state+t1]
movifnidn t0, r0 ; WIN64
mov t4d, ~1
mov t3d, t5d
and t4d, t6d
shr t5d, 6
movifnidn t2d, r2m
%if WIN64
PUSH r7
%endif
%ifdef PIC
lea r7, [$$]
%endif
LOAD_GLOBAL t5d, cabac_range_lps-4, t5, t4*2, t4
LOAD_GLOBAL t4d, cabac_transition, t2, t6*2, t4
and t6d, 1
sub t3d, t5d
cmp t6d, t2d
mov t6d, [t0+cb.low]
lea t2, [t6+t3]
cmovne t3d, t5d
cmovne t6d, t2d
mov [t0+cb.state+t1], t4b
;cabac_encode_renorm
mov t4d, t3d
%ifidn %1, bmi2
lzcnt t3d, t3d
sub t3d, 23
shlx t4d, t4d, t3d
shlx t6d, t6d, t3d
%else
shr t3d, 3
LOAD_GLOBAL t3d, cabac_renorm_shift, t3
shl t4d, t3b
shl t6d, t3b
%endif
%if WIN64
POP r7
%endif
mov [t0+cb.range], t4d
add t3d, [t0+cb.queue]
jge cabac_putbyte_%1
.update_queue_low:
mov [t0+cb.low], t6d
mov [t0+cb.queue], t3d
RET
cglobal cabac_encode_bypass_%1, 2,3
mov t7d, [r0+cb.low]
and r1d, [r0+cb.range]
lea t7d, [t7*2+r1]
movifnidn t0, r0 ; WIN64
mov t3d, [r0+cb.queue]
inc t3d
%if ARCH_X86_64 ; .putbyte compiles to nothing but a jmp
jge cabac_putbyte_%1
%else
jge .putbyte
%endif
mov [t0+cb.low], t7d
mov [t0+cb.queue], t3d
RET
%if ARCH_X86_64 == 0
.putbyte:
PROLOGUE 0,7
movifnidn t6d, t7d
jmp cabac_putbyte_%1
%endif
%ifnidn %1,bmi2
cglobal cabac_encode_terminal_%1, 1,3
sub dword [r0+cb.range], 2
; shortcut: the renormalization shift in terminal
; can only be 0 or 1 and is zero over 99% of the time.
test dword [r0+cb.range], 0x100
je .renorm
RET
.renorm:
shl dword [r0+cb.low], 1
shl dword [r0+cb.range], 1
inc dword [r0+cb.queue]
jge .putbyte
RET
.putbyte:
PROLOGUE 0,7
movifnidn t0, r0 ; WIN64
mov t3d, [r0+cb.queue]
mov t6d, [t0+cb.low]
%endif
cabac_putbyte_%1:
; alive: t0=cb t3=queue t6=low
%if WIN64
DECLARE_REG_TMP 3,6,1,0,2,5,4
%endif
%ifidn %1, bmi2
add t3d, 10
shrx t2d, t6d, t3d
bzhi t6d, t6d, t3d
sub t3d, 18
%else
mov t1d, -1
add t3d, 10
mov t2d, t6d
shl t1d, t3b
shr t2d, t3b ; out
not t1d
sub t3d, 18
and t6d, t1d
%endif
mov t5d, [t0+cb.bytes_outstanding]
cmp t2b, 0xff ; FIXME is a 32bit op faster?
jz .postpone
mov t1, [t0+cb.p]
add [t1-1], t2h
dec t2h
.loop_outstanding:
mov [t1], t2h
inc t1
dec t5d
jge .loop_outstanding
mov [t1-1], t2b
mov [t0+cb.p], t1
.postpone:
inc t5d
mov [t0+cb.bytes_outstanding], t5d
jmp mangle(private_prefix %+ _cabac_encode_decision_%1.update_queue_low)
%endmacro
CABAC asm
CABAC bmi2
; %1 = label name
; %2 = node_ctx init?
%macro COEFF_ABS_LEVEL_GT1 2
%if %2
%define ctx 1
%else
movzx r11d, byte [coeff_abs_level1_ctx+r2 GLOBAL]
%define ctx r11
%endif
movzx r9d, byte [r8+ctx]
; if( coeff_abs > 1 )
cmp r1d, 1
jg .%1_gt1
; x264_cabac_encode_decision( cb, ctx_level+ctx, 0 )
movzx r10d, byte [cabac_transition+r9*2 GLOBAL]
movzx r9d, word [cabac_entropy+r9*2 GLOBAL]
lea r0d, [r0+r9+256]
mov [r8+ctx], r10b
%if %2
mov r2d, 1
%else
movzx r2d, byte [coeff_abs_level_transition+r2 GLOBAL]
%endif
jmp .%1_end
.%1_gt1:
; x264_cabac_encode_decision( cb, ctx_level+ctx, 1 )
movzx r10d, byte [cabac_transition+r9*2+1 GLOBAL]
xor r9d, 1
movzx r9d, word [cabac_entropy+r9*2 GLOBAL]
mov [r8+ctx], r10b
add r0d, r9d
%if %2
%define ctx 5
%else
movzx r11d, byte [coeff_abs_levelgt1_ctx+r2 GLOBAL]
%define ctx r11
%endif
; if( coeff_abs < 15 )
cmp r1d, 15
jge .%1_escape
shl r1d, 7
; x264_cabac_transition_unary[coeff_abs-1][cb->state[ctx_level+ctx]]
movzx r9d, byte [r8+ctx]
add r9d, r1d
movzx r10d, byte [cabac_transition_unary-128+r9 GLOBAL]
; x264_cabac_size_unary[coeff_abs-1][cb->state[ctx_level+ctx]]
movzx r9d, word [cabac_size_unary-256+r9*2 GLOBAL]
mov [r8+ctx], r10b
add r0d, r9d
jmp .%1_gt1_end
.%1_escape:
; x264_cabac_transition_unary[14][cb->state[ctx_level+ctx]]
movzx r9d, byte [r8+ctx]
movzx r10d, byte [cabac_transition_unary+128*14+r9 GLOBAL]
; x264_cabac_size_unary[14][cb->state[ctx_level+ctx]]
movzx r9d, word [cabac_size_unary+256*14+r9*2 GLOBAL]
add r0d, r9d
mov [r8+ctx], r10b
sub r1d, 14
%if cpuflag(lzcnt)
lzcnt r9d, r1d
xor r9d, 0x1f
%else
bsr r9d, r1d
%endif
; bs_size_ue_big(coeff_abs-15)<<8
shl r9d, 9
; (ilog2(coeff_abs-14)+1) << 8
lea r0d, [r0+r9+256]
.%1_gt1_end:
%if %2
mov r2d, 4
%else
movzx r2d, byte [coeff_abs_level_transition+8+r2 GLOBAL]
%endif
.%1_end:
%endmacro
%macro LOAD_DCTCOEF 1
%if HIGH_BIT_DEPTH
mov %1, [dct+r6*4]
%else
movzx %1, word [dct+r6*2]
%endif
%endmacro
%macro ABS_DCTCOEFS 2
%if HIGH_BIT_DEPTH
%define %%abs ABSD
%else
%define %%abs ABSW
%endif
%if mmsize == %2*SIZEOF_DCTCOEF
%%abs m0, [%1], m1
mova [rsp], m0
%elif mmsize == %2*SIZEOF_DCTCOEF/2
%%abs m0, [%1+0*mmsize], m2
%%abs m1, [%1+1*mmsize], m3
mova [rsp+0*mmsize], m0
mova [rsp+1*mmsize], m1
%else
%assign i 0
%rep %2*SIZEOF_DCTCOEF/(4*mmsize)
%%abs m0, [%1+(4*i+0)*mmsize], m4
%%abs m1, [%1+(4*i+1)*mmsize], m5
%%abs m2, [%1+(4*i+2)*mmsize], m4
%%abs m3, [%1+(4*i+3)*mmsize], m5
mova [rsp+(4*i+0)*mmsize], m0
mova [rsp+(4*i+1)*mmsize], m1
mova [rsp+(4*i+2)*mmsize], m2
mova [rsp+(4*i+3)*mmsize], m3
%assign i i+1
%endrep
%endif
%endmacro
%macro SIG_OFFSET 1
%if %1
movzx r11d, byte [r4+r6]
%endif
%endmacro
%macro LAST_OFFSET 1
%if %1
movzx r11d, byte [last_coeff_flag_offset_8x8+r6 GLOBAL]
%endif
%endmacro
%macro COEFF_LAST 2 ; table, ctx_block_cat
%ifdef PIC
lea r1, [%1 GLOBAL]
movsxd r6, [r1+4*%2]
add r6, r1
%else
movsxd r6, [%1+4*%2]
%endif
call r6
%endmacro
;-----------------------------------------------------------------------------
; void x264_cabac_block_residual_rd_internal_sse2 ( dctcoef *l, int b_interlaced,
; int ctx_block_cat, x264_cabac_t *cb );
;-----------------------------------------------------------------------------
;%1 = 8x8 mode
%macro CABAC_RESIDUAL_RD 2
%if %1
%define func cabac_block_residual_8x8_rd_internal
%define maxcoeffs 64
%define dct rsp
%else
%define func cabac_block_residual_rd_internal
%define maxcoeffs 16
%define dct r4
%endif
%ifdef PIC
cglobal func, 4,13,6,-maxcoeffs*SIZEOF_DCTCOEF
lea r12, [$$]
%define GLOBAL +r12-$$
%else
cglobal func, 4,12,6,-maxcoeffs*SIZEOF_DCTCOEF
%define GLOBAL
%endif
shl r1d, 4 ; MB_INTERLACED*16
%if %1
lea r4, [significant_coeff_flag_offset_8x8+r1*4 GLOBAL] ; r12 = sig offset 8x8
%endif
add r1d, r2d
movzx r5d, word [significant_coeff_flag_offset+r1*2 GLOBAL] ; r5 = ctx_sig
movzx r7d, word [last_coeff_flag_offset+r1*2 GLOBAL] ; r7 = ctx_last
movzx r8d, word [coeff_abs_level_m1_offset+r2*2 GLOBAL] ; r8 = ctx_level
; abs() all the coefficients; copy them to the stack to avoid
; changing the originals.
; overreading is okay; it's all valid aligned data anyways.
%if %1
ABS_DCTCOEFS r0, 64
%else
mov r4, r0 ; r4 = dct
and r4, ~SIZEOF_DCTCOEF ; handle AC coefficient case
ABS_DCTCOEFS r4, 16
xor r4, r0 ; calculate our new dct pointer
add r4, rsp ; restore AC coefficient offset
%endif
; for improved OOE performance, run coeff_last on the original coefficients.
COEFF_LAST %2, r2 ; coeff_last[ctx_block_cat]( dct )
; we know on 64-bit that the SSE2 versions of this function only
; overwrite r0, r1, and rax (r6). last64 overwrites r2 too, but we
; don't need r2 in 8x8 mode.
mov r0d, [r3+cb.bits_encoded] ; r0 = cabac.f8_bits_encoded
; pre-add some values to simplify addressing
add r3, cb.state
add r5, r3
add r7, r3
add r8, r3 ; precalculate cabac state pointers
; if( last != count_cat_m1[ctx_block_cat] )
%if %1
cmp r6b, 63
%else
cmp r6b, [count_cat_m1+r2 GLOBAL]
%endif
je .skip_last_sigmap
; in 8x8 mode we have to do a bit of extra calculation for ctx_sig/last,
; so we'll use r11 for this.
%if %1
%define siglast_ctx r11
%else
%define siglast_ctx r6
%endif
; x264_cabac_encode_decision( cb, ctx_sig + last, 1 )
; x264_cabac_encode_decision( cb, ctx_last + last, 1 )
SIG_OFFSET %1
movzx r1d, byte [r5+siglast_ctx]
movzx r9d, byte [cabac_transition+1+r1*2 GLOBAL]
xor r1d, 1
movzx r1d, word [cabac_entropy+r1*2 GLOBAL]
mov [r5+siglast_ctx], r9b
add r0d, r1d
LAST_OFFSET %1
movzx r1d, byte [r7+siglast_ctx]
movzx r9d, byte [cabac_transition+1+r1*2 GLOBAL]
xor r1d, 1
movzx r1d, word [cabac_entropy+r1*2 GLOBAL]
mov [r7+siglast_ctx], r9b
add r0d, r1d
.skip_last_sigmap:
LOAD_DCTCOEF r1d
COEFF_ABS_LEVEL_GT1 last, 1
; for( int i = last-1 ; i >= 0; i-- )
dec r6d
jl .end
.coeff_loop:
LOAD_DCTCOEF r1d
; if( l[i] )
SIG_OFFSET %1
movzx r9d, byte [r5+siglast_ctx]
test r1d, r1d
jnz .coeff_nonzero
; x264_cabac_encode_decision( cb, ctx_sig + i, 0 )
movzx r10d, byte [cabac_transition+r9*2 GLOBAL]
movzx r9d, word [cabac_entropy+r9*2 GLOBAL]
mov [r5+siglast_ctx], r10b
add r0d, r9d
dec r6d
jge .coeff_loop
jmp .end
.coeff_nonzero:
; x264_cabac_encode_decision( cb, ctx_sig + i, 1 )
movzx r10d, byte [cabac_transition+r9*2+1 GLOBAL]
xor r9d, 1
movzx r9d, word [cabac_entropy+r9*2 GLOBAL]
mov [r5+siglast_ctx], r10b
add r0d, r9d
; x264_cabac_encode_decision( cb, ctx_last + i, 0 );
LAST_OFFSET %1
movzx r9d, byte [r7+siglast_ctx]
movzx r10d, byte [cabac_transition+r9*2 GLOBAL]
movzx r9d, word [cabac_entropy+r9*2 GLOBAL]
mov [r7+siglast_ctx], r10b
add r0d, r9d
COEFF_ABS_LEVEL_GT1 coeff, 0
dec r6d
jge .coeff_loop
.end:
mov [r3+cb.bits_encoded-cb.state], r0d
RET
%endmacro
%if ARCH_X86_64
INIT_XMM sse2
CABAC_RESIDUAL_RD 0, coeff_last_sse2
CABAC_RESIDUAL_RD 1, coeff_last_sse2
INIT_XMM lzcnt
CABAC_RESIDUAL_RD 0, coeff_last_lzcnt
CABAC_RESIDUAL_RD 1, coeff_last_lzcnt
INIT_XMM ssse3
CABAC_RESIDUAL_RD 0, coeff_last_sse2
CABAC_RESIDUAL_RD 1, coeff_last_sse2
INIT_XMM ssse3,lzcnt
CABAC_RESIDUAL_RD 0, coeff_last_lzcnt
CABAC_RESIDUAL_RD 1, coeff_last_lzcnt
%if HIGH_BIT_DEPTH
INIT_ZMM avx512
%else
INIT_YMM avx512
%endif
CABAC_RESIDUAL_RD 0, coeff_last_avx512
INIT_ZMM avx512
CABAC_RESIDUAL_RD 1, coeff_last_avx512
%endif
;-----------------------------------------------------------------------------
; void x264_cabac_block_residual_internal_sse2 ( dctcoef *l, int b_interlaced,
; int ctx_block_cat, x264_cabac_t *cb );
;-----------------------------------------------------------------------------
%macro CALL_CABAC 0
%if cpuflag(bmi2)
call cabac_encode_decision_bmi2
%else
call cabac_encode_decision_asm
%endif
%if WIN64 ; move cabac back
mov r0, r3
%endif
%endmacro
; %1 = 8x8 mode
; %2 = dct register
; %3 = countcat
; %4 = name
%macro SIGMAP_LOOP 3-4
.sigmap_%4loop:
%if HIGH_BIT_DEPTH
mov %2, [dct+r10*4]
%else
movsx %2, word [dct+r10*2]
%endif
%if %1
movzx r1d, byte [sigoff_8x8 + r10]
add r1d, sigoffd
%else
lea r1d, [sigoffd + r10d]
%endif
test %2, %2
jz .sigmap_%4zero ; if( l[i] )
inc coeffidxd
mov [coeffs+coeffidxq*4], %2 ; coeffs[++coeff_idx] = l[i];
mov r2d, 1
CALL_CABAC ; x264_cabac_encode_decision( cb, ctx_sig + sig_off, 1 );
%if %1
movzx r1d, byte [last_coeff_flag_offset_8x8 + r10 GLOBAL]
add r1d, lastoffd
%else
lea r1d, [lastoffd + r10d]
%endif
cmp r10d, lastm ; if( i == last )
je .sigmap_%4last
xor r2d, r2d
CALL_CABAC ; x264_cabac_encode_decision( cb, ctx_last + last_off, 0 );
jmp .sigmap_%4loop_endcheck
.sigmap_%4zero:
xor r2d, r2d
CALL_CABAC ; x264_cabac_encode_decision( cb, ctx_sig + sig_off, 0 );
.sigmap_%4loop_endcheck:
inc r10d
cmp r10d, %3
jne .sigmap_%4loop ; if( ++i == count_m1 )
%if HIGH_BIT_DEPTH
mov %2, [dct+r10*4]
%else
movsx %2, word [dct+r10*2]
%endif
inc coeffidxd
mov [coeffs+coeffidxq*4], %2 ; coeffs[++coeff_idx] = l[i]
jmp .sigmap_%4end
.sigmap_%4last: ; x264_cabac_encode_decision( cb, ctx_last + last_off, 1 );
mov r2d, 1
CALL_CABAC
.sigmap_%4end:
%if %1==0
jmp .level_loop_start
%endif
%endmacro
%macro CABAC_RESIDUAL 1
cglobal cabac_block_residual_internal, 4,15,0,-4*64
%ifdef PIC
; if we use the same r7 as in cabac_encode_decision, we can cheat and save a register.
lea r7, [$$]
%define lastm [rsp+4*1]
%define GLOBAL +r7-$$
%else
%define lastm r7d
%define GLOBAL
%endif
shl r1d, 4
%define sigoffq r8
%define sigoffd r8d
%define lastoffq r9
%define lastoffd r9d
%define leveloffq r10
%define leveloffd r10d
%define leveloffm [rsp+4*0]
%define countcatd r11d
%define sigoff_8x8 r12
%define coeffidxq r13
%define coeffidxd r13d
%define dct r14
%define coeffs rsp+4*2
lea sigoff_8x8, [significant_coeff_flag_offset_8x8+r1*4 GLOBAL]
add r1d, r2d
movzx sigoffd, word [significant_coeff_flag_offset+r1*2 GLOBAL]
movzx lastoffd, word [last_coeff_flag_offset+r1*2 GLOBAL]
movzx leveloffd, word [coeff_abs_level_m1_offset+r2*2 GLOBAL]
movzx countcatd, byte [count_cat_m1+r2 GLOBAL]
mov coeffidxd, -1
mov dct, r0
mov leveloffm, leveloffd
COEFF_LAST %1, r2
mov lastm, eax
; put cabac in r0; needed for cabac_encode_decision
mov r0, r3
xor r10d, r10d
cmp countcatd, 63
je .sigmap_8x8
SIGMAP_LOOP 0, r12d, countcatd,
.sigmap_8x8:
SIGMAP_LOOP 1, r11d, 63, _8x8
.level_loop_start:
; we now have r8, r9, r11, r12, and r7/r14(dct) free for the main loop.
%define nodectxq r8
%define nodectxd r8d
mov leveloffd, leveloffm
xor nodectxd, nodectxd
.level_loop:
mov r9d, [coeffs+coeffidxq*4]
mov r11d, r9d
sar r11d, 31
add r9d, r11d
movzx r1d, byte [coeff_abs_level1_ctx+nodectxq GLOBAL]
xor r9d, r11d
add r1d, leveloffd
cmp r9d, 1
jg .level_gt1
xor r2d, r2d
CALL_CABAC
movzx nodectxd, byte [coeff_abs_level_transition+nodectxq GLOBAL]
jmp .level_sign
.level_gt1:
mov r2d, 1
CALL_CABAC
movzx r14d, byte [coeff_abs_levelgt1_ctx+nodectxq GLOBAL]
add r14d, leveloffd
cmp r9d, 15
mov r12d, 15
cmovl r12d, r9d
sub r12d, 2
jz .level_eq2
.level_gt1_loop:
mov r1d, r14d
mov r2d, 1
CALL_CABAC
dec r12d
jg .level_gt1_loop
cmp r9d, 15
jge .level_bypass
.level_eq2:
mov r1d, r14d
xor r2d, r2d
CALL_CABAC
jmp .level_gt1_end
.level_bypass:
lea r2d, [r9d-15]
xor r1d, r1d
push r0
; we could avoid this if we implemented it in asm, but I don't feel like that
; right now.
%if UNIX64
push r7
push r8
%else
sub rsp, 40 ; shadow space and alignment
%endif
call cabac_encode_ue_bypass
%if UNIX64
pop r8
pop r7
%else
add rsp, 40
%endif
pop r0
.level_gt1_end:
movzx nodectxd, byte [coeff_abs_level_transition+8+nodectxq GLOBAL]
.level_sign:
mov r1d, r11d
%if cpuflag(bmi2)
call cabac_encode_bypass_bmi2
%else
call cabac_encode_bypass_asm
%endif
%if WIN64
mov r0, r3
%endif
dec coeffidxd
jge .level_loop
RET
%endmacro
%if ARCH_X86_64
INIT_XMM sse2
CABAC_RESIDUAL coeff_last_sse2
INIT_XMM lzcnt
CABAC_RESIDUAL coeff_last_lzcnt
INIT_XMM avx2
CABAC_RESIDUAL coeff_last_avx2
INIT_XMM avx512
CABAC_RESIDUAL coeff_last_avx512
%endif
| 26.502525 | 97 | 0.623678 |
91ea9a9310dbefe8bf1f859900f7d3d9c64eca22 | 722 | asm | Assembly | oeis/338/A338086.asm | neoneye/loda-programs | 84790877f8e6c2e821b183d2e334d612045d29c0 | [
"Apache-2.0"
] | 11 | 2021-08-22T19:44:55.000Z | 2022-03-20T16:47:57.000Z | oeis/338/A338086.asm | neoneye/loda-programs | 84790877f8e6c2e821b183d2e334d612045d29c0 | [
"Apache-2.0"
] | 9 | 2021-08-29T13:15:54.000Z | 2022-03-09T19:52:31.000Z | oeis/338/A338086.asm | neoneye/loda-programs | 84790877f8e6c2e821b183d2e334d612045d29c0 | [
"Apache-2.0"
] | 3 | 2021-08-22T20:56:47.000Z | 2021-09-29T06:26:12.000Z | ; A338086: Duplicate the ternary digits of n, so each 0, 1 or 2 becomes 00, 11 or 22 respectively.
; Submitted by Jamie Morken(w1)
; 0,4,8,36,40,44,72,76,80,324,328,332,360,364,368,396,400,404,648,652,656,684,688,692,720,724,728,2916,2920,2924,2952,2956,2960,2988,2992,2996,3240,3244,3248,3276,3280,3284,3312,3316,3320,3564,3568,3572,3600,3604,3608,3636,3640,3644,5832,5836,5840,5868,5872,5876,5904,5908,5912,6156,6160,6164,6192,6196,6200,6228,6232,6236,6480,6484,6488,6516,6520,6524,6552,6556,6560,26244,26248,26252,26280,26284,26288,26316,26320,26324,26568,26572,26576,26604,26608,26612,26640,26644,26648,26892
mov $3,1
lpb $0
mov $2,$0
div $0,3
mod $2,3
mul $2,$3
add $1,$2
mul $3,9
lpe
mov $0,$1
mul $0,4
| 45.125 | 481 | 0.732687 |
21e07208110e0528cd5644bf6d3cc65664a3ea92 | 1,033 | asm | Assembly | libsrc/math/genmath/rshift_noaf.asm | andydansby/z88dk-mk2 | 51c15f1387293809c496f5eaf7b196f8a0e9b66b | [
"ClArtistic"
] | 1 | 2020-09-15T08:35:49.000Z | 2020-09-15T08:35:49.000Z | libsrc/math/genmath/rshift_noaf.asm | andydansby/z88dk-MK2 | 51c15f1387293809c496f5eaf7b196f8a0e9b66b | [
"ClArtistic"
] | null | null | null | libsrc/math/genmath/rshift_noaf.asm | andydansby/z88dk-MK2 | 51c15f1387293809c496f5eaf7b196f8a0e9b66b | [
"ClArtistic"
] | null | null | null | ;
; Z88dk Generic Floating Point Math Library
;
; Shift c ix de b right by a
;
; $Id: rshift_noaf.asm,v 1.1 2012/04/17 16:37:46 stefano Exp $:
XLIB rshift
XDEF rsh8
.RSHIFT LD B,0
.RSH2 SUB 8
JR C,RSH4 ;c => 7 or fewer shifts remain
LD B,E ;shift c ix de b right by 8...
LD E,D
LD D,IXL
;EX AF,AF'
PUSH AF
LD A,IXH
LD IXL,A
;EX AF,AF'
POP AF
LD IXH,C
LD C,0 ;...end of shifting
JR RSH2
;
.RSH4 ADD A,9
LD L,A
.RSH6 XOR A
DEC L
RET Z ;z => requested shift is complete
LD A,C
.RSH8 RRA ;shift c ix de b right by one...
LD C,A
LD A,IXH
RRA
LD IXH,A
LD A,IXL
RRA
LD IXL,A
RR D
RR E
RR B ;...end of shifting
JR RSH6
| 20.66 | 69 | 0.393998 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.