297 lines
39 KiB
HTML
Executable File
297 lines
39 KiB
HTML
Executable File
<!DOCTYPE html>
|
|
<html lang="en">
|
|
<head>
|
|
<meta charset="UTF-8">
|
|
<meta name="generator" content="TempleOS V5.03">
|
|
<meta name="viewport" content="width=device-width">
|
|
<link rel="stylesheet" href="/style/templeos.css">
|
|
<script src="/script/templeos.js"></script>
|
|
<style type="text/css">
|
|
.cF0{color:#000000;background-color:#ffffff;}
|
|
.cF1{color:#0000aa;background-color:#ffffff;}
|
|
.cF2{color:#00aa00;background-color:#ffffff;}
|
|
.cF3{color:#00aaaa;background-color:#ffffff;}
|
|
.cF4{color:#aa0000;background-color:#ffffff;}
|
|
.cF5{color:#aa00aa;background-color:#ffffff;}
|
|
.cF6{color:#aa5500;background-color:#ffffff;}
|
|
.cF7{color:#aaaaaa;background-color:#ffffff;}
|
|
.cF8{color:#555555;background-color:#ffffff;}
|
|
.cF9{color:#5555ff;background-color:#ffffff;}
|
|
.cFA{color:#55ff55;background-color:#ffffff;}
|
|
.cFB{color:#55ffff;background-color:#ffffff;}
|
|
.cFC{color:#ff5555;background-color:#ffffff;}
|
|
.cFD{color:#ff55ff;background-color:#ffffff;}
|
|
.cFE{color:#ffff55;background-color:#ffffff;}
|
|
.cFF{color:#ffffff;background-color:#ffffff;}
|
|
</style>
|
|
</head>
|
|
<body>
|
|
<pre id="content">
|
|
<a name="l1"></a><span class=cF1>asm</span><span class=cF0> {
|
|
<a name="l2"></a></span><span class=cF2>//************************************</span><span class=cF0>
|
|
<a name="l3"></a></span><span class=cFD>SYS_HASH_STR</span><span class=cF0>::
|
|
<a name="l4"></a></span><span class=cF2>// IN:</span><span class=cF0> </span><span class=cF2>RSI=Addr of string</span><span class=cF0>
|
|
<a name="l5"></a></span><span class=cF2>// OUT:</span><span class=cF0> </span><span class=cF2>RAX</span><span class=cF0>
|
|
<a name="l6"></a> </span><span class=cF1>XOR</span><span class=cF0> </span><span class=cFC>RAX</span><span class=cF0>,</span><span class=cFC>RAX</span><span class=cF0>
|
|
<a name="l7"></a> </span><span class=cF1>TEST</span><span class=cF0> </span><span class=cFC>RSI</span><span class=cF0>,</span><span class=cFC>RSI</span><span class=cF0>
|
|
<a name="l8"></a> </span><span class=cF1>JZ</span><span class=cF0> @@15
|
|
<a name="l9"></a>
|
|
<a name="l10"></a> </span><span class=cF1>PUSH</span><span class=cF0> </span><span class=cFC>RSI</span><span class=cF0>
|
|
<a name="l11"></a> </span><span class=cF1>PUSH</span><span class=cF0> </span><span class=cFC>RBX</span><span class=cF0>
|
|
<a name="l12"></a> </span><span class=cF1>XOR</span><span class=cF0> </span><span class=cFC>RBX</span><span class=cF0>,</span><span class=cFC>RBX</span><span class=cF0>
|
|
<a name="l13"></a> </span><span class=cF1>JMP</span><span class=cF0> @@10
|
|
<a name="l14"></a>
|
|
<a name="l15"></a>@@05: </span><span class=cF1>SHL1</span><span class=cF0> </span><span class=cFC>RBX</span><span class=cF0>
|
|
<a name="l16"></a> </span><span class=cF1>ADC</span><span class=cF0> </span><span class=cFC>RBX</span><span class=cF0>,</span><span class=cFC>RAX</span><span class=cF0>
|
|
<a name="l17"></a>@@10: </span><span class=cF1>LODSB</span><span class=cF0>
|
|
<a name="l18"></a> </span><span class=cF1>TEST</span><span class=cF0> </span><span class=cFC>AL</span><span class=cF0>,</span><span class=cFC>AL</span><span class=cF0>
|
|
<a name="l19"></a> </span><span class=cF1>JNZ</span><span class=cF0> @@05
|
|
<a name="l20"></a>
|
|
<a name="l21"></a> </span><span class=cF1>MOV</span><span class=cF0> </span><span class=cFC>RAX</span><span class=cF0>,</span><span class=cFC>RBX</span><span class=cF0>
|
|
<a name="l22"></a> </span><span class=cF1>SHR</span><span class=cF0> </span><span class=cFC>RBX</span><span class=cF0>,16
|
|
<a name="l23"></a> </span><span class=cF1>ADC</span><span class=cF0> </span><span class=cFC>RAX</span><span class=cF0>,</span><span class=cFC>RBX</span><span class=cF0>
|
|
<a name="l24"></a> </span><span class=cF1>POP</span><span class=cF0> </span><span class=cFC>RBX</span><span class=cF0>
|
|
<a name="l25"></a> </span><span class=cF1>POP</span><span class=cF0> </span><span class=cFC>RSI</span><span class=cF0>
|
|
<a name="l26"></a>
|
|
<a name="l27"></a>@@15: </span><span class=cF1>RET</span><span class=cF0>
|
|
<a name="l28"></a></span><span class=cF2>//************************************</span><span class=cF0>
|
|
<a name="l29"></a></span><span class=cFD>SYS_HASH_SINGLE_TABLE_FIND1</span><span class=cF0>::
|
|
<a name="l30"></a></span><span class=cF2>// IN:</span><span class=cF0> </span><span class=cF2>RAX=HASHED STRING VAL</span><span class=cF0>
|
|
<a name="l31"></a></span><span class=cF2>//</span><span class=cF0> </span><span class=cF2>RSI=STR</span><span class=cF0>
|
|
<a name="l32"></a></span><span class=cF2>//</span><span class=cF0> </span><span class=cF2>RBX=TYPE MASK</span><span class=cF0>
|
|
<a name="l33"></a></span><span class=cF2>//</span><span class=cF0> </span><span class=cF2>RDI=TABLE</span><span class=cF0>
|
|
<a name="l34"></a></span><span class=cF2>//</span><span class=cF0> </span><span class=cF2>RCX=INSTANCE, NOT ZERO</span><span class=cF0>
|
|
<a name="l35"></a></span><span class=cF2>// OUT: RAX=ENTRY OR ZERO NOT FOUND</span><span class=cF0>
|
|
<a name="l36"></a></span><span class=cF2>//</span><span class=cF0> </span><span class=cF2>RDX=POINTER TO POINTER TO ENTRY</span><span class=cF0>
|
|
<a name="l37"></a></span><span class=cF2>//</span><span class=cF0> </span><span class=cF2>RCX IF NOT FOUND ENOUGH, DECREMENTED BY NUM MATCHES</span><span class=cF0>
|
|
<a name="l38"></a></span><span class=cF2>//</span><span class=cF0> </span><span class=cF2>ZERO FLAG SET NOT FOUND</span><span class=cF0>
|
|
<a name="l39"></a> </span><span class=cF1>MOV</span><span class=cF0> </span><span class=cFC>RCX</span><span class=cF0>,1
|
|
<a name="l40"></a></span><span class=cFD>SYS_HASH_SINGLE_TABLE_FIND</span><span class=cF0>::
|
|
<a name="l41"></a> </span><span class=cF1>TEST</span><span class=cF0> </span><span class=cFC>RCX</span><span class=cF0>,</span><span class=cFC>RCX</span><span class=cF0>
|
|
<a name="l42"></a> </span><span class=cF1>JNZ</span><span class=cF0> @@05
|
|
<a name="l43"></a> </span><span class=cF1>XOR</span><span class=cF0> </span><span class=cFC>RAX</span><span class=cF0>,</span><span class=cFC>RAX</span><span class=cF0>
|
|
<a name="l44"></a> </span><span class=cF1>RET</span><span class=cF0>
|
|
<a name="l45"></a>@@05: </span><span class=cF1>AND</span><span class=cF0> </span><span class=cFC>RAX</span><span class=cF0>,</span><span class=cF9>U64</span><span class=cF0> </span><span class=cF9>CHashTable</span><span class=cF0>.mask[</span><span class=cFC>RDI</span><span class=cF0>]
|
|
<a name="l46"></a> </span><span class=cF1>MOV</span><span class=cF0> </span><span class=cFC>RDX</span><span class=cF0>,</span><span class=cF9>U64</span><span class=cF0> </span><span class=cF9>CHashTable</span><span class=cF0>.body[</span><span class=cFC>RDI</span><span class=cF0>]
|
|
<a name="l47"></a> </span><span class=cF1>LEA</span><span class=cF0> </span><span class=cFC>RDX</span><span class=cF0>,</span><span class=cF9>U64</span><span class=cF0> [</span><span class=cFC>RDX</span><span class=cF0>+</span><span class=cFC>RAX</span><span class=cF0>*8]
|
|
<a name="l48"></a>@@10: </span><span class=cF1>MOV</span><span class=cF0> </span><span class=cFC>RAX</span><span class=cF0>,</span><span class=cF9>U64</span><span class=cF0> [</span><span class=cFC>RDX</span><span class=cF0>]
|
|
<a name="l49"></a> </span><span class=cF1>TEST</span><span class=cF0> </span><span class=cFC>RAX</span><span class=cF0>,</span><span class=cFC>RAX</span><span class=cF0>
|
|
<a name="l50"></a> </span><span class=cF1>JNZ</span><span class=cF0> @@15
|
|
<a name="l51"></a> </span><span class=cF1>RET</span><span class=cF0>
|
|
<a name="l52"></a>
|
|
<a name="l53"></a>@@15: </span><span class=cF1>TEST</span><span class=cF0> </span><span class=cF9>U32</span><span class=cF0> </span><span class=cF9>CHash</span><span class=cF0>.type[</span><span class=cFC>RAX</span><span class=cF0>],</span><span class=cFC>EBX</span><span class=cF0>
|
|
<a name="l54"></a> </span><span class=cF1>JZ</span><span class=cF0> @@30
|
|
<a name="l55"></a> </span><span class=cF1>PUSH</span><span class=cF0> </span><span class=cFC>RAX</span><span class=cF0>
|
|
<a name="l56"></a> </span><span class=cF1>PUSH</span><span class=cF0> </span><span class=cFC>RDI</span><span class=cF0>
|
|
<a name="l57"></a> </span><span class=cF1>PUSH</span><span class=cF0> </span><span class=cFC>RSI</span><span class=cF0>
|
|
<a name="l58"></a> </span><span class=cF1>MOV</span><span class=cF0> </span><span class=cFC>RDI</span><span class=cF0>,</span><span class=cF9>U64</span><span class=cF0> </span><span class=cF9>CHash</span><span class=cF0>.str[</span><span class=cFC>RAX</span><span class=cF0>]
|
|
<a name="l59"></a>@@20: </span><span class=cF1>LODSB</span><span class=cF0>
|
|
<a name="l60"></a> </span><span class=cF1>CMP</span><span class=cF0> </span><span class=cF1>U8</span><span class=cF0> [</span><span class=cFC>RDI</span><span class=cF0>],</span><span class=cFC>AL</span><span class=cF0>
|
|
<a name="l61"></a> </span><span class=cF1>JNE</span><span class=cF0> @@25
|
|
<a name="l62"></a> </span><span class=cF1>INC</span><span class=cF0> </span><span class=cFC>RDI</span><span class=cF0>
|
|
<a name="l63"></a> </span><span class=cF1>TEST</span><span class=cF0> </span><span class=cFC>AL</span><span class=cF0>,</span><span class=cFC>AL</span><span class=cF0>
|
|
<a name="l64"></a> </span><span class=cF1>JNZ</span><span class=cF0> @@20
|
|
<a name="l65"></a> </span><span class=cF1>POP</span><span class=cF0> </span><span class=cFC>RSI</span><span class=cF0>
|
|
<a name="l66"></a> </span><span class=cF1>POP</span><span class=cF0> </span><span class=cFC>RDI</span><span class=cF0>
|
|
<a name="l67"></a> </span><span class=cF1>POP</span><span class=cF0> </span><span class=cFC>RAX</span><span class=cF0>
|
|
<a name="l68"></a> </span><span class=cF1>LOOP</span><span class=cF0> @@30
|
|
<a name="l69"></a> </span><span class=cF1>INC</span><span class=cF0> </span><span class=cF9>U32</span><span class=cF0> </span><span class=cF9>CHash</span><span class=cF0>.use_cnt[</span><span class=cFC>RAX</span><span class=cF0>]
|
|
<a name="l70"></a> </span><span class=cF1>TEST</span><span class=cF0> </span><span class=cFC>RAX</span><span class=cF0>,</span><span class=cFC>RAX</span><span class=cF0>
|
|
<a name="l71"></a> </span><span class=cF1>RET</span><span class=cF0>
|
|
<a name="l72"></a>
|
|
<a name="l73"></a>@@25: </span><span class=cF1>POP</span><span class=cF0> </span><span class=cFC>RSI</span><span class=cF0>
|
|
<a name="l74"></a> </span><span class=cF1>POP</span><span class=cF0> </span><span class=cFC>RDI</span><span class=cF0>
|
|
<a name="l75"></a> </span><span class=cF1>POP</span><span class=cF0> </span><span class=cFC>RAX</span><span class=cF0>
|
|
<a name="l76"></a>
|
|
<a name="l77"></a>@@30: </span><span class=cF1>LEA</span><span class=cF0> </span><span class=cFC>RDX</span><span class=cF0>,</span><span class=cF9>U64</span><span class=cF0> </span><span class=cF9>CHash</span><span class=cF0>.next[</span><span class=cFC>RAX</span><span class=cF0>]
|
|
<a name="l78"></a> </span><span class=cF1>JMP</span><span class=cF0> @@10
|
|
<a name="l79"></a></span><span class=cF2>//************************************</span><span class=cF0>
|
|
<a name="l80"></a></span><span class=cFD>SYS_HASH_FIND1</span><span class=cF0>::
|
|
<a name="l81"></a></span><span class=cF2>// IN:</span><span class=cF0> </span><span class=cF2>RSI=STR</span><span class=cF0>
|
|
<a name="l82"></a></span><span class=cF2>//</span><span class=cF0> </span><span class=cF2>RBX=TYPE MASK</span><span class=cF0>
|
|
<a name="l83"></a></span><span class=cF2>//</span><span class=cF0> </span><span class=cF2>RDI=TABLE</span><span class=cF0>
|
|
<a name="l84"></a></span><span class=cF2>//</span><span class=cF0> </span><span class=cF2>RCX=INSTANCE NUM</span><span class=cF0>
|
|
<a name="l85"></a></span><span class=cF2>// OUT: RAX=ENTRY OR ZERO NOT FOUND</span><span class=cF0>
|
|
<a name="l86"></a></span><span class=cF2>//</span><span class=cF0> </span><span class=cF2>ZERO FLAG SET NOT FOUND</span><span class=cF0>
|
|
<a name="l87"></a> </span><span class=cF1>MOV</span><span class=cF0> </span><span class=cFC>RCX</span><span class=cF0>,1
|
|
<a name="l88"></a></span><span class=cFD>SYS_HASH_FIND</span><span class=cF0>::
|
|
<a name="l89"></a> </span><span class=cF1>PUSH</span><span class=cF0> </span><span class=cFC>RDI</span><span class=cF0>
|
|
<a name="l90"></a> </span><span class=cF1>CALL</span><span class=cF0> </span><span class=cFD>SYS_HASH_STR</span><span class=cF0>
|
|
<a name="l91"></a>
|
|
<a name="l92"></a>@@05: </span><span class=cF1>PUSH</span><span class=cF0> </span><span class=cFC>RAX</span><span class=cF0>
|
|
<a name="l93"></a> </span><span class=cF1>CALL</span><span class=cF0> </span><span class=cFD>SYS_HASH_SINGLE_TABLE_FIND</span><span class=cF0>
|
|
<a name="l94"></a> </span><span class=cF1>JNZ</span><span class=cF0> @@15
|
|
<a name="l95"></a> </span><span class=cF1>POP</span><span class=cF0> </span><span class=cFC>RAX</span><span class=cF0>
|
|
<a name="l96"></a>@@10: </span><span class=cF1>MOV</span><span class=cF0> </span><span class=cFC>RDI</span><span class=cF0>,</span><span class=cF9>U64</span><span class=cF0> </span><span class=cF9>CHashTable</span><span class=cF0>.next[</span><span class=cFC>RDI</span><span class=cF0>]
|
|
<a name="l97"></a> </span><span class=cF1>TEST</span><span class=cF0> </span><span class=cFC>RDI</span><span class=cF0>,</span><span class=cFC>RDI</span><span class=cF0>
|
|
<a name="l98"></a> </span><span class=cF1>JNZ</span><span class=cF0> @@05
|
|
<a name="l99"></a> </span><span class=cF1>POP</span><span class=cF0> </span><span class=cFC>RDI</span><span class=cF0>
|
|
<a name="l100"></a> </span><span class=cF1>XOR</span><span class=cF0> </span><span class=cFC>RAX</span><span class=cF0>,</span><span class=cFC>RAX</span><span class=cF0>
|
|
<a name="l101"></a> </span><span class=cF1>RET</span><span class=cF0>
|
|
<a name="l102"></a>
|
|
<a name="l103"></a>@@15: </span><span class=cF1>ADD</span><span class=cF0> </span><span class=cFC>RSP</span><span class=cF0>,8
|
|
<a name="l104"></a> </span><span class=cF1>POP</span><span class=cF0> </span><span class=cFC>RDI</span><span class=cF0>
|
|
<a name="l105"></a> </span><span class=cF1>TEST</span><span class=cF0> </span><span class=cFC>RAX</span><span class=cF0>,</span><span class=cFC>RAX</span><span class=cF0>
|
|
<a name="l106"></a> </span><span class=cF1>RET</span><span class=cF0>
|
|
<a name="l107"></a></span><span class=cF2>//************************************</span><span class=cF0>
|
|
<a name="l108"></a></span><span class=cFD>SYS_HASH_BUCKET_FIND</span><span class=cF0>::
|
|
<a name="l109"></a></span><span class=cF2>// IN:</span><span class=cF0> </span><span class=cF2>RSI=STR</span><span class=cF0>
|
|
<a name="l110"></a></span><span class=cF2>//</span><span class=cF0> </span><span class=cF2>RDI=TABLE</span><span class=cF0>
|
|
<a name="l111"></a></span><span class=cF2>// OUT: RAX=BUCKET</span><span class=cF0>
|
|
<a name="l112"></a> </span><span class=cF1>PUSH</span><span class=cF0> </span><span class=cFC>RDX</span><span class=cF0>
|
|
<a name="l113"></a> </span><span class=cF1>CALL</span><span class=cF0> </span><span class=cFD>SYS_HASH_STR</span><span class=cF0>
|
|
<a name="l114"></a> </span><span class=cF1>AND</span><span class=cF0> </span><span class=cFC>RAX</span><span class=cF0>,</span><span class=cF9>U64</span><span class=cF0> </span><span class=cF9>CHashTable</span><span class=cF0>.mask[</span><span class=cFC>RDI</span><span class=cF0>]
|
|
<a name="l115"></a> </span><span class=cF1>MOV</span><span class=cF0> </span><span class=cFC>RDX</span><span class=cF0>,</span><span class=cF9>U64</span><span class=cF0> </span><span class=cF9>CHashTable</span><span class=cF0>.body[</span><span class=cFC>RDI</span><span class=cF0>]
|
|
<a name="l116"></a> </span><span class=cF1>LEA</span><span class=cF0> </span><span class=cFC>RAX</span><span class=cF0>,</span><span class=cF9>U64</span><span class=cF0> [</span><span class=cFC>RDX</span><span class=cF0>+</span><span class=cFC>RAX</span><span class=cF0>*8]
|
|
<a name="l117"></a> </span><span class=cF1>POP</span><span class=cF0> </span><span class=cFC>RDX</span><span class=cF0>
|
|
<a name="l118"></a> </span><span class=cF1>RET</span><span class=cF0>
|
|
<a name="l119"></a></span><span class=cFD>_HASH_STR</span><span class=cF0>::
|
|
<a name="l120"></a> </span><span class=cF1>PUSH</span><span class=cF0> </span><span class=cFC>RBP</span><span class=cF0>
|
|
<a name="l121"></a> </span><span class=cF1>MOV</span><span class=cF0> </span><span class=cFC>RBP</span><span class=cF0>,</span><span class=cFC>RSP</span><span class=cF0>
|
|
<a name="l122"></a> </span><span class=cF1>PUSH</span><span class=cF0> </span><span class=cFC>RSI</span><span class=cF0>
|
|
<a name="l123"></a> </span><span class=cF1>MOV</span><span class=cF0> </span><span class=cFC>RSI</span><span class=cF0>,</span><span class=cF9>U64</span><span class=cF0> </span><span class=cF3>SF_ARG1</span><span class=cF0>[</span><span class=cFC>RBP</span><span class=cF0>]
|
|
<a name="l124"></a> </span><span class=cF1>CALL</span><span class=cF0> </span><span class=cFD>SYS_HASH_STR</span><span class=cF0>
|
|
<a name="l125"></a> </span><span class=cF1>POP</span><span class=cF0> </span><span class=cFC>RSI</span><span class=cF0>
|
|
<a name="l126"></a> </span><span class=cF1>POP</span><span class=cF0> </span><span class=cFC>RBP</span><span class=cF0>
|
|
<a name="l127"></a> </span><span class=cF1>RET1</span><span class=cF0> 8
|
|
<a name="l128"></a></span><span class=cFD>_HASH_FIND</span><span class=cF0>::
|
|
<a name="l129"></a> </span><span class=cF1>PUSH</span><span class=cF0> </span><span class=cFC>RBP</span><span class=cF0>
|
|
<a name="l130"></a> </span><span class=cF1>MOV</span><span class=cF0> </span><span class=cFC>RBP</span><span class=cF0>,</span><span class=cFC>RSP</span><span class=cF0>
|
|
<a name="l131"></a> </span><span class=cF1>PUSH</span><span class=cF0> </span><span class=cFC>RSI</span><span class=cF0>
|
|
<a name="l132"></a> </span><span class=cF1>PUSH</span><span class=cF0> </span><span class=cFC>RDI</span><span class=cF0>
|
|
<a name="l133"></a> </span><span class=cF1>MOV</span><span class=cF0> </span><span class=cFC>RSI</span><span class=cF0>,</span><span class=cF9>U64</span><span class=cF0> </span><span class=cF3>SF_ARG1</span><span class=cF0>[</span><span class=cFC>RBP</span><span class=cF0>]
|
|
<a name="l134"></a> </span><span class=cF1>MOV</span><span class=cF0> </span><span class=cFC>RDI</span><span class=cF0>,</span><span class=cF9>U64</span><span class=cF0> </span><span class=cF3>SF_ARG2</span><span class=cF0>[</span><span class=cFC>RBP</span><span class=cF0>]
|
|
<a name="l135"></a> </span><span class=cF1>MOV</span><span class=cF0> </span><span class=cFC>RBX</span><span class=cF0>,</span><span class=cF9>U64</span><span class=cF0> </span><span class=cF3>SF_ARG3</span><span class=cF0>[</span><span class=cFC>RBP</span><span class=cF0>]
|
|
<a name="l136"></a> </span><span class=cF1>MOV</span><span class=cF0> </span><span class=cFC>RCX</span><span class=cF0>,</span><span class=cF9>U64</span><span class=cF0> </span><span class=cF3>SF_ARG4</span><span class=cF0>[</span><span class=cFC>RBP</span><span class=cF0>]
|
|
<a name="l137"></a> </span><span class=cF1>CALL</span><span class=cF0> </span><span class=cFD>SYS_HASH_FIND</span><span class=cF0>
|
|
<a name="l138"></a> </span><span class=cF1>POP</span><span class=cF0> </span><span class=cFC>RDI</span><span class=cF0>
|
|
<a name="l139"></a> </span><span class=cF1>POP</span><span class=cF0> </span><span class=cFC>RSI</span><span class=cF0>
|
|
<a name="l140"></a> </span><span class=cF1>POP</span><span class=cF0> </span><span class=cFC>RBP</span><span class=cF0>
|
|
<a name="l141"></a> </span><span class=cF1>RET1</span><span class=cF0> 32
|
|
<a name="l142"></a></span><span class=cFD>_HASH_SINGLE_TABLE_FIND</span><span class=cF0>::
|
|
<a name="l143"></a> </span><span class=cF1>PUSH</span><span class=cF0> </span><span class=cFC>RBP</span><span class=cF0>
|
|
<a name="l144"></a> </span><span class=cF1>MOV</span><span class=cF0> </span><span class=cFC>RBP</span><span class=cF0>,</span><span class=cFC>RSP</span><span class=cF0>
|
|
<a name="l145"></a> </span><span class=cF1>PUSH</span><span class=cF0> </span><span class=cFC>RSI</span><span class=cF0>
|
|
<a name="l146"></a> </span><span class=cF1>PUSH</span><span class=cF0> </span><span class=cFC>RDI</span><span class=cF0>
|
|
<a name="l147"></a> </span><span class=cF1>MOV</span><span class=cF0> </span><span class=cFC>RSI</span><span class=cF0>,</span><span class=cF9>U64</span><span class=cF0> </span><span class=cF3>SF_ARG1</span><span class=cF0>[</span><span class=cFC>RBP</span><span class=cF0>]
|
|
<a name="l148"></a> </span><span class=cF1>MOV</span><span class=cF0> </span><span class=cFC>RDI</span><span class=cF0>,</span><span class=cF9>U64</span><span class=cF0> </span><span class=cF3>SF_ARG2</span><span class=cF0>[</span><span class=cFC>RBP</span><span class=cF0>]
|
|
<a name="l149"></a> </span><span class=cF1>MOV</span><span class=cF0> </span><span class=cFC>RBX</span><span class=cF0>,</span><span class=cF9>U64</span><span class=cF0> </span><span class=cF3>SF_ARG3</span><span class=cF0>[</span><span class=cFC>RBP</span><span class=cF0>]
|
|
<a name="l150"></a> </span><span class=cF1>MOV</span><span class=cF0> </span><span class=cFC>RCX</span><span class=cF0>,</span><span class=cF9>U64</span><span class=cF0> </span><span class=cF3>SF_ARG4</span><span class=cF0>[</span><span class=cFC>RBP</span><span class=cF0>]
|
|
<a name="l151"></a> </span><span class=cF1>CALL</span><span class=cF0> </span><span class=cFD>SYS_HASH_STR</span><span class=cF0>
|
|
<a name="l152"></a> </span><span class=cF1>CALL</span><span class=cF0> </span><span class=cFD>SYS_HASH_SINGLE_TABLE_FIND</span><span class=cF0>
|
|
<a name="l153"></a> </span><span class=cF1>POP</span><span class=cF0> </span><span class=cFC>RDI</span><span class=cF0>
|
|
<a name="l154"></a> </span><span class=cF1>POP</span><span class=cF0> </span><span class=cFC>RSI</span><span class=cF0>
|
|
<a name="l155"></a> </span><span class=cF1>POP</span><span class=cF0> </span><span class=cFC>RBP</span><span class=cF0>
|
|
<a name="l156"></a> </span><span class=cF1>RET1</span><span class=cF0> 32
|
|
<a name="l157"></a></span><span class=cFD>_HASH_BUCKET_FIND</span><span class=cF0>::
|
|
<a name="l158"></a> </span><span class=cF1>PUSH</span><span class=cF0> </span><span class=cFC>RBP</span><span class=cF0>
|
|
<a name="l159"></a> </span><span class=cF1>MOV</span><span class=cF0> </span><span class=cFC>RBP</span><span class=cF0>,</span><span class=cFC>RSP</span><span class=cF0>
|
|
<a name="l160"></a> </span><span class=cF1>PUSH</span><span class=cF0> </span><span class=cFC>RSI</span><span class=cF0>
|
|
<a name="l161"></a> </span><span class=cF1>PUSH</span><span class=cF0> </span><span class=cFC>RDI</span><span class=cF0>
|
|
<a name="l162"></a> </span><span class=cF1>MOV</span><span class=cF0> </span><span class=cFC>RSI</span><span class=cF0>,</span><span class=cF9>U64</span><span class=cF0> </span><span class=cF3>SF_ARG1</span><span class=cF0>[</span><span class=cFC>RBP</span><span class=cF0>]
|
|
<a name="l163"></a> </span><span class=cF1>MOV</span><span class=cF0> </span><span class=cFC>RDI</span><span class=cF0>,</span><span class=cF9>U64</span><span class=cF0> </span><span class=cF3>SF_ARG2</span><span class=cF0>[</span><span class=cFC>RBP</span><span class=cF0>]
|
|
<a name="l164"></a> </span><span class=cF1>CALL</span><span class=cF0> </span><span class=cFD>SYS_HASH_BUCKET_FIND</span><span class=cF0>
|
|
<a name="l165"></a> </span><span class=cF1>POP</span><span class=cF0> </span><span class=cFC>RDI</span><span class=cF0>
|
|
<a name="l166"></a> </span><span class=cF1>POP</span><span class=cF0> </span><span class=cFC>RSI</span><span class=cF0>
|
|
<a name="l167"></a> </span><span class=cF1>POP</span><span class=cF0> </span><span class=cFC>RBP</span><span class=cF0>
|
|
<a name="l168"></a> </span><span class=cF1>RET1</span><span class=cF0> 16
|
|
<a name="l169"></a></span><span class=cFD>_HASH_ADD</span><span class=cF0>::
|
|
<a name="l170"></a> </span><span class=cF1>PUSH</span><span class=cF0> </span><span class=cFC>RBP</span><span class=cF0>
|
|
<a name="l171"></a> </span><span class=cF1>MOV</span><span class=cF0> </span><span class=cFC>RBP</span><span class=cF0>,</span><span class=cFC>RSP</span><span class=cF0>
|
|
<a name="l172"></a> </span><span class=cF1>PUSH</span><span class=cF0> </span><span class=cFC>RSI</span><span class=cF0>
|
|
<a name="l173"></a> </span><span class=cF1>PUSH</span><span class=cF0> </span><span class=cFC>RDI</span><span class=cF0>
|
|
<a name="l174"></a> </span><span class=cF1>MOV</span><span class=cF0> </span><span class=cFC>RCX</span><span class=cF0>,</span><span class=cF9>U64</span><span class=cF0> </span><span class=cF3>SF_ARG1</span><span class=cF0>[</span><span class=cFC>RBP</span><span class=cF0>]
|
|
<a name="l175"></a> </span><span class=cF1>MOV</span><span class=cF0> </span><span class=cFC>RSI</span><span class=cF0>,</span><span class=cF9>U64</span><span class=cF0> </span><span class=cF9>CHash</span><span class=cF0>.str[</span><span class=cFC>RCX</span><span class=cF0>]
|
|
<a name="l176"></a> </span><span class=cF1>MOV</span><span class=cF0> </span><span class=cFC>RDI</span><span class=cF0>,</span><span class=cF9>U64</span><span class=cF0> </span><span class=cF3>SF_ARG2</span><span class=cF0>[</span><span class=cFC>RBP</span><span class=cF0>]
|
|
<a name="l177"></a> </span><span class=cF1>CALL</span><span class=cF0> </span><span class=cFD>SYS_HASH_BUCKET_FIND</span><span class=cF0>
|
|
<a name="l178"></a> </span><span class=cF1>MOV</span><span class=cF0> </span><span class=cFC>RCX</span><span class=cF0>,</span><span class=cF9>U64</span><span class=cF0> </span><span class=cF3>SF_ARG1</span><span class=cF0>[</span><span class=cFC>RBP</span><span class=cF0>]
|
|
<a name="l179"></a> </span><span class=cF1>PUSHFD</span><span class=cF0>
|
|
<a name="l180"></a> </span><span class=cF1>CLI</span><span class=cF0>
|
|
<a name="l181"></a> </span><span class=cF1>MOV</span><span class=cF0> </span><span class=cFC>RBX</span><span class=cF0>,</span><span class=cF9>U64</span><span class=cF0> [</span><span class=cFC>RAX</span><span class=cF0>]
|
|
<a name="l182"></a> </span><span class=cF1>MOV</span><span class=cF0> </span><span class=cF9>U64</span><span class=cF0> </span><span class=cF9>CHash</span><span class=cF0>.next[</span><span class=cFC>RCX</span><span class=cF0>],</span><span class=cFC>RBX</span><span class=cF0>
|
|
<a name="l183"></a> </span><span class=cF1>MOV</span><span class=cF0> </span><span class=cF9>U64</span><span class=cF0> [</span><span class=cFC>RAX</span><span class=cF0>],</span><span class=cFC>RCX</span><span class=cF0>
|
|
<a name="l184"></a>
|
|
<a name="l185"></a> </span><span class=cF1>POPFD</span><span class=cF0>
|
|
<a name="l186"></a> </span><span class=cF1>POP</span><span class=cF0> </span><span class=cFC>RDI</span><span class=cF0>
|
|
<a name="l187"></a> </span><span class=cF1>POP</span><span class=cF0> </span><span class=cFC>RSI</span><span class=cF0>
|
|
<a name="l188"></a> </span><span class=cF1>POP</span><span class=cF0> </span><span class=cFC>RBP</span><span class=cF0>
|
|
<a name="l189"></a> </span><span class=cF1>RET1</span><span class=cF0> 16
|
|
<a name="l190"></a></span><span class=cFD>_HASH_ADD_AFTER</span><span class=cF0>::
|
|
<a name="l191"></a> </span><span class=cF1>PUSH</span><span class=cF0> </span><span class=cFC>RBP</span><span class=cF0>
|
|
<a name="l192"></a> </span><span class=cF1>MOV</span><span class=cF0> </span><span class=cFC>RBP</span><span class=cF0>,</span><span class=cFC>RSP</span><span class=cF0>
|
|
<a name="l193"></a> </span><span class=cF1>PUSH</span><span class=cF0> </span><span class=cFC>RDI</span><span class=cF0>
|
|
<a name="l194"></a> </span><span class=cF1>MOV</span><span class=cF0> </span><span class=cFC>RCX</span><span class=cF0>,</span><span class=cF9>U64</span><span class=cF0> </span><span class=cF3>SF_ARG1</span><span class=cF0>[</span><span class=cFC>RBP</span><span class=cF0>]
|
|
<a name="l195"></a> </span><span class=cF1>MOV</span><span class=cF0> </span><span class=cFC>RDI</span><span class=cF0>,</span><span class=cF9>U64</span><span class=cF0> </span><span class=cF3>SF_ARG3</span><span class=cF0>[</span><span class=cFC>RBP</span><span class=cF0>]
|
|
<a name="l196"></a> </span><span class=cF1>PUSHFD</span><span class=cF0>
|
|
<a name="l197"></a> </span><span class=cF1>CLI</span><span class=cF0>
|
|
<a name="l198"></a> </span><span class=cF1>MOV</span><span class=cF0> </span><span class=cFC>RAX</span><span class=cF0>,</span><span class=cF3>SF_ARG2</span><span class=cF0>[</span><span class=cFC>RBP</span><span class=cF0>]
|
|
<a name="l199"></a> </span><span class=cF1>MOV</span><span class=cF0> </span><span class=cFC>RBX</span><span class=cF0>,</span><span class=cF9>U64</span><span class=cF0> [</span><span class=cFC>RAX</span><span class=cF0>]
|
|
<a name="l200"></a> </span><span class=cF1>MOV</span><span class=cF0> </span><span class=cF9>U64</span><span class=cF0> </span><span class=cF9>CHash</span><span class=cF0>.next[</span><span class=cFC>RCX</span><span class=cF0>],</span><span class=cFC>RBX</span><span class=cF0>
|
|
<a name="l201"></a> </span><span class=cF1>MOV</span><span class=cF0> </span><span class=cF9>U64</span><span class=cF0> [</span><span class=cFC>RAX</span><span class=cF0>],</span><span class=cFC>RCX</span><span class=cF0>
|
|
<a name="l202"></a>
|
|
<a name="l203"></a> </span><span class=cF1>POPFD</span><span class=cF0>
|
|
<a name="l204"></a> </span><span class=cF1>POP</span><span class=cF0> </span><span class=cFC>RDI</span><span class=cF0>
|
|
<a name="l205"></a> </span><span class=cF1>POP</span><span class=cF0> </span><span class=cFC>RBP</span><span class=cF0>
|
|
<a name="l206"></a> </span><span class=cF1>RET1</span><span class=cF0> 24
|
|
<a name="l207"></a></span><span class=cFD>_HASH_REM_DEL</span><span class=cF0>::
|
|
<a name="l208"></a> </span><span class=cF1>PUSH</span><span class=cF0> </span><span class=cFC>RBP</span><span class=cF0>
|
|
<a name="l209"></a> </span><span class=cF1>MOV</span><span class=cF0> </span><span class=cFC>RBP</span><span class=cF0>,</span><span class=cFC>RSP</span><span class=cF0>
|
|
<a name="l210"></a> </span><span class=cF1>PUSH</span><span class=cF0> </span><span class=cFC>RSI</span><span class=cF0>
|
|
<a name="l211"></a> </span><span class=cF1>PUSH</span><span class=cF0> </span><span class=cFC>RDI</span><span class=cF0>
|
|
<a name="l212"></a> </span><span class=cF1>MOV</span><span class=cF0> </span><span class=cFC>RCX</span><span class=cF0>,</span><span class=cF9>U64</span><span class=cF0> </span><span class=cF3>SF_ARG1</span><span class=cF0>[</span><span class=cFC>RBP</span><span class=cF0>]
|
|
<a name="l213"></a> </span><span class=cF1>TEST</span><span class=cF0> </span><span class=cFC>RCX</span><span class=cF0>,</span><span class=cFC>RCX</span><span class=cF0>
|
|
<a name="l214"></a> </span><span class=cF1>JZ</span><span class=cF0> @@10
|
|
<a name="l215"></a> </span><span class=cF1>MOV</span><span class=cF0> </span><span class=cFC>RSI</span><span class=cF0>,</span><span class=cF9>U64</span><span class=cF0> </span><span class=cF9>CHash</span><span class=cF0>.str[</span><span class=cFC>RCX</span><span class=cF0>]
|
|
<a name="l216"></a> </span><span class=cF1>XOR</span><span class=cF0> </span><span class=cFC>RBX</span><span class=cF0>,</span><span class=cFC>RBX</span><span class=cF0>
|
|
<a name="l217"></a> </span><span class=cF1>MOV</span><span class=cF0> </span><span class=cFC>EBX</span><span class=cF0>,</span><span class=cF9>U32</span><span class=cF0> </span><span class=cF9>CHash</span><span class=cF0>.type[</span><span class=cFC>RCX</span><span class=cF0>]
|
|
<a name="l218"></a> </span><span class=cF1>AND</span><span class=cF0> </span><span class=cFC>EBX</span><span class=cF0>,~</span><span class=cF3>HTG_FLAGS_MASK</span><span class=cF0>&0xFFFFFFFF
|
|
<a name="l219"></a> </span><span class=cF1>MOV</span><span class=cF0> </span><span class=cFC>RDI</span><span class=cF0>,</span><span class=cF9>U64</span><span class=cF0> </span><span class=cF3>SF_ARG2</span><span class=cF0>[</span><span class=cFC>RBP</span><span class=cF0>]
|
|
<a name="l220"></a> </span><span class=cF1>MOV</span><span class=cF0> </span><span class=cFC>RCX</span><span class=cF0>,</span><span class=cF9>U64</span><span class=cF0> </span><span class=cF3>SF_ARG3</span><span class=cF0>[</span><span class=cFC>RBP</span><span class=cF0>]
|
|
<a name="l221"></a> </span><span class=cF1>CALL</span><span class=cF0> </span><span class=cFD>SYS_HASH_STR</span><span class=cF0>
|
|
<a name="l222"></a>
|
|
<a name="l223"></a> </span><span class=cF1>PUSHFD</span><span class=cF0>
|
|
<a name="l224"></a> </span><span class=cF1>CLI</span><span class=cF0>
|
|
<a name="l225"></a> </span><span class=cF1>CALL</span><span class=cF0> </span><span class=cFD>SYS_HASH_SINGLE_TABLE_FIND</span><span class=cF0>
|
|
<a name="l226"></a> </span><span class=cF1>JZ</span><span class=cF0> @@05
|
|
<a name="l227"></a> </span><span class=cF1>CMP</span><span class=cF0> </span><span class=cFC>RAX</span><span class=cF0>,</span><span class=cF9>U64</span><span class=cF0> </span><span class=cF3>SF_ARG1</span><span class=cF0>[</span><span class=cFC>RBP</span><span class=cF0>]
|
|
<a name="l228"></a> </span><span class=cF1>JNE</span><span class=cF0> @@05
|
|
<a name="l229"></a>
|
|
<a name="l230"></a> </span><span class=cF1>MOV</span><span class=cF0> </span><span class=cFC>RBX</span><span class=cF0>,</span><span class=cF9>U64</span><span class=cF0> </span><span class=cF9>CHash</span><span class=cF0>.next[</span><span class=cFC>RAX</span><span class=cF0>]
|
|
<a name="l231"></a> </span><span class=cF1>MOV</span><span class=cF0> </span><span class=cF9>U64</span><span class=cF0> [</span><span class=cFC>RDX</span><span class=cF0>],</span><span class=cFC>RBX</span><span class=cF0>
|
|
<a name="l232"></a>
|
|
<a name="l233"></a> </span><span class=cF1>POPFD</span><span class=cF0>
|
|
<a name="l234"></a>
|
|
<a name="l235"></a> </span><span class=cF3>PUSH_C_REGS</span><span class=cF0>
|
|
<a name="l236"></a> </span><span class=cF1>PUSH</span><span class=cF0> </span><span class=cFC>RAX</span><span class=cF0>
|
|
<a name="l237"></a> </span><span class=cF1>CALL</span><span class=cF0> &</span><span class=cF5>HashDel</span><span class=cF0>
|
|
<a name="l238"></a> </span><span class=cF3>POP_C_REGS</span><span class=cF0>
|
|
<a name="l239"></a>
|
|
<a name="l240"></a> </span><span class=cF1>POP</span><span class=cF0> </span><span class=cFC>RDI</span><span class=cF0>
|
|
<a name="l241"></a> </span><span class=cF1>POP</span><span class=cF0> </span><span class=cFC>RSI</span><span class=cF0>
|
|
<a name="l242"></a> </span><span class=cF1>MOV</span><span class=cF0> </span><span class=cFC>RAX</span><span class=cF0>,1
|
|
<a name="l243"></a> </span><span class=cF1>POP</span><span class=cF0> </span><span class=cFC>RBP</span><span class=cF0>
|
|
<a name="l244"></a> </span><span class=cF1>RET1</span><span class=cF0> 24
|
|
<a name="l245"></a>
|
|
<a name="l246"></a>@@05: </span><span class=cF1>POPFD</span><span class=cF0>
|
|
<a name="l247"></a>@@10: </span><span class=cF1>POP</span><span class=cF0> </span><span class=cFC>RDI</span><span class=cF0>
|
|
<a name="l248"></a> </span><span class=cF1>POP</span><span class=cF0> </span><span class=cFC>RSI</span><span class=cF0>
|
|
<a name="l249"></a> </span><span class=cF1>XOR</span><span class=cF0> </span><span class=cFC>RAX</span><span class=cF0>,</span><span class=cFC>RAX</span><span class=cF0>
|
|
<a name="l250"></a> </span><span class=cF1>POP</span><span class=cF0> </span><span class=cFC>RBP</span><span class=cF0>
|
|
<a name="l251"></a> </span><span class=cF1>RET1</span><span class=cF0> 24
|
|
<a name="l252"></a>}
|
|
<a name="l253"></a>
|
|
<a name="l254"></a></span><span class=cF1>_extern</span><span class=cF0> </span><span class=cFD>_HASH_STR</span><span class=cF0> </span><span class=cF9>I64</span><span class=cF0> </span><span class=cF5>HashStr</span><span class=cF0>(</span><span class=cF1>U8</span><span class=cF0> *st); </span><span class=cF2>//Hash a string.</span><span class=cF0>
|
|
<a name="l255"></a></span><span class=cF1>_extern</span><span class=cF0> </span><span class=cFD>_HASH_FIND</span><span class=cF0> </span><span class=cF9>CHash</span><span class=cF0> *</span><span class=cF5>HashFind</span><span class=cF0>(</span><span class=cF1>U8</span><span class=cF0> *needle_str,</span><span class=cF9>CHashTable</span><span class=cF0> *haystack_table,
|
|
<a name="l256"></a> </span><span class=cF9>I64</span><span class=cF0> mask,</span><span class=cF9>I64</span><span class=cF0> instance=1);</span><span class=cF2>//Find string in hash table.</span><span class=cF0>
|
|
<a name="l257"></a></span><span class=cF1>_extern</span><span class=cF0> </span><span class=cFD>_HASH_SINGLE_TABLE_FIND</span><span class=cF0> </span><span class=cF9>CHash</span><span class=cF0> *</span><span class=cF5>HashSingleTableFind</span><span class=cF0>(</span><span class=cF1>U8</span><span class=cF0> *needle_str,
|
|
<a name="l258"></a> </span><span class=cF9>CHashTable</span><span class=cF0> *haystack_table,
|
|
<a name="l259"></a> </span><span class=cF9>I64</span><span class=cF0> mask,</span><span class=cF9>I64</span><span class=cF0> instance=1);</span><span class=cF2>//Find string in single hash table.</span><span class=cF0>
|
|
<a name="l260"></a></span><span class=cF1>_extern</span><span class=cF0> </span><span class=cFD>_HASH_BUCKET_FIND</span><span class=cF0> </span><span class=cF9>CHash</span><span class=cF0> **</span><span class=cF5>HashBucketFind</span><span class=cF0>(</span><span class=cF1>U8</span><span class=cF0> *needle_str,
|
|
<a name="l261"></a> </span><span class=cF9>CHashTable</span><span class=cF0> *haystack_table); </span><span class=cF2>//Find hash bucket.</span><span class=cF0>
|
|
<a name="l262"></a></span><span class=cF1>_extern</span><span class=cF0> </span><span class=cFD>_HASH_ADD</span><span class=cF0> </span><span class=cF1>U0</span><span class=cF0> </span><span class=cF5>HashAdd</span><span class=cF0>(</span><span class=cF9>CHash</span><span class=cF0> *tmph,
|
|
<a name="l263"></a> </span><span class=cF9>CHashTable</span><span class=cF0> *table); </span><span class=cF2>//Add entry to hash table.</span><span class=cF0>
|
|
<a name="l264"></a></span><span class=cF1>_extern</span><span class=cF0> </span><span class=cFD>_HASH_REM_DEL</span><span class=cF0> </span><span class=cF1>Bool</span><span class=cF0> </span><span class=cF5>HashRemDel</span><span class=cF0>(</span><span class=cF9>CHash</span><span class=cF0> *tmph,</span><span class=cF9>CHashTable</span><span class=cF0> *table,
|
|
<a name="l265"></a> </span><span class=cF9>I64</span><span class=cF0> instance=1);</span><span class=cF2>//Remove hash entry and del. Instance must match.</span><span class=cF0>
|
|
</span></pre></body>
|
|
</html>
|