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
|
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
9eb3ff80db446bd605abf22319808c9b65b547a6
| 275
|
asm
|
Assembly
|
Mid-Term/Solution/4.asm
|
NasirSunny50/CSE331L-Section-1-Fall20-NSU
|
cede019f310e694ac660292b19c181bbf1579a00
|
[
"MIT"
] | null | null | null |
Mid-Term/Solution/4.asm
|
NasirSunny50/CSE331L-Section-1-Fall20-NSU
|
cede019f310e694ac660292b19c181bbf1579a00
|
[
"MIT"
] | null | null | null |
Mid-Term/Solution/4.asm
|
NasirSunny50/CSE331L-Section-1-Fall20-NSU
|
cede019f310e694ac660292b19c181bbf1579a00
|
[
"MIT"
] | null | null | null |
.MODEL SMALL
.STACK 100H
.data
.CODE
MAIN PROC
MOV AX, @DATA
MOV DS, AX
MOV CX, 1
MOV AH, 2
MOV DL, 42
@LOOP:
INT 21H
INC DL
DEC CX
JNZ @LOOP
MOV AH, 4CH
INT 21H
MAIN ENDP
END MAIN
| 8.088235
| 17
| 0.458182
|
f683601204901e4998a6d8742024ffe1ca55ddb7
| 2,097
|
asm
|
Assembly
|
demo/joypad.asm
|
stoneface86/tbengine
|
a3c6c0f2bf28426f89eedfabbd6f480f6c59d0db
|
[
"MIT"
] | 6
|
2020-07-18T01:14:29.000Z
|
2022-03-11T18:18:52.000Z
|
scraps/demo/joypad.asm
|
stoneface86/gbsoundengine
|
774a9ea67143e5930f7692b86a6a011257adc0f1
|
[
"MIT"
] | null | null | null |
scraps/demo/joypad.asm
|
stoneface86/gbsoundengine
|
774a9ea67143e5930f7692b86a6a011257adc0f1
|
[
"MIT"
] | null | null | null |
INCLUDE "hardware.inc"
SECTION "joypad", ROM0
debounce: MACRO
REPT 4 ; increase if debouncing occurs
ld a, [rP1]
ENDR
ENDM
; pressed: ~prev | current
; released: ~(~prev & current)
joypad_init::
push hl
ld a, $FF
ld hl, wJoypadState
REPT 3
ld [hl+], a
ENDR
pop hl
ret
joypad_read::
ld c, $F0 ; mask to set the upper bits to 1
ld a, P1F_GET_BTN ; read button states
ld [rP1], a
debounce
or a, c ; mask
ld b, a ; save for later
swap b ; button states are in the upper bits
ld a, P1F_GET_DPAD ; read dpad state
ld [rP1], a
debounce
or a, c ; mask
and b ; combine dpad states with button states
ld b, a ; b = current joypad state
ld a, [wJoypadState] ; a = last joypad state
cpl ; compliment and OR with the current
ld c, a ; c = ~previous
or b
ld [wJoypadPressed], a ; store into pressed variable
ld a, c ; a = ~previous
and b ; and it with the current state
cpl ; compliment again
ld [wJoypadReleased], a ; store into released
ld a, b
ld [wJoypadState], a ; store current in wram variable
ret
SECTION "joypad_wram", WRAM0
; these variables are active LOW, meaning that 0 = down/pressed/released
; layout
; bit 7: start
; bit 6: select
; bit 5: b
; bit 4: a
; bit 3: down
; bit 2: up
; bit 1: left
; bit 0: right
; contains the states of all buttons currently held down
wJoypadState:: DS 1
; contains which buttons were pressed (up -> down) for the current frame
wJoypadPressed:: DS 1
; contains which buttons were released (down -> up) for the current frame
wJoypadReleased:: DS 1
| 25.888889
| 76
| 0.504053
|
5f1f950138921e412e7bc56ac025d6121883c57e
| 312
|
asm
|
Assembly
|
programs/oeis/095/A095311.asm
|
neoneye/loda
|
afe9559fb53ee12e3040da54bd6aa47283e0d9ec
|
[
"Apache-2.0"
] | 22
|
2018-02-06T19:19:31.000Z
|
2022-01-17T21:53:31.000Z
|
programs/oeis/095/A095311.asm
|
neoneye/loda
|
afe9559fb53ee12e3040da54bd6aa47283e0d9ec
|
[
"Apache-2.0"
] | 41
|
2021-02-22T19:00:34.000Z
|
2021-08-28T10:47:47.000Z
|
programs/oeis/095/A095311.asm
|
neoneye/loda
|
afe9559fb53ee12e3040da54bd6aa47283e0d9ec
|
[
"Apache-2.0"
] | 5
|
2021-02-24T21:14:16.000Z
|
2021-08-09T19:48:05.000Z
|
; A095311: 47-gonal numbers.
; 1,47,138,274,455,681,952,1268,1629,2035,2486,2982,3523,4109,4740,5416,6137,6903,7714,8570,9471,10417,11408,12444,13525,14651,15822,17038,18299,19605,20956,22352,23793,25279,26810,28386,30007,31673,33384
mov $1,45
mul $1,$0
add $1,2
mov $2,$0
add $2,1
mul $1,$2
div $1,2
mov $0,$1
| 26
| 204
| 0.724359
|
c03019ba4005854f71fc017abc76c389ed1bdb0a
| 571
|
asm
|
Assembly
|
programs/oeis/003/A003589.asm
|
karttu/loda
|
9c3b0fc57b810302220c044a9d17db733c76a598
|
[
"Apache-2.0"
] | null | null | null |
programs/oeis/003/A003589.asm
|
karttu/loda
|
9c3b0fc57b810302220c044a9d17db733c76a598
|
[
"Apache-2.0"
] | null | null | null |
programs/oeis/003/A003589.asm
|
karttu/loda
|
9c3b0fc57b810302220c044a9d17db733c76a598
|
[
"Apache-2.0"
] | null | null | null |
; A003589: a(n) has the property that the sequence b(n) = number of 2's between successive 3's is the same as the original sequence.
; 2,2,3,2,2,3,2,2,3,2,2,2,3,2,2,3,2,2,3,2,2,2,3,2,2,3,2,2,3,2,2,2,3,2,2,3,2,2,3,2,2,3,2,2,2,3,2,2,3,2,2,3,2,2,2,3,2,2,3,2
mov $2,$0
mov $5,2
lpb $5,1
mov $0,$2
sub $5,1
add $0,$5
sub $0,1
mov $3,1
mov $4,$0
add $0,3
add $3,$4
add $3,$0
div $4,8
add $4,$3
mov $0,$4
div $0,7
mul $0,5
mov $6,$0
mov $7,$5
lpb $7,1
mov $1,$6
sub $7,1
lpe
lpe
lpb $2,1
sub $1,$6
mov $2,0
lpe
div $1,5
add $1,2
| 16.794118
| 132
| 0.530648
|
12b223cc1f8fb6e1977fe6163be006733bfc316f
| 522
|
asm
|
Assembly
|
programs/oeis/262/A262770.asm
|
karttu/loda
|
9c3b0fc57b810302220c044a9d17db733c76a598
|
[
"Apache-2.0"
] | 1
|
2021-03-15T11:38:20.000Z
|
2021-03-15T11:38:20.000Z
|
programs/oeis/262/A262770.asm
|
karttu/loda
|
9c3b0fc57b810302220c044a9d17db733c76a598
|
[
"Apache-2.0"
] | null | null | null |
programs/oeis/262/A262770.asm
|
karttu/loda
|
9c3b0fc57b810302220c044a9d17db733c76a598
|
[
"Apache-2.0"
] | null | null | null |
; A262770: A Beatty sequence: a(n)=floor(n*p) where p=2*cos(Pi/7)=A160389.
; 0,1,3,5,7,9,10,12,14,16,18,19,21,23,25,27,28,30,32,34,36,37,39,41,43,45,46,48,50,52,54,55,57,59,61,63,64,66,68,70,72,73,75,77,79,81,82,84,86,88,90,91,93,95,97,99,100,102,104,106,108,109,111,113,115,117,118,120,122,124,126,127,129,131,133,135,136,138,140,142,144,145,147,149,151,153,154,156,158,160,162,163,165,167,169,171,172,174,176,178,180,181,183,185,187,189,191
mov $1,$0
sub $0,1
div $0,105
mov $2,$1
mul $2,9
div $2,5
add $0,$2
mov $1,$0
| 43.5
| 367
| 0.67433
|
94c24728bf6b9f2fe947a9b9a6b78b8693327a32
| 818
|
asm
|
Assembly
|
initcode.asm
|
dylsugar/cs461_hw6
|
7935498fa371ac4eada4e8b0d73d92f5f0ed592b
|
[
"MIT-0"
] | null | null | null |
initcode.asm
|
dylsugar/cs461_hw6
|
7935498fa371ac4eada4e8b0d73d92f5f0ed592b
|
[
"MIT-0"
] | null | null | null |
initcode.asm
|
dylsugar/cs461_hw6
|
7935498fa371ac4eada4e8b0d73d92f5f0ed592b
|
[
"MIT-0"
] | null | null | null |
initcode.o: file format elf64-x86-64
Disassembly of section .text:
0000000000000000 <start>:
#include "traps.h"
# exec(init, argv)
.global start
start:
mov $init, %rdi
0: 48 c7 c7 00 00 00 00 mov $0x0,%rdi
mov $argv, %rsi
7: 48 c7 c6 00 00 00 00 mov $0x0,%rsi
mov $SYS_exec, %rax
e: 48 c7 c0 07 00 00 00 mov $0x7,%rax
syscall
15: 0f 05 syscall
0000000000000017 <exit>:
# for(;;) exit();
exit:
mov $SYS_exit, %rax
17: 48 c7 c0 02 00 00 00 mov $0x2,%rax
syscall
1e: 0f 05 syscall
jmp exit
20: eb f5 jmp 17 <exit>
0000000000000022 <init>:
22: 2f (bad)
23: 69 6e 69 74 00 00 0f imul $0xf000074,0x69(%rsi),%ebp
2a: 1f (bad)
...
000000000000002c <argv>:
...
| 19.95122
| 61
| 0.545232
|
1dabb3ef1caa0fd4ed5ff185c2ca283a315a5c2e
| 735
|
asm
|
Assembly
|
lab4/es1.asm
|
neskov7/AssemblyProgramsCE
|
35b7ea5afe8d30d630a148244bfe0fec07da76a4
|
[
"MIT"
] | null | null | null |
lab4/es1.asm
|
neskov7/AssemblyProgramsCE
|
35b7ea5afe8d30d630a148244bfe0fec07da76a4
|
[
"MIT"
] | null | null | null |
lab4/es1.asm
|
neskov7/AssemblyProgramsCE
|
35b7ea5afe8d30d630a148244bfe0fec07da76a4
|
[
"MIT"
] | null | null | null |
.model small
.stack
.data
a dw -2
b dw 1
c dw 2
m4 db 4
nonRealeMessage db 'no radici reali!!!!!!'
realeMessage db 'si radici reali!!!!!!'
errorDD db 'delta non rappresentabile in word!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! '
.code
.startup
mov di,0
mov ax,b
imul b
jc erroreDD
mov dx, ax
mov ax,a
imul c
imul m4
sub dx,ax
cmp dx,0
jl nonRappresentabile
rappresentabile:
mov ah,02h
lea si,realeMessage
mov cx,16
jmp stampa
erroreDD:
mov ah,02h
lea si, errorDD
mov cx , 30
jmp stampa
nonRappresentabile:
mov ah,02h
lea si, nonRealeMessage
mov cx , 16
jmp stampa
stampa:
mov dl, [si]
int 21h
inc si
loop stampa
jmp fine
fine:
.exit
end
| 12.04918
| 92
| 0.598639
|
68b8ce611ed919776b1e8cd6902eac656f3329ef
| 685
|
asm
|
Assembly
|
oeis/166/A166149.asm
|
neoneye/loda-programs
|
84790877f8e6c2e821b183d2e334d612045d29c0
|
[
"Apache-2.0"
] | 11
|
2021-08-22T19:44:55.000Z
|
2022-03-20T16:47:57.000Z
|
oeis/166/A166149.asm
|
neoneye/loda-programs
|
84790877f8e6c2e821b183d2e334d612045d29c0
|
[
"Apache-2.0"
] | 9
|
2021-08-29T13:15:54.000Z
|
2022-03-09T19:52:31.000Z
|
oeis/166/A166149.asm
|
neoneye/loda-programs
|
84790877f8e6c2e821b183d2e334d612045d29c0
|
[
"Apache-2.0"
] | 3
|
2021-08-22T20:56:47.000Z
|
2021-09-29T06:26:12.000Z
|
; A166149: a(n) = (5^n + 10*(-6)^n)/11.
; Submitted by Jon Maiga
; 1,-5,35,-185,1235,-6785,43835,-247385,1562435,-8983985,55857035,-325376585,2001087635,-11762385185,71795014235,-424666569785,2578516996835,-15318514090385,92674023995435,-552229446706985,3332450166570035,-19899333567779585,119872838564880635,-716852845598268185,4313038002544687235,-25818623370492732785,155209763446833349835,-929768464561615333385,5586061367966615828435,-33479115304815075829985,201060956343813550683035,-1205434415488265825582585,7237263105802672346073635
mov $1,1
lpb $0
sub $0,1
add $2,1
mul $2,-1
mov $3,$1
mul $1,5
mul $2,3
add $3,$2
sub $3,1
add $2,$3
lpe
mov $0,$2
add $0,1
| 36.052632
| 476
| 0.772263
|
e5556d88c4b5ce8bc146bdb9d1b0ff38816080e9
| 582
|
asm
|
Assembly
|
oeis/173/A173275.asm
|
neoneye/loda-programs
|
84790877f8e6c2e821b183d2e334d612045d29c0
|
[
"Apache-2.0"
] | 11
|
2021-08-22T19:44:55.000Z
|
2022-03-20T16:47:57.000Z
|
oeis/173/A173275.asm
|
neoneye/loda-programs
|
84790877f8e6c2e821b183d2e334d612045d29c0
|
[
"Apache-2.0"
] | 9
|
2021-08-29T13:15:54.000Z
|
2022-03-09T19:52:31.000Z
|
oeis/173/A173275.asm
|
neoneye/loda-programs
|
84790877f8e6c2e821b183d2e334d612045d29c0
|
[
"Apache-2.0"
] | 3
|
2021-08-22T20:56:47.000Z
|
2021-09-29T06:26:12.000Z
|
; A173275: a(n) = 169*n^2 + n.
; 170,678,1524,2708,4230,6090,8288,10824,13698,16910,20460,24348,28574,33138,38040,43280,48858,54774,61028,67620,74550,81818,89424,97368,105650,114270,123228,132524,142158,152130,162440,173088,184074,195398,207060,219060,231398,244074,257088,270440,284130,298158,312524,327228,342270,357650,373368,389424,405818,422550,439620,457028,474774,492858,511280,530040,549138,568574,588348,608460,628910,649698,670824,692288,714090,736230,758708,781524,804678,828170,852000,876168,900674,925518,950700,976220
add $0,1
mov $2,$0
mul $0,169
add $0,1
mul $0,$2
| 64.666667
| 500
| 0.798969
|
b294253b90fa67a2169a7767552ed3351df8cefe
| 720
|
asm
|
Assembly
|
programs/oeis/089/A089090.asm
|
jmorken/loda
|
99c09d2641e858b074f6344a352d13bc55601571
|
[
"Apache-2.0"
] | 1
|
2021-03-15T11:38:20.000Z
|
2021-03-15T11:38:20.000Z
|
programs/oeis/089/A089090.asm
|
jmorken/loda
|
99c09d2641e858b074f6344a352d13bc55601571
|
[
"Apache-2.0"
] | null | null | null |
programs/oeis/089/A089090.asm
|
jmorken/loda
|
99c09d2641e858b074f6344a352d13bc55601571
|
[
"Apache-2.0"
] | null | null | null |
; A089090: a(n) is the smallest composite number coprime to n.
; 4,9,4,9,4,25,4,9,4,9,4,25,4,9,4,9,4,25,4,9,4,9,4,25,4,9,4,9,4,49,4,9,4,9,4,25,4,9,4,9,4,25,4,9,4,9,4,25,4,9,4,9,4,25,4,9,4,9,4,49,4,9,4,9,4,25,4,9,4,9,4,25,4,9,4,9,4,25,4,9,4,9,4,25,4,9,4,9,4,49,4,9,4,9,4,25,4,9,4,9,4,25,4,9,4,9,4,25,4,9,4,9,4,25,4,9,4,9,4,49,4,9,4,9,4,25,4,9,4,9,4,25,4,9,4,9,4,25,4,9,4,9,4,25,4,9,4,9,4,49,4,9,4,9,4,25,4,9,4,9,4,25,4,9,4,9,4,25,4,9,4,9,4,25,4,9,4,9,4,49,4,9,4,9,4,25,4,9,4,9,4,25,4,9,4,9,4,25,4,9,4,9,4,25,4,9,4,9,4,121,4,9,4,9,4,25,4,9,4,9,4,25,4,9,4,9,4,25,4,9,4,9,4,25,4,9,4,9,4,49,4,9,4,9,4,25,4,9,4,9
cal $0,53669 ; Smallest prime not dividing n.
add $2,$0
mul $2,$0
add $1,$2
mul $1,2
sub $1,8
div $1,2
add $1,4
| 60
| 543
| 0.566667
|
28f4d72b6417d78f0ddbe45d62a43c72a978f482
| 3,736
|
asm
|
Assembly
|
SE-2/MIL/15_ndp/ndpadi.asm
|
Adityajn/College-Codes
|
f40e1eee53b951f2101981230fc72201081fd5f7
|
[
"Unlicense"
] | 1
|
2017-02-22T18:22:39.000Z
|
2017-02-22T18:22:39.000Z
|
SE-2/MIL/15_ndp/ndpadi.asm
|
Adityajn/College-Codes
|
f40e1eee53b951f2101981230fc72201081fd5f7
|
[
"Unlicense"
] | null | null | null |
SE-2/MIL/15_ndp/ndpadi.asm
|
Adityajn/College-Codes
|
f40e1eee53b951f2101981230fc72201081fd5f7
|
[
"Unlicense"
] | null | null | null |
%macro inout 4
push rax
push rbx
push rcx
push rdx
mov eax,%1
mov ebx,%2
mov ecx,%3
mov edx,%4
int 80h
pop rdx
pop rcx
pop rbx
pop rax
%endmacro
section .data
arr dd 123.44,152.56,456.23
tn dd 3.0
mean db "Mean is:",20h
meanlen equ $-mean
msg1 db "1.Enter your choice-",10,"1.Mean",10,"2.Variance",10,"3.Standard Deviation",10,"4.Exit",10
msg1len equ $-msg1
means dd 0.0
res dt 0.0
vares dt 0.0
stres dt 0.0
save dd 0.0
point db "."
pointl equ $-point
thousand dd 10000.0
variance dd 0.0
deviation dd 0.0
nwln db 10
nwlen equ $-nwln
section .bss
cho resb 2
by resb 1
section .text
global _start
_start:
inout 4,1,msg1,msg1len
inout 3,0,cho,2
cmp byte[cho],32h
je var
cmp byte[cho],33h
je std
ja exit
FINIT ;initialize NDP
FLDZ ;Initialize ST(0) with 0.0
mov esi,arr ;esi points to starting of arr
mov cx,3h ;initialize counter
again: FADD dword[esi] ;add first dword into ST(0)
add esi,4 ;increment esi to next dword
dec cx ;decrement counter
jnz again
FDIV dword[tn] ;div sum of numbers by total numbers
FST dword[mean] ;store ST(0) in mean buffer
FMUL dword[thousand] ;multiply ST(0) with 10000
FBSTP tword[res] ;Convert real data into BCD and pop to tword-res
mov esi,res ;initialize pointer to res
call dispdec ;call routine to display BCD no in tword
inout 4,1,nwln,nwlen
jmp _start
var: mov cx,3 ;initialize counter with 3
mov esi,arr ;initialize pointer esi to arr
aga:
FLDZ ;initialize ST(0) with 0.0
FLD dword[esi] ;Load dword pointer by esi in ST(0)
FSUB dword[mean] ;ST(0) <-- ST(0)-mean
FST dword[save] ;store ST(0) in dword-save
FMUL dword[save] ;ST(0) <-- ST(0)*save
FADD dword[variance] ;ST(0) <-- ST(0)+variance
FST dword[variance] ;variance <--ST(0)
add esi,4 ;increment pointer with 4
dec cx ;decrement counter
jnz aga
FDIV dword[tn] ;divide ST(0) by total num
FMUL dword[thousand] ;Multiply ST(0) by 10000
FBSTP tword[vares] ;convert real data into BCD and pop to tword-vares
mov esi,vares ;esi points to tword-vares
call dispdec ;call routine to display BCD no (in tword)
inout 4,1,nwln,nwlen
jmp _start
std:
FLDZ ;initialize ST(0) with 0.0
FLD dword[variance] ;load dword-variance in ST(0)
FSQRT ;ST(0) <-- sqrt(ST(0))
FST dword[deviation] ;store ST(0) in dword-deviation
FMUL dword[thousand] ;multiply ST(0) with 10000
FBSTP tword[stres] ;convert real data into BCD and pop tword-stres
mov esi,stres ;esi points to tword-stres
call dispdec ;call routine to display BCD no in tword
inout 4,1,nwln,nwlen
jmp _start
exit:
mov eax,1
mov ebx,0
int 80h
dispbyte: ;logic to display one byte of tword
mov bl,byte[esi] ;copy byte into bl
rol bl,4 ;to display upper BCD digit
and bl,0fh ;mask upper digit
add bl,30h ;convert digit to ASCII
mov byte[by],bl ;mov ASCII digit to byte[by]
inout 4,1,by,1 ;display digit
mov bl,byte[esi] ;again copy byte into bl
and bl,0fh ;mask upper digit
add bl,30h ;convert digit to ASCII
mov byte[by],bl ;mov ASCII digit to byte[by]
inout 4,1,by,1 ;display digit
ret
dispdec: ;logic to choose which byte to dislpay
add esi,9 ;increment esi so that it points to last digit
mov cx,0Ah ;intialize counter with 10
jmp ok
again2: dec esi ;decrement pointer
dec cx ;decremetn counter
jz done
ok: cmp byte[esi],0 ;compare byte with 00
je again2 ;skip until byte!=0 comes
again3: call dispbyte ;call routine to display byte
dec esi ;decremnent pointer
dec cx ;decrement counter
cmp cx,2 ;if counter =2 display point
jne again3
dpoint: inout 4,1,point,pointl
done:
again4: call dispbyte ;call routine to display byte
dec esi ;decrement pointer
dec cx ;decrement counter
jnz again4
ret
| 23.496855
| 99
| 0.7053
|
9cabb5bdf79b7c70c83bb53d728425a56769105c
| 101
|
asm
|
Assembly
|
kamehameha.x86-32.asm
|
brightprogrammer/r2wars-bots
|
2c4cac045a20d7a92f31780592179ddd64b09aa0
|
[
"CC0-1.0"
] | null | null | null |
kamehameha.x86-32.asm
|
brightprogrammer/r2wars-bots
|
2c4cac045a20d7a92f31780592179ddd64b09aa0
|
[
"CC0-1.0"
] | null | null | null |
kamehameha.x86-32.asm
|
brightprogrammer/r2wars-bots
|
2c4cac045a20d7a92f31780592179ddd64b09aa0
|
[
"CC0-1.0"
] | null | null | null |
mov eax, 0x100
mov esp, eax
mov ebp, 0xe4ff6060
mov esi, 0x6060e046
mov edi, 0x0f60fc83
pusha
jmp esp
| 14.428571
| 19
| 0.782178
|
69ab81ee316979f00307a94b4983a15063e9fc0a
| 762
|
asm
|
Assembly
|
programs/oeis/032/A032608.asm
|
jmorken/loda
|
99c09d2641e858b074f6344a352d13bc55601571
|
[
"Apache-2.0"
] | 1
|
2021-03-15T11:38:20.000Z
|
2021-03-15T11:38:20.000Z
|
programs/oeis/032/A032608.asm
|
jmorken/loda
|
99c09d2641e858b074f6344a352d13bc55601571
|
[
"Apache-2.0"
] | null | null | null |
programs/oeis/032/A032608.asm
|
jmorken/loda
|
99c09d2641e858b074f6344a352d13bc55601571
|
[
"Apache-2.0"
] | null | null | null |
; A032608: Concatenation of n and n + 3.
; 14,25,36,47,58,69,710,811,912,1013,1114,1215,1316,1417,1518,1619,1720,1821,1922,2023,2124,2225,2326,2427,2528,2629,2730,2831,2932,3033,3134,3235,3336,3437,3538,3639,3740,3841,3942,4043,4144,4245
mov $2,$0
add $2,1
mov $8,$0
lpb $2
mov $0,$8
sub $2,1
sub $0,$2
mov $9,$0
mov $11,2
lpb $11
mov $0,$9
sub $11,1
add $0,$11
sub $0,1
mov $3,8
lpb $0
mov $5,$0
mov $0,5
mul $5,5
add $5,5
mul $5,6
add $5,1
mov $7,$5
mul $7,8
mov $3,$7
lpe
mov $4,$11
mov $6,$3
lpb $4
sub $4,1
mov $10,$6
lpe
lpe
lpb $9
mov $9,0
sub $10,$6
lpe
mov $6,$10
div $6,8
mul $6,3
add $6,11
add $1,$6
lpe
| 16.212766
| 196
| 0.511811
|
9c08cfed928b06ee2baf48d250ff77f3a0ae8773
| 700
|
asm
|
Assembly
|
oeis/049/A049392.asm
|
neoneye/loda-programs
|
84790877f8e6c2e821b183d2e334d612045d29c0
|
[
"Apache-2.0"
] | 11
|
2021-08-22T19:44:55.000Z
|
2022-03-20T16:47:57.000Z
|
oeis/049/A049392.asm
|
neoneye/loda-programs
|
84790877f8e6c2e821b183d2e334d612045d29c0
|
[
"Apache-2.0"
] | 9
|
2021-08-29T13:15:54.000Z
|
2022-03-09T19:52:31.000Z
|
oeis/049/A049392.asm
|
neoneye/loda-programs
|
84790877f8e6c2e821b183d2e334d612045d29c0
|
[
"Apache-2.0"
] | 3
|
2021-08-22T20:56:47.000Z
|
2021-09-29T06:26:12.000Z
|
; A049392: Expansion of (1-25*x)^(2/5).
; Submitted by Jon Maiga
; 1,-10,-75,-1000,-16250,-292500,-5606250,-112125000,-2312578125,-48821093750,-1049653515625,-22901531250000,-505742148437500,-11281940234375000,-253843655273437500,-5753789519531250000,-131258323414306640625,-3011220360681152343750,-69425358315704345703125,-1607745139942626953125000,-37380074503666076660156250,-872201738418875122070312500,-20417449785714576721191406250,-479366212360255279541015625000,-11285079582647676372528076171875,-266327878150485162391662597656250
mul $0,2
mov $1,1
mov $2,2
mov $3,$0
mov $4,5
lpb $3
mul $1,$2
mul $1,$4
sub $3,2
mov $4,$2
sub $5,1
div $1,$5
sub $2,5
sub $4,$2
lpe
mov $0,$1
| 33.333333
| 473
| 0.772857
|
007c43a7ec2b0fbbaa2f0235fb8d5eb921da62ee
| 712
|
asm
|
Assembly
|
programs/oeis/059/A059867.asm
|
neoneye/loda
|
afe9559fb53ee12e3040da54bd6aa47283e0d9ec
|
[
"Apache-2.0"
] | 22
|
2018-02-06T19:19:31.000Z
|
2022-01-17T21:53:31.000Z
|
programs/oeis/059/A059867.asm
|
neoneye/loda
|
afe9559fb53ee12e3040da54bd6aa47283e0d9ec
|
[
"Apache-2.0"
] | 41
|
2021-02-22T19:00:34.000Z
|
2021-08-28T10:47:47.000Z
|
programs/oeis/059/A059867.asm
|
neoneye/loda
|
afe9559fb53ee12e3040da54bd6aa47283e0d9ec
|
[
"Apache-2.0"
] | 5
|
2021-02-24T21:14:16.000Z
|
2021-08-09T19:48:05.000Z
|
; A059867: Number of irreducible representations of the symmetric group S_n that have odd degree.
; 1,2,2,4,4,8,8,8,8,16,16,32,32,64,64,16,16,32,32,64,64,128,128,128,128,256,256,512,512,1024,1024,32,32,64,64,128,128,256,256,256,256,512,512,1024,1024,2048,2048,512,512,1024,1024,2048,2048,4096,4096,4096,4096,8192,8192,16384,16384,32768,32768,64,64,128,128,256,256,512,512,512,512,1024,1024,2048,2048,4096,4096,1024,1024,2048,2048,4096,4096,8192,8192,8192,8192,16384,16384,32768,32768,65536,65536,2048,2048,4096,4096,8192
add $0,1
div $0,2
mul $0,2
seq $0,73642 ; Replace 2^k in the binary representation of n with k (i.e., if n = 2^a + 2^b + 2^c + ... then a(n) = a + b + c + ...).
mov $1,2
pow $1,$0
mov $0,$1
| 64.727273
| 422
| 0.705056
|
5f9c34f5c336b70cb447706a2f95cd98131e1f4b
| 308
|
asm
|
Assembly
|
data/wild/maps/VictoryRoad3F.asm
|
opiter09/ASM-Machina
|
75d8e457b3e82cc7a99b8e70ada643ab02863ada
|
[
"CC0-1.0"
] | 1
|
2022-02-15T00:19:44.000Z
|
2022-02-15T00:19:44.000Z
|
data/wild/maps/VictoryRoad3F.asm
|
opiter09/ASM-Machina
|
75d8e457b3e82cc7a99b8e70ada643ab02863ada
|
[
"CC0-1.0"
] | null | null | null |
data/wild/maps/VictoryRoad3F.asm
|
opiter09/ASM-Machina
|
75d8e457b3e82cc7a99b8e70ada643ab02863ada
|
[
"CC0-1.0"
] | null | null | null |
VictoryRoad3FWildMons:
def_grass_wildmons 0 ;15 ; encounter rate
;db 24, MACHOP
;db 26, GEODUDE
;db 22, ZUBAT
;db 42, ONIX
;db 40, VENOMOTH
;db 45, ONIX
;db 43, GRAVELER
;db 41, GOLBAT
;db 42, MACHOKE
;db 45, MACHOKE
end_grass_wildmons
def_water_wildmons 0 ; encounter rate
end_water_wildmons
| 18.117647
| 42
| 0.730519
|
e89e3333c243f237e588c146ed9e17ec6e8037c1
| 8,297
|
asm
|
Assembly
|
Transynther/x86/_processed/NC/_ht_zr_un_/i7-7700_9_0xca.log_21829_555.asm
|
ljhsiun2/medusa
|
67d769b8a2fb42c538f10287abaf0e6dbb463f0c
|
[
"MIT"
] | 9
|
2020-08-13T19:41:58.000Z
|
2022-03-30T12:22:51.000Z
|
Transynther/x86/_processed/NC/_ht_zr_un_/i7-7700_9_0xca.log_21829_555.asm
|
ljhsiun2/medusa
|
67d769b8a2fb42c538f10287abaf0e6dbb463f0c
|
[
"MIT"
] | 1
|
2021-04-29T06:29:35.000Z
|
2021-05-13T21:02:30.000Z
|
Transynther/x86/_processed/NC/_ht_zr_un_/i7-7700_9_0xca.log_21829_555.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 %r8
push %rbx
push %rcx
push %rdi
push %rdx
push %rsi
lea addresses_UC_ht+0x1b732, %rbx
nop
nop
sub $31082, %rsi
and $0xffffffffffffffc0, %rbx
movaps (%rbx), %xmm7
vpextrq $1, %xmm7, %r14
nop
nop
nop
mfence
lea addresses_WT_ht+0x13612, %r13
clflush (%r13)
nop
nop
nop
nop
add %rsi, %rsi
mov $0x6162636465666768, %rbx
movq %rbx, %xmm3
and $0xffffffffffffffc0, %r13
vmovntdq %ymm3, (%r13)
sub $64339, %r13
lea addresses_WT_ht+0x17a60, %rsi
lea addresses_normal_ht+0x145f2, %rdi
xor %r14, %r14
mov $70, %rcx
rep movsw
nop
nop
nop
nop
nop
cmp $39803, %rbx
lea addresses_UC_ht+0x5572, %r13
clflush (%r13)
nop
sub $27512, %rbx
mov $0x6162636465666768, %rcx
movq %rcx, %xmm0
vmovups %ymm0, (%r13)
nop
nop
add $11288, %rdi
lea addresses_normal_ht+0x8172, %rcx
inc %rsi
vmovups (%rcx), %ymm7
vextracti128 $0, %ymm7, %xmm7
vpextrq $1, %xmm7, %r13
nop
nop
nop
nop
add $6412, %r13
lea addresses_D_ht+0x13372, %rsi
lea addresses_WT_ht+0x1d572, %rdi
nop
nop
and %rdx, %rdx
mov $35, %rcx
rep movsl
nop
nop
nop
nop
and $8944, %r8
lea addresses_D_ht+0x4ff2, %rsi
lea addresses_WT_ht+0x14c72, %rdi
nop
nop
and %r8, %r8
mov $126, %rcx
rep movsw
nop
add %r13, %r13
lea addresses_WC_ht+0x17d72, %r13
nop
cmp %rdi, %rdi
mov (%r13), %rcx
xor $29747, %r13
lea addresses_UC_ht+0x1c244, %rsi
lea addresses_WT_ht+0x6fb2, %rdi
nop
nop
nop
and %rdx, %rdx
mov $7, %rcx
rep movsb
nop
nop
nop
nop
nop
and $26607, %r13
lea addresses_WC_ht+0x153f2, %rbx
nop
nop
nop
xor $26886, %rdi
mov (%rbx), %r13
nop
nop
nop
nop
nop
sub $23205, %rdx
lea addresses_normal_ht+0x4dd2, %rdi
nop
xor $16756, %rdx
vmovups (%rdi), %ymm1
vextracti128 $1, %ymm1, %xmm1
vpextrq $0, %xmm1, %r8
xor $57599, %rcx
pop %rsi
pop %rdx
pop %rdi
pop %rcx
pop %rbx
pop %r8
pop %r14
pop %r13
ret
.global s_faulty_load
s_faulty_load:
push %r8
push %r9
push %rax
push %rbp
push %rbx
push %rcx
push %rdx
// Store
mov $0x73c23e0000000d72, %r9
nop
cmp $42261, %rbx
movw $0x5152, (%r9)
nop
nop
nop
nop
nop
add %rbx, %rbx
// Store
lea addresses_UC+0x7606, %rbx
clflush (%rbx)
nop
nop
sub %rax, %rax
mov $0x5152535455565758, %rbp
movq %rbp, (%rbx)
cmp %rbx, %rbx
// Store
lea addresses_US+0x87c6, %r8
nop
nop
nop
nop
nop
dec %rcx
movb $0x51, (%r8)
nop
cmp $60026, %rbp
// Load
lea addresses_UC+0x13072, %r8
nop
nop
cmp $63021, %rdx
movups (%r8), %xmm5
vpextrq $1, %xmm5, %rcx
nop
nop
nop
nop
add %rbp, %rbp
// Store
lea addresses_PSE+0x8984, %rbx
nop
sub %rax, %rax
mov $0x5152535455565758, %r8
movq %r8, (%rbx)
nop
nop
nop
nop
xor %rcx, %rcx
// Faulty Load
mov $0x73c23e0000000d72, %rax
nop
and $32279, %r8
vmovups (%rax), %ymm1
vextracti128 $1, %ymm1, %xmm1
vpextrq $1, %xmm1, %rbp
lea oracles, %rdx
and $0xff, %rbp
shlq $12, %rbp
mov (%rdx,%rbp,1), %rbp
pop %rdx
pop %rcx
pop %rbx
pop %rbp
pop %rax
pop %r9
pop %r8
ret
/*
<gen_faulty_load>
[REF]
{'src': {'congruent': 0, 'AVXalign': False, 'same': False, 'size': 16, 'NT': False, 'type': 'addresses_NC'}, 'OP': 'LOAD'}
{'OP': 'STOR', 'dst': {'congruent': 0, 'AVXalign': False, 'same': True, 'size': 2, 'NT': True, 'type': 'addresses_NC'}}
{'OP': 'STOR', 'dst': {'congruent': 2, 'AVXalign': False, 'same': False, 'size': 8, 'NT': False, 'type': 'addresses_UC'}}
{'OP': 'STOR', 'dst': {'congruent': 1, 'AVXalign': False, 'same': False, 'size': 1, 'NT': False, 'type': 'addresses_US'}}
{'src': {'congruent': 7, 'AVXalign': False, 'same': False, 'size': 16, 'NT': False, 'type': 'addresses_UC'}, 'OP': 'LOAD'}
{'OP': 'STOR', 'dst': {'congruent': 0, 'AVXalign': False, 'same': False, 'size': 8, 'NT': True, 'type': 'addresses_PSE'}}
[Faulty Load]
{'src': {'congruent': 0, 'AVXalign': False, 'same': True, 'size': 32, 'NT': False, 'type': 'addresses_NC'}, 'OP': 'LOAD'}
<gen_prepare_buffer>
{'src': {'congruent': 6, 'AVXalign': True, 'same': False, 'size': 16, 'NT': False, 'type': 'addresses_UC_ht'}, 'OP': 'LOAD'}
{'OP': 'STOR', 'dst': {'congruent': 5, 'AVXalign': False, 'same': False, 'size': 32, 'NT': True, 'type': 'addresses_WT_ht'}}
{'src': {'congruent': 1, 'same': False, 'type': 'addresses_WT_ht'}, 'OP': 'REPM', 'dst': {'congruent': 7, 'same': False, 'type': 'addresses_normal_ht'}}
{'OP': 'STOR', 'dst': {'congruent': 11, 'AVXalign': False, 'same': False, 'size': 32, 'NT': False, 'type': 'addresses_UC_ht'}}
{'src': {'congruent': 10, 'AVXalign': False, 'same': False, 'size': 32, 'NT': False, 'type': 'addresses_normal_ht'}, 'OP': 'LOAD'}
{'src': {'congruent': 6, 'same': False, 'type': 'addresses_D_ht'}, 'OP': 'REPM', 'dst': {'congruent': 9, 'same': False, 'type': 'addresses_WT_ht'}}
{'src': {'congruent': 6, 'same': False, 'type': 'addresses_D_ht'}, 'OP': 'REPM', 'dst': {'congruent': 8, 'same': False, 'type': 'addresses_WT_ht'}}
{'src': {'congruent': 11, 'AVXalign': False, 'same': False, 'size': 8, 'NT': False, 'type': 'addresses_WC_ht'}, 'OP': 'LOAD'}
{'src': {'congruent': 1, 'same': False, 'type': 'addresses_UC_ht'}, 'OP': 'REPM', 'dst': {'congruent': 6, 'same': False, 'type': 'addresses_WT_ht'}}
{'src': {'congruent': 6, 'AVXalign': False, 'same': True, 'size': 8, 'NT': False, 'type': 'addresses_WC_ht'}, 'OP': 'LOAD'}
{'src': {'congruent': 0, 'AVXalign': False, 'same': False, 'size': 32, 'NT': False, 'type': 'addresses_normal_ht'}, 'OP': 'LOAD'}
{'44': 181, '46': 1425, '06': 1, '00': 20220, '40': 1, '04': 1}
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 44 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 44 00 00 46 00 00 00 00 46 46 00 00 00 00 00 00 46 00 00 00 00 00 00 00 00 46 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 46 00 00 00 00 00 00 00 00 00 00 00 00 00 00 46 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 46 00 00 00 46 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 46 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 46 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 46 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 46 00 00 00 00 46 00 00 00 00 46 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 46 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 46 00 00 00 00 00 00 00 00 00 46 00 00 00 46 00 00 00 00 46 00 44 00 00 00 44 00 00 00 00 00 00 00 00 00 00 00 46 00 00 00 00 00 00 00 00 00 00 00 00 46 46 46 00 00 00 00 00 00 00 44 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 46 00 00 00 00 00 46 00 00 00 00 46 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 46 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 44 00 00 00 46 00 00 00 00 00 00 00 00 00 00 46 00 00 00 00 00 00 00 00 46 00 00 00 00 00 00 00 00 00 00 46 00 00 00 00 00 00 00 00 00 00 46 00 46 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 46 00 46 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 46 00 46 00 00 00 00 00 00 00 00 00 00 00 44 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 46 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 46 00 00 46 00 00 00 00 46 00 00 00 00 00 46 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 46 46 00 00 00 00 00 00 00 00 46 00 00 00 00 00 00 00 00 00 46 00 00 00 00 00 00 00 00 00 00 00 00 00 46 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 46 00 00 00 00 00 44 00 00 00 00 00 00 00 00 00 46 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 46 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 46 00 46 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 46 00 00 00 00 00 00 00 00 00 00 00 00 46 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 46 00 00 00 46 00 00 46 00 00 00 00 00 00 00 00 00 00 00 00 46 00 00 00 00 46 00 00 00 00 00 46 00 00 00 00 00 00 00 46 00 00 00 46 00 00 46 00 00 44 00 00 00 00 00 00 00 46 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 46 00 00 46 46 00 00 00 00 46 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 46
*/
| 33.321285
| 2,999
| 0.654453
|
cee6e7e5c449c8192fcb37172112f09527c54c1b
| 321
|
asm
|
Assembly
|
programs/oeis/084/A084857.asm
|
neoneye/loda
|
afe9559fb53ee12e3040da54bd6aa47283e0d9ec
|
[
"Apache-2.0"
] | 22
|
2018-02-06T19:19:31.000Z
|
2022-01-17T21:53:31.000Z
|
programs/oeis/084/A084857.asm
|
neoneye/loda
|
afe9559fb53ee12e3040da54bd6aa47283e0d9ec
|
[
"Apache-2.0"
] | 41
|
2021-02-22T19:00:34.000Z
|
2021-08-28T10:47:47.000Z
|
programs/oeis/084/A084857.asm
|
neoneye/loda
|
afe9559fb53ee12e3040da54bd6aa47283e0d9ec
|
[
"Apache-2.0"
] | 5
|
2021-02-24T21:14:16.000Z
|
2021-08-09T19:48:05.000Z
|
; A084857: Inverse binomial transform of n^2*3^(n-1).
; 0,1,10,48,176,560,1632,4480,11776,29952,74240,180224,430080,1011712,2351104,5406720,12320768,27852800,62521344,139460608,309329920,682622976,1499463680,3279945728,7147094016,15518924800,33587986432
mov $1,2
mov $2,$0
mul $0,3
bin $0,2
pow $1,$2
mul $0,$1
div $0,6
| 29.181818
| 199
| 0.760125
|
09998072d079ba8b9bb277841f49eaf9bbe0613d
| 271
|
nasm
|
Assembly
|
Projetos/F-Assembly/src/nasm/abs.nasm
|
juanjorgegarcia/Z01
|
7d49ef8f476f9c8e9f187a62f96fdca7bcd46314
|
[
"Unlicense"
] | null | null | null |
Projetos/F-Assembly/src/nasm/abs.nasm
|
juanjorgegarcia/Z01
|
7d49ef8f476f9c8e9f187a62f96fdca7bcd46314
|
[
"Unlicense"
] | 67
|
2018-03-13T21:40:05.000Z
|
2018-05-23T19:17:13.000Z
|
Projetos/F-Assembly/src/nasm/abs.nasm
|
juanjorgegarcia/Z01
|
7d49ef8f476f9c8e9f187a62f96fdca7bcd46314
|
[
"Unlicense"
] | 3
|
2018-03-07T01:27:37.000Z
|
2018-03-23T19:35:14.000Z
|
; Arquivo: Abs.nasm
; Curso: Elementos de Sistemas
; Criado por: Luciano Soares
; Data: 27/03/2017
; Copia o valor de RAM[1] para RAM[0] deixando o valor sempre positivo.
leaw $1,%A
movw (%A),%S
leaw $6,%A
jge %S
nop
negw %S
leaw $0,%A
movw %S,(%A)
nop
| 15.941176
| 72
| 0.627306
|
c4fb153497d4d34e8d3f6e7365a56be6c32723b4
| 864
|
asm
|
Assembly
|
programs/oeis/179/A179339.asm
|
neoneye/loda
|
afe9559fb53ee12e3040da54bd6aa47283e0d9ec
|
[
"Apache-2.0"
] | 22
|
2018-02-06T19:19:31.000Z
|
2022-01-17T21:53:31.000Z
|
programs/oeis/179/A179339.asm
|
neoneye/loda
|
afe9559fb53ee12e3040da54bd6aa47283e0d9ec
|
[
"Apache-2.0"
] | 41
|
2021-02-22T19:00:34.000Z
|
2021-08-28T10:47:47.000Z
|
programs/oeis/179/A179339.asm
|
neoneye/loda
|
afe9559fb53ee12e3040da54bd6aa47283e0d9ec
|
[
"Apache-2.0"
] | 5
|
2021-02-24T21:14:16.000Z
|
2021-08-09T19:48:05.000Z
|
; A179339: Positive integers of the form (30*m^2+1)/11.
; 11,221,461,1091,1571,2621,3341,4811,5771,7661,8861,11171,12611,15341,17021,20171,22091,25661,27821,31811,34211,38621,41261,46091,48971,54221,57341,63011,66371,72461,76061,82571,86411,93341,97421,104771,109091,116861,121421,129611,134411,143021,148061,157091,162371,171821,177341,187211,192971,203261,209261,219971,226211,237341,243821,255371,262091,274061,281021,293411,300611,313421,320861,334091,341771,355421,363341,377411,385571,400061,408461,423371,432011,447341,456221,471971,481091,497261,506621,523211,532811,549821,559661,577091,587171,605021,615341,633611,644171,662861,673661,692771,703811,723341,734621,754571,766091,786461,798221,819011
mov $1,2
add $1,$0
mov $2,$0
mov $3,$0
add $3,$0
mov $4,2
add $4,$3
div $4,4
add $2,$4
mul $2,3
add $1,$2
pow $1,2
div $1,11
mul $1,30
add $1,11
mov $0,$1
| 43.2
| 651
| 0.777778
|
703611acad4419eb925a2de984ba5d9fd34f1755
| 428
|
asm
|
Assembly
|
src/z80asm/dev/z80asm_lib/add_de_a.asm
|
Frodevan/z88dk
|
f27af9fe840ff995c63c80a73673ba7ee33fffac
|
[
"ClArtistic"
] | 38
|
2021-06-18T12:56:15.000Z
|
2022-03-12T20:38:40.000Z
|
src/z80asm/dev/z80asm_lib/add_de_a.asm
|
Frodevan/z88dk
|
f27af9fe840ff995c63c80a73673ba7ee33fffac
|
[
"ClArtistic"
] | 2
|
2021-06-20T16:28:12.000Z
|
2021-11-17T21:33:56.000Z
|
src/z80asm/dev/z80asm_lib/add_de_a.asm
|
Frodevan/z88dk
|
f27af9fe840ff995c63c80a73673ba7ee33fffac
|
[
"ClArtistic"
] | 6
|
2021-06-18T18:18:36.000Z
|
2021-12-22T08:01:32.000Z
|
; Substitute for the z80 add de,a instruction
; no flags are affected
; CPU Min T Max T
; 8080 74 74
; 8085 73 73
; gbz80 72 72
; r2k 52 52
; z180 69 69
; z80 71 71
; z80n 8 8
SECTION code_crt0_sccz80
PUBLIC __z80asm__add_de_a
__z80asm__add_de_a:
push af
add a, e
ld e, a
ld a, d
adc a, 0
ld d, a
pop af
ret
| 15.851852
| 45
| 0.511682
|
81ab94a31ff5c3417a461cbc099e093cd0927082
| 569
|
asm
|
Assembly
|
programs/oeis/003/A003842.asm
|
neoneye/loda
|
afe9559fb53ee12e3040da54bd6aa47283e0d9ec
|
[
"Apache-2.0"
] | 22
|
2018-02-06T19:19:31.000Z
|
2022-01-17T21:53:31.000Z
|
programs/oeis/003/A003842.asm
|
neoneye/loda
|
afe9559fb53ee12e3040da54bd6aa47283e0d9ec
|
[
"Apache-2.0"
] | 41
|
2021-02-22T19:00:34.000Z
|
2021-08-28T10:47:47.000Z
|
programs/oeis/003/A003842.asm
|
neoneye/loda
|
afe9559fb53ee12e3040da54bd6aa47283e0d9ec
|
[
"Apache-2.0"
] | 5
|
2021-02-24T21:14:16.000Z
|
2021-08-09T19:48:05.000Z
|
; A003842: The infinite Fibonacci word: start with 1, repeatedly apply the morphism 1->12, 2->1, take limit; or, start with S(0)=2, S(1)=1, and for n>1 define S(n)=S(n-1)S(n-2), then the sequence is S(oo).
; 1,2,1,1,2,1,2,1,1,2,1,1,2,1,2,1,1,2,1,2,1,1,2,1,1,2,1,2,1,1,2,1,1,2,1,2,1,1,2,1,2,1,1,2,1,1,2,1,2,1,1,2,1,2,1,1,2,1,1,2,1,2,1,1,2,1,1,2,1,2,1,1,2,1,2,1,1,2,1,1,2,1,2,1,1,2,1,1,2,1,2,1,1,2,1,2,1,1,2,1
lpb $0
mov $1,$0
mov $2,$0
seq $2,66628 ; a(n) = n - the largest Fibonacci number <= n.
mov $0,$2
lpe
lpb $1
mov $1,2
lpe
mod $1,2
add $1,1
mov $0,$1
| 35.5625
| 205
| 0.574692
|
6372f24f2f2291f7234c882eab72e28179593718
| 2,786
|
asm
|
Assembly
|
src/main.asm
|
munshkr/nes-snake
|
f46910798e453edc17b274d6bd65f8665addea61
|
[
"Apache-2.0"
] | null | null | null |
src/main.asm
|
munshkr/nes-snake
|
f46910798e453edc17b274d6bd65f8665addea61
|
[
"Apache-2.0"
] | null | null | null |
src/main.asm
|
munshkr/nes-snake
|
f46910798e453edc17b274d6bd65f8665addea61
|
[
"Apache-2.0"
] | null | null | null |
;;;;;;;;;;;;;;;;;;;;;
;;; VARIABLES ;;;
;;;;;;;;;;;;;;;;;;;;;
.enum $0000 ; Zero Page variables
; main
nmis .dsb 1
cur_keys .dsb 2
new_keys .dsb 2
ticks .dsb 1
; player
snake_px .dsb 1
snake_py .dsb 1
snake_dir .dsb 1
snake_next_dir .dsb 1
snake_tile .dsb 1
; apples.asm
apple_px .dsb 1
apple_py .dsb 1
; pads.asm
thisRead .dsb 2
firstRead .dsb 2
lastFrameKeys .dsb 2
; prng.asm
seed .dsb 2
.ende
.enum $0400 ; Variables at $0400. Can start on any RAM page
.ende
;;;;;;;;;;;;;;;;
;;; CODE ;;;
;;;;;;;;;;;;;;;;
setup:
jsr load_palettes
lda #%10010000 ; enable nmi, sprites from pattern table 0 and bg from 1
sta PPUCTRL
lda #%00011000 ; enable sprites
sta PPUMASK
main:
jsr title_screen
jsr game_loop
jmp main ; jump back to forever, infinite loop
load_palettes:
lda PPUSTATUS ; read ppu status to reset the high/low latch
lda #$3f
sta PPUADDR ; write the high byte of $3f00 address (where palettes should be stored)
lda #$00
sta PPUADDR ; write the low byte of $3f00 address
ldx #$00 ; start out at 0
@loop:
lda palette, x ; load data from address (palette + the value in x)
sta PPUDATA ; write to ppu
inx ; x = x + 1
cpx #$20 ; there are 2 palettes (bg and sprites), each of 16/$10 bytes
bne @loop
rts
clear_background:
;; set nt #0
lda #$20
sta PPUADDR
lda #$00
sta PPUADDR
lda #$01
ldx #$80
@loop:
sta PPUDATA
sta PPUDATA
sta PPUDATA
sta PPUDATA
dex
bne @loop
;; set attributes for nt #0
lda #$23
sta PPUADDR
lda #$c0
sta PPUADDR
lda #%11111111
ldx #$40
@attrLoop:
sta PPUDATA
dex
bne @attrLoop
rts
title_screen:
jsr clear_background
@loop:
jmp @loop
rts
game_loop:
; jsr load_background
jsr init_player
jsr spawn_apple
lda #GAME_TICKS
sta ticks
;; FIXME: should set a random seed based on the elapsed time between now and
;; when the user presses Start, or something like that...
lda #$40
sta seed
@loop:
; Game logic
jsr read_pads
jsr move_player
; Drawing
jsr draw_player
jsr draw_apple
; Wait for vblank to write to PPU
lda nmis
@vblankwait
cmp nmis
beq @vblankwait
; Update OAM
lda #$00
sta OAMADDR ; set the low byte (00) of the ram address
lda #$02
sta OAMDMA ; set the high byte (02) of the ram address, start the transfer
jmp @loop ; for now, loop infinitely
rts
nmi:
inc nmis ; trigger NMI signal on main routine
rti
| 18.090909
| 98
| 0.57107
|
662c2d4509f8292d3f2f0d77098f4ddde7b22d3c
| 16,520
|
asm
|
Assembly
|
src/coreclr/src/vm/amd64/JitHelpers_Fast.asm
|
patricksadowski/runtime
|
aa5b2041471d7687dbddb1d275ea8a93943c43bf
|
[
"MIT"
] | 2
|
2020-03-28T13:38:11.000Z
|
2020-12-18T15:00:04.000Z
|
src/coreclr/src/vm/amd64/JitHelpers_Fast.asm
|
patricksadowski/runtime
|
aa5b2041471d7687dbddb1d275ea8a93943c43bf
|
[
"MIT"
] | 1
|
2020-04-24T10:03:11.000Z
|
2020-04-24T10:03:11.000Z
|
src/coreclr/src/vm/amd64/JitHelpers_Fast.asm
|
patricksadowski/runtime
|
aa5b2041471d7687dbddb1d275ea8a93943c43bf
|
[
"MIT"
] | 3
|
2021-02-10T16:20:05.000Z
|
2021-03-12T07:55:36.000Z
|
; Licensed to the .NET Foundation under one or more agreements.
; The .NET Foundation licenses this file to you under the MIT license.
; See the LICENSE file in the project root for more information.
; ==++==
;
;
; ==--==
; ***********************************************************************
; File: JitHelpers_Fast.asm, see jithelp.asm for history
;
; Notes: routinues which we believe to be on the hot path for managed
; code in most scenarios.
; ***********************************************************************
include AsmMacros.inc
include asmconstants.inc
; Min amount of stack space that a nested function should allocate.
MIN_SIZE equ 28h
EXTERN g_ephemeral_low:QWORD
EXTERN g_ephemeral_high:QWORD
EXTERN g_lowest_address:QWORD
EXTERN g_highest_address:QWORD
EXTERN g_card_table:QWORD
ifdef FEATURE_MANUALLY_MANAGED_CARD_BUNDLES
EXTERN g_card_bundle_table:QWORD
endif
ifdef FEATURE_USE_SOFTWARE_WRITE_WATCH_FOR_GC_HEAP
EXTERN g_sw_ww_table:QWORD
EXTERN g_sw_ww_enabled_for_gc_heap:BYTE
endif
ifdef WRITE_BARRIER_CHECK
; Those global variables are always defined, but should be 0 for Server GC
g_GCShadow TEXTEQU <?g_GCShadow@@3PEAEEA>
g_GCShadowEnd TEXTEQU <?g_GCShadowEnd@@3PEAEEA>
EXTERN g_GCShadow:QWORD
EXTERN g_GCShadowEnd:QWORD
endif
INVALIDGCVALUE equ 0CCCCCCCDh
ifdef _DEBUG
extern JIT_WriteBarrier_Debug:proc
endif
extern JIT_InternalThrow:proc
; There is an even more optimized version of these helpers possible which takes
; advantage of knowledge of which way the ephemeral heap is growing to only do 1/2
; that check (this is more significant in the JIT_WriteBarrier case).
;
; Additionally we can look into providing helpers which will take the src/dest from
; specific registers (like x86) which _could_ (??) make for easier register allocation
; for the JIT64, however it might lead to having to have some nasty code that treats
; these guys really special like... :(.
;
; Version that does the move, checks whether or not it's in the GC and whether or not
; it needs to have it's card updated
;
; void JIT_CheckedWriteBarrier(Object** dst, Object* src)
LEAF_ENTRY JIT_CheckedWriteBarrier, _TEXT
; When WRITE_BARRIER_CHECK is defined _NotInHeap will write the reference
; but if it isn't then it will just return.
;
; See if this is in GCHeap
cmp rcx, [g_lowest_address]
jb NotInHeap
cmp rcx, [g_highest_address]
jnb NotInHeap
jmp JIT_WriteBarrier
NotInHeap:
; See comment above about possible AV
mov [rcx], rdx
ret
LEAF_END_MARKED JIT_CheckedWriteBarrier, _TEXT
; Mark start of the code region that we patch at runtime
LEAF_ENTRY JIT_PatchedCodeStart, _TEXT
ret
LEAF_END JIT_PatchedCodeStart, _TEXT
; This is used by the mechanism to hold either the JIT_WriteBarrier_PreGrow
; or JIT_WriteBarrier_PostGrow code (depending on the state of the GC). It _WILL_
; change at runtime as the GC changes. Initially it should simply be a copy of the
; larger of the two functions (JIT_WriteBarrier_PostGrow) to ensure we have created
; enough space to copy that code in.
LEAF_ENTRY JIT_WriteBarrier, _TEXT
align 16
ifdef _DEBUG
; In debug builds, this just contains jump to the debug version of the write barrier by default
jmp JIT_WriteBarrier_Debug
endif
ifdef FEATURE_USE_SOFTWARE_WRITE_WATCH_FOR_GC_HEAP
; JIT_WriteBarrier_WriteWatch_PostGrow64
; Regarding patchable constants:
; - 64-bit constants have to be loaded into a register
; - The constants have to be aligned to 8 bytes so that they can be patched easily
; - The constant loads have been located to minimize NOP padding required to align the constants
; - Using different registers for successive constant loads helps pipeline better. Should we decide to use a special
; non-volatile calling convention, this should be changed to use just one register.
; Do the move into the GC . It is correct to take an AV here, the EH code
; figures out that this came from a WriteBarrier and correctly maps it back
; to the managed method which called the WriteBarrier (see setup in
; InitializeExceptionHandling, vm\exceptionhandling.cpp).
mov [rcx], rdx
; Update the write watch table if necessary
mov rax, rcx
mov r8, 0F0F0F0F0F0F0F0F0h
shr rax, 0Ch ; SoftwareWriteWatch::AddressToTableByteIndexShift
NOP_2_BYTE ; padding for alignment of constant
mov r9, 0F0F0F0F0F0F0F0F0h
add rax, r8
cmp byte ptr [rax], 0h
jne CheckCardTable
mov byte ptr [rax], 0FFh
NOP_3_BYTE ; padding for alignment of constant
; Check the lower and upper ephemeral region bounds
CheckCardTable:
cmp rdx, r9
jb Exit
NOP_3_BYTE ; padding for alignment of constant
mov r8, 0F0F0F0F0F0F0F0F0h
cmp rdx, r8
jae Exit
nop ; padding for alignment of constant
mov rax, 0F0F0F0F0F0F0F0F0h
; Touch the card table entry, if not already dirty.
shr rcx, 0Bh
cmp byte ptr [rcx + rax], 0FFh
jne UpdateCardTable
REPRET
UpdateCardTable:
mov byte ptr [rcx + rax], 0FFh
ifdef FEATURE_MANUALLY_MANAGED_CARD_BUNDLES
mov rax, 0F0F0F0F0F0F0F0F0h
shr rcx, 0Ah
cmp byte ptr [rcx + rax], 0FFh
jne UpdateCardBundleTable
REPRET
UpdateCardBundleTable:
mov byte ptr [rcx + rax], 0FFh
endif
ret
align 16
Exit:
REPRET
else
; JIT_WriteBarrier_PostGrow64
; Do the move into the GC . It is correct to take an AV here, the EH code
; figures out that this came from a WriteBarrier and correctly maps it back
; to the managed method which called the WriteBarrier (see setup in
; InitializeExceptionHandling, vm\exceptionhandling.cpp).
mov [rcx], rdx
NOP_3_BYTE ; padding for alignment of constant
; Can't compare a 64 bit immediate, so we have to move them into a
; register. Values of these immediates will be patched at runtime.
; By using two registers we can pipeline better. Should we decide to use
; a special non-volatile calling convention, this should be changed to
; just one.
mov rax, 0F0F0F0F0F0F0F0F0h
; Check the lower and upper ephemeral region bounds
cmp rdx, rax
jb Exit
nop ; padding for alignment of constant
mov r8, 0F0F0F0F0F0F0F0F0h
cmp rdx, r8
jae Exit
nop ; padding for alignment of constant
mov rax, 0F0F0F0F0F0F0F0F0h
; Touch the card table entry, if not already dirty.
shr rcx, 0Bh
cmp byte ptr [rcx + rax], 0FFh
jne UpdateCardTable
REPRET
UpdateCardTable:
mov byte ptr [rcx + rax], 0FFh
ifdef FEATURE_MANUALLY_MANAGED_CARD_BUNDLES
mov rax, 0F0F0F0F0F0F0F0F0h
shr rcx, 0Ah
cmp byte ptr [rcx + rax], 0FFh
jne UpdateCardBundleTable
REPRET
UpdateCardBundleTable:
mov byte ptr [rcx + rax], 0FFh
endif
ret
align 16
Exit:
REPRET
endif
; make sure this is bigger than any of the others
align 16
nop
LEAF_END_MARKED JIT_WriteBarrier, _TEXT
; Mark start of the code region that we patch at runtime
LEAF_ENTRY JIT_PatchedCodeLast, _TEXT
ret
LEAF_END JIT_PatchedCodeLast, _TEXT
; JIT_ByRefWriteBarrier has weird symantics, see usage in StubLinkerX86.cpp
;
; Entry:
; RDI - address of ref-field (assigned to)
; RSI - address of the data (source)
; RCX is trashed
; RAX is trashed when FEATURE_USE_SOFTWARE_WRITE_WATCH_FOR_GC_HEAP is defined
; Exit:
; RDI, RSI are incremented by SIZEOF(LPVOID)
LEAF_ENTRY JIT_ByRefWriteBarrier, _TEXT
mov rcx, [rsi]
; If !WRITE_BARRIER_CHECK do the write first, otherwise we might have to do some ShadowGC stuff
ifndef WRITE_BARRIER_CHECK
; rcx is [rsi]
mov [rdi], rcx
endif
; When WRITE_BARRIER_CHECK is defined _NotInHeap will write the reference
; but if it isn't then it will just return.
;
; See if this is in GCHeap
cmp rdi, [g_lowest_address]
jb NotInHeap
cmp rdi, [g_highest_address]
jnb NotInHeap
ifdef WRITE_BARRIER_CHECK
; we can only trash rcx in this function so in _DEBUG we need to save
; some scratch registers.
push r10
push r11
push rax
; **ALSO update the shadow GC heap if that is enabled**
; Do not perform the work if g_GCShadow is 0
cmp g_GCShadow, 0
je NoShadow
; If we end up outside of the heap don't corrupt random memory
mov r10, rdi
sub r10, [g_lowest_address]
jb NoShadow
; Check that our adjusted destination is somewhere in the shadow gc
add r10, [g_GCShadow]
cmp r10, [g_GCShadowEnd]
ja NoShadow
; Write ref into real GC
mov [rdi], rcx
; Write ref into shadow GC
mov [r10], rcx
; Ensure that the write to the shadow heap occurs before the read from
; the GC heap so that race conditions are caught by INVALIDGCVALUE
mfence
; Check that GC/ShadowGC values match
mov r11, [rdi]
mov rax, [r10]
cmp rax, r11
je DoneShadow
mov r11, INVALIDGCVALUE
mov [r10], r11
jmp DoneShadow
; If we don't have a shadow GC we won't have done the write yet
NoShadow:
mov [rdi], rcx
; If we had a shadow GC then we already wrote to the real GC at the same time
; as the shadow GC so we want to jump over the real write immediately above.
; Additionally we know for sure that we are inside the heap and therefore don't
; need to replicate the above checks.
DoneShadow:
pop rax
pop r11
pop r10
endif
ifdef FEATURE_USE_SOFTWARE_WRITE_WATCH_FOR_GC_HEAP
; Update the write watch table if necessary
cmp byte ptr [g_sw_ww_enabled_for_gc_heap], 0h
je CheckCardTable
mov rax, rdi
shr rax, 0Ch ; SoftwareWriteWatch::AddressToTableByteIndexShift
add rax, qword ptr [g_sw_ww_table]
cmp byte ptr [rax], 0h
jne CheckCardTable
mov byte ptr [rax], 0FFh
endif
; See if we can just quick out
CheckCardTable:
cmp rcx, [g_ephemeral_low]
jb Exit
cmp rcx, [g_ephemeral_high]
jnb Exit
; move current rdi value into rcx and then increment the pointers
mov rcx, rdi
add rsi, 8h
add rdi, 8h
; Check if we need to update the card table
; Calc pCardByte
shr rcx, 0Bh
add rcx, [g_card_table]
; Check if this card is dirty
cmp byte ptr [rcx], 0FFh
jne UpdateCardTable
REPRET
UpdateCardTable:
mov byte ptr [rcx], 0FFh
ifdef FEATURE_MANUALLY_MANAGED_CARD_BUNDLES
; check if we need to update the card bundle table
; restore destination address from rdi - rdi has been incremented by 8 already
lea rcx, [rdi-8]
shr rcx, 15h
add rcx, [g_card_bundle_table]
cmp byte ptr [rcx], 0FFh
jne UpdateCardBundleTable
REPRET
UpdateCardBundleTable:
mov byte ptr [rcx], 0FFh
endif
ret
align 16
NotInHeap:
; If WRITE_BARRIER_CHECK then we won't have already done the mov and should do it here
; If !WRITE_BARRIER_CHECK we want _NotInHeap and _Leave to be the same and have both
; 16 byte aligned.
ifdef WRITE_BARRIER_CHECK
; rcx is [rsi]
mov [rdi], rcx
endif
Exit:
; Increment the pointers before leaving
add rdi, 8h
add rsi, 8h
ret
LEAF_END_MARKED JIT_ByRefWriteBarrier, _TEXT
extern JIT_FailFast:proc
extern s_gsCookie:qword
OFFSETOF_GSCOOKIE equ 0h
OFFSETOF_FRAME equ OFFSETOF_GSCOOKIE + \
8h
;
; incoming:
;
; rsp -> return address
; :
;
; Stack Layout:
;
; rsp-> callee scratch
; + 8h callee scratch
; +10h callee scratch
; +18h callee scratch
; :
; stack arguments
; :
; r13-> gsCookie
; + 8h __VFN_table
; +10h m_Next
; +18h m_pGCLayout
; +20h m_padding
; +28h m_rdi
; +30h m_rsi
; +38h m_rbx
; +40h m_rbp
; +48h m_r12
; +50h m_r13
; +58h m_r14
; +60h m_r15
; +68h m_ReturnAddress
; r12 -> // Caller's SP
;
; r14 = GetThread();
; r15 = GetThread()->GetFrame(); // For restoring/popping the frame
;
NESTED_ENTRY TailCallHelperStub, _TEXT
PUSH_CALLEE_SAVED_REGISTERS
alloc_stack 48h ; m_padding, m_pGCLayout, m_Next, __VFN_table, gsCookie, outgoing shadow area
set_frame r13, 20h
END_PROLOGUE
;
; This part is never executed, but we keep it here for reference
;
int 3
if 0 ne 0
; Save the caller's SP
mov r12, rsp + ...
;
; fully initialize the TailCallFrame
;
call TCF_GETMETHODFRAMEVPTR
mov [r13 + OFFSETOF_FRAME], rax
mov rax, s_gsCookie
mov [r13 + OFFSETOF_GSCOOKIE], rax
;
; link the TailCallFrame
;
INLINE_GETTHREAD r14
mov r15, [r14 + OFFSETOF__Thread__m_pFrame]
mov [r13 + OFFSETOF_FRAME + OFFSETOF__Frame__m_Next], r15
lea r10, [r13 + OFFSETOF_FRAME]
mov [r14 + OFFSETOF__Thread__m_pFrame], r10
endif
; the pretend call would be here
; with the return address pointing this this real epilog
PATCH_LABEL JIT_TailCallHelperStub_ReturnAddress
; our epilog (which also unlinks the TailCallFrame)
ifdef _DEBUG
mov rcx, s_gsCookie
cmp [r13 + OFFSETOF_GSCookie], rcx
je GoodGSCookie
call JIT_FailFast
GoodGSCookie:
endif ; _DEBUG
;
; unlink the TailCallFrame
;
mov [r14 + OFFSETOF__Thread__m_pFrame], r15
;
; epilog
;
lea rsp, [r13 + 28h]
POP_CALLEE_SAVED_REGISTERS
ret
NESTED_END TailCallHelperStub, _TEXT
; The following helper will access ("probe") a word on each page of the stack
; starting with the page right beneath rsp down to the one pointed to by r11.
; The procedure is needed to make sure that the "guard" page is pushed down below the allocated stack frame.
; The call to the helper will be emitted by JIT in the function/funclet prolog when large (larger than 0x3000 bytes) stack frame is required.
;
; NOTE: this helper will NOT modify a value of rsp and can be defined as a leaf function.
PAGE_SIZE equ 1000h
LEAF_ENTRY JIT_StackProbe, _TEXT
; On entry:
; r11 - points to the lowest address on the stack frame being allocated (i.e. [InitialSp - FrameSize])
; rsp - points to some byte on the last probed page
; On exit:
; rax - is not preserved
; r11 - is preserved
;
; NOTE: this helper will probe at least one page below the one pointed by rsp.
mov rax, rsp ; rax points to some byte on the last probed page
and rax, -PAGE_SIZE ; rax points to the **lowest address** on the last probed page
; This is done to make the following loop end condition simpler.
ProbeLoop:
sub rax, PAGE_SIZE ; rax points to the lowest address of the **next page** to probe
test dword ptr [rax], eax ; rax points to the lowest address on the **last probed** page
cmp rax, r11
jg ProbeLoop ; If (rax > r11), then we need to probe at least one more page.
ret
LEAF_END_MARKED JIT_StackProbe, _TEXT
end
| 30.93633
| 141
| 0.630024
|
98772243f6d2818bf039f40848427516ffb5e3f4
| 6,299
|
asm
|
Assembly
|
Transynther/x86/_processed/US/_zr_/i7-7700_9_0xca.log_21829_831.asm
|
ljhsiun2/medusa
|
67d769b8a2fb42c538f10287abaf0e6dbb463f0c
|
[
"MIT"
] | 9
|
2020-08-13T19:41:58.000Z
|
2022-03-30T12:22:51.000Z
|
Transynther/x86/_processed/US/_zr_/i7-7700_9_0xca.log_21829_831.asm
|
ljhsiun2/medusa
|
67d769b8a2fb42c538f10287abaf0e6dbb463f0c
|
[
"MIT"
] | 1
|
2021-04-29T06:29:35.000Z
|
2021-05-13T21:02:30.000Z
|
Transynther/x86/_processed/US/_zr_/i7-7700_9_0xca.log_21829_831.asm
|
ljhsiun2/medusa
|
67d769b8a2fb42c538f10287abaf0e6dbb463f0c
|
[
"MIT"
] | 3
|
2020-07-14T17:07:07.000Z
|
2022-03-21T01:12:22.000Z
|
.global s_prepare_buffers
s_prepare_buffers:
push %r10
push %r11
push %r12
push %r13
push %rbx
push %rcx
push %rdi
push %rsi
lea addresses_WT_ht+0x171cf, %rsi
lea addresses_D_ht+0x10f8f, %rdi
nop
nop
nop
inc %r13
mov $63, %rcx
rep movsq
nop
sub %r12, %r12
lea addresses_normal_ht+0x4796, %r13
nop
nop
sub $20753, %rbx
movw $0x6162, (%r13)
nop
nop
nop
nop
cmp $14360, %rsi
lea addresses_WC_ht+0xc78f, %rsi
nop
xor %r11, %r11
movl $0x61626364, (%rsi)
nop
cmp $14059, %rbx
lea addresses_A_ht+0xd18f, %rsi
lea addresses_WT_ht+0x5f8f, %rdi
nop
inc %r10
mov $59, %rcx
rep movsq
nop
nop
sub $56180, %rcx
lea addresses_WC_ht+0xd90f, %r11
clflush (%r11)
xor $36025, %rsi
mov $0x6162636465666768, %r12
movq %r12, %xmm1
movups %xmm1, (%r11)
nop
nop
cmp %rdi, %rdi
lea addresses_D_ht+0x1ab8f, %rsi
lea addresses_WC_ht+0x158f, %rdi
clflush (%rdi)
nop
nop
nop
nop
nop
cmp $50267, %r13
mov $103, %rcx
rep movsq
nop
dec %rdi
lea addresses_WT_ht+0x28f, %rsi
mfence
and $0xffffffffffffffc0, %rsi
vmovntdqa (%rsi), %ymm7
vextracti128 $1, %ymm7, %xmm7
vpextrq $1, %xmm7, %rcx
nop
nop
add $52271, %rdi
lea addresses_D_ht+0x1ad0f, %rsi
lea addresses_WC_ht+0x14b8f, %rdi
nop
nop
nop
nop
sub $13350, %rbx
mov $3, %rcx
rep movsl
nop
nop
lfence
lea addresses_A_ht+0xcb8f, %rsi
nop
nop
nop
nop
sub $23908, %r12
movups (%rsi), %xmm4
vpextrq $0, %xmm4, %r13
nop
nop
sub %r11, %r11
pop %rsi
pop %rdi
pop %rcx
pop %rbx
pop %r13
pop %r12
pop %r11
pop %r10
ret
.global s_faulty_load
s_faulty_load:
push %r11
push %r9
push %rbx
push %rdi
push %rsi
// Faulty Load
lea addresses_US+0xef8f, %rbx
nop
add %rdi, %rdi
movups (%rbx), %xmm1
vpextrq $1, %xmm1, %rsi
lea oracles, %rbx
and $0xff, %rsi
shlq $12, %rsi
mov (%rbx,%rsi,1), %rsi
pop %rsi
pop %rdi
pop %rbx
pop %r9
pop %r11
ret
/*
<gen_faulty_load>
[REF]
{'src': {'congruent': 0, 'AVXalign': True, 'same': False, 'size': 32, 'NT': False, 'type': 'addresses_US'}, 'OP': 'LOAD'}
[Faulty Load]
{'src': {'congruent': 0, 'AVXalign': False, 'same': True, 'size': 16, 'NT': False, 'type': 'addresses_US'}, 'OP': 'LOAD'}
<gen_prepare_buffer>
{'src': {'congruent': 6, 'same': False, 'type': 'addresses_WT_ht'}, 'OP': 'REPM', 'dst': {'congruent': 11, 'same': False, 'type': 'addresses_D_ht'}}
{'OP': 'STOR', 'dst': {'congruent': 0, 'AVXalign': False, 'same': False, 'size': 2, 'NT': False, 'type': 'addresses_normal_ht'}}
{'OP': 'STOR', 'dst': {'congruent': 8, 'AVXalign': False, 'same': False, 'size': 4, 'NT': False, 'type': 'addresses_WC_ht'}}
{'src': {'congruent': 8, 'same': False, 'type': 'addresses_A_ht'}, 'OP': 'REPM', 'dst': {'congruent': 10, 'same': False, 'type': 'addresses_WT_ht'}}
{'OP': 'STOR', 'dst': {'congruent': 7, 'AVXalign': False, 'same': False, 'size': 16, 'NT': False, 'type': 'addresses_WC_ht'}}
{'src': {'congruent': 10, 'same': False, 'type': 'addresses_D_ht'}, 'OP': 'REPM', 'dst': {'congruent': 9, 'same': False, 'type': 'addresses_WC_ht'}}
{'src': {'congruent': 8, 'AVXalign': False, 'same': False, 'size': 32, 'NT': True, 'type': 'addresses_WT_ht'}, 'OP': 'LOAD'}
{'src': {'congruent': 7, 'same': True, 'type': 'addresses_D_ht'}, 'OP': 'REPM', 'dst': {'congruent': 10, 'same': False, 'type': 'addresses_WC_ht'}}
{'src': {'congruent': 8, 'AVXalign': False, 'same': False, 'size': 16, 'NT': False, 'type': 'addresses_A_ht'}, 'OP': 'LOAD'}
{'00': 21829}
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
*/
| 40.902597
| 2,999
| 0.661534
|
55dfa086bc41f0a494a34a6de595c3204f348485
| 662
|
asm
|
Assembly
|
oeis/055/A055798.asm
|
neoneye/loda-programs
|
84790877f8e6c2e821b183d2e334d612045d29c0
|
[
"Apache-2.0"
] | 11
|
2021-08-22T19:44:55.000Z
|
2022-03-20T16:47:57.000Z
|
oeis/055/A055798.asm
|
neoneye/loda-programs
|
84790877f8e6c2e821b183d2e334d612045d29c0
|
[
"Apache-2.0"
] | 9
|
2021-08-29T13:15:54.000Z
|
2022-03-09T19:52:31.000Z
|
oeis/055/A055798.asm
|
neoneye/loda-programs
|
84790877f8e6c2e821b183d2e334d612045d29c0
|
[
"Apache-2.0"
] | 3
|
2021-08-22T20:56:47.000Z
|
2021-09-29T06:26:12.000Z
|
; A055798: T(2n+5,n), array T as in A055794.
; 1,7,29,93,255,627,1419,3003,6006,11440,20878,36686,62322,102714,164730,257754,394383,591261,870067,1258675,1792505,2516085,3484845,4767165,6446700,8625006,11424492,14991724,19501108,25158980,32208132,40932804,51664173,64786371,80743065,100044633,123275971,151104967,184291679,223698255,270299634,325195068,389620506,464961882,552769350,654772510,772896670,909280190,1066292955,1246556025,1452962511,1688699727,1957272669,2262528873,2608684705,3000353137,3442573064,3940840218,4501139736,5129980440
lpb $0
mov $2,$0
sub $0,1
seq $2,55797 ; T(2n+4,n), array T as in A055794.
add $1,$2
lpe
add $1,1
mov $0,$1
| 55.166667
| 499
| 0.800604
|
d2ea99b0393bc86fd8eb0c559731e4e6c52386e9
| 294
|
asm
|
Assembly
|
GAS/Gas/GASC/UtilsLib/Errors.asm
|
Gabidal/GAS_Pack
|
02f13531849bc5c03721a4319a9e315a60ba7707
|
[
"MIT"
] | 1
|
2021-09-21T13:07:37.000Z
|
2021-09-21T13:07:37.000Z
|
GAS/Gas/GASC/UtilsLib/Errors.asm
|
Gabidal/GAS_Pack
|
02f13531849bc5c03721a4319a9e315a60ba7707
|
[
"MIT"
] | null | null | null |
GAS/Gas/GASC/UtilsLib/Errors.asm
|
Gabidal/GAS_Pack
|
02f13531849bc5c03721a4319a9e315a60ba7707
|
[
"MIT"
] | null | null | null |
openErr:
append Error, openError, 23
sout Error
jmp endCompile
readErr:
append Error, readError, 32
sout Error
jmp endCompile
writeErr:
append Error, writeError, 43
sout Error
jmp endCompile
closeErr:
append Error, closeError, 18
sout Error
jmp endCompile
| 14.7
| 31
| 0.707483
|
e6b8d17a88efe5092e842c8b22ded006aa4cbe35
| 566
|
asm
|
Assembly
|
programs/oeis/002/A002378.asm
|
neoneye/loda
|
afe9559fb53ee12e3040da54bd6aa47283e0d9ec
|
[
"Apache-2.0"
] | 22
|
2018-02-06T19:19:31.000Z
|
2022-01-17T21:53:31.000Z
|
programs/oeis/002/A002378.asm
|
neoneye/loda
|
afe9559fb53ee12e3040da54bd6aa47283e0d9ec
|
[
"Apache-2.0"
] | 41
|
2021-02-22T19:00:34.000Z
|
2021-08-28T10:47:47.000Z
|
programs/oeis/002/A002378.asm
|
neoneye/loda
|
afe9559fb53ee12e3040da54bd6aa47283e0d9ec
|
[
"Apache-2.0"
] | 5
|
2021-02-24T21:14:16.000Z
|
2021-08-09T19:48:05.000Z
|
; A002378: Oblong (or promic, pronic, or heteromecic) numbers: a(n) = n*(n+1).
; 0,2,6,12,20,30,42,56,72,90,110,132,156,182,210,240,272,306,342,380,420,462,506,552,600,650,702,756,812,870,930,992,1056,1122,1190,1260,1332,1406,1482,1560,1640,1722,1806,1892,1980,2070,2162,2256,2352,2450,2550,2652,2756,2862,2970,3080,3192,3306,3422,3540,3660,3782,3906,4032,4160,4290,4422,4556,4692,4830,4970,5112,5256,5402,5550,5700,5852,6006,6162,6320,6480,6642,6806,6972,7140,7310,7482,7656,7832,8010,8190,8372,8556,8742,8930,9120,9312,9506,9702,9900
mov $1,$0
add $0,1
mul $0,$1
| 80.857143
| 456
| 0.745583
|
1ad0bd8c02576090872cf2c78ac713da7f361e41
| 1,033
|
asm
|
Assembly
|
libsrc/_DEVELOPMENT/temp/sp1/zx/sprites/asm_sp1_PutSprClr.asm
|
jpoikela/z88dk
|
7108b2d7e3a98a77de99b30c9a7c9199da9c75cb
|
[
"ClArtistic"
] | 640
|
2017-01-14T23:33:45.000Z
|
2022-03-30T11:28:42.000Z
|
libsrc/_DEVELOPMENT/temp/sp1/zx/sprites/asm_sp1_PutSprClr.asm
|
jpoikela/z88dk
|
7108b2d7e3a98a77de99b30c9a7c9199da9c75cb
|
[
"ClArtistic"
] | 1,600
|
2017-01-15T16:12:02.000Z
|
2022-03-31T12:11:12.000Z
|
libsrc/_DEVELOPMENT/temp/sp1/zx/sprites/asm_sp1_PutSprClr.asm
|
jpoikela/z88dk
|
7108b2d7e3a98a77de99b30c9a7c9199da9c75cb
|
[
"ClArtistic"
] | 215
|
2017-01-17T10:43:03.000Z
|
2022-03-23T17:25:02.000Z
|
; void sp1_PutSprClr(uchar **sprdest, struct sp1_ap *src, uchar n)
; 02.2006 aralbrec, Sprite Pack v3.0
; sinclair spectrum version
SECTION code_clib
SECTION code_temp_sp1
PUBLIC asm_sp1_PutSprClr
asm_sp1_PutSprClr:
; Colour sprite by writing (mask,attr) pairs into each
; struct_sp1_cs whose addresses are stored in the array
; pointed at by hl. The array of struct_sp1_cs is
; populated by a call to SP1GetSprClrAddr.
;
; enter : b = number of colour pairs to copy (size of sprite in tiles)
; de = struct sp1_ap[] source array of colour pairs
; hl = array of sprite colour addresses (all point at struct sp1_cs.attr_mask)
; uses : af, bc, de, hl
ld c,$ff
.loop
push de
ld e,(hl)
inc hl
ld d,(hl) ; de = & sp1_cs.attr_mask
inc hl
ex (sp),hl ; hl = struct sp1_ap[
ldi ; copy mask and attribute into struct sp1_cs
ldi
pop de ; de = array of sprite colour addresses advanced one entry
ex de,hl
djnz loop
ret
| 25.825
| 86
| 0.657309
|
87370ef9e61bef641f2d9fc885f28fcdcb2f0d8b
| 564
|
asm
|
Assembly
|
oeis/001/A001405.asm
|
neoneye/loda-programs
|
84790877f8e6c2e821b183d2e334d612045d29c0
|
[
"Apache-2.0"
] | 11
|
2021-08-22T19:44:55.000Z
|
2022-03-20T16:47:57.000Z
|
oeis/001/A001405.asm
|
neoneye/loda-programs
|
84790877f8e6c2e821b183d2e334d612045d29c0
|
[
"Apache-2.0"
] | 9
|
2021-08-29T13:15:54.000Z
|
2022-03-09T19:52:31.000Z
|
oeis/001/A001405.asm
|
neoneye/loda-programs
|
84790877f8e6c2e821b183d2e334d612045d29c0
|
[
"Apache-2.0"
] | 3
|
2021-08-22T20:56:47.000Z
|
2021-09-29T06:26:12.000Z
|
; A001405: a(n) = binomial(n, floor(n/2)).
; 1,1,2,3,6,10,20,35,70,126,252,462,924,1716,3432,6435,12870,24310,48620,92378,184756,352716,705432,1352078,2704156,5200300,10400600,20058300,40116600,77558760,155117520,300540195,601080390,1166803110,2333606220,4537567650,9075135300,17672631900,35345263800,68923264410,137846528820,269128937220,538257874440,1052049481860,2104098963720,4116715363800,8233430727600,16123801841550,32247603683100,63205303218876,126410606437752,247959266474052,495918532948104,973469712824056,1946939425648112
mov $1,$0
div $1,2
bin $0,$1
| 80.571429
| 490
| 0.840426
|
a8ee17e11df9806700c545d52792c6f6af698e0a
| 434
|
asm
|
Assembly
|
Samples/Primes.asm
|
charles-fox/ManchesterBabyPython
|
dcf544c8beec83d07943ec4da2926821a4fbe6eb
|
[
"MIT"
] | null | null | null |
Samples/Primes.asm
|
charles-fox/ManchesterBabyPython
|
dcf544c8beec83d07943ec4da2926821a4fbe6eb
|
[
"MIT"
] | null | null | null |
Samples/Primes.asm
|
charles-fox/ManchesterBabyPython
|
dcf544c8beec83d07943ec4da2926821a4fbe6eb
|
[
"MIT"
] | null | null | null |
--
-- Each time the program is run (pressing the EXEC button) the next prime number in the sequence is generated.
--
00: JMP 24
01: LDN 21
02: STO 21
03: LDN 21
04: SUB 15
05: STO 21
06: LDN 15
07: STO 22
08: LDN 22
09: STO 22
10: LDN 22
11: SUB 15
12: STO 22
13: SUB 21
14: CMP
15: NUM -1
16: LDN 21
17: STO 23
18: LDN 23
19: SUB 22
20: JMP 0
21: NUM 1
24: NUM 7
25: CMP
26: JPR 0
27: STO 23
28: LDN 23
29: SUB 22
30: CMP
31: JMP 20
| 12.764706
| 110
| 0.656682
|
f03bb0f6320f453cfbd508cd5b66b0b46f2ea675
| 4,563
|
asm
|
Assembly
|
common/c32quik.asm
|
DigitalMars/optlink
|
493de158282046641ef2a3a60a88e25e26d88ec4
|
[
"BSL-1.0"
] | 28
|
2015-02-03T01:38:24.000Z
|
2022-03-23T05:48:24.000Z
|
common/c32quik.asm
|
DigitalMars/optlink
|
493de158282046641ef2a3a60a88e25e26d88ec4
|
[
"BSL-1.0"
] | 20
|
2015-01-02T14:51:20.000Z
|
2021-01-09T21:37:19.000Z
|
common/c32quik.asm
|
DigitalMars/optlink
|
493de158282046641ef2a3a60a88e25e26d88ec4
|
[
"BSL-1.0"
] | 9
|
2015-02-11T17:43:56.000Z
|
2019-09-05T11:07:02.000Z
|
TITLE QUIK-SUBS Copyright (c) SLR Systems, Inc 1994
INCLUDE MACROS
if fg_dospack OR fg_winpack
INCLUDE SLR32
PUBLIC PUTSTUFF_SMALL_QUIK32,PUTSTUFF_QUIK32,FLUSHSTUFF_QUIK32,FIX_BUFFERS_QUIK32,PUT_0,PUT_1,FLUSH_PUTSTUFF
.DATA
EXTERNDEF HUF_MINI_BUFFER:BYTE
EXTERNDEF SLR_MASK:DWORD,SLR_WORD:DWORD,SLR_CPOS:DWORD,SLR_VARS:DWORD,SLR_TMP_PTR:DWORD
.CODE PASS2_TEXT
EXTERNDEF ?_KEEP_QUIK_COMPRESSED:PROC,MOVE_EAX_TO_COMPRESS_OUTPUT:PROC,DOT:PROC
PUTSTUFF_SMALL_QUIK32 PROC NEAR
;
;AL IS NORMAL BYTE TO OUTPUT
;
PUSHM EDI,EBX
MOV EBX,SLR_MASK
MOV ECX,SLR_WORD
OR ECX,EBX
MOV EDI,SLR_TMP_PTR
SHR EBX,1
MOV SLR_WORD,ECX
MOV SLR_MASK,EBX
JZ L101$
L1019$:
MOV [EDI],AL
INC EDI
MOV SLR_TMP_PTR,EDI
POP EBX
POP EDI
RET
L101$:
PUSH EDX
CALL FLUSH_PUTSTUFF
POP EDX
JMP L1019$
PUTSTUFF_SMALL_QUIK32 ENDP
FIX_BUFFERS_QUIK32 PROC NEAR
;
;TELL EXPANDER TO FIX UP POINTERS
;ALSO TELL COMPRESSER WE JUST DID ANOTHER 16K
;
MOV EAX,81H-THRESHOLD
FIX_BUFFERS_QUIK32 ENDP
PUTSTUFF_QUIK32 PROC NEAR
;
;EAX IS CHAR, EBX IS DISTANCE
;
;NOW STORE CHAR
;
MOV EDI,SLR_TMP_PTR
MOV EDX,SLR_MASK
;
;>255, OUTPUT A ZERO BIT
;
SHR EDX,1 ;0
JZ L20$
MOV SLR_MASK,EDX
L209$:
;
;FIRST WE OUTPUT COPY COUNT
;
;
;FIRST TRY 2-3
;
PUSH EAX
CMP AL,3-THRESHOLD
JA L1$
L19$:
CALL PUT_0 ;0X 2-3
JMP L49$
L20$:
MOV SLR_MASK,EDX
CALL FLUSH_PUTSTUFF
JMP L209$
L1$:
SUB AL,4-THRESHOLD
CALL PUT_1 ;1
CMP AL,2 ;TRY 4-5
JB L19$
SUB AL,2
CALL PUT_1 ;11
CMP AL,2 ;TRY 6-7
JB L19$
SUB AL,2
CALL PUT_1 ;111
CMP AL,4 ;TRY 8-11
JAE L2$
CALL PUT_0 ;1110XX 8-11
CALL PUT_AL_TWO_BITS
JMP L5$
L2$:
SUB AL,4
CALL PUT_1 ;1111
CMP AL,8 ;TRY 12-19
JAE L3$
CALL PUT_0 ;11110XXX 12-19
CALL PUT_AL_3_BITS
JMP L5$
L3$:
POP EAX
CALL PUT_1 ;11111
PUSH EAX
ADD AL,THRESHOLD
MOV [EDI],AL
INC EDI
JMP L5$
L49$:
ROR AL,1
CALL PUT_0_OR_1
L5$:
;
;NOW SEND POSITION PLEASE
;
POP EAX
CMP AL,2-THRESHOLD ;TWO JUST GETS 8-BIT OFFSET
JZ L8$
CMP AL,80H-THRESHOLD
JA L9$ ;ADJUST, QUIT, ETC GET NOTHING...
PUSH EBX
MOV AL,BH
CMP AL,4
JAE L6$
CALL PUT_0 ;00 0
CMP AL,0
JA L51$
L50$:
CALL PUT_0
POP EBX
JMP L81$
L51$:
CALL PUT_1 ;010 1
CMP AL,1
JZ L50$
CALL PUT_1 ;0110 2
ROR AL,1 ;0111 3
CALL PUT_0_OR_1
POP EBX
JMP L81$
L6$:
CALL PUT_1
CMP AL,16
JAE L7$
CALL PUT_0
CMP AL,8
JAE L65$
CALL PUT_0
SUB AL,4 ;100XX 4-7
CALL PUT_AL_TWO_BITS
POP EBX
JMP L81$
L65$:
CALL PUT_1 ;101XXX 8-F
SUB AL,8
CALL PUT_AL_3_BITS
POP EBX
JMP L81$
L7$:
CALL PUT_1
CMP AL,20H
JAE L71$
L70$:
CALL PUT_0 ;110XXXX 10-1F
CALL PUT_AL_4_BITS
POP EBX
JMP L81$
L71$:
CALL PUT_1 ;111
CMP AL,30H
JB L70$ ;1110XXXX 20-2F
CALL PUT_1 ;1111
CMP AL,40H
JB L70$ ;11110XXXX 30-3F
CALL PUT_1 ;11111XXXXXX 40-7F
ROR AL,6
CALL PUT_TWO_BITS
CALL PUT_FOUR_BITS
POP EBX
L8$:
L81$:
MOV [EDI],BL
INC EDI
L9$:
MOV SLR_TMP_PTR,EDI
RET
PUT_AL_3_BITS:
ROR AL,3
ADD AL,AL
CALL PUT_0_OR_1
JMP PUT_TWO_BITS
PUT_AL_4_BITS:
ROR AL,4
PUT_FOUR_BITS:
CALL PUT_TWO_BITS
JMP PUT_TWO_BITS
PUT_AL_TWO_BITS:
ROR AL,2
PUT_TWO_BITS:
ADD AL,AL
CALL PUT_0_OR_1
ADD AL,AL
PUT_0_OR_1:
JC PUT_1
;
;PUT A ZERO
;
PUT_0::
SHR SLR_MASK,1
JZ FLUSH_PUTSTUFF
RET
PUT_1::
MOV ECX,SLR_WORD
MOV EDX,SLR_MASK
OR ECX,EDX
SHR EDX,1
MOV SLR_WORD,ECX
MOV SLR_MASK,EDX
JZ FLUSH_PUTSTUFF
RET
PUTSTUFF_QUIK32 ENDP
FLUSH_PUTSTUFF PROC NEAR
;
;NEED NEW MASK
;
PUSHM EAX
MOV ECX,SLR_CPOS
MOV EAX,SLR_WORD
CMP EDI,OFF HUF_MINI_BUFFER+HMB_SIZE-28
MOV SLR_MASK,8000H
MOV [ECX],AX
JA L51$
L52$:
MOV SLR_CPOS,EDI
XOR EAX,EAX
MOV [EDI],AL
MOV SLR_WORD,EAX
MOV [EDI+1],AL
ADD EDI,2
POP EAX
RET
L51$:
CALL FLUSH_MINI
JMP L52$
FLUSH_PUTSTUFF ENDP
FLUSHSTUFF_QUIK32 PROC NEAR
;
;ALL DONE, SIGNAL END OF IT ALL
;
MOV EAX,82H-THRESHOLD
CALL PUTSTUFF_QUIK32
;
;NOW FLUSH LZ_WORD BY WRITING 15 ZEROS
;
CALL FLUSH_PUTSTUFF
SUB EDI,2
CALL FLUSH_MINI
JMP ?_KEEP_QUIK_COMPRESSED
FLUSH_MINI::
;
;FLUSH STUFF FROM HUF_MINI_BUFFER
;
PUSHM EDX,ECX
MOV ECX,EDI
MOV EAX,OFF HUF_MINI_BUFFER
SUB ECX,EAX
JZ L9$
CALL MOVE_EAX_TO_COMPRESS_OUTPUT
MOV EDI,OFF HUF_MINI_BUFFER
L9$:
POPM ECX,EDX
RET
FLUSHSTUFF_QUIK32 ENDP
endif
END
| 11.4075
| 110
| 0.662503
|
2a7bbe0bfacfdca2266896ac8db793697bf41836
| 475
|
asm
|
Assembly
|
programs/oeis/005/A005356.asm
|
neoneye/loda
|
afe9559fb53ee12e3040da54bd6aa47283e0d9ec
|
[
"Apache-2.0"
] | 22
|
2018-02-06T19:19:31.000Z
|
2022-01-17T21:53:31.000Z
|
programs/oeis/005/A005356.asm
|
neoneye/loda
|
afe9559fb53ee12e3040da54bd6aa47283e0d9ec
|
[
"Apache-2.0"
] | 41
|
2021-02-22T19:00:34.000Z
|
2021-08-28T10:47:47.000Z
|
programs/oeis/005/A005356.asm
|
neoneye/loda
|
afe9559fb53ee12e3040da54bd6aa47283e0d9ec
|
[
"Apache-2.0"
] | 5
|
2021-02-24T21:14:16.000Z
|
2021-08-09T19:48:05.000Z
|
; A005356: Number of low discrepancy sequences in base 2.
; 0,0,1,3,5,8,11,14,18,22,26,30,34,38,43,48,53,58,63,68,73,78,83,89,95,101,107,113,119,125,131,137,143,149,155,161,167,173,179,185,191,198,205,212,219,226,233,240,247,254,261,268,275,282,289,296
mov $2,$0
mov $6,$0
lpb $2
mov $0,$6
sub $2,1
sub $0,$2
mul $0,2
mov $3,$0
add $3,1
pow $3,2
mov $4,6
mov $5,6
lpb $3
add $3,$5
div $3,3
add $4,1
lpe
sub $4,8
add $1,$4
lpe
mov $0,$1
| 19
| 194
| 0.591579
|
63ecfed25f9b12e5c69214c1127d185a43e70e00
| 424
|
asm
|
Assembly
|
programs/oeis/202/A202049.asm
|
jmorken/loda
|
99c09d2641e858b074f6344a352d13bc55601571
|
[
"Apache-2.0"
] | 1
|
2021-03-15T11:38:20.000Z
|
2021-03-15T11:38:20.000Z
|
programs/oeis/202/A202049.asm
|
jmorken/loda
|
99c09d2641e858b074f6344a352d13bc55601571
|
[
"Apache-2.0"
] | null | null | null |
programs/oeis/202/A202049.asm
|
jmorken/loda
|
99c09d2641e858b074f6344a352d13bc55601571
|
[
"Apache-2.0"
] | null | null | null |
; A202049: Number of (n+2) X 7 binary arrays avoiding patterns 001 and 110 in rows and columns.
; 966,3304,9170,22092,47950,95984,180054,320180,544390,890904,1410682,2170364,3255630,4775008,6864158,9690660,13459334,18418120,24864546,33152812,43701518,57002064,73627750,94243604,119616966,150628856
mov $1,9
add $1,$0
add $0,2
bin $1,$0
sub $0,2
mul $1,2
sub $1,7
mov $2,2
add $2,$0
sub $1,$2
sub $1,63
mul $1,14
add $1,966
| 24.941176
| 201
| 0.742925
|
6cb96234e2a9b5e8b74fb90147c0c2f42df3da63
| 632
|
asm
|
Assembly
|
chapter09/ex9.asm
|
bgst009/AssemblyLanguage
|
60969495e42830a2e5be5fb6d6dacf2dc635e3d4
|
[
"Apache-2.0"
] | null | null | null |
chapter09/ex9.asm
|
bgst009/AssemblyLanguage
|
60969495e42830a2e5be5fb6d6dacf2dc635e3d4
|
[
"Apache-2.0"
] | null | null | null |
chapter09/ex9.asm
|
bgst009/AssemblyLanguage
|
60969495e42830a2e5be5fb6d6dacf2dc635e3d4
|
[
"Apache-2.0"
] | 1
|
2021-05-21T07:05:07.000Z
|
2021-05-21T07:05:07.000Z
|
assume cs:code,ds:data,ss:stack
stack segment
db 128 dup(0)
stack ends
data segment
db 'welcome to masm!'
db 00001010B
db 00101100B
db 01111001B
data ends
code segment
start:
mov ax,data
mov ds,ax
mov ax,0b800h
mov es,ax
mov si,0
mov bx,16
mov di,160*10+2*30
mov cx,3
showRow:
push bx
push cx
push si
push di
mov cx,16
mov ah,ds:[bx]
show:
mov al,ds:[si]
mov es:[di],ax
inc si
add di,2
loop show
pop di
pop si
pop cx
pop bx
inc bx
add di,160
loop showRow
mov ax,4c00h
int 21h
code ends
end start
| 10.031746
| 31
| 0.582278
|
5828c518e7b58c84c39aeff85aadfddc1e701663
| 438
|
asm
|
Assembly
|
oeis/335/A335840.asm
|
neoneye/loda-programs
|
84790877f8e6c2e821b183d2e334d612045d29c0
|
[
"Apache-2.0"
] | 11
|
2021-08-22T19:44:55.000Z
|
2022-03-20T16:47:57.000Z
|
oeis/335/A335840.asm
|
neoneye/loda-programs
|
84790877f8e6c2e821b183d2e334d612045d29c0
|
[
"Apache-2.0"
] | 9
|
2021-08-29T13:15:54.000Z
|
2022-03-09T19:52:31.000Z
|
oeis/335/A335840.asm
|
neoneye/loda-programs
|
84790877f8e6c2e821b183d2e334d612045d29c0
|
[
"Apache-2.0"
] | 3
|
2021-08-22T20:56:47.000Z
|
2021-09-29T06:26:12.000Z
|
; A335840: Expansion of x*(1+2*x)/((1-2*x)*(1-x+4*x^2)).
; Submitted by Jon Maiga
; 1,5,9,5,1,45,169,245,81,125,1849,5445,6241,845,8649,70805,167281,146205,1369,465125,2556801,4890605,3052009,266805,21613201,87654845,135419769,53235845,48427681,909226125,2862999049,3521061845,659000241,3754622045
mov $1,1
mov $2,1
mov $3,2
lpb $0
sub $0,1
sub $3,$1
mul $3,4
add $3,3
add $1,$3
mul $2,2
add $2,1
sub $1,$2
lpe
mov $0,$1
| 23.052632
| 215
| 0.675799
|
84ced2ed30ab023b2fede7d77b38efba32006bb2
| 291
|
asm
|
Assembly
|
libsrc/_DEVELOPMENT/l/sccz80/9-common/l_debug_pop_frame.asm
|
ahjelm/z88dk
|
c4de367f39a76b41f6390ceeab77737e148178fa
|
[
"ClArtistic"
] | 640
|
2017-01-14T23:33:45.000Z
|
2022-03-30T11:28:42.000Z
|
libsrc/_DEVELOPMENT/l/sccz80/9-common/l_debug_pop_frame.asm
|
ahjelm/z88dk
|
c4de367f39a76b41f6390ceeab77737e148178fa
|
[
"ClArtistic"
] | 1,600
|
2017-01-15T16:12:02.000Z
|
2022-03-31T12:11:12.000Z
|
libsrc/_DEVELOPMENT/l/sccz80/9-common/l_debug_pop_frame.asm
|
ahjelm/z88dk
|
c4de367f39a76b41f6390ceeab77737e148178fa
|
[
"ClArtistic"
] | 215
|
2017-01-17T10:43:03.000Z
|
2022-03-23T17:25:02.000Z
|
IF !__CPU_GBZ80__
SECTION code_clib
SECTION code_l_sccz80
PUBLIC l_debug_pop_frame
EXTERN __debug_framepointer
l_debug_pop_frame:
pop bc ;return code
ex (sp),hl ;hl=old frame pointer
ld (__debug_framepointer),hl
pop hl
push bc
ret
ENDIF
| 16.166667
| 41
| 0.680412
|
1a3d28cff9bd0a1253508b188c169cefa8d6f646
| 697
|
asm
|
Assembly
|
data/pokemon/base_stats/mantine.asm
|
Karkino/KarkCrystal16
|
945dde0354016f9357e9d3798312cc6efa52ff7a
|
[
"blessing"
] | null | null | null |
data/pokemon/base_stats/mantine.asm
|
Karkino/KarkCrystal16
|
945dde0354016f9357e9d3798312cc6efa52ff7a
|
[
"blessing"
] | null | null | null |
data/pokemon/base_stats/mantine.asm
|
Karkino/KarkCrystal16
|
945dde0354016f9357e9d3798312cc6efa52ff7a
|
[
"blessing"
] | null | null | null |
db 0 ; species ID placeholder
db 85, 40, 70, 70, 80, 140
; hp atk def spd sat sdf
db WATER, FLYING ; type
db 25 ; catch rate
db 168 ; base exp
db NO_ITEM, NO_ITEM ; items
db GENDER_F50 ; gender ratio
db 100 ; unknown 1
db 25 ; step cycles to hatch
db 5 ; unknown 2
INCBIN "gfx/pokemon/mantine/front.dimensions"
db 0, 0, 0, 0 ; padding
db GROWTH_SLOW ; growth rate
dn EGG_WATER_1, EGG_WATER_1 ; egg groups
; tm/hm learnset
tmhm HEADBUTT, CURSE, TOXIC, DARK_PULSE, SNORE, BLIZZARD, ICY_WIND, PROTECT, RAIN_DANCE, IRON_HEAD, THUNDER, RETURN, DOUBLE_TEAM, SWAGGER, SLEEP_TALK, SWIFT, PURSUIT, REST, ATTRACT, STEEL_WING, FLY, SURF, WHIRLPOOL, WATERFALL, ICE_BEAM
; end
| 31.681818
| 236
| 0.708752
|
d99c0c9718ea95c5d72cd2c9b7655a0a9286df63
| 705
|
asm
|
Assembly
|
oeis/078/A078318.asm
|
neoneye/loda-programs
|
84790877f8e6c2e821b183d2e334d612045d29c0
|
[
"Apache-2.0"
] | 11
|
2021-08-22T19:44:55.000Z
|
2022-03-20T16:47:57.000Z
|
oeis/078/A078318.asm
|
neoneye/loda-programs
|
84790877f8e6c2e821b183d2e334d612045d29c0
|
[
"Apache-2.0"
] | 9
|
2021-08-29T13:15:54.000Z
|
2022-03-09T19:52:31.000Z
|
oeis/078/A078318.asm
|
neoneye/loda-programs
|
84790877f8e6c2e821b183d2e334d612045d29c0
|
[
"Apache-2.0"
] | 3
|
2021-08-22T20:56:47.000Z
|
2021-09-29T06:26:12.000Z
|
; A078318: Sum of divisors of n*rad(n)+1, where rad=A007947 (squarefree kernel).
; Submitted by Christian Krause
; 3,6,18,13,42,38,93,18,56,102,186,74,324,198,342,48,540,110,546,272,756,588,972,180,312,678,126,528,1266,972,1596,84,1980,1260,1842,256,2484,1842,2286,402,2613,2124,3534,1440,1281,2220,4536,307,660,672,3906,2016,5076,434,4860,948,6552,4044,5226,1802,5586,4620,2324,176,6342,4358,8100,3354,7146,5490,7566,434,10584,5478,1692,4320,10692,7308,9366,1170,434,8370,13608,3530,10842,7980,13644,2100,12636,2812,12852,6048,16182,8838,13542,578,16956,1374,6160,1344
seq $0,64549 ; a(n) = n * Product_{primes p|n} p.
seq $0,203 ; a(n) = sigma(n), the sum of the divisors of n. Also called sigma_1(n).
| 100.714286
| 456
| 0.743262
|
6fe4df6df6152ceb9e97cba164a879fabc705513
| 517
|
asm
|
Assembly
|
oeis/159/A159702.asm
|
neoneye/loda-programs
|
84790877f8e6c2e821b183d2e334d612045d29c0
|
[
"Apache-2.0"
] | 11
|
2021-08-22T19:44:55.000Z
|
2022-03-20T16:47:57.000Z
|
oeis/159/A159702.asm
|
neoneye/loda-programs
|
84790877f8e6c2e821b183d2e334d612045d29c0
|
[
"Apache-2.0"
] | 9
|
2021-08-29T13:15:54.000Z
|
2022-03-09T19:52:31.000Z
|
oeis/159/A159702.asm
|
neoneye/loda-programs
|
84790877f8e6c2e821b183d2e334d612045d29c0
|
[
"Apache-2.0"
] | 3
|
2021-08-22T20:56:47.000Z
|
2021-09-29T06:26:12.000Z
|
; A159702: Decimal expansion of (969 + 44*sqrt(2))/967.
; Submitted by Christian Krause
; 1,0,6,6,4,1,7,1,6,3,1,2,7,6,2,7,9,0,2,9,4,4,4,4,0,8,5,1,9,8,0,5,8,6,0,5,5,2,8,1,3,5,0,1,1,6,3,5,6,3,4,5,1,0,3,6,3,9,8,9,0,2,8,7,9,7,4,7,5,9,2,8,5,4,7,2,9,3,9,7,2,0,4,8,5,4,3,6,4,5,4,5,0,9,2,2,0,5,0,5
bin $1,$0
mov $2,2
mov $3,$0
mul $3,4
lpb $3
add $5,$2
add $1,$5
add $2,$1
mov $1,$2
sub $3,1
lpe
mul $1,2
add $2,$5
mov $4,10
pow $4,$0
add $5,$2
div $2,3
mul $2,60
add $2,$5
div $2,$4
div $1,$2
mov $0,$1
mod $0,10
| 18.464286
| 201
| 0.539652
|
e0552d670b875145da7cd5e35e1253e7aaf45684
| 2,912
|
asm
|
Assembly
|
assiignment3.asm
|
Klaus073/Assembly-language
|
2ddddf9e3ef6ce6c05f56b015be5697d1ac3c0be
|
[
"BSD-2-Clause"
] | null | null | null |
assiignment3.asm
|
Klaus073/Assembly-language
|
2ddddf9e3ef6ce6c05f56b015be5697d1ac3c0be
|
[
"BSD-2-Clause"
] | null | null | null |
assiignment3.asm
|
Klaus073/Assembly-language
|
2ddddf9e3ef6ce6c05f56b015be5697d1ac3c0be
|
[
"BSD-2-Clause"
] | null | null | null |
;q1
[org 0x0100]
jmp start
Array: dw 3, 9, 56, 43, 1, 2, 23
odd_counter: dw 0
even_counter: dw 0
Odd_Subroutine: ;; function for finding no. of odd number is array by Subroutine method
mov cx,2 ;divider
loop_odd:
xor ax,ax
xor dx,dx
mov ax ,[Array+bx]
div cx
cmp dx ,1
jne odd
add word[odd_counter],1
odd:
add bx,2
cmp bx,14
jne loop_odd
ret
Even_Subroutine: ;; function for finding no. of even number is array by Subroutine method
mov cx,2 ;divider
loop_even:
xor ax,ax
xor dx,dx
mov ax ,[Array+bx]
div cx
cmp dx ,1
je even
add word[even_counter],1
even:
add bx,2
cmp bx,14
jne loop_even
ret
;///////////////////////
;; Main Function
start:
mov ax,0
mov bx,0
mov dx,0
call Odd_Subroutine ;; Calling the odd function
mov ax,0
mov bx,0
mov dx,0
call Even_Subroutine ;; Calling the even function
mov ax, 0x4c00
int 0x21
;q2
[org 0x0100]
jmp start
Example: dw 47, 79, 31
sum_of_two_digit: dw 0
divider: dw 10
Subroutine_Function:
mov ax,0
mov bx,0
mov cx,0
mov dx,0
mov ax,[Example+bx] ;; static for 1st value of the array ;; we ll store first value sum to compare with other sums..
div word[divider] ;; it ll divide every coming value with 10
add dx,ax ;; it ll add the quotiont in label e.g 47-> 0+4=4
add word[sum_of_two_digit],dx ;; it ll add the remainder in the previous same label e.g 47-> 4+7=11
loop:
xor ax,ax
xor dx,dx
xor cx,cx
mov ax,word[Example+bx+2] ;; now ax ll get the 2nd value in the of array ,,
div word[divider] ;; divider
add dx,ax ;; e.g 47-> 0+4=4
mov cx,dx ;; it ll put the value of ax e.g 47 in the cx
cmp cx,[sum_of_two_digit] ;; here we ll compare the the sum of 1st value of array with summ 0f 2nd val of array
jng greater
mov si,word[Example+bx+2]
mov word[sum_of_two_digit],cx
greater:
mov si,word[Example+bx]
add bx,2
cmp bx,4 ;; chechks end loop condition
jne loop ;; loop if
mov ax, 0x4c00
int 0x21
start:
call Subroutine_Function ;; Calling the function
mov ax, 0x4c00
int 0x21
;q3
[org 0x0100]
jmp start
sum: dw 0
sum1: dw 0
add2:
mov bp,sp
mov cx,[bp+2]
add cx,ax
add cx,bx
pop word[bp+2]
ret
add1:
push bp
mov bp,sp
mov ax,[bp+4]
mov bx,[bp+6]
add word[sum],bx
add word[sum],ax
push word[sum]
call add2
pop bp
ret 4
start:
push 5
push 4
call add1
mov ax, 0x4c00
int 0x21
| 16.088398
| 120
| 0.544643
|
e0a062695b99a69d3d830b75316189ed7c8e94bf
| 116
|
asm
|
Assembly
|
libsrc/_DEVELOPMENT/arch/zx/misc/c/sccz80/zx_cls.asm
|
meesokim/z88dk
|
5763c7778f19a71d936b3200374059d267066bb2
|
[
"ClArtistic"
] | null | null | null |
libsrc/_DEVELOPMENT/arch/zx/misc/c/sccz80/zx_cls.asm
|
meesokim/z88dk
|
5763c7778f19a71d936b3200374059d267066bb2
|
[
"ClArtistic"
] | null | null | null |
libsrc/_DEVELOPMENT/arch/zx/misc/c/sccz80/zx_cls.asm
|
meesokim/z88dk
|
5763c7778f19a71d936b3200374059d267066bb2
|
[
"ClArtistic"
] | null | null | null |
; void zx_cls(uchar attr)
SECTION code_arch
PUBLIC zx_cls
zx_cls:
INCLUDE "arch/zx/misc/z80/asm_zx_cls.asm"
| 10.545455
| 44
| 0.741379
|
b0b8e39924a2772a1e211447a8baa75d422e3754
| 681
|
asm
|
Assembly
|
oeis/127/A127896.asm
|
neoneye/loda-programs
|
84790877f8e6c2e821b183d2e334d612045d29c0
|
[
"Apache-2.0"
] | 11
|
2021-08-22T19:44:55.000Z
|
2022-03-20T16:47:57.000Z
|
oeis/127/A127896.asm
|
neoneye/loda-programs
|
84790877f8e6c2e821b183d2e334d612045d29c0
|
[
"Apache-2.0"
] | 9
|
2021-08-29T13:15:54.000Z
|
2022-03-09T19:52:31.000Z
|
oeis/127/A127896.asm
|
neoneye/loda-programs
|
84790877f8e6c2e821b183d2e334d612045d29c0
|
[
"Apache-2.0"
] | 3
|
2021-08-22T20:56:47.000Z
|
2021-09-29T06:26:12.000Z
|
; A127896: Expansion of 1/(1 + 2*x + 3*x^2 + x^3).
; Submitted by Jamie Morken(s1)
; 1,-2,1,3,-7,4,10,-25,16,33,-89,63,108,-316,245,350,-1119,943,1121,-3952,3598,3539,-13920,13625,10971,-48897,51256,33208,-171287,191694,97265,-598325,713161,271388,-2083934,2640543,699328,-7236351,9734175,1541375,-25048924,35739548,2126301,-86422322,130726193,-4311721,-297132815,476474600,-57239034,-1017812917,1730868336,-351058887,-3472674317,6267656959,-1766232080,-11797832400,22626704081,-8093678882,-39894922079,81444176723,-35109908327,-134217791436,292321131130,-146878979625,-448987642704
add $0,1
mov $4,1
lpb $0
mov $3,$2
sub $2,3
bin $3,$0
sub $0,1
add $4,$3
lpe
mov $0,$4
| 45.4
| 499
| 0.737151
|
eb2b1e32e4334ea59f1efd9b855c2888bd66afa2
| 144
|
asm
|
Assembly
|
libsrc/_DEVELOPMENT/stdlib/c/sdcc_iy/atexit_fastcall.asm
|
meesokim/z88dk
|
5763c7778f19a71d936b3200374059d267066bb2
|
[
"ClArtistic"
] | null | null | null |
libsrc/_DEVELOPMENT/stdlib/c/sdcc_iy/atexit_fastcall.asm
|
meesokim/z88dk
|
5763c7778f19a71d936b3200374059d267066bb2
|
[
"ClArtistic"
] | null | null | null |
libsrc/_DEVELOPMENT/stdlib/c/sdcc_iy/atexit_fastcall.asm
|
meesokim/z88dk
|
5763c7778f19a71d936b3200374059d267066bb2
|
[
"ClArtistic"
] | null | null | null |
; int atexit_fastcall(void (*func)(void))
SECTION code_stdlib
PUBLIC _atexit_fastcall
EXTERN asm_atexit
defc _atexit_fastcall = asm_atexit
| 13.090909
| 41
| 0.805556
|
4c0013328bf01de5ff4f5f106b3841dd9c6e1427
| 4,571
|
asm
|
Assembly
|
Transynther/x86/_processed/NONE/_xt_/i7-7700_9_0x48_notsx.log_21829_97.asm
|
ljhsiun2/medusa
|
67d769b8a2fb42c538f10287abaf0e6dbb463f0c
|
[
"MIT"
] | 9
|
2020-08-13T19:41:58.000Z
|
2022-03-30T12:22:51.000Z
|
Transynther/x86/_processed/NONE/_xt_/i7-7700_9_0x48_notsx.log_21829_97.asm
|
ljhsiun2/medusa
|
67d769b8a2fb42c538f10287abaf0e6dbb463f0c
|
[
"MIT"
] | 1
|
2021-04-29T06:29:35.000Z
|
2021-05-13T21:02:30.000Z
|
Transynther/x86/_processed/NONE/_xt_/i7-7700_9_0x48_notsx.log_21829_97.asm
|
ljhsiun2/medusa
|
67d769b8a2fb42c538f10287abaf0e6dbb463f0c
|
[
"MIT"
] | 3
|
2020-07-14T17:07:07.000Z
|
2022-03-21T01:12:22.000Z
|
.global s_prepare_buffers
s_prepare_buffers:
push %r11
push %r13
push %r15
push %rbp
push %rcx
push %rdi
push %rsi
lea addresses_D_ht+0x19ed, %rsi
lea addresses_UC_ht+0x18b8d, %rdi
xor $42686, %r15
mov $126, %rcx
rep movsw
nop
nop
nop
sub $39795, %rbp
lea addresses_UC_ht+0x1d59d, %r13
nop
nop
lfence
movb (%r13), %r15b
mfence
lea addresses_D_ht+0xf695, %r13
nop
nop
nop
dec %r15
movl $0x61626364, (%r13)
nop
nop
nop
nop
add %rsi, %rsi
pop %rsi
pop %rdi
pop %rcx
pop %rbp
pop %r15
pop %r13
pop %r11
ret
.global s_faulty_load
s_faulty_load:
push %r11
push %r12
push %r13
push %r14
push %r15
push %rdi
// Faulty Load
lea addresses_A+0x1a9ed, %r15
nop
nop
nop
nop
dec %rdi
movups (%r15), %xmm6
vpextrq $0, %xmm6, %r14
lea oracles, %r12
and $0xff, %r14
shlq $12, %r14
mov (%r12,%r14,1), %r14
pop %rdi
pop %r15
pop %r14
pop %r13
pop %r12
pop %r11
ret
/*
<gen_faulty_load>
[REF]
{'OP': 'LOAD', 'src': {'same': True, 'NT': False, 'AVXalign': False, 'size': 32, 'type': 'addresses_A', 'congruent': 0}}
[Faulty Load]
{'OP': 'LOAD', 'src': {'same': True, 'NT': False, 'AVXalign': False, 'size': 16, 'type': 'addresses_A', 'congruent': 0}}
<gen_prepare_buffer>
{'dst': {'same': False, 'congruent': 5, 'type': 'addresses_UC_ht'}, 'OP': 'REPM', 'src': {'same': False, 'congruent': 6, 'type': 'addresses_D_ht'}}
{'OP': 'LOAD', 'src': {'same': False, 'NT': False, 'AVXalign': False, 'size': 1, 'type': 'addresses_UC_ht', 'congruent': 4}}
{'dst': {'same': False, 'NT': False, 'AVXalign': False, 'size': 4, 'type': 'addresses_D_ht', 'congruent': 2}, 'OP': 'STOR'}
{'35': 21829}
35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35 35
*/
| 51.943182
| 2,999
| 0.662656
|
6391b48c19f49402dc105b53d2752170a43571eb
| 795
|
asm
|
Assembly
|
Game of Life/C64GameOfLife/Macros.asm
|
detlefgrohs/C64
|
f9b6c0bb664b93aecae92f6a8f4db5225148dfdb
|
[
"MIT"
] | null | null | null |
Game of Life/C64GameOfLife/Macros.asm
|
detlefgrohs/C64
|
f9b6c0bb664b93aecae92f6a8f4db5225148dfdb
|
[
"MIT"
] | null | null | null |
Game of Life/C64GameOfLife/Macros.asm
|
detlefgrohs/C64
|
f9b6c0bb664b93aecae92f6a8f4db5225148dfdb
|
[
"MIT"
] | null | null | null |
!MACRO ROL_3 {
ROL
ROL
ROL
}
!MACRO ROL_7 {
ROL
ROL
ROL
ROL
ROL
ROL
ROL
}
!MACRO ROR_5 {
ROR
ROR
ROR
ROR
ROR
}
!MACRO LOAD_WORD_TO_ZPA ZPA, WORD {
LDA #<WORD
STA ZPA
LDA #>WORD
STA ZPA + 1
}
!MACRO COPY_WORD_TO_ZPA ZPA_WORD, ZPA {
LDA (ZPA_WORD), Y
STA ZPA
INY
LDA (ZPA_WORD), Y
STA ZPA + 1
INY
}
!MACRO ADD_BYTE_TO_WORD_ZPA ZPA, BYTE {
CLC
LDA ZPA
ADC #BYTE
STA ZPA
BCC +
INC ZPA + 1
+
}
!MACRO COPY_ZPA_WORD ZPA_SRC, ZPA_DST {
LDA ZPA_SRC
STA ZPA_DST
LDA ZPA_SRC + 1
STA ZPA_DST + 1
}
| 15.9
| 39
| 0.431447
|
34d634ab27ba96feb03397b823ff2c9439bc6a61
| 3,818
|
asm
|
Assembly
|
src/vm/arm64/PInvokeStubs.asm
|
danmosemsft/coreclr
|
04a3d11e4eecec2a4b7dcc81ab1575a57e30e3e2
|
[
"MIT"
] | 6
|
2017-09-22T06:55:45.000Z
|
2021-07-02T07:07:08.000Z
|
src/vm/arm64/PInvokeStubs.asm
|
danmosemsft/coreclr
|
04a3d11e4eecec2a4b7dcc81ab1575a57e30e3e2
|
[
"MIT"
] | 2
|
2017-09-23T08:21:05.000Z
|
2017-09-27T03:31:06.000Z
|
src/vm/arm64/PInvokeStubs.asm
|
danmosemsft/coreclr
|
04a3d11e4eecec2a4b7dcc81ab1575a57e30e3e2
|
[
"MIT"
] | 2
|
2017-06-04T15:47:12.000Z
|
2020-03-16T07:01:47.000Z
|
; Licensed to the .NET Foundation under one or more agreements.
; The .NET Foundation licenses this file to you under the MIT license.
; See the LICENSE file in the project root for more information.
; ==++==
;;
;;
;; ==--==
#include "ksarm64.h"
#include "asmconstants.h"
#include "asmmacros.h"
IMPORT VarargPInvokeStubWorker
IMPORT GenericPInvokeCalliStubWorker
; ------------------------------------------------------------------
; Macro to generate PInvoke Stubs.
; $__PInvokeStubFuncName : function which calls the actual stub obtained from VASigCookie
; $__PInvokeGenStubFuncName : function which generates the IL stubs for PInvoke
;
; Params :-
; $FuncPrefix : prefix of the function name for the stub
; Eg. VarargPinvoke, GenericPInvokeCalli
; $VASigCookieReg : register which contains the VASigCookie
; $SaveFPArgs : "Yes" or "No" . For varidic functions FP Args are not present in FP regs
; So need not save FP Args registers for vararg Pinvoke
MACRO
PINVOKE_STUB $FuncPrefix,$VASigCookieReg,$HiddenArg,$SaveFPArgs
GBLS __PInvokeStubFuncName
GBLS __PInvokeGenStubFuncName
GBLS __PInvokeStubWorkerName
IF "$FuncPrefix" == "GenericPInvokeCalli"
__PInvokeStubFuncName SETS "$FuncPrefix":CC:"Helper"
ELSE
__PInvokeStubFuncName SETS "$FuncPrefix":CC:"Stub"
ENDIF
__PInvokeGenStubFuncName SETS "$FuncPrefix":CC:"GenILStub"
__PInvokeStubWorkerName SETS "$FuncPrefix":CC:"StubWorker"
IF "$VASigCookieReg" == "x1"
__PInvokeStubFuncName SETS "$__PInvokeStubFuncName":CC:"_RetBuffArg"
__PInvokeGenStubFuncName SETS "$__PInvokeGenStubFuncName":CC:"_RetBuffArg"
ENDIF
NESTED_ENTRY $__PInvokeStubFuncName
; get the stub
ldr x9, [$VASigCookieReg, #VASigCookie__pNDirectILStub]
; if null goto stub generation
cbz x9, %0
EPILOG_BRANCH_REG x9
0
EPILOG_BRANCH $__PInvokeGenStubFuncName
NESTED_END
NESTED_ENTRY $__PInvokeGenStubFuncName
PROLOG_WITH_TRANSITION_BLOCK 0, $SaveFPArgs
; x2 = Umanaged Target\MethodDesc
mov x2, $HiddenArg
; x1 = VaSigCookie
IF "$VASigCookieReg" != "x1"
mov x1, $VASigCookieReg
ENDIF
; x0 = pTransitionBlock
add x0, sp, #__PWTB_TransitionBlock
; save hidden arg
mov x19, $HiddenArg
bl $__PInvokeStubWorkerName
; restore hidden arg (method desc or unmanaged target)
mov $HiddenArg , x19
EPILOG_WITH_TRANSITION_BLOCK_TAILCALL
EPILOG_BRANCH $__PInvokeStubFuncName
NESTED_END
MEND
TEXTAREA
; ------------------------------------------------------------------
; VarargPInvokeStub & VarargPInvokeGenILStub
; There is a separate stub when the method has a hidden return buffer arg.
;
; in:
; x0 = VASigCookie*
; x12 = MethodDesc *
;
PINVOKE_STUB VarargPInvoke, x0, x12, {false}
; ------------------------------------------------------------------
; GenericPInvokeCalliHelper & GenericPInvokeCalliGenILStub
; Helper for generic pinvoke calli instruction
;
; in:
; x15 = VASigCookie*
; x14 = Unmanaged target
;
PINVOKE_STUB GenericPInvokeCalli, x15, x14, {true}
; ------------------------------------------------------------------
; VarargPInvokeStub_RetBuffArg & VarargPInvokeGenILStub_RetBuffArg
; Vararg PInvoke Stub when the method has a hidden return buffer arg
;
; in:
; x1 = VASigCookie*
; x12 = MethodDesc*
;
PINVOKE_STUB VarargPInvoke, x1, x12, {false}
; Must be at very end of file
END
| 27.666667
| 89
| 0.608958
|
3cfa4cff8882783b582638d9a6ffe94b09a0de8e
| 512
|
asm
|
Assembly
|
programs/oeis/284/A284620.asm
|
neoneye/loda
|
afe9559fb53ee12e3040da54bd6aa47283e0d9ec
|
[
"Apache-2.0"
] | 22
|
2018-02-06T19:19:31.000Z
|
2022-01-17T21:53:31.000Z
|
programs/oeis/284/A284620.asm
|
neoneye/loda
|
afe9559fb53ee12e3040da54bd6aa47283e0d9ec
|
[
"Apache-2.0"
] | 41
|
2021-02-22T19:00:34.000Z
|
2021-08-28T10:47:47.000Z
|
programs/oeis/284/A284620.asm
|
neoneye/loda
|
afe9559fb53ee12e3040da54bd6aa47283e0d9ec
|
[
"Apache-2.0"
] | 5
|
2021-02-24T21:14:16.000Z
|
2021-08-09T19:48:05.000Z
|
; A284620: {00->2}-transform of the infinite Fibonacci word A003849.
; 0,1,2,1,0,1,2,1,2,1,0,1,2,1,0,1,2,1,2,1,0,1,2,1,2,1,0,1,2,1,0,1,2,1,2,1,0,1,2,1,0,1,2,1,2,1,0,1,2,1,2,1,0,1,2,1,0,1,2,1,2,1,0,1,2,1,2,1,0,1,2,1,0,1,2,1,2,1,0,1,2,1,0,1,2,1,2,1,0,1,2,1,2,1,0,1,2,1,0,1
mov $3,2
mov $5,$0
lpb $3
mov $0,$5
sub $3,1
add $0,$3
trn $0,1
seq $0,187952 ; Positions of 1 in A187950; complement of A187951.
mov $2,$3
mul $2,$0
add $1,$2
mov $4,$0
lpe
min $5,1
mul $5,$4
sub $1,$5
sub $1,1
mov $0,$1
| 23.272727
| 201
| 0.554688
|
43666fd7ff69e74b5510d8e17791760a036132f4
| 239
|
asm
|
Assembly
|
libsrc/_DEVELOPMENT/ctype/z80/asm_toupper.asm
|
meesokim/z88dk
|
5763c7778f19a71d936b3200374059d267066bb2
|
[
"ClArtistic"
] | null | null | null |
libsrc/_DEVELOPMENT/ctype/z80/asm_toupper.asm
|
meesokim/z88dk
|
5763c7778f19a71d936b3200374059d267066bb2
|
[
"ClArtistic"
] | null | null | null |
libsrc/_DEVELOPMENT/ctype/z80/asm_toupper.asm
|
meesokim/z88dk
|
5763c7778f19a71d936b3200374059d267066bb2
|
[
"ClArtistic"
] | null | null | null |
SECTION code_ctype
PUBLIC asm_toupper
asm_toupper:
; if char is in [a-z] make it upper case
; enter : a = char
; exit : a = upper case char
; uses : af
cp 'a'
ret c
cp 'z'+1
ret nc
and $df
ret
| 10.863636
| 43
| 0.543933
|
4471b486bd6cbe69f40cbe323bf40713b4aa2339
| 435
|
asm
|
Assembly
|
print/p009.asm
|
czfshine/assembly-exercise
|
95c8be8331810dfd12f50e48109a4b2a8a978853
|
[
"MIT"
] | 1
|
2018-05-16T13:01:26.000Z
|
2018-05-16T13:01:26.000Z
|
print/p009.asm
|
czfshine/assembly-exercise
|
95c8be8331810dfd12f50e48109a4b2a8a978853
|
[
"MIT"
] | null | null | null |
print/p009.asm
|
czfshine/assembly-exercise
|
95c8be8331810dfd12f50e48109a4b2a8a978853
|
[
"MIT"
] | null | null | null |
; 8086 assembly file
; by:czfshine
; date: 2018/04/12 10:10:56
;编写一个程序,从键盘输入一个不长于8位的四进制数,
;并将所输入的数以10进制数形式显示出来。
; The Main Data segment
include scan.inc
DATA SEGMENT
DATA ENDS
;entry code segment
CODE SEGMENT
ASSUME CS:CODE ,DS:DATA
START: ;entry point
MOV AX,DATA
MOV DS,AX
mov di,4
call inputnumbybase
mov si,10
call rebase
MOV AH,4CH ;return
INT 21H
CODE ENDS
END START
| 16.111111
| 34
| 0.666667
|
f3ccc8916cca23e07c55ae06e66bf1660886f08a
| 692
|
asm
|
Assembly
|
oeis/084/A084214.asm
|
neoneye/loda-programs
|
84790877f8e6c2e821b183d2e334d612045d29c0
|
[
"Apache-2.0"
] | 11
|
2021-08-22T19:44:55.000Z
|
2022-03-20T16:47:57.000Z
|
oeis/084/A084214.asm
|
neoneye/loda-programs
|
84790877f8e6c2e821b183d2e334d612045d29c0
|
[
"Apache-2.0"
] | 9
|
2021-08-29T13:15:54.000Z
|
2022-03-09T19:52:31.000Z
|
oeis/084/A084214.asm
|
neoneye/loda-programs
|
84790877f8e6c2e821b183d2e334d612045d29c0
|
[
"Apache-2.0"
] | 3
|
2021-08-22T20:56:47.000Z
|
2021-09-29T06:26:12.000Z
|
; A084214: Inverse binomial transform of a math magic problem.
; Submitted by Jamie Morken(s2)
; 1,1,4,6,14,26,54,106,214,426,854,1706,3414,6826,13654,27306,54614,109226,218454,436906,873814,1747626,3495254,6990506,13981014,27962026,55924054,111848106,223696214,447392426,894784854,1789569706,3579139414,7158278826,14316557654,28633115306,57266230614,114532461226,229064922454,458129844906,916259689814,1832519379626,3665038759254,7330077518506,14660155037014,29320310074026,58640620148054,117281240296106,234562480592214,469124961184426,938249922368854,1876499844737706,3752999689475414
mov $1,2
pow $1,$0
div $1,3
add $1,1
mov $2,$1
div $1,2
add $2,2
mul $2,2
add $2,$1
mov $0,$2
sub $0,5
| 43.25
| 492
| 0.819364
|
86db44670ba30ae9c8b0228663e2e092b65bb1c9
| 7,935
|
asm
|
Assembly
|
maps/AzaleaGym.asm
|
Dev727/ancientplatinum
|
8b212a1728cc32a95743e1538b9eaa0827d013a7
|
[
"blessing"
] | 28
|
2019-11-08T07:19:00.000Z
|
2021-12-20T10:17:54.000Z
|
maps/AzaleaGym.asm
|
Dev727/ancientplatinum
|
8b212a1728cc32a95743e1538b9eaa0827d013a7
|
[
"blessing"
] | 13
|
2020-01-11T17:00:40.000Z
|
2021-09-14T01:27:38.000Z
|
maps/AzaleaGym.asm
|
Dev727/ancientplatinum
|
8b212a1728cc32a95743e1538b9eaa0827d013a7
|
[
"blessing"
] | 22
|
2020-05-28T17:31:38.000Z
|
2022-03-07T20:49:35.000Z
|
object_const_def ; object_event constants
const AZALEAGYM_BUGSY
const AZALEAGYM_BUG_CATCHER1
const AZALEAGYM_BUG_CATCHER2
const AZALEAGYM_BUG_CATCHER3
const AZALEAGYM_TWIN1
const AZALEAGYM_TWIN2
const AZALEAGYM_GYM_GUY
AzaleaGym_MapScripts:
db 0 ; scene scripts
db 0 ; callbacks
AzaleaGymBugsyScript:
faceplayer
opentext
checkevent EVENT_BEAT_BUGSY
iftrue .FightDone
writetext BugsyText_INeverLose
waitbutton
closetext
winlosstext BugsyText_ResearchIncomplete, 0
loadtrainer BUGSY, BUGSY1
startbattle
reloadmapafterbattle
setevent EVENT_BEAT_BUGSY
opentext
writetext Text_ReceivedHiveBadge
playsound SFX_GET_BADGE
waitsfx
setflag ENGINE_HIVEBADGE
readvar VAR_BADGES
scall AzaleaGymActivateRockets
.FightDone:
checkevent EVENT_GOT_TM49_FURY_CUTTER
iftrue .GotFuryCutter
setevent EVENT_BEAT_TWINS_AMY_AND_MAY
setevent EVENT_BEAT_BUG_CATCHER_BENNY
setevent EVENT_BEAT_BUG_CATCHER_AL
setevent EVENT_BEAT_BUG_CATCHER_JOSH
writetext BugsyText_HiveBadgeSpeech
buttonsound
verbosegiveitem TM_FURY_CUTTER
iffalse .NoRoomForFuryCutter
setevent EVENT_GOT_TM49_FURY_CUTTER
writetext BugsyText_FuryCutterSpeech
waitbutton
closetext
end
.GotFuryCutter:
writetext BugsyText_BugMonsAreDeep
waitbutton
.NoRoomForFuryCutter:
closetext
end
AzaleaGymActivateRockets:
ifequal 7, .RadioTowerRockets
ifequal 6, .GoldenrodRockets
end
.GoldenrodRockets:
jumpstd goldenrodrockets
.RadioTowerRockets:
jumpstd radiotowerrockets
TrainerTwinsAmyandmay1:
trainer TWINS, AMYANDMAY1, EVENT_BEAT_TWINS_AMY_AND_MAY, TwinsAmyandmay1SeenText, TwinsAmyandmay1BeatenText, 0, .AfterScript
.AfterScript:
endifjustbattled
opentext
writetext TwinsAmyandmay1AfterBattleText
waitbutton
closetext
end
TrainerTwinsAmyandmay2:
trainer TWINS, AMYANDMAY2, EVENT_BEAT_TWINS_AMY_AND_MAY, TwinsAmyandmay2SeenText, TwinsAmyandmay2BeatenText, 0, .AfterScript
.AfterScript:
endifjustbattled
opentext
writetext TwinsAmyandmay2AfterBattleText
waitbutton
closetext
end
TrainerBugCatcherBenny:
trainer BUG_CATCHER, BUG_CATCHER_BENNY, EVENT_BEAT_BUG_CATCHER_BENNY, BugCatcherBennySeenText, BugCatcherBennyBeatenText, 0, .AfterScript
.AfterScript:
endifjustbattled
opentext
writetext BugCatcherBennyAfterBattleText
waitbutton
closetext
end
TrainerBugCatcherAl:
trainer BUG_CATCHER, AL, EVENT_BEAT_BUG_CATCHER_AL, BugCatcherAlSeenText, BugCatcherAlBeatenText, 0, .AfterScript
.AfterScript:
endifjustbattled
opentext
writetext BugCatcherAlAfterBattleText
waitbutton
closetext
end
TrainerBugCatcherJosh:
trainer BUG_CATCHER, JOSH, EVENT_BEAT_BUG_CATCHER_JOSH, BugCatcherJoshSeenText, BugCatcherJoshBeatenText, 0, .AfterScript
.AfterScript:
endifjustbattled
opentext
writetext BugCatcherJoshAfterBattleText
waitbutton
closetext
end
AzaleaGymGuyScript:
faceplayer
checkevent EVENT_BEAT_BUGSY
iftrue .AzaleaGymGuyWinScript
opentext
writetext AzaleaGymGuyText
waitbutton
closetext
end
.AzaleaGymGuyWinScript:
opentext
writetext AzaleaGymGuyWinText
waitbutton
closetext
end
AzaleaGymStatue:
checkflag ENGINE_HIVEBADGE
iftrue .Beaten
jumpstd gymstatue1
.Beaten:
gettrainername STRING_BUFFER_4, BUGSY, BUGSY1
jumpstd gymstatue2
BugsyText_INeverLose:
text "I'm BUGSY!"
line "I never lose when"
para "it comes to bug"
line "#MON."
para "My research is"
line "going to make me"
para "the authority on"
line "bug #MON!"
para "Let me demonstrate"
line "what I've learned"
cont "from my studies."
done
BugsyText_ResearchIncomplete:
text "Whoa, amazing!"
line "You're an expert"
cont "on #MON!"
para "My research isn't"
line "complete yet."
para "OK, you win. Take"
line "this BADGE."
done
Text_ReceivedHiveBadge:
text "<PLAYER> received"
line "HIVEBADGE."
done
BugsyText_HiveBadgeSpeech:
text "Do you know the"
line "benefits of HIVE-"
cont "BADGE?"
para "If you have it,"
line "#MON up to L30"
para "will obey you,"
line "even traded ones."
para "#MON that know"
line "CUT will be able"
para "to use it outside"
line "of battle too."
para "Here, I also want"
line "you to have this."
done
BugsyText_FuryCutterSpeech:
text "TM49 contains"
line "FURY CUTTER."
para "If you don't miss,"
line "it gets stronger"
cont "every turn."
para "The longer your"
line "battle goes, the"
cont "better it gets."
para "Isn't that great?"
line "I discovered it!"
done
BugsyText_BugMonsAreDeep:
text "Bug #MON are"
line "deep. There are"
para "many mysteries to"
line "be explored."
para "Study your favor-"
line "ites thoroughly."
done
BugCatcherBennySeenText:
text "Bug #MON evolve"
line "young. So they get"
para "stronger that much"
line "faster."
done
BugCatcherBennyBeatenText:
text "Just evolving"
line "isn't enough!"
done
BugCatcherBennyAfterBattleText:
text "#MON become"
line "stronger if they"
cont "evolve. Really!"
done
BugCatcherAlSeenText:
text "Bug #MON are"
line "cool and tough!"
para "I'll prove it to"
line "you!"
done
BugCatcherAlBeatenText:
text "You proved how"
line "tough you are…"
done
BugCatcherAlAfterBattleText:
text "They're so cool,"
line "but most girls"
para "don't like bug"
line "#MON."
para "I don't know why…"
done
BugCatcherJoshSeenText:
text "You saved all the"
line "SLOWPOKE? Whew,"
cont "you're mighty!"
para "But my grown-up"
line "#MON are pretty"
cont "tough too!"
done
BugCatcherJoshBeatenText:
text "Urrgggh!"
done
BugCatcherJoshAfterBattleText:
text "I guess I should"
line "teach them better"
cont "moves…"
done
TwinsAmyandmay1SeenText:
text "AMY: Hi! Are you"
line "challenging the"
cont "LEADER? No way!"
done
TwinsAmyandmay1BeatenText:
text "AMY & MAY: Oh,"
line "double goodness!"
done
TwinsAmyandmay1AfterBattleText:
text "AMY: You're"
line "really strong!"
done
TwinsAmyandmay2SeenText:
text "MAY: You want to"
line "see the LEADER?"
cont "We come first!"
done
TwinsAmyandmay2BeatenText:
text "AMY & MAY: Oh,"
line "double goodness!"
done
TwinsAmyandmay2AfterBattleText:
text "MAY: Our bug #-"
line "MON lost! Oh, what"
cont "a shame."
done
AzaleaGymGuyText:
text "Yo, challenger!"
para "BUGSY's young, but"
line "his knowledge of"
para "bug #MON is for"
line "real."
para "It's going to be"
line "tough without my"
cont "advice."
para "Let's see… Bug"
line "#MON don't like"
cont "fire."
para "Flying-type moves"
line "are super-effec-"
cont "tive too."
done
AzaleaGymGuyWinText:
text "Well done! That"
line "was a great clash"
para "of talented young"
line "trainers."
para "With people like"
line "you, the future of"
cont "#MON is bright!"
done
AzaleaGym_MapEvents:
db 0, 0 ; filler
db 2 ; warp events
warp_event 4, 15, AZALEA_TOWN, 5
warp_event 5, 15, AZALEA_TOWN, 5
db 0 ; coord events
db 2 ; bg events
bg_event 3, 13, BGEVENT_READ, AzaleaGymStatue
bg_event 6, 13, BGEVENT_READ, AzaleaGymStatue
db 7 ; object events
object_event 5, 7, SPRITE_BUGSY, SPRITEMOVEDATA_SPINRANDOM_SLOW, 0, 0, -1, -1, PAL_NPC_GREEN, OBJECTTYPE_SCRIPT, 0, AzaleaGymBugsyScript, -1
object_event 5, 3, SPRITE_BUG_CATCHER, SPRITEMOVEDATA_SPINRANDOM_FAST, 0, 0, -1, -1, PAL_NPC_BROWN, OBJECTTYPE_TRAINER, 2, TrainerBugCatcherBenny, -1
object_event 8, 8, SPRITE_BUG_CATCHER, SPRITEMOVEDATA_STANDING_DOWN, 0, 0, -1, -1, PAL_NPC_BROWN, OBJECTTYPE_TRAINER, 3, TrainerBugCatcherAl, -1
object_event 0, 2, SPRITE_BUG_CATCHER, SPRITEMOVEDATA_STANDING_DOWN, 0, 0, -1, -1, PAL_NPC_BROWN, OBJECTTYPE_TRAINER, 3, TrainerBugCatcherJosh, -1
object_event 4, 10, SPRITE_TWIN, SPRITEMOVEDATA_STANDING_DOWN, 0, 0, -1, -1, PAL_NPC_RED, OBJECTTYPE_TRAINER, 1, TrainerTwinsAmyandmay1, -1
object_event 5, 10, SPRITE_TWIN, SPRITEMOVEDATA_STANDING_DOWN, 0, 0, -1, -1, PAL_NPC_RED, OBJECTTYPE_TRAINER, 1, TrainerTwinsAmyandmay2, -1
object_event 7, 13, SPRITE_GYM_GUY, SPRITEMOVEDATA_STANDING_DOWN, 0, 0, -1, -1, PAL_NPC_RED, OBJECTTYPE_SCRIPT, 0, AzaleaGymGuyScript, -1
| 20.718016
| 152
| 0.775173
|
814c8ae311896d997f8fa3f17ef80916f555924a
| 2,214
|
asm
|
Assembly
|
CONFidence CTF 2016/Teaser/Bubblegum/solution/shellcode.asm
|
IMULMUL/ctf-tasks
|
9c1549c71aa5fc876f3a46751de226320dc879af
|
[
"Apache-2.0"
] | 581
|
2019-02-20T08:53:36.000Z
|
2022-03-20T13:29:29.000Z
|
CONFidence CTF 2016/Teaser/Bubblegum/solution/shellcode.asm
|
Ma3k4H3d/ctf-tasks
|
67b3564307a20a9175bcf695ce9643fb80d4652f
|
[
"Apache-2.0"
] | null | null | null |
CONFidence CTF 2016/Teaser/Bubblegum/solution/shellcode.asm
|
Ma3k4H3d/ctf-tasks
|
67b3564307a20a9175bcf695ce9643fb80d4652f
|
[
"Apache-2.0"
] | 61
|
2019-02-20T10:57:42.000Z
|
2021-07-02T06:53:09.000Z
|
[bits 32]
; Constants
CREATEFILEW_OFFSET equ 0x2511C
READFILE_OFFSET equ 0x250FC
GETSTDHANDLE_OFFSET equ 0x250CC
WRITEFILE_OFFSET equ 0x250D8
SLEEPEX_OFFSET equ 0x2500C
STD_OUTPUT_HANDLE equ 0xfffffff5
; Shellcode start
start:
; Get the instruction pointer into EBX.
call @@
@@:
pop ebx
; Get the program image base into ESI.
mov esi, ebx
and esi, 0xffff0000
mov esi, [esi]
; Call CreateFileW() to open the flag file.
push 0 ; hTemplateFile (NULL)
push 0x80 ; dwFlagsAndAttributes (FILE_ATTRIBUTE_NORMAL)
push 3 ; dwCreationDisposition (OPEN_EXISTING)
push 0 ; lpSecurityAttributes (NULL)
push 1 ; dwShareMode (FILE_SHARE_READ)
push 0x80000000 ; dwDesiredAccess (GENERIC_READ)
lea eax, [ebx + (flag_path) - @@]
push eax ; lpFileName (L"flag.txt")
call [esi + CREATEFILEW_OFFSET]
; Check for failure.
test eax, eax
je end
; Save the file handle in EDI.
mov edi, eax
; Call ReadFile() to read the flag.
push 0 ; lpOverlapped (NULL)
lea eax, [ebx + (bytes_processed) - @@]
push eax ; lpNumberOfBytesRead
push 256 ; nNumberOfBytesToRead (256)
lea eax, [ebx + (flag_buffer) - @@]
push eax ; lpBuffer
push edi ; hFile
call [esi + READFILE_OFFSET]
; Call WriteFile() to print out the flag.
push 0 ; lpOverlapped (NULL)
lea eax, [ebx + (bytes_processed) - @@]
push eax ; lpNumberOfBytesWritten
push 256 ; nNumberOfBytesToWrite
lea eax, [ebx + (flag_buffer) - @@]
push eax ; lpBuffer
push STD_OUTPUT_HANDLE ; nStdHandle
call [esi + GETSTDHANDLE_OFFSET]
push eax ; hFile
call [esi + WRITEFILE_OFFSET]
; Call SleepEx() to give the kernel time to flush buffers and send the flag out.
push 0 ; bAlertable (FALSE)
push 5000 ; dwMilliseconds
call [esi + SLEEPEX_OFFSET]
end:
; Crash the application.
xor eax, eax
jmp eax
flag_path: db 'f', 0, 'l', 0, 'a', 0, 'g', 0, '.', 0, 't', 0, 'x', 0, 't', 0, 0, 0
bytes_processed: dd 0
flag_buffer: db 0
| 27.333333
| 83
| 0.608401
|
0642d29c48d3e2ff6cf14f1587e8fc38023e2af5
| 3,889
|
asm
|
Assembly
|
lib/sprites.asm
|
cppchriscpp/waddles-the-duck
|
05127094ffea6dbb3bc822fb8c0be2a7800e5060
|
[
"MIT"
] | null | null | null |
lib/sprites.asm
|
cppchriscpp/waddles-the-duck
|
05127094ffea6dbb3bc822fb8c0be2a7800e5060
|
[
"MIT"
] | null | null | null |
lib/sprites.asm
|
cppchriscpp/waddles-the-duck
|
05127094ffea6dbb3bc822fb8c0be2a7800e5060
|
[
"MIT"
] | null | null | null |
; Definitions for all sprites used by our app, and some useful constants.
SPRITE_TYPE_COLLECTIBLE = 0
SPRITE_TYPE_JUMPABLE_ENEMY = 1
SPRITE_TYPE_INVULN_ENEMY = 2
SPRITE_TYPE_DIMENSIONER = 3
SPRITE_TYPE_FIREBALL = 4
SPRITE_TYPE_SHARK = 5
SPRITE_TYPE_PROFESSOR = 6
SPRITE_TYPE_TELEPORT = 7
SPRITE_TYPE_TELEPORT_2 = 8
SPRITE_TYPE_GRABBER = 9
SPRITE_SIZE_DEFAULT = 0
SPRITE_SIZE_TINY = 1
SPRITE_SIZE_2X1 = 2
SPRITE_SIZE_3X1 = 3
SPRITE_SIZE_4X1 = 4
SPRITE_SIZE_TINY_NORMAL_ALIGNMENT = 5
SPRITE_SIZE_TELEPORTER = 6
SPRITE_ANIMATION_NONE = 0
SPRITE_ANIMATION_NORMAL = 1
SPRITE_ANIMATION_BINARY = 2 ; first tile, second tile, first tile, second tile...
SPRITE_ANIMATION_LR = 3 ; 1 for left, 1 for right
SPRITE_ANIMATION_FAST = 4
SPRITE_ANIMATION_DYING = $a0 ; NOTE: This must not match any dimensions or things will fall apart. This is %10100000
SPRITE_TYPE_COIN = 0
SPRITE_TYPE_TURTLE = 1
SPRITE_TYPE_GATOR = 2
SPRITE_TYPE_SNAKE = 3
SPRITE_TYPE_PLATFORM = 4
PALETTE_0 = %00000000
PALETTE_1 = %00000001
PALETTE_2 = %00000010
PALETTE_3 = %00000011
COLLECTIBLE_SPRITE_ID = 0
sprite_definitions:
; Type, width, height, size, animation, first tile id, palette, speed.
.byte SPRITE_TYPE_COLLECTIBLE, 8, 8, SPRITE_SIZE_TINY, SPRITE_ANIMATION_NONE, $2, PALETTE_0, 0 ; 0. Coin
.byte SPRITE_TYPE_JUMPABLE_ENEMY, 16, 8, SPRITE_SIZE_2X1, SPRITE_ANIMATION_NORMAL, $20, PALETTE_1, 1 ; 1. Turtle
.byte SPRITE_TYPE_JUMPABLE_ENEMY, 16, 8, SPRITE_SIZE_2X1, SPRITE_ANIMATION_NORMAL, $24, PALETTE_1, 1 ; 2. Gator
.byte SPRITE_TYPE_JUMPABLE_ENEMY, 24, 8, SPRITE_SIZE_3X1, SPRITE_ANIMATION_NORMAL, $28, PALETTE_1, 2 ; 3. Snake
.byte SPRITE_TYPE_INVULN_ENEMY, 16, 14, SPRITE_SIZE_DEFAULT, SPRITE_ANIMATION_NORMAL, $40, PALETTE_1, 1 ; 4. Militarized turtle
.byte SPRITE_TYPE_PLATFORM, 32, 8, SPRITE_SIZE_4X1, SPRITE_ANIMATION_NORMAL, $03, PALETTE_1, 0 ; Falling platform.
.byte SPRITE_TYPE_FIREBALL, 10, 11, SPRITE_SIZE_DEFAULT, SPRITE_ANIMATION_FAST, $44, PALETTE_1, 64 ; fireball (extra data/speed = how high the ball goes)
.byte SPRITE_TYPE_SHARK, 16, 8, SPRITE_SIZE_2X1, SPRITE_ANIMATION_LR, $68, PALETTE_1, 0 ; Blank sprites to keep dimension stuff on one line.
; Dimension Swappers
.byte SPRITE_TYPE_DIMENSIONER, 32, 16, SPRITE_SIZE_TINY_NORMAL_ALIGNMENT, DIMENSION_PLAIN, $0, PALETTE_0, DIMENSION_BARREN
.byte SPRITE_TYPE_DIMENSIONER, 32, 16, SPRITE_SIZE_TINY_NORMAL_ALIGNMENT, DIMENSION_PLAIN, $0, PALETTE_0, DIMENSION_ICE_AGE
.byte SPRITE_TYPE_DIMENSIONER, 32, 16, SPRITE_SIZE_TINY_NORMAL_ALIGNMENT, DIMENSION_BARREN, $0, PALETTE_0, DIMENSION_ICE_AGE
.byte SPRITE_TYPE_DIMENSIONER, 32, 16, SPRITE_SIZE_TINY_NORMAL_ALIGNMENT, DIMENSION_AGGRESSIVE, $0, PALETTE_0, DIMENSION_PLAIN
.byte SPRITE_TYPE_DIMENSIONER, 32, 16, SPRITE_SIZE_TINY_NORMAL_ALIGNMENT, DIMENSION_AGGRESSIVE, $0, PALETTE_0, DIMENSION_ICE_AGE
.byte SPRITE_TYPE_DIMENSIONER, 32, 16, SPRITE_SIZE_TINY_NORMAL_ALIGNMENT, DIMENSION_BARREN, $0, PALETTE_0, DIMENSION_AGGRESSIVE
.byte SPRITE_TYPE_DIMENSIONER, 32, 16, SPRITE_SIZE_TINY_NORMAL_ALIGNMENT, DIMENSION_AGGRESSIVE, $0, PALETTE_0, DIMENSION_END_OF_DAYS
.byte SPRITE_TYPE_DIMENSIONER, 32, 16, SPRITE_SIZE_TINY_NORMAL_ALIGNMENT, DIMENSION_PLAIN, $0, PALETTE_0, DIMENSION_END_OF_DAYS
.byte SPRITE_TYPE_PROFESSOR, 32, 32, SPRITE_SIZE_DEFAULT, SPRITE_ANIMATION_NONE, $07, PALETTE_0, 0
.byte SPRITE_TYPE_PROFESSOR, 16, 32, SPRITE_SIZE_DEFAULT, SPRITE_ANIMATION_NONE, $09, PALETTE_0, 0
.byte SPRITE_TYPE_TELEPORT, 24, 8, SPRITE_SIZE_TELEPORTER, SPRITE_ANIMATION_BINARY, $48, PALETTE_2, 0
.byte SPRITE_TYPE_TELEPORT_2, 24, 8, SPRITE_SIZE_TELEPORTER, SPRITE_ANIMATION_BINARY, $48, PALETTE_2, 0 ; Intentional duplicate... based on id, first one only shows in normal dim, second only in dark.
.byte SPRITE_TYPE_GRABBER, 16, 16, SPRITE_SIZE_DEFAULT, SPRITE_ANIMATION_NORMAL, $80, PALETTE_1, 3
| 58.044776
| 201
| 0.794549
|
8075ac003c05ae19c9113cfdb424131dae944d7f
| 1,718
|
asm
|
Assembly
|
programs/oeis/098/A098021.asm
|
karttu/loda
|
9c3b0fc57b810302220c044a9d17db733c76a598
|
[
"Apache-2.0"
] | null | null | null |
programs/oeis/098/A098021.asm
|
karttu/loda
|
9c3b0fc57b810302220c044a9d17db733c76a598
|
[
"Apache-2.0"
] | null | null | null |
programs/oeis/098/A098021.asm
|
karttu/loda
|
9c3b0fc57b810302220c044a9d17db733c76a598
|
[
"Apache-2.0"
] | null | null | null |
; A098021: Positions of 0's in the zero-one sequence [nr+2r]-[nr]-[2r], where r=sqrt(2) and [ ]=floor; see A187967.
; 5,10,17,22,29,34,39,46,51,58,63,68,75,80,87,92,99,104,109,116,121,128,133,138,145,150,157,162,169,174,179,186,191,198,203,208,215,220,227,232,237,244,249,256,261,268,273,278,285,290,297,302,307,314,319,326,331,338,343,348,355,360,367,372,377,384,389,396,401,406,413,418,425,430,437,442,447,454,459,466,471,476,483,488,495,500,507,512,517,524,529,536,541,546,553,558,565,570,577,582,587,594,599,606,611,616,623,628,635,640,645,652,657,664,669,676,681,686,693,698,705,710,715,722,727,734,739,746,751,756,763,768,775,780,785,792,797,804,809,814,821,826,833,838,845,850,855,862,867,874,879,884,891,896,903,908,915,920,925,932,937,944,949,954,961,966,973,978,985,990,995,1002,1007,1014,1019,1024,1031,1036,1043,1048,1053,1060,1065,1072,1077,1084,1089,1094,1101,1106,1113,1118,1123,1130,1135,1142,1147,1154,1159,1164,1171,1176,1183,1188,1193,1200,1205,1212,1217,1222,1229,1234,1241,1246,1253,1258,1263,1270,1275,1282,1287,1292,1299,1304,1311,1316,1323,1328,1333,1340,1345,1352,1357,1362,1369,1374,1381,1386,1391,1398,1403,1410,1415,1422,1427,1432,1439,1444,1451,1456
mov $2,$0
add $2,1
mov $5,$0
lpb $2,1
mov $0,$5
sub $2,1
sub $0,$2
mov $7,$0
mov $9,2
lpb $9,1
mov $0,$7
sub $9,1
add $0,$9
sub $0,1
mov $11,$0
add $0,1
add $6,$0
pow $0,2
mul $0,2
trn $3,$6
lpb $0,1
add $3,2
sub $0,$3
trn $0,1
lpe
mov $4,$3
mov $12,$11
mul $12,2
add $4,$12
mov $8,$9
lpb $8,1
sub $8,1
mov $10,$4
lpe
lpe
lpb $7,1
mov $7,0
sub $10,$4
lpe
mov $4,$10
trn $4,4
add $4,5
add $1,$4
lpe
| 35.791667
| 1,062
| 0.643772
|
6ce06cfcd6e1abc3fd7884ffd8e628ec603caea3
| 728
|
asm
|
Assembly
|
oeis/019/A019525.asm
|
neoneye/loda-programs
|
84790877f8e6c2e821b183d2e334d612045d29c0
|
[
"Apache-2.0"
] | 11
|
2021-08-22T19:44:55.000Z
|
2022-03-20T16:47:57.000Z
|
oeis/019/A019525.asm
|
neoneye/loda-programs
|
84790877f8e6c2e821b183d2e334d612045d29c0
|
[
"Apache-2.0"
] | 9
|
2021-08-29T13:15:54.000Z
|
2022-03-09T19:52:31.000Z
|
oeis/019/A019525.asm
|
neoneye/loda-programs
|
84790877f8e6c2e821b183d2e334d612045d29c0
|
[
"Apache-2.0"
] | 3
|
2021-08-22T20:56:47.000Z
|
2021-09-29T06:26:12.000Z
|
; A019525: Poincaré series [or Poincare series] for depths of roots in a certain root system.
; Submitted by Jon Maiga
; 2,3,6,12,27,60,138,315,726,1668,3843,8844,20370,46899,108006,248700,572715,1318812,3036954,6993387,16104246,37084404,85397139,196650348,452841762,1042792803,2401318086,5529696492,12733650747,29322740220,67523692458,155491913115,358062990486,824538729828,1898727701283,4372343890764,10068526994610,23185558666899,53391139650726,122947815651420,283121234603595,651964681557852,1501328385368634,3457222430042187,7961207586148086,18332874876274644,42216497634718899,97215122263542828,223864615167699522
mov $3,1
lpb $0
sub $0,1
mul $1,3
mov $2,$3
add $3,$1
mov $1,$2
lpe
add $3,$1
mov $0,$3
add $0,1
| 45.5
| 500
| 0.815934
|
d1d09c67d5e525656e6c0bd58c77c9adbea49a08
| 111
|
asm
|
Assembly
|
patches/vwf_dialogues/vwffontpointers.asm
|
RPGHacker/SMW-Workspace
|
dbbc37a650b71800c5113b28f115aa6ffc59fa7f
|
[
"MIT"
] | 9
|
2017-11-03T17:37:24.000Z
|
2021-10-16T23:01:24.000Z
|
patches/vwf_dialogues/vwffontpointers.asm
|
RPGHacker/SMW-Workspace
|
dbbc37a650b71800c5113b28f115aa6ffc59fa7f
|
[
"MIT"
] | 17
|
2017-11-03T17:37:16.000Z
|
2021-11-02T14:42:12.000Z
|
patches/vwf_dialogues/vwffontpointers.asm
|
RPGHacker/SMW-Workspace
|
dbbc37a650b71800c5113b28f115aa6ffc59fa7f
|
[
"MIT"
] | 3
|
2018-01-14T21:49:55.000Z
|
2019-06-27T10:41:27.000Z
|
; This table contains the pointers to each font.
; Format:
; dl <fontName>,<fontWidth>
dl Font1,Font1_Width
| 18.5
| 48
| 0.72973
|
f5db4c1a1671e76c56a176b9c1e69a9c3c2524ee
| 2,683
|
asm
|
Assembly
|
TP4_PWM/main.asm
|
lmberard/Assembly
|
cbd0c332f08247aa82115fd3d4bfb9643f20a4db
|
[
"MIT"
] | null | null | null |
TP4_PWM/main.asm
|
lmberard/Assembly
|
cbd0c332f08247aa82115fd3d4bfb9643f20a4db
|
[
"MIT"
] | null | null | null |
TP4_PWM/main.asm
|
lmberard/Assembly
|
cbd0c332f08247aa82115fd3d4bfb9643f20a4db
|
[
"MIT"
] | null | null | null |
;----------------------------------------------------------------------
; Universidad de Buenos Aires
; Facultad de Ingenieria
; Laboratorio de microprocesadores
; Trabajo Practico N4 : PWM
; Alumna : Lucia Berard
; Padron : 101213
;----------------------------------------------------------------------
;----------------------------------------------------------------------
; Resumen del programa
;----------------------------------------------------------------------
;El programa aumenta y disminuye el brillo de un LED.
;Para eso se dispone de 2 pulsadores (UP, DOWN), un led y una resistencia 220ohm.
;Para la variación de brillo se usa PWM para modificar el ciclo de trabajo de una señal (sin modificar su frecuencia).
;Con esta señal se alimentará el LED, de forma que el valor medio de la señal será proporcional al brillo del LED, a
;mayor ancho de pulso, más brillo.
;----------------------------------------------------------------------
; Conexion de pines en el Arduino UNO
;----------------------------------------------------------------------
; Pulsadores en puerto 2 y 3 del arduino y alimentados a 5V
; Led en puerto 9 del arduino en serie con resistencia 220 ohm.
;----------------------------------------------------------------------
.include "m328pdef.inc"
.include "macros.inc"
;Interrupciones:
.org INT0addr
rjmp INT0action
.org INT1addr
rjmp INT1action
.cseg
.org 0x0000
jmp config
.org INT_VECTORS_SIZE
;----------------------------------------------------------------------
; Configuracion de los puertos
;----------------------------------------------------------------------
config:
; Inicializo el stack
initSP
; Declaro PortB como salida (LED)
configport DDRB,0xff
;Declaro PortD como entrada (pulsadores)
configport DDRD,0x00
; Configuro interrupciones
configINT
; Configuro timer
configtimer
;----------------------------------------------------------------------
; Main
;----------------------------------------------------------------------
;El loop principal no hace nada, todo lo hacen las interrupciones
main:
rjmp main
;-----------------------------------------------------------------------
; Rutinas de interrupción
;-----------------------------------------------------------------------
;Incrementa
INT0action:
;Verifico el maximo
cpi aux1, 0xff
breq INT0end
ldi aux2, 10
add aux1, aux2
sts OCR1AL, aux1
INT0end:
reti
;Disminuye
INT1action:
;Verifico el minimo
cpi aux1, 0x00
breq INT1end
ldi aux2, 10
sub aux1, aux2
sts OCR1AL, aux1
INT1end:
reti
| 28.242105
| 120
| 0.453224
|
9981f5e437ca8a5ef0ce9c9fd3b218371fa7e977
| 118
|
asm
|
Assembly
|
audio/sfx/battle_19.asm
|
adhi-thirumala/EvoYellow
|
6fb1b1d6a1fa84b02e2d982f270887f6c63cdf4c
|
[
"Unlicense"
] | 16
|
2018-08-28T21:47:01.000Z
|
2022-02-20T20:29:59.000Z
|
audio/sfx/battle_19.asm
|
adhi-thirumala/EvoYellow
|
6fb1b1d6a1fa84b02e2d982f270887f6c63cdf4c
|
[
"Unlicense"
] | 5
|
2019-04-03T19:53:11.000Z
|
2022-03-11T22:49:34.000Z
|
audio/sfx/battle_19.asm
|
adhi-thirumala/EvoYellow
|
6fb1b1d6a1fa84b02e2d982f270887f6c63cdf4c
|
[
"Unlicense"
] | 2
|
2019-12-09T19:46:02.000Z
|
2020-12-05T21:36:30.000Z
|
SFX_Battle_19_Ch1:
unknownnoise0x20 2, 132, 67
unknownnoise0x20 2, 196, 34
unknownnoise0x20 8, 242, 52
endchannel
| 19.666667
| 28
| 0.788136
|
1bf478dbde6028c4d58d4d9942dd507dd49acf87
| 336
|
asm
|
Assembly
|
programs/oeis/095/A095122.asm
|
neoneye/loda
|
afe9559fb53ee12e3040da54bd6aa47283e0d9ec
|
[
"Apache-2.0"
] | 22
|
2018-02-06T19:19:31.000Z
|
2022-01-17T21:53:31.000Z
|
programs/oeis/095/A095122.asm
|
neoneye/loda
|
afe9559fb53ee12e3040da54bd6aa47283e0d9ec
|
[
"Apache-2.0"
] | 41
|
2021-02-22T19:00:34.000Z
|
2021-08-28T10:47:47.000Z
|
programs/oeis/095/A095122.asm
|
neoneye/loda
|
afe9559fb53ee12e3040da54bd6aa47283e0d9ec
|
[
"Apache-2.0"
] | 5
|
2021-02-24T21:14:16.000Z
|
2021-08-09T19:48:05.000Z
|
; A095122: Fib(n)(2Fib(n)-1).
; 0,1,1,6,15,45,120,325,861,2278,5995,15753,41328,108345,283881,743590,1947351,5099221,13351528,34957341,91523685,239618886,627341331,1642418641,4299936480,11257426225,29472399505,77159865030,202007345631
seq $0,45 ; Fibonacci numbers: F(n) = F(n-1) + F(n-2) with F(0) = 0 and F(1) = 1.
mul $0,2
bin $0,2
| 48
| 204
| 0.72619
|
bed8869bb7fab3e816be7d605488687bf3c6aa07
| 1,054
|
asm
|
Assembly
|
programs/oeis/048/A048883.asm
|
jmorken/loda
|
99c09d2641e858b074f6344a352d13bc55601571
|
[
"Apache-2.0"
] | 1
|
2021-03-15T11:38:20.000Z
|
2021-03-15T11:38:20.000Z
|
programs/oeis/048/A048883.asm
|
jmorken/loda
|
99c09d2641e858b074f6344a352d13bc55601571
|
[
"Apache-2.0"
] | null | null | null |
programs/oeis/048/A048883.asm
|
jmorken/loda
|
99c09d2641e858b074f6344a352d13bc55601571
|
[
"Apache-2.0"
] | null | null | null |
; A048883: a(n) = 3^wt(n), where wt(n) = A000120(n).
; 1,3,3,9,3,9,9,27,3,9,9,27,9,27,27,81,3,9,9,27,9,27,27,81,9,27,27,81,27,81,81,243,3,9,9,27,9,27,27,81,9,27,27,81,27,81,81,243,9,27,27,81,27,81,81,243,27,81,81,243,81,243,243,729,3,9,9,27,9,27,27,81,9,27,27,81,27,81,81,243,9,27,27,81,27,81,81,243,27,81,81,243,81,243,243,729,9,27,27,81,27,81,81,243,27,81,81,243,81,243,243,729,27,81,81,243,81,243,243,729,81,243,243,729,243,729,729,2187,3,9,9,27,9,27,27,81,9,27,27,81,27,81,81,243,9,27,27,81,27,81,81,243,27,81,81,243,81,243,243,729,9,27,27,81,27,81,81,243,27,81,81,243,81,243,243,729,27,81,81,243,81,243,243,729,81,243,243,729,243,729,729,2187,9,27,27,81,27,81,81,243,27,81,81,243,81,243,243,729,27,81,81,243,81,243,243,729,81,243,243,729,243,729,729,2187,27,81,81,243,81,243,243,729,81,243,243,729,243,729,729,2187,81,243,243,729,243,729,729,2187,243,729
mov $3,1
lpb $3
mov $1,$0
mov $2,$0
sub $3,1
mov $4,1
mul $4,$0
lpb $2
lpb $1
div $4,2
sub $1,$4
lpe
mov $0,$1
sub $2,1
lpe
mov $1,3
pow $1,$0
lpe
| 47.909091
| 806
| 0.63093
|
f0bd641390d2c234654fbc56a09cb1ff0617aaf4
| 657
|
asm
|
Assembly
|
oeis/321/A321942.asm
|
neoneye/loda-programs
|
84790877f8e6c2e821b183d2e334d612045d29c0
|
[
"Apache-2.0"
] | 11
|
2021-08-22T19:44:55.000Z
|
2022-03-20T16:47:57.000Z
|
oeis/321/A321942.asm
|
neoneye/loda-programs
|
84790877f8e6c2e821b183d2e334d612045d29c0
|
[
"Apache-2.0"
] | 9
|
2021-08-29T13:15:54.000Z
|
2022-03-09T19:52:31.000Z
|
oeis/321/A321942.asm
|
neoneye/loda-programs
|
84790877f8e6c2e821b183d2e334d612045d29c0
|
[
"Apache-2.0"
] | 3
|
2021-08-22T20:56:47.000Z
|
2021-09-29T06:26:12.000Z
|
; A321942: A sequence related to the Euler-Gompertz constant.
; Submitted by Jon Maiga
; 1,2,8,44,300,2420,22460,235260,2741660,35152820,491459820,7436765660,121046445260,2108118579060,39104985755420,769549656815420,16009942093608060,351030466622487860,8089084984387984460,195421894806240545820,4938445392988428283820,130275956079881386959860,3580856252034008546068860,102380610069178419863547260,3040017242266969855883805020,93612513314108410731945700020,2985451998174215362468648838060,98483875553077740601949804679260,3356579195905724400284840345144460
mov $1,1
lpb $0
sub $0,1
add $2,1
mul $3,$2
add $3,$1
mul $1,$2
add $1,$3
lpe
mov $0,$1
| 43.8
| 468
| 0.841705
|
81883fe428a5354963e8420bdba5f9eaf328e58b
| 2,347
|
asm
|
Assembly
|
data/moves/effects_pointers.asm
|
AtmaBuster/pokeoctober
|
12652b84eb2df1a0ed2f654a0ffcfb78202e515f
|
[
"blessing"
] | 1
|
2022-02-21T03:41:27.000Z
|
2022-02-21T03:41:27.000Z
|
data/moves/effects_pointers.asm
|
AtmaBuster/pokeoctober
|
12652b84eb2df1a0ed2f654a0ffcfb78202e515f
|
[
"blessing"
] | null | null | null |
data/moves/effects_pointers.asm
|
AtmaBuster/pokeoctober
|
12652b84eb2df1a0ed2f654a0ffcfb78202e515f
|
[
"blessing"
] | null | null | null |
MoveEffectsPointers:
; entries correspond to EFFECT_* constants
dw NormalHit
dw DoSleep
dw PoisonHit
dw LeechHit
dw BurnHit
dw FreezeHit
dw ParalyzeHit
dw Selfdestruct
dw DreamEater
dw MirrorMove
dw AttackUp
dw DefenseUp
dw SpeedUp
dw SpecialAttackUp
dw SpecialDefenseUp
dw AccuracyUp
dw EvasionUp
dw NormalHit
dw AttackDown
dw DefenseDown
dw SpeedDown
dw SpecialAttackDown
dw SpecialDefenseDown
dw AccuracyDown
dw EvasionDown
dw ResetStats
dw Bide
dw Rampage
dw ForceSwitch
dw MultiHit
dw Conversion
dw FlinchHit
dw Heal
dw Toxic
dw PayDay
dw LightScreen
dw TriAttack
dw NormalHit
dw OHKOHit
dw RazorWind
dw SuperFang
dw StaticDamage
dw TrapTarget
dw NormalHit
dw MultiHit
dw NormalHit
dw Mist
dw FocusEnergy
dw RecoilHit
dw DoConfuse
dw AttackUp2
dw DefenseUp2
dw SpeedUp2
dw SpecialAttackUp2
dw SpecialDefenseUp2
dw AccuracyUp2
dw EvasionUp2
dw Transform
dw AttackDown2
dw DefenseDown2
dw SpeedDown2
dw SpecialAttackDown2
dw SpecialDefenseDown2
dw AccuracyDown2
dw EvasionDown2
dw Reflect
dw DoPoison
dw DoParalyze
dw AttackDownHit
dw DefenseDownHit
dw SpeedDownHit
dw SpecialAttackDownHit
dw SpecialDefenseDownHit
dw AccuracyDownHit
dw EvasionDownHit
dw SkyAttack
dw ConfuseHit
dw PoisonMultiHit
dw NormalHit
dw Substitute
dw HyperBeam
dw Rage
dw Mimic
dw Metronome
dw LeechSeed
dw Splash
dw Disable
dw StaticDamage
dw Psywave
dw Counter
dw Encore
dw PainSplit
dw Snore
dw Conversion2
dw LockOn
dw Sketch
dw DefrostOpponent
dw SleepTalk
dw DestinyBond
dw Reversal
dw Spite
dw FalseSwipe
dw HealBell
dw NormalHit
dw TripleKick
dw Thief
dw MeanLook
dw Nightmare
dw FlameWheel
dw Curse
dw NormalHit
dw Protect
dw Spikes
dw Foresight
dw PerishSong
dw Sandstorm
dw Endure
dw Rollout
dw Swagger
dw FuryCutter
dw Attract
dw Return
dw Present
dw Frustration
dw Safeguard
dw SacredFire
dw Magnitude
dw BatonPass
dw Pursuit
dw RapidSpin
dw NormalHit
dw NormalHit
dw MorningSun
dw Synthesis
dw Moonlight
dw HiddenPower
dw RainDance
dw SunnyDay
dw DefenseUpHit
dw AttackUpHit
dw AllUpHit
dw FakeOut
dw BellyDrum
dw PsychUp
dw MirrorCoat
dw SkullBash
dw Twister
dw Earthquake
dw FutureSight
dw Gust
dw Stomp
dw Solarbeam
dw Thunder
dw Teleport
dw BeatUp
dw Fly
dw DefenseCurl
dw CoinHurl
dw Bounce
| 14.57764
| 42
| 0.792927
|
bc4be6883f0b6bd2ea610ee777e1643606be6a29
| 207
|
asm
|
Assembly
|
libsrc/_DEVELOPMENT/string/c/sdcc_iy/strnlen.asm
|
meesokim/z88dk
|
5763c7778f19a71d936b3200374059d267066bb2
|
[
"ClArtistic"
] | null | null | null |
libsrc/_DEVELOPMENT/string/c/sdcc_iy/strnlen.asm
|
meesokim/z88dk
|
5763c7778f19a71d936b3200374059d267066bb2
|
[
"ClArtistic"
] | null | null | null |
libsrc/_DEVELOPMENT/string/c/sdcc_iy/strnlen.asm
|
meesokim/z88dk
|
5763c7778f19a71d936b3200374059d267066bb2
|
[
"ClArtistic"
] | null | null | null |
; size_t strnlen(const char *s, size_t maxlen)
SECTION code_string
PUBLIC _strnlen
EXTERN asm_strnlen
_strnlen:
pop af
pop hl
pop bc
push bc
push hl
push af
jp asm_strnlen
| 9.857143
| 46
| 0.666667
|
106f0c804dd21ec0cc937fda25149e209e5ca9c2
| 745
|
asm
|
Assembly
|
programs/oeis/014/A014024.asm
|
karttu/loda
|
9c3b0fc57b810302220c044a9d17db733c76a598
|
[
"Apache-2.0"
] | null | null | null |
programs/oeis/014/A014024.asm
|
karttu/loda
|
9c3b0fc57b810302220c044a9d17db733c76a598
|
[
"Apache-2.0"
] | null | null | null |
programs/oeis/014/A014024.asm
|
karttu/loda
|
9c3b0fc57b810302220c044a9d17db733c76a598
|
[
"Apache-2.0"
] | null | null | null |
; A014024: Inverse of 15th cyclotomic polynomial.
; 1,1,1,0,0,-1,-1,-1,0,0,0,0,0,0,0,1,1,1,0,0,-1,-1,-1,0,0,0,0,0,0,0,1,1,1,0,0,-1,-1,-1,0,0,0,0,0,0,0,1,1,1,0,0,-1,-1,-1,0,0,0,0,0,0,0,1,1,1,0,0,-1,-1,-1,0,0,0,0,0,0,0,1,1,1,0,0,-1,-1,-1,0,0,0,0,0,0,0,1,1,1,0,0,-1,-1,-1,0,0,0,0,0,0,0,1,1,1,0,0,-1,-1,-1,0,0,0,0,0,0,0,1,1,1,0,0,-1,-1,-1,0,0,0,0,0,0,0,1,1,1,0,0,-1,-1,-1,0,0,0,0,0,0,0,1,1,1,0,0,-1,-1,-1,0,0,0,0,0,0,0,1,1,1,0,0,-1,-1,-1,0,0,0,0,0,0,0,1,1,1,0,0,-1,-1,-1,0,0,0,0,0,0,0,1,1,1,0,0,-1,-1,-1,0,0,0,0,0,0,0,1,1,1,0,0,-1,-1,-1,0,0,0,0,0,0,0,1,1,1,0,0,-1,-1,-1,0,0,0,0,0,0,0,1,1,1,0,0,-1,-1,-1,0,0
mul $0,2
div $0,5
add $0,1
mod $0,6
sub $0,2
mov $2,1
lpb $0,1
div $0,10
add $0,1
sub $2,6
lpe
add $4,$2
sub $3,$4
div $0,$3
mov $1,$0
| 39.210526
| 552
| 0.488591
|
8624a6c01a5bcdd1223fd5aae2e746412d736512
| 138
|
asm
|
Assembly
|
pkgs/tools/yasm/src/modules/arch/x86/tests/loopadsz.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/arch/x86/tests/loopadsz.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/arch/x86/tests/loopadsz.asm
|
manggoguy/parsec-modified
|
d14edfb62795805c84a4280d67b50cca175b95af
|
[
"BSD-3-Clause"
] | 338
|
2020-04-18T08:03:10.000Z
|
2022-03-29T12:33:22.000Z
|
[bits 16]
foo: a32 loop foo ; 67 E2 FD
bar: loop bar, ecx ; 67 E2 FD
[bits 32]
baz: a16 loop baz ; 67 E2 FD
qux: loop qux, cx ; 67 E2 FD
| 17.25
| 29
| 0.630435
|
61bbbeebfe7c4773b87f29566ac6e87991243d85
| 2,070
|
asm
|
Assembly
|
dino/lcs/enemy/8D.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
|
dino/lcs/enemy/8D.asm
|
zengfr/arcade_game_romhacking_sourcecode_top_secret_data
|
a4a0c86c200241494b3f1834cd0aef8dc02f7683
|
[
"Apache-2.0"
] | null | null | null |
dino/lcs/enemy/8D.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
03563C bne $35634 [enemy+ 9, enemy+29, enemy+49, enemy+69, enemy+89, enemy+A9]
035644 move.b #$1, ($ad,A6) [enemy+ 9, enemy+29, enemy+49, enemy+69, enemy+89, enemy+A9]
03564A jsr $119c.l [enemy+ D, enemy+2D, enemy+4D, enemy+6D, enemy+8D, enemy+AD]
035A20 move.b D0, ($bf,A6)
035A24 move.b D0, ($ba,A6)
035A28 move.b D0, ($7a,A6)
035A2C move.b D0, ($ad,A6)
035A30 move.b D0, ($c4,A6)
035A34 move.w #$fed4, ($c0,A6)
035A3A jsr $3140c.l [enemy+ 0, enemy+20, enemy+40, enemy+60, enemy+A0]
03C3A2 tst.b ($2d,A6) [enemy+ 0, enemy+20, enemy+40, enemy+60, enemy+80, enemy+A0]
03C3AC jsr $a062.l
040316 move.w #$50, ($84,A6) [enemy+ 3, enemy+23, enemy+43, enemy+63, enemy+83, enemy+A3]
04031C move.l #$6df2a, ($40,A6) [enemy+ 4, enemy+24, enemy+44, enemy+64, enemy+84, enemy+A4]
040324 move.b #$1, ($2d,A6) [enemy+ 0, enemy+ 2, enemy+20, enemy+22, enemy+40, enemy+42, enemy+60, enemy+62, enemy+80, enemy+82, enemy+A0, enemy+A2]
04032A moveq #$1, D0 [enemy+ D, enemy+2D, enemy+4D, enemy+6D, enemy+8D, enemy+AD]
040624 move.b #$0, ($ad,A6) [enemy+ C, enemy+2C, enemy+4C, enemy+6C, enemy+8C, enemy+AC]
04062A rts
040630 beq $406be [enemy+98, enemy+B8]
040A96 rts [enemy+ D, enemy+2D, enemy+4D, enemy+6D, enemy+8D, enemy+AD]
040B24 jmp $32b68.l [enemy+ D, enemy+2D, enemy+4D, enemy+6D, enemy+8D, enemy+AD]
040BB6 jmp $32b68.l [enemy+ D, enemy+2D, enemy+4D, enemy+6D, enemy+8D, enemy+AD]
040F5E move.b #$0, ($ac,A6) [enemy+ D, enemy+2D, enemy+4D, enemy+6D, enemy+8D]
040F64 rts
05AA9E move.w #$70, ($84,A6) [enemy+ 3, enemy+23, enemy+43, enemy+63, enemy+83, enemy+A3]
05AAA4 move.l #$6da40, ($40,A6) [enemy+ 4, enemy+24, enemy+44, enemy+64, enemy+84, enemy+A4]
05AAAC bra $5aac4 [enemy+ 0, enemy+ 2, enemy+20, enemy+22, enemy+40, enemy+42, enemy+60, enemy+62, enemy+80, enemy+82, enemy+A0, enemy+A2]
05AACA moveq #$1e, D0 [enemy+ D, enemy+2D, enemy+4D, enemy+6D, enemy+8D, enemy+AD]
copyright zengfr site:http://github.com/zengfr/romhack
| 62.727273
| 150
| 0.645894
|
bc5337b31461617b552f8f581eb203f36012d2e6
| 4,082
|
asm
|
Assembly
|
Source/a20.asm
|
Dogelix/SystemsProgramming_Stage1
|
e3c0adf578a2690213232f5ac6fc8fca4f2f6b3d
|
[
"MIT"
] | null | null | null |
Source/a20.asm
|
Dogelix/SystemsProgramming_Stage1
|
e3c0adf578a2690213232f5ac6fc8fca4f2f6b3d
|
[
"MIT"
] | null | null | null |
Source/a20.asm
|
Dogelix/SystemsProgramming_Stage1
|
e3c0adf578a2690213232f5ac6fc8fca4f2f6b3d
|
[
"MIT"
] | null | null | null |
; Test_A20_Enabled. Check the status of the A20 line.
;
; Returns: 0 in ax if the A20 line is disabled (memory wraps around)
; 1 in ax if the A20 line is enabled (memory does not wrap around)
Test_A20_Enabled:
pushf
push ds
push es
push di
push si
xor ax, ax ; Set DS:SI to point to FFFF:0510 and ES:DI to point to 0000:0500.
mov es, ax
not ax
mov ds, ax
mov di, 0500h
mov si, 0510h
mov al, byte [es:di] ; Save the current contents of 0000:0500
push ax
mov al, byte [ds:si] ; Save the current contents of FFFF:0510
push ax
mov byte [es:di], 0 ; Now write 00 to 0000:0500 and FF to FFFF:0510
mov byte [ds:si], 0FFh
cmp byte [es:di], 0FFh ; If 0000:0500 contains FF, then memory addressing is wrapping round which means that
; the A20 line is NOT enabled.
pop ax
mov byte [ds:si], al ; Restore the original values of the memory locations
pop ax
mov byte [es:di], al
mov ax, 0
je Test_A20_Exit ; Return 0 if the line is NOT enabled.
mov ax, 1 ; otherwise return 1.
Test_A20_Exit:
pop si
pop di
pop es
pop ds
popf
ret
; The original method used to enable the A20 line involved using some
; hardware IO using the Keyboard Controller chip (8042 chip).
;
; Before each command is sent to the chip (via I/O port 64h, we need to ensure
; that the keyboard input buffer is empty).
;
; If you want to know more about this, see http://wiki.osdev.org/%228042%22_PS/2_Controller
Enable_A20_Using_Kbd_Controller:
call A20Wait_Input
mov al, 0ADh ; Disable keyboard
out 64h, al
call A20Wait_Input
mov al, 0D0h ; Issue command to say we are going to read from input port
out 64h ,al
call A20Wait_Output
in al, 60h ; Do the read and save the result
push eax
call A20Wait_Input
mov al,0D1h ; Issue command to say we are going to write to output port
out 64h,al
call A20Wait_Input
pop eax ; Retrieve byte that we read
or al, 2 ; Set bit to enable A20 line
out 60h,al ; and output it
call A20Wait_Input ; Enable keyboard
mov al,0AEh
out 64h,al
call A20Wait_Input
ret
A20Wait_Input: ; Wait for input buffer to be empty (wait for bit 1 to be 0). This must be empty before any attempt
in al,64h ; is made to write to output ports 60h or 64h
test al,2
jnz A20Wait_Input
ret
A20Wait_Output: ; Wait for output buffer to be full (must be set before attempting to read from input port 60h)
in al,64h
test al,1
jz A20Wait_Output
ret
; Enable the A20 line. We attempt this using various mechanisms in the following order:
;
; 1. Attempt to use the BIOS function
; 2. Attempt using the keyboard controller`
; 3. Attempt using the Fast A20 gate
; Register dx holds the status code
; 0 = A20 Fail,
; 1 = A20 Default Enabled,
; 2 = A20 BIOS Enable,
; 3 = Keyboard Controller Enable,
; 4 = Fast A20 Enable
Enable_A20:
call Test_A20_Enabled ; First see if it is already enabled. If so, there is nothing to do.
mov dx, 1 ; Indicate that A20 is already enabled
cmp ax, 1
je A20_Enabled
mov ax, 2401h ; Try the BIOS function that enables the A20 line first (note that it is possible it is not supported)
int 15h
call Test_A20_Enabled ; Now see if A20 is enabled.
mov dx, 2
cmp ax, 1
je A20_Enabled
Call Enable_A20_Using_Kbd_Controller ; See if we can enable A20 using the keyboard controller`
call Test_A20_Enabled ; Now see if A20 is enabled.
mov dx, 3
cmp ax, 1
je A20_Enabled
in al, 92h ; Finally see if we can enable A20 using the Fast A20 gate (We try this method last since
test al, 2 ; it could crash if it fails).
jnz FastA20_Exit
or al, 2
and al, 0FEh
out 92h, al
FastA20_Exit:
call Test_A20_Enabled ; And see if A20 is enabled
mov dx, 4
cmp ax, 1
je A20_Enabled
mov dx, 0
A20_Enabled:
ret
| 27.958904
| 121
| 0.657276
|
cd61083931bae7abed7f64014d2672c28e314626
| 1,692
|
asm
|
Assembly
|
libsrc/_DEVELOPMENT/stdio/z80/input_helpers/__stdio_scanf_s.asm
|
jpoikela/z88dk
|
7108b2d7e3a98a77de99b30c9a7c9199da9c75cb
|
[
"ClArtistic"
] | 640
|
2017-01-14T23:33:45.000Z
|
2022-03-30T11:28:42.000Z
|
libsrc/_DEVELOPMENT/stdio/z80/input_helpers/__stdio_scanf_s.asm
|
jpoikela/z88dk
|
7108b2d7e3a98a77de99b30c9a7c9199da9c75cb
|
[
"ClArtistic"
] | 1,600
|
2017-01-15T16:12:02.000Z
|
2022-03-31T12:11:12.000Z
|
libsrc/_DEVELOPMENT/stdio/z80/input_helpers/__stdio_scanf_s.asm
|
jpoikela/z88dk
|
7108b2d7e3a98a77de99b30c9a7c9199da9c75cb
|
[
"ClArtistic"
] | 215
|
2017-01-17T10:43:03.000Z
|
2022-03-23T17:25:02.000Z
|
SECTION code_clib
SECTION code_stdio
PUBLIC __stdio_scanf_s
PUBLIC __stdio_scanf_s_tail
EXTERN __stdio_recv_input_eat_ws_repeat, __stdio_recv_input_eatc, __stdio_scanf_sm_string
__stdio_scanf_s:
; %s converter called from vfscanf()
;
; enter : ix = FILE *
; bc = field width (0 means default)
; hl = void *p (0 means assignment suppression)
;
; exit : carry set if error
;
; uses : all except ix
; CONSUME LEADING WHITESPACE
push bc
push hl
call __stdio_recv_input_eat_ws_repeat
; stack = field width, void *buffer
; READ STREAM CHARS INTO BUFFER
pop bc ; bc = void *buffer
ld hl,__stdio_scanf_sm_string ; hl = string state machine
exx
pop bc ; bc = field width
ld a,b
or c
jr nz, width_specified ; if field width was supplied
dec bc ; otherwise consume all string chars from stream
width_specified:
call __stdio_recv_input_eatc
exx
__stdio_scanf_s_tail:
jr c, stream_error
zero_terminate:
; ZERO TERMINATE THE STRING
; if bc != 0 (assignment not suppressed), terminate the string
ld a,b
or c
ret z ; if assignment suppressed
exx
ld a,b
or c
jr z, no_chars
inc hl ; if at least one char consumed from stream, num items assigned++
no_chars:
exx
xor a
ld (bc),a ; zero terminate string
ret
stream_error:
push af ; save error type and carry set
call zero_terminate ; always zero terminate string
pop af
ret
| 18.593407
| 96
| 0.600473
|
0fdd60ab64c5a88d29466d730254d039a35385a2
| 926
|
asm
|
Assembly
|
unittests/ASM/X87_F64/FXAM_Push_F64.asm
|
Seas0/FEX
|
4f4263263b560b0a25e0d48555d5b99ca12c938f
|
[
"MIT"
] | null | null | null |
unittests/ASM/X87_F64/FXAM_Push_F64.asm
|
Seas0/FEX
|
4f4263263b560b0a25e0d48555d5b99ca12c938f
|
[
"MIT"
] | null | null | null |
unittests/ASM/X87_F64/FXAM_Push_F64.asm
|
Seas0/FEX
|
4f4263263b560b0a25e0d48555d5b99ca12c938f
|
[
"MIT"
] | null | null | null |
%ifdef CONFIG
{
"RegData": {
"RAX": "8"
},
"Env": { "FEX_X87REDUCEDPRECISION" : "1" }
}
%endif
mov rdx, 0xe0000000
; This behaviour was seen around Wine 32-bit libraries
; Anything doing a call to a double application would spin
; the x87 stack on to the stack looking for fxam to return empty
; Empty in this case is that C0 and C3 is set whiel C2 is not
fninit
; Fill the x87 stack
fldz
fldz
fldz
fldz
fldz
fldz
fldz
fldz
mov eax, 0
mov ecx, 0
.ExamineStack:
; Examine st(0)
fxam
fwait
; Get the results in to AX
fnstsw ax
and ax, 0x4500
; Check for empty
cmp ax, 0x4100
je .Done
; Now push the x87 stack value
; We know it isn't empty
fstp qword [rdx + rcx * 8]
fwait
inc ecx
jmp .ExamineStack
.Done:
; Save how many we stored
mov eax, ecx
; Now fill with "Garbage"
fld1
fld1
fld1
fld1
fld1
fld1
fld1
fld1
.Reload:
; Now reload the stack
dec ecx
fld qword [rdx + rcx * 8]
cmp ecx, 0x0
jne .Reload;
hlt
| 12.861111
| 64
| 0.703024
|
fb37385bad51255d10edaff64dca375225ccd7db
| 175
|
asm
|
Assembly
|
libsrc/target/lviv/stdio/fputc_cons_native.asm
|
ahjelm/z88dk
|
c4de367f39a76b41f6390ceeab77737e148178fa
|
[
"ClArtistic"
] | 640
|
2017-01-14T23:33:45.000Z
|
2022-03-30T11:28:42.000Z
|
libsrc/target/lviv/stdio/fputc_cons_native.asm
|
C-Chads/z88dk
|
a4141a8e51205c6414b4ae3263b633c4265778e6
|
[
"ClArtistic"
] | 1,600
|
2017-01-15T16:12:02.000Z
|
2022-03-31T12:11:12.000Z
|
libsrc/target/lviv/stdio/fputc_cons_native.asm
|
C-Chads/z88dk
|
a4141a8e51205c6414b4ae3263b633c4265778e6
|
[
"ClArtistic"
] | 215
|
2017-01-17T10:43:03.000Z
|
2022-03-23T17:25:02.000Z
|
SECTION code_clib
PUBLIC fputc_cons_native
PUBLIC _fputc_cons_native
fputc_cons_native:
_fputc_cons_native:
ld hl,2
add hl,sp
ld a,(hl)
call $bffa
ret
| 11.666667
| 26
| 0.72
|
12ea0e333618d0e40d57ddea9bfe3616b32a26e1
| 4,054
|
asm
|
Assembly
|
Transynther/x86/_processed/NONE/_xt_/i7-8650U_0xd2.log_7129_1700.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_7129_1700.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_7129_1700.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 %rbp
push %rcx
push %rdi
push %rsi
lea addresses_WT_ht+0x133fa, %rsi
lea addresses_WC_ht+0x69e2, %rdi
sub $3443, %rbp
mov $71, %rcx
rep movsw
nop
nop
xor %rbp, %rbp
pop %rsi
pop %rdi
pop %rcx
pop %rbp
ret
.global s_faulty_load
s_faulty_load:
push %r14
push %r8
push %r9
push %rax
push %rbx
push %rdi
// Faulty Load
lea addresses_normal+0x13d1a, %rdi
nop
nop
cmp %rbx, %rbx
mov (%rdi), %rax
lea oracles, %rbx
and $0xff, %rax
shlq $12, %rax
mov (%rbx,%rax,1), %rax
pop %rdi
pop %rbx
pop %rax
pop %r9
pop %r8
pop %r14
ret
/*
<gen_faulty_load>
[REF]
{'OP': 'LOAD', 'src': {'type': 'addresses_normal', 'size': 2, 'AVXalign': False, 'NT': False, 'congruent': 0, 'same': False}}
[Faulty Load]
{'OP': 'LOAD', 'src': {'type': 'addresses_normal', 'size': 8, 'AVXalign': False, 'NT': False, 'congruent': 0, 'same': True}}
<gen_prepare_buffer>
{'OP': 'REPM', 'src': {'type': 'addresses_WT_ht', 'congruent': 5, 'same': False}, 'dst': {'type': 'addresses_WC_ht', 'congruent': 0, 'same': False}}
{'34': 7129}
34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34
*/
| 68.711864
| 2,999
| 0.664282
|
9fccb0e27ca0cdd960abc1064b82039408ee156e
| 1,099
|
asm
|
Assembly
|
programs/oeis/033/A033116.asm
|
neoneye/loda
|
afe9559fb53ee12e3040da54bd6aa47283e0d9ec
|
[
"Apache-2.0"
] | 22
|
2018-02-06T19:19:31.000Z
|
2022-01-17T21:53:31.000Z
|
programs/oeis/033/A033116.asm
|
neoneye/loda
|
afe9559fb53ee12e3040da54bd6aa47283e0d9ec
|
[
"Apache-2.0"
] | 41
|
2021-02-22T19:00:34.000Z
|
2021-08-28T10:47:47.000Z
|
programs/oeis/033/A033116.asm
|
neoneye/loda
|
afe9559fb53ee12e3040da54bd6aa47283e0d9ec
|
[
"Apache-2.0"
] | 5
|
2021-02-24T21:14:16.000Z
|
2021-08-09T19:48:05.000Z
|
; A033116: Base-6 digits are, in order, the first n terms of the periodic sequence with initial period 1,0.
; 1,6,37,222,1333,7998,47989,287934,1727605,10365630,62193781,373162686,2238976117,13433856702,80603140213,483618841278,2901713047669,17410278286014,104461669716085,626770018296510,3760620109779061,22563720658674366,135382323952046197,812293943712277182,4873763662273663093,29242581973641978558,175455491841851871349,1052732951051111228094,6316397706306667368565,37898386237840004211390,227390317427040025268341,1364341904562240151610046,8186051427373440909660277,49116308564240645457961662,294697851385443872747769973,1768187108312663236486619838,10609122649875979418919719029,63654735899255876513518314174,381928415395535259081109885045,2291570492373211554486659310270,13749422954239269326919955861621,82496537725435615961519735169726,494979226352613695769118411018357,2969875358115682174614710466110142,17819252148694093047688262796660853,106915512892164558286129576779965118,641493077352987349716777460679790709
add $0,2
mov $1,6
pow $1,$0
div $1,7
sub $1,5
div $1,5
add $1,1
mov $0,$1
| 91.583333
| 915
| 0.899909
|
b4b8298ee2364866e462aa88991fb1e7153d77cd
| 649
|
asm
|
Assembly
|
oeis/022/A022087.asm
|
neoneye/loda-programs
|
84790877f8e6c2e821b183d2e334d612045d29c0
|
[
"Apache-2.0"
] | 11
|
2021-08-22T19:44:55.000Z
|
2022-03-20T16:47:57.000Z
|
oeis/022/A022087.asm
|
neoneye/loda-programs
|
84790877f8e6c2e821b183d2e334d612045d29c0
|
[
"Apache-2.0"
] | 9
|
2021-08-29T13:15:54.000Z
|
2022-03-09T19:52:31.000Z
|
oeis/022/A022087.asm
|
neoneye/loda-programs
|
84790877f8e6c2e821b183d2e334d612045d29c0
|
[
"Apache-2.0"
] | 3
|
2021-08-22T20:56:47.000Z
|
2021-09-29T06:26:12.000Z
|
; A022087: Fibonacci sequence beginning 0, 4.
; Submitted by Jon Maiga
; 0,4,4,8,12,20,32,52,84,136,220,356,576,932,1508,2440,3948,6388,10336,16724,27060,43784,70844,114628,185472,300100,485572,785672,1271244,2056916,3328160,5385076,8713236,14098312,22811548,36909860,59721408,96631268,156352676,252983944,409336620,662320564,1071657184,1733977748,2805634932,4539612680,7345247612,11884860292,19230107904,31114968196,50345076100,81460044296,131805120396,213265164692,345070285088,558335449780,903405734868,1461741184648,2365146919516,3826888104164,6192035023680
mov $3,1
lpb $0
sub $0,1
mov $2,$3
add $3,$1
mov $1,$2
lpe
mov $0,$1
mul $0,4
| 46.357143
| 490
| 0.807396
|
818993d145beaed5a4296900dfe7356b43b41367
| 211
|
asm
|
Assembly
|
Assembly/Exemplos-de-Codigos/subtrair.asm
|
carlosvilela/Testes-C-
|
b6be1d94569027d0b5d6e8aa227e279a7cb16937
|
[
"MIT"
] | null | null | null |
Assembly/Exemplos-de-Codigos/subtrair.asm
|
carlosvilela/Testes-C-
|
b6be1d94569027d0b5d6e8aa227e279a7cb16937
|
[
"MIT"
] | null | null | null |
Assembly/Exemplos-de-Codigos/subtrair.asm
|
carlosvilela/Testes-C-
|
b6be1d94569027d0b5d6e8aa227e279a7cb16937
|
[
"MIT"
] | null | null | null |
; Desenvolvido em Visual Studio 2012
.486
.model tiny
.code
main:
mov eax, 07h ; move 07h para o registrador eax
mov ebx, 05h ; move 05h para o registrador ebx
sub eax, ebx ; subtrai ebx do abx
end main
| 14.066667
| 47
| 0.71564
|
7d7b536ae5b6d479f5ee0a2b4e610fbe0391de1b
| 324
|
asm
|
Assembly
|
programs/oeis/014/A014018.asm
|
neoneye/loda
|
afe9559fb53ee12e3040da54bd6aa47283e0d9ec
|
[
"Apache-2.0"
] | 22
|
2018-02-06T19:19:31.000Z
|
2022-01-17T21:53:31.000Z
|
programs/oeis/014/A014018.asm
|
neoneye/loda
|
afe9559fb53ee12e3040da54bd6aa47283e0d9ec
|
[
"Apache-2.0"
] | 41
|
2021-02-22T19:00:34.000Z
|
2021-08-28T10:47:47.000Z
|
programs/oeis/014/A014018.asm
|
neoneye/loda
|
afe9559fb53ee12e3040da54bd6aa47283e0d9ec
|
[
"Apache-2.0"
] | 5
|
2021-02-24T21:14:16.000Z
|
2021-08-09T19:48:05.000Z
|
; A014018: Inverse of 9th cyclotomic polynomial.
; 1,0,0,-1,0,0,0,0,0,1,0,0,-1,0,0,0,0,0,1,0,0,-1,0,0,0,0,0,1,0,0,-1,0,0,0,0,0,1,0,0,-1,0,0,0,0,0,1,0,0,-1,0,0,0,0,0,1,0,0,-1,0,0,0,0,0,1,0,0,-1,0,0,0,0,0,1,0,0,-1,0,0,0,0,0,1,0,0,-1,0,0,0,0,0,1,0,0,-1,0,0,0,0,0,1
lpb $0
mod $0,9
lpe
pow $1,$0
cmp $0,3
sub $1,$0
mov $0,$1
| 29.454545
| 212
| 0.527778
|
8b6e08879b05ad7e90a9529913bf55dd3d0b07ac
| 16,677
|
asm
|
Assembly
|
T1.asm
|
matprado/Calculadora_Assembly
|
c3c69b7b2e53ebf7389eea9ba7df07003d21502b
|
[
"MIT"
] | null | null | null |
T1.asm
|
matprado/Calculadora_Assembly
|
c3c69b7b2e53ebf7389eea9ba7df07003d21502b
|
[
"MIT"
] | null | null | null |
T1.asm
|
matprado/Calculadora_Assembly
|
c3c69b7b2e53ebf7389eea9ba7df07003d21502b
|
[
"MIT"
] | null | null | null |
#Trabalho 1 de Organização e Arquitetura de Computadores.
#O objetivo desse trabalho é fazer um programa em Assembly MIPS que simule uma calculadora com
#determinadas operações.
#Convenção: argumentos para os procedimentos sempre ficam entre os registradores $a0, ..., $a3(ou $f.. para valores flutuantes)
# e retorno sempre em $v0 e/ou $v1;
#ATENÇÃO: APENAS DIVISÃO E IMC TRATAM NÚMEROS FLOAT
#data:
.data
.align 0
ponteiro: .word
str_menu: .asciiz "Escolha uma das seguintes opções:\n"
str_op0: .asciiz "Opção 0 -> Soma;\n"
str_op1: .asciiz "Opção 1 -> Subtração;\n"
str_op2: .asciiz "Opção 2 -> Multiplicação;\n"
str_op3: .asciiz "Opção 3 -> Divisão;\n"
str_op4: .asciiz "Opção 4 -> Potência;\n"
str_op5: .asciiz "Opção 5 -> Raiz quadrada;\n"
str_op6: .asciiz "Opção 6 -> Tabuada de um número;\n"
str_op7: .asciiz "Opção 7 -> Cálculo de IMC;\n"
str_op8: .asciiz "Opção 8 -> Fatorial;\n"
str_op9: .asciiz "Opção 9 -> Sequência de Fibonacci;\n"
str_op10: .asciiz "Opção 10 -> Sair do programa;\n"
str_dig1_32b: .asciiz "Digite um número(até 32 bits):"
str_dig2_32b: .asciiz "Digite outro número(até 32 bits):"
str_dig1_16b: .asciiz "Digite um número(até 16 bits):"
str_dig2_16b: .asciiz "Digite outro número(até 16 bits):"
str_peso: .asciiz "Digite o peso(em kg)(até 16 bits):"
str_altura: .asciiz "Digite a altura:(em m)(até 16 bits):"
str_res: .asciiz "O resultado é: "
str_fim: .asciiz "Fim de execução.\n"
str_erro: .asciiz "Erro -> Opção Inválida!\n"
str_erro_16b: .asciiz "Erro -> Número digitado excede os 16 bits.\n"
str_erro_div_zero: .asciiz "Erro -> Divisão por zero!\n"
str_erro_raiz_neg: .asciiz "Erro -> Raiz negativa!\n"
str_barra_n: .asciiz "\n"
str_virgula: .asciiz ", "
.align 2
float_16b: .float 65535.0
float_zero: .float 0.0
#text:
.text
.globl main
main:
#seta os valores de comparação:
li $t0, 1
li $t1, 2
li $t2, 3
li $t3, 4
li $t4, 5
li $t5, 6
li $t6, 7
li $t7, 8
li $t8, 9
li $t9, 10
#variável auxiliar para o loop do switch:
li $v1, 1
j switch
erro:
li $v0, 4
la $a0, str_erro
syscall
switch:
#imprimir menu e opções:
li $v0, 4
la $a0, str_menu
syscall
la $a0, str_op0
syscall
la $a0, str_op1
syscall
la $a0, str_op2
syscall
la $a0, str_op3
syscall
la $a0, str_op4
syscall
la $a0, str_op5
syscall
la $a0, str_op6
syscall
la $a0, str_op7
syscall
la $a0, str_op8
syscall
la $a0, str_op9
syscall
la $a0, str_op10
syscall
#ler opção digitada:
li $v0, 5
syscall
#seleciona o label para onde realizará o brench
blt $v0, $zero, erro
beq $v0, $zero, op0
beq $v0, $t0, op1
beq $v0, $t1, op2
beq $v0, $t2, op3
beq $v0, $t3, op4
beq $v0, $t4, op5
beq $v0, $t5, op6
beq $v0, $t6, op7
beq $v0, $t7, op8
beq $v0, $t8, op9
beq $v0, $t9, op10
bgt $v0, $t9, erro
#Soma
op0:
#imprime str_dig1_32b
li $v0, 4
la $a0, str_dig1_32b
syscall
#lê o primeiro número
li $v0, 5
syscall
#argumento do procedimento soma
move $a1, $v0
#imprime str_dig2_32b
li $v0, 4
la $a0, str_dig2_32b
syscall
#lê o segundo número
li $v0, 5
syscall
move $a0, $a1 #primeiro argumento no a0
#argumento do procedimento soma
move $a1, $v0
jal soma
#argumento para imprimir posteriormente
move $a1, $v0
#imprime str_res
li $v0, 4
la $a0, str_res
syscall
#imprime o retorno
move $a0, $a1
li $v0, 1
syscall
#imprime str_barra_n
li $v0, 4
la $a0, str_barra_n
syscall
j switch
#Subtração
op1:
#imprime str_dig1_32b
li $v0, 4
la $a0, str_dig1_32b
syscall
#lê o primeiro número
li $v0, 5
syscall
#argumento do procedimento subtrair
move $a1, $v0
#imprime str_dig2_32b
li $v0, 4
la $a0, str_dig2_32b
syscall
#lê o segundo número
li $v0, 5
syscall
move $a0, $a1 #primeiro argumento no a0
#argumento do procedimento subtrair
move $a1, $v0
jal subtracao
#argumento para imprimir posteriormente
move $a1, $v0
#imprime str_res
li $v0, 4
la $a0, str_res
syscall
#imprime o retorno
move $a0, $a1
li $v0, 1
syscall
#imprime str_barra_n
li $v0, 4
la $a0, str_barra_n
syscall
j switch
#Multiplicação
op2:
#imprime str_dig1_16b
li $v0, 4
la $a0, str_dig1_16b
syscall
#lê o primeiro número
li $v0, 5
syscall
#argumento do procedimento multiplicar
move $a1, $v0
#confere se o número digitado cabe em 16 bits
li $v0, 65535 #v0 = (2^16 - 1)
bgt $a1, $v0, erro_16b
#imprime str_dig2_16b
li $v0, 4
la $a0, str_dig2_16b
syscall
#lê o segundo número
li $v0, 5
syscall
move $a0, $a1 #primeiro argumento no a0
#argumento do procedimento multiplicar
move $a1, $v0
#confere se o número digitado cabe em 16 bits
li $v0, 65535 #v0 = (2^16 - 1)
bgt $a1, $v0, erro_16b
jal multiplicacao
#argumento para imprimir posteriormente
move $a1, $v0
#imprime str_res
li $v0, 4
la $a0, str_res
syscall
#imprime o retorno
move $a0, $a1
li $v0, 1
syscall
#imprime str_barra_n
li $v0, 4
la $a0, str_barra_n
syscall
j switch
#Divisão
op3:
#imprime str_dig1_16b
li $v0, 4
la $a0, str_dig1_16b
syscall
#lê o primeiro número
li $v0, 6
syscall
#argumento do procedimento dividir
mov.s $f1, $f0
#confere se o número digitado cabe em 16 bits
l.s $f2, float_16b #f2 = (2^16 - 1)
c.lt.s $f2, $f1
bc1t erro_16b
#imprime str_dig2_16b
li $v0, 4
la $a0, str_dig2_16b
syscall
#lê o segundo número
li $v0, 6
syscall
#primeiro argumento está no $f1, segundo no $f0
#confere se o número digitado cabe em 16 bits
c.lt.s $f2, $f0
bc1t erro_16b
#$v1 == 0 (inicializa sem erro)
li $v1, 0
#swap entre $f0 e $f1
mov.s $f2, $f0
mov.s $f0, $f1
mov.s $f1, $f2
jal divisao
#confere se o $v1 é 1(erro de divisão por 0)
bne $v1, $zero, erro_div_zero
#imprime str_res
li $v0, 4
la $a0, str_res
syscall
#imprime o retorno
mov.s $f12, $f2
li $v0, 2
syscall
#imprime str_barra_n
li $v0, 4
la $a0, str_barra_n
syscall
j switch
erro_div_zero:
li $v0, 4
la $a0, str_erro_div_zero
syscall
j switch
#Potenciação
op4:
#imprime str_dig1_32b
li $v0, 4
la $a0, str_dig1_32b
syscall
#lê o primeiro número
li $v0, 5
syscall
#argumento do procedimento potencia
move $a1, $v0
#imprime str_dig2_32b
li $v0, 4
la $a0, str_dig2_32b
syscall
#lê o segundo número
li $v0, 5
syscall
move $a0, $a1 #primeiro argumento no a0
#argumento do procedimento potencia
move $a1, $v0
jal potencia
#argumento para imprimir posteriormente
move $a1, $v0
#imprime str_res
li $v0, 4
la $a0, str_res
syscall
#imprime o retorno
move $a0, $a1
li $v0, 1
syscall
#imprime str_barra_n
li $v0, 4
la $a0, str_barra_n
syscall
j switch
#Raiz quadrada
op5:
#imprime str_dig1_32b
li $v0, 4
la $a0, str_dig1_32b
syscall
#lê o número
li $v0, 5
syscall
#argumento do procedimento raiz
move $a0, $v0
jal raiz_quadrada
#confere se o $v1 é 1(erro de raiz de numero negativo)
blt $v1, $zero, erro_raiz_neg
#argumento para imprimir posteriormente
move $a1, $v0
#imprime str_res
li $v0, 4
la $a0, str_res
syscall
#imprime o retorno
move $a0, $a1
li $v0, 1
syscall
#imprime str_barra_n
li $v0, 4
la $a0, str_barra_n
syscall
j switch
erro_raiz_neg:
li $v0, 4
la $a0, str_erro_raiz_neg
syscall
j switch
#Tabuada
op6:
#imprime str_dig1_32b
li $v0, 4
la $a0, str_dig1_32b
syscall
#lê o número
li $v0, 5
syscall
#argumento do procedimento tabuada
move $a0, $v0
jal tabuada
j switch
#Cálculo de IMC
op7:
#imprime str_altura
li $v0, 4
la $a0, str_altura
syscall
#lê o primeiro número
li $v0, 6
syscall
#argumento do procedimento imc
mov.s $f1, $f0
#confere se o número digitado cabe em 16 bits
l.s $f2, float_16b #f2 = (2^16 - 1)
c.lt.s $f2, $f1
bc1t erro_16b
#imprime str_peso
li $v0, 4
la $a0, str_peso
syscall
#lê o segundo número
li $v0, 6
syscall
#confere se o número digitado cabe em 16 bits
c.lt.s $f2, $f0
bc1t erro_16b
li $v1, 0 #seta erro para zero
jal IMC
bne $v1, $zero, erro_div_zero
#imprime str_res
li $v0, 4
la $a0, str_res
syscall
#imprime o retorno
mov.s $f12, $f2
li $v0, 2
syscall
#imprime str_barra_n
li $v0, 4
la $a0, str_barra_n
syscall
j switch
#Fatorial
op8:
#imprime str_dig1_32b
li $v0, 4
la $a0, str_dig1_32b
syscall
#lê o número
li $v0, 5
syscall
#argumento do procedimento fatorial
move $a0, $v0
jal fatorial
#argumento para imprimir posteriormente
move $a1, $v0
#imprime str_res
li $v0, 4
la $a0, str_res
syscall
#imprime o retorno
move $a0, $a1
li $v0, 1
syscall
#imprime str_barra_n
li $v0, 4
la $a0, str_barra_n
syscall
j switch
#Fibonacci
op9:
#imprime str_dig1_32b
li $v0, 4
la $a0, str_dig1_32b
syscall
#lê o primeiro número
li $v0, 5
syscall
#argumento do procedimento fibonacci
move $a1, $v0
#imprime str_dig2_32b
li $v0, 4
la $a0, str_dig2_32b
syscall
#lê o segundo número
li $v0, 5
syscall
move $a0, $a1 #primeiro argumento no a0
#argumento do procedimento fibonacci
move $a1, $v0
jal fibonacci_em_intervalo
j switch
op10:
#imprime mensagem de encerramento
li $v0, 4
la $a0, str_fim
syscall
#sai do programa
li $v0, 10
syscall
erro_16b:
#imprime mensagem de erro
li $v0, 4
la $a0, str_erro_16b
syscall
j switch
#Procedimentos:
#procedimento soma:
#parâmetros: $a0, $a1
#retorno: $v0
soma:
addi $sp, $sp, -12
sw $a0, 0($sp)
sw $a1, 4($sp)
sw $ra, 8($sp)
add $v0, $a0, $a1 #soma os dois numeros dados e salva em v0
lw $a0, 0($sp)
lw $a1, 4($sp)
lw $ra, 8($sp)
addi $sp, $sp, 12
jr $ra
#procedimento subtracao:
#parâmetros: $a0, $a1
#retorno: $v0
subtracao:
addi $sp, $sp, -12
sw $a0, 0($sp)
sw $a1, 4($sp)
sw $ra, 8($sp)
sub $v0, $a0, $a1 #subtrai os dois numeros dados e salva em v0
lw $a0, 0($sp)
lw $a1, 4($sp)
lw $ra, 8($sp)
addi $sp, $sp, 12
jr $ra
#procedimento multiplicacao:
#parâmetros: $a0, $a1
#retorno: $v0
multiplicacao:
addi $sp, $sp, -12
sw $a0, 0($sp)
sw $a1, 4($sp)
sw $ra, 8($sp)
mul $v0, $a0, $a1 #multiplica os dois numeros dados e salva em v0
lw $a0, 0($sp)
lw $a1, 4($sp)
lw $ra, 8($sp)
addi $sp, $sp, 12
jr $ra
#procedimento divisao:
#parâmetros: $f0, $f1
#retorno: $f2(resultado), $v1(erro)
divisao:
addi $sp, $sp, -12
s.s $f0, 0($sp)
s.s $f1, 4($sp)
sw $ra, 8($sp)
#trata o caso de divisão por zero
l.s $f2 , float_zero
c.eq.s $f1, $f2
bc1t erro_divisao
div.s $f2, $f0, $f1 #divide os dois numeros dados e salva o resultado em $f2
j retorna_divisao
erro_divisao:
li $v1, 1
retorna_divisao:
l.s $f0, 0($sp)
l.s $f1, 4($sp)
lw $ra, 8($sp)
addi $sp, $sp, 12
jr $ra
#procedimento IMC:
#parâmetros: $f0, $f1 (peso e altura, respectivamente)
#retorno: $f2(IMC), $v1(erro)
IMC:
addi $sp, $sp, -12
s.s $f0, 0($sp)
s.s $f1, 4($sp)
sw $ra, 8($sp)
#trata o caso de erro da altura == 0, para não dividir por 0
l.s $f2, float_zero
c.eq.s $f1, $f2
bc1t erro_IMC
mul.s $f2, $f1, $f1 #f2 = altura * altura
div.s $f2, $f0, $f2 #f2 = peso / v0
j retorna_IMC
erro_IMC:
li $v1, 1
retorna_IMC:
l.s $f0, 0($sp)
l.s $f1, 4($sp)
lw $ra, 8($sp)
addi $sp, $sp, 12
jr $ra
#procedimento fatorial recursivo: recebe como parametro o inteiro em $a0 e retorna o fatorial dele em $v0
fatorial:
#armazena $a0 e $ra na pilha
addi $sp, $sp, -8
sw $a0, 0($sp)
sw $ra, 4($sp)
ble $a0, $zero, retorna1 #a0 <= 0, retorna 1
subi $a0, $a0, 1 #a0--
jal fatorial #chamada recursiva
addi $a0, $a0, 1 #evita que multiplique v0 por 0
mul $v0, $v0, $a0
j retorna_fat
retorna1:
li $v0, 1
retorna_fat:
#recupera da pilha
lw $a0, 0($sp)
lw $ra, 4($sp)
addi $sp, $sp, 8
#return
jr $ra
#Procedimento potencia recebe argumentos $a0 e $a1 e retorna em $v0 o resultado;
#a0 base
#a1 potencia desejada
potencia:
addi $sp, $sp, -12
sw $a0, 0($sp)
sw $a1, 4($sp)
sw $ra, 8($sp)
li $v0, 1
powLoop:
beqz $a1, exit_powLoop
mul $v0, $v0, $a0
addi $a1, $a1, -1
j powLoop
exit_powLoop:
lw $a0, 0($sp)
lw $a1, 4($sp)
lw $ra, 8($sp)
addi $sp, $sp, 12
jr $ra
#Procedimento raiz_quadrada recebe como argumento o $a0 e retorna sua raiz em $v0.
#a0 base da raiz
raiz_quadrada:
#a0 base da raiz
#EMPILHANDO $t0, $ra, $a0
addi $sp, $sp, -28 # $sp = $sp - 28
sw $t0, 0($sp)
sw $t1, 4($sp)
sw $t2, 8($sp)
sw $t3, 12($sp)
sw $t4, 16($sp)
sw $ra, 20($sp)
sw $a0, 24($sp)
#COPIANDO O VALOR 2 PARA $t0
addi $t0, $zero, 2 # $t0 = zero + 2
addi $t1, $a0, 0 # $t1 = $a0 + 0
div $t1, $t0 # $t1 / $t0
mflo $t1 # send to $t1 quocient of div
addi $t0, $zero, 0 # $t0 = $zero + 0
addi $t2, $a0, 0 # $t2 = $a0 + 0
addi $t4, $zero, 2 # $t4 = $zero + 2
rootLoop:
bge $t0, $t1, exit_rootLoop # if $t0 >= $t1 then exit_rootLoop
div $a0, $t2 # $a0 / $t2
mflo $t3 # send to $t3 quocient of div
add $t2, $t3, $t2 # $t0 = $t3 + $t2
div $t2, $t4 # $t2 / $t4(2)
mflo $t2 # send to $ quocient of div
addi $t0, $t0, 1 # $t0 = $t0 + 1
j rootLoop # jump to rootLoop
exit_rootLoop:
add $v0, $t2, $zero # $v0 = $t2 + $zero
lw $t0, 0($sp)
lw $t1, 4($sp)
lw $t2, 8($sp)
lw $t3, 12($sp)
lw $t4, 16($sp)
lw $ra, 20($sp)
lw $a0, 24($sp)
addi $sp, $sp, 28 # $sp = $sp + 28
jr $ra # jump to $ra
#Procedimento tabuada recebe como argumento o $a0.
#a0 é o número que se deseja mostrar a tabuada.
tabuada:
#a0 como numero base para a tabuada
addi $sp, $sp, -16 # $sp = $sp - 20
sw $ra, 0($sp)
sw $t0, 4($sp)
sw $t1, 8($sp)
sw $t2, 12($sp)
sw $a0, 16($sp)
addi $t0, $zero, 1 # $t0 = $zero + 1
addi $t1, $zero, 10 # $t1 = $zero + 10
add $t2, $zero, $a0 # $t2 = $zero + $a0
tabuadaLoop:
bgt $t0, $t1, tabuada_exitLoop # if $t0 > $t1 then tabuada_exitLoop
add $a0, $zero, $t2 # $a0 = $zero + $t2
mult $a0, $t0 # $a0 * $t0 = Hi and Lo registers
mflo $a0 # copy Lo to $a0
li $v0, 1 # $v0 = 1
syscall #printing integer
#imprime str_barra_n
li $v0, 4
la $a0, str_barra_n
syscall
addi $t0, $t0, 1 # $t0 = $zero + 1
j tabuadaLoop #jump to tabuadaLoop
tabuada_exitLoop:
lw $ra, 0($sp)
lw $t0, 4($sp)
lw $t1, 8($sp)
lw $t2, 12($sp)
lw $a0, 16($sp)
addi $sp, $sp, 16 # $sp = $sp + 20
jr $ra # jump to $ra
#Procedimento fibonacci_em_intervalo recebe como argumentos $a0 e $a1 com o intervalo de fibonacci desejado
# e chama o procedimento fibonacci para cada valor do intervalo imprimindo seu resultado;
fibonacci_em_intervalo:
addi $sp, $sp, -12
sw $a0, 0($sp)
sw $a1, 4($sp)
sw $ra, 8($sp)
subi $a0, $a0, 1
#loop para calcular o fibonacci de cada número do intervalo e imprimir este número
loop_fibo: beq $a0, $a1, fim_loop_fibo
jal fibonacci #retorno em $v0
#imprime retorno
move $s0, $a0
move $s1, $v0
li $v0, 1
move $a0, $s1
syscall
li $v0, 4
la $a0, str_virgula
syscall
move $a0, $s0
addi $a0, $a0, 1
j loop_fibo
fim_loop_fibo:
li $v0, 4
la $a0, str_barra_n
syscall
lw $a0, 0($sp)
lw $a1, 4($sp)
lw $ra, 8($sp)
addi $sp, $sp, 12
jr $ra
#Procedimento fibonacci recebe como parâmetro $a0 para o número da sequência de fibonacci
fibonacci:
addi $sp, $sp, -16
sw $s0, 0($sp)
sw $s1, 4($sp)
sw $a0, 8($sp)
sw $ra, 12($sp)
li $s2, 0
slti $s2, $a0, 2 #se a0 menor que 2, s2 é 1
beq $s2, $zero, retorna_fib #se s2 for 0, vai pro retorna_fib
addi $v0, $zero, 1 #últimas 2 chamadas da recursão
j retorna
retorna_fib:
addi $s0, $a0, 0
addi $a0, $a0, -1
jal fibonacci
addi $s1, $v0, 0
addi $a0, $s0, -2
jal fibonacci
add $v0, $s1, $v0
#v0 tem o resultado
retorna:
lw $s0, 0($sp)
lw $s1, 4($sp)
lw $a0, 8($sp)
lw $ra, 12($sp)
addi $sp, $sp, 16
jr $ra
| 17.970905
| 127
| 0.599868
|
eef420e0bcff6e14d68f695f0efa9401f56c3549
| 592
|
asm
|
Assembly
|
oeis/275/A275574.asm
|
neoneye/loda-programs
|
84790877f8e6c2e821b183d2e334d612045d29c0
|
[
"Apache-2.0"
] | 11
|
2021-08-22T19:44:55.000Z
|
2022-03-20T16:47:57.000Z
|
oeis/275/A275574.asm
|
neoneye/loda-programs
|
84790877f8e6c2e821b183d2e334d612045d29c0
|
[
"Apache-2.0"
] | 9
|
2021-08-29T13:15:54.000Z
|
2022-03-09T19:52:31.000Z
|
oeis/275/A275574.asm
|
neoneye/loda-programs
|
84790877f8e6c2e821b183d2e334d612045d29c0
|
[
"Apache-2.0"
] | 3
|
2021-08-22T20:56:47.000Z
|
2021-09-29T06:26:12.000Z
|
; A275574: ((-1)^n - 1 + 2*(n^floor((n + 1)/2)))/4
; 0,1,4,8,62,108,1200,2048,29524,50000,885780,1492992,31374258,52706752,1281445312,2147483648,59293938248,99179645184,3065533128900,5120000000000,175138750271110,292159150705664,10957312216010160,18260173718028288,745058059692382812,1240576436601868288,54709494565756179604,91029559914971267072,4314594373799092220474,7174453500000000000000,363711560873592631914240,604462909807314587353088,32636755824132221485912336,54214017802982966177103872,3105952449627779006958007812
mov $1,$0
add $0,2
div $0,2
add $1,1
pow $1,$0
div $1,2
mov $0,$1
| 53.818182
| 473
| 0.83277
|
b8d0cab47be985328d051c64818c0d73d1a48ad6
| 6,216
|
asm
|
Assembly
|
CS2ASM/Amd64/EntryPoint.asm
|
nifanfa/CS2ASM
|
d4c3fcc039aeba38d4c6e387da17e603cabc0c7e
|
[
"MIT"
] | 23
|
2021-11-30T07:17:11.000Z
|
2022-02-07T05:42:46.000Z
|
CS2ASM/Amd64/EntryPoint.asm
|
nifanfa/IL2ASM
|
d4c3fcc039aeba38d4c6e387da17e603cabc0c7e
|
[
"MIT"
] | 5
|
2021-11-30T16:00:49.000Z
|
2022-02-10T03:42:19.000Z
|
CS2ASM/Amd64/EntryPoint.asm
|
nifanfa/CS2ASM
|
d4c3fcc039aeba38d4c6e387da17e603cabc0c7e
|
[
"MIT"
] | 2
|
2021-12-10T19:51:21.000Z
|
2022-01-06T23:01:26.000Z
|
[BITS 32]
[global _start]
[ORG 0x100000]
;If using '-f bin' we need to specify the
;origin point for our code with ORG directive
;multiboot loaders load us at physical
;address 0x100000
MULTIBOOT_AOUT_KLUDGE equ 1 << 16
;FLAGS[16] indicates to GRUB we are not
;an ELF executable and the fields
;header address, load address, load end address;
;bss end address and entry address will be available
;in Multiboot header
MULTIBOOT_ALIGN equ 1<<0
; align loaded modules on page boundaries
MULTIBOOT_MEMINFO equ 1<<1
; provide memory map
MULTIBOOT_VBE_MODE equ 1<<2
MULTIBOOT_HEADER_MAGIC equ 0x1BADB002
;magic number GRUB searches for in the first 8k
;of the kernel file GRUB is told to load
MULTIBOOT_HEADER_FLAGS equ MULTIBOOT_AOUT_KLUDGE|MULTIBOOT_ALIGN|MULTIBOOT_MEMINFO;|MULTIBOOT_VBE_MODE
CHECKSUM equ -(MULTIBOOT_HEADER_MAGIC + MULTIBOOT_HEADER_FLAGS)
KERNEL_STACK equ 0x00200000
;Stack starts at the 2mb address & grows down
_start:
xor eax, eax ;Clear eax and ebx in the event
xor ebx, ebx ;we are not loaded by GRUB.
jmp multiboot_entry ;Jump over the multiboot header
align 4 ;Multiboot header must be 32
;bits aligned to avoid error 13
multiboot_header:
dd MULTIBOOT_HEADER_MAGIC ;magic number
dd MULTIBOOT_HEADER_FLAGS ;flags
dd CHECKSUM ;checksum
dd multiboot_header ;header address
dd _start ;load address of code entry point
;in our case _start
dd 00 ;load end address : not necessary
dd 00 ;bss end address : not necessary
dd multiboot_entry ;entry address GRUB will start at
; Uncomment this and "|MULTIBOOT_VBE_MODE" in MULTIBOOT_HEADER_FLAGS to enable VBE
;dd 00
;dd 1024
;dd 768
;dd 32
multiboot_entry:
mov esp, KERNEL_STACK ;Setup the stack
push 0 ;Reset EFLAGS
popf
push eax ;2nd argument is magic number
push 0 ;Reserve
push ebx ;1st argument multiboot info pointer
push 0 ;Reserve
call EnterLongMode ;Call _Main
die:
cli
endloop:
hlt
jmp endloop
%macro pushaq 0
push r15
push r14
push r13
push r12
push r11
push r10
push r9
push r8
push rdi
push rsi
push rbx
push rdx
push rcx
push rax
%endmacro
%macro popaq 0
pop rax
pop rcx
pop rdx
pop rbx
pop rsi
pop rdi
pop r8
pop r9
pop r10
pop r11
pop r12
pop r13
pop r14
pop r15
%endmacro
ALIGN 4
IDT:
.Length dw 0
.Base dd 0
; Function to switch directly to long mode from real mode.
; Identity maps the first 1GiB.
; Uses Intel syntax.
; es:edi Should point to a valid page-aligned 16KiB buffer, for the PML4, PDPT, PD and a PT.
; ss:esp Should point to memory that can be used as a small (1 uint32_t) stack
EnterLongMode:
mov edi, p4_table
; Zero out the 16KiB buffer.
; Since we are doing a rep stosd, count should be bytes/4.
push di ; REP STOSD alters DI.
; map first P4 entry to P3 table
mov eax, p3_table
or eax, 0b11 ; present + writable
mov [p4_table], eax
; map first P3 entry to P2 table
mov eax, p2_table
or eax, 0b11 ; present + writable
mov [p3_table], eax
; map each P2 entry to a huge 2MiB page
mov ecx, 0 ; counter variable
.Map_P2_Table:
; map ecx-th P2 entry to a huge page that starts at address 2MiB*ecx
mov eax, 0x200000 ; 2MiB
mul ecx ; start address of ecx-th page
or eax, 0b10000011 ; present + writable + huge
mov [p2_table + ecx * 8], eax ; map ecx-th entry
inc ecx ; increase counter
cmp ecx, 512 ; if counter == 512, the whole P2 table is mapped
jne .Map_P2_Table ; else map the next entry
;1024MB of memory should be mapped now
pop di ; Restore DI.
; Disable IRQs
mov al, 0xFF ; Out 0xFF to 0xA1 and 0x21 to disable all IRQs.
out 0xA1, al
out 0x21, al
cli
nop
nop
lidt [IDT] ; Load a zero length IDT so that any NMI causes a triple fault.
; Enter long mode.
mov eax, 10100000b ; Set the PAE and PGE bit.
mov cr4, eax
mov edx, edi ; Point CR3 at the PML4.
mov cr3, edx
mov ecx, 0xC0000080 ; Read from the EFER MSR.
rdmsr
or eax, 0x00000100 ; Set the LME bit.
wrmsr
mov ebx, cr0 ; Activate long mode -
or ebx,0x80000001 ; - by enabling paging and protection simultaneously.
mov cr0, ebx
lgdt [GDT.Pointer] ; Load GDT.Pointer defined below.
sti
jmp 0x0008:_Main ; Load CS with 64 bit segment and flush the instruction cache
; Global Descriptor Table
GDT:
.Null:
dq 0x0000000000000000 ; Null Descriptor - should be present.
.Code:
dq 0x00209A0000000000 ; 64-bit code descriptor (exec/read).
dq 0x0000920000000000 ; 64-bit data descriptor (read/write).
ALIGN 4
dw 0 ; Padding to make the "address of the GDT" field aligned on a 4-byte boundary
.Pointer:
dw $ - GDT - 1 ; 16-bit Size (Limit) of GDT.
dd GDT ; 32-bit Base Address of GDT. (CPU will zero extend to 64-bit)
ALIGN 4096
p4_table:
resb 4096
p3_table:
resb 4096
p2_table:
resb 4096
[BITS 64]
_Main:
mov ax, 0x0010
mov ds, ax
mov es, ax
mov fs, ax
mov gs, ax
mov ss, ax
pop rsi ;MagicNumber
pop rdi ;Multiboot Info Ptr
mov rbp,KERNEL_STACK-1024
mov rsp,rbp
%include "Kernel.asm"
| 27.626667
| 115
| 0.581403
|
040716039e004bbcafea4acff133ad36101b29d8
| 630
|
asm
|
Assembly
|
programs/oeis/093/A093050.asm
|
karttu/loda
|
9c3b0fc57b810302220c044a9d17db733c76a598
|
[
"Apache-2.0"
] | null | null | null |
programs/oeis/093/A093050.asm
|
karttu/loda
|
9c3b0fc57b810302220c044a9d17db733c76a598
|
[
"Apache-2.0"
] | null | null | null |
programs/oeis/093/A093050.asm
|
karttu/loda
|
9c3b0fc57b810302220c044a9d17db733c76a598
|
[
"Apache-2.0"
] | null | null | null |
; A093050: Exponent of 2 in (3^n-3)*2^(n-1).
; 0,0,3,2,6,4,7,6,11,8,11,10,14,12,15,14,20,16,19,18,22,20,23,22,27,24,27,26,30,28,31,30,37,32,35,34,38,36,39,38,43,40,43,42,46,44,47,46,52,48,51,50,54,52,55,54,59,56,59,58,62,60,63,62,70,64,67,66,70
mov $5,$0
mov $7,2
lpb $7,1
clr $0,5
mov $0,$5
sub $7,1
add $0,$7
sub $0,1
add $1,$0
sub $3,$1
mul $3,$1
sub $3,6
div $3,2
lpb $0,1
sub $0,1
sub $3,$1
div $1,2
lpe
add $3,3
mov $4,1
add $4,$3
mov $3,2
sub $3,$4
mov $1,$3
mov $8,$7
lpb $8,1
mov $6,$1
sub $8,1
lpe
lpe
lpb $5,1
mov $5,0
sub $6,$1
lpe
mov $1,$6
sub $1,1
| 15.75
| 199
| 0.519048
|
86baa61d878ac5c214d6c46430cdcb63eb4bd500
| 7,493
|
asm
|
Assembly
|
Transynther/x86/_processed/NONE/_xt_/i9-9900K_12_0xca.log_21829_890.asm
|
ljhsiun2/medusa
|
67d769b8a2fb42c538f10287abaf0e6dbb463f0c
|
[
"MIT"
] | 9
|
2020-08-13T19:41:58.000Z
|
2022-03-30T12:22:51.000Z
|
Transynther/x86/_processed/NONE/_xt_/i9-9900K_12_0xca.log_21829_890.asm
|
ljhsiun2/medusa
|
67d769b8a2fb42c538f10287abaf0e6dbb463f0c
|
[
"MIT"
] | 1
|
2021-04-29T06:29:35.000Z
|
2021-05-13T21:02:30.000Z
|
Transynther/x86/_processed/NONE/_xt_/i9-9900K_12_0xca.log_21829_890.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 %rax
push %rbp
push %rbx
push %rcx
push %rdi
push %rdx
push %rsi
lea addresses_D_ht+0xe408, %rbx
nop
inc %rax
movl $0x61626364, (%rbx)
nop
nop
cmp $65136, %rbp
lea addresses_normal_ht+0x13918, %rsi
lea addresses_D_ht+0x1263c, %rdi
nop
nop
add %rdx, %rdx
mov $81, %rcx
rep movsq
nop
nop
nop
nop
nop
xor $29348, %rdi
lea addresses_normal_ht+0x7704, %rdx
nop
nop
cmp $14645, %rcx
vmovups (%rdx), %ymm7
vextracti128 $0, %ymm7, %xmm7
vpextrq $0, %xmm7, %rsi
nop
nop
dec %rcx
lea addresses_normal_ht+0x3098, %rsi
lea addresses_WC_ht+0xc098, %rdi
clflush (%rsi)
nop
nop
nop
add $39079, %rdx
mov $67, %rcx
rep movsw
nop
nop
cmp $22135, %rax
lea addresses_WC_ht+0x1d398, %rsi
lea addresses_WT_ht+0x11498, %rdi
nop
nop
inc %rax
mov $69, %rcx
rep movsb
cmp %r10, %r10
lea addresses_WT_ht+0x2898, %rsi
lea addresses_normal_ht+0x6681, %rdi
nop
sub %rbx, %rbx
mov $112, %rcx
rep movsq
nop
nop
nop
nop
sub %rax, %rax
lea addresses_WC_ht+0x3118, %rsi
lea addresses_normal_ht+0x7098, %rdi
nop
sub $13168, %r10
mov $17, %rcx
rep movsb
nop
nop
nop
nop
add $64774, %rax
lea addresses_A_ht+0xf258, %rsi
lea addresses_D_ht+0x1c118, %rdi
nop
nop
cmp $47276, %r10
mov $60, %rcx
rep movsw
nop
nop
nop
cmp %rdx, %rdx
lea addresses_D_ht+0x10718, %rsi
lea addresses_UC_ht+0x17698, %rdi
nop
cmp %rbx, %rbx
mov $112, %rcx
rep movsl
nop
nop
nop
nop
nop
sub $14083, %rdi
lea addresses_A_ht+0xa5f8, %rsi
lea addresses_WC_ht+0x115b8, %rdi
nop
nop
nop
nop
nop
add $58992, %rbp
mov $66, %rcx
rep movsl
nop
nop
nop
nop
nop
sub $61449, %rdi
lea addresses_D_ht+0x8498, %rbx
nop
nop
nop
nop
xor $8162, %rbp
movl $0x61626364, (%rbx)
dec %rdx
lea addresses_UC_ht+0xea8, %r10
nop
dec %rbp
mov (%r10), %ebx
nop
nop
nop
dec %rcx
pop %rsi
pop %rdx
pop %rdi
pop %rcx
pop %rbx
pop %rbp
pop %rax
pop %r10
ret
.global s_faulty_load
s_faulty_load:
push %r13
push %r14
push %r15
push %r8
push %rbp
push %rbx
// Store
lea addresses_UC+0x4b40, %r14
nop
nop
cmp $49981, %r8
mov $0x5152535455565758, %r15
movq %r15, (%r14)
nop
sub %r15, %r15
// Faulty Load
lea addresses_PSE+0x19898, %r15
nop
nop
nop
nop
xor $29645, %rbx
vmovups (%r15), %ymm0
vextracti128 $1, %ymm0, %xmm0
vpextrq $0, %xmm0, %rbp
lea oracles, %r15
and $0xff, %rbp
shlq $12, %rbp
mov (%r15,%rbp,1), %rbp
pop %rbx
pop %rbp
pop %r8
pop %r15
pop %r14
pop %r13
ret
/*
<gen_faulty_load>
[REF]
{'OP': 'LOAD', 'src': {'size': 2, 'NT': False, 'type': 'addresses_PSE', 'same': False, 'AVXalign': False, 'congruent': 0}}
{'OP': 'STOR', 'dst': {'size': 8, 'NT': False, 'type': 'addresses_UC', 'same': False, 'AVXalign': True, 'congruent': 3}}
[Faulty Load]
{'OP': 'LOAD', 'src': {'size': 32, 'NT': False, 'type': 'addresses_PSE', 'same': True, 'AVXalign': False, 'congruent': 0}}
<gen_prepare_buffer>
{'OP': 'STOR', 'dst': {'size': 4, 'NT': False, 'type': 'addresses_D_ht', 'same': True, 'AVXalign': False, 'congruent': 4}}
{'OP': 'REPM', 'src': {'same': False, 'type': 'addresses_normal_ht', 'congruent': 4}, 'dst': {'same': True, 'type': 'addresses_D_ht', 'congruent': 1}}
{'OP': 'LOAD', 'src': {'size': 32, 'NT': False, 'type': 'addresses_normal_ht', 'same': False, 'AVXalign': False, 'congruent': 1}}
{'OP': 'REPM', 'src': {'same': False, 'type': 'addresses_normal_ht', 'congruent': 11}, 'dst': {'same': False, 'type': 'addresses_WC_ht', 'congruent': 11}}
{'OP': 'REPM', 'src': {'same': False, 'type': 'addresses_WC_ht', 'congruent': 8}, 'dst': {'same': False, 'type': 'addresses_WT_ht', 'congruent': 10}}
{'OP': 'REPM', 'src': {'same': False, 'type': 'addresses_WT_ht', 'congruent': 11}, 'dst': {'same': False, 'type': 'addresses_normal_ht', 'congruent': 0}}
{'OP': 'REPM', 'src': {'same': False, 'type': 'addresses_WC_ht', 'congruent': 7}, 'dst': {'same': False, 'type': 'addresses_normal_ht', 'congruent': 8}}
{'OP': 'REPM', 'src': {'same': False, 'type': 'addresses_A_ht', 'congruent': 6}, 'dst': {'same': False, 'type': 'addresses_D_ht', 'congruent': 7}}
{'OP': 'REPM', 'src': {'same': False, 'type': 'addresses_D_ht', 'congruent': 7}, 'dst': {'same': False, 'type': 'addresses_UC_ht', 'congruent': 6}}
{'OP': 'REPM', 'src': {'same': False, 'type': 'addresses_A_ht', 'congruent': 5}, 'dst': {'same': False, 'type': 'addresses_WC_ht', 'congruent': 2}}
{'OP': 'STOR', 'dst': {'size': 4, 'NT': True, 'type': 'addresses_D_ht', 'same': False, 'AVXalign': True, 'congruent': 10}}
{'OP': 'LOAD', 'src': {'size': 4, 'NT': False, 'type': 'addresses_UC_ht', 'same': False, 'AVXalign': False, '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
*/
| 35.34434
| 2,999
| 0.662618
|
5531b3ce0c0e93b39d2245a3a1bf79339f02e5fd
| 2,131
|
asm
|
Assembly
|
data/trainers/dvs.asm
|
AtmaBuster/pokeoctober
|
12652b84eb2df1a0ed2f654a0ffcfb78202e515f
|
[
"blessing"
] | 1
|
2022-02-21T03:41:27.000Z
|
2022-02-21T03:41:27.000Z
|
data/trainers/dvs.asm
|
AtmaBuster/pokeoctober
|
12652b84eb2df1a0ed2f654a0ffcfb78202e515f
|
[
"blessing"
] | null | null | null |
data/trainers/dvs.asm
|
AtmaBuster/pokeoctober
|
12652b84eb2df1a0ed2f654a0ffcfb78202e515f
|
[
"blessing"
] | null | null | null |
TrainerClassDVs:
; entries correspond to trainer classes (see constants/trainer_constants.asm)
; atk,def,spd,spc
dn 9, 10, 7, 7 ; FALKNER
dn 8, 8, 8, 8 ; BUGSY
dn 9, 8, 8, 8 ; WHITNEY
dn 9, 8, 8, 8 ; MORTY
dn 9, 8, 8, 8 ; PRYCE
dn 9, 8, 8, 8 ; JASMINE
dn 9, 8, 8, 8 ; CHUCK
dn 7, 12, 13, 13 ; CLAIR
dn 13, 13, 13, 13 ; RIVAL1
dn 9, 8, 8, 8 ; POKEMON_PROF
dn 13, 12, 13, 13 ; WILL
dn 13, 12, 13, 13 ; CAL
dn 13, 12, 13, 13 ; BRUNO
dn 7, 15, 13, 15 ; KAREN
dn 13, 12, 13, 13 ; KOGA
dn 13, 12, 13, 13 ; CHAMPION
dn 9, 8, 8, 8 ; BROCK
dn 7, 8, 8, 8 ; MISTY
dn 9, 8, 8, 8 ; LT_SURGE
dn 9, 8, 8, 8 ; SCIENTIST
dn 7, 8, 8, 8 ; ERIKA
dn 9, 8, 8, 8 ; YOUNGSTER
dn 9, 8, 8, 8 ; SCHOOLBOY
dn 9, 8, 8, 8 ; BIRD_KEEPER
dn 5, 8, 8, 8 ; LASS
dn 9, 8, 8, 8 ; JANINE
dn 13, 8, 12, 8 ; COOLTRAINERM
dn 7, 12, 12, 8 ; COOLTRAINERF
dn 6, 9, 12, 8 ; BEAUTY
dn 9, 8, 8, 8 ; POKEMANIAC
dn 13, 8, 10, 8 ; GRUNTM
dn 9, 8, 8, 8 ; GENTLEMAN
dn 9, 8, 8, 8 ; SKIER
dn 6, 8, 8, 8 ; TEACHER
dn 7, 13, 8, 7 ; SABRINA
dn 9, 8, 8, 8 ; BUG_CATCHER
dn 9, 8, 8, 8 ; FISHER
dn 9, 8, 8, 8 ; SWIMMERM
dn 7, 8, 8, 8 ; SWIMMERF
dn 9, 8, 8, 8 ; SAILOR
dn 9, 8, 8, 8 ; SUPER_NERD
dn 9, 8, 8, 8 ; RIVAL2
dn 9, 8, 8, 8 ; GUITARIST
dn 10, 8, 8, 8 ; HIKER
dn 9, 8, 8, 8 ; BIKER
dn 9, 8, 8, 8 ; BLAINE
dn 9, 8, 8, 8 ; BURGLAR
dn 9, 8, 8, 8 ; FIREBREATHER
dn 9, 8, 8, 8 ; JUGGLER
dn 9, 8, 8, 8 ; BLACKBELT_T
dn 13, 8, 10, 8 ; EXECUTIVEM
dn 9, 8, 8, 8 ; PSYCHIC_T
dn 6, 10, 10, 8 ; PICNICKER
dn 9, 8, 8, 8 ; CAMPER
dn 7, 14, 10, 8 ; EXECUTIVEF
dn 9, 8, 8, 8 ; SAGE
dn 7, 8, 8, 8 ; MEDIUM
dn 9, 8, 8, 8 ; BOARDER
dn 9, 8, 8, 8 ; POKEFANM
dn 6, 8, 8, 10 ; KIMONO_GIRL
dn 6, 8, 10, 8 ; TWINS
dn 6, 13, 8, 8 ; POKEFANF
dn 15, 13, 13, 14 ; RED
dn 9, 13, 13, 13 ; BLUE
dn 9, 8, 8, 8 ; OFFICER
dn 7, 14, 10, 8 ; GRUNTF
dn 9, 8, 8, 8 ; MYSTICALMAN
dn 9, 8, 8, 8 ; INSTRUCTOR
dn 9, 8, 8, 9 ; PROFESSOR
| 29.191781
| 77
| 0.498358
|
984ad38cca68e7d222e28910dbe9ef33d72ec092
| 1,566
|
asm
|
Assembly
|
libsrc/_DEVELOPMENT/target/zx/driver/terminal/zx_01_output_char_64/zx_01_output_char_64_oterm_msg_printc.asm
|
meesokim/z88dk
|
5763c7778f19a71d936b3200374059d267066bb2
|
[
"ClArtistic"
] | null | null | null |
libsrc/_DEVELOPMENT/target/zx/driver/terminal/zx_01_output_char_64/zx_01_output_char_64_oterm_msg_printc.asm
|
meesokim/z88dk
|
5763c7778f19a71d936b3200374059d267066bb2
|
[
"ClArtistic"
] | null | null | null |
libsrc/_DEVELOPMENT/target/zx/driver/terminal/zx_01_output_char_64/zx_01_output_char_64_oterm_msg_printc.asm
|
meesokim/z88dk
|
5763c7778f19a71d936b3200374059d267066bb2
|
[
"ClArtistic"
] | null | null | null |
SECTION code_fcntl
PUBLIC zx_01_output_char_64_oterm_msg_printc
EXTERN asm_zx_cyx2saddr, asm_zx_saddr2aaddr
zx_01_output_char_64_oterm_msg_printc:
; enter : c = ascii code >= 32
; b = parameter (currently unused)
; l = absolute x coordinate
; h = absolute y coordinate
; can use: af, bc, de, hl
; djm 3/3/2000
; adapted aralbrec 12/2014
srl l ; column /= 2
ld b,$0f
jr c, __screen_address
ld b,$f0
__screen_address:
call asm_zx_cyx2saddr
ex de,hl ; de = screen address
ld l,c
ld h,0
add hl,hl
add hl,hl
add hl,hl ; hl = 8 * ascii code
ld a,b ; a = character set mask
ld c,(ix+21)
ld b,(ix+22) ; bc = font address
add hl,bc ; hl = & character definition
; print character pixels
; a = character set mask
; de = screen address
; hl = & character definition
ld b,8
ld c,a
ex de,hl
__print_loop:
ld a,c
cpl ; screen mask
and (hl)
ld (hl),a
ld a,(de)
and c
or (hl)
ld (hl),a
inc de
inc h
djnz __print_loop
dec h
; put colour
call asm_zx_saddr2aaddr ; hl = attribute address
ld c,(ix+23) ; c = foreground colour
ld b,(ix+24) ; b = foreground mask
ld a,b
cpl
and c
ld c,a
ld a,b
and (hl)
or c
ld (hl),a
ret
| 16.659574
| 60
| 0.498084
|
835ad25e339a684a679f70a6e8d00d0de8f4003a
| 6,962
|
asm
|
Assembly
|
Transynther/x86/_processed/NONE/_xt_/i9-9900K_12_0xa0_notsx.log_21829_1395.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_1395.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_1395.asm
|
ljhsiun2/medusa
|
67d769b8a2fb42c538f10287abaf0e6dbb463f0c
|
[
"MIT"
] | 3
|
2020-07-14T17:07:07.000Z
|
2022-03-21T01:12:22.000Z
|
.global s_prepare_buffers
s_prepare_buffers:
push %r10
push %r11
push %r12
push %r14
push %r15
push %rcx
push %rdi
push %rsi
lea addresses_A_ht+0x13420, %r10
nop
nop
nop
sub %r15, %r15
mov (%r10), %di
and %r14, %r14
lea addresses_D_ht+0x6568, %rsi
lea addresses_WT_ht+0x19564, %rdi
nop
nop
nop
nop
sub $12273, %r15
mov $73, %rcx
rep movsb
and %r15, %r15
lea addresses_normal_ht+0x11904, %r15
nop
nop
nop
nop
xor %rdi, %rdi
mov (%r15), %ecx
nop
nop
nop
nop
and %rdi, %rdi
lea addresses_UC_ht+0x16420, %r14
nop
and $18519, %r11
vmovups (%r14), %ymm6
vextracti128 $0, %ymm6, %xmm6
vpextrq $0, %xmm6, %rdi
nop
nop
nop
nop
nop
sub %rsi, %rsi
lea addresses_WC_ht+0xa20, %rsi
lea addresses_UC_ht+0x19c20, %rdi
nop
nop
nop
dec %r12
mov $4, %rcx
rep movsl
nop
nop
cmp %rcx, %rcx
lea addresses_normal_ht+0x9b4c, %rsi
lea addresses_normal_ht+0x14420, %rdi
nop
nop
nop
nop
sub %r14, %r14
mov $31, %rcx
rep movsq
nop
nop
nop
nop
cmp $10700, %r12
lea addresses_WC_ht+0x11020, %rsi
lea addresses_WT_ht+0x12e20, %rdi
nop
cmp %r11, %r11
mov $59, %rcx
rep movsl
nop
nop
xor %r15, %r15
lea addresses_D_ht+0x17648, %rsi
lea addresses_D_ht+0x19708, %rdi
nop
nop
sub %r14, %r14
mov $91, %rcx
rep movsw
nop
nop
nop
nop
add $2620, %r11
lea addresses_WC_ht+0x6980, %r10
clflush (%r10)
nop
nop
nop
nop
cmp $40504, %rsi
and $0xffffffffffffffc0, %r10
vmovaps (%r10), %ymm5
vextracti128 $1, %ymm5, %xmm5
vpextrq $1, %xmm5, %rcx
nop
and $14261, %r10
lea addresses_normal_ht+0x1c020, %r10
nop
sub $16856, %rdi
movb (%r10), %r12b
nop
nop
nop
nop
nop
xor $20288, %rcx
pop %rsi
pop %rdi
pop %rcx
pop %r15
pop %r14
pop %r12
pop %r11
pop %r10
ret
.global s_faulty_load
s_faulty_load:
push %r11
push %r13
push %r9
push %rax
push %rcx
push %rdi
// Store
lea addresses_UC+0x1420, %r11
sub $23576, %r13
mov $0x5152535455565758, %rdi
movq %rdi, (%r11)
nop
nop
nop
and $36840, %rdi
// Faulty Load
lea addresses_UC+0x1420, %r13
nop
nop
nop
nop
nop
xor $16089, %rcx
vmovups (%r13), %ymm0
vextracti128 $1, %ymm0, %xmm0
vpextrq $0, %xmm0, %r11
lea oracles, %r13
and $0xff, %r11
shlq $12, %r11
mov (%r13,%r11,1), %r11
pop %rdi
pop %rcx
pop %rax
pop %r9
pop %r13
pop %r11
ret
/*
<gen_faulty_load>
[REF]
{'src': {'type': 'addresses_UC', 'AVXalign': False, 'size': 8, 'NT': False, 'same': False, 'congruent': 0}, 'OP': 'LOAD'}
{'OP': 'STOR', 'dst': {'type': 'addresses_UC', 'AVXalign': True, 'size': 8, 'NT': False, 'same': True, 'congruent': 0}}
[Faulty Load]
{'src': {'type': 'addresses_UC', 'AVXalign': False, 'size': 32, 'NT': False, 'same': True, 'congruent': 0}, 'OP': 'LOAD'}
<gen_prepare_buffer>
{'src': {'type': 'addresses_A_ht', 'AVXalign': False, 'size': 2, 'NT': True, 'same': False, 'congruent': 11}, 'OP': 'LOAD'}
{'src': {'type': 'addresses_D_ht', 'congruent': 1, 'same': False}, 'OP': 'REPM', 'dst': {'type': 'addresses_WT_ht', 'congruent': 1, 'same': False}}
{'src': {'type': 'addresses_normal_ht', 'AVXalign': True, 'size': 4, 'NT': False, 'same': False, 'congruent': 0}, 'OP': 'LOAD'}
{'src': {'type': 'addresses_UC_ht', 'AVXalign': False, 'size': 32, 'NT': False, 'same': False, 'congruent': 9}, 'OP': 'LOAD'}
{'src': {'type': 'addresses_WC_ht', 'congruent': 9, 'same': True}, 'OP': 'REPM', 'dst': {'type': 'addresses_UC_ht', 'congruent': 11, 'same': False}}
{'src': {'type': 'addresses_normal_ht', 'congruent': 2, 'same': True}, 'OP': 'REPM', 'dst': {'type': 'addresses_normal_ht', 'congruent': 11, 'same': False}}
{'src': {'type': 'addresses_WC_ht', 'congruent': 10, 'same': False}, 'OP': 'REPM', 'dst': {'type': 'addresses_WT_ht', 'congruent': 9, 'same': False}}
{'src': {'type': 'addresses_D_ht', 'congruent': 3, 'same': True}, 'OP': 'REPM', 'dst': {'type': 'addresses_D_ht', 'congruent': 3, 'same': False}}
{'src': {'type': 'addresses_WC_ht', 'AVXalign': True, 'size': 32, 'NT': False, 'same': False, 'congruent': 4}, 'OP': 'LOAD'}
{'src': {'type': 'addresses_normal_ht', 'AVXalign': False, 'size': 1, 'NT': False, 'same': False, 'congruent': 10}, 'OP': 'LOAD'}
{'37': 21829}
37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37 37
*/
| 35.886598
| 2,999
| 0.66073
|
40848e4de246b515db9b5c140e7d1e90b5c4734e
| 173
|
asm
|
Assembly
|
data/pokemon/dex_entries/deoxys.asm
|
AtmaBuster/pokeplat-gen2
|
fa83b2e75575949b8f72cb2c48f7a1042e97f70f
|
[
"blessing"
] | 6
|
2021-06-19T06:41:19.000Z
|
2022-02-15T17:12:33.000Z
|
data/pokemon/dex_entries/deoxys.asm
|
AtmaBuster/pokeplat-gen2-old
|
01e42c55db5408d72d89133dc84a46c699d849ad
|
[
"blessing"
] | null | null | null |
data/pokemon/dex_entries/deoxys.asm
|
AtmaBuster/pokeplat-gen2-old
|
01e42c55db5408d72d89133dc84a46c699d849ad
|
[
"blessing"
] | 3
|
2021-01-15T18:45:40.000Z
|
2021-10-16T03:35:27.000Z
|
db "DNA@" ; species name
db "DNA from a space"
next "virus mutated and"
next "became a #MON."
page "It appeares when"
next "auroras are seen"
next "in the sky.@"
| 17.3
| 25
| 0.647399
|
076a243cc90fd70a2e826d92707c02ef37b7f93e
| 898
|
asm
|
Assembly
|
programs/oeis/080/A080239.asm
|
karttu/loda
|
9c3b0fc57b810302220c044a9d17db733c76a598
|
[
"Apache-2.0"
] | 1
|
2021-03-15T11:38:20.000Z
|
2021-03-15T11:38:20.000Z
|
programs/oeis/080/A080239.asm
|
karttu/loda
|
9c3b0fc57b810302220c044a9d17db733c76a598
|
[
"Apache-2.0"
] | null | null | null |
programs/oeis/080/A080239.asm
|
karttu/loda
|
9c3b0fc57b810302220c044a9d17db733c76a598
|
[
"Apache-2.0"
] | null | null | null |
; A080239: Antidiagonal sums of triangle A035317.
; 1,1,2,3,6,9,15,24,40,64,104,168,273,441,714,1155,1870,3025,4895,7920,12816,20736,33552,54288,87841,142129,229970,372099,602070,974169,1576239,2550408,4126648,6677056,10803704,17480760,28284465,45765225,74049690,119814915,193864606,313679521,507544127,821223648,1328767776,2149991424,3478759200,5628750624,9107509825,14736260449,23843770274,38580030723,62423800998,101003831721,163427632719,264431464440,427859097160,692290561600,1120149658760,1812440220360,2932589879121,4745030099481,7677619978602,12422650078083,20100270056686,32522920134769,52623190191455,85146110326224,137769300517680,222915410843904,360684711361584,583600122205488,944284833567073,1527884955772561,2472169789339634,4000054745112195,6472224534451830
add $0,1
cal $0,293411 ; a(n) = a(n-1) + a(n-3) + a(n-4), where a(0) = 1, a(1) = 2, a(2) = 3, a(3) = 4.
mov $1,$0
div $1,2
| 112.25
| 723
| 0.821826
|
cd1d7c5ca91eb1247ed5e1088eb8fb84e40ec01e
| 749
|
asm
|
Assembly
|
libsrc/_DEVELOPMENT/arch/zx/bifrost_h/c/sdcc/BIFROSTH_drawBackTilesH_callee.asm
|
teknoplop/z88dk
|
bb03fbfd6b2ab0f397a1358559089f9cd3706485
|
[
"ClArtistic"
] | null | null | null |
libsrc/_DEVELOPMENT/arch/zx/bifrost_h/c/sdcc/BIFROSTH_drawBackTilesH_callee.asm
|
teknoplop/z88dk
|
bb03fbfd6b2ab0f397a1358559089f9cd3706485
|
[
"ClArtistic"
] | null | null | null |
libsrc/_DEVELOPMENT/arch/zx/bifrost_h/c/sdcc/BIFROSTH_drawBackTilesH_callee.asm
|
teknoplop/z88dk
|
bb03fbfd6b2ab0f397a1358559089f9cd3706485
|
[
"ClArtistic"
] | 1
|
2019-12-03T23:57:48.000Z
|
2019-12-03T23:57:48.000Z
|
; ----------------------------------------------------------------
; Z88DK INTERFACE LIBRARY FOR THE BIFROST* ENGINE - RELEASE 1.2/L
;
; See "bifrost_h.h" for further details
; ----------------------------------------------------------------
; void BIFROSTH_drawBackTilesH(unsigned int lin,unsigned int col,unsigned int attr)
; callee
SECTION code_clib
SECTION code_bifrost_h
PUBLIC _BIFROSTH_drawBackTilesH_callee
EXTERN asm_BIFROSTH_drawBackTilesH
_BIFROSTH_drawBackTilesH_callee:
pop hl ; RET address
pop bc ; C=lin
pop de ; E=col
ld d,c ; D=lin
pop bc ; C=attrib
push hl
jp asm_BIFROSTH_drawBackTilesH ; execute 'draw_back_tiles'
| 27.740741
| 83
| 0.539386
|
dc4bdf056f6334b74e37e52d58a857863ba81437
| 43,090
|
asm
|
Assembly
|
base/mvdm/wow16/drivers/comm/ibmcom1.asm
|
npocmaka/Windows-Server-2003
|
5c6fe3db626b63a384230a1aa6b92ac416b0765f
|
[
"Unlicense"
] | 17
|
2020-11-13T13:42:52.000Z
|
2021-09-16T09:13:13.000Z
|
base/mvdm/wow16/drivers/comm/ibmcom1.asm
|
sancho1952007/Windows-Server-2003
|
5c6fe3db626b63a384230a1aa6b92ac416b0765f
|
[
"Unlicense"
] | 2
|
2020-10-19T08:02:06.000Z
|
2020-10-19T08:23:18.000Z
|
base/mvdm/wow16/drivers/comm/ibmcom1.asm
|
sancho1952007/Windows-Server-2003
|
5c6fe3db626b63a384230a1aa6b92ac416b0765f
|
[
"Unlicense"
] | 14
|
2020-11-14T09:43:20.000Z
|
2021-08-28T08:59:57.000Z
|
page
;---------------------------Module-Header-------------------------------;
; Module Name: IBMCOM1.ASM
;
; Copyright (c) Microsoft Corporation 1985-1990. All Rights Reserved.
;
;----------------------------Private-Routine----------------------------;
;
; DoLPT - Do Function To LPT port
;
; The given function (output or reset) is performed to the
; passed LPT port.
;
; Before a character is sent, a check is made to see if the device
; will be able to accept the character. If it can, then the character
; will be sent. If not, then an error will be returned. If the
; printer is selected and busy and no error, then the code returned
; will be CE_TXFULL and the handshake bits will be set in HSFlag
; to simulate that a handshake was received.
;
; If the BIOS ROM code is examined, you will note that they wait for
; the busy character from the last charcater to be cleared before
; they strobe in the current character. This can take a long time
; on the standard EPSON class printer (1 mSec to greater than
; 300 mSec if the last character actually caused printing).
;
; Because of this, several status read retrys will be made before
; declaring that the device is actually busy. If only one status
; read is performed, the spooler will yeild, take a while to get
; back here, and things will be really slow. What difference does
; it really make if we or the BIOS does the delay, at least we can
; break out of it at some point when it seems hopeless.
;
; The OKIHACK: Okidata reports a 50 ns. 2.2 volt pulse on the paper
; out signal on the trailing edge of the Busy signal. If we see this
; glitch then we report paper out. So we try to get the status twice...
; if it changes between the two tries we keep getting the status.
;
;
; Entry:
; AH = cid
; AL = character to output
; CH = Function request. 0 = Output, 1 = Initialize, 2 = Status
; DS:SI -> DEB for the port
; Returns:
; AX = 0 if no errors occured
; Error Returns:
; AX = error code
; Registers Preserved:
; SI,DI
; Registers Destroyed:
; AX,BX,CX,DX,ES,FLAGS
; History:
; sudeepb 10-Jan-1993 changed the costly cli/sti with non-trapping
; FCLI/FSTI macros
;-----------------------------------------------------------------------;
;------------------------------Pseudo-Code------------------------------;
; {
; }
;-----------------------------------------------------------------------;
assumes ds,Data
assumes es,nothing
include vint.inc
externFP OutputDebugString
dbmsg macro msg
.286
push cs
push offset $ + 3 + 5 + 2 ; push + far call + short jump
call OutputDebugString
jmp short @F
db msg,13,10,0
@@:
endm
iodelay macro
jmp $+2
jmp $+2
endm
public DoLPT ;Publics for debugging
public LPT_Reset
public LPT_Outchar
public LPT_Strobe
public LPT_GetStatus
public DoLPT40
; status bit defines
L_BITS equ 0F8h ; the status bits we want
L_BITS_INVERT equ 048h ; must invert to match BIOS
L_DEVBUSY equ 080h ; device busy bit
L_TIMEOUT equ 001h ; timeout bit
; control bit defines
L_NORMAL equ 00Ch ; normal state: selected, no reset
L_RESET equ 008h ; reset state
L_STROBE equ 00Dh ; tell printer we have char
DoLPT proc near
mov dx,Port[si] ;Get port address
; DX = port address
; CH = operation: 0 = write, 1 = init, 2 = status
; AL = character
or ch, ch
jz LPT_OutChar
cmp ch, 1
jz LPT_Reset
jmp LPT_GetStatus
ret
LPT_Reset:
inc dx
inc dx
mov al, L_RESET
iodelay
out dx, al
push dx
cCall GetSystemMsecCount
mov bx, ax
LPT_ResetDelay:
push bx
cCall GetSystemMsecCount
pop bx
sub ax, bx
cmp ax, 300 ; 1/3 sec as good as any
jbe LPT_ResetDelay
pop dx
mov al, L_NORMAL
iodelay
iodelay
out dx, al
dec dx
dec dx
jmp LPT_GetStatus
LPT_OutChar:
push ax ; save character to be written
; first check to see if printer is ready for us
push di
push dx
call GetSystemMSecCount
mov di, ax
pop dx
LPT_WaitReady:
inc dx ; point to status port
iodelay
in al, dx ; get status bits
and al, L_BITS ; mask unused ones
xor al, L_BITS_INVERT ; flip a couple
xchg al, ah
ifndef NOOKIHACK
iodelay
in al, dx
dec dx
and al, L_BITS
xor al, L_BITS_INVERT
cmp al, ah ; did any bits change?
jnz LPT_WaitReady
else
dec dx
endif
test ah, PS_PaperOut or PS_IOError
jnz LPT_PrinterNotReady
test ah, PS_Select
jz LPT_PrinterNotReady
test ah, PS_NotBusy
jnz LPT_PrinterReady
push ax
push dx
call GetSystemMSecCount
pop dx
pop bx
sub ax, di
cmp ax, 300 ; 1/3 sec timeout
jbe LPT_WaitReady
; The device seems to be selected and powered up, but is just
; busy (some printers seem to show selected but busy when they
; are taken offline). Show that the transmit queue is full and
; that the hold handshakes are set. This is so the windows
; spooler will retry (and do yields so that other apps may run).
or ComErr[si],CE_TXFULL ;Show queue full
mov ah,bh
or ah, L_TIMEOUT
LPT_PrinterNotReady:
pop di
pop cx ; throw away character
jmp LPT_ReturnStatus
LPT_PrinterReady:
pop di ; get di back
pop ax ; get character back
iodelay
out dx, al ; write character to port
inc dx ; access status port
LPT_Strobe:
inc dx ; control port
mov al, L_STROBE ; set strobe high
iodelay
iodelay
iodelay
iodelay
out dx, al ; ...
mov al, L_NORMAL ;
iodelay
iodelay
iodelay
iodelay
out dx, al ; set strobe low
sub dx, 2 ; point back to port base
; FALL THRU
LPT_GetStatus:
inc dx ; point to status port
LPT_GS1:
iodelay
iodelay
in al, dx ; get status bits
and al, L_BITS ; mask unused ones
xor al, L_BITS_INVERT ; flip a couple
mov ah, al
ifndef NOOKIHACK
in al, dx
and al, L_BITS
xor al, L_BITS_INVERT
cmp al, ah
jnz LPT_GS1 ; if they changed try again...
endif
LPT_ReturnStatus:
assumes ds,Data
and ax,(PS_PaperOut+PS_Select+PS_IOError+PS_Timeout)*256
shr ah,1
adc ah,al ;Get back Timeout bit
xor ah,HIGH CE_DNS ;Invert selected bit
.errnz LOW CE_DNS
or by ComErr+1[si],ah ;Save comm error
ret
.errnz CE_PTO-0200h
.errnz CE_IOE-0400h
.errnz CE_DNS-0800h
.errnz CE_OOP-1000h
DoLPT40:
assumes ds,Data
or ComErr[si],CE_TXFULL ;Show queue full
ret
DoLPT endp
page
;----------------------------Private-Routine----------------------------;
;
; TXI - Transmit A Character Immediately
;
; Set up a character to be transmitted "immediately".
; by placing the character in a location that guarantees
; it to be the next character transmitted.
;
; The check to see if the immediate character can be placed has
; already been made prior to entry.
;
; Interrupts must be disabled before entering this code
;
; Entry:
; AH = Character
; DS:SI --> DEB
; Returns:
; None
; Error Returns:
; None
; Registers Preserved:
; BX,CX,SI,DI,DS,ES
; Registers Destroyed:
; AL,DX,FLAGS
; History:
;-----------------------------------------------------------------------;
;------------------------------Pseudo-Code------------------------------;
; {
; }
;-----------------------------------------------------------------------;
assumes ds,Data
assumes es,nothing
public TXI ;Public for debugging
TXI proc near
; FCLI ;Must be done by caller!
or EFlags[si],fTxImmed ;Show char to xmit
mov ImmedChar[si],ah ;Set character to transmit next
; jmp short KickTx ;Kick Xmit just in case
errn$ KickTx
TXI endp
page
;----------------------------Private-Routine----------------------------;
;
; KickTx - Kick Transmitter
;
; "Kick" the transmitter interrupt routine into operation.
; If the Transmitter Holding Register isn't empty, then
; nothing needs to be done. If it is empty, then the xmit
; interrupt needs to enabled in the IER.
;
; Entry:
; DS:SI --> DEB
; INTERRUPTS DISABLED!
; Returns:
; None
; Error Returns:
; None
; Registers Preserved:
; BX,CX,SI,DI,DS,ES
; Registers Destroyed:
; AX,DX,FLAGS
; History:
;-----------------------------------------------------------------------;
;------------------------------Pseudo-Code------------------------------;
; {
; }
;-----------------------------------------------------------------------;
assumes ds,Data
assumes es,nothing
public KickTx ;Public for debugging
KickTx proc near
; FCLI ;Done by caller
mov dx,Port[si] ;Get device I/O address
add dl,ACE_LSR ;Point at the line status reg
pin al,dx ;And get it
and al,ACE_THRE ;Check transmitter holding reg status
jz KickTx10 ;Busy, interrupt will hit soon enough
sub dl,ACE_LSR-ACE_IER ;--> Interrupt enable register
pin al,dx ;Get current IER state
test al,ACE_THREI ;Interrupt already enabled?
jnz KickTx10 ; Yes, don't reenable it
or al,ACE_THREI ; No, enable it
pout dx,al
pause ;8250, 8250-B bug requires
pout dx,al ; writting register twice
KickTx10:
; FSTI ;Done by caller
ret
KickTx endp
page
;----------------------------Private-Routine----------------------------;
;
; GetDEB - Get Pointer To Device's DEB
;
; Returns a pointer to appropriate DEB, based on device number.
;
; Entry:
; AH = cid
; Returns:
; 'C' clear
; 'S' set if LPT device
; DS:SI --> DEB is valid cid
; AH = cid
; Error Returns:
; 'C' set if error (cid is invalid)
; AX = 8000h
; Registers Preserved:
; BX,CX,DX,DI,DS,ES
; Registers Destroyed:
; AX,SI,FLAGS
; History:
;-----------------------------------------------------------------------;
;------------------------------Pseudo-Code------------------------------;
; {
; }
;-----------------------------------------------------------------------;
assumes ds,Data
assumes es,nothing
public GetDEB ;Public for debugging
GetDEB proc near
cmp ah,LPTx+MAXLPT ;Within range?
ja GetDEB30 ;No, return invalid ID
mov si,DataOFFSET LPT3 ;Assume LPT3
je GetDEB10 ;It's LPT3
cmp ah,MAXCOM ;Is cid within range for a com port?
ja GetDEB20 ; No, check for a LPT port 1 and 2
mov si,DataOFFSET Comm4 ;Assume COM4 [rkh] ...
je GetDEB10 ;It was COM4
mov si,DataOFFSET Comm3 ;Assume COM3
cmp ah,MAXCOM-1 ;Is cid within range for a com port?
je GetDEB10 ;It was COM3
mov si,DataOFFSET Comm2 ;Assume COM2
cmp ah,MAXCOM-2 ;Is cid within range for a com port?
je GetDEB10 ;It was COM2
mov si,DataOFFSET Comm1 ;It was COM1
GetDEB10:
or ah,ah ;Set 'S' if LPT, clear 'C'
ret
.errnz LPTx-10000000b
GetDEB20:
mov si,DataOFFSET LPT1 ;Assume LPT1
cmp ah,LPTx
je GetDEB10 ;Its LPT1
mov si,DataOFFSET LPT2 ;Assume LPT2
ja GetDEB10 ;Its LPT2
GetDEB30:
mov ax,8000h ;Set error code
stc ;Set 'C' to show error
ret
GetDEB endp
page
;----------------------------Public Routine-----------------------------;
;
; $SETQUE - Set up Queue Pointers
;
; Sets pointers to Receive and Transmit Queues, as provided by the
; caller, and initializes those queues to be empty.
;
; Queues must be set before $INICOM is called!
;
; Entry:
; AH = Device ID
; ES:BX --> Queue Definition Block
; Returns:
; AX = 0 if no errors occured
; Error Returns:
; AX = error code
; Registers Preserved:
; BX,DX,SI,DI,DS
; Registers Destroyed:
; AX,CX,ES,FLAGS
; History:
;-----------------------------------------------------------------------;
;------------------------------Pseudo-Code------------------------------;
; {
; }
;-----------------------------------------------------------------------;
assumes ds,Data
assumes es,nothing
public $SETQUE
$SETQUE proc near
push si ;These will be used
push di
call GetDEB ;Get DEB
jc SetQue10 ;Invalid, ignore the call
js SetQue10 ;Ignore call for LPT ports
push ds ;Set ds:si --> QDB
push es ;Set es:di --> to ComDCB.QInAddr
pop ds
assumes ds,nothing
pop es
assumes es,Data
lea di,QInAddr[si]
mov si,bx
mov cx,(SIZE QDB)/2
.errnz (SIZE QDB) AND 1
xor ax,ax ;Will do some zero filling
cld
FCLI ;No one else can play with queues
rep movsw
mov cl,(EFlags-QInCount)/2
.errnz (EFlags-QInCount) AND 0FE01h
rep stosw
FSTI
push es ;Restore the data segment
pop ds
assumes ds,Data
assumes es,nothing
SetQue10:
pop di ;Restore saved registers
pop si
ret
; The above code made a few assumptions about how memory
; was allocated within the structures:
.errnz (QueueRxSize-QueueRxAddr)-(QInSize-QInAddr)
.errnz (QueueTxAddr-QueueRxSize)-(QOutAddr-QInSize)
.errnz (QueueTxSize-QueueTxAddr)-(QOutSize-QOutAddr)
.errnz QueueRxSize-QueueRxAddr-4
.errnz QueueTxAddr-QueueRxSize-2
.errnz QueueTxSize-QueueTxAddr-4
.errnz QInSize-QInAddr-4
.errnz QOutAddr-QInSize-2
.errnz QOutSize-QOutAddr-4
.errnz QInCount-QOutSize-2
.errnz QInGet-QInCount-2
.errnz QInPut-QInGet-2
.errnz QOutCount-QInPut-2
.errnz QOutGet-QOutCount-2
.errnz QOutPut-QOutGet-2
.errnz EFlags-QOutPut-2 ;First non-queue item
$SETQUE endp
page
;----------------------------Public Routine-----------------------------;
;
; $EVT - Set Event Mask
;
; Set up event word and mask. Returns a pointer to a word in which
; certain bits, as enabled by the mask, will be set when certain
; events occur.
;
; Entry:
; AH = Device ID
; BX = Event enable mask
; Returns:
; DX:AX --> event word.
; Error Returns:
; AX = 0 if error
; Registers Preserved:
; BX,CX,SI,DI,DS,ES
; Registers Destroyed:
; AX,DX,FLAGS
; History:
;-----------------------------------------------------------------------;
;------------------------------Pseudo-Code------------------------------;
; {
; }
;-----------------------------------------------------------------------;
assumes ds,Data
assumes es,nothing
public $EVT
$EVT proc near
push si
xor dx,dx ;In case of error
call GetDEB ;Get pointer to DEB
mov ax,dx ;Finish setting error return value
jc Evt10 ;Illegal id, return error
js Evt10 ;LPTx, return error
mov EvtMask[si],bx ;Save the new event mask
lea ax,EvtWord[si] ;Get address of event word
mov dx,ds ; into dx:ax
Evt10:
pop si
ret
$EVT endp
page
;----------------------------Public Routine-----------------------------;
;
; $EVTGET - Get Event Word
;
; Return and clear fields in the event word. This routine MUST be used
; by applications to read the event word, as it is the ONLY way they
; can be assured that an event is not lost between reading the flags
; and resetting some.
;
; Entry:
; AH = Device ID
; BX = Event clear mask
; Returns:
; AX = event word
; Error Returns:
; None
; Registers Preserved:
; AX,CX,SI,DI,DS,ES
; Registers Destroyed:
; BX,FLAGS
; History:
;-----------------------------------------------------------------------;
;------------------------------Pseudo-Code------------------------------;
; {
; }
;-----------------------------------------------------------------------;
assumes ds,Data
assumes es,nothing
public $EVTGET
$EVTGET proc near
push si
call GetDEB
mov ah,0 ;In case of error (AL already 0)
jc EvtGet10 ;Illegal ID
js EvtGet10 ;Illegal ID
FCLI ;No interrupts allowed
mov ax,EvtWord[si] ;Get the current event word
not bx ;Convert mask for our purposes
and bx,ax ;Clear events that user wants us to
mov EvtWord[si],bx ;And save those results
FSTI ;Magic over
EvtGet10:
pop si
ret
$EVTGET endp
page
;----------------------------Public Routine-----------------------------;
;
; $STACOM - Return Status Information
;
; Returns the number of bytes in both queues.
;
; LPT ports will show both queues empty.
; and resetting some.
;
; Entry:
; AH = Device ID
; ES:BX = Pointer to status structure to be updated.
; = Null if not to update
; Returns:
; AX = comm error word
; Status Structure Updated.
; Error Returns:
; AX = error code
; Registers Preserved:
; SI,DI,DS,ES
; Registers Destroyed:
; AX,BX,CX,DX,FLAGS
; History:
;-----------------------------------------------------------------------;
;------------------------------Pseudo-Code------------------------------;
; {
; }
;-----------------------------------------------------------------------;
assumes ds,Data
assumes es,nothing
public $STACOM
$STACOM proc near
push si
call GetDEB ;Get DEB pointer in SI
jc StaCom30 ;Invalid ID
mov cx,es ;Is the pointer NULL?
or cx,bx
jz StaCom25 ; Yes, just return error code
xor cx,cx
xor dx,dx
or ah,ah ;Set 'S' if LPT port
mov ax,cx ;For LPTs, everything is zero
js StaCom20 ;LPT port
; Need to get the status for a com port. Since not all the
; status is contained within EFlags, it has to be assembled.
; Also note that currently there is no way to specify RLSD
; as a handshaking line, so fRLSDHold is always returned false.
mov al,MSRShadow[si] ;Get state of hardware lines
and al,OutHHSLines[si] ;Mask off required bits
xor al,OutHHSLines[si] ;1 = line low
mov cl,4 ;Align bits
shr al,cl ;al = fCTSHold + fDSRHold
.errnz ACE_CTS-00010000b
.errnz ACE_DSR-00100000b
.errnz fCTSHold-00000001b
.errnz fDSRHold-00000010b
mov ah,HSFlag[si] ;Get fXOffHold+fXOffSent
and ah,XOffReceived+XOffSent
or al,ah
.errnz XOffReceived-fXOFFHold
.errnz XOffSent-fXOFFSent
mov ah,EFlags[si] ;Get fEOF+fTxImmed
and ah,fEOF+fTxImmed
or al,ah
mov cx,QInCount[si] ;Get input queue count
mov dx,QOutCount[si] ;Get tx queue count
StaCom20:
mov es:StatFlags[bx],al
mov es:StatRxCount[bx],cx
mov es:StatTxCount[bx],dx
StaCom25:
xor ax,ax ;Return old com error
xchg ax,ComErr[si] ; and clear it out
StaCom30:
pop si
ret
$STACOM endp
page
;----------------------------Public Routine-----------------------------;
;
; $SetBrk - Set Break
;
; Clamp the Tx data line low. Does not wait for the
; transmitter holding register and shift registers to empty.
;
; LPT ports will just return the comm error word
;
; Entry:
; AH = Device ID
; Returns:
; AX = comm error word
; Error Returns:
; AX = error code
; Registers Preserved:
; SI,DI,DS,ES
; Registers Destroyed:
; AX,BX,CX,DX,FLAGS
; History:
;-----------------------------------------------------------------------;
;------------------------------Pseudo-Code------------------------------;
; {
; }
;-----------------------------------------------------------------------;
assumes ds,Data
assumes es,nothing
public $SETBRK
$SETBRK proc near
mov cx,0FF00h+ACE_SB ;Will be setting break
jmp short ClrBrk10
.errnz BreakSet-ACE_SB ;Must be same bits
$SETBRK endp
page
;----------------------------Public Routine-----------------------------;
;
; $CLRBRK - Clear Break
;
; Release any BREAK clamp on the Tx data line.
;
; LPT ports will just return the comm error word
;
; Entry:
; AH = Device ID
; Returns:
; AX = comm error word
; Error Returns:
; AX = error code
; Registers Preserved:
; SI,DI,DS,ES
; Registers Destroyed:
; AX,BX,CX,DX,FLAGS
; History:
;-----------------------------------------------------------------------;
;------------------------------Pseudo-Code------------------------------;
; {
; }
;-----------------------------------------------------------------------;
assumes ds,Data
assumes es,nothing
public $CLRBRK
$CLRBRK proc near
mov cx,(NOT ACE_SB) SHL 8
.errnz BreakSet-ACE_SB ;Must be same bits
ClrBrk10:
push si
call GetDEB ;Get DEB address
jc ClrBrk30 ;Invalid ID
js ClrBrk20 ;Ignored for LPT ports
FCLI
and HSFlag[si],ch ;Set or clear the BreakSet bit
or HSFlag[si],cl
; ch = mask to remove bits in the Line Control Register
; cl = mask to turn bits on in the Line Control Register
mov dx,Port[si] ;Get comm device base I/O port
add dl,ACE_LCR ;Point at the Line Control Regieter
pin al,dx ;Get old line control value
and al,ch ;Turn off desired bits
or al,cl ;Turn on desired bits
pause
pout dx,al ;Output New LCR.
FSTI
ClrBrk20:
mov ax,ComErr[si] ;Return Status Word
ClrBrk30:
pop si
ret
$CLRBRK endp
page
;----------------------------Public Routine-----------------------------;
;
; $EXTCOM - Extended Comm Functions
;
; A number of extended functions are routed through this entry point.
;
; Functions currently implemented:
;
; 0: Ignored
; 1: SETXOFF - Exactly as if X-OFF character has been received.
; 2: SETXON - Exactly as if X-ON character has been received.
; 3: SETRTS - Set the RTS signal
; 4: CLRRTS - Clear the RTS signal
; 5: SETDTR - Set the DTR signal
; 6: CLRDTR - Clear the DTR signal
; 7: RESET - Yank on reset line if available (LPT devices)
;
; Entry:
; AH = Device ID
; BL = Function Code
; (0-127 are MS-defined, 128-255 are OEM defined)
; Returns:
; AX = comm error word
; Error Returns:
; AX = error code
; Registers Preserved:
; SI,DI,DS
; Registers Destroyed:
; AX,BX,CX,DX,ES,FLAGS
; History:
;-----------------------------------------------------------------------;
;------------------------------Pseudo-Code------------------------------;
; {
; }
;-----------------------------------------------------------------------;
; Dispatch table for the extended functions
ExtTab dw ExtComDummy ;Function 0: Never Mind
dw ExtCom_FN1 ;1: Set X-Off
dw ExtCom_FN2 ;2: Clear X-Off
dw ExtCom_FN3 ;3: Set RTS
dw ExtCom_FN4 ;4: Clear RTS
dw ExtCom_FN5 ;5: Set DSR
dw ExtCom_FN6 ;6: Clear DSR
dw ExtCom_FN7 ;7: Reset printer
assumes ds,Data
assumes es,nothing
public $EXTCOM
$EXTCOM proc near
push si
call GetDEB ;Get DEB pointer
jc ExtCom40 ;Invalid ID, return error
mov dx,Port[si] ; get port address
jns ExtCom10 ;Its a COM port
cmp bl,7 ;RESET extended function?
jne ExtCom30 ; No, return error word
jmp short ExtCom20 ; Yes, invoke the function
ExtCom10:
cmp bl,7 ;Last fcn supported +1
jnc ExtCom30 ;Not an implemented function.
ExtCom20:
xor bh,bh
add bx,bx ;Shift for the call
FCLI ;Consider as critical sections
call ExtTab[bx] ; and perform the function
FSTI
ExtCom30:
mov ax,ComErr[si] ;Return standard error word
ExtCom40:
pop si
ExtComDummy:
ret
$EXTCOM endp
page
;----------------------------Private-Routine----------------------------;
;
; ExtCom_FN1 - Extended Function Set X-Off
;
; Analagous to receiving an X-OFF character. Bufferred transmision of
; characters is halted until an X-ON character is received, or until
; we fake that with a Clear X-Off call.
;
; Entry:
; interrupts disabled
; dx = port base address
; Returns:
; None
; Error Returns:
; None
; Registers Preserved:
; SI,DI,DS
; Registers Destroyed:
; AX,BX,CX,DX,ES,FLAGS
; History:
;-----------------------------------------------------------------------;
;------------------------------Pseudo-Code------------------------------;
; {
; }
;-----------------------------------------------------------------------;
assumes ds,Data
assumes es,nothing
public ExtCom_FN1
ExtCom_FN1 proc near
or HSFlag[si],XOffReceived
ret
ExtCom_FN1 endp
page
;----------------------------Private-Routine----------------------------;
;
; ExtCom_FN2 - Extended Function Clear X-Off
;
; Analagous to receiving an X-ON character. Buffered
; transmission of characters is restarted.
;
; Entry:
; interrupts disabled
; dx = port base address
; Returns:
; None
; Error Returns:
; None
; Registers Preserved:
; SI,DI,DS
; Registers Destroyed:
; AX,BX,CX,DX,ES,FLAGS
; History:
;-----------------------------------------------------------------------;
;------------------------------Pseudo-Code------------------------------;
; {
; }
;-----------------------------------------------------------------------;
assumes ds,Data
assumes es,nothing
public ExtCom_FN2
ExtCom_FN2 proc near
and HSFlag[si],NOT XOffReceived
jmp KickTx ;Kick transmitter interrupts on
ExtCom_FN2 endp
page
;----------------------------Private-Routine----------------------------;
;
; ExtCom_FN3 - Extended Function Set RTS
;
; Set the RTS signal active.
;
; Entry:
; interrupts disabled
; dx = port base address
; Returns:
; None
; Error Returns:
; None
; Registers Preserved:
; SI,DI,DS
; Registers Destroyed:
; AX,BX,CX,DX,ES,FLAGS
; History:
;-----------------------------------------------------------------------;
;------------------------------Pseudo-Code------------------------------;
; {
; }
;-----------------------------------------------------------------------;
assumes ds,Data
assumes es,nothing
public ExtCom_FN3
ExtCom_FN3 proc near
add dl,ACE_MCR ;Point at Modem Control Register
pin al,dx ;Get current settings
or al,ACE_RTS ;Set RTS
pause
pout dx,al ;And update
ret
ExtCom_FN3 endp
page
;----------------------------Private-Routine----------------------------;
;
; ExtCom_FN4 - Extended Function Clear RTS
;
; Set the RTS signal inactive.
;
; Entry:
; interrupts disabled
; dx = port base address
; Returns:
; None
; Error Returns:
; None
; Registers Preserved:
; SI,DI,DS
; Registers Destroyed:
; AX,BX,CX,DX,ES,FLAGS
; History:
;-----------------------------------------------------------------------;
;------------------------------Pseudo-Code------------------------------;
; {
; }
;-----------------------------------------------------------------------;
assumes ds,Data
assumes es,nothing
public ExtCom_FN4
ExtCom_FN4 proc near
add dl,ACE_MCR ;Point at Modem Control Register
pin al,dx ;Get current settings
and al,NOT ACE_RTS ;Clear RTS
pause
pout dx,al ;And update
ret
ExtCom_FN4 endp
page
;----------------------------Private-Routine----------------------------;
;
; ExtCom_FN5 - Extended Function Set DTR
;
; Set the DTR signal active.
;
; Entry:
; interrupts disabled
; dx = port base address
; Returns:
; None
; Error Returns:
; None
; Registers Preserved:
; SI,DI,DS
; Registers Destroyed:
; AX,BX,CX,DX,ES,FLAGS
; History:
;-----------------------------------------------------------------------;
;------------------------------Pseudo-Code------------------------------;
; {
; }
;-----------------------------------------------------------------------;
assumes ds,Data
assumes es,nothing
public ExtCom_FN5
ExtCom_FN5 proc near
add dl,ACE_MCR ;Point at Modem Control Register
pin al,dx ;Get current settings
or al,ACE_DTR ;Set DTR
pause
pout dx,al ;And update
ret
ExtCom_FN5 endp
page
;----------------------------Private-Routine----------------------------;
;
; ExtCom_FN6 - Extended Function Clear DTR
;
; Set the DTR signal inactive.
;
; Entry:
; interrupts disabled
; dx = port base address
; Returns:
; None
; Error Returns:
; None
; Registers Preserved:
; SI,DI,DS
; Registers Destroyed:
; AX,BX,CX,DX,ES,FLAGS
; History:
;-----------------------------------------------------------------------;
;------------------------------Pseudo-Code------------------------------;
; {
; }
;-----------------------------------------------------------------------;
assumes ds,Data
assumes es,nothing
public ExtCom_FN6
ExtCom_FN6 proc near
add dl,ACE_MCR ;Point at Modem Control Register
pin al,dx ;Get current settings
and al,NOT ACE_DTR ;Clear DTR
pause
pout dx,al ;And update
ret
ExtCom_FN6 endp
page
;----------------------------Private-Routine----------------------------;
;
; ExtCom_FN7 - Extended Function Reset Printer
;
; Assert the RESET line on an LPT port
;
; Entry:
; interrupts disabled
; dx = port base address
; Returns:
; None
; Error Returns:
; None
; Registers Preserved:
; SI,DI,DS
; Registers Destroyed:
; AX,BX,CX,DX,ES,FLAGS
; History:
;-----------------------------------------------------------------------;
;------------------------------Pseudo-Code------------------------------;
; {
; }
;-----------------------------------------------------------------------;
assumes ds,Data
assumes es,nothing
public ExtCom_FN7
ExtCom_FN7 proc near
FSTI ;Not called at interrupt time
mov ch,1 ;ROM BIOS Reset Port
call DoLPT ;Perform the function
ret
ExtCom_FN7 endp
page
;----------------------------Public Routine-----------------------------;
;
; $DCBPtr - Return Pointer To DCB
;
; Returns a long pointer to the DCB for the requested device.
;
; Entry:
; AH = Device ID
; Returns:
; DX:AX = pointer to DCB.
; Error Returns:
; DX:AX = 0
; Registers Preserved:
; SI,DI,DS
; Registers Destroyed:
; BX,CX,ES,FLAGS
; History:
;-----------------------------------------------------------------------;
;------------------------------Pseudo-Code------------------------------;
; {
; }
;-----------------------------------------------------------------------;
assumes ds,Data
assumes es,nothing
public $DCBPTR
$DCBPTR proc near
push si
xor dx,dx
call GetDEB ;Get pointer to DEB
mov ax,dx
jc DCBPtr10 ;Jump if invalid device
mov ax,si ;else return value here
mov dx,ds
DCBPtr10:
pop si
ret
$DCBPTR endp
page
;----------------------------Public Routine-----------------------------;
;
; $RECCOM - Receive Characters From Device
;
; Read Byte From RS232 Input Queue If Data Is Ready
;
; LPT ports will return with an indication that no characters are
; available.
;
; Entry:
; AH = Device ID
; Returns:
; 'Z' clear if data available
; AL = byte
; Error Returns:
; 'Z' Set if error or no data
; AX = error code
; AX = 0 if no data
; Registers Preserved:
; SI,DI,DS
; Registers Destroyed:
; AX,BX,CX,DX,ES,FLAGS
; History:
;-----------------------------------------------------------------------;
;------------------------------Pseudo-Code------------------------------;
; {
; }
;-----------------------------------------------------------------------;
assumes ds,Data
assumes es,nothing
public $RECCOM
$RECCOM proc near
push si ;Once again, save some registers
push di
call GetDEB ;Get DEB pointer in SI
jc RecCom10 ;Invalid Port [rkh] ...
js RecCom20 ;LPT port, return no characters
jmp short RecCom30
RecCom10:
jmp RecCom100 ; Invalid Port
RecCom20:
jmp RecCom95 ;LPT port, return no characters
; Before removing any charcters from the input queue, check to see
; if XON needs to be issued. If it needs to be issued, set the
; flag that will force it and arm transmit interrupts.
RecCom30:
test Flags[si],fEnqAck+fEtxAck ;Enq or Etx Ack?
jz RecCom32 ; No
test HSFlag[si],EnqReceived+HHSDropped ;Enq recvd or lines dropped?
jz RecCom60 ; No Enq recvd & no lines dropped
jmp short RecCom34
RecCom32:
test HSFlag[si],HSSent ;Handshake sent?
jz RecCom60 ; No XOFF sent & no lines dropped
RecCom34:
mov ax,QInCount[si] ;Get current count of input chars
cmp ax,XONLim[si] ;See if at XOn limit
ja RecCom60 ;Not at XOn limit yet
; If any hardware lines are down, then raise them. Then see
; about sending XON.
mov dx,Port[si] ;Get the port
mov ah,HHSLines[si] ;Get hardware lines mask
FCLI ;Handle this as a critical section
mov cl,HSFlag[si] ;Get handshaking flags
or ah,ah ;Any hardware lines to play with?
jz RecCom40 ; No
add dl,ACE_MCR ;--> Modem control register
pin al,dx
or al,ah ;Turn on the hardware bits
pause
pout dx,al
and cl,NOT HHSDropped ;Show hardware lines back up
RecCom40:
test Flags[si],fEnqAck+fEtxAck ;Enq or Etx Ack?
jz RecCom47 ; No
test cl,EnqReceived ;Did we receive Enq?
jz RecCom55 ; No
and cl,NOT EnqReceived
jmp short RecCom50
RecCom47:
test cl,XOffSent ;Did we send XOFF?
jz RecCom55 ; No
and cl,NOT XOffSent ;Remove XOFF sent flag
RecCom50:
or cl,XOnPending ;Show XON or ACK must be sent
call KickTx ;Kick xmit if needed
RecCom55:
mov HSFlag[si],cl ;Store handshake flag
FSTI ;Can allow interrupts now
; Now we can get down to the business at hand, and remove a character
; from the receive queue. If a communications error exists, we return
; that, and nothing else.
RecCom60:
xor ax,ax
or ax,ComErr[si] ;Any Errors?
jnz RecCom100 ; Yes, return the error code
or ax,QInCount[si] ;Get current input char count
jz RecCom90 ;No characters in the queue
les di,QInAddr[si] ;Get queue pointer
assumes es,nothing
mov bx,QInGet[si] ;Also get the index to head
mov al,es:[bx][di] ;Finally, get byte from queue
inc bx ;Update queue index
cmp bx,QInSize[si] ;See if time for wrap-around
jc RecCom70 ;Jump if no wrap
xor bx,bx ;wrap by zeroing the index
RecCom70:
mov QInGet[si],bx ;Save new head pointer
dec QInCount[si] ;Dec # of bytes in queue
RecCom80:
or sp,sp ;Reset PSW.Z
pop di
pop si
ret
; No characters in the input queue. Check to see if EOF
; was received, and return it if it was. Otherwise show
; no characters.
RecCom90:
test Flags[si],fBinary ;Are we doing binary stuff?
jnz RecCom95 ; Yes, show no characters
mov al,EOFChar[si] ;Assume EOF
test EFlags[si],fEOF ;Has end of file char been received?
jnz RecCom80 ; Yes, show end of file
RecCom95:
xor ax,ax ;Show no more characters
; Return with 'Z' to show error or no characters
RecCom100:
xor cx,cx ;Set PSW.Z
pop di
pop si
ret
$RECCOM endp
page
;----------------------------Public Routine-----------------------------;
;
; $FLUSH - Flush The Input and Output Queues
;
; This is a hard initialization of the transmit and receive queue's,
; which immediately empties the given queue.
;
; LPT ports will just return the device error word
;
; Entry:
; AH = Device ID
; BH = Queue # to clear (0=Tx, 1=Rx)
; Returns:
; AX = Device Error Word. (Not reset)
; Error Returns:
; AX = error code
; Registers Preserved:
; SI,DI,DS
; Registers Destroyed:
; AX,BX,CX,DX,ES,FLAGS
; History:
;-----------------------------------------------------------------------;
;------------------------------Pseudo-Code------------------------------;
; {
; }
;-----------------------------------------------------------------------;
assumes ds,Data
assumes es,nothing
public $FLUSH
$FLUSH proc near
push si
push di
call GetDEB ;si --> DEB
jc Flush40 ;Invalid ID
js Flush30 ;LPT port, return any error
mov cx,QOutCount-QInCount ;# of bytes to zero
lea di,QInCount[si] ;--> receive queue data
or bh,bh ;Transmit queue?
jnz Flush10 ; No, input queue
add di,cx ; Yes, --> xmit queue data
Flush10:
cld
push ds
pop es
assumes es,nothing
xor al,al
FCLI ;Time to worry about critical sections
rep stosb
FSTI
.errnz QInGet-QInCount-2
.errnz QInPut-QInGet-2
.errnz QOutCount-QInPut-2
.errnz QOutGet-QOutCount-2
.errnz QOutPut-QOutGet-2
or bh,bh ;Rx queue?
jz Flush30 ; No, xmit queue
; If the queue to be cleared is the receive queue, any
; hardware handshake must be cleared to prevent a possible
; deadlock situation. Since we just zeroed the queue count,
; a quick call to $RecCom should do wonders to clear any
; receive handshake (i.e. send XON if needed).
Flush20:
call $RECCOM ;Take care of handshakes here
Flush30:
mov ax,ComErr[si] ;And return the error word.
Flush40:
pop di
pop si
ret
$FLUSH endp
ifdef DEBUG
public KickTx10
public GetDEB10
public GetDEB20
public GetDEB30
public SetQue10
public Evt10
public EvtGet10
public StaCom20
public StaCom25
public StaCom30
public ClrBrk10
public ClrBrk20
public ClrBrk30
public ExtCom10
public ExtCom20
public ExtCom30
public ExtCom40
public ExtComDummy
public DCBPtr10
public RecCom30
public RecCom40
public RecCom50
public RecCom60
public RecCom70
public RecCom80
public RecCom90
public RecCom95
public RecCom100
public Flush10
public Flush20
public Flush30
public Flush40
endif
| 27.675016
| 80
| 0.482409
|
7e600fe28d84ab10d87b2854fb9c7d2f806faf55
| 3,118
|
asm
|
Assembly
|
source/float/fpfromstr.asm
|
paulscottrobson/basic-65
|
5d38713aca0ec239bb1ee89ea05e548448abcc2c
|
[
"MIT"
] | null | null | null |
source/float/fpfromstr.asm
|
paulscottrobson/basic-65
|
5d38713aca0ec239bb1ee89ea05e548448abcc2c
|
[
"MIT"
] | null | null | null |
source/float/fpfromstr.asm
|
paulscottrobson/basic-65
|
5d38713aca0ec239bb1ee89ea05e548448abcc2c
|
[
"MIT"
] | null | null | null |
; *******************************************************************************************
; *******************************************************************************************
;
; Name : fpfromstr.asm
; Purpose : Convert String to floating point
; Date : 16th August 2019
; Author : Paul Robson (paul@robsons.org.uk)
;
; *******************************************************************************************
; *******************************************************************************************
; *******************************************************************************************
;
; Called after IntFromString. Starting at (zGenPtr),y try to extract first a
; decimal part, which can be added to A, and then an exponent scalar, which
; can be used to scale A.
;
; *******************************************************************************************
FPFromString:
pha ; push A
lda (zGenPtr),y ; is it followed by a DP ?
cmp #"."
beq _FPFIsDecimal
jmp _FPFNotDecimal
;
; Handle the decimal places bit.
;
_FPFIsDecimal:
iny ; consume the decimal.
;
jsr FPUToFloat ; convert the integer to float.
phx ; save X.
phy ; save decimal start position
inx6 ; go to next section.
jsr INTFromStringY ; get the part after the DP.
jsr FPUToFloat ; convert that to a float.
;
pla ; calculate - chars consumed.
sty ExpTemp
sec
sbc ExpTemp ; this is the shift amount
jsr FPUScale10A ; scale it by 10^AC
plx ; restore original X
jsr FPAdd ; Add X2 to X1 giving the fractional bit.
;
lda (zGenPtr),y ; exponent ?
cmp #"E"
beq _FPFExponent
cmp #"e"
bne _FPFNotDecimal ; no, then exit normally.
;
; Handle exponent bit. First, find the - sign if it exists.
;
_FPFExponent:
iny ; skip over E symbol.
lda (zGenPtr),y ; look at next
eor #"-" ; will be zero if -ve
bne _FPFGotSign
iny ; if it was - skip over it.
_FPFGotSign:
pha ; push direction : 0 -ve, #0 +ve onto stack.
;
; Then get the exponent and check it's in the right range.
;
phx
inx6 ; go to next slot.
jsr INTFromStringY ; get the exponent
plx ; restore X.
lda XS2_Mantissa+1,x ; check exponent low bytes are all zero.
ora XS2_Mantissa+3,x
ora XS2_Mantissa+2,x
bne _FPFXOverflow ; if not, must be a bad exponent
lda XS2_Mantissa+0,x ; get the exponent, the low byte
cmp #30 ; check in range 0-30
bcs _FPFXOverflow
;
; Negate it if it was the - sign after the E/e
;
pla ; get direction
bne _FPFXScale ; if non-zero, e.g. +ve skip the next bit
lda XS2_Mantissa+0,x ; negate the exponent
eor #$FF
inc a
sta XS2_Mantissa+0,x
_FPFXScale:
;
; Finally scale by 10^Exponent.
;
lda XS2_Mantissa+0,x ; get scale amount
jsr FPUScale10A ; scale by the exponent.
_FPFNotDecimal:
pla
rts
_FPFXOverflow:
jsr ERR_Handler
.text "Exponent Range",0
| 30.271845
| 93
| 0.502245
|
83c20d39c16731e2940c50f59f68bb5ef2500355
| 1,568
|
asm
|
Assembly
|
programs/oeis/049/A049451.asm
|
karttu/loda
|
9c3b0fc57b810302220c044a9d17db733c76a598
|
[
"Apache-2.0"
] | 1
|
2021-03-15T11:38:20.000Z
|
2021-03-15T11:38:20.000Z
|
programs/oeis/049/A049451.asm
|
karttu/loda
|
9c3b0fc57b810302220c044a9d17db733c76a598
|
[
"Apache-2.0"
] | null | null | null |
programs/oeis/049/A049451.asm
|
karttu/loda
|
9c3b0fc57b810302220c044a9d17db733c76a598
|
[
"Apache-2.0"
] | null | null | null |
; A049451: Twice second pentagonal numbers.
; 0,4,14,30,52,80,114,154,200,252,310,374,444,520,602,690,784,884,990,1102,1220,1344,1474,1610,1752,1900,2054,2214,2380,2552,2730,2914,3104,3300,3502,3710,3924,4144,4370,4602,4840,5084,5334,5590,5852,6120,6394,6674,6960,7252,7550,7854,8164,8480,8802,9130,9464,9804,10150,10502,10860,11224,11594,11970,12352,12740,13134,13534,13940,14352,14770,15194,15624,16060,16502,16950,17404,17864,18330,18802,19280,19764,20254,20750,21252,21760,22274,22794,23320,23852,24390,24934,25484,26040,26602,27170,27744,28324,28910,29502,30100,30704,31314,31930,32552,33180,33814,34454,35100,35752,36410,37074,37744,38420,39102,39790,40484,41184,41890,42602,43320,44044,44774,45510,46252,47000,47754,48514,49280,50052,50830,51614,52404,53200,54002,54810,55624,56444,57270,58102,58940,59784,60634,61490,62352,63220,64094,64974,65860,66752,67650,68554,69464,70380,71302,72230,73164,74104,75050,76002,76960,77924,78894,79870,80852,81840,82834,83834,84840,85852,86870,87894,88924,89960,91002,92050,93104,94164,95230,96302,97380,98464,99554,100650,101752,102860,103974,105094,106220,107352,108490,109634,110784,111940,113102,114270,115444,116624,117810,119002,120200,121404,122614,123830,125052,126280,127514,128754,130000,131252,132510,133774,135044,136320,137602,138890,140184,141484,142790,144102,145420,146744,148074,149410,150752,152100,153454,154814,156180,157552,158930,160314,161704,163100,164502,165910,167324,168744,170170,171602,173040,174484,175934,177390,178852,180320,181794,183274,184760,186252
mov $1,3
mul $1,$0
mul $1,$0
add $1,$0
| 196
| 1,483
| 0.820791
|
ba703b3cd5f75e434cc96964152bcec794c41284
| 704
|
asm
|
Assembly
|
oeis/235/A235355.asm
|
neoneye/loda-programs
|
84790877f8e6c2e821b183d2e334d612045d29c0
|
[
"Apache-2.0"
] | 11
|
2021-08-22T19:44:55.000Z
|
2022-03-20T16:47:57.000Z
|
oeis/235/A235355.asm
|
neoneye/loda-programs
|
84790877f8e6c2e821b183d2e334d612045d29c0
|
[
"Apache-2.0"
] | 9
|
2021-08-29T13:15:54.000Z
|
2022-03-09T19:52:31.000Z
|
oeis/235/A235355.asm
|
neoneye/loda-programs
|
84790877f8e6c2e821b183d2e334d612045d29c0
|
[
"Apache-2.0"
] | 3
|
2021-08-22T20:56:47.000Z
|
2021-09-29T06:26:12.000Z
|
; A235355: 0 followed by the sum of (1),(2), (3,4),(5,6), (7,8,9),(10,11,12) from the natural numbers.
; 0,1,2,7,11,24,33,58,74,115,140,201,237,322,371,484,548,693,774,955,1055,1276,1397,1662,1806,2119,2288,2653,2849,3270,3495,3976,4232,4777,5066,5679,6003,6688,7049,7810,8210,9051,9492,10417,10901,11914,12443,13548,14124,15325,15950,17251,17927,19332,20061,21574,22358,23983,24824,26565,27465,29326,30287,32272,33296,35409,36498,38743,39899,42280,43505,46026,47322,49987,51356,54169,55613,58578,60099,63220,64820,68101,69782,73227,74991,78604,80453,84238,86174,90135,92160,96301,98417,102742,104951
lpb $0
add $3,$0
sub $0,1
add $1,$3
add $2,2
sub $3,$2
add $3,$0
trn $0,1
lpe
mov $0,$1
| 50.285714
| 497
| 0.724432
|
3497b2b93b0c3990039ed1c076f15edc5d141fe9
| 1,256
|
asm
|
Assembly
|
data/maps/environment_colors.asm
|
Dev727/ancientplatinum
|
8b212a1728cc32a95743e1538b9eaa0827d013a7
|
[
"blessing"
] | 28
|
2019-11-08T07:19:00.000Z
|
2021-12-20T10:17:54.000Z
|
data/maps/environment_colors.asm
|
Dev727/ancientplatinum
|
8b212a1728cc32a95743e1538b9eaa0827d013a7
|
[
"blessing"
] | 13
|
2020-01-11T17:00:40.000Z
|
2021-09-14T01:27:38.000Z
|
data/maps/environment_colors.asm
|
Dev727/ancientplatinum
|
8b212a1728cc32a95743e1538b9eaa0827d013a7
|
[
"blessing"
] | 22
|
2020-05-28T17:31:38.000Z
|
2022-03-07T20:49:35.000Z
|
EnvironmentColorsPointers:
; entries correspond to environment constants (see constants/map_data_constants.asm)
dw .OutdoorColors ; unused
dw .OutdoorColors ; TOWN
dw .OutdoorColors ; ROUTE
dw .IndoorColors ; INDOOR
dw .DungeonColors ; CAVE
dw .Env5Colors ; ENVIRONMENT_5
dw .IndoorColors ; GATE
dw .DungeonColors ; DUNGEON
; Valid indices: $00 - $29 (see gfx/tilesets/bg_tiles.pal)
.OutdoorColors:
db $00, $01, $02, $28, $04, $05, $06, $07 ; morn
db $08, $09, $0a, $28, $0c, $0d, $0e, $0f ; day
db $10, $11, $12, $29, $14, $15, $16, $17 ; nite
db $18, $19, $1a, $1b, $1c, $1d, $1e, $1f ; dark
.IndoorColors:
db $20, $21, $22, $23, $24, $25, $26, $07 ; morn
db $20, $21, $22, $23, $24, $25, $26, $07 ; day
db $10, $11, $12, $13, $14, $15, $16, $07 ; nite
db $18, $19, $1a, $1b, $1c, $1d, $1e, $07 ; dark
.DungeonColors:
db $00, $01, $02, $03, $04, $05, $06, $07 ; morn
db $08, $09, $0a, $0b, $0c, $0d, $0e, $0f ; day
db $10, $11, $12, $13, $14, $15, $16, $17 ; nite
db $18, $19, $1a, $1b, $1c, $1d, $1e, $1f ; dark
.Env5Colors:
db $00, $01, $02, $03, $04, $05, $06, $07 ; morn
db $08, $09, $0a, $0b, $0c, $0d, $0e, $0f ; day
db $10, $11, $12, $13, $14, $15, $16, $17 ; nite
db $18, $19, $1a, $1b, $1c, $1d, $1e, $1f ; dark
| 34.888889
| 84
| 0.555732
|
83b3f986c6bdd458cae2610bf7a7ad159526ea4e
| 466
|
asm
|
Assembly
|
arch/i386/hwid/hwdetect.asm
|
moondeck/hydrogen
|
5b98da9dac1ad85b3aaf98cc739a092350db6d1b
|
[
"Apache-2.0"
] | 6
|
2016-12-28T21:51:28.000Z
|
2021-02-15T18:48:40.000Z
|
arch/i386/hwid/hwdetect.asm
|
moondeck/hydrogen
|
5b98da9dac1ad85b3aaf98cc739a092350db6d1b
|
[
"Apache-2.0"
] | 7
|
2017-02-07T16:03:31.000Z
|
2018-01-02T19:41:21.000Z
|
arch/i386/hwid/hwdetect.asm
|
moondeck/hydrogen
|
5b98da9dac1ad85b3aaf98cc739a092350db6d1b
|
[
"Apache-2.0"
] | 2
|
2017-03-11T13:25:06.000Z
|
2018-03-25T15:35:48.000Z
|
[BITS 32]
global identify_cpu
identify_cpu:
mov esi, [ebp + 8] ;offset to the function argument
mov eax, 0x00
cpuid
mov [esi], ebx
add esi, 4
mov [esi], edx
add esi, 4
mov [esi], ecx
add esi, 4
inc esi
mov eax, 0x00
mov [esi], eax
add esi, 4
cpuid ;dont mov eax into anywhere, since eax is the return value
ret
get_hileaf:
mov eax, 0x00
cpuid
ret
get_brand:
done:
ret
| 11.948718
| 78
| 0.570815
|
07e5bade0c93b8d6f9d1babf2a2e342d49647428
| 742
|
asm
|
Assembly
|
oeis/206/A206927.asm
|
neoneye/loda-programs
|
84790877f8e6c2e821b183d2e334d612045d29c0
|
[
"Apache-2.0"
] | 11
|
2021-08-22T19:44:55.000Z
|
2022-03-20T16:47:57.000Z
|
oeis/206/A206927.asm
|
neoneye/loda-programs
|
84790877f8e6c2e821b183d2e334d612045d29c0
|
[
"Apache-2.0"
] | 9
|
2021-08-29T13:15:54.000Z
|
2022-03-09T19:52:31.000Z
|
oeis/206/A206927.asm
|
neoneye/loda-programs
|
84790877f8e6c2e821b183d2e334d612045d29c0
|
[
"Apache-2.0"
] | 3
|
2021-08-22T20:56:47.000Z
|
2021-09-29T06:26:12.000Z
|
; A206927: Minimal numbers of binary length n+1 such that the number of contiguous palindromic bit patterns in the binary representation is minimal.
; 2,4,9,18,37,75,150,300,601,1202,2405,4811,9622,19244,38489,76978,153957,307915,615830,1231660,2463321,4926642,9853285,19706571,39413142,78826284,157652569,315305138,630610277,1261220555,2522441110,5044882220,10089764441,20179528882,40359057765,80718115531,161436231062,322872462124,645744924249,1291489848498,2582979696997,5165959393995,10331918787990,20663837575980,41327675151961,82655350303922,165310700607845,330621401215691,661242802431382,1322485604862764,2644971209725529,5289942419451058
add $0,2
mov $1,33
lpb $0
sub $0,1
sub $1,1
mul $1,2
add $1,6
lpe
div $1,63
mov $0,$1
| 53
| 497
| 0.828841
|
9294fa94e7a0ea640d26244044b572a96a852489
| 2,653
|
asm
|
Assembly
|
programs/oeis/202/A202048.asm
|
karttu/loda
|
9c3b0fc57b810302220c044a9d17db733c76a598
|
[
"Apache-2.0"
] | null | null | null |
programs/oeis/202/A202048.asm
|
karttu/loda
|
9c3b0fc57b810302220c044a9d17db733c76a598
|
[
"Apache-2.0"
] | null | null | null |
programs/oeis/202/A202048.asm
|
karttu/loda
|
9c3b0fc57b810302220c044a9d17db733c76a598
|
[
"Apache-2.0"
] | null | null | null |
; A202048: Number of (n+2) X 6 binary arrays avoiding patterns 001 and 110 in rows and columns.
; 636,1968,4980,11016,22092,41088,71964,120000,192060,296880,445380,651000,930060,1302144,1790508,2422512,3230076,4250160,5525268,7103976,9041484,11400192,14250300,17670432,21748284,26581296,32277348,38955480,46746636,55794432,66255948,78302544,92120700,107912880,125898420,146314440,169416780,195480960,224803164,257701248,294515772,335611056,381376260,432226488,488603916,550978944,619851372,695751600,779241852,870917424,971407956,1081378728,1201531980,1332608256,1475387772,1630691808,1799384124,1982372400,2180609700,2395095960,2626879500,2877058560,3146782860,3437255184,3749732988,4085530032,4446018036,4832628360,5246853708,5690249856,6164437404,6671103552,7212003900,7788964272,8403882564,9058730616,9755556108,10496484480,11283720876,12119552112,13006348668,13946566704,14942750100,15997532520,17113639500,18293890560,19541201340,20858585760,22249158204,23716135728,25262840292,26892701016,28609256460,30416156928,32317166796,34316166864,36417156732,38624257200,40941712692,43373893704,45925299276,48600559488,51404437980,54341834496,57417787452,60637476528,64006225284,67529503800,71212931340,75062279040,79083472620,83282595120,87665889660,92239762224,97010784468,101985696552,107171409996,112575010560,118203761148,124065104736,130166667324,136516260912,143121886500,149991737112,157134200844,164557863936,172271513868,180284142480,188604949116,197243343792,206208950388,215511609864,225161383500,235168556160,245543639580,256297375680,267440739900,278984944560,290941442244,303321929208,316138348812,329402894976,343128015660,357326416368,372011063676,387195188784,402892291092,419116141800,435880787532,453200553984,471090049596,489564169248,508638097980,528327314736,548647596132,569615020248,591245970444,613557139200,636565531980,660288471120,684743599740,709948885680,735922625460,762683448264,790250319948,818642547072,847879780956,877982021760,908969622588,940863293616,973684106244,1007453497272,1042193273100,1077925613952,1114673078124,1152458606256,1191305525628,1231237554480,1272278806356,1314453794472,1357787436108,1402305057024,1448032395900,1494995608800,1543221273660,1592736394800,1643568407460,1695745182360,1749295030284,1804246706688,1860629416332,1918472817936,1977807028860,2038662629808,2101070669556,2165062669704,2230670629452,2297927030400,2366864841372,2437517523264,2509919033916,2584103833008,2660106886980,2737963673976,2817710188812,2899382947968,2983018994604,3068655903600,3156331786620,3246085297200
mov $1,5
mov $2,$0
add $2,3
add $1,$2
bin $1,6
add $1,1
mul $1,2
sub $1,$0
sub $1,58
mul $1,12
add $1,636
| 176.866667
| 2,449
| 0.892951
|
6d8209ee61c8ac04efa0b01bfb1f5122264049ef
| 1,843
|
asm
|
Assembly
|
Appl/Startup/BStartup/bsTimeDate.asm
|
steakknife/pcgeos
|
95edd7fad36df400aba9bab1d56e154fc126044a
|
[
"Apache-2.0"
] | 504
|
2018-11-18T03:35:53.000Z
|
2022-03-29T01:02:51.000Z
|
Appl/Startup/BStartup/bsTimeDate.asm
|
steakknife/pcgeos
|
95edd7fad36df400aba9bab1d56e154fc126044a
|
[
"Apache-2.0"
] | 96
|
2018-11-19T21:06:50.000Z
|
2022-03-06T10:26:48.000Z
|
Appl/Startup/BStartup/bsTimeDate.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: bsTimeDate.asm
AUTHOR: Steve Yegge, Jul 15, 1993
ROUTINES:
Name Description
---- -----------
REVISION HISTORY:
Name Date Description
---- ---- -----------
stevey 7/15/93 Initial revision
DESCRIPTION:
$Id: bsTimeDate.asm,v 1.1 97/04/04 16:53:07 newdeal Exp $
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%@
;-----------------------------------------------------------------------------
; CODE
;-----------------------------------------------------------------------------
PrefTDCode segment resource
COMMENT @%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
PrefTDDialogApply
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
SYNOPSIS: Handle "OK" in "Time/Date" section.
CALLED BY: MSG_TIME_DATE_APPLY
PASS: *ds:si - instance data
ds:di - *ds:si
es - seg addr of PrefTDDialogClass
ax - the message
RETURN: none
DESTROYED: bx, si, di, ds, es (method handler)
PSEUDO CODE/STRATEGY:
KNOWN BUGS/SIDE EFFECTS/IDEAS:
REVISION HISTORY:
Name Date Description
---- ---- -----------
gene 8/25/92 Initial version
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%@
BSTimeDateDialogApply method dynamic BSTimeDateDialogClass,
MSG_GEN_APPLY
mov di, offset BSTimeDateDialogClass
call ObjCallSuperNoLock
;
; Tell the primary we're done.
;
GetResourceHandleNS MyBSPrimary, bx
mov si, offset MyBSPrimary
mov di, mask MF_FORCE_QUEUE
mov ax, MSG_BS_PRIMARY_DONE_DATE_TIME
GOTO ObjMessage
BSTimeDateDialogApply endm
PrefTDCode ends
| 23.935065
| 79
| 0.473142
|
730d8f2df1b1de0702061feb0f3cae2d25f5c260
| 63
|
asm
|
Assembly
|
data/maps/headers/Route2Gate.asm
|
opiter09/ASM-Machina
|
75d8e457b3e82cc7a99b8e70ada643ab02863ada
|
[
"CC0-1.0"
] | 1
|
2022-02-15T00:19:44.000Z
|
2022-02-15T00:19:44.000Z
|
data/maps/headers/Route2Gate.asm
|
opiter09/ASM-Machina
|
75d8e457b3e82cc7a99b8e70ada643ab02863ada
|
[
"CC0-1.0"
] | null | null | null |
data/maps/headers/Route2Gate.asm
|
opiter09/ASM-Machina
|
75d8e457b3e82cc7a99b8e70ada643ab02863ada
|
[
"CC0-1.0"
] | null | null | null |
map_header Route2Gate, ROUTE_2_GATE, GATE, 0
end_map_header
| 15.75
| 45
| 0.809524
|
83295b8c54cff8666f04d21c1a48431e03b516a3
| 2,215
|
asm
|
Assembly
|
programs/oeis/158/A158413.asm
|
karttu/loda
|
9c3b0fc57b810302220c044a9d17db733c76a598
|
[
"Apache-2.0"
] | 1
|
2021-03-15T11:38:20.000Z
|
2021-03-15T11:38:20.000Z
|
programs/oeis/158/A158413.asm
|
karttu/loda
|
9c3b0fc57b810302220c044a9d17db733c76a598
|
[
"Apache-2.0"
] | null | null | null |
programs/oeis/158/A158413.asm
|
karttu/loda
|
9c3b0fc57b810302220c044a9d17db733c76a598
|
[
"Apache-2.0"
] | null | null | null |
; A158413: 961n^2 + 2n.
; 963,3848,8655,15384,24035,34608,47103,61520,77859,96120,116303,138408,162435,188384,216255,246048,277763,311400,346959,384440,423843,465168,508415,553584,600675,649688,700623,753480,808259,864960,923583,984128,1046595,1110984,1177295,1245528,1315683,1387760,1461759,1537680,1615523,1695288,1776975,1860584,1946115,2033568,2122943,2214240,2307459,2402600,2499663,2598648,2699555,2802384,2907135,3013808,3122403,3232920,3345359,3459720,3576003,3694208,3814335,3936384,4060355,4186248,4314063,4443800,4575459,4709040,4844543,4981968,5121315,5262584,5405775,5550888,5697923,5846880,5997759,6150560,6305283,6461928,6620495,6780984,6943395,7107728,7273983,7442160,7612259,7784280,7958223,8134088,8311875,8491584,8673215,8856768,9042243,9229640,9418959,9610200,9803363,9998448,10195455,10394384,10595235,10798008,11002703,11209320,11417859,11628320,11840703,12055008,12271235,12489384,12709455,12931448,13155363,13381200,13608959,13838640,14070243,14303768,14539215,14776584,15015875,15257088,15500223,15745280,15992259,16241160,16491983,16744728,16999395,17255984,17514495,17774928,18037283,18301560,18567759,18835880,19105923,19377888,19651775,19927584,20205315,20484968,20766543,21050040,21335459,21622800,21912063,22203248,22496355,22791384,23088335,23387208,23688003,23990720,24295359,24601920,24910403,25220808,25533135,25847384,26163555,26481648,26801663,27123600,27447459,27773240,28100943,28430568,28762115,29095584,29430975,29768288,30107523,30448680,30791759,31136760,31483683,31832528,32183295,32535984,32890595,33247128,33605583,33965960,34328259,34692480,35058623,35426688,35796675,36168584,36542415,36918168,37295843,37675440,38056959,38440400,38825763,39213048,39602255,39993384,40386435,40781408,41178303,41577120,41977859,42380520,42785103,43191608,43600035,44010384,44422655,44836848,45252963,45671000,46090959,46512840,46936643,47362368,47790015,48219584,48651075,49084488,49519823,49957080,50396259,50837360,51280383,51725328,52172195,52620984,53071695,53524328,53978883,54435360,54893759,55354080,55816323,56280488,56746575,57214584,57684515,58156368,58630143,59105840,59583459,60063000
mul $0,961
add $0,1
mov $1,961
add $1,$0
pow $1,2
sub $1,925444
div $1,961
add $1,963
| 184.583333
| 2,103
| 0.866366
|
0063dd3c6e3f70417d390d2434530a8f6d08b880
| 3,591
|
asm
|
Assembly
|
Chapter07/structures_win.asm
|
PacktPublishing/Mastering-Assembly-Programming
|
f5de70a911021e3e5189864cec8dc1ddfa103d24
|
[
"MIT"
] | 34
|
2019-07-10T00:32:25.000Z
|
2022-03-20T16:32:08.000Z
|
Chapter07/structures_win.asm
|
PacktPublishing/Mastering-Assembly-Programming
|
f5de70a911021e3e5189864cec8dc1ddfa103d24
|
[
"MIT"
] | null | null | null |
Chapter07/structures_win.asm
|
PacktPublishing/Mastering-Assembly-Programming
|
f5de70a911021e3e5189864cec8dc1ddfa103d24
|
[
"MIT"
] | 4
|
2020-04-13T01:23:51.000Z
|
2021-09-21T03:17:00.000Z
|
; File: src\template_win.asm
; First of all, we tell the compiler which type of executable
; we want it to be. In our case it is a 32-bit PE executable.
format PE GUI
; Tell the compiler where we want our program to start - define
; the entry point. We want it to be at the place labeled with '_start'.
entry _start
; The following line includes a set of macros, shipped with FASM,
; which are essential for Windows program. We can, of course, implement
; all we need ourselves, and we will do that in chapter 9.
include 'win32a.inc'
; PE file consists of at least one section. In this template we only need 3:
; 1. '.text' - section that contains executable code
; 2. '.data' - section that contains data
; 3. '.idata' - section that contains import information
;
; '.text' section: contains code, is readable, is executable
section '.text' code readable executable
struc strtabentry [s]
{
.length dw .pad - .string
.string db s, 0
.pad rb 30 - (.pad - .string)
.previous dd ?
.next dd ?
.size = $ - .length
}
macro make_links baseAddr
{
local b
b = baseAddr
store dword b + 80 at b + 36
store dword b + 120 at b + 80 + 36
store dword b + 40 at b + 120 + 36
store dword b + 120 at b + 40 + 32
store dword b + 80 at b + 120 + 32
store dword b at b + 80 + 32
}
macro make_strtab strtabName, [strings]
{
common
label strtabName#_ptr dword
local c
c = 0
forward
c = c + 1
common
dd c
forward
local a
dd a
common
label strtabName dword
forward
a strtabentry strings
}
get_string_length:
push ebp
mov ebp, esp
push ebx ecx
virtual at ebp + 8
.structPtr dd ?
.structIdx dd ?
end virtual
virtual at ebx + ecx
.s strtabentry ?
end virtual
mov ebx, [.structPtr]
mov ecx, [.structIdx]
shl ecx, 5
mov ax, [.s.length]
movzx eax, ax
dec eax
pop ecx ebx
leave
ret 8
add_node:
push ebp
mov ebp, esp
push eax ebx ecx
virtual at ebp + 8
.topPtr dd ?
.nodePtr dd ?
end virtual
virtual at ebx
.s0 strtabentry ?
end virtual
virtual at ecx
.s1 strtabentry ?
end virtual
mov eax, [.topPtr]
mov ebx, [.nodePtr]
or dword[eax],0
jz @f
mov .s1, [eax]
mov [.s0.next], ecx
mov [.s1.previous], ebx
@@:
mov [eax], ebx
pop ecx ebx eax
leave
ret 8
; Entry point
_start:
push strtab + 40
push list_top
call add_node
push strtab + 120
push list_top
call add_node
push strtab + 80
push list_top
call add_node
push strtab
push list_top
call add_node
nop
; We have to terminate the process properly
; Put return code on stack
push 0
; Call ExitProcess Windows API function
call [exitProcess]
; '.data' section: contains data, is readable, may be writeable
section '.data' data readable writeable
;
; Put your data here
;
dd 0
make_strtab strtab,\
"string 0",\
"string 1 ",\
"string 2 ",\
"string 3 "
list_top dd 0
;make_links strtab
; '.idata' section: contains import information, is readable, is writeable
section '.idata' import data readable writeable
; 'library' macro from 'win32a.inc' creates proper entry for importing
; functions from a dynamic link library. For now it is only 'kernel32.dll'.
library kernel, 'kernel32.dll'
; 'import' macro creates the actual entries for functions we want to import from a dynamic link library
import kernel,\
exitProcess, 'ExitProcess'
| 19.622951
| 104
| 0.639655
|
df9bc4b078611d41fb103a286b8d20929a1c167d
| 114
|
asm
|
Assembly
|
test/test.asm
|
richRemer/atlatl
|
169c0c9c29d277dc1295e6c37b0963af6e02741a
|
[
"MIT"
] | null | null | null |
test/test.asm
|
richRemer/atlatl
|
169c0c9c29d277dc1295e6c37b0963af6e02741a
|
[
"MIT"
] | null | null | null |
test/test.asm
|
richRemer/atlatl
|
169c0c9c29d277dc1295e6c37b0963af6e02741a
|
[
"MIT"
] | null | null | null |
global _start
extern test_case
extern sys.exit
section .text
_start:
call test_case
call sys.exit
| 11.4
| 21
| 0.710526
|
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.