<?xml version="1.0" encoding="UTF-8" ?><rdf:RDF 
  xmlns="http://purl.org/rss/1.0/"
  xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
  xmlns:atom="http://www.w3.org/2005/Atom"
  xmlns:dc="http://purl.org/dc/elements/1.1/"
  xml:lang="ja">
  <channel rdf:about="http://w.atwiki.jp/makotof/">
    <title>makotof @ ウィキ</title>
    <link>http://w.atwiki.jp/makotof/</link>
    <atom:link href="https://w.atwiki.jp/makotof/rss10.xml" rel="self" type="application/rss+xml" />
    <atom:link rel="hub" href="https://pubsubhubbub.appspot.com" />
    <description>makotof @ ウィキ</description>

    <dc:language>ja</dc:language>
    <dc:date>2009-08-30T19:08:02+09:00</dc:date>
    <utime>1251626882</utime>

    <items>
      <rdf:Seq>
                <rdf:li rdf:resource="https://w.atwiki.jp/makotof/pages/47.html" />
                <rdf:li rdf:resource="https://w.atwiki.jp/makotof/pages/46.html" />
                <rdf:li rdf:resource="https://w.atwiki.jp/makotof/pages/45.html" />
                <rdf:li rdf:resource="https://w.atwiki.jp/makotof/pages/44.html" />
                <rdf:li rdf:resource="https://w.atwiki.jp/makotof/pages/43.html" />
                <rdf:li rdf:resource="https://w.atwiki.jp/makotof/pages/42.html" />
                <rdf:li rdf:resource="https://w.atwiki.jp/makotof/pages/41.html" />
                <rdf:li rdf:resource="https://w.atwiki.jp/makotof/pages/40.html" />
                <rdf:li rdf:resource="https://w.atwiki.jp/makotof/pages/39.html" />
                <rdf:li rdf:resource="https://w.atwiki.jp/makotof/pages/38.html" />
              </rdf:Seq>
    </items>
	
		
    
  </channel>
    <item rdf:about="https://w.atwiki.jp/makotof/pages/47.html">
    <title>入出力</title>
    <link>https://w.atwiki.jp/makotof/pages/47.html</link>
    <description>
      *システムコール
***文字の出力

例)
    mov ah, 02h
    mov dl, 31h
    int 21h

***文字列の出力

例）
    mov ah, 09h
    mov dx, msg  ;出力する文字列の先頭アドレスをDX[[レジスタ]]にセットする
    int 21h

***文字の入力

例)
    mov ah, 08h
    int 21h

[[sample&gt;http://makotof.unfuddle.com/svn/makotof_android/assembler/Assembler101/inpc.asm]]
[[sample&gt;http://makotof.unfuddle.com/svn/makotof_android/assembler/Assembler101/inpch.asm]]

***文字列の入力

例)
    mov ah, 0Ah         ;キーボードからの文字列入力
    mov dx, buf
    mov byte[buf], 20h  ;バッファの長さ
    int 21h

※入力された文字列はバッファの3バイト目以降に入る。バッファの2バイト目には入力された文字列が入る

[[sample&gt;http://makotof.unfuddle.com/svn/makotof_android/assembler/Assembler101/inps.asm]]

***ファイルからの読み込み

例)
    mov dx, sfile    ;DX=ファイル名文字列
    mov al, 0        ;モード(AL:0 = 読み出し, 1 = 書き込み, 2 = 読み書き)
    mov ah, 3Dh      ;ファイルオープンを指定
    int 21h

sfile db &quot;srcfile.txt&quot;, 0  ;ファイル名 (0で終わる文字列)
ファイルが開くとAXレジスタにファイルハンドルが入る

    mov [fh], ax      ;ファイルハンドル

データを読み込むためには、AHレジスタを3FhにしてINT21を実行する
        </description>
    <dc:date>2009-08-30T19:08:02+09:00</dc:date>
    <utime>1251626882</utime>
  </item>
    <item rdf:about="https://w.atwiki.jp/makotof/pages/46.html">
    <title>分岐とサブルーチン</title>
    <link>https://w.atwiki.jp/makotof/pages/46.html</link>
    <description>
      &amp;bold(){ジャンプ}

[[sample&gt;http://makotof.unfuddle.com/svn/makotof_android/assembler/Assembler101/jmp.asm]]

|FAR|異なるコードセグメントの中のコードへジャンプ|
|NEAR|同じコードセグメントの中のコードへのジャンプ|
|SHORT|同じコードセグメントの中の相対オフセットで-128-127バイト以内のコードへのジャンプ|

**条件付きジャンプ (Jcc)

例) cmp dl, 5Bh
    jnz dispchr

[[sample&gt;http://makotof.unfuddle.com/svn/makotof_android/assembler/Assembler101/jnz.asm]]

**JCXZとJECXZ

|JCXZ|CX[[レジスタ]]の内容が0である場合にショートジャンプ|
|JECXZ|ECXレジスタの内容が0である場合にショートジャンプ|

例)
    mov cx, N;
doit:
    dec cx
    jcxz endquit
    jmp doit
endquit:

[[sample&gt;http://makotof.unfuddle.com/svn/makotof_android/assembler/Assembler101/jcxz.asm]]

*ループ

CXレジスタが0であるかどうかという条件のみ

例)
    mov cx, N
doit:
    loop    doit ;CXがゼロでなければdoitにジャンプする

32ビットの場合は、ECXが使われる

[[sample&gt;http://makotof.unfuddle.com/svn/makotof_android/assembler/Assembler101/loop.asm]]

**条件付きループ

|命令|概要|
|LOOPE|等しい(ZF=1)ならば繰り返す|
|LOOPNE|等しくない(ZF=0)ならば繰り返す|
|LOOPNZ|ゼロでない(ZF=0)ならば繰り返す|
|LOOPZ|ゼロ(ZF=1)ならば繰り返す|

例)
    </description>
    <dc:date>2009-08-26T00:39:01+09:00</dc:date>
    <utime>1251214741</utime>
  </item>
    <item rdf:about="https://w.atwiki.jp/makotof/pages/45.html">
    <title>移動命令</title>
    <link>https://w.atwiki.jp/makotof/pages/45.html</link>
    <description>
      &amp;bold(){MOV}
MOV {destinattion} {source}

[[sample&gt;http://makotof.unfuddle.com/svn/makotof_android/assembler/Assembler101/dispstr.asm]]


&amp;bold(){メモリ参照}
mov ax, [bar]     ;アドレスbarにある値をAXに移動する
mov ax, bar       ;値barをAXに移動する
mov eax, [ebp+8]  ;ebp+8にある値をeaxに移動する

※すぐに値が計算できる即値でなければならない

[[sample&gt;http://makotof.unfuddle.com/svn/makotof_android/assembler/Assembler101/ha.asm]]

メモリからメモリへは直接値をコピーできない
ダメな例
mov byte[x], [y]
良い例
mov dl, [y]
mov [x], dl
※通常はMOVSを使う。

また、destination operandにメモリを指定したとき、サイズ単位がわからないので、明示する
ダメな例
mov [x], 8
良い例
mov byte[x], 8
mov word[x], 8

&amp;bold(){XCHG}
source operand &lt;-&gt; destination operandの交換

例
xchg dl, [msg+1]    ;msg+1の内容とdlを交換する
xchg al, ah         ;alとahの内容を交換する

[[sample&gt;http://makotof.unfuddle.com/svn/makotof_android/assembler/Assembler101/xchg.asm]]

&amp;bold(){ポップとプッシュ}

POPで取り出されるデータは
16bitの場合は[SS:SP], 32ビットの値は[SS:ESP]の値

&amp;bold(){PUSHAとPOPA}
すべての汎用[[レジスタ]] AX,CX,DX,BX,SP,BP,SI,DIを連続してスタックにプッシュする
16bit環境では、スタックポ    </description>
    <dc:date>2009-08-25T02:16:02+09:00</dc:date>
    <utime>1251134162</utime>
  </item>
    <item rdf:about="https://w.atwiki.jp/makotof/pages/44.html">
    <title>レジスタ</title>
    <link>https://w.atwiki.jp/makotof/pages/44.html</link>
    <description>
      &amp;bold(){汎用レジスタ}

|AX|accumulator register|データの一時記憶、各種演算|
|BX|base address register|特定のメモリを指定するポインタ|
|CX|count register|繰り返し処理命令の回数を数えるカウンタ|
|DX|data register|データの一時記憶。AXと組み合わせて剰余算|

AH-AL, BH-BL, CH-CL, DH-DL

&amp;bold(){セグメントレジスタ}
|CS|Code Segment|命令コードのあるセグメントアドレスを保存|
|DS|Data Segment|データのあるセグメントアドレスを保存|
|ES|Extra Segment|第2のデータセグメントアドレスを保存|
|SS|Stack Segment|スタックセグメントアドレスを保存|

※8ビット以下のCPUやセグメントを使わない設計のCPUには、セグメントレジスタはない

&amp;bold(){特殊目的}
|SI|Source Index|メモリを指すポインタ|
|DI|Destination Index|メモリを指すポインタ|
|BP|Base Pointer|プログラムスタックを管理するポインタ|
|SP|Stack Pointer| スタックセグメントで使うベースポインタ |
|IP|Instruction Pointer|次に実行する命令のオフセットアドレスを保存|

使用例:
BP, プロシージャの中で、パラメートとローカル変数にアクセス
SI, DI SIを転送元アドレス、DIを転送先アドレスとして、間接的にメモリにアクセスしたりする

&amp;bold(){フラグレジスタ}
|OF|Overflow Flag|符号付き演算で桁あふれが生じるとセットされる|
|DF|Direction Flag|ストリング操作命令でポインタの増減を表す|
|IF|Interrupt Flag|リセットすると外部割り込みを受け付けなくなる|
|TF|Trace Flag|トレースで実行するときのフラグ|
|SF|Sign Flag|演算結果が負になるとセットされる|
|ZF|Zero Flag|演算結果がゼロになるか、比較で一致するとセットされる|
    </description>
    <dc:date>2009-08-25T01:33:32+09:00</dc:date>
    <utime>1251131612</utime>
  </item>
    <item rdf:about="https://w.atwiki.jp/makotof/pages/43.html">
    <title>基本</title>
    <link>https://w.atwiki.jp/makotof/pages/43.html</link>
    <description>
      ニブル: 4ビット単位 16進数の1桁で表現できる数
バイト: 8ビット単位 16進数の2桁
ワード: 2バイト, 16ビット
ダブルワード: 4バイト, 32ビット

リトルエンディアン: 下位の桁からメモリに保存する
ビッグエンディアン: 上位の桁からメモリに保存する

[[レジスタ]]
[[移動命令]]
[[分岐とサブルーチン]]
[[入出力]]    </description>
    <dc:date>2009-08-26T22:32:48+09:00</dc:date>
    <utime>1251293568</utime>
  </item>
    <item rdf:about="https://w.atwiki.jp/makotof/pages/42.html">
    <title>Assembler</title>
    <link>https://w.atwiki.jp/makotof/pages/42.html</link>
    <description>
      [[基本]]    </description>
    <dc:date>2009-08-25T01:16:27+09:00</dc:date>
    <utime>1251130587</utime>
  </item>
    <item rdf:about="https://w.atwiki.jp/makotof/pages/41.html">
    <title>Android</title>
    <link>https://w.atwiki.jp/makotof/pages/41.html</link>
    <description>
      [[3D Animation]]    </description>
    <dc:date>2009-06-20T17:15:00+09:00</dc:date>
    <utime>1245485700</utime>
  </item>
    <item rdf:about="https://w.atwiki.jp/makotof/pages/40.html">
    <title>Understanding Microsoft&#039;s SharePoint Server 2007 Development Plan</title>
    <link>https://w.atwiki.jp/makotof/pages/40.html</link>
    <description>
      &amp;bold(){Plan Integration}

Business Data Catalog
Excel Services
Microsoft Office Forms Server
Microsoft Search Server
Microsoft ForeFront Security for [[SharePoint]]
Microsoft Office Groove Server 2007
Incoming e-mail

&amp;bold(){その他}

Microsoft Office ProjectServer 2007
Microsoft Office Project Portfolio Server
Microsoft Office Communications Server 2007
Microsoft Office PerformancePoint Server 2007    </description>
    <dc:date>2008-11-20T20:41:17+09:00</dc:date>
    <utime>1227181277</utime>
  </item>
    <item rdf:about="https://w.atwiki.jp/makotof/pages/39.html">
    <title>Business Requirements</title>
    <link>https://w.atwiki.jp/makotof/pages/39.html</link>
    <description>
      &amp;bold(){Business Reguirements}

-&gt; Lower Order
-&gt; Speed up Product Time
-&gt; Improve Communications with regional offices
-&gt; Improve order-to-ship times
-&gt; Expand into overseas markets

&amp;bold(){Function Requirements}

Recude the number of order-entry screens from five to two
Pre-populate key information, such as customer identification and address, automatically
Change a form from fill-in-the-blank to pick-list data entry
Provide better training to order-entry personnel to reduce the learning curve    </description>
    <dc:date>2008-11-20T20:24:30+09:00</dc:date>
    <utime>1227180270</utime>
  </item>
    <item rdf:about="https://w.atwiki.jp/makotof/pages/38.html">
    <title>Summary</title>
    <link>https://w.atwiki.jp/makotof/pages/38.html</link>
    <description>
      Implement in an iterative fashion
Incrementally grow your solution
Gather requirements
Involve your users
Train your people
Test your theories
Have design reviews
Document, document, document    </description>
    <dc:date>2008-11-20T19:55:37+09:00</dc:date>
    <utime>1227178537</utime>
  </item>
  </rdf:RDF>
