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 |
|---|---|---|---|---|
oeis/131/A131569.asm | neoneye/loda-programs | 11 | 244834 | ; A131569: a(n) = (1/2)*(F(n+2)-1)*(F(n+2)-2) + F(n), where F() are the Fibonacci numbers.
; Submitted by <NAME>
; 1,2,8,24,71,198,541,1452,3862,10208,26885,70644,185369,485982,1273420,3335640,8735707,22875050,59895221,156819960,410579786,1074943872,2814291433,7367994504,19289795761,50501560538,132215157296,346144350552,906218605007,2372512614318,6211321098445,16261453691364,42573044846494,111457688729312,291800034093485,763942434184380,2000027301844937,5236139525368950,13708391361665716,35889034701050520,93958712970311971,245987104580133842,644002601369164133,1686020700496681584,4414059501689278226
add $0,1
lpb $0
add $2,1
mov $4,$0
sub $0,1
cmp $3,$2
sub $3,$1
cmp $4,0
sub $4,1
mul $5,$4
add $5,1
sub $5,$3
add $1,$5
lpe
bin $1,2
add $1,$5
mov $0,$1
|
src/main/java/com/talentica/dsl/antlr/Calculator.g4 | Talentica/antlrDemo | 0 | 2686 | grammar Calculator;
@header{
package com.talentica.dsl.antlr;
}
// PARSER
program
: statement* expression;
expression
: '(' expression ')' # parenExpression
| expression ('*'|'/') expression # multOrDiv
| expression ('+'|'-') expression # addOrSubtract
| ID # idExpression
| DOUBLE # doubleExpression;
statement
: ID '=' expression;
// LEXER
ID : ('_'|'a'..'z'|'A'..'Z')('_'|'a'..'z'|'A'..'Z'|'0'..'9')*;
DOUBLE : '0'..'9'*[\.]'0'..'9'+|'0'..'9'+([\.]'0'..'9'*)?;
COMMENT : ('#'.*?[\n]) -> skip;
WS : [ \t\r\n]+ -> skip;
|
sw/552tests/rand_simple/t_4_slli.asm | JPShen-UWM/ThreadKraken | 1 | 288 | // seed 4
lbi r0, 246 // icount 0
slbi r0, 223 // icount 1
lbi r1, 105 // icount 2
slbi r1, 105 // icount 3
lbi r2, 23 // icount 4
slbi r2, 20 // icount 5
lbi r3, 164 // icount 6
slbi r3, 222 // icount 7
lbi r4, 176 // icount 8
slbi r4, 66 // icount 9
lbi r5, 203 // icount 10
slbi r5, 226 // icount 11
lbi r6, 165 // icount 12
slbi r6, 211 // icount 13
lbi r7, 180 // icount 14
slbi r7, 106 // icount 15
slli r6, r0, 0 // icount 16
slli r3, r2, 2 // icount 17
slli r4, r4, 12 // icount 18
slli r2, r0, 0 // icount 19
slli r7, r1, 2 // icount 20
slli r7, r2, 4 // icount 21
slli r3, r7, 5 // icount 22
slli r4, r2, 12 // icount 23
slli r0, r2, 1 // icount 24
slli r7, r2, 3 // icount 25
slli r1, r7, 6 // icount 26
slli r1, r7, 14 // icount 27
slli r3, r5, 6 // icount 28
slli r1, r5, 0 // icount 29
slli r6, r7, 14 // icount 30
slli r5, r7, 12 // icount 31
halt // icount 32
|
src/tk/tk-image-photo.adb | thindil/tashy2 | 2 | 14129 | <gh_stars>1-10
-- Copyright (c) 2021 <NAME> <<EMAIL>>
--
-- Licensed 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.
with Ada.Characters.Handling;
with Ada.Strings; use Ada.Strings;
with Ada.Strings.Fixed; use Ada.Strings.Fixed;
with Ada.Strings.Unbounded; use Ada.Strings.Unbounded;
package body Tk.Image.Photo is
function Options_To_String(Options: Photo_Options) return String is
Options_String: Unbounded_String := Null_Unbounded_String;
begin
Option_Image
(Name => "data", Value => Options.Data,
Options_String => Options_String);
Option_Image
(Name => "format", Value => Options.Format,
Options_String => Options_String);
Option_Image
(Name => "file", Value => Options.File,
Options_String => Options_String);
Option_Image
(Name => "gamma", Value => Options.Gamma,
Options_String => Options_String);
Option_Image
(Name => "height", Value => Options.Height,
Options_String => Options_String);
if Options.Palette /= Empty_Shades then
if Options.Palette.Grayscale then
Append
(Source => Options_String,
New_Item =>
" -palette" & Shades_Range'Image(Options.Palette.Gray));
else
Append
(Source => Options_String,
New_Item =>
" -palette" & Shades_Range'Image(Options.Palette.Red) & "/" &
Trim
(Source => Shades_Range'Image(Options.Palette.Green),
Side => Left) &
"/" &
Trim
(Source => Shades_Range'Image(Options.Palette.Blue),
Side => Left));
end if;
end if;
Option_Image
(Name => "width", Value => Options.Width,
Options_String => Options_String);
return To_String(Source => Options_String);
end Options_To_String;
procedure Create
(Photo_Image: Tk_Image; Options: Photo_Options;
Interpreter: Tcl_Interpreter := Get_Interpreter) is
begin
Tcl_Eval
(Tcl_Script =>
"image create photo " & Photo_Image &
Options_To_String(Options => Options),
Interpreter => Interpreter);
end Create;
function Create
(Options: Photo_Options; Interpreter: Tcl_Interpreter := Get_Interpreter)
return Tk_Image is
begin
return
Tcl_Eval
(Tcl_Script =>
"image create photo" & Options_To_String(Options => Options),
Interpreter => Interpreter)
.Result;
end Create;
procedure Blank
(Photo_Image: Tk_Image;
Interpreter: Tcl_Interpreter := Get_Interpreter) is
begin
Tcl_Eval
(Tcl_Script => Photo_Image & " blank", Interpreter => Interpreter);
end Blank;
procedure Configure
(Photo_Image: Tk_Image; Options: Photo_Options;
Interpreter: Tcl_Interpreter := Get_Interpreter) is
begin
Tcl_Eval
(Tcl_Script =>
Photo_Image & " configure " & Options_To_String(Options => Options),
Interpreter => Interpreter);
end Configure;
function Get_Option
(Photo_Image: Tk_Image; Name: String;
Interpreter: Tcl_Interpreter := Get_Interpreter) return String is
Result_List: constant Array_List :=
Split_List
(List =>
Tcl_Eval
(Tcl_Script => Photo_Image & " configure -" & Name,
Interpreter => Interpreter)
.Result,
Interpreter => Interpreter);
begin
return To_Ada_String(Source => Result_List(Result_List'Last));
end Get_Option;
function Get_Options
(Photo_Image: Tk_Image; Interpreter: Tcl_Interpreter := Get_Interpreter)
return Photo_Options is
Result: constant String :=
Get_Option
(Photo_Image => Photo_Image, Name => "palette",
Interpreter => Interpreter);
Slash_Index: constant Natural := Index(Source => Result, Pattern => "/");
begin
return Options: Photo_Options := Default_Photo_Options do
Options.Data :=
To_Tcl_String
(Source =>
Get_Option
(Photo_Image => Photo_Image, Name => "data",
Interpreter => Interpreter));
Options.File :=
To_Tcl_String
(Source =>
Get_Option
(Photo_Image => Photo_Image, Name => "file",
Interpreter => Interpreter));
Options.Format :=
To_Tcl_String
(Source =>
Get_Option
(Photo_Image => Photo_Image, Name => "format",
Interpreter => Interpreter));
Options.Gamma :=
Positive_Float'Value
(Get_Option
(Photo_Image => Photo_Image, Name => "gamma",
Interpreter => Interpreter));
Options.Height :=
Natural'Value
(Get_Option
(Photo_Image => Photo_Image, Name => "height",
Interpreter => Interpreter));
Options.Width :=
Natural'Value
(Get_Option
(Photo_Image => Photo_Image, Name => "width",
Interpreter => Interpreter));
--## rule off IMPROPER_INITIALIZATION
Get_Palette_Block :
declare
Result_Palette: Shades_Type
(Grayscale => (if Slash_Index = 0 then True else False));
begin
if Slash_Index = 0 then
if Result'Length > 0 then
Result_Palette.Gray := Shades_Range'Value(Result);
else
Result_Palette.Gray := -1;
end if;
else
Result_Palette.Red :=
Shades_Range'Value(Result(Result'First .. Slash_Index - 1));
Result_Palette.Green :=
Shades_Range'Value
(Result
(Slash_Index + 1 ..
Index
(Source => Result, Pattern => "/",
From => Slash_Index + 1) -
1));
Result_Palette.Blue :=
Shades_Range'Value
(Result
(Index
(Source => Result, Pattern => "/",
Going => Backward) +
1 ..
Result'Last));
end if;
Options.Palette := Result_Palette;
end Get_Palette_Block;
--## rule on IMPROPER_INITIALIZATION
end return;
end Get_Options;
procedure Dimension_To_String
(Name: String; Value: Dimensions_Type;
Options: in out Unbounded_String) is
begin
if Value /= Empty_Dimension then
Append
(Source => Options,
New_Item =>
" -" & Name & Natural'Image(Value.Start_X) &
Natural'Image(Value.Start_Y));
if Value.End_X > -1 then
Append
(Source => Options,
New_Item =>
Extended_Natural'Image(Value.End_X) &
Extended_Natural'Image(Value.End_Y));
end if;
end if;
end Dimension_To_String;
procedure Copy
(Destination_Image, Source_Image: Tk_Image;
From, To: Dimensions_Type := Empty_Dimension; Shrink: Boolean := False;
Zoom, Sub_Sample: Point_Position := Empty_Point_Position;
Compositing_Rule: Compositing_Types := NONE;
Interpreter: Tcl_Interpreter := Get_Interpreter) is
use Ada.Characters.Handling;
Options: Unbounded_String := Null_Unbounded_String;
begin
Dimension_To_String(Name => "from", Value => From, Options => Options);
Dimension_To_String(Name => "to", Value => To, Options => Options);
Option_Image
(Name => "shrink", Value => Shrink, Options_String => Options);
Option_Image(Name => "zoom", Value => Zoom, Options_String => Options);
Option_Image
(Name => "subsample", Value => Sub_Sample, Options_String => Options);
if Compositing_Rule /= NONE then
Append
(Source => Options,
New_Item =>
" -compositingrule " &
To_Lower(Item => Compositing_Types'Image(Compositing_Rule)));
end if;
Tcl_Eval
(Tcl_Script =>
Destination_Image & " copy " & Source_Image &
To_String(Source => Options),
Interpreter => Interpreter);
end Copy;
function Get_Data
(Photo_Image: Tk_Image; Background, Format: Tcl_String := Null_Tcl_String;
From: Dimensions_Type := Empty_Dimension; Grayscale: Boolean := False;
Interpreter: Tcl_Interpreter := Get_Interpreter) return Tcl_String is
Options: Unbounded_String := Null_Unbounded_String;
begin
Option_Image
(Name => "background", Value => Background, Options_String => Options);
Option_Image
(Name => "format", Value => Format, Options_String => Options);
Dimension_To_String(Name => "from", Value => From, Options => Options);
Option_Image
(Name => "grayscale", Value => Grayscale, Options_String => Options);
return
To_Tcl_String
(Source =>
Tcl_Eval
(Tcl_Script =>
Photo_Image & " data" & To_String(Source => Options),
Interpreter => Interpreter)
.Result);
end Get_Data;
function Get_Color
(Photo_Image: Tk_Image; X, Y: Natural;
Interpreter: Tcl_Interpreter := Get_Interpreter) return Color_Type is
Result_List: constant Array_List :=
Split_List
(List =>
Tcl_Eval
(Tcl_Script =>
Photo_Image & " get" & Natural'Image(X) & Natural'Image(Y),
Interpreter => Interpreter)
.Result,
Interpreter => Interpreter);
begin
return
(Red => Color_Range'Value(To_Ada_String(Source => Result_List(1))),
Green => Color_Range'Value(To_Ada_String(Source => Result_List(2))),
Blue => Color_Range'Value(To_Ada_String(Source => Result_List(3))));
end Get_Color;
procedure Put_Data
(Photo_Image: Tk_Image; Data: Tcl_String;
Format: Tcl_String := Null_Tcl_String;
To: Dimensions_Type := Empty_Dimension;
Interpreter: Tcl_Interpreter := Get_Interpreter) is
Options: Unbounded_String := Null_Unbounded_String;
begin
Option_Image
(Name => "format", Value => Format, Options_String => Options);
Dimension_To_String(Name => "to", Value => To, Options => Options);
Tcl_Eval
(Tcl_Script =>
Photo_Image & " put " & To_String(Source => Data) & " " &
To_String(Source => Options),
Interpreter => Interpreter);
end Put_Data;
procedure Read
(Photo_Image: Tk_Image; File_Name: Tcl_String;
Format: Tcl_String := Null_Tcl_String;
From: Dimensions_Type := Empty_Dimension; Shrink: Boolean := False;
To: Point_Position := Empty_Point_Position;
Interpreter: Tcl_Interpreter := Get_Interpreter) is
Options: Unbounded_String := Null_Unbounded_String;
begin
Option_Image
(Name => "format", Value => Format, Options_String => Options);
Dimension_To_String(Name => "from", Value => From, Options => Options);
Option_Image
(Name => "shrink", Value => Shrink, Options_String => Options);
Option_Image(Name => "to", Value => To, Options_String => Options);
Tcl_Eval
(Tcl_Script =>
Photo_Image & " read " & To_String(Source => File_Name) & " " &
To_String(Source => Options),
Interpreter => Interpreter);
end Read;
procedure Redither
(Photo_Image: Tk_Image;
Interpreter: Tcl_Interpreter := Get_Interpreter) is
begin
Tcl_Eval
(Tcl_Script => Photo_Image & " redither", Interpreter => Interpreter);
end Redither;
function Get_Transparency
(Photo_Image: Tk_Image; X, Y: Natural;
Interpreter: Tcl_Interpreter := Get_Interpreter)
return Tcl_Boolean_Result is
begin
return
Tcl_Eval
(Tcl_Script =>
Photo_Image & " transparency get" & Natural'Image(X) &
Natural'Image(Y),
Interpreter => Interpreter);
end Get_Transparency;
procedure Set_Transparency
(Photo_Image: Tk_Image; X, Y: Natural; Transparent: Boolean;
Interpreter: Tcl_Interpreter := Get_Interpreter) is
begin
Tcl_Eval
(Tcl_Script =>
Photo_Image & " transparency set" & Natural'Image(X) &
Natural'Image(Y) & " " & (if Transparent then "1" else "0"),
Interpreter => Interpreter);
end Set_Transparency;
procedure Write
(Photo_Image: Tk_Image; File_Name: Tcl_String;
Background, Format: Tcl_String := Null_Tcl_String;
From: Dimensions_Type := Empty_Dimension; Grayscale: Boolean := False;
Interpreter: Tcl_Interpreter := Get_Interpreter) is
Options: Unbounded_String := Null_Unbounded_String;
begin
Option_Image
(Name => "background", Value => Background, Options_String => Options);
Option_Image
(Name => "format", Value => Format, Options_String => Options);
Dimension_To_String(Name => "from", Value => From, Options => Options);
Option_Image
(Name => "grayscale", Value => Grayscale, Options_String => Options);
Tcl_Eval
(Tcl_Script =>
Photo_Image & " write " & To_String(Source => File_Name) &
To_String(Source => Options),
Interpreter => Interpreter);
end Write;
end Tk.Image.Photo;
|
src/main/antlr/SlateParser.g4 | agmcc/slate-lang | 1 | 2699 | parser grammar SlateParser;
options { tokenVocab=SlateLexer; }
compilationUnit: methodDeclaration* EOF;
methodDeclaration: ID (L_PAREN parameter (COMMA parameter)* R_PAREN)? (COLON returnType=type)? statement;
parameter: type ID;
type: (INT|DEC|STRING|BOOL)(ARRAY)?;
statement: expression # expressionStatement
| ret # returnStatement
| varDeclaration # varDeclarationStatement
| assignment # assignmentStatement
| print # printStatement
| block # blockStatement
| condition # conditionStatement
| whileLoop # whileLoopStatement
| forLoop # forLoopStatement;
print: PRINT expression;
varDeclaration: VAR assignment;
assignment: ID ASSIGN expression;
block: L_BRACE statement* R_BRACE;
condition: IF expression trueStatement=statement (ELSE falseStatement=statement)?;
whileLoop: WHILE expression body=statement;
forLoop: FOR declaration=statement check=expression after=expression body=statement # forTraditional;
ret: RETURN (value=expression)?;
expression: left=expression operator=(DIV|MUL) right=expression # binaryOperation
| left=expression operator=(ADD|SUB) right=expression # binaryOperation
| left=expression operator=(GREATER|GREATER_EQ|EQUAL|NOT_EQUAL|LESS|LESS_EQ|AND|OR) right=expression # binaryOperation
| L_PAREN expression R_PAREN # parenExpression
| ID L_PAREN (expression (COMMA expression)*)? R_PAREN # methodInvocation
| ID # varReference
| STRING_LIT # stringLiteral
| INT_LIT # intLiteral
| DEC_LIT # decimalLiteral
| (TRUE_LIT|FALSE_LIT) # booleanLiteral
| INCREMENT ID # preIncrement
| ID INCREMENT # postIncrement
| DECREMENT ID # preDecrement
| ID DECREMENT # postDecrement;
|
.build/ada/asis-gela-elements-expr.ads | faelys/gela-asis | 4 | 390 | <reponame>faelys/gela-asis<filename>.build/ada/asis-gela-elements-expr.ads
------------------------------------------------------------------------------
-- Copyright (c) 2006-2013, <NAME>
-- All rights reserved.
--
-- Redistribution and use in source and binary forms, with or without
-- modification, are permitted provided that the following conditions are met:
--
-- * Redistributions of source code must retain the above copyright notice,
-- this list of conditions and the following disclaimer.
-- * Redistributions in binary form must reproduce the above copyright
-- notice, this list of conditions and the following disclaimer in the
-- documentation and/or other materials provided with the distribution.
-- * Neither the name of the Maxim Reznik, IE 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 OWNER 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.
------------------------------------------------------------------------------
package Asis.Gela.Elements.Expr is
-------------------------
-- Box_Expression_Node --
-------------------------
type Box_Expression_Node is
new Expression_Node with private;
type Box_Expression_Ptr is
access all Box_Expression_Node;
for Box_Expression_Ptr'Storage_Pool use Lists.Pool;
function New_Box_Expression_Node
(The_Context : ASIS.Context)
return Box_Expression_Ptr;
function Expression_Kind (Element : Box_Expression_Node)
return Asis.Expression_Kinds;
function Clone
(Element : Box_Expression_Node;
Parent : Asis.Element)
return Asis.Element;
-----------------------
-- Base_Literal_Node --
-----------------------
type Base_Literal_Node is abstract
new Expression_Node with private;
type Base_Literal_Ptr is
access all Base_Literal_Node;
for Base_Literal_Ptr'Storage_Pool use Lists.Pool;
function Value_Image
(Element : Base_Literal_Node) return Wide_String;
procedure Set_Value_Image
(Element : in out Base_Literal_Node;
Value : in Wide_String);
--------------------------
-- Integer_Literal_Node --
--------------------------
type Integer_Literal_Node is
new Base_Literal_Node with private;
type Integer_Literal_Ptr is
access all Integer_Literal_Node;
for Integer_Literal_Ptr'Storage_Pool use Lists.Pool;
function New_Integer_Literal_Node
(The_Context : ASIS.Context)
return Integer_Literal_Ptr;
function Expression_Kind (Element : Integer_Literal_Node)
return Asis.Expression_Kinds;
function Clone
(Element : Integer_Literal_Node;
Parent : Asis.Element)
return Asis.Element;
-----------------------
-- Real_Literal_Node --
-----------------------
type Real_Literal_Node is
new Base_Literal_Node with private;
type Real_Literal_Ptr is
access all Real_Literal_Node;
for Real_Literal_Ptr'Storage_Pool use Lists.Pool;
function New_Real_Literal_Node
(The_Context : ASIS.Context)
return Real_Literal_Ptr;
function Expression_Kind (Element : Real_Literal_Node)
return Asis.Expression_Kinds;
function Clone
(Element : Real_Literal_Node;
Parent : Asis.Element)
return Asis.Element;
-------------------------
-- String_Literal_Node --
-------------------------
type String_Literal_Node is
new Base_Literal_Node with private;
type String_Literal_Ptr is
access all String_Literal_Node;
for String_Literal_Ptr'Storage_Pool use Lists.Pool;
function New_String_Literal_Node
(The_Context : ASIS.Context)
return String_Literal_Ptr;
function Expression_Kind (Element : String_Literal_Node)
return Asis.Expression_Kinds;
function Clone
(Element : String_Literal_Node;
Parent : Asis.Element)
return Asis.Element;
--------------------------
-- Base_Identifier_Node --
--------------------------
type Base_Identifier_Node is abstract
new Expression_Node with private;
type Base_Identifier_Ptr is
access all Base_Identifier_Node;
for Base_Identifier_Ptr'Storage_Pool use Lists.Pool;
function Name_Image
(Element : Base_Identifier_Node) return Wide_String;
procedure Set_Name_Image
(Element : in out Base_Identifier_Node;
Value : in Wide_String);
function Corresponding_Name_Declaration
(Element : Base_Identifier_Node) return Asis.Declaration;
procedure Set_Corresponding_Name_Declaration
(Element : in out Base_Identifier_Node;
Value : in Asis.Declaration);
function Corresponding_Name_Definition_List
(Element : Base_Identifier_Node;
Include_Pragmas : in Boolean := False) return Asis.Element_List;
procedure Add_To_Corresponding_Name_Definition_List
(Element : in out Base_Identifier_Node;
Item : in Asis.Element);
function Corresponding_Generic_Element
(Element : Base_Identifier_Node) return Asis.Defining_Name;
procedure Set_Corresponding_Generic_Element
(Element : in out Base_Identifier_Node;
Value : in Asis.Defining_Name);
---------------------
-- Identifier_Node --
---------------------
type Identifier_Node is
new Base_Identifier_Node with private;
type Identifier_Ptr is
access all Identifier_Node;
for Identifier_Ptr'Storage_Pool use Lists.Pool;
function New_Identifier_Node
(The_Context : ASIS.Context)
return Identifier_Ptr;
function Expression_Kind (Element : Identifier_Node)
return Asis.Expression_Kinds;
function Clone
(Element : Identifier_Node;
Parent : Asis.Element)
return Asis.Element;
--------------------------
-- Operator_Symbol_Node --
--------------------------
type Operator_Symbol_Node is
new Base_Identifier_Node with private;
type Operator_Symbol_Ptr is
access all Operator_Symbol_Node;
for Operator_Symbol_Ptr'Storage_Pool use Lists.Pool;
function New_Operator_Symbol_Node
(The_Context : ASIS.Context)
return Operator_Symbol_Ptr;
function Operator_Kind
(Element : Operator_Symbol_Node) return Asis.Operator_Kinds;
procedure Set_Operator_Kind
(Element : in out Operator_Symbol_Node;
Value : in Asis.Operator_Kinds);
function Expression_Kind (Element : Operator_Symbol_Node)
return Asis.Expression_Kinds;
function Clone
(Element : Operator_Symbol_Node;
Parent : Asis.Element)
return Asis.Element;
----------------------------
-- Character_Literal_Node --
----------------------------
type Character_Literal_Node is
new Base_Identifier_Node with private;
type Character_Literal_Ptr is
access all Character_Literal_Node;
for Character_Literal_Ptr'Storage_Pool use Lists.Pool;
function New_Character_Literal_Node
(The_Context : ASIS.Context)
return Character_Literal_Ptr;
function Expression_Kind (Element : Character_Literal_Node)
return Asis.Expression_Kinds;
function Clone
(Element : Character_Literal_Node;
Parent : Asis.Element)
return Asis.Element;
------------------------------
-- Enumeration_Literal_Node --
------------------------------
type Enumeration_Literal_Node is
new Base_Identifier_Node with private;
type Enumeration_Literal_Ptr is
access all Enumeration_Literal_Node;
for Enumeration_Literal_Ptr'Storage_Pool use Lists.Pool;
function New_Enumeration_Literal_Node
(The_Context : ASIS.Context)
return Enumeration_Literal_Ptr;
function Expression_Kind (Element : Enumeration_Literal_Node)
return Asis.Expression_Kinds;
function Clone
(Element : Enumeration_Literal_Node;
Parent : Asis.Element)
return Asis.Element;
-------------------------------
-- Explicit_Dereference_Node --
-------------------------------
type Explicit_Dereference_Node is
new Expression_Node with private;
type Explicit_Dereference_Ptr is
access all Explicit_Dereference_Node;
for Explicit_Dereference_Ptr'Storage_Pool use Lists.Pool;
function New_Explicit_Dereference_Node
(The_Context : ASIS.Context)
return Explicit_Dereference_Ptr;
function Prefix
(Element : Explicit_Dereference_Node) return Asis.Expression;
procedure Set_Prefix
(Element : in out Explicit_Dereference_Node;
Value : in Asis.Expression);
function Expression_Kind (Element : Explicit_Dereference_Node)
return Asis.Expression_Kinds;
function Children (Element : access Explicit_Dereference_Node)
return Traverse_List;
function Clone
(Element : Explicit_Dereference_Node;
Parent : Asis.Element)
return Asis.Element;
procedure Copy
(Source : in Asis.Element;
Target : access Explicit_Dereference_Node;
Cloner : in Cloner_Class;
Parent : in Asis.Element);
------------------------
-- Function_Call_Node --
------------------------
type Function_Call_Node is
new Expression_Node with private;
type Function_Call_Ptr is
access all Function_Call_Node;
for Function_Call_Ptr'Storage_Pool use Lists.Pool;
function New_Function_Call_Node
(The_Context : ASIS.Context)
return Function_Call_Ptr;
function Prefix
(Element : Function_Call_Node) return Asis.Expression;
procedure Set_Prefix
(Element : in out Function_Call_Node;
Value : in Asis.Expression);
function Is_Prefix_Call
(Element : Function_Call_Node) return Boolean;
procedure Set_Is_Prefix_Call
(Element : in out Function_Call_Node;
Value : in Boolean);
function Is_Dispatching_Call
(Element : Function_Call_Node) return Boolean;
procedure Set_Is_Dispatching_Call
(Element : in out Function_Call_Node;
Value : in Boolean);
function Corresponding_Called_Function
(Element : Function_Call_Node) return Asis.Declaration;
procedure Set_Corresponding_Called_Function
(Element : in out Function_Call_Node;
Value : in Asis.Declaration);
function Function_Call_Parameters
(Element : Function_Call_Node;
Include_Pragmas : in Boolean := False) return Asis.Element_List;
procedure Set_Function_Call_Parameters
(Element : in out Function_Call_Node;
Value : in Asis.Element);
function Function_Call_Parameters_List
(Element : Function_Call_Node) return Asis.Element;
function Normalized_Function_Call_Parameters
(Element : Function_Call_Node;
Include_Pragmas : in Boolean := False) return Asis.Element_List;
procedure Add_To_Normalized_Function_Call_Parameters
(Element : in out Function_Call_Node;
Item : in Asis.Element);
function Is_Call_On_Dispatching_Operation
(Element : Function_Call_Node) return Boolean;
procedure Set_Is_Call_On_Dispatching_Operation
(Element : in out Function_Call_Node;
Value : in Boolean);
function Record_Aggregate
(Element : Function_Call_Node) return Asis.Element;
procedure Set_Record_Aggregate
(Element : in out Function_Call_Node;
Value : in Asis.Element);
function Expression_Kind (Element : Function_Call_Node)
return Asis.Expression_Kinds;
function Children (Element : access Function_Call_Node)
return Traverse_List;
function Clone
(Element : Function_Call_Node;
Parent : Asis.Element)
return Asis.Element;
procedure Copy
(Source : in Asis.Element;
Target : access Function_Call_Node;
Cloner : in Cloner_Class;
Parent : in Asis.Element);
----------------------------
-- Indexed_Component_Node --
----------------------------
type Indexed_Component_Node is
new Expression_Node with private;
type Indexed_Component_Ptr is
access all Indexed_Component_Node;
for Indexed_Component_Ptr'Storage_Pool use Lists.Pool;
function New_Indexed_Component_Node
(The_Context : ASIS.Context)
return Indexed_Component_Ptr;
function Prefix
(Element : Indexed_Component_Node) return Asis.Expression;
procedure Set_Prefix
(Element : in out Indexed_Component_Node;
Value : in Asis.Expression);
function Index_Expressions
(Element : Indexed_Component_Node;
Include_Pragmas : in Boolean := False) return Asis.Element_List;
procedure Set_Index_Expressions
(Element : in out Indexed_Component_Node;
Value : in Asis.Element);
function Index_Expressions_List
(Element : Indexed_Component_Node) return Asis.Element;
function Expression_Kind (Element : Indexed_Component_Node)
return Asis.Expression_Kinds;
function Children (Element : access Indexed_Component_Node)
return Traverse_List;
function Clone
(Element : Indexed_Component_Node;
Parent : Asis.Element)
return Asis.Element;
procedure Copy
(Source : in Asis.Element;
Target : access Indexed_Component_Node;
Cloner : in Cloner_Class;
Parent : in Asis.Element);
----------------
-- Slice_Node --
----------------
type Slice_Node is
new Expression_Node with private;
type Slice_Ptr is
access all Slice_Node;
for Slice_Ptr'Storage_Pool use Lists.Pool;
function New_Slice_Node
(The_Context : ASIS.Context)
return Slice_Ptr;
function Prefix
(Element : Slice_Node) return Asis.Expression;
procedure Set_Prefix
(Element : in out Slice_Node;
Value : in Asis.Expression);
function Slice_Range
(Element : Slice_Node) return Asis.Discrete_Range;
procedure Set_Slice_Range
(Element : in out Slice_Node;
Value : in Asis.Discrete_Range);
function Expression_Kind (Element : Slice_Node)
return Asis.Expression_Kinds;
function Children (Element : access Slice_Node)
return Traverse_List;
function Clone
(Element : Slice_Node;
Parent : Asis.Element)
return Asis.Element;
procedure Copy
(Source : in Asis.Element;
Target : access Slice_Node;
Cloner : in Cloner_Class;
Parent : in Asis.Element);
-----------------------------
-- Selected_Component_Node --
-----------------------------
type Selected_Component_Node is
new Expression_Node with private;
type Selected_Component_Ptr is
access all Selected_Component_Node;
for Selected_Component_Ptr'Storage_Pool use Lists.Pool;
function New_Selected_Component_Node
(The_Context : ASIS.Context)
return Selected_Component_Ptr;
function Prefix
(Element : Selected_Component_Node) return Asis.Expression;
procedure Set_Prefix
(Element : in out Selected_Component_Node;
Value : in Asis.Expression);
function Selector
(Element : Selected_Component_Node) return Asis.Expression;
procedure Set_Selector
(Element : in out Selected_Component_Node;
Value : in Asis.Expression);
function Expression_Kind (Element : Selected_Component_Node)
return Asis.Expression_Kinds;
function Children (Element : access Selected_Component_Node)
return Traverse_List;
function Clone
(Element : Selected_Component_Node;
Parent : Asis.Element)
return Asis.Element;
procedure Copy
(Source : in Asis.Element;
Target : access Selected_Component_Node;
Cloner : in Cloner_Class;
Parent : in Asis.Element);
------------------------------
-- Attribute_Reference_Node --
------------------------------
type Attribute_Reference_Node is
new Expression_Node with private;
type Attribute_Reference_Ptr is
access all Attribute_Reference_Node;
for Attribute_Reference_Ptr'Storage_Pool use Lists.Pool;
function New_Attribute_Reference_Node
(The_Context : ASIS.Context)
return Attribute_Reference_Ptr;
function Prefix
(Element : Attribute_Reference_Node) return Asis.Expression;
procedure Set_Prefix
(Element : in out Attribute_Reference_Node;
Value : in Asis.Expression);
function Attribute_Kind
(Element : Attribute_Reference_Node) return Asis.Attribute_Kinds;
procedure Set_Attribute_Kind
(Element : in out Attribute_Reference_Node;
Value : in Asis.Attribute_Kinds);
function Attribute_Designator_Identifier
(Element : Attribute_Reference_Node) return Asis.Expression;
procedure Set_Attribute_Designator_Identifier
(Element : in out Attribute_Reference_Node;
Value : in Asis.Expression);
function Attribute_Designator_Expressions
(Element : Attribute_Reference_Node;
Include_Pragmas : in Boolean := False) return Asis.Element_List;
procedure Set_Attribute_Designator_Expressions
(Element : in out Attribute_Reference_Node;
Value : in Asis.Element);
function Attribute_Designator_Expressions_List
(Element : Attribute_Reference_Node) return Asis.Element;
function Expression_Kind (Element : Attribute_Reference_Node)
return Asis.Expression_Kinds;
function Children (Element : access Attribute_Reference_Node)
return Traverse_List;
function Clone
(Element : Attribute_Reference_Node;
Parent : Asis.Element)
return Asis.Element;
procedure Copy
(Source : in Asis.Element;
Target : access Attribute_Reference_Node;
Cloner : in Cloner_Class;
Parent : in Asis.Element);
--------------------------------
-- Base_Record_Aggregate_Node --
--------------------------------
type Base_Record_Aggregate_Node is abstract
new Expression_Node with private;
type Base_Record_Aggregate_Ptr is
access all Base_Record_Aggregate_Node;
for Base_Record_Aggregate_Ptr'Storage_Pool use Lists.Pool;
function Record_Component_Associations
(Element : Base_Record_Aggregate_Node;
Include_Pragmas : in Boolean := False) return Asis.Element_List;
procedure Set_Record_Component_Associations
(Element : in out Base_Record_Aggregate_Node;
Value : in Asis.Element);
function Record_Component_Associations_List
(Element : Base_Record_Aggregate_Node) return Asis.Element;
function Normalized_Record_Component_Associations
(Element : Base_Record_Aggregate_Node;
Include_Pragmas : in Boolean := False) return Asis.Element_List;
procedure Add_To_Normalized_Record_Component_Associations
(Element : in out Base_Record_Aggregate_Node;
Item : in Asis.Element);
function Children (Element : access Base_Record_Aggregate_Node)
return Traverse_List;
---------------------------
-- Record_Aggregate_Node --
---------------------------
type Record_Aggregate_Node is
new Base_Record_Aggregate_Node with private;
type Record_Aggregate_Ptr is
access all Record_Aggregate_Node;
for Record_Aggregate_Ptr'Storage_Pool use Lists.Pool;
function New_Record_Aggregate_Node
(The_Context : ASIS.Context)
return Record_Aggregate_Ptr;
function Expression_Kind (Element : Record_Aggregate_Node)
return Asis.Expression_Kinds;
function Clone
(Element : Record_Aggregate_Node;
Parent : Asis.Element)
return Asis.Element;
procedure Copy
(Source : in Asis.Element;
Target : access Record_Aggregate_Node;
Cloner : in Cloner_Class;
Parent : in Asis.Element);
------------------------------
-- Extension_Aggregate_Node --
------------------------------
type Extension_Aggregate_Node is
new Base_Record_Aggregate_Node with private;
type Extension_Aggregate_Ptr is
access all Extension_Aggregate_Node;
for Extension_Aggregate_Ptr'Storage_Pool use Lists.Pool;
function New_Extension_Aggregate_Node
(The_Context : ASIS.Context)
return Extension_Aggregate_Ptr;
function Extension_Aggregate_Expression
(Element : Extension_Aggregate_Node) return Asis.Expression;
procedure Set_Extension_Aggregate_Expression
(Element : in out Extension_Aggregate_Node;
Value : in Asis.Expression);
function Expression_Kind (Element : Extension_Aggregate_Node)
return Asis.Expression_Kinds;
function Children (Element : access Extension_Aggregate_Node)
return Traverse_List;
function Clone
(Element : Extension_Aggregate_Node;
Parent : Asis.Element)
return Asis.Element;
procedure Copy
(Source : in Asis.Element;
Target : access Extension_Aggregate_Node;
Cloner : in Cloner_Class;
Parent : in Asis.Element);
-------------------------------
-- Base_Array_Aggregate_Node --
-------------------------------
type Base_Array_Aggregate_Node is abstract
new Expression_Node with private;
type Base_Array_Aggregate_Ptr is
access all Base_Array_Aggregate_Node;
for Base_Array_Aggregate_Ptr'Storage_Pool use Lists.Pool;
function Array_Component_Associations
(Element : Base_Array_Aggregate_Node;
Include_Pragmas : in Boolean := False) return Asis.Element_List;
procedure Set_Array_Component_Associations
(Element : in out Base_Array_Aggregate_Node;
Value : in Asis.Element);
function Array_Component_Associations_List
(Element : Base_Array_Aggregate_Node) return Asis.Element;
function Children (Element : access Base_Array_Aggregate_Node)
return Traverse_List;
-------------------------------------
-- Positional_Array_Aggregate_Node --
-------------------------------------
type Positional_Array_Aggregate_Node is
new Base_Array_Aggregate_Node with private;
type Positional_Array_Aggregate_Ptr is
access all Positional_Array_Aggregate_Node;
for Positional_Array_Aggregate_Ptr'Storage_Pool use Lists.Pool;
function New_Positional_Array_Aggregate_Node
(The_Context : ASIS.Context)
return Positional_Array_Aggregate_Ptr;
function Expression_Kind (Element : Positional_Array_Aggregate_Node)
return Asis.Expression_Kinds;
function Clone
(Element : Positional_Array_Aggregate_Node;
Parent : Asis.Element)
return Asis.Element;
procedure Copy
(Source : in Asis.Element;
Target : access Positional_Array_Aggregate_Node;
Cloner : in Cloner_Class;
Parent : in Asis.Element);
--------------------------------
-- Named_Array_Aggregate_Node --
--------------------------------
type Named_Array_Aggregate_Node is
new Base_Array_Aggregate_Node with private;
type Named_Array_Aggregate_Ptr is
access all Named_Array_Aggregate_Node;
for Named_Array_Aggregate_Ptr'Storage_Pool use Lists.Pool;
function New_Named_Array_Aggregate_Node
(The_Context : ASIS.Context)
return Named_Array_Aggregate_Ptr;
function Expression_Kind (Element : Named_Array_Aggregate_Node)
return Asis.Expression_Kinds;
function Clone
(Element : Named_Array_Aggregate_Node;
Parent : Asis.Element)
return Asis.Element;
procedure Copy
(Source : in Asis.Element;
Target : access Named_Array_Aggregate_Node;
Cloner : in Cloner_Class;
Parent : in Asis.Element);
-----------------------------
-- Base_Short_Circuit_Node --
-----------------------------
type Base_Short_Circuit_Node is abstract
new Expression_Node with private;
type Base_Short_Circuit_Ptr is
access all Base_Short_Circuit_Node;
for Base_Short_Circuit_Ptr'Storage_Pool use Lists.Pool;
function Short_Circuit_Operation_Left_Expression
(Element : Base_Short_Circuit_Node) return Asis.Expression;
procedure Set_Short_Circuit_Operation_Left_Expression
(Element : in out Base_Short_Circuit_Node;
Value : in Asis.Expression);
function Short_Circuit_Operation_Right_Expression
(Element : Base_Short_Circuit_Node) return Asis.Expression;
procedure Set_Short_Circuit_Operation_Right_Expression
(Element : in out Base_Short_Circuit_Node;
Value : in Asis.Expression);
function Children (Element : access Base_Short_Circuit_Node)
return Traverse_List;
---------------------------------
-- And_Then_Short_Circuit_Node --
---------------------------------
type And_Then_Short_Circuit_Node is
new Base_Short_Circuit_Node with private;
type And_Then_Short_Circuit_Ptr is
access all And_Then_Short_Circuit_Node;
for And_Then_Short_Circuit_Ptr'Storage_Pool use Lists.Pool;
function New_And_Then_Short_Circuit_Node
(The_Context : ASIS.Context)
return And_Then_Short_Circuit_Ptr;
function Expression_Kind (Element : And_Then_Short_Circuit_Node)
return Asis.Expression_Kinds;
function Clone
(Element : And_Then_Short_Circuit_Node;
Parent : Asis.Element)
return Asis.Element;
procedure Copy
(Source : in Asis.Element;
Target : access And_Then_Short_Circuit_Node;
Cloner : in Cloner_Class;
Parent : in Asis.Element);
--------------------------------
-- Or_Else_Short_Circuit_Node --
--------------------------------
type Or_Else_Short_Circuit_Node is
new Base_Short_Circuit_Node with private;
type Or_Else_Short_Circuit_Ptr is
access all Or_Else_Short_Circuit_Node;
for Or_Else_Short_Circuit_Ptr'Storage_Pool use Lists.Pool;
function New_Or_Else_Short_Circuit_Node
(The_Context : ASIS.Context)
return Or_Else_Short_Circuit_Ptr;
function Expression_Kind (Element : Or_Else_Short_Circuit_Node)
return Asis.Expression_Kinds;
function Clone
(Element : Or_Else_Short_Circuit_Node;
Parent : Asis.Element)
return Asis.Element;
procedure Copy
(Source : in Asis.Element;
Target : access Or_Else_Short_Circuit_Node;
Cloner : in Cloner_Class;
Parent : in Asis.Element);
-----------------------------------
-- In_Range_Membership_Test_Node --
-----------------------------------
type In_Range_Membership_Test_Node is
new Expression_Node with private;
type In_Range_Membership_Test_Ptr is
access all In_Range_Membership_Test_Node;
for In_Range_Membership_Test_Ptr'Storage_Pool use Lists.Pool;
function New_In_Range_Membership_Test_Node
(The_Context : ASIS.Context)
return In_Range_Membership_Test_Ptr;
function Membership_Test_Expression
(Element : In_Range_Membership_Test_Node) return Asis.Expression;
procedure Set_Membership_Test_Expression
(Element : in out In_Range_Membership_Test_Node;
Value : in Asis.Expression);
function Membership_Test_Range
(Element : In_Range_Membership_Test_Node) return Asis.Range_Constraint;
procedure Set_Membership_Test_Range
(Element : in out In_Range_Membership_Test_Node;
Value : in Asis.Range_Constraint);
function Expression_Kind (Element : In_Range_Membership_Test_Node)
return Asis.Expression_Kinds;
function Children (Element : access In_Range_Membership_Test_Node)
return Traverse_List;
function Clone
(Element : In_Range_Membership_Test_Node;
Parent : Asis.Element)
return Asis.Element;
procedure Copy
(Source : in Asis.Element;
Target : access In_Range_Membership_Test_Node;
Cloner : in Cloner_Class;
Parent : in Asis.Element);
---------------------------------------
-- Not_In_Range_Membership_Test_Node --
---------------------------------------
type Not_In_Range_Membership_Test_Node is
new In_Range_Membership_Test_Node with private;
type Not_In_Range_Membership_Test_Ptr is
access all Not_In_Range_Membership_Test_Node;
for Not_In_Range_Membership_Test_Ptr'Storage_Pool use Lists.Pool;
function New_Not_In_Range_Membership_Test_Node
(The_Context : ASIS.Context)
return Not_In_Range_Membership_Test_Ptr;
function Expression_Kind (Element : Not_In_Range_Membership_Test_Node)
return Asis.Expression_Kinds;
function Clone
(Element : Not_In_Range_Membership_Test_Node;
Parent : Asis.Element)
return Asis.Element;
procedure Copy
(Source : in Asis.Element;
Target : access Not_In_Range_Membership_Test_Node;
Cloner : in Cloner_Class;
Parent : in Asis.Element);
----------------------------------
-- In_Type_Membership_Test_Node --
----------------------------------
type In_Type_Membership_Test_Node is
new Expression_Node with private;
type In_Type_Membership_Test_Ptr is
access all In_Type_Membership_Test_Node;
for In_Type_Membership_Test_Ptr'Storage_Pool use Lists.Pool;
function New_In_Type_Membership_Test_Node
(The_Context : ASIS.Context)
return In_Type_Membership_Test_Ptr;
function Membership_Test_Expression
(Element : In_Type_Membership_Test_Node) return Asis.Expression;
procedure Set_Membership_Test_Expression
(Element : in out In_Type_Membership_Test_Node;
Value : in Asis.Expression);
function Membership_Test_Subtype_Mark
(Element : In_Type_Membership_Test_Node) return Asis.Expression;
procedure Set_Membership_Test_Subtype_Mark
(Element : in out In_Type_Membership_Test_Node;
Value : in Asis.Expression);
function Expression_Kind (Element : In_Type_Membership_Test_Node)
return Asis.Expression_Kinds;
function Children (Element : access In_Type_Membership_Test_Node)
return Traverse_List;
function Clone
(Element : In_Type_Membership_Test_Node;
Parent : Asis.Element)
return Asis.Element;
procedure Copy
(Source : in Asis.Element;
Target : access In_Type_Membership_Test_Node;
Cloner : in Cloner_Class;
Parent : in Asis.Element);
--------------------------------------
-- Not_In_Type_Membership_Test_Node --
--------------------------------------
type Not_In_Type_Membership_Test_Node is
new In_Type_Membership_Test_Node with private;
type Not_In_Type_Membership_Test_Ptr is
access all Not_In_Type_Membership_Test_Node;
for Not_In_Type_Membership_Test_Ptr'Storage_Pool use Lists.Pool;
function New_Not_In_Type_Membership_Test_Node
(The_Context : ASIS.Context)
return Not_In_Type_Membership_Test_Ptr;
function Expression_Kind (Element : Not_In_Type_Membership_Test_Node)
return Asis.Expression_Kinds;
function Clone
(Element : Not_In_Type_Membership_Test_Node;
Parent : Asis.Element)
return Asis.Element;
procedure Copy
(Source : in Asis.Element;
Target : access Not_In_Type_Membership_Test_Node;
Cloner : in Cloner_Class;
Parent : in Asis.Element);
-----------------------
-- Null_Literal_Node --
-----------------------
type Null_Literal_Node is
new Expression_Node with private;
type Null_Literal_Ptr is
access all Null_Literal_Node;
for Null_Literal_Ptr'Storage_Pool use Lists.Pool;
function New_Null_Literal_Node
(The_Context : ASIS.Context)
return Null_Literal_Ptr;
function Expression_Kind (Element : Null_Literal_Node)
return Asis.Expression_Kinds;
function Clone
(Element : Null_Literal_Node;
Parent : Asis.Element)
return Asis.Element;
-----------------------------------
-- Parenthesized_Expression_Node --
-----------------------------------
type Parenthesized_Expression_Node is
new Expression_Node with private;
type Parenthesized_Expression_Ptr is
access all Parenthesized_Expression_Node;
for Parenthesized_Expression_Ptr'Storage_Pool use Lists.Pool;
function New_Parenthesized_Expression_Node
(The_Context : ASIS.Context)
return Parenthesized_Expression_Ptr;
function Expression_Parenthesized
(Element : Parenthesized_Expression_Node) return Asis.Expression;
procedure Set_Expression_Parenthesized
(Element : in out Parenthesized_Expression_Node;
Value : in Asis.Expression);
function Expression_Kind (Element : Parenthesized_Expression_Node)
return Asis.Expression_Kinds;
function Children (Element : access Parenthesized_Expression_Node)
return Traverse_List;
function Clone
(Element : Parenthesized_Expression_Node;
Parent : Asis.Element)
return Asis.Element;
procedure Copy
(Source : in Asis.Element;
Target : access Parenthesized_Expression_Node;
Cloner : in Cloner_Class;
Parent : in Asis.Element);
--------------------------
-- Base_Conversion_Node --
--------------------------
type Base_Conversion_Node is abstract
new Expression_Node with private;
type Base_Conversion_Ptr is
access all Base_Conversion_Node;
for Base_Conversion_Ptr'Storage_Pool use Lists.Pool;
function Converted_Or_Qualified_Subtype_Mark
(Element : Base_Conversion_Node) return Asis.Expression;
procedure Set_Converted_Or_Qualified_Subtype_Mark
(Element : in out Base_Conversion_Node;
Value : in Asis.Expression);
function Converted_Or_Qualified_Expression
(Element : Base_Conversion_Node) return Asis.Expression;
procedure Set_Converted_Or_Qualified_Expression
(Element : in out Base_Conversion_Node;
Value : in Asis.Expression);
function Children (Element : access Base_Conversion_Node)
return Traverse_List;
--------------------------
-- Type_Conversion_Node --
--------------------------
type Type_Conversion_Node is
new Base_Conversion_Node with private;
type Type_Conversion_Ptr is
access all Type_Conversion_Node;
for Type_Conversion_Ptr'Storage_Pool use Lists.Pool;
function New_Type_Conversion_Node
(The_Context : ASIS.Context)
return Type_Conversion_Ptr;
function Expression_Kind (Element : Type_Conversion_Node)
return Asis.Expression_Kinds;
function Clone
(Element : Type_Conversion_Node;
Parent : Asis.Element)
return Asis.Element;
procedure Copy
(Source : in Asis.Element;
Target : access Type_Conversion_Node;
Cloner : in Cloner_Class;
Parent : in Asis.Element);
-------------------------------
-- Qualified_Expression_Node --
-------------------------------
type Qualified_Expression_Node is
new Base_Conversion_Node with private;
type Qualified_Expression_Ptr is
access all Qualified_Expression_Node;
for Qualified_Expression_Ptr'Storage_Pool use Lists.Pool;
function New_Qualified_Expression_Node
(The_Context : ASIS.Context)
return Qualified_Expression_Ptr;
function Expression_Kind (Element : Qualified_Expression_Node)
return Asis.Expression_Kinds;
function Clone
(Element : Qualified_Expression_Node;
Parent : Asis.Element)
return Asis.Element;
procedure Copy
(Source : in Asis.Element;
Target : access Qualified_Expression_Node;
Cloner : in Cloner_Class;
Parent : in Asis.Element);
----------------------------------
-- Allocation_From_Subtype_Node --
----------------------------------
type Allocation_From_Subtype_Node is
new Expression_Node with private;
type Allocation_From_Subtype_Ptr is
access all Allocation_From_Subtype_Node;
for Allocation_From_Subtype_Ptr'Storage_Pool use Lists.Pool;
function New_Allocation_From_Subtype_Node
(The_Context : ASIS.Context)
return Allocation_From_Subtype_Ptr;
function Allocator_Subtype_Indication
(Element : Allocation_From_Subtype_Node) return Asis.Subtype_Indication;
procedure Set_Allocator_Subtype_Indication
(Element : in out Allocation_From_Subtype_Node;
Value : in Asis.Subtype_Indication);
function Expression_Kind (Element : Allocation_From_Subtype_Node)
return Asis.Expression_Kinds;
function Children (Element : access Allocation_From_Subtype_Node)
return Traverse_List;
function Clone
(Element : Allocation_From_Subtype_Node;
Parent : Asis.Element)
return Asis.Element;
procedure Copy
(Source : in Asis.Element;
Target : access Allocation_From_Subtype_Node;
Cloner : in Cloner_Class;
Parent : in Asis.Element);
-----------------------------------------------
-- Allocation_From_Qualified_Expression_Node --
-----------------------------------------------
type Allocation_From_Qualified_Expression_Node is
new Expression_Node with private;
type Allocation_From_Qualified_Expression_Ptr is
access all Allocation_From_Qualified_Expression_Node;
for Allocation_From_Qualified_Expression_Ptr'Storage_Pool use Lists.Pool;
function New_Allocation_From_Qualified_Expression_Node
(The_Context : ASIS.Context)
return Allocation_From_Qualified_Expression_Ptr;
function Allocator_Qualified_Expression
(Element : Allocation_From_Qualified_Expression_Node) return Asis.Expression;
procedure Set_Allocator_Qualified_Expression
(Element : in out Allocation_From_Qualified_Expression_Node;
Value : in Asis.Expression);
function Expression_Kind (Element : Allocation_From_Qualified_Expression_Node)
return Asis.Expression_Kinds;
function Children (Element : access Allocation_From_Qualified_Expression_Node)
return Traverse_List;
function Clone
(Element : Allocation_From_Qualified_Expression_Node;
Parent : Asis.Element)
return Asis.Element;
procedure Copy
(Source : in Asis.Element;
Target : access Allocation_From_Qualified_Expression_Node;
Cloner : in Cloner_Class;
Parent : in Asis.Element);
private
type Box_Expression_Node is
new Expression_Node with
record
null;
end record;
type Base_Literal_Node is abstract
new Expression_Node with
record
Value_Image : aliased Unbounded_Wide_String;
end record;
type Integer_Literal_Node is
new Base_Literal_Node with
record
null;
end record;
type Real_Literal_Node is
new Base_Literal_Node with
record
null;
end record;
type String_Literal_Node is
new Base_Literal_Node with
record
null;
end record;
type Base_Identifier_Node is abstract
new Expression_Node with
record
Name_Image : aliased Unbounded_Wide_String;
Corresponding_Name_Declaration : aliased Asis.Declaration;
Corresponding_Name_Definition_List : aliased Secondary_Definition_Lists.List_Node;
Corresponding_Generic_Element : aliased Asis.Defining_Name;
end record;
type Identifier_Node is
new Base_Identifier_Node with
record
null;
end record;
type Operator_Symbol_Node is
new Base_Identifier_Node with
record
Operator_Kind : aliased Asis.Operator_Kinds := Not_An_Operator;
end record;
type Character_Literal_Node is
new Base_Identifier_Node with
record
null;
end record;
type Enumeration_Literal_Node is
new Base_Identifier_Node with
record
null;
end record;
type Explicit_Dereference_Node is
new Expression_Node with
record
Prefix : aliased Asis.Expression;
end record;
type Function_Call_Node is
new Expression_Node with
record
Prefix : aliased Asis.Expression;
Is_Prefix_Call : aliased Boolean
:= True;
Is_Dispatching_Call : aliased Boolean := False;
Corresponding_Called_Function : aliased Asis.Declaration;
Function_Call_Parameters : aliased Primary_Association_Lists.List;
Normalized_Function_Call_Parameters : aliased Secondary_Association_Lists.List_Node;
Is_Call_On_Dispatching_Operation : aliased Boolean := False;
Record_Aggregate : aliased Asis.Element;
end record;
type Indexed_Component_Node is
new Expression_Node with
record
Prefix : aliased Asis.Expression;
Index_Expressions : aliased Primary_Expression_Lists.List;
end record;
type Slice_Node is
new Expression_Node with
record
Prefix : aliased Asis.Expression;
Slice_Range : aliased Asis.Discrete_Range;
end record;
type Selected_Component_Node is
new Expression_Node with
record
Prefix : aliased Asis.Expression;
Selector : aliased Asis.Expression;
end record;
type Attribute_Reference_Node is
new Expression_Node with
record
Prefix : aliased Asis.Expression;
Attribute_Kind : aliased Asis.Attribute_Kinds := Not_An_Attribute;
Attribute_Designator_Identifier : aliased Asis.Expression;
Attribute_Designator_Expressions : aliased Primary_Expression_Lists.List;
end record;
type Base_Record_Aggregate_Node is abstract
new Expression_Node with
record
Record_Component_Associations : aliased Primary_Association_Lists.List;
Normalized_Record_Component_Associations : aliased Secondary_Association_Lists.List_Node;
end record;
type Record_Aggregate_Node is
new Base_Record_Aggregate_Node with
record
null;
end record;
type Extension_Aggregate_Node is
new Base_Record_Aggregate_Node with
record
Extension_Aggregate_Expression : aliased Asis.Expression;
end record;
type Base_Array_Aggregate_Node is abstract
new Expression_Node with
record
Array_Component_Associations : aliased Primary_Association_Lists.List;
end record;
type Positional_Array_Aggregate_Node is
new Base_Array_Aggregate_Node with
record
null;
end record;
type Named_Array_Aggregate_Node is
new Base_Array_Aggregate_Node with
record
null;
end record;
type Base_Short_Circuit_Node is abstract
new Expression_Node with
record
Short_Circuit_Operation_Left_Expression : aliased Asis.Expression;
Short_Circuit_Operation_Right_Expression : aliased Asis.Expression;
end record;
type And_Then_Short_Circuit_Node is
new Base_Short_Circuit_Node with
record
null;
end record;
type Or_Else_Short_Circuit_Node is
new Base_Short_Circuit_Node with
record
null;
end record;
type In_Range_Membership_Test_Node is
new Expression_Node with
record
Membership_Test_Expression : aliased Asis.Expression;
Membership_Test_Range : aliased Asis.Range_Constraint;
end record;
type Not_In_Range_Membership_Test_Node is
new In_Range_Membership_Test_Node with
record
null;
end record;
type In_Type_Membership_Test_Node is
new Expression_Node with
record
Membership_Test_Expression : aliased Asis.Expression;
Membership_Test_Subtype_Mark : aliased Asis.Expression;
end record;
type Not_In_Type_Membership_Test_Node is
new In_Type_Membership_Test_Node with
record
null;
end record;
type Null_Literal_Node is
new Expression_Node with
record
null;
end record;
type Parenthesized_Expression_Node is
new Expression_Node with
record
Expression_Parenthesized : aliased Asis.Expression;
end record;
type Base_Conversion_Node is abstract
new Expression_Node with
record
Converted_Or_Qualified_Subtype_Mark : aliased Asis.Expression;
Converted_Or_Qualified_Expression : aliased Asis.Expression;
end record;
type Type_Conversion_Node is
new Base_Conversion_Node with
record
null;
end record;
type Qualified_Expression_Node is
new Base_Conversion_Node with
record
null;
end record;
type Allocation_From_Subtype_Node is
new Expression_Node with
record
Allocator_Subtype_Indication : aliased Asis.Subtype_Indication;
end record;
type Allocation_From_Qualified_Expression_Node is
new Expression_Node with
record
Allocator_Qualified_Expression : aliased Asis.Expression;
end record;
end Asis.Gela.Elements.Expr;
|
legend-engine-language-pure-grammar/src/main/antlr4/org/finos/legend/engine/language/pure/grammar/from/antlr4/mapping/operationClassMapping/OperationClassMappingLexerGrammar.g4 | dave-wathen/legend-engine | 32 | 1814 | lexer grammar OperationClassMappingLexerGrammar;
import CoreLexerGrammar;
|
oeis/176/A176054.asm | neoneye/loda-programs | 11 | 27455 | <gh_stars>10-100
; A176054: Decimal expansion of (7+3*sqrt(7))/7.
; Submitted by <NAME>
; 2,1,3,3,8,9,3,4,1,9,0,2,7,6,8,1,6,8,1,6,4,3,5,4,9,6,0,8,7,0,2,5,4,0,1,8,2,4,4,7,2,5,3,9,3,5,6,0,6,7,6,4,3,6,3,0,1,5,0,0,0,4,8,2,5,1,4,7,4,3,7,8,1,3,8,4,4,0,7,2,6,9,0,4,0,1,6,8,3,7,9,9,1,7,6,6,1,5,4,7
mov $2,1
mov $3,$0
mul $3,4
lpb $3
mov $5,7
add $5,$2
add $5,$2
add $5,$2
add $1,$5
add $2,$1
mul $1,2
sub $3,1
lpe
mov $1,1
add $1,$5
add $1,1
sub $2,$5
mov $4,10
pow $4,$0
div $2,$4
div $1,$2
mov $0,$1
mod $0,10
|
gcc-gcc-7_3_0-release/gcc/testsuite/gnat.dg/opt8.ads | best08618/asylo | 7 | 13031 | <filename>gcc-gcc-7_3_0-release/gcc/testsuite/gnat.dg/opt8.ads
package Opt8 is
type Value_Number_Kind is
(Int_Literal_VN,
Selected_Address_VN,
Membership_VN,
Initial_External_Kappa_VN,
Aliased_Kappa_VN,
Phi_As_Kappa_VN,
Multi_Target_Call_Kappa_VN,
Final_Value_Of_Seq_Kappa_VN,
Block_Kappa_VN);
subtype Kappa_VN is Value_Number_Kind
range Initial_External_Kappa_VN .. Block_Kappa_VN;
type Value_Number_Id is new Positive;
type Kappa_Component_Rec;
type Kappa_Component_Ptr is access Kappa_Component_Rec;
type Kappa_Component_Rec is record
Content_VN : Value_Number_Id;
Next : Kappa_Component_Ptr;
end record;
type Value_Number_Rec(Kind : Value_Number_Kind) is record
Id: Value_Number_Id;
case Kind is
when Int_Literal_VN =>
Int_Val : Integer;
when Kappa_VN =>
Old_Value : Kappa_Component_Rec;
Possible_New_Values : Kappa_Component_Ptr;
Use_Default : Boolean;
when Others =>
null;
end case;
end record;
type Value_Number is access all Value_Number_Rec;
function VN_Complexity (Val : Value_Number; N : Natural) return Natural;
end Opt8;
|
T4P2/AssemblyT4P2.asm | cggewehr/Projeto-De-Processadores | 0 | 23058 |
; PROJETO DE PROCESSADORES - ELC 1094 - PROF. CARARA
; PROCESSADOR R8
; <NAME> E <NAME>
; DESCRIÇÃO:
; PROCESSADOR R8 COM SUPORTE A INTERRUPÇÕES DE I/O VIA PIC
; APLICAÇÃO ATUAL:
; COMUNICAÇAO COM MULTIPLOS PERIFERICOS "CRYPTOMESSAGE" VIA INTERRUPÇÃO COM PRIORIDADES
; CHANGELOG:
; - Emilio - Adicionado a mascara para interrupção no pic
; - Trocada a ordem dos HANDLERS ( No hdl Estamos usando os menos prioritários)
;
; TODO:
;
; OBSERVAÇÕES:
; - O parametro ISR_ADDR deve ser setado para 0x"0001" na instanciação do processador na entity top level
; - Respeitar o padrão de registradores estabelecidos
; - Novas adições ao código deve ser o mais modular possível
; - Subrotinas importantes devem começar com letra maiuscula
; - Subrotinas auxiliares devem começar com letra minuscula e serem identadas com 2 espaços
; - Instruções devem ser identadas com 4 espaços
; REGISTRADORES:
; --------------------- r0 = 0
; --------------------- r2 = PARAMETRO para subrotina
; --------------------- r3 = PARAMETRO para subrotina
; --------------------- r14 = Retorno de subrotina
; --------------------- r15 = Retorno de subrotina
;////////////////////////////////////////////////////////////////////////////////////////////////////////////
; port_io[8] = Direção dos bits de dados (dataDD) (15 a 8) , 1 = entrada, 0 = saida (out)
; port_io[7] = data[7] (in/out)
; port_io[6] = data[6] (in/out)
; port_io[5] = data[5] (in/out)
; port_io[4] = data[4] (in/out)
; port_io[3] = data[3] (in/out)
; port_io[2] = data[2] (in/out)
; port_io[1] = data[1] (in/out)
; port_io[0] = data[0] (in/out)
; port_io[11] = data_av (in)
; port_io[10] = ack (out)
; port_io[9] = eom (in)
; port_io[12] = keyExchange CryptoMessage0 (in) Maior prioridade
; port_io[13] = keyExchange CryptoMessage0 (in)
; port_io[14] = keyExchange CryptoMessage0 (in)
; port_io[15] = keyExchange CryptoMessage0 (in) Menor prioridade
.org #0000h
.code
;-----------------------------------------------------BOOT---------------------------------------------------
jmpd #setup ;Sempre primeira instrução do programa
jmpd #InterruptionServiceRoutine ;Sempre segunda instrução do programa
;---------------------------------------------CONFIGURAÇÃO INICIAL-------------------------------------------
setup:
; Inicializa ponteiro da pilha para 0x"7FFF" (ultimo endereço no espaço de endereçamento da memoria)
ldh r0, #7Fh
ldl r0, #FFh
ldsp r0
; Inicializa ponteiro da pilha para 0x"03E6" (ultimo endereço no espaço de endereçamento da memoria)
; ldh r0, #03h
; ldl r0, #E6h
; ldsp r0
; Seta endereço do tratador de interrupção
ldh r0, #InterruptionServiceRoutine
ldl r0, #InterruptionServiceRoutine
ldisra r0
xor r0, r0, r0
; Seta a Mascara do vetor de interrupções
ldl r4, #02h ; Atualiza o indexador para carregar a mascara em arrayPIC
ldh r7, #arrayPIC ; Carrega o endereço para o vetor de interrupções
ldl r7, #arrayPIC ; Carrega o endereço do vetor de interrupções
ld r7, r4, r7 ; &mask
ldh r8, #00h
ldl r8, #F0h ; Carrega a Mascara para o PIC [ r8 <= "0000_0000_1111_0000"]
xor r0, r0, r0
st r8, r0, r7 ; arrayPIC [MASK] <= "0000_0000_1111_0000"
; Array de registradores do controlador de interrupções
; arrayPIC [ IrqID(0x80F0) | IntACK(0x80F1) | Mask(0x80F2) ]
;arrayPIC: db #80F0h, #80F1h, #80F2h
; r1 <= &arrayPorta
ldh r1, #arrayPorta ; Carrega &Porta
ldl r1, #arrayPorta ; Carrega &Porta
ld r1, r0, r1
xor r4, r4, r4
; Seta PortConfig
ldl r4, #01h ; Atualiza indexador de arrayPorta [ arrayPorta[r4] -> &PortConfig ]
ldh r5, #FAh ; r5 <= "11111010_11111111"
ldl r5, #FFh ; bits 7 a 0 inicialmente são entrada, espera interrupção
st r5, r1, r4 ; PortConfig <= "11111010_11111111"
; Seta irqtEnable
ldl r4, #03h ; Atualiza indexador de arrayPorta [ arrayPorta[r4] -> &irqtEnable ]
ldh r5, #F0h ; r5 <= "11110000_00000000"
ldl r5, #00h ; Habilita a interrupção nos bits 12 a 15
st r5, r1, r4 ; irqtEnable <= "11110000_00000000"
; Seta PortEnable
ldl r4, #02h ; Atualiza indexador de arrayPorta [ arrayPorta[r4] -> &PortEnable ]
ldh r5, #FFh ; r5 <= "11111111_11111111"
ldl r5, #FFh ; Habilita acesso a todos os bits da porta de I/O
st r5, r1, r4 ; PortEnable <= "11111111_11111111"
; Seta dataDD como '1', ack como '0'
ldl r4, #0 ; Atualiza indexador de arrayPorta [ arrayPorta[r4] -> &PortData ]
ldh r5, #01h ; r5 <= "xxxxx0x1_xxxxxxxx"
ldl r5, #00h ; dataDD = '1', ACK = '0'
st r5, r1, r4 ; portData <= "xxxxx0x1_xxxxxxxx"
; Inicialização dos registradores
xor r0, r0, r0
xor r1, r1, r1
xor r2, r2, r2
xor r3, r3, r3
xor r4, r4, r4
xor r5, r5, r5
xor r6, r6, r6
xor r7, r7, r7
xor r8, r8, r8
xor r9, r9, r9
xor r10, r10, r10
xor r11, r11, r11
xor r12, r12, r12
xor r13, r13, r13
xor r13, r13, r13
xor r14, r14, r14
xor r15, r15, r15
jmpd #main
; END SETUP
;____________________________________________________________________________________________________________
;-----------------------------------------TRATAMENTO DE INTERRUPÇÃO------------------------------------------
InterruptionServiceRoutine:
; 1. Salvamento de contexto
; 2. Ler do PIC o número da IRQ
; 3. Indexar irq_handlers e gravar em algum registrador o endereço do handler
; 4. jsr reg (chama handler)
; 5. Notificar PIC sobre a IRQ tratada
; 6. Recuperação de contexto
; 7. Retorno (rti)
;////////////////////////////////////////////////////////////////////////////////////////////////////////////
; port_io[8] = Direção dos bits de dados (dataDD) (15 a 8) , 1 = entrada, 0 = saida (out)
; port_io[7] = data[7] (in/out)
; port_io[6] = data[6] (in/out)
; port_io[5] = data[5] (in/out)
; port_io[4] = data[4] (in/out)
; port_io[3] = data[3] (in/out)
; port_io[2] = data[2] (in/out)
; port_io[1] = data[1] (in/out)
; port_io[0] = data[0] (in/out)
; port_io[11] = data_av (in)
; port_io[10] = ack (out)
; port_io[9] = eom (in)
; port_io[12] = keyExchange CryptoMessage0 (in) Maior prioridade
; port_io[13] = keyExchange CryptoMessage1 (in)
; port_io[14] = keyExchange CryptoMessage2 (in)
; port_io[15] = keyExchange CryptoMessage3 (in) Menor prioridade
;////////////////////////////////////////////////////////////////////////////////////////////////////////////
;-----------------------------------------------Salva contexto-----------------------------------------------
push r0
push r1
push r2
push r3
push r4
push r5
push r6
push r7
push r8
push r9
push r10
push r11
push r12
push r13
push r14
push r15
pushf
xor r0, r0, r0
xor r4, r4, r4
xor r5, r5, r5
xor r6, r6, r6
;------------------------------------------Ler ID da interrupção do PIC--------------------------------------
; r4 <= IrqID
ldh r4, #arrayPIC
ldl r4, #arrayPIC
ld r4, r0, r4 ; r4 <= &IrqID
ld r4, r0, r4 ; r4 <= IrqID
; r1 <= &interruptVector
ldh r1, #interruptVector
ldl r1, #interruptVector
; r1 <= interruptVector[IrqID]
ld r1, r4, r1
;-----------------------------------------------Jump para handler--------------------------------------------
jsr r1
;-----------------------------------------Notificar interrupção tratada--------------------------------------
; r1 <= &IntACK
ldh r1, #arrayPIC
ldl r1, #arrayPIC
addi r1, #1
ld r1, r0, r1
; IntACK <= IrqID
st r1, r0, r4
;-----------------------------------------------Recupera contexto--------------------------------------------
popf
pop r15
pop r14
pop r13
pop r12
pop r11
pop r10
pop r9
pop r8
pop r7
pop r6
pop r5
pop r4
pop r3
pop r2
pop r1
pop r0
rti
; END InterruptionServiceRoutine
;____________________________________________________________________________________________________________
;-------------------------------------------------HANDLERS---------------------------------------------------
irq0Handler: ; CryptoMessage 0 - OPEN
halt
irq1Handler: ; CryptoMessage 1 - OPEN
halt
irq2Handler: ; CryptoMessage 2 - OPEN
halt
irq3Handler: ; CryptoMessage 3 - OPEN
halt
irq4Handler: ; CryptoMessage 0
; Chama Driver com ID = 0
xor r2, r2, r2
jsrd #GenericCryptoDriver
rts
; ACK Interrupçao
ldh r1, #arrayPIC
ldl r1, #arrayPIC
ld r1, r0, r1 ; r1 <= &irqID
addi r1, #1 ; r1 <= &itrACK
ldh r5, #0
ldl r5, #4
st r5, r0, r1
irq5Handler: ; CryptoMessage 1
; Chama Driver com ID = 1
xor r2, r2, r2
addi r2, #1
jsrd #GenericCryptoDriver
rts
; ACK Interrupçao
ldh r1, #arrayPIC
ldl r1, #arrayPIC
ld r1, r0, r1 ; r1 <= &irqID
addi r1, #1 ; r1 <= &itrACK
ldh r5, #0
ldl r5, #5
st r5, r0, r1
irq6Handler: ; CryptoMessage 2
; Chama Driver com ID = 2
xor r2, r2, r2
addi r2, #2
jsrd #GenericCryptoDriver
rts
; ACK Interrupçao
ldh r1, #arrayPIC
ldl r1, #arrayPIC
ld r1, r0, r1 ; r1 <= &irqID
addi r1, #1 ; r1 <= &itrACK
ldh r5, #0
ldl r5, #6
st r5, r0, r1
irq7Handler: ; CryptoMessage 3
; Chama Driver com ID = 3
xor r2, r2, r2
addi r2, #3
jsrd #GenericCryptoDriver
rts
; ACK Interrupçao
ldh r1, #arrayPIC
ldl r1, #arrayPIC
ld r1, r0, r1 ; r1 <= &irqID
addi r1, #1 ; r1 <= &itrACK
ldh r5, #0
ldl r5, #7
st r5, r0, r1
;-------------------------------------------------DRIVERS----------------------------------------------------
GenericCryptoDriver: ; Espera como parametro o ID do CryptoMessage interrompente em r2
; 1. CryptoMessage ativa keyExchange e coloca no barramento data_out seu magicNumber
; 2. R8 lê o magicNumber e calcula o seu magicNumber
; 3. R8 coloca o seu magicNumber no barramento data_in do CryptoMessage e gera um pulso em ack. Feito isso, ambos calculam a chave criptografica.
; 4. CryptoMessage coloca um caracter da mensagem criptografado no barramento data_out e ativa data_av
; 5. R8 lê o caracter e gera um pulso em ack
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; ESTADO 1 ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
push r1
push r4
push r5
push r6
push r7
xor r0, r0, r0
xor r1, r1, r1
xor r4, r4, r4
xor r5, r5, r5
xor r6, r6, r6
xor r7, r7, r7
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; ESTADO 2 ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
; r1 <= &PortData
ldh r1, #arrayPorta
ldl r1, #arrayPorta
ld r1, r0, r1
; Salva o interruptionID
ldh r7, #InterruptionID
ldl r7, #InterruptionID
st r2, r0, r7 ; InterruptionID <= ID
; Seta PortConfig
ldl r4, #01h ; Atualiza indexador de arrayPorta [ arrayPorta[r4] -> &PortConfig ]
ldh r5, #FAh ; r5 <= "11111010_11111111"
ldl r5, #FFh ; bits 15 a 8 inicialmente são entrada, espera keyExchange
st r5, r1, r4 ; PortConfig <= "11111111_0xxx1101"
; Set data direction as IN ( ack = 0, dataDD = 1 )
ldh r5, #01h
ldl r5, #00h
st r5, r0, r1 ; portData <= "xxxxx0x1_xxxxxxxx"
; r1 <= &PortData
ldh r1, #arrayPorta
ldl r1, #arrayPorta
ld r1, r0, r1
; r5 <= PortData
ld r5, r0, r1
; Apaga parte alta dos dados lidos ( r5 <= "00000000" & magicNumberCrypto )
ldh r5, #0
; Carrega endereço da variavel magicNumberCryptoMessage
ldh r1, #magicNumberCryptoMessage
ldl r1, #magicNumberCryptoMessage
; Salva magicNumber do periférico na variavel magicNumberCryptoMessage
st r5, r0, r1
; Calcula magicNumber do processador (dado disponivel em r14)
jsrd #CalculaMagicNumberR8
; Salva magicNumber do processador
ldh r1, #magicNumberR8
ldl r1, #magicNumberR8 ; r1 <= &magicNumberR8
add r5, r0, r14 ; r5 <= magicNumberR8
st r5, r0, r1 ; Salva magicNumberR8 em memoria
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; ESTADO 3 ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
; Set data direction as OUT
ldh r1, #arrayPorta
ldl r1, #arrayPorta
ld r1, r0, r1 ; r1 <= &portData
; r5 <= "xxxxx0x0_xxxxxxxx" (Disables Tristate)
ldh r5, #00h
ldl r5, #00h
st r5, r0, r1
; Seta em portConfig a direção dos dados como saída
ldh r1, #arrayPorta
ldl r1, #arrayPorta
addi r1, #1
ld r1, r0, r1 ; r1 <= &portConfig
ldh r5, #FAh
ldl r5, #00h
st r5, r0, r1 ; portConfig <= ("11111010_00000000")
; Prepara dado para escrita
ldh r1, #magicNumberR8
ldl r1, #magicNumberR8
ld r5, r0, r1
; Seta ack para '1', dataDD para '0' (saida)
ldh r5, #04h ; r5 <= "xxxxx1x0" & magicNumberR8
; Carrega endereço de PortData
ldh r1, #arrayPorta
ldl r1, #arrayPorta
ld r1, r0, r1 ; r1 <= &portData
; Transmite p/ porta magicNumberR8, sinaliza dataDD = OUT, ack = '1'
st r5, r0, r1 ; r5 <= "xxxxx1x0_(magicnumberR8)"
; Transmite ACK = '0'
st r0, r0, r1
; Seta bits de dados novamente como entrada
ldh r1, #arrayPorta
ldl r1, #arrayPorta
addi r1, #1
ld r1, r0, r1 ; r1 <= &portConfig
; Seta bits de dados novamente como entrada
ldh r5, #FAh
ldl r5, #FFh
st r5, r0, r1 ; r5 <= "11111010_11111111"
; Seta dataDD como entrada (dataDD = '1', ack = '0')
ldh r1, #arrayPorta
ldl r1, #arrayPorta
ld r1, r0, r1 ; r1 <= &portData
ldh r5, #01h
ldl r5, #00h
st r5, r0, r1 ; r5 <= "xxxx_x0x1_xxxx_xxxx"
; Seta argumento para calculo da chave criptografica (r2 <= magicNumberCryptoMessage)
ldh r1, #magicNumberCryptoMessage
ldl r1, #magicNumberCryptoMessage
ld r2, r0, r1
; Calcula chave criptografica
jsrd #CalculaCryptoKey
ldh r2, #InterruptionID
ldl r2, #InterruptionID
ld r2, r0, r2
; Salva chave criptografica
ldh r1, #cryptoKey
ldl r1, #cryptoKey
st r14, r0, r1 ; Salva chave criptografica em memoria
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; ESTADO 4 ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
PollingLoop: ; Espera próximo sinal de data_av = '1'
; Seta bits de dados como entrada
ldh r1, #arrayPorta
ldl r1, #arrayPorta
addi r1, #1
ld r1, r0, r1 ; r1 <= &portConfig
; Seta bits de dados novamente como entrada
ldh r5, #FAh
ldl r5, #FFh
st r5, r0, r1 ; r5 <= "11111010_11111111"
; Seta dataDD como entrada (dataDD = '1', ack = '0')
ldh r1, #arrayPorta
ldl r1, #arrayPorta
ld r1, r0, r1 ; r1 <= &portData
ldh r5, #01h
ldl r5, #00h
st r5, r0, r1 ; r5 <= "xxxx_xxx1_xxxx_xxxx"
; r1 <= &PortData
ldh r1, #arrayPorta
ldl r1, #arrayPorta
ld r1, r0, r1
; r5 <= PortData
ld r5, r0, r1
; Carrega mascara de comparação para bit 11 (data_av)
ldh r6, #08h
ldl r6, #00h ; r6 <= "00001000_00000000"
; Se operação com mascara resultar em 0, coloca caracter no array criptografado e descriptografado
and r1, r5, r6
sub r6, r6, r1
jmpzd #callLeCaracter
returncallLeCaracter:
; Carrega mascara de comparação para bit 9 (eom)
ldh r6, #02h
ldl r6, #00h ; r6 <= "00000010_00000000"
; Se operação com mascara resultar em 0, retorna da subrotina de driver p/ ISR, else, espera novo caracter
and r1, r5, r6
sub r6, r6, r1
jmpzd #returnPollingLoop
jmpd #PollingLoop
returnPollingLoop:
; Incrementa contador de mensagens
ldh r1, #contadorMSGS
ldl r1, #contadorMSGS
; r5 <= contadorMSGS
ld r5, r0, r1
; Compara contador com 251, se for igual, volta para 0, se nao, incrementa
ldh r1, #00h
ldl r1, #251
sub r1, r5, r1
jmpzd #contadorMSGSld0
addi r5, #1
returncontadorMSGSld0:
ldh r1, #contadorMSGS
ldl r1, #contadorMSGS
; Stores new value of message counter
st r5, r0, r1
; Resets CryptoPointer
ldh r1, #arrayCryptoPointer
ldl r1, #arrayCryptoPointer
ld r1, r2, r1 ; r1 <= &CryptoPointer(irqID)
st r0, r0, r1 ; CryptoPointer(irqID) <= 0
pop r7
pop r6
pop r5
pop r4
pop r1
rts
contadorMSGSld0:
xor r5, r5, r5
jmpd #returncontadorMSGSld0
callLeCaracter:
jsrd #LeCaracter
jmpd #returncallLeCaracter
;_____________________________________________________________________________________________________________
;------------------------------------------------SUBROTINAS--------------------------------------------------
; CalculaMagicNumberR8: DONE
; CalculaCryptoKey: DONE
; GeraACK: DONE
; LeCaracter: TODO
CalculaMagicNumberR8: ; Retorna em r14 o magicNumber do processador
; MagicNumberR8 = a^x * mod q
; MagicNumberR8 = 6^x * mod 251
push r4 ; 251
push r5 ; x ou Seed
push r6 ; 6
push r7 ; Mascara de bit (overflow)
push r12 ; Temporario
push r13 ; Temporario
xor r14, r14, r14 ; Zera o valor de retorno
addi r14, #01 ; Retorno <= 1
ldh r4, #00h
ldl r4, #FBh ; r4 < 251
; Carrega a seed
ldh r5, #contadorMSGS
ldl r5, #contadorMSGS
ld r5, r0, r5 ; Carrega o Valor do Contador msg para r5
ldh r6, #00h
ldl r6, #06h ; carreaga Seis
ldh r7, #00h
ldl r7, #80h ; Mascara [ 0000 0000 1000 0000]
; Verifica se a seed é menor que 251
sub r6, r4, r5 ; Realiza (251 - Seed )
jmpnd #SeedInvalida
jmpzd #SeedInvalida ; caso a seed for Negativa ou Zero
xor r6, r6, r6
addi r6, #06h
addi r5, #00h ; Caso a seed esteja igual a zero
jmpd #calculoExponencial
SeedInvalida:
xor r5, r5, r5 ; Zera a Seed
jmpd #calculoExponencial
calculoExponencial: ; DEBUG - r14 sendo atualizado com r6
jmpzd #retornaMagicNumber
mul r14, r14
mfl r14 ; r14 <= r14^2
div r14, r4
mfh r14 ; r14 <= r14^2 mod q
and r13, r7, r14 ; Comparacao da mascara
jmpzd #shiftAndJump
calculoMod:
mul r14, r6
mfl r14 ; r14 <= r14 * 6
div r14, r4
mfh r14 ; r14 <= r14 * 6 mod 251
shiftAndJump:
sr0 r7, r7 ; Shift da mascara
jmpd #calculoExponencial
retornaMagicNumber:
pop r13
pop r12
pop r7
pop r6
pop r5
pop r4
rts
CalculaCryptoKey: ; Retorna em r14 chave criptografica, recebe em r2 magic number do periferico (Se magicNumber = 0, retorna 1)
; KEY = a^b mod q
; KEY = MagicNumberR8 ^ magicNumberFromCrypto * mod q
; Se da pelo calculo de Key = magicNumberR8^magicNumberFromCrypto mod q
;push r2 ; magicNumberFromCrypto
push r3 ; magicNumberR8
push r4 ; 251
push r5 ; Mascara
push r6 ; Seed
push r13 ; temporario
ldh r3, #magicNumberR8
ldl r3, #magicNumberR8
ld r3, r0, r3 ; r3 <= magicNumberR8
ldh r4, #00h
ldl r4, #FBh ; r3 <= 251
ldh r5, #00h
ldl r5, #80h ; Mascara [ 0000 0000 1000 0000]
ldh r6, #contadorMSGS
ldl r6, #contadorMSGS
ld r6, r0, r6 ; Carrega o Valor do Contador msg para r6
xor r14, r14, r14 ; Zera a key
add r2, r0, r2
jmpzd #calculaCryptoKeyRetornaZero ; Se magicNumberFromCrypto == 0, retorna 1
addi r14, #1 ; Precisa estar em um pra realizar exp
;add r14, r3, r0 ; recebe o numero do magicNumberR8
;;-----
addi r6, #00h ; Caso a seed esteja igual a zero
jmpd #calculoExponencialKey
calculoExponencialKey:
jmpzd #retornaCalculaCryptoKey
mul r14, r14
mfl r14 ; r14 <= r14^2
div r14, r4
mfh r14 ; r14 <= r14^2 mod q
and r13, r5, r2 ; Comparacao da mascara
jmpzd #shiftAndJumpKey
calculoModKey:
mul r14, r6
mfl r14 ; r14 <= r14 * magicNumberR8 |
div r14, r4
mfh r14 ; r14 <= r14 * magicNumberR8 mod 251
shiftAndJumpKey:
sr0 r5, r5 ; Shift da mascara
jmpd #calculoExponencialKey
calculaCryptoKeyRetornaZero:
addi r14, #1
jmpd #retornaCalculaCryptoKey
retornaCalculaCryptoKey:
pop r13
pop r6
pop r5
pop r4
pop r3
;pop r2
rts
GeraACK: ; Envia pulso de ACK
push r1
push r5
push r6
xor r0, r0, r0
xor r1, r1, r1
xor r5, r5, r5
xor r6, r6, r6
; r1 <= &portConfig
ldh r1, #arrayPorta ; Carrega &Porta
ldl r1, #arrayPorta ; Carrega &Porta
addi r1, #1
ld r1, r0, r1 ; Carrega &portConfig
; r5 <= (Bits de dados como entrada, dataDD saida, outros de acordo)
ldh r5, #FAh
ldl r5, #FFh
st r5, r0, r1
; r1 <= &portData
ldh r1, #arrayPorta
ldl r1, #arrayPorta
ld r1, r0, r1
; r5 <= dataDD = '1', ACK = '1'
ldh r5, #05h
ldl r5, #00h
; r6 <= dataDD = '1', ACK = '0'
ldh r6, #01h
ldl r6, #00h
; portData <= dataDD = '1', ACK = '1'
st r5, r1, r0
; portData <= dataDD = '1', ACK = '0''
st r6, r1, r0
pop r6
pop r5
pop r1
rts
LeCaracter: ; Le caracter atual da porta, salva nos arrays, incrementa ponteiro p/ arrays
; Espera ID do CryptoMessage interrompente em r2 (para gravar caracter atual no array correspondente)
push r1
push r4
push r5
push r6
xor r0, r0, r0
xor r1, r1, r1
xor r4, r4, r4
xor r5, r5, r5
xor r6, r6, r6
; r1 <= &portConfig
ldh r1, #arrayPorta ; Carrega &Porta
ldl r1, #arrayPorta ; Carrega &Porta
addi r1, #1
ld r1, r0, r1 ; Carrega &portData
; r5 <= (Bits de dados como entrada, dataDD como saida, outros de acordo)
ldh r5, #FAh
ldl r5, #FFh
st r5, r0, r1
; r1 <= &portData
ldh r1, #arrayPorta ; Carrega &Porta
ldl r1, #arrayPorta ; Carrega &Porta
ld r1, r0, r1 ; Carrega &portData
; r5 <= dataDD = IN, ACK = 0 (Habilita Tristate)
ldh r5, #01h
ldl r5, #00h
st r5, r0, r1
; r5 <= PortData
ld r5, r0, r1
; r1 <= arrayEncrypted[irqID]
ldh r1, #arrayDecrypted
ldl r1, #arrayDecrypted
ld r1, r2, r1 ; r1 <= &arrayEncrypted
; r4 <= cryptoPointer
ldh r4, #arrayCryptoPointer
ldl r4, #arrayCryptoPointer
ld r4, r2, r4
; Carrega chave de criptografia
ldh r6, #cryptoKey
ldl r6, #cryptoKey
ld r6, r0, r6
; Descriptografa dado
xor r5, r6, r5
; Zera bit não relevantes
ldh r6, #0
ldl r6, #7Fh ; r6 <= "00000000_01111111"
and r5, r5, r6
; if "saveHighLow" == 0, save character on lower part, else, save on higher part
; r6 <= saveHighLow
ldh r6, #arraySaveHighLow
ldl r6, #arraySaveHighLow
ldh r7, #InterruptionID
ldl r7, #InterruptionID
ld r7, r0, r7 ; r7 <= Conteudo de InterruptionID [0, 1, 2, 3]
ld r6, r7, r6 ;;; *********************************************************************************************
ld r6, r0, r6 ;;; r6 <= valor interrupt ID
add r6, r0, r6 ; Gera flag
jmpzd #saveOnLower
jmpd #saveOnHigher
saveOnLower:
st r5, r1, r4 ; arrayDecrypted[r4] = Caracter descriptografado
; Incrementa saveHighLow (sinaliza proximo caracter a ser salvo na parte alta)
xor r1, r1, r1
addi r1, #1
ldh r6, #arraySaveHighLow
ldl r6, #arraySaveHighLow ; r6 <= Endereço arraySaveHighLow
ldh r7, #InterruptionID
ldl r7, #InterruptionID
ld r7, r0, r7 ; r7 <= Conteudo de InterruptionID [0, 1, 2, 3]
ld r6, r6, r7 ; Endereço do Highlow
st r1, r0, r7 ; Zera o Highlow
; Incrementa CryptoPointer
ldh r4, #arrayCryptoPointer
ldl r4, #arrayCryptoPointer
ld r5, r2, r4
addi r5, #1
st r5, r2, r4
jmpd #returnSaveHighLow
saveOnHigher:
; Shifta dado até bits mais significativos
sl0 r5, r5 ; MSB @ 8
sl0 r5, r5 ; MSB @ 9
sl0 r5, r5 ; MSB @ 10
sl0 r5, r5 ; MSB @ 11
sl0 r5, r5 ; MSB @ 12
sl0 r5, r5 ; MSB @ 13
sl0 r5, r5 ; MSB @ 14
sl0 r5, r5 ; MSB @ 15
; r6 <= Caracter salvo na parte baixa
ld r6, r1, r4 ; r6 <= arrayEncryped(irqID)[CryptoPointer]
; Apaga parte alta
ldh r6, #0
; Junta caracter antigo com caracter novo
xor r5, r5, r6
; Salva caracter antigo & caracter novo
st r5, r1, r4 ; arrayDecrypted[r4] = Caracter antigo + novo
; Zera saveHighLow
ldh r6, #arraySaveHighLow
ldl r6, #arraySaveHighLow ; r6 <= Endereço arraySaveHighLow
ldh r7, #InterruptionID
ldl r7, #InterruptionID
ld r7, r0, r7 ; r7 <= Conteudo de InterruptionID [0, 1, 2, 3]
ld r6, r6, r7 ; Endereço do Highlow
st r0, r0, r7 ; Zera o Highlow
jmpd #returnSaveHighLow
returnSaveHighLow:
; Gera ACK
jsrd #GeraACK
pop r6
pop r5
pop r4
pop r1
rts
;=============================================================================================================
;=============================================================================================================
;=============================================================================================================
;=============================================================================================================
;=============================================================================================================
;------------------------------------------- PROGRAMA PRINCIPAL ---------------------------------------------
main:
;; BUBBLE SORT DO CARARA
;* Bubble sort
;* Sort array in ascending order
;*
;* Used registers:
;* r1: points the first element of array
;* r2: temporary register
;* r3: points the end of array (right after the last element)
;* r4: indicates elements swaping (r4 = 1)
;* r5: array index
;* r6: array index
;* r7: element array[r5]
;* r8: element array[r8]
;*
;*********************************************************************
BubbleSort:
;halt ; DEBUG, ignora bubble sort
; Initialization code
xor r0, r0, r0 ; r0 <- 0
ldh r1, #arraySort ;
ldl r1, #arraySort ; r1 <- &array
ldh r2, #arraySortSize ;
ldl r2, #arraySortSize ; r2 <- &size
ld r2, r2, r0 ; r2 <- size
add r3, r2, r1 ; r3 points the end of array (right after the last element)
ldl r4, #0 ;
ldh r4, #1 ; r4 <- 1
; Main code
scan:
addi r4, #0 ; Verifies if there was element swapping
jmpzd #end ; If r4 = 0 then no element swapping
xor r4, r4, r4 ; r4 <- 0 before each pass
add r5, r1, r0 ; r5 points the first array element
add r6, r1, r0 ;
addi r6, #1 ; r6 points the second array element
; Read two consecutive elements and compares them
loop:
ld r7, r5, r0 ; r7 <- array[r5]
ld r8, r6, r0 ; r8 <- array[r6]
sub r2, r8, r7 ; If r8 > r7, negative flag is set
jmpnd #swap ; (if array[r5] > array[r6] jump)
; Increments the index registers and verifies if the pass is concluded
continue:
addi r5, #1 ; r5++
addi r6, #1 ; r6++
sub r2, r6, r3 ; Verifies if the end of array was reached (r6 = r3)
jmpzd #scan ; If r6 = r3 jump
jmpd #loop ; else, the next two elements are compared
; Swaps two array elements (memory)
swap:
st r7, r6, r0 ; array[r6] <- r7
st r8, r5, r0 ; array[r5] <- r8
ldl r4, #1 ; Set the element swapping (r4 <- 1)
jmpd #continue
end:
halt ; Suspend the execution
;=============================================================================================================
;=============================================================================================================
;=============================================================================================================
;=============================================================================================================
;=============================================================================================================
.endcode
.org #0300h
.data
; Array de registradores da Porta Bidirecional
; arrayPorta [ PortData(0x8000) | PortConfig(0x8001) | PortEnable(0x8002) | irqtEnable(0x8003) ]
arrayPorta: db #8000h, #8001h, #8002h, #8003h
; Array de registradores do controlador de interrupções
; arrayPIC [ IrqID(0x80F0) | IntACK(0x80F1) | Mask(0x80F2) ]
arrayPIC: db #80F0h, #80F1h, #80F2h
; Vetor com tratadores de interrupção
interruptVector: db #irq0Handler, #irq1Handler, #irq2Handler, #irq3Handler, #irq4Handler, #irq5Handler, #irq6Handler, #irq7Handler
; Variaveis p/ criptografia
magicNumberR8: db #0000h
magicNumberCryptoMessage: db #0000h
cryptoKey: db #0000h
contadorMSGS: db #0000h ; Novo seed para geração de magic number
; Arrays a serem indexados com ID da interrupção
arrayDecrypted: db #arrayDecrypted0, #arrayDecrypted1, #arrayDecrypted2, #arrayDecrypted3
arrayCryptoPointer: db #CryptoPointer0, #CryptoPointer1, #CryptoPointer2, #CryptoPointer3
arraySaveHighLow: db #SaveHighLow0, #SaveHighLow1, #SaveHighLow2, #SaveHighLow3
InterruptionID: db #0000h ; Id of interruption, can be [ 0, 1, 2, 3]
; Variaveis CryptoMessage 0
CryptoPointer0: db #0000h
arrayDecrypted0: db #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h
saveHighLow0: db #0001h ; Se = 0, salva caracter na parte baixa, se = 1 salva na parte alta
; Variaveis CryptoMessage 1
CryptoPointer1: db #0000h
arrayDecrypted1: db #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h
saveHighLow1: db #0001h ; Se = 0, salva caracter na parte baixa, se = 1 salva na parte alta
; Variaveis CryptoMessage 2
CryptoPointer2: db #0000h
arrayDecrypted2: db #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h
saveHighLow2: db #0001h ; Se = 0, salva caracter na parte baixa, se = 1 salva na parte alta
; Variaveis CryptoMessage 3
CryptoPointer3: db #0000h
arrayDecrypted3: db #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h, #0000h
saveHighLow3: db #0001h ; Se = 0, salva caracter na parte baixa, se = 1 salva na parte alta
; Array para aplicação principal (Bubble Sort) de 50 elementos
; Starts in 919 ends 968
arraySort: db #0050h, #0049h, #0048h, #0047h, #0046h, #0045h, #0044h, #0043h, #0042h, #0041h, #0040h, #0039h, #0038h, #0037h, #0036h, #0035h, #0034h, #0033h, #0032h, #0031h, #0030h, #0029h, #0028h, #0027h, #0026h, #0025h, #0024h, #0023h, #0022h, #0021h, #0020h, #0019h, #0018h, #0017h, #0016h, #0015h, #0014h, #0013h, #0012h, #0011h, #0010h, #0009h, #0008h, #0007h, #0006h, #0005h, #0004h, #0003h, #0002h, #0001h
; Tamanho do array p/ bubble sort (50 elementos)
arraySortSize: db #50
.enddata
|
source/adam-entity.adb | charlie5/aIDE | 3 | 22594 | with
Ada.Tags,
AdaM.Factory;
package body AdaM.Entity
is
-- Entities
--
function to_spec_Source (the_Entities : in Entities) return text_Vectors.Vector
is
the_Source : text_Vectors.Vector;
begin
for Each of the_Entities
loop
the_Source.append (Each.to_Source);
end loop;
return the_Source;
end to_spec_Source;
-- Entity
--
-- function Name (Self : in Item) return String
-- is
-- pragma Unreferenced (Self);
-- begin
-- return "<anon>";
-- end Name;
-- function full_Name (Self : in Item'Class) return String
-- is
-- begin
-- if Self.parent_Entity = null
-- then
-- return Self.Name;
-- else
-- return Self.parent_Entity.full_Name & "." & Self.Name;
-- end if;
-- end full_Name;
-- function to_spec_Source (Self : in Item) return text_Vectors.Vector
-- is
-- pragma Unreferenced (Self);
-- the_Source : text_Vectors.Vector;
-- begin
-- raise Program_Error with "TODO";
-- return the_Source;
-- end to_spec_Source;
function parent_Entity (Self : in Item) return Entity.view
is
begin
return Self.parent_Entity;
end parent_Entity;
procedure parent_Entity_is (Self : in out Item; Now : in Entity.View)
is
begin
Self.parent_Entity := Now;
end parent_Entity_is;
function Children (Self : access Item) return Entities_view
is
begin
return Self.Children'unchecked_Access;
end Children;
function Children (Self : in Item) return Entities'Class
is
begin
return Self.Children;
end Children;
procedure Children_are (Self : in out Item; Now : in Entities'Class)
is
begin
Self.Children := Entities (Now);
end Children_are;
function is_Public (Self : in Item) return Boolean
is
begin
return Self.is_Public;
end is_Public;
procedure is_Public (Self : in out Item; Now : in Boolean := True)
is
begin
Self.is_Public := Now;
end is_Public;
----------
-- Streams
--
procedure View_write (Stream : not null access Ada.Streams.Root_Stream_Type'Class;
Self : in View)
is
use Ada.Tags;
begin
if Self = null
then
AdaM.Id'write (Stream, null_Id);
return;
end if;
AdaM.Id'write (Stream, Self.Id);
String 'output (Stream, external_Tag (Self.all'Tag));
end View_write;
procedure View_read (Stream : not null access Ada.Streams.Root_Stream_Type'Class;
Self : out View)
is
Id : AdaM.Id;
begin
AdaM.Id'read (Stream, Id);
if Id = null_Id
then
Self := null;
return;
end if;
declare
use Ada.Tags;
the_String : constant String := String'Input (Stream); -- Read tag as string from stream.
the_Tag : constant Tag := Descendant_Tag (the_String, Item'Tag); -- Convert to a tag.
begin
Self := View (AdaM.Factory.to_View (Id, the_Tag));
end;
end View_read;
end AdaM.Entity;
|
src/firmware-tests/Platform/Buttons/InitialiseAfterButtonsDummy.asm | pete-restall/Cluck2Sesame-Prototype | 1 | 96955 | #include "Platform.inc"
#include "InitialisationChain.inc"
radix decimal
InitialiseAfterButtonsDummy code
global INITIALISE_AFTER_BUTTONS
INITIALISE_AFTER_BUTTONS:
return
end
|
SingletonChunks.agda | nad/codata | 1 | 15371 | ------------------------------------------------------------------------
-- An implementation of the Fibonacci sequence using tail
------------------------------------------------------------------------
module SingletonChunks where
open import Codata.Musical.Notation
open import Codata.Musical.Stream as S using (Stream; _≈_; _∷_)
open import Data.Bool
open import Data.Nat
open import Data.Vec as V using (Vec; []; _∷_)
import Relation.Binary.PropositionalEquality as P
------------------------------------------------------------------------
-- Stream programs
-- StreamP b A encodes programs generating streams in chunks of size
-- (at least) 1. The first chunk may be empty if b is false.
infixr 5 _∷_
data StreamP : Bool → Set → Set₁ where
[_] : ∀ {A} (xs : ∞ (StreamP true A)) → StreamP false A
_∷_ : ∀ {A} (x : A) (xs : StreamP false A) → StreamP true A
forget : ∀ {A} (xs : StreamP true A) → StreamP false A
tail : ∀ {A} (xs : StreamP true A) → StreamP false A
zipWith : ∀ {b A B C} (f : A → B → C)
(xs : StreamP b A) (ys : StreamP b B) → StreamP b C
data StreamW : Bool → Set → Set₁ where
[_] : ∀ {A} (xs : StreamP true A) → StreamW false A
_∷_ : ∀ {A} (x : A) (xs : StreamW false A) → StreamW true A
forgetW : ∀ {A} → StreamW true A → StreamW false A
forgetW (x ∷ [ xs ]) = [ x ∷ forget xs ]
tailW : ∀ {A} → StreamW true A → StreamW false A
tailW (x ∷ xs) = xs
zipWithW : ∀ {b A B C} → (A → B → C) →
StreamW b A → StreamW b B → StreamW b C
zipWithW f [ xs ] [ ys ] = [ zipWith f xs ys ]
zipWithW f (x ∷ xs) (y ∷ ys) = f x y ∷ zipWithW f xs ys
whnf : ∀ {b A} → StreamP b A → StreamW b A
whnf [ xs ] = [ ♭ xs ]
whnf (x ∷ xs) = x ∷ whnf xs
whnf (forget xs) = forgetW (whnf xs)
whnf (tail xs) = tailW (whnf xs)
whnf (zipWith f xs ys) = zipWithW f (whnf xs) (whnf ys)
mutual
⟦_⟧W : ∀ {A} → StreamW true A → Stream A
⟦ x ∷ [ xs ] ⟧W = x ∷ ♯ ⟦ xs ⟧P
⟦_⟧P : ∀ {A} → StreamP true A → Stream A
⟦ xs ⟧P = ⟦ whnf xs ⟧W
------------------------------------------------------------------------
-- The Fibonacci sequence
fib : StreamP true ℕ
fib = 0 ∷ [ ♯ (1 ∷ zipWith _+_ (forget fib) (tail fib)) ]
------------------------------------------------------------------------
-- The definition of fib is correct
-- ⟦_⟧ is homomorphic with respect to zipWith/S.zipWith.
zipWith-hom : ∀ {A B C} (_∙_ : A → B → C) xs ys →
⟦ zipWith _∙_ xs ys ⟧P ≈ S.zipWith _∙_ ⟦ xs ⟧P ⟦ ys ⟧P
zipWith-hom _∙_ xs ys with whnf xs | whnf ys
zipWith-hom _∙_ xs ys | x ∷ [ xs′ ] | y ∷ [ ys′ ] =
P.refl ∷ ♯ zipWith-hom _∙_ xs′ ys′
-- forget is the identity on streams.
open import MapIterate as M using (_≈P_; _∷_; _≈⟨_⟩_; _∎)
open import Relation.Binary.PropositionalEquality as P using (_≡_; [_])
forget-lemma : ∀ {A} x (xs : StreamP true A) →
⟦ x ∷ forget xs ⟧P ≈P x ∷ ♯ ⟦ xs ⟧P
forget-lemma x xs with whnf xs | P.inspect whnf xs
... | y ∷ [ ys ] | [ eq ] = x ∷ ♯ helper eq
where
helper : whnf xs ≡ y ∷ [ ys ] →
⟦ y ∷ forget ys ⟧P ≈P ⟦ xs ⟧P
helper eq rewrite eq = _ ≈⟨ forget-lemma y ys ⟩ (y ∷ ♯ (_ ∎))
-- The stream ⟦ fib ⟧P satisfies its intended defining equation.
open import Relation.Binary
module SS {A : Set} = Setoid (S.setoid A)
fib-correct :
⟦ fib ⟧P ≈ 0 ∷ ♯ (1 ∷ ♯ S.zipWith _+_ ⟦ fib ⟧P (S.tail ⟦ fib ⟧P))
fib-correct =
P.refl ∷ ♯ (P.refl ∷ ♯ SS.trans
(zipWith-hom _+_ (0 ∷ forget fib′) fib′)
(S.zipWith-cong _+_ (SS.trans (M.soundP (forget-lemma 0 fib′))
(P.refl ∷ ♯ SS.refl)) SS.refl))
where fib′ = 1 ∷ zipWith _+_ (forget fib) (tail fib)
------------------------------------------------------------------------
-- An equality proof language
infix 4 _≈[_]P_ _≈[_]W_
infix 3 _∎
infixr 2 _≈⟨_⟩_
data _≈[_]P_ : {A : Set} → Stream A → Bool → Stream A → Set₁ where
[_] : ∀ {A} {xs ys : Stream A}
(xs≈ys : ∞ (xs ≈[ true ]P ys)) → xs ≈[ false ]P ys
_∷_ : ∀ {b A} (x : A) {xs ys : ∞ (Stream A)}
(xs≈ys : ♭ xs ≈[ b ]P ♭ ys) → x ∷ xs ≈[ true ]P x ∷ ys
forget : ∀ {A} {xs ys : Stream A}
(xs≈ys : xs ≈[ true ]P ys) → xs ≈[ false ]P ys
_≈⟨_⟩_ : ∀ {b A} (xs : Stream A) {ys zs}
(xs≈ys : xs ≈[ b ]P ys) (ys≈zs : ys ≈[ b ]P zs) →
xs ≈[ b ]P zs
_∎ : ∀ {A} (xs : Stream A) → xs ≈[ true ]P xs
tail : ∀ {A} {xs ys : Stream A} (xs≈ys : xs ≈[ true ]P ys) →
S.tail xs ≈[ false ]P S.tail ys
zipWith : ∀ {b A B C} (f : A → B → C) {xs xs′ ys ys′}
(xs≈xs′ : xs ≈[ b ]P xs′) (ys≈ys′ : ys ≈[ b ]P ys′) →
S.zipWith f xs ys ≈[ b ]P S.zipWith f xs′ ys′
-- Completeness.
completeP : ∀ {A : Set} {xs ys : Stream A} →
xs ≈ ys → xs ≈[ true ]P ys
completeP (P.refl ∷ xs≈ys) = _ ∷ [ ♯ completeP (♭ xs≈ys) ]
-- Weak head normal forms.
data _≈[_]W_ {A : Set} : Stream A → Bool → Stream A → Set₁ where
[_] : {xs ys : Stream A}
(xs≈ys : xs ≈[ true ]P ys) → xs ≈[ false ]W ys
_∷_ : ∀ (x : A) {xs ys}
(xs≈ys : ♭ xs ≈[ true ]P ♭ ys) → x ∷ xs ≈[ true ]W x ∷ ys
consW≈ : ∀ {A b} (x : A) {xs ys} →
♭ xs ≈[ b ]W ♭ ys → x ∷ xs ≈[ true ]W x ∷ ys
consW≈ x xs≈ys = x ∷ helper xs≈ys
where
helper : ∀ {A b} {xs ys : Stream A} →
xs ≈[ b ]W ys → xs ≈[ true ]P ys
helper [ xs≈ys ] = xs≈ys
helper (x ∷ xs≈ys) = x ∷ xs≈ys
forgetW≈ : ∀ {A} {xs ys : Stream A} →
xs ≈[ true ]W ys → xs ≈[ false ]W ys
forgetW≈ (x ∷ xs≈ys) = [ x ∷ forget xs≈ys ]
transW≈ : ∀ {A b} {xs ys zs : Stream A} →
xs ≈[ b ]W ys → ys ≈[ b ]W zs → xs ≈[ b ]W zs
transW≈ [ xs≈ys ] [ ys≈zs ] = [ _ ≈⟨ xs≈ys ⟩ ys≈zs ]
transW≈ (x ∷ xs≈ys) (.x ∷ ys≈zs) = x ∷ (_ ≈⟨ xs≈ys ⟩ ys≈zs)
reflW≈ : ∀ {A} (xs : Stream A) → xs ≈[ true ]W xs
reflW≈ (x ∷ xs) = x ∷ (♭ xs ∎)
tailW≈ : ∀ {A} {xs ys : Stream A} →
xs ≈[ true ]W ys → S.tail xs ≈[ false ]W S.tail ys
tailW≈ (x ∷ xs≈ys) = [ xs≈ys ]
zipWithW≈ : ∀ {A B C b} (_∙_ : A → B → C) {xs₁ ys₁ xs₂ ys₂} →
xs₁ ≈[ b ]W ys₁ → xs₂ ≈[ b ]W ys₂ →
S.zipWith _∙_ xs₁ xs₂ ≈[ b ]W S.zipWith _∙_ ys₁ ys₂
zipWithW≈ _∙_ [ xs₁≈ys₁ ] [ xs₂≈ys₂ ] = [ zipWith _∙_ xs₁≈ys₁ xs₂≈ys₂ ]
zipWithW≈ _∙_ (x₁ ∷ xs₁≈ys₁) (x₂ ∷ xs₂≈ys₂) =
(x₁ ∙ x₂) ∷ zipWith _∙_ xs₁≈ys₁ xs₂≈ys₂
whnf≈ : ∀ {A : Set} {xs ys : Stream A} {b} →
xs ≈[ b ]P ys → xs ≈[ b ]W ys
whnf≈ [ xs≈ys ] = [ ♭ xs≈ys ]
whnf≈ (x ∷ xs≈ys) = consW≈ x (whnf≈ xs≈ys)
whnf≈ (forget xs≈ys) = forgetW≈ (whnf≈ xs≈ys)
whnf≈ (xs ≈⟨ xs≈ys ⟩ ys≈zs) = transW≈ (whnf≈ xs≈ys) (whnf≈ ys≈zs)
whnf≈ (xs ∎) = reflW≈ xs
whnf≈ (tail xs≈ys) = tailW≈ (whnf≈ xs≈ys)
whnf≈ (zipWith f xs≈xs′ ys≈ys′) = zipWithW≈ f (whnf≈ xs≈xs′) (whnf≈ ys≈ys′)
-- Soundness.
mutual
soundW : {A : Set} {xs ys : Stream A} → xs ≈[ true ]W ys → xs ≈ ys
soundW (x ∷ xs≈ys) = P.refl ∷ ♯ soundP xs≈ys
soundP : {A : Set} {xs ys : Stream A} → xs ≈[ true ]P ys → xs ≈ ys
soundP xs≈ys = soundW (whnf≈ xs≈ys)
------------------------------------------------------------------------
-- The equation given for fib has a unique solution
fib-rhs : Stream ℕ → Stream ℕ
fib-rhs ns = 0 ∷ ♯ (1 ∷ ♯ S.zipWith _+_ ns (S.tail ns))
fib-unique :
∀ ms ns → ms ≈ fib-rhs ms → ns ≈ fib-rhs ns → ms ≈[ true ]P ns
fib-unique ms ns ms≈ ns≈ =
ms ≈⟨ completeP ms≈ ⟩
fib-rhs ms ≈⟨ 0 ∷ [ ♯ (1 ∷ zipWith _+_ (forget (fib-unique ms ns ms≈ ns≈))
(tail (fib-unique ms ns ms≈ ns≈))) ] ⟩
fib-rhs ns ≈⟨ completeP (SS.sym ns≈) ⟩
ns ∎
|
oeis/029/A029653.asm | neoneye/loda-programs | 11 | 179370 | ; A029653: Numbers in (2,1)-Pascal triangle (by row).
; Submitted by <NAME>
; 1,2,1,2,3,1,2,5,4,1,2,7,9,5,1,2,9,16,14,6,1,2,11,25,30,20,7,1,2,13,36,55,50,27,8,1,2,15,49,91,105,77,35,9,1,2,17,64,140,196,182,112,44,10,1,2,19,81,204,336,378,294,156,54,11,1,2,21,100,285,540,714,672,450,210,65,12,1,2,23,121,385,825,1254,1386,1122,660,275,77,13,1,2,25,144,506,1210,2079,2640,2508,1782
lpb $0
add $2,$1
add $1,1
sub $0,$1
bin $2,$0
lpe
bin $1,$0
add $1,$2
mov $0,$1
|
container/w/core.agda | HoTT/M-types | 27 | 14449 | module container.w.core where
open import level
open import sum
open import equality
open import function.extensionality
open import function.isomorphism
open import function.isomorphism.properties
open import function.overloading
open import sets.empty
open import sets.nat.core using (suc)
open import sets.unit
open import hott.level
open import container.core
open import container.fixpoint
open import container.equality
private
module Definition {li la lb} (c : Container li la lb) where
open Container c
-- definition of indexed W-types using a type family
data W (i : I) : Set (la ⊔ lb) where
sup : (a : A i) → ((b : B a) → W (r b)) → W i
-- initial F-algebra
inW : F W →ⁱ W
inW i (a , f) = sup a f
module Elim {lx} {X : I → Set lx}
(α : F X →ⁱ X) where
-- catamorphisms
fold : W →ⁱ X
fold i (sup a f) = α i (a , λ b → fold _ (f b))
-- computational rule for catamorphisms
-- this holds definitionally
fold-β : ∀ {i} (x : F W i) → fold i (inW i x) ≡ α i (imap fold i x)
fold-β x = refl
-- η-rule, this is only propositional
fold-η : (h : W →ⁱ X)
→ (∀ {i} (x : F W i) → h i (inW i x) ≡ α i (imap h i x))
→ ∀ {i} (x : W i) → h i x ≡ fold i x
fold-η h p {i} (sup a f) = p (a , λ b → f b) · lem
where
lem : α i (a , (λ b → h _ (f b)))
≡ α i (a , (λ b → fold _ (f b)))
lem = ap (λ z → α i (a , z))
(funext λ b → fold-η h p (f b))
open Elim public
head : ∀ {i} → W i → A i
head (sup a f) = a
tail : ∀ {i} (x : W i)(b : B (head x)) → W (r b)
tail (sup a f) = f
fixpoint : (i : I) → W i ≅ F W i
fixpoint _ = iso f g H K
where
f : {i : I} → W i → F W i
f (sup a f) = a , f
g : {i : I} → F W i → W i
g (a , f) = sup a f
H : {i : I}(w : W i) → g (f w) ≡ w
H (sup a f) = refl
K : {i : I}(w : F W i) → f (g w) ≡ w
K (a , f) = refl
private
module Properties {li la lb}{c : Container li la lb} where
open Container c
open Definition c
open Equality c (fix W fixpoint)
open Container equality
using ()
renaming (F to F-≡')
open Definition equality
using ()
renaming ( W to W-≡
; fixpoint to fixpoint-≡ )
F-≡ : ∀ {lx}
→ (∀ {i} → W i → W i → Set lx)
→ (∀ {i} → W i → W i → Set _)
F-≡ X u v = F-≡' (λ {(i , u , v) → X {i} u v}) (_ , u , v)
_≡W_ : ∀ {i} → W i → W i → Set _
_≡W_ {i} u v = W-≡ (i , u , v)
fixpoint-W : ∀ {i}{u v : W i} → (u ≡ v) ≅ F-≡ _≡_ u v
fixpoint-W {i}{sup a f}{sup a' f'} = begin
(sup a f ≡ sup a' f')
≅⟨ iso≡ (fixpoint i) ⟩
(apply (fixpoint i) (sup a f) ≡ apply (fixpoint i) (sup a' f'))
≅⟨ sym≅ Σ-split-iso ⟩
(Σ (a ≡ a') λ p → subst (λ a → (b : B a) → W (r b)) p f ≡ f')
≅⟨ Σ-ap-iso refl≅ (substX-β f f') ⟩
(Σ (a ≡ a') λ p → ∀ b → f b ≡ substX p b (f' (subst B p b)))
∎
where open ≅-Reasoning
str-iso : ∀ {i}{u v : W i} → (u ≡ v) ≅ (u ≡W v)
str-iso {i}{sup a f}{sup a' f'} = begin
(sup a f ≡ sup a' f')
≅⟨ fixpoint-W ⟩
(Σ (a ≡ a') λ p → ∀ b → f b ≡ substX p b (f' (subst B p b)))
≅⟨ Σ-ap-iso refl≅ (λ a → Π-ap-iso refl≅ λ b → str-iso) ⟩
(Σ (a ≡ a') λ p → ∀ b → f b ≡W substX p b (f' (subst B p b)))
≅⟨ sym≅ (fixpoint-≡ _) ⟩
(sup a f ≡W sup a' f')
∎
where open ≅-Reasoning
-- w-level : ∀ {n} → ((i : I) → h (suc n) (A i)) → (i : I) → h (suc n) (W i)
-- w-level hA i (sup a f) (sup a' f') = iso-level (sym≅ lem)
-- (Σ-level (hA i a a') (λ p → Π-level λ b → w-level hA _ _ _))
-- where
-- lem : ∀ {i}{a a' : A i}
-- {f : (b : B a) → W (r b)}
-- {f' : (b : B a') → W (r b)}
-- → (sup a f ≡ sup a' f')
-- ≅ Σ (a ≡ a') λ p → ∀ b → f b ≡ substX p b (f' (subst B p b))
-- lem = fixpoint-W
open Definition public
-- open Properties public using (w-level)
|
oeis/206/A206047.asm | neoneye/loda-programs | 11 | 16212 | ; A206047: Number of (n+1) X 2 0..2 arrays with the number of clockwise edge increases in every 2 X 2 subblock equal to one.
; Submitted by <NAME>
; 48,255,1338,7041,37020,194691,1023822,5384085,28313712,148895799,783011010,4117687209,21654034308,113873925675,598838568438,3149163684861,16560776867160,87089576125791,457985415203562,2408447139960465,12665507314015212,66605188405376979,350262410539693470,1841954946368382309,9686446282440629568,50938944933261807495,267876993817394872338,1408707697237530882681,7408091855805364022100,38957567316249382522491,204869496861160016479302,1077364774946775015530445,5665630443182721412431912
add $0,3
mov $1,2
mov $4,2
lpb $0
sub $0,1
add $1,$3
add $2,$5
add $4,$2
mov $5,$4
mov $4,$2
add $4,$1
mul $5,2
add $1,$5
mov $3,$5
mov $5,$1
lpe
mov $0,$2
div $0,2
mul $0,3
|
imprimir.asm | jeremylive/Shared_Code | 0 | 19577 | <reponame>jeremylive/Shared_Code
;falta agregar signos
;imprime en binario ----------------------------------------------------
%macro PutBin 1
push eax
push ebx
push ecx
push edx
mov eax,%1
xor ecx, ecx
dec ecx
%%zero_loop:
inc ecx
rol eax,1
mov ebx, eax
and ebx, 00000001h
cmp ecx, 31 ;condicion de parada
jae %%end
cmp ebx,0
je %%zero_loop
PutCh '1'
%%print_loop:
inc ecx
rol eax,1
mov ebx, eax
and ebx, 00000001h
add bl, '0'
PutCh bl
cmp ecx, 31
jb %%print_loop
%%end:
PutCh 'b'
pop edx
pop ecx
pop ebx
pop eax
%endmacro
;imprime en octal-------------------------------------------------------
%macro PutOct 1
push eax
push ebx
push ecx
push edx
mov eax,%1
xor ecx, ecx
dec ecx
rol eax, 2
mov ebx, eax
and ebx,3
cmp ebx, 0
je %%zero_loop
add bl, '0'
PutCh bl
jmp %%print_loop
%%zero_loop:
inc ecx
rol eax,3
mov ebx, eax
and ebx, 00000007h
cmp ecx, 9 ;condicion de parada
jae %%end
cmp ebx,0
je %%zero_loop
add bl,'0'
PutCh bl
%%print_loop:
inc ecx
rol eax,3
mov ebx, eax
and ebx, 00000007h
add bl, '0'
PutCh bl
cmp ecx, 9
jb %%print_loop
%%end:
PutCh 'o'
pop edx
pop ecx
pop ebx
pop eax
%endmacro
;imprime en hexadecimal-------------------------------------------------
%macro PutHex 1
push eax
push ebx
push ecx
push edx
mov eax,%1
xor ecx, ecx
dec ecx
%%zero_loop:
inc ecx
rol eax,4
mov ebx, eax
and ebx, 0000000Fh
cmp ecx, 8 ;condicion de parada
jae %%end
cmp ebx,0
je %%zero_loop
printN ebx
cmp ecx, 7
jae %%end
%%print_loop:
inc ecx
rol eax,4
mov ebx, eax
and ebx, 0000000Fh
printN ebx
cmp ecx, 7
jb %%print_loop
%%end:
PutCh 'h'
pop edx
pop ecx
pop ebx
pop eax
%endmacro
%macro printN 1
push eax
push ebx
push ecx
push edx
mov ebx, %1
cmp bl, 9
jg %%leter
add bl, '0'
PutCh bl
jmp %%end
%%leter:
sub bl, 10
add bl, 'A'
PutCh bl
%%end:
pop edx
pop ecx
pop ebx
pop eax
%endmacro
|
programs/oeis/184/A184389.asm | karttu/loda | 1 | 96127 | ; A184389: a(n) = Sum_{k=1..tau(n)} k, where tau is the number of divisors of n (A000005).
; 1,3,3,6,3,10,3,10,6,10,3,21,3,10,10,15,3,21,3,21,10,10,3,36,6,10,10,21,3,36,3,21,10,10,10,45,3,10,10,36,3,36,3,21,21,10,3,55,6,21,10,21,3,36,10,36,10,10,3,78,3,10,21,28,10,36,3,21,10,36,3,78,3,10,21,21,10,36,3,55,15,10,3,78,10,10,10,36,3,78,10,21,10,10,10,78,3,21,21,45,3,36,3,36,36,10,3,78,3,36,10,55,3,36,10,21,21,10,10,136,6,10,10,21,10,78,3,36,10,36,3,78,10,10,36,36,3,36,3,78,10,10,10,120,10,10,21,21,3,78,3,36,21,36,10,78,3,10,10,78,10,55,3,21,36,10,3,136,6,36,21,21,3,36,21,55,10,10,3,171,3,36,10,36,10,36,10,21,36,36,3,105,3,10,36,45,3,78,3,78,10,10,10,78,10,10,21,55,10,136,3,21,10,10,10,136,10,10,10,78,10,36,3,78,45,10,3,78,3,36,36,36,3,78,10,21,10,36,3,210,3,21,21,21,21,36,10,36,10,36
cal $0,5 ; d(n) (also called tau(n) or sigma_0(n)), the number of divisors of n.
add $0,1
bin $0,2
mov $1,$0
|
data/mapObjects/fuchsiahouse3.asm | adhi-thirumala/EvoYellow | 16 | 102982 | <filename>data/mapObjects/fuchsiahouse3.asm
FuchsiaHouse3Object:
db $c ; border block
db $3 ; warps
db $0, $2, $8, $ff
db $7, $2, $7, $ff
db $7, $3, $7, $ff
db $0 ; signs
db $1 ; objects
object SPRITE_FISHER, $5, $3, STAY, RIGHT, $1 ; person
; warp-to
EVENT_DISP FUCHSIA_HOUSE_3_WIDTH, $0, $2
EVENT_DISP FUCHSIA_HOUSE_3_WIDTH, $7, $2
EVENT_DISP FUCHSIA_HOUSE_3_WIDTH, $7, $3
|
src/lib/Generic_Symbol_Table/symbol_tables-generic_symbol_table.ads | fintatarta/protypo | 0 | 10290 | with Ada.Containers.Indefinite_Hashed_Maps;
-- with Ada.Containers.Indefinite_Holders;
with Ada.Containers.Indefinite_Vectors;
with Ada.Containers.Vectors;
with Ada.Finalization;
use Ada;
--
-- ## What is this?
--
-- This package implements a generic "symbol table," that is a structure that
-- maps symbol "names" (a string) to symbol values.
--
-- The peculiarity that differentiate the symbol tables defined in this
-- package from an ordirary `Hashed_Maps.Map` is the possibility of
-- having different namespaces, possibly nested.
--
-- ### Data model
--
-- The abstract model is as follows.
-- * The symbol table contains one or more _namespace_
-- * A newly created table has only one namespace: the _root namespace_
-- that contains all the globally visible symbols
-- * At any time there is a _current_ namespace
-- * New namespaces can be created as _children_ of an existing namespace.
-- Two common choices for the parent namespace are
-- * The current namespace (like using a `declare .. begin .. end` in Ada)
-- * The root namespace (like when a new procedure is defined)
-- * When a symbol is searched for, first it is searched the current
--- namespace. If the symbol is not found, it is searched in the parent,
-- grand-parent and so on... until the root namespace is reached.
-- * When a new namespace is created it becomes the current one;
-- when the namespace is closed, the previous current namespace is selected.
--
-- It turns out that namespaces are organized in two structures
--
-- * They are organized as a tree (having the global namspace as root)
-- according to the child-parent relationship
-- * They are organized as a stack whose top is the current namespace.
-- New namespaces are pushed to the top and they are popped when
-- they are closed.
--
-- ### Cursors
--
-- When the table is queried it returns a `Cursor` that "points to" the
-- found element (or it assumes the special value `No_Element`). This
-- is similar to the behaviour of standard Ada containers.
--
-- The main difference with the usual `Cursor` is that the cursor of
-- this structure is "stable" with respect to tampering; that is, it
-- remains valid even if new elements and/or new namespaces are added
-- (I do not think this is guaranteed with the standard containers).
-- Only removing the namespace that contains the entry pointed by the cursors
-- invalidates the cursor (obviously).
--
generic
type Symbol_Name is new String;
type Symbol_Value (<>) is private;
with function Hash (Key : Symbol_Name) return Ada.Containers.Hash_Type;
with function Equivalent_Names (X, Y : Symbol_Name) return Boolean;
package Symbol_Tables.Generic_Symbol_Table is
type Symbol_Table is
new Finalization.Limited_Controlled
with
private;
type Cursor is private;
No_Element : constant Cursor;
function Image (X : Cursor) return String;
-- Return a printable representation of a cursor. Useful
-- mostly for debugging
type Table_Namespace is private;
No_Namespace : constant Table_Namespace;
function Copy_Globals (T : Symbol_Table) return Symbol_Table;
function Root (T : Symbol_Table) return Table_Namespace;
-- Return the global namespace of the table
function Current_Namespace (T : Symbol_Table) return Table_Namespace;
-- Return the current namespace
function Parent_Of (T : Symbol_Table;
Block : Table_Namespace) return Table_Namespace
with Post => (if Block = T.Root then Parent_Of'Result = No_Namespace);
-- Return the parent of a given namespace
procedure Open_Namespace (Table : in out Symbol_Table;
Parent : Table_Namespace)
with
Pre => Parent /= No_Namespace,
Post => Parent_Of (Table, Table.Current_Namespace) = Parent;
-- Create a new namespace with the given parent
procedure Open_Internal_Namespace (Table : in out Symbol_Table);
-- Syntactic sugar: Parent defaults to Table.Current_Block
procedure Open_External_Namespace (Table : in out Symbol_Table);
-- Syntactic sugar: Parent defaults to Table.Root
procedure Close_Namespace (Table : in out Symbol_Table)
with
Pre => Table.Current_Namespace /= Table.Root;
function Find (Table : Symbol_Table;
Name : Symbol_Name)
return Cursor;
function Contains (Table : Symbol_Table;
Name : Symbol_Name)
return Boolean
is (Table.Find (Name) /= No_Element);
function Has_Value (Pos : Cursor) return Boolean
with Pre => Pos /= No_Element;
function Value (Pos : Cursor) return Symbol_Value
with Pre => Has_Value (Pos);
function Name (Pos : Cursor) return Symbol_Name
with Pre => Pos /= No_Element;
function Contains (Block : Table_Namespace;
Name : Symbol_Name)
return Boolean;
procedure Create (Table : in out Symbol_Table;
Name : Symbol_Name;
Initial_Value : Symbol_Value)
with
Pre =>
not Contains (Table.Current_Namespace, Name),
Post =>
Contains (Table.Current_Namespace, Name)
and
Table.Current_Namespace = Table.Current_Namespace'Old;
procedure Create (Table : in out Symbol_Table;
Name : Symbol_Name;
Initial_Value : Symbol_Value;
Position : out Cursor)
with
Pre =>
not Contains (Table.Current_Namespace, Name),
Post =>
Contains (Table.Current_Namespace, Name)
and
Table.Current_Namespace = Table.Current_Namespace'Old
and
Table.Find (Name) = Position
and
Has_Value (Position)
and
Value (Position) = Initial_Value;
-- procedure Create (Table : in out Symbol_Table;
-- Name : Symbol_Name;
-- Position : out Cursor)
-- with
-- Pre =>
-- not Contains (Table.Current_Block, Name),
-- Post =>
-- Contains (Table.Current_Block, Name)
-- and
-- Table.Current_Block = Table.Current_Block'Old
-- and
-- Table.Find (Name) = Position
-- and
-- not Has_Value (Position);
procedure Update (Pos : Cursor;
New_Value : Symbol_Value)
with
Pre => Pos /= No_Element;
Uninitialized_Value : exception;
type Value_Printer is access function (X : Symbol_Value) return String;
procedure Set_Printer (Callback : Value_Printer);
-- Useful for debugging. Setup a function that converts symbol values
-- to string. This function will be used in generating debug prints.
-- Why specifying the converter in this way and not as a parameter
-- to package? Because it is a feature that it is not always
-- required.
Stale_Cursor : exception;
private
--
-- The structure of the symbol table is as follows: we have a stacks
-- of Namespaces. When a new namespace is open, it is pushed on the
-- stack, when it is closed it is popped out. The top of the stack
-- is always the current block. The stack can never be empty, the
-- bottom of the stack is the global namespace.
--
-- Blocks can have a "parent" that is searched when the symbol is not
-- found. The parent list goes from the block to the root.
--
-- Every namespace has an ID that is monotonically increased. Two
-- namespaces will never have the same ID.
--
-- Every namespace has two structure: a vector of Symbol_Value and
-- a Map mapping symbol_names to vector indexes. Why this involuted
-- structure? Why not just a map sending names to values? Because
-- in this way we can have a stable Cursor given by
-- * The namespace index in the stack
-- * The namespace ID
-- * The index of the entry in the value vector
--
-- This Cursor is stable against new additions to the table, a feature
-- that is sometimes required and that maybe is not guaranteed with
-- the usual library structures. The ID is not stricly necessary,
-- but it is useful to check for stale Cursors that refer to past
-- namespaces.
--
type Value_Index is range 1 .. Positive'Last;
type Namespace_Index is range 1 .. Positive'Last;
type Namespace_ID is range 0 .. Positive'Last;
Root_ID : constant Namespace_ID := Namespace_ID'First;
Root_Namespace : constant Namespace_Index := Namespace_Index'First;
package Name_Maps is
new Ada.Containers.Indefinite_Hashed_Maps
(Key_Type => Symbol_Name,
Element_Type => Value_Index,
Hash => Hash,
Equivalent_Keys => Equivalent_Names);
package Value_Vectors is
new Ada.Containers.Indefinite_Vectors (Index_Type => Value_Index,
Element_Type => Symbol_Value);
package Name_Vectors is
new Ada.Containers.Indefinite_Vectors (Index_Type => Value_Index,
Element_Type => Symbol_Name);
type Basic_Table;
type Basic_Table_Access is access Basic_Table;
type Table_Namespace is
record
Table : Basic_Table_Access;
Index : Namespace_Index;
ID : Namespace_ID;
end record;
No_Namespace : constant Table_Namespace := (Table => null,
Index => Namespace_Index'Last,
ID => Namespace_ID'Last);
type Namespace_Block is
record
Name_Map : Name_Maps.Map;
Values : Value_Vectors.Vector;
Names : Name_Vectors.Vector;
ID : Namespace_ID;
Parent : Table_Namespace;
end record;
-- with Dynamic_Predicate =>
-- (for all Idx in Namespace_Block.Names.First_Index .. Namespace_Block.Names.Last_Index
-- => Namespace_Block.Name_Map (Namespace_Block.Names (Idx)) = Idx)
-- and Names.First_Index = Values.First_Index
-- and Names.Last_Index = Values.Last_Index;
type Cursor is
record
Namespace : Table_Namespace;
Idx : Value_Index;
end record;
No_Element : constant Cursor := Cursor'(Namespace => No_Namespace,
Idx => Value_Index'Last);
function Image (X : Cursor) return String
is (if Has_Value (X) then
"["
& X.Idx'Image
& "@"
& X.Namespace.Index'Image
& ","
& X.Namespace.ID'Image
& "]"
else
"NO_ELEMENT");
package Namespace_Stacks is
new Ada.Containers.Vectors (Index_Type => Namespace_Index,
Element_Type => Namespace_Block);
-- package Value_Holders is
-- new Ada.Containers.Indefinite_Holders (Symbol_Value);
--
-- use type Value_Holders.Holder;
--
-- subtype Map_Entry is Value_Holders.Holder;
subtype Namespace_Stack is Namespace_Stacks.Vector;
procedure Push (Stack : in out Namespace_Stack;
Item : Namespace_Block);
procedure Pop (Stack : in out Namespace_Stack);
type Basic_Table is
record
Stack : Namespace_Stacks.Vector;
end record;
type Symbol_Table is
new Finalization.Limited_Controlled
with
record
Counter : Namespace_ID := Root_ID;
T : Basic_Table_Access;
end record;
overriding procedure Initialize (Object : in out Symbol_Table);
function Root (T : Symbol_Table) return Table_Namespace
is (Table_Namespace'(Table => T.T,
Index => Root_Namespace,
ID => Root_ID));
function Current_Namespace (T : Symbol_Table) return Table_Namespace
is (Table_Namespace'(Table => T.T,
Index => T.T.Stack.Last_Index,
Id => T.T.Stack.Last_Element.ID));
function Parent_Of (Block : Table_Namespace) return Table_Namespace
is (Block.Table.Stack.Element (Block.Index).Parent);
function Contains (Block : Table_Namespace;
Name : Symbol_Name)
return Boolean
is (Block.Table.Stack (Block.Index).Name_Map.Contains (Name));
function Is_Stale (Pos : Cursor) return Boolean
is (Pos.Namespace /= No_Namespace and then
(Pos.Namespace.Table.Stack (Pos.Namespace.Index).Id /= Pos.Namespace.Id));
function Value (Pos : Cursor) return Symbol_Value
is (if not Is_Stale (Pos) then
(if Has_Value (Pos) then
Pos.Namespace.Table.Stack (Pos.Namespace.Index).Values (Pos.Idx)
else
raise Uninitialized_Value with String (Name (Pos)))
else
raise Stale_Cursor);
function Has_Value (Pos : Cursor) return Boolean
is (Pos.Namespace /= No_Namespace);
function Name (Pos : Cursor) return Symbol_Name
is (Pos.Namespace.Table.Stack (Pos.Namespace.Index).Names (Pos.Idx));
function Parent_Of (T : Symbol_Table;
Block : Table_Namespace) return Table_Namespace
is (Table_Namespace'(Table => Block.Table,
Index => Block.Table.Stack (Block.Index).Parent.Index,
ID => Block.Table.Stack (Block.Index).Parent.ID));
end Symbol_Tables.Generic_Symbol_Table;
|
agda-stdlib-0.9/src/Relation/Binary/On.agda | qwe2/try-agda | 1 | 6044 | <gh_stars>1-10
------------------------------------------------------------------------
-- The Agda standard library
--
-- Many properties which hold for _∼_ also hold for _∼_ on f
------------------------------------------------------------------------
open import Relation.Binary
module Relation.Binary.On where
open import Function
open import Data.Product
module _ {a b} {A : Set a} {B : Set b} (f : B → A) where
implies : ∀ {ℓ₁ ℓ₂} (≈ : Rel A ℓ₁) (∼ : Rel A ℓ₂) →
≈ ⇒ ∼ → (≈ on f) ⇒ (∼ on f)
implies _ _ impl = impl
reflexive : ∀ {ℓ} (∼ : Rel A ℓ) → Reflexive ∼ → Reflexive (∼ on f)
reflexive _ refl = refl
irreflexive : ∀ {ℓ₁ ℓ₂} (≈ : Rel A ℓ₁) (∼ : Rel A ℓ₂) →
Irreflexive ≈ ∼ → Irreflexive (≈ on f) (∼ on f)
irreflexive _ _ irrefl = irrefl
symmetric : ∀ {ℓ} (∼ : Rel A ℓ) → Symmetric ∼ → Symmetric (∼ on f)
symmetric _ sym = sym
transitive : ∀ {ℓ} (∼ : Rel A ℓ) → Transitive ∼ → Transitive (∼ on f)
transitive _ trans = trans
antisymmetric : ∀ {ℓ₁ ℓ₂} (≈ : Rel A ℓ₁) (≤ : Rel A ℓ₂) →
Antisymmetric ≈ ≤ → Antisymmetric (≈ on f) (≤ on f)
antisymmetric _ _ antisym = antisym
asymmetric : ∀ {ℓ} (< : Rel A ℓ) → Asymmetric < → Asymmetric (< on f)
asymmetric _ asym = asym
respects : ∀ {ℓ p} (∼ : Rel A ℓ) (P : A → Set p) →
P Respects ∼ → (P ∘ f) Respects (∼ on f)
respects _ _ resp = resp
respects₂ : ∀ {ℓ₁ ℓ₂} (∼₁ : Rel A ℓ₁) (∼₂ : Rel A ℓ₂) →
∼₁ Respects₂ ∼₂ → (∼₁ on f) Respects₂ (∼₂ on f)
respects₂ _ _ (resp₁ , resp₂) =
((λ {_} {_} {_} → resp₁) , λ {_} {_} {_} → resp₂)
decidable : ∀ {ℓ} (∼ : Rel A ℓ) → Decidable ∼ → Decidable (∼ on f)
decidable _ dec = λ x y → dec (f x) (f y)
total : ∀ {ℓ} (∼ : Rel A ℓ) → Total ∼ → Total (∼ on f)
total _ tot = λ x y → tot (f x) (f y)
trichotomous : ∀ {ℓ₁ ℓ₂} (≈ : Rel A ℓ₁) (< : Rel A ℓ₂) →
Trichotomous ≈ < → Trichotomous (≈ on f) (< on f)
trichotomous _ _ compare = λ x y → compare (f x) (f y)
isEquivalence : ∀ {ℓ} {≈ : Rel A ℓ} →
IsEquivalence ≈ → IsEquivalence (≈ on f)
isEquivalence {≈ = ≈} eq = record
{ refl = reflexive ≈ Eq.refl
; sym = symmetric ≈ Eq.sym
; trans = transitive ≈ Eq.trans
}
where module Eq = IsEquivalence eq
isPreorder : ∀ {ℓ₁ ℓ₂} {≈ : Rel A ℓ₁} {∼ : Rel A ℓ₂} →
IsPreorder ≈ ∼ → IsPreorder (≈ on f) (∼ on f)
isPreorder {≈ = ≈} {∼} pre = record
{ isEquivalence = isEquivalence Pre.isEquivalence
; reflexive = implies ≈ ∼ Pre.reflexive
; trans = transitive ∼ Pre.trans
}
where module Pre = IsPreorder pre
isDecEquivalence : ∀ {ℓ} {≈ : Rel A ℓ} →
IsDecEquivalence ≈ → IsDecEquivalence (≈ on f)
isDecEquivalence {≈ = ≈} dec = record
{ isEquivalence = isEquivalence Dec.isEquivalence
; _≟_ = decidable ≈ Dec._≟_
}
where module Dec = IsDecEquivalence dec
isPartialOrder : ∀ {ℓ₁ ℓ₂} {≈ : Rel A ℓ₁} {≤ : Rel A ℓ₂} →
IsPartialOrder ≈ ≤ →
IsPartialOrder (≈ on f) (≤ on f)
isPartialOrder {≈ = ≈} {≤} po = record
{ isPreorder = isPreorder Po.isPreorder
; antisym = antisymmetric ≈ ≤ Po.antisym
}
where module Po = IsPartialOrder po
isDecPartialOrder : ∀ {ℓ₁ ℓ₂} {≈ : Rel A ℓ₁} {≤ : Rel A ℓ₂} →
IsDecPartialOrder ≈ ≤ →
IsDecPartialOrder (≈ on f) (≤ on f)
isDecPartialOrder dpo = record
{ isPartialOrder = isPartialOrder DPO.isPartialOrder
; _≟_ = decidable _ DPO._≟_
; _≤?_ = decidable _ DPO._≤?_
}
where module DPO = IsDecPartialOrder dpo
isStrictPartialOrder : ∀ {ℓ₁ ℓ₂} {≈ : Rel A ℓ₁} {< : Rel A ℓ₂} →
IsStrictPartialOrder ≈ < →
IsStrictPartialOrder (≈ on f) (< on f)
isStrictPartialOrder {≈ = ≈} {<} spo = record
{ isEquivalence = isEquivalence Spo.isEquivalence
; irrefl = irreflexive ≈ < Spo.irrefl
; trans = transitive < Spo.trans
; <-resp-≈ = respects₂ < ≈ Spo.<-resp-≈
}
where module Spo = IsStrictPartialOrder spo
isTotalOrder : ∀ {ℓ₁ ℓ₂} {≈ : Rel A ℓ₁} {≤ : Rel A ℓ₂} →
IsTotalOrder ≈ ≤ →
IsTotalOrder (≈ on f) (≤ on f)
isTotalOrder {≈ = ≈} {≤} to = record
{ isPartialOrder = isPartialOrder To.isPartialOrder
; total = total ≤ To.total
}
where module To = IsTotalOrder to
isDecTotalOrder : ∀ {ℓ₁ ℓ₂} {≈ : Rel A ℓ₁} {≤ : Rel A ℓ₂} →
IsDecTotalOrder ≈ ≤ →
IsDecTotalOrder (≈ on f) (≤ on f)
isDecTotalOrder {≈ = ≈} {≤} dec = record
{ isTotalOrder = isTotalOrder Dec.isTotalOrder
; _≟_ = decidable ≈ Dec._≟_
; _≤?_ = decidable ≤ Dec._≤?_
}
where module Dec = IsDecTotalOrder dec
isStrictTotalOrder : ∀ {ℓ₁ ℓ₂} {≈ : Rel A ℓ₁} {< : Rel A ℓ₂} →
IsStrictTotalOrder ≈ < →
IsStrictTotalOrder (≈ on f) (< on f)
isStrictTotalOrder {≈ = ≈} {<} sto = record
{ isEquivalence = isEquivalence Sto.isEquivalence
; trans = transitive < Sto.trans
; compare = trichotomous ≈ < Sto.compare
; <-resp-≈ = respects₂ < ≈ Sto.<-resp-≈
}
where module Sto = IsStrictTotalOrder sto
preorder : ∀ {p₁ p₂ p₃ b} {B : Set b} (P : Preorder p₁ p₂ p₃) →
(B → Preorder.Carrier P) → Preorder _ _ _
preorder P f = record
{ isPreorder = isPreorder f (Preorder.isPreorder P)
}
setoid : ∀ {s₁ s₂ b} {B : Set b} (S : Setoid s₁ s₂) →
(B → Setoid.Carrier S) → Setoid _ _
setoid S f = record
{ isEquivalence = isEquivalence f (Setoid.isEquivalence S)
}
decSetoid : ∀ {d₁ d₂ b} {B : Set b} (D : DecSetoid d₁ d₂) →
(B → DecSetoid.Carrier D) → DecSetoid _ _
decSetoid D f = record
{ isDecEquivalence = isDecEquivalence f (DecSetoid.isDecEquivalence D)
}
poset : ∀ {p₁ p₂ p₃ b} {B : Set b} (P : Poset p₁ p₂ p₃) →
(B → Poset.Carrier P) → Poset _ _ _
poset P f = record
{ isPartialOrder = isPartialOrder f (Poset.isPartialOrder P)
}
decPoset : ∀ {d₁ d₂ d₃ b} {B : Set b} (D : DecPoset d₁ d₂ d₃) →
(B → DecPoset.Carrier D) → DecPoset _ _ _
decPoset D f = record
{ isDecPartialOrder =
isDecPartialOrder f (DecPoset.isDecPartialOrder D)
}
strictPartialOrder :
∀ {s₁ s₂ s₃ b} {B : Set b} (S : StrictPartialOrder s₁ s₂ s₃) →
(B → StrictPartialOrder.Carrier S) → StrictPartialOrder _ _ _
strictPartialOrder S f = record
{ isStrictPartialOrder =
isStrictPartialOrder f (StrictPartialOrder.isStrictPartialOrder S)
}
totalOrder : ∀ {t₁ t₂ t₃ b} {B : Set b} (T : TotalOrder t₁ t₂ t₃) →
(B → TotalOrder.Carrier T) → TotalOrder _ _ _
totalOrder T f = record
{ isTotalOrder = isTotalOrder f (TotalOrder.isTotalOrder T)
}
decTotalOrder :
∀ {d₁ d₂ d₃ b} {B : Set b} (D : DecTotalOrder d₁ d₂ d₃) →
(B → DecTotalOrder.Carrier D) → DecTotalOrder _ _ _
decTotalOrder D f = record
{ isDecTotalOrder = isDecTotalOrder f (DecTotalOrder.isDecTotalOrder D)
}
strictTotalOrder :
∀ {s₁ s₂ s₃ b} {B : Set b} (S : StrictTotalOrder s₁ s₂ s₃) →
(B → StrictTotalOrder.Carrier S) → StrictTotalOrder _ _ _
strictTotalOrder S f = record
{ isStrictTotalOrder =
isStrictTotalOrder f (StrictTotalOrder.isStrictTotalOrder S)
}
|
UniBank.asm | Cancer52/flamedriver | 9 | 1631 | <filename>UniBank.asm
; ===========================================================================
; FM Universial Voice Bank
; ===========================================================================
SourceSMPS2ASM set 0
SourceDriver set 3
; Synth Bass 2
; Voice $00
; $3C
; $01, $00, $00, $00, $1F, $1F, $15, $1F, $11, $0D, $12, $05
; $07, $04, $09, $02, $55, $3A, $25, $1A, $1A, $80, $07, $80
smpsVcAlgorithm $04
smpsVcFeedback $07
smpsVcUnusedBits $00
smpsVcDetune $00, $00, $00, $00
smpsVcCoarseFreq $00, $00, $00, $01
smpsVcRateScale $00, $00, $00, $00
smpsVcAttackRate $1F, $15, $1F, $1F
smpsVcAmpMod $00, $00, $00, $00
smpsVcDecayRate1 $05, $12, $0D, $11
smpsVcDecayRate2 $02, $09, $04, $07
smpsVcDecayLevel $01, $02, $03, $05
smpsVcReleaseRate $0A, $05, $0A, $05
smpsVcTotalLevel $00, $07, $00, $1A
; Trumpet 1
; Voice $01
; $3D
; $01, $01, $01, $01, $94, $19, $19, $19, $0F, $0D, $0D, $0D
; $07, $04, $04, $04, $25, $1A, $1A, $1A, $15, $80, $80, $80
smpsVcAlgorithm $05
smpsVcFeedback $07
smpsVcUnusedBits $00
smpsVcDetune $00, $00, $00, $00
smpsVcCoarseFreq $01, $01, $01, $01
smpsVcRateScale $00, $00, $00, $02
smpsVcAttackRate $19, $19, $19, $14
smpsVcAmpMod $00, $00, $00, $00
smpsVcDecayRate1 $0D, $0D, $0D, $0F
smpsVcDecayRate2 $04, $04, $04, $07
smpsVcDecayLevel $01, $01, $01, $02
smpsVcReleaseRate $0A, $0A, $0A, $05
smpsVcTotalLevel $00, $00, $00, $15
; Slap Bass 2
; Voice $02
; $03
; $00, $D7, $33, $02, $5F, $9F, $5F, $1F, $13, $0F, $0A, $0A
; $10, $0F, $02, $09, $35, $15, $25, $1A, $13, $16, $15, $80
smpsVcAlgorithm $03
smpsVcFeedback $00
smpsVcUnusedBits $00
smpsVcDetune $00, $03, $0D, $00
smpsVcCoarseFreq $02, $03, $07, $00
smpsVcRateScale $00, $01, $02, $01
smpsVcAttackRate $1F, $1F, $1F, $1F
smpsVcAmpMod $00, $00, $00, $00
smpsVcDecayRate1 $0A, $0A, $0F, $13
smpsVcDecayRate2 $09, $02, $0F, $10
smpsVcDecayLevel $01, $02, $01, $03
smpsVcReleaseRate $0A, $05, $05, $05
smpsVcTotalLevel $00, $15, $16, $13
; Synth Bass 1
; Voice $03
; $34
; $70, $72, $31, $31, $1F, $1F, $1F, $1F, $10, $06, $06, $06
; $01, $06, $06, $06, $35, $1A, $15, $1A, $10, $83, $18, $83
smpsVcAlgorithm $04
smpsVcFeedback $06
smpsVcUnusedBits $00
smpsVcDetune $03, $03, $07, $07
smpsVcCoarseFreq $01, $01, $02, $00
smpsVcRateScale $00, $00, $00, $00
smpsVcAttackRate $1F, $1F, $1F, $1F
smpsVcAmpMod $00, $00, $00, $00
smpsVcDecayRate1 $06, $06, $06, $10
smpsVcDecayRate2 $06, $06, $06, $01
smpsVcDecayLevel $01, $01, $01, $03
smpsVcReleaseRate $0A, $05, $0A, $05
smpsVcTotalLevel $03, $18, $03, $10
; Bell Synth 1
; Voice $04
; $3E
; $77, $71, $32, $31, $1F, $1F, $1F, $1F, $0D, $06, $00, $00
; $08, $06, $00, $00, $15, $0A, $0A, $0A, $1B, $80, $80, $80
smpsVcAlgorithm $06
smpsVcFeedback $07
smpsVcUnusedBits $00
smpsVcDetune $03, $03, $07, $07
smpsVcCoarseFreq $01, $02, $01, $07
smpsVcRateScale $00, $00, $00, $00
smpsVcAttackRate $1F, $1F, $1F, $1F
smpsVcAmpMod $00, $00, $00, $00
smpsVcDecayRate1 $00, $00, $06, $0D
smpsVcDecayRate2 $00, $00, $06, $08
smpsVcDecayLevel $00, $00, $00, $01
smpsVcReleaseRate $0A, $0A, $0A, $05
smpsVcTotalLevel $00, $00, $00, $1B
; Bell Synth 2
; Voice $05
; $34
; $33, $41, $7E, $74, $5B, $9F, $5F, $1F, $04, $07, $07, $08
; $00, $00, $00, $00, $FF, $FF, $EF, $FF, $23, $80, $29, $87
smpsVcAlgorithm $04
smpsVcFeedback $06
smpsVcUnusedBits $00
smpsVcDetune $07, $07, $04, $03
smpsVcCoarseFreq $04, $0E, $01, $03
smpsVcRateScale $00, $01, $02, $01
smpsVcAttackRate $1F, $1F, $1F, $1B
smpsVcAmpMod $00, $00, $00, $00
smpsVcDecayRate1 $08, $07, $07, $04
smpsVcDecayRate2 $00, $00, $00, $00
smpsVcDecayLevel $0F, $0E, $0F, $0F
smpsVcReleaseRate $0F, $0F, $0F, $0F
smpsVcTotalLevel $07, $29, $00, $23
; Synth Brass 1
; Voice $06
; $3A
; $01, $07, $31, $71, $8E, $8E, $8D, $53, $0E, $0E, $0E, $03
; $00, $00, $00, $07, $1F, $FF, $1F, $0F, $18, $28, $27, $80
smpsVcAlgorithm $02
smpsVcFeedback $07
smpsVcUnusedBits $00
smpsVcDetune $07, $03, $00, $00
smpsVcCoarseFreq $01, $01, $07, $01
smpsVcRateScale $01, $02, $02, $02
smpsVcAttackRate $13, $0D, $0E, $0E
smpsVcAmpMod $00, $00, $00, $00
smpsVcDecayRate1 $03, $0E, $0E, $0E
smpsVcDecayRate2 $07, $00, $00, $00
smpsVcDecayLevel $00, $01, $0F, $01
smpsVcReleaseRate $0F, $0F, $0F, $0F
smpsVcTotalLevel $00, $27, $28, $18
; Synth like Bassoon
; Voice $07
; $3C
; $32, $32, $71, $42, $1F, $18, $1F, $1E, $07, $1F, $07, $1F
; $00, $00, $00, $00, $1F, $0F, $1F, $0F, $1E, $80, $0C, $80
smpsVcAlgorithm $04
smpsVcFeedback $07
smpsVcUnusedBits $00
smpsVcDetune $04, $07, $03, $03
smpsVcCoarseFreq $02, $01, $02, $02
smpsVcRateScale $00, $00, $00, $00
smpsVcAttackRate $1E, $1F, $18, $1F
smpsVcAmpMod $00, $00, $00, $00
smpsVcDecayRate1 $1F, $07, $1F, $07
smpsVcDecayRate2 $00, $00, $00, $00
smpsVcDecayLevel $00, $01, $00, $01
smpsVcReleaseRate $0F, $0F, $0F, $0F
smpsVcTotalLevel $00, $0C, $00, $1E
; Bell Horn type thing
; Voice $08
; $3C
; $71, $72, $3F, $34, $8D, $52, $9F, $1F, $09, $00, $00, $0D
; $00, $00, $00, $00, $23, $08, $02, $F7, $15, $80, $1D, $87
smpsVcAlgorithm $04
smpsVcFeedback $07
smpsVcUnusedBits $00
smpsVcDetune $03, $03, $07, $07
smpsVcCoarseFreq $04, $0F, $02, $01
smpsVcRateScale $00, $02, $01, $02
smpsVcAttackRate $1F, $1F, $12, $0D
smpsVcAmpMod $00, $00, $00, $00
smpsVcDecayRate1 $0D, $00, $00, $09
smpsVcDecayRate2 $00, $00, $00, $00
smpsVcDecayLevel $0F, $00, $00, $02
smpsVcReleaseRate $07, $02, $08, $03
smpsVcTotalLevel $07, $1D, $00, $15
; Synth Bass 3
; Voice $09
; $3D
; $01, $01, $00, $00, $8E, $52, $14, $4C, $08, $08, $0E, $03
; $00, $00, $00, $00, $1F, $1F, $1F, $1F, $1B, $80, $80, $9B
smpsVcAlgorithm $05
smpsVcFeedback $07
smpsVcUnusedBits $00
smpsVcDetune $00, $00, $00, $00
smpsVcCoarseFreq $00, $00, $01, $01
smpsVcRateScale $01, $00, $01, $02
smpsVcAttackRate $0C, $14, $12, $0E
smpsVcAmpMod $00, $00, $00, $00
smpsVcDecayRate1 $03, $0E, $08, $08
smpsVcDecayRate2 $00, $00, $00, $00
smpsVcDecayLevel $01, $01, $01, $01
smpsVcReleaseRate $0F, $0F, $0F, $0F
smpsVcTotalLevel $1B, $00, $00, $1B
; Synth Trumpet
; Voice $0A
; $3A
; $01, $01, $01, $02, $8D, $07, $07, $52, $09, $00, $00, $03
; $01, $02, $02, $00, $52, $02, $02, $28, $18, $22, $18, $80
smpsVcAlgorithm $02
smpsVcFeedback $07
smpsVcUnusedBits $00
smpsVcDetune $00, $00, $00, $00
smpsVcCoarseFreq $02, $01, $01, $01
smpsVcRateScale $01, $00, $00, $02
smpsVcAttackRate $12, $07, $07, $0D
smpsVcAmpMod $00, $00, $00, $00
smpsVcDecayRate1 $03, $00, $00, $09
smpsVcDecayRate2 $00, $02, $02, $01
smpsVcDecayLevel $02, $00, $00, $05
smpsVcReleaseRate $08, $02, $02, $02
smpsVcTotalLevel $00, $18, $22, $18
; Wood Block
; Voice $0B
; $3C
; $36, $31, $76, $71, $94, $9F, $96, $9F, $12, $00, $14, $0F
; $04, $0A, $04, $0D, $2F, $0F, $4F, $2F, $33, $80, $1A, $80
smpsVcAlgorithm $04
smpsVcFeedback $07
smpsVcUnusedBits $00
smpsVcDetune $07, $07, $03, $03
smpsVcCoarseFreq $01, $06, $01, $06
smpsVcRateScale $02, $02, $02, $02
smpsVcAttackRate $1F, $16, $1F, $14
smpsVcAmpMod $00, $00, $00, $00
smpsVcDecayRate1 $0F, $14, $00, $12
smpsVcDecayRate2 $0D, $04, $0A, $04
smpsVcDecayLevel $02, $04, $00, $02
smpsVcReleaseRate $0F, $0F, $0F, $0F
smpsVcTotalLevel $00, $1A, $00, $33
; Tubular Bell
; Voice $0C
; $34
; $33, $41, $7E, $74, $5B, $9F, $5F, $1F, $04, $07, $07, $08
; $00, $00, $00, $00, $FF, $FF, $EF, $FF, $23, $90, $29, $97
smpsVcAlgorithm $04
smpsVcFeedback $06
smpsVcUnusedBits $00
smpsVcDetune $07, $07, $04, $03
smpsVcCoarseFreq $04, $0E, $01, $03
smpsVcRateScale $00, $01, $02, $01
smpsVcAttackRate $1F, $1F, $1F, $1B
smpsVcAmpMod $00, $00, $00, $00
smpsVcDecayRate1 $08, $07, $07, $04
smpsVcDecayRate2 $00, $00, $00, $00
smpsVcDecayLevel $0F, $0E, $0F, $0F
smpsVcReleaseRate $0F, $0F, $0F, $0F
smpsVcTotalLevel $17, $29, $10, $23
; Strike Bass
; Voice $0D
; $38
; $63, $31, $31, $31, $10, $13, $1A, $1B, $0E, $00, $00, $00
; $00, $00, $00, $00, $3F, $0F, $0F, $0F, $1A, $19, $1A, $80
smpsVcAlgorithm $00
smpsVcFeedback $07
smpsVcUnusedBits $00
smpsVcDetune $03, $03, $03, $06
smpsVcCoarseFreq $01, $01, $01, $03
smpsVcRateScale $00, $00, $00, $00
smpsVcAttackRate $1B, $1A, $13, $10
smpsVcAmpMod $00, $00, $00, $00
smpsVcDecayRate1 $00, $00, $00, $0E
smpsVcDecayRate2 $00, $00, $00, $00
smpsVcDecayLevel $00, $00, $00, $03
smpsVcReleaseRate $0F, $0F, $0F, $0F
smpsVcTotalLevel $00, $1A, $19, $1A
; <NAME>
; Voice $0E
; $3A
; $31, $25, $73, $41, $5F, $1F, $1F, $9C, $08, $05, $04, $05
; $03, $04, $02, $02, $2F, $2F, $1F, $2F, $29, $27, $1F, $80
smpsVcAlgorithm $02
smpsVcFeedback $07
smpsVcUnusedBits $00
smpsVcDetune $04, $07, $02, $03
smpsVcCoarseFreq $01, $03, $05, $01
smpsVcRateScale $02, $00, $00, $01
smpsVcAttackRate $1C, $1F, $1F, $1F
smpsVcAmpMod $00, $00, $00, $00
smpsVcDecayRate1 $05, $04, $05, $08
smpsVcDecayRate2 $02, $02, $04, $03
smpsVcDecayLevel $02, $01, $02, $02
smpsVcReleaseRate $0F, $0F, $0F, $0F
smpsVcTotalLevel $00, $1F, $27, $29
; <NAME>
; Voice $0F
; $04
; $71, $41, $31, $31, $12, $12, $12, $12, $00, $00, $00, $00
; $00, $00, $00, $00, $0F, $0F, $0F, $0F, $23, $80, $23, $80
smpsVcAlgorithm $04
smpsVcFeedback $00
smpsVcUnusedBits $00
smpsVcDetune $03, $03, $04, $07
smpsVcCoarseFreq $01, $01, $01, $01
smpsVcRateScale $00, $00, $00, $00
smpsVcAttackRate $12, $12, $12, $12
smpsVcAmpMod $00, $00, $00, $00
smpsVcDecayRate1 $00, $00, $00, $00
smpsVcDecayRate2 $00, $00, $00, $00
smpsVcDecayLevel $00, $00, $00, $00
smpsVcReleaseRate $0F, $0F, $0F, $0F
smpsVcTotalLevel $00, $23, $00, $23
; $<NAME>
; Voice $10
; $14
; $75, $72, $35, $32, $9F, $9F, $9F, $9F, $05, $05, $00, $0A
; $05, $05, $07, $05, $2F, $FF, $0F, $2F, $1E, $80, $14, $80
smpsVcAlgorithm $04
smpsVcFeedback $02
smpsVcUnusedBits $00
smpsVcDetune $03, $03, $07, $07
smpsVcCoarseFreq $02, $05, $02, $05
smpsVcRateScale $02, $02, $02, $02
smpsVcAttackRate $1F, $1F, $1F, $1F
smpsVcAmpMod $00, $00, $00, $00
smpsVcDecayRate1 $0A, $00, $05, $05
smpsVcDecayRate2 $05, $07, $05, $05
smpsVcDecayLevel $02, $00, $0F, $02
smpsVcReleaseRate $0F, $0F, $0F, $0F
smpsVcTotalLevel $00, $14, $00, $1E
; Synth Brass 2
; Voice $11
; $3D
; $01, $00, $01, $02, $12, $1F, $1F, $14, $07, $02, $02, $0A
; $05, $05, $05, $05, $2F, $2F, $2F, $AF, $1C, $80, $82, $80
smpsVcAlgorithm $05
smpsVcFeedback $07
smpsVcUnusedBits $00
smpsVcDetune $00, $00, $00, $00
smpsVcCoarseFreq $02, $01, $00, $01
smpsVcRateScale $00, $00, $00, $00
smpsVcAttackRate $14, $1F, $1F, $12
smpsVcAmpMod $00, $00, $00, $00
smpsVcDecayRate1 $0A, $02, $02, $07
smpsVcDecayRate2 $05, $05, $05, $05
smpsVcDecayLevel $0A, $02, $02, $02
smpsVcReleaseRate $0F, $0F, $0F, $0F
smpsVcTotalLevel $00, $02, $00, $1C
; Bell Piano
; Voice $12
; $1C
; $73, $72, $33, $32, $94, $99, $94, $99, $08, $0A, $08, $0A
; $00, $05, $00, $05, $3F, $4F, $3F, $4F, $1E, $80, $19, $80
smpsVcAlgorithm $04
smpsVcFeedback $03
smpsVcUnusedBits $00
smpsVcDetune $03, $03, $07, $07
smpsVcCoarseFreq $02, $03, $02, $03
smpsVcRateScale $02, $02, $02, $02
smpsVcAttackRate $19, $14, $19, $14
smpsVcAmpMod $00, $00, $00, $00
smpsVcDecayRate1 $0A, $08, $0A, $08
smpsVcDecayRate2 $05, $00, $05, $00
smpsVcDecayLevel $04, $03, $04, $03
smpsVcReleaseRate $0F, $0F, $0F, $0F
smpsVcTotalLevel $00, $19, $00, $1E
; Wet Wood Bass
; Voice $13
; $31
; $33, $01, $00, $00, $9F, $1F, $1F, $1F, $0D, $0A, $0A, $0A
; $0A, $07, $07, $07, $FF, $AF, $AF, $AF, $1E, $1E, $1E, $80
smpsVcAlgorithm $01
smpsVcFeedback $06
smpsVcUnusedBits $00
smpsVcDetune $00, $00, $00, $03
smpsVcCoarseFreq $00, $00, $01, $03
smpsVcRateScale $00, $00, $00, $02
smpsVcAttackRate $1F, $1F, $1F, $1F
smpsVcAmpMod $00, $00, $00, $00
smpsVcDecayRate1 $0A, $0A, $0A, $0D
smpsVcDecayRate2 $07, $07, $07, $0A
smpsVcDecayLevel $0A, $0A, $0A, $0F
smpsVcReleaseRate $0F, $0F, $0F, $0F
smpsVcTotalLevel $00, $1E, $1E, $1E
; <NAME>
; Voice $14
; $3A
; $70, $76, $30, $71, $1F, $95, $1F, $1F, $0E, $0F, $05, $0C
; $07, $06, $06, $07, $2F, $4F, $1F, $5F, $21, $12, $28, $80
smpsVcAlgorithm $02
smpsVcFeedback $07
smpsVcUnusedBits $00
smpsVcDetune $07, $03, $07, $07
smpsVcCoarseFreq $01, $00, $06, $00
smpsVcRateScale $00, $00, $02, $00
smpsVcAttackRate $1F, $1F, $15, $1F
smpsVcAmpMod $00, $00, $00, $00
smpsVcDecayRate1 $0C, $05, $0F, $0E
smpsVcDecayRate2 $07, $06, $06, $07
smpsVcDecayLevel $05, $01, $04, $02
smpsVcReleaseRate $0F, $0F, $0F, $0F
smpsVcTotalLevel $00, $28, $12, $21
; Picked Bass
; Voice $15
; $28
; $71, $00, $30, $01, $1F, $1F, $1D, $1F, $13, $13, $06, $05
; $03, $03, $02, $05, $4F, $4F, $2F, $3F, $0E, $14, $1E, $80
smpsVcAlgorithm $00
smpsVcFeedback $05
smpsVcUnusedBits $00
smpsVcDetune $00, $03, $00, $07
smpsVcCoarseFreq $01, $00, $00, $01
smpsVcRateScale $00, $00, $00, $00
smpsVcAttackRate $1F, $1D, $1F, $1F
smpsVcAmpMod $00, $00, $00, $00
smpsVcDecayRate1 $05, $06, $13, $13
smpsVcDecayRate2 $05, $02, $03, $03
smpsVcDecayLevel $03, $02, $04, $04
smpsVcReleaseRate $0F, $0F, $0F, $0F
smpsVcTotalLevel $00, $1E, $14, $0E
; Xylophone
; Voice $16
; $3E
; $38, $01, $7A, $34, $59, $D9, $5F, $9C, $0F, $04, $0F, $0A
; $02, $02, $05, $05, $AF, $AF, $66, $66, $28, $80, $A3, $80
smpsVcAlgorithm $06
smpsVcFeedback $07
smpsVcUnusedBits $00
smpsVcDetune $03, $07, $00, $03
smpsVcCoarseFreq $04, $0A, $01, $08
smpsVcRateScale $02, $01, $03, $01
smpsVcAttackRate $1C, $1F, $19, $19
smpsVcAmpMod $00, $00, $00, $00
smpsVcDecayRate1 $0A, $0F, $04, $0F
smpsVcDecayRate2 $05, $05, $02, $02
smpsVcDecayLevel $06, $06, $0A, $0A
smpsVcReleaseRate $06, $06, $0F, $0F
smpsVcTotalLevel $00, $23, $00, $28
; Sine Flute
; Voice $17
; $39
; $32, $31, $72, $71, $1F, $1F, $1F, $1F, $00, $00, $00, $00
; $00, $00, $00, $00, $0F, $0F, $0F, $0F, $1B, $32, $28, $80
smpsVcAlgorithm $01
smpsVcFeedback $07
smpsVcUnusedBits $00
smpsVcDetune $07, $07, $03, $03
smpsVcCoarseFreq $01, $02, $01, $02
smpsVcRateScale $00, $00, $00, $00
smpsVcAttackRate $1F, $1F, $1F, $1F
smpsVcAmpMod $00, $00, $00, $00
smpsVcDecayRate1 $00, $00, $00, $00
smpsVcDecayRate2 $00, $00, $00, $00
smpsVcDecayLevel $00, $00, $00, $00
smpsVcReleaseRate $0F, $0F, $0F, $0F
smpsVcTotalLevel $00, $28, $32, $1B
; Pipe Organ
; Voice $18
; $07
; $34, $74, $32, $71, $1F, $1F, $1F, $1F, $0A, $0A, $05, $03
; $00, $00, $00, $00, $3F, $3F, $2F, $2F, $8A, $8A, $80, $80
smpsVcAlgorithm $07
smpsVcFeedback $00
smpsVcUnusedBits $00
smpsVcDetune $07, $03, $07, $03
smpsVcCoarseFreq $01, $02, $04, $04
smpsVcRateScale $00, $00, $00, $00
smpsVcAttackRate $1F, $1F, $1F, $1F
smpsVcAmpMod $00, $00, $00, $00
smpsVcDecayRate1 $03, $05, $0A, $0A
smpsVcDecayRate2 $00, $00, $00, $00
smpsVcDecayLevel $02, $02, $03, $03
smpsVcReleaseRate $0F, $0F, $0F, $0F
smpsVcTotalLevel $00, $00, $0A, $0A
; Synth Brass 2
; Voice $19
; $3A
; $31, $37, $31, $31, $8D, $8D, $8E, $53, $0E, $0E, $0E, $03
; $00, $00, $00, $00, $1F, $FF, $1F, $0F, $17, $28, $26, $80
smpsVcAlgorithm $02
smpsVcFeedback $07
smpsVcUnusedBits $00
smpsVcDetune $03, $03, $03, $03
smpsVcCoarseFreq $01, $01, $07, $01
smpsVcRateScale $01, $02, $02, $02
smpsVcAttackRate $13, $0E, $0D, $0D
smpsVcAmpMod $00, $00, $00, $00
smpsVcDecayRate1 $03, $0E, $0E, $0E
smpsVcDecayRate2 $00, $00, $00, $00
smpsVcDecayLevel $00, $01, $0F, $01
smpsVcReleaseRate $0F, $0F, $0F, $0F
smpsVcTotalLevel $00, $26, $28, $17
; Harpischord
; Voice $1A
; $3B
; $3A, $31, $71, $74, $DF, $1F, $1F, $DF, $00, $0A, $0A, $05
; $00, $05, $05, $03, $0F, $5F, $1F, $5F, $32, $1E, $0F, $80
smpsVcAlgorithm $03
smpsVcFeedback $07
smpsVcUnusedBits $00
smpsVcDetune $07, $07, $03, $03
smpsVcCoarseFreq $04, $01, $01, $0A
smpsVcRateScale $03, $00, $00, $03
smpsVcAttackRate $1F, $1F, $1F, $1F
smpsVcAmpMod $00, $00, $00, $00
smpsVcDecayRate1 $05, $0A, $0A, $00
smpsVcDecayRate2 $03, $05, $05, $00
smpsVcDecayLevel $05, $01, $05, $00
smpsVcReleaseRate $0F, $0F, $0F, $0F
smpsVcTotalLevel $00, $0F, $1E, $32
; Metallic Bass
; Voice $1B
; $05
; $04, $01, $02, $04, $8D, $1F, $15, $52, $06, $00, $00, $04
; $02, $08, $00, $00, $1F, $0F, $0F, $2F, $16, $90, $84, $8C
smpsVcAlgorithm $05
smpsVcFeedback $00
smpsVcUnusedBits $00
smpsVcDetune $00, $00, $00, $00
smpsVcCoarseFreq $04, $02, $01, $04
smpsVcRateScale $01, $00, $00, $02
smpsVcAttackRate $12, $15, $1F, $0D
smpsVcAmpMod $00, $00, $00, $00
smpsVcDecayRate1 $04, $00, $00, $06
smpsVcDecayRate2 $00, $00, $08, $02
smpsVcDecayLevel $02, $00, $00, $01
smpsVcReleaseRate $0F, $0F, $0F, $0F
smpsVcTotalLevel $0C, $04, $10, $16
; Alternate Metallic Bass
; Voice $1C
; $2C
; $71, $74, $32, $32, $1F, $12, $1F, $12, $00, $0A, $00, $0A
; $00, $00, $00, $00, $0F, $1F, $0F, $1F, $16, $80, $17, $80
smpsVcAlgorithm $04
smpsVcFeedback $05
smpsVcUnusedBits $00
smpsVcDetune $03, $03, $07, $07
smpsVcCoarseFreq $02, $02, $04, $01
smpsVcRateScale $00, $00, $00, $00
smpsVcAttackRate $12, $1F, $12, $1F
smpsVcAmpMod $00, $00, $00, $00
smpsVcDecayRate1 $0A, $00, $0A, $00
smpsVcDecayRate2 $00, $00, $00, $00
smpsVcDecayLevel $01, $00, $01, $00
smpsVcReleaseRate $0F, $0F, $0F, $0F
smpsVcTotalLevel $00, $17, $00, $16
; Backdropped Metallic Bass
; Voice $1D
; $3A
; $01, $07, $01, $01, $8E, $8E, $8D, $53, $0E, $0E, $0E, $03
; $00, $00, $00, $07, $1F, $FF, $1F, $0F, $18, $28, $27, $8F
smpsVcAlgorithm $02
smpsVcFeedback $07
smpsVcUnusedBits $00
smpsVcDetune $00, $00, $00, $00
smpsVcCoarseFreq $01, $01, $07, $01
smpsVcRateScale $01, $02, $02, $02
smpsVcAttackRate $13, $0D, $0E, $0E
smpsVcAmpMod $00, $00, $00, $00
smpsVcDecayRate1 $03, $0E, $0E, $0E
smpsVcDecayRate2 $07, $00, $00, $00
smpsVcDecayLevel $00, $01, $0F, $01
smpsVcReleaseRate $0F, $0F, $0F, $0F
smpsVcTotalLevel $0F, $27, $28, $18
; Sine like Bell
; Voice $1E
; $36
; $7A, $32, $51, $11, $1F, $1F, $59, $1C, $0A, $0D, $06, $0A
; $07, $00, $02, $02, $AF, $5F, $5F, $5F, $1E, $8B, $81, $80
smpsVcAlgorithm $06
smpsVcFeedback $06
smpsVcUnusedBits $00
smpsVcDetune $01, $05, $03, $07
smpsVcCoarseFreq $01, $01, $02, $0A
smpsVcRateScale $00, $01, $00, $00
smpsVcAttackRate $1C, $19, $1F, $1F
smpsVcAmpMod $00, $00, $00, $00
smpsVcDecayRate1 $0A, $06, $0D, $0A
smpsVcDecayRate2 $02, $02, $00, $07
smpsVcDecayLevel $05, $05, $05, $0A
smpsVcReleaseRate $0F, $0F, $0F, $0F
smpsVcTotalLevel $00, $01, $0B, $1E
; Synth like Metallic with Small Bell
; Voice $1F
; $3C
; $71, $72, $3F, $34, $8D, $52, $9F, $1F, $09, $00, $00, $0D
; $00, $00, $00, $00, $23, $08, $02, $F7, $15, $85, $1D, $8A
smpsVcAlgorithm $04
smpsVcFeedback $07
smpsVcUnusedBits $00
smpsVcDetune $03, $03, $07, $07
smpsVcCoarseFreq $04, $0F, $02, $01
smpsVcRateScale $00, $02, $01, $02
smpsVcAttackRate $1F, $1F, $12, $0D
smpsVcAmpMod $00, $00, $00, $00
smpsVcDecayRate1 $0D, $00, $00, $09
smpsVcDecayRate2 $00, $00, $00, $00
smpsVcDecayLevel $0F, $00, $00, $02
smpsVcReleaseRate $07, $02, $08, $03
smpsVcTotalLevel $0A, $1D, $05, $15
; Nice Synth like lead
; Voice $20
; $3E
; $77, $71, $32, $31, $1F, $1F, $1F, $1F, $0D, $06, $00, $00
; $08, $06, $00, $00, $15, $0A, $0A, $0A, $1B, $8F, $8F, $8F
smpsVcAlgorithm $06
smpsVcFeedback $07
smpsVcUnusedBits $00
smpsVcDetune $03, $03, $07, $07
smpsVcCoarseFreq $01, $02, $01, $07
smpsVcRateScale $00, $00, $00, $00
smpsVcAttackRate $1F, $1F, $1F, $1F
smpsVcAmpMod $00, $00, $00, $00
smpsVcDecayRate1 $00, $00, $06, $0D
smpsVcDecayRate2 $00, $00, $06, $08
smpsVcDecayLevel $00, $00, $00, $01
smpsVcReleaseRate $0A, $0A, $0A, $05
smpsVcTotalLevel $0F, $0F, $0F, $1B
; Rock Organ
; Voice $21
; $07
; $34, $74, $32, $71, $1F, $1F, $1F, $1F, $0A, $0A, $05, $03
; $00, $00, $00, $00, $3F, $3F, $2F, $2F, $8A, $8A, $8A, $8A
smpsVcAlgorithm $07
smpsVcFeedback $00
smpsVcUnusedBits $00
smpsVcDetune $07, $03, $07, $03
smpsVcCoarseFreq $01, $02, $04, $04
smpsVcRateScale $00, $00, $00, $00
smpsVcAttackRate $1F, $1F, $1F, $1F
smpsVcAmpMod $00, $00, $00, $00
smpsVcDecayRate1 $03, $05, $0A, $0A
smpsVcDecayRate2 $00, $00, $00, $00
smpsVcDecayLevel $02, $02, $03, $03
smpsVcReleaseRate $0F, $0F, $0F, $0F
smpsVcTotalLevel $0A, $0A, $0A, $0A
; Strike like Slap Bass
; Voice $22
; $20
; $36, $35, $30, $31, $DF, $DF, $9F, $9F, $07, $06, $09, $06
; $07, $06, $06, $08, $20, $10, $10, $F8, $19, $37, $13, $80
smpsVcAlgorithm $00
smpsVcFeedback $04
smpsVcUnusedBits $00
smpsVcDetune $03, $03, $03, $03
smpsVcCoarseFreq $01, $00, $05, $06
smpsVcRateScale $02, $02, $03, $03
smpsVcAttackRate $1F, $1F, $1F, $1F
smpsVcAmpMod $00, $00, $00, $00
smpsVcDecayRate1 $06, $09, $06, $07
smpsVcDecayRate2 $08, $06, $06, $07
smpsVcDecayLevel $0F, $01, $01, $02
smpsVcReleaseRate $08, $00, $00, $00
smpsVcTotalLevel $00, $13, $37, $19
|
oeis/028/A028161.asm | neoneye/loda-programs | 11 | 93653 | ; A028161: Expansion of 1/((1-4*x)*(1-9*x)*(1-10*x)*(1-11*x)).
; Submitted by <NAME>
; 1,34,737,12998,203493,2949042,40498969,534679966,6850824365,85749662570,1053427606881,12745999413654,152297310673717,1800758893450018,21104410600012073,245479747499528462
mov $1,1
mov $2,$0
mov $3,$0
lpb $2
mov $0,$3
sub $2,1
sub $0,$2
seq $0,19742 ; Expansion of 1/((1-4x)(1-10x)(1-11x)).
mul $1,9
add $1,$0
lpe
mov $0,$1
|
programs/oeis/082/A082413.asm | karttu/loda | 1 | 102646 | ; A082413: a(n) = (2*9^n + 3^n)/3.
; 1,7,57,495,4401,39447,354537,3189375,28700001,258286887,2324542617,20920765455,188286534801,1694577750327,15251196564297,137260759512735,1235346806916801,11118121176157767
mov $2,3
pow $2,$0
mov $1,$2
pow $2,2
div $1,2
add $1,$2
div $1,3
mul $1,2
add $1,1
|
data/mapObjects/unknowndungeon2.asm | adhi-thirumala/EvoYellow | 16 | 91978 | UnknownDungeon2Object:
db $7d ; border block
db $6 ; warps
db $1, $1d, $2, UNKNOWN_DUNGEON_1
db $6, $16, $3, UNKNOWN_DUNGEON_1
db $7, $13, $4, UNKNOWN_DUNGEON_1
db $1, $9, $5, UNKNOWN_DUNGEON_1
db $3, $1, $6, UNKNOWN_DUNGEON_1
db $b, $3, $7, UNKNOWN_DUNGEON_1
db $0 ; signs
db $4 ; objects
object SPRITE_BALL, $0, $b, STAY, NONE, $1, RARE_CANDY
object SPRITE_BALL, $10, $7, STAY, NONE, $2, ULTRA_BALL
object SPRITE_BALL, $13, $b, STAY, NONE, $3, MAX_REVIVE
object SPRITE_BALL, $1b, $9, STAY, NONE, $4, FULL_RESTORE
; warp-to
EVENT_DISP UNKNOWN_DUNGEON_2_WIDTH, $1, $1d ; UNKNOWN_DUNGEON_1
EVENT_DISP UNKNOWN_DUNGEON_2_WIDTH, $6, $16 ; UNKNOWN_DUNGEON_1
EVENT_DISP UNKNOWN_DUNGEON_2_WIDTH, $7, $13 ; UNKNOWN_DUNGEON_1
EVENT_DISP UNKNOWN_DUNGEON_2_WIDTH, $1, $9 ; UNKNOWN_DUNGEON_1
EVENT_DISP UNKNOWN_DUNGEON_2_WIDTH, $3, $1 ; UNKNOWN_DUNGEON_1
EVENT_DISP UNKNOWN_DUNGEON_2_WIDTH, $b, $3 ; UNKNOWN_DUNGEON_1
|
School Directory Project/test_data/ben.asm | AriaPahlavan/Fall-2014-EE-306-Projects-Assembly-Binary | 1 | 246596 | <reponame>AriaPahlavan/Fall-2014-EE-306-Projects-Assembly-Binary<filename>School Directory Project/test_data/ben.asm<gh_stars>1-10
.ORIG x4050
.STRINGZ "BEN"
.END
|
agda/sn-calculus-props.agda | florence/esterel-calculus | 3 | 13301 | <reponame>florence/esterel-calculus<filename>agda/sn-calculus-props.agda
module _ where
open import Data.Nat using (ℕ ; _+_ ; _≤′_ ; suc)
open import Induction.Nat using (<′-rec)
open import Esterel.Lang.CanFunction
open import Function using (_∋_ ; _∘_ ; id ; _$_)
open import Data.Nat.Properties.Simple using ( +-comm ; +-assoc)
open import utility
open import noetherian using (noetherian ; ∥_∥s)
open import Esterel.Lang
open import Esterel.Lang.Properties
open import Esterel.Environment as Env
open import Esterel.Context
open import Data.Product
open import Data.Sum
open import Data.Bool
open import Data.List using ([] ; [_] ; _∷_ ; List ; _++_)
open import Relation.Nullary
open import Relation.Binary.PropositionalEquality using (_≡_ ; refl ; sym ; subst ; cong ; trans ; module ≡-Reasoning ; cong₂ ; subst₂ ; inspect)
open import Data.Empty
open import sn-calculus
open import context-properties -- get view, E-views
open import Esterel.Lang.Binding
open import Data.Maybe using ( just )
-- open import coherence
open import Data.List.Any
open import Data.List.Any.Properties
open import Esterel.Lang.CanFunction.Base
open import eval
open import blocked
open import Data.List.All
open ≡-Reasoning using (_≡⟨_⟩_ ; _≡⟨⟩_ ; _∎)
open import Relation.Nullary.Decidable
using (⌊_⌋)
open import Data.FiniteMap
import Data.OrderedListMap as OMap
open import Esterel.Variable.Signal as Signal
using (Signal ; _ₛ)
open import Esterel.Variable.Shared as SharedVar
using (SharedVar ; _ₛₕ)
open import Esterel.Variable.Sequential as SeqVar
using (SeqVar ; _ᵥ)
open import Esterel.CompletionCode as Code
using () renaming (CompletionCode to Code)
open import sn-calculus-compatconf using (1-step)
open import Data.OrderedListMap Signal Signal.unwrap Signal.Status as SigM
open import Data.OrderedListMap SharedVar SharedVar.unwrap (Σ SharedVar.Status (λ _ → ℕ)) as ShrM
open import Data.OrderedListMap SeqVar SeqVar.unwrap ℕ as SeqM
open import binding-preserve
{- definition of two relations commuting
(wrt to Correct Binding) -}
CB-COMMUTE : (Term -> Term -> Set) ->
(Term -> Term -> Set) ->
Set
CB-COMMUTE R1 R2 =
∀ {p q r BV FV} ->
CorrectBinding p BV FV ->
R1 p q ->
R2 p r ->
∃ λ {z → (R2 q z × R1 r z)}
{- a relation that commutes with itself is confluent -}
CB-CONFLUENT : (Term -> Term -> Set) -> Set
CB-CONFLUENT R = CB-COMMUTE R R
sn⟶*-confluent : CB-CONFLUENT _sn⟶*_
sn⟶*-confluent {p} {q} {r} {BV} {FV} CB =
newman ∥ p ∥s p q r BV FV refl CB where
{-
Proof of Newman's lemma from:
_Confluent Reductions: Abstract Properties and Applications to Term
Rewriting Systems_ by <NAME>. Oct 1980; JACM volume 27 issue 4
https://dl.acm.org/citation.cfm?id=322230
-}
newmantype : ℕ -> Set
newmantype c = ∀ p q r BV FV ->
∥ p ∥s ≡ c ->
CorrectBinding p BV FV ->
p sn⟶* q ->
p sn⟶* r ->
Σ[ z ∈ Term ] (q sn⟶* z × r sn⟶* z)
step : ∀ (c : ℕ) ->
((c′ : ℕ) → suc c′ ≤′ c → newmantype c′)
-> (newmantype c)
step c rec x .x z BV FV nsx≡c CB rrefl s*xz = z , (s*xz , rrefl)
step c rec x y .x BV FV nsx≡c CB s*xy rrefl = y , (rrefl , s*xy)
step c rec x y z BV FV refl CB
(rstep {.x} {y1} {.y} sxy1 s*y1y)
(rstep {.x} {z1} {.z} sxz1 s*z1z)
with 1-step {x} {y1} {z1} {BV} {FV} CB sxy1 sxz1
... | (u , s*y1u , s*z1u) with sn⟶-maintains-binding CB sxy1
... | (BVy1 , FVy1) , (CBy1 , _) with sn⟶-maintains-binding CB sxz1
... | (BVz1 , FVz1) , (CBz1 , _) with rec ∥ y1 ∥s (noetherian{x}{y1} sxy1)
y1 y u BVy1 FVy1 refl CBy1 s*y1y s*y1u
... | (v , s*yv , s*uv) with rec ∥ z1 ∥s (noetherian{x}{z1} sxz1)
z1 v z BVz1 FVz1 refl CBz1 (sn⟶*+ s*z1u s*uv) s*z1z
... | (t , s*vt , s*zt) = t , (sn⟶*+ s*yv s*vt) , s*zt
newman : ∀ c -> newmantype c
newman = <′-rec _ step
lift-sn⟶* : ∀ {p q} → (P : Term → Set) → (∀ {p q} → P p → p sn⟶ q → P q) → P p → p sn⟶* q → P q
lift-sn⟶* P P-respects-sn⟶ Pp rrefl = Pp
lift-sn⟶* P P-respects-sn⟶ Pp (rstep psn⟶r rsn⟶*q) =
lift-sn⟶* P P-respects-sn⟶ (P-respects-sn⟶ Pp psn⟶r) rsn⟶*q
sn≡ₑ-preserve-cb : ∀{p q BV FV} → CorrectBinding p BV FV → p sn≡ₑ q → Σ (VarList × VarList) λ {(BVq , FVq) → CorrectBinding q BVq FVq}
sn≡ₑ-preserve-cb cb (rstp x) with sn⟶-maintains-binding cb x
... | (bv,fv , cbq , _)= _ , cbq
sn≡ₑ-preserve-cb cb (rsym psn≡ₑq x) = _ , x
sn≡ₑ-preserve-cb cb rref = _ , cb
sn≡ₑ-preserve-cb cb (rtrn psn≡ₑq psn≡ₑq₁) = sn≡ₑ-preserve-cb (proj₂ (sn≡ₑ-preserve-cb cb psn≡ₑq)) psn≡ₑq₁
sn≡ₑ-consistent : ∀{p q BV FV} → CorrectBinding p BV FV → p sn≡ₑ q → Σ[ r ∈ Term ] p sn⟶* r × q sn⟶* r
sn≡ₑ-consistent cb (rstp x) = _ , rstep x rrefl , rrefl
sn≡ₑ-consistent cb (rsym qsn≡ₑp cbq) with sn≡ₑ-consistent cbq qsn≡ₑp
... | (r , qsn⟶r , psn⟶r ) = (r , psn⟶r , qsn⟶r)
sn≡ₑ-consistent cb rref = _ , rrefl , rrefl
sn≡ₑ-consistent cb (rtrn psn≡ₑs ssn≡ₑq) with (sn≡ₑ-preserve-cb cb psn≡ₑs)
... | (_ , cbs) with sn≡ₑ-consistent cb psn≡ₑs | sn≡ₑ-consistent cbs ssn≡ₑq
... | (rl , psn⟶*rl , ssn⟶*rl) | (rr , ssn⟶*rr , qsn⟶*rr) with sn⟶*-confluent cbs ssn⟶*rl ssn⟶*rr
... | (r , rlsn⟶*r , rrsn⟶*r) = r , (sn⟶*+ psn⟶*rl rlsn⟶*r , sn⟶*+ qsn⟶*rr rrsn⟶*r )
irreducibility-of-complete-sn⟶₁ : ∀{p q} → complete p → p sn⟶₁ q → ⊥
irreducibility-of-complete-sn⟶₁ (codone p/done) psn⟶₁q = done-¬sn⟶₁ p/done psn⟶₁q
irreducibility-of-complete-sn⟶₁ (coenv {θ} (θcomplete x x₁) p/done) ρθpsn⟶₁ρθ'q
with ρ-stays-ρ-sn⟶₁ ρθpsn⟶₁ρθ'q
... | θ' , q , A' , refl with get-view ρθpsn⟶₁ρθ'q
irreducibility-of-complete-sn⟶₁ (coenv {θ} (θcomplete x x₁) p/done) ρθpsn⟶₁ρθ'q
| θ' , q , A' , refl | inj₁ (E , pin , qin , p≐E⟦pin⟧ , q≐E⟦qin⟧ , e-view) =
⊥-elim
(done-E-view-term-disjoint
(done-⟦⟧e p/done p≐E⟦pin⟧)
(->E-view-inner-term e-view))
irreducibility-of-complete-sn⟶₁ (coenv {θ} (θcomplete x x₁) p/done) ρθpsn⟶₁ρθ'q
| θ' , q , A' , refl | inj₂ (refl , refl , vabsence S S∈ x₂ x₃)
with x S S∈
... | inj₁ S≡ = lookup-S-eq θ S S∈ S∈ S≡ x₂ (λ ())
... | inj₂ S≡ = lookup-S-eq θ S S∈ S∈ S≡ x₂ (λ ())
irreducibility-of-complete-sn⟶₁ (coenv {θ} (θcomplete x x₁) p/done) ρθpsn⟶₁ρθ'q
| θ' , q , A' , refl | inj₂ (refl , refl , vreadyness s s∈ x₂ x₃)
with x₁ s s∈
... | s≡ with x₂
... | inj₁ s2≡ = lookup-s-eq θ s s∈ s∈ s≡ s2≡ (λ ())
... | inj₂ s2≡ = lookup-s-eq θ s s∈ s∈ s≡ s2≡ (λ ())
inescapability-of-paused-sn⟶ : ∀ {p q} ->
paused p ->
p sn⟶ q ->
paused q
inescapability-of-paused-sn⟶ ppause (rcontext .[] dchole ())
inescapability-of-paused-sn⟶ (pseq ()) (rcontext .[] dchole rseq-done)
inescapability-of-paused-sn⟶ (pseq ()) (rcontext .[] dchole rseq-exit)
inescapability-of-paused-sn⟶ (pseq pausedp) (rcontext _ (dcseq₁ dc) psn⟶₁p')
= pseq (inescapability-of-paused-sn⟶ pausedp (rcontext _ dc psn⟶₁p'))
inescapability-of-paused-sn⟶ (pseq pausedp) (rcontext _ (dcseq₂ dc) psn⟶₁p')
= pseq pausedp
inescapability-of-paused-sn⟶ (ploopˢ ()) (rcontext .[] dchole rloopˢ-exit)
inescapability-of-paused-sn⟶ (ploopˢ pausedp) (rcontext _ (dcloopˢ₁ dc) psn⟶₁p')
= ploopˢ (inescapability-of-paused-sn⟶ pausedp (rcontext _ dc psn⟶₁p'))
inescapability-of-paused-sn⟶ (ploopˢ pausedp) (rcontext _ (dcloopˢ₂ dc) psn⟶₁p')
= ploopˢ pausedp
inescapability-of-paused-sn⟶ (ppar pausedp _) (rcontext .[] dchole (rpar-done-right p' q'))
= ⊥-elim (halted-paused-disjoint p' pausedp)
inescapability-of-paused-sn⟶ (ppar _ pausedq) (rcontext .[] dchole (rpar-done-left p' q'))
= ⊥-elim (halted-paused-disjoint q' pausedq)
inescapability-of-paused-sn⟶ (ppar pausedp pausedq) (rcontext _ (dcpar₁ dc) psn⟶₁p')
= ppar (inescapability-of-paused-sn⟶ pausedp (rcontext _ dc psn⟶₁p')) pausedq
inescapability-of-paused-sn⟶ (ppar pausedp pausedq) (rcontext _ (dcpar₂ dc) psn⟶₁p')
= ppar pausedp (inescapability-of-paused-sn⟶ pausedq (rcontext _ dc psn⟶₁p'))
inescapability-of-paused-sn⟶ (psuspend pausedp) (rcontext .[] dchole (rsuspend-done haltedp))
= ⊥-elim (halted-paused-disjoint haltedp pausedp)
inescapability-of-paused-sn⟶ (psuspend pausedp) (rcontext _ (dcsuspend dc) psn⟶₁p')
= psuspend (inescapability-of-paused-sn⟶ pausedp (rcontext _ dc psn⟶₁p'))
inescapability-of-paused-sn⟶ (ptrap ()) (rcontext .[] dchole (rtrap-done hnothin))
inescapability-of-paused-sn⟶ (ptrap ()) (rcontext .[] dchole (rtrap-done (hexit n)))
inescapability-of-paused-sn⟶ (ptrap pausedp) (rcontext _ (dctrap dc) psn⟶₁p')
= ptrap (inescapability-of-paused-sn⟶ pausedp (rcontext _ dc psn⟶₁p'))
inescapability-of-paused-sn⟶* : ∀ {p q} ->
paused p ->
p sn⟶* q ->
paused q
inescapability-of-paused-sn⟶* pausedp rrefl = pausedp
inescapability-of-paused-sn⟶* pausedp (rstep psn⟶r r⟶q)
= inescapability-of-paused-sn⟶* (inescapability-of-paused-sn⟶ pausedp psn⟶r) r⟶q
inescapability-of-complete-sn⟶ : ∀{p q} → complete p → p sn⟶ q → complete q
inescapability-of-complete-sn⟶ c@(codone p-done) psn⟶q = codone (done-sn⟶ p-done psn⟶q)
inescapability-of-complete-sn⟶ c@(coenv x x₁) (rcontext .[] dchole psn⟶₁p') = ⊥-elim (irreducibility-of-complete-sn⟶₁ c psn⟶₁p')
inescapability-of-complete-sn⟶ (coenv x (dhalted hnothin)) (rcontext .(cenv _ _ ∷ []) (dcenv dchole) psn⟶₁p')
= ⊥-elim (irreducibility-of-complete-sn⟶₁ (codone (dhalted hnothin)) psn⟶₁p')
inescapability-of-complete-sn⟶ (coenv x (dhalted (hexit n))) (rcontext .(cenv _ _ ∷ []) (dcenv dchole) psn⟶₁p')
= ⊥-elim (irreducibility-of-complete-sn⟶₁ (codone (dhalted (hexit n))) psn⟶₁p')
inescapability-of-complete-sn⟶ (coenv x (dpaused p/paused)) (rcontext .(cenv _ _ ∷ _) (dcenv dc) psn⟶₁p')
with (inescapability-of-complete-sn⟶ (codone (dpaused p/paused)) (rcontext _ dc psn⟶₁p'))
inescapability-of-complete-sn⟶ (coenv x (dpaused ppause)) (rcontext .(cenv _ _ ∷ _) (dcenv dchole) psn⟶₁p') | rec
= ⊥-elim (irreducibility-of-complete-sn⟶₁ (codone (dpaused ppause)) psn⟶₁p')
inescapability-of-complete-sn⟶ (coenv x₁ (dpaused (ploopˢ p/paused))) (rcontext .(cenv _ _ ∷ []) (dcenv dchole) psn⟶₁p') | rec
= ⊥-elim (irreducibility-of-complete-sn⟶₁ (codone (dpaused (ploopˢ p/paused))) psn⟶₁p')
inescapability-of-complete-sn⟶ (coenv x₁ (dpaused (ploopˢ p/paused))) (rcontext .(cenv _ _ ∷ ceval (eloopˢ _) ∷ _) (dcenv (dcloopˢ₁ dc)) psn⟶₁p') | codone x
= coenv x₁ x
inescapability-of-complete-sn⟶ (coenv x₁ (dpaused (ploopˢ p/paused))) (rcontext .(cenv _ _ ∷ cloopˢ₂ _ ∷ _) (dcenv (dcloopˢ₂ dc)) psn⟶₁p') | codone x
= coenv x₁ x
inescapability-of-complete-sn⟶ (coenv x₁ (dpaused (pseq p/paused))) (rcontext .(cenv _ _ ∷ []) (dcenv dchole) psn⟶₁p') | rec
= ⊥-elim (irreducibility-of-complete-sn⟶₁ (codone (dpaused (pseq p/paused))) psn⟶₁p')
inescapability-of-complete-sn⟶ (coenv x₁ (dpaused (pseq p/paused))) (rcontext .(cenv _ _ ∷ ceval (eseq _) ∷ _) (dcenv (dcseq₁ dc)) psn⟶₁p') | codone x
= coenv x₁ x
inescapability-of-complete-sn⟶ (coenv x₁ (dpaused (pseq p/paused))) (rcontext .(cenv _ _ ∷ cseq₂ _ ∷ _) (dcenv (dcseq₂ dc)) psn⟶₁p') | codone x
= coenv x₁ x
inescapability-of-complete-sn⟶ (coenv x (dpaused (ppar p/paused p/paused₁))) (rcontext .(cenv _ _ ∷ []) (dcenv dchole) psn⟶₁p') | rec
= ⊥-elim (irreducibility-of-complete-sn⟶₁ (codone (dpaused (ppar p/paused p/paused₁))) psn⟶₁p')
inescapability-of-complete-sn⟶ (coenv x₁ (dpaused (ppar p/paused p/paused₁))) (rcontext .(cenv _ _ ∷ ceval (epar₁ _) ∷ _) (dcenv (dcpar₁ dc)) psn⟶₁p') | codone x
= coenv x₁ x
inescapability-of-complete-sn⟶ (coenv x₁ (dpaused (ppar p/paused p/paused₁))) (rcontext .(cenv _ _ ∷ ceval (epar₂ _) ∷ _) (dcenv (dcpar₂ dc)) psn⟶₁p') | codone x = coenv x₁ x
inescapability-of-complete-sn⟶ (coenv x (dpaused (psuspend p/paused))) (rcontext .(cenv _ _ ∷ []) (dcenv dchole) psn⟶₁p') | rec
= ⊥-elim (irreducibility-of-complete-sn⟶₁ (codone (dpaused (psuspend p/paused))) psn⟶₁p')
inescapability-of-complete-sn⟶ (coenv x₁ (dpaused (psuspend p/paused))) (rcontext .(cenv _ _ ∷ ceval (esuspend _) ∷ _) (dcenv (dcsuspend dc)) psn⟶₁p') | codone x = coenv x₁ x
inescapability-of-complete-sn⟶ (coenv x (dpaused (ptrap p/paused))) (rcontext .(cenv _ _ ∷ []) (dcenv dchole) psn⟶₁p') | rec
= ⊥-elim (irreducibility-of-complete-sn⟶₁ (codone (dpaused (ptrap p/paused))) psn⟶₁p')
inescapability-of-complete-sn⟶ (coenv x₁ (dpaused (ptrap p/paused))) (rcontext .(cenv _ _ ∷ ceval etrap ∷ _) (dcenv (dctrap dc)) psn⟶₁p') | codone x = coenv x₁ x
inescapability-of-complete-sn : ∀{p q} → complete p → p sn⟶* q → complete q
inescapability-of-complete-sn = lift-sn⟶* complete inescapability-of-complete-sn⟶
equality-of-complete-sn⟶* : ∀{θ θ' p q A A'} →
complete (ρ⟨ θ , A ⟩· p) →
(ρ⟨ θ , A ⟩· p) sn⟶* (ρ⟨ θ' , A' ⟩· q) →
θ ≡ θ' × A ≡ A'
equality-of-complete-sn⟶* ρθp/complete rrefl = refl , refl
equality-of-complete-sn⟶* ρθp/complete (rstep (rcontext _ dchole ρθpsn⟶₁ρθ''r) ρθ''rsn⟶*ρθ'q)
with irreducibility-of-complete-sn⟶₁ ρθp/complete ρθpsn⟶₁ρθ''r
... | ()
equality-of-complete-sn⟶* ρθp/complete (rstep (rcontext _ (dcenv ρθp≐C⟦p'⟧) p'sn⟶₁r) ρθrsn⟶*ρθ'q) =
equality-of-complete-sn⟶*
(inescapability-of-complete-sn⟶ ρθp/complete (rcontext _ (dcenv ρθp≐C⟦p'⟧) p'sn⟶₁r))
ρθrsn⟶*ρθ'q
get-view/blocked : ∀{θ θ' p q A A'} →
blocked θ A p →
(ρθpsn⟶₁ρθ'q : ρ⟨ θ , A ⟩· p sn⟶₁ ρ⟨ θ' , A' ⟩· q) →
∃ (λ a → ∃ (->pot-view ρθpsn⟶₁ρθ'q a))
get-view/blocked p/blocked ρθpsn⟶₁ρθ'q with get-view ρθpsn⟶₁ρθ'q
... | inj₂ refl-pot-view = refl-pot-view
... | inj₁ (E , pin , qin , p≐E⟦pin⟧ , q≐E⟦qin⟧ , e-view)
with blocked-⟦⟧e p/blocked p≐E⟦pin⟧ | ->E-view-inner-term e-view
... | inj₂ pin/done | e-view-term =
⊥-elim
(done-E-view-term-disjoint
pin/done
(->E-view-inner-term e-view))
... | (inj₁ (bpar-both pin'/blocked qin'/blocked)) | ()
... | (inj₁ (bpar-left pin'/blocked qin'/done)) | ()
... | (inj₁ (bpar-right pin'/done qin'/blocked)) | ()
... | (inj₁ (bloopˢ pin/blocked)) | ()
... | (inj₁ (bseq pin/blocked)) | ()
... | (inj₁ (bsusp pin/blocked)) | ()
... | (inj₁ (btrap pin/blocked)) | ()
get-view/blocked {θ} p/blocked (ris-present S∈' θS≡present .p≐E⟦pin⟧)
| inj₁ (E , pin , qin , p≐E⟦pin⟧ , q≐E⟦qin⟧ , vis-present)
| (inj₁ (bsig-exists S S∈ θS≡unknown)) | evt-present
with trans (sym θS≡present) (trans (Env.sig-stats-∈-irr {S} {θ} S∈' S∈) θS≡unknown)
... | ()
get-view/blocked {θ} p/blocked (ris-absent S∈' θS≡absent .p≐E⟦pin⟧)
| inj₁ (E , pin , qin , p≐E⟦pin⟧ , q≐E⟦qin⟧ , vis-absent)
| (inj₁ (bsig-exists S S∈ θS≡unknown)) | evt-present
with trans (sym θS≡absent) (trans (Env.sig-stats-∈-irr {S} {θ} S∈' S∈) θS≡unknown)
... | ()
get-view/blocked p/blocked (rraise-shared {s = s} e' .p≐E⟦pin⟧)
| inj₁ (E , pin , qin , p≐E⟦pin⟧ , q≐E⟦qin⟧ , vraise-shared)
| (inj₁ (bshared e/blocked)) | evt-raise-shared =
⊥-elim (all-ready-blocked-disjoint (e' , e/blocked))
get-view/blocked p/blocked (rset-shared-value-old {s = s} e' s∈ θs≡old .p≐E⟦pin⟧)
| inj₁ (E , pin , qin , p≐E⟦pin⟧ , q≐E⟦qin⟧ , vset-shared-value-old)
| (inj₁ (bsset e/blocked)) | evt-set-shared =
⊥-elim (all-ready-blocked-disjoint (e' , e/blocked))
get-view/blocked p/blocked (rset-shared-value-new {s = s} e' s∈ θs≡new .p≐E⟦pin⟧)
| inj₁ (E , pin , qin , p≐E⟦pin⟧ , q≐E⟦qin⟧ , vset-shared-value-new)
| (inj₁ (bsset e/blocked)) | evt-set-shared =
⊥-elim (all-ready-blocked-disjoint (e' , e/blocked))
get-view/blocked p/blocked (rraise-var {x = x} e' .p≐E⟦pin⟧)
| inj₁ (E , pin , qin , p≐E⟦pin⟧ , q≐E⟦qin⟧ , vraise-var)
| (inj₁ (bvar e/blocked)) | evt-raise-var =
⊥-elim (all-ready-blocked-disjoint (e' , e/blocked))
get-view/blocked p/blocked (rset-var {x = x} x∈ e' .p≐E⟦pin⟧)
| inj₁ (E , pin , qin , p≐E⟦pin⟧ , q≐E⟦qin⟧ , vset-var)
| (inj₁ (bxset e/blocked)) | evt-set-var =
⊥-elim (all-ready-blocked-disjoint (e' , e/blocked))
get-view/blocked {A = .WAIT} p/blocked ρθpsn⟶₁ρθ'q | inj₁ (E , s ⇐ e , qin , p≐E⟦pin⟧ , q≐E⟦qin⟧ , ())
| inj₁ bwset | evt-set-shared
get-view/blocked {A = .WAIT} p/blocked ρθpsn⟶₁ρθ'q | inj₁ (E , emit S , qin , p≐E⟦pin⟧ , q≐E⟦qin⟧ , ())
| inj₁ bwemit | evt-emit
irreducibility-of-blocked-sn⟶₁ : ∀ {θ p q A} → blocked θ A p → p sn⟶₁ q → ⊥
irreducibility-of-blocked-sn⟶₁ (bsig-exists S S∈ θS≡unknown) ()
irreducibility-of-blocked-sn⟶₁ (bshared e/blocked) ()
irreducibility-of-blocked-sn⟶₁ (bsset e/blocked) ()
irreducibility-of-blocked-sn⟶₁ (bvar e/blocked) ()
irreducibility-of-blocked-sn⟶₁ (bxset e/blocked) ()
irreducibility-of-blocked-sn⟶₁ {p = s ⇐ e} {A = WAIT} bwset ()
irreducibility-of-blocked-sn⟶₁ {p = emit S} {A = WAIT} bwemit ()
irreducibility-of-blocked-sn⟶₁ (bpar-both p/blocked q/blocked)
(rpar-done-right p/halted q/done) =
halted-blocked-disjoint p/halted p/blocked
irreducibility-of-blocked-sn⟶₁ (bpar-left p/blocked q/done)
(rpar-done-right p/halted q/done') =
halted-blocked-disjoint p/halted p/blocked
irreducibility-of-blocked-sn⟶₁ (bpar-right p/done q/blocked)
(rpar-done-right p/halted q/done) =
done-blocked-disjoint q/done q/blocked
irreducibility-of-blocked-sn⟶₁ (bpar-both p/blocked q/blocked)
(rpar-done-left p/done q/halted) =
halted-blocked-disjoint q/halted q/blocked
irreducibility-of-blocked-sn⟶₁ (bpar-left p/blocked q/done)
(rpar-done-left p/done q/halted) =
done-blocked-disjoint p/done p/blocked
irreducibility-of-blocked-sn⟶₁ (bpar-right p/done q/blocked)
(rpar-done-left p/done' q/halted) =
halted-blocked-disjoint q/halted q/blocked
irreducibility-of-blocked-sn⟶₁ (bseq ())
rseq-done
irreducibility-of-blocked-sn⟶₁ (bseq ())
rseq-exit
irreducibility-of-blocked-sn⟶₁ (bloopˢ ())
rloopˢ-exit
irreducibility-of-blocked-sn⟶₁ (bsusp p/blocked)
(rsuspend-done p/halted) =
halted-blocked-disjoint p/halted p/blocked
irreducibility-of-blocked-sn⟶₁ (btrap p/blocked)
(rtrap-done p/halted) =
halted-blocked-disjoint p/halted p/blocked
irreducibility-of-halted-sn⟶ : ∀ {p q} ->
halted p ->
p sn⟶ q ->
⊥
irreducibility-of-halted-sn⟶ hnothin (rcontext [] dchole ())
irreducibility-of-halted-sn⟶ (hexit n) (rcontext [] dchole ())
-- not sure if it's worthwhile for now to also prove this for ρ θ · p sn⟶₁ ρ θ' · p
inescapability-of-blocked-inside-sn⟶ : ∀{θ p q A} →
blocked θ A p →
p sn⟶ q →
blocked θ A q
inescapability-of-blocked-inside-sn⟶ p/blocked (rcontext _ dchole psn⟶₁p') =
⊥-elim (irreducibility-of-blocked-sn⟶₁ p/blocked psn⟶₁p')
inescapability-of-blocked-inside-sn⟶ (bpar-both p/blocked q/blocked)
(rcontext _ (dcpar₁ p≐C⟦pin⟧) pinsn⟶₁pin') =
bpar-both
(inescapability-of-blocked-inside-sn⟶ p/blocked
(rcontext _ p≐C⟦pin⟧ pinsn⟶₁pin'))
q/blocked
inescapability-of-blocked-inside-sn⟶ (bpar-both p/blocked q/blocked)
(rcontext _ (dcpar₂ p≐C⟦pin⟧) pinsn⟶₁pin') =
bpar-both p/blocked
(inescapability-of-blocked-inside-sn⟶ q/blocked
(rcontext _ p≐C⟦pin⟧ pinsn⟶₁pin'))
inescapability-of-blocked-inside-sn⟶ (bpar-left p/blocked q/done)
(rcontext _ (dcpar₁ p≐C⟦pin⟧) pinsn⟶₁pin') =
bpar-left
(inescapability-of-blocked-inside-sn⟶ p/blocked
(rcontext _ p≐C⟦pin⟧ pinsn⟶₁pin'))
q/done
inescapability-of-blocked-inside-sn⟶ (bpar-left p/blocked q/done)
(rcontext _ (dcpar₂ p≐C⟦pin⟧) pinsn⟶₁pin') =
bpar-left p/blocked
(done-sn⟶ q/done (rcontext _ p≐C⟦pin⟧ pinsn⟶₁pin'))
inescapability-of-blocked-inside-sn⟶ (bpar-right p/done q/blocked)
(rcontext _ (dcpar₁ p≐C⟦pin⟧) pinsn⟶₁pin') =
bpar-right (done-sn⟶ p/done (rcontext _ p≐C⟦pin⟧ pinsn⟶₁pin'))
q/blocked
inescapability-of-blocked-inside-sn⟶ (bpar-right p/done q/blocked)
(rcontext _ (dcpar₂ p≐C⟦pin⟧) pinsn⟶₁pin') =
bpar-right p/done
(inescapability-of-blocked-inside-sn⟶ q/blocked
(rcontext _ p≐C⟦pin⟧ pinsn⟶₁pin'))
inescapability-of-blocked-inside-sn⟶ (bseq p/blocked)
(rcontext _ (dcseq₁ p≐C⟦pin⟧) pinsn⟶₁pin') =
bseq
(inescapability-of-blocked-inside-sn⟶ p/blocked
(rcontext _ p≐C⟦pin⟧ pinsn⟶₁pin'))
inescapability-of-blocked-inside-sn⟶ (bseq p/blocked)
(rcontext _ (dcseq₂ p≐C⟦pin⟧) pinsn⟶₁pin') =
bseq p/blocked
inescapability-of-blocked-inside-sn⟶ (bloopˢ p/blocked)
(rcontext _ (dcloopˢ₁ p≐C⟦pin⟧) pinsn⟶₁pin') =
bloopˢ
(inescapability-of-blocked-inside-sn⟶ p/blocked
(rcontext _ p≐C⟦pin⟧ pinsn⟶₁pin'))
inescapability-of-blocked-inside-sn⟶ (bloopˢ p/blocked)
(rcontext _ (dcloopˢ₂ p≐C⟦pin⟧) pinsn⟶₁pin') =
bloopˢ p/blocked
inescapability-of-blocked-inside-sn⟶ (bsusp p/blocked)
(rcontext _ (dcsuspend p≐C⟦pin⟧) pinsn⟶₁pin') =
bsusp
(inescapability-of-blocked-inside-sn⟶ p/blocked
(rcontext _ p≐C⟦pin⟧ pinsn⟶₁pin'))
inescapability-of-blocked-inside-sn⟶ (btrap p/blocked)
(rcontext _ (dctrap p≐C⟦pin⟧) pinsn⟶₁pin') =
btrap
(inescapability-of-blocked-inside-sn⟶ p/blocked
(rcontext _ p≐C⟦pin⟧ pinsn⟶₁pin'))
inescapability-of-blocked-inside-sn⟶ (bshared e/blocked)
(rcontext _ (dcshared p≐C⟦pin⟧) pinsn⟶₁pin') =
bshared e/blocked
inescapability-of-blocked-inside-sn⟶ (bvar e/blocked)
(rcontext _ (dcvar p≐C⟦pin⟧) pinsn⟶₁pin') =
bvar e/blocked
inescapability-of-blocked-inside-sn⟶ {θ} {A = A}(bsig-exists S S∈ θS≡unknown)
(rcontext _ S?p:q≐C⟦pin⟧ pinsn⟶₁pin') with S?p:q≐C⟦pin⟧
-- we still have the dchole case here since Agda can't determine that it cannot happen
... | dchole = ⊥-elim (irreducibility-of-blocked-sn⟶₁ {A = A} (bsig-exists {θ} S S∈ θS≡unknown) pinsn⟶₁pin')
... | dcpresent₁ p≐C⟦pin⟧ = bsig-exists S S∈ θS≡unknown
... | dcpresent₂ p≐C⟦pin⟧ = bsig-exists S S∈ θS≡unknown
|
Working Disassembly/General/Sprites/Robotnik/Map - Dragonfly.asm | TeamASM-Blur/Sonic-3-Blue-Balls-Edition | 5 | 18152 | ; Dragonfly mappings
dc.w word_8DFEE-Map_Dragonfly
dc.w word_8E008-Map_Dragonfly
dc.w word_8E022-Map_Dragonfly
dc.w word_8E03C-Map_Dragonfly
dc.w word_8E056-Map_Dragonfly
dc.w word_8E070-Map_Dragonfly
dc.w word_8E078-Map_Dragonfly
dc.w word_8E080-Map_Dragonfly
dc.w word_8E08E-Map_Dragonfly
dc.w word_8E09C-Map_Dragonfly
word_8DFEE: dc.w 4 ; DATA XREF: ROM:0008DFDAo
dc.b $FA, 4, 0, 4, $FF, $F8
dc.b $FC, 0, 0, 6, $FF, $F0
dc.b $FC, 0, 0, 6, 0, 8
dc.b $F8, 5, 0, 0, $FF, $F8
word_8E008: dc.w 4 ; DATA XREF: ROM:0008DFDAo
byte_8E00A: dc.b $FB, 4, 0, 4, $FF, $F8
dc.b $FC, 0, 0, 6, $FF, $F0
dc.b $FC, 0, 0, 6, 0, 8
dc.b $F8, 5, 0, 0, $FF, $F8
word_8E022: dc.w 4 ; DATA XREF: ROM:0008DFDAo
dc.b $FC, 4, 0, 4, $FF, $F8
dc.b $FC, 0, 0, 6, $FF, $F0
dc.b $FC, 0, 0, 6, 0, 8
dc.b $F8, 5, 0, 0, $FF, $F8
word_8E03C: dc.w 4 ; DATA XREF: ROM:0008DFDAo
dc.b $FD, 4, 0, 4, $FF, $F8
dc.b $FC, 0, 0, 6, $FF, $F0
dc.b $FC, 0, 0, 6, 0, 8
dc.b $F8, 5, 0, 0, $FF, $F8
word_8E056: dc.w 4 ; DATA XREF: ROM:0008DFDAo
dc.b $FE, 4, 0, 4, $FF, $F8
dc.b $FC, 0, 0, 6, $FF, $F0
dc.b $FC, 0, 0, 6, 0, 8
dc.b $F8, 5, 0, 0, $FF, $F8
word_8E070: dc.w 1 ; DATA XREF: ROM:0008DFDAo
dc.b $FC, 4, 0, 7, $FF, $F8
word_8E078: dc.w 1 ; DATA XREF: ROM:0008DFDAo
dc.b $FC, 0, 0, 9, $FF, $FC
word_8E080: dc.w 2 ; DATA XREF: ROM:0008DFDAo
dc.b $F8, 8, 0, $A, $FF, $D8
dc.b $F8, 8, 8, $A, 0, $10
word_8E08E: dc.w 2 ; DATA XREF: ROM:0008DFDAo
dc.b 0, 8, $10, $A, $FF, $D8
dc.b 0, 8, $18, $A, 0, $10
word_8E09C: dc.w 0 ; DATA XREF: ROM:0008DFDAo
|
oeis/239/A239426.asm | neoneye/loda-programs | 11 | 29674 | ; A239426: 21*n^4 - 36*n^3 + 25*n^2 - 8*n + 1.
; Submitted by <NAME>
; 1,3,133,931,3441,9211,20293,39243,69121,113491,176421,262483,376753,524811,712741,947131,1235073,1584163,2002501,2498691,3081841,3761563,4547973,5451691,6483841,7656051,8980453,10469683,12136881,13995691,16060261,18345243,20865793,23637571,26676741,29999971,33624433,37567803,41848261,46484491,51495681,56901523,62722213,68978451,75691441,82882891,90575013,98790523,107552641,116885091,126812101,137358403,148549233,160410331,172967941,186248811,200280193,215089843,230706021,247157491,264473521
mov $2,$0
mov $0,1
sub $0,$2
mov $1,$0
mul $1,2
mul $1,$0
mov $2,3
mul $2,$0
mov $0,1
sub $2,1
sub $0,$2
mul $0,$2
sub $0,1
add $1,$0
mul $0,11
mul $0,$1
div $0,33
|
Task/Address-of-a-variable/Ada/address-of-a-variable-2.ada | LaudateCorpus1/RosettaCodeData | 1 | 2412 | <gh_stars>1-10
I : Integer;
for I'Address use 16#A100#;
|
Applications/Reminders/delete/delete lists/test.applescript | looking-for-a-job/applescript-examples | 1 | 3371 | <filename>Applications/Reminders/delete/delete lists/test.applescript<gh_stars>1-10
#!/usr/bin/env osascript
tell application "Reminders"
repeat with l in every list
tell l
if count of reminders is 0 then
delete list (name of l)
end if
end tell
end repeat
end tell
|
oeis/209/A209427.asm | neoneye/loda-programs | 11 | 95450 | <filename>oeis/209/A209427.asm<gh_stars>10-100
; A209427: T(n,k) = binomial(n,k)^n.
; 1,1,1,1,4,1,1,27,27,1,1,256,1296,256,1,1,3125,100000,100000,3125,1,1,46656,11390625,64000000,11390625,46656,1,1,823543,1801088541,64339296875,64339296875,1801088541,823543,1,1,16777216,377801998336,96717311574016,576480100000000,96717311574016,377801998336,16777216,1,1,387420489,101559956668416,208215748530929664,8004512848309157376,8004512848309157376,208215748530929664,101559956668416,387420489,1,1,10000000000,34050628916015625,619173642240000000000,166798809782010000000000
lpb $0
add $2,1
sub $0,$2
mov $1,$2
bin $1,$0
lpe
pow $1,$2
mov $0,$1
|
audio/sfx/teleport_enter1_1.asm | adhi-thirumala/EvoYellow | 16 | 82517 | <filename>audio/sfx/teleport_enter1_1.asm<gh_stars>10-100
SFX_Teleport_Enter1_1_Ch1:
duty 1
unknownsfx0x10 23
unknownsfx0x20 15, 215, 0, 7
unknownsfx0x20 15, 183, 128, 6
unknownsfx0x20 15, 135, 0, 6
unknownsfx0x20 15, 71, 128, 5
unknownsfx0x20 15, 23, 0, 5
unknownsfx0x10 8
endchannel
|
src/Algebra/Linear/Space/Product.agda | felko/linear-algebra | 15 | 5291 | <filename>src/Algebra/Linear/Space/Product.agda
{-# OPTIONS --without-K --safe #-}
open import Algebra.Structures.Bundles.Field
open import Algebra.Linear.Structures.Bundles
module Algebra.Linear.Space.Product
{k ℓ} (K : Field k ℓ)
{a₁ ℓ₁} (V₁-space : VectorSpace K a₁ ℓ₁)
{a₂ ℓ₂} (V₂-space : VectorSpace K a₂ ℓ₂)
where
open import Relation.Binary
open import Level using (_⊔_)
open import Data.Nat using (ℕ; zero; suc) renaming (_+_ to _+ℕ_)
open import Algebra.Linear.Structures.VectorSpace
import Algebra.FunctionProperties as FP
open VectorSpaceField K
open VectorSpace V₁-space
using ()
renaming
( Carrier to V₁
; _≈_ to _≈₁_
; isEquivalence to ≈₁-isEquiv
; refl to ≈₁-refl
; sym to ≈₁-sym
; trans to ≈₁-trans
; _+_ to _+₁_
; _∙_ to _∙₁_
; -_ to -₁_
; 0# to 0₁
; +-identityˡ to +₁-identityˡ
; +-identityʳ to +₁-identityʳ
; +-identity to +₁-identity
; +-cong to +₁-cong
; +-assoc to +₁-assoc
; +-comm to +₁-comm
; *ᵏ-∙-compat to *ᵏ-∙₁-compat
; ∙-+-distrib to ∙₁-+₁-distrib
; ∙-+ᵏ-distrib to ∙₁-+ᵏ-distrib
; ∙-cong to ∙₁-cong
; ∙-identity to ∙₁-identity
; ∙-absorbˡ to ∙₁-absorbˡ
; ∙-absorbʳ to ∙₁-absorbʳ
; -‿cong to -₁‿cong
; -‿inverseˡ to -₁‿inverseˡ
; -‿inverseʳ to -₁‿inverseʳ
)
open VectorSpace V₂-space
using ()
renaming
( Carrier to V₂
; _≈_ to _≈₂_
; isEquivalence to ≈₂-isEquiv
; refl to ≈₂-refl
; sym to ≈₂-sym
; trans to ≈₂-trans
; _+_ to _+₂_
; _∙_ to _∙₂_
; -_ to -₂_
; 0# to 0₂
; +-identityˡ to +₂-identityˡ
; +-identityʳ to +₂-identityʳ
; +-identity to +₂-identity
; +-cong to +₂-cong
; +-assoc to +₂-assoc
; +-comm to +₂-comm
; *ᵏ-∙-compat to *ᵏ-∙₂-compat
; ∙-+-distrib to ∙₂-+₂-distrib
; ∙-+ᵏ-distrib to ∙₂-+ᵏ-distrib
; ∙-cong to ∙₂-cong
; ∙-identity to ∙₂-identity
; ∙-absorbˡ to ∙₂-absorbˡ
; ∙-absorbʳ to ∙₂-absorbʳ
; -‿cong to -₂‿cong
; -‿inverseˡ to -₂‿inverseˡ
; -‿inverseʳ to -₂‿inverseʳ
)
open import Data.Product
open import Data.Product.Relation.Binary.Pointwise.NonDependent
private
V : Set (a₁ ⊔ a₂)
V = V₁ × V₂
_≈_ : Rel V (ℓ₁ ⊔ ℓ₂)
_≈_ = Pointwise _≈₁_ _≈₂_
≈-isEquiv : IsEquivalence _≈_
≈-isEquiv = ×-isEquivalence ≈₁-isEquiv ≈₂-isEquiv
prod-setoid : Setoid (a₁ ⊔ a₂) (ℓ₁ ⊔ ℓ₂)
prod-setoid = record
{ Carrier = V
; _≈_ = _≈_
; isEquivalence = ≈-isEquiv
}
open IsEquivalence ≈-isEquiv renaming
( refl to ≈-refl
; sym to ≈-sym
; trans to ≈-trans
)
open import Algebra.FunctionProperties _≈_
open import Algebra.Structures _≈_
0# : V
0# = (0₁ , 0₂)
-_ : Op₁ V
- (x₁ , x₂) = (-₁ x₁ , -₂ x₂)
infixr 25 _+_
_+_ : Op₂ V
(x₁ , x₂) + (y₁ , y₂) = (x₁ +₁ y₁ , x₂ +₂ y₂)
infixr 30 _∙_
_∙_ : K' -> V -> V
k ∙ (x₁ , x₂) = (k ∙₁ x₁ , k ∙₂ x₂)
+-cong : Congruent₂ _+_
+-cong (r₁ , r₂) (s₁ , s₂) = ( +₁-cong r₁ s₁ , +₂-cong r₂ s₂ )
+-assoc : Associative _+_
+-assoc (x₁ , x₂) (y₁ , y₂) (z₁ , z₂) = ( +₁-assoc x₁ y₁ z₁ , +₂-assoc x₂ y₂ z₂ )
+-identityˡ : LeftIdentity 0# _+_
+-identityˡ (x₁ , x₂) = ( +₁-identityˡ x₁ , +₂-identityˡ x₂ )
+-identityʳ : RightIdentity 0# _+_
+-identityʳ (x₁ , x₂) = ( +₁-identityʳ x₁ , +₂-identityʳ x₂ )
+-identity : Identity 0# _+_
+-identity = +-identityˡ , +-identityʳ
+-comm : Commutative _+_
+-comm (x₁ , x₂) (y₁ , y₂) = ( +₁-comm x₁ y₁ , +₂-comm x₂ y₂ )
*ᵏ-∙-compat : ∀ (a b : K') (u : V) -> ((a *ᵏ b) ∙ u) ≈ (a ∙ (b ∙ u))
*ᵏ-∙-compat a b (x₁ , x₂) = ( *ᵏ-∙₁-compat a b x₁ , *ᵏ-∙₂-compat a b x₂ )
∙-+-distrib : ∀ (a : K') (u v : V) -> (a ∙ (u + v)) ≈ ((a ∙ u) + (a ∙ v))
∙-+-distrib a (x₁ , x₂) (y₁ , y₂) = ( ∙₁-+₁-distrib a x₁ y₁ , ∙₂-+₂-distrib a x₂ y₂ )
∙-+ᵏ-distrib : ∀ (a b : K') (u : V) -> ((a +ᵏ b) ∙ u) ≈ ((a ∙ u) + (b ∙ u))
∙-+ᵏ-distrib a b (x₁ , x₂) = ( ∙₁-+ᵏ-distrib a b x₁ , ∙₂-+ᵏ-distrib a b x₂ )
∙-cong : ∀ {a b : K'} {u v : V} -> a ≈ᵏ b -> u ≈ v -> (a ∙ u) ≈ (b ∙ v)
∙-cong rₓ (r₁ , r₂) = ( ∙₁-cong rₓ r₁ , ∙₂-cong rₓ r₂ )
∙-identity : ∀ (x : V) → (1ᵏ ∙ x) ≈ x
∙-identity (x₁ , x₂) = ( ∙₁-identity x₁ , ∙₂-identity x₂ )
∙-absorbˡ : ∀ (x : V) → (0ᵏ ∙ x) ≈ 0#
∙-absorbˡ (x₁ , x₂) = ( ∙₁-absorbˡ x₁ , ∙₂-absorbˡ x₂ )
-‿inverseˡ : LeftInverse 0# -_ _+_
-‿inverseˡ (x₁ , x₂) = ( -₁‿inverseˡ x₁ , -₂‿inverseˡ x₂ )
-‿inverseʳ : RightInverse 0# -_ _+_
-‿inverseʳ (x₁ , x₂) = ( -₁‿inverseʳ x₁ , -₂‿inverseʳ x₂ )
-‿inverse : Inverse 0# -_ _+_
-‿inverse = -‿inverseˡ , -‿inverseʳ
-‿cong : Congruent₁ -_
-‿cong (x₁ , x₂) = ( -₁‿cong x₁ , -₂‿cong x₂ )
isMagma : IsMagma _+_
isMagma = record
{ isEquivalence = ≈-isEquiv
; ∙-cong = +-cong
}
isSemigroup : IsSemigroup _+_
isSemigroup = record
{ isMagma = isMagma
; assoc = +-assoc
}
isMonoid : IsMonoid _+_ 0#
isMonoid = record
{ isSemigroup = isSemigroup
; identity = +-identity
}
isGroup : IsGroup _+_ 0# -_
isGroup = record
{ isMonoid = isMonoid
; inverse = -‿inverse
; ⁻¹-cong = -‿cong
}
isAbelianGroup : IsAbelianGroup _+_ 0# -_
isAbelianGroup = record
{ isGroup = isGroup
; comm = +-comm
}
isVectorSpace : IsVectorSpace K _≈_ _+_ _∙_ -_ 0#
isVectorSpace = record
{ isAbelianGroup = isAbelianGroup
; *ᵏ-∙-compat = *ᵏ-∙-compat
; ∙-+-distrib = ∙-+-distrib
; ∙-+ᵏ-distrib = ∙-+ᵏ-distrib
; ∙-cong = ∙-cong
; ∙-identity = ∙-identity
; ∙-absorbˡ = ∙-absorbˡ
}
vectorSpace : VectorSpace K (a₁ ⊔ a₂) (ℓ₁ ⊔ ℓ₂)
vectorSpace = record { isVectorSpace = isVectorSpace }
|
i2c_periph.asm | conoror/picmicro | 1 | 6279 | ; This is code to show how to implement an I2C Peripheral on a midrange
; PIC (eg: PIC16F88). The enhanced midrange have more registers to solve
; some of the difficulties presented by the older I2C implementations.
; It is way harder than it looks to create a robust I2C Peripheral
; on these. (Note: "Peripheral" is my (and NXP's) preferred term.)
;
; There is existing code out there to do this but the idea of this
; code is to be as robust and as clear as I possibly make it.
; The code has been tested including edge cases like forcing an
; overflow condition. I used a digital analyser to catch these cases.
;
; Even so, there is a single case remaining. In the case of an exchange
; which never completes (eg: reset on the master side), there is every
; possibility of the I2C bus hanging up. This requires an I2C watchdog
; to be implemented. This is not done in this code as I need to create
; a broken I2C controller to test it.
;
; Distribution and use of this software are as per the terms of the
; Simplified BSD License (also known as the "2-Clause License")
;
; Copyright 2012 <NAME>. All rights reserved.
;
; ---- Processor and Config -----------------------------------------
processor pic16f88
#include p16f88.inc
#include macrosp16.inc
{{
I use a few basic macros to help my brain with btfss etc
but I do use them in this code extensively. The macros
are present in the repository.
I put clarifing comments in these brackets as it's not code.
Needless to say, this won't compile!
One thing - I don't assume any particular radix. But I
do think a default radix of "hex" by Microchip is really
silly. Why? Well. Is "BF" a define or a number?
}}
; ---- Defines and equates ------------------------------------------
{{
I find the PIC documentation to be vague as regards the
address. They use an 8-bit address not the usual 7-bit.
By explicitly doing the shift, I'm pointing that out.
}}
#define I2CADDR 0x5B << 1
#define I2CISXMIT i2c_isxmit, 0
#define I2CISFIRST i2c_isfirst, 0
#define I2CISNEXT i2c_isfirst, 1
#define I2CGOODCMD i2c_cmd, 7
; ---- Variables ----------------------------------------------------
CBLOCK 0x20 ; Bank 0
i2c_isxmit ; i2c variables are assumed Bank0
i2c_isfirst
i2c_stat
i2c_cmd
i2c_value
ENDC
{{
I do assume in my code that the I2C variables are held in Bank0.
i2c_isxmit, i2c_isfirst are flags used by the ISR. By "Transmit"
I mean master read. This is the peripheral so we transmit on read.
i2c_isfirst is two flags (ok, bad naming maybe). ISFIRST means
we've started receiving and ISNEXT means we've got the first
byte (command) and are now waiting for the value.
i2c_stat,cmd and value are implementations that I happen to be
using and you could change these as you see fit:
i2c_stat: a status register. Eg: key presses. fan on/off
an I2C read returns this register over and over
i2c_cmd: I use an i2c write as: command/value. i2c_cmd
hold the command. The high bit means I got a
good command and I can use the value in i2c_value.
Yes, it's a bit of a hack. I clear this bit when
I process the command so I know it's done.
i2c_value: The value that goes with command
}}
CBLOCK 0x70 ; On all banks
temp_w
temp_status
ENDC
; ==== Reset Vector =================================================
org 0x0000
goto Init
; ---- ISR Entry Point ----------------------------------------------
org 0x0004
movwf temp_w
movf STATUS, W
movwf temp_status
banksel PIR1 ; Bank0
ifbset PIR1, SSPIF ; I2C
goto IsrI2CEntry
{{
You could put other tests in there for Timer1 etc. It's
all about priority. I felt that my Timer1 could wait 100us!
}}
goto IsrExit ; Everything else
; ---- I2C Peripheral ISR Handling ----
IsrI2CEntry:
bcf PIR1, SSPIF ; Clear SSP Interrupt Flag
; Is the buffer address or data?
banksel SSPSTAT
ifbset SSPSTAT, D_NOT_A
goto IsrI2CData
; == It's an address ==
; R/W# is valid here but few other places
; Copy R/W# bit into i2c_isxmit
; Set first byte flag
clrw
ifbset SSPSTAT, R_NOT_W
movlw 0x01
banksel i2c_isxmit ; Bank0/SSPCON/SSPBUF
movwf i2c_isxmit
{{
Getting the address means the start of a sequence. So
you could reset pointers or whatever you need to get
ready. I just set a first flag and clear the next flag
}}
bsf I2CISFIRST ; Or reset pointers etc
bcf I2CISNEXT
; SSPBUF has I2C address:
; On receive, SSPBUF must be read to clear BF
; No side effects in reading SSPBUF on transmit
; Read SSPBUF before checking overflow to avoid races
movf SSPBUF, W
ifbset I2CISXMIT
goto IsrI2CData
; == Address + Receive ==
; Check for overflow and exit
ifbset SSPCON, SSPOV ; Check overflow
goto IsrI2COverflow
goto IsrExit ; ---- Done ----
IsrI2CData:
; == Data Transmit or Receive ==
; Transmit may be right after address. (D_NOT_A == 1 or 0)
; Receive will be the next cycle (D_NOT_A == 1).
banksel i2c_isxmit ; Bank0/SSPCON/SSPBUF (necessary)
ifbset I2CISXMIT
goto IsrI2CTransmit
; == Receiving data ==
; BF should be 1 here. If it's 0 something went badly
; wrong. Like not clearing SSPIF on an Overflow. Unlikely!
banksel SSPSTAT
ifbclr SSPSTAT, BF
goto IsrI2COverflow
banksel SSPCON
movf SSPBUF, W
; First byte is command, next byte is data. Once data is stored
; set high bit on cmd to signal a good command. If that high bit
; is already set, there was some sort of race problem
ifbclr I2CISFIRST
goto IsrI2CRecvDone
ifbclr I2CISNEXT
goto IsrI2CRecvFirst
; Second byte is the value. No more data after this:
movwf i2c_value
bsf I2CGOODCMD
clrf i2c_isfirst
goto IsrI2CRecvDone
IsrI2CRecvFirst:
ifbset I2CGOODCMD
clrf i2c_isfirst
ifbset I2CGOODCMD
goto IsrI2CRecvDone
movwf i2c_cmd
bcf I2CGOODCMD
bsf I2CISNEXT
IsrI2CRecvDone:
; If BF is set, data will be valid. However if an Overflow occurs
; (which will not overwrite SSPBUF), SSPOV *and* SSPIF are set.
; Read SSPBUF _before_ checking overflow to avoid race conditions.
ifbset SSPCON, SSPOV
goto IsrI2COverflow
goto IsrExit ; ---- Done ----
IsrI2CTransmit:
; Transmitting data iff master ACK last time
; Clock should be halted (CKP==0) if continuing (not NACK)
; R/W# indicates the status of last ACK
; Master NACK if R/W# is 0. Can check CKP too to be sure
banksel SSPSTAT
ifbclr SSPSTAT, R_NOT_W
goto IsrI2CMasterNack
banksel SSPCON ; SSPCON/SSPBUF
ifbset SSPCON, CKP
goto IsrI2CMasterNack
; == Transmit byte ==
bcf SSPCON, SSPOV ; Hmm. I suppose I should clear
bcf SSPCON, WCOL ; these before collision checks
movf i2c_stat, W
movwf SSPBUF ; Send data - BF set
{{
I thought this was neat. Reading certain statuses like
keystrokes can be problematic. What you want to do is
read them once and then note you did that. What I do
is set the key status in i2c_stat and then clear them
when I know they've been read. Which is here. The
defines are personal to my code so they aren't here:
}}
; Fetching keystates autoclears them; thus we get them once...
bcf i2c_stat, CMD_BIT_SKEY
bcf i2c_stat, CMD_BIT_LKEY
ifbset SSPCON, WCOL
goto IsrI2CWriteCol
; Wait a setup time (check for wcol will cover that)
bsf SSPCON, CKP ; Start the clock back up
goto IsrExit ; --- Done ---
IsrI2CMasterNack:
banksel SSPCON
movf SSPBUF, W ; Mostly pedantic
bcf SSPCON, SSPOV
bcf SSPCON, WCOL
bsf SSPCON, CKP
goto IsrExit ; --- Done ---
IsrI2CWriteCol:
IsrI2COverflow:
; == Game over. I2C cycle ends. No ACK from us ==
; Just clear everything. NOTE: SSPOV sets SSPIF.
; Write collision handling done here (like AN734)
banksel SSPCON ; Bank0/SSPBUF/SSPCON/PIR1
movf SSPBUF, W ; Clear BF
bcf SSPCON, SSPOV
bcf SSPCON, WCOL
bsf SSPCON, CKP ; For the write collision case
bcf PIR1, SSPIF ; MUST clear the pending IRQ
goto IsrExit ; --- Done ---
; ---- OTHER ISR Handling here ----
{{
Timer is most obvious
}}
; ---- ISR Exit point ----
IsrExit:
movf temp_status, W
movwf STATUS
swapf temp_w, F ; Don't change status register
swapf temp_w, W
retfie
; ==== Main code ====================================================
; ---- Initialisation -----------------------------------------------
Init:
; == Ports and Oscillator Config ==
{{
The usual code would be here
}}
; == I2C Initialisation ==
banksel i2c_stat
clrf i2c_isxmit
clrf i2c_isfirst
clrf i2c_stat
clrf i2c_cmd
clrf i2c_value
banksel SSPADD ; SSPADD/PIE1
movlw I2CADDR
movwf SSPADD ; Set address
{{
etc
}}
|
oeis/081/A081915.asm | neoneye/loda-programs | 11 | 161929 | <filename>oeis/081/A081915.asm
; A081915: a(n) = 4^n*(n^3 - 3n^2 + 2n + 384)/384.
; Submitted by <NAME>(s2)
; 1,4,16,65,272,1184,5376,25344,122880,606208,3014656,15007744,74448896,367001600,1795162112,8707375104,41875931136,199715979264,944892805120,4436701216768,20684562497536,95794950569984,440904162738176,2017603836968960,9183121115185152,41587927808999424,187462334489296896,841328705388150784,3760505688854364160,16744383414563504128,74291379453103702016,328510571218913460224,1448069409786199801856,6364126705429795307520,27891477039448842043392,121914531583146426630144,531561377228014439366656
mov $2,4
pow $2,$0
bin $0,3
mul $0,$2
div $0,64
add $2,$0
mov $0,$2
|
oeis/074/A074538.asm | neoneye/loda-programs | 11 | 16761 | ; A074538: a(n) = 2^n + 5^n + 7^n.
; Submitted by <NAME>(s1.)
; 3,14,78,476,3042,19964,133338,901796,6155682,42307244,292241898,2026156916,14085431922,98109721724,684326604858,4778079120836,33385518525762,233393453571404,1632228295438218,11417968672225556,79887633730301202,559022701243584284,3912205234378197978,27380668269044383076,191640836025358582242,1341366642887875408364,9388970453767206180138,65719812944131338185396,460023789447724848552882,3220092020328103359411644,22540271613266874640120698,157780038647718886155104516,1104450957308286037563157122
mov $3,$0
seq $0,74503 ; a(n) = 1^n + 2^n + 7^n.
mov $2,5
pow $2,$3
add $0,$2
sub $0,1
|
src/test_repeat/test2.asm | hra1129/zma | 8 | 178438 |
org 0x0000
dw end_address
include "test2_inc.asm"
end_address:
|
src/day-19/adventofcode-day_19-main.adb | persan/advent-of-code-2020 | 0 | 14734 | <reponame>persan/advent-of-code-2020<gh_stars>0
with Ada.Text_IO; use Ada.Text_IO;
procedure Adventofcode.Day_19.Main is
begin
Put_Line ("Day-19");
end Adventofcode.Day_19.Main;
|
Plugins/DocumentationParserPlugin/src/main/antlr/JavadocParser.g4 | MagicalAsh/Weasel | 0 | 5612 | /*
[The "BSD licence"]
Copyright (c) 2016 <NAME>
All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions
are met:
1. Redistributions of source code must retain the above copyright
notice, this list of conditions and the following disclaimer.
2. Redistributions in binary form must reproduce the above copyright
notice, this list of conditions and the following disclaimer in the
documentation and/or other materials provided with the distribution.
3. The name of the author may not be used to endorse or promote products
derived from this software without specific prior written permission.
THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``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 AUTHOR 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.
*/
parser grammar JavadocParser;
options { tokenVocab=JavadocLexer; }
// warning to anyone working in intellij: the ANTLR preview does not
// work, since this grammar uses a lookahead. :(
documentation
: EOF
| JAVADOC_START skipWhitespace* documentationContent JAVADOC_END EOF
| skipWhitespace* documentationContent EOF
;
documentationContent
: description skipWhitespace*
| skipWhitespace* tagSection
| description NEWLINE+ skipWhitespace* tagSection
;
skipWhitespace
: SPACE
| NEWLINE
;
description
: descriptionLine (descriptionNewline+ descriptionLine)*
;
descriptionLine
: descriptionLineStart descriptionLineElement*
| inlineTag descriptionLineElement*
;
descriptionLineStart
: SPACE? descriptionLineNoSpaceNoAt+ (descriptionLineNoSpaceNoAt | SPACE | AT)*
;
descriptionLineNoSpaceNoAt
: TEXT_CONTENT
| NAME
| STAR
| SLASH
| BRACE_OPEN
| BRACE_CLOSE
;
descriptionLineElement
: inlineTag
| descriptionLineText
;
descriptionLineText
: (descriptionLineNoSpaceNoAt | SPACE | AT)+
;
descriptionNewline
: NEWLINE
;
tagSection
: blockTag+
;
blockTag
: SPACE? AT blockTagName SPACE? blockTagContent*
;
blockTagName
: NAME
;
blockTagContent
: blockTagText
| inlineTag
| NEWLINE
;
blockTagText
: blockTagTextElement+
;
blockTagTextElement
: TEXT_CONTENT
| NAME
| SPACE
| STAR
| SLASH
| BRACE_OPEN
| BRACE_CLOSE
;
inlineTag
: INLINE_TAG_START inlineTagName SPACE* inlineTagContent? BRACE_CLOSE
;
inlineTagName
: NAME
;
inlineTagContent
: braceContent+
;
braceExpression
: BRACE_OPEN braceContent* BRACE_CLOSE
;
braceContent
: braceExpression
| braceText (NEWLINE* braceText)*
;
braceText
: TEXT_CONTENT
| NAME
| SPACE
| STAR
| SLASH
| NEWLINE
;
|
sk/sfx/BC.asm | Cancer52/flamedriver | 9 | 96699 | <reponame>Cancer52/flamedriver
Sound_BC_Header:
smpsHeaderStartSong 3
smpsHeaderVoice Sound_BC_C8_Voices
smpsHeaderTempoSFX $01
smpsHeaderChanSFX $01
smpsHeaderSFXChannel cFM3, Sound_BC_C8_FM3, $00, $10
; FM3 Data
Sound_BC_C8_FM3:
smpsSetvoice $00
Sound_BC_C8_Loop00:
dc.b nBb6, $16
smpsContinuousLoop Sound_BC_C8_Loop00
smpsStop
Sound_BC_C8_Voices:
; Voice $00
; $38
; $00, $30, $00, $01, $1F, $1F, $1F, $0F, $00, $00, $00, $00
; $00, $00, $00, $00, $0F, $0F, $0F, $0F, $00, $00, $00, $80
smpsVcAlgorithm $00
smpsVcFeedback $07
smpsVcUnusedBits $00
smpsVcDetune $00, $00, $03, $00
smpsVcCoarseFreq $01, $00, $00, $00
smpsVcRateScale $00, $00, $00, $00
smpsVcAttackRate $0F, $1F, $1F, $1F
smpsVcAmpMod $00, $00, $00, $00
smpsVcDecayRate1 $00, $00, $00, $00
smpsVcDecayRate2 $00, $00, $00, $00
smpsVcDecayLevel $00, $00, $00, $00
smpsVcReleaseRate $0F, $0F, $0F, $0F
smpsVcTotalLevel $00, $00, $00, $00
|
prototyping/Properties.agda | gideros/luau | 1 | 10121 | <filename>prototyping/Properties.agda
{-# OPTIONS --rewriting #-}
module Properties where
import Properties.Contradiction
import Properties.Dec
import Properties.Equality
import Properties.Remember
import Properties.Step
import Properties.StrictMode
import Properties.TypeCheck
|
projects/batfish/src/main/antlr4/org/batfish/grammar/cisco_xr/CiscoXr_common.g4 | adiapel/batfish | 0 | 5123 | parser grammar CiscoXr_common;
options {
tokenVocab = CiscoXrLexer;
}
access_list_action
:
PERMIT
| DENY
;
address_family_footer
:
(
(
EXIT_ADDRESS_FAMILY
| EXIT
) NEWLINE
)?
;
asn_dotted
:
uint_legacy PERIOD uint_legacy
;
bgp_asn
:
asn = uint_legacy
| asn4b = asn_dotted
;
literal_community
:
ACCEPT_OWN
| GRACEFUL_SHUTDOWN
| INTERNET
| LOCAL_AS
| NO_ADVERTISE
| NO_EXPORT
| hi = uint16 COLON lo = uint16
;
description_line
:
DESCRIPTION text = RAW_TEXT? NEWLINE
;
double_quoted_string
:
DOUBLE_QUOTE
(
inner_text += ~DOUBLE_QUOTE
)* DOUBLE_QUOTE
;
dscp_type
:
uint_legacy
| AF11
| AF12
| AF13
| AF21
| AF22
| AF23
| AF31
| AF32
| AF33
| AF41
| AF42
| AF43
| CS1
| CS2
| CS3
| CS4
| CS5
| CS6
| CS7
| DEFAULT
| EF
;
ec_literal
:
uint_legacy COLON uint_legacy
;
eigrp_metric
:
bw_kbps = uint_legacy delay_10us = uint_legacy reliability = uint_legacy eff_bw = uint_legacy mtu = uint_legacy
;
exit_line
:
EXIT NEWLINE
;
extended_community
:
ec_literal
;
hash_comment
:
POUND RAW_TEXT
;
int_expr
:
(
(
PLUS
| DASH
)? uint_legacy
)
| IGP_COST
| RP_VARIABLE
;
interface_name
:
name_prefix_alpha = M_Interface_PREFIX
(
(
(
name_middle_parts += M_Interface_PREFIX
)? name_middle_parts += UINT_BIG
(
name_middle_parts += FORWARD_SLASH
| name_middle_parts += PERIOD
| name_middle_parts += COLON
)
)*
| name_middle_parts += MODULE
) range?
;
interface_name_unstructured
:
(
VARIABLE
| variable_interface_name uint_legacy?
)
(
(
COLON
| FORWARD_SLASH
| PERIOD
) uint_legacy
)*
;
ios_delimited_banner
:
BANNER_DELIMITER_IOS body = BANNER_BODY? BANNER_DELIMITER_IOS
;
isis_level
:
LEVEL_1
| LEVEL_1_2
| LEVEL_2
;
line_type
:
// intentional blank
| AUX
| CON
| CONSOLE
| DEFAULT
|
(
TEMPLATE name = variable
)
| TTY
| VTY
;
null_rest_of_line
:
~NEWLINE* NEWLINE
;
ospf_route_type
:
(
EXTERNAL uint_legacy?
)
| INTERNAL
|
(
NSSA_EXTERNAL uint_legacy?
)
;
port_specifier
:
(
EQ
(
args += port
)+
)
|
(
GT arg = port
)
|
(
NEQ
(
args += port
)+
)
|
(
LT arg = port
)
|
(
RANGE arg1 = port arg2 = port
)
;
port
:
uint_legacy
| ACAP
| ACR_NEMA
| AFPOVERTCP
| AOL
| ARNS
| ASF_RMCP
| ASIP_WEBADMIN
| AT_RTMP
| AURP
| AUTH
| BFD
| BFD_ECHO
| BFTP
| BGMP
| BGP
| BIFF
| BOOTPC
| BOOTPS
| CHARGEN
| CIFS
| CISCO_TDP
| CITADEL
| CITRIX_ICA
| CLEARCASE
| CMD
| COMMERCE
| COURIER
| CSNET_NS
| CTIQBE
| DAYTIME
| DHCP_FAILOVER2
| DHCPV6_CLIENT
| DHCPV6_SERVER
| DISCARD
| DNSIX
| DOMAIN
| DSP
| ECHO
| EFS
| EPP
| ESRO_GEN
| EXEC
| FINGER
| FTP
| FTP_DATA
| FTPS
| FTPS_DATA
| GODI
| GOPHER
| GRE
| GTP_C
| GTP_PRIME
| GTP_U
| H323
| HA_CLUSTER
| HOSTNAME
| HP_ALARM_MGR
| HTTP
| HTTP_ALT
| HTTP_MGMT
| HTTP_RPC_EPMAP
| HTTPS
| IDENT
| IEEE_MMS_SSL
| IMAP
| IMAP3
| IMAP4
| IMAPS
| IPP
| IPX
| IRC
| IRIS_BEEP
| ISAKMP
| ISCSI
| ISI_GL
| ISO_TSAP
| KERBEROS
| KERBEROS_ADM
| KLOGIN
| KPASSWD
| KSHELL
| L2TP
| LA_MAINT
| LANZ
| LDAP
| LDAPS
| LDP
| LMP
| LOGIN
| LOTUSNOTES
| LPD
| MAC_SRVR_ADMIN
| MATIP_TYPE_A
| MATIP_TYPE_B
| MICRO_BFD
| MICROSOFT_DS
| MLAG
| MOBILE_IP
| MONITOR
| MPP
| MS_SQL_M
| MS_SQL_S
| MSDP
| MSEXCH_ROUTING
| MSG_ICP
| MSP
| MSRPC
| NAMESERVER
| NAS
| NAT
| NCP
| NETBIOS_DGM
| NETBIOS_NS
| NETBIOS_SS
| NETBIOS_SSN
| NETRJS_1
| NETRJS_2
| NETRJS_3
| NETRJS_4
| NETWALL
| NETWNEWS
| NEW_RWHO
| NFS
| NNTP
| NNTPS
| NON500_ISAKMP
| NSW_FE
| NTP
| ODMR
| OLSR
| OPENVPN
| PCANYWHERE_DATA
| PCANYWHERE_STATUS
| PIM_AUTO_RP
| PKIX_TIMESTAMP
| PKT_KRB_IPSEC
| POP2
| POP3
| POP3S
| PPTP
| PRINT_SRV
| PTP_EVENT
| PTP_GENERAL
| QMTP
| QOTD
| RADIUS
| RADIUS_ACCT
| RE_MAIL_CK
| REMOTEFS
| REPCMD
| RIP
| RJE
| RLP
| RLZDBASE
| RMC
| RMONITOR
| RPC2PORTMAP
| RSH
| RSYNC
| RTELNET
| RTSP
| SECUREID_UDP
| SGMP
| SILC
| SIP
| SMTP
| SMUX
| SNAGAS
| SNMP
| SNMP_TRAP
| SNMPTRAP
| SNPP
| SQLNET
| SQLSERV
| SQLSRV
| SSH
| SUBMISSION
| SUNRPC
| SVRLOC
| SYSLOG
| SYSTAT
| TACACS
| TACACS_DS
| TALK
| TBRPF
| TCPMUX
| TCPNETHASPSRV
| TELNET
| TFTP
| TIME
| TIMED
| TUNNEL
| UPS
| UUCP
| UUCP_PATH
| VMNET
| VXLAN
| WHO
| WHOIS
| WWW
| XDMCP
| XNS_CH
| XNS_MAIL
| XNS_TIME
| Z39_50
;
prefix_set_elem
:
(
ipa = IP_ADDRESS
| prefix = IP_PREFIX
| ipv6a = IPV6_ADDRESS
| ipv6_prefix = IPV6_PREFIX
)
(
(
GE minpl = uint_legacy
)
|
(
LE maxpl = uint_legacy
)
|
(
EQ eqpl = uint_legacy
)
)*
;
protocol
:
AH
| AHP
| uint_legacy
| EIGRP
| ESP
| GRE
| ICMP
| ICMP6
| ICMPV6
| IGMP
| IGRP
| IP
| IPINIP
| IPSEC
| IPV4
| IPV6
| ND
| NOS
| OSPF
| PIM
| PPTP
| SCTP
| SNP
| TCP
| TCP_UDP
| UDP
| VRRP
;
range
:
(
range_list += subrange
(
COMMA range_list += subrange
)*
)
| NONE
;
route_distinguisher
:
(IP_ADDRESS | bgp_asn) COLON uint_legacy
;
route_tag
:
// 1-4294967295
uint32
;
route_target
:
(IP_ADDRESS | bgp_asn) COLON uint_legacy
;
route_policy_params_list
:
params_list += variable
(
COMMA params_list += variable
)*
;
rp_subrange
:
first = int_expr
|
(
BRACKET_LEFT first = int_expr PERIOD PERIOD last = int_expr BRACKET_RIGHT
)
;
subrange
:
low = uint_legacy
(
DASH high = uint_legacy
)?
;
switchport_trunk_encapsulation
:
DOT1Q
| ISL
| NEGOTIATE
;
uint8
:
UINT8
;
uint16
:
UINT8
| UINT16
;
uint32
:
UINT8
| UINT16
| UINT32
;
uint64
:
UINT8
| UINT16
| UINT32
| UINT64
;
uint_big
:
UINT8
| UINT16
| UINT32
| UINT64
| UINT_BIG
;
// TODO: replace all references with one of above rules and remove this rule
uint_legacy
:
UINT8
| UINT16
| UINT32
| UINT64
| UINT_BIG
;
variable
:
~NEWLINE
;
variable_aclname
:
(
~( ETH | IN | NEWLINE | OUT | REMARK | SESSION | WS )
)+
;
variable_community_name
:
~( NEWLINE | DOUBLE_QUOTE | GROUP | IPV4 | IPV6 | RO | RW | SDROWNER |
SYSTEMOWNER | USE_ACL | USE_IPV4_ACL | USE_IPV6_ACL | VIEW )
;
variable_distribute_list
:
~( NEWLINE | IN | OUT )+
;
variable_hostname
:
~( USE_VRF | NEWLINE | VRF )+
;
variable_interface_name
:
~( UINT8 | UINT16 | IP_ADDRESS | IP_PREFIX | ADMIN_DIST | ADMIN_DISTANCE | METRIC |
NAME | NEWLINE | TAG | TRACK | VARIABLE )
;
variable_max_metric
:
~(NEWLINE | BGP | EXTERNAL_LSA | INCLUDE_STUB | ON_STARTUP | ROUTER_LSA | SUMMARY_LSA | WAIT_FOR)
;
variable_permissive
:
(
~( NEWLINE | WS )
)+
;
variable_secret
:
~( NEWLINE | ATTRIBUTES | ENCRYPTED | LEVEL | MSCHAP | NT_ENCRYPTED | PBKDF2 | PRIVILEGE | ROLE )+
;
variable_group_id
:
~( NEWLINE | TCP | TCP_UDP | UDP )+
;
vlan_id: v = uint16;
community_set_name: WORD;
parameter: PARAMETER;
route_policy_name: WORD;
vrf_name: WORD;
access_list_name: WORD;
rd_set_name: WORD;
|
test/Succeed/ImplicitlyDottedVariable.agda | shlevy/agda | 1,989 | 9219 | open import Agda.Builtin.Nat
data Vec (A : Set) : Nat → Set where
[] : Vec A 0
cons : (n : Nat) → A → Vec A n → Vec A (suc n)
tail : {A : Set} (n : Nat) → Vec A (suc n) → Vec A n
tail n (cons n x xs) = xs
tail' : {A : Set} (n : Nat) → Vec A (suc n) → Vec A n
tail' 0 (cons 0 x []) = []
tail' (suc n) (cons (suc n) x (cons n x₁ xs)) = (cons n x₁ xs)
|
src/mathutil.adb | Kurinkitos/Twizy-Security | 1 | 1244 | with Ada.Numerics.Generic_Elementary_Functions;
package body Mathutil with SPARK_Mode => Off is
package FloatingMath is
new Ada.Numerics.Generic_Elementary_Functions(FloatingNumber);
function ArcTan(Y : FloatingNumber; X : FloatingNumber) return FloatingNumber
is
begin
return FloatingMath.ArcTan(Y / X, 1.0, 360.0);
end ArcTan;
function Sin(X : FloatingNumber) return FloatingNumber
is
begin
return FloatingMath.Sin(X, 360.0);
end;
function Cos(X : FloatingNumber) return FloatingNumber
is
begin
return FloatingMath.Cos(X, 360.0);
end;
function Tan(X : FloatingNumber) return FloatingNumber
is
begin
return FloatingMath.Tan(X, 360.0);
end;
function Sin_r(X : FloatingNumber) return FloatingNumber
is
begin
return FloatingMath.Sin(X);
end;
function Cos_r(X : FloatingNumber) return FloatingNumber
is
begin
return FloatingMath.Cos(X);
end;
function Tan_r(X : FloatingNumber) return FloatingNumber
is
begin
return FloatingMath.Tan(X);
end;
function Sqrt(X : FloatingNumber) return FloatingNumber
is
begin
return FloatingMath.Sqrt(X);
end Sqrt;
end;
|
archive/agda-3/src/Oscar/Class/Leftunit.agda | m0davis/oscar | 0 | 599 |
open import Oscar.Prelude
open import Oscar.Class
open import Oscar.Class.Unit
module Oscar.Class.Leftunit where
module Leftunit
{𝔞 𝔟} {𝔄 : Ø 𝔞} {𝔅 : Ø 𝔟}
{𝔢} {𝔈 : Ø 𝔢}
{𝔞𝔟}
(_↤_ : 𝔅 → 𝔄 → Ø 𝔞𝔟) (let _↤_ = _↤_; infix 4 _↤_)
(ε : 𝔈)
(_◃_ : 𝔈 → 𝔄 → 𝔅) (let _◃_ = _◃_; infix 16 _◃_)
(x : 𝔄)
= ℭLASS (ε , _◃_ , _↤_) (ε ◃ x ↤ x)
module _
{𝔞} {𝔄 : Ø 𝔞} {𝔢} {𝔈 : Ø 𝔢} {ℓ}
{_↦_ : 𝔄 → 𝔄 → Ø ℓ}
{ε : 𝔈}
{_◃_ : 𝔈 → 𝔄 → 𝔄}
{x : 𝔄}
where
leftunit = Leftunit.method _↦_ ε _◃_ x
open import Oscar.Class.Reflexivity
open import Oscar.Class.Surjection
open import Oscar.Class.Smap
module Leftunit,smaparrow
{𝔵₁ 𝔵₂ 𝔭₁ 𝔭₂ 𝔯 𝔭̇₁₂} {𝔛₁ : Ø 𝔵₁} {𝔛₂ : Ø 𝔵₂}
(ℜ : π̂² 𝔯 𝔛₁)
(𝔓₁ : π̂ 𝔭₁ 𝔛₂)
(𝔓₂ : π̂ 𝔭₂ 𝔛₂)
(ε : Reflexivity.type ℜ)
(surjection : Surjection.type 𝔛₁ 𝔛₂)
(smaparrow : Smaparrow.type ℜ 𝔓₁ 𝔓₂ surjection surjection)
(𝔓̇₁₂ : ∀ {x} → 𝔓₁ (surjection x) → 𝔓₂ (surjection x) → Ø 𝔭̇₁₂)
where
class = ∀ {x} {p : 𝔓₁ (surjection x)} → Leftunit.class (flip 𝔓̇₁₂) ε smaparrow p
type = ∀ {x} {p : 𝔓₁ (surjection x)} → Leftunit.type (flip 𝔓̇₁₂) ε smaparrow p
method : ⦃ _ : class ⦄ → type
method {x} {p} = Leftunit.method (flip 𝔓̇₁₂) ε smaparrow p
module Leftunit,smaparrow!
{𝔵₁ 𝔵₂ 𝔭₁ 𝔭₂ 𝔯 𝔭̇₁₂} {𝔛₁ : Ø 𝔵₁} {𝔛₂ : Ø 𝔵₂}
(ℜ : π̂² 𝔯 𝔛₁)
(𝔓₁ : π̂ 𝔭₁ 𝔛₂)
(𝔓₂ : π̂ 𝔭₂ 𝔛₂)
⦃ _ : Reflexivity.class ℜ ⦄
⦃ _ : Surjection.class 𝔛₁ 𝔛₂ ⦄
⦃ _ : Smaparrow!.class ℜ 𝔓₁ 𝔓₂ ⦄
(𝔓̇₁₂ : ∀ {x} → 𝔓₁ (surjection x) → 𝔓₂ (surjection x) → Ø 𝔭̇₁₂)
= Leftunit,smaparrow ℜ 𝔓₁ 𝔓₂ ε surjection smaparrow 𝔓̇₁₂
module Leftunit,smaphomarrow
{𝔵₁ 𝔵₂ 𝔭 𝔯 𝔭̇} {𝔛₁ : Ø 𝔵₁} {𝔛₂ : Ø 𝔵₂}
(ℜ : π̂² 𝔯 𝔛₁)
(𝔓 : π̂ 𝔭 𝔛₂)
(ε : Reflexivity.type ℜ)
(surjection : Surjection.type 𝔛₁ 𝔛₂)
(smaparrow : Smaphomarrow.type ℜ 𝔓 surjection)
(𝔓̇ : ∀ {x} → 𝔓 (surjection x) → 𝔓 (surjection x) → Ø 𝔭̇)
= Leftunit,smaparrow ℜ 𝔓 𝔓 ε surjection smaparrow 𝔓̇
module Leftunit,smaphomarrow!
{𝔵₁ 𝔵₂ 𝔭 𝔯 𝔭̇} {𝔛₁ : Ø 𝔵₁} {𝔛₂ : Ø 𝔵₂}
(ℜ : π̂² 𝔯 𝔛₁)
(𝔓 : π̂ 𝔭 𝔛₂)
⦃ _ : Reflexivity.class ℜ ⦄
⦃ _ : Surjection.class 𝔛₁ 𝔛₂ ⦄
⦃ _ : Smaphomarrow!.class ℜ 𝔓 ⦄
(𝔓̇ : ∀ {x} → 𝔓 (surjection x) → 𝔓 (surjection x) → Ø 𝔭̇)
= Leftunit,smaphomarrow ℜ 𝔓 ε surjection smaparrow 𝔓̇
open import Oscar.Class.HasEquivalence
module Leftunit,equivalence,smaphomarrow!
{𝔵₁ 𝔵₂ 𝔭 𝔯 𝔭̇} {𝔛₁ : Ø 𝔵₁} {𝔛₂ : Ø 𝔵₂}
(ℜ : π̂² 𝔯 𝔛₁)
(𝔓 : π̂ 𝔭 𝔛₂)
⦃ _ : Reflexivity.class ℜ ⦄
⦃ _ : Surjection.class 𝔛₁ 𝔛₂ ⦄
⦃ _ : Smaphomarrow!.class ℜ 𝔓 ⦄
⦃ _ : ∀ {x} → HasEquivalence (𝔓 x) 𝔭̇ ⦄
= Leftunit,smaphomarrow! ℜ 𝔓 _≈_
|
Transynther/x86/_processed/NONE/_xt_/i3-7100_9_0x84_notsx.log_14_1406.asm | ljhsiun2/medusa | 9 | 165821 | .global s_prepare_buffers
s_prepare_buffers:
push %r14
push %rbp
push %rcx
push %rdi
push %rdx
push %rsi
lea addresses_D_ht+0x17d0, %rsi
lea addresses_A_ht+0xb6a0, %rdi
and $26565, %rdx
mov $108, %rcx
rep movsw
nop
nop
dec %rbp
lea addresses_WT_ht+0xc59a, %rsi
lea addresses_normal_ht+0x2030, %rdi
clflush (%rdi)
nop
nop
nop
nop
cmp %rdx, %rdx
mov $92, %rcx
rep movsw
add %rdi, %rdi
lea addresses_normal_ht+0x188b0, %rsi
lea addresses_A_ht+0xc8ec, %rdi
nop
nop
nop
sub $22821, %r14
mov $84, %rcx
rep movsw
add $17767, %rbp
lea addresses_A_ht+0xe743, %rbp
clflush (%rbp)
xor $48398, %r14
mov $0x6162636465666768, %rcx
movq %rcx, %xmm0
and $0xffffffffffffffc0, %rbp
movaps %xmm0, (%rbp)
nop
inc %rcx
pop %rsi
pop %rdx
pop %rdi
pop %rcx
pop %rbp
pop %r14
ret
.global s_faulty_load
s_faulty_load:
push %r10
push %r13
push %rax
push %rbp
push %rcx
push %rdi
push %rsi
// Store
mov $0xeb0, %r13
nop
nop
nop
nop
nop
sub $32639, %rdi
movl $0x51525354, (%r13)
nop
nop
nop
nop
xor %rdi, %rdi
// REPMOV
lea addresses_D+0x6f1b, %rsi
lea addresses_PSE+0xf5e8, %rdi
nop
nop
sub $19616, %rbp
mov $4, %rcx
rep movsl
nop
nop
nop
nop
nop
sub %rcx, %rcx
// Store
mov $0x9b0, %r10
nop
nop
nop
nop
add %rax, %rax
mov $0x5152535455565758, %rsi
movq %rsi, %xmm0
movups %xmm0, (%r10)
nop
nop
nop
nop
xor $57888, %r10
// Faulty Load
lea addresses_D+0xa8b0, %rax
nop
nop
nop
nop
inc %rcx
mov (%rax), %edi
lea oracles, %rsi
and $0xff, %rdi
shlq $12, %rdi
mov (%rsi,%rdi,1), %rdi
pop %rsi
pop %rdi
pop %rcx
pop %rbp
pop %rax
pop %r13
pop %r10
ret
/*
<gen_faulty_load>
[REF]
{'src': {'type': 'addresses_D', 'same': False, 'size': 2, 'congruent': 0, 'NT': True, 'AVXalign': False}, 'OP': 'LOAD'}
{'dst': {'type': 'addresses_P', 'same': False, 'size': 4, 'congruent': 9, 'NT': False, 'AVXalign': False}, 'OP': 'STOR'}
{'src': {'type': 'addresses_D', 'congruent': 0, 'same': False}, 'dst': {'type': 'addresses_PSE', 'congruent': 1, 'same': False}, 'OP': 'REPM'}
{'dst': {'type': 'addresses_P', 'same': False, 'size': 16, 'congruent': 4, 'NT': False, 'AVXalign': False}, 'OP': 'STOR'}
[Faulty Load]
{'src': {'type': 'addresses_D', 'same': True, 'size': 4, 'congruent': 0, 'NT': False, 'AVXalign': False}, 'OP': 'LOAD'}
<gen_prepare_buffer>
{'src': {'type': 'addresses_D_ht', 'congruent': 2, 'same': False}, 'dst': {'type': 'addresses_A_ht', 'congruent': 3, 'same': False}, 'OP': 'REPM'}
{'src': {'type': 'addresses_WT_ht', 'congruent': 1, 'same': False}, 'dst': {'type': 'addresses_normal_ht', 'congruent': 7, 'same': True}, 'OP': 'REPM'}
{'src': {'type': 'addresses_normal_ht', 'congruent': 10, 'same': False}, 'dst': {'type': 'addresses_A_ht', 'congruent': 1, 'same': False}, 'OP': 'REPM'}
{'dst': {'type': 'addresses_A_ht', 'same': False, 'size': 16, 'congruent': 0, 'NT': False, 'AVXalign': True}, 'OP': 'STOR'}
{'36': 14}
36 36 36 36 36 36 36 36 36 36 36 36 36 36
*/
|
alloy4fun_models/trashltl/models/3/mc5XA7uwkev8rsKxi.als | Kaixi26/org.alloytools.alloy | 0 | 407 | open main
pred idmc5XA7uwkev8rsKxi_prop4 {
some f: File | eventually always f in Trash
}
pred __repair { idmc5XA7uwkev8rsKxi_prop4 }
check __repair { idmc5XA7uwkev8rsKxi_prop4 <=> prop4o } |
Transynther/x86/_processed/AVXALIGN/_zr_/i7-7700_9_0xca.log_21829_405.asm | ljhsiun2/medusa | 9 | 242954 | <reponame>ljhsiun2/medusa
.global s_prepare_buffers
s_prepare_buffers:
push %r12
push %r14
push %r15
push %r8
push %rax
push %rbx
push %rcx
push %rdi
push %rsi
lea addresses_WC_ht+0x19935, %rax
clflush (%rax)
nop
nop
nop
sub %r15, %r15
vmovups (%rax), %ymm4
vextracti128 $1, %ymm4, %xmm4
vpextrq $0, %xmm4, %r14
nop
nop
nop
dec %rbx
lea addresses_D_ht+0x104a5, %r8
nop
nop
nop
and $3288, %rax
mov $0x6162636465666768, %rsi
movq %rsi, %xmm6
vmovups %ymm6, (%r8)
nop
nop
nop
nop
nop
xor %rsi, %rsi
lea addresses_UC_ht+0xbe49, %rax
nop
nop
xor $23938, %r12
and $0xffffffffffffffc0, %rax
movaps (%rax), %xmm5
vpextrq $0, %xmm5, %rbx
nop
nop
nop
nop
sub %r14, %r14
lea addresses_normal_ht+0x17821, %rsi
lea addresses_WC_ht+0x1b6b5, %rdi
clflush (%rdi)
nop
nop
nop
xor %r15, %r15
mov $77, %rcx
rep movsw
nop
nop
cmp $45919, %rdi
lea addresses_normal_ht+0x18cb5, %rsi
lea addresses_A_ht+0x111a5, %rdi
nop
nop
and %r8, %r8
mov $101, %rcx
rep movsq
nop
nop
nop
sub %r15, %r15
lea addresses_WT_ht+0x10735, %r14
clflush (%r14)
nop
nop
nop
nop
inc %rdi
mov $0x6162636465666768, %r15
movq %r15, %xmm4
movups %xmm4, (%r14)
nop
nop
nop
nop
nop
add $44781, %rsi
lea addresses_WT_ht+0xfe9d, %rcx
nop
and %r15, %r15
movw $0x6162, (%rcx)
nop
nop
nop
add %r15, %r15
pop %rsi
pop %rdi
pop %rcx
pop %rbx
pop %rax
pop %r8
pop %r15
pop %r14
pop %r12
ret
.global s_faulty_load
s_faulty_load:
push %r10
push %r14
push %r8
push %rax
push %rdi
push %rdx
push %rsi
// Store
mov $0x149, %rax
nop
sub $52562, %r8
movw $0x5152, (%rax)
nop
nop
nop
xor $63148, %rax
// Store
lea addresses_A+0xb3c5, %r10
nop
nop
nop
nop
nop
dec %rsi
movb $0x51, (%r10)
sub $21240, %rax
// Store
mov $0x2f2e580000000301, %rdx
clflush (%rdx)
nop
nop
nop
nop
xor %rax, %rax
mov $0x5152535455565758, %r14
movq %r14, %xmm4
movups %xmm4, (%rdx)
nop
nop
xor %rdi, %rdi
// Store
lea addresses_US+0x13092, %r10
nop
nop
nop
nop
cmp %rdi, %rdi
movl $0x51525354, (%r10)
nop
nop
nop
nop
and $54199, %rax
// Load
lea addresses_US+0x1a2b5, %rsi
nop
nop
nop
nop
add $35258, %rax
movb (%rsi), %r8b
add %rsi, %rsi
// Store
lea addresses_UC+0x14b5, %rsi
sub $40046, %r14
mov $0x5152535455565758, %rdi
movq %rdi, %xmm6
movups %xmm6, (%rsi)
nop
nop
nop
nop
nop
cmp %rdx, %rdx
// Store
lea addresses_PSE+0xaab5, %rdx
nop
nop
nop
xor %r14, %r14
mov $0x5152535455565758, %rax
movq %rax, %xmm7
vmovups %ymm7, (%rdx)
nop
nop
and %rsi, %rsi
// Store
mov $0xd21, %r8
nop
nop
nop
xor %rax, %rax
movl $0x51525354, (%r8)
nop
nop
xor %rdi, %rdi
// Faulty Load
lea addresses_PSE+0xaab5, %r14
and $44769, %r8
vmovaps (%r14), %ymm4
vextracti128 $1, %ymm4, %xmm4
vpextrq $0, %xmm4, %rdx
lea oracles, %rsi
and $0xff, %rdx
shlq $12, %rdx
mov (%rsi,%rdx,1), %rdx
pop %rsi
pop %rdx
pop %rdi
pop %rax
pop %r8
pop %r14
pop %r10
ret
/*
<gen_faulty_load>
[REF]
{'src': {'congruent': 0, 'AVXalign': False, 'same': False, 'size': 32, 'NT': False, 'type': 'addresses_PSE'}, 'OP': 'LOAD'}
{'OP': 'STOR', 'dst': {'congruent': 2, 'AVXalign': False, 'same': False, 'size': 2, 'NT': False, 'type': 'addresses_P'}}
{'OP': 'STOR', 'dst': {'congruent': 3, 'AVXalign': False, 'same': False, 'size': 1, 'NT': False, 'type': 'addresses_A'}}
{'OP': 'STOR', 'dst': {'congruent': 2, 'AVXalign': False, 'same': False, 'size': 16, 'NT': False, 'type': 'addresses_NC'}}
{'OP': 'STOR', 'dst': {'congruent': 0, 'AVXalign': False, 'same': False, 'size': 4, 'NT': False, 'type': 'addresses_US'}}
{'src': {'congruent': 10, 'AVXalign': False, 'same': False, 'size': 1, 'NT': True, 'type': 'addresses_US'}, 'OP': 'LOAD'}
{'OP': 'STOR', 'dst': {'congruent': 8, 'AVXalign': False, 'same': False, 'size': 16, 'NT': False, 'type': 'addresses_UC'}}
{'OP': 'STOR', 'dst': {'congruent': 0, 'AVXalign': False, 'same': True, 'size': 32, 'NT': False, 'type': 'addresses_PSE'}}
{'OP': 'STOR', 'dst': {'congruent': 2, 'AVXalign': False, 'same': False, 'size': 4, 'NT': False, 'type': 'addresses_P'}}
[Faulty Load]
{'src': {'congruent': 0, 'AVXalign': True, 'same': True, 'size': 32, 'NT': True, 'type': 'addresses_PSE'}, 'OP': 'LOAD'}
<gen_prepare_buffer>
{'src': {'congruent': 7, 'AVXalign': False, 'same': False, 'size': 32, 'NT': False, 'type': 'addresses_WC_ht'}, 'OP': 'LOAD'}
{'OP': 'STOR', 'dst': {'congruent': 4, 'AVXalign': False, 'same': True, 'size': 32, 'NT': False, 'type': 'addresses_D_ht'}}
{'src': {'congruent': 2, 'AVXalign': True, 'same': False, 'size': 16, 'NT': False, 'type': 'addresses_UC_ht'}, 'OP': 'LOAD'}
{'src': {'congruent': 2, 'same': False, 'type': 'addresses_normal_ht'}, 'OP': 'REPM', 'dst': {'congruent': 7, 'same': False, 'type': 'addresses_WC_ht'}}
{'src': {'congruent': 9, 'same': False, 'type': 'addresses_normal_ht'}, 'OP': 'REPM', 'dst': {'congruent': 4, 'same': False, 'type': 'addresses_A_ht'}}
{'OP': 'STOR', 'dst': {'congruent': 2, 'AVXalign': False, 'same': False, 'size': 16, 'NT': False, 'type': 'addresses_WT_ht'}}
{'OP': 'STOR', 'dst': {'congruent': 3, 'AVXalign': False, 'same': False, 'size': 2, 'NT': False, 'type': 'addresses_WT_ht'}}
{'00': 21829}
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
*/
|
src/clic-tty.ads | reznikmm/clic | 9 | 1567 | with ANSI;
package CLIC.TTY
with Preelaborate
is
-- Color/Formatting related subprograms. These won't have any
-- effect if a redirection of output is detected, or if global
-- flag Simple_Logging.Is_TTY is false.
-- Re-expose for clients
package ANSI renames Standard.ANSI;
function Is_TTY return Boolean;
procedure Force_Disable_TTY
with Post => not Is_TTY;
-- Disable TTY support even if availabe
--------------------
-- Color enabling --
--------------------
function Color_Enabled return Boolean;
procedure Disable_Color;
-- Disables color/formatting output even when TTY is capable
procedure Enable_Color (Force : Boolean := False);
-- Prepares colors for the logging messages. Unless Force, will do nothing
-- if a console redirection is detected.
function Format (Text : String;
Fore : ANSI.Colors := ANSI.Default;
Back : ANSI.Colors := ANSI.Default;
Style : ANSI.Styles := ANSI.Default)
return String;
-- Wrap text with the appropriate ANSI sequences. Following text will be
-- unaffected. Default colors are interpreted as no change of color (will
-- result in no color sequences), not as setting the default color (which
-- is always set after a color change).
------------------------
-- Predefined formats --
------------------------
function Info (Text : String := "") return String;
-- Prepends Text with a Emph ("🛈") or "Note: " if no tty color enabled
function Success (Text : String := "") return String;
-- Prepends Text (in normal formatting) with a green check mark, or a
-- simple Success: text if no tty or color enabled.
function OK (Text : String) return String;
-- Bold Light_Green
function Emph (Text : String) return String;
-- Something to highlight not negatively, bold cyan
function Error (Text : String) return String;
-- Bold Red
function Warn (Text : String) return String;
-- Bold Yellow
function Bold (Text : String) return String;
function Dim (Text : String) return String;
function Italic (Text : String) return String;
function Underline (Text : String) return String;
function Description (Text : String) return String;
-- Not bold cyan for crate descriptions
function Terminal (Text : String) return String;
-- For showing commands that the user can run; mimics old amber displays.
function URL (Text : String) return String;
function Version (Text : String) return String;
-- For versions/version sets, bold magenta
private
function Info (Text : String := "") return String is
(if Color_Enabled and then Is_TTY
then Emph ("ⓘ") & " " & Text
else "Note: " & Text);
function Success (Text : String := "") return String is
(if Color_Enabled and then Is_TTY
then OK ("✓") & " " & Text
else "Success: " & Text);
function OK (Text : String) return String is
(Format (Text,
Fore => ANSI.Light_Green,
Style => ANSI.Bright));
function Emph (Text : String) return String is
(Format (Text,
Fore => ANSI.Cyan,
Style => ANSI.Bright));
function Error (Text : String) return String is
(Format (Text,
Fore => ANSI.Red,
Style => ANSI.Bright));
function Warn (Text : String) return String is
(Format (Text,
Fore => ANSI.Yellow,
Style => ANSI.Bright));
function Bold (Text : String) return String is
(Format (Text,
Style => ANSI.Bright));
function Dim (Text : String) return String is
(Format (Text,
Style => ANSI.Dim));
function Italic (Text : String) return String is
(Format (Text,
Style => ANSI.Italic));
function Underline (Text : String) return String is
(Format (Text,
Style => ANSI.Underline));
function Name (Text : String) return String is
(Bold (Text));
function Description (Text : String) return String is
(Format (Text,
Fore => ANSI.Light_Cyan));
function Terminal (Text : String) return String is
(if Color_Enabled and then Is_TTY
then ANSI.Color_Wrap (Text, ANSI.Palette_Fg (5, 3, 0))
else Text);
function URL (Text : String) return String renames Version;
function Version (Text : String) return String is
(Format (Text,
Fore => ANSI.Magenta,
Style => ANSI.Bright));
end CLIC.TTY;
|
main.asm | szymbar15/Mario-Kart-DS-ASM-hacks-from-YouTube-Videos | 1 | 18876 | <gh_stars>1-10
.nds
CustomStuffRegion equ 0x21DA340
Offset equ CustomStuffRegion-DefaultCustomDataStart
DefaultCustomDataStart equ 0x21773C0
KartCount equ #0x25
.open "arm9.bin",0x02000000
.thumb
; List of hooks
.org 0x2025EA8
dcd DefaultKartOrder
.org 0x2025E30
dcd MenuKartIDOrder
.org 0x2025E5C
dcd MenuKartIDOrder
; Reading kart_appear longer
.org 0x2025E18
cmp r4, KartCount
; Loading one more character slot
.org 0x2025DDE
CMP R4, KartCount
.org 0x2025E3C
CMP R4, KartCount
.org 0x2025E50
CMP R4, KartCount
; Arrow left
.org 0x202925A
mov R5, KartCount-1
.org 0x202929A
MOV R5, KartCount-1
; Arrow right
.org 0x20292CA
CMP R5, KartCount
.org 0x202930A
CMP R5, KartCount
.org 0x2025DA0
dcd KartNameReferenceList
.arm
.org 0x2071B3C
bl kartSoundsTable
.include "autoloadtableregen.asm"
.close
.open "arm9.bin",0x02000000+Offset
.skip DefaultCustomDataStart-0x2000000
ExtraDataStartingPosition:
.include "defaultkartorder.asm"
.include "menukartidorder.asm"
.include "kartnamereferencelist.asm"
.include "sounds.asm"
LengthOfTheFile:
.close |
BasicIS4/Syntax/Common.agda | mietek/hilbert-gentzen | 29 | 8768 | <filename>BasicIS4/Syntax/Common.agda
-- Basic intuitionistic modal logic S4, without ∨, ⊥, or ◇.
-- Common syntax.
module BasicIS4.Syntax.Common where
open import Common.ContextPair public
-- Types, or propositions.
infixr 10 □_
infixl 9 _∧_
infixr 7 _▻_
data Ty : Set where
α_ : Atom → Ty
_▻_ : Ty → Ty → Ty
□_ : Ty → Ty
_∧_ : Ty → Ty → Ty
⊤ : Ty
-- Additional useful types.
infix 7 _▻◅_
_▻◅_ : Ty → Ty → Ty
A ▻◅ B = (A ▻ B) ∧ (B ▻ A)
infixr 7 _▻⋯▻_
_▻⋯▻_ : Cx Ty → Ty → Ty
∅ ▻⋯▻ B = B
(Ξ , A) ▻⋯▻ B = Ξ ▻⋯▻ (A ▻ B)
infixr 10 □⋆_
□⋆_ : Cx Ty → Cx Ty
□⋆ ∅ = ∅
□⋆ (Ξ , A) = □⋆ Ξ , □ A
dist□⋆₁ : ∀ Ξ Ξ′ → □⋆ (Ξ ⧺ Ξ′) ≡ (□⋆ Ξ) ⧺ (□⋆ Ξ′)
dist□⋆₁ Ξ ∅ = refl
dist□⋆₁ Ξ (Ξ′ , A) = cong² _,_ (dist□⋆₁ Ξ Ξ′) refl
lift⊆ : ∀ {Δ Δ′} → Δ ⊆ Δ′ → □⋆ Δ ⊆ □⋆ Δ′
lift⊆ done = done
lift⊆ (skip θ) = skip (lift⊆ θ)
lift⊆ (keep θ) = keep (lift⊆ θ)
-- Inversion principles.
invα : ∀ {P P′} → α P ≡ α P′ → P ≡ P′
invα refl = refl
inv▻₁ : ∀ {A A′ B B′} → A ▻ B ≡ A′ ▻ B′ → A ≡ A′
inv▻₁ refl = refl
inv▻₂ : ∀ {A A′ B B′} → A ▻ B ≡ A′ ▻ B′ → B ≡ B′
inv▻₂ refl = refl
inv□ : ∀ {A A′} → □ A ≡ □ A′ → A ≡ A′
inv□ refl = refl
inv∧₁ : ∀ {A A′ B B′} → A ∧ B ≡ A′ ∧ B′ → A ≡ A′
inv∧₁ refl = refl
inv∧₂ : ∀ {A A′ B B′} → A ∧ B ≡ A′ ∧ B′ → B ≡ B′
inv∧₂ refl = refl
-- Decidable equality on types.
_≟ᵀ_ : (A A′ : Ty) → Dec (A ≡ A′)
(α P) ≟ᵀ (α P′) with P ≟ᵅ P′
(α P) ≟ᵀ (α .P) | yes refl = yes refl
(α P) ≟ᵀ (α P′) | no P≢P′ = no (P≢P′ ∘ invα)
(α P) ≟ᵀ (A′ ▻ B′) = no λ ()
(α P) ≟ᵀ (□ A′) = no λ ()
(α P) ≟ᵀ (A′ ∧ B′) = no λ ()
(α P) ≟ᵀ ⊤ = no λ ()
(A ▻ B) ≟ᵀ (α P′) = no λ ()
(A ▻ B) ≟ᵀ (A′ ▻ B′) with A ≟ᵀ A′ | B ≟ᵀ B′
(A ▻ B) ≟ᵀ (.A ▻ .B) | yes refl | yes refl = yes refl
(A ▻ B) ≟ᵀ (A′ ▻ B′) | no A≢A′ | _ = no (A≢A′ ∘ inv▻₁)
(A ▻ B) ≟ᵀ (A′ ▻ B′) | _ | no B≢B′ = no (B≢B′ ∘ inv▻₂)
(A ▻ B) ≟ᵀ (□ A′) = no λ ()
(A ▻ B) ≟ᵀ (A′ ∧ B′) = no λ ()
(A ▻ B) ≟ᵀ ⊤ = no λ ()
(□ A) ≟ᵀ (α P′) = no λ ()
(□ A) ≟ᵀ (A′ ▻ B′) = no λ ()
(□ A) ≟ᵀ (□ A′) with A ≟ᵀ A′
(□ A) ≟ᵀ (□ .A) | yes refl = yes refl
(□ A) ≟ᵀ (□ A′) | no A≢A′ = no (A≢A′ ∘ inv□)
(□ A) ≟ᵀ (A′ ∧ B′) = no λ ()
(□ A) ≟ᵀ ⊤ = no λ ()
(A ∧ B) ≟ᵀ (α P′) = no λ ()
(A ∧ B) ≟ᵀ (A′ ▻ B′) = no λ ()
(A ∧ B) ≟ᵀ (□ A′) = no λ ()
(A ∧ B) ≟ᵀ (A′ ∧ B′) with A ≟ᵀ A′ | B ≟ᵀ B′
(A ∧ B) ≟ᵀ (.A ∧ .B) | yes refl | yes refl = yes refl
(A ∧ B) ≟ᵀ (A′ ∧ B′) | no A≢A′ | _ = no (A≢A′ ∘ inv∧₁)
(A ∧ B) ≟ᵀ (A′ ∧ B′) | _ | no B≢B′ = no (B≢B′ ∘ inv∧₂)
(A ∧ B) ≟ᵀ ⊤ = no λ ()
⊤ ≟ᵀ (α P′) = no λ ()
⊤ ≟ᵀ (A′ ▻ B′) = no λ ()
⊤ ≟ᵀ (□ A′) = no λ ()
⊤ ≟ᵀ (A′ ∧ B′) = no λ ()
⊤ ≟ᵀ ⊤ = yes refl
open ContextEquality (_≟ᵀ_) public
|
test/bugs/LongList.agda | alhassy/agda | 3 | 10508 | <filename>test/bugs/LongList.agda
module LongList where
infixr 6 _∷_
data List (A : Set) : Set where
[] : List A
_∷_ : A -> List A -> List A
postulate
Bool : Set
t : Bool
long : List Bool
long =
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷ t ∷
[]
|
packages/hullrepl/HullReplProtocol/HullReplProtocol.scpt | fossabot/hull-connectors | 0 | 776 | <reponame>fossabot/hull-connectors<filename>packages/hullrepl/HullReplProtocol/HullReplProtocol.scpt
on open location hullReplURL
tell application "iTerm"
tell current window
create tab with default profile
tell current session
write text "hullrepl --url \"" & hullReplURL & "\""
end tell
end tell
end tell
end open location
|
programs/oeis/194/A194386.asm | neoneye/loda | 22 | 2972 | <gh_stars>10-100
; A194386: Numbers m such that Sum_{k=1..m} (<1/2 + k*r> - <k*r>) > 0, where r=sqrt(10) and < > denotes fractional part.
; 1,2,3,4,5,7,8,9,10,11,13,14,15,16,17,19,20,21,22,23,25,26,27,28,29,31,32,33,34,35,37,38,39,40,41,42,43,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75
mov $2,$0
div $0,5
lpb $0
mov $0,6
lpe
add $0,1
add $0,$2
|
grammars/BigDataScript.g4 | augustand/BigDataScript | 0 | 916 | grammar BigDataScript;
import BigDataScriptLexerRules;
//------------------------------------------------------------------------------
// Parser
//------------------------------------------------------------------------------
// Main program
programUnit : eol* statement+;
// End of line (semicolons are optional)
eol : (';' | '\n' )+;
// Types
typeList : type (',' type)* ;
type : 'bool' # typePrimitiveBool
| 'int' # typePrimitiveInt
| 'real' # typePrimitiveReal
| 'string' # typePrimitiveString
| 'void' # typePrimitiveVoid
| type '[' ']' # typeArray
| type '{' '}' # typeMap
| type '{' type '}' # typeMap
;
// Variable declaration
varDeclaration : type variableInit (',' variableInit)* | variableInitImplicit;
variableInit : ID ('=' expression)? HELP_LITERAL?;
variableInitImplicit : ID ':=' expression HELP_LITERAL?;
// Include statement
includeFile : 'include' (STRING_LITERAL | STRING_LITERAL_SINGLE) eol;
// Statements
statement : '{' statement* '}' # block
| 'break' eol* # break
| 'breakpoint' expression? eol* # breakpoint
| 'checkpoint' expression? eol* # checkpoint
| 'continue' eol* # continue
| 'debug' expression? eol* # debug
| 'exit' expression? eol* # exit
| 'print' expression? eol* # print
| 'println' expression? eol* # println
| 'warning' expression? eol* # warning
| 'error' expression? eol* # error
| 'for' '(' ( forInit )?
';' ( forCondition )?
';' ( end=forEnd )?
')' statement eol* # forLoop
| 'for' '(' varDeclaration ':' expression ')' statement eol* # forLoopList
| 'if' '(' expression ')' statement eol* ( 'else' statement eol* )? # if
| 'kill' expression eol* # kill
| 'return' expression? eol* # return
| 'wait' (expression (',' expression)* )? eol* # wait
| 'while' '(' expression? ')' statement eol* # while
| type ID '(' varDeclaration? (',' varDeclaration)* ')' statement eol* # functionDeclaration
| varDeclaration eol* # statementVarDeclaration
| expression eol* # statementExpr
| includeFile eol* # statementInclude
| HELP_LITERAL # help
| eol # statmentEol
;
forInit : varDeclaration | expressionList;
forCondition : expression;
forEnd : expressionList;
expression : BOOL_LITERAL # literalBool
| INT_LITERAL # literalInt
| REAL_LITERAL # literalReal
| STRING_LITERAL # literalString
| STRING_LITERAL_SINGLE # literalString
| ID '('(expression (',' expression )*)? ')' # functionCall
| expression '.' ID '('(expression (',' expression )*)? ')' # methodCall
| ID # referenceVar
| expression '[' expression ']' # referenceList
| expression '{' expression '}' # referenceMap
| ('++' | '--') expression # pre
| expression ('++' | '--') # post
| '~' expression # expressionBitNegation
| '!' expression # expressionLogicNot
| expression '%' expression # expressionModulo
| expression '/' expression # expressionDivide
| expression '*' expression # expressionTimes
| expression '-' expression # expressionMinus
| expression '+' expression # expressionPlus
| expression '<' expression # expressionLt
| expression '>' expression # expressionGt
| expression '<=' expression # expressionLe
| expression '>=' expression # expressionGe
| expression '!=' expression # expressionNe
| expression '==' expression # expressionEq
| '-' expression # expressionUnaryMinus
| '+' expression # expressionUnaryPlus
| expression '&' expression # expressionBitAnd
| expression '^' expression # expressionBitXor
| expression '|' expression # expressionBitOr
| expression '&&' expression # expressionLogicAnd
| expression '||' expression # expressionLogicOr
| '(' expression ')' # expressionParen
| expression '?' expression ':' expression # expressionCond
| expression '<-' expression # expressionDepOperator
| '[' ']' # literalListEmpty
| '[' expression (',' expression)* ']' # literalList
| '{' '}' # literalMapEmpty
| '{' expression '=>' expression (',' expression '=>' expression)* '}' # literalMap
| SYS_LITERAL # expressionSys
| TASK_LITERAL # expressionTaskLiteral
| 'task' ( '(' expression (',' expression)* ')' )? statement # expressionTask
| 'dep' '(' expression (',' expression)* ')' statement # expressionDep
| 'goal' expression # expressionGoal
| ('par' | 'parallel') ( '(' expression (',' expression)* ')' )? statement # expressionParallel
| expression '|=' expression # expressionAssignmentBitOr
| expression '&=' expression # expressionAssignmentBitAnd
| expression '/=' expression # expressionAssignmentDiv
| expression '*=' expression # expressionAssignmentMult
| expression '-=' expression # expressionAssignmentMinus
| expression '+=' expression # expressionAssignmentPlus
| '(' expression (',' expression )+ ')' '=' expression # expressionAssignmentList
| expression '=' expression # expressionAssignment
| ID ':=' expression # expressionVariableInitImplicit
;
expressionList : expression ( ',' expression )* ;
|
Coffeisseur/Like/SafariLikeBot-5-30.applescript | TylerKuster/Automator | 0 | 2900 | <reponame>TylerKuster/Automator<filename>Coffeisseur/Like/SafariLikeBot-5-30.applescript
on run {}
-- Initial delay to allow images to load
delay 5.332081
-- Set hashtag count to number of tabs to cycle through
-- 5 * 30 = 150, don't exceed 350/hour
set hashtagCount to 5
set likeCount to 30
set tabsToMostRecent to 13
set timeoutSeconds to 2.0
set test to "cool"
log test
-- my doPrepareTabs(hashtagCount, tabsToMostRecent, timeoutSeconds)
-- my doLikePosts(hashtagCount, likeCount)
-- return input
end run
on doPrepareTabs(hashtagCount, tabsToMostRecent, timeoutSeconds)
set tabScript to "keystroke \" \" using option down"
set returnScript to "keystroke \"
\" "
set tabSwitchScript to "keystroke \" \" using control down"
repeat hashtagCount times -- Once per hashtag tab
try
my doTabWithTimeout(tabScript, tabsToMostRecent, timeoutSeconds)
my doReturnWithTimeout(returnScript, timeoutSeconds)
my doTabSwitchWithTimeout(tabSwitchScript, timeoutSeconds)
delay 0.332081
on error errorMessage
end try
end repeat
end doPrepareTabs
on doLikePosts(hashtagCount, likeCount)
set clickLikeScript to "click UI Element \"Like\" of group 1 of group 1 of group 1 of group 1 of UI Element 1 of scroll area 1 of group 1 of group 1 of tab group 1 of splitter group 1 of window 1 of application process \"Safari\""
set rightArrowScript to "keystroke \"\""
set closeTabScript to "keystroke \"w\" using command down"
repeat hashtagCount times
try
set endDate to (current date) + 15
repeat likeCount times
try
run script "tell application \"System Events\"
" & clickLikeScript & "
end tell"
delay 0.332081
run script "tell application \"System Events\"
" & rightArrowScript & "
end tell"
delay 0.332081
on error errorMessage
if ((current date) > endDate) then
run script "tell application \"System Events\"
" & closeTabScript & "
end tell"
delay 0.332081
end if
end try
end repeat
on error errorMessage
end try
try
run script "tell application \"System Events\"
" & closeTabScript & "
end tell"
delay 0.332081
on error errorMessage
end try
end repeat
end doLikePosts
-- Tab to most recent picture
on doTabWithTimeout(tabScript, tabsToMostRecent, timeoutSeconds)
-- set endDate to (current date) + timeoutSeconds
repeat tabsToMostRecent times -- Tab to most recent picture
try
run script "tell application \"System Events\"
" & tabScript & "
end tell"
delay 0.332081
on error errorMessage
end try
end repeat
end doTabWithTimeout
-- Press Return to open the picture
on doReturnWithTimeout(returnScript, timeoutSeconds)
set endDate to (current date) + timeoutSeconds
repeat
try
run script "tell application \"System Events\"
" & returnScript & "
end tell"
exit repeat
on error errorMessage
end try
end repeat
end doReturnWithTimeout
-- Press control + tab to switch browser tabs
on doTabSwitchWithTimeout(tabSwitchScript, timeoutSeconds)
set endDate to (current date) + timeoutSeconds
repeat
try
run script "tell application \"System Events\"
" & tabSwitchScript & "
end tell"
exit repeat
on error errorMessage
end try
end repeat
end doTabSwitchWithTimeout |
oeis/052/A052106.asm | neoneye/loda-programs | 11 | 244157 | ; A052106: a(n) = lcm(n, n - phi(n)).
; Submitted by <NAME>
; 0,2,3,4,5,12,7,8,9,30,11,24,13,56,105,16,17,36,19,60,63,132,23,48,25,182,27,112,29,330,31,32,429,306,385,72,37,380,195,120,41,210,43,264,315,552,47,96,49,150,969,364,53,108,165,224,399,870,59,660,61,992,189,64,1105,1518,67,612,1725,1610,71,144,73,1406,525,760,1309,702,79,240,81,1722,83,420,1785,1892,2697,528,89,990,1729,1104,1023,2256,2185,192,97,392,1287,300
mov $1,$0
seq $0,51953 ; Cototient(n) := n - phi(n).
seq $1,109395 ; Denominator of phi(n)/n = Product_{p|n} (1 - 1/p); phi(n)=A000010(n), the Euler totient function.
mul $0,$1
|
Examples/ch15/Colorstr.asm | satadriver/LiunuxOS | 0 | 88331 | <filename>Examples/ch15/Colorstr.asm
TITLE Color String Example (ColorStr.asm)
; This program writes a multicolor string on the display.
; Last update: 8/21/01
INCLUDE Irvine16.inc
.data
ATTRIB_HI = 10000000b
string BYTE "ABCDEFGHIJKLMOP"
color BYTE 1
.code
main PROC
mov ax,@data
mov ds,ax
call ClrScr
call EnableBlinking
mov cx,SIZEOF string
mov si,OFFSET string
L1: push cx ; save loop counter
mov ah,9 ; write character/attribute
mov al,[si] ; character to display
mov bh,0 ; video page 0
mov bl,color ; attribute
or bl,ATTRIB_HI ; set blink/intensity bit
mov cx,1 ; display it one time
int 10h
mov cx,1 ; advance cursor to
call AdvanceCursor ; next screen column
inc color ; next color
inc si ; next character
pop cx ; restore loop counter
Loop L1
call Crlf
exit
main ENDP
;--------------------------------------------------
EnableBlinking PROC
;
; Enable blinking (using the high bit of color
; attributes). In MS-Windows, this only works if
; the program is running in full-screen mode.
; Receives: nothing.
; Returns: nothing
;--------------------------------------------------
push ax
push bx
mov ax,1003h
mov bl,1 ; blinking is enabled
int 10h
pop bx
pop ax
ret
EnableBlinking ENDP
;--------------------------------------------------
AdvanceCursor PROC
;
; Advances the cursor n columns to the right.
; Receives: CX = number of columns
; Returns: nothing
;--------------------------------------------------
pusha
L1:
push cx ; save loop counter
mov ah,3 ; get cursor position
mov bh,0 ; into DH, DL
int 10h ; changes CX register!
inc dl ; increment column
mov ah,2 ; set cursor position
int 10h
pop cx ; restore loop counter
loop L1 ; next column
popa
ret
AdvanceCursor ENDP
END main
|
Ada95/samples/ncurses2-genericputs.ads | CandyROM/external_libncurses | 1,167 | 22730 | ------------------------------------------------------------------------------
-- --
-- GNAT ncurses Binding Samples --
-- --
-- ncurses --
-- --
-- B O D Y --
-- --
------------------------------------------------------------------------------
-- Copyright (c) 2000-2006,2009 Free Software Foundation, Inc. --
-- --
-- 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, distribute with modifications, 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 ABOVE 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. --
-- --
-- Except as contained in this notice, the name(s) of the above copyright --
-- holders shall not be used in advertising or otherwise to promote the --
-- sale, use or other dealings in this Software without prior written --
-- authorization. --
------------------------------------------------------------------------------
-- Author: <NAME> <<EMAIL>> 2000
-- Version Control
-- $Revision: 1.3 $
-- $Date: 2009/12/26 17:38:58 $
-- Binding Version 01.00
------------------------------------------------------------------------------
with Ada.Text_IO; use Ada.Text_IO;
with Ada.Strings.Bounded;
use Ada.Strings.Bounded;
with Interfaces.C; use Interfaces.C;
with Interfaces.C.Strings; use Interfaces.C.Strings;
with Terminal_Interface.Curses;
generic
Max : Natural;
-- type mystring is private;
-- type myint is
package ncurses2.genericPuts is
package BS is new
Ada.Strings.Bounded.Generic_Bounded_Length (Max);
use BS;
procedure myGet (Win : Terminal_Interface.Curses.Window
:= Terminal_Interface.Curses.Standard_Window;
Str : out BS.Bounded_String;
Len : Integer := -1);
procedure myPut (Str : out BS.Bounded_String;
i : Integer;
Base : Number_Base := 10);
-- the default should be Ada.Text_IO.Integer_IO.Default_Base
-- but Default_Base is hidden in the generic so doesn't exist!
procedure myAdd (Str : BS.Bounded_String);
procedure Fill_String (Cp : chars_ptr; Str : out BS.Bounded_String);
end ncurses2.genericPuts;
|
src/main/antlr/com/manymobi/esdsl/antlr4/EsdslParser.g4 | manymobi/esdsl-core | 9 | 6188 | <reponame>manymobi/esdsl-core
parser grammar EsdslParser;
options { tokenVocab=EsdslLexer; }
esdslarray
: esdsl*
;
esdsl
: '==>' ID LINE_SKIPPING? request? json? (LINE_SKIPPING)?
;
request
: REQUEST_METHOD uri
;
uri
: '/'? path? query? WS?
;
path
: string*
;
query
: '?' search
;
search
: searchparameter (AND searchparameter?)*
;
searchparameter
: string ('=' (string | NUMBER ))?
;
string
:ID
|parameter
|TRUE
|FALSE
|NULL
|ROD
|SLASH
;
json
: value
;
obj
: '{' statement (','? statement)* '}'
| '{' '}'
;
pair
: STRING ':' statement
;
array
: '[' statement ((',' value)|statement)* ']'
| '[' ']'
;
value
: STRING
| parameter
| NUMBER
| obj
| array
| 'true'
| 'false'
| 'null'
;
parameter
:PARAMETER
;
ifThenStatement
: '#if' '(' expression ')' statement ('#elseif' '(' expression ')' statement)*('#else' statement)? '#endif'
;
forStatement
:'#for' '(' (index ',')? item 'in' parameter forParameter*? ')' statement '#endfor'
;
forParameter
: 'open' '=' symbolTring
| 'close''=' symbolTring
| 'separator''=' symbolTring
;
symbolTring/*符号*/
:SYMBOL*?
|'\''STRING'\''
;
statement
:pair(','pair)* ','?
|value ','?
|ifThenStatement ','?
|forStatement ','?
;
expression
:singleIfcondition (AND_OR_XOR singleIfcondition)*?
;
singleIfcondition
: wrong? value logicCharacter value
;
logicCharacter
: LOGIC_CHARACTER
;
wrong
:WRONG
;
index
:ID
;
item
:ID
;
|
computer-architecture/labs/seminar_6.asm | vampy/university | 6 | 82164 | <filename>computer-architecture/labs/seminar_6.asm<gh_stars>1-10
=== Seminary 6. 8086 Interrupts. ===
Interrupt - is an electrical signal sent through the control bus of
the cumputing system which signalises the occurence of an event
Interrupts can be generated by :
- hardware components: keyboard(when the user presses a key), network card, etc
- the cpu through software instructions: the cpu can generate an interrupt
when an exception occurs(e.g. division by zero) or as the result of the
instruction 'int'.
When the cpu detects an interrupt it does the following things:
- it suspends the execution of the current program
- it calls the interrupt handling routine(IHR) of that interrupt
- sometimes it resumes the execution of the suspended program
At software level an interrupt is identified by a natural number
The IHR of some interrupts performs different things depending on the
value from AH register; in this case we say the interrupt has several
functions or functionalities.
ex:
1) mov AX, 4C00h
int 21h
- these instruction generates interrupt 21h whoose IHR checks the
value from AH which is 4Ch and executes function 4Ch which
ends/terminates the current program; AL contains the exit code 00h
2) mov AH, 01h
int 21h
- generates interrupt 21h whose IHR executes function 01h which
reads a character from the standard input device(i.e. the keyboard)
and stores its ascii code in AL
3) mov AH, 02h
mov DL, 'a'
int 21h
- generates interrupt 21h whose IHR executes function 02h which
prints to the standard output device(i.e. the screen/display)
the character from DL
== Ex.1 ==
Write a program which reads the name of the file from the keyboard and
deletes that file if it exists.
ASSUME CS:code, DS:data
data SEGMENT
msg DB 'Filename=', '$'
filename DB 12, ?, 13 DUP(?) ; memory buffer(i.e. string) used for
; holding the name of the file
errMsg DB 'Error deleting file', '$'
data ENDS
code SEGMENT
start:
mov AX, data
mov DS, AX
; we print msg on the screen using function 09h of interrupt 21h
; which prints the string with the address in DS:DX(these string must
; end with '$' sign)
mov AH, 09h ; function name
; DS already contains the segment address of msg
mov DX, offset msg ; <=> lea DX, msg
int 21h ; generate the interrupt
; we read the name of the file from the standard input device using
; function 0Ah of interrupt 21h which reads a string and stores the
; string at the memory address DS:DX
; DS:DX should store the address of a memory buffer with the
; following structure:
; - at offset 0 we store the maximum number of characters that should
; be read
; - at offset 1 the IHR will return the actual number of read characters
; - starting at offset 2 the IHR will store the ascii code of the read
; characters
mov AH, 0Ah ; the function name
lea DX, filename
int 21h ; generate the interrupt
; assuming we have read the string 'a.txt' filename will look like this
; see DRAWING 1
; filename variable in memory:
;
; +0 +1 +2 +3 +4 +5 +6 +7
; ------------------------------------------------------------------
; | 12| 5| 'a'| '.'| 't'| 'x'| 't'| |...
; -------------------------------------------------------------------
;
; filenamep[1] is the acutal number of read characters
; we need to put a 0 on filename[7]
;
; DRAWING 1
; in order to use function 41h of interrupt 21h we first need to
; transform the filename string into asciiz string (which is a string
; that ends in 0)
; the offset of the last character of filename is
; offset filename + filename[1] + 2
mov AL, filename[1]
mov AH, 0 ; unsigned conversion of AL to AX
add AX, offset filename + 2
mov SI, AX
mov bytes PTR [SI], 0 ; put 0 at the end of filename
; we delete the file using function 41h of interrupt 21h which deletes
; the file with the name whose address is in DS:DX
mov AH, 41h
mov DX, offset filename + 2 ; <=> lea DX, filename + 2
; we use filename + 2 because the name of the file starts at offset
; 2 in the filename
int 21h
; function 41h of interrupt 41h sets CF(carry flag) if an error occurs
jnc the_end ; if CF != 1 jump to the end of the program
; else print an error message using function 09h of interrupt 21h
mov AH, 09h
mov DX, offset errMsg
int 21h
the_end:
mov AX, 4C00h
int 21h
code ENDS
END start
== Ex.2 ==
Write a program which prints on the screen the value in base 10 of AX and BX
ASSUME CS:code, DS:data
data SEGMENT
msg1 DB 'AX=', '$'
msg2 DB 'BX=', '$'
newline DB 10, 13, '$' ; printing these 2 characters moves the writing
; prompt from the beggining of a new line
; 10 - is line feed
; 13 - carry return
ten DW 10
data ENDS
code SEGMENT
print_base10 PROC ; define a procedure wich prints AX in base 10
; if AX is negative we print a minus sign
cmp AX, 0h
jge positive
push AX ; save AX on the stack
mov AH, 02h
mov DL, '-'
int 21h ; print '-'
pop AX ; restore AX from the stack
neg AX ; AX = |AX| - convert to absolute value
positive:
mov CX, 0 ; CX will store the number of digits we put on the stack
repeat:
; in order to avoid situations in which the quotient of the division
; AX / 10 does not fit onto AL we always convert AX to DX:AX and divide it
; to a word with the value 10
mov DX, 0
div ten
push DX ; put the digit which is the remainder on the stack
inc CX
cmp AX, 0
ja repeat
; loop until the quotient is zero
; now we have to pop CX digits from the stack and print them on the screen
get_digits:
pop DX ; the digit is in DL
add DL, '0' ; obtain the ascii code of the digit
mov AH, 02h
int 21h ; print the digit using function 02h of interrupt 21h
loop get_digits
ret ; return from procedure
print_base10 ENDP ; end of the procedure
start:
mov AX, data
mov DS, AX
; print the value of AX
mov AH, 09h
lea DX, msg1
int 21h ; print msg1 to the screen
call print_base10 ; call the procedure
; print a new line
mov AH, 09h
lea DX, newline
int 21h
;print the value of BX
mov AH, 09h
lea DX, msg2
int 21h ; print msg2 to the screen
mov AX, BX
call print_base10 ; print the value of BX in base 10
mov AX, 4C00h
int 21h
code ENDS
END start
|
tools/EmoMemory Code Gen.applescript | aureliojargas/emomemory | 1 | 1494 | -- Copy the email to the clipboard and run
on split(theText, theSeparator)
if theText is "" then return {}
set AppleScript's text item delimiters to theSeparator
set theList to text items of theText
set AppleScript's text item delimiters to ""
return theList
end split
on gen_code(email)
set magic to 84 -- D. cell
set mask to {"A", "C", "5", "2", "D", "B", "3", "F", "8", "7"}
set sum to 0
-- E-mail chars -> numbers, add all of them in one big number
repeat with i from 1 to count email
set sum to sum + (((ASCII number character i of email) + magic + i))
end repeat
-- Make sure we have at least 7 digits
set sum to sum * 333 as text
-- Mask numbers to fake hexa
set sumHexa to ""
repeat with c in characters of sum
set sumHexa to sumHexa & item (c + 1) of mask
end repeat
return email & ":" & sumHexa
end gen_code
set email to the clipboard
gen_code(email)
|
oeis/133/A133645.asm | neoneye/loda-programs | 11 | 21303 | ; A133645: Integers arising in A133677.
; Submitted by <NAME>
; 2,5,15,77,187,345,551,1107,1457,1855,2301,3337,4565,5251,6767,7597,8475,11397,12467,14751,18537,19895,21301,24257,25807,34277,36115,38001,41917,43947,46025,48151,52547,57135,64377,66887,80157,82955,85801
seq $0,45309 ; Primes congruent to {0, 2} mod 3.
mul $0,2
add $2,$0
bin $2,2
mov $0,$2
div $0,3
|
so/overlay/src/overlay6.asm | bmnascimento/von-neumann-simulator | 0 | 88738 | <filename>so/overlay/src/overlay6.asm
@ 600
k ff
k ff
k ff
k ff
k ff
k ff
k ff
k ff
k ff
k ff
k ff
k ff
k ff
k ff
k ff
k ff
k ff
k ff
k ff
k ff
k ff
k ff
k ff
k ff
k ff
k ff
k ff
k ff
k ff
k ff
k ff
k ff
k ff
k ff
k ff
k ff
k ff
k ff
k ff
k ff
k ff
k ff
k ff
k ff
k ff
k ff
k ff
k ff
k ff
k ff
k ff
k ff
k ff
k ff
k ff
k ff
k ff
k ff
k ff
k ff
k ff
k ff
k ff
k ff
k ff
k ff
k ff
k ff
k ff
k ff
k ff
k ff
k ff
k ff
k ff
k ff
k ff
k ff
k ff
k ff
k ff
k ff
k ff
k ff
k ff
k ff
k ff
k ff
k ff
k ff
k ff
k ff
k ff
k ff
k ff
k ff
k ff
k ff
k ff
k ff
|
FactorialByFucntion.asm | ARBII-xD/AssemblyCodes | 0 | 23460 | <filename>FactorialByFucntion.asm<gh_stars>0
.data
msg1: .asciiz "Enter the num: "
out1: .asciiz "The result of factorial is: "
.text
.globl main
.ent main
main:
#print Enter the num
li $v0, 4
la $a0, msg1
syscall
#input the num
li $v0, 5
syscall
#$t0 <- num
move $t0, $v0
#passes the parameters
move $a0, $t0
jal factorial
#return the function value to the $s0
move $t0, $v0
#print message out1
li $v0, 4
la $a0, out1
syscall
#printing result
li $v0, 1
move $a0, $t0
syscall
#exit
li $v0,10
syscall
factorial:
addi $sp, $sp, -4
sw $s0, 0($sp)
#counter
li, $s0, 1
loop:
beq $t0, $0, exit
mult $s0, $t0
mflo $s0
mfhi $t1
add $s0, $s0, $t1
addi $t0, $t0, -1
j loop
exit:
move $v0, $s0
lw $s0, 0($sp)
addi $sp, $sp, 4
jr $ra
.end main
|
Transynther/x86/_processed/NONE/_xt_/i3-7100_9_0x84_notsx.log_21829_1565.asm | ljhsiun2/medusa | 9 | 101885 | .global s_prepare_buffers
s_prepare_buffers:
push %r10
push %r14
push %rbp
push %rbx
push %rcx
push %rdi
push %rsi
lea addresses_A_ht+0x13750, %r14
clflush (%r14)
and $31790, %rbp
movups (%r14), %xmm3
vpextrq $1, %xmm3, %rbx
nop
nop
nop
nop
nop
and $20254, %rsi
lea addresses_UC_ht+0xbb1, %r10
nop
nop
nop
nop
add $911, %r14
movb (%r10), %cl
nop
nop
nop
xor %rsi, %rsi
lea addresses_A_ht+0x4550, %rsi
lea addresses_WT_ht+0x12200, %rdi
clflush (%rsi)
nop
nop
nop
nop
nop
dec %r10
mov $21, %rcx
rep movsq
nop
nop
nop
nop
nop
add %rsi, %rsi
pop %rsi
pop %rdi
pop %rcx
pop %rbx
pop %rbp
pop %r14
pop %r10
ret
.global s_faulty_load
s_faulty_load:
push %r14
push %r15
push %r8
push %r9
push %rbx
push %rdx
push %rsi
// Store
lea addresses_UC+0x1c7f0, %r9
nop
nop
nop
cmp $12822, %rdx
movb $0x51, (%r9)
nop
nop
nop
nop
nop
add $32744, %rbx
// Store
lea addresses_WT+0x121d0, %r15
nop
sub %rsi, %rsi
movl $0x51525354, (%r15)
nop
nop
nop
nop
sub $17880, %rsi
// Store
lea addresses_WC+0x1a150, %rbx
nop
nop
sub $56630, %r8
movw $0x5152, (%rbx)
nop
xor $54101, %rbx
// Store
lea addresses_WC+0xf550, %rdx
nop
cmp %rsi, %rsi
movl $0x51525354, (%rdx)
nop
nop
nop
cmp $51116, %r15
// Faulty Load
lea addresses_WT+0x15d50, %r9
clflush (%r9)
nop
nop
nop
xor $29020, %r14
movups (%r9), %xmm5
vpextrq $1, %xmm5, %rbx
lea oracles, %rsi
and $0xff, %rbx
shlq $12, %rbx
mov (%rsi,%rbx,1), %rbx
pop %rsi
pop %rdx
pop %rbx
pop %r9
pop %r8
pop %r15
pop %r14
ret
/*
<gen_faulty_load>
[REF]
{'src': {'type': 'addresses_WT', 'same': False, 'size': 1, 'congruent': 0, 'NT': True, 'AVXalign': False}, 'OP': 'LOAD'}
{'dst': {'type': 'addresses_UC', 'same': False, 'size': 1, 'congruent': 5, 'NT': False, 'AVXalign': False}, 'OP': 'STOR'}
{'dst': {'type': 'addresses_WT', 'same': False, 'size': 4, 'congruent': 7, 'NT': False, 'AVXalign': False}, 'OP': 'STOR'}
{'dst': {'type': 'addresses_WC', 'same': False, 'size': 2, 'congruent': 10, 'NT': False, 'AVXalign': False}, 'OP': 'STOR'}
{'dst': {'type': 'addresses_WC', 'same': False, 'size': 4, 'congruent': 11, 'NT': False, 'AVXalign': False}, 'OP': 'STOR'}
[Faulty Load]
{'src': {'type': 'addresses_WT', 'same': True, 'size': 16, 'congruent': 0, 'NT': False, 'AVXalign': False}, 'OP': 'LOAD'}
<gen_prepare_buffer>
{'src': {'type': 'addresses_A_ht', 'same': False, 'size': 16, 'congruent': 9, 'NT': False, 'AVXalign': False}, 'OP': 'LOAD'}
{'src': {'type': 'addresses_UC_ht', 'same': False, 'size': 1, 'congruent': 0, 'NT': False, 'AVXalign': False}, 'OP': 'LOAD'}
{'src': {'type': 'addresses_A_ht', 'congruent': 9, 'same': True}, 'dst': {'type': 'addresses_WT_ht', 'congruent': 2, 'same': False}, 'OP': 'REPM'}
{'39': 21829}
39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39
*/
|
programs/oeis/257/A257113.asm | neoneye/loda | 22 | 103191 | <filename>programs/oeis/257/A257113.asm
; A257113: a(1) = 2, a(2) = 3; thereafter a(n) is the sum of all the previous terms.
; 2,3,5,10,20,40,80,160,320,640,1280,2560,5120,10240,20480,40960,81920,163840,327680,655360,1310720,2621440,5242880,10485760,20971520,41943040,83886080,167772160,335544320,671088640,1342177280,2684354560,5368709120,10737418240,21474836480,42949672960,85899345920,171798691840,343597383680,687194767360,1374389534720,2748779069440,5497558138880,10995116277760,21990232555520,43980465111040,87960930222080,175921860444160,351843720888320,703687441776640,1407374883553280,2814749767106560,5629499534213120,11258999068426240,22517998136852480,45035996273704960,90071992547409920,180143985094819840,360287970189639680,720575940379279360,1441151880758558720,2882303761517117440,5764607523034234880,11529215046068469760,23058430092136939520,46116860184273879040,92233720368547758080,184467440737095516160,368934881474191032320,737869762948382064640,1475739525896764129280,2951479051793528258560,5902958103587056517120,11805916207174113034240,23611832414348226068480,47223664828696452136960,94447329657392904273920,188894659314785808547840,377789318629571617095680,755578637259143234191360,1511157274518286468382720,3022314549036572936765440,6044629098073145873530880,12089258196146291747061760,24178516392292583494123520,48357032784585166988247040,96714065569170333976494080,193428131138340667952988160,386856262276681335905976320,773712524553362671811952640,1547425049106725343623905280,3094850098213450687247810560,6189700196426901374495621120,12379400392853802748991242240,24758800785707605497982484480,49517601571415210995964968960,99035203142830421991929937920,198070406285660843983859875840,396140812571321687967719751680,792281625142643375935439503360
mov $1,2
pow $1,$0
mul $1,5
add $1,3
div $1,4
mov $0,$1
|
llvm-gcc-4.2-2.9/gcc/ada/a-dirval.adb | vidkidz/crossbridge | 1 | 13316 | <filename>llvm-gcc-4.2-2.9/gcc/ada/a-dirval.adb
------------------------------------------------------------------------------
-- --
-- GNAT RUN-TIME COMPONENTS --
-- --
-- A D A . D I R E C T O R I E S . V A L I D I T Y --
-- --
-- B o d y --
-- (POSIX Version) --
-- --
-- Copyright (C) 2004-2005, 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, 51 Franklin Street, Fifth Floor, --
-- Boston, MA 02110-1301, USA. --
-- --
-- As a special exception, if other files instantiate generics from this --
-- unit, or you link this unit with other files to produce an executable, --
-- this unit does not by itself cause the resulting executable to be --
-- covered by the GNU General Public License. This exception does not --
-- however invalidate any other reasons why the executable file might be --
-- covered by the GNU Public License. --
-- --
-- GNAT was originally developed by the GNAT team at New York University. --
-- Extensive contributions were provided by Ada Core Technologies Inc. --
-- --
------------------------------------------------------------------------------
-- This is the POSIX version of this package
package body Ada.Directories.Validity is
---------------------------------
-- Is_Path_Name_Case_Sensitive --
---------------------------------
function Is_Path_Name_Case_Sensitive return Boolean is
begin
return True;
end Is_Path_Name_Case_Sensitive;
------------------------
-- Is_Valid_Path_Name --
------------------------
function Is_Valid_Path_Name (Name : String) return Boolean is
begin
-- A path name cannot be empty and cannot contain any NUL character
if Name'Length = 0 then
return False;
else
for J in Name'Range loop
if Name (J) = ASCII.NUL then
return False;
end if;
end loop;
end if;
-- If Name does not contain any NUL character, it is valid
return True;
end Is_Valid_Path_Name;
--------------------------
-- Is_Valid_Simple_Name --
--------------------------
function Is_Valid_Simple_Name (Name : String) return Boolean is
begin
-- A file name cannot be empty and cannot contain a slash ('/') or
-- the NUL character.
if Name'Length = 0 then
return False;
else
for J in Name'Range loop
if Name (J) = '/' or else Name (J) = ASCII.NUL then
return False;
end if;
end loop;
end if;
-- If Name does not contain any slash or NUL, it is valid
return True;
end Is_Valid_Simple_Name;
-------------
-- OpenVMS --
-------------
function OpenVMS return Boolean is
begin
return False;
end OpenVMS;
end Ada.Directories.Validity;
|
programs/oeis/229/A229279.asm | karttu/loda | 0 | 6561 | <reponame>karttu/loda
; A229279: Number of ascending runs in {1,...,5}^n.
; 0,5,40,275,1750,10625,62500,359375,2031250,11328125,62500000,341796875,1855468750,10009765625,53710937500,286865234375,1525878906250,8087158203125,42724609375000,225067138671875,1182556152343750,6198883056640625,32424926757812500
mov $1,$0
mov $2,$0
lpb $0,1
add $1,1
add $1,$2
add $1,$2
mov $2,$1
add $1,$0
sub $0,1
sub $1,$0
add $2,$1
lpe
|
1A/S6/Architecture/TPs/TP3_4/sieve_eratosthenes.asm | MOUDDENEHamza/ENSEEIHT | 4 | 25152 | <filename>1A/S6/Architecture/TPs/TP3_4/sieve_eratosthenes.asm
//-----------------------------------------------------------------------------------------
// Implement the sieve of eratosthenes, the purpose of this program is to eliminate from an
// array of n items all the items which are multile of another
//
// @author <NAME>
//-----------------------------------------------------------------------------------------
set T , %r1 // %r1 = &T
set elim , %r6 // %r6 = &elim
set n , %r4 // %r4 = &n
ld [%r4] , %r4 // %r4 = n
sub %r4, 2, %r12 // %r12 = n - 2
sub %r4, 1, %r4 // %r4 = n - 1
clr %r2 // i = 0
loop1: cmp %r2, %r12 // if (i < n - 2)
bg endloop1 // si i > n - 2 goto to endloop1
ld[%r6 + %r2], %r7 // %r7 = elim[i]
if1: cmp %r7, 0 // if (elim[i] == 0)
bne endif1 // if (elim[i] != 0) goto endif1
ld[%r1 + %r2], %r5 // %r5 = T[i]
add %r2, 1, %r8 // %r8 = j = i + 1
loop2: cmp %r8, %r4 // if (j < n - 1)
bg endloop2 // if (j > n - 1) goto endloop2
ld[%r1 + %r8], %r10 // %r10 = T[j]
ld[%r1 + %r2], %r11 // %r11 = x = T[i]
loop3: cmp %r11, %r10 // if (x < T[j])
bge endloop3 // if (x >= T[j]) goto endloop3
add %r11, %r5, %r11 // %r11 = x = x + T[i]
bl loop3 // if (x < T[j]) goto endloop3
endloop3: // Quit loop3
if2: cmp %r11, %r10 // if (x == T[j])
bne endif2 // if (x != T[j]) goto enif2
clr %r13 // %r13 = 0
inc %r13 // %r13 = 1
st %r13, [%r6 + %r8] // %r13 = elim[j] = 1
endif2: // Quit if2
inc %r8 // j += 1
cmp %r8, %r4 // if (j < n - 1)
ble loop2 // if (j <= n - 1) goto loop2
endloop2: // Quit loop2
endif1: // Quit if1
inc %r2 // i += 1
cmp %r2, %r12 // if (i < n - 2)
ble loop1 // if (i <= n - 2) goto loop1
endloop1: ba endloop1 // Quit loop1
elim : .word 0, 0, 0, 0, 0, 0, 0, 0, 0, 0
T: .word 3, 4, 7, 12, 13, 15, 16, 20, 23, 37
n: .word 10
|
Function/Equals/Proofs.agda | Lolirofle/stuff-in-agda | 6 | 11277 | module Function.Equals.Proofs where
import Lvl
open import Data
import Functional
import Function.Equals
open import Logic.Predicate
open import Logic.Propositional
open import Structure.Setoid
open import Structure.Function
import Structure.Operator.Names as Names
open import Structure.Operator.Properties
open import Structure.Operator
open import Structure.Relator.Equivalence
open import Structure.Relator.Properties
open import Syntax.Transitivity
open import Syntax.Type
open import Type
private variable ℓ ℓ₁ ℓ₂ ℓ₃ ℓ₄ ℓₑ ℓᵤ ℓₑ₁ ℓₑ₂ ℓₑ₃ ℓₑ₄ : Lvl.Level
module Dependent where
open Functional using (id)
open import Functional.Dependent
open Function.Equals.Dependent
module _ {A : Type{ℓ₁}} {B : A → Type{ℓ₂}} ⦃ equiv-B : ∀{a} → Equiv{ℓₑ₂}(B(a)) ⦄ where
[⊜]-identityₗ : Identityₗ {T₂ = (a : A) → B(a)} (_∘_)(id)
_⊜_.proof (Identityₗ.proof [⊜]-identityₗ) {x} = reflexivity(_≡_) ⦃ Equiv.reflexivity equiv-B ⦄
module _ {A : Type{ℓ₁}} {B : Type{ℓ₂}} {C : B → Type{ℓ₂}} ⦃ equiv-C : ∀{b} → Equiv{ℓₑ₃}(C(b)) ⦄ where
[⊜][∘]ₗ-function-raw : ∀{f₁ f₂ : (b : B) → C(b)}{g : A → B} → (f₁ ⊜ f₂) → ((f₁ ∘ g) ⊜ (f₂ ∘ g))
[⊜][∘]ₗ-function-raw {g = g} (intro feq) = intro(\{x} → feq{g(x)})
module _ {A : Type{ℓ₁}} {B : A → Type{ℓ₂}} {C : (a : A) → B(a) → Type{ℓ₃}} ⦃ equiv-C : ∀{a}{b} → Equiv{ℓₑ₃}(C(a)(b)) ⦄ where
[⊜][∘ₛ]ₗ-function-raw : ∀{f₁ f₂ : (a : A) → (b : B(a)) → C(a)(b)}{g : (a : A) → B(a)} → (f₁ ⊜ f₂) → ((f₁ ∘ₛ g) ⊜ (f₂ ∘ₛ g))
[⊜][∘ₛ]ₗ-function-raw {g = g} (intro feq) = intro(\{x} → _⊜_.proof (feq{x}) {g(x)})
-- module _ {A : Type{ℓ₁}} {B : Type{ℓ₂}} {C : B → Type{ℓ₃}} ⦃ _ : Equiv(B) ⦄ ⦃ equiv-C : ∀{b} → Equiv(C(b)) ⦄ {f₁ f₂ : (b : B) → C(b)} ⦃ _ : Function(f₂) ⦄ where (TODO: Requires Function to be able to take a dependent function)
-- [⊜][∘]-binaryOperator-raw : (f₁ ⊜ f₂) → ∀{g₁ g₂ : A → B} → (g₁ ⊜ g₂) → (f₁ ∘ g₁ ⊜ f₂ ∘ g₂)
-- [⊜][∘]-binaryOperator-raw feq (intro geq) = [⊜][∘]ₗ-function-raw feq 🝖 (intro(congruence₁(f₂) (geq)))
open Functional
open Function.Equals
private variable A B C D A₁ A₂ B₁ B₂ : Type{ℓ}
-- TODO: Rename all these so that they mention (_∘_)
module _ ⦃ _ : let _ = A in Equiv{ℓₑ₂}(B) ⦄ where
[⊜]-identityₗ : Identityₗ {T₂ = A → B} (_∘_)(id)
_⊜_.proof(Identityₗ.proof([⊜]-identityₗ)) = reflexivity(_≡_)
[⊜]-identityᵣ : Identityᵣ {T₁ = A → B} (_∘_)(id)
_⊜_.proof(Identityᵣ.proof([⊜]-identityᵣ)) = reflexivity(_≡_)
module _ ⦃ _ : Equiv{ℓₑ}(A) ⦄ where
[⊜]-identity : Identity {T = A → A} (_∘_)(id)
[⊜]-identity = intro ⦃ left = [⊜]-identityₗ ⦄ ⦃ right = [⊜]-identityᵣ ⦄
module _ ⦃ _ : let _ = A ; _ = B ; _ = C ; _ = D in Equiv{ℓₑ₄}(D) ⦄ where
[⊜]-associativity : Names.AssociativityPattern {T₁ = C → D} {T₂ = B → C} {T₃ = A → B} (_∘_)(_∘_)(_∘_)(_∘_)
_⊜_.proof ([⊜]-associativity {f} {g} {h}) {x} = reflexivity(_≡_)
module _ ⦃ _ : Equiv{ℓₑ₁}(Empty{ℓₑ}) ⦄ where
[⊜]-emptyₗ : ∀{f g : A → Empty{ℓₑ}} → (f ⊜ g)
[⊜]-emptyₗ {f = f} = intro(\{x} → empty(f(x)))
module _ ⦃ _ : Equiv{ℓₑ}(A) ⦄ where
[⊜]-emptyᵣ : ∀{f g : Empty{ℓₑ} → A} → (f ⊜ g)
[⊜]-emptyᵣ = intro(\{})
module _ ⦃ _ : Equiv{ℓₑ}(Unit{ℓᵤ}) ⦄ where
[⊜]-unitₗ : ∀{f g : A → Unit{ℓᵤ}} → (f ⊜ g)
[⊜]-unitₗ = intro(reflexivity(_≡_))
module _ ⦃ _ : let _ = A ; _ = B ; _ = C in Equiv{ℓₑ₃}(C) ⦄ where
[⊜][∘]ₗ-function-raw : ∀{f₁ f₂ : B → C}{g : A → B} → (f₁ ⊜ f₂) → ((f₁ ∘ g) ⊜ (f₂ ∘ g))
[⊜][∘]ₗ-function-raw {g = g} (intro feq) = intro(\{x} → feq{g(x)})
module _ ⦃ _ : let _ = A in Equiv{ℓₑ₂}(B) ⦄ ⦃ _ : Equiv{ℓₑ₃}(C) ⦄ {f₁ f₂ : B → C} ⦃ func₂ : Function(f₂) ⦄ {g₁ g₂ : A → B} where
[⊜][∘]-binaryOperator-raw : (f₁ ⊜ f₂) → (g₁ ⊜ g₂) → (f₁ ∘ g₁ ⊜ f₂ ∘ g₂)
[⊜][∘]-binaryOperator-raw feq (intro geq) = [⊜][∘]ₗ-function-raw feq 🝖 (intro(congruence₁(f₂) (geq)))
module _ ⦃ _ : let _ = A in Equiv{ℓₑ₂}(B) ⦄ ⦃ _ : Equiv{ℓₑ₃}(C) ⦄ ⦃ function : ∀{f : B → C} → Function(f) ⦄ where
instance
[⊜][∘]-binaryOperator : BinaryOperator(_∘_ {X = A}{Y = B}{Z = C})
BinaryOperator.congruence [⊜][∘]-binaryOperator = [⊜][∘]-binaryOperator-raw
module _ ⦃ _ : let _ = A in Equiv{ℓₑ₂}(B) ⦄ where
[⊜]-abstract : ∀{a b : B} → (a ≡ b) → ((x ↦ a) ⊜ ((x ↦ b) :of: (A → B)))
[⊜]-abstract {a} {b} x = intro x
[⊜]-apply : ∀{f g : A → B} → (f ⊜ g) → (∀{x} → (f(x) ≡ g(x)))
[⊜]-apply (intro proof) = proof
-- TODO: Is this correct?
-- [⊜]-not-all : ∀{ℓ₁ ℓ₂}{T₁ : Type{ℓ₁}}{T₂ : Type{ℓ₂}} → (∀{f g : T₁ → T₂} → (f ⊜ g)) → IsEmpty(T₁)
-- [⊜]-not-all{_}{_} {_} {_}{_} = intro(\{})
{- TODO: What assumptions? Unprovable?
module _
{ℓ} -- {ℓ₁}{ℓ₂}{ℓ₃}{ℓ₄}
{A : Type{ℓ}} ⦃ _ : Equiv(A) ⦄
{B : Type{ℓ}} ⦃ _ : Equiv(B) ⦄
{C : Type{ℓ}} ⦃ eq-c : Equiv(C) ⦄
{D : Type{ℓ}} ⦃ eq-d : Equiv(D) ⦄
{f : (A → B) → (C → D)}
⦃ fn : ∀{ab} → Function {T₁ = C} ⦃ eq-c ⦄ {T₂ = D} ⦃ eq-d ⦄ (f(ab)) ⦄
where
instance
[⊜]-function : Function {T₁ = A → B} ⦃ [⊜]-equiv ⦄ {T₂ = C → D} ⦃ [⊜]-equiv ⦄ (f)
_⊜_.proof (Function.congruence ([⊜]-function) {g} {h} (intro eq)) {x} = {!!}
-}
|
Lab4/lab4d.adb | albinjal/ada_basic | 3 | 17414 | with Date_Package; use Date_Package;
with Ada.Text_IO; use Ada.Text_IO;
procedure Lab4d is
type Dates is array (1..10) of Date_Type;
procedure Test_Get(Date: out Date_Type) is
begin
loop
begin
Get(Date);
exit;
exception
when YEAR_ERROR => Put_Line("FEL: YEAR_ERROR");
when MONTH_ERROR => Put_Line("FEL: MONTH_ERROR");
when DAY_ERROR => Put_Line("FEL: DAY_ERROR");
when FORMAT_ERROR => Put_Line("FEL: FORMAT_ERROR");
end;
end loop;
end Test_Get;
Date: Date_Type;
Date2: Date_Type;
begin
Put("Ange ett datum: ");
Test_Get(Date);
Put("Ange ett till datum: ");
Test_Get(Date2);
Put("Ett datum: ");
Put(Date); New_Line;
Put("Ett till datum: ");
Put(Date2); New_Line;
if Date = Date2 then
Put("Lika"); New_Line;
else
Put("Olika"); New_Line;
end if;
if Date > Date2 then
Put(Date); Put(" > "); Put(Date2); New_Line;
else
Put(Date); Put(" !!> "); Put(Date2); New_Line;
end if;
if Date < Date2 then
Put(Date); Put(" < "); Put(Date2); New_Line;
else
Put(Date); Put(" !!< "); Put(Date2); New_Line;
end if;
end Lab4d;
|
oeis/268/A268730.asm | neoneye/loda-programs | 11 | 97303 | ; A268730: a(n) = Product_{k = 0..n} 2*(8*k + 5).
; Submitted by <NAME>(s1.)
; 10,260,10920,633360,46868640,4218177600,447126825600,54549472723200,7527827235801600,1159285394313446400,197078517033285888000,36656604168191175168000,7404634041974617383936000,1614210221150466589698048000,377725191749209181989343232000,94431297937302295497335808000000,25118725251322410602291324928000000,7083480520872919789846153629696000000,2110877195220130097374153781649408000000,662815439299120850575484287437914112000000,218729094968709880689909814854511656960000000
mov $1,1
mov $2,10
lpb $0
sub $0,1
add $2,16
mul $1,$2
lpe
mov $0,$1
mul $0,10
|
Palmtree.Math.Core.Implements/vs_build/x64_Debug/pmc_parse.asm | rougemeilland/Palmtree.Math.Core.Implements | 0 | 17855 | ; Listing generated by Microsoft (R) Optimizing Compiler Version 19.16.27026.1
include listing.inc
INCLUDELIB MSVCRTD
INCLUDELIB OLDNAMES
msvcjmc SEGMENT
__7B7A869E_ctype@h DB 01H
__457DD326_basetsd@h DB 01H
__4384A2D9_corecrt_memcpy_s@h DB 01H
__4E51A221_corecrt_wstring@h DB 01H
__2140C079_string@h DB 01H
__1887E595_winnt@h DB 01H
__9FC7C64B_processthreadsapi@h DB 01H
__FA470AEC_memoryapi@h DB 01H
__F37DAFF1_winerror@h DB 01H
__7A450CCC_winbase@h DB 01H
__B4B40122_winioctl@h DB 01H
__86261D59_stralign@h DB 01H
__7B8DBFC3_pmc_uint_internal@h DB 01H
__6B0481B0_pmc_inline_func@h DB 01H
__C5BBD3C1_pmc_parse@c DB 01H
msvcjmc ENDS
PUBLIC Initialize_Parse
PUBLIC PMC_TryParse
PUBLIC __JustMyCode_Default
PUBLIC ??_C@_13DEFPDAGF@?$AA?0@ ; `string'
PUBLIC ??_C@_13JOFGPIOO@?$AA?4@ ; `string'
PUBLIC ??_C@_01EKENIIDA@3@ ; `string'
PUBLIC ??_C@_13KJIIAINM@?$AA?$CL@ ; `string'
PUBLIC ??_C@_13IMODFHAA@?$AA?9@ ; `string'
EXTRN __imp_lstrcpyA:PROC
EXTRN __imp_lstrcpyW:PROC
EXTRN __imp_lstrlenW:PROC
EXTRN AllocateBlock:PROC
EXTRN DeallocateBlock:PROC
EXTRN CheckBlockLight:PROC
EXTRN AllocateNumber:PROC
EXTRN DeallocateNumber:PROC
EXTRN CommitNumber:PROC
EXTRN CheckNumber:PROC
EXTRN _RTC_CheckStackVars:PROC
EXTRN _RTC_InitBase:PROC
EXTRN _RTC_Shutdown:PROC
EXTRN __CheckForDebuggerJustMyCode:PROC
EXTRN __GSHandlerCheck:PROC
EXTRN __security_check_cookie:PROC
EXTRN number_zero:BYTE
EXTRN statistics_info:BYTE
EXTRN __ImageBase:BYTE
EXTRN __security_cookie:QWORD
_BSS SEGMENT
default_number_format_option DB 028H DUP (?)
fp_MultiplyAndAdd DQ 01H DUP (?)
_BSS ENDS
; COMDAT pdata
pdata SEGMENT
$pdata$Initialize_Parse DD imagerel $LN5
DD imagerel $LN5+243
DD imagerel $unwind$Initialize_Parse
pdata ENDS
; COMDAT pdata
pdata SEGMENT
$pdata$PMC_TryParse DD imagerel $LN12
DD imagerel $LN12+348
DD imagerel $unwind$PMC_TryParse
pdata ENDS
; COMDAT pdata
pdata SEGMENT
$pdata$IncrementMULTI32Counter DD imagerel IncrementMULTI32Counter
DD imagerel IncrementMULTI32Counter+62
DD imagerel $unwind$IncrementMULTI32Counter
pdata ENDS
; COMDAT pdata
pdata SEGMENT
$pdata$IncrementMULTI64Counter DD imagerel IncrementMULTI64Counter
DD imagerel IncrementMULTI64Counter+62
DD imagerel $unwind$IncrementMULTI64Counter
pdata ENDS
; COMDAT pdata
pdata SEGMENT
$pdata$AddToMULTI32Counter DD imagerel AddToMULTI32Counter
DD imagerel AddToMULTI32Counter+78
DD imagerel $unwind$AddToMULTI32Counter
pdata ENDS
; COMDAT pdata
pdata SEGMENT
$pdata$AddToMULTI64Counter DD imagerel AddToMULTI64Counter
DD imagerel AddToMULTI64Counter+78
DD imagerel $unwind$AddToMULTI64Counter
pdata ENDS
; COMDAT pdata
pdata SEGMENT
$pdata$_COPY_MEMORY_UNIT DD imagerel _COPY_MEMORY_UNIT
DD imagerel _COPY_MEMORY_UNIT+100
DD imagerel $unwind$_COPY_MEMORY_UNIT
pdata ENDS
; COMDAT pdata
pdata SEGMENT
$pdata$_DIVIDE_CEILING_UNIT DD imagerel _DIVIDE_CEILING_UNIT
DD imagerel _DIVIDE_CEILING_UNIT+97
DD imagerel $unwind$_DIVIDE_CEILING_UNIT
pdata ENDS
; COMDAT pdata
pdata SEGMENT
$pdata$_DIVIDE_CEILING_SIZE DD imagerel _DIVIDE_CEILING_SIZE
DD imagerel _DIVIDE_CEILING_SIZE+97
DD imagerel $unwind$_DIVIDE_CEILING_SIZE
pdata ENDS
; COMDAT pdata
pdata SEGMENT
$pdata$_ADD_UNIT DD imagerel _ADD_UNIT
DD imagerel _ADD_UNIT+118
DD imagerel $unwind$_ADD_UNIT
pdata ENDS
; COMDAT pdata
pdata SEGMENT
$pdata$_ADDX_UNIT DD imagerel _ADDX_UNIT
DD imagerel _ADDX_UNIT+121
DD imagerel $unwind$_ADDX_UNIT
pdata ENDS
; COMDAT pdata
pdata SEGMENT
$pdata$_MULTIPLY_UNIT DD imagerel _MULTIPLY_UNIT
DD imagerel _MULTIPLY_UNIT+118
DD imagerel $unwind$_MULTIPLY_UNIT
pdata ENDS
; COMDAT pdata
pdata SEGMENT
$pdata$_MULTIPLYX_UNIT DD imagerel _MULTIPLYX_UNIT
DD imagerel _MULTIPLYX_UNIT+103
DD imagerel $unwind$_MULTIPLYX_UNIT
pdata ENDS
; COMDAT pdata
pdata SEGMENT
$pdata$StartsWith DD imagerel StartsWith
DD imagerel StartsWith+154
DD imagerel $unwind$StartsWith
pdata ENDS
; COMDAT pdata
pdata SEGMENT
$pdata$InitializeParserState DD imagerel InitializeParserState
DD imagerel InitializeParserState+561
DD imagerel $unwind$InitializeParserState
pdata ENDS
; COMDAT pdata
pdata SEGMENT
$pdata$FinalizeParserState DD imagerel FinalizeParserState
DD imagerel FinalizeParserState+113
DD imagerel $unwind$FinalizeParserState
pdata ENDS
; COMDAT pdata
pdata SEGMENT
$pdata$SkipSpace DD imagerel SkipSpace
DD imagerel SkipSpace+142
DD imagerel $unwind$SkipSpace
pdata ENDS
; COMDAT pdata
pdata SEGMENT
$pdata$ParseAsIntegerPartNumberSequence DD imagerel ParseAsIntegerPartNumberSequence
DD imagerel ParseAsIntegerPartNumberSequence+650
DD imagerel $unwind$ParseAsIntegerPartNumberSequence
pdata ENDS
; COMDAT pdata
pdata SEGMENT
$pdata$ParseAsFractionPartNumberSequence DD imagerel ParseAsFractionPartNumberSequence
DD imagerel ParseAsFractionPartNumberSequence+460
DD imagerel $unwind$ParseAsFractionPartNumberSequence
pdata ENDS
; COMDAT pdata
pdata SEGMENT
$pdata$ParseAsDecimalNumberString DD imagerel ParseAsDecimalNumberString
DD imagerel ParseAsDecimalNumberString+1133
DD imagerel $unwind$ParseAsDecimalNumberString
pdata ENDS
; COMDAT pdata
pdata SEGMENT
$pdata$ParseAsHexNumberString DD imagerel ParseAsHexNumberString
DD imagerel ParseAsHexNumberString+265
DD imagerel $unwind$ParseAsHexNumberString
pdata ENDS
; COMDAT pdata
pdata SEGMENT
$pdata$BuildLeading1WordFromDecimalString DD imagerel BuildLeading1WordFromDecimalString
DD imagerel BuildLeading1WordFromDecimalString+156
DD imagerel $unwind$BuildLeading1WordFromDecimalString
pdata ENDS
; COMDAT pdata
pdata SEGMENT
$pdata$Build1WordFromDecimalString DD imagerel Build1WordFromDecimalString
DD imagerel Build1WordFromDecimalString+969
DD imagerel $unwind$Build1WordFromDecimalString
pdata ENDS
; COMDAT pdata
pdata SEGMENT
$pdata$BuildBinaryFromDecimalString DD imagerel BuildBinaryFromDecimalString
DD imagerel BuildBinaryFromDecimalString+347
DD imagerel $unwind$BuildBinaryFromDecimalString
pdata ENDS
; COMDAT pdata
pdata SEGMENT
$pdata$MultiplyAndAdd1Word_using_ADC_MUL DD imagerel MultiplyAndAdd1Word_using_ADC_MUL
DD imagerel MultiplyAndAdd1Word_using_ADC_MUL+188
DD imagerel $unwind$MultiplyAndAdd1Word_using_ADC_MUL
pdata ENDS
; COMDAT pdata
pdata SEGMENT
$pdata$MultiplyAndAdd1Word_using_ADCX_MULX DD imagerel MultiplyAndAdd1Word_using_ADCX_MULX
DD imagerel MultiplyAndAdd1Word_using_ADCX_MULX+188
DD imagerel $unwind$MultiplyAndAdd1Word_using_ADCX_MULX
pdata ENDS
; COMDAT pdata
pdata SEGMENT
$pdata$MultiplyAndAdd_using_ADC_MUL DD imagerel MultiplyAndAdd_using_ADC_MUL
DD imagerel MultiplyAndAdd_using_ADC_MUL+4203
DD imagerel $unwind$MultiplyAndAdd_using_ADC_MUL
pdata ENDS
; COMDAT pdata
pdata SEGMENT
$pdata$MultiplyAndAdd_using_ADCX_MULX DD imagerel MultiplyAndAdd_using_ADCX_MULX
DD imagerel MultiplyAndAdd_using_ADCX_MULX+4203
DD imagerel $unwind$MultiplyAndAdd_using_ADCX_MULX
pdata ENDS
; COMDAT pdata
pdata SEGMENT
$pdata$ConvertCardinalNumber DD imagerel ConvertCardinalNumber
DD imagerel ConvertCardinalNumber+404
DD imagerel $unwind$ConvertCardinalNumber
pdata ENDS
; COMDAT pdata
pdata SEGMENT
$pdata$TryParseDN DD imagerel TryParseDN
DD imagerel TryParseDN+1565
DD imagerel $unwind$TryParseDN
pdata ENDS
; COMDAT pdata
pdata SEGMENT
$pdata$Parse1DigitFromHexChar DD imagerel Parse1DigitFromHexChar
DD imagerel Parse1DigitFromHexChar+247
DD imagerel $unwind$Parse1DigitFromHexChar
pdata ENDS
; COMDAT pdata
pdata SEGMENT
$pdata$BuildLeading1WordFromHexString DD imagerel BuildLeading1WordFromHexString
DD imagerel BuildLeading1WordFromHexString+222
DD imagerel $unwind$BuildLeading1WordFromHexString
pdata ENDS
; COMDAT pdata
pdata SEGMENT
$pdata$Build1WordFromHexString DD imagerel Build1WordFromHexString
DD imagerel Build1WordFromHexString+1121
DD imagerel $unwind$Build1WordFromHexString
pdata ENDS
; COMDAT pdata
pdata SEGMENT
$pdata$BuildBinaryFromHexString DD imagerel BuildBinaryFromHexString
DD imagerel BuildBinaryFromHexString+332
DD imagerel $unwind$BuildBinaryFromHexString
pdata ENDS
; COMDAT pdata
pdata SEGMENT
$pdata$TryParseX DD imagerel TryParseX
DD imagerel TryParseX+485
DD imagerel $unwind$TryParseX
pdata ENDS
; COMDAT rtc$TMZ
rtc$TMZ SEGMENT
_RTC_Shutdown.rtc$TMZ DQ FLAT:_RTC_Shutdown
rtc$TMZ ENDS
; COMDAT rtc$IMZ
rtc$IMZ SEGMENT
_RTC_InitBase.rtc$IMZ DQ FLAT:_RTC_InitBase
rtc$IMZ ENDS
; COMDAT ??_C@_13IMODFHAA@?$AA?9@
CONST SEGMENT
??_C@_13IMODFHAA@?$AA?9@ DB '-', 00H, 00H, 00H ; `string'
CONST ENDS
; COMDAT ??_C@_13KJIIAINM@?$AA?$CL@
CONST SEGMENT
??_C@_13KJIIAINM@?$AA?$CL@ DB '+', 00H, 00H, 00H ; `string'
CONST ENDS
; COMDAT ??_C@_01EKENIIDA@3@
CONST SEGMENT
??_C@_01EKENIIDA@3@ DB '3', 00H ; `string'
CONST ENDS
; COMDAT ??_C@_13JOFGPIOO@?$AA?4@
CONST SEGMENT
??_C@_13JOFGPIOO@?$AA?4@ DB '.', 00H, 00H, 00H ; `string'
CONST ENDS
; COMDAT ??_C@_13DEFPDAGF@?$AA?0@
CONST SEGMENT
??_C@_13DEFPDAGF@?$AA?0@ DB ',', 00H, 00H, 00H ; `string'
CONST ENDS
; COMDAT xdata
xdata SEGMENT
$unwind$TryParseX DD 025053801H
DD 011c2321H
DD 07015003dH
DD 05014H
xdata ENDS
; COMDAT CONST
CONST SEGMENT
TryParseX$rtcName$0 DB 069H
DB 06eH
DB 074H
DB 05fH
DB 070H
DB 061H
DB 072H
DB 074H
DB 05fH
DB 062H
DB 075H
DB 066H
DB 05fH
DB 063H
DB 06fH
DB 064H
DB 065H
DB 00H
ORG $+6
TryParseX$rtcName$1 DB 069H
DB 06eH
DB 074H
DB 05fH
DB 070H
DB 061H
DB 072H
DB 074H
DB 05fH
DB 062H
DB 075H
DB 066H
DB 05fH
DB 077H
DB 06fH
DB 072H
DB 064H
DB 073H
DB 00H
ORG $+5
TryParseX$rtcName$2 DB 06fH
DB 05fH
DB 06cH
DB 069H
DB 067H
DB 068H
DB 074H
DB 05fH
DB 063H
DB 068H
DB 065H
DB 063H
DB 06bH
DB 05fH
DB 063H
DB 06fH
DB 064H
DB 065H
DB 00H
ORG $+13
TryParseX$rtcVarDesc DD 0108H
DD 08H
DQ FLAT:TryParseX$rtcName$2
DD 088H
DD 08H
DQ FLAT:TryParseX$rtcName$1
DD 068H
DD 08H
DQ FLAT:TryParseX$rtcName$0
ORG $+144
TryParseX$rtcFrameData DD 03H
DD 00H
DQ FLAT:TryParseX$rtcVarDesc
CONST ENDS
; COMDAT xdata
xdata SEGMENT
$unwind$BuildBinaryFromHexString DD 025052f01H
DD 01132318H
DD 0700c0031H
DD 0500bH
xdata ENDS
; COMDAT xdata
xdata SEGMENT
$unwind$Build1WordFromHexString DD 025052a01H
DD 010e2313H
DD 070070021H
DD 05006H
xdata ENDS
; COMDAT xdata
xdata SEGMENT
$unwind$BuildLeading1WordFromHexString DD 025052f01H
DD 01132318H
DD 0700c0021H
DD 0500bH
xdata ENDS
; COMDAT xdata
xdata SEGMENT
$unwind$Parse1DigitFromHexChar DD 025052a01H
DD 010e2313H
DD 07007001fH
DD 05006H
xdata ENDS
; COMDAT xdata
xdata SEGMENT
$unwind$TryParseDN DD 035053801H
DD 011c3321H
DD 070150087H
DD 05014H
xdata ENDS
; COMDAT CONST
CONST SEGMENT
TryParseDN$rtcName$0 DB 069H
DB 06eH
DB 074H
DB 05fH
DB 070H
DB 061H
DB 072H
DB 074H
DB 05fH
DB 062H
DB 075H
DB 066H
DB 05fH
DB 063H
DB 06fH
DB 064H
DB 065H
DB 00H
ORG $+6
TryParseDN$rtcName$1 DB 069H
DB 06eH
DB 074H
DB 05fH
DB 070H
DB 061H
DB 072H
DB 074H
DB 05fH
DB 062H
DB 075H
DB 066H
DB 05fH
DB 077H
DB 06fH
DB 072H
DB 064H
DB 073H
DB 00H
ORG $+5
TryParseDN$rtcName$2 DB 066H
DB 072H
DB 061H
DB 063H
DB 05fH
DB 070H
DB 061H
DB 072H
DB 074H
DB 05fH
DB 062H
DB 075H
DB 066H
DB 05fH
DB 063H
DB 06fH
DB 064H
DB 065H
DB 00H
ORG $+5
TryParseDN$rtcName$3 DB 066H
DB 072H
DB 061H
DB 063H
DB 05fH
DB 070H
DB 061H
DB 072H
DB 074H
DB 05fH
DB 062H
DB 075H
DB 066H
DB 05fH
DB 077H
DB 06fH
DB 072H
DB 064H
DB 073H
DB 00H
TryParseDN$rtcName$4 DB 073H
DB 069H
DB 067H
DB 06eH
DB 00H
ORG $+7
TryParseDN$rtcName$5 DB 062H
DB 069H
DB 06eH
DB 05fH
DB 062H
DB 075H
DB 066H
DB 05fH
DB 063H
DB 06fH
DB 064H
DB 065H
DB 00H
ORG $+3
TryParseDN$rtcName$6 DB 062H
DB 069H
DB 06eH
DB 05fH
DB 062H
DB 075H
DB 066H
DB 05fH
DB 077H
DB 06fH
DB 072H
DB 064H
DB 073H
DB 00H
ORG $+2
TryParseDN$rtcName$7 DB 062H
DB 069H
DB 06eH
DB 05fH
DB 062H
DB 075H
DB 066H
DB 05fH
DB 063H
DB 06fH
DB 075H
DB 06eH
DB 074H
DB 00H
ORG $+2
TryParseDN$rtcName$8 DB 06eH
DB 06fH
DB 05fH
DB 06cH
DB 069H
DB 067H
DB 068H
DB 074H
DB 05fH
DB 063H
DB 068H
DB 065H
DB 063H
DB 06bH
DB 05fH
DB 063H
DB 06fH
DB 064H
DB 065H
DB 00H
ORG $+4
TryParseDN$rtcVarDesc DD 0298H
DD 08H
DQ FLAT:TryParseDN$rtcName$8
DD 0258H
DD 08H
DQ FLAT:TryParseDN$rtcName$7
DD 0218H
DD 08H
DQ FLAT:TryParseDN$rtcName$6
DD 01f8H
DD 08H
DQ FLAT:TryParseDN$rtcName$5
DD 0154H
DD 04H
DQ FLAT:TryParseDN$rtcName$4
DD 0118H
DD 08H
DQ FLAT:TryParseDN$rtcName$3
DD 0f8H
DD 08H
DQ FLAT:TryParseDN$rtcName$2
DD 0b8H
DD 08H
DQ FLAT:TryParseDN$rtcName$1
DD 098H
DD 08H
DQ FLAT:TryParseDN$rtcName$0
ORG $+432
TryParseDN$rtcFrameData DD 09H
DD 00H
DQ FLAT:TryParseDN$rtcVarDesc
CONST ENDS
; COMDAT xdata
xdata SEGMENT
$unwind$ConvertCardinalNumber DD 025053401H
DD 0118231dH
DD 070110035H
DD 05010H
xdata ENDS
; COMDAT CONST
CONST SEGMENT
ConvertCardinalNumber$rtcName$0 DB 077H
DB 06fH
DB 072H
DB 06bH
DB 05fH
DB 062H
DB 075H
DB 066H
DB 05fH
DB 063H
DB 06fH
DB 064H
DB 065H
DB 00H
ORG $+2
ConvertCardinalNumber$rtcName$1 DB 077H
DB 06fH
DB 072H
DB 06bH
DB 05fH
DB 062H
DB 075H
DB 066H
DB 05fH
DB 077H
DB 06fH
DB 072H
DB 064H
DB 073H
DB 00H
ORG $+1
ConvertCardinalNumber$rtcVarDesc DD 068H
DD 08H
DQ FLAT:ConvertCardinalNumber$rtcName$1
DD 048H
DD 08H
DQ FLAT:ConvertCardinalNumber$rtcName$0
ORG $+96
ConvertCardinalNumber$rtcFrameData DD 02H
DD 00H
DQ FLAT:ConvertCardinalNumber$rtcVarDesc
CONST ENDS
; COMDAT xdata
xdata SEGMENT
$unwind$MultiplyAndAdd_using_ADCX_MULX DD 025053401H
DD 0118231dH
DD 070110025H
DD 05010H
xdata ENDS
; COMDAT xdata
xdata SEGMENT
$unwind$MultiplyAndAdd_using_ADC_MUL DD 025053401H
DD 0118231dH
DD 070110025H
DD 05010H
xdata ENDS
; COMDAT xdata
xdata SEGMENT
$unwind$MultiplyAndAdd1Word_using_ADCX_MULX DD 025053401H
DD 0118231dH
DD 070110029H
DD 05010H
xdata ENDS
; COMDAT CONST
CONST SEGMENT
MultiplyAndAdd1Word_using_ADCX_MULX$rtcName$0 DB 074H
DB 05fH
DB 068H
DB 069H
DB 00H
ORG $+11
MultiplyAndAdd1Word_using_ADCX_MULX$rtcVarDesc DD 048H
DD 08H
DQ FLAT:MultiplyAndAdd1Word_using_ADCX_MULX$rtcName$0
ORG $+48
MultiplyAndAdd1Word_using_ADCX_MULX$rtcFrameData DD 01H
DD 00H
DQ FLAT:MultiplyAndAdd1Word_using_ADCX_MULX$rtcVarDesc
CONST ENDS
; COMDAT xdata
xdata SEGMENT
$unwind$MultiplyAndAdd1Word_using_ADC_MUL DD 025053401H
DD 0118231dH
DD 070110029H
DD 05010H
xdata ENDS
; COMDAT CONST
CONST SEGMENT
MultiplyAndAdd1Word_using_ADC_MUL$rtcName$0 DB 074H
DB 05fH
DB 068H
DB 069H
DB 00H
ORG $+11
MultiplyAndAdd1Word_using_ADC_MUL$rtcVarDesc DD 048H
DD 08H
DQ FLAT:MultiplyAndAdd1Word_using_ADC_MUL$rtcName$0
ORG $+48
MultiplyAndAdd1Word_using_ADC_MUL$rtcFrameData DD 01H
DD 00H
DQ FLAT:MultiplyAndAdd1Word_using_ADC_MUL$rtcVarDesc
CONST ENDS
; COMDAT xdata
xdata SEGMENT
$unwind$BuildBinaryFromDecimalString DD 025053401H
DD 0118231dH
DD 070110031H
DD 05010H
xdata ENDS
; COMDAT xdata
xdata SEGMENT
$unwind$Build1WordFromDecimalString DD 025052a01H
DD 010e2313H
DD 070070021H
DD 05006H
xdata ENDS
; COMDAT xdata
xdata SEGMENT
$unwind$BuildLeading1WordFromDecimalString DD 025052f01H
DD 01132318H
DD 0700c0021H
DD 0500bH
xdata ENDS
; COMDAT xdata
xdata SEGMENT
$unwind$ParseAsHexNumberString DD 035054919H
DD 011c3321H
DD 07015002fH
DD 05014H
DD imagerel __GSHandlerCheck
DD 0168H
xdata ENDS
; COMDAT CONST
CONST SEGMENT
ParseAsHexNumberString$rtcName$0 DB 073H
DB 074H
DB 061H
DB 074H
DB 065H
DB 00H
ORG $+10
ParseAsHexNumberString$rtcVarDesc DD 040H
DD 060H
DQ FLAT:ParseAsHexNumberString$rtcName$0
ORG $+48
ParseAsHexNumberString$rtcFrameData DD 01H
DD 00H
DQ FLAT:ParseAsHexNumberString$rtcVarDesc
CONST ENDS
; COMDAT xdata
xdata SEGMENT
$unwind$ParseAsDecimalNumberString DD 035054919H
DD 011c3321H
DD 07015002fH
DD 05014H
DD imagerel __GSHandlerCheck
DD 0168H
xdata ENDS
; COMDAT CONST
CONST SEGMENT
ParseAsDecimalNumberString$rtcName$0 DB 073H
DB 074H
DB 061H
DB 074H
DB 065H
DB 00H
ORG $+10
ParseAsDecimalNumberString$rtcVarDesc DD 040H
DD 060H
DQ FLAT:ParseAsDecimalNumberString$rtcName$0
ORG $+48
ParseAsDecimalNumberString$rtcFrameData DD 01H
DD 00H
DQ FLAT:ParseAsDecimalNumberString$rtcVarDesc
CONST ENDS
; COMDAT xdata
xdata SEGMENT
$unwind$ParseAsFractionPartNumberSequence DD 025052a01H
DD 010e2313H
DD 07007001dH
DD 05006H
xdata ENDS
; COMDAT xdata
xdata SEGMENT
$unwind$ParseAsIntegerPartNumberSequence DD 025052a01H
DD 010e2313H
DD 07007001dH
DD 05006H
xdata ENDS
; COMDAT xdata
xdata SEGMENT
$unwind$SkipSpace DD 025052a01H
DD 010e2313H
DD 07007001fH
DD 05006H
xdata ENDS
; COMDAT xdata
xdata SEGMENT
$unwind$FinalizeParserState DD 025052a01H
DD 010e2313H
DD 07007001dH
DD 05006H
xdata ENDS
; COMDAT xdata
xdata SEGMENT
$unwind$InitializeParserState DD 025053901H
DD 011d2322H
DD 07016001dH
DD 05015H
xdata ENDS
; COMDAT xdata
xdata SEGMENT
$unwind$StartsWith DD 025052f01H
DD 01132318H
DD 0700c001dH
DD 0500bH
xdata ENDS
; COMDAT xdata
xdata SEGMENT
$unwind$_MULTIPLYX_UNIT DD 025053401H
DD 0118231dH
DD 07011001dH
DD 05010H
xdata ENDS
; COMDAT xdata
xdata SEGMENT
$unwind$_MULTIPLY_UNIT DD 025053401H
DD 0118231dH
DD 07011001fH
DD 05010H
xdata ENDS
; COMDAT xdata
xdata SEGMENT
$unwind$_ADDX_UNIT DD 025053801H
DD 011c2321H
DD 07015001dH
DD 05014H
xdata ENDS
; COMDAT xdata
xdata SEGMENT
$unwind$_ADD_UNIT DD 025053801H
DD 011c2321H
DD 07015001dH
DD 05014H
xdata ENDS
; COMDAT xdata
xdata SEGMENT
$unwind$_DIVIDE_CEILING_SIZE DD 025052f01H
DD 01132318H
DD 0700c001dH
DD 0500bH
xdata ENDS
; COMDAT xdata
xdata SEGMENT
$unwind$_DIVIDE_CEILING_UNIT DD 025052f01H
DD 01132318H
DD 0700c001dH
DD 0500bH
xdata ENDS
; COMDAT xdata
xdata SEGMENT
$unwind$_COPY_MEMORY_UNIT DD 025063501H
DD 0119231eH
DD 07012001cH
DD 050106011H
xdata ENDS
; COMDAT xdata
xdata SEGMENT
$unwind$AddToMULTI64Counter DD 025052801H
DD 010d2312H
DD 07006001dH
DD 05005H
xdata ENDS
; COMDAT xdata
xdata SEGMENT
$unwind$AddToMULTI32Counter DD 025052801H
DD 010d2312H
DD 07006001dH
DD 05005H
xdata ENDS
; COMDAT xdata
xdata SEGMENT
$unwind$IncrementMULTI64Counter DD 025051e01H
DD 010a230fH
DD 07003001dH
DD 05002H
xdata ENDS
; COMDAT xdata
xdata SEGMENT
$unwind$IncrementMULTI32Counter DD 025051e01H
DD 010a230fH
DD 07003001dH
DD 05002H
xdata ENDS
; COMDAT xdata
xdata SEGMENT
$unwind$PMC_TryParse DD 025053801H
DD 011c2321H
DD 070150029H
DD 05014H
xdata ENDS
; COMDAT CONST
CONST SEGMENT
PMC_TryParse$rtcName$0 DB 06eH
DB 06fH
DB 00H
ORG $+13
PMC_TryParse$rtcVarDesc DD 048H
DD 08H
DQ FLAT:PMC_TryParse$rtcName$0
ORG $+48
PMC_TryParse$rtcFrameData DD 01H
DD 00H
DQ FLAT:PMC_TryParse$rtcVarDesc
CONST ENDS
; COMDAT xdata
xdata SEGMENT
$unwind$Initialize_Parse DD 025052a01H
DD 010e2313H
DD 07007001dH
DD 05006H
xdata ENDS
; Function compile flags: /Odt
; COMDAT __JustMyCode_Default
_TEXT SEGMENT
__JustMyCode_Default PROC ; COMDAT
ret 0
__JustMyCode_Default ENDP
_TEXT ENDS
; Function compile flags: /Odtp /RTCsu /ZI
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_parse.c
; COMDAT TryParseX
_TEXT SEGMENT
result$ = 4
source_len$ = 40
int_part_buf_code$ = 72
int_part_buf_words$ = 104
int_part_buf$ = 136
result_parsing$ = 164
o_bit_count$ = 200
o_light_check_code$ = 232
source$ = 480
number_styles$ = 488
format_option$ = 496
o$ = 504
TryParseX PROC ; COMDAT
; 968 : {
mov QWORD PTR [rsp+32], r9
mov QWORD PTR [rsp+24], r8
mov DWORD PTR [rsp+16], edx
mov QWORD PTR [rsp+8], rcx
push rbp
push rdi
sub rsp, 488 ; 000001e8H
lea rbp, QWORD PTR [rsp+32]
mov rdi, rsp
mov ecx, 122 ; 0000007aH
mov eax, -858993460 ; ccccccccH
rep stosd
mov rcx, QWORD PTR [rsp+520]
lea rcx, OFFSET FLAT:__C5BBD3C1_pmc_parse@c
call __CheckForDebuggerJustMyCode
; 969 : PMC_STATUS_CODE result;
; 970 : __UNIT_TYPE source_len = lstrlenW(source);
mov rcx, QWORD PTR source$[rbp]
call QWORD PTR __imp_lstrlenW
cdqe
mov QWORD PTR source_len$[rbp], rax
; 971 : __UNIT_TYPE int_part_buf_code;
; 972 : __UNIT_TYPE int_part_buf_words;
; 973 : wchar_t* int_part_buf = (wchar_t*)AllocateBlock((source_len + 1) * sizeof(wchar_t) * 8, &int_part_buf_words, &int_part_buf_code);
mov rax, QWORD PTR source_len$[rbp]
lea rax, QWORD PTR [rax+rax+2]
shl rax, 3
lea r8, QWORD PTR int_part_buf_code$[rbp]
lea rdx, QWORD PTR int_part_buf_words$[rbp]
mov rcx, rax
call AllocateBlock
mov QWORD PTR int_part_buf$[rbp], rax
; 974 : if (int_part_buf == NULL)
cmp QWORD PTR int_part_buf$[rbp], 0
jne SHORT $LN2@TryParseX
; 975 : return (PMC_STATUS_NOT_ENOUGH_MEMORY);
mov eax, -5
jmp $LN1@TryParseX
$LN2@TryParseX:
; 976 : int result_parsing = ParseAsHexNumberString(source, number_styles, format_option, int_part_buf);
mov r9, QWORD PTR int_part_buf$[rbp]
mov r8, QWORD PTR format_option$[rbp]
mov edx, DWORD PTR number_styles$[rbp]
mov rcx, QWORD PTR source$[rbp]
call ParseAsHexNumberString
mov DWORD PTR result_parsing$[rbp], eax
; 977 : if ((result = CheckBlockLight((__UNIT_TYPE*)int_part_buf, int_part_buf_code)) != PMC_STATUS_OK)
mov rdx, QWORD PTR int_part_buf_code$[rbp]
mov rcx, QWORD PTR int_part_buf$[rbp]
call CheckBlockLight
mov DWORD PTR result$[rbp], eax
cmp DWORD PTR result$[rbp], 0
je SHORT $LN3@TryParseX
; 978 : return (result);
mov eax, DWORD PTR result$[rbp]
jmp $LN1@TryParseX
$LN3@TryParseX:
; 979 : if (!result_parsing || int_part_buf[0] == L'\0')
cmp DWORD PTR result_parsing$[rbp], 0
je SHORT $LN5@TryParseX
mov eax, 2
imul rax, rax, 0
mov rcx, QWORD PTR int_part_buf$[rbp]
movzx eax, WORD PTR [rcx+rax]
test eax, eax
jne SHORT $LN4@TryParseX
$LN5@TryParseX:
; 980 : {
; 981 : DeallocateBlock((__UNIT_TYPE*)int_part_buf, int_part_buf_words);
mov rdx, QWORD PTR int_part_buf_words$[rbp]
mov rcx, QWORD PTR int_part_buf$[rbp]
call DeallocateBlock
; 982 : return (PMC_STATUS_PARSING_ERROR);
mov eax, 1
jmp $LN1@TryParseX
$LN4@TryParseX:
; 983 : }
; 984 : __UNIT_TYPE o_bit_count = lstrlenW(int_part_buf) * 4;
mov rcx, QWORD PTR int_part_buf$[rbp]
call QWORD PTR __imp_lstrlenW
shl eax, 2
cdqe
mov QWORD PTR o_bit_count$[rbp], rax
; 985 : __UNIT_TYPE o_light_check_code;
; 986 : if ((result = AllocateNumber(o, o_bit_count, &o_light_check_code)) != PMC_STATUS_OK)
lea r8, QWORD PTR o_light_check_code$[rbp]
mov rdx, QWORD PTR o_bit_count$[rbp]
mov rcx, QWORD PTR o$[rbp]
call AllocateNumber
mov DWORD PTR result$[rbp], eax
cmp DWORD PTR result$[rbp], 0
je SHORT $LN6@TryParseX
; 987 : {
; 988 : DeallocateBlock((__UNIT_TYPE*)int_part_buf, int_part_buf_words);
mov rdx, QWORD PTR int_part_buf_words$[rbp]
mov rcx, QWORD PTR int_part_buf$[rbp]
call DeallocateBlock
; 989 : return (result);
mov eax, DWORD PTR result$[rbp]
jmp SHORT $LN1@TryParseX
$LN6@TryParseX:
; 990 : }
; 991 : BuildBinaryFromHexString(int_part_buf, (*o)->BLOCK);
mov rax, QWORD PTR o$[rbp]
mov rax, QWORD PTR [rax]
mov rdx, QWORD PTR [rax+56]
mov rcx, QWORD PTR int_part_buf$[rbp]
call BuildBinaryFromHexString
; 992 : if ((result = CheckBlockLight((*o)->BLOCK, o_light_check_code)) != PMC_STATUS_OK)
mov rax, QWORD PTR o$[rbp]
mov rax, QWORD PTR [rax]
mov rdx, QWORD PTR o_light_check_code$[rbp]
mov rcx, QWORD PTR [rax+56]
call CheckBlockLight
mov DWORD PTR result$[rbp], eax
cmp DWORD PTR result$[rbp], 0
je SHORT $LN7@TryParseX
; 993 : return (result);
mov eax, DWORD PTR result$[rbp]
jmp SHORT $LN1@TryParseX
$LN7@TryParseX:
; 994 : DeallocateBlock((__UNIT_TYPE*)int_part_buf, int_part_buf_words);
mov rdx, QWORD PTR int_part_buf_words$[rbp]
mov rcx, QWORD PTR int_part_buf$[rbp]
call DeallocateBlock
; 995 : CommitNumber(*o);
mov rax, QWORD PTR o$[rbp]
mov rcx, QWORD PTR [rax]
call CommitNumber
; 996 : return (PMC_STATUS_OK);
xor eax, eax
$LN1@TryParseX:
; 997 : }
mov rdi, rax
lea rcx, QWORD PTR [rbp-32]
lea rdx, OFFSET FLAT:TryParseX$rtcFrameData
call _RTC_CheckStackVars
mov rax, rdi
lea rsp, QWORD PTR [rbp+456]
pop rdi
pop rbp
ret 0
TryParseX ENDP
_TEXT ENDS
; Function compile flags: /Odtp /RTCsu /ZI
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_parse.c
; COMDAT BuildBinaryFromHexString
_TEXT SEGMENT
word_digit_count$ = 4
source_count$ = 40
in_ptr$ = 72
out_ptr$ = 104
r$ = 132
tv74 = 344
source$ = 384
out_buf$ = 392
BuildBinaryFromHexString PROC ; COMDAT
; 947 : {
mov QWORD PTR [rsp+16], rdx
mov QWORD PTR [rsp+8], rcx
push rbp
push rdi
sub rsp, 392 ; 00000188H
lea rbp, QWORD PTR [rsp+32]
mov rdi, rsp
mov ecx, 98 ; 00000062H
mov eax, -858993460 ; ccccccccH
rep stosd
mov rcx, QWORD PTR [rsp+424]
lea rcx, OFFSET FLAT:__C5BBD3C1_pmc_parse@c
call __CheckForDebuggerJustMyCode
; 948 : int word_digit_count = __UNIT_TYPE_BIT_COUNT / 4;
mov DWORD PTR word_digit_count$[rbp], 16
; 949 : __UNIT_TYPE source_count = lstrlenW(source);
mov rcx, QWORD PTR source$[rbp]
call QWORD PTR __imp_lstrlenW
cdqe
mov QWORD PTR source_count$[rbp], rax
; 950 : wchar_t* in_ptr = source;
mov rax, QWORD PTR source$[rbp]
mov QWORD PTR in_ptr$[rbp], rax
; 951 : __UNIT_TYPE* out_ptr = out_buf + _DIVIDE_CEILING_UNIT(source_count, word_digit_count) - 1;
movsxd rax, DWORD PTR word_digit_count$[rbp]
mov rdx, rax
mov rcx, QWORD PTR source_count$[rbp]
call _DIVIDE_CEILING_UNIT
mov rcx, QWORD PTR out_buf$[rbp]
lea rax, QWORD PTR [rcx+rax*8-8]
mov QWORD PTR out_ptr$[rbp], rax
; 952 : int r = source_count % word_digit_count;
movsxd rax, DWORD PTR word_digit_count$[rbp]
mov QWORD PTR tv74[rbp], rax
xor edx, edx
mov rax, QWORD PTR source_count$[rbp]
mov rcx, QWORD PTR tv74[rbp]
div rcx
mov rax, rdx
mov DWORD PTR r$[rbp], eax
; 953 : if (r > 0)
cmp DWORD PTR r$[rbp], 0
jle SHORT $LN4@BuildBinar
; 954 : {
; 955 : *out_ptr-- = BuildLeading1WordFromHexString(in_ptr, r);
movsxd rax, DWORD PTR r$[rbp]
mov rdx, rax
mov rcx, QWORD PTR in_ptr$[rbp]
call BuildLeading1WordFromHexString
mov rcx, QWORD PTR out_ptr$[rbp]
mov QWORD PTR [rcx], rax
mov rax, QWORD PTR out_ptr$[rbp]
sub rax, 8
mov QWORD PTR out_ptr$[rbp], rax
; 956 : in_ptr += r;
movsxd rax, DWORD PTR r$[rbp]
mov rcx, QWORD PTR in_ptr$[rbp]
lea rax, QWORD PTR [rcx+rax*2]
mov QWORD PTR in_ptr$[rbp], rax
; 957 : source_count -= r;
movsxd rax, DWORD PTR r$[rbp]
mov rcx, QWORD PTR source_count$[rbp]
sub rcx, rax
mov rax, rcx
mov QWORD PTR source_count$[rbp], rax
$LN4@BuildBinar:
$LN2@BuildBinar:
; 958 : }
; 959 : while (source_count > 0)
cmp QWORD PTR source_count$[rbp], 0
jbe SHORT $LN3@BuildBinar
; 960 : {
; 961 : *out_ptr-- = Build1WordFromHexString(in_ptr);
mov rcx, QWORD PTR in_ptr$[rbp]
call Build1WordFromHexString
mov rcx, QWORD PTR out_ptr$[rbp]
mov QWORD PTR [rcx], rax
mov rax, QWORD PTR out_ptr$[rbp]
sub rax, 8
mov QWORD PTR out_ptr$[rbp], rax
; 962 : in_ptr += word_digit_count;
movsxd rax, DWORD PTR word_digit_count$[rbp]
mov rcx, QWORD PTR in_ptr$[rbp]
lea rax, QWORD PTR [rcx+rax*2]
mov QWORD PTR in_ptr$[rbp], rax
; 963 : source_count -= word_digit_count;
movsxd rax, DWORD PTR word_digit_count$[rbp]
mov rcx, QWORD PTR source_count$[rbp]
sub rcx, rax
mov rax, rcx
mov QWORD PTR source_count$[rbp], rax
; 964 : }
jmp SHORT $LN2@BuildBinar
$LN3@BuildBinar:
; 965 : }
lea rsp, QWORD PTR [rbp+360]
pop rdi
pop rbp
ret 0
BuildBinaryFromHexString ENDP
_TEXT ENDS
; Function compile flags: /Odtp /RTCsu /ZI
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_parse.c
; COMDAT Build1WordFromHexString
_TEXT SEGMENT
x$ = 8
tv206 = 212
tv198 = 212
tv191 = 212
tv183 = 212
tv176 = 212
tv169 = 212
tv162 = 212
tv154 = 212
tv147 = 212
tv140 = 212
tv133 = 212
tv94 = 212
tv87 = 212
tv80 = 212
tv73 = 212
tv66 = 212
in_ptr$ = 256
Build1WordFromHexString PROC ; COMDAT
; 914 : {
mov QWORD PTR [rsp+8], rcx
push rbp
push rdi
sub rsp, 264 ; 00000108H
lea rbp, QWORD PTR [rsp+32]
mov rdi, rsp
mov ecx, 66 ; 00000042H
mov eax, -858993460 ; ccccccccH
rep stosd
mov rcx, QWORD PTR [rsp+296]
lea rcx, OFFSET FLAT:__C5BBD3C1_pmc_parse@c
call __CheckForDebuggerJustMyCode
; 915 : __UNIT_TYPE x = Parse1DigitFromHexChar(*in_ptr++);
mov rax, QWORD PTR in_ptr$[rbp]
movzx eax, WORD PTR [rax]
mov WORD PTR tv66[rbp], ax
mov rax, QWORD PTR in_ptr$[rbp]
add rax, 2
mov QWORD PTR in_ptr$[rbp], rax
movzx ecx, WORD PTR tv66[rbp]
call Parse1DigitFromHexChar
mov eax, eax
mov QWORD PTR x$[rbp], rax
; 916 : if (sizeof(__UNIT_TYPE) >= sizeof(_UINT64_T))
xor eax, eax
cmp eax, 1
je $LN2@Build1Word
; 917 : {
; 918 : x = x * 16 + Parse1DigitFromHexChar(*in_ptr++);
mov rax, QWORD PTR in_ptr$[rbp]
movzx eax, WORD PTR [rax]
mov WORD PTR tv73[rbp], ax
mov rax, QWORD PTR in_ptr$[rbp]
add rax, 2
mov QWORD PTR in_ptr$[rbp], rax
movzx ecx, WORD PTR tv73[rbp]
call Parse1DigitFromHexChar
mov eax, eax
imul rcx, QWORD PTR x$[rbp], 16
add rcx, rax
mov rax, rcx
mov QWORD PTR x$[rbp], rax
; 919 : x = x * 16 + Parse1DigitFromHexChar(*in_ptr++);
mov rax, QWORD PTR in_ptr$[rbp]
movzx eax, WORD PTR [rax]
mov WORD PTR tv80[rbp], ax
mov rax, QWORD PTR in_ptr$[rbp]
add rax, 2
mov QWORD PTR in_ptr$[rbp], rax
movzx ecx, WORD PTR tv80[rbp]
call Parse1DigitFromHexChar
mov eax, eax
imul rcx, QWORD PTR x$[rbp], 16
add rcx, rax
mov rax, rcx
mov QWORD PTR x$[rbp], rax
; 920 : x = x * 16 + Parse1DigitFromHexChar(*in_ptr++);
mov rax, QWORD PTR in_ptr$[rbp]
movzx eax, WORD PTR [rax]
mov WORD PTR tv87[rbp], ax
mov rax, QWORD PTR in_ptr$[rbp]
add rax, 2
mov QWORD PTR in_ptr$[rbp], rax
movzx ecx, WORD PTR tv87[rbp]
call Parse1DigitFromHexChar
mov eax, eax
imul rcx, QWORD PTR x$[rbp], 16
add rcx, rax
mov rax, rcx
mov QWORD PTR x$[rbp], rax
; 921 : x = x * 16 + Parse1DigitFromHexChar(*in_ptr++);
mov rax, QWORD PTR in_ptr$[rbp]
movzx eax, WORD PTR [rax]
mov WORD PTR tv94[rbp], ax
mov rax, QWORD PTR in_ptr$[rbp]
add rax, 2
mov QWORD PTR in_ptr$[rbp], rax
movzx ecx, WORD PTR tv94[rbp]
call Parse1DigitFromHexChar
mov eax, eax
imul rcx, QWORD PTR x$[rbp], 16
add rcx, rax
mov rax, rcx
mov QWORD PTR x$[rbp], rax
; 922 : x = x * 16 + Parse1DigitFromHexChar(*in_ptr++);
mov rax, QWORD PTR in_ptr$[rbp]
movzx eax, WORD PTR [rax]
mov WORD PTR tv133[rbp], ax
mov rax, QWORD PTR in_ptr$[rbp]
add rax, 2
mov QWORD PTR in_ptr$[rbp], rax
movzx ecx, WORD PTR tv133[rbp]
call Parse1DigitFromHexChar
mov eax, eax
imul rcx, QWORD PTR x$[rbp], 16
add rcx, rax
mov rax, rcx
mov QWORD PTR x$[rbp], rax
; 923 : x = x * 16 + Parse1DigitFromHexChar(*in_ptr++);
mov rax, QWORD PTR in_ptr$[rbp]
movzx eax, WORD PTR [rax]
mov WORD PTR tv140[rbp], ax
mov rax, QWORD PTR in_ptr$[rbp]
add rax, 2
mov QWORD PTR in_ptr$[rbp], rax
movzx ecx, WORD PTR tv140[rbp]
call Parse1DigitFromHexChar
mov eax, eax
imul rcx, QWORD PTR x$[rbp], 16
add rcx, rax
mov rax, rcx
mov QWORD PTR x$[rbp], rax
; 924 : x = x * 16 + Parse1DigitFromHexChar(*in_ptr++);
mov rax, QWORD PTR in_ptr$[rbp]
movzx eax, WORD PTR [rax]
mov WORD PTR tv147[rbp], ax
mov rax, QWORD PTR in_ptr$[rbp]
add rax, 2
mov QWORD PTR in_ptr$[rbp], rax
movzx ecx, WORD PTR tv147[rbp]
call Parse1DigitFromHexChar
mov eax, eax
imul rcx, QWORD PTR x$[rbp], 16
add rcx, rax
mov rax, rcx
mov QWORD PTR x$[rbp], rax
; 925 : x = x * 16 + Parse1DigitFromHexChar(*in_ptr++);
mov rax, QWORD PTR in_ptr$[rbp]
movzx eax, WORD PTR [rax]
mov WORD PTR tv154[rbp], ax
mov rax, QWORD PTR in_ptr$[rbp]
add rax, 2
mov QWORD PTR in_ptr$[rbp], rax
movzx ecx, WORD PTR tv154[rbp]
call Parse1DigitFromHexChar
mov eax, eax
imul rcx, QWORD PTR x$[rbp], 16
add rcx, rax
mov rax, rcx
mov QWORD PTR x$[rbp], rax
$LN2@Build1Word:
; 926 : }
; 927 : if (sizeof(__UNIT_TYPE) >= sizeof(_UINT32_T))
xor eax, eax
cmp eax, 1
je $LN3@Build1Word
; 928 : {
; 929 : x = x * 16 + Parse1DigitFromHexChar(*in_ptr++);
mov rax, QWORD PTR in_ptr$[rbp]
movzx eax, WORD PTR [rax]
mov WORD PTR tv162[rbp], ax
mov rax, QWORD PTR in_ptr$[rbp]
add rax, 2
mov QWORD PTR in_ptr$[rbp], rax
movzx ecx, WORD PTR tv162[rbp]
call Parse1DigitFromHexChar
mov eax, eax
imul rcx, QWORD PTR x$[rbp], 16
add rcx, rax
mov rax, rcx
mov QWORD PTR x$[rbp], rax
; 930 : x = x * 16 + Parse1DigitFromHexChar(*in_ptr++);
mov rax, QWORD PTR in_ptr$[rbp]
movzx eax, WORD PTR [rax]
mov WORD PTR tv169[rbp], ax
mov rax, QWORD PTR in_ptr$[rbp]
add rax, 2
mov QWORD PTR in_ptr$[rbp], rax
movzx ecx, WORD PTR tv169[rbp]
call Parse1DigitFromHexChar
mov eax, eax
imul rcx, QWORD PTR x$[rbp], 16
add rcx, rax
mov rax, rcx
mov QWORD PTR x$[rbp], rax
; 931 : x = x * 16 + Parse1DigitFromHexChar(*in_ptr++);
mov rax, QWORD PTR in_ptr$[rbp]
movzx eax, WORD PTR [rax]
mov WORD PTR tv176[rbp], ax
mov rax, QWORD PTR in_ptr$[rbp]
add rax, 2
mov QWORD PTR in_ptr$[rbp], rax
movzx ecx, WORD PTR tv176[rbp]
call Parse1DigitFromHexChar
mov eax, eax
imul rcx, QWORD PTR x$[rbp], 16
add rcx, rax
mov rax, rcx
mov QWORD PTR x$[rbp], rax
; 932 : x = x * 16 + Parse1DigitFromHexChar(*in_ptr++);
mov rax, QWORD PTR in_ptr$[rbp]
movzx eax, WORD PTR [rax]
mov WORD PTR tv183[rbp], ax
mov rax, QWORD PTR in_ptr$[rbp]
add rax, 2
mov QWORD PTR in_ptr$[rbp], rax
movzx ecx, WORD PTR tv183[rbp]
call Parse1DigitFromHexChar
mov eax, eax
imul rcx, QWORD PTR x$[rbp], 16
add rcx, rax
mov rax, rcx
mov QWORD PTR x$[rbp], rax
$LN3@Build1Word:
; 933 : }
; 934 : if (sizeof(__UNIT_TYPE) >= sizeof(_UINT16_T))
xor eax, eax
cmp eax, 1
je $LN4@Build1Word
; 935 : {
; 936 : x = x * 16 + Parse1DigitFromHexChar(*in_ptr++);
mov rax, QWORD PTR in_ptr$[rbp]
movzx eax, WORD PTR [rax]
mov WORD PTR tv191[rbp], ax
mov rax, QWORD PTR in_ptr$[rbp]
add rax, 2
mov QWORD PTR in_ptr$[rbp], rax
movzx ecx, WORD PTR tv191[rbp]
call Parse1DigitFromHexChar
mov eax, eax
imul rcx, QWORD PTR x$[rbp], 16
add rcx, rax
mov rax, rcx
mov QWORD PTR x$[rbp], rax
; 937 : x = x * 16 + Parse1DigitFromHexChar(*in_ptr++);
mov rax, QWORD PTR in_ptr$[rbp]
movzx eax, WORD PTR [rax]
mov WORD PTR tv198[rbp], ax
mov rax, QWORD PTR in_ptr$[rbp]
add rax, 2
mov QWORD PTR in_ptr$[rbp], rax
movzx ecx, WORD PTR tv198[rbp]
call Parse1DigitFromHexChar
mov eax, eax
imul rcx, QWORD PTR x$[rbp], 16
add rcx, rax
mov rax, rcx
mov QWORD PTR x$[rbp], rax
$LN4@Build1Word:
; 938 : }
; 939 : if (sizeof(__UNIT_TYPE) >= sizeof(_BYTE_T))
xor eax, eax
cmp eax, 1
je SHORT $LN5@Build1Word
; 940 : {
; 941 : x = x * 16 + Parse1DigitFromHexChar(*in_ptr++);
mov rax, QWORD PTR in_ptr$[rbp]
movzx eax, WORD PTR [rax]
mov WORD PTR tv206[rbp], ax
mov rax, QWORD PTR in_ptr$[rbp]
add rax, 2
mov QWORD PTR in_ptr$[rbp], rax
movzx ecx, WORD PTR tv206[rbp]
call Parse1DigitFromHexChar
mov eax, eax
imul rcx, QWORD PTR x$[rbp], 16
add rcx, rax
mov rax, rcx
mov QWORD PTR x$[rbp], rax
$LN5@Build1Word:
; 942 : }
; 943 : return (x);
mov rax, QWORD PTR x$[rbp]
; 944 : }
lea rsp, QWORD PTR [rbp+232]
pop rdi
pop rbp
ret 0
Build1WordFromHexString ENDP
_TEXT ENDS
; Function compile flags: /Odtp /RTCsu /ZI
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_parse.c
; COMDAT BuildLeading1WordFromHexString
_TEXT SEGMENT
x$ = 8
tv70 = 216
in_ptr$ = 256
count$ = 264
BuildLeading1WordFromHexString PROC ; COMDAT
; 900 : {
mov QWORD PTR [rsp+16], rdx
mov QWORD PTR [rsp+8], rcx
push rbp
push rdi
sub rsp, 264 ; 00000108H
lea rbp, QWORD PTR [rsp+32]
mov rdi, rsp
mov ecx, 66 ; 00000042H
mov eax, -858993460 ; ccccccccH
rep stosd
mov rcx, QWORD PTR [rsp+296]
lea rcx, OFFSET FLAT:__C5BBD3C1_pmc_parse@c
call __CheckForDebuggerJustMyCode
; 901 : __UNIT_TYPE x = Parse1DigitFromHexChar(*in_ptr);
mov rax, QWORD PTR in_ptr$[rbp]
movzx ecx, WORD PTR [rax]
call Parse1DigitFromHexChar
mov eax, eax
mov QWORD PTR x$[rbp], rax
; 902 : ++in_ptr;
mov rax, QWORD PTR in_ptr$[rbp]
add rax, 2
mov QWORD PTR in_ptr$[rbp], rax
; 903 : --count;
mov rax, QWORD PTR count$[rbp]
dec rax
mov QWORD PTR count$[rbp], rax
$LN2@BuildLeadi:
; 904 : while (count > 0)
cmp QWORD PTR count$[rbp], 0
jbe SHORT $LN3@BuildLeadi
; 905 : {
; 906 : x = x * 16 + Parse1DigitFromHexChar(*in_ptr);
imul rax, QWORD PTR x$[rbp], 16
mov QWORD PTR tv70[rbp], rax
mov rcx, QWORD PTR in_ptr$[rbp]
movzx ecx, WORD PTR [rcx]
call Parse1DigitFromHexChar
mov eax, eax
mov rcx, QWORD PTR tv70[rbp]
add rcx, rax
mov rax, rcx
mov QWORD PTR x$[rbp], rax
; 907 : ++in_ptr;
mov rax, QWORD PTR in_ptr$[rbp]
add rax, 2
mov QWORD PTR in_ptr$[rbp], rax
; 908 : --count;
mov rax, QWORD PTR count$[rbp]
dec rax
mov QWORD PTR count$[rbp], rax
; 909 : }
jmp SHORT $LN2@BuildLeadi
$LN3@BuildLeadi:
; 910 : return (x);
mov rax, QWORD PTR x$[rbp]
; 911 : }
lea rsp, QWORD PTR [rbp+232]
pop rdi
pop rbp
ret 0
BuildLeading1WordFromHexString ENDP
_TEXT ENDS
; Function compile flags: /Odtp /RTCsu /ZI
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_parse.c
; COMDAT Parse1DigitFromHexChar
_TEXT SEGMENT
tv65 = 192
c$ = 240
Parse1DigitFromHexChar PROC ; COMDAT
; 866 : {
mov WORD PTR [rsp+8], cx
push rbp
push rdi
sub rsp, 248 ; 000000f8H
lea rbp, QWORD PTR [rsp+32]
mov rdi, rsp
mov ecx, 62 ; 0000003eH
mov eax, -858993460 ; ccccccccH
rep stosd
movzx ecx, WORD PTR [rsp+280]
lea rcx, OFFSET FLAT:__C5BBD3C1_pmc_parse@c
call __CheckForDebuggerJustMyCode
; 867 : switch (c)
movzx eax, WORD PTR c$[rbp]
mov DWORD PTR tv65[rbp], eax
mov eax, DWORD PTR tv65[rbp]
sub eax, 48 ; 00000030H
mov DWORD PTR tv65[rbp], eax
cmp DWORD PTR tv65[rbp], 54 ; 00000036H
ja SHORT $LN7@Parse1Digi
movsxd rax, DWORD PTR tv65[rbp]
lea rcx, OFFSET FLAT:__ImageBase
movzx eax, BYTE PTR $LN9@Parse1Digi[rcx+rax]
mov eax, DWORD PTR $LN10@Parse1Digi[rcx+rax*4]
add rax, rcx
jmp rax
$LN4@Parse1Digi:
; 868 : {
; 869 : case L'0':
; 870 : case L'1':
; 871 : case L'2':
; 872 : case L'3':
; 873 : case L'4':
; 874 : case L'5':
; 875 : case L'6':
; 876 : case L'7':
; 877 : case L'8':
; 878 : case L'9':
; 879 : return (c - L'0');
movzx eax, WORD PTR c$[rbp]
sub eax, 48 ; 00000030H
jmp SHORT $LN1@Parse1Digi
$LN5@Parse1Digi:
; 880 : case L'a':
; 881 : case L'b':
; 882 : case L'c':
; 883 : case L'd':
; 884 : case L'e':
; 885 : case L'f':
; 886 : return (c - L'a' + 10);
movzx eax, WORD PTR c$[rbp]
sub eax, 87 ; 00000057H
jmp SHORT $LN1@Parse1Digi
$LN6@Parse1Digi:
; 887 : case L'A':
; 888 : case L'B':
; 889 : case L'C':
; 890 : case L'D':
; 891 : case L'E':
; 892 : case L'F':
; 893 : return (c - L'A' + 10);
movzx eax, WORD PTR c$[rbp]
sub eax, 55 ; 00000037H
jmp SHORT $LN1@Parse1Digi
$LN7@Parse1Digi:
; 894 : default:
; 895 : return ((_UINT32_T)-1);
mov eax, -1 ; ffffffffH
$LN1@Parse1Digi:
; 896 : }
; 897 : }
lea rsp, QWORD PTR [rbp+216]
pop rdi
pop rbp
ret 0
$LN10@Parse1Digi:
DD $LN4@Parse1Digi
DD $LN6@Parse1Digi
DD $LN5@Parse1Digi
DD $LN7@Parse1Digi
$LN9@Parse1Digi:
DB 0
DB 0
DB 0
DB 0
DB 0
DB 0
DB 0
DB 0
DB 0
DB 0
DB 3
DB 3
DB 3
DB 3
DB 3
DB 3
DB 3
DB 1
DB 1
DB 1
DB 1
DB 1
DB 1
DB 3
DB 3
DB 3
DB 3
DB 3
DB 3
DB 3
DB 3
DB 3
DB 3
DB 3
DB 3
DB 3
DB 3
DB 3
DB 3
DB 3
DB 3
DB 3
DB 3
DB 3
DB 3
DB 3
DB 3
DB 3
DB 3
DB 2
DB 2
DB 2
DB 2
DB 2
DB 2
Parse1DigitFromHexChar ENDP
_TEXT ENDS
; Function compile flags: /Odtp /RTCsu /ZI
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_parse.c
; COMDAT TryParseDN
_TEXT SEGMENT
result$ = 4
word_digit_count$ = 36
source_len$ = 72
int_part_buf_code$ = 104
int_part_buf_words$ = 136
int_part_buf$ = 168
frac_part_buf_code$ = 200
frac_part_buf_words$ = 232
frac_part_buf$ = 264
sign$ = 292
result_parsing$ = 324
s_ptr$12 = 360
d_ptr$13 = 392
frac_ptr$ = 424
bin_buf_code$ = 456
bin_buf_words$ = 488
bin_buf$ = 520
bin_buf_count$ = 552
o_bit_count$ = 584
no_light_check_code$ = 616
tv202 = 1016
source$ = 1056
number_styles$ = 1064
format_option$ = 1072
o$ = 1080
TryParseDN PROC ; COMDAT
; 722 : {
mov QWORD PTR [rsp+32], r9
mov QWORD PTR [rsp+24], r8
mov DWORD PTR [rsp+16], edx
mov QWORD PTR [rsp+8], rcx
push rbp
push rdi
sub rsp, 1080 ; 00000438H
lea rbp, QWORD PTR [rsp+48]
mov rdi, rsp
mov ecx, 270 ; 0000010eH
mov eax, -858993460 ; ccccccccH
rep stosd
mov rcx, QWORD PTR [rsp+1112]
lea rcx, OFFSET FLAT:__C5BBD3C1_pmc_parse@c
call __CheckForDebuggerJustMyCode
; 723 : PMC_STATUS_CODE result;
; 724 : #ifdef _M_IX86
; 725 : int word_digit_count = 9;
; 726 : #elif defined(_M_IX64)
; 727 : int word_digit_count = 19;
mov DWORD PTR word_digit_count$[rbp], 19
; 728 : #else
; 729 : #error unknown platform
; 730 : #endif
; 731 : __UNIT_TYPE source_len = lstrlenW(source);
mov rcx, QWORD PTR source$[rbp]
call QWORD PTR __imp_lstrlenW
cdqe
mov QWORD PTR source_len$[rbp], rax
; 732 :
; 733 : __UNIT_TYPE int_part_buf_code;
; 734 : __UNIT_TYPE int_part_buf_words;
; 735 : wchar_t* int_part_buf = (wchar_t*)AllocateBlock((source_len + 1) * sizeof(wchar_t) * 8, &int_part_buf_words, &int_part_buf_code);
mov rax, QWORD PTR source_len$[rbp]
lea rax, QWORD PTR [rax+rax+2]
shl rax, 3
lea r8, QWORD PTR int_part_buf_code$[rbp]
lea rdx, QWORD PTR int_part_buf_words$[rbp]
mov rcx, rax
call AllocateBlock
mov QWORD PTR int_part_buf$[rbp], rax
; 736 : if (int_part_buf == NULL)
cmp QWORD PTR int_part_buf$[rbp], 0
jne SHORT $LN9@TryParseDN
; 737 : return (PMC_STATUS_NOT_ENOUGH_MEMORY);
mov eax, -5
jmp $LN1@TryParseDN
$LN9@TryParseDN:
; 738 :
; 739 : __UNIT_TYPE frac_part_buf_code;
; 740 : __UNIT_TYPE frac_part_buf_words;
; 741 : wchar_t* frac_part_buf = (wchar_t*)AllocateBlock((source_len + 1) * sizeof(wchar_t) * 8, &frac_part_buf_words, &frac_part_buf_code);
mov rax, QWORD PTR source_len$[rbp]
lea rax, QWORD PTR [rax+rax+2]
shl rax, 3
lea r8, QWORD PTR frac_part_buf_code$[rbp]
lea rdx, QWORD PTR frac_part_buf_words$[rbp]
mov rcx, rax
call AllocateBlock
mov QWORD PTR frac_part_buf$[rbp], rax
; 742 : if (frac_part_buf == NULL)
cmp QWORD PTR frac_part_buf$[rbp], 0
jne SHORT $LN10@TryParseDN
; 743 : {
; 744 : DeallocateBlock((__UNIT_TYPE*)int_part_buf, int_part_buf_words);
mov rdx, QWORD PTR int_part_buf_words$[rbp]
mov rcx, QWORD PTR int_part_buf$[rbp]
call DeallocateBlock
; 745 : return (PMC_STATUS_NOT_ENOUGH_MEMORY);
mov eax, -5
jmp $LN1@TryParseDN
$LN10@TryParseDN:
; 746 : }
; 747 : int sign;
; 748 : int result_parsing = ParseAsDecimalNumberString(source, number_styles, format_option, &sign, int_part_buf, frac_part_buf);
mov rax, QWORD PTR frac_part_buf$[rbp]
mov QWORD PTR [rsp+40], rax
mov rax, QWORD PTR int_part_buf$[rbp]
mov QWORD PTR [rsp+32], rax
lea r9, QWORD PTR sign$[rbp]
mov r8, QWORD PTR format_option$[rbp]
mov edx, DWORD PTR number_styles$[rbp]
mov rcx, QWORD PTR source$[rbp]
call ParseAsDecimalNumberString
mov DWORD PTR result_parsing$[rbp], eax
; 749 : if ((result = CheckBlockLight((__UNIT_TYPE*)int_part_buf, int_part_buf_code)) != PMC_STATUS_OK)
mov rdx, QWORD PTR int_part_buf_code$[rbp]
mov rcx, QWORD PTR int_part_buf$[rbp]
call CheckBlockLight
mov DWORD PTR result$[rbp], eax
cmp DWORD PTR result$[rbp], 0
je SHORT $LN11@TryParseDN
; 750 : return (result);
mov eax, DWORD PTR result$[rbp]
jmp $LN1@TryParseDN
$LN11@TryParseDN:
; 751 : if ((result = CheckBlockLight((__UNIT_TYPE*)frac_part_buf, frac_part_buf_code)) != PMC_STATUS_OK)
mov rdx, QWORD PTR frac_part_buf_code$[rbp]
mov rcx, QWORD PTR frac_part_buf$[rbp]
call CheckBlockLight
mov DWORD PTR result$[rbp], eax
cmp DWORD PTR result$[rbp], 0
je SHORT $LN12@TryParseDN
; 752 : return (result);
mov eax, DWORD PTR result$[rbp]
jmp $LN1@TryParseDN
$LN12@TryParseDN:
; 753 : if (!result_parsing)
cmp DWORD PTR result_parsing$[rbp], 0
jne SHORT $LN13@TryParseDN
; 754 : {
; 755 : DeallocateBlock((__UNIT_TYPE*)frac_part_buf, frac_part_buf_words);
mov rdx, QWORD PTR frac_part_buf_words$[rbp]
mov rcx, QWORD PTR frac_part_buf$[rbp]
call DeallocateBlock
; 756 : DeallocateBlock((__UNIT_TYPE*)int_part_buf, int_part_buf_words);
mov rdx, QWORD PTR int_part_buf_words$[rbp]
mov rcx, QWORD PTR int_part_buf$[rbp]
call DeallocateBlock
; 757 : return (PMC_STATUS_PARSING_ERROR);
mov eax, 1
jmp $LN1@TryParseDN
$LN13@TryParseDN:
; 758 : }
; 759 : // 整数部と小数部がともに空ならばエラーとする
; 760 : if (int_part_buf[0] == L'\0' && frac_part_buf[0] == L'\0')
mov eax, 2
imul rax, rax, 0
mov rcx, QWORD PTR int_part_buf$[rbp]
movzx eax, WORD PTR [rcx+rax]
test eax, eax
jne SHORT $LN14@TryParseDN
mov eax, 2
imul rax, rax, 0
mov rcx, QWORD PTR frac_part_buf$[rbp]
movzx eax, WORD PTR [rcx+rax]
test eax, eax
jne SHORT $LN14@TryParseDN
; 761 : {
; 762 : DeallocateBlock((__UNIT_TYPE*)frac_part_buf, frac_part_buf_words);
mov rdx, QWORD PTR frac_part_buf_words$[rbp]
mov rcx, QWORD PTR frac_part_buf$[rbp]
call DeallocateBlock
; 763 : DeallocateBlock((__UNIT_TYPE*)int_part_buf, int_part_buf_words);
mov rdx, QWORD PTR int_part_buf_words$[rbp]
mov rcx, QWORD PTR int_part_buf$[rbp]
call DeallocateBlock
; 764 : return (PMC_STATUS_PARSING_ERROR);
mov eax, 1
jmp $LN1@TryParseDN
$LN14@TryParseDN:
; 765 : }
; 766 :
; 767 : if (int_part_buf[0] == L'0')
mov eax, 2
imul rax, rax, 0
mov rcx, QWORD PTR int_part_buf$[rbp]
movzx eax, WORD PTR [rcx+rax]
cmp eax, 48 ; 00000030H
jne $LN15@TryParseDN
; 768 : {
; 769 : // 整数部の先行する 0 を削除する
; 770 : wchar_t* s_ptr = int_part_buf;
mov rax, QWORD PTR int_part_buf$[rbp]
mov QWORD PTR s_ptr$12[rbp], rax
; 771 : wchar_t* d_ptr = int_part_buf;
mov rax, QWORD PTR int_part_buf$[rbp]
mov QWORD PTR d_ptr$13[rbp], rax
$LN2@TryParseDN:
; 772 : while (*s_ptr == L'0')
mov rax, QWORD PTR s_ptr$12[rbp]
movzx eax, WORD PTR [rax]
cmp eax, 48 ; 00000030H
jne SHORT $LN3@TryParseDN
; 773 : ++s_ptr;
mov rax, QWORD PTR s_ptr$12[rbp]
add rax, 2
mov QWORD PTR s_ptr$12[rbp], rax
jmp SHORT $LN2@TryParseDN
$LN3@TryParseDN:
$LN4@TryParseDN:
; 774 : for (;;)
; 775 : {
; 776 : *d_ptr = *s_ptr;
mov rax, QWORD PTR d_ptr$13[rbp]
mov rcx, QWORD PTR s_ptr$12[rbp]
movzx ecx, WORD PTR [rcx]
mov WORD PTR [rax], cx
; 777 : if (*s_ptr == L'\0')
mov rax, QWORD PTR s_ptr$12[rbp]
movzx eax, WORD PTR [rax]
test eax, eax
jne SHORT $LN16@TryParseDN
; 778 : break;
jmp SHORT $LN5@TryParseDN
$LN16@TryParseDN:
; 779 : ++s_ptr;
mov rax, QWORD PTR s_ptr$12[rbp]
add rax, 2
mov QWORD PTR s_ptr$12[rbp], rax
; 780 : ++d_ptr;
mov rax, QWORD PTR d_ptr$13[rbp]
add rax, 2
mov QWORD PTR d_ptr$13[rbp], rax
; 781 : }
jmp SHORT $LN4@TryParseDN
$LN5@TryParseDN:
$LN15@TryParseDN:
; 782 : }
; 783 :
; 784 : // 小数部の末尾の 0 を削除する
; 785 : wchar_t* frac_ptr = frac_part_buf + lstrlenW(frac_part_buf);
mov rcx, QWORD PTR frac_part_buf$[rbp]
call QWORD PTR __imp_lstrlenW
cdqe
mov rcx, QWORD PTR frac_part_buf$[rbp]
lea rax, QWORD PTR [rcx+rax*2]
mov QWORD PTR frac_ptr$[rbp], rax
$LN7@TryParseDN:
; 786 : while (frac_ptr > frac_part_buf && frac_ptr[-1] == L'0')
mov rax, QWORD PTR frac_part_buf$[rbp]
cmp QWORD PTR frac_ptr$[rbp], rax
jbe SHORT $LN8@TryParseDN
mov eax, 2
imul rax, rax, -1
mov rcx, QWORD PTR frac_ptr$[rbp]
movzx eax, WORD PTR [rcx+rax]
cmp eax, 48 ; 00000030H
jne SHORT $LN8@TryParseDN
; 787 : --frac_ptr;
mov rax, QWORD PTR frac_ptr$[rbp]
sub rax, 2
mov QWORD PTR frac_ptr$[rbp], rax
jmp SHORT $LN7@TryParseDN
$LN8@TryParseDN:
; 788 : *frac_ptr = L'\0';
xor eax, eax
mov rcx, QWORD PTR frac_ptr$[rbp]
mov WORD PTR [rcx], ax
; 789 :
; 790 : // 小数部が 0 ではない場合、エラーとする
; 791 : if (frac_part_buf[0] != L'\0')
mov eax, 2
imul rax, rax, 0
mov rcx, QWORD PTR frac_part_buf$[rbp]
movzx eax, WORD PTR [rcx+rax]
test eax, eax
je SHORT $LN17@TryParseDN
; 792 : {
; 793 : DeallocateBlock((__UNIT_TYPE*)frac_part_buf, frac_part_buf_words);
mov rdx, QWORD PTR frac_part_buf_words$[rbp]
mov rcx, QWORD PTR frac_part_buf$[rbp]
call DeallocateBlock
; 794 : DeallocateBlock((__UNIT_TYPE*)int_part_buf, int_part_buf_words);
mov rdx, QWORD PTR int_part_buf_words$[rbp]
mov rcx, QWORD PTR int_part_buf$[rbp]
call DeallocateBlock
; 795 : return (PMC_STATUS_PARSING_ERROR);
mov eax, 1
jmp $LN1@TryParseDN
$LN17@TryParseDN:
; 796 : }
; 797 :
; 798 : if (sign < 0)
cmp DWORD PTR sign$[rbp], 0
jge SHORT $LN18@TryParseDN
; 799 : {
; 800 : if (int_part_buf[0] == L'\0')
mov eax, 2
imul rax, rax, 0
mov rcx, QWORD PTR int_part_buf$[rbp]
movzx eax, WORD PTR [rcx+rax]
test eax, eax
jne SHORT $LN19@TryParseDN
; 801 : {
; 802 : // - 符号が与えられていてかつ整数部が 0 であるなら符号を修正する
; 803 : sign = 0;
mov DWORD PTR sign$[rbp], 0
; 804 : }
jmp SHORT $LN20@TryParseDN
$LN19@TryParseDN:
; 805 : else
; 806 : {
; 807 : // - 符号が与えられていてかつ整数部が 0 ではないなら、エラーとする
; 808 : DeallocateBlock((__UNIT_TYPE*)frac_part_buf, frac_part_buf_words);
mov rdx, QWORD PTR frac_part_buf_words$[rbp]
mov rcx, QWORD PTR frac_part_buf$[rbp]
call DeallocateBlock
; 809 : DeallocateBlock((__UNIT_TYPE*)int_part_buf, int_part_buf_words);
mov rdx, QWORD PTR int_part_buf_words$[rbp]
mov rcx, QWORD PTR int_part_buf$[rbp]
call DeallocateBlock
; 810 : return (PMC_STATUS_OVERFLOW);
mov eax, -2
jmp $LN1@TryParseDN
$LN20@TryParseDN:
$LN18@TryParseDN:
; 811 : }
; 812 : }
; 813 :
; 814 : // 整数部が空である場合、1桁の 0 を設定する
; 815 : if (int_part_buf[0] == L'\0')
mov eax, 2
imul rax, rax, 0
mov rcx, QWORD PTR int_part_buf$[rbp]
movzx eax, WORD PTR [rcx+rax]
test eax, eax
jne SHORT $LN21@TryParseDN
; 816 : {
; 817 : int_part_buf[0] = L'0';
mov eax, 2
imul rax, rax, 0
mov ecx, 48 ; 00000030H
mov rdx, QWORD PTR int_part_buf$[rbp]
mov WORD PTR [rdx+rax], cx
; 818 : int_part_buf[1] = L'\0';
mov eax, 2
imul rax, rax, 1
xor ecx, ecx
mov rdx, QWORD PTR int_part_buf$[rbp]
mov WORD PTR [rdx+rax], cx
$LN21@TryParseDN:
; 819 : }
; 820 :
; 821 : // 小数部は捨てる
; 822 : DeallocateBlock((__UNIT_TYPE*)frac_part_buf, frac_part_buf_words);
mov rdx, QWORD PTR frac_part_buf_words$[rbp]
mov rcx, QWORD PTR frac_part_buf$[rbp]
call DeallocateBlock
; 823 :
; 824 : __UNIT_TYPE bin_buf_code;
; 825 : __UNIT_TYPE bin_buf_words;
; 826 : __UNIT_TYPE* bin_buf = AllocateBlock(_DIVIDE_CEILING_SIZE(lstrlenW(int_part_buf), word_digit_count) * __UNIT_TYPE_BIT_COUNT, &bin_buf_words, &bin_buf_code);
movsxd rax, DWORD PTR word_digit_count$[rbp]
mov QWORD PTR tv202[rbp], rax
mov rcx, QWORD PTR int_part_buf$[rbp]
call QWORD PTR __imp_lstrlenW
cdqe
mov rcx, QWORD PTR tv202[rbp]
mov rdx, rcx
mov rcx, rax
call _DIVIDE_CEILING_SIZE
imul rax, rax, 64 ; 00000040H
lea r8, QWORD PTR bin_buf_code$[rbp]
lea rdx, QWORD PTR bin_buf_words$[rbp]
mov rcx, rax
call AllocateBlock
mov QWORD PTR bin_buf$[rbp], rax
; 827 : if (bin_buf == NULL)
cmp QWORD PTR bin_buf$[rbp], 0
jne SHORT $LN22@TryParseDN
; 828 : {
; 829 : DeallocateBlock((__UNIT_TYPE*)int_part_buf, int_part_buf_words);
mov rdx, QWORD PTR int_part_buf_words$[rbp]
mov rcx, QWORD PTR int_part_buf$[rbp]
call DeallocateBlock
; 830 : return (PMC_STATUS_NOT_ENOUGH_MEMORY);
mov eax, -5
jmp $LN1@TryParseDN
$LN22@TryParseDN:
; 831 : }
; 832 : __UNIT_TYPE bin_buf_count;
; 833 : BuildBinaryFromDecimalString(int_part_buf, bin_buf, &bin_buf_count);
lea r8, QWORD PTR bin_buf_count$[rbp]
mov rdx, QWORD PTR bin_buf$[rbp]
mov rcx, QWORD PTR int_part_buf$[rbp]
call BuildBinaryFromDecimalString
; 834 : if ((result = CheckBlockLight(bin_buf, bin_buf_code)) != PMC_STATUS_OK)
mov rdx, QWORD PTR bin_buf_code$[rbp]
mov rcx, QWORD PTR bin_buf$[rbp]
call CheckBlockLight
mov DWORD PTR result$[rbp], eax
cmp DWORD PTR result$[rbp], 0
je SHORT $LN23@TryParseDN
; 835 : return (result);
mov eax, DWORD PTR result$[rbp]
jmp $LN1@TryParseDN
$LN23@TryParseDN:
; 836 : DeallocateBlock((__UNIT_TYPE*)int_part_buf, int_part_buf_words);
mov rdx, QWORD PTR int_part_buf_words$[rbp]
mov rcx, QWORD PTR int_part_buf$[rbp]
call DeallocateBlock
; 837 :
; 838 : __UNIT_TYPE o_bit_count = bin_buf_count * __UNIT_TYPE_BIT_COUNT;
imul rax, QWORD PTR bin_buf_count$[rbp], 64 ; 00000040H
mov QWORD PTR o_bit_count$[rbp], rax
; 839 : __UNIT_TYPE no_light_check_code;
; 840 : if ((result = AllocateNumber(o, o_bit_count, &no_light_check_code)) != PMC_STATUS_OK)
lea r8, QWORD PTR no_light_check_code$[rbp]
mov rdx, QWORD PTR o_bit_count$[rbp]
mov rcx, QWORD PTR o$[rbp]
call AllocateNumber
mov DWORD PTR result$[rbp], eax
cmp DWORD PTR result$[rbp], 0
je SHORT $LN24@TryParseDN
; 841 : {
; 842 : DeallocateBlock(bin_buf, bin_buf_words);
mov rdx, QWORD PTR bin_buf_words$[rbp]
mov rcx, QWORD PTR bin_buf$[rbp]
call DeallocateBlock
; 843 : return (result);
mov eax, DWORD PTR result$[rbp]
jmp $LN1@TryParseDN
$LN24@TryParseDN:
; 844 : }
; 845 :
; 846 : if ((result = ConvertCardinalNumber(bin_buf, bin_buf_count, (*o)->BLOCK)) != PMC_STATUS_OK)
mov rax, QWORD PTR o$[rbp]
mov rax, QWORD PTR [rax]
mov r8, QWORD PTR [rax+56]
mov rdx, QWORD PTR bin_buf_count$[rbp]
mov rcx, QWORD PTR bin_buf$[rbp]
call ConvertCardinalNumber
mov DWORD PTR result$[rbp], eax
cmp DWORD PTR result$[rbp], 0
je SHORT $LN25@TryParseDN
; 847 : {
; 848 : DeallocateNumber(*o);
mov rax, QWORD PTR o$[rbp]
mov rcx, QWORD PTR [rax]
call DeallocateNumber
; 849 : DeallocateBlock(bin_buf, bin_buf_words);
mov rdx, QWORD PTR bin_buf_words$[rbp]
mov rcx, QWORD PTR bin_buf$[rbp]
call DeallocateBlock
; 850 : return (result);
mov eax, DWORD PTR result$[rbp]
jmp $LN1@TryParseDN
$LN25@TryParseDN:
; 851 : }
; 852 : if ((result = CheckBlockLight((*o)->BLOCK, no_light_check_code)) != PMC_STATUS_OK)
mov rax, QWORD PTR o$[rbp]
mov rax, QWORD PTR [rax]
mov rdx, QWORD PTR no_light_check_code$[rbp]
mov rcx, QWORD PTR [rax+56]
call CheckBlockLight
mov DWORD PTR result$[rbp], eax
cmp DWORD PTR result$[rbp], 0
je SHORT $LN26@TryParseDN
; 853 : return (result);
mov eax, DWORD PTR result$[rbp]
jmp SHORT $LN1@TryParseDN
$LN26@TryParseDN:
; 854 : DeallocateBlock(bin_buf, bin_buf_words);
mov rdx, QWORD PTR bin_buf_words$[rbp]
mov rcx, QWORD PTR bin_buf$[rbp]
call DeallocateBlock
; 855 : CommitNumber(*o);
mov rax, QWORD PTR o$[rbp]
mov rcx, QWORD PTR [rax]
call CommitNumber
; 856 : if ((*o)->IS_ZERO)
mov rax, QWORD PTR o$[rbp]
mov rax, QWORD PTR [rax]
mov eax, DWORD PTR [rax+40]
shr eax, 1
and eax, 1
test eax, eax
je SHORT $LN27@TryParseDN
; 857 : {
; 858 : DeallocateNumber(*o);
mov rax, QWORD PTR o$[rbp]
mov rcx, QWORD PTR [rax]
call DeallocateNumber
; 859 : *o = &number_zero;
mov rax, QWORD PTR o$[rbp]
lea rcx, OFFSET FLAT:number_zero
mov QWORD PTR [rax], rcx
$LN27@TryParseDN:
; 860 : }
; 861 : return (PMC_STATUS_OK);
xor eax, eax
$LN1@TryParseDN:
; 862 : }
mov rdi, rax
lea rcx, QWORD PTR [rbp-48]
lea rdx, OFFSET FLAT:TryParseDN$rtcFrameData
call _RTC_CheckStackVars
mov rax, rdi
lea rsp, QWORD PTR [rbp+1032]
pop rdi
pop rbp
ret 0
TryParseDN ENDP
_TEXT ENDS
; Function compile flags: /Odtp /RTCsu /ZI
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_parse.c
; COMDAT ConvertCardinalNumber
_TEXT SEGMENT
result$ = 4
work_buf_code$ = 40
work_buf_words$ = 72
work_buf$ = 104
work_buf_count$ = 136
w_tail$5 = 168
in_buf$ = 416
in_buf_count$ = 424
out_buf$ = 432
ConvertCardinalNumber PROC ; COMDAT
; 694 : {
mov QWORD PTR [rsp+24], r8
mov QWORD PTR [rsp+16], rdx
mov QWORD PTR [rsp+8], rcx
push rbp
push rdi
sub rsp, 424 ; 000001a8H
lea rbp, QWORD PTR [rsp+32]
mov rdi, rsp
mov ecx, 106 ; 0000006aH
mov eax, -858993460 ; ccccccccH
rep stosd
mov rcx, QWORD PTR [rsp+456]
lea rcx, OFFSET FLAT:__C5BBD3C1_pmc_parse@c
call __CheckForDebuggerJustMyCode
; 695 : PMC_STATUS_CODE result;
; 696 : __UNIT_TYPE work_buf_code;
; 697 : __UNIT_TYPE work_buf_words;
; 698 : __UNIT_TYPE* work_buf = AllocateBlock(__UNIT_TYPE_BIT_COUNT * (in_buf_count + 1), &work_buf_words, &work_buf_code);
mov rax, QWORD PTR in_buf_count$[rbp]
inc rax
imul rax, rax, 64 ; 00000040H
lea r8, QWORD PTR work_buf_code$[rbp]
lea rdx, QWORD PTR work_buf_words$[rbp]
mov rcx, rax
call AllocateBlock
mov QWORD PTR work_buf$[rbp], rax
; 699 : if (work_buf == NULL)
cmp QWORD PTR work_buf$[rbp], 0
jne SHORT $LN4@ConvertCar
; 700 : return (PMC_STATUS_NOT_ENOUGH_MEMORY);
mov eax, -5
jmp $LN1@ConvertCar
$LN4@ConvertCar:
; 701 :
; 702 : __UNIT_TYPE work_buf_count = 1;
mov QWORD PTR work_buf_count$[rbp], 1
; 703 : work_buf[0] = in_buf[0];
mov eax, 8
imul rax, rax, 0
mov ecx, 8
imul rcx, rcx, 0
mov rdx, QWORD PTR work_buf$[rbp]
mov r8, QWORD PTR in_buf$[rbp]
mov rax, QWORD PTR [r8+rax]
mov QWORD PTR [rdx+rcx], rax
; 704 : ++in_buf;
mov rax, QWORD PTR in_buf$[rbp]
add rax, 8
mov QWORD PTR in_buf$[rbp], rax
; 705 : --in_buf_count;
mov rax, QWORD PTR in_buf_count$[rbp]
dec rax
mov QWORD PTR in_buf_count$[rbp], rax
$LN2@ConvertCar:
; 706 :
; 707 : while (in_buf_count > 0)
cmp QWORD PTR in_buf_count$[rbp], 0
jbe SHORT $LN3@ConvertCar
; 708 : {
; 709 : __UNIT_TYPE* w_tail = (*fp_MultiplyAndAdd)(work_buf, work_buf_count, *in_buf);
mov rax, QWORD PTR in_buf$[rbp]
mov r8, QWORD PTR [rax]
mov rdx, QWORD PTR work_buf_count$[rbp]
mov rcx, QWORD PTR work_buf$[rbp]
call QWORD PTR fp_MultiplyAndAdd
mov QWORD PTR w_tail$5[rbp], rax
; 710 : work_buf_count = w_tail - work_buf;
mov rax, QWORD PTR work_buf$[rbp]
mov rcx, QWORD PTR w_tail$5[rbp]
sub rcx, rax
mov rax, rcx
sar rax, 3
mov QWORD PTR work_buf_count$[rbp], rax
; 711 : ++in_buf;
mov rax, QWORD PTR in_buf$[rbp]
add rax, 8
mov QWORD PTR in_buf$[rbp], rax
; 712 : --in_buf_count;
mov rax, QWORD PTR in_buf_count$[rbp]
dec rax
mov QWORD PTR in_buf_count$[rbp], rax
; 713 : }
jmp SHORT $LN2@ConvertCar
$LN3@ConvertCar:
; 714 : if ((result = CheckBlockLight(work_buf, work_buf_code)) != PMC_STATUS_OK)
mov rdx, QWORD PTR work_buf_code$[rbp]
mov rcx, QWORD PTR work_buf$[rbp]
call CheckBlockLight
mov DWORD PTR result$[rbp], eax
cmp DWORD PTR result$[rbp], 0
je SHORT $LN5@ConvertCar
; 715 : return (result);
mov eax, DWORD PTR result$[rbp]
jmp SHORT $LN1@ConvertCar
$LN5@ConvertCar:
; 716 : _COPY_MEMORY_UNIT(out_buf, work_buf, work_buf_count);
mov r8, QWORD PTR work_buf_count$[rbp]
mov rdx, QWORD PTR work_buf$[rbp]
mov rcx, QWORD PTR out_buf$[rbp]
call _COPY_MEMORY_UNIT
; 717 : DeallocateBlock(work_buf, work_buf_words);
mov rdx, QWORD PTR work_buf_words$[rbp]
mov rcx, QWORD PTR work_buf$[rbp]
call DeallocateBlock
; 718 : return (PMC_STATUS_OK);
xor eax, eax
$LN1@ConvertCar:
; 719 : }
mov rdi, rax
lea rcx, QWORD PTR [rbp-32]
lea rdx, OFFSET FLAT:ConvertCardinalNumber$rtcFrameData
call _RTC_CheckStackVars
mov rax, rdi
lea rsp, QWORD PTR [rbp+392]
pop rdi
pop rbp
ret 0
ConvertCardinalNumber ENDP
_TEXT ENDS
; Function compile flags: /Odtp /RTCsu /ZI
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_parse.c
; COMDAT MultiplyAndAdd_using_ADCX_MULX
_TEXT SEGMENT
k$ = 8
count$ = 40
u_buf$ = 288
u_count$ = 296
x$ = 304
MultiplyAndAdd_using_ADCX_MULX PROC ; COMDAT
; 551 : {
mov QWORD PTR [rsp+24], r8
mov QWORD PTR [rsp+16], rdx
mov QWORD PTR [rsp+8], rcx
push rbp
push rdi
sub rsp, 296 ; 00000128H
lea rbp, QWORD PTR [rsp+32]
mov rdi, rsp
mov ecx, 74 ; 0000004aH
mov eax, -858993460 ; ccccccccH
rep stosd
mov rcx, QWORD PTR [rsp+328]
lea rcx, OFFSET FLAT:__C5BBD3C1_pmc_parse@c
call __CheckForDebuggerJustMyCode
; 552 : __UNIT_TYPE k = x;
mov rax, QWORD PTR x$[rbp]
mov QWORD PTR k$[rbp], rax
; 553 : __UNIT_TYPE count = u_count >> 5;
mov rax, QWORD PTR u_count$[rbp]
shr rax, 5
mov QWORD PTR count$[rbp], rax
$LN2@MultiplyAn:
; 554 : while (count > 0)
cmp QWORD PTR count$[rbp], 0
jbe $LN3@MultiplyAn
; 555 : {
; 556 : k = MultiplyAndAdd1Word_using_ADCX_MULX(k, u_buf[0], &u_buf[0]);
mov eax, 8
imul rax, rax, 0
mov rcx, QWORD PTR u_buf$[rbp]
add rcx, rax
mov rax, rcx
mov ecx, 8
imul rcx, rcx, 0
mov r8, rax
mov rax, QWORD PTR u_buf$[rbp]
mov rdx, QWORD PTR [rax+rcx]
mov rcx, QWORD PTR k$[rbp]
call MultiplyAndAdd1Word_using_ADCX_MULX
mov QWORD PTR k$[rbp], rax
; 557 : k = MultiplyAndAdd1Word_using_ADCX_MULX(k, u_buf[1], &u_buf[1]);
mov eax, 8
imul rax, rax, 1
mov rcx, QWORD PTR u_buf$[rbp]
add rcx, rax
mov rax, rcx
mov ecx, 8
imul rcx, rcx, 1
mov r8, rax
mov rax, QWORD PTR u_buf$[rbp]
mov rdx, QWORD PTR [rax+rcx]
mov rcx, QWORD PTR k$[rbp]
call MultiplyAndAdd1Word_using_ADCX_MULX
mov QWORD PTR k$[rbp], rax
; 558 : k = MultiplyAndAdd1Word_using_ADCX_MULX(k, u_buf[2], &u_buf[2]);
mov eax, 8
imul rax, rax, 2
mov rcx, QWORD PTR u_buf$[rbp]
add rcx, rax
mov rax, rcx
mov ecx, 8
imul rcx, rcx, 2
mov r8, rax
mov rax, QWORD PTR u_buf$[rbp]
mov rdx, QWORD PTR [rax+rcx]
mov rcx, QWORD PTR k$[rbp]
call MultiplyAndAdd1Word_using_ADCX_MULX
mov QWORD PTR k$[rbp], rax
; 559 : k = MultiplyAndAdd1Word_using_ADCX_MULX(k, u_buf[3], &u_buf[3]);
mov eax, 8
imul rax, rax, 3
mov rcx, QWORD PTR u_buf$[rbp]
add rcx, rax
mov rax, rcx
mov ecx, 8
imul rcx, rcx, 3
mov r8, rax
mov rax, QWORD PTR u_buf$[rbp]
mov rdx, QWORD PTR [rax+rcx]
mov rcx, QWORD PTR k$[rbp]
call MultiplyAndAdd1Word_using_ADCX_MULX
mov QWORD PTR k$[rbp], rax
; 560 : k = MultiplyAndAdd1Word_using_ADCX_MULX(k, u_buf[4], &u_buf[4]);
mov eax, 8
imul rax, rax, 4
mov rcx, QWORD PTR u_buf$[rbp]
add rcx, rax
mov rax, rcx
mov ecx, 8
imul rcx, rcx, 4
mov r8, rax
mov rax, QWORD PTR u_buf$[rbp]
mov rdx, QWORD PTR [rax+rcx]
mov rcx, QWORD PTR k$[rbp]
call MultiplyAndAdd1Word_using_ADCX_MULX
mov QWORD PTR k$[rbp], rax
; 561 : k = MultiplyAndAdd1Word_using_ADCX_MULX(k, u_buf[5], &u_buf[5]);
mov eax, 8
imul rax, rax, 5
mov rcx, QWORD PTR u_buf$[rbp]
add rcx, rax
mov rax, rcx
mov ecx, 8
imul rcx, rcx, 5
mov r8, rax
mov rax, QWORD PTR u_buf$[rbp]
mov rdx, QWORD PTR [rax+rcx]
mov rcx, QWORD PTR k$[rbp]
call MultiplyAndAdd1Word_using_ADCX_MULX
mov QWORD PTR k$[rbp], rax
; 562 : k = MultiplyAndAdd1Word_using_ADCX_MULX(k, u_buf[6], &u_buf[6]);
mov eax, 8
imul rax, rax, 6
mov rcx, QWORD PTR u_buf$[rbp]
add rcx, rax
mov rax, rcx
mov ecx, 8
imul rcx, rcx, 6
mov r8, rax
mov rax, QWORD PTR u_buf$[rbp]
mov rdx, QWORD PTR [rax+rcx]
mov rcx, QWORD PTR k$[rbp]
call MultiplyAndAdd1Word_using_ADCX_MULX
mov QWORD PTR k$[rbp], rax
; 563 : k = MultiplyAndAdd1Word_using_ADCX_MULX(k, u_buf[7], &u_buf[7]);
mov eax, 8
imul rax, rax, 7
mov rcx, QWORD PTR u_buf$[rbp]
add rcx, rax
mov rax, rcx
mov ecx, 8
imul rcx, rcx, 7
mov r8, rax
mov rax, QWORD PTR u_buf$[rbp]
mov rdx, QWORD PTR [rax+rcx]
mov rcx, QWORD PTR k$[rbp]
call MultiplyAndAdd1Word_using_ADCX_MULX
mov QWORD PTR k$[rbp], rax
; 564 : k = MultiplyAndAdd1Word_using_ADCX_MULX(k, u_buf[8], &u_buf[8]);
mov eax, 8
imul rax, rax, 8
mov rcx, QWORD PTR u_buf$[rbp]
add rcx, rax
mov rax, rcx
mov ecx, 8
imul rcx, rcx, 8
mov r8, rax
mov rax, QWORD PTR u_buf$[rbp]
mov rdx, QWORD PTR [rax+rcx]
mov rcx, QWORD PTR k$[rbp]
call MultiplyAndAdd1Word_using_ADCX_MULX
mov QWORD PTR k$[rbp], rax
; 565 : k = MultiplyAndAdd1Word_using_ADCX_MULX(k, u_buf[9], &u_buf[9]);
mov eax, 8
imul rax, rax, 9
mov rcx, QWORD PTR u_buf$[rbp]
add rcx, rax
mov rax, rcx
mov ecx, 8
imul rcx, rcx, 9
mov r8, rax
mov rax, QWORD PTR u_buf$[rbp]
mov rdx, QWORD PTR [rax+rcx]
mov rcx, QWORD PTR k$[rbp]
call MultiplyAndAdd1Word_using_ADCX_MULX
mov QWORD PTR k$[rbp], rax
; 566 : k = MultiplyAndAdd1Word_using_ADCX_MULX(k, u_buf[10], &u_buf[10]);
mov eax, 8
imul rax, rax, 10
mov rcx, QWORD PTR u_buf$[rbp]
add rcx, rax
mov rax, rcx
mov ecx, 8
imul rcx, rcx, 10
mov r8, rax
mov rax, QWORD PTR u_buf$[rbp]
mov rdx, QWORD PTR [rax+rcx]
mov rcx, QWORD PTR k$[rbp]
call MultiplyAndAdd1Word_using_ADCX_MULX
mov QWORD PTR k$[rbp], rax
; 567 : k = MultiplyAndAdd1Word_using_ADCX_MULX(k, u_buf[11], &u_buf[11]);
mov eax, 8
imul rax, rax, 11
mov rcx, QWORD PTR u_buf$[rbp]
add rcx, rax
mov rax, rcx
mov ecx, 8
imul rcx, rcx, 11
mov r8, rax
mov rax, QWORD PTR u_buf$[rbp]
mov rdx, QWORD PTR [rax+rcx]
mov rcx, QWORD PTR k$[rbp]
call MultiplyAndAdd1Word_using_ADCX_MULX
mov QWORD PTR k$[rbp], rax
; 568 : k = MultiplyAndAdd1Word_using_ADCX_MULX(k, u_buf[12], &u_buf[12]);
mov eax, 8
imul rax, rax, 12
mov rcx, QWORD PTR u_buf$[rbp]
add rcx, rax
mov rax, rcx
mov ecx, 8
imul rcx, rcx, 12
mov r8, rax
mov rax, QWORD PTR u_buf$[rbp]
mov rdx, QWORD PTR [rax+rcx]
mov rcx, QWORD PTR k$[rbp]
call MultiplyAndAdd1Word_using_ADCX_MULX
mov QWORD PTR k$[rbp], rax
; 569 : k = MultiplyAndAdd1Word_using_ADCX_MULX(k, u_buf[13], &u_buf[13]);
mov eax, 8
imul rax, rax, 13
mov rcx, QWORD PTR u_buf$[rbp]
add rcx, rax
mov rax, rcx
mov ecx, 8
imul rcx, rcx, 13
mov r8, rax
mov rax, QWORD PTR u_buf$[rbp]
mov rdx, QWORD PTR [rax+rcx]
mov rcx, QWORD PTR k$[rbp]
call MultiplyAndAdd1Word_using_ADCX_MULX
mov QWORD PTR k$[rbp], rax
; 570 : k = MultiplyAndAdd1Word_using_ADCX_MULX(k, u_buf[14], &u_buf[14]);
mov eax, 8
imul rax, rax, 14
mov rcx, QWORD PTR u_buf$[rbp]
add rcx, rax
mov rax, rcx
mov ecx, 8
imul rcx, rcx, 14
mov r8, rax
mov rax, QWORD PTR u_buf$[rbp]
mov rdx, QWORD PTR [rax+rcx]
mov rcx, QWORD PTR k$[rbp]
call MultiplyAndAdd1Word_using_ADCX_MULX
mov QWORD PTR k$[rbp], rax
; 571 : k = MultiplyAndAdd1Word_using_ADCX_MULX(k, u_buf[15], &u_buf[15]);
mov eax, 8
imul rax, rax, 15
mov rcx, QWORD PTR u_buf$[rbp]
add rcx, rax
mov rax, rcx
mov ecx, 8
imul rcx, rcx, 15
mov r8, rax
mov rax, QWORD PTR u_buf$[rbp]
mov rdx, QWORD PTR [rax+rcx]
mov rcx, QWORD PTR k$[rbp]
call MultiplyAndAdd1Word_using_ADCX_MULX
mov QWORD PTR k$[rbp], rax
; 572 : k = MultiplyAndAdd1Word_using_ADCX_MULX(k, u_buf[16], &u_buf[16]);
mov eax, 8
imul rax, rax, 16
mov rcx, QWORD PTR u_buf$[rbp]
add rcx, rax
mov rax, rcx
mov ecx, 8
imul rcx, rcx, 16
mov r8, rax
mov rax, QWORD PTR u_buf$[rbp]
mov rdx, QWORD PTR [rax+rcx]
mov rcx, QWORD PTR k$[rbp]
call MultiplyAndAdd1Word_using_ADCX_MULX
mov QWORD PTR k$[rbp], rax
; 573 : k = MultiplyAndAdd1Word_using_ADCX_MULX(k, u_buf[17], &u_buf[17]);
mov eax, 8
imul rax, rax, 17
mov rcx, QWORD PTR u_buf$[rbp]
add rcx, rax
mov rax, rcx
mov ecx, 8
imul rcx, rcx, 17
mov r8, rax
mov rax, QWORD PTR u_buf$[rbp]
mov rdx, QWORD PTR [rax+rcx]
mov rcx, QWORD PTR k$[rbp]
call MultiplyAndAdd1Word_using_ADCX_MULX
mov QWORD PTR k$[rbp], rax
; 574 : k = MultiplyAndAdd1Word_using_ADCX_MULX(k, u_buf[18], &u_buf[18]);
mov eax, 8
imul rax, rax, 18
mov rcx, QWORD PTR u_buf$[rbp]
add rcx, rax
mov rax, rcx
mov ecx, 8
imul rcx, rcx, 18
mov r8, rax
mov rax, QWORD PTR u_buf$[rbp]
mov rdx, QWORD PTR [rax+rcx]
mov rcx, QWORD PTR k$[rbp]
call MultiplyAndAdd1Word_using_ADCX_MULX
mov QWORD PTR k$[rbp], rax
; 575 : k = MultiplyAndAdd1Word_using_ADCX_MULX(k, u_buf[19], &u_buf[19]);
mov eax, 8
imul rax, rax, 19
mov rcx, QWORD PTR u_buf$[rbp]
add rcx, rax
mov rax, rcx
mov ecx, 8
imul rcx, rcx, 19
mov r8, rax
mov rax, QWORD PTR u_buf$[rbp]
mov rdx, QWORD PTR [rax+rcx]
mov rcx, QWORD PTR k$[rbp]
call MultiplyAndAdd1Word_using_ADCX_MULX
mov QWORD PTR k$[rbp], rax
; 576 : k = MultiplyAndAdd1Word_using_ADCX_MULX(k, u_buf[20], &u_buf[20]);
mov eax, 8
imul rax, rax, 20
mov rcx, QWORD PTR u_buf$[rbp]
add rcx, rax
mov rax, rcx
mov ecx, 8
imul rcx, rcx, 20
mov r8, rax
mov rax, QWORD PTR u_buf$[rbp]
mov rdx, QWORD PTR [rax+rcx]
mov rcx, QWORD PTR k$[rbp]
call MultiplyAndAdd1Word_using_ADCX_MULX
mov QWORD PTR k$[rbp], rax
; 577 : k = MultiplyAndAdd1Word_using_ADCX_MULX(k, u_buf[21], &u_buf[21]);
mov eax, 8
imul rax, rax, 21
mov rcx, QWORD PTR u_buf$[rbp]
add rcx, rax
mov rax, rcx
mov ecx, 8
imul rcx, rcx, 21
mov r8, rax
mov rax, QWORD PTR u_buf$[rbp]
mov rdx, QWORD PTR [rax+rcx]
mov rcx, QWORD PTR k$[rbp]
call MultiplyAndAdd1Word_using_ADCX_MULX
mov QWORD PTR k$[rbp], rax
; 578 : k = MultiplyAndAdd1Word_using_ADCX_MULX(k, u_buf[22], &u_buf[22]);
mov eax, 8
imul rax, rax, 22
mov rcx, QWORD PTR u_buf$[rbp]
add rcx, rax
mov rax, rcx
mov ecx, 8
imul rcx, rcx, 22
mov r8, rax
mov rax, QWORD PTR u_buf$[rbp]
mov rdx, QWORD PTR [rax+rcx]
mov rcx, QWORD PTR k$[rbp]
call MultiplyAndAdd1Word_using_ADCX_MULX
mov QWORD PTR k$[rbp], rax
; 579 : k = MultiplyAndAdd1Word_using_ADCX_MULX(k, u_buf[23], &u_buf[23]);
mov eax, 8
imul rax, rax, 23
mov rcx, QWORD PTR u_buf$[rbp]
add rcx, rax
mov rax, rcx
mov ecx, 8
imul rcx, rcx, 23
mov r8, rax
mov rax, QWORD PTR u_buf$[rbp]
mov rdx, QWORD PTR [rax+rcx]
mov rcx, QWORD PTR k$[rbp]
call MultiplyAndAdd1Word_using_ADCX_MULX
mov QWORD PTR k$[rbp], rax
; 580 : k = MultiplyAndAdd1Word_using_ADCX_MULX(k, u_buf[24], &u_buf[24]);
mov eax, 8
imul rax, rax, 24
mov rcx, QWORD PTR u_buf$[rbp]
add rcx, rax
mov rax, rcx
mov ecx, 8
imul rcx, rcx, 24
mov r8, rax
mov rax, QWORD PTR u_buf$[rbp]
mov rdx, QWORD PTR [rax+rcx]
mov rcx, QWORD PTR k$[rbp]
call MultiplyAndAdd1Word_using_ADCX_MULX
mov QWORD PTR k$[rbp], rax
; 581 : k = MultiplyAndAdd1Word_using_ADCX_MULX(k, u_buf[25], &u_buf[25]);
mov eax, 8
imul rax, rax, 25
mov rcx, QWORD PTR u_buf$[rbp]
add rcx, rax
mov rax, rcx
mov ecx, 8
imul rcx, rcx, 25
mov r8, rax
mov rax, QWORD PTR u_buf$[rbp]
mov rdx, QWORD PTR [rax+rcx]
mov rcx, QWORD PTR k$[rbp]
call MultiplyAndAdd1Word_using_ADCX_MULX
mov QWORD PTR k$[rbp], rax
; 582 : k = MultiplyAndAdd1Word_using_ADCX_MULX(k, u_buf[26], &u_buf[26]);
mov eax, 8
imul rax, rax, 26
mov rcx, QWORD PTR u_buf$[rbp]
add rcx, rax
mov rax, rcx
mov ecx, 8
imul rcx, rcx, 26
mov r8, rax
mov rax, QWORD PTR u_buf$[rbp]
mov rdx, QWORD PTR [rax+rcx]
mov rcx, QWORD PTR k$[rbp]
call MultiplyAndAdd1Word_using_ADCX_MULX
mov QWORD PTR k$[rbp], rax
; 583 : k = MultiplyAndAdd1Word_using_ADCX_MULX(k, u_buf[27], &u_buf[27]);
mov eax, 8
imul rax, rax, 27
mov rcx, QWORD PTR u_buf$[rbp]
add rcx, rax
mov rax, rcx
mov ecx, 8
imul rcx, rcx, 27
mov r8, rax
mov rax, QWORD PTR u_buf$[rbp]
mov rdx, QWORD PTR [rax+rcx]
mov rcx, QWORD PTR k$[rbp]
call MultiplyAndAdd1Word_using_ADCX_MULX
mov QWORD PTR k$[rbp], rax
; 584 : k = MultiplyAndAdd1Word_using_ADCX_MULX(k, u_buf[28], &u_buf[28]);
mov eax, 8
imul rax, rax, 28
mov rcx, QWORD PTR u_buf$[rbp]
add rcx, rax
mov rax, rcx
mov ecx, 8
imul rcx, rcx, 28
mov r8, rax
mov rax, QWORD PTR u_buf$[rbp]
mov rdx, QWORD PTR [rax+rcx]
mov rcx, QWORD PTR k$[rbp]
call MultiplyAndAdd1Word_using_ADCX_MULX
mov QWORD PTR k$[rbp], rax
; 585 : k = MultiplyAndAdd1Word_using_ADCX_MULX(k, u_buf[29], &u_buf[29]);
mov eax, 8
imul rax, rax, 29
mov rcx, QWORD PTR u_buf$[rbp]
add rcx, rax
mov rax, rcx
mov ecx, 8
imul rcx, rcx, 29
mov r8, rax
mov rax, QWORD PTR u_buf$[rbp]
mov rdx, QWORD PTR [rax+rcx]
mov rcx, QWORD PTR k$[rbp]
call MultiplyAndAdd1Word_using_ADCX_MULX
mov QWORD PTR k$[rbp], rax
; 586 : k = MultiplyAndAdd1Word_using_ADCX_MULX(k, u_buf[30], &u_buf[30]);
mov eax, 8
imul rax, rax, 30
mov rcx, QWORD PTR u_buf$[rbp]
add rcx, rax
mov rax, rcx
mov ecx, 8
imul rcx, rcx, 30
mov r8, rax
mov rax, QWORD PTR u_buf$[rbp]
mov rdx, QWORD PTR [rax+rcx]
mov rcx, QWORD PTR k$[rbp]
call MultiplyAndAdd1Word_using_ADCX_MULX
mov QWORD PTR k$[rbp], rax
; 587 : k = MultiplyAndAdd1Word_using_ADCX_MULX(k, u_buf[31], &u_buf[31]);
mov eax, 8
imul rax, rax, 31
mov rcx, QWORD PTR u_buf$[rbp]
add rcx, rax
mov rax, rcx
mov ecx, 8
imul rcx, rcx, 31
mov r8, rax
mov rax, QWORD PTR u_buf$[rbp]
mov rdx, QWORD PTR [rax+rcx]
mov rcx, QWORD PTR k$[rbp]
call MultiplyAndAdd1Word_using_ADCX_MULX
mov QWORD PTR k$[rbp], rax
; 588 : u_buf += 32;
mov rax, QWORD PTR u_buf$[rbp]
add rax, 256 ; 00000100H
mov QWORD PTR u_buf$[rbp], rax
; 589 : --count;
mov rax, QWORD PTR count$[rbp]
dec rax
mov QWORD PTR count$[rbp], rax
; 590 : #ifdef ENABLED_PERFORMANCE_COUNTER
; 591 : if (sizeof(k) == sizeof(_UINT32_T))
xor eax, eax
test eax, eax
je SHORT $LN4@MultiplyAn
; 592 : AddToMULTI32Counter(32);
mov ecx, 32 ; 00000020H
call AddToMULTI32Counter
jmp SHORT $LN5@MultiplyAn
$LN4@MultiplyAn:
; 593 : else
; 594 : AddToMULTI64Counter(32);
mov ecx, 32 ; 00000020H
call AddToMULTI64Counter
$LN5@MultiplyAn:
; 595 : #endif
; 596 : }
jmp $LN2@MultiplyAn
$LN3@MultiplyAn:
; 597 :
; 598 : if (u_count & 0x10)
mov rax, QWORD PTR u_count$[rbp]
and rax, 16
test rax, rax
je $LN6@MultiplyAn
; 599 : {
; 600 : k = MultiplyAndAdd1Word_using_ADCX_MULX(k, u_buf[0], &u_buf[0]);
mov eax, 8
imul rax, rax, 0
mov rcx, QWORD PTR u_buf$[rbp]
add rcx, rax
mov rax, rcx
mov ecx, 8
imul rcx, rcx, 0
mov r8, rax
mov rax, QWORD PTR u_buf$[rbp]
mov rdx, QWORD PTR [rax+rcx]
mov rcx, QWORD PTR k$[rbp]
call MultiplyAndAdd1Word_using_ADCX_MULX
mov QWORD PTR k$[rbp], rax
; 601 : k = MultiplyAndAdd1Word_using_ADCX_MULX(k, u_buf[1], &u_buf[1]);
mov eax, 8
imul rax, rax, 1
mov rcx, QWORD PTR u_buf$[rbp]
add rcx, rax
mov rax, rcx
mov ecx, 8
imul rcx, rcx, 1
mov r8, rax
mov rax, QWORD PTR u_buf$[rbp]
mov rdx, QWORD PTR [rax+rcx]
mov rcx, QWORD PTR k$[rbp]
call MultiplyAndAdd1Word_using_ADCX_MULX
mov QWORD PTR k$[rbp], rax
; 602 : k = MultiplyAndAdd1Word_using_ADCX_MULX(k, u_buf[2], &u_buf[2]);
mov eax, 8
imul rax, rax, 2
mov rcx, QWORD PTR u_buf$[rbp]
add rcx, rax
mov rax, rcx
mov ecx, 8
imul rcx, rcx, 2
mov r8, rax
mov rax, QWORD PTR u_buf$[rbp]
mov rdx, QWORD PTR [rax+rcx]
mov rcx, QWORD PTR k$[rbp]
call MultiplyAndAdd1Word_using_ADCX_MULX
mov QWORD PTR k$[rbp], rax
; 603 : k = MultiplyAndAdd1Word_using_ADCX_MULX(k, u_buf[3], &u_buf[3]);
mov eax, 8
imul rax, rax, 3
mov rcx, QWORD PTR u_buf$[rbp]
add rcx, rax
mov rax, rcx
mov ecx, 8
imul rcx, rcx, 3
mov r8, rax
mov rax, QWORD PTR u_buf$[rbp]
mov rdx, QWORD PTR [rax+rcx]
mov rcx, QWORD PTR k$[rbp]
call MultiplyAndAdd1Word_using_ADCX_MULX
mov QWORD PTR k$[rbp], rax
; 604 : k = MultiplyAndAdd1Word_using_ADCX_MULX(k, u_buf[4], &u_buf[4]);
mov eax, 8
imul rax, rax, 4
mov rcx, QWORD PTR u_buf$[rbp]
add rcx, rax
mov rax, rcx
mov ecx, 8
imul rcx, rcx, 4
mov r8, rax
mov rax, QWORD PTR u_buf$[rbp]
mov rdx, QWORD PTR [rax+rcx]
mov rcx, QWORD PTR k$[rbp]
call MultiplyAndAdd1Word_using_ADCX_MULX
mov QWORD PTR k$[rbp], rax
; 605 : k = MultiplyAndAdd1Word_using_ADCX_MULX(k, u_buf[5], &u_buf[5]);
mov eax, 8
imul rax, rax, 5
mov rcx, QWORD PTR u_buf$[rbp]
add rcx, rax
mov rax, rcx
mov ecx, 8
imul rcx, rcx, 5
mov r8, rax
mov rax, QWORD PTR u_buf$[rbp]
mov rdx, QWORD PTR [rax+rcx]
mov rcx, QWORD PTR k$[rbp]
call MultiplyAndAdd1Word_using_ADCX_MULX
mov QWORD PTR k$[rbp], rax
; 606 : k = MultiplyAndAdd1Word_using_ADCX_MULX(k, u_buf[6], &u_buf[6]);
mov eax, 8
imul rax, rax, 6
mov rcx, QWORD PTR u_buf$[rbp]
add rcx, rax
mov rax, rcx
mov ecx, 8
imul rcx, rcx, 6
mov r8, rax
mov rax, QWORD PTR u_buf$[rbp]
mov rdx, QWORD PTR [rax+rcx]
mov rcx, QWORD PTR k$[rbp]
call MultiplyAndAdd1Word_using_ADCX_MULX
mov QWORD PTR k$[rbp], rax
; 607 : k = MultiplyAndAdd1Word_using_ADCX_MULX(k, u_buf[7], &u_buf[7]);
mov eax, 8
imul rax, rax, 7
mov rcx, QWORD PTR u_buf$[rbp]
add rcx, rax
mov rax, rcx
mov ecx, 8
imul rcx, rcx, 7
mov r8, rax
mov rax, QWORD PTR u_buf$[rbp]
mov rdx, QWORD PTR [rax+rcx]
mov rcx, QWORD PTR k$[rbp]
call MultiplyAndAdd1Word_using_ADCX_MULX
mov QWORD PTR k$[rbp], rax
; 608 : k = MultiplyAndAdd1Word_using_ADCX_MULX(k, u_buf[8], &u_buf[8]);
mov eax, 8
imul rax, rax, 8
mov rcx, QWORD PTR u_buf$[rbp]
add rcx, rax
mov rax, rcx
mov ecx, 8
imul rcx, rcx, 8
mov r8, rax
mov rax, QWORD PTR u_buf$[rbp]
mov rdx, QWORD PTR [rax+rcx]
mov rcx, QWORD PTR k$[rbp]
call MultiplyAndAdd1Word_using_ADCX_MULX
mov QWORD PTR k$[rbp], rax
; 609 : k = MultiplyAndAdd1Word_using_ADCX_MULX(k, u_buf[9], &u_buf[9]);
mov eax, 8
imul rax, rax, 9
mov rcx, QWORD PTR u_buf$[rbp]
add rcx, rax
mov rax, rcx
mov ecx, 8
imul rcx, rcx, 9
mov r8, rax
mov rax, QWORD PTR u_buf$[rbp]
mov rdx, QWORD PTR [rax+rcx]
mov rcx, QWORD PTR k$[rbp]
call MultiplyAndAdd1Word_using_ADCX_MULX
mov QWORD PTR k$[rbp], rax
; 610 : k = MultiplyAndAdd1Word_using_ADCX_MULX(k, u_buf[10], &u_buf[10]);
mov eax, 8
imul rax, rax, 10
mov rcx, QWORD PTR u_buf$[rbp]
add rcx, rax
mov rax, rcx
mov ecx, 8
imul rcx, rcx, 10
mov r8, rax
mov rax, QWORD PTR u_buf$[rbp]
mov rdx, QWORD PTR [rax+rcx]
mov rcx, QWORD PTR k$[rbp]
call MultiplyAndAdd1Word_using_ADCX_MULX
mov QWORD PTR k$[rbp], rax
; 611 : k = MultiplyAndAdd1Word_using_ADCX_MULX(k, u_buf[11], &u_buf[11]);
mov eax, 8
imul rax, rax, 11
mov rcx, QWORD PTR u_buf$[rbp]
add rcx, rax
mov rax, rcx
mov ecx, 8
imul rcx, rcx, 11
mov r8, rax
mov rax, QWORD PTR u_buf$[rbp]
mov rdx, QWORD PTR [rax+rcx]
mov rcx, QWORD PTR k$[rbp]
call MultiplyAndAdd1Word_using_ADCX_MULX
mov QWORD PTR k$[rbp], rax
; 612 : k = MultiplyAndAdd1Word_using_ADCX_MULX(k, u_buf[12], &u_buf[12]);
mov eax, 8
imul rax, rax, 12
mov rcx, QWORD PTR u_buf$[rbp]
add rcx, rax
mov rax, rcx
mov ecx, 8
imul rcx, rcx, 12
mov r8, rax
mov rax, QWORD PTR u_buf$[rbp]
mov rdx, QWORD PTR [rax+rcx]
mov rcx, QWORD PTR k$[rbp]
call MultiplyAndAdd1Word_using_ADCX_MULX
mov QWORD PTR k$[rbp], rax
; 613 : k = MultiplyAndAdd1Word_using_ADCX_MULX(k, u_buf[13], &u_buf[13]);
mov eax, 8
imul rax, rax, 13
mov rcx, QWORD PTR u_buf$[rbp]
add rcx, rax
mov rax, rcx
mov ecx, 8
imul rcx, rcx, 13
mov r8, rax
mov rax, QWORD PTR u_buf$[rbp]
mov rdx, QWORD PTR [rax+rcx]
mov rcx, QWORD PTR k$[rbp]
call MultiplyAndAdd1Word_using_ADCX_MULX
mov QWORD PTR k$[rbp], rax
; 614 : k = MultiplyAndAdd1Word_using_ADCX_MULX(k, u_buf[14], &u_buf[14]);
mov eax, 8
imul rax, rax, 14
mov rcx, QWORD PTR u_buf$[rbp]
add rcx, rax
mov rax, rcx
mov ecx, 8
imul rcx, rcx, 14
mov r8, rax
mov rax, QWORD PTR u_buf$[rbp]
mov rdx, QWORD PTR [rax+rcx]
mov rcx, QWORD PTR k$[rbp]
call MultiplyAndAdd1Word_using_ADCX_MULX
mov QWORD PTR k$[rbp], rax
; 615 : k = MultiplyAndAdd1Word_using_ADCX_MULX(k, u_buf[15], &u_buf[15]);
mov eax, 8
imul rax, rax, 15
mov rcx, QWORD PTR u_buf$[rbp]
add rcx, rax
mov rax, rcx
mov ecx, 8
imul rcx, rcx, 15
mov r8, rax
mov rax, QWORD PTR u_buf$[rbp]
mov rdx, QWORD PTR [rax+rcx]
mov rcx, QWORD PTR k$[rbp]
call MultiplyAndAdd1Word_using_ADCX_MULX
mov QWORD PTR k$[rbp], rax
; 616 : u_buf += 16;
mov rax, QWORD PTR u_buf$[rbp]
add rax, 128 ; 00000080H
mov QWORD PTR u_buf$[rbp], rax
; 617 : #ifdef ENABLED_PERFORMANCE_COUNTER
; 618 : if (sizeof(k) == sizeof(_UINT32_T))
xor eax, eax
test eax, eax
je SHORT $LN7@MultiplyAn
; 619 : AddToMULTI32Counter(16);
mov ecx, 16
call AddToMULTI32Counter
jmp SHORT $LN8@MultiplyAn
$LN7@MultiplyAn:
; 620 : else
; 621 : AddToMULTI64Counter(16);
mov ecx, 16
call AddToMULTI64Counter
$LN8@MultiplyAn:
$LN6@MultiplyAn:
; 622 : #endif
; 623 : }
; 624 :
; 625 : if (u_count & 0x8)
mov rax, QWORD PTR u_count$[rbp]
and rax, 8
test rax, rax
je $LN9@MultiplyAn
; 626 : {
; 627 : k = MultiplyAndAdd1Word_using_ADCX_MULX(k, u_buf[0], &u_buf[0]);
mov eax, 8
imul rax, rax, 0
mov rcx, QWORD PTR u_buf$[rbp]
add rcx, rax
mov rax, rcx
mov ecx, 8
imul rcx, rcx, 0
mov r8, rax
mov rax, QWORD PTR u_buf$[rbp]
mov rdx, QWORD PTR [rax+rcx]
mov rcx, QWORD PTR k$[rbp]
call MultiplyAndAdd1Word_using_ADCX_MULX
mov QWORD PTR k$[rbp], rax
; 628 : k = MultiplyAndAdd1Word_using_ADCX_MULX(k, u_buf[1], &u_buf[1]);
mov eax, 8
imul rax, rax, 1
mov rcx, QWORD PTR u_buf$[rbp]
add rcx, rax
mov rax, rcx
mov ecx, 8
imul rcx, rcx, 1
mov r8, rax
mov rax, QWORD PTR u_buf$[rbp]
mov rdx, QWORD PTR [rax+rcx]
mov rcx, QWORD PTR k$[rbp]
call MultiplyAndAdd1Word_using_ADCX_MULX
mov QWORD PTR k$[rbp], rax
; 629 : k = MultiplyAndAdd1Word_using_ADCX_MULX(k, u_buf[2], &u_buf[2]);
mov eax, 8
imul rax, rax, 2
mov rcx, QWORD PTR u_buf$[rbp]
add rcx, rax
mov rax, rcx
mov ecx, 8
imul rcx, rcx, 2
mov r8, rax
mov rax, QWORD PTR u_buf$[rbp]
mov rdx, QWORD PTR [rax+rcx]
mov rcx, QWORD PTR k$[rbp]
call MultiplyAndAdd1Word_using_ADCX_MULX
mov QWORD PTR k$[rbp], rax
; 630 : k = MultiplyAndAdd1Word_using_ADCX_MULX(k, u_buf[3], &u_buf[3]);
mov eax, 8
imul rax, rax, 3
mov rcx, QWORD PTR u_buf$[rbp]
add rcx, rax
mov rax, rcx
mov ecx, 8
imul rcx, rcx, 3
mov r8, rax
mov rax, QWORD PTR u_buf$[rbp]
mov rdx, QWORD PTR [rax+rcx]
mov rcx, QWORD PTR k$[rbp]
call MultiplyAndAdd1Word_using_ADCX_MULX
mov QWORD PTR k$[rbp], rax
; 631 : k = MultiplyAndAdd1Word_using_ADCX_MULX(k, u_buf[4], &u_buf[4]);
mov eax, 8
imul rax, rax, 4
mov rcx, QWORD PTR u_buf$[rbp]
add rcx, rax
mov rax, rcx
mov ecx, 8
imul rcx, rcx, 4
mov r8, rax
mov rax, QWORD PTR u_buf$[rbp]
mov rdx, QWORD PTR [rax+rcx]
mov rcx, QWORD PTR k$[rbp]
call MultiplyAndAdd1Word_using_ADCX_MULX
mov QWORD PTR k$[rbp], rax
; 632 : k = MultiplyAndAdd1Word_using_ADCX_MULX(k, u_buf[5], &u_buf[5]);
mov eax, 8
imul rax, rax, 5
mov rcx, QWORD PTR u_buf$[rbp]
add rcx, rax
mov rax, rcx
mov ecx, 8
imul rcx, rcx, 5
mov r8, rax
mov rax, QWORD PTR u_buf$[rbp]
mov rdx, QWORD PTR [rax+rcx]
mov rcx, QWORD PTR k$[rbp]
call MultiplyAndAdd1Word_using_ADCX_MULX
mov QWORD PTR k$[rbp], rax
; 633 : k = MultiplyAndAdd1Word_using_ADCX_MULX(k, u_buf[6], &u_buf[6]);
mov eax, 8
imul rax, rax, 6
mov rcx, QWORD PTR u_buf$[rbp]
add rcx, rax
mov rax, rcx
mov ecx, 8
imul rcx, rcx, 6
mov r8, rax
mov rax, QWORD PTR u_buf$[rbp]
mov rdx, QWORD PTR [rax+rcx]
mov rcx, QWORD PTR k$[rbp]
call MultiplyAndAdd1Word_using_ADCX_MULX
mov QWORD PTR k$[rbp], rax
; 634 : k = MultiplyAndAdd1Word_using_ADCX_MULX(k, u_buf[7], &u_buf[7]);
mov eax, 8
imul rax, rax, 7
mov rcx, QWORD PTR u_buf$[rbp]
add rcx, rax
mov rax, rcx
mov ecx, 8
imul rcx, rcx, 7
mov r8, rax
mov rax, QWORD PTR u_buf$[rbp]
mov rdx, QWORD PTR [rax+rcx]
mov rcx, QWORD PTR k$[rbp]
call MultiplyAndAdd1Word_using_ADCX_MULX
mov QWORD PTR k$[rbp], rax
; 635 : u_buf += 8;
mov rax, QWORD PTR u_buf$[rbp]
add rax, 64 ; 00000040H
mov QWORD PTR u_buf$[rbp], rax
; 636 : #ifdef ENABLED_PERFORMANCE_COUNTER
; 637 : if (sizeof(k) == sizeof(_UINT32_T))
xor eax, eax
test eax, eax
je SHORT $LN10@MultiplyAn
; 638 : AddToMULTI32Counter(8);
mov ecx, 8
call AddToMULTI32Counter
jmp SHORT $LN11@MultiplyAn
$LN10@MultiplyAn:
; 639 : else
; 640 : AddToMULTI64Counter(8);
mov ecx, 8
call AddToMULTI64Counter
$LN11@MultiplyAn:
$LN9@MultiplyAn:
; 641 : #endif
; 642 : }
; 643 :
; 644 : if (u_count & 0x4)
mov rax, QWORD PTR u_count$[rbp]
and rax, 4
test rax, rax
je $LN12@MultiplyAn
; 645 : {
; 646 : k = MultiplyAndAdd1Word_using_ADCX_MULX(k, u_buf[0], &u_buf[0]);
mov eax, 8
imul rax, rax, 0
mov rcx, QWORD PTR u_buf$[rbp]
add rcx, rax
mov rax, rcx
mov ecx, 8
imul rcx, rcx, 0
mov r8, rax
mov rax, QWORD PTR u_buf$[rbp]
mov rdx, QWORD PTR [rax+rcx]
mov rcx, QWORD PTR k$[rbp]
call MultiplyAndAdd1Word_using_ADCX_MULX
mov QWORD PTR k$[rbp], rax
; 647 : k = MultiplyAndAdd1Word_using_ADCX_MULX(k, u_buf[1], &u_buf[1]);
mov eax, 8
imul rax, rax, 1
mov rcx, QWORD PTR u_buf$[rbp]
add rcx, rax
mov rax, rcx
mov ecx, 8
imul rcx, rcx, 1
mov r8, rax
mov rax, QWORD PTR u_buf$[rbp]
mov rdx, QWORD PTR [rax+rcx]
mov rcx, QWORD PTR k$[rbp]
call MultiplyAndAdd1Word_using_ADCX_MULX
mov QWORD PTR k$[rbp], rax
; 648 : k = MultiplyAndAdd1Word_using_ADCX_MULX(k, u_buf[2], &u_buf[2]);
mov eax, 8
imul rax, rax, 2
mov rcx, QWORD PTR u_buf$[rbp]
add rcx, rax
mov rax, rcx
mov ecx, 8
imul rcx, rcx, 2
mov r8, rax
mov rax, QWORD PTR u_buf$[rbp]
mov rdx, QWORD PTR [rax+rcx]
mov rcx, QWORD PTR k$[rbp]
call MultiplyAndAdd1Word_using_ADCX_MULX
mov QWORD PTR k$[rbp], rax
; 649 : k = MultiplyAndAdd1Word_using_ADCX_MULX(k, u_buf[3], &u_buf[3]);
mov eax, 8
imul rax, rax, 3
mov rcx, QWORD PTR u_buf$[rbp]
add rcx, rax
mov rax, rcx
mov ecx, 8
imul rcx, rcx, 3
mov r8, rax
mov rax, QWORD PTR u_buf$[rbp]
mov rdx, QWORD PTR [rax+rcx]
mov rcx, QWORD PTR k$[rbp]
call MultiplyAndAdd1Word_using_ADCX_MULX
mov QWORD PTR k$[rbp], rax
; 650 : u_buf += 4;
mov rax, QWORD PTR u_buf$[rbp]
add rax, 32 ; 00000020H
mov QWORD PTR u_buf$[rbp], rax
; 651 : #ifdef ENABLED_PERFORMANCE_COUNTER
; 652 : if (sizeof(k) == sizeof(_UINT32_T))
xor eax, eax
test eax, eax
je SHORT $LN13@MultiplyAn
; 653 : AddToMULTI32Counter(4);
mov ecx, 4
call AddToMULTI32Counter
jmp SHORT $LN14@MultiplyAn
$LN13@MultiplyAn:
; 654 : else
; 655 : AddToMULTI64Counter(4);
mov ecx, 4
call AddToMULTI64Counter
$LN14@MultiplyAn:
$LN12@MultiplyAn:
; 656 : #endif
; 657 : }
; 658 :
; 659 : if (u_count & 0x2)
mov rax, QWORD PTR u_count$[rbp]
and rax, 2
test rax, rax
je $LN15@MultiplyAn
; 660 : {
; 661 : k = MultiplyAndAdd1Word_using_ADCX_MULX(k, u_buf[0], &u_buf[0]);
mov eax, 8
imul rax, rax, 0
mov rcx, QWORD PTR u_buf$[rbp]
add rcx, rax
mov rax, rcx
mov ecx, 8
imul rcx, rcx, 0
mov r8, rax
mov rax, QWORD PTR u_buf$[rbp]
mov rdx, QWORD PTR [rax+rcx]
mov rcx, QWORD PTR k$[rbp]
call MultiplyAndAdd1Word_using_ADCX_MULX
mov QWORD PTR k$[rbp], rax
; 662 : k = MultiplyAndAdd1Word_using_ADCX_MULX(k, u_buf[1], &u_buf[1]);
mov eax, 8
imul rax, rax, 1
mov rcx, QWORD PTR u_buf$[rbp]
add rcx, rax
mov rax, rcx
mov ecx, 8
imul rcx, rcx, 1
mov r8, rax
mov rax, QWORD PTR u_buf$[rbp]
mov rdx, QWORD PTR [rax+rcx]
mov rcx, QWORD PTR k$[rbp]
call MultiplyAndAdd1Word_using_ADCX_MULX
mov QWORD PTR k$[rbp], rax
; 663 : u_buf += 2;
mov rax, QWORD PTR u_buf$[rbp]
add rax, 16
mov QWORD PTR u_buf$[rbp], rax
; 664 : #ifdef ENABLED_PERFORMANCE_COUNTER
; 665 : if (sizeof(k) == sizeof(_UINT32_T))
xor eax, eax
test eax, eax
je SHORT $LN16@MultiplyAn
; 666 : AddToMULTI32Counter(2);
mov ecx, 2
call AddToMULTI32Counter
jmp SHORT $LN17@MultiplyAn
$LN16@MultiplyAn:
; 667 : else
; 668 : AddToMULTI64Counter(2);
mov ecx, 2
call AddToMULTI64Counter
$LN17@MultiplyAn:
$LN15@MultiplyAn:
; 669 : #endif
; 670 : }
; 671 :
; 672 : if (u_count & 0x1)
mov rax, QWORD PTR u_count$[rbp]
and rax, 1
test rax, rax
je SHORT $LN18@MultiplyAn
; 673 : {
; 674 : k = MultiplyAndAdd1Word_using_ADCX_MULX(k, u_buf[0], &u_buf[0]);
mov eax, 8
imul rax, rax, 0
mov rcx, QWORD PTR u_buf$[rbp]
add rcx, rax
mov rax, rcx
mov ecx, 8
imul rcx, rcx, 0
mov r8, rax
mov rax, QWORD PTR u_buf$[rbp]
mov rdx, QWORD PTR [rax+rcx]
mov rcx, QWORD PTR k$[rbp]
call MultiplyAndAdd1Word_using_ADCX_MULX
mov QWORD PTR k$[rbp], rax
; 675 : u_buf += 1;
mov rax, QWORD PTR u_buf$[rbp]
add rax, 8
mov QWORD PTR u_buf$[rbp], rax
; 676 : #ifdef ENABLED_PERFORMANCE_COUNTER
; 677 : if (sizeof(k) == sizeof(_UINT32_T))
xor eax, eax
test eax, eax
je SHORT $LN19@MultiplyAn
; 678 : IncrementMULTI32Counter();
call IncrementMULTI32Counter
jmp SHORT $LN20@MultiplyAn
$LN19@MultiplyAn:
; 679 : else
; 680 : IncrementMULTI64Counter();
call IncrementMULTI64Counter
$LN20@MultiplyAn:
$LN18@MultiplyAn:
; 681 : #endif
; 682 : }
; 683 :
; 684 : if (k > 0)
cmp QWORD PTR k$[rbp], 0
jbe SHORT $LN21@MultiplyAn
; 685 : {
; 686 : u_buf[0] = k;
mov eax, 8
imul rax, rax, 0
mov rcx, QWORD PTR u_buf$[rbp]
mov rdx, QWORD PTR k$[rbp]
mov QWORD PTR [rcx+rax], rdx
; 687 : u_buf += 1;
mov rax, QWORD PTR u_buf$[rbp]
add rax, 8
mov QWORD PTR u_buf$[rbp], rax
$LN21@MultiplyAn:
; 688 : }
; 689 :
; 690 : return (u_buf);
mov rax, QWORD PTR u_buf$[rbp]
; 691 : }
lea rsp, QWORD PTR [rbp+264]
pop rdi
pop rbp
ret 0
MultiplyAndAdd_using_ADCX_MULX ENDP
_TEXT ENDS
; Function compile flags: /Odtp /RTCsu /ZI
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_parse.c
; COMDAT MultiplyAndAdd_using_ADC_MUL
_TEXT SEGMENT
k$ = 8
count$ = 40
u_buf$ = 288
u_count$ = 296
x$ = 304
MultiplyAndAdd_using_ADC_MUL PROC ; COMDAT
; 408 : {
mov QWORD PTR [rsp+24], r8
mov QWORD PTR [rsp+16], rdx
mov QWORD PTR [rsp+8], rcx
push rbp
push rdi
sub rsp, 296 ; 00000128H
lea rbp, QWORD PTR [rsp+32]
mov rdi, rsp
mov ecx, 74 ; 0000004aH
mov eax, -858993460 ; ccccccccH
rep stosd
mov rcx, QWORD PTR [rsp+328]
lea rcx, OFFSET FLAT:__C5BBD3C1_pmc_parse@c
call __CheckForDebuggerJustMyCode
; 409 : __UNIT_TYPE k = x;
mov rax, QWORD PTR x$[rbp]
mov QWORD PTR k$[rbp], rax
; 410 : __UNIT_TYPE count = u_count >> 5;
mov rax, QWORD PTR u_count$[rbp]
shr rax, 5
mov QWORD PTR count$[rbp], rax
$LN2@MultiplyAn:
; 411 : while (count > 0)
cmp QWORD PTR count$[rbp], 0
jbe $LN3@MultiplyAn
; 412 : {
; 413 : k = MultiplyAndAdd1Word_using_ADC_MUL(k, u_buf[0], &u_buf[0]);
mov eax, 8
imul rax, rax, 0
mov rcx, QWORD PTR u_buf$[rbp]
add rcx, rax
mov rax, rcx
mov ecx, 8
imul rcx, rcx, 0
mov r8, rax
mov rax, QWORD PTR u_buf$[rbp]
mov rdx, QWORD PTR [rax+rcx]
mov rcx, QWORD PTR k$[rbp]
call MultiplyAndAdd1Word_using_ADC_MUL
mov QWORD PTR k$[rbp], rax
; 414 : k = MultiplyAndAdd1Word_using_ADC_MUL(k, u_buf[1], &u_buf[1]);
mov eax, 8
imul rax, rax, 1
mov rcx, QWORD PTR u_buf$[rbp]
add rcx, rax
mov rax, rcx
mov ecx, 8
imul rcx, rcx, 1
mov r8, rax
mov rax, QWORD PTR u_buf$[rbp]
mov rdx, QWORD PTR [rax+rcx]
mov rcx, QWORD PTR k$[rbp]
call MultiplyAndAdd1Word_using_ADC_MUL
mov QWORD PTR k$[rbp], rax
; 415 : k = MultiplyAndAdd1Word_using_ADC_MUL(k, u_buf[2], &u_buf[2]);
mov eax, 8
imul rax, rax, 2
mov rcx, QWORD PTR u_buf$[rbp]
add rcx, rax
mov rax, rcx
mov ecx, 8
imul rcx, rcx, 2
mov r8, rax
mov rax, QWORD PTR u_buf$[rbp]
mov rdx, QWORD PTR [rax+rcx]
mov rcx, QWORD PTR k$[rbp]
call MultiplyAndAdd1Word_using_ADC_MUL
mov QWORD PTR k$[rbp], rax
; 416 : k = MultiplyAndAdd1Word_using_ADC_MUL(k, u_buf[3], &u_buf[3]);
mov eax, 8
imul rax, rax, 3
mov rcx, QWORD PTR u_buf$[rbp]
add rcx, rax
mov rax, rcx
mov ecx, 8
imul rcx, rcx, 3
mov r8, rax
mov rax, QWORD PTR u_buf$[rbp]
mov rdx, QWORD PTR [rax+rcx]
mov rcx, QWORD PTR k$[rbp]
call MultiplyAndAdd1Word_using_ADC_MUL
mov QWORD PTR k$[rbp], rax
; 417 : k = MultiplyAndAdd1Word_using_ADC_MUL(k, u_buf[4], &u_buf[4]);
mov eax, 8
imul rax, rax, 4
mov rcx, QWORD PTR u_buf$[rbp]
add rcx, rax
mov rax, rcx
mov ecx, 8
imul rcx, rcx, 4
mov r8, rax
mov rax, QWORD PTR u_buf$[rbp]
mov rdx, QWORD PTR [rax+rcx]
mov rcx, QWORD PTR k$[rbp]
call MultiplyAndAdd1Word_using_ADC_MUL
mov QWORD PTR k$[rbp], rax
; 418 : k = MultiplyAndAdd1Word_using_ADC_MUL(k, u_buf[5], &u_buf[5]);
mov eax, 8
imul rax, rax, 5
mov rcx, QWORD PTR u_buf$[rbp]
add rcx, rax
mov rax, rcx
mov ecx, 8
imul rcx, rcx, 5
mov r8, rax
mov rax, QWORD PTR u_buf$[rbp]
mov rdx, QWORD PTR [rax+rcx]
mov rcx, QWORD PTR k$[rbp]
call MultiplyAndAdd1Word_using_ADC_MUL
mov QWORD PTR k$[rbp], rax
; 419 : k = MultiplyAndAdd1Word_using_ADC_MUL(k, u_buf[6], &u_buf[6]);
mov eax, 8
imul rax, rax, 6
mov rcx, QWORD PTR u_buf$[rbp]
add rcx, rax
mov rax, rcx
mov ecx, 8
imul rcx, rcx, 6
mov r8, rax
mov rax, QWORD PTR u_buf$[rbp]
mov rdx, QWORD PTR [rax+rcx]
mov rcx, QWORD PTR k$[rbp]
call MultiplyAndAdd1Word_using_ADC_MUL
mov QWORD PTR k$[rbp], rax
; 420 : k = MultiplyAndAdd1Word_using_ADC_MUL(k, u_buf[7], &u_buf[7]);
mov eax, 8
imul rax, rax, 7
mov rcx, QWORD PTR u_buf$[rbp]
add rcx, rax
mov rax, rcx
mov ecx, 8
imul rcx, rcx, 7
mov r8, rax
mov rax, QWORD PTR u_buf$[rbp]
mov rdx, QWORD PTR [rax+rcx]
mov rcx, QWORD PTR k$[rbp]
call MultiplyAndAdd1Word_using_ADC_MUL
mov QWORD PTR k$[rbp], rax
; 421 : k = MultiplyAndAdd1Word_using_ADC_MUL(k, u_buf[8], &u_buf[8]);
mov eax, 8
imul rax, rax, 8
mov rcx, QWORD PTR u_buf$[rbp]
add rcx, rax
mov rax, rcx
mov ecx, 8
imul rcx, rcx, 8
mov r8, rax
mov rax, QWORD PTR u_buf$[rbp]
mov rdx, QWORD PTR [rax+rcx]
mov rcx, QWORD PTR k$[rbp]
call MultiplyAndAdd1Word_using_ADC_MUL
mov QWORD PTR k$[rbp], rax
; 422 : k = MultiplyAndAdd1Word_using_ADC_MUL(k, u_buf[9], &u_buf[9]);
mov eax, 8
imul rax, rax, 9
mov rcx, QWORD PTR u_buf$[rbp]
add rcx, rax
mov rax, rcx
mov ecx, 8
imul rcx, rcx, 9
mov r8, rax
mov rax, QWORD PTR u_buf$[rbp]
mov rdx, QWORD PTR [rax+rcx]
mov rcx, QWORD PTR k$[rbp]
call MultiplyAndAdd1Word_using_ADC_MUL
mov QWORD PTR k$[rbp], rax
; 423 : k = MultiplyAndAdd1Word_using_ADC_MUL(k, u_buf[10], &u_buf[10]);
mov eax, 8
imul rax, rax, 10
mov rcx, QWORD PTR u_buf$[rbp]
add rcx, rax
mov rax, rcx
mov ecx, 8
imul rcx, rcx, 10
mov r8, rax
mov rax, QWORD PTR u_buf$[rbp]
mov rdx, QWORD PTR [rax+rcx]
mov rcx, QWORD PTR k$[rbp]
call MultiplyAndAdd1Word_using_ADC_MUL
mov QWORD PTR k$[rbp], rax
; 424 : k = MultiplyAndAdd1Word_using_ADC_MUL(k, u_buf[11], &u_buf[11]);
mov eax, 8
imul rax, rax, 11
mov rcx, QWORD PTR u_buf$[rbp]
add rcx, rax
mov rax, rcx
mov ecx, 8
imul rcx, rcx, 11
mov r8, rax
mov rax, QWORD PTR u_buf$[rbp]
mov rdx, QWORD PTR [rax+rcx]
mov rcx, QWORD PTR k$[rbp]
call MultiplyAndAdd1Word_using_ADC_MUL
mov QWORD PTR k$[rbp], rax
; 425 : k = MultiplyAndAdd1Word_using_ADC_MUL(k, u_buf[12], &u_buf[12]);
mov eax, 8
imul rax, rax, 12
mov rcx, QWORD PTR u_buf$[rbp]
add rcx, rax
mov rax, rcx
mov ecx, 8
imul rcx, rcx, 12
mov r8, rax
mov rax, QWORD PTR u_buf$[rbp]
mov rdx, QWORD PTR [rax+rcx]
mov rcx, QWORD PTR k$[rbp]
call MultiplyAndAdd1Word_using_ADC_MUL
mov QWORD PTR k$[rbp], rax
; 426 : k = MultiplyAndAdd1Word_using_ADC_MUL(k, u_buf[13], &u_buf[13]);
mov eax, 8
imul rax, rax, 13
mov rcx, QWORD PTR u_buf$[rbp]
add rcx, rax
mov rax, rcx
mov ecx, 8
imul rcx, rcx, 13
mov r8, rax
mov rax, QWORD PTR u_buf$[rbp]
mov rdx, QWORD PTR [rax+rcx]
mov rcx, QWORD PTR k$[rbp]
call MultiplyAndAdd1Word_using_ADC_MUL
mov QWORD PTR k$[rbp], rax
; 427 : k = MultiplyAndAdd1Word_using_ADC_MUL(k, u_buf[14], &u_buf[14]);
mov eax, 8
imul rax, rax, 14
mov rcx, QWORD PTR u_buf$[rbp]
add rcx, rax
mov rax, rcx
mov ecx, 8
imul rcx, rcx, 14
mov r8, rax
mov rax, QWORD PTR u_buf$[rbp]
mov rdx, QWORD PTR [rax+rcx]
mov rcx, QWORD PTR k$[rbp]
call MultiplyAndAdd1Word_using_ADC_MUL
mov QWORD PTR k$[rbp], rax
; 428 : k = MultiplyAndAdd1Word_using_ADC_MUL(k, u_buf[15], &u_buf[15]);
mov eax, 8
imul rax, rax, 15
mov rcx, QWORD PTR u_buf$[rbp]
add rcx, rax
mov rax, rcx
mov ecx, 8
imul rcx, rcx, 15
mov r8, rax
mov rax, QWORD PTR u_buf$[rbp]
mov rdx, QWORD PTR [rax+rcx]
mov rcx, QWORD PTR k$[rbp]
call MultiplyAndAdd1Word_using_ADC_MUL
mov QWORD PTR k$[rbp], rax
; 429 : k = MultiplyAndAdd1Word_using_ADC_MUL(k, u_buf[16], &u_buf[16]);
mov eax, 8
imul rax, rax, 16
mov rcx, QWORD PTR u_buf$[rbp]
add rcx, rax
mov rax, rcx
mov ecx, 8
imul rcx, rcx, 16
mov r8, rax
mov rax, QWORD PTR u_buf$[rbp]
mov rdx, QWORD PTR [rax+rcx]
mov rcx, QWORD PTR k$[rbp]
call MultiplyAndAdd1Word_using_ADC_MUL
mov QWORD PTR k$[rbp], rax
; 430 : k = MultiplyAndAdd1Word_using_ADC_MUL(k, u_buf[17], &u_buf[17]);
mov eax, 8
imul rax, rax, 17
mov rcx, QWORD PTR u_buf$[rbp]
add rcx, rax
mov rax, rcx
mov ecx, 8
imul rcx, rcx, 17
mov r8, rax
mov rax, QWORD PTR u_buf$[rbp]
mov rdx, QWORD PTR [rax+rcx]
mov rcx, QWORD PTR k$[rbp]
call MultiplyAndAdd1Word_using_ADC_MUL
mov QWORD PTR k$[rbp], rax
; 431 : k = MultiplyAndAdd1Word_using_ADC_MUL(k, u_buf[18], &u_buf[18]);
mov eax, 8
imul rax, rax, 18
mov rcx, QWORD PTR u_buf$[rbp]
add rcx, rax
mov rax, rcx
mov ecx, 8
imul rcx, rcx, 18
mov r8, rax
mov rax, QWORD PTR u_buf$[rbp]
mov rdx, QWORD PTR [rax+rcx]
mov rcx, QWORD PTR k$[rbp]
call MultiplyAndAdd1Word_using_ADC_MUL
mov QWORD PTR k$[rbp], rax
; 432 : k = MultiplyAndAdd1Word_using_ADC_MUL(k, u_buf[19], &u_buf[19]);
mov eax, 8
imul rax, rax, 19
mov rcx, QWORD PTR u_buf$[rbp]
add rcx, rax
mov rax, rcx
mov ecx, 8
imul rcx, rcx, 19
mov r8, rax
mov rax, QWORD PTR u_buf$[rbp]
mov rdx, QWORD PTR [rax+rcx]
mov rcx, QWORD PTR k$[rbp]
call MultiplyAndAdd1Word_using_ADC_MUL
mov QWORD PTR k$[rbp], rax
; 433 : k = MultiplyAndAdd1Word_using_ADC_MUL(k, u_buf[20], &u_buf[20]);
mov eax, 8
imul rax, rax, 20
mov rcx, QWORD PTR u_buf$[rbp]
add rcx, rax
mov rax, rcx
mov ecx, 8
imul rcx, rcx, 20
mov r8, rax
mov rax, QWORD PTR u_buf$[rbp]
mov rdx, QWORD PTR [rax+rcx]
mov rcx, QWORD PTR k$[rbp]
call MultiplyAndAdd1Word_using_ADC_MUL
mov QWORD PTR k$[rbp], rax
; 434 : k = MultiplyAndAdd1Word_using_ADC_MUL(k, u_buf[21], &u_buf[21]);
mov eax, 8
imul rax, rax, 21
mov rcx, QWORD PTR u_buf$[rbp]
add rcx, rax
mov rax, rcx
mov ecx, 8
imul rcx, rcx, 21
mov r8, rax
mov rax, QWORD PTR u_buf$[rbp]
mov rdx, QWORD PTR [rax+rcx]
mov rcx, QWORD PTR k$[rbp]
call MultiplyAndAdd1Word_using_ADC_MUL
mov QWORD PTR k$[rbp], rax
; 435 : k = MultiplyAndAdd1Word_using_ADC_MUL(k, u_buf[22], &u_buf[22]);
mov eax, 8
imul rax, rax, 22
mov rcx, QWORD PTR u_buf$[rbp]
add rcx, rax
mov rax, rcx
mov ecx, 8
imul rcx, rcx, 22
mov r8, rax
mov rax, QWORD PTR u_buf$[rbp]
mov rdx, QWORD PTR [rax+rcx]
mov rcx, QWORD PTR k$[rbp]
call MultiplyAndAdd1Word_using_ADC_MUL
mov QWORD PTR k$[rbp], rax
; 436 : k = MultiplyAndAdd1Word_using_ADC_MUL(k, u_buf[23], &u_buf[23]);
mov eax, 8
imul rax, rax, 23
mov rcx, QWORD PTR u_buf$[rbp]
add rcx, rax
mov rax, rcx
mov ecx, 8
imul rcx, rcx, 23
mov r8, rax
mov rax, QWORD PTR u_buf$[rbp]
mov rdx, QWORD PTR [rax+rcx]
mov rcx, QWORD PTR k$[rbp]
call MultiplyAndAdd1Word_using_ADC_MUL
mov QWORD PTR k$[rbp], rax
; 437 : k = MultiplyAndAdd1Word_using_ADC_MUL(k, u_buf[24], &u_buf[24]);
mov eax, 8
imul rax, rax, 24
mov rcx, QWORD PTR u_buf$[rbp]
add rcx, rax
mov rax, rcx
mov ecx, 8
imul rcx, rcx, 24
mov r8, rax
mov rax, QWORD PTR u_buf$[rbp]
mov rdx, QWORD PTR [rax+rcx]
mov rcx, QWORD PTR k$[rbp]
call MultiplyAndAdd1Word_using_ADC_MUL
mov QWORD PTR k$[rbp], rax
; 438 : k = MultiplyAndAdd1Word_using_ADC_MUL(k, u_buf[25], &u_buf[25]);
mov eax, 8
imul rax, rax, 25
mov rcx, QWORD PTR u_buf$[rbp]
add rcx, rax
mov rax, rcx
mov ecx, 8
imul rcx, rcx, 25
mov r8, rax
mov rax, QWORD PTR u_buf$[rbp]
mov rdx, QWORD PTR [rax+rcx]
mov rcx, QWORD PTR k$[rbp]
call MultiplyAndAdd1Word_using_ADC_MUL
mov QWORD PTR k$[rbp], rax
; 439 : k = MultiplyAndAdd1Word_using_ADC_MUL(k, u_buf[26], &u_buf[26]);
mov eax, 8
imul rax, rax, 26
mov rcx, QWORD PTR u_buf$[rbp]
add rcx, rax
mov rax, rcx
mov ecx, 8
imul rcx, rcx, 26
mov r8, rax
mov rax, QWORD PTR u_buf$[rbp]
mov rdx, QWORD PTR [rax+rcx]
mov rcx, QWORD PTR k$[rbp]
call MultiplyAndAdd1Word_using_ADC_MUL
mov QWORD PTR k$[rbp], rax
; 440 : k = MultiplyAndAdd1Word_using_ADC_MUL(k, u_buf[27], &u_buf[27]);
mov eax, 8
imul rax, rax, 27
mov rcx, QWORD PTR u_buf$[rbp]
add rcx, rax
mov rax, rcx
mov ecx, 8
imul rcx, rcx, 27
mov r8, rax
mov rax, QWORD PTR u_buf$[rbp]
mov rdx, QWORD PTR [rax+rcx]
mov rcx, QWORD PTR k$[rbp]
call MultiplyAndAdd1Word_using_ADC_MUL
mov QWORD PTR k$[rbp], rax
; 441 : k = MultiplyAndAdd1Word_using_ADC_MUL(k, u_buf[28], &u_buf[28]);
mov eax, 8
imul rax, rax, 28
mov rcx, QWORD PTR u_buf$[rbp]
add rcx, rax
mov rax, rcx
mov ecx, 8
imul rcx, rcx, 28
mov r8, rax
mov rax, QWORD PTR u_buf$[rbp]
mov rdx, QWORD PTR [rax+rcx]
mov rcx, QWORD PTR k$[rbp]
call MultiplyAndAdd1Word_using_ADC_MUL
mov QWORD PTR k$[rbp], rax
; 442 : k = MultiplyAndAdd1Word_using_ADC_MUL(k, u_buf[29], &u_buf[29]);
mov eax, 8
imul rax, rax, 29
mov rcx, QWORD PTR u_buf$[rbp]
add rcx, rax
mov rax, rcx
mov ecx, 8
imul rcx, rcx, 29
mov r8, rax
mov rax, QWORD PTR u_buf$[rbp]
mov rdx, QWORD PTR [rax+rcx]
mov rcx, QWORD PTR k$[rbp]
call MultiplyAndAdd1Word_using_ADC_MUL
mov QWORD PTR k$[rbp], rax
; 443 : k = MultiplyAndAdd1Word_using_ADC_MUL(k, u_buf[30], &u_buf[30]);
mov eax, 8
imul rax, rax, 30
mov rcx, QWORD PTR u_buf$[rbp]
add rcx, rax
mov rax, rcx
mov ecx, 8
imul rcx, rcx, 30
mov r8, rax
mov rax, QWORD PTR u_buf$[rbp]
mov rdx, QWORD PTR [rax+rcx]
mov rcx, QWORD PTR k$[rbp]
call MultiplyAndAdd1Word_using_ADC_MUL
mov QWORD PTR k$[rbp], rax
; 444 : k = MultiplyAndAdd1Word_using_ADC_MUL(k, u_buf[31], &u_buf[31]);
mov eax, 8
imul rax, rax, 31
mov rcx, QWORD PTR u_buf$[rbp]
add rcx, rax
mov rax, rcx
mov ecx, 8
imul rcx, rcx, 31
mov r8, rax
mov rax, QWORD PTR u_buf$[rbp]
mov rdx, QWORD PTR [rax+rcx]
mov rcx, QWORD PTR k$[rbp]
call MultiplyAndAdd1Word_using_ADC_MUL
mov QWORD PTR k$[rbp], rax
; 445 : u_buf += 32;
mov rax, QWORD PTR u_buf$[rbp]
add rax, 256 ; 00000100H
mov QWORD PTR u_buf$[rbp], rax
; 446 : --count;
mov rax, QWORD PTR count$[rbp]
dec rax
mov QWORD PTR count$[rbp], rax
; 447 : #ifdef ENABLED_PERFORMANCE_COUNTER
; 448 : if (sizeof(k) == sizeof(_UINT32_T))
xor eax, eax
test eax, eax
je SHORT $LN4@MultiplyAn
; 449 : AddToMULTI32Counter(32);
mov ecx, 32 ; 00000020H
call AddToMULTI32Counter
jmp SHORT $LN5@MultiplyAn
$LN4@MultiplyAn:
; 450 : else
; 451 : AddToMULTI64Counter(32);
mov ecx, 32 ; 00000020H
call AddToMULTI64Counter
$LN5@MultiplyAn:
; 452 : #endif
; 453 : }
jmp $LN2@MultiplyAn
$LN3@MultiplyAn:
; 454 :
; 455 : if (u_count & 0x10)
mov rax, QWORD PTR u_count$[rbp]
and rax, 16
test rax, rax
je $LN6@MultiplyAn
; 456 : {
; 457 : k = MultiplyAndAdd1Word_using_ADC_MUL(k, u_buf[0], &u_buf[0]);
mov eax, 8
imul rax, rax, 0
mov rcx, QWORD PTR u_buf$[rbp]
add rcx, rax
mov rax, rcx
mov ecx, 8
imul rcx, rcx, 0
mov r8, rax
mov rax, QWORD PTR u_buf$[rbp]
mov rdx, QWORD PTR [rax+rcx]
mov rcx, QWORD PTR k$[rbp]
call MultiplyAndAdd1Word_using_ADC_MUL
mov QWORD PTR k$[rbp], rax
; 458 : k = MultiplyAndAdd1Word_using_ADC_MUL(k, u_buf[1], &u_buf[1]);
mov eax, 8
imul rax, rax, 1
mov rcx, QWORD PTR u_buf$[rbp]
add rcx, rax
mov rax, rcx
mov ecx, 8
imul rcx, rcx, 1
mov r8, rax
mov rax, QWORD PTR u_buf$[rbp]
mov rdx, QWORD PTR [rax+rcx]
mov rcx, QWORD PTR k$[rbp]
call MultiplyAndAdd1Word_using_ADC_MUL
mov QWORD PTR k$[rbp], rax
; 459 : k = MultiplyAndAdd1Word_using_ADC_MUL(k, u_buf[2], &u_buf[2]);
mov eax, 8
imul rax, rax, 2
mov rcx, QWORD PTR u_buf$[rbp]
add rcx, rax
mov rax, rcx
mov ecx, 8
imul rcx, rcx, 2
mov r8, rax
mov rax, QWORD PTR u_buf$[rbp]
mov rdx, QWORD PTR [rax+rcx]
mov rcx, QWORD PTR k$[rbp]
call MultiplyAndAdd1Word_using_ADC_MUL
mov QWORD PTR k$[rbp], rax
; 460 : k = MultiplyAndAdd1Word_using_ADC_MUL(k, u_buf[3], &u_buf[3]);
mov eax, 8
imul rax, rax, 3
mov rcx, QWORD PTR u_buf$[rbp]
add rcx, rax
mov rax, rcx
mov ecx, 8
imul rcx, rcx, 3
mov r8, rax
mov rax, QWORD PTR u_buf$[rbp]
mov rdx, QWORD PTR [rax+rcx]
mov rcx, QWORD PTR k$[rbp]
call MultiplyAndAdd1Word_using_ADC_MUL
mov QWORD PTR k$[rbp], rax
; 461 : k = MultiplyAndAdd1Word_using_ADC_MUL(k, u_buf[4], &u_buf[4]);
mov eax, 8
imul rax, rax, 4
mov rcx, QWORD PTR u_buf$[rbp]
add rcx, rax
mov rax, rcx
mov ecx, 8
imul rcx, rcx, 4
mov r8, rax
mov rax, QWORD PTR u_buf$[rbp]
mov rdx, QWORD PTR [rax+rcx]
mov rcx, QWORD PTR k$[rbp]
call MultiplyAndAdd1Word_using_ADC_MUL
mov QWORD PTR k$[rbp], rax
; 462 : k = MultiplyAndAdd1Word_using_ADC_MUL(k, u_buf[5], &u_buf[5]);
mov eax, 8
imul rax, rax, 5
mov rcx, QWORD PTR u_buf$[rbp]
add rcx, rax
mov rax, rcx
mov ecx, 8
imul rcx, rcx, 5
mov r8, rax
mov rax, QWORD PTR u_buf$[rbp]
mov rdx, QWORD PTR [rax+rcx]
mov rcx, QWORD PTR k$[rbp]
call MultiplyAndAdd1Word_using_ADC_MUL
mov QWORD PTR k$[rbp], rax
; 463 : k = MultiplyAndAdd1Word_using_ADC_MUL(k, u_buf[6], &u_buf[6]);
mov eax, 8
imul rax, rax, 6
mov rcx, QWORD PTR u_buf$[rbp]
add rcx, rax
mov rax, rcx
mov ecx, 8
imul rcx, rcx, 6
mov r8, rax
mov rax, QWORD PTR u_buf$[rbp]
mov rdx, QWORD PTR [rax+rcx]
mov rcx, QWORD PTR k$[rbp]
call MultiplyAndAdd1Word_using_ADC_MUL
mov QWORD PTR k$[rbp], rax
; 464 : k = MultiplyAndAdd1Word_using_ADC_MUL(k, u_buf[7], &u_buf[7]);
mov eax, 8
imul rax, rax, 7
mov rcx, QWORD PTR u_buf$[rbp]
add rcx, rax
mov rax, rcx
mov ecx, 8
imul rcx, rcx, 7
mov r8, rax
mov rax, QWORD PTR u_buf$[rbp]
mov rdx, QWORD PTR [rax+rcx]
mov rcx, QWORD PTR k$[rbp]
call MultiplyAndAdd1Word_using_ADC_MUL
mov QWORD PTR k$[rbp], rax
; 465 : k = MultiplyAndAdd1Word_using_ADC_MUL(k, u_buf[8], &u_buf[8]);
mov eax, 8
imul rax, rax, 8
mov rcx, QWORD PTR u_buf$[rbp]
add rcx, rax
mov rax, rcx
mov ecx, 8
imul rcx, rcx, 8
mov r8, rax
mov rax, QWORD PTR u_buf$[rbp]
mov rdx, QWORD PTR [rax+rcx]
mov rcx, QWORD PTR k$[rbp]
call MultiplyAndAdd1Word_using_ADC_MUL
mov QWORD PTR k$[rbp], rax
; 466 : k = MultiplyAndAdd1Word_using_ADC_MUL(k, u_buf[9], &u_buf[9]);
mov eax, 8
imul rax, rax, 9
mov rcx, QWORD PTR u_buf$[rbp]
add rcx, rax
mov rax, rcx
mov ecx, 8
imul rcx, rcx, 9
mov r8, rax
mov rax, QWORD PTR u_buf$[rbp]
mov rdx, QWORD PTR [rax+rcx]
mov rcx, QWORD PTR k$[rbp]
call MultiplyAndAdd1Word_using_ADC_MUL
mov QWORD PTR k$[rbp], rax
; 467 : k = MultiplyAndAdd1Word_using_ADC_MUL(k, u_buf[10], &u_buf[10]);
mov eax, 8
imul rax, rax, 10
mov rcx, QWORD PTR u_buf$[rbp]
add rcx, rax
mov rax, rcx
mov ecx, 8
imul rcx, rcx, 10
mov r8, rax
mov rax, QWORD PTR u_buf$[rbp]
mov rdx, QWORD PTR [rax+rcx]
mov rcx, QWORD PTR k$[rbp]
call MultiplyAndAdd1Word_using_ADC_MUL
mov QWORD PTR k$[rbp], rax
; 468 : k = MultiplyAndAdd1Word_using_ADC_MUL(k, u_buf[11], &u_buf[11]);
mov eax, 8
imul rax, rax, 11
mov rcx, QWORD PTR u_buf$[rbp]
add rcx, rax
mov rax, rcx
mov ecx, 8
imul rcx, rcx, 11
mov r8, rax
mov rax, QWORD PTR u_buf$[rbp]
mov rdx, QWORD PTR [rax+rcx]
mov rcx, QWORD PTR k$[rbp]
call MultiplyAndAdd1Word_using_ADC_MUL
mov QWORD PTR k$[rbp], rax
; 469 : k = MultiplyAndAdd1Word_using_ADC_MUL(k, u_buf[12], &u_buf[12]);
mov eax, 8
imul rax, rax, 12
mov rcx, QWORD PTR u_buf$[rbp]
add rcx, rax
mov rax, rcx
mov ecx, 8
imul rcx, rcx, 12
mov r8, rax
mov rax, QWORD PTR u_buf$[rbp]
mov rdx, QWORD PTR [rax+rcx]
mov rcx, QWORD PTR k$[rbp]
call MultiplyAndAdd1Word_using_ADC_MUL
mov QWORD PTR k$[rbp], rax
; 470 : k = MultiplyAndAdd1Word_using_ADC_MUL(k, u_buf[13], &u_buf[13]);
mov eax, 8
imul rax, rax, 13
mov rcx, QWORD PTR u_buf$[rbp]
add rcx, rax
mov rax, rcx
mov ecx, 8
imul rcx, rcx, 13
mov r8, rax
mov rax, QWORD PTR u_buf$[rbp]
mov rdx, QWORD PTR [rax+rcx]
mov rcx, QWORD PTR k$[rbp]
call MultiplyAndAdd1Word_using_ADC_MUL
mov QWORD PTR k$[rbp], rax
; 471 : k = MultiplyAndAdd1Word_using_ADC_MUL(k, u_buf[14], &u_buf[14]);
mov eax, 8
imul rax, rax, 14
mov rcx, QWORD PTR u_buf$[rbp]
add rcx, rax
mov rax, rcx
mov ecx, 8
imul rcx, rcx, 14
mov r8, rax
mov rax, QWORD PTR u_buf$[rbp]
mov rdx, QWORD PTR [rax+rcx]
mov rcx, QWORD PTR k$[rbp]
call MultiplyAndAdd1Word_using_ADC_MUL
mov QWORD PTR k$[rbp], rax
; 472 : k = MultiplyAndAdd1Word_using_ADC_MUL(k, u_buf[15], &u_buf[15]);
mov eax, 8
imul rax, rax, 15
mov rcx, QWORD PTR u_buf$[rbp]
add rcx, rax
mov rax, rcx
mov ecx, 8
imul rcx, rcx, 15
mov r8, rax
mov rax, QWORD PTR u_buf$[rbp]
mov rdx, QWORD PTR [rax+rcx]
mov rcx, QWORD PTR k$[rbp]
call MultiplyAndAdd1Word_using_ADC_MUL
mov QWORD PTR k$[rbp], rax
; 473 : u_buf += 16;
mov rax, QWORD PTR u_buf$[rbp]
add rax, 128 ; 00000080H
mov QWORD PTR u_buf$[rbp], rax
; 474 : #ifdef ENABLED_PERFORMANCE_COUNTER
; 475 : if (sizeof(k) == sizeof(_UINT32_T))
xor eax, eax
test eax, eax
je SHORT $LN7@MultiplyAn
; 476 : AddToMULTI32Counter(16);
mov ecx, 16
call AddToMULTI32Counter
jmp SHORT $LN8@MultiplyAn
$LN7@MultiplyAn:
; 477 : else
; 478 : AddToMULTI64Counter(16);
mov ecx, 16
call AddToMULTI64Counter
$LN8@MultiplyAn:
$LN6@MultiplyAn:
; 479 : #endif
; 480 : }
; 481 :
; 482 : if (u_count & 0x8)
mov rax, QWORD PTR u_count$[rbp]
and rax, 8
test rax, rax
je $LN9@MultiplyAn
; 483 : {
; 484 : k = MultiplyAndAdd1Word_using_ADC_MUL(k, u_buf[0], &u_buf[0]);
mov eax, 8
imul rax, rax, 0
mov rcx, QWORD PTR u_buf$[rbp]
add rcx, rax
mov rax, rcx
mov ecx, 8
imul rcx, rcx, 0
mov r8, rax
mov rax, QWORD PTR u_buf$[rbp]
mov rdx, QWORD PTR [rax+rcx]
mov rcx, QWORD PTR k$[rbp]
call MultiplyAndAdd1Word_using_ADC_MUL
mov QWORD PTR k$[rbp], rax
; 485 : k = MultiplyAndAdd1Word_using_ADC_MUL(k, u_buf[1], &u_buf[1]);
mov eax, 8
imul rax, rax, 1
mov rcx, QWORD PTR u_buf$[rbp]
add rcx, rax
mov rax, rcx
mov ecx, 8
imul rcx, rcx, 1
mov r8, rax
mov rax, QWORD PTR u_buf$[rbp]
mov rdx, QWORD PTR [rax+rcx]
mov rcx, QWORD PTR k$[rbp]
call MultiplyAndAdd1Word_using_ADC_MUL
mov QWORD PTR k$[rbp], rax
; 486 : k = MultiplyAndAdd1Word_using_ADC_MUL(k, u_buf[2], &u_buf[2]);
mov eax, 8
imul rax, rax, 2
mov rcx, QWORD PTR u_buf$[rbp]
add rcx, rax
mov rax, rcx
mov ecx, 8
imul rcx, rcx, 2
mov r8, rax
mov rax, QWORD PTR u_buf$[rbp]
mov rdx, QWORD PTR [rax+rcx]
mov rcx, QWORD PTR k$[rbp]
call MultiplyAndAdd1Word_using_ADC_MUL
mov QWORD PTR k$[rbp], rax
; 487 : k = MultiplyAndAdd1Word_using_ADC_MUL(k, u_buf[3], &u_buf[3]);
mov eax, 8
imul rax, rax, 3
mov rcx, QWORD PTR u_buf$[rbp]
add rcx, rax
mov rax, rcx
mov ecx, 8
imul rcx, rcx, 3
mov r8, rax
mov rax, QWORD PTR u_buf$[rbp]
mov rdx, QWORD PTR [rax+rcx]
mov rcx, QWORD PTR k$[rbp]
call MultiplyAndAdd1Word_using_ADC_MUL
mov QWORD PTR k$[rbp], rax
; 488 : k = MultiplyAndAdd1Word_using_ADC_MUL(k, u_buf[4], &u_buf[4]);
mov eax, 8
imul rax, rax, 4
mov rcx, QWORD PTR u_buf$[rbp]
add rcx, rax
mov rax, rcx
mov ecx, 8
imul rcx, rcx, 4
mov r8, rax
mov rax, QWORD PTR u_buf$[rbp]
mov rdx, QWORD PTR [rax+rcx]
mov rcx, QWORD PTR k$[rbp]
call MultiplyAndAdd1Word_using_ADC_MUL
mov QWORD PTR k$[rbp], rax
; 489 : k = MultiplyAndAdd1Word_using_ADC_MUL(k, u_buf[5], &u_buf[5]);
mov eax, 8
imul rax, rax, 5
mov rcx, QWORD PTR u_buf$[rbp]
add rcx, rax
mov rax, rcx
mov ecx, 8
imul rcx, rcx, 5
mov r8, rax
mov rax, QWORD PTR u_buf$[rbp]
mov rdx, QWORD PTR [rax+rcx]
mov rcx, QWORD PTR k$[rbp]
call MultiplyAndAdd1Word_using_ADC_MUL
mov QWORD PTR k$[rbp], rax
; 490 : k = MultiplyAndAdd1Word_using_ADC_MUL(k, u_buf[6], &u_buf[6]);
mov eax, 8
imul rax, rax, 6
mov rcx, QWORD PTR u_buf$[rbp]
add rcx, rax
mov rax, rcx
mov ecx, 8
imul rcx, rcx, 6
mov r8, rax
mov rax, QWORD PTR u_buf$[rbp]
mov rdx, QWORD PTR [rax+rcx]
mov rcx, QWORD PTR k$[rbp]
call MultiplyAndAdd1Word_using_ADC_MUL
mov QWORD PTR k$[rbp], rax
; 491 : k = MultiplyAndAdd1Word_using_ADC_MUL(k, u_buf[7], &u_buf[7]);
mov eax, 8
imul rax, rax, 7
mov rcx, QWORD PTR u_buf$[rbp]
add rcx, rax
mov rax, rcx
mov ecx, 8
imul rcx, rcx, 7
mov r8, rax
mov rax, QWORD PTR u_buf$[rbp]
mov rdx, QWORD PTR [rax+rcx]
mov rcx, QWORD PTR k$[rbp]
call MultiplyAndAdd1Word_using_ADC_MUL
mov QWORD PTR k$[rbp], rax
; 492 : u_buf += 8;
mov rax, QWORD PTR u_buf$[rbp]
add rax, 64 ; 00000040H
mov QWORD PTR u_buf$[rbp], rax
; 493 : #ifdef ENABLED_PERFORMANCE_COUNTER
; 494 : if (sizeof(k) == sizeof(_UINT32_T))
xor eax, eax
test eax, eax
je SHORT $LN10@MultiplyAn
; 495 : AddToMULTI32Counter(8);
mov ecx, 8
call AddToMULTI32Counter
jmp SHORT $LN11@MultiplyAn
$LN10@MultiplyAn:
; 496 : else
; 497 : AddToMULTI64Counter(8);
mov ecx, 8
call AddToMULTI64Counter
$LN11@MultiplyAn:
$LN9@MultiplyAn:
; 498 : #endif
; 499 : }
; 500 :
; 501 : if (u_count & 0x4)
mov rax, QWORD PTR u_count$[rbp]
and rax, 4
test rax, rax
je $LN12@MultiplyAn
; 502 : {
; 503 : k = MultiplyAndAdd1Word_using_ADC_MUL(k, u_buf[0], &u_buf[0]);
mov eax, 8
imul rax, rax, 0
mov rcx, QWORD PTR u_buf$[rbp]
add rcx, rax
mov rax, rcx
mov ecx, 8
imul rcx, rcx, 0
mov r8, rax
mov rax, QWORD PTR u_buf$[rbp]
mov rdx, QWORD PTR [rax+rcx]
mov rcx, QWORD PTR k$[rbp]
call MultiplyAndAdd1Word_using_ADC_MUL
mov QWORD PTR k$[rbp], rax
; 504 : k = MultiplyAndAdd1Word_using_ADC_MUL(k, u_buf[1], &u_buf[1]);
mov eax, 8
imul rax, rax, 1
mov rcx, QWORD PTR u_buf$[rbp]
add rcx, rax
mov rax, rcx
mov ecx, 8
imul rcx, rcx, 1
mov r8, rax
mov rax, QWORD PTR u_buf$[rbp]
mov rdx, QWORD PTR [rax+rcx]
mov rcx, QWORD PTR k$[rbp]
call MultiplyAndAdd1Word_using_ADC_MUL
mov QWORD PTR k$[rbp], rax
; 505 : k = MultiplyAndAdd1Word_using_ADC_MUL(k, u_buf[2], &u_buf[2]);
mov eax, 8
imul rax, rax, 2
mov rcx, QWORD PTR u_buf$[rbp]
add rcx, rax
mov rax, rcx
mov ecx, 8
imul rcx, rcx, 2
mov r8, rax
mov rax, QWORD PTR u_buf$[rbp]
mov rdx, QWORD PTR [rax+rcx]
mov rcx, QWORD PTR k$[rbp]
call MultiplyAndAdd1Word_using_ADC_MUL
mov QWORD PTR k$[rbp], rax
; 506 : k = MultiplyAndAdd1Word_using_ADC_MUL(k, u_buf[3], &u_buf[3]);
mov eax, 8
imul rax, rax, 3
mov rcx, QWORD PTR u_buf$[rbp]
add rcx, rax
mov rax, rcx
mov ecx, 8
imul rcx, rcx, 3
mov r8, rax
mov rax, QWORD PTR u_buf$[rbp]
mov rdx, QWORD PTR [rax+rcx]
mov rcx, QWORD PTR k$[rbp]
call MultiplyAndAdd1Word_using_ADC_MUL
mov QWORD PTR k$[rbp], rax
; 507 : u_buf += 4;
mov rax, QWORD PTR u_buf$[rbp]
add rax, 32 ; 00000020H
mov QWORD PTR u_buf$[rbp], rax
; 508 : #ifdef ENABLED_PERFORMANCE_COUNTER
; 509 : if (sizeof(k) == sizeof(_UINT32_T))
xor eax, eax
test eax, eax
je SHORT $LN13@MultiplyAn
; 510 : AddToMULTI32Counter(4);
mov ecx, 4
call AddToMULTI32Counter
jmp SHORT $LN14@MultiplyAn
$LN13@MultiplyAn:
; 511 : else
; 512 : AddToMULTI64Counter(4);
mov ecx, 4
call AddToMULTI64Counter
$LN14@MultiplyAn:
$LN12@MultiplyAn:
; 513 : #endif
; 514 : }
; 515 :
; 516 : if (u_count & 0x2)
mov rax, QWORD PTR u_count$[rbp]
and rax, 2
test rax, rax
je $LN15@MultiplyAn
; 517 : {
; 518 : k = MultiplyAndAdd1Word_using_ADC_MUL(k, u_buf[0], &u_buf[0]);
mov eax, 8
imul rax, rax, 0
mov rcx, QWORD PTR u_buf$[rbp]
add rcx, rax
mov rax, rcx
mov ecx, 8
imul rcx, rcx, 0
mov r8, rax
mov rax, QWORD PTR u_buf$[rbp]
mov rdx, QWORD PTR [rax+rcx]
mov rcx, QWORD PTR k$[rbp]
call MultiplyAndAdd1Word_using_ADC_MUL
mov QWORD PTR k$[rbp], rax
; 519 : k = MultiplyAndAdd1Word_using_ADC_MUL(k, u_buf[1], &u_buf[1]);
mov eax, 8
imul rax, rax, 1
mov rcx, QWORD PTR u_buf$[rbp]
add rcx, rax
mov rax, rcx
mov ecx, 8
imul rcx, rcx, 1
mov r8, rax
mov rax, QWORD PTR u_buf$[rbp]
mov rdx, QWORD PTR [rax+rcx]
mov rcx, QWORD PTR k$[rbp]
call MultiplyAndAdd1Word_using_ADC_MUL
mov QWORD PTR k$[rbp], rax
; 520 : u_buf += 2;
mov rax, QWORD PTR u_buf$[rbp]
add rax, 16
mov QWORD PTR u_buf$[rbp], rax
; 521 : #ifdef ENABLED_PERFORMANCE_COUNTER
; 522 : if (sizeof(k) == sizeof(_UINT32_T))
xor eax, eax
test eax, eax
je SHORT $LN16@MultiplyAn
; 523 : AddToMULTI32Counter(2);
mov ecx, 2
call AddToMULTI32Counter
jmp SHORT $LN17@MultiplyAn
$LN16@MultiplyAn:
; 524 : else
; 525 : AddToMULTI64Counter(2);
mov ecx, 2
call AddToMULTI64Counter
$LN17@MultiplyAn:
$LN15@MultiplyAn:
; 526 : #endif
; 527 : }
; 528 :
; 529 : if (u_count & 0x1)
mov rax, QWORD PTR u_count$[rbp]
and rax, 1
test rax, rax
je SHORT $LN18@MultiplyAn
; 530 : {
; 531 : k = MultiplyAndAdd1Word_using_ADC_MUL(k, u_buf[0], &u_buf[0]);
mov eax, 8
imul rax, rax, 0
mov rcx, QWORD PTR u_buf$[rbp]
add rcx, rax
mov rax, rcx
mov ecx, 8
imul rcx, rcx, 0
mov r8, rax
mov rax, QWORD PTR u_buf$[rbp]
mov rdx, QWORD PTR [rax+rcx]
mov rcx, QWORD PTR k$[rbp]
call MultiplyAndAdd1Word_using_ADC_MUL
mov QWORD PTR k$[rbp], rax
; 532 : u_buf += 1;
mov rax, QWORD PTR u_buf$[rbp]
add rax, 8
mov QWORD PTR u_buf$[rbp], rax
; 533 : #ifdef ENABLED_PERFORMANCE_COUNTER
; 534 : if (sizeof(k) == sizeof(_UINT32_T))
xor eax, eax
test eax, eax
je SHORT $LN19@MultiplyAn
; 535 : IncrementMULTI32Counter();
call IncrementMULTI32Counter
jmp SHORT $LN20@MultiplyAn
$LN19@MultiplyAn:
; 536 : else
; 537 : IncrementMULTI64Counter();
call IncrementMULTI64Counter
$LN20@MultiplyAn:
$LN18@MultiplyAn:
; 538 : #endif
; 539 : }
; 540 :
; 541 : if (k > 0)
cmp QWORD PTR k$[rbp], 0
jbe SHORT $LN21@MultiplyAn
; 542 : {
; 543 : u_buf[0] = k;
mov eax, 8
imul rax, rax, 0
mov rcx, QWORD PTR u_buf$[rbp]
mov rdx, QWORD PTR k$[rbp]
mov QWORD PTR [rcx+rax], rdx
; 544 : u_buf += 1;
mov rax, QWORD PTR u_buf$[rbp]
add rax, 8
mov QWORD PTR u_buf$[rbp], rax
$LN21@MultiplyAn:
; 545 : }
; 546 :
; 547 : return (u_buf);
mov rax, QWORD PTR u_buf$[rbp]
; 548 : }
lea rsp, QWORD PTR [rbp+264]
pop rdi
pop rbp
ret 0
MultiplyAndAdd_using_ADC_MUL ENDP
_TEXT ENDS
; Function compile flags: /Odtp /RTCsu /ZI
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_parse.c
; COMDAT MultiplyAndAdd1Word_using_ADCX_MULX
_TEXT SEGMENT
base_value$ = 8
t_hi$ = 40
t_lo$ = 72
k$ = 320
u$ = 328
w_buf$ = 336
MultiplyAndAdd1Word_using_ADCX_MULX PROC ; COMDAT
; 393 : {
mov QWORD PTR [rsp+24], r8
mov QWORD PTR [rsp+16], rdx
mov QWORD PTR [rsp+8], rcx
push rbp
push rdi
sub rsp, 328 ; 00000148H
lea rbp, QWORD PTR [rsp+32]
mov rdi, rsp
mov ecx, 82 ; 00000052H
mov eax, -858993460 ; ccccccccH
rep stosd
mov rcx, QWORD PTR [rsp+360]
lea rcx, OFFSET FLAT:__C5BBD3C1_pmc_parse@c
call __CheckForDebuggerJustMyCode
; 394 : #ifdef _M_IX86
; 395 : __UNIT_TYPE base_value = 1000000000U; // 10^9
; 396 : #elif defined(_M_IX64)
; 397 : __UNIT_TYPE base_value = 10000000000000000000UL; // 10^19
mov rax, -8446744073709551616 ; 8ac7230489e80000H
mov QWORD PTR base_value$[rbp], rax
; 398 : #else
; 399 : #error unknown platform
; 400 : #endif
; 401 : __UNIT_TYPE t_hi;
; 402 : __UNIT_TYPE t_lo = _MULTIPLYX_UNIT(u, base_value, &t_hi);
lea r8, QWORD PTR t_hi$[rbp]
mov rdx, QWORD PTR base_value$[rbp]
mov rcx, QWORD PTR u$[rbp]
call _MULTIPLYX_UNIT
mov QWORD PTR t_lo$[rbp], rax
; 403 : _ADDX_UNIT(_ADDX_UNIT(0, t_lo, k, w_buf), t_hi, 0, &k);
mov r9, QWORD PTR w_buf$[rbp]
mov r8, QWORD PTR k$[rbp]
mov rdx, QWORD PTR t_lo$[rbp]
xor ecx, ecx
call _ADDX_UNIT
lea r9, QWORD PTR k$[rbp]
xor r8d, r8d
mov rdx, QWORD PTR t_hi$[rbp]
movzx ecx, al
call _ADDX_UNIT
; 404 : return (k);
mov rax, QWORD PTR k$[rbp]
; 405 : }
mov rdi, rax
lea rcx, QWORD PTR [rbp-32]
lea rdx, OFFSET FLAT:MultiplyAndAdd1Word_using_ADCX_MULX$rtcFrameData
call _RTC_CheckStackVars
mov rax, rdi
lea rsp, QWORD PTR [rbp+296]
pop rdi
pop rbp
ret 0
MultiplyAndAdd1Word_using_ADCX_MULX ENDP
_TEXT ENDS
; Function compile flags: /Odtp /RTCsu /ZI
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_parse.c
; COMDAT MultiplyAndAdd1Word_using_ADC_MUL
_TEXT SEGMENT
base_value$ = 8
t_hi$ = 40
t_lo$ = 72
k$ = 320
u$ = 328
w_buf$ = 336
MultiplyAndAdd1Word_using_ADC_MUL PROC ; COMDAT
; 378 : {
mov QWORD PTR [rsp+24], r8
mov QWORD PTR [rsp+16], rdx
mov QWORD PTR [rsp+8], rcx
push rbp
push rdi
sub rsp, 328 ; 00000148H
lea rbp, QWORD PTR [rsp+32]
mov rdi, rsp
mov ecx, 82 ; 00000052H
mov eax, -858993460 ; ccccccccH
rep stosd
mov rcx, QWORD PTR [rsp+360]
lea rcx, OFFSET FLAT:__C5BBD3C1_pmc_parse@c
call __CheckForDebuggerJustMyCode
; 379 : #ifdef _M_IX86
; 380 : __UNIT_TYPE base_value = 1000000000U; // 10^9
; 381 : #elif defined(_M_IX64)
; 382 : __UNIT_TYPE base_value = 10000000000000000000UL; // 10^19
mov rax, -8446744073709551616 ; 8ac7230489e80000H
mov QWORD PTR base_value$[rbp], rax
; 383 : #else
; 384 : #error unknown platform
; 385 : #endif
; 386 : __UNIT_TYPE t_hi;
; 387 : __UNIT_TYPE t_lo = _MULTIPLY_UNIT(u, base_value, &t_hi);
lea r8, QWORD PTR t_hi$[rbp]
mov rdx, QWORD PTR base_value$[rbp]
mov rcx, QWORD PTR u$[rbp]
call _MULTIPLY_UNIT
mov QWORD PTR t_lo$[rbp], rax
; 388 : _ADD_UNIT(_ADD_UNIT(0, t_lo, k, w_buf), t_hi, 0, &k);
mov r9, QWORD PTR w_buf$[rbp]
mov r8, QWORD PTR k$[rbp]
mov rdx, QWORD PTR t_lo$[rbp]
xor ecx, ecx
call _ADD_UNIT
lea r9, QWORD PTR k$[rbp]
xor r8d, r8d
mov rdx, QWORD PTR t_hi$[rbp]
movzx ecx, al
call _ADD_UNIT
; 389 : return (k);
mov rax, QWORD PTR k$[rbp]
; 390 : }
mov rdi, rax
lea rcx, QWORD PTR [rbp-32]
lea rdx, OFFSET FLAT:MultiplyAndAdd1Word_using_ADC_MUL$rtcFrameData
call _RTC_CheckStackVars
mov rax, rdi
lea rsp, QWORD PTR [rbp+296]
pop rdi
pop rbp
ret 0
MultiplyAndAdd1Word_using_ADC_MUL ENDP
_TEXT ENDS
; Function compile flags: /Odtp /RTCsu /ZI
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_parse.c
; COMDAT BuildBinaryFromDecimalString
_TEXT SEGMENT
word_digit_count$ = 4
in_ptr$ = 40
out_ptr$ = 72
source_count$ = 104
r$ = 132
tv67 = 344
source$ = 384
out_buf$ = 392
out_buf_count$ = 400
BuildBinaryFromDecimalString PROC ; COMDAT
; 350 : {
mov QWORD PTR [rsp+24], r8
mov QWORD PTR [rsp+16], rdx
mov QWORD PTR [rsp+8], rcx
push rbp
push rdi
sub rsp, 392 ; 00000188H
lea rbp, QWORD PTR [rsp+32]
mov rdi, rsp
mov ecx, 98 ; 00000062H
mov eax, -858993460 ; ccccccccH
rep stosd
mov rcx, QWORD PTR [rsp+424]
lea rcx, OFFSET FLAT:__C5BBD3C1_pmc_parse@c
call __CheckForDebuggerJustMyCode
; 351 : #ifdef _M_IX86
; 352 : int word_digit_count = 9;
; 353 : #elif defined(_M_IX64)
; 354 : int word_digit_count = 19;
mov DWORD PTR word_digit_count$[rbp], 19
; 355 : #else
; 356 : #error unknown platform
; 357 : #endif
; 358 : wchar_t* in_ptr = source;
mov rax, QWORD PTR source$[rbp]
mov QWORD PTR in_ptr$[rbp], rax
; 359 : __UNIT_TYPE* out_ptr = out_buf;
mov rax, QWORD PTR out_buf$[rbp]
mov QWORD PTR out_ptr$[rbp], rax
; 360 : __UNIT_TYPE source_count = lstrlenW(source);
mov rcx, QWORD PTR source$[rbp]
call QWORD PTR __imp_lstrlenW
cdqe
mov QWORD PTR source_count$[rbp], rax
; 361 : int r = source_count % word_digit_count;
movsxd rax, DWORD PTR word_digit_count$[rbp]
mov QWORD PTR tv67[rbp], rax
xor edx, edx
mov rax, QWORD PTR source_count$[rbp]
mov rcx, QWORD PTR tv67[rbp]
div rcx
mov rax, rdx
mov DWORD PTR r$[rbp], eax
; 362 : if (r > 0)
cmp DWORD PTR r$[rbp], 0
jle SHORT $LN4@BuildBinar
; 363 : {
; 364 : *out_ptr++ = BuildLeading1WordFromDecimalString(in_ptr, r);
movsxd rax, DWORD PTR r$[rbp]
mov rdx, rax
mov rcx, QWORD PTR in_ptr$[rbp]
call BuildLeading1WordFromDecimalString
mov rcx, QWORD PTR out_ptr$[rbp]
mov QWORD PTR [rcx], rax
mov rax, QWORD PTR out_ptr$[rbp]
add rax, 8
mov QWORD PTR out_ptr$[rbp], rax
; 365 : in_ptr += r;
movsxd rax, DWORD PTR r$[rbp]
mov rcx, QWORD PTR in_ptr$[rbp]
lea rax, QWORD PTR [rcx+rax*2]
mov QWORD PTR in_ptr$[rbp], rax
; 366 : source_count -= r;
movsxd rax, DWORD PTR r$[rbp]
mov rcx, QWORD PTR source_count$[rbp]
sub rcx, rax
mov rax, rcx
mov QWORD PTR source_count$[rbp], rax
$LN4@BuildBinar:
$LN2@BuildBinar:
; 367 : }
; 368 : while (source_count > 0)
cmp QWORD PTR source_count$[rbp], 0
jbe SHORT $LN3@BuildBinar
; 369 : {
; 370 : *out_ptr++ = Build1WordFromDecimalString(in_ptr);
mov rcx, QWORD PTR in_ptr$[rbp]
call Build1WordFromDecimalString
mov rcx, QWORD PTR out_ptr$[rbp]
mov QWORD PTR [rcx], rax
mov rax, QWORD PTR out_ptr$[rbp]
add rax, 8
mov QWORD PTR out_ptr$[rbp], rax
; 371 : in_ptr += word_digit_count;
movsxd rax, DWORD PTR word_digit_count$[rbp]
mov rcx, QWORD PTR in_ptr$[rbp]
lea rax, QWORD PTR [rcx+rax*2]
mov QWORD PTR in_ptr$[rbp], rax
; 372 : source_count -= word_digit_count;
movsxd rax, DWORD PTR word_digit_count$[rbp]
mov rcx, QWORD PTR source_count$[rbp]
sub rcx, rax
mov rax, rcx
mov QWORD PTR source_count$[rbp], rax
; 373 : }
jmp SHORT $LN2@BuildBinar
$LN3@BuildBinar:
; 374 : *out_buf_count = out_ptr - out_buf;
mov rax, QWORD PTR out_buf$[rbp]
mov rcx, QWORD PTR out_ptr$[rbp]
sub rcx, rax
mov rax, rcx
sar rax, 3
mov rcx, QWORD PTR out_buf_count$[rbp]
mov QWORD PTR [rcx], rax
; 375 : }
lea rsp, QWORD PTR [rbp+360]
pop rdi
pop rbp
ret 0
BuildBinaryFromDecimalString ENDP
_TEXT ENDS
; Function compile flags: /Odtp /RTCsu /ZI
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_parse.c
; COMDAT Build1WordFromDecimalString
_TEXT SEGMENT
x$ = 8
in_ptr$ = 256
Build1WordFromDecimalString PROC ; COMDAT
; 313 : {
mov QWORD PTR [rsp+8], rcx
push rbp
push rdi
sub rsp, 264 ; 00000108H
lea rbp, QWORD PTR [rsp+32]
mov rdi, rsp
mov ecx, 66 ; 00000042H
mov eax, -858993460 ; ccccccccH
rep stosd
mov rcx, QWORD PTR [rsp+296]
lea rcx, OFFSET FLAT:__C5BBD3C1_pmc_parse@c
call __CheckForDebuggerJustMyCode
; 314 : __UNIT_TYPE x = (*in_ptr++ - L'0');
mov rax, QWORD PTR in_ptr$[rbp]
movzx eax, WORD PTR [rax]
sub eax, 48 ; 00000030H
cdqe
mov QWORD PTR x$[rbp], rax
mov rax, QWORD PTR in_ptr$[rbp]
add rax, 2
mov QWORD PTR in_ptr$[rbp], rax
; 315 : if (sizeof(__UNIT_TYPE) >= sizeof(_UINT64_T))
xor eax, eax
cmp eax, 1
je $LN2@Build1Word
; 316 : {
; 317 : x = x * 10 + (*in_ptr++ - L'0');
imul rax, QWORD PTR x$[rbp], 10
mov rcx, QWORD PTR in_ptr$[rbp]
movzx ecx, WORD PTR [rcx]
sub ecx, 48 ; 00000030H
movsxd rcx, ecx
add rax, rcx
mov QWORD PTR x$[rbp], rax
mov rax, QWORD PTR in_ptr$[rbp]
add rax, 2
mov QWORD PTR in_ptr$[rbp], rax
; 318 : x = x * 10 + (*in_ptr++ - L'0');
imul rax, QWORD PTR x$[rbp], 10
mov rcx, QWORD PTR in_ptr$[rbp]
movzx ecx, WORD PTR [rcx]
sub ecx, 48 ; 00000030H
movsxd rcx, ecx
add rax, rcx
mov QWORD PTR x$[rbp], rax
mov rax, QWORD PTR in_ptr$[rbp]
add rax, 2
mov QWORD PTR in_ptr$[rbp], rax
; 319 : x = x * 10 + (*in_ptr++ - L'0');
imul rax, QWORD PTR x$[rbp], 10
mov rcx, QWORD PTR in_ptr$[rbp]
movzx ecx, WORD PTR [rcx]
sub ecx, 48 ; 00000030H
movsxd rcx, ecx
add rax, rcx
mov QWORD PTR x$[rbp], rax
mov rax, QWORD PTR in_ptr$[rbp]
add rax, 2
mov QWORD PTR in_ptr$[rbp], rax
; 320 : x = x * 10 + (*in_ptr++ - L'0');
imul rax, QWORD PTR x$[rbp], 10
mov rcx, QWORD PTR in_ptr$[rbp]
movzx ecx, WORD PTR [rcx]
sub ecx, 48 ; 00000030H
movsxd rcx, ecx
add rax, rcx
mov QWORD PTR x$[rbp], rax
mov rax, QWORD PTR in_ptr$[rbp]
add rax, 2
mov QWORD PTR in_ptr$[rbp], rax
; 321 : x = x * 10 + (*in_ptr++ - L'0');
imul rax, QWORD PTR x$[rbp], 10
mov rcx, QWORD PTR in_ptr$[rbp]
movzx ecx, WORD PTR [rcx]
sub ecx, 48 ; 00000030H
movsxd rcx, ecx
add rax, rcx
mov QWORD PTR x$[rbp], rax
mov rax, QWORD PTR in_ptr$[rbp]
add rax, 2
mov QWORD PTR in_ptr$[rbp], rax
; 322 : x = x * 10 + (*in_ptr++ - L'0');
imul rax, QWORD PTR x$[rbp], 10
mov rcx, QWORD PTR in_ptr$[rbp]
movzx ecx, WORD PTR [rcx]
sub ecx, 48 ; 00000030H
movsxd rcx, ecx
add rax, rcx
mov QWORD PTR x$[rbp], rax
mov rax, QWORD PTR in_ptr$[rbp]
add rax, 2
mov QWORD PTR in_ptr$[rbp], rax
; 323 : x = x * 10 + (*in_ptr++ - L'0');
imul rax, QWORD PTR x$[rbp], 10
mov rcx, QWORD PTR in_ptr$[rbp]
movzx ecx, WORD PTR [rcx]
sub ecx, 48 ; 00000030H
movsxd rcx, ecx
add rax, rcx
mov QWORD PTR x$[rbp], rax
mov rax, QWORD PTR in_ptr$[rbp]
add rax, 2
mov QWORD PTR in_ptr$[rbp], rax
; 324 : x = x * 10 + (*in_ptr++ - L'0');
imul rax, QWORD PTR x$[rbp], 10
mov rcx, QWORD PTR in_ptr$[rbp]
movzx ecx, WORD PTR [rcx]
sub ecx, 48 ; 00000030H
movsxd rcx, ecx
add rax, rcx
mov QWORD PTR x$[rbp], rax
mov rax, QWORD PTR in_ptr$[rbp]
add rax, 2
mov QWORD PTR in_ptr$[rbp], rax
; 325 : x = x * 10 + (*in_ptr++ - L'0');
imul rax, QWORD PTR x$[rbp], 10
mov rcx, QWORD PTR in_ptr$[rbp]
movzx ecx, WORD PTR [rcx]
sub ecx, 48 ; 00000030H
movsxd rcx, ecx
add rax, rcx
mov QWORD PTR x$[rbp], rax
mov rax, QWORD PTR in_ptr$[rbp]
add rax, 2
mov QWORD PTR in_ptr$[rbp], rax
; 326 : x = x * 10 + (*in_ptr++ - L'0');
imul rax, QWORD PTR x$[rbp], 10
mov rcx, QWORD PTR in_ptr$[rbp]
movzx ecx, WORD PTR [rcx]
sub ecx, 48 ; 00000030H
movsxd rcx, ecx
add rax, rcx
mov QWORD PTR x$[rbp], rax
mov rax, QWORD PTR in_ptr$[rbp]
add rax, 2
mov QWORD PTR in_ptr$[rbp], rax
$LN2@Build1Word:
; 327 : }
; 328 : if (sizeof(__UNIT_TYPE) >= sizeof(_UINT32_T))
xor eax, eax
cmp eax, 1
je $LN3@Build1Word
; 329 : {
; 330 : x = x * 10 + (*in_ptr++ - L'0');
imul rax, QWORD PTR x$[rbp], 10
mov rcx, QWORD PTR in_ptr$[rbp]
movzx ecx, WORD PTR [rcx]
sub ecx, 48 ; 00000030H
movsxd rcx, ecx
add rax, rcx
mov QWORD PTR x$[rbp], rax
mov rax, QWORD PTR in_ptr$[rbp]
add rax, 2
mov QWORD PTR in_ptr$[rbp], rax
; 331 : x = x * 10 + (*in_ptr++ - L'0');
imul rax, QWORD PTR x$[rbp], 10
mov rcx, QWORD PTR in_ptr$[rbp]
movzx ecx, WORD PTR [rcx]
sub ecx, 48 ; 00000030H
movsxd rcx, ecx
add rax, rcx
mov QWORD PTR x$[rbp], rax
mov rax, QWORD PTR in_ptr$[rbp]
add rax, 2
mov QWORD PTR in_ptr$[rbp], rax
; 332 : x = x * 10 + (*in_ptr++ - L'0');
imul rax, QWORD PTR x$[rbp], 10
mov rcx, QWORD PTR in_ptr$[rbp]
movzx ecx, WORD PTR [rcx]
sub ecx, 48 ; 00000030H
movsxd rcx, ecx
add rax, rcx
mov QWORD PTR x$[rbp], rax
mov rax, QWORD PTR in_ptr$[rbp]
add rax, 2
mov QWORD PTR in_ptr$[rbp], rax
; 333 : x = x * 10 + (*in_ptr++ - L'0');
imul rax, QWORD PTR x$[rbp], 10
mov rcx, QWORD PTR in_ptr$[rbp]
movzx ecx, WORD PTR [rcx]
sub ecx, 48 ; 00000030H
movsxd rcx, ecx
add rax, rcx
mov QWORD PTR x$[rbp], rax
mov rax, QWORD PTR in_ptr$[rbp]
add rax, 2
mov QWORD PTR in_ptr$[rbp], rax
; 334 : x = x * 10 + (*in_ptr++ - L'0');
imul rax, QWORD PTR x$[rbp], 10
mov rcx, QWORD PTR in_ptr$[rbp]
movzx ecx, WORD PTR [rcx]
sub ecx, 48 ; 00000030H
movsxd rcx, ecx
add rax, rcx
mov QWORD PTR x$[rbp], rax
mov rax, QWORD PTR in_ptr$[rbp]
add rax, 2
mov QWORD PTR in_ptr$[rbp], rax
$LN3@Build1Word:
; 335 : }
; 336 : if (sizeof(__UNIT_TYPE) >= sizeof(_UINT16_T))
xor eax, eax
cmp eax, 1
je SHORT $LN4@Build1Word
; 337 : {
; 338 : x = x * 10 + (*in_ptr++ - L'0');
imul rax, QWORD PTR x$[rbp], 10
mov rcx, QWORD PTR in_ptr$[rbp]
movzx ecx, WORD PTR [rcx]
sub ecx, 48 ; 00000030H
movsxd rcx, ecx
add rax, rcx
mov QWORD PTR x$[rbp], rax
mov rax, QWORD PTR in_ptr$[rbp]
add rax, 2
mov QWORD PTR in_ptr$[rbp], rax
; 339 : x = x * 10 + (*in_ptr++ - L'0');
imul rax, QWORD PTR x$[rbp], 10
mov rcx, QWORD PTR in_ptr$[rbp]
movzx ecx, WORD PTR [rcx]
sub ecx, 48 ; 00000030H
movsxd rcx, ecx
add rax, rcx
mov QWORD PTR x$[rbp], rax
mov rax, QWORD PTR in_ptr$[rbp]
add rax, 2
mov QWORD PTR in_ptr$[rbp], rax
$LN4@Build1Word:
; 340 : }
; 341 : if (sizeof(__UNIT_TYPE) >= sizeof(_BYTE_T))
xor eax, eax
cmp eax, 1
je SHORT $LN5@Build1Word
; 342 : {
; 343 : x = x * 10 + (*in_ptr++ - L'0');
imul rax, QWORD PTR x$[rbp], 10
mov rcx, QWORD PTR in_ptr$[rbp]
movzx ecx, WORD PTR [rcx]
sub ecx, 48 ; 00000030H
movsxd rcx, ecx
add rax, rcx
mov QWORD PTR x$[rbp], rax
mov rax, QWORD PTR in_ptr$[rbp]
add rax, 2
mov QWORD PTR in_ptr$[rbp], rax
$LN5@Build1Word:
; 344 : }
; 345 : return (x);
mov rax, QWORD PTR x$[rbp]
; 346 : }
lea rsp, QWORD PTR [rbp+232]
pop rdi
pop rbp
ret 0
Build1WordFromDecimalString ENDP
_TEXT ENDS
; Function compile flags: /Odtp /RTCsu /ZI
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_parse.c
; COMDAT BuildLeading1WordFromDecimalString
_TEXT SEGMENT
x$ = 8
in_ptr$ = 256
count$ = 264
BuildLeading1WordFromDecimalString PROC ; COMDAT
; 302 : {
mov QWORD PTR [rsp+16], rdx
mov QWORD PTR [rsp+8], rcx
push rbp
push rdi
sub rsp, 264 ; 00000108H
lea rbp, QWORD PTR [rsp+32]
mov rdi, rsp
mov ecx, 66 ; 00000042H
mov eax, -858993460 ; ccccccccH
rep stosd
mov rcx, QWORD PTR [rsp+296]
lea rcx, OFFSET FLAT:__C5BBD3C1_pmc_parse@c
call __CheckForDebuggerJustMyCode
; 303 : __UNIT_TYPE x = 0;
mov QWORD PTR x$[rbp], 0
$LN2@BuildLeadi:
; 304 : while (count > 0)
cmp QWORD PTR count$[rbp], 0
jbe SHORT $LN3@BuildLeadi
; 305 : {
; 306 : x = x * 10 + (*in_ptr++ - L'0');
imul rax, QWORD PTR x$[rbp], 10
mov rcx, QWORD PTR in_ptr$[rbp]
movzx ecx, WORD PTR [rcx]
sub ecx, 48 ; 00000030H
movsxd rcx, ecx
add rax, rcx
mov QWORD PTR x$[rbp], rax
mov rax, QWORD PTR in_ptr$[rbp]
add rax, 2
mov QWORD PTR in_ptr$[rbp], rax
; 307 : --count;
mov rax, QWORD PTR count$[rbp]
dec rax
mov QWORD PTR count$[rbp], rax
; 308 : }
jmp SHORT $LN2@BuildLeadi
$LN3@BuildLeadi:
; 309 : return (x);
mov rax, QWORD PTR x$[rbp]
; 310 : }
lea rsp, QWORD PTR [rbp+232]
pop rdi
pop rbp
ret 0
BuildLeading1WordFromDecimalString ENDP
_TEXT ENDS
; Function compile flags: /Odtp /RTCsu /ZI
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_parse.c
; COMDAT ParseAsHexNumberString
_TEXT SEGMENT
state$ = 16
__$ArrayPad$ = 312
in_ptr$ = 352
number_styles$ = 360
format_option$ = 368
int_part_buf$ = 376
ParseAsHexNumberString PROC ; COMDAT
; 287 : {
mov QWORD PTR [rsp+32], r9
mov QWORD PTR [rsp+24], r8
mov DWORD PTR [rsp+16], edx
mov QWORD PTR [rsp+8], rcx
push rbp
push rdi
sub rsp, 376 ; 00000178H
lea rbp, QWORD PTR [rsp+48]
mov rdi, rsp
mov ecx, 94 ; 0000005eH
mov eax, -858993460 ; ccccccccH
rep stosd
mov rcx, QWORD PTR [rsp+408]
mov rax, QWORD PTR __security_cookie
xor rax, rbp
mov QWORD PTR __$ArrayPad$[rbp], rax
lea rcx, OFFSET FLAT:__C5BBD3C1_pmc_parse@c
call __CheckForDebuggerJustMyCode
; 288 : struct __tag_PARSER_STATE state;
; 289 : InitializeParserState(&state, in_ptr, number_styles, format_option, int_part_buf, NULL);
mov QWORD PTR [rsp+40], 0
mov rax, QWORD PTR int_part_buf$[rbp]
mov QWORD PTR [rsp+32], rax
mov r9, QWORD PTR format_option$[rbp]
mov r8d, DWORD PTR number_styles$[rbp]
mov rdx, QWORD PTR in_ptr$[rbp]
lea rcx, QWORD PTR state$[rbp]
call InitializeParserState
; 290 : if (number_styles & PMC_NUMBER_STYLE_ALLOW_LEADING_WHITE)
mov eax, DWORD PTR number_styles$[rbp]
and eax, 1
test eax, eax
je SHORT $LN2@ParseAsHex
; 291 : SkipSpace(&state);
lea rcx, QWORD PTR state$[rbp]
call SkipSpace
$LN2@ParseAsHex:
; 292 : ParseAsIntegerPartNumberSequence(&state);
lea rcx, QWORD PTR state$[rbp]
call ParseAsIntegerPartNumberSequence
; 293 : if (number_styles & PMC_NUMBER_STYLE_ALLOW_TRAILING_WHITE)
mov eax, DWORD PTR number_styles$[rbp]
and eax, 2
test eax, eax
je SHORT $LN3@ParseAsHex
; 294 : SkipSpace(&state);
lea rcx, QWORD PTR state$[rbp]
call SkipSpace
$LN3@ParseAsHex:
; 295 : if (*state.IN_PTR != L'\0')
mov rax, QWORD PTR state$[rbp]
movzx eax, WORD PTR [rax]
test eax, eax
je SHORT $LN4@ParseAsHex
; 296 : return (0);
xor eax, eax
jmp SHORT $LN1@ParseAsHex
$LN4@ParseAsHex:
; 297 : FinalizeParserState(&state);
lea rcx, QWORD PTR state$[rbp]
call FinalizeParserState
; 298 : return (1);
mov eax, 1
$LN1@ParseAsHex:
; 299 : }
mov rdi, rax
lea rcx, QWORD PTR [rbp-48]
lea rdx, OFFSET FLAT:ParseAsHexNumberString$rtcFrameData
call _RTC_CheckStackVars
mov rax, rdi
mov rcx, QWORD PTR __$ArrayPad$[rbp]
xor rcx, rbp
call __security_check_cookie
lea rsp, QWORD PTR [rbp+328]
pop rdi
pop rbp
ret 0
ParseAsHexNumberString ENDP
_TEXT ENDS
; Function compile flags: /Odtp /RTCsu /ZI
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_parse.c
; COMDAT ParseAsDecimalNumberString
_TEXT SEGMENT
state$ = 16
__$ArrayPad$ = 312
in_ptr$ = 352
number_styles$ = 360
format_option$ = 368
sign$ = 376
int_part_buf$ = 384
frac_part_buf$ = 392
ParseAsDecimalNumberString PROC ; COMDAT
; 190 : {
mov QWORD PTR [rsp+32], r9
mov QWORD PTR [rsp+24], r8
mov DWORD PTR [rsp+16], edx
mov QWORD PTR [rsp+8], rcx
push rbp
push rdi
sub rsp, 376 ; 00000178H
lea rbp, QWORD PTR [rsp+48]
mov rdi, rsp
mov ecx, 94 ; 0000005eH
mov eax, -858993460 ; ccccccccH
rep stosd
mov rcx, QWORD PTR [rsp+408]
mov rax, QWORD PTR __security_cookie
xor rax, rbp
mov QWORD PTR __$ArrayPad$[rbp], rax
lea rcx, OFFSET FLAT:__C5BBD3C1_pmc_parse@c
call __CheckForDebuggerJustMyCode
; 191 : struct __tag_PARSER_STATE state;
; 192 : InitializeParserState(&state, in_ptr, number_styles, format_option, int_part_buf, frac_part_buf);
mov rax, QWORD PTR frac_part_buf$[rbp]
mov QWORD PTR [rsp+40], rax
mov rax, QWORD PTR int_part_buf$[rbp]
mov QWORD PTR [rsp+32], rax
mov r9, QWORD PTR format_option$[rbp]
mov r8d, DWORD PTR number_styles$[rbp]
mov rdx, QWORD PTR in_ptr$[rbp]
lea rcx, QWORD PTR state$[rbp]
call InitializeParserState
; 193 : if (number_styles & PMC_NUMBER_STYLE_ALLOW_LEADING_WHITE)
mov eax, DWORD PTR number_styles$[rbp]
and eax, 1
test eax, eax
je SHORT $LN2@ParseAsDec
; 194 : SkipSpace(&state);
lea rcx, QWORD PTR state$[rbp]
call SkipSpace
$LN2@ParseAsDec:
; 195 : if ((number_styles & PMC_NUMBER_STYLE_ALLOW_PARENTHESES) && *state.IN_PTR == L'(')
mov eax, DWORD PTR number_styles$[rbp]
and eax, 16
test eax, eax
je $LN3@ParseAsDec
mov rax, QWORD PTR state$[rbp]
movzx eax, WORD PTR [rax]
cmp eax, 40 ; 00000028H
jne $LN3@ParseAsDec
; 196 : {
; 197 : state.SIGN = -1;
mov DWORD PTR state$[rbp+12], -1
; 198 : state.IN_PTR += 1;
mov rax, QWORD PTR state$[rbp]
add rax, 2
mov QWORD PTR state$[rbp], rax
; 199 : if (*state.IN_PTR >= L'0' && *state.IN_PTR <= L'9')
mov rax, QWORD PTR state$[rbp]
movzx eax, WORD PTR [rax]
cmp eax, 48 ; 00000030H
jl SHORT $LN5@ParseAsDec
mov rax, QWORD PTR state$[rbp]
movzx eax, WORD PTR [rax]
cmp eax, 57 ; 00000039H
jg SHORT $LN5@ParseAsDec
; 200 : ParseAsIntegerPartNumberSequence(&state);
lea rcx, QWORD PTR state$[rbp]
call ParseAsIntegerPartNumberSequence
$LN5@ParseAsDec:
; 201 : if ((number_styles & PMC_NUMBER_STYLE_ALLOW_DECIMAL_POINT) && StartsWith(state.IN_PTR, state.DECIMAL_SEPARATOR))
mov eax, DWORD PTR number_styles$[rbp]
and eax, 32 ; 00000020H
test eax, eax
je SHORT $LN6@ParseAsDec
lea rdx, QWORD PTR state$[rbp+40]
mov rcx, QWORD PTR state$[rbp]
call StartsWith
test eax, eax
je SHORT $LN6@ParseAsDec
; 202 : {
; 203 : state.IN_PTR += state.DECIMAL_SEPARATOR_LENGTH;
movsxd rax, DWORD PTR state$[rbp+48]
mov rcx, QWORD PTR state$[rbp]
lea rax, QWORD PTR [rcx+rax*2]
mov QWORD PTR state$[rbp], rax
; 204 : ParseAsFractionPartNumberSequence(&state);
lea rcx, QWORD PTR state$[rbp]
call ParseAsFractionPartNumberSequence
$LN6@ParseAsDec:
; 205 : }
; 206 : if (*state.IN_PTR != L')')
mov rax, QWORD PTR state$[rbp]
movzx eax, WORD PTR [rax]
cmp eax, 41 ; 00000029H
je SHORT $LN7@ParseAsDec
; 207 : return (0);
xor eax, eax
jmp $LN1@ParseAsDec
$LN7@ParseAsDec:
; 208 : state.IN_PTR += 1;
mov rax, QWORD PTR state$[rbp]
add rax, 2
mov QWORD PTR state$[rbp], rax
; 209 : }
jmp $LN4@ParseAsDec
$LN3@ParseAsDec:
; 210 : else if ((number_styles & PMC_NUMBER_STYLE_ALLOW_LEADING_SIGN) && StartsWith(state.IN_PTR, state.POSITIVE_SIGN))
mov eax, DWORD PTR number_styles$[rbp]
and eax, 4
test eax, eax
je $LN8@ParseAsDec
lea rdx, QWORD PTR state$[rbp+16]
mov rcx, QWORD PTR state$[rbp]
call StartsWith
test eax, eax
je SHORT $LN8@ParseAsDec
; 211 : {
; 212 : state.SIGN = 1;
mov DWORD PTR state$[rbp+12], 1
; 213 : state.IN_PTR += state.POSITIVE_SIGN_LENGTH;
movsxd rax, DWORD PTR state$[rbp+24]
mov rcx, QWORD PTR state$[rbp]
lea rax, QWORD PTR [rcx+rax*2]
mov QWORD PTR state$[rbp], rax
; 214 : if (*state.IN_PTR >= L'0' && *state.IN_PTR <= L'9')
mov rax, QWORD PTR state$[rbp]
movzx eax, WORD PTR [rax]
cmp eax, 48 ; 00000030H
jl SHORT $LN10@ParseAsDec
mov rax, QWORD PTR state$[rbp]
movzx eax, WORD PTR [rax]
cmp eax, 57 ; 00000039H
jg SHORT $LN10@ParseAsDec
; 215 : ParseAsIntegerPartNumberSequence(&state);
lea rcx, QWORD PTR state$[rbp]
call ParseAsIntegerPartNumberSequence
$LN10@ParseAsDec:
; 216 : if ((number_styles & PMC_NUMBER_STYLE_ALLOW_DECIMAL_POINT) && StartsWith(state.IN_PTR, state.DECIMAL_SEPARATOR))
mov eax, DWORD PTR number_styles$[rbp]
and eax, 32 ; 00000020H
test eax, eax
je SHORT $LN11@ParseAsDec
lea rdx, QWORD PTR state$[rbp+40]
mov rcx, QWORD PTR state$[rbp]
call StartsWith
test eax, eax
je SHORT $LN11@ParseAsDec
; 217 : {
; 218 : state.IN_PTR += state.DECIMAL_SEPARATOR_LENGTH;
movsxd rax, DWORD PTR state$[rbp+48]
mov rcx, QWORD PTR state$[rbp]
lea rax, QWORD PTR [rcx+rax*2]
mov QWORD PTR state$[rbp], rax
; 219 : ParseAsFractionPartNumberSequence(&state);
lea rcx, QWORD PTR state$[rbp]
call ParseAsFractionPartNumberSequence
$LN11@ParseAsDec:
; 220 : }
; 221 : }
jmp $LN9@ParseAsDec
$LN8@ParseAsDec:
; 222 : else if ((number_styles & PMC_NUMBER_STYLE_ALLOW_LEADING_SIGN) && StartsWith(state.IN_PTR, state.NEGATIVE_SIGN))
mov eax, DWORD PTR number_styles$[rbp]
and eax, 4
test eax, eax
je $LN12@ParseAsDec
lea rdx, QWORD PTR state$[rbp+28]
mov rcx, QWORD PTR state$[rbp]
call StartsWith
test eax, eax
je SHORT $LN12@ParseAsDec
; 223 : {
; 224 : state.SIGN = -1;
mov DWORD PTR state$[rbp+12], -1
; 225 : state.IN_PTR += state.NEGATIVE_SIGN_LENGTH;
movsxd rax, DWORD PTR state$[rbp+36]
mov rcx, QWORD PTR state$[rbp]
lea rax, QWORD PTR [rcx+rax*2]
mov QWORD PTR state$[rbp], rax
; 226 : if (*state.IN_PTR >= L'0' && *state.IN_PTR <= L'9')
mov rax, QWORD PTR state$[rbp]
movzx eax, WORD PTR [rax]
cmp eax, 48 ; 00000030H
jl SHORT $LN14@ParseAsDec
mov rax, QWORD PTR state$[rbp]
movzx eax, WORD PTR [rax]
cmp eax, 57 ; 00000039H
jg SHORT $LN14@ParseAsDec
; 227 : ParseAsIntegerPartNumberSequence(&state);
lea rcx, QWORD PTR state$[rbp]
call ParseAsIntegerPartNumberSequence
$LN14@ParseAsDec:
; 228 : if ((number_styles & PMC_NUMBER_STYLE_ALLOW_DECIMAL_POINT) && StartsWith(state.IN_PTR, state.DECIMAL_SEPARATOR))
mov eax, DWORD PTR number_styles$[rbp]
and eax, 32 ; 00000020H
test eax, eax
je SHORT $LN15@ParseAsDec
lea rdx, QWORD PTR state$[rbp+40]
mov rcx, QWORD PTR state$[rbp]
call StartsWith
test eax, eax
je SHORT $LN15@ParseAsDec
; 229 : {
; 230 : state.IN_PTR += state.DECIMAL_SEPARATOR_LENGTH;
movsxd rax, DWORD PTR state$[rbp+48]
mov rcx, QWORD PTR state$[rbp]
lea rax, QWORD PTR [rcx+rax*2]
mov QWORD PTR state$[rbp], rax
; 231 : ParseAsFractionPartNumberSequence(&state);
lea rcx, QWORD PTR state$[rbp]
call ParseAsFractionPartNumberSequence
$LN15@ParseAsDec:
; 232 : }
; 233 : }
jmp $LN13@ParseAsDec
$LN12@ParseAsDec:
; 234 : else if (*state.IN_PTR >= L'0' && *state.IN_PTR <= L'9')
mov rax, QWORD PTR state$[rbp]
movzx eax, WORD PTR [rax]
cmp eax, 48 ; 00000030H
jl $LN16@ParseAsDec
mov rax, QWORD PTR state$[rbp]
movzx eax, WORD PTR [rax]
cmp eax, 57 ; 00000039H
jg $LN16@ParseAsDec
; 235 : {
; 236 : ParseAsIntegerPartNumberSequence(&state);
lea rcx, QWORD PTR state$[rbp]
call ParseAsIntegerPartNumberSequence
; 237 : if ((number_styles & PMC_NUMBER_STYLE_ALLOW_DECIMAL_POINT) && StartsWith(state.IN_PTR, state.DECIMAL_SEPARATOR))
mov eax, DWORD PTR number_styles$[rbp]
and eax, 32 ; 00000020H
test eax, eax
je SHORT $LN18@ParseAsDec
lea rdx, QWORD PTR state$[rbp+40]
mov rcx, QWORD PTR state$[rbp]
call StartsWith
test eax, eax
je SHORT $LN18@ParseAsDec
; 238 : {
; 239 : state.IN_PTR += state.DECIMAL_SEPARATOR_LENGTH;
movsxd rax, DWORD PTR state$[rbp+48]
mov rcx, QWORD PTR state$[rbp]
lea rax, QWORD PTR [rcx+rax*2]
mov QWORD PTR state$[rbp], rax
; 240 : ParseAsFractionPartNumberSequence(&state);
lea rcx, QWORD PTR state$[rbp]
call ParseAsFractionPartNumberSequence
$LN18@ParseAsDec:
; 241 : }
; 242 : if ((number_styles & PMC_NUMBER_STYLE_ALLOW_TRAILING_SIGN) && StartsWith(state.IN_PTR, state.POSITIVE_SIGN))
mov eax, DWORD PTR number_styles$[rbp]
and eax, 8
test eax, eax
je SHORT $LN19@ParseAsDec
lea rdx, QWORD PTR state$[rbp+16]
mov rcx, QWORD PTR state$[rbp]
call StartsWith
test eax, eax
je SHORT $LN19@ParseAsDec
; 243 : {
; 244 : state.SIGN = 1;
mov DWORD PTR state$[rbp+12], 1
; 245 : state.IN_PTR += state.POSITIVE_SIGN_LENGTH;
movsxd rax, DWORD PTR state$[rbp+24]
mov rcx, QWORD PTR state$[rbp]
lea rax, QWORD PTR [rcx+rax*2]
mov QWORD PTR state$[rbp], rax
; 246 : }
jmp SHORT $LN20@ParseAsDec
$LN19@ParseAsDec:
; 247 : else if ((number_styles & PMC_NUMBER_STYLE_ALLOW_TRAILING_SIGN) && StartsWith(state.IN_PTR, state.NEGATIVE_SIGN))
mov eax, DWORD PTR number_styles$[rbp]
and eax, 8
test eax, eax
je SHORT $LN21@ParseAsDec
lea rdx, QWORD PTR state$[rbp+28]
mov rcx, QWORD PTR state$[rbp]
call StartsWith
test eax, eax
je SHORT $LN21@ParseAsDec
; 248 : {
; 249 : state.SIGN = -1;
mov DWORD PTR state$[rbp+12], -1
; 250 : state.IN_PTR += state.NEGATIVE_SIGN_LENGTH;
movsxd rax, DWORD PTR state$[rbp+36]
mov rcx, QWORD PTR state$[rbp]
lea rax, QWORD PTR [rcx+rax*2]
mov QWORD PTR state$[rbp], rax
$LN21@ParseAsDec:
$LN20@ParseAsDec:
; 251 : }
; 252 : else
; 253 : {
; 254 : }
; 255 : }
jmp $LN17@ParseAsDec
$LN16@ParseAsDec:
; 256 : else if ((number_styles & PMC_NUMBER_STYLE_ALLOW_DECIMAL_POINT) && StartsWith(state.IN_PTR, state.DECIMAL_SEPARATOR))
mov eax, DWORD PTR number_styles$[rbp]
and eax, 32 ; 00000020H
test eax, eax
je $LN23@ParseAsDec
lea rdx, QWORD PTR state$[rbp+40]
mov rcx, QWORD PTR state$[rbp]
call StartsWith
test eax, eax
je $LN23@ParseAsDec
; 257 : {
; 258 : state.IN_PTR += state.DECIMAL_SEPARATOR_LENGTH;
movsxd rax, DWORD PTR state$[rbp+48]
mov rcx, QWORD PTR state$[rbp]
lea rax, QWORD PTR [rcx+rax*2]
mov QWORD PTR state$[rbp], rax
; 259 : ParseAsFractionPartNumberSequence(&state);
lea rcx, QWORD PTR state$[rbp]
call ParseAsFractionPartNumberSequence
; 260 : if ((number_styles & PMC_NUMBER_STYLE_ALLOW_TRAILING_SIGN) && StartsWith(state.IN_PTR, state.POSITIVE_SIGN))
mov eax, DWORD PTR number_styles$[rbp]
and eax, 8
test eax, eax
je SHORT $LN25@ParseAsDec
lea rdx, QWORD PTR state$[rbp+16]
mov rcx, QWORD PTR state$[rbp]
call StartsWith
test eax, eax
je SHORT $LN25@ParseAsDec
; 261 : {
; 262 : state.SIGN = 1;
mov DWORD PTR state$[rbp+12], 1
; 263 : state.IN_PTR += state.POSITIVE_SIGN_LENGTH;
movsxd rax, DWORD PTR state$[rbp+24]
mov rcx, QWORD PTR state$[rbp]
lea rax, QWORD PTR [rcx+rax*2]
mov QWORD PTR state$[rbp], rax
; 264 : }
jmp SHORT $LN26@ParseAsDec
$LN25@ParseAsDec:
; 265 : else if ((number_styles & PMC_NUMBER_STYLE_ALLOW_TRAILING_SIGN) && StartsWith(state.IN_PTR, state.NEGATIVE_SIGN))
mov eax, DWORD PTR number_styles$[rbp]
and eax, 8
test eax, eax
je SHORT $LN27@ParseAsDec
lea rdx, QWORD PTR state$[rbp+28]
mov rcx, QWORD PTR state$[rbp]
call StartsWith
test eax, eax
je SHORT $LN27@ParseAsDec
; 266 : {
; 267 : state.SIGN = -1;
mov DWORD PTR state$[rbp+12], -1
; 268 : state.IN_PTR += state.NEGATIVE_SIGN_LENGTH;
movsxd rax, DWORD PTR state$[rbp+36]
mov rcx, QWORD PTR state$[rbp]
lea rax, QWORD PTR [rcx+rax*2]
mov QWORD PTR state$[rbp], rax
$LN27@ParseAsDec:
$LN26@ParseAsDec:
; 269 : }
; 270 : else
; 271 : {
; 272 : }
; 273 : }
jmp SHORT $LN24@ParseAsDec
$LN23@ParseAsDec:
; 274 : else
; 275 : return (0);
xor eax, eax
jmp SHORT $LN1@ParseAsDec
$LN24@ParseAsDec:
$LN17@ParseAsDec:
$LN13@ParseAsDec:
$LN9@ParseAsDec:
$LN4@ParseAsDec:
; 276 : if (number_styles & PMC_NUMBER_STYLE_ALLOW_TRAILING_WHITE)
mov eax, DWORD PTR number_styles$[rbp]
and eax, 2
test eax, eax
je SHORT $LN29@ParseAsDec
; 277 : SkipSpace(&state);
lea rcx, QWORD PTR state$[rbp]
call SkipSpace
$LN29@ParseAsDec:
; 278 : if (*state.IN_PTR != L'\0')
mov rax, QWORD PTR state$[rbp]
movzx eax, WORD PTR [rax]
test eax, eax
je SHORT $LN30@ParseAsDec
; 279 : return (0);
xor eax, eax
jmp SHORT $LN1@ParseAsDec
$LN30@ParseAsDec:
; 280 : FinalizeParserState(&state);
lea rcx, QWORD PTR state$[rbp]
call FinalizeParserState
; 281 : *sign = state.SIGN;
mov rax, QWORD PTR sign$[rbp]
mov ecx, DWORD PTR state$[rbp+12]
mov DWORD PTR [rax], ecx
; 282 : return (1);
mov eax, 1
$LN1@ParseAsDec:
; 283 : }
mov rdi, rax
lea rcx, QWORD PTR [rbp-48]
lea rdx, OFFSET FLAT:ParseAsDecimalNumberString$rtcFrameData
call _RTC_CheckStackVars
mov rax, rdi
mov rcx, QWORD PTR __$ArrayPad$[rbp]
xor rcx, rbp
call __security_check_cookie
lea rsp, QWORD PTR [rbp+328]
pop rdi
pop rbp
ret 0
ParseAsDecimalNumberString ENDP
_TEXT ENDS
; Function compile flags: /Odtp /RTCsu /ZI
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_parse.c
; COMDAT ParseAsFractionPartNumberSequence
_TEXT SEGMENT
state$ = 224
ParseAsFractionPartNumberSequence PROC ; COMDAT
; 162 : {
mov QWORD PTR [rsp+8], rcx
push rbp
push rdi
sub rsp, 232 ; 000000e8H
lea rbp, QWORD PTR [rsp+32]
mov rdi, rsp
mov ecx, 58 ; 0000003aH
mov eax, -858993460 ; ccccccccH
rep stosd
mov rcx, QWORD PTR [rsp+264]
lea rcx, OFFSET FLAT:__C5BBD3C1_pmc_parse@c
call __CheckForDebuggerJustMyCode
$LN2@ParseAsFra:
; 163 : for (;;)
; 164 : {
; 165 : if (*state->IN_PTR >= L'0' && *state->IN_PTR <= L'9')
mov rax, QWORD PTR state$[rbp]
mov rax, QWORD PTR [rax]
movzx eax, WORD PTR [rax]
cmp eax, 48 ; 00000030H
jl SHORT $LN5@ParseAsFra
mov rax, QWORD PTR state$[rbp]
mov rax, QWORD PTR [rax]
movzx eax, WORD PTR [rax]
cmp eax, 57 ; 00000039H
jg SHORT $LN5@ParseAsFra
; 166 : {
; 167 : *state->FRAC_PART_PTR = *state->IN_PTR;
mov rax, QWORD PTR state$[rbp]
mov rax, QWORD PTR [rax]
mov rcx, QWORD PTR state$[rbp]
mov rcx, QWORD PTR [rcx+88]
movzx eax, WORD PTR [rax]
mov WORD PTR [rcx], ax
; 168 : state->FRAC_PART_PTR += 1;
mov rax, QWORD PTR state$[rbp]
mov rax, QWORD PTR [rax+88]
add rax, 2
mov rcx, QWORD PTR state$[rbp]
mov QWORD PTR [rcx+88], rax
; 169 : state->IN_PTR += 1;
mov rax, QWORD PTR state$[rbp]
mov rax, QWORD PTR [rax]
add rax, 2
mov rcx, QWORD PTR state$[rbp]
mov QWORD PTR [rcx], rax
; 170 : }
jmp $LN6@ParseAsFra
$LN5@ParseAsFra:
; 171 : else if (state->NUMBER_STYLES & PMC_NUMBER_STYLE_ALLOW_HEX_SPECIFIER && *state->IN_PTR >= L'a' && *state->IN_PTR <= L'f')
mov rax, QWORD PTR state$[rbp]
mov eax, DWORD PTR [rax+8]
and eax, 512 ; 00000200H
test eax, eax
je SHORT $LN7@ParseAsFra
mov rax, QWORD PTR state$[rbp]
mov rax, QWORD PTR [rax]
movzx eax, WORD PTR [rax]
cmp eax, 97 ; 00000061H
jl SHORT $LN7@ParseAsFra
mov rax, QWORD PTR state$[rbp]
mov rax, QWORD PTR [rax]
movzx eax, WORD PTR [rax]
cmp eax, 102 ; 00000066H
jg SHORT $LN7@ParseAsFra
; 172 : {
; 173 : *state->FRAC_PART_PTR = *state->IN_PTR;
mov rax, QWORD PTR state$[rbp]
mov rax, QWORD PTR [rax]
mov rcx, QWORD PTR state$[rbp]
mov rcx, QWORD PTR [rcx+88]
movzx eax, WORD PTR [rax]
mov WORD PTR [rcx], ax
; 174 : state->FRAC_PART_PTR += 1;
mov rax, QWORD PTR state$[rbp]
mov rax, QWORD PTR [rax+88]
add rax, 2
mov rcx, QWORD PTR state$[rbp]
mov QWORD PTR [rcx+88], rax
; 175 : state->IN_PTR += 1;
mov rax, QWORD PTR state$[rbp]
mov rax, QWORD PTR [rax]
add rax, 2
mov rcx, QWORD PTR state$[rbp]
mov QWORD PTR [rcx], rax
; 176 : }
jmp $LN8@ParseAsFra
$LN7@ParseAsFra:
; 177 : else if (state->NUMBER_STYLES & PMC_NUMBER_STYLE_ALLOW_HEX_SPECIFIER && *state->IN_PTR >= L'A' && *state->IN_PTR <= L'F')
mov rax, QWORD PTR state$[rbp]
mov eax, DWORD PTR [rax+8]
and eax, 512 ; 00000200H
test eax, eax
je SHORT $LN9@ParseAsFra
mov rax, QWORD PTR state$[rbp]
mov rax, QWORD PTR [rax]
movzx eax, WORD PTR [rax]
cmp eax, 65 ; 00000041H
jl SHORT $LN9@ParseAsFra
mov rax, QWORD PTR state$[rbp]
mov rax, QWORD PTR [rax]
movzx eax, WORD PTR [rax]
cmp eax, 70 ; 00000046H
jg SHORT $LN9@ParseAsFra
; 178 : {
; 179 : *state->FRAC_PART_PTR = *state->IN_PTR;
mov rax, QWORD PTR state$[rbp]
mov rax, QWORD PTR [rax]
mov rcx, QWORD PTR state$[rbp]
mov rcx, QWORD PTR [rcx+88]
movzx eax, WORD PTR [rax]
mov WORD PTR [rcx], ax
; 180 : state->FRAC_PART_PTR += 1;
mov rax, QWORD PTR state$[rbp]
mov rax, QWORD PTR [rax+88]
add rax, 2
mov rcx, QWORD PTR state$[rbp]
mov QWORD PTR [rcx+88], rax
; 181 : state->IN_PTR += 1;
mov rax, QWORD PTR state$[rbp]
mov rax, QWORD PTR [rax]
add rax, 2
mov rcx, QWORD PTR state$[rbp]
mov QWORD PTR [rcx], rax
; 182 : }
jmp SHORT $LN10@ParseAsFra
$LN9@ParseAsFra:
; 183 : else
; 184 : break;
jmp SHORT $LN3@ParseAsFra
$LN10@ParseAsFra:
$LN8@ParseAsFra:
$LN6@ParseAsFra:
; 185 : }
jmp $LN2@ParseAsFra
$LN3@ParseAsFra:
; 186 : }
lea rsp, QWORD PTR [rbp+200]
pop rdi
pop rbp
ret 0
ParseAsFractionPartNumberSequence ENDP
_TEXT ENDS
; Function compile flags: /Odtp /RTCsu /ZI
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_parse.c
; COMDAT ParseAsIntegerPartNumberSequence
_TEXT SEGMENT
state$ = 224
ParseAsIntegerPartNumberSequence PROC ; COMDAT
; 131 : {
mov QWORD PTR [rsp+8], rcx
push rbp
push rdi
sub rsp, 232 ; 000000e8H
lea rbp, QWORD PTR [rsp+32]
mov rdi, rsp
mov ecx, 58 ; 0000003aH
mov eax, -858993460 ; ccccccccH
rep stosd
mov rcx, QWORD PTR [rsp+264]
lea rcx, OFFSET FLAT:__C5BBD3C1_pmc_parse@c
call __CheckForDebuggerJustMyCode
$LN2@ParseAsInt:
; 132 : for (;;)
; 133 : {
; 134 : if (*state->IN_PTR >= L'0' && *state->IN_PTR <= L'9')
mov rax, QWORD PTR state$[rbp]
mov rax, QWORD PTR [rax]
movzx eax, WORD PTR [rax]
cmp eax, 48 ; 00000030H
jl SHORT $LN5@ParseAsInt
mov rax, QWORD PTR state$[rbp]
mov rax, QWORD PTR [rax]
movzx eax, WORD PTR [rax]
cmp eax, 57 ; 00000039H
jg SHORT $LN5@ParseAsInt
; 135 : {
; 136 : *state->INT_PART_PTR = *state->IN_PTR;
mov rax, QWORD PTR state$[rbp]
mov rax, QWORD PTR [rax]
mov rcx, QWORD PTR state$[rbp]
mov rcx, QWORD PTR [rcx+80]
movzx eax, WORD PTR [rax]
mov WORD PTR [rcx], ax
; 137 : state->INT_PART_PTR += 1;
mov rax, QWORD PTR state$[rbp]
mov rax, QWORD PTR [rax+80]
add rax, 2
mov rcx, QWORD PTR state$[rbp]
mov QWORD PTR [rcx+80], rax
; 138 : state->IN_PTR += 1;
mov rax, QWORD PTR state$[rbp]
mov rax, QWORD PTR [rax]
add rax, 2
mov rcx, QWORD PTR state$[rbp]
mov QWORD PTR [rcx], rax
; 139 : }
jmp $LN6@ParseAsInt
$LN5@ParseAsInt:
; 140 : else if (state->NUMBER_STYLES & PMC_NUMBER_STYLE_ALLOW_HEX_SPECIFIER && *state->IN_PTR >= L'a' && *state->IN_PTR <= L'f')
mov rax, QWORD PTR state$[rbp]
mov eax, DWORD PTR [rax+8]
and eax, 512 ; 00000200H
test eax, eax
je SHORT $LN7@ParseAsInt
mov rax, QWORD PTR state$[rbp]
mov rax, QWORD PTR [rax]
movzx eax, WORD PTR [rax]
cmp eax, 97 ; 00000061H
jl SHORT $LN7@ParseAsInt
mov rax, QWORD PTR state$[rbp]
mov rax, QWORD PTR [rax]
movzx eax, WORD PTR [rax]
cmp eax, 102 ; 00000066H
jg SHORT $LN7@ParseAsInt
; 141 : {
; 142 : *state->INT_PART_PTR = *state->IN_PTR;
mov rax, QWORD PTR state$[rbp]
mov rax, QWORD PTR [rax]
mov rcx, QWORD PTR state$[rbp]
mov rcx, QWORD PTR [rcx+80]
movzx eax, WORD PTR [rax]
mov WORD PTR [rcx], ax
; 143 : state->INT_PART_PTR += 1;
mov rax, QWORD PTR state$[rbp]
mov rax, QWORD PTR [rax+80]
add rax, 2
mov rcx, QWORD PTR state$[rbp]
mov QWORD PTR [rcx+80], rax
; 144 : state->IN_PTR += 1;
mov rax, QWORD PTR state$[rbp]
mov rax, QWORD PTR [rax]
add rax, 2
mov rcx, QWORD PTR state$[rbp]
mov QWORD PTR [rcx], rax
; 145 : }
jmp $LN8@ParseAsInt
$LN7@ParseAsInt:
; 146 : else if (state->NUMBER_STYLES & PMC_NUMBER_STYLE_ALLOW_HEX_SPECIFIER && *state->IN_PTR >= L'A' && *state->IN_PTR <= L'F')
mov rax, QWORD PTR state$[rbp]
mov eax, DWORD PTR [rax+8]
and eax, 512 ; 00000200H
test eax, eax
je SHORT $LN9@ParseAsInt
mov rax, QWORD PTR state$[rbp]
mov rax, QWORD PTR [rax]
movzx eax, WORD PTR [rax]
cmp eax, 65 ; 00000041H
jl SHORT $LN9@ParseAsInt
mov rax, QWORD PTR state$[rbp]
mov rax, QWORD PTR [rax]
movzx eax, WORD PTR [rax]
cmp eax, 70 ; 00000046H
jg SHORT $LN9@ParseAsInt
; 147 : {
; 148 : *state->INT_PART_PTR = *state->IN_PTR;
mov rax, QWORD PTR state$[rbp]
mov rax, QWORD PTR [rax]
mov rcx, QWORD PTR state$[rbp]
mov rcx, QWORD PTR [rcx+80]
movzx eax, WORD PTR [rax]
mov WORD PTR [rcx], ax
; 149 : state->INT_PART_PTR += 1;
mov rax, QWORD PTR state$[rbp]
mov rax, QWORD PTR [rax+80]
add rax, 2
mov rcx, QWORD PTR state$[rbp]
mov QWORD PTR [rcx+80], rax
; 150 : state->IN_PTR += 1;
mov rax, QWORD PTR state$[rbp]
mov rax, QWORD PTR [rax]
add rax, 2
mov rcx, QWORD PTR state$[rbp]
mov QWORD PTR [rcx], rax
; 151 : }
jmp $LN10@ParseAsInt
$LN9@ParseAsInt:
; 152 : else if (state->NUMBER_STYLES & PMC_NUMBER_STYLE_ALLOW_THOUSANDS && StartsWith(state->IN_PTR, state->GROUP_SEPARATOR))
mov rax, QWORD PTR state$[rbp]
mov eax, DWORD PTR [rax+8]
and eax, 64 ; 00000040H
test eax, eax
je SHORT $LN11@ParseAsInt
mov rax, QWORD PTR state$[rbp]
add rax, 52 ; 00000034H
mov rdx, rax
mov rax, QWORD PTR state$[rbp]
mov rcx, QWORD PTR [rax]
call StartsWith
test eax, eax
je SHORT $LN11@ParseAsInt
; 153 : state->IN_PTR += state->GROUP_SEPARATOR_LENGTH;
mov rax, QWORD PTR state$[rbp]
movsxd rax, DWORD PTR [rax+60]
mov rcx, QWORD PTR state$[rbp]
mov rcx, QWORD PTR [rcx]
lea rax, QWORD PTR [rcx+rax*2]
mov rcx, QWORD PTR state$[rbp]
mov QWORD PTR [rcx], rax
jmp SHORT $LN12@ParseAsInt
$LN11@ParseAsInt:
; 154 : else if (state->NUMBER_STYLES & PMC_NUMBER_STYLE_ALLOW_THOUSANDS && state->SECONDARY_GROUP_SEPARATOR_LENGTH > 0 && StartsWith(state->IN_PTR, state->SECONDARY_GROUP_SEPARATOR))
mov rax, QWORD PTR state$[rbp]
mov eax, DWORD PTR [rax+8]
and eax, 64 ; 00000040H
test eax, eax
je SHORT $LN13@ParseAsInt
mov rax, QWORD PTR state$[rbp]
cmp DWORD PTR [rax+72], 0
jle SHORT $LN13@ParseAsInt
mov rax, QWORD PTR state$[rbp]
add rax, 64 ; 00000040H
mov rdx, rax
mov rax, QWORD PTR state$[rbp]
mov rcx, QWORD PTR [rax]
call StartsWith
test eax, eax
je SHORT $LN13@ParseAsInt
; 155 : state->IN_PTR += state->SECONDARY_GROUP_SEPARATOR_LENGTH;
mov rax, QWORD PTR state$[rbp]
movsxd rax, DWORD PTR [rax+72]
mov rcx, QWORD PTR state$[rbp]
mov rcx, QWORD PTR [rcx]
lea rax, QWORD PTR [rcx+rax*2]
mov rcx, QWORD PTR state$[rbp]
mov QWORD PTR [rcx], rax
jmp SHORT $LN14@ParseAsInt
$LN13@ParseAsInt:
; 156 : else
; 157 : break;
jmp SHORT $LN3@ParseAsInt
$LN14@ParseAsInt:
$LN12@ParseAsInt:
$LN10@ParseAsInt:
$LN8@ParseAsInt:
$LN6@ParseAsInt:
; 158 : }
jmp $LN2@ParseAsInt
$LN3@ParseAsInt:
; 159 : }
lea rsp, QWORD PTR [rbp+200]
pop rdi
pop rbp
ret 0
ParseAsIntegerPartNumberSequence ENDP
_TEXT ENDS
; Function compile flags: /Odtp /RTCsu /ZI
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_parse.c
; COMDAT SkipSpace
_TEXT SEGMENT
tv67 = 192
state$ = 240
SkipSpace PROC ; COMDAT
; 110 : {
mov QWORD PTR [rsp+8], rcx
push rbp
push rdi
sub rsp, 248 ; 000000f8H
lea rbp, QWORD PTR [rsp+32]
mov rdi, rsp
mov ecx, 62 ; 0000003eH
mov eax, -858993460 ; ccccccccH
rep stosd
mov rcx, QWORD PTR [rsp+280]
lea rcx, OFFSET FLAT:__C5BBD3C1_pmc_parse@c
call __CheckForDebuggerJustMyCode
$LN2@SkipSpace:
; 111 : for (;;)
; 112 : {
; 113 : switch (*state->IN_PTR)
mov rax, QWORD PTR state$[rbp]
mov rax, QWORD PTR [rax]
movzx eax, WORD PTR [rax]
mov DWORD PTR tv67[rbp], eax
cmp DWORD PTR tv67[rbp], 9
jl SHORT $LN8@SkipSpace
cmp DWORD PTR tv67[rbp], 13
jle SHORT $LN7@SkipSpace
cmp DWORD PTR tv67[rbp], 32 ; 00000020H
je SHORT $LN7@SkipSpace
jmp SHORT $LN8@SkipSpace
$LN7@SkipSpace:
; 114 : {
; 115 : case L' ':
; 116 : case L'\t':
; 117 : case L'\n':
; 118 : case L'\r':
; 119 : case L'\f':
; 120 : case L'\v':
; 121 : break;
jmp SHORT $LN5@SkipSpace
$LN8@SkipSpace:
; 122 :
; 123 : default:
; 124 : return;
jmp SHORT $LN1@SkipSpace
$LN5@SkipSpace:
; 125 : }
; 126 : state->IN_PTR += 1;
mov rax, QWORD PTR state$[rbp]
mov rax, QWORD PTR [rax]
add rax, 2
mov rcx, QWORD PTR state$[rbp]
mov QWORD PTR [rcx], rax
; 127 : }
jmp SHORT $LN2@SkipSpace
$LN1@SkipSpace:
; 128 : }
lea rsp, QWORD PTR [rbp+216]
pop rdi
pop rbp
ret 0
SkipSpace ENDP
_TEXT ENDS
; Function compile flags: /Odtp /RTCsu /ZI
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_parse.c
; COMDAT FinalizeParserState
_TEXT SEGMENT
state$ = 224
FinalizeParserState PROC ; COMDAT
; 102 : {
mov QWORD PTR [rsp+8], rcx
push rbp
push rdi
sub rsp, 232 ; 000000e8H
lea rbp, QWORD PTR [rsp+32]
mov rdi, rsp
mov ecx, 58 ; 0000003aH
mov eax, -858993460 ; ccccccccH
rep stosd
mov rcx, QWORD PTR [rsp+264]
lea rcx, OFFSET FLAT:__C5BBD3C1_pmc_parse@c
call __CheckForDebuggerJustMyCode
; 103 : *state->INT_PART_PTR = L'\0';
mov rax, QWORD PTR state$[rbp]
mov rax, QWORD PTR [rax+80]
xor ecx, ecx
mov WORD PTR [rax], cx
; 104 : if (state->NUMBER_STYLES & PMC_NUMBER_STYLE_ALLOW_DECIMAL_POINT)
mov rax, QWORD PTR state$[rbp]
mov eax, DWORD PTR [rax+8]
and eax, 32 ; 00000020H
test eax, eax
je SHORT $LN2@FinalizePa
; 105 : *state->FRAC_PART_PTR = L'\0';
mov rax, QWORD PTR state$[rbp]
mov rax, QWORD PTR [rax+88]
xor ecx, ecx
mov WORD PTR [rax], cx
$LN2@FinalizePa:
; 106 : }
lea rsp, QWORD PTR [rbp+200]
pop rdi
pop rbp
ret 0
FinalizeParserState ENDP
_TEXT ENDS
; Function compile flags: /Odtp /RTCsu /ZI
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_parse.c
; COMDAT InitializeParserState
_TEXT SEGMENT
state$ = 224
in_ptr$ = 232
number_styles$ = 240
format_option$ = 248
int_part_buf$ = 256
frac_part_buf$ = 264
InitializeParserState PROC ; COMDAT
; 74 : {
mov QWORD PTR [rsp+32], r9
mov DWORD PTR [rsp+24], r8d
mov QWORD PTR [rsp+16], rdx
mov QWORD PTR [rsp+8], rcx
push rbp
push rdi
sub rsp, 232 ; 000000e8H
lea rbp, QWORD PTR [rsp+32]
mov rdi, rsp
mov ecx, 58 ; 0000003aH
mov eax, -858993460 ; ccccccccH
rep stosd
mov rcx, QWORD PTR [rsp+264]
lea rcx, OFFSET FLAT:__C5BBD3C1_pmc_parse@c
call __CheckForDebuggerJustMyCode
; 75 : state->IN_PTR = in_ptr;
mov rax, QWORD PTR state$[rbp]
mov rcx, QWORD PTR in_ptr$[rbp]
mov QWORD PTR [rax], rcx
; 76 : state->NUMBER_STYLES = number_styles;
mov rax, QWORD PTR state$[rbp]
mov ecx, DWORD PTR number_styles$[rbp]
mov DWORD PTR [rax+8], ecx
; 77 : state->SIGN = 0;
mov rax, QWORD PTR state$[rbp]
mov DWORD PTR [rax+12], 0
; 78 : lstrcpyW(state->POSITIVE_SIGN, format_option->PositiveSign);
mov rax, QWORD PTR format_option$[rbp]
add rax, 16
mov rcx, QWORD PTR state$[rbp]
add rcx, 16
mov rdx, rax
call QWORD PTR __imp_lstrcpyW
; 79 : state->POSITIVE_SIGN_LENGTH = lstrlenW(state->POSITIVE_SIGN);
mov rax, QWORD PTR state$[rbp]
add rax, 16
mov rcx, rax
call QWORD PTR __imp_lstrlenW
mov rcx, QWORD PTR state$[rbp]
mov DWORD PTR [rcx+24], eax
; 80 : lstrcpyW(state->NEGATIVE_SIGN, format_option->NegativeSign);
mov rax, QWORD PTR format_option$[rbp]
add rax, 22
mov rcx, QWORD PTR state$[rbp]
add rcx, 28
mov rdx, rax
call QWORD PTR __imp_lstrcpyW
; 81 : state->NEGATIVE_SIGN_LENGTH = lstrlenW(state->NEGATIVE_SIGN);
mov rax, QWORD PTR state$[rbp]
add rax, 28
mov rcx, rax
call QWORD PTR __imp_lstrlenW
mov rcx, QWORD PTR state$[rbp]
mov DWORD PTR [rcx+36], eax
; 82 : lstrcpyW(state->DECIMAL_SEPARATOR, format_option->DecimalSeparator);
mov rax, QWORD PTR format_option$[rbp]
add rax, 10
mov rcx, QWORD PTR state$[rbp]
add rcx, 40 ; 00000028H
mov rdx, rax
call QWORD PTR __imp_lstrcpyW
; 83 : state->DECIMAL_SEPARATOR_LENGTH = lstrlenW(state->DECIMAL_SEPARATOR);
mov rax, QWORD PTR state$[rbp]
add rax, 40 ; 00000028H
mov rcx, rax
call QWORD PTR __imp_lstrlenW
mov rcx, QWORD PTR state$[rbp]
mov DWORD PTR [rcx+48], eax
; 84 : lstrcpyW(state->GROUP_SEPARATOR, format_option->GroupSeparator);
mov rax, QWORD PTR format_option$[rbp]
add rax, 4
mov rcx, QWORD PTR state$[rbp]
add rcx, 52 ; 00000034H
mov rdx, rax
call QWORD PTR __imp_lstrcpyW
; 85 : state->GROUP_SEPARATOR_LENGTH = lstrlenW(state->GROUP_SEPARATOR);
mov rax, QWORD PTR state$[rbp]
add rax, 52 ; 00000034H
mov rcx, rax
call QWORD PTR __imp_lstrlenW
mov rcx, QWORD PTR state$[rbp]
mov DWORD PTR [rcx+60], eax
; 86 : if (state->GROUP_SEPARATOR[0] == L'\xa0' && state->GROUP_SEPARATOR[1] == L'\0')
mov eax, 2
imul rax, rax, 0
mov rcx, QWORD PTR state$[rbp]
movzx eax, WORD PTR [rcx+rax+52]
cmp eax, 160 ; 000000a0H
jne SHORT $LN2@Initialize
mov eax, 2
imul rax, rax, 1
mov rcx, QWORD PTR state$[rbp]
movzx eax, WORD PTR [rcx+rax+52]
test eax, eax
jne SHORT $LN2@Initialize
; 87 : {
; 88 : state->SECONDARY_GROUP_SEPARATOR[0] = L'\x20';
mov eax, 2
imul rax, rax, 0
mov ecx, 32 ; 00000020H
mov rdx, QWORD PTR state$[rbp]
mov WORD PTR [rdx+rax+64], cx
; 89 : state->SECONDARY_GROUP_SEPARATOR[1] = L'\0';
mov eax, 2
imul rax, rax, 1
xor ecx, ecx
mov rdx, QWORD PTR state$[rbp]
mov WORD PTR [rdx+rax+64], cx
; 90 : state->SECONDARY_GROUP_SEPARATOR_LENGTH = 1;
mov rax, QWORD PTR state$[rbp]
mov DWORD PTR [rax+72], 1
; 91 : }
jmp SHORT $LN3@Initialize
$LN2@Initialize:
; 92 : else
; 93 : {
; 94 : state->SECONDARY_GROUP_SEPARATOR[0] = L'\0';
mov eax, 2
imul rax, rax, 0
xor ecx, ecx
mov rdx, QWORD PTR state$[rbp]
mov WORD PTR [rdx+rax+64], cx
; 95 : state->SECONDARY_GROUP_SEPARATOR_LENGTH = 0;
mov rax, QWORD PTR state$[rbp]
mov DWORD PTR [rax+72], 0
$LN3@Initialize:
; 96 : }
; 97 : state->INT_PART_PTR = int_part_buf;
mov rax, QWORD PTR state$[rbp]
mov rcx, QWORD PTR int_part_buf$[rbp]
mov QWORD PTR [rax+80], rcx
; 98 : state->FRAC_PART_PTR = frac_part_buf;
mov rax, QWORD PTR state$[rbp]
mov rcx, QWORD PTR frac_part_buf$[rbp]
mov QWORD PTR [rax+88], rcx
; 99 : }
lea rsp, QWORD PTR [rbp+200]
pop rdi
pop rbp
ret 0
InitializeParserState ENDP
_TEXT ENDS
; Function compile flags: /Odtp /RTCsu /ZI
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_parse.c
; COMDAT StartsWith
_TEXT SEGMENT
a$ = 224
b$ = 232
StartsWith PROC ; COMDAT
; 62 : {
mov QWORD PTR [rsp+16], rdx
mov QWORD PTR [rsp+8], rcx
push rbp
push rdi
sub rsp, 232 ; 000000e8H
lea rbp, QWORD PTR [rsp+32]
mov rdi, rsp
mov ecx, 58 ; 0000003aH
mov eax, -858993460 ; ccccccccH
rep stosd
mov rcx, QWORD PTR [rsp+264]
lea rcx, OFFSET FLAT:__C5BBD3C1_pmc_parse@c
call __CheckForDebuggerJustMyCode
$LN2@StartsWith:
; 63 : while (*b != L'\0')
mov rax, QWORD PTR b$[rbp]
movzx eax, WORD PTR [rax]
test eax, eax
je SHORT $LN3@StartsWith
; 64 : {
; 65 : if (*a != *b)
mov rax, QWORD PTR a$[rbp]
movzx eax, WORD PTR [rax]
mov rcx, QWORD PTR b$[rbp]
movzx ecx, WORD PTR [rcx]
cmp eax, ecx
je SHORT $LN4@StartsWith
; 66 : return (0);
xor eax, eax
jmp SHORT $LN1@StartsWith
$LN4@StartsWith:
; 67 : ++a;
mov rax, QWORD PTR a$[rbp]
add rax, 2
mov QWORD PTR a$[rbp], rax
; 68 : ++b;
mov rax, QWORD PTR b$[rbp]
add rax, 2
mov QWORD PTR b$[rbp], rax
; 69 : }
jmp SHORT $LN2@StartsWith
$LN3@StartsWith:
; 70 : return (1);
mov eax, 1
$LN1@StartsWith:
; 71 : }
lea rsp, QWORD PTR [rbp+200]
pop rdi
pop rbp
ret 0
StartsWith ENDP
_TEXT ENDS
; Function compile flags: /Odtp /RTCsu /ZI
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_inline_func.h
; COMDAT _MULTIPLYX_UNIT
_TEXT SEGMENT
u$ = 224
v$ = 232
w_hi$ = 240
_MULTIPLYX_UNIT PROC ; COMDAT
; 335 : {
mov QWORD PTR [rsp+24], r8
mov QWORD PTR [rsp+16], rdx
mov QWORD PTR [rsp+8], rcx
push rbp
push rdi
sub rsp, 232 ; 000000e8H
lea rbp, QWORD PTR [rsp+32]
mov rdi, rsp
mov ecx, 58 ; 0000003aH
mov eax, -858993460 ; ccccccccH
rep stosd
mov rcx, QWORD PTR [rsp+264]
lea rcx, OFFSET FLAT:__6B0481B0_pmc_inline_func@h
call __CheckForDebuggerJustMyCode
; 336 : #ifdef _MSC_VER
; 337 : #ifdef _M_IX86
; 338 : return (_FROMDWORDTOWORD((_UINT64_T)u * v, w_hi));
; 339 : #elif defined(_M_X64)
; 340 : return (_mulx_u64(u, v, w_hi));
mov rdx, QWORD PTR v$[rbp]
mulx rax, rcx, QWORD PTR u$[rbp]
mov rdx, QWORD PTR w_hi$[rbp]
mov QWORD PTR [rdx], rax
mov rax, rcx
; 341 : #else
; 342 : #error unknown platform
; 343 : #endif
; 344 : #elif defined(__GNUC__)
; 345 : #ifdef _M_IX86
; 346 : _UINT32_T w_lo;
; 347 : __asm__("mulxl %3, %0, %1" : "=r"(w_lo), "=r"(*w_hi), "+d"(u) : "rm"(v));
; 348 : return (w_lo);
; 349 : #elif defined(_M_X64)
; 350 : _UINT64_T w_lo;
; 351 : __asm__("mulxq %3, %0, %1" : "=r"(w_lo), "=r"(*w_hi), "+d"(u) : "rm"(v));
; 352 : return (w_lo);
; 353 : #else
; 354 : #error unknown platform
; 355 : #endif
; 356 : #else
; 357 : #error unknown compiler
; 358 : #endif
; 359 : }
lea rsp, QWORD PTR [rbp+200]
pop rdi
pop rbp
ret 0
_MULTIPLYX_UNIT ENDP
_TEXT ENDS
; Function compile flags: /Odtp /RTCsu /ZI
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_inline_func.h
; COMDAT _MULTIPLY_UNIT
_TEXT SEGMENT
tv69 = 192
u$ = 240
v$ = 248
w_hi$ = 256
_MULTIPLY_UNIT PROC ; COMDAT
; 297 : {
mov QWORD PTR [rsp+24], r8
mov QWORD PTR [rsp+16], rdx
mov QWORD PTR [rsp+8], rcx
push rbp
push rdi
sub rsp, 248 ; 000000f8H
lea rbp, QWORD PTR [rsp+32]
mov rdi, rsp
mov ecx, 62 ; 0000003eH
mov eax, -858993460 ; ccccccccH
rep stosd
mov rcx, QWORD PTR [rsp+280]
lea rcx, OFFSET FLAT:__6B0481B0_pmc_inline_func@h
call __CheckForDebuggerJustMyCode
; 298 : #ifdef _M_IX86
; 299 : #ifdef _MSC_VER
; 300 : return (_FROMDWORDTOWORD((_UINT64_T)u * v, w_hi));
; 301 : #elif defined(__GNUC__)
; 302 : _UINT32_T w_lo;
; 303 : __asm__("mull %3": "=a"(w_lo), "=d"(*w_hi) : "0"(u), "rm"(v));
; 304 : return (w_lo);
; 305 : #else
; 306 : #error unknown compiler
; 307 : #endif
; 308 : #elif defined(_M_X64)
; 309 : return (_umul128(u, v, w_hi));
mov rax, QWORD PTR u$[rbp]
mov QWORD PTR tv69[rbp], rax
mov rcx, QWORD PTR v$[rbp]
mov rax, rcx
mov rcx, QWORD PTR tv69[rbp]
mul rcx
mov rcx, QWORD PTR w_hi$[rbp]
mov QWORD PTR [rcx], rdx
; 310 : #else
; 311 : #error unknown platform
; 312 : #endif
; 313 : }
lea rsp, QWORD PTR [rbp+216]
pop rdi
pop rbp
ret 0
_MULTIPLY_UNIT ENDP
_TEXT ENDS
; Function compile flags: /Odtp /RTCsu /ZI
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_inline_func.h
; COMDAT _ADDX_UNIT
_TEXT SEGMENT
carry$ = 224
u$ = 232
v$ = 240
w$ = 248
_ADDX_UNIT PROC ; COMDAT
; 241 : {
mov QWORD PTR [rsp+32], r9
mov QWORD PTR [rsp+24], r8
mov QWORD PTR [rsp+16], rdx
mov BYTE PTR [rsp+8], cl
push rbp
push rdi
sub rsp, 232 ; 000000e8H
lea rbp, QWORD PTR [rsp+32]
mov rdi, rsp
mov ecx, 58 ; 0000003aH
mov eax, -858993460 ; ccccccccH
rep stosd
movzx ecx, BYTE PTR [rsp+264]
lea rcx, OFFSET FLAT:__6B0481B0_pmc_inline_func@h
call __CheckForDebuggerJustMyCode
; 242 : #ifdef _M_IX86
; 243 : return (_addcarryx_u32(carry, u, v, w));
; 244 : #elif defined(_M_X64)
; 245 : return (_addcarryx_u64(carry, u, v, w));
mov rax, QWORD PTR u$[rbp]
movzx ecx, BYTE PTR carry$[rbp]
add cl, -1
adcx rax, QWORD PTR v$[rbp]
setb cl
mov rdx, QWORD PTR w$[rbp]
mov QWORD PTR [rdx], rax
movzx eax, cl
; 246 : #else
; 247 : #error unknown platform
; 248 : #endif
; 249 : }
lea rsp, QWORD PTR [rbp+200]
pop rdi
pop rbp
ret 0
_ADDX_UNIT ENDP
_TEXT ENDS
; Function compile flags: /Odtp /RTCsu /ZI
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_inline_func.h
; COMDAT _ADD_UNIT
_TEXT SEGMENT
carry$ = 224
u$ = 232
v$ = 240
w$ = 248
_ADD_UNIT PROC ; COMDAT
; 213 : {
mov QWORD PTR [rsp+32], r9
mov QWORD PTR [rsp+24], r8
mov QWORD PTR [rsp+16], rdx
mov BYTE PTR [rsp+8], cl
push rbp
push rdi
sub rsp, 232 ; 000000e8H
lea rbp, QWORD PTR [rsp+32]
mov rdi, rsp
mov ecx, 58 ; 0000003aH
mov eax, -858993460 ; ccccccccH
rep stosd
movzx ecx, BYTE PTR [rsp+264]
lea rcx, OFFSET FLAT:__6B0481B0_pmc_inline_func@h
call __CheckForDebuggerJustMyCode
; 214 : #ifdef _M_IX86
; 215 : return (_addcarry_u32(carry, u, v, w));
; 216 : #elif defined(_M_X64)
; 217 : return (_addcarry_u64(carry, u, v, w));
mov rax, QWORD PTR u$[rbp]
movzx ecx, BYTE PTR carry$[rbp]
add cl, -1
adc rax, QWORD PTR v$[rbp]
setb cl
mov rdx, QWORD PTR w$[rbp]
mov QWORD PTR [rdx], rax
movzx eax, cl
; 218 : #else
; 219 : #error unknown platform
; 220 : #endif
; 221 : }
lea rsp, QWORD PTR [rbp+200]
pop rdi
pop rbp
ret 0
_ADD_UNIT ENDP
_TEXT ENDS
; Function compile flags: /Odtp /RTCsu /ZI
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_inline_func.h
; COMDAT _DIVIDE_CEILING_SIZE
_TEXT SEGMENT
u$ = 224
v$ = 232
_DIVIDE_CEILING_SIZE PROC ; COMDAT
; 198 : {
mov QWORD PTR [rsp+16], rdx
mov QWORD PTR [rsp+8], rcx
push rbp
push rdi
sub rsp, 232 ; 000000e8H
lea rbp, QWORD PTR [rsp+32]
mov rdi, rsp
mov ecx, 58 ; 0000003aH
mov eax, -858993460 ; ccccccccH
rep stosd
mov rcx, QWORD PTR [rsp+264]
lea rcx, OFFSET FLAT:__6B0481B0_pmc_inline_func@h
call __CheckForDebuggerJustMyCode
; 199 : return ((u + v - 1) / v);
mov rax, QWORD PTR u$[rbp]
mov rcx, QWORD PTR v$[rbp]
lea rax, QWORD PTR [rax+rcx-1]
xor edx, edx
div QWORD PTR v$[rbp]
; 200 : }
lea rsp, QWORD PTR [rbp+200]
pop rdi
pop rbp
ret 0
_DIVIDE_CEILING_SIZE ENDP
_TEXT ENDS
; Function compile flags: /Odtp /RTCsu /ZI
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_inline_func.h
; COMDAT _DIVIDE_CEILING_UNIT
_TEXT SEGMENT
u$ = 224
v$ = 232
_DIVIDE_CEILING_UNIT PROC ; COMDAT
; 193 : {
mov QWORD PTR [rsp+16], rdx
mov QWORD PTR [rsp+8], rcx
push rbp
push rdi
sub rsp, 232 ; 000000e8H
lea rbp, QWORD PTR [rsp+32]
mov rdi, rsp
mov ecx, 58 ; 0000003aH
mov eax, -858993460 ; ccccccccH
rep stosd
mov rcx, QWORD PTR [rsp+264]
lea rcx, OFFSET FLAT:__6B0481B0_pmc_inline_func@h
call __CheckForDebuggerJustMyCode
; 194 : return ((u + v - 1) / v);
mov rax, QWORD PTR u$[rbp]
mov rcx, QWORD PTR v$[rbp]
lea rax, QWORD PTR [rax+rcx-1]
xor edx, edx
div QWORD PTR v$[rbp]
; 195 : }
lea rsp, QWORD PTR [rbp+200]
pop rdi
pop rbp
ret 0
_DIVIDE_CEILING_UNIT ENDP
_TEXT ENDS
; Function compile flags: /Odtp /RTCsu /ZI
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_inline_func.h
; COMDAT _COPY_MEMORY_UNIT
_TEXT SEGMENT
d$ = 224
s$ = 232
count$ = 240
_COPY_MEMORY_UNIT PROC ; COMDAT
; 66 : {
mov QWORD PTR [rsp+24], r8
mov QWORD PTR [rsp+16], rdx
mov QWORD PTR [rsp+8], rcx
push rbp
push rsi
push rdi
sub rsp, 224 ; 000000e0H
lea rbp, QWORD PTR [rsp+32]
mov rdi, rsp
mov ecx, 56 ; 00000038H
mov eax, -858993460 ; ccccccccH
rep stosd
mov rcx, QWORD PTR [rsp+264]
lea rcx, OFFSET FLAT:__6B0481B0_pmc_inline_func@h
call __CheckForDebuggerJustMyCode
; 67 : #ifdef _M_IX86
; 68 : __movsd((unsigned long *)d, (unsigned long *)s, (unsigned long)count);
; 69 : #elif defined(_M_X64)
; 70 : __movsq(d, s, count);
mov rdi, QWORD PTR d$[rbp]
mov rsi, QWORD PTR s$[rbp]
mov rcx, QWORD PTR count$[rbp]
rep movsq
; 71 : #else
; 72 : #error unknown platform
; 73 : #endif
; 74 : }
lea rsp, QWORD PTR [rbp+192]
pop rdi
pop rsi
pop rbp
ret 0
_COPY_MEMORY_UNIT ENDP
_TEXT ENDS
; Function compile flags: /Odtp /RTCsu /ZI
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_uint_internal.h
; COMDAT AddToMULTI64Counter
_TEXT SEGMENT
value$ = 224
AddToMULTI64Counter PROC ; COMDAT
; 357 : {
mov DWORD PTR [rsp+8], ecx
push rbp
push rdi
sub rsp, 232 ; 000000e8H
lea rbp, QWORD PTR [rsp+32]
mov rdi, rsp
mov ecx, 58 ; 0000003aH
mov eax, -858993460 ; ccccccccH
rep stosd
mov ecx, DWORD PTR [rsp+264]
lea rcx, OFFSET FLAT:__7B8DBFC3_pmc_uint_internal@h
call __CheckForDebuggerJustMyCode
; 358 : _InterlockedExchangeAdd(&statistics_info.COUNT_MULTI64, value);
lea rax, OFFSET FLAT:statistics_info
mov ecx, DWORD PTR value$[rbp]
lock add DWORD PTR [rax], ecx
; 359 : }
lea rsp, QWORD PTR [rbp+200]
pop rdi
pop rbp
ret 0
AddToMULTI64Counter ENDP
_TEXT ENDS
; Function compile flags: /Odtp /RTCsu /ZI
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_uint_internal.h
; COMDAT AddToMULTI32Counter
_TEXT SEGMENT
value$ = 224
AddToMULTI32Counter PROC ; COMDAT
; 351 : {
mov DWORD PTR [rsp+8], ecx
push rbp
push rdi
sub rsp, 232 ; 000000e8H
lea rbp, QWORD PTR [rsp+32]
mov rdi, rsp
mov ecx, 58 ; 0000003aH
mov eax, -858993460 ; ccccccccH
rep stosd
mov ecx, DWORD PTR [rsp+264]
lea rcx, OFFSET FLAT:__7B8DBFC3_pmc_uint_internal@h
call __CheckForDebuggerJustMyCode
; 352 : _InterlockedExchangeAdd(&statistics_info.COUNT_MULTI32, value);
lea rax, OFFSET FLAT:statistics_info+4
mov ecx, DWORD PTR value$[rbp]
lock add DWORD PTR [rax], ecx
; 353 : }
lea rsp, QWORD PTR [rbp+200]
pop rdi
pop rbp
ret 0
AddToMULTI32Counter ENDP
_TEXT ENDS
; Function compile flags: /Odtp /RTCsu /ZI
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_uint_internal.h
; COMDAT IncrementMULTI64Counter
_TEXT SEGMENT
IncrementMULTI64Counter PROC ; COMDAT
; 334 : {
push rbp
push rdi
sub rsp, 232 ; 000000e8H
lea rbp, QWORD PTR [rsp+32]
mov rdi, rsp
mov ecx, 58 ; 0000003aH
mov eax, -858993460 ; ccccccccH
rep stosd
lea rcx, OFFSET FLAT:__7B8DBFC3_pmc_uint_internal@h
call __CheckForDebuggerJustMyCode
; 335 : _InterlockedIncrement(&statistics_info.COUNT_MULTI64);
lea rax, OFFSET FLAT:statistics_info
lock inc DWORD PTR [rax]
; 336 : }
lea rsp, QWORD PTR [rbp+200]
pop rdi
pop rbp
ret 0
IncrementMULTI64Counter ENDP
_TEXT ENDS
; Function compile flags: /Odtp /RTCsu /ZI
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_uint_internal.h
; COMDAT IncrementMULTI32Counter
_TEXT SEGMENT
IncrementMULTI32Counter PROC ; COMDAT
; 328 : {
push rbp
push rdi
sub rsp, 232 ; 000000e8H
lea rbp, QWORD PTR [rsp+32]
mov rdi, rsp
mov ecx, 58 ; 0000003aH
mov eax, -858993460 ; ccccccccH
rep stosd
lea rcx, OFFSET FLAT:__7B8DBFC3_pmc_uint_internal@h
call __CheckForDebuggerJustMyCode
; 329 : _InterlockedIncrement(&statistics_info.COUNT_MULTI32);
lea rax, OFFSET FLAT:statistics_info+4
lock inc DWORD PTR [rax]
; 330 : }
lea rsp, QWORD PTR [rbp+200]
pop rdi
pop rbp
ret 0
IncrementMULTI32Counter ENDP
_TEXT ENDS
; Function compile flags: /Odtp /RTCsu /ZI
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_parse.c
; COMDAT PMC_TryParse
_TEXT SEGMENT
result$ = 4
no$ = 40
mask$4 = 68
source$ = 320
number_styles$ = 328
format_option$ = 336
o$ = 344
PMC_TryParse PROC ; COMDAT
; 1000 : {
$LN12:
mov QWORD PTR [rsp+32], r9
mov QWORD PTR [rsp+24], r8
mov DWORD PTR [rsp+16], edx
mov QWORD PTR [rsp+8], rcx
push rbp
push rdi
sub rsp, 328 ; 00000148H
lea rbp, QWORD PTR [rsp+32]
mov rdi, rsp
mov ecx, 82 ; 00000052H
mov eax, -858993460 ; ccccccccH
rep stosd
mov rcx, QWORD PTR [rsp+360]
lea rcx, OFFSET FLAT:__C5BBD3C1_pmc_parse@c
call __CheckForDebuggerJustMyCode
; 1001 : PMC_STATUS_CODE result;
; 1002 : if (source == NULL)
cmp QWORD PTR source$[rbp], 0
jne SHORT $LN2@PMC_TryPar
; 1003 : return (PMC_STATUS_ARGUMENT_ERROR);
mov eax, -1
jmp $LN1@PMC_TryPar
$LN2@PMC_TryPar:
; 1004 : if (o == NULL)
cmp QWORD PTR o$[rbp], 0
jne SHORT $LN3@PMC_TryPar
; 1005 : return (PMC_STATUS_ARGUMENT_ERROR);
mov eax, -1
jmp $LN1@PMC_TryPar
$LN3@PMC_TryPar:
; 1006 : if (format_option == NULL)
cmp QWORD PTR format_option$[rbp], 0
jne SHORT $LN4@PMC_TryPar
; 1007 : format_option = &default_number_format_option;
lea rax, OFFSET FLAT:default_number_format_option
mov QWORD PTR format_option$[rbp], rax
$LN4@PMC_TryPar:
; 1008 : NUMBER_HEADER* no;
; 1009 : if (number_styles & PMC_NUMBER_STYLE_ALLOW_HEX_SPECIFIER)
mov eax, DWORD PTR number_styles$[rbp]
and eax, 512 ; 00000200H
test eax, eax
je SHORT $LN5@PMC_TryPar
; 1010 : {
; 1011 : // 許可されている組み合わせのフラグ
; 1012 : _UINT32_T mask = PMC_NUMBER_STYLE_ALLOW_HEX_SPECIFIER | PMC_NUMBER_STYLE_ALLOW_LEADING_WHITE | PMC_NUMBER_STYLE_ALLOW_TRAILING_WHITE;
mov DWORD PTR mask$4[rbp], 515 ; 00000203H
; 1013 :
; 1014 : // 許可されていないフラグが指定されていればエラー
; 1015 : if (number_styles & ~mask)
mov eax, DWORD PTR mask$4[rbp]
not eax
mov ecx, DWORD PTR number_styles$[rbp]
and ecx, eax
mov eax, ecx
test eax, eax
je SHORT $LN7@PMC_TryPar
; 1016 : return (PMC_STATUS_ARGUMENT_ERROR);
mov eax, -1
jmp $LN1@PMC_TryPar
$LN7@PMC_TryPar:
; 1017 :
; 1018 : if ((result = TryParseX(source, number_styles, format_option, &no)) != PMC_STATUS_OK)
lea r9, QWORD PTR no$[rbp]
mov r8, QWORD PTR format_option$[rbp]
mov edx, DWORD PTR number_styles$[rbp]
mov rcx, QWORD PTR source$[rbp]
call TryParseX
mov DWORD PTR result$[rbp], eax
cmp DWORD PTR result$[rbp], 0
je SHORT $LN8@PMC_TryPar
; 1019 : return (result);
mov eax, DWORD PTR result$[rbp]
jmp SHORT $LN1@PMC_TryPar
$LN8@PMC_TryPar:
; 1020 : }
jmp SHORT $LN6@PMC_TryPar
$LN5@PMC_TryPar:
; 1021 : else
; 1022 : {
; 1023 : if ((result = TryParseDN(source, number_styles, format_option, &no)) != PMC_STATUS_OK)
lea r9, QWORD PTR no$[rbp]
mov r8, QWORD PTR format_option$[rbp]
mov edx, DWORD PTR number_styles$[rbp]
mov rcx, QWORD PTR source$[rbp]
call TryParseDN
mov DWORD PTR result$[rbp], eax
cmp DWORD PTR result$[rbp], 0
je SHORT $LN9@PMC_TryPar
; 1024 : return (result);
mov eax, DWORD PTR result$[rbp]
jmp SHORT $LN1@PMC_TryPar
$LN9@PMC_TryPar:
$LN6@PMC_TryPar:
; 1025 : }
; 1026 : *o = no;
mov rax, QWORD PTR o$[rbp]
mov rcx, QWORD PTR no$[rbp]
mov QWORD PTR [rax], rcx
; 1027 : #ifdef _DEBUG
; 1028 : if ((result = CheckNumber(*o)) != PMC_STATUS_OK)
mov rax, QWORD PTR o$[rbp]
mov rcx, QWORD PTR [rax]
call CheckNumber
mov DWORD PTR result$[rbp], eax
cmp DWORD PTR result$[rbp], 0
je SHORT $LN10@PMC_TryPar
; 1029 : return (result);
mov eax, DWORD PTR result$[rbp]
jmp SHORT $LN1@PMC_TryPar
$LN10@PMC_TryPar:
; 1030 : #endif
; 1031 : return (PMC_STATUS_OK);
xor eax, eax
$LN1@PMC_TryPar:
; 1032 : }
mov rdi, rax
lea rcx, QWORD PTR [rbp-32]
lea rdx, OFFSET FLAT:PMC_TryParse$rtcFrameData
call _RTC_CheckStackVars
mov rax, rdi
lea rsp, QWORD PTR [rbp+296]
pop rdi
pop rbp
ret 0
PMC_TryParse ENDP
_TEXT ENDS
; Function compile flags: /Odtp /RTCsu /ZI
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_parse.c
; COMDAT Initialize_Parse
_TEXT SEGMENT
feature$ = 224
Initialize_Parse PROC ; COMDAT
; 1035 : {
$LN5:
mov QWORD PTR [rsp+8], rcx
push rbp
push rdi
sub rsp, 232 ; 000000e8H
lea rbp, QWORD PTR [rsp+32]
mov rdi, rsp
mov ecx, 58 ; 0000003aH
mov eax, -858993460 ; ccccccccH
rep stosd
mov rcx, QWORD PTR [rsp+264]
lea rcx, OFFSET FLAT:__C5BBD3C1_pmc_parse@c
call __CheckForDebuggerJustMyCode
; 1036 : default_number_format_option.DecimalDigits = 2;
mov DWORD PTR default_number_format_option, 2
; 1037 : lstrcpyW(default_number_format_option.GroupSeparator, L",");
lea rdx, OFFSET FLAT:??_C@_13DEFPDAGF@?$AA?0@
lea rcx, OFFSET FLAT:default_number_format_option+4
call QWORD PTR __imp_lstrcpyW
; 1038 : lstrcpyW(default_number_format_option.DecimalSeparator, L".");
lea rdx, OFFSET FLAT:??_C@_13JOFGPIOO@?$AA?4@
lea rcx, OFFSET FLAT:default_number_format_option+10
call QWORD PTR __imp_lstrcpyW
; 1039 : lstrcpy(default_number_format_option.GroupSizes, "3");
lea rdx, OFFSET FLAT:??_C@_01EKENIIDA@3@
lea rcx, OFFSET FLAT:default_number_format_option+28
call QWORD PTR __imp_lstrcpyA
; 1040 : lstrcpyW(default_number_format_option.PositiveSign, L"+");
lea rdx, OFFSET FLAT:??_C@_13KJIIAINM@?$AA?$CL@
lea rcx, OFFSET FLAT:default_number_format_option+16
call QWORD PTR __imp_lstrcpyW
; 1041 : lstrcpyW(default_number_format_option.NegativeSign, L"-");
lea rdx, OFFSET FLAT:??_C@_13IMODFHAA@?$AA?9@
lea rcx, OFFSET FLAT:default_number_format_option+22
call QWORD PTR __imp_lstrcpyW
; 1042 :
; 1043 : if (feature->PROCESSOR_FEATURE_ADX && feature->PROCESSOR_FEATURE_BMI2)
mov rax, QWORD PTR feature$[rbp]
mov eax, DWORD PTR [rax]
shr eax, 1
and eax, 1
test eax, eax
je SHORT $LN2@Initialize
mov rax, QWORD PTR feature$[rbp]
mov eax, DWORD PTR [rax]
shr eax, 3
and eax, 1
test eax, eax
je SHORT $LN2@Initialize
; 1044 : fp_MultiplyAndAdd = MultiplyAndAdd_using_ADCX_MULX;
lea rax, OFFSET FLAT:MultiplyAndAdd_using_ADCX_MULX
mov QWORD PTR fp_MultiplyAndAdd, rax
jmp SHORT $LN3@Initialize
$LN2@Initialize:
; 1045 : else
; 1046 : fp_MultiplyAndAdd = MultiplyAndAdd_using_ADC_MUL;
lea rax, OFFSET FLAT:MultiplyAndAdd_using_ADC_MUL
mov QWORD PTR fp_MultiplyAndAdd, rax
$LN3@Initialize:
; 1047 :
; 1048 : return (PMC_STATUS_OK);
xor eax, eax
; 1049 : }
lea rsp, QWORD PTR [rbp+200]
pop rdi
pop rbp
ret 0
Initialize_Parse ENDP
_TEXT ENDS
END
|
oeis/329/A329943.asm | neoneye/loda-programs | 11 | 83522 | ; A329943: Square array read by antidiagonals: T(n,k) is the number of right total relations between set A with n elements and set B with k elements.
; Submitted by <NAME>
; 1,3,1,7,9,1,15,49,27,1,31,225,343,81,1,63,961,3375,2401,243,1,127,3969,29791,50625,16807,729,1,255,16129,250047,923521,759375,117649,2187,1,511,65025,2048383,15752961,28629151,11390625,823543,6561,1
lpb $0
add $1,1
sub $0,$1
mov $2,$1
sub $2,$0
lpe
add $0,1
mov $1,2
pow $1,$2
mov $2,$1
mul $2,2
sub $2,1
pow $2,$0
mov $0,$2
|
1-source-files/original-sources/converted_source_files/a.tcode_3.asm | markmoxon/elite-a-beebasm | 16 | 82059 | <gh_stars>10-100
.msg_1
EQUB &00
EQUS &09, &0B, &01, &08, " ", &F1, "SK AC", &E9, "SS ME", &E1, &D7, &0A, &02, "1. ", &95, &D7, "2. SA", &FA
EQUS " ", &9A, " ", &04, &D7, "3. C", &F5, "A", &E0, "GUE", &D7, "4. DEL", &DD, "E", &D0, "FI", &E5, &D7, "5. E"
EQUS "X", &DB, &D7
EQUB &00
EQUS &0C, "WHICH ", &97, "?"
EQUB &00
\ EQUA "ARE YOU SURE?"
EQUS &EE, "E ", &B3, " SU", &F2, "?"
EQUB &00
EQUS &96, &97, " ", &10, &98, &D7
EQUB &00
EQUS &B0, "m", &CA, "n", &B1
EQUB &00
EQUS " ", &95, " ", &01, "(Y/N)?", &02, &0C, &0C
EQUB &00
EQUS "P", &F2, "SS SPA", &E9, " ", &FD, " FI", &F2, ",", &9A, ".", &0C, &0C
EQUB &00
EQUS &9A, "'S", &C8
EQUB &00
EQUS &15, "FI", &E5, &C9, "DEL", &DD, "E?"
EQUB &00
EQUS &17, &0E, &02, "G", &F2, &DD, &F0, "GS", &D5, &B2, &13, "I ", &F7, "G", &D0, "MOM", &F6, "T OF ", &B3, "R V", &E4
EQUS "U", &D8, &E5, " ", &FB, "ME", &CC, "WE W", &D9, "LD LIKE ", &B3, &C9, "DO", &D0, "L", &DB, "T", &E5, " JO"
EQUS "B F", &FD, " ", &EC, &CC, &93, &CF, " ", &B3, " ", &DA, "E HE", &F2, &CA, "A", &D2, "MODEL, ", &93
EQUS &13, "C", &DF, &DE, "RICT", &FD, ", E", &FE, "IP", &C4, "WI", &E2, &D0, "TOP ", &DA, "CR", &DD, &D2, "SHI"
EQUS "ELD G", &F6, &F4, &F5, &FD, &CC, "UNF", &FD, "TUN", &F5, "ELY ", &DB, "'S ", &F7, &F6, " ", &DE, "O"
EQUS "L", &F6, &CC, &16, &DB, " W", &F6, "T MISS", &C3, "FROM ", &D9, "R ", &CF, " Y", &EE, "D ", &DF, " ", &13, &E6
EQUS &F4, " FI", &FA, " M", &DF, &E2, "S AGO", &B2, &1C, &CC, &B3, "R MISSI", &DF, ", SH", &D9, "LD "
EQUS &B3, " DECIDE", &C9, "AC", &E9, "PT ", &DB, ", IS", &C9, &DA, "EK", &B2, "D", &ED, "TROY ", &94, &CF
EQUS &CC, &B3, " A", &F2, " CAU", &FB, &DF, &C4, &E2, &F5, " ", &DF, "LY ", &06, "u", &05, "S W", &DC, "L P", &F6
EQUS &DD, &F8, "TE ", &93, "NEW SHIELDS", &B2, &E2, &F5, " ", &93, &13, "C", &DF, &DE, "RICT", &FD
EQUS &CA, "F", &DB, "T", &C4, "WI", &E2, " ", &FF, " ", &06, "l", &05, &B1, &02, &08, "GOOD LUCK, ", &9A, &D4, &16
EQUB &00
EQUS &19, &09, &17, &0E, &02, " ", &F5, "T", &F6, &FB, &DF, &D5, ". ", &13, "WE HA", &FA, " NE", &C4, "OF ", &B3, "R"
EQUS " ", &DA, "RVIC", &ED, " AGA", &F0, &CC, "IF ", &B3, " W", &D9, "LD ", &F7, " ", &EB, " GOOD AS", &C9
EQUS "GO", &C9, &13, &E9, &F4, &F1, " ", &B3, " W", &DC, "L ", &F7, " BRIEF", &FC, &CC, "IF SUC", &E9, "S"
EQUS "SFUL, ", &B3, " W", &DC, "L ", &F7, " WELL ", &F2, "W", &EE, "D", &FC, &D4, &18
EQUB &00
EQUS "(", &13, "C) AC", &FD, "N", &EB, "FT 1984"
EQUB &00
EQUS "BY D.B", &F8, &F7, "N & I.", &F7, "LL"
EQUB &00
EQUS &15, &91, &C8, &1A
EQUB &00
EQUS &19, &09, &17, &0E, &02, " C", &DF, "G", &F8, "TU", &F9, &FB, &DF, "S ", &9A, "!", &0C, &0C, &E2, &F4, "E", &0D, " W"
EQUS &DC, "L ", &E4, "WAYS ", &F7, &D0, "P", &F9, &E9, " F", &FD, " ", &B3, " ", &F0, &D3, &CC, &FF, "D ", &EF
EQUS "Y", &F7, " ", &EB, &DF, &F4, " ", &E2, &FF, " ", &B3, " ", &E2, &F0, "K..", &D4, &18
EQUB &00
EQUS "F", &D8, &E5, "D"
EQUB &00
EQUS &E3, "T", &D8, &E5
EQUB &00
EQUS "WELL K", &E3, "WN"
EQUB &00
EQUS "FAMO", &EC
EQUB &00
EQUS &E3, "T", &FC
EQUB &00
EQUS &FA, "RY"
EQUB &00
EQUS "M", &DC, "DLY"
EQUB &00
EQUS "MO", &DE
EQUB &00
EQUS &F2, "AS", &DF, &D8, "LY"
EQUB &00
EQUB &00
EQUS &A5
EQUB &00
EQUS "r"
EQUB &00
EQUS "G", &F2, &F5
EQUB &00
EQUS "VA", &DE
EQUB &00
EQUS "P", &F0, "K"
EQUB &00
EQUS &02, "w v", &0D, " ", &B9, "A", &FB, &DF, "S"
EQUB &00
EQUS &9C, "S"
EQUB &00
EQUS "u"
EQUB &00
EQUS &80, " F", &FD, &ED, "TS"
EQUB &00
EQUS "O", &E9, &FF, "S"
EQUB &00
EQUS "SHYN", &ED, "S"
EQUB &00
EQUS "S", &DC, "L", &F0, &ED, "S"
EQUB &00
EQUS &EF, "T", &C3, "T", &F8, &F1, &FB, &DF, "S"
EQUB &00
EQUS &E0, &F5, "H", &C3, "OF d"
EQUB &00
EQUS &E0, &FA, " F", &FD, " d"
EQUB &00
EQUS "FOOD B", &E5, "ND", &F4, "S"
EQUB &00
EQUS "T", &D9, "RI", &DE, "S"
EQUB &00
EQUS "PO", &DD, "RY"
EQUB &00
EQUS &F1, "SCOS"
EQUB &00
EQUS "l"
EQUB &00
EQUS "W", &E4, "K", &C3, &9E
EQUB &00
EQUS "C", &F8, "B"
EQUB &00
EQUS "B", &F5
EQUB &00
EQUS &E0, "B", &DE
EQUB &00
EQUS &12
EQUB &00
EQUS &F7, "S", &DD
EQUB &00
EQUS "P", &F9, "GU", &FC
EQUB &00
EQUS &F8, "VAG", &FC
EQUB &00
EQUS "CURS", &FC
EQUB &00
EQUS "SC", &D9, "RG", &FC
EQUB &00
EQUS "q CIV", &DC, " W", &EE
EQUB &00
EQUS "h _ `S"
EQUB &00
EQUS "A h ", &F1, &DA, "A", &DA
EQUB &00
EQUS "q E", &EE, &E2, &FE, "AK", &ED
EQUB &00
EQUS "q ", &EB, &F9, "R AC", &FB, "V", &DB, "Y"
EQUB &00
EQUS &AF, "] ^"
EQUB &00
EQUS &93, &11, " _ `"
EQUB &00
EQUS &AF, &C1, "S' b c"
EQUB &00
EQUS &02, "z", &0D
EQUB &00
EQUS &AF, "k l"
EQUB &00
EQUS "JUI", &E9
EQUB &00
EQUS "B", &F8, "NDY"
EQUB &00
EQUS "W", &F5, &F4
EQUB &00
EQUS "B", &F2, "W"
EQUB &00
EQUS "G", &EE, "G", &E5, " B", &F9, &DE, &F4, "S"
EQUB &00
EQUS &12
EQUB &00
EQUS &11, " `"
EQUB &00
EQUS &11, " ", &12
EQUB &00
EQUS &11, " h"
EQUB &00
EQUS "h ", &12
EQUB &00
EQUS "F", &D8, "U", &E0, &EC
EQUB &00
EQUS "EXO", &FB, "C"
EQUB &00
EQUS "HOOPY"
EQUB &00
EQUS "U", &E1, "SU", &E4
EQUB &00
EQUS "EXC", &DB, &F0, "G"
EQUB &00
EQUS "CUIS", &F0, "E"
EQUB &00
EQUS "NIGHT LIFE"
EQUB &00
EQUS "CASI", &E3, "S"
EQUB &00
EQUS "S", &DB, " COMS"
EQUB &00
EQUS &02, "z", &0D
EQUB &00
EQUS &03
EQUB &00
EQUS &93, &91, " ", &03
EQUB &00
EQUS &93, &92, " ", &03
EQUB &00
EQUS &94, &91
EQUB &00
EQUS &94, &92
EQUB &00
EQUS "S", &DF, " OF", &D0, "B", &DB, "CH"
EQUB &00
EQUS "SC", &D9, "ND", &F2, "L"
EQUB &00
EQUS "B", &F9, "CKGU", &EE, "D"
EQUB &00
EQUS "ROGUE"
EQUB &00
EQUS "WH", &FD, &ED, &DF, " ", &F7, &DD, &E5, " HEAD", &C6, "F", &F9, "P E", &EE, "'D KNA", &FA
EQUB &00
EQUS "N UN", &F2, &EF, "RK", &D8, &E5
EQUB &00
EQUS " B", &FD, &F0, "G"
EQUB &00
EQUS " DULL"
EQUB &00
EQUS " TE", &F1, "O", &EC
EQUB &00
EQUS " ", &F2, "VOLT", &F0, "G"
EQUB &00
EQUS &91
EQUB &00
EQUS &92
EQUB &00
EQUS "P", &F9, &E9
EQUB &00
EQUS "L", &DB, "T", &E5, " ", &91
EQUB &00
EQUS "DUMP"
EQUB &00
EQUS "I HE", &EE, &D0, "r ", &E0, "OK", &C3, &CF, " APPE", &EE, &C4, &F5, &D1
EQUB &00
EQUS "YEAH, I HE", &EE, &D0, "r ", &CF, " ", &E5, "FT", &D1, &D0, " WHI", &E5, " BACK"
EQUB &00
EQUS "G", &DD, " ", &B3, "R IR", &DF, " ASS OV", &F4, " TO", &D1
EQUB &00
EQUS &EB, "ME s", &D2, &CF, " WAS ", &DA, &F6, " ", &F5, &D1
EQUB &00
EQUS "TRY", &D1
EQUB &00
EQUS &01, "SPECI", &E4, " C", &EE, "GO"
EQUB &00
EQUB &00
EQUS "C", &EE, "GO V", &E4, "UE:"
EQUB &00
EQUS " MO", &F1, "FI", &FC, " BY A.J.C.DUGG", &FF
EQUB &00
EQUS "WASP"
EQUB &00
EQUS "MO", &E2
EQUB &00
EQUS "GRUB"
EQUB &00
EQUS &FF, "T"
EQUB &00
EQUS &12
EQUB &00
EQUS "PO", &DD
EQUB &00
EQUS &EE, "TS G", &F8, "DU", &F5, "E"
EQUB &00
EQUS "YAK"
EQUB &00
EQUS "SNA", &DC
EQUB &00
EQUS "SLUG"
EQUB &00
EQUS "TROPIC", &E4
EQUB &00
EQUS "D", &F6, &DA
EQUB &00
EQUS &F8, &F0
EQUB &00
EQUS "IMP", &F6, &DD, &F8, "B", &E5
EQUB &00
EQUS "EXU", &F7, &F8, "NT"
EQUB &00
EQUS "FUNNY"
EQUB &00
EQUS "WI", &F4, "D"
EQUB &00
EQUS "U", &E1, "SU", &E4
EQUB &00
EQUS &DE, &F8, "N", &E7
EQUB &00
EQUS "PECULI", &EE
EQUB &00
EQUS "F", &F2, &FE, &F6, "T"
EQUB &00
EQUS "OCCASI", &DF, &E4
EQUB &00
EQUS "UNP", &F2, &F1, "CT", &D8, &E5
EQUB &00
EQUS "D", &F2, "ADFUL"
EQUB &00
EQUS &AB
EQUB &00
EQUS "\ [ F", &FD, " e"
EQUB &00
EQUS &8C, &B2, "e"
EQUB &00
EQUS "f BY g"
EQUB &00
EQUS &8C, " BUT ", &8E
EQUB &00
EQUS " Ao p"
EQUB &00
EQUS "PL", &FF, &DD
EQUB &00
EQUS "W", &FD, "LD"
EQUB &00
EQUS &E2, "E "
EQUB &00
EQUS &E2, "IS "
EQUB &00
EQUS &E0, "AD", &D2, &9A
EQUB &00
EQUS &09, &0B, &01, &08
EQUB &00
EQUS "DRI", &FA
EQUB &00
EQUS " C", &F5, "A", &E0, "GUE"
EQUB &00
EQUS "I", &FF
EQUB &00
EQUS &13, "COMM", &FF, "D", &F4
EQUB &00
EQUS "h"
EQUB &00
EQUS "M", &D9, "NTA", &F0
EQUB &00
EQUS &FC, "IB", &E5
EQUB &00
EQUS "T", &F2, "E"
EQUB &00
EQUS "SPOTT", &FC
EQUB &00
EQUS "x"
EQUB &00
EQUS "y"
EQUB &00
EQUS "aOID"
EQUB &00
EQUS &7F
EQUB &00
EQUS "~"
EQUB &00
EQUS &FF, "CI", &F6, "T"
EQUB &00
EQUS "EX", &E9, "P", &FB, &DF, &E4
EQUB &00
EQUS "EC", &E9, "NTRIC"
EQUB &00
EQUS &F0, "G", &F8, &F0, &FC
EQUB &00
EQUS "r"
EQUB &00
EQUS "K", &DC, "L", &F4
EQUB &00
EQUS "DEADLY"
EQUB &00
EQUS "EV", &DC
EQUB &00
EQUS &E5, &E2, &E4
EQUB &00
EQUS "VICIO", &EC
EQUB &00
EQUS &DB, "S "
EQUB &00
EQUS &0D, &0E, &13
EQUB &00
EQUS ".", &0C, &0F
EQUB &00
EQUS " ", &FF, "D "
EQUB &00
EQUS "Y", &D9
EQUB &00
EQUS "P", &EE, "K", &C3, "M", &DD, &F4, "S"
EQUB &00
EQUS "D", &EC, "T C", &E0, "UDS"
EQUB &00
EQUS "I", &E9, " ", &F7, "RGS"
EQUB &00
EQUS "ROCK F", &FD, &EF, &FB, &DF, "S"
EQUB &00
EQUS "VOLCA", &E3, &ED
EQUB &00
EQUS "PL", &FF, "T"
EQUB &00
EQUS "TULIP"
EQUB &00
EQUS "B", &FF, &FF, "A"
EQUB &00
EQUS "C", &FD, "N"
EQUB &00
EQUS &12, "WE", &FC
EQUB &00
EQUS &12
EQUB &00
EQUS &11, " ", &12
EQUB &00
EQUS &11, " h"
EQUB &00
EQUS &F0, "HA", &EA, "T", &FF, "T"
EQUB &00
EQUS &BF
EQUB &00
EQUS &F0, "G "
EQUB &00
EQUS &FC, " "
EQUB &00
EQUB &00
EQUB &00
EQUB &00
EQUS " NAME? "
EQUB &00
EQUS " TO "
EQUB &00
EQUS " IS "
EQUB &00
EQUS "WAS ", &F9, &DE, " ", &DA, &F6, " ", &F5, " ", &13
EQUB &00
EQUS ".", &0C, " ", &13
EQUB &00
EQUS "DOCK", &FC
EQUB &00
EQUS &01, "(Y/N)?"
EQUB &00
EQUS "SHIP"
EQUB &00
EQUS " A "
EQUB &00
EQUS " ", &F4, "RI", &EC
EQUB &00
EQUS " NEW "
EQUB &00
EQUS &02, " H", &F4, " ", &EF, "J", &ED, "TY'S SPA", &E9, " NAVY", &0D
EQUB &00
EQUS &B1, &08, &01, " M", &ED, "SA", &E7, " ", &F6, "DS"
EQUB &00
EQUS " ", &9A, " ", &04, ", I ", &0D, "AM", &02, " CAPTA", &F0, " ", &1B, " ", &0D, "OF", &D3
EQUB &00
EQUB &00
EQUS &0F, " UNK", &E3, "WN ", &91
EQUB &00
EQUS &09, &08, &17, &01, &F0, "COM", &C3, "M", &ED, "SA", &E7
EQUB &00
EQUS "CURRU", &E2, &F4, "S"
EQUB &00
EQUS "FOSDYKE SMY", &E2, "E"
EQUB &00
EQUS "F", &FD, "T", &ED, &FE, "E"
EQUB &00
EQUS &CB, &F2, &ED, &F1, &E9
EQUB &00
EQUS "IS ", &F7, "LIEV", &FC, &C9, "HA", &FA, " JUMP", &FC, &C9, &94, "G", &E4, "AXY"
EQUB &00
EQUS &19, &09, &1D, &0E, &02, "GOOD DAY ", &9A, " ", &04, &CC, "I", &0D, " AM ", &13, "AG", &F6, "T ", &13, "B", &F9, "KE"
EQUS " OF ", &13, "NAV", &E4, " ", &13, &F0, "TEL", &E5, "G", &F6, &E9, &CC, "AS ", &B3, " K", &E3, "W, ", &93, &13
EQUS "NAVY HA", &FA, " ", &F7, &F6, " KEEP", &C3, &93, &13, &E2, &EE, "GOIDS OFF ", &B3, "R A"
EQUS "SS ", &D9, "T ", &F0, " DEEP SPA", &E9, " F", &FD, " ", &EF, "NY YE", &EE, "S ", &E3, "W. ", &13, "WEL"
EQUS "L ", &93, "S", &DB, "UA", &FB, &DF, " HAS CH", &FF, "G", &FC, &CC, &D9, "R BOYS ", &EE, "E ", &F2
EQUS "ADY F", &FD, &D0, "P", &EC, "H RIGHT", &C9, &93, "HOME SY", &DE, "EM OF ", &E2, "O", &DA, " MO"
EQUS &E2, &F4, "S", &CC, &18, &09, &1D, "I", &0D, " HA", &FA, " OBTA", &F0, &C4, &93, "DEF", &F6, &E9, " P", &F9
EQUS "NS F", &FD, " ", &E2, "EIR ", &13, "HI", &FA, " ", &13, "W", &FD, "LDS", &CC, &93, &F7, &DD, &E5, "S K", &E3
EQUS "W WE'", &FA, " GOT ", &EB, "ME", &E2, &C3, "BUT ", &E3, "T WH", &F5, &CC, "IF ", &13, "I T", &F8, "N"
EQUS "SM", &DB, " ", &93, "P", &F9, "NS", &C9, &D9, "R BA", &DA, " ", &DF, " ", &13, &EA, &F2, &F8, " ", &E2, "EY'L"
EQUS "L ", &F0, "T", &F4, &E9, "PT ", &93, "TR", &FF, "SMISSI", &DF, ". ", &13, "I NE", &FC, &D0, &CF, &C9
EQUS &EF, "KE ", &93, "RUN", &CC, &B3, "'", &F2, " E", &E5, "CT", &FC, &CC, &93, "P", &F9, "NS A", &F2, " "
EQUS "UNIPUL", &DA, " COD", &C4, "WI", &E2, &F0, " ", &94, "TR", &FF, "SMISSI", &DF, &CC, &08, &B3, " "
EQUS "W", &DC, "L ", &F7, " PAID", &CC, " ", &13, "GOOD LUCK ", &9A, &D4, &18
EQUB &00
EQUS &19, &09, &1D, &08, &0E, &0D, &13, "WELL D", &DF, "E ", &9A, &CC, &B3, " HA", &FA, " ", &DA, "RV", &C4, &EC, " "
EQUS "WELL", &B2, "WE SH", &E4, "L ", &F2, "MEMB", &F4, &CC, "WE ", &F1, "D ", &E3, "T EXPECT ", &93
EQUS &13, &E2, &EE, "GOIDS", &C9, "F", &F0, "D ", &D9, "T ", &D8, &D9, "T ", &B3, &CC, "F", &FD, " ", &93, "MOM", &F6
EQUS "T P", &E5, "A", &DA, " AC", &E9, "PT ", &94, &13, "NAVY ", &06, "r", &05, " AS PAYM", &F6, "T", &D4, &18
EQUB &00
EQUB &00
EQUS "SH", &F2, "W"
EQUB &00
EQUS &F7, "A", &DE
EQUB &00
EQUS &EA, "S", &DF
EQUB &00
EQUS "SNAKE"
EQUB &00
EQUS "WOLF"
EQUB &00
EQUS &E5, "OP", &EE, "D"
EQUB &00
EQUS "C", &F5
EQUB &00
EQUS "M", &DF, "KEY"
EQUB &00
EQUS "GO", &F5
EQUB &00
EQUS "FISH"
EQUB &00
EQUS "j i"
EQUB &00
EQUS &11, " x {"
EQUB &00
EQUS &AF, "k y {"
EQUB &00
EQUS &7C, " }"
EQUB &00
EQUS "j i"
EQUB &00
EQUS "ME", &F5
EQUB &00
EQUS "CUTL", &DD
EQUB &00
EQUS &DE, "EAK"
EQUB &00
EQUS "BURG", &F4, "S"
EQUB &00
EQUS &EB, "UP"
EQUB &00
EQUS "I", &E9
EQUB &00
EQUS "MUD"
EQUB &00
EQUS "Z", &F4, "O-", &13, "G"
EQUB &00
EQUS "VACUUM"
EQUB &00
EQUS &11, " ULT", &F8
EQUB &00
EQUS "HOCKEY"
EQUB &00
EQUS "CRICK", &DD
EQUB &00
EQUS "K", &EE, &F5, "E"
EQUB &00
EQUS "PO", &E0
EQUB &00
EQUS "T", &F6, "NIS"
EQUB &00
.l_5338
EQUB &00
.misn_data1
EQUB &D3, &96, &24, &1C, &FD, &4F, &35, &76, &64, &20, &44, &A4
EQUB &DC, &6A, &10, &A2, &03, &6B, &1A, &C0, &B8, &05, &65, &C1
.misn_data2
EQUB &29, &80, &00, &00, &00, &01, &01, &01, &01, &82, &01, &01
EQUB &01, &01, &01, &01, &01, &01, &01, &01, &01, &01, &01, &02
EQUB &01, &82
.msg_2
EQUB &00
EQUS &93, "CO", &E0, "NI", &DE, "S HE", &F2, " HA", &FA, " VIOL", &F5, &FC, &02, " ", &F0, "T", &F4, "G", &E4
EQUS "AC", &FB, "C C", &E0, "N", &C3, "PROTOCOL", &0D, &B2, "SH", &D9, "LD ", &F7, " AVOID", &FC
EQUB &00
EQUS &93, "C", &DF, &DE, "RICT", &FD, " ", &CB, &F2, &ED, &F1, &E9, ", ", &9A
EQUB &00
EQUS "A r ", &E0, "OK", &C3, &CF, " ", &E5, "FT HE", &F2, &D0, "WHI", &E5, " BACK. ", &E0, "OK", &C4, "B", &D9
EQUS "ND F", &FD, " ", &EE, "E", &E6
EQUB &00
EQUS "YEP,", &D0, "r", &D2, &CF, " HAD", &D0, "G", &E4, "AC", &FB, "C HYP", &F4, "DRI", &FA, " F", &DB, "T", &C4
EQUS "HE", &F2, ". ", &EC, &C4, &DB, " TOO"
EQUB &00
EQUS &94, " r ", &CF, " DEHYP", &C4, "HE", &F2, " FROM ", &E3, "WHE", &F2, ", SUN SKIMM", &FC
EQUS &B2, "JUMP", &FC, ". I HE", &EE, " ", &DB, " W", &F6, "T", &C9, &F0, &EA, &F7
EQUB &00
EQUS "s ", &CF, " W", &F6, "T F", &FD, " ME ", &F5, " A", &EC, &EE, ". MY ", &F9, "S", &F4, "S ", &F1, "DN'T E"
EQUS "V", &F6, " SC", &F8, "TCH ", &93, "s"
EQUB &00
EQUS "OH DE", &EE, " ME Y", &ED, ".", &D0, "FRIGHTFUL ROGUE WI", &E2, " WH", &F5, " I ", &F7
EQUS "LIE", &FA, " ", &B3, " PEOP", &E5, " C", &E4, "L", &D0, &E5, "AD PO", &DE, &F4, "I", &FD, " SHOT UP"
EQUS " ", &E0, "TS OF ", &E2, "O", &DA, " ", &F7, "A", &DE, "LY PI", &F8, "T", &ED, &B2, "W", &F6, "T", &C9, &EC, &E5
EQUS "RI"
EQUB &00
EQUS &B3, " C", &FF, " TACK", &E5, " ", &93, "h s IF ", &B3, " LIKE. HE'S ", &F5, " ", &FD, &EE
EQUS &F8
EQUB &00
EQUS &01, "COM", &C3, &EB, &DF, ": EL", &DB, "E III"
EQUB &00
EQUS "t"
EQUB &00
EQUS "t"
EQUB &00
EQUS "t"
EQUB &00
EQUS "t"
EQUB &00
EQUS "t"
EQUB &00
EQUS "t"
EQUB &00
EQUS "t"
EQUB &00
EQUS "t"
EQUB &00
EQUS "t"
EQUB &00
EQUS "t"
EQUB &00
EQUS "t"
EQUB &00
EQUS "t"
EQUB &00
EQUS "t"
EQUB &00
EQUS "BOY A", &F2, " ", &B3, " ", &F0, " ", &93, "WR", &DF, "G G", &E4, "AXY!"
EQUB &00
EQUS &E2, &F4, "E'S", &D0, &F2, &E4, " s PI", &F8, "TE ", &D9, "T ", &E2, &F4, "E"
EQUB &00
EQUS &93, &C1, "<NAME>", &F2, " ", &EB, " A", &EF, "Z", &F0, "<NAME>", &FB, &FA, " ", &E2, &F5
EQUS " ", &E2, "EY ", &DE, &DC, "L ", &E2, &F0, "K ", &13, "EL", &DB, "E", &CA, "A P", &F2, "TTY NE", &F5, " GAME"
EQUB &00
.l_55c0
EQUB &10, &15, &1A, &1F, &9B, &A0, &2E, &A5, &24, &29, &3D, &33
EQUB &38, &AA, &42, &47, &4C, &51, &56, &8C, &60, &65, &87, &82
EQUB &5B, &6A, &B4, &B9, &BE, &E1, &E6, &EB, &F0, &F5, &FA, &73
EQUB &78, &7D
|
Lab_6/C_Task_1.a51 | DeeptimaanB/8051_Programs | 0 | 87008 | <gh_stars>0
;Write an 8051 assembly language program to toggle all the bits of P1 for every 1 Seconds.
;Assume the crystal frequency as 11.0592 MHz. Verify the output using ESA 8051 Microcontroller kit.
ORG 0000H
MOV P1,#00H ;o/p
BACK: MOV A,#55H
MOV P1,A
ACALL DELAY
MOV A, #0AAH
MOV P1,A
ACALL DELAY
SJMP BACK
DELAY:MOV R2,#08H
HERE3:MOV R1,#0FFH
HERE2:MOV R0,#0FFH
HERE1:DJNZ R0,HERE1
DJNZ R1,HERE2
DJNZ R2, HERE3
RET
END ;Deeptimaan Banerjee
|
Monoids.agda | jmchapman/Relative-Monads | 21 | 11521 | module Monoids where
open import Library
record Monoid {a} : Set (lsuc a) where
field S : Set a
ε : S
_•_ : S → S → S
lid : ∀{m} → ε • m ≅ m
rid : ∀{m} → m • ε ≅ m
ass : ∀{m n o} → (m • n) • o ≅ m • (n • o)
infix 10 _•_
Nat+Mon : Monoid
Nat+Mon = record {
S = ℕ;
ε = zero;
_•_ = _+_;
lid = refl;
rid = ≡-to-≅ $ +-right-identity _;
ass = λ{m} → ≡-to-≅ $ +-assoc m _ _}
|
_anim/SBZ Spin Platform Conveyor.asm | kodishmediacenter/msu-md-sonic | 9 | 240137 | <reponame>kodishmediacenter/msu-md-sonic
; ---------------------------------------------------------------------------
; Animation script - platform on conveyor belt (SBZ)
; ---------------------------------------------------------------------------
Ani_SpinConvey: dc.w @spin-Ani_SpinConvey
dc.w @still-Ani_SpinConvey
@spin: dc.b 0, 0, 1, 2, 3, 4, $43, $42, $41, $40, $61, $62, $63
dc.b $64, $23, $22, $21, 0, afEnd
even
@still: dc.b $F, 0, afEnd
even |
oeis/293/A293163.asm | neoneye/loda-programs | 11 | 167408 | <filename>oeis/293/A293163.asm<gh_stars>10-100
; A293163: a(n) = A010060(3n+1).
; 1,1,1,0,1,1,1,1,1,1,1,0,1,0,0,0,1,1,1,0,1,1,1,1,1,1,1,1,0,1,1,1,1,1,1,0,1,1,1,1,1,1,1,0,1,0,0,0,1,1,1,0,1,0,0,0,0,0,0,0,1,0,0,0,1,1,1,0,1,1,1,1,1,1,1,0,1,0,0,0,1,1,1,0,1,1,1,1,1,1,1,1,0,1,1,1,1,1,1,0
mul $0,3
add $0,1
seq $0,120 ; 1's-counting sequence: number of 1's in binary expansion of n (or the binary weight of n).
mod $0,2
|
lib/chibiakumas/SrcALL/V1_Functions.asm | gilbertfrancois/msx | 0 | 16062 | <reponame>gilbertfrancois/msx
ifdef BuildCPC
read "..\SrcCPC\CPC_V1_Functions.asm"
endif
ifdef BuildMSX
read "..\SrcMSX\MSX_V1_Functions.asm"
endif
ifdef BuildTI8
read "..\SrcTI\TI_V1_Functions.asm"
endif
ifdef BuildZX8 ;ZX81
read "..\SrcZX8\ZX8_V1_Functions.asm"
endif
ifdef BuildZXS
read "..\SrcZX\ZX_V1_Functions.asm"
endif
ifdef BuildENT
read "..\SrcENT\ENT_V1_Functions.asm"
endif
ifdef BuildSAM
read "..\SrcSAM\SAM_V1_Functions.asm"
endif
ifdef BuildSMS
read "..\SrcSMS\SMS_V1_Functions.asm"
endif
ifdef BuildSGG
read "..\SrcSMS\SMS_V1_Functions.asm"
endif
ifdef BuildGMB
include "..\SrcGB\GB_V1_Functions.asm"
endif
ifdef BuildGBC
include "..\SrcGB\GB_V1_Functions.asm"
endif
ifdef BuildCLX
include "..\SrcCLX\CLX_V1_Functions.asm"
endif |
linux64/lesson03.asm | mashingan/notes-asmtutor | 1 | 165331 | format ELF64 executable 3
entry start
include 'procs.inc'
segment readable writeable
msg db 'Hello the new brave isekai!', 0Ah, 0
segment readable executable
start:
mov rbx, msg
mov rax, rbx
.nextchar:
cmp byte [rax], 0
jz .finished
inc rax
jmp .nextchar
.finished:
sub rax, rbx
mov rdx, rax
mov rsi, rbx
mov edi, 1
mov eax, 1
syscall
xorc rdi
mov eax, 60
syscall
|
other.7z/SFC.7z/SFC/ソースデータ/MarioKart/demo-j.asm | prismotizm/gigaleak | 0 | 99795 | Name: demo-j.asm
Type: file
Size: 7315
Last-Modified: '1992-07-14T15:00:00Z'
SHA-1: 86F098FD765C15CC649E9B0916088A95FEA07BDC
Description: null
|
other.7z/NEWS.7z/NEWS/テープリストア/NEWS_05/NEWS_05.tar/home/kimura/kart/mak.lzh/mak/condrv.asm | prismotizm/gigaleak | 0 | 23447 | Name: condrv.asm
Type: file
Size: 24663
Last-Modified: '1992-02-13T07:47:49Z'
SHA-1: E68699AAFD7EF40093A9107450CB2D4C9B565BD1
Description: null
|
Task/Calendar/Ada/calendar-1.ada | LaudateCorpus1/RosettaCodeData | 1 | 30749 | <filename>Task/Calendar/Ada/calendar-1.ada<gh_stars>1-10
with Ada.Calendar.Formatting;
package Printable_Calendar is
subtype String20 is String(1 .. 20);
type Month_Rep_Type is array (Ada.Calendar.Month_Number) of String20;
type Description is record
Weekday_Rep: String20;
Month_Rep: Month_Rep_Type;
end record;
-- for internationalization, you only need to define a new description
Default_Description: constant Description :=
(Weekday_Rep =>
"Mo Tu We Th Fr Sa So",
Month_Rep =>
(" January ", " February ", " March ",
" April ", " May ", " June ",
" July ", " August ", " September ",
" October ", " November ", " December "));
type Calendar (<>) is tagged private;
-- Initialize a calendar for devices with 80- or 132-characters per row
function Init_80(Des: Description := Default_Description) return Calendar;
function Init_132(Des: Description := Default_Description) return Calendar;
-- the following procedures output to standard IO; override if neccessary
procedure New_Line(Cal: Calendar);
procedure Put_String(Cal: Calendar; S: String);
-- the following procedures do the real stuff
procedure Print_Line_Centered(Cal: Calendar'Class; Line: String);
procedure Print(Cal: Calendar'Class;
Year: Ada.Calendar.Year_Number;
Year_String: String); -- this is the main Thing
private
type Calendar is tagged record
Columns, Rows, Space_Between_Columns: Positive;
Left_Space: Natural;
Weekday_Rep: String20;
Month_Rep: Month_Rep_Type;
end record;
end Printable_Calendar;
|
antlr/expr/Expr.g4 | kajigor/study | 0 | 7708 | <filename>antlr/expr/Expr.g4
// Expressions
grammar Expr;
start : e WS EOF;
e : e '*' e
| e '+' e
| NUM
;
NUM : [1-9][0-9]*
| '0'
;
WS : [ \t\n\r]*;
|
programs/oeis/228/A228219.asm | jmorken/loda | 1 | 97096 | <reponame>jmorken/loda
; A228219: Number of second differences of arrays of length 4 of numbers in 0..n.
; 15,49,103,177,271,385,519,673,847,1041,1255,1489,1743,2017,2311,2625,2959,3313,3687,4081,4495,4929,5383,5857,6351,6865,7399,7953,8527,9121,9735,10369,11023,11697,12391,13105,13839,14593,15367,16161,16975,17809
mov $1,5
mul $1,$0
add $1,12
mul $1,$0
mul $1,2
add $1,15
|
Scripts/fmClip - Clipboard FM Objects to XML.applescript | jwillinghalpern/FmClipTools | 12 | 2606 | <reponame>jwillinghalpern/FmClipTools<filename>Scripts/fmClip - Clipboard FM Objects to XML.applescript
-- fmClip - Clipboard FM Objects to XML
-- version 4.0.1, <NAME>, <NAME>
-- 4.0.1 - 2018-04-20 ( dshockley/eshagdar ): if layout objects, no modification. Others default to prettify.
-- 4.0 - 2018-04-04 ( dshockley/eshagdar ): load fmObjectTranslator code by reference instead of embedded.
-- 3.9.2 - 2017-08-09 ( eshagdar ): renamed 'Clipboard FileMaker Objects to XML' to 'fmClip - Clipboard FM Objects to XML' to match other handler name pattern
-- 1.8 - "clipboard convert" now ADDs the other data, not replace clipboard
-- 1.7 - handles UTF-8 properly now
-- 1.3 - put the actual conversion code into a handler with script object
-- 1.2 - cleaned up for use in Script menu
-- 1.1 - added ability to determine which FM class is in clipboard
on run
set objTrans to run script alias (((((path to me as text) & "::") as alias) as string) & "fmObjectTranslator.applescript")
(* If you need a self-contained script, copy the code from fmObjectTranslator into this script and use the following instead of the run script step above:
set objTrans to fmObjectTranslator_Instantiate({})
*)
set clipboardType to checkClipboardForObjects({}) of objTrans
if currentCode of objTrans is "XML2" then
-- layout objects - do NOT touch!
set shouldPrettify of objTrans to false
set shouldSimpleFormat of objTrans to false
else
-- all other objects:
set shouldPrettify of objTrans to true
end if
set debugMode of objTrans to true
if clipboardType is false then
display dialog "The clipboard did not contain any FileMaker objects."
return false
end if
clipboardConvertToXML({}) of objTrans
return true
end run
|
programs/oeis/186/A186438.asm | jmorken/loda | 1 | 20705 | <filename>programs/oeis/186/A186438.asm
; A186438: Positive numbers whose squares end in two identical digits.
; 10,12,20,30,38,40,50,60,62,70,80,88,90,100,110,112,120,130,138,140,150,160,162,170,180,188,190,200,210,212,220,230,238,240,250,260,262,270,280,288,290,300,310,312,320,330,338,340,350,360,362,370,380,388,390,400,410,412
mov $29,$0
add $29,1
lpb $29
clr $0,27
sub $29,1
sub $0,$29
cal $0,131372 ; Period 7: repeat [1, -1, 0, 1, 0, -1, 1].
add $1,$0
mul $1,2
mov $26,$1
cmp $26,0
add $1,$26
add $2,3
add $4,$1
add $4,$2
mov $1,$4
sub $1,1
mul $1,2
add $1,2
add $28,$1
lpe
mov $1,$28
|
engine/items/itemfinder.asm | adhi-thirumala/EvoYellow | 16 | 240632 | HiddenItemNear:
ld hl, HiddenItemCoords
ld b, 0
.loop
ld de, 3
ld a, [wCurMap]
call IsInRestOfArray
ret nc ; return if current map has no hidden items
push bc
push hl
ld hl, wObtainedHiddenItemsFlags
ld c, b
ld b, FLAG_TEST
predef FlagActionPredef
ld a, c
pop hl
pop bc
inc b
and a
inc hl
ld d, [hl]
inc hl
ld e, [hl]
inc hl
jr nz, .loop ; if the item has already been obtained
; check if the item is within 4-5 tiles (depending on the direction of item)
ld a, [wYCoord]
call Sub5ClampTo0
cp d
jr nc, .loop
ld a, [wYCoord]
add 4
cp d
jr c, .loop
ld a, [wXCoord]
call Sub5ClampTo0
cp e
jr nc, .loop
ld a, [wXCoord]
add 5
cp e
jr c, .loop
scf
ret
Sub5ClampTo0:
; subtract 5 but clamp to 0
sub 5
cp $f0
ret c
xor a
ret
|
kv-avm-tree_rewrite.ads | davidkristola/vole | 4 | 5011 | <reponame>davidkristola/vole<filename>kv-avm-tree_rewrite.ads
with Ada.Text_IO;
with kv.avm.vole_tree; use kv.avm.vole_tree;
with kv.avm.Tree_Visitors; use kv.avm.Tree_Visitors;
package kv.avm.Tree_Rewrite is
type Rewriter_Class is limited new Visitor_Class with
record
Temp : Natural := 0;
Block : Natural := 0;
end record;
procedure Init
(Self : in out Rewriter_Class);
procedure Finalize
(Self : in out Rewriter_Class);
function Next_Temp(Self : access Rewriter_Class; Src_Line : Positive) return String;
function Next_Block(Self : access Rewriter_Class) return String;
overriding procedure Visit_Id
(Self : in out Rewriter_Class;
Target : in out Id_Node_Class'CLASS;
Depth : in Natural);
overriding procedure Visit_Actor_Definition
(Self : in out Rewriter_Class;
Target : in out Node_Base_Class'CLASS;
Depth : in Natural);
overriding procedure Visit_Attribute_Definition
(Self : in out Rewriter_Class;
Target : in out Node_Base_Class'CLASS;
Depth : in Natural);
overriding procedure Visit_Message_Definition
(Self : in out Rewriter_Class;
Target : in out Node_Base_Class'CLASS;
Depth : in Natural);
overriding procedure Visit_Kind_Node
(Self : in out Rewriter_Class;
Target : in out Node_Base_Class'CLASS;
Depth : in Natural);
overriding procedure Visit_Argument
(Self : in out Rewriter_Class;
Target : in out Node_Base_Class'CLASS;
Depth : in Natural);
overriding procedure Visit_Constructor_Send_Node
(Self : in out Rewriter_Class;
Target : in out Node_Base_Class'CLASS;
Depth : in Natural);
overriding procedure Visit_Expression_List
(Self : in out Rewriter_Class;
Target : in out Node_Base_Class'CLASS;
Depth : in Natural);
overriding procedure Visit_Expression_Op
(Self : in out Rewriter_Class;
Target : in out Node_Base_Class'CLASS;
Depth : in Natural);
overriding procedure Visit_Expression_Var
(Self : in out Rewriter_Class;
Target : in out Node_Base_Class'CLASS;
Depth : in Natural);
overriding procedure Visit_Expression_Literal
(Self : in out Rewriter_Class;
Target : in out Node_Base_Class'CLASS;
Depth : in Natural);
overriding procedure Visit_Expression_Send
(Self : in out Rewriter_Class;
Target : in out Node_Base_Class'CLASS;
Depth : in Natural);
overriding procedure Visit_Expression_Fold
(Self : in out Rewriter_Class;
Target : in out Node_Base_Class'CLASS;
Depth : in Natural);
overriding procedure Visit_Statement_List
(Self : in out Rewriter_Class;
Target : in out Node_Base_Class'CLASS;
Depth : in Natural);
overriding procedure Visit_Statement_Assign
(Self : in out Rewriter_Class;
Target : in out Node_Base_Class'CLASS;
Depth : in Natural);
overriding procedure Visit_Statement_Var_Def
(Self : in out Rewriter_Class;
Target : in out Node_Base_Class'CLASS;
Depth : in Natural);
overriding procedure Visit_Statement_Emit
(Self : in out Rewriter_Class;
Target : in out Node_Base_Class'CLASS;
Depth : in Natural);
overriding procedure Visit_Statement_Return
(Self : in out Rewriter_Class;
Target : in out Node_Base_Class'CLASS;
Depth : in Natural);
overriding procedure Visit_Statement_If
(Self : in out Rewriter_Class;
Target : in out Node_Base_Class'CLASS;
Depth : in Natural);
overriding procedure Visit_Statement_Assert
(Self : in out Rewriter_Class;
Target : in out Node_Base_Class'CLASS;
Depth : in Natural);
overriding procedure Visit_Statement_Send
(Self : in out Rewriter_Class;
Target : in out Node_Base_Class'CLASS;
Depth : in Natural);
overriding procedure Visit_Statement_While
(Self : in out Rewriter_Class;
Target : in out Node_Base_Class'CLASS;
Depth : in Natural);
overriding procedure Visit_Program
(Self : in out Rewriter_Class;
Target : in out Node_Base_Class'CLASS;
Depth : in Natural);
overriding procedure Visit_Unimp
(Self : in out Rewriter_Class;
Target : in out Node_Base_Class'CLASS;
Depth : in Natural);
end kv.avm.Tree_Rewrite;
|
test/interaction/Issue2769.agda | shlevy/agda | 2 | 540 | <filename>test/interaction/Issue2769.agda
-- Andreas, 2017-10-11, issue #2769
-- Patch https://github.com/agda/agda/commit/7fc73607703e0373beaf65ba05fb1911b6d84a5e
--
-- Re #2495: make mutual info safer by distinguishing Nothing and Just []
--
-- Nothing means: never computed.
-- Just [] means: computed, but non-recursive.
--
-- These two notions were conflated before.
--
-- introduced this regression because the projection-likeness check failed.
-- {-# OPTIONS --show-implicit #-}
-- {-# OPTIONS -v 10 #-}
-- {-# OPTIONS -v tc.signature:60 #-}
-- {-# OPTIONS -v tc.mod.apply:80 #-}
-- {-# OPTIONS -v tc.sig.param:90 #-}
-- {-# OPTIONS -v tc.display:100 #-}
module Issue2769 where
module M (_X : Set₁)
where
record R (_Y : Set₂) : Set₁ where
field A : Set
record S : Set₁ where
field r : R Set₁
module Rr = R r
ok : (s : M.S Set) → M.R.A (M.S.r s) -- M.S.Rr.A s
ok = {!!} -- goal displayed as (s : M.S Set) → M.R.A (M.S.r s)
module MSet = M Set
goal : (s : M.S Set) → M.R.A (M.S.r s) -- M.S.Rr.A s
goal = {!!} -- WAS: goal displayed as (s : MSet.S) → MSet.S.Rr.A
-- adding display form Issue2769.M.R.A --> Issue2769.MSet.S.Rr.A
-- Display {dfFreeVars = 1, dfPats = [Apply ru(Def Issue2769.M.S.r [Apply ru(Var 0 [])])], dfRHS = DTerm (Def Issue2769.MSet.S.Rr.A [])}
-- EXPECTED:
-- Should display goal 1 as
-- ?1 : (s : MSet.S) → M.R.A (MSet.S.r s)
|
oeis/190/A190002.asm | neoneye/loda-programs | 11 | 979 | ; A190002: a(n) = n + [n*s/r] + [n*t/r]; r=1, s=(sinh(1))^2, t=(cosh(1))^2.
; Submitted by <NAME>
; 4,8,14,18,22,28,32,38,42,46,52,56,60,66,70,76,80,84,90,94,100,104,108,114,118,122,128,132,138,142,146,152,156,160,166,170,176,180,184,190,194,200,204,208,214,218,222,228,232,238,242,246,252,256,260,266,270,276,280,284,290,294,300,304,308,314,318,322,328,332,338,342,346,352,356,360,366,370,376,380,384,390,394,400,404,408,414,418,422,428,432,438,442,446,452,456,460,466,470,476
seq $0,190004 ; A190002/2.
mul $0,2
|
test/asset/agda-stdlib-1.0/Data/Integer/Divisibility.agda | omega12345/agda-mode | 0 | 1606 | <reponame>omega12345/agda-mode
------------------------------------------------------------------------
-- The Agda standard library
--
-- Unsigned divisibility
------------------------------------------------------------------------
-- For signed divisibility see `Data.Integer.Divisibility.Signed`
{-# OPTIONS --without-K --safe #-}
module Data.Integer.Divisibility where
open import Function
open import Data.Integer
open import Data.Integer.Properties
import Data.Nat as ℕ
import Data.Nat.Properties as ℕᵖ
import Data.Nat.Divisibility as ℕᵈ
import Data.Nat.Coprimality as ℕᶜ
open import Level
open import Relation.Binary
open import Relation.Binary.PropositionalEquality
------------------------------------------------------------------------
-- Divisibility
infix 4 _∣_
_∣_ : Rel ℤ 0ℓ
_∣_ = ℕᵈ._∣_ on ∣_∣
open ℕᵈ public using (divides)
------------------------------------------------------------------------
-- Properties of divisibility
*-monoʳ-∣ : ∀ k → (k *_) Preserves _∣_ ⟶ _∣_
*-monoʳ-∣ k {i} {j} i∣j = begin
∣ k * i ∣ ≡⟨ abs-*-commute k i ⟩
∣ k ∣ ℕ.* ∣ i ∣ ∣⟨ ℕᵈ.*-cong ∣ k ∣ i∣j ⟩
∣ k ∣ ℕ.* ∣ j ∣ ≡⟨ sym (abs-*-commute k j) ⟩
∣ k * j ∣ ∎
where open ℕᵈ.∣-Reasoning
*-monoˡ-∣ : ∀ k → (_* k) Preserves _∣_ ⟶ _∣_
*-monoˡ-∣ k {i} {j}
rewrite *-comm i k
| *-comm j k
= *-monoʳ-∣ k
*-cancelˡ-∣ : ∀ k {i j} → k ≢ + 0 → k * i ∣ k * j → i ∣ j
*-cancelˡ-∣ k {i} {j} k≢0 k*i∣k*j = ℕᵈ./-cong (ℕ.pred ∣ k ∣) $ begin
let ∣k∣-is-suc = ℕᵖ.m≢0⇒suc[pred[m]]≡m (k≢0 ∘ ∣n∣≡0⇒n≡0) in
ℕ.suc (ℕ.pred ∣ k ∣) ℕ.* ∣ i ∣ ≡⟨ cong (ℕ._* ∣ i ∣) (∣k∣-is-suc) ⟩
∣ k ∣ ℕ.* ∣ i ∣ ≡⟨ sym (abs-*-commute k i) ⟩
∣ k * i ∣ ∣⟨ k*i∣k*j ⟩
∣ k * j ∣ ≡⟨ abs-*-commute k j ⟩
∣ k ∣ ℕ.* ∣ j ∣ ≡⟨ cong (ℕ._* ∣ j ∣) (sym ∣k∣-is-suc) ⟩
ℕ.suc (ℕ.pred ∣ k ∣) ℕ.* ∣ j ∣ ∎
where open ℕᵈ.∣-Reasoning
*-cancelʳ-∣ : ∀ k {i j} → k ≢ + 0 → i * k ∣ j * k → i ∣ j
*-cancelʳ-∣ k {i} {j} ≢0 = *-cancelˡ-∣ k ≢0 ∘
subst₂ _∣_ (*-comm i k) (*-comm j k)
|
y2s2/csa/practicals/prac-5/8-loop-ex-6.asm | ouldevloper/university | 8 | 23908 | ; Display "9" to "1", jump 1 numbers every time.
.MODEL SMALL
.STACK 100
.DATA
CHAR DB "9"
.CODE
MAIN PROC
MOV AX,@DATA
MOV DS,AX
MOV CX, 5
L1:
MOV AH, 02H
MOV DL, CHAR
INT 21H
DEC CHAR
DEC CHAR
LOOP L1
MOV AX,4C00H
INT 21H
MAIN ENDP
END MAIN |
data/pokedex_order.asm | longlostsoul/EvoYellow | 16 | 98008 | PokedexOrder: ;order shown in game is decided by constants instead elsewhere
db DEX_KANGASKHAN
db DEX_NIDORAN_M
db DEX_CLEFAIRY
db DEX_SPEAROW
db DEX_VOLTORB
db DEX_NIDOKING
db DEX_SLOWBRO
db DEX_LICKITUNG
db DEX_EXEGGCUTE
db DEX_GRIMER
db DEX_GENGAR
db DEX_NIDORAN_F
db DEX_NIDOQUEEN
db DEX_CUBONE
db DEX_RHYHORN
db DEX_LAPRAS
db DEX_ARCANINE
db DEX_MEW
db DEX_GYARADOS
db DEX_SHELLDER
db DEX_TENTACOOL
db DEX_GASTLY
db DEX_SCYTHER
db DEX_STARYU
db DEX_PINSIR
db DEX_TANGELA
db DEX_GROWLITHE
db DEX_ONIX
db DEX_FEAROW
db DEX_PIDGEY
db DEX_SLOWPOKE
db DEX_KADABRA
db DEX_GRAVELER
db DEX_CHANSEY
db DEX_MACHOKE
db DEX_MR_MIME
db DEX_HITMONLEE
db DEX_HITMONCHAN
db DEX_ARBOK
db DEX_PARASECT
db DEX_PSYDUCK
db DEX_DROWZEE
db DEX_GOLEM
db DEX_MAGMAR
db DEX_ELECTABUZZ
db DEX_MAGNETON
db DEX_KOFFING
db DEX_MANKEY
db DEX_SEEL
db DEX_DIGLETT
db DEX_TAUROS
db DEX_FARFETCHD
db DEX_VENONAT
db DEX_DRAGONITE
db DEX_DODUO
db DEX_POLIWAG
db DEX_JYNX
db DEX_MOLTRES
db DEX_ARTICUNO
db DEX_ZAPDOS
db DEX_DITTO
db DEX_MEOWTH
db DEX_KRABBY
db DEX_VULPIX
db DEX_NINETALES
db DEX_PIKACHU
db DEX_RAICHU
db DEX_DRATINI
db DEX_DRAGONAIR
db DEX_KABUTO
db DEX_KABUTOPS
db DEX_HORSEA
db DEX_SEADRA
db DEX_SANDSHREW
db DEX_SANDSLASH
db DEX_OMANYTE
db DEX_OMASTAR
db DEX_JIGGLYPUFF
db DEX_WIGGLYTUFF
db DEX_EEVEE
db DEX_FLAREON
db DEX_JOLTEON
db DEX_VAPOREON
db DEX_MACHOP
db DEX_ZUBAT
db DEX_EKANS
db DEX_PARAS
db DEX_POLIWHIRL
db DEX_POLIWRATH
db DEX_WEEDLE
db DEX_KAKUNA
db DEX_BEEDRILL
db DEX_DODRIO
db DEX_PRIMEAPE
db DEX_DUGTRIO
db DEX_VENOMOTH
db DEX_DEWGONG
db DEX_CATERPIE
db DEX_METAPOD
db DEX_BUTTERFREE
db DEX_MACHAMP
db DEX_GOLDUCK
db DEX_HYPNO
db DEX_GOLBAT
db DEX_MEWTWO
db DEX_SNORLAX
db DEX_MAGIKARP
db DEX_MUK
db DEX_KINGLER
db DEX_CLOYSTER
db DEX_ELECTRODE
db DEX_CLEFABLE
db DEX_WEEZING
db DEX_PERSIAN
db DEX_MAROWAK
db DEX_HAUNTER
db DEX_ABRA
db DEX_ALAKAZAM
db DEX_PIDGEOTTO
db DEX_PIDGEOT
db DEX_STARMIE
db DEX_TENTACRUEL
db DEX_GOLDEEN
db DEX_SEAKING
db DEX_PONYTA
db DEX_RAPIDASH
db DEX_RATTATA
db DEX_RATICATE
db DEX_NIDORINO
db DEX_NIDORINA
db DEX_GEODUDE
db DEX_PORYGON
db DEX_AERODACTYL
db DEX_MAGNEMITE
db DEX_ODDISH
db DEX_GLOOM
db DEX_VILEPLUME
db DEX_BELLSPROUT
db DEX_WEEPINBELL
db DEX_VICTREEBEL
db DEX_TOGEPI
db DEX_TOGETIC
db DEX_TOGEKISS
db DEX_HOUNDOUR
db DEX_HOUNDOOM
db DEX_HERACROSS
db DEX_CROBAT
db DEX_SNEASEL
db DEX_WEAVILE
db DEX_SKARMORY
db DEX_MISDREAVUS
db DEX_MISMAGIUS
db DEX_MILTANK
db DEX_CHINCHOU
db DEX_LANTURN
db DEX_ROCKRUFF;SLUGMA
db DEX_LYCANROC;MAGCARGO
db DEX_TYROGUE
db DEX_HITMONTOP
db DEX_MURKROW
db DEX_HONCHKROW
db DEX_MARILL
db DEX_AZUMARILL
db DEX_SWINNUB
db DEX_PILOSWINE
db DEX_MAMOSWINE
db DEX_WOOPER
db DEX_QUAGSIRE
db DEX_YANMA
db DEX_YANMEGA
db DEX_PORYGONZ
db DEX_PHANPY
db DEX_DONPHAN
db DEX_GLIGAR
db DEX_GLISCOR
db DEX_TEDDIURSA
db DEX_URSARING
db DEX_SNUBBULL
db DEX_GRANBULL
db DEX_LARVITAR
db DEX_PUPITAR
db DEX_TYRANITAR
db DEX_ABSOL;STANTLER
db DEX_CORSOLA
db DEX_HOOTHOOT
db DEX_NOCTOWL
db DEX_SALANDIT;SUNKERN
db DEX_SALAZZLE;SUNFLORA
db DEX_HOPPIP
db DEX_JUMPLUFF
db DEX_SKIPLOOM
db DEX_MAREEP
db DEX_FLAAFFY
db DEX_AMPHAROS
db DEX_NATU
db DEX_XATU
db DEX_CARVANHA;REMORAID
db DEX_SHARPEDO;OCTILLERY
db DEX_MR_RIME;orig SENTRET
db DEX_SIRFETCHD;FURRET
db DEX_QWILFISH
db DEX_CURSOLA;DELIBIRD
db DEX_RHYDON
db DEX_DUNSPARCE
db DEX_GIRAFARIG
db DEX_RIOLU
db DEX_LUCARIO
db DEX_SUDOWOODO
db DEX_POLITOED
db DEX_SLOWKING
db DEX_BELLOSSOM
db DEX_KINGDRA
db DEX_BLISSEY
db DEX_PORYGON2
db DEX_MAGMORTAR
db DEX_ELECTIVIRE
db DEX_MAGNEZONE
db DEX_RHYPERIOR
db DEX_TANGROWTH
db DEX_LICKILICKY
db DEX_ESPEON
db DEX_UMBREON
db DEX_GLACEON
db DEX_LEAFEON
db DEX_SYLVEON
db DEX_SCIZOR
db DEX_STEELIX
db DEX_EXEGGUTOR
db DEX_CHARMANDER
db DEX_SQUIRTLE
db DEX_BULBASAUR
db DEX_IVYSAUR
db DEX_VENUSAUR
db DEX_CHARMELEON
db DEX_WARTORTLE
db DEX_BLASTOISE
db DEX_CHARIZARD
db DEX_ZIGZAGOON
db DEX_LINOONE
db DEX_OBSTAGOON
db DEX_SPINARAK
db DEX_ARIADOS
db DEX_MANTYKE
db DEX_MANTINE
db DEX_PINECO;AIPOM
db DEX_FORRETRESS;AMBIPOM
db DEX_MUNCHLAX
db DEX_SMEARGLE
db DEX_SUICUNE
db DEX_ENTEI
db DEX_RAIKOU
; db DEX_MEGA_CHARIZARD
; db DEX_MEGA_BLASTOISE
; db DEX_MEGA_VENUSAUR
db DEX_WOBBUFFET |
src/Data/PropFormula/ExperimentalSyntax.agda | jonaprieto/agda-prop | 13 | 2409 | <reponame>jonaprieto/agda-prop<filename>src/Data/PropFormula/ExperimentalSyntax.agda
------------------------------------------------------------------------------
-- Agda-Prop Library.
-- Syntax Experiment definitions.
------------------------------------------------------------------------------
open import Data.Nat using ( ℕ )
module Data.PropFormula.SyntaxExperiment ( n : ℕ ) where
------------------------------------------------------------------------------
open import Data.Bool using (false; true)
open import Data.PropFormula.Syntax n
open import Data.PropFormula.Views n
open import Data.PropFormula.Dec n
open import Data.PropFormula.Properties n
open import Data.List public
open import Function using (_∘_)
open import Relation.Binary.PropositionalEquality using (_≡_)
------------------------------------------------------------------------------
data _⊢∧_ : Ctxt → List PropFormula → Set where
empty-intro : ∀ {Γ} → Γ ⊢∧ []
∷-intro : ∀ {Γ} {φ} {L}
→ Γ ⊢ φ
→ Γ ⊢∧ L
→ Γ ⊢∧ (φ ∷ L)
∷-proj₁
: ∀ {Γ} {φ} {L}
→ Γ ⊢∧ (φ ∷ L)
→ Γ ⊢ φ
∷-proj₁ (∷-intro Γ⊢φ _) = Γ⊢φ
∷-proj₂
: ∀ {Γ} {φ} {L}
→ Γ ⊢∧ (φ ∷ L)
→ Γ ⊢∧ L
∷-proj₂ (∷-intro _ Γ⊢∧L) = Γ⊢∧L
intro-thm
: ∀ {Γ} {φ}
→ Γ ⊢ φ
→ Γ ⊢∧ [ φ ]
intro-thm {Γ} {φ} Γ⊢φ = ∷-intro Γ⊢φ empty-intro
++-intro : ∀ {Γ} {L₁ L₂}
→ Γ ⊢∧ L₁ → Γ ⊢∧ L₂
→ Γ ⊢∧ (L₁ ++ L₂)
++-intro empty-intro th2 = th2
++-intro (∷-intro x th1) th2 = ∷-intro x (++-intro th1 th2)
toList : PropFormula → List PropFormula
toList φ with conj-view φ
toList .(φ₁ ∧ φ₂) | conj φ₁ φ₂ = toList φ₁ ++ toList φ₂
toList φ | other .φ = [ φ ]
⊢-to-⊢∧
: ∀ {Γ} {φ}
→ Γ ⊢ φ
→ Γ ⊢∧ toList φ
⊢-to-⊢∧ {_} {φ} Γ⊢φ with conj-view φ
... | conj φ₁ φ₂ = ++-intro (⊢-to-⊢∧ (∧-proj₁ Γ⊢φ)) (⊢-to-⊢∧ (∧-proj₂ Γ⊢φ))
... | other .φ = ∷-intro Γ⊢φ empty-intro
toProp : List PropFormula → PropFormula
toProp [] = ⊤
toProp (φ ∷ []) = φ
toProp (φ ∷ L) = φ ∧ toProp L
⊢∧-to-⊢
: ∀ {Γ} {L}
→ Γ ⊢∧ L
→ Γ ⊢ toProp L
⊢∧-to-⊢ {_} {[]} _ = ⊤-intro
⊢∧-to-⊢ {_} {_ ∷ []} Γ⊢∧L = ∷-proj₁ Γ⊢∧L
⊢∧-to-⊢ {_} {x ∷ _ ∷ _} (∷-intro Γ⊢φ Γ⊢∧L) = ∧-intro Γ⊢φ (⊢∧-to-⊢ Γ⊢∧L)
right-assoc-∧ : PropFormula → PropFormula
right-assoc-∧ = toProp ∘ toList
right-assoc-∧-lem
: ∀ {Γ} {φ}
→ Γ ⊢ φ
→ Γ ⊢ right-assoc-∧ φ
right-assoc-∧-lem = ⊢∧-to-⊢ ∘ ⊢-to-⊢∧
find-conjunct : List PropFormula → PropFormula → PropFormula
find-conjunct [] x = ⊤
find-conjunct (x ∷ xs) y with ⌊ eq x y ⌋
... | false = find-conjunct xs y
... | true = x
find-conjunct-thm
: ∀ {Γ} {L}
→ (ψ : PropFormula)
→ Γ ⊢∧ L
→ Γ ⊢ find-conjunct L ψ
find-conjunct-thm {_} {[]} ψ Γ⊢∧L = ⊤-intro
find-conjunct-thm {_} {x ∷ L} ψ Γ⊢∧L with ⌊ eq x ψ ⌋
find-conjunct-thm {_} {x ∷ L} ψ Γ⊢∧L | false with Γ⊢∧L
find-conjunct-thm {_} {x ∷ L} ψ Γ⊢∧L | false | ∷-intro x₁ w = find-conjunct-thm ψ w
find-conjunct-thm {_} {x ∷ L} ψ Γ⊢∧L | true = ∷-proj₁ Γ⊢∧L
conjunct-thm
: ∀ {Γ} {φ}
→ (ψ : PropFormula)
→ Γ ⊢ φ
→ Γ ⊢ find-conjunct (toList φ) ψ
conjunct-thm {_} ψ Γ⊢φ = find-conjunct-thm ψ (⊢-to-⊢∧ Γ⊢φ)
{-
toWeak : (Γ : List PropFormula) (ψ : PropFormula) → List PropFormula
toWeak t f = t , f , f
strip : ∀ {Γ} {φ} → (ψ : PropFormula) → Γ ⊢ φ → (toWeak Γ ψ) ⊢ φ
strip ψ Γ⊢φ = (weaken ψ (weaken ψ Γ⊢φ))
-- Bag Equivalance
-- open import Data.Fin using (Fin; suc; zero; #_)
-- open import Data.List using (length)
-- infixl 3 _↔_
-- record _↔_(A B : Set) : Set where
-- field
-- to : A → B
-- from : B → A
-- from-to : ∀ x → from (to x) ≡ x
-- to-from : ∀ x → to (from x) ≡ x
-- lookup : (xs : List PropFormula) → Fin (length xs) → PropFormula
-- lookup [] ()
-- lookup (x ∷ xs) zero = x
-- lookup (x ∷ xs) (suc n) = lookup xs n
-- record _≈Bag_(xs ys : List PropFormula) : Set where
-- field
-- bijection : Fin (length xs) ↔ Fin (length ys)
-- related : ∀ i → lookup xs i ≡ lookup ys (_↔_.to bijection i)
-- data _+_ (A B : Set) : Set where
-- left : A → A + B
-- right : B → A + B
-- Any : (Prop → Set) → List PropFormula → Set
-- Any P [] = ⊥₂
-- Any P (x ∷ xs) = P x + Any P xs
-- infix 4 _∈₂_
-- _∈₂_ : PropFormula → List PropFormula → Set
-- x ∈₂ xs = Any (λ y → x ≡ y) xs
-- _≈Bag₂_ : List PropFormula → List PropFormula → Set
-- xs ≈Bag₂ ys = ∀ x → x ∈₂ xs ↔ x ∈₂ ys
-}
|
Palmtree.Math.Core.Implements/vs_build/x64_Debug/pmc_tostring.asm | rougemeilland/Palmtree.Math.Core.Implements | 0 | 245423 | ; Listing generated by Microsoft (R) Optimizing Compiler Version 19.16.27026.1
include listing.inc
INCLUDELIB MSVCRTD
INCLUDELIB OLDNAMES
msvcjmc SEGMENT
__7B7A869E_ctype@h DB 01H
__457DD326_basetsd@h DB 01H
__4384A2D9_corecrt_memcpy_s@h DB 01H
__4E51A221_corecrt_wstring@h DB 01H
__2140C079_string@h DB 01H
__1887E595_winnt@h DB 01H
__9FC7C64B_processthreadsapi@h DB 01H
__FA470AEC_memoryapi@h DB 01H
__F37DAFF1_winerror@h DB 01H
__7A450CCC_winbase@h DB 01H
__B4B40122_winioctl@h DB 01H
__86261D59_stralign@h DB 01H
__7B8DBFC3_pmc_uint_internal@h DB 01H
__6B0481B0_pmc_inline_func@h DB 01H
__3AA1CF5E_pmc_tostring@c DB 01H
msvcjmc ENDS
PUBLIC Initialize_ToString
PUBLIC PMC_ToString
PUBLIC __JustMyCode_Default
PUBLIC ??_C@_13DEFPDAGF@?$AA?0@ ; `string'
PUBLIC ??_C@_13JOFGPIOO@?$AA?4@ ; `string'
PUBLIC ??_C@_01EKENIIDA@3@ ; `string'
PUBLIC ??_C@_13KJIIAINM@?$AA?$CL@ ; `string'
PUBLIC ??_C@_13IMODFHAA@?$AA?9@ ; `string'
EXTRN __imp_lstrcpyA:PROC
EXTRN __imp_lstrcpyW:PROC
EXTRN __imp_lstrlenW:PROC
EXTRN AllocateBlock:PROC
EXTRN DeallocateBlock:PROC
EXTRN CheckBlockLight:PROC
EXTRN CheckNumber:PROC
EXTRN DivRem_X_1W:PROC
EXTRN _RTC_CheckStackVars:PROC
EXTRN _RTC_InitBase:PROC
EXTRN _RTC_Shutdown:PROC
EXTRN __CheckForDebuggerJustMyCode:PROC
EXTRN __GSHandlerCheck:PROC
EXTRN __security_check_cookie:PROC
EXTRN statistics_info:BYTE
EXTRN __ImageBase:BYTE
EXTRN __security_cookie:QWORD
_BSS SEGMENT
default_number_format_option DB 028H DUP (?)
_BSS ENDS
; COMDAT pdata
pdata SEGMENT
$pdata$Initialize_ToString DD imagerel $LN3
DD imagerel $LN3+176
DD imagerel $unwind$Initialize_ToString
pdata ENDS
; COMDAT pdata
pdata SEGMENT
$pdata$PMC_ToString DD imagerel $LN24
DD imagerel $LN24+681
DD imagerel $unwind$PMC_ToString
pdata ENDS
; COMDAT pdata
pdata SEGMENT
$pdata$IncrementDIV32Counter DD imagerel IncrementDIV32Counter
DD imagerel IncrementDIV32Counter+62
DD imagerel $unwind$IncrementDIV32Counter
pdata ENDS
; COMDAT pdata
pdata SEGMENT
$pdata$IncrementDIV64Counter DD imagerel IncrementDIV64Counter
DD imagerel IncrementDIV64Counter+62
DD imagerel $unwind$IncrementDIV64Counter
pdata ENDS
; COMDAT pdata
pdata SEGMENT
$pdata$AddToDIV32Counter DD imagerel AddToDIV32Counter
DD imagerel AddToDIV32Counter+78
DD imagerel $unwind$AddToDIV32Counter
pdata ENDS
; COMDAT pdata
pdata SEGMENT
$pdata$AddToDIV64Counter DD imagerel AddToDIV64Counter
DD imagerel AddToDIV64Counter+78
DD imagerel $unwind$AddToDIV64Counter
pdata ENDS
; COMDAT pdata
pdata SEGMENT
$pdata$_COPY_MEMORY_UNIT_DIV DD imagerel _COPY_MEMORY_UNIT_DIV
DD imagerel _COPY_MEMORY_UNIT_DIV+100
DD imagerel $unwind$_COPY_MEMORY_UNIT_DIV
pdata ENDS
; COMDAT pdata
pdata SEGMENT
$pdata$_ZERO_MEMORY_UNIT_DIV DD imagerel _ZERO_MEMORY_UNIT_DIV
DD imagerel _ZERO_MEMORY_UNIT_DIV+100
DD imagerel $unwind$_ZERO_MEMORY_UNIT_DIV
pdata ENDS
; COMDAT pdata
pdata SEGMENT
$pdata$_FILL_MEMORY_16 DD imagerel _FILL_MEMORY_16
DD imagerel _FILL_MEMORY_16+98
DD imagerel $unwind$_FILL_MEMORY_16
pdata ENDS
; COMDAT pdata
pdata SEGMENT
$pdata$_FROMWORDTODWORD DD imagerel _FROMWORDTODWORD
DD imagerel _FROMWORDTODWORD+85
DD imagerel $unwind$_FROMWORDTODWORD
pdata ENDS
; COMDAT pdata
pdata SEGMENT
$pdata$_DIVIDE_CEILING_UNIT DD imagerel _DIVIDE_CEILING_UNIT
DD imagerel _DIVIDE_CEILING_UNIT+97
DD imagerel $unwind$_DIVIDE_CEILING_UNIT
pdata ENDS
; COMDAT pdata
pdata SEGMENT
$pdata$_DIVREM_UNIT DD imagerel _DIVREM_UNIT
DD imagerel _DIVREM_UNIT+218
DD imagerel $unwind$_DIVREM_UNIT
pdata ENDS
; COMDAT pdata
pdata SEGMENT
$pdata$_ROTATE_L_UNIT DD imagerel _ROTATE_L_UNIT
DD imagerel _ROTATE_L_UNIT+87
DD imagerel $unwind$_ROTATE_L_UNIT
pdata ENDS
; COMDAT pdata
pdata SEGMENT
$pdata$ConvertCardinalNumber DD imagerel ConvertCardinalNumber
DD imagerel ConvertCardinalNumber+643
DD imagerel $unwind$ConvertCardinalNumber
pdata ENDS
; COMDAT pdata
pdata SEGMENT
$pdata$InitializeOutputState DD imagerel InitializeOutputState
DD imagerel InitializeOutputState+474
DD imagerel $unwind$InitializeOutputState
pdata ENDS
; COMDAT pdata
pdata SEGMENT
$pdata$OutputDecimalSeparator DD imagerel OutputDecimalSeparator
DD imagerel OutputDecimalSeparator+132
DD imagerel $unwind$OutputDecimalSeparator
pdata ENDS
; COMDAT pdata
pdata SEGMENT
$pdata$OutputUngroupedOneChar DD imagerel OutputUngroupedOneChar
DD imagerel OutputUngroupedOneChar+125
DD imagerel $unwind$OutputUngroupedOneChar
pdata ENDS
; COMDAT pdata
pdata SEGMENT
$pdata$OutputOneChar DD imagerel OutputOneChar
DD imagerel OutputOneChar+489
DD imagerel $unwind$OutputOneChar
pdata ENDS
; COMDAT pdata
pdata SEGMENT
$pdata$ToStringDN_LEADING_1WORD DD imagerel ToStringDN_LEADING_1WORD
DD imagerel ToStringDN_LEADING_1WORD+155
DD imagerel $unwind$ToStringDN_LEADING_1WORD
pdata ENDS
; COMDAT pdata
pdata SEGMENT
$pdata$ToStringDN_1WORD DD imagerel ToStringDN_1WORD
DD imagerel ToStringDN_1WORD+1031
DD imagerel $unwind$ToStringDN_1WORD
pdata ENDS
; COMDAT pdata
pdata SEGMENT
$pdata$PrintDecimal DD imagerel PrintDecimal
DD imagerel PrintDecimal+498
DD imagerel $unwind$PrintDecimal
pdata ENDS
; COMDAT pdata
pdata SEGMENT
$pdata$ToStringDN_Finalize DD imagerel ToStringDN_Finalize
DD imagerel ToStringDN_Finalize+191
DD imagerel $unwind$ToStringDN_Finalize
pdata ENDS
; COMDAT pdata
pdata SEGMENT
$pdata$ToStringDN DD imagerel ToStringDN
DD imagerel ToStringDN+1094
DD imagerel $unwind$ToStringDN
pdata ENDS
; COMDAT pdata
pdata SEGMENT
$pdata$ToStringX_1WORD DD imagerel ToStringX_1WORD
DD imagerel ToStringX_1WORD+2393
DD imagerel $unwind$ToStringX_1WORD
pdata ENDS
; COMDAT pdata
pdata SEGMENT
$pdata$ToStringX DD imagerel ToStringX
DD imagerel ToStringX+650
DD imagerel $unwind$ToStringX
pdata ENDS
; COMDAT rtc$TMZ
rtc$TMZ SEGMENT
_RTC_Shutdown.rtc$TMZ DQ FLAT:_RTC_Shutdown
rtc$TMZ ENDS
; COMDAT rtc$IMZ
rtc$IMZ SEGMENT
_RTC_InitBase.rtc$IMZ DQ FLAT:_RTC_InitBase
rtc$IMZ ENDS
; COMDAT ??_C@_13IMODFHAA@?$AA?9@
CONST SEGMENT
??_C@_13IMODFHAA@?$AA?9@ DB '-', 00H, 00H, 00H ; `string'
CONST ENDS
; COMDAT ??_C@_13KJIIAINM@?$AA?$CL@
CONST SEGMENT
??_C@_13KJIIAINM@?$AA?$CL@ DB '+', 00H, 00H, 00H ; `string'
CONST ENDS
; COMDAT ??_C@_01EKENIIDA@3@
CONST SEGMENT
??_C@_01EKENIIDA@3@ DB '3', 00H ; `string'
CONST ENDS
; COMDAT ??_C@_13JOFGPIOO@?$AA?4@
CONST SEGMENT
??_C@_13JOFGPIOO@?$AA?4@ DB '.', 00H, 00H, 00H ; `string'
CONST ENDS
; COMDAT ??_C@_13DEFPDAGF@?$AA?0@
CONST SEGMENT
??_C@_13DEFPDAGF@?$AA?0@ DB ',', 00H, 00H, 00H ; `string'
CONST ENDS
_DATA SEGMENT
decimal_digits DB '0', 00H, '1', 00H, '2', 00H, '3', 00H, '4', 00H, '5', 00H
DB '6', 00H, '7', 00H, '8', 00H, '9', 00H, 00H, 00H
ORG $+2
hexadecimal_lower_digits DB '0', 00H, '1', 00H, '2', 00H, '3', 00H, '4', 00H
DB '5', 00H, '6', 00H, '7', 00H, '8', 00H, '9', 00H, 'a', 00H, 'b'
DB 00H, 'c', 00H, 'd', 00H, 'e', 00H, 'f', 00H, 00H, 00H
ORG $+6
hexadecimal_upper_digits DB '0', 00H, '1', 00H, '2', 00H, '3', 00H, '4', 00H
DB '5', 00H, '6', 00H, '7', 00H, '8', 00H, '9', 00H, 'A', 00H, 'B'
DB 00H, 'C', 00H, 'D', 00H, 'E', 00H, 'F', 00H, 00H, 00H
_DATA ENDS
; COMDAT xdata
xdata SEGMENT
$unwind$ToStringX DD 025053901H
DD 011d2322H
DD 07016003dH
DD 05015H
xdata ENDS
; COMDAT xdata
xdata SEGMENT
$unwind$ToStringX_1WORD DD 025053801H
DD 011c2321H
DD 070150021H
DD 05014H
xdata ENDS
; COMDAT xdata
xdata SEGMENT
$unwind$ToStringDN DD 045053901H
DD 011d4322H
DD 070160051H
DD 05015H
xdata ENDS
; COMDAT CONST
CONST SEGMENT
ToStringDN$rtcName$0 DB 072H
DB 05fH
DB 062H
DB 075H
DB 066H
DB 05fH
DB 063H
DB 06fH
DB 064H
DB 065H
DB 00H
ORG $+5
ToStringDN$rtcName$1 DB 072H
DB 05fH
DB 062H
DB 075H
DB 066H
DB 05fH
DB 077H
DB 06fH
DB 072H
DB 064H
DB 073H
DB 00H
ORG $+4
ToStringDN$rtcName$2 DB 072H
DB 05fH
DB 062H
DB 075H
DB 066H
DB 05fH
DB 063H
DB 06fH
DB 075H
DB 06eH
DB 074H
DB 00H
ORG $+4
ToStringDN$rtcName$3 DB 072H
DB 065H
DB 076H
DB 05fH
DB 073H
DB 074H
DB 072H
DB 05fH
DB 062H
DB 075H
DB 066H
DB 05fH
DB 063H
DB 06fH
DB 064H
DB 065H
DB 00H
ORG $+7
ToStringDN$rtcName$4 DB 072H
DB 065H
DB 076H
DB 05fH
DB 073H
DB 074H
DB 072H
DB 05fH
DB 062H
DB 075H
DB 066H
DB 05fH
DB 077H
DB 06fH
DB 072H
DB 064H
DB 073H
DB 00H
ORG $+6
ToStringDN$rtcName$5 DB 072H
DB 065H
DB 076H
DB 05fH
DB 073H
DB 074H
DB 072H
DB 05fH
DB 062H
DB 075H
DB 066H
DB 05fH
DB 063H
DB 06fH
DB 075H
DB 06eH
DB 074H
DB 00H
ORG $+6
ToStringDN$rtcFrameData DD 06H
DD 00H
DQ FLAT:ToStringDN$rtcVarDesc
ORG $+8
ToStringDN$rtcVarDesc DD 01a8H
DD 08H
DQ FLAT:ToStringDN$rtcName$5
DD 0168H
DD 08H
DQ FLAT:ToStringDN$rtcName$4
DD 0148H
DD 08H
DQ FLAT:ToStringDN$rtcName$3
DD 0128H
DD 08H
DQ FLAT:ToStringDN$rtcName$2
DD 0e8H
DD 08H
DQ FLAT:ToStringDN$rtcName$1
DD 0c8H
DD 08H
DQ FLAT:ToStringDN$rtcName$0
CONST ENDS
; COMDAT xdata
xdata SEGMENT
$unwind$ToStringDN_Finalize DD 025053901H
DD 011d2322H
DD 070160029H
DD 05015H
xdata ENDS
; COMDAT xdata
xdata SEGMENT
$unwind$PrintDecimal DD 025054a19H
DD 011d2322H
DD 070160037H
DD 05015H
DD imagerel __GSHandlerCheck
DD 01a8H
xdata ENDS
; COMDAT CONST
CONST SEGMENT
PrintDecimal$rtcName$0 DB 073H
DB 074H
DB 061H
DB 074H
DB 065H
DB 00H
ORG $+10
PrintDecimal$rtcVarDesc DD 028H
DD 038H
DQ FLAT:PrintDecimal$rtcName$0
ORG $+48
PrintDecimal$rtcFrameData DD 01H
DD 00H
DQ FLAT:PrintDecimal$rtcVarDesc
CONST ENDS
; COMDAT xdata
xdata SEGMENT
$unwind$ToStringDN_1WORD DD 025052e01H
DD 01122317H
DD 0700b0021H
DD 0500aH
xdata ENDS
; COMDAT CONST
CONST SEGMENT
ToStringDN_1WORD$rtcName$0 DB 072H
DB 00H
ORG $+14
ToStringDN_1WORD$rtcVarDesc DD 024H
DD 04H
DQ FLAT:ToStringDN_1WORD$rtcName$0
ORG $+48
ToStringDN_1WORD$rtcFrameData DD 01H
DD 00H
DQ FLAT:ToStringDN_1WORD$rtcVarDesc
CONST ENDS
; COMDAT xdata
xdata SEGMENT
$unwind$ToStringDN_LEADING_1WORD DD 025052e01H
DD 01122317H
DD 0700b0021H
DD 0500aH
xdata ENDS
; COMDAT CONST
CONST SEGMENT
ToStringDN_LEADING_1WORD$rtcName$0 DB 072H
DB 00H
ORG $+14
ToStringDN_LEADING_1WORD$rtcVarDesc DD 024H
DD 04H
DQ FLAT:ToStringDN_LEADING_1WORD$rtcName$0
ORG $+48
ToStringDN_LEADING_1WORD$rtcFrameData DD 01H
DD 00H
DQ FLAT:ToStringDN_LEADING_1WORD$rtcVarDesc
CONST ENDS
; COMDAT xdata
xdata SEGMENT
$unwind$OutputOneChar DD 025052e01H
DD 01122317H
DD 0700b001dH
DD 0500aH
xdata ENDS
; COMDAT xdata
xdata SEGMENT
$unwind$OutputUngroupedOneChar DD 025052e01H
DD 01122317H
DD 0700b001dH
DD 0500aH
xdata ENDS
; COMDAT xdata
xdata SEGMENT
$unwind$OutputDecimalSeparator DD 025052a01H
DD 010e2313H
DD 07007001dH
DD 05006H
xdata ENDS
; COMDAT xdata
xdata SEGMENT
$unwind$InitializeOutputState DD 025053901H
DD 011d2322H
DD 070160025H
DD 05015H
xdata ENDS
; COMDAT xdata
xdata SEGMENT
$unwind$ConvertCardinalNumber DD 035053901H
DD 011d3322H
DD 070160053H
DD 05015H
xdata ENDS
; COMDAT CONST
CONST SEGMENT
ConvertCardinalNumber$rtcName$0 DB 077H
DB 06fH
DB 072H
DB 06bH
DB 05fH
DB 062H
DB 075H
DB 066H
DB 05fH
DB 031H
DB 05fH
DB 063H
DB 06fH
DB 064H
DB 065H
DB 00H
ConvertCardinalNumber$rtcName$1 DB 077H
DB 06fH
DB 072H
DB 06bH
DB 05fH
DB 062H
DB 075H
DB 066H
DB 05fH
DB 031H
DB 05fH
DB 077H
DB 06fH
DB 072H
DB 064H
DB 073H
DB 00H
ORG $+7
ConvertCardinalNumber$rtcName$2 DB 077H
DB 06fH
DB 072H
DB 06bH
DB 05fH
DB 062H
DB 075H
DB 066H
DB 05fH
DB 032H
DB 05fH
DB 063H
DB 06fH
DB 064H
DB 065H
DB 00H
ConvertCardinalNumber$rtcName$3 DB 077H
DB 06fH
DB 072H
DB 06bH
DB 05fH
DB 062H
DB 075H
DB 066H
DB 05fH
DB 032H
DB 05fH
DB 077H
DB 06fH
DB 072H
DB 064H
DB 073H
DB 00H
ORG $+7
ConvertCardinalNumber$rtcName$4 DB 072H
DB 05fH
DB 076H
DB 061H
DB 06cH
DB 075H
DB 065H
DB 00H
ORG $+8
ConvertCardinalNumber$rtcVarDesc DD 0194H
DD 04H
DQ FLAT:ConvertCardinalNumber$rtcName$4
DD 0d8H
DD 08H
DQ FLAT:ConvertCardinalNumber$rtcName$3
DD 0b8H
DD 08H
DQ FLAT:ConvertCardinalNumber$rtcName$2
DD 078H
DD 08H
DQ FLAT:ConvertCardinalNumber$rtcName$1
DD 058H
DD 08H
DQ FLAT:ConvertCardinalNumber$rtcName$0
ORG $+240
ConvertCardinalNumber$rtcFrameData DD 05H
DD 00H
DQ FLAT:ConvertCardinalNumber$rtcVarDesc
CONST ENDS
; COMDAT xdata
xdata SEGMENT
$unwind$_ROTATE_L_UNIT DD 025052e01H
DD 01122317H
DD 0700b001dH
DD 0500aH
xdata ENDS
; COMDAT xdata
xdata SEGMENT
$unwind$_DIVREM_UNIT DD 025053601H
DD 011b2320H
DD 070140021H
DD 05013H
xdata ENDS
; COMDAT xdata
xdata SEGMENT
$unwind$_DIVIDE_CEILING_UNIT DD 025052f01H
DD 01132318H
DD 0700c001dH
DD 0500bH
xdata ENDS
; COMDAT xdata
xdata SEGMENT
$unwind$_FROMWORDTODWORD DD 025052c01H
DD 01112316H
DD 0700a001dH
DD 05009H
xdata ENDS
; COMDAT xdata
xdata SEGMENT
$unwind$_FILL_MEMORY_16 DD 025053401H
DD 0118231dH
DD 07011001dH
DD 05010H
xdata ENDS
; COMDAT xdata
xdata SEGMENT
$unwind$_ZERO_MEMORY_UNIT_DIV DD 025052f01H
DD 01132318H
DD 0700c001fH
DD 0500bH
xdata ENDS
; COMDAT xdata
xdata SEGMENT
$unwind$_COPY_MEMORY_UNIT_DIV DD 025063501H
DD 0119231eH
DD 07012001cH
DD 050106011H
xdata ENDS
; COMDAT xdata
xdata SEGMENT
$unwind$AddToDIV64Counter DD 025052801H
DD 010d2312H
DD 07006001dH
DD 05005H
xdata ENDS
; COMDAT xdata
xdata SEGMENT
$unwind$AddToDIV32Counter DD 025052801H
DD 010d2312H
DD 07006001dH
DD 05005H
xdata ENDS
; COMDAT xdata
xdata SEGMENT
$unwind$IncrementDIV64Counter DD 025051e01H
DD 010a230fH
DD 07003001dH
DD 05002H
xdata ENDS
; COMDAT xdata
xdata SEGMENT
$unwind$IncrementDIV32Counter DD 025051e01H
DD 010a230fH
DD 07003001dH
DD 05002H
xdata ENDS
; COMDAT xdata
xdata SEGMENT
$unwind$PMC_ToString DD 035053901H
DD 011d3322H
DD 070160027H
DD 05015H
xdata ENDS
; COMDAT xdata
xdata SEGMENT
$unwind$Initialize_ToString DD 025052a01H
DD 010e2313H
DD 07007001dH
DD 05006H
xdata ENDS
; Function compile flags: /Odt
; COMDAT __JustMyCode_Default
_TEXT SEGMENT
__JustMyCode_Default PROC ; COMDAT
ret 0
__JustMyCode_Default ENDP
_TEXT ENDS
; Function compile flags: /Odtp /RTCsu /ZI
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_tostring.c
; COMDAT ToStringX
_TEXT SEGMENT
output_len$1 = 8
filling_digit_len$2 = 40
total_length$3 = 72
filling_digit_count$4 = 104
s_ptr$5 = 136
d_ptr$6 = 168
digit_table$7 = 200
w_count$8 = 232
tv134 = 440
x$ = 480
buffer$ = 488
buffer_size$ = 496
width$ = 504
format_option$ = 512
using_upper_letter$ = 520
ToStringX PROC ; COMDAT
; 480 : {
mov DWORD PTR [rsp+32], r9d
mov QWORD PTR [rsp+24], r8
mov QWORD PTR [rsp+16], rdx
mov QWORD PTR [rsp+8], rcx
push rbp
push rdi
sub rsp, 488 ; 000001e8H
lea rbp, QWORD PTR [rsp+32]
mov rdi, rsp
mov ecx, 122 ; 0000007aH
mov eax, -858993460 ; ccccccccH
rep stosd
mov rcx, QWORD PTR [rsp+520]
lea rcx, OFFSET FLAT:__3AA1CF5E_pmc_tostring@c
call __CheckForDebuggerJustMyCode
; 481 : if (x->IS_ZERO)
mov rax, QWORD PTR x$[rbp]
mov eax, DWORD PTR [rax+40]
shr eax, 1
and eax, 1
test eax, eax
je SHORT $LN4@ToStringX
; 482 : {
; 483 : // x が 0 である場合
; 484 : // 最低で 1 桁、最高で format_option->MinimumWidth 桁だけ '0' を出力する。
; 485 :
; 486 : if (width < 1)
cmp DWORD PTR width$[rbp], 1
jae SHORT $LN6@ToStringX
; 487 : width = 1;
mov DWORD PTR width$[rbp], 1
$LN6@ToStringX:
; 488 : if (buffer_size < width + 1)
mov eax, DWORD PTR width$[rbp]
inc eax
mov eax, eax
cmp QWORD PTR buffer_size$[rbp], rax
jae SHORT $LN7@ToStringX
; 489 : return (PMC_STATUS_INSUFFICIENT_BUFFER);
mov eax, -4
jmp $LN1@ToStringX
$LN7@ToStringX:
; 490 : _FILL_MEMORY_16(buffer, L'0', width);
mov eax, DWORD PTR width$[rbp]
mov r8d, eax
mov dx, 48 ; 00000030H
mov rcx, QWORD PTR buffer$[rbp]
call _FILL_MEMORY_16
; 491 : buffer[width] = L'\0';
mov eax, DWORD PTR width$[rbp]
xor ecx, ecx
mov rdx, QWORD PTR buffer$[rbp]
mov WORD PTR [rdx+rax*2], cx
; 492 : }
jmp $LN5@ToStringX
$LN4@ToStringX:
; 493 : else
; 494 : {
; 495 : // x が 0 ではない場合
; 496 : __UNIT_TYPE output_len = _DIVIDE_CEILING_UNIT(x->UNIT_BIT_COUNT, 4);
mov edx, 4
mov rax, QWORD PTR x$[rbp]
mov rcx, QWORD PTR [rax+16]
call _DIVIDE_CEILING_UNIT
mov QWORD PTR output_len$1[rbp], rax
; 497 : __UNIT_TYPE filling_digit_len;;
; 498 : __UNIT_TYPE total_length;
; 499 : if (output_len < width)
mov eax, DWORD PTR width$[rbp]
cmp QWORD PTR output_len$1[rbp], rax
jae SHORT $LN8@ToStringX
; 500 : {
; 501 : filling_digit_len = width - output_len;
mov eax, DWORD PTR width$[rbp]
sub rax, QWORD PTR output_len$1[rbp]
mov QWORD PTR filling_digit_len$2[rbp], rax
; 502 : total_length = width;
mov eax, DWORD PTR width$[rbp]
mov QWORD PTR total_length$3[rbp], rax
; 503 : }
jmp SHORT $LN9@ToStringX
$LN8@ToStringX:
; 504 : else
; 505 : {
; 506 : filling_digit_len = 0;
mov QWORD PTR filling_digit_len$2[rbp], 0
; 507 : total_length = output_len;
mov rax, QWORD PTR output_len$1[rbp]
mov QWORD PTR total_length$3[rbp], rax
$LN9@ToStringX:
; 508 : }
; 509 : if (buffer_size < total_length + 1)
mov rax, QWORD PTR total_length$3[rbp]
inc rax
cmp QWORD PTR buffer_size$[rbp], rax
jae SHORT $LN10@ToStringX
; 510 : return (PMC_STATUS_INSUFFICIENT_BUFFER);
mov eax, -4
jmp $LN1@ToStringX
$LN10@ToStringX:
; 511 : __UNIT_TYPE filling_digit_count = filling_digit_len;
mov rax, QWORD PTR filling_digit_len$2[rbp]
mov QWORD PTR filling_digit_count$4[rbp], rax
; 512 : if (filling_digit_len > 0)
cmp QWORD PTR filling_digit_len$2[rbp], 0
jbe SHORT $LN11@ToStringX
; 513 : _FILL_MEMORY_16(buffer, L'0', filling_digit_len);
mov r8, QWORD PTR filling_digit_len$2[rbp]
mov dx, 48 ; 00000030H
mov rcx, QWORD PTR buffer$[rbp]
call _FILL_MEMORY_16
$LN11@ToStringX:
; 514 : __UNIT_TYPE* s_ptr = x->BLOCK + x->UNIT_WORD_COUNT - 1;
mov rax, QWORD PTR x$[rbp]
mov rax, QWORD PTR [rax+8]
mov rcx, QWORD PTR x$[rbp]
mov rcx, QWORD PTR [rcx+56]
lea rax, QWORD PTR [rcx+rax*8-8]
mov QWORD PTR s_ptr$5[rbp], rax
; 515 : wchar_t* d_ptr = buffer + filling_digit_len;
mov rax, QWORD PTR buffer$[rbp]
mov rcx, QWORD PTR filling_digit_len$2[rbp]
lea rax, QWORD PTR [rax+rcx*2]
mov QWORD PTR d_ptr$6[rbp], rax
; 516 : wchar_t* digit_table = using_upper_letter ? hexadecimal_upper_digits : hexadecimal_lower_digits;
cmp DWORD PTR using_upper_letter$[rbp], 0
je SHORT $LN13@ToStringX
lea rax, OFFSET FLAT:hexadecimal_upper_digits
mov QWORD PTR tv134[rbp], rax
jmp SHORT $LN14@ToStringX
$LN13@ToStringX:
lea rax, OFFSET FLAT:hexadecimal_lower_digits
mov QWORD PTR tv134[rbp], rax
$LN14@ToStringX:
mov rax, QWORD PTR tv134[rbp]
mov QWORD PTR digit_table$7[rbp], rax
; 517 : __UNIT_TYPE w_count = x->UNIT_WORD_COUNT;
mov rax, QWORD PTR x$[rbp]
mov rax, QWORD PTR [rax+8]
mov QWORD PTR w_count$8[rbp], rax
; 518 : d_ptr = ToStringX_1WORD(*s_ptr, (int)(x->UNIT_WORD_COUNT * (__UNIT_TYPE_BIT_COUNT / 4) - output_len), digit_table, d_ptr);
mov rax, QWORD PTR x$[rbp]
imul rax, QWORD PTR [rax+8], 16
sub rax, QWORD PTR output_len$1[rbp]
mov r9, QWORD PTR d_ptr$6[rbp]
mov r8, QWORD PTR digit_table$7[rbp]
mov edx, eax
mov rax, QWORD PTR s_ptr$5[rbp]
mov rcx, QWORD PTR [rax]
call ToStringX_1WORD
mov QWORD PTR d_ptr$6[rbp], rax
; 519 : --s_ptr;
mov rax, QWORD PTR s_ptr$5[rbp]
sub rax, 8
mov QWORD PTR s_ptr$5[rbp], rax
; 520 : --w_count;
mov rax, QWORD PTR w_count$8[rbp]
dec rax
mov QWORD PTR w_count$8[rbp], rax
$LN2@ToStringX:
; 521 : while (w_count > 0)
cmp QWORD PTR w_count$8[rbp], 0
jbe SHORT $LN3@ToStringX
; 522 : {
; 523 : d_ptr = ToStringX_1WORD(*s_ptr, 0, digit_table, d_ptr);
mov r9, QWORD PTR d_ptr$6[rbp]
mov r8, QWORD PTR digit_table$7[rbp]
xor edx, edx
mov rax, QWORD PTR s_ptr$5[rbp]
mov rcx, QWORD PTR [rax]
call ToStringX_1WORD
mov QWORD PTR d_ptr$6[rbp], rax
; 524 : --s_ptr;
mov rax, QWORD PTR s_ptr$5[rbp]
sub rax, 8
mov QWORD PTR s_ptr$5[rbp], rax
; 525 : --w_count;
mov rax, QWORD PTR w_count$8[rbp]
dec rax
mov QWORD PTR w_count$8[rbp], rax
; 526 : }
jmp SHORT $LN2@ToStringX
$LN3@ToStringX:
; 527 : *d_ptr = '\0';
xor eax, eax
mov rcx, QWORD PTR d_ptr$6[rbp]
mov WORD PTR [rcx], ax
$LN5@ToStringX:
; 528 : }
; 529 : return (PMC_STATUS_OK);
xor eax, eax
$LN1@ToStringX:
; 530 : }
lea rsp, QWORD PTR [rbp+456]
pop rdi
pop rbp
ret 0
ToStringX ENDP
_TEXT ENDS
; Function compile flags: /Odtp /RTCsu /ZI
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_tostring.c
; COMDAT ToStringX_1WORD
_TEXT SEGMENT
count$ = 4
x$ = 256
skip_digit_len$ = 264
digit_table$ = 272
ptr$ = 280
ToStringX_1WORD PROC ; COMDAT
; 412 : {
mov QWORD PTR [rsp+32], r9
mov QWORD PTR [rsp+24], r8
mov DWORD PTR [rsp+16], edx
mov QWORD PTR [rsp+8], rcx
push rbp
push rdi
sub rsp, 264 ; 00000108H
lea rbp, QWORD PTR [rsp+32]
mov rdi, rsp
mov ecx, 66 ; 00000042H
mov eax, -858993460 ; ccccccccH
rep stosd
mov rcx, QWORD PTR [rsp+296]
lea rcx, OFFSET FLAT:__3AA1CF5E_pmc_tostring@c
call __CheckForDebuggerJustMyCode
; 413 : if (sizeof(__UNIT_TYPE) > sizeof(_UINT64_T))
xor eax, eax
test eax, eax
je SHORT $LN2@ToStringX_
; 414 : {
; 415 : // 64bit を超える __UNIT_TYPE には未対応
; 416 : // 対応するには以降のコーディングを見直す必要がある
; 417 : return (NULL);
xor eax, eax
jmp $LN1@ToStringX_
$LN2@ToStringX_:
; 418 : }
; 419 : int count = __UNIT_TYPE_BIT_COUNT / 4;
mov DWORD PTR count$[rbp], 16
; 420 : if (skip_digit_len > 0)
cmp DWORD PTR skip_digit_len$[rbp], 0
jle SHORT $LN3@ToStringX_
; 421 : {
; 422 : x = _ROTATE_L_UNIT(x, 4 * skip_digit_len);
mov eax, DWORD PTR skip_digit_len$[rbp]
shl eax, 2
mov edx, eax
mov rcx, QWORD PTR x$[rbp]
call _ROTATE_L_UNIT
mov QWORD PTR x$[rbp], rax
; 423 : count -= skip_digit_len;
mov eax, DWORD PTR skip_digit_len$[rbp]
mov ecx, DWORD PTR count$[rbp]
sub ecx, eax
mov eax, ecx
mov DWORD PTR count$[rbp], eax
$LN3@ToStringX_:
; 424 : }
; 425 : if (count & 0x10)
mov eax, DWORD PTR count$[rbp]
and eax, 16
test eax, eax
je $LN4@ToStringX_
; 426 : {
; 427 : x = _ROTATE_L_UNIT(x, 4); ptr[0] = digit_table[x & 0x0f];
mov edx, 4
mov rcx, QWORD PTR x$[rbp]
call _ROTATE_L_UNIT
mov QWORD PTR x$[rbp], rax
mov rax, QWORD PTR x$[rbp]
and rax, 15
mov ecx, 2
imul rcx, rcx, 0
mov rdx, QWORD PTR ptr$[rbp]
mov r8, QWORD PTR digit_table$[rbp]
movzx eax, WORD PTR [r8+rax*2]
mov WORD PTR [rdx+rcx], ax
; 428 : x = _ROTATE_L_UNIT(x, 4); ptr[1] = digit_table[x & 0x0f];
mov edx, 4
mov rcx, QWORD PTR x$[rbp]
call _ROTATE_L_UNIT
mov QWORD PTR x$[rbp], rax
mov rax, QWORD PTR x$[rbp]
and rax, 15
mov ecx, 2
imul rcx, rcx, 1
mov rdx, QWORD PTR ptr$[rbp]
mov r8, QWORD PTR digit_table$[rbp]
movzx eax, WORD PTR [r8+rax*2]
mov WORD PTR [rdx+rcx], ax
; 429 : x = _ROTATE_L_UNIT(x, 4); ptr[2] = digit_table[x & 0x0f];
mov edx, 4
mov rcx, QWORD PTR x$[rbp]
call _ROTATE_L_UNIT
mov QWORD PTR x$[rbp], rax
mov rax, QWORD PTR x$[rbp]
and rax, 15
mov ecx, 2
imul rcx, rcx, 2
mov rdx, QWORD PTR ptr$[rbp]
mov r8, QWORD PTR digit_table$[rbp]
movzx eax, WORD PTR [r8+rax*2]
mov WORD PTR [rdx+rcx], ax
; 430 : x = _ROTATE_L_UNIT(x, 4); ptr[3] = digit_table[x & 0x0f];
mov edx, 4
mov rcx, QWORD PTR x$[rbp]
call _ROTATE_L_UNIT
mov QWORD PTR x$[rbp], rax
mov rax, QWORD PTR x$[rbp]
and rax, 15
mov ecx, 2
imul rcx, rcx, 3
mov rdx, QWORD PTR ptr$[rbp]
mov r8, QWORD PTR digit_table$[rbp]
movzx eax, WORD PTR [r8+rax*2]
mov WORD PTR [rdx+rcx], ax
; 431 : x = _ROTATE_L_UNIT(x, 4); ptr[4] = digit_table[x & 0x0f];
mov edx, 4
mov rcx, QWORD PTR x$[rbp]
call _ROTATE_L_UNIT
mov QWORD PTR x$[rbp], rax
mov rax, QWORD PTR x$[rbp]
and rax, 15
mov ecx, 2
imul rcx, rcx, 4
mov rdx, QWORD PTR ptr$[rbp]
mov r8, QWORD PTR digit_table$[rbp]
movzx eax, WORD PTR [r8+rax*2]
mov WORD PTR [rdx+rcx], ax
; 432 : x = _ROTATE_L_UNIT(x, 4); ptr[5] = digit_table[x & 0x0f];
mov edx, 4
mov rcx, QWORD PTR x$[rbp]
call _ROTATE_L_UNIT
mov QWORD PTR x$[rbp], rax
mov rax, QWORD PTR x$[rbp]
and rax, 15
mov ecx, 2
imul rcx, rcx, 5
mov rdx, QWORD PTR ptr$[rbp]
mov r8, QWORD PTR digit_table$[rbp]
movzx eax, WORD PTR [r8+rax*2]
mov WORD PTR [rdx+rcx], ax
; 433 : x = _ROTATE_L_UNIT(x, 4); ptr[6] = digit_table[x & 0x0f];
mov edx, 4
mov rcx, QWORD PTR x$[rbp]
call _ROTATE_L_UNIT
mov QWORD PTR x$[rbp], rax
mov rax, QWORD PTR x$[rbp]
and rax, 15
mov ecx, 2
imul rcx, rcx, 6
mov rdx, QWORD PTR ptr$[rbp]
mov r8, QWORD PTR digit_table$[rbp]
movzx eax, WORD PTR [r8+rax*2]
mov WORD PTR [rdx+rcx], ax
; 434 : x = _ROTATE_L_UNIT(x, 4); ptr[7] = digit_table[x & 0x0f];
mov edx, 4
mov rcx, QWORD PTR x$[rbp]
call _ROTATE_L_UNIT
mov QWORD PTR x$[rbp], rax
mov rax, QWORD PTR x$[rbp]
and rax, 15
mov ecx, 2
imul rcx, rcx, 7
mov rdx, QWORD PTR ptr$[rbp]
mov r8, QWORD PTR digit_table$[rbp]
movzx eax, WORD PTR [r8+rax*2]
mov WORD PTR [rdx+rcx], ax
; 435 : x = _ROTATE_L_UNIT(x, 4); ptr[8] = digit_table[x & 0x0f];
mov edx, 4
mov rcx, QWORD PTR x$[rbp]
call _ROTATE_L_UNIT
mov QWORD PTR x$[rbp], rax
mov rax, QWORD PTR x$[rbp]
and rax, 15
mov ecx, 2
imul rcx, rcx, 8
mov rdx, QWORD PTR ptr$[rbp]
mov r8, QWORD PTR digit_table$[rbp]
movzx eax, WORD PTR [r8+rax*2]
mov WORD PTR [rdx+rcx], ax
; 436 : x = _ROTATE_L_UNIT(x, 4); ptr[9] = digit_table[x & 0x0f];
mov edx, 4
mov rcx, QWORD PTR x$[rbp]
call _ROTATE_L_UNIT
mov QWORD PTR x$[rbp], rax
mov rax, QWORD PTR x$[rbp]
and rax, 15
mov ecx, 2
imul rcx, rcx, 9
mov rdx, QWORD PTR ptr$[rbp]
mov r8, QWORD PTR digit_table$[rbp]
movzx eax, WORD PTR [r8+rax*2]
mov WORD PTR [rdx+rcx], ax
; 437 : x = _ROTATE_L_UNIT(x, 4); ptr[10] = digit_table[x & 0x0f];
mov edx, 4
mov rcx, QWORD PTR x$[rbp]
call _ROTATE_L_UNIT
mov QWORD PTR x$[rbp], rax
mov rax, QWORD PTR x$[rbp]
and rax, 15
mov ecx, 2
imul rcx, rcx, 10
mov rdx, QWORD PTR ptr$[rbp]
mov r8, QWORD PTR digit_table$[rbp]
movzx eax, WORD PTR [r8+rax*2]
mov WORD PTR [rdx+rcx], ax
; 438 : x = _ROTATE_L_UNIT(x, 4); ptr[11] = digit_table[x & 0x0f];
mov edx, 4
mov rcx, QWORD PTR x$[rbp]
call _ROTATE_L_UNIT
mov QWORD PTR x$[rbp], rax
mov rax, QWORD PTR x$[rbp]
and rax, 15
mov ecx, 2
imul rcx, rcx, 11
mov rdx, QWORD PTR ptr$[rbp]
mov r8, QWORD PTR digit_table$[rbp]
movzx eax, WORD PTR [r8+rax*2]
mov WORD PTR [rdx+rcx], ax
; 439 : x = _ROTATE_L_UNIT(x, 4); ptr[12] = digit_table[x & 0x0f];
mov edx, 4
mov rcx, QWORD PTR x$[rbp]
call _ROTATE_L_UNIT
mov QWORD PTR x$[rbp], rax
mov rax, QWORD PTR x$[rbp]
and rax, 15
mov ecx, 2
imul rcx, rcx, 12
mov rdx, QWORD PTR ptr$[rbp]
mov r8, QWORD PTR digit_table$[rbp]
movzx eax, WORD PTR [r8+rax*2]
mov WORD PTR [rdx+rcx], ax
; 440 : x = _ROTATE_L_UNIT(x, 4); ptr[13] = digit_table[x & 0x0f];
mov edx, 4
mov rcx, QWORD PTR x$[rbp]
call _ROTATE_L_UNIT
mov QWORD PTR x$[rbp], rax
mov rax, QWORD PTR x$[rbp]
and rax, 15
mov ecx, 2
imul rcx, rcx, 13
mov rdx, QWORD PTR ptr$[rbp]
mov r8, QWORD PTR digit_table$[rbp]
movzx eax, WORD PTR [r8+rax*2]
mov WORD PTR [rdx+rcx], ax
; 441 : x = _ROTATE_L_UNIT(x, 4); ptr[14] = digit_table[x & 0x0f];
mov edx, 4
mov rcx, QWORD PTR x$[rbp]
call _ROTATE_L_UNIT
mov QWORD PTR x$[rbp], rax
mov rax, QWORD PTR x$[rbp]
and rax, 15
mov ecx, 2
imul rcx, rcx, 14
mov rdx, QWORD PTR ptr$[rbp]
mov r8, QWORD PTR digit_table$[rbp]
movzx eax, WORD PTR [r8+rax*2]
mov WORD PTR [rdx+rcx], ax
; 442 : x = _ROTATE_L_UNIT(x, 4); ptr[15] = digit_table[x & 0x0f];
mov edx, 4
mov rcx, QWORD PTR x$[rbp]
call _ROTATE_L_UNIT
mov QWORD PTR x$[rbp], rax
mov rax, QWORD PTR x$[rbp]
and rax, 15
mov ecx, 2
imul rcx, rcx, 15
mov rdx, QWORD PTR ptr$[rbp]
mov r8, QWORD PTR digit_table$[rbp]
movzx eax, WORD PTR [r8+rax*2]
mov WORD PTR [rdx+rcx], ax
; 443 : ptr += 16;
mov rax, QWORD PTR ptr$[rbp]
add rax, 32 ; 00000020H
mov QWORD PTR ptr$[rbp], rax
$LN4@ToStringX_:
; 444 : }
; 445 : if (count & 0x8)
mov eax, DWORD PTR count$[rbp]
and eax, 8
test eax, eax
je $LN5@ToStringX_
; 446 : {
; 447 : x = _ROTATE_L_UNIT(x, 4); ptr[0] = digit_table[x & 0x0f];
mov edx, 4
mov rcx, QWORD PTR x$[rbp]
call _ROTATE_L_UNIT
mov QWORD PTR x$[rbp], rax
mov rax, QWORD PTR x$[rbp]
and rax, 15
mov ecx, 2
imul rcx, rcx, 0
mov rdx, QWORD PTR ptr$[rbp]
mov r8, QWORD PTR digit_table$[rbp]
movzx eax, WORD PTR [r8+rax*2]
mov WORD PTR [rdx+rcx], ax
; 448 : x = _ROTATE_L_UNIT(x, 4); ptr[1] = digit_table[x & 0x0f];
mov edx, 4
mov rcx, QWORD PTR x$[rbp]
call _ROTATE_L_UNIT
mov QWORD PTR x$[rbp], rax
mov rax, QWORD PTR x$[rbp]
and rax, 15
mov ecx, 2
imul rcx, rcx, 1
mov rdx, QWORD PTR ptr$[rbp]
mov r8, QWORD PTR digit_table$[rbp]
movzx eax, WORD PTR [r8+rax*2]
mov WORD PTR [rdx+rcx], ax
; 449 : x = _ROTATE_L_UNIT(x, 4); ptr[2] = digit_table[x & 0x0f];
mov edx, 4
mov rcx, QWORD PTR x$[rbp]
call _ROTATE_L_UNIT
mov QWORD PTR x$[rbp], rax
mov rax, QWORD PTR x$[rbp]
and rax, 15
mov ecx, 2
imul rcx, rcx, 2
mov rdx, QWORD PTR ptr$[rbp]
mov r8, QWORD PTR digit_table$[rbp]
movzx eax, WORD PTR [r8+rax*2]
mov WORD PTR [rdx+rcx], ax
; 450 : x = _ROTATE_L_UNIT(x, 4); ptr[3] = digit_table[x & 0x0f];
mov edx, 4
mov rcx, QWORD PTR x$[rbp]
call _ROTATE_L_UNIT
mov QWORD PTR x$[rbp], rax
mov rax, QWORD PTR x$[rbp]
and rax, 15
mov ecx, 2
imul rcx, rcx, 3
mov rdx, QWORD PTR ptr$[rbp]
mov r8, QWORD PTR digit_table$[rbp]
movzx eax, WORD PTR [r8+rax*2]
mov WORD PTR [rdx+rcx], ax
; 451 : x = _ROTATE_L_UNIT(x, 4); ptr[4] = digit_table[x & 0x0f];
mov edx, 4
mov rcx, QWORD PTR x$[rbp]
call _ROTATE_L_UNIT
mov QWORD PTR x$[rbp], rax
mov rax, QWORD PTR x$[rbp]
and rax, 15
mov ecx, 2
imul rcx, rcx, 4
mov rdx, QWORD PTR ptr$[rbp]
mov r8, QWORD PTR digit_table$[rbp]
movzx eax, WORD PTR [r8+rax*2]
mov WORD PTR [rdx+rcx], ax
; 452 : x = _ROTATE_L_UNIT(x, 4); ptr[5] = digit_table[x & 0x0f];
mov edx, 4
mov rcx, QWORD PTR x$[rbp]
call _ROTATE_L_UNIT
mov QWORD PTR x$[rbp], rax
mov rax, QWORD PTR x$[rbp]
and rax, 15
mov ecx, 2
imul rcx, rcx, 5
mov rdx, QWORD PTR ptr$[rbp]
mov r8, QWORD PTR digit_table$[rbp]
movzx eax, WORD PTR [r8+rax*2]
mov WORD PTR [rdx+rcx], ax
; 453 : x = _ROTATE_L_UNIT(x, 4); ptr[6] = digit_table[x & 0x0f];
mov edx, 4
mov rcx, QWORD PTR x$[rbp]
call _ROTATE_L_UNIT
mov QWORD PTR x$[rbp], rax
mov rax, QWORD PTR x$[rbp]
and rax, 15
mov ecx, 2
imul rcx, rcx, 6
mov rdx, QWORD PTR ptr$[rbp]
mov r8, QWORD PTR digit_table$[rbp]
movzx eax, WORD PTR [r8+rax*2]
mov WORD PTR [rdx+rcx], ax
; 454 : x = _ROTATE_L_UNIT(x, 4); ptr[7] = digit_table[x & 0x0f];
mov edx, 4
mov rcx, QWORD PTR x$[rbp]
call _ROTATE_L_UNIT
mov QWORD PTR x$[rbp], rax
mov rax, QWORD PTR x$[rbp]
and rax, 15
mov ecx, 2
imul rcx, rcx, 7
mov rdx, QWORD PTR ptr$[rbp]
mov r8, QWORD PTR digit_table$[rbp]
movzx eax, WORD PTR [r8+rax*2]
mov WORD PTR [rdx+rcx], ax
; 455 : ptr+=8;
mov rax, QWORD PTR ptr$[rbp]
add rax, 16
mov QWORD PTR ptr$[rbp], rax
$LN5@ToStringX_:
; 456 : }
; 457 : if (count & 0x4)
mov eax, DWORD PTR count$[rbp]
and eax, 4
test eax, eax
je $LN6@ToStringX_
; 458 : {
; 459 : x = _ROTATE_L_UNIT(x, 4); ptr[0] = digit_table[x & 0x0f];
mov edx, 4
mov rcx, QWORD PTR x$[rbp]
call _ROTATE_L_UNIT
mov QWORD PTR x$[rbp], rax
mov rax, QWORD PTR x$[rbp]
and rax, 15
mov ecx, 2
imul rcx, rcx, 0
mov rdx, QWORD PTR ptr$[rbp]
mov r8, QWORD PTR digit_table$[rbp]
movzx eax, WORD PTR [r8+rax*2]
mov WORD PTR [rdx+rcx], ax
; 460 : x = _ROTATE_L_UNIT(x, 4); ptr[1] = digit_table[x & 0x0f];
mov edx, 4
mov rcx, QWORD PTR x$[rbp]
call _ROTATE_L_UNIT
mov QWORD PTR x$[rbp], rax
mov rax, QWORD PTR x$[rbp]
and rax, 15
mov ecx, 2
imul rcx, rcx, 1
mov rdx, QWORD PTR ptr$[rbp]
mov r8, QWORD PTR digit_table$[rbp]
movzx eax, WORD PTR [r8+rax*2]
mov WORD PTR [rdx+rcx], ax
; 461 : x = _ROTATE_L_UNIT(x, 4); ptr[2] = digit_table[x & 0x0f];
mov edx, 4
mov rcx, QWORD PTR x$[rbp]
call _ROTATE_L_UNIT
mov QWORD PTR x$[rbp], rax
mov rax, QWORD PTR x$[rbp]
and rax, 15
mov ecx, 2
imul rcx, rcx, 2
mov rdx, QWORD PTR ptr$[rbp]
mov r8, QWORD PTR digit_table$[rbp]
movzx eax, WORD PTR [r8+rax*2]
mov WORD PTR [rdx+rcx], ax
; 462 : x = _ROTATE_L_UNIT(x, 4); ptr[3] = digit_table[x & 0x0f];
mov edx, 4
mov rcx, QWORD PTR x$[rbp]
call _ROTATE_L_UNIT
mov QWORD PTR x$[rbp], rax
mov rax, QWORD PTR x$[rbp]
and rax, 15
mov ecx, 2
imul rcx, rcx, 3
mov rdx, QWORD PTR ptr$[rbp]
mov r8, QWORD PTR digit_table$[rbp]
movzx eax, WORD PTR [r8+rax*2]
mov WORD PTR [rdx+rcx], ax
; 463 : ptr += 4;
mov rax, QWORD PTR ptr$[rbp]
add rax, 8
mov QWORD PTR ptr$[rbp], rax
$LN6@ToStringX_:
; 464 : }
; 465 : if (count & 0x2)
mov eax, DWORD PTR count$[rbp]
and eax, 2
test eax, eax
je $LN7@ToStringX_
; 466 : {
; 467 : x = _ROTATE_L_UNIT(x, 4); ptr[0] = digit_table[x & 0x0f];
mov edx, 4
mov rcx, QWORD PTR x$[rbp]
call _ROTATE_L_UNIT
mov QWORD PTR x$[rbp], rax
mov rax, QWORD PTR x$[rbp]
and rax, 15
mov ecx, 2
imul rcx, rcx, 0
mov rdx, QWORD PTR ptr$[rbp]
mov r8, QWORD PTR digit_table$[rbp]
movzx eax, WORD PTR [r8+rax*2]
mov WORD PTR [rdx+rcx], ax
; 468 : x = _ROTATE_L_UNIT(x, 4); ptr[1] = digit_table[x & 0x0f];
mov edx, 4
mov rcx, QWORD PTR x$[rbp]
call _ROTATE_L_UNIT
mov QWORD PTR x$[rbp], rax
mov rax, QWORD PTR x$[rbp]
and rax, 15
mov ecx, 2
imul rcx, rcx, 1
mov rdx, QWORD PTR ptr$[rbp]
mov r8, QWORD PTR digit_table$[rbp]
movzx eax, WORD PTR [r8+rax*2]
mov WORD PTR [rdx+rcx], ax
; 469 : ptr += 2;
mov rax, QWORD PTR ptr$[rbp]
add rax, 4
mov QWORD PTR ptr$[rbp], rax
$LN7@ToStringX_:
; 470 : }
; 471 : if (count & 0x1)
mov eax, DWORD PTR count$[rbp]
and eax, 1
test eax, eax
je SHORT $LN8@ToStringX_
; 472 : {
; 473 : x = _ROTATE_L_UNIT(x, 4); ptr[0] = digit_table[x & 0x0f];
mov edx, 4
mov rcx, QWORD PTR x$[rbp]
call _ROTATE_L_UNIT
mov QWORD PTR x$[rbp], rax
mov rax, QWORD PTR x$[rbp]
and rax, 15
mov ecx, 2
imul rcx, rcx, 0
mov rdx, QWORD PTR ptr$[rbp]
mov r8, QWORD PTR digit_table$[rbp]
movzx eax, WORD PTR [r8+rax*2]
mov WORD PTR [rdx+rcx], ax
; 474 : ptr += 1;
mov rax, QWORD PTR ptr$[rbp]
add rax, 2
mov QWORD PTR ptr$[rbp], rax
$LN8@ToStringX_:
; 475 : }
; 476 : return (ptr);
mov rax, QWORD PTR ptr$[rbp]
$LN1@ToStringX_:
; 477 : }
lea rsp, QWORD PTR [rbp+232]
pop rdi
pop rbp
ret 0
ToStringX_1WORD ENDP
_TEXT ENDS
; Function compile flags: /Odtp /RTCsu /ZI
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_tostring.c
; COMDAT ToStringDN
_TEXT SEGMENT
base_value$ = 4
word_digit_count$ = 36
decimal_separator_len$9 = 68
result$10 = 100
r_buf_code$11 = 136
r_buf_words$12 = 168
r_buf$13 = 200
r_buf_count$14 = 232
rev_str_buf_code$15 = 264
rev_str_buf_words$16 = 296
rev_str_buf$17 = 328
rev_str_buf_count$18 = 360
tv180 = 568
x$ = 608
buffer$ = 616
buffer_size$ = 624
format$ = 632
width$ = 640
format_option$ = 648
ToStringDN PROC ; COMDAT
; 319 : {
mov BYTE PTR [rsp+32], r9b
mov QWORD PTR [rsp+24], r8
mov QWORD PTR [rsp+16], rdx
mov QWORD PTR [rsp+8], rcx
push rbp
push rdi
sub rsp, 648 ; 00000288H
lea rbp, QWORD PTR [rsp+64]
mov rdi, rsp
mov ecx, 162 ; 000000a2H
mov eax, -858993460 ; ccccccccH
rep stosd
mov rcx, QWORD PTR [rsp+680]
lea rcx, OFFSET FLAT:__3AA1CF5E_pmc_tostring@c
call __CheckForDebuggerJustMyCode
; 320 : __UNIT_TYPE_DIV base_value;
; 321 : int word_digit_count;
; 322 : if (sizeof(__UNIT_TYPE_DIV) == sizeof(_UINT32_T))
xor eax, eax
cmp eax, 1
je SHORT $LN2@ToStringDN
; 323 : {
; 324 : base_value = 1000000000U; // 10^9
mov DWORD PTR base_value$[rbp], 1000000000 ; 3b9aca00H
; 325 : word_digit_count = 9;
mov DWORD PTR word_digit_count$[rbp], 9
; 326 : }
jmp SHORT $LN3@ToStringDN
$LN2@ToStringDN:
; 327 : else if (sizeof(__UNIT_TYPE_DIV) == sizeof(_UINT64_T))
xor eax, eax
test eax, eax
je SHORT $LN4@ToStringDN
; 328 : {
; 329 : base_value = (__UNIT_TYPE_DIV)10000000000000000000UL; // 10^19
mov DWORD PTR base_value$[rbp], -1981284352 ; 89e80000H
; 330 : word_digit_count = 19;
mov DWORD PTR word_digit_count$[rbp], 19
; 331 : }
jmp SHORT $LN5@ToStringDN
$LN4@ToStringDN:
; 332 : else
; 333 : return (PMC_STATUS_NOT_SUPPORTED);
mov eax, -6
jmp $LN1@ToStringDN
$LN5@ToStringDN:
$LN3@ToStringDN:
; 334 :
; 335 : if (x->IS_ZERO)
mov rax, QWORD PTR x$[rbp]
mov eax, DWORD PTR [rax+40]
shr eax, 1
and eax, 1
test eax, eax
je $LN6@ToStringDN
; 336 : {
; 337 : // x が 0 である場合
; 338 : if (format == 'N')
movsx eax, BYTE PTR format$[rbp]
cmp eax, 78 ; 0000004eH
jne $LN8@ToStringDN
; 339 : {
; 340 : // format が 'N' である場合
; 341 :
; 342 : // 整数部が 1 桁の 0、小数部が width 桁の 0 である文字列を出力する。
; 343 : buffer[0] = '0';
mov eax, 2
imul rax, rax, 0
mov ecx, 48 ; 00000030H
mov rdx, QWORD PTR buffer$[rbp]
mov WORD PTR [rdx+rax], cx
; 344 : if (width == 0)
cmp DWORD PTR width$[rbp], 0
jne SHORT $LN10@ToStringDN
; 345 : buffer[1] = L'\0';
mov eax, 2
imul rax, rax, 1
xor ecx, ecx
mov rdx, QWORD PTR buffer$[rbp]
mov WORD PTR [rdx+rax], cx
jmp SHORT $LN11@ToStringDN
$LN10@ToStringDN:
; 346 : else
; 347 : {
; 348 : lstrcpyW(&buffer[1], format_option->DecimalSeparator);
mov rax, QWORD PTR format_option$[rbp]
add rax, 10
mov ecx, 2
imul rcx, rcx, 1
mov rdx, QWORD PTR buffer$[rbp]
add rdx, rcx
mov rcx, rdx
mov rdx, rax
call QWORD PTR __imp_lstrcpyW
; 349 : int decimal_separator_len = lstrlenW(format_option->DecimalSeparator);
mov rax, QWORD PTR format_option$[rbp]
add rax, 10
mov rcx, rax
call QWORD PTR __imp_lstrlenW
mov DWORD PTR decimal_separator_len$9[rbp], eax
; 350 : _FILL_MEMORY_16(buffer + 1 + decimal_separator_len, L'0', width);
mov eax, DWORD PTR width$[rbp]
movsxd rcx, DWORD PTR decimal_separator_len$9[rbp]
mov rdx, QWORD PTR buffer$[rbp]
lea rcx, QWORD PTR [rdx+rcx*2+2]
mov r8d, eax
mov dx, 48 ; 00000030H
call _FILL_MEMORY_16
; 351 : buffer[1 + decimal_separator_len + width] = L'\0';
mov eax, DWORD PTR decimal_separator_len$9[rbp]
mov ecx, DWORD PTR width$[rbp]
lea eax, DWORD PTR [rax+rcx+1]
mov eax, eax
xor ecx, ecx
mov rdx, QWORD PTR buffer$[rbp]
mov WORD PTR [rdx+rax*2], cx
$LN11@ToStringDN:
; 352 : }
; 353 : }
jmp SHORT $LN9@ToStringDN
$LN8@ToStringDN:
; 354 : else
; 355 : {
; 356 : // format が 'D' である場合
; 357 :
; 358 : // 最低で 1 桁、最高で width 桁だけ '0' を出力する。
; 359 : if (width < 1)
cmp DWORD PTR width$[rbp], 1
jae SHORT $LN12@ToStringDN
; 360 : width = 1;
mov DWORD PTR width$[rbp], 1
$LN12@ToStringDN:
; 361 : if (buffer_size < width + 1)
mov eax, DWORD PTR width$[rbp]
inc eax
mov eax, eax
cmp QWORD PTR buffer_size$[rbp], rax
jae SHORT $LN13@ToStringDN
; 362 : return (PMC_STATUS_INSUFFICIENT_BUFFER);
mov eax, -4
jmp $LN1@ToStringDN
$LN13@ToStringDN:
; 363 : _FILL_MEMORY_16(buffer, L'0', width);
mov eax, DWORD PTR width$[rbp]
mov r8d, eax
mov dx, 48 ; 00000030H
mov rcx, QWORD PTR buffer$[rbp]
call _FILL_MEMORY_16
; 364 : buffer[width] = L'\0';
mov eax, DWORD PTR width$[rbp]
xor ecx, ecx
mov rdx, QWORD PTR buffer$[rbp]
mov WORD PTR [rdx+rax*2], cx
$LN9@ToStringDN:
; 365 : }
; 366 : }
jmp $LN7@ToStringDN
$LN6@ToStringDN:
; 367 : else
; 368 : {
; 369 : // x が 0 ではない場合
; 370 : PMC_STATUS_CODE result;
; 371 : __UNIT_TYPE r_buf_code;
; 372 : __UNIT_TYPE r_buf_words;
; 373 : // xを base_value 基数として変換した数値が r に格納される。約 7% ほど余分に領域が必要な計算になるが、余裕を見て 12.5% 程度の領域を獲得している。
; 374 : __UNIT_TYPE_DIV* r_buf = (__UNIT_TYPE_DIV*)AllocateBlock(x->UNIT_BIT_COUNT + (x->UNIT_BIT_COUNT >> 3) + __UNIT_TYPE_BIT_COUNT, &r_buf_words, &r_buf_code);
mov rax, QWORD PTR x$[rbp]
mov rax, QWORD PTR [rax+16]
shr rax, 3
mov rcx, QWORD PTR x$[rbp]
mov rcx, QWORD PTR [rcx+16]
lea rax, QWORD PTR [rcx+rax+64]
lea r8, QWORD PTR r_buf_code$11[rbp]
lea rdx, QWORD PTR r_buf_words$12[rbp]
mov rcx, rax
call AllocateBlock
mov QWORD PTR r_buf$13[rbp], rax
; 375 : if (r_buf == NULL)
cmp QWORD PTR r_buf$13[rbp], 0
jne SHORT $LN14@ToStringDN
; 376 : return (PMC_STATUS_NOT_ENOUGH_MEMORY);
mov eax, -5
jmp $LN1@ToStringDN
$LN14@ToStringDN:
; 377 : __UNIT_TYPE r_buf_count;
; 378 : if ((result = ConvertCardinalNumber((__UNIT_TYPE_DIV*)x->BLOCK, x->UNIT_WORD_COUNT * sizeof(__UNIT_TYPE) / sizeof(__UNIT_TYPE_DIV), x->UNIT_BIT_COUNT, base_value, r_buf, &r_buf_count)) != PMC_STATUS_OK)
mov rax, QWORD PTR x$[rbp]
mov rax, QWORD PTR [rax+8]
shl rax, 3
xor edx, edx
mov ecx, 4
div rcx
lea rcx, QWORD PTR r_buf_count$14[rbp]
mov QWORD PTR [rsp+40], rcx
mov rcx, QWORD PTR r_buf$13[rbp]
mov QWORD PTR [rsp+32], rcx
mov r9d, DWORD PTR base_value$[rbp]
mov rcx, QWORD PTR x$[rbp]
mov r8, QWORD PTR [rcx+16]
mov rdx, rax
mov rax, QWORD PTR x$[rbp]
mov rcx, QWORD PTR [rax+56]
call ConvertCardinalNumber
mov DWORD PTR result$10[rbp], eax
cmp DWORD PTR result$10[rbp], 0
je SHORT $LN15@ToStringDN
; 379 : {
; 380 : DeallocateBlock((__UNIT_TYPE*)r_buf, r_buf_words);
mov rdx, QWORD PTR r_buf_words$12[rbp]
mov rcx, QWORD PTR r_buf$13[rbp]
call DeallocateBlock
; 381 : return (result);
mov eax, DWORD PTR result$10[rbp]
jmp $LN1@ToStringDN
$LN15@ToStringDN:
; 382 : }
; 383 : if ((result = CheckBlockLight((__UNIT_TYPE*)r_buf, r_buf_code)) != PMC_STATUS_OK)
mov rdx, QWORD PTR r_buf_code$11[rbp]
mov rcx, QWORD PTR r_buf$13[rbp]
call CheckBlockLight
mov DWORD PTR result$10[rbp], eax
cmp DWORD PTR result$10[rbp], 0
je SHORT $LN16@ToStringDN
; 384 : return (result);
mov eax, DWORD PTR result$10[rbp]
jmp $LN1@ToStringDN
$LN16@ToStringDN:
; 385 :
; 386 : __UNIT_TYPE rev_str_buf_code;
; 387 : __UNIT_TYPE rev_str_buf_words;
; 388 : // 獲得領域長の * 2 は、桁区切りのワーストケースにより文字列が膨らんだ場合を考慮したもの。
; 389 : wchar_t* rev_str_buf = (wchar_t*)AllocateBlock((max(r_buf_count * word_digit_count, width) * 2 + width + 2) * sizeof(wchar_t) * 8, &rev_str_buf_words, &rev_str_buf_code);
movsxd rax, DWORD PTR word_digit_count$[rbp]
mov rcx, QWORD PTR r_buf_count$14[rbp]
imul rcx, rax
mov rax, rcx
mov ecx, DWORD PTR width$[rbp]
cmp rax, rcx
jbe SHORT $LN21@ToStringDN
movsxd rax, DWORD PTR word_digit_count$[rbp]
mov rcx, QWORD PTR r_buf_count$14[rbp]
imul rcx, rax
mov rax, rcx
mov QWORD PTR tv180[rbp], rax
jmp SHORT $LN22@ToStringDN
$LN21@ToStringDN:
mov eax, DWORD PTR width$[rbp]
mov QWORD PTR tv180[rbp], rax
$LN22@ToStringDN:
mov eax, DWORD PTR width$[rbp]
mov rcx, QWORD PTR tv180[rbp]
lea rax, QWORD PTR [rax+rcx*2]
lea rax, QWORD PTR [rax+rax+4]
shl rax, 3
lea r8, QWORD PTR rev_str_buf_code$15[rbp]
lea rdx, QWORD PTR rev_str_buf_words$16[rbp]
mov rcx, rax
call AllocateBlock
mov QWORD PTR rev_str_buf$17[rbp], rax
; 390 : if (r_buf == NULL)
cmp QWORD PTR r_buf$13[rbp], 0
jne SHORT $LN17@ToStringDN
; 391 : {
; 392 : DeallocateBlock((__UNIT_TYPE*)r_buf, r_buf_words);
mov rdx, QWORD PTR r_buf_words$12[rbp]
mov rcx, QWORD PTR r_buf$13[rbp]
call DeallocateBlock
; 393 : return (PMC_STATUS_NOT_ENOUGH_MEMORY);
mov eax, -5
jmp $LN1@ToStringDN
$LN17@ToStringDN:
; 394 : }
; 395 : __UNIT_TYPE rev_str_buf_count;
; 396 : PrintDecimal(r_buf, r_buf_count, rev_str_buf, &rev_str_buf_count, format, width, format_option);
mov rax, QWORD PTR format_option$[rbp]
mov QWORD PTR [rsp+48], rax
mov eax, DWORD PTR width$[rbp]
mov DWORD PTR [rsp+40], eax
movzx eax, BYTE PTR format$[rbp]
mov BYTE PTR [rsp+32], al
lea r9, QWORD PTR rev_str_buf_count$18[rbp]
mov r8, QWORD PTR rev_str_buf$17[rbp]
mov rdx, QWORD PTR r_buf_count$14[rbp]
mov rcx, QWORD PTR r_buf$13[rbp]
call PrintDecimal
; 397 : if ((result = CheckBlockLight((__UNIT_TYPE*)rev_str_buf, rev_str_buf_code)) != PMC_STATUS_OK)
mov rdx, QWORD PTR rev_str_buf_code$15[rbp]
mov rcx, QWORD PTR rev_str_buf$17[rbp]
call CheckBlockLight
mov DWORD PTR result$10[rbp], eax
cmp DWORD PTR result$10[rbp], 0
je SHORT $LN18@ToStringDN
; 398 : return (result);
mov eax, DWORD PTR result$10[rbp]
jmp SHORT $LN1@ToStringDN
$LN18@ToStringDN:
; 399 : DeallocateBlock((__UNIT_TYPE*)r_buf, r_buf_words);
mov rdx, QWORD PTR r_buf_words$12[rbp]
mov rcx, QWORD PTR r_buf$13[rbp]
call DeallocateBlock
; 400 : if (rev_str_buf_count + 1 > buffer_size)
mov rax, QWORD PTR rev_str_buf_count$18[rbp]
inc rax
cmp rax, QWORD PTR buffer_size$[rbp]
jbe SHORT $LN19@ToStringDN
; 401 : {
; 402 : DeallocateBlock((__UNIT_TYPE*)rev_str_buf, rev_str_buf_words);
mov rdx, QWORD PTR rev_str_buf_words$16[rbp]
mov rcx, QWORD PTR rev_str_buf$17[rbp]
call DeallocateBlock
; 403 : return (PMC_STATUS_INSUFFICIENT_BUFFER);
mov eax, -4
jmp SHORT $LN1@ToStringDN
$LN19@ToStringDN:
; 404 : }
; 405 : ToStringDN_Finalize(rev_str_buf, rev_str_buf_count, buffer, buffer_size);
mov r9, QWORD PTR buffer_size$[rbp]
mov r8, QWORD PTR buffer$[rbp]
mov rdx, QWORD PTR rev_str_buf_count$18[rbp]
mov rcx, QWORD PTR rev_str_buf$17[rbp]
call ToStringDN_Finalize
; 406 : DeallocateBlock((__UNIT_TYPE*)rev_str_buf, rev_str_buf_words);
mov rdx, QWORD PTR rev_str_buf_words$16[rbp]
mov rcx, QWORD PTR rev_str_buf$17[rbp]
call DeallocateBlock
$LN7@ToStringDN:
; 407 : }
; 408 : return (PMC_STATUS_OK);
xor eax, eax
$LN1@ToStringDN:
; 409 : }
mov rdi, rax
lea rcx, QWORD PTR [rbp-64]
lea rdx, OFFSET FLAT:ToStringDN$rtcFrameData
call _RTC_CheckStackVars
mov rax, rdi
lea rsp, QWORD PTR [rbp+584]
pop rdi
pop rbp
ret 0
ToStringDN ENDP
_TEXT ENDS
; Function compile flags: /Odtp /RTCsu /ZI
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_tostring.c
; COMDAT ToStringDN_Finalize
_TEXT SEGMENT
in_ptr$ = 8
out_ptr$ = 40
count$ = 72
in_buf$ = 320
in_buf_count$ = 328
out_buf$ = 336
out_buf_count$ = 344
ToStringDN_Finalize PROC ; COMDAT
; 306 : {
mov QWORD PTR [rsp+32], r9
mov QWORD PTR [rsp+24], r8
mov QWORD PTR [rsp+16], rdx
mov QWORD PTR [rsp+8], rcx
push rbp
push rdi
sub rsp, 328 ; 00000148H
lea rbp, QWORD PTR [rsp+32]
mov rdi, rsp
mov ecx, 82 ; 00000052H
mov eax, -858993460 ; ccccccccH
rep stosd
mov rcx, QWORD PTR [rsp+360]
lea rcx, OFFSET FLAT:__3AA1CF5E_pmc_tostring@c
call __CheckForDebuggerJustMyCode
; 307 : wchar_t* in_ptr = in_buf + in_buf_count - 1;
mov rax, QWORD PTR in_buf$[rbp]
mov rcx, QWORD PTR in_buf_count$[rbp]
lea rax, QWORD PTR [rax+rcx*2-2]
mov QWORD PTR in_ptr$[rbp], rax
; 308 : wchar_t* out_ptr = out_buf;
mov rax, QWORD PTR out_buf$[rbp]
mov QWORD PTR out_ptr$[rbp], rax
; 309 : __UNIT_TYPE count = in_buf_count;
mov rax, QWORD PTR in_buf_count$[rbp]
mov QWORD PTR count$[rbp], rax
$LN2@ToStringDN:
; 310 : while (count > 0)
cmp QWORD PTR count$[rbp], 0
jbe SHORT $LN3@ToStringDN
; 311 : {
; 312 : *out_ptr++ = *in_ptr--;
mov rax, QWORD PTR out_ptr$[rbp]
mov rcx, QWORD PTR in_ptr$[rbp]
movzx ecx, WORD PTR [rcx]
mov WORD PTR [rax], cx
mov rax, QWORD PTR out_ptr$[rbp]
add rax, 2
mov QWORD PTR out_ptr$[rbp], rax
mov rax, QWORD PTR in_ptr$[rbp]
sub rax, 2
mov QWORD PTR in_ptr$[rbp], rax
; 313 : --count;
mov rax, QWORD PTR count$[rbp]
dec rax
mov QWORD PTR count$[rbp], rax
; 314 : }
jmp SHORT $LN2@ToStringDN
$LN3@ToStringDN:
; 315 : *out_ptr = L'\0';
xor eax, eax
mov rcx, QWORD PTR out_ptr$[rbp]
mov WORD PTR [rcx], ax
; 316 : }
lea rsp, QWORD PTR [rbp+296]
pop rdi
pop rbp
ret 0
ToStringDN_Finalize ENDP
_TEXT ENDS
; Function compile flags: /Odtp /RTCsu /ZI
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_tostring.c
; COMDAT PrintDecimal
_TEXT SEGMENT
state$ = 8
count$4 = 84
in_ptr$ = 120
in_count$ = 152
count$5 = 180
__$ArrayPad$ = 392
in_buf$ = 432
in_buf_count$ = 440
out_buf$ = 448
out_buf_count$ = 456
format$ = 464
width$ = 472
format_option$ = 480
PrintDecimal PROC ; COMDAT
; 264 : {
mov QWORD PTR [rsp+32], r9
mov QWORD PTR [rsp+24], r8
mov QWORD PTR [rsp+16], rdx
mov QWORD PTR [rsp+8], rcx
push rbp
push rdi
sub rsp, 440 ; 000001b8H
lea rbp, QWORD PTR [rsp+32]
mov rdi, rsp
mov ecx, 110 ; 0000006eH
mov eax, -858993460 ; ccccccccH
rep stosd
mov rcx, QWORD PTR [rsp+472]
mov rax, QWORD PTR __security_cookie
xor rax, rbp
mov QWORD PTR __$ArrayPad$[rbp], rax
lea rcx, OFFSET FLAT:__3AA1CF5E_pmc_tostring@c
call __CheckForDebuggerJustMyCode
; 265 : struct TOSTRINGN_OUTPUT_STATE state;
; 266 : InitializeOutputState(&state, out_buf, format, format_option);
mov r9, QWORD PTR format_option$[rbp]
movzx r8d, BYTE PTR format$[rbp]
mov rdx, QWORD PTR out_buf$[rbp]
lea rcx, QWORD PTR state$[rbp]
call InitializeOutputState
; 267 : if (format == 'N' && width > 0)
movsx eax, BYTE PTR format$[rbp]
cmp eax, 78 ; 0000004eH
jne SHORT $LN8@PrintDecim
cmp DWORD PTR width$[rbp], 0
jbe SHORT $LN8@PrintDecim
; 268 : {
; 269 : _UINT32_T count = width;
mov eax, DWORD PTR width$[rbp]
mov DWORD PTR count$4[rbp], eax
$LN2@PrintDecim:
; 270 : while (count > 0)
cmp DWORD PTR count$4[rbp], 0
jbe SHORT $LN3@PrintDecim
; 271 : {
; 272 : OutputUngroupedOneChar(&state, 0);
xor edx, edx
lea rcx, QWORD PTR state$[rbp]
call OutputUngroupedOneChar
; 273 : --count;
mov eax, DWORD PTR count$4[rbp]
dec eax
mov DWORD PTR count$4[rbp], eax
; 274 : }
jmp SHORT $LN2@PrintDecim
$LN3@PrintDecim:
; 275 : OutputDecimalSeparator(&state);
lea rcx, QWORD PTR state$[rbp]
call OutputDecimalSeparator
$LN8@PrintDecim:
; 276 : }
; 277 : __UNIT_TYPE_DIV* in_ptr = in_buf;
mov rax, QWORD PTR in_buf$[rbp]
mov QWORD PTR in_ptr$[rbp], rax
; 278 : __UNIT_TYPE in_count = in_buf_count - 1;
mov rax, QWORD PTR in_buf_count$[rbp]
dec rax
mov QWORD PTR in_count$[rbp], rax
$LN4@PrintDecim:
; 279 : while (in_count != 0)
cmp QWORD PTR in_count$[rbp], 0
je SHORT $LN5@PrintDecim
; 280 : {
; 281 : ToStringDN_1WORD(&state, *in_ptr);
mov rax, QWORD PTR in_ptr$[rbp]
mov edx, DWORD PTR [rax]
lea rcx, QWORD PTR state$[rbp]
call ToStringDN_1WORD
; 282 : ++in_ptr;
mov rax, QWORD PTR in_ptr$[rbp]
add rax, 4
mov QWORD PTR in_ptr$[rbp], rax
; 283 : --in_count;
mov rax, QWORD PTR in_count$[rbp]
dec rax
mov QWORD PTR in_count$[rbp], rax
; 284 : }
jmp SHORT $LN4@PrintDecim
$LN5@PrintDecim:
; 285 : ToStringDN_LEADING_1WORD(&state, *in_ptr);
mov rax, QWORD PTR in_ptr$[rbp]
mov edx, DWORD PTR [rax]
lea rcx, QWORD PTR state$[rbp]
call ToStringDN_LEADING_1WORD
; 286 : ++in_ptr;
mov rax, QWORD PTR in_ptr$[rbp]
add rax, 4
mov QWORD PTR in_ptr$[rbp], rax
; 287 : --in_count;
mov rax, QWORD PTR in_count$[rbp]
dec rax
mov QWORD PTR in_count$[rbp], rax
; 288 : if (format == 'D')
movsx eax, BYTE PTR format$[rbp]
cmp eax, 68 ; 00000044H
jne SHORT $LN9@PrintDecim
; 289 : {
; 290 : if (state.OUT_PTR < out_buf + width)
mov eax, DWORD PTR width$[rbp]
mov rcx, QWORD PTR out_buf$[rbp]
lea rax, QWORD PTR [rcx+rax*2]
cmp QWORD PTR state$[rbp+48], rax
jae SHORT $LN10@PrintDecim
; 291 : {
; 292 : int count = width - (int)(state.OUT_PTR - out_buf);
mov rax, QWORD PTR out_buf$[rbp]
mov rcx, QWORD PTR state$[rbp+48]
sub rcx, rax
mov rax, rcx
sar rax, 1
mov ecx, DWORD PTR width$[rbp]
sub ecx, eax
mov eax, ecx
mov DWORD PTR count$5[rbp], eax
$LN6@PrintDecim:
; 293 : while (count > 0)
cmp DWORD PTR count$5[rbp], 0
jle SHORT $LN7@PrintDecim
; 294 : {
; 295 : OutputOneChar(&state, 0);
xor edx, edx
lea rcx, QWORD PTR state$[rbp]
call OutputOneChar
; 296 : --count;
mov eax, DWORD PTR count$5[rbp]
dec eax
mov DWORD PTR count$5[rbp], eax
; 297 : }
jmp SHORT $LN6@PrintDecim
$LN7@PrintDecim:
$LN10@PrintDecim:
$LN9@PrintDecim:
; 298 : }
; 299 : }
; 300 : *out_buf_count = state.OUT_PTR - out_buf;
mov rax, QWORD PTR out_buf$[rbp]
mov rcx, QWORD PTR state$[rbp+48]
sub rcx, rax
mov rax, rcx
sar rax, 1
mov rcx, QWORD PTR out_buf_count$[rbp]
mov QWORD PTR [rcx], rax
; 301 : *state.OUT_PTR = '\0';
xor eax, eax
mov rcx, QWORD PTR state$[rbp+48]
mov WORD PTR [rcx], ax
; 302 : }
lea rcx, QWORD PTR [rbp-32]
lea rdx, OFFSET FLAT:PrintDecimal$rtcFrameData
call _RTC_CheckStackVars
mov rcx, QWORD PTR __$ArrayPad$[rbp]
xor rcx, rbp
call __security_check_cookie
lea rsp, QWORD PTR [rbp+408]
pop rdi
pop rbp
ret 0
PrintDecimal ENDP
_TEXT ENDS
; Function compile flags: /Odtp /RTCsu /ZI
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_tostring.c
; COMDAT ToStringDN_1WORD
_TEXT SEGMENT
r$ = 4
state$ = 256
x$ = 264
ToStringDN_1WORD PROC ; COMDAT
; 204 : {
mov DWORD PTR [rsp+16], edx
mov QWORD PTR [rsp+8], rcx
push rbp
push rdi
sub rsp, 264 ; 00000108H
lea rbp, QWORD PTR [rsp+32]
mov rdi, rsp
mov ecx, 66 ; 00000042H
mov eax, -858993460 ; ccccccccH
rep stosd
mov rcx, QWORD PTR [rsp+296]
lea rcx, OFFSET FLAT:__3AA1CF5E_pmc_tostring@c
call __CheckForDebuggerJustMyCode
; 205 : __UNIT_TYPE_DIV r;
; 206 : if (sizeof(__UNIT_TYPE_DIV) >= sizeof(_UINT64_T))
xor eax, eax
test eax, eax
je $LN2@ToStringDN
; 207 : {
; 208 : x = _DIVREM_UNIT(0, x, 10, &r); OutputOneChar(state, r);
lea r9, QWORD PTR r$[rbp]
mov r8d, 10
mov edx, DWORD PTR x$[rbp]
xor ecx, ecx
call _DIVREM_UNIT
mov DWORD PTR x$[rbp], eax
mov edx, DWORD PTR r$[rbp]
mov rcx, QWORD PTR state$[rbp]
call OutputOneChar
; 209 : x = _DIVREM_UNIT(0, x, 10, &r); OutputOneChar(state, r);
lea r9, QWORD PTR r$[rbp]
mov r8d, 10
mov edx, DWORD PTR x$[rbp]
xor ecx, ecx
call _DIVREM_UNIT
mov DWORD PTR x$[rbp], eax
mov edx, DWORD PTR r$[rbp]
mov rcx, QWORD PTR state$[rbp]
call OutputOneChar
; 210 : x = _DIVREM_UNIT(0, x, 10, &r); OutputOneChar(state, r);
lea r9, QWORD PTR r$[rbp]
mov r8d, 10
mov edx, DWORD PTR x$[rbp]
xor ecx, ecx
call _DIVREM_UNIT
mov DWORD PTR x$[rbp], eax
mov edx, DWORD PTR r$[rbp]
mov rcx, QWORD PTR state$[rbp]
call OutputOneChar
; 211 : x = _DIVREM_UNIT(0, x, 10, &r); OutputOneChar(state, r);
lea r9, QWORD PTR r$[rbp]
mov r8d, 10
mov edx, DWORD PTR x$[rbp]
xor ecx, ecx
call _DIVREM_UNIT
mov DWORD PTR x$[rbp], eax
mov edx, DWORD PTR r$[rbp]
mov rcx, QWORD PTR state$[rbp]
call OutputOneChar
; 212 : x = _DIVREM_UNIT(0, x, 10, &r); OutputOneChar(state, r);
lea r9, QWORD PTR r$[rbp]
mov r8d, 10
mov edx, DWORD PTR x$[rbp]
xor ecx, ecx
call _DIVREM_UNIT
mov DWORD PTR x$[rbp], eax
mov edx, DWORD PTR r$[rbp]
mov rcx, QWORD PTR state$[rbp]
call OutputOneChar
; 213 : x = _DIVREM_UNIT(0, x, 10, &r); OutputOneChar(state, r);
lea r9, QWORD PTR r$[rbp]
mov r8d, 10
mov edx, DWORD PTR x$[rbp]
xor ecx, ecx
call _DIVREM_UNIT
mov DWORD PTR x$[rbp], eax
mov edx, DWORD PTR r$[rbp]
mov rcx, QWORD PTR state$[rbp]
call OutputOneChar
; 214 : x = _DIVREM_UNIT(0, x, 10, &r); OutputOneChar(state, r);
lea r9, QWORD PTR r$[rbp]
mov r8d, 10
mov edx, DWORD PTR x$[rbp]
xor ecx, ecx
call _DIVREM_UNIT
mov DWORD PTR x$[rbp], eax
mov edx, DWORD PTR r$[rbp]
mov rcx, QWORD PTR state$[rbp]
call OutputOneChar
; 215 : x = _DIVREM_UNIT(0, x, 10, &r); OutputOneChar(state, r);
lea r9, QWORD PTR r$[rbp]
mov r8d, 10
mov edx, DWORD PTR x$[rbp]
xor ecx, ecx
call _DIVREM_UNIT
mov DWORD PTR x$[rbp], eax
mov edx, DWORD PTR r$[rbp]
mov rcx, QWORD PTR state$[rbp]
call OutputOneChar
; 216 : x = _DIVREM_UNIT(0, x, 10, &r); OutputOneChar(state, r);
lea r9, QWORD PTR r$[rbp]
mov r8d, 10
mov edx, DWORD PTR x$[rbp]
xor ecx, ecx
call _DIVREM_UNIT
mov DWORD PTR x$[rbp], eax
mov edx, DWORD PTR r$[rbp]
mov rcx, QWORD PTR state$[rbp]
call OutputOneChar
; 217 : x = _DIVREM_UNIT(0, x, 10, &r); OutputOneChar(state, r);
lea r9, QWORD PTR r$[rbp]
mov r8d, 10
mov edx, DWORD PTR x$[rbp]
xor ecx, ecx
call _DIVREM_UNIT
mov DWORD PTR x$[rbp], eax
mov edx, DWORD PTR r$[rbp]
mov rcx, QWORD PTR state$[rbp]
call OutputOneChar
; 218 : #ifdef ENABLED_PERFORMANCE_COUNTER
; 219 : if (sizeof(r) == sizeof(_UINT64_T))
xor eax, eax
test eax, eax
je SHORT $LN3@ToStringDN
; 220 : AddToDIV64Counter(10);
mov ecx, 10
call AddToDIV64Counter
jmp SHORT $LN4@ToStringDN
$LN3@ToStringDN:
; 221 : else
; 222 : AddToDIV32Counter(10);
mov ecx, 10
call AddToDIV32Counter
$LN4@ToStringDN:
$LN2@ToStringDN:
; 223 : #endif
; 224 : }
; 225 : if (sizeof(__UNIT_TYPE_DIV) >= sizeof(_UINT32_T))
xor eax, eax
cmp eax, 1
je $LN5@ToStringDN
; 226 : {
; 227 : x = _DIVREM_UNIT(0, x, 10, &r); OutputOneChar(state, r);
lea r9, QWORD PTR r$[rbp]
mov r8d, 10
mov edx, DWORD PTR x$[rbp]
xor ecx, ecx
call _DIVREM_UNIT
mov DWORD PTR x$[rbp], eax
mov edx, DWORD PTR r$[rbp]
mov rcx, QWORD PTR state$[rbp]
call OutputOneChar
; 228 : x = _DIVREM_UNIT(0, x, 10, &r); OutputOneChar(state, r);
lea r9, QWORD PTR r$[rbp]
mov r8d, 10
mov edx, DWORD PTR x$[rbp]
xor ecx, ecx
call _DIVREM_UNIT
mov DWORD PTR x$[rbp], eax
mov edx, DWORD PTR r$[rbp]
mov rcx, QWORD PTR state$[rbp]
call OutputOneChar
; 229 : x = _DIVREM_UNIT(0, x, 10, &r); OutputOneChar(state, r);
lea r9, QWORD PTR r$[rbp]
mov r8d, 10
mov edx, DWORD PTR x$[rbp]
xor ecx, ecx
call _DIVREM_UNIT
mov DWORD PTR x$[rbp], eax
mov edx, DWORD PTR r$[rbp]
mov rcx, QWORD PTR state$[rbp]
call OutputOneChar
; 230 : x = _DIVREM_UNIT(0, x, 10, &r); OutputOneChar(state, r);
lea r9, QWORD PTR r$[rbp]
mov r8d, 10
mov edx, DWORD PTR x$[rbp]
xor ecx, ecx
call _DIVREM_UNIT
mov DWORD PTR x$[rbp], eax
mov edx, DWORD PTR r$[rbp]
mov rcx, QWORD PTR state$[rbp]
call OutputOneChar
; 231 : x = _DIVREM_UNIT(0, x, 10, &r); OutputOneChar(state, r);
lea r9, QWORD PTR r$[rbp]
mov r8d, 10
mov edx, DWORD PTR x$[rbp]
xor ecx, ecx
call _DIVREM_UNIT
mov DWORD PTR x$[rbp], eax
mov edx, DWORD PTR r$[rbp]
mov rcx, QWORD PTR state$[rbp]
call OutputOneChar
; 232 : #ifdef ENABLED_PERFORMANCE_COUNTER
; 233 : if (sizeof(r) == sizeof(_UINT64_T))
xor eax, eax
test eax, eax
je SHORT $LN6@ToStringDN
; 234 : AddToDIV64Counter(5);
mov ecx, 5
call AddToDIV64Counter
jmp SHORT $LN7@ToStringDN
$LN6@ToStringDN:
; 235 : else
; 236 : AddToDIV32Counter(5);
mov ecx, 5
call AddToDIV32Counter
$LN7@ToStringDN:
$LN5@ToStringDN:
; 237 : #endif
; 238 : }
; 239 : if (sizeof(__UNIT_TYPE_DIV) >= sizeof(_UINT16_T))
xor eax, eax
cmp eax, 1
je SHORT $LN8@ToStringDN
; 240 : {
; 241 : x = _DIVREM_UNIT(0, x, 10, &r); OutputOneChar(state, r);
lea r9, QWORD PTR r$[rbp]
mov r8d, 10
mov edx, DWORD PTR x$[rbp]
xor ecx, ecx
call _DIVREM_UNIT
mov DWORD PTR x$[rbp], eax
mov edx, DWORD PTR r$[rbp]
mov rcx, QWORD PTR state$[rbp]
call OutputOneChar
; 242 : x = _DIVREM_UNIT(0, x, 10, &r); OutputOneChar(state, r);
lea r9, QWORD PTR r$[rbp]
mov r8d, 10
mov edx, DWORD PTR x$[rbp]
xor ecx, ecx
call _DIVREM_UNIT
mov DWORD PTR x$[rbp], eax
mov edx, DWORD PTR r$[rbp]
mov rcx, QWORD PTR state$[rbp]
call OutputOneChar
; 243 : #ifdef ENABLED_PERFORMANCE_COUNTER
; 244 : if (sizeof(r) == sizeof(_UINT64_T))
xor eax, eax
test eax, eax
je SHORT $LN9@ToStringDN
; 245 : AddToDIV64Counter(2);
mov ecx, 2
call AddToDIV64Counter
jmp SHORT $LN10@ToStringDN
$LN9@ToStringDN:
; 246 : else
; 247 : AddToDIV32Counter(2);
mov ecx, 2
call AddToDIV32Counter
$LN10@ToStringDN:
$LN8@ToStringDN:
; 248 : #endif
; 249 : }
; 250 : if (sizeof(__UNIT_TYPE_DIV) >= sizeof(_BYTE_T))
xor eax, eax
cmp eax, 1
je SHORT $LN11@ToStringDN
; 251 : {
; 252 : x = _DIVREM_UNIT(0, x, 10, &r); OutputOneChar(state, r);
lea r9, QWORD PTR r$[rbp]
mov r8d, 10
mov edx, DWORD PTR x$[rbp]
xor ecx, ecx
call _DIVREM_UNIT
mov DWORD PTR x$[rbp], eax
mov edx, DWORD PTR r$[rbp]
mov rcx, QWORD PTR state$[rbp]
call OutputOneChar
; 253 : OutputOneChar(state, x);
mov edx, DWORD PTR x$[rbp]
mov rcx, QWORD PTR state$[rbp]
call OutputOneChar
; 254 : #ifdef ENABLED_PERFORMANCE_COUNTER
; 255 : if (sizeof(r) == sizeof(_UINT64_T))
xor eax, eax
test eax, eax
je SHORT $LN12@ToStringDN
; 256 : IncrementDIV64Counter();
call IncrementDIV64Counter
jmp SHORT $LN13@ToStringDN
$LN12@ToStringDN:
; 257 : else
; 258 : IncrementDIV32Counter();
call IncrementDIV32Counter
$LN13@ToStringDN:
$LN11@ToStringDN:
; 259 : #endif
; 260 : }
; 261 : }
lea rcx, QWORD PTR [rbp-32]
lea rdx, OFFSET FLAT:ToStringDN_1WORD$rtcFrameData
call _RTC_CheckStackVars
lea rsp, QWORD PTR [rbp+232]
pop rdi
pop rbp
ret 0
ToStringDN_1WORD ENDP
_TEXT ENDS
; Function compile flags: /Odtp /RTCsu /ZI
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_tostring.c
; COMDAT ToStringDN_LEADING_1WORD
_TEXT SEGMENT
r$ = 4
state$ = 256
x$ = 264
ToStringDN_LEADING_1WORD PROC ; COMDAT
; 187 : {
mov DWORD PTR [rsp+16], edx
mov QWORD PTR [rsp+8], rcx
push rbp
push rdi
sub rsp, 264 ; 00000108H
lea rbp, QWORD PTR [rsp+32]
mov rdi, rsp
mov ecx, 66 ; 00000042H
mov eax, -858993460 ; ccccccccH
rep stosd
mov rcx, QWORD PTR [rsp+296]
lea rcx, OFFSET FLAT:__3AA1CF5E_pmc_tostring@c
call __CheckForDebuggerJustMyCode
$LN4@ToStringDN:
; 188 : __UNIT_TYPE_DIV r;
; 189 : do
; 190 : {
; 191 : x = _DIVREM_UNIT(0, x, 10, &r);
lea r9, QWORD PTR r$[rbp]
mov r8d, 10
mov edx, DWORD PTR x$[rbp]
xor ecx, ecx
call _DIVREM_UNIT
mov DWORD PTR x$[rbp], eax
; 192 : OutputOneChar(state, r);
mov edx, DWORD PTR r$[rbp]
mov rcx, QWORD PTR state$[rbp]
call OutputOneChar
; 193 : #ifdef ENABLED_PERFORMANCE_COUNTER
; 194 : if (sizeof(r) == sizeof(_UINT64_T))
xor eax, eax
test eax, eax
je SHORT $LN5@ToStringDN
; 195 : IncrementDIV64Counter();
call IncrementDIV64Counter
jmp SHORT $LN6@ToStringDN
$LN5@ToStringDN:
; 196 : else
; 197 : IncrementDIV32Counter();
call IncrementDIV32Counter
$LN6@ToStringDN:
; 198 : #endif
; 199 : } while (x != 0);
cmp DWORD PTR x$[rbp], 0
jne SHORT $LN4@ToStringDN
; 200 : }
lea rcx, QWORD PTR [rbp-32]
lea rdx, OFFSET FLAT:ToStringDN_LEADING_1WORD$rtcFrameData
call _RTC_CheckStackVars
lea rsp, QWORD PTR [rbp+232]
pop rdi
pop rbp
ret 0
ToStringDN_LEADING_1WORD ENDP
_TEXT ENDS
; Function compile flags: /Odtp /RTCsu /ZI
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_tostring.c
; COMDAT OutputOneChar
_TEXT SEGMENT
state$ = 224
x$ = 232
OutputOneChar PROC ; COMDAT
; 146 : {
mov DWORD PTR [rsp+16], edx
mov QWORD PTR [rsp+8], rcx
push rbp
push rdi
sub rsp, 232 ; 000000e8H
lea rbp, QWORD PTR [rsp+32]
mov rdi, rsp
mov ecx, 58 ; 0000003aH
mov eax, -858993460 ; ccccccccH
rep stosd
mov rcx, QWORD PTR [rsp+264]
lea rcx, OFFSET FLAT:__3AA1CF5E_pmc_tostring@c
call __CheckForDebuggerJustMyCode
; 147 : if (state->FORMAT == 'N')
mov rax, QWORD PTR state$[rbp]
movsx eax, BYTE PTR [rax]
cmp eax, 78 ; 0000004eH
jne $LN2@OutputOneC
; 148 : {
; 149 : // 書式が N である場合
; 150 : if (state->CURRENT_GROUP_SIZE > 0 && state->CURRENT_GROUP_INDEX >= state->CURRENT_GROUP_SIZE)
mov rax, QWORD PTR state$[rbp]
cmp DWORD PTR [rax+40], 0
jle $LN4@OutputOneC
mov rax, QWORD PTR state$[rbp]
mov rcx, QWORD PTR state$[rbp]
mov ecx, DWORD PTR [rcx+40]
cmp DWORD PTR [rax+44], ecx
jl $LN4@OutputOneC
; 151 : {
; 152 : // 現在のグループ幅が 0 ではなく、かつ既に出力した文字数がグループ幅に達した場合
; 153 :
; 154 : // グループ区切り文字を出力してから与えられた文字を出力する
; 155 : lstrcpyW(state->OUT_PTR, state->GROUP_SEPARATOR);
mov rax, QWORD PTR state$[rbp]
add rax, 2
mov rdx, rax
mov rax, QWORD PTR state$[rbp]
mov rcx, QWORD PTR [rax+48]
call QWORD PTR __imp_lstrcpyW
; 156 : state->OUT_PTR += state->GROUP_SEPARATOR_LENGTH;
mov rax, QWORD PTR state$[rbp]
movsxd rax, DWORD PTR [rax+24]
mov rcx, QWORD PTR state$[rbp]
mov rcx, QWORD PTR [rcx+48]
lea rax, QWORD PTR [rcx+rax*2]
mov rcx, QWORD PTR state$[rbp]
mov QWORD PTR [rcx+48], rax
; 157 : *state->OUT_PTR = decimal_digits[x];
mov eax, DWORD PTR x$[rbp]
lea rcx, OFFSET FLAT:decimal_digits
mov rdx, QWORD PTR state$[rbp]
mov rdx, QWORD PTR [rdx+48]
movzx eax, WORD PTR [rcx+rax*2]
mov WORD PTR [rdx], ax
; 158 : state->OUT_PTR += 1;
mov rax, QWORD PTR state$[rbp]
mov rax, QWORD PTR [rax+48]
add rax, 2
mov rcx, QWORD PTR state$[rbp]
mov QWORD PTR [rcx+48], rax
; 159 : state->CURRENT_GROUP_INDEX = 1;
mov rax, QWORD PTR state$[rbp]
mov DWORD PTR [rax+44], 1
; 160 :
; 161 : // 次のグループが存在すればそのグループに移行する
; 162 : if (state->CURRENT_GROUP[1] != '\0')
mov eax, 1
imul rax, rax, 1
mov rcx, QWORD PTR state$[rbp]
mov rcx, QWORD PTR [rcx+32]
movsx eax, BYTE PTR [rcx+rax]
test eax, eax
je SHORT $LN6@OutputOneC
; 163 : {
; 164 : state->CURRENT_GROUP += 1;
mov rax, QWORD PTR state$[rbp]
mov rax, QWORD PTR [rax+32]
inc rax
mov rcx, QWORD PTR state$[rbp]
mov QWORD PTR [rcx+32], rax
; 165 : state->CURRENT_GROUP_SIZE = *state->CURRENT_GROUP - '0';
mov rax, QWORD PTR state$[rbp]
mov rax, QWORD PTR [rax+32]
movsx eax, BYTE PTR [rax]
sub eax, 48 ; 00000030H
mov rcx, QWORD PTR state$[rbp]
mov DWORD PTR [rcx+40], eax
$LN6@OutputOneC:
; 166 : }
; 167 : }
jmp SHORT $LN5@OutputOneC
$LN4@OutputOneC:
; 168 : else
; 169 : {
; 170 : // 現在のグループの幅が 0 であるかあるいは出力した文字数がグループ幅に達していない場合
; 171 : *state->OUT_PTR = decimal_digits[x];
mov eax, DWORD PTR x$[rbp]
lea rcx, OFFSET FLAT:decimal_digits
mov rdx, QWORD PTR state$[rbp]
mov rdx, QWORD PTR [rdx+48]
movzx eax, WORD PTR [rcx+rax*2]
mov WORD PTR [rdx], ax
; 172 : state->OUT_PTR += 1;
mov rax, QWORD PTR state$[rbp]
mov rax, QWORD PTR [rax+48]
add rax, 2
mov rcx, QWORD PTR state$[rbp]
mov QWORD PTR [rcx+48], rax
; 173 : state->CURRENT_GROUP_INDEX += 1;
mov rax, QWORD PTR state$[rbp]
mov eax, DWORD PTR [rax+44]
inc eax
mov rcx, QWORD PTR state$[rbp]
mov DWORD PTR [rcx+44], eax
$LN5@OutputOneC:
; 174 : }
; 175 : }
jmp SHORT $LN3@OutputOneC
$LN2@OutputOneC:
; 176 : else
; 177 : {
; 178 : // 書式が N ではない (つまり D である) 場合
; 179 :
; 180 : *state->OUT_PTR = decimal_digits[x];
mov eax, DWORD PTR x$[rbp]
lea rcx, OFFSET FLAT:decimal_digits
mov rdx, QWORD PTR state$[rbp]
mov rdx, QWORD PTR [rdx+48]
movzx eax, WORD PTR [rcx+rax*2]
mov WORD PTR [rdx], ax
; 181 : state->OUT_PTR += 1;
mov rax, QWORD PTR state$[rbp]
mov rax, QWORD PTR [rax+48]
add rax, 2
mov rcx, QWORD PTR state$[rbp]
mov QWORD PTR [rcx+48], rax
$LN3@OutputOneC:
; 182 : }
; 183 : }
lea rsp, QWORD PTR [rbp+200]
pop rdi
pop rbp
ret 0
OutputOneChar ENDP
_TEXT ENDS
; Function compile flags: /Odtp /RTCsu /ZI
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_tostring.c
; COMDAT OutputUngroupedOneChar
_TEXT SEGMENT
state$ = 224
x$ = 232
OutputUngroupedOneChar PROC ; COMDAT
; 140 : {
mov DWORD PTR [rsp+16], edx
mov QWORD PTR [rsp+8], rcx
push rbp
push rdi
sub rsp, 232 ; 000000e8H
lea rbp, QWORD PTR [rsp+32]
mov rdi, rsp
mov ecx, 58 ; 0000003aH
mov eax, -858993460 ; ccccccccH
rep stosd
mov rcx, QWORD PTR [rsp+264]
lea rcx, OFFSET FLAT:__3AA1CF5E_pmc_tostring@c
call __CheckForDebuggerJustMyCode
; 141 : *state->OUT_PTR = decimal_digits[x];
mov eax, DWORD PTR x$[rbp]
lea rcx, OFFSET FLAT:decimal_digits
mov rdx, QWORD PTR state$[rbp]
mov rdx, QWORD PTR [rdx+48]
movzx eax, WORD PTR [rcx+rax*2]
mov WORD PTR [rdx], ax
; 142 : state->OUT_PTR += 1;
mov rax, QWORD PTR state$[rbp]
mov rax, QWORD PTR [rax+48]
add rax, 2
mov rcx, QWORD PTR state$[rbp]
mov QWORD PTR [rcx+48], rax
; 143 : }
lea rsp, QWORD PTR [rbp+200]
pop rdi
pop rbp
ret 0
OutputUngroupedOneChar ENDP
_TEXT ENDS
; Function compile flags: /Odtp /RTCsu /ZI
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_tostring.c
; COMDAT OutputDecimalSeparator
_TEXT SEGMENT
state$ = 224
OutputDecimalSeparator PROC ; COMDAT
; 134 : {
mov QWORD PTR [rsp+8], rcx
push rbp
push rdi
sub rsp, 232 ; 000000e8H
lea rbp, QWORD PTR [rsp+32]
mov rdi, rsp
mov ecx, 58 ; 0000003aH
mov eax, -858993460 ; ccccccccH
rep stosd
mov rcx, QWORD PTR [rsp+264]
lea rcx, OFFSET FLAT:__3AA1CF5E_pmc_tostring@c
call __CheckForDebuggerJustMyCode
; 135 : lstrcpyW(state->OUT_PTR, state->DECIMAL_SEPARATOR);
mov rax, QWORD PTR state$[rbp]
add rax, 12
mov rdx, rax
mov rax, QWORD PTR state$[rbp]
mov rcx, QWORD PTR [rax+48]
call QWORD PTR __imp_lstrcpyW
; 136 : state->OUT_PTR += state->DECIMAL_SEPARATOR_LENGTH;
mov rax, QWORD PTR state$[rbp]
movsxd rax, DWORD PTR [rax+28]
mov rcx, QWORD PTR state$[rbp]
mov rcx, QWORD PTR [rcx+48]
lea rax, QWORD PTR [rcx+rax*2]
mov rcx, QWORD PTR state$[rbp]
mov QWORD PTR [rcx+48], rax
; 137 : }
lea rsp, QWORD PTR [rbp+200]
pop rdi
pop rbp
ret 0
OutputDecimalSeparator ENDP
_TEXT ENDS
; Function compile flags: /Odtp /RTCsu /ZI
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_tostring.c
; COMDAT InitializeOutputState
_TEXT SEGMENT
in_ptr$ = 8
out_ptr$ = 40
state$ = 288
out_buf$ = 296
format$ = 304
format_option$ = 312
InitializeOutputState PROC ; COMDAT
; 102 : {
mov QWORD PTR [rsp+32], r9
mov BYTE PTR [rsp+24], r8b
mov QWORD PTR [rsp+16], rdx
mov QWORD PTR [rsp+8], rcx
push rbp
push rdi
sub rsp, 296 ; 00000128H
lea rbp, QWORD PTR [rsp+32]
mov rdi, rsp
mov ecx, 74 ; 0000004aH
mov eax, -858993460 ; ccccccccH
rep stosd
mov rcx, QWORD PTR [rsp+328]
lea rcx, OFFSET FLAT:__3AA1CF5E_pmc_tostring@c
call __CheckForDebuggerJustMyCode
; 103 : state->FORMAT = format;
mov rax, QWORD PTR state$[rbp]
movzx ecx, BYTE PTR format$[rbp]
mov BYTE PTR [rax], cl
; 104 :
; 105 : state->GROUP_SEPARATOR_LENGTH = lstrlenW(format_option->GroupSeparator);
mov rax, QWORD PTR format_option$[rbp]
add rax, 4
mov rcx, rax
call QWORD PTR __imp_lstrlenW
mov rcx, QWORD PTR state$[rbp]
mov DWORD PTR [rcx+24], eax
; 106 : wchar_t* in_ptr = format_option->GroupSeparator;
mov rax, QWORD PTR format_option$[rbp]
add rax, 4
mov QWORD PTR in_ptr$[rbp], rax
; 107 : wchar_t* out_ptr = state->GROUP_SEPARATOR + state->GROUP_SEPARATOR_LENGTH;
mov rax, QWORD PTR state$[rbp]
movsxd rax, DWORD PTR [rax+24]
mov rcx, QWORD PTR state$[rbp]
lea rax, QWORD PTR [rcx+rax*2+2]
mov QWORD PTR out_ptr$[rbp], rax
; 108 : *out_ptr-- = '\0';
xor eax, eax
mov rcx, QWORD PTR out_ptr$[rbp]
mov WORD PTR [rcx], ax
mov rax, QWORD PTR out_ptr$[rbp]
sub rax, 2
mov QWORD PTR out_ptr$[rbp], rax
$LN2@Initialize:
; 109 : while (*in_ptr != L'\0')
mov rax, QWORD PTR in_ptr$[rbp]
movzx eax, WORD PTR [rax]
test eax, eax
je SHORT $LN3@Initialize
; 110 : {
; 111 : *out_ptr = *in_ptr;
mov rax, QWORD PTR out_ptr$[rbp]
mov rcx, QWORD PTR in_ptr$[rbp]
movzx ecx, WORD PTR [rcx]
mov WORD PTR [rax], cx
; 112 : --out_ptr;
mov rax, QWORD PTR out_ptr$[rbp]
sub rax, 2
mov QWORD PTR out_ptr$[rbp], rax
; 113 : ++in_ptr;
mov rax, QWORD PTR in_ptr$[rbp]
add rax, 2
mov QWORD PTR in_ptr$[rbp], rax
; 114 : }
jmp SHORT $LN2@Initialize
$LN3@Initialize:
; 115 :
; 116 : state->DECIMAL_SEPARATOR_LENGTH = lstrlenW(format_option->DecimalSeparator);
mov rax, QWORD PTR format_option$[rbp]
add rax, 10
mov rcx, rax
call QWORD PTR __imp_lstrlenW
mov rcx, QWORD PTR state$[rbp]
mov DWORD PTR [rcx+28], eax
; 117 : in_ptr = format_option->DecimalSeparator;
mov rax, QWORD PTR format_option$[rbp]
add rax, 10
mov QWORD PTR in_ptr$[rbp], rax
; 118 : out_ptr = state->DECIMAL_SEPARATOR + state->DECIMAL_SEPARATOR_LENGTH;
mov rax, QWORD PTR state$[rbp]
movsxd rax, DWORD PTR [rax+28]
mov rcx, QWORD PTR state$[rbp]
lea rax, QWORD PTR [rcx+rax*2+12]
mov QWORD PTR out_ptr$[rbp], rax
; 119 : *out_ptr-- = '\0';
xor eax, eax
mov rcx, QWORD PTR out_ptr$[rbp]
mov WORD PTR [rcx], ax
mov rax, QWORD PTR out_ptr$[rbp]
sub rax, 2
mov QWORD PTR out_ptr$[rbp], rax
$LN4@Initialize:
; 120 : while (*in_ptr != L'\0')
mov rax, QWORD PTR in_ptr$[rbp]
movzx eax, WORD PTR [rax]
test eax, eax
je SHORT $LN5@Initialize
; 121 : {
; 122 : *out_ptr = *in_ptr;
mov rax, QWORD PTR out_ptr$[rbp]
mov rcx, QWORD PTR in_ptr$[rbp]
movzx ecx, WORD PTR [rcx]
mov WORD PTR [rax], cx
; 123 : --out_ptr;
mov rax, QWORD PTR out_ptr$[rbp]
sub rax, 2
mov QWORD PTR out_ptr$[rbp], rax
; 124 : ++in_ptr;
mov rax, QWORD PTR in_ptr$[rbp]
add rax, 2
mov QWORD PTR in_ptr$[rbp], rax
; 125 : }
jmp SHORT $LN4@Initialize
$LN5@Initialize:
; 126 :
; 127 : state->CURRENT_GROUP = &format_option->GroupSizes[0];
mov eax, 1
imul rax, rax, 0
mov rcx, QWORD PTR format_option$[rbp]
lea rax, QWORD PTR [rcx+rax+28]
mov rcx, QWORD PTR state$[rbp]
mov QWORD PTR [rcx+32], rax
; 128 : state->CURRENT_GROUP_SIZE = *state->CURRENT_GROUP - '0';
mov rax, QWORD PTR state$[rbp]
mov rax, QWORD PTR [rax+32]
movsx eax, BYTE PTR [rax]
sub eax, 48 ; 00000030H
mov rcx, QWORD PTR state$[rbp]
mov DWORD PTR [rcx+40], eax
; 129 : state->CURRENT_GROUP_INDEX = 0;
mov rax, QWORD PTR state$[rbp]
mov DWORD PTR [rax+44], 0
; 130 : state->OUT_PTR = out_buf;
mov rax, QWORD PTR state$[rbp]
mov rcx, QWORD PTR out_buf$[rbp]
mov QWORD PTR [rax+48], rcx
; 131 : }
lea rsp, QWORD PTR [rbp+264]
pop rdi
pop rbp
ret 0
InitializeOutputState ENDP
_TEXT ENDS
; Function compile flags: /Odtp /RTCsu /ZI
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_tostring.c
; COMDAT ConvertCardinalNumber
_TEXT SEGMENT
result$ = 4
work_buf_1_code$ = 40
work_buf_1_words$ = 72
work_buf_1$ = 104
work_buf_2_code$ = 136
work_buf_2_words$ = 168
work_buf_2$ = 200
u_ptr$ = 232
q_ptr$ = 264
r_ptr$ = 296
work_u_count$ = 328
r_value$8 = 356
temp$9 = 392
x_buf$ = 640
x_buf_size$ = 648
x_bit_count$ = 656
base_value$ = 664
r_buf$ = 672
r_buf_count$ = 680
ConvertCardinalNumber PROC ; COMDAT
; 59 : {
mov DWORD PTR [rsp+32], r9d
mov QWORD PTR [rsp+24], r8
mov QWORD PTR [rsp+16], rdx
mov QWORD PTR [rsp+8], rcx
push rbp
push rdi
sub rsp, 664 ; 00000298H
lea rbp, QWORD PTR [rsp+48]
mov rdi, rsp
mov ecx, 166 ; 000000a6H
mov eax, -858993460 ; ccccccccH
rep stosd
mov rcx, QWORD PTR [rsp+696]
lea rcx, OFFSET FLAT:__3AA1CF5E_pmc_tostring@c
call __CheckForDebuggerJustMyCode
; 60 : PMC_STATUS_CODE result;
; 61 : __UNIT_TYPE work_buf_1_code;
; 62 : __UNIT_TYPE work_buf_1_words;
; 63 : __UNIT_TYPE_DIV* work_buf_1 = (__UNIT_TYPE_DIV*)AllocateBlock(x_bit_count + __UNIT_TYPE_BIT_COUNT, &work_buf_1_words, &work_buf_1_code);
mov rax, QWORD PTR x_bit_count$[rbp]
add rax, 64 ; 00000040H
lea r8, QWORD PTR work_buf_1_code$[rbp]
lea rdx, QWORD PTR work_buf_1_words$[rbp]
mov rcx, rax
call AllocateBlock
mov QWORD PTR work_buf_1$[rbp], rax
; 64 : if (work_buf_1 == NULL)
cmp QWORD PTR work_buf_1$[rbp], 0
jne SHORT $LN6@ConvertCar
; 65 : return (PMC_STATUS_NOT_ENOUGH_MEMORY);
mov eax, -5
jmp $LN1@ConvertCar
$LN6@ConvertCar:
; 66 : __UNIT_TYPE work_buf_2_code;
; 67 : __UNIT_TYPE work_buf_2_words;
; 68 : __UNIT_TYPE_DIV* work_buf_2 = (__UNIT_TYPE_DIV*)AllocateBlock(x_bit_count + __UNIT_TYPE_BIT_COUNT, &work_buf_2_words, &work_buf_2_code);
mov rax, QWORD PTR x_bit_count$[rbp]
add rax, 64 ; 00000040H
lea r8, QWORD PTR work_buf_2_code$[rbp]
lea rdx, QWORD PTR work_buf_2_words$[rbp]
mov rcx, rax
call AllocateBlock
mov QWORD PTR work_buf_2$[rbp], rax
; 69 : if (work_buf_2 == NULL)
cmp QWORD PTR work_buf_2$[rbp], 0
jne SHORT $LN7@ConvertCar
; 70 : {
; 71 : DeallocateBlock((__UNIT_TYPE*)work_buf_1, work_buf_1_words);
mov rdx, QWORD PTR work_buf_1_words$[rbp]
mov rcx, QWORD PTR work_buf_1$[rbp]
call DeallocateBlock
; 72 : return (PMC_STATUS_NOT_ENOUGH_MEMORY);
mov eax, -5
jmp $LN1@ConvertCar
$LN7@ConvertCar:
; 73 : }
; 74 : __UNIT_TYPE_DIV* u_ptr = work_buf_1;
mov rax, QWORD PTR work_buf_1$[rbp]
mov QWORD PTR u_ptr$[rbp], rax
; 75 : __UNIT_TYPE_DIV* q_ptr = work_buf_2;
mov rax, QWORD PTR work_buf_2$[rbp]
mov QWORD PTR q_ptr$[rbp], rax
; 76 : _COPY_MEMORY_UNIT_DIV(u_ptr, x_buf, x_buf_size);
mov r8, QWORD PTR x_buf_size$[rbp]
mov rdx, QWORD PTR x_buf$[rbp]
mov rcx, QWORD PTR u_ptr$[rbp]
call _COPY_MEMORY_UNIT_DIV
; 77 : __UNIT_TYPE_DIV* r_ptr = r_buf;
mov rax, QWORD PTR r_buf$[rbp]
mov QWORD PTR r_ptr$[rbp], rax
; 78 : __UNIT_TYPE work_u_count = work_buf_1_words * (sizeof(__UNIT_TYPE) / sizeof(__UNIT_TYPE_DIV));
mov rax, QWORD PTR work_buf_1_words$[rbp]
shl rax, 1
mov QWORD PTR work_u_count$[rbp], rax
$LN2@ConvertCar:
; 79 : while (work_u_count > 0)
cmp QWORD PTR work_u_count$[rbp], 0
jbe $LN3@ConvertCar
; 80 : {
; 81 : _ZERO_MEMORY_UNIT_DIV(q_ptr, work_u_count);
mov rdx, QWORD PTR work_u_count$[rbp]
mov rcx, QWORD PTR q_ptr$[rbp]
call _ZERO_MEMORY_UNIT_DIV
; 82 : __UNIT_TYPE_DIV r_value;
; 83 : DivRem_X_1W(u_ptr, work_u_count, base_value, q_ptr, &r_value);
lea rax, QWORD PTR r_value$8[rbp]
mov QWORD PTR [rsp+32], rax
mov r9, QWORD PTR q_ptr$[rbp]
mov r8d, DWORD PTR base_value$[rbp]
mov rdx, QWORD PTR work_u_count$[rbp]
mov rcx, QWORD PTR u_ptr$[rbp]
call DivRem_X_1W
; 84 : if ((result = CheckBlockLight((__UNIT_TYPE*)work_buf_2, work_buf_2_code)) != PMC_STATUS_OK)
mov rdx, QWORD PTR work_buf_2_code$[rbp]
mov rcx, QWORD PTR work_buf_2$[rbp]
call CheckBlockLight
mov DWORD PTR result$[rbp], eax
cmp DWORD PTR result$[rbp], 0
je SHORT $LN8@ConvertCar
; 85 : return (result);
mov eax, DWORD PTR result$[rbp]
jmp $LN1@ConvertCar
$LN8@ConvertCar:
; 86 : if ((result = CheckBlockLight((__UNIT_TYPE*)work_buf_1, work_buf_1_code)) != PMC_STATUS_OK)
mov rdx, QWORD PTR work_buf_1_code$[rbp]
mov rcx, QWORD PTR work_buf_1$[rbp]
call CheckBlockLight
mov DWORD PTR result$[rbp], eax
cmp DWORD PTR result$[rbp], 0
je SHORT $LN9@ConvertCar
; 87 : return (result);
mov eax, DWORD PTR result$[rbp]
jmp $LN1@ConvertCar
$LN9@ConvertCar:
; 88 : *r_ptr++ = r_value;
mov rax, QWORD PTR r_ptr$[rbp]
mov ecx, DWORD PTR r_value$8[rbp]
mov DWORD PTR [rax], ecx
mov rax, QWORD PTR r_ptr$[rbp]
add rax, 4
mov QWORD PTR r_ptr$[rbp], rax
; 89 : __UNIT_TYPE_DIV* temp = u_ptr;
mov rax, QWORD PTR u_ptr$[rbp]
mov QWORD PTR temp$9[rbp], rax
; 90 : u_ptr = q_ptr;
mov rax, QWORD PTR q_ptr$[rbp]
mov QWORD PTR u_ptr$[rbp], rax
; 91 : q_ptr = temp;
mov rax, QWORD PTR temp$9[rbp]
mov QWORD PTR q_ptr$[rbp], rax
$LN4@ConvertCar:
; 92 : while (work_u_count > 0 && u_ptr[work_u_count - 1] == 0)
cmp QWORD PTR work_u_count$[rbp], 0
jbe SHORT $LN5@ConvertCar
mov rax, QWORD PTR u_ptr$[rbp]
mov rcx, QWORD PTR work_u_count$[rbp]
cmp DWORD PTR [rax+rcx*4-4], 0
jne SHORT $LN5@ConvertCar
; 93 : --work_u_count;
mov rax, QWORD PTR work_u_count$[rbp]
dec rax
mov QWORD PTR work_u_count$[rbp], rax
jmp SHORT $LN4@ConvertCar
$LN5@ConvertCar:
; 94 : }
jmp $LN2@ConvertCar
$LN3@ConvertCar:
; 95 : *r_buf_count = r_ptr - r_buf;
mov rax, QWORD PTR r_buf$[rbp]
mov rcx, QWORD PTR r_ptr$[rbp]
sub rcx, rax
mov rax, rcx
sar rax, 2
mov rcx, QWORD PTR r_buf_count$[rbp]
mov QWORD PTR [rcx], rax
; 96 : DeallocateBlock((__UNIT_TYPE*)work_buf_2, work_buf_2_words);
mov rdx, QWORD PTR work_buf_2_words$[rbp]
mov rcx, QWORD PTR work_buf_2$[rbp]
call DeallocateBlock
; 97 : DeallocateBlock((__UNIT_TYPE*)work_buf_1, work_buf_1_words);
mov rdx, QWORD PTR work_buf_1_words$[rbp]
mov rcx, QWORD PTR work_buf_1$[rbp]
call DeallocateBlock
; 98 : return (PMC_STATUS_OK);
xor eax, eax
$LN1@ConvertCar:
; 99 : }
mov rdi, rax
lea rcx, QWORD PTR [rbp-48]
lea rdx, OFFSET FLAT:ConvertCardinalNumber$rtcFrameData
call _RTC_CheckStackVars
mov rax, rdi
lea rsp, QWORD PTR [rbp+616]
pop rdi
pop rbp
ret 0
ConvertCardinalNumber ENDP
_TEXT ENDS
; Function compile flags: /Odtp /RTCsu /ZI
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_inline_func.h
; COMDAT _ROTATE_L_UNIT
_TEXT SEGMENT
x$ = 224
count$ = 232
_ROTATE_L_UNIT PROC ; COMDAT
; 481 : {
mov DWORD PTR [rsp+16], edx
mov QWORD PTR [rsp+8], rcx
push rbp
push rdi
sub rsp, 232 ; 000000e8H
lea rbp, QWORD PTR [rsp+32]
mov rdi, rsp
mov ecx, 58 ; 0000003aH
mov eax, -858993460 ; ccccccccH
rep stosd
mov rcx, QWORD PTR [rsp+264]
lea rcx, OFFSET FLAT:__6B0481B0_pmc_inline_func@h
call __CheckForDebuggerJustMyCode
; 482 : #ifdef _M_IX86
; 483 : return (_rotl(x, count));
; 484 : #elif defined(_M_X64)
; 485 : return (_rotl64(x, count));
mov eax, DWORD PTR count$[rbp]
movzx ecx, al
mov rax, QWORD PTR x$[rbp]
rol rax, cl
; 486 : #else
; 487 : #error unknown platform
; 488 : #endif
; 489 : }
lea rsp, QWORD PTR [rbp+200]
pop rdi
pop rbp
ret 0
_ROTATE_L_UNIT ENDP
_TEXT ENDS
; Function compile flags: /Odtp /RTCsu /ZI
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_inline_func.h
; COMDAT _DIVREM_UNIT
_TEXT SEGMENT
t$1 = 8
tv71 = 216
tv68 = 216
u_high$ = 256
u_low$ = 264
v$ = 272
r$ = 280
_DIVREM_UNIT PROC ; COMDAT
; 384 : {
mov QWORD PTR [rsp+32], r9
mov DWORD PTR [rsp+24], r8d
mov DWORD PTR [rsp+16], edx
mov DWORD PTR [rsp+8], ecx
push rbp
push rdi
sub rsp, 264 ; 00000108H
lea rbp, QWORD PTR [rsp+32]
mov rdi, rsp
mov ecx, 66 ; 00000042H
mov eax, -858993460 ; ccccccccH
rep stosd
mov ecx, DWORD PTR [rsp+296]
lea rcx, OFFSET FLAT:__6B0481B0_pmc_inline_func@h
call __CheckForDebuggerJustMyCode
; 385 : #ifdef _MSC_VER
; 386 : if (sizeof(__UNIT_TYPE_DIV) == sizeof(_UINT32_T))
xor eax, eax
cmp eax, 1
je SHORT $LN2@DIVREM_UNI
; 387 : {
; 388 : // 64bit/32bitの除算を行う組み込み関数は実装されていない。
; 389 : _UINT64_T t = _FROMWORDTODWORD(u_high, u_low);
mov edx, DWORD PTR u_low$[rbp]
mov ecx, DWORD PTR u_high$[rbp]
call _FROMWORDTODWORD
mov QWORD PTR t$1[rbp], rax
; 390 : *r = (_UINT32_T)(t % v);
mov eax, DWORD PTR v$[rbp]
mov QWORD PTR tv68[rbp], rax
xor edx, edx
mov rax, QWORD PTR t$1[rbp]
mov rcx, QWORD PTR tv68[rbp]
div rcx
mov rax, rdx
mov rcx, QWORD PTR r$[rbp]
mov DWORD PTR [rcx], eax
; 391 : return ((_UINT32_T)(t / v));
mov eax, DWORD PTR v$[rbp]
mov QWORD PTR tv71[rbp], rax
xor edx, edx
mov rax, QWORD PTR t$1[rbp]
mov rcx, QWORD PTR tv71[rbp]
div rcx
jmp SHORT $LN1@DIVREM_UNI
; 392 : }
jmp SHORT $LN3@DIVREM_UNI
$LN2@DIVREM_UNI:
; 393 : else if (sizeof(__UNIT_TYPE_DIV) == sizeof(_UINT64_T))
xor eax, eax
test eax, eax
je SHORT $LN4@DIVREM_UNI
; 394 : {
; 395 : // 以下の理由のため、MSVCでは 128bit/64bit の除算を実装できない。運用で回避すること。
; 396 : // ・(x64 に限らず) 除算の組み込み関数が用意されていない。
; 397 : // ・128bit 整数のデータ型が用意されていない。
; 398 : // ・x64 ではインラインアセンブラがサポートされていない。
; 399 : *r = 0;
mov rax, QWORD PTR r$[rbp]
mov DWORD PTR [rax], 0
; 400 : return (0);
xor eax, eax
jmp SHORT $LN1@DIVREM_UNI
; 401 : }
jmp SHORT $LN5@DIVREM_UNI
$LN4@DIVREM_UNI:
; 402 : else
; 403 : {
; 404 : // 未知のプラットフォームの場合はとりあえず適当なものを返す。
; 405 : *r = 0;
mov rax, QWORD PTR r$[rbp]
mov DWORD PTR [rax], 0
; 406 : return (0);
xor eax, eax
$LN5@DIVREM_UNI:
$LN3@DIVREM_UNI:
$LN1@DIVREM_UNI:
; 407 : }
; 408 : #elif defined(__GNUC__)
; 409 : __UNIT_TYPE q;
; 410 : if (sizeof(__UNIT_TYPE_DIV) == sizeof(_UINT32_T))
; 411 : __asm__("divl %4": "=a"(q), "=d"(*r) : "0"(u_low), "1"(u_high), "rm"(v));
; 412 : else if (sizeof(__UNIT_TYPE_DIV) == sizeof(_UINT64_T))
; 413 : __asm__("divq %4": "=a"(q), "=d"(*r) : "0"(u_low), "1"(u_high), "rm"(v));
; 414 : else
; 415 : {
; 416 : // 未知のプラットフォームの場合はとりあえず適当なものを返す。
; 417 : *r = 0;
; 418 : q = 0;
; 419 : }
; 420 : return (q);
; 421 : #else
; 422 : #error unknown compiler
; 423 : #endif
; 424 : }
lea rsp, QWORD PTR [rbp+232]
pop rdi
pop rbp
ret 0
_DIVREM_UNIT ENDP
_TEXT ENDS
; Function compile flags: /Odtp /RTCsu /ZI
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_inline_func.h
; COMDAT _DIVIDE_CEILING_UNIT
_TEXT SEGMENT
u$ = 224
v$ = 232
_DIVIDE_CEILING_UNIT PROC ; COMDAT
; 193 : {
mov QWORD PTR [rsp+16], rdx
mov QWORD PTR [rsp+8], rcx
push rbp
push rdi
sub rsp, 232 ; 000000e8H
lea rbp, QWORD PTR [rsp+32]
mov rdi, rsp
mov ecx, 58 ; 0000003aH
mov eax, -858993460 ; ccccccccH
rep stosd
mov rcx, QWORD PTR [rsp+264]
lea rcx, OFFSET FLAT:__6B0481B0_pmc_inline_func@h
call __CheckForDebuggerJustMyCode
; 194 : return ((u + v - 1) / v);
mov rax, QWORD PTR u$[rbp]
mov rcx, QWORD PTR v$[rbp]
lea rax, QWORD PTR [rax+rcx-1]
xor edx, edx
div QWORD PTR v$[rbp]
; 195 : }
lea rsp, QWORD PTR [rbp+200]
pop rdi
pop rbp
ret 0
_DIVIDE_CEILING_UNIT ENDP
_TEXT ENDS
; Function compile flags: /Odtp /RTCsu /ZI
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_inline_func.h
; COMDAT _FROMWORDTODWORD
_TEXT SEGMENT
value_high$ = 224
value_low$ = 232
_FROMWORDTODWORD PROC ; COMDAT
; 177 : {
mov DWORD PTR [rsp+16], edx
mov DWORD PTR [rsp+8], ecx
push rbp
push rdi
sub rsp, 232 ; 000000e8H
lea rbp, QWORD PTR [rsp+32]
mov rdi, rsp
mov ecx, 58 ; 0000003aH
mov eax, -858993460 ; ccccccccH
rep stosd
mov ecx, DWORD PTR [rsp+264]
lea rcx, OFFSET FLAT:__6B0481B0_pmc_inline_func@h
call __CheckForDebuggerJustMyCode
; 178 : return (((_UINT64_T)value_high << 32) | value_low);
mov eax, DWORD PTR value_high$[rbp]
shl rax, 32 ; 00000020H
mov ecx, DWORD PTR value_low$[rbp]
or rax, rcx
; 179 : }
lea rsp, QWORD PTR [rbp+200]
pop rdi
pop rbp
ret 0
_FROMWORDTODWORD ENDP
_TEXT ENDS
; Function compile flags: /Odtp /RTCsu /ZI
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_inline_func.h
; COMDAT _FILL_MEMORY_16
_TEXT SEGMENT
d$ = 224
x$ = 232
count$ = 240
_FILL_MEMORY_16 PROC ; COMDAT
; 149 : {
mov QWORD PTR [rsp+24], r8
mov WORD PTR [rsp+16], dx
mov QWORD PTR [rsp+8], rcx
push rbp
push rdi
sub rsp, 232 ; 000000e8H
lea rbp, QWORD PTR [rsp+32]
mov rdi, rsp
mov ecx, 58 ; 0000003aH
mov eax, -858993460 ; ccccccccH
rep stosd
mov rcx, QWORD PTR [rsp+264]
lea rcx, OFFSET FLAT:__6B0481B0_pmc_inline_func@h
call __CheckForDebuggerJustMyCode
; 150 : __stosw(d, x, count);
mov rdi, QWORD PTR d$[rbp]
movzx eax, WORD PTR x$[rbp]
mov rcx, QWORD PTR count$[rbp]
rep stosw
; 151 : }
lea rsp, QWORD PTR [rbp+200]
pop rdi
pop rbp
ret 0
_FILL_MEMORY_16 ENDP
_TEXT ENDS
; Function compile flags: /Odtp /RTCsu /ZI
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_inline_func.h
; COMDAT _ZERO_MEMORY_UNIT_DIV
_TEXT SEGMENT
tv64 = 192
d$ = 240
count$ = 248
_ZERO_MEMORY_UNIT_DIV PROC ; COMDAT
; 127 : {
mov QWORD PTR [rsp+16], rdx
mov QWORD PTR [rsp+8], rcx
push rbp
push rdi
sub rsp, 248 ; 000000f8H
lea rbp, QWORD PTR [rsp+32]
mov rdi, rsp
mov ecx, 62 ; 0000003eH
mov eax, -858993460 ; ccccccccH
rep stosd
mov rcx, QWORD PTR [rsp+280]
lea rcx, OFFSET FLAT:__6B0481B0_pmc_inline_func@h
call __CheckForDebuggerJustMyCode
; 128 : #ifdef _M_IX86
; 129 : __stosd((unsigned long*)d, 0, (unsigned long)count);
; 130 : #elif defined(_M_X64)
; 131 : #ifdef _MSC_VER
; 132 : __stosd((unsigned long*)d, 0, (unsigned long)count);
mov eax, DWORD PTR count$[rbp]
mov QWORD PTR tv64[rbp], rax
mov rdi, QWORD PTR d$[rbp]
xor eax, eax
mov rcx, QWORD PTR tv64[rbp]
rep stosd
; 133 : #elif defined(__GNUC__)
; 134 : __stosq(d, 0, count);
; 135 : #else
; 136 : #error unknown compiler
; 137 : #endif
; 138 : #else
; 139 : #error unknown platform
; 140 : #endif
; 141 : }
lea rsp, QWORD PTR [rbp+216]
pop rdi
pop rbp
ret 0
_ZERO_MEMORY_UNIT_DIV ENDP
_TEXT ENDS
; Function compile flags: /Odtp /RTCsu /ZI
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_inline_func.h
; COMDAT _COPY_MEMORY_UNIT_DIV
_TEXT SEGMENT
d$ = 224
s$ = 232
count$ = 240
_COPY_MEMORY_UNIT_DIV PROC ; COMDAT
; 77 : {
mov QWORD PTR [rsp+24], r8
mov QWORD PTR [rsp+16], rdx
mov QWORD PTR [rsp+8], rcx
push rbp
push rsi
push rdi
sub rsp, 224 ; 000000e0H
lea rbp, QWORD PTR [rsp+32]
mov rdi, rsp
mov ecx, 56 ; 00000038H
mov eax, -858993460 ; ccccccccH
rep stosd
mov rcx, QWORD PTR [rsp+264]
lea rcx, OFFSET FLAT:__6B0481B0_pmc_inline_func@h
call __CheckForDebuggerJustMyCode
; 78 : #ifdef _M_IX86
; 79 : __movsd((unsigned long *)d, (unsigned long *)s, (unsigned long)count);
; 80 : #elif defined(_M_X64)
; 81 : #ifdef _MSC_VER
; 82 : __movsd((unsigned long *)d, (unsigned long *)s, (unsigned long)count);
mov eax, DWORD PTR count$[rbp]
mov rdi, QWORD PTR d$[rbp]
mov rsi, QWORD PTR s$[rbp]
mov ecx, eax
rep movsd
; 83 : #elif defined(__GNUC__)
; 84 : __movsq(d, s, count);
; 85 : #else
; 86 : #error unknown compiler
; 87 : #endif
; 88 : #else
; 89 : #error unknown platform
; 90 : #endif
; 91 : }
lea rsp, QWORD PTR [rbp+192]
pop rdi
pop rsi
pop rbp
ret 0
_COPY_MEMORY_UNIT_DIV ENDP
_TEXT ENDS
; Function compile flags: /Odtp /RTCsu /ZI
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_uint_internal.h
; COMDAT AddToDIV64Counter
_TEXT SEGMENT
value$ = 224
AddToDIV64Counter PROC ; COMDAT
; 345 : {
mov DWORD PTR [rsp+8], ecx
push rbp
push rdi
sub rsp, 232 ; 000000e8H
lea rbp, QWORD PTR [rsp+32]
mov rdi, rsp
mov ecx, 58 ; 0000003aH
mov eax, -858993460 ; ccccccccH
rep stosd
mov ecx, DWORD PTR [rsp+264]
lea rcx, OFFSET FLAT:__7B8DBFC3_pmc_uint_internal@h
call __CheckForDebuggerJustMyCode
; 346 : _InterlockedExchangeAdd(&statistics_info.COUNT_DIV64, value);
lea rax, OFFSET FLAT:statistics_info+8
mov ecx, DWORD PTR value$[rbp]
lock add DWORD PTR [rax], ecx
; 347 : }
lea rsp, QWORD PTR [rbp+200]
pop rdi
pop rbp
ret 0
AddToDIV64Counter ENDP
_TEXT ENDS
; Function compile flags: /Odtp /RTCsu /ZI
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_uint_internal.h
; COMDAT AddToDIV32Counter
_TEXT SEGMENT
value$ = 224
AddToDIV32Counter PROC ; COMDAT
; 339 : {
mov DWORD PTR [rsp+8], ecx
push rbp
push rdi
sub rsp, 232 ; 000000e8H
lea rbp, QWORD PTR [rsp+32]
mov rdi, rsp
mov ecx, 58 ; 0000003aH
mov eax, -858993460 ; ccccccccH
rep stosd
mov ecx, DWORD PTR [rsp+264]
lea rcx, OFFSET FLAT:__7B8DBFC3_pmc_uint_internal@h
call __CheckForDebuggerJustMyCode
; 340 : _InterlockedExchangeAdd(&statistics_info.COUNT_DIV32, value);
lea rax, OFFSET FLAT:statistics_info+12
mov ecx, DWORD PTR value$[rbp]
lock add DWORD PTR [rax], ecx
; 341 : }
lea rsp, QWORD PTR [rbp+200]
pop rdi
pop rbp
ret 0
AddToDIV32Counter ENDP
_TEXT ENDS
; Function compile flags: /Odtp /RTCsu /ZI
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_uint_internal.h
; COMDAT IncrementDIV64Counter
_TEXT SEGMENT
IncrementDIV64Counter PROC ; COMDAT
; 322 : {
push rbp
push rdi
sub rsp, 232 ; 000000e8H
lea rbp, QWORD PTR [rsp+32]
mov rdi, rsp
mov ecx, 58 ; 0000003aH
mov eax, -858993460 ; ccccccccH
rep stosd
lea rcx, OFFSET FLAT:__7B8DBFC3_pmc_uint_internal@h
call __CheckForDebuggerJustMyCode
; 323 : _InterlockedIncrement(&statistics_info.COUNT_DIV64);
lea rax, OFFSET FLAT:statistics_info+8
lock inc DWORD PTR [rax]
; 324 : }
lea rsp, QWORD PTR [rbp+200]
pop rdi
pop rbp
ret 0
IncrementDIV64Counter ENDP
_TEXT ENDS
; Function compile flags: /Odtp /RTCsu /ZI
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_uint_internal.h
; COMDAT IncrementDIV32Counter
_TEXT SEGMENT
IncrementDIV32Counter PROC ; COMDAT
; 316 : {
push rbp
push rdi
sub rsp, 232 ; 000000e8H
lea rbp, QWORD PTR [rsp+32]
mov rdi, rsp
mov ecx, 58 ; 0000003aH
mov eax, -858993460 ; ccccccccH
rep stosd
lea rcx, OFFSET FLAT:__7B8DBFC3_pmc_uint_internal@h
call __CheckForDebuggerJustMyCode
; 317 : _InterlockedIncrement(&statistics_info.COUNT_DIV32);
lea rax, OFFSET FLAT:statistics_info+12
lock inc DWORD PTR [rax]
; 318 : }
lea rsp, QWORD PTR [rbp+200]
pop rdi
pop rbp
ret 0
IncrementDIV32Counter ENDP
_TEXT ENDS
; Function compile flags: /Odtp /RTCsu /ZI
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_tostring.c
; COMDAT PMC_ToString
_TEXT SEGMENT
nx$ = 8
result$ = 36
tv135 = 244
tv95 = 244
tv86 = 244
tv76 = 244
tv71 = 244
x$ = 288
buffer$ = 296
buffer_size$ = 304
format$ = 312
width$ = 320
format_option$ = 328
PMC_ToString PROC ; COMDAT
; 533 : {
$LN24:
mov BYTE PTR [rsp+32], r9b
mov QWORD PTR [rsp+24], r8
mov QWORD PTR [rsp+16], rdx
mov QWORD PTR [rsp+8], rcx
push rbp
push rdi
sub rsp, 312 ; 00000138H
lea rbp, QWORD PTR [rsp+48]
mov rdi, rsp
mov ecx, 78 ; 0000004eH
mov eax, -858993460 ; ccccccccH
rep stosd
mov rcx, QWORD PTR [rsp+344]
lea rcx, OFFSET FLAT:__3AA1CF5E_pmc_tostring@c
call __CheckForDebuggerJustMyCode
; 534 : if (x == NULL)
cmp QWORD PTR x$[rbp], 0
jne SHORT $LN4@PMC_ToStri
; 535 : return (PMC_STATUS_ARGUMENT_ERROR);
mov eax, -1
jmp $LN1@PMC_ToStri
$LN4@PMC_ToStri:
; 536 : if (buffer == NULL)
cmp QWORD PTR buffer$[rbp], 0
jne SHORT $LN5@PMC_ToStri
; 537 : return (PMC_STATUS_ARGUMENT_ERROR);
mov eax, -1
jmp $LN1@PMC_ToStri
$LN5@PMC_ToStri:
; 538 : if (format_option == NULL)
cmp QWORD PTR format_option$[rbp], 0
jne SHORT $LN6@PMC_ToStri
; 539 : format_option = &default_number_format_option;
lea rax, OFFSET FLAT:default_number_format_option
mov QWORD PTR format_option$[rbp], rax
$LN6@PMC_ToStri:
; 540 : NUMBER_HEADER* nx = (NUMBER_HEADER*)x;
mov rax, QWORD PTR x$[rbp]
mov QWORD PTR nx$[rbp], rax
; 541 : PMC_STATUS_CODE result;
; 542 : if ((result = CheckNumber(nx)) != PMC_STATUS_OK)
mov rcx, QWORD PTR nx$[rbp]
call CheckNumber
mov DWORD PTR result$[rbp], eax
cmp DWORD PTR result$[rbp], 0
je SHORT $LN7@PMC_ToStri
; 543 : return (result);
mov eax, DWORD PTR result$[rbp]
jmp $LN1@PMC_ToStri
$LN7@PMC_ToStri:
; 544 : switch (format)
movsx eax, BYTE PTR format$[rbp]
mov DWORD PTR tv71[rbp], eax
mov eax, DWORD PTR tv71[rbp]
sub eax, 68 ; 00000044H
mov DWORD PTR tv71[rbp], eax
cmp DWORD PTR tv71[rbp], 52 ; 00000034H
ja $LN12@PMC_ToStri
movsxd rax, DWORD PTR tv71[rbp]
lea rcx, OFFSET FLAT:__ImageBase
movzx eax, BYTE PTR $LN22@PMC_ToStri[rcx+rax]
mov eax, DWORD PTR $LN23@PMC_ToStri[rcx+rax*4]
add rax, rcx
jmp rax
$LN8@PMC_ToStri:
; 545 : {
; 546 : case 'n':
; 547 : case 'N':
; 548 : return (ToStringDN(nx, buffer, buffer_size, 'N', width >= 0 ? width : format_option->DecimalDigits, format_option));
cmp DWORD PTR width$[rbp], 0
jl SHORT $LN14@PMC_ToStri
mov eax, DWORD PTR width$[rbp]
mov DWORD PTR tv76[rbp], eax
jmp SHORT $LN15@PMC_ToStri
$LN14@PMC_ToStri:
mov rax, QWORD PTR format_option$[rbp]
mov eax, DWORD PTR [rax]
mov DWORD PTR tv76[rbp], eax
$LN15@PMC_ToStri:
mov rax, QWORD PTR format_option$[rbp]
mov QWORD PTR [rsp+40], rax
mov eax, DWORD PTR tv76[rbp]
mov DWORD PTR [rsp+32], eax
mov r9b, 78 ; 0000004eH
mov r8, QWORD PTR buffer_size$[rbp]
mov rdx, QWORD PTR buffer$[rbp]
mov rcx, QWORD PTR nx$[rbp]
call ToStringDN
jmp $LN1@PMC_ToStri
$LN9@PMC_ToStri:
; 549 : case 'x':
; 550 : return (ToStringX(nx, buffer, buffer_size, width >= 0 ? width : 0, format_option, 0));
cmp DWORD PTR width$[rbp], 0
jl SHORT $LN16@PMC_ToStri
mov eax, DWORD PTR width$[rbp]
mov DWORD PTR tv86[rbp], eax
jmp SHORT $LN17@PMC_ToStri
$LN16@PMC_ToStri:
mov DWORD PTR tv86[rbp], 0
$LN17@PMC_ToStri:
mov DWORD PTR [rsp+40], 0
mov rax, QWORD PTR format_option$[rbp]
mov QWORD PTR [rsp+32], rax
mov r9d, DWORD PTR tv86[rbp]
mov r8, QWORD PTR buffer_size$[rbp]
mov rdx, QWORD PTR buffer$[rbp]
mov rcx, QWORD PTR nx$[rbp]
call ToStringX
jmp $LN1@PMC_ToStri
$LN10@PMC_ToStri:
; 551 : case 'X':
; 552 : return (ToStringX(nx, buffer, buffer_size, width >= 0 ? width : 0, format_option, 1));
cmp DWORD PTR width$[rbp], 0
jl SHORT $LN18@PMC_ToStri
mov eax, DWORD PTR width$[rbp]
mov DWORD PTR tv95[rbp], eax
jmp SHORT $LN19@PMC_ToStri
$LN18@PMC_ToStri:
mov DWORD PTR tv95[rbp], 0
$LN19@PMC_ToStri:
mov DWORD PTR [rsp+40], 1
mov rax, QWORD PTR format_option$[rbp]
mov QWORD PTR [rsp+32], rax
mov r9d, DWORD PTR tv95[rbp]
mov r8, QWORD PTR buffer_size$[rbp]
mov rdx, QWORD PTR buffer$[rbp]
mov rcx, QWORD PTR nx$[rbp]
call ToStringX
jmp SHORT $LN1@PMC_ToStri
$LN11@PMC_ToStri:
; 553 : case 'd':
; 554 : case 'D':
; 555 : return (ToStringDN(nx, buffer, buffer_size, 'D', width >= 0 ? width : 0, format_option));
cmp DWORD PTR width$[rbp], 0
jl SHORT $LN20@PMC_ToStri
mov eax, DWORD PTR width$[rbp]
mov DWORD PTR tv135[rbp], eax
jmp SHORT $LN21@PMC_ToStri
$LN20@PMC_ToStri:
mov DWORD PTR tv135[rbp], 0
$LN21@PMC_ToStri:
mov rax, QWORD PTR format_option$[rbp]
mov QWORD PTR [rsp+40], rax
mov eax, DWORD PTR tv135[rbp]
mov DWORD PTR [rsp+32], eax
mov r9b, 68 ; 00000044H
mov r8, QWORD PTR buffer_size$[rbp]
mov rdx, QWORD PTR buffer$[rbp]
mov rcx, QWORD PTR nx$[rbp]
call ToStringDN
jmp SHORT $LN1@PMC_ToStri
$LN12@PMC_ToStri:
; 556 : default:
; 557 : return (PMC_STATUS_ARGUMENT_ERROR);
mov eax, -1
$LN1@PMC_ToStri:
; 558 : }
; 559 : }
lea rsp, QWORD PTR [rbp+264]
pop rdi
pop rbp
ret 0
npad 1
$LN23@PMC_ToStri:
DD $LN11@PMC_ToStri
DD $LN8@PMC_ToStri
DD $LN10@PMC_ToStri
DD $LN9@PMC_ToStri
DD $LN12@PMC_ToStri
$LN22@PMC_ToStri:
DB 0
DB 4
DB 4
DB 4
DB 4
DB 4
DB 4
DB 4
DB 4
DB 4
DB 1
DB 4
DB 4
DB 4
DB 4
DB 4
DB 4
DB 4
DB 4
DB 4
DB 2
DB 4
DB 4
DB 4
DB 4
DB 4
DB 4
DB 4
DB 4
DB 4
DB 4
DB 4
DB 0
DB 4
DB 4
DB 4
DB 4
DB 4
DB 4
DB 4
DB 4
DB 4
DB 1
DB 4
DB 4
DB 4
DB 4
DB 4
DB 4
DB 4
DB 4
DB 4
DB 3
PMC_ToString ENDP
_TEXT ENDS
; Function compile flags: /Odtp /RTCsu /ZI
; File z:\sources\lunor\repos\rougemeilland\palmtree.math.core.implements\palmtree.math.core.implements\pmc_tostring.c
; COMDAT Initialize_ToString
_TEXT SEGMENT
feature$ = 224
Initialize_ToString PROC ; COMDAT
; 562 : {
$LN3:
mov QWORD PTR [rsp+8], rcx
push rbp
push rdi
sub rsp, 232 ; 000000e8H
lea rbp, QWORD PTR [rsp+32]
mov rdi, rsp
mov ecx, 58 ; 0000003aH
mov eax, -858993460 ; ccccccccH
rep stosd
mov rcx, QWORD PTR [rsp+264]
lea rcx, OFFSET FLAT:__3AA1CF5E_pmc_tostring@c
call __CheckForDebuggerJustMyCode
; 563 : default_number_format_option.DecimalDigits = 2;
mov DWORD PTR default_number_format_option, 2
; 564 : lstrcpyW(default_number_format_option.GroupSeparator, L",");
lea rdx, OFFSET FLAT:??_C@_13DEFPDAGF@?$AA?0@
lea rcx, OFFSET FLAT:default_number_format_option+4
call QWORD PTR __imp_lstrcpyW
; 565 : lstrcpyW(default_number_format_option.DecimalSeparator, L".");
lea rdx, OFFSET FLAT:??_C@_13JOFGPIOO@?$AA?4@
lea rcx, OFFSET FLAT:default_number_format_option+10
call QWORD PTR __imp_lstrcpyW
; 566 : lstrcpy(default_number_format_option.GroupSizes, "3");
lea rdx, OFFSET FLAT:??_C@_01EKENIIDA@3@
lea rcx, OFFSET FLAT:default_number_format_option+28
call QWORD PTR __imp_lstrcpyA
; 567 : lstrcpyW(default_number_format_option.PositiveSign, L"+");
lea rdx, OFFSET FLAT:??_C@_13KJIIAINM@?$AA?$CL@
lea rcx, OFFSET FLAT:default_number_format_option+16
call QWORD PTR __imp_lstrcpyW
; 568 : lstrcpyW(default_number_format_option.NegativeSign, L"-");
lea rdx, OFFSET FLAT:??_C@_13IMODFHAA@?$AA?9@
lea rcx, OFFSET FLAT:default_number_format_option+22
call QWORD PTR __imp_lstrcpyW
; 569 :
; 570 : return (PMC_STATUS_OK);
xor eax, eax
; 571 : }
lea rsp, QWORD PTR [rbp+200]
pop rdi
pop rbp
ret 0
Initialize_ToString ENDP
_TEXT ENDS
END
|
notes/setoids/LeibnizEquality.agda | asr/fotc | 11 | 15198 | <filename>notes/setoids/LeibnizEquality.agda
{-# OPTIONS --exact-split #-}
{-# OPTIONS --no-sized-types #-}
{-# OPTIONS --no-universe-polymorphism #-}
{-# OPTIONS --without-K #-}
module LeibnizEquality where
------------------------------------------------------------------------------
-- The identity type.
data _≡_ {A : Set}(x : A) : A → Set where
refl : x ≡ x
-- Leibniz equality (see [Luo 1994, sec. 5.1.3])
-- (From Agda/examples/lib/Logic/Leibniz.agda)
_≐_ : {A : Set} → A → A → Set₁
x ≐ y = (P : _ → Set) → P x → P y
-- Properties
≐-refl : {A : Set}{x : A} → x ≐ x
≐-refl P Px = Px
≐-sym : {A : Set}{x y : A} → x ≐ y → y ≐ x
≐-sym {x = x} {y} h P Py = h (λ z → P z → P x) (λ Px → Px) Py
≐-trans : {A : Set}{x y z : A} → x ≐ y → y ≐ z → x ≐ z
≐-trans h₁ h₂ P Px = h₂ P (h₁ P Px)
≐-subst : {A : Set}(P : A → Set){x y : A} → x ≐ y → P x → P y
≐-subst P h = h P
------------------------------------------------------------------------------
-- Leibniz's equality and the identity type
-- "In the presence of a type of propositions "Prop" one can also
-- define propositional equality by Leibniz's principle." [Hofmman
-- 1995, p. 4]
≐→≡ : {A : Set}{x y : A} → x ≐ y → x ≡ y
≐→≡ {x = x} h = h (λ z → x ≡ z) refl
≡→≐ : {A : Set}{x y : A} → x ≡ y → x ≐ y
≡→≐ refl P Px = Px
------------------------------------------------------------------------------
-- References
--
-- Hofmann, Martin (1995). Extensional concepts in intensional type
-- theory. PhD thesis. University of Edinburgh.
-- Luo, Zhaohui (1994). Computation and Reasoning. A Type Theory for
-- Computer Science. Oxford University Press.
|
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.