changeset 0:6abb63b73e47

add
author Miyagi Mitsuki <e135756@ie.u-ryukyu.ac.jp>
date Fri, 21 Oct 2016 22:41:40 +0900
parents
children 45bc92a01821
files Makefile dummy.tex midterm.aux midterm.dvi midterm.log midterm.pdf midterm.tex pic/codesegment.bb pic/codesegment.pdf pic/emblem-bitmap.pdf pic/llvmProcess.graffle pic/llvmProcess.pdf picins.sty
diffstat 13 files changed, 2408 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Makefile	Fri Oct 21 22:41:40 2016 +0900
@@ -0,0 +1,36 @@
+# Created by Daichi Toma on Nov 16, 2011
+
+TARGET=midterm
+
+LATEX=platex
+BIBTEX=pbibtex
+DVIPDF=dvipdfmx -p a4
+#You need setting "-l" option if You think You get a landscape PDF
+#DVIPDF_OPT=-l
+
+#Embed fonts
+#DVIPDF_OPT=-f hiraginoEmbed.map
+
+.SUFFIXES: .tex .dvi .pdf
+
+.tex.dvi:
+	$(LATEX) $<
+	#$(BIBTEX) $(TARGET)
+	$(LATEX) $<
+	$(LATEX) $<
+
+.dvi.pdf:
+	$(DVIPDF) $(DVIPDF_OPT) $<
+
+
+all: $(TARGET).pdf
+	open $(TARGET).pdf
+
+dvi: $(TARGET).dvi
+
+pdf: $(TARGET).pdf
+
+
+clean:
+	rm -f *.dvi *.aux *.log *.pdf *.ps *.gz *.bbl *.blg *.toc *~ *.core
+
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/dummy.tex	Fri Oct 21 22:41:40 2016 +0900
@@ -0,0 +1,60 @@
+%%% jdummy.def
+%
+\DeclareRelationFont{JY1}{mc}{it}{}{OT1}{cmr}{it}{}
+\DeclareRelationFont{JT1}{mc}{it}{}{OT1}{cmr}{it}{}
+\DeclareFontShape{JY1}{mc}{m}{it}{<5> <6> <7> <8> <9> <10> sgen*min
+    <10.95><12><14.4><17.28><20.74><24.88> min10
+    <-> min10}{}
+\DeclareFontShape{JT1}{mc}{m}{it}{<5> <6> <7> <8> <9> <10> sgen*tmin
+    <10.95><12><14.4><17.28><20.74><24.88> tmin10
+    <-> tmin10}{}
+\DeclareRelationFont{JY1}{mc}{sl}{}{OT1}{cmr}{sl}{}
+\DeclareRelationFont{JT1}{mc}{sl}{}{OT1}{cmr}{sl}{}
+\DeclareFontShape{JY1}{mc}{m}{sl}{<5> <6> <7> <8> <9> <10> sgen*min
+    <10.95><12><14.4><17.28><20.74><24.88> min10
+    <-> min10}{}
+\DeclareFontShape{JT1}{mc}{m}{sl}{<5> <6> <7> <8> <9> <10> sgen*tmin
+    <10.95><12><14.4><17.28><20.74><24.88> tmin10
+    <-> tmin10}{}
+\DeclareRelationFont{JY1}{mc}{sc}{}{OT1}{cmr}{sc}{}
+\DeclareRelationFont{JT1}{mc}{sc}{}{OT1}{cmr}{sc}{}
+\DeclareFontShape{JY1}{mc}{m}{sc}{<5> <6> <7> <8> <9> <10> sgen*min
+    <10.95><12><14.4><17.28><20.74><24.88> min10
+    <-> min10}{}
+\DeclareFontShape{JT1}{mc}{m}{sc}{<5> <6> <7> <8> <9> <10> sgen*tmin
+    <10.95><12><14.4><17.28><20.74><24.88> tmin10
+    <-> tmin10}{}
+\DeclareRelationFont{JY1}{gt}{it}{}{OT1}{cmbx}{it}{}
+\DeclareRelationFont{JT1}{gt}{it}{}{OT1}{cmbx}{it}{}
+\DeclareFontShape{JY1}{mc}{bx}{it}{<5> <6> <7> <8> <9> <10> sgen*goth
+    <10.95><12><14.4><17.28><20.74><24.88> goth10
+    <-> goth10}{}
+\DeclareFontShape{JT1}{mc}{bx}{it}{<5> <6> <7> <8> <9> <10> sgen*tgoth
+    <10.95><12><14.4><17.28><20.74><24.88> tgoth10
+    <-> tgoth10}{}
+\DeclareRelationFont{JY1}{gt}{sl}{}{OT1}{cmbx}{sl}{}
+\DeclareRelationFont{JT1}{gt}{sl}{}{OT1}{cmbx}{sl}{}
+\DeclareFontShape{JY1}{mc}{bx}{sl}{<5> <6> <7> <8> <9> <10> sgen*goth
+    <10.95><12><14.4><17.28><20.74><24.88> goth10
+    <-> goth10}{}
+\DeclareFontShape{JT1}{mc}{bx}{sl}{<5> <6> <7> <8> <9> <10> sgen*tgoth
+    <10.95><12><14.4><17.28><20.74><24.88> tgoth10
+    <-> tgoth10}{}
+\DeclareRelationFont{JY1}{gt}{sc}{}{OT1}{cmbx}{sc}{}
+\DeclareRelationFont{JT1}{gt}{sc}{}{OT1}{cmbx}{sc}{}
+\DeclareFontShape{JY1}{mc}{bx}{sc}{<5> <6> <7> <8> <9> <10> sgen*goth
+    <10.95><12><14.4><17.28><20.74><24.88> goth10
+    <-> goth10}{}
+\DeclareFontShape{JT1}{mc}{bx}{sc}{<5> <6> <7> <8> <9> <10> sgen*tgoth
+    <10.95><12><14.4><17.28><20.74><24.88> tgoth10
+    <-> tgoth10}{}
+\DeclareRelationFont{JY1}{gt}{it}{}{OT1}{cmr}{it}{}
+\DeclareRelationFont{JT1}{gt}{it}{}{OT1}{cmr}{it}{}
+\DeclareFontShape{JY1}{gt}{m}{it}{<5> <6> <7> <8> <9> <10> sgen*goth
+    <10.95><12><14.4><17.28><20.74><24.88> goth10
+    <-> goth10}{}
+\DeclareFontShape{JT1}{gt}{m}{it}{<5> <6> <7> <8> <9> <10> sgen*tgoth
+    <10.95><12><14.4><17.28><20.74><24.88> tgoth10
+    <-> tgoth10}{}
+\endinput
+%%%% end of jdummy.def
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/midterm.aux	Fri Oct 21 22:41:40 2016 +0900
@@ -0,0 +1,17 @@
+\relax 
+\@writefile{toc}{\contentsline {section}{\numberline {1}研究目的}{1}}
+\@writefile{toc}{\contentsline {section}{\numberline {2}Continuation based C (CbC)}{1}}
+\@writefile{lof}{\contentsline {figure}{\numberline {1}{\ignorespaces gotoによる Code Segment 間の接続}}{1}}
+\newlabel{fig:codesegment}{{1}{1}}
+\@writefile{toc}{\contentsline {section}{\numberline {3}LLVM/clang}{1}}
+\@writefile{lof}{\contentsline {figure}{\numberline {2}{\ignorespaces LLVM の 処理過程}}{2}}
+\newlabel{fig:llvmProcess}{{2}{2}}
+\@writefile{toc}{\contentsline {section}{\numberline {4}LLVM/clang のリファクタリング}{2}}
+\@writefile{toc}{\contentsline {section}{\numberline {5}Gears OS の構文サポート}{2}}
+\bibcite{1}{1}
+\bibcite{2}{2}
+\bibcite{3}{3}
+\bibcite{4}{4}
+\bibcite{5}{5}
+\bibcite{6}{6}
+\@writefile{toc}{\contentsline {section}{\numberline {6}今後の課題}{3}}
Binary file midterm.dvi has changed
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/midterm.log	Fri Oct 21 22:41:40 2016 +0900
@@ -0,0 +1,187 @@
+This is pTeX, Version 3.141592-p3.1.10 (utf8.euc) (Web2C 7.5.4) (format=platex 2012.6.18)  21 OCT 2016 22:33
+**midterm.tex
+(./midterm.tex
+pLaTeX2e <2006/11/10>+0 (based on LaTeX2e <2003/12/01> patch level 0)
+(/usr/local/share/texmf/ptex/platex/base/jarticle.cls
+Document Class: jarticle 2006/06/27 v1.6 Standard pLaTeX class
+\c@@paper=\count81
+(/usr/local/share/texmf/ptex/platex/base/jsize10.clo
+File: jsize10.clo 2006/06/27 v1.6 Standard pLaTeX file (size option)
+)
+\c@part=\count82
+\c@section=\count83
+\c@subsection=\count84
+\c@subsubsection=\count85
+\c@paragraph=\count86
+\c@subparagraph=\count87
+\c@figure=\count88
+\c@table=\count89
+\abovecaptionskip=\skip41
+\belowcaptionskip=\skip42
+\symmincho=\mathgroup4
+LaTeX Font Info:    Overwriting symbol font `mincho' in version `bold'
+(Font)                  JY1/mc/m/n --> JY1/gt/m/n on input line 601.
+\toclineskip=\dimen118
+\@lnumwidth=\dimen119
+\bibindent=\dimen120
+\heisei=\count90
+)
+(/usr/local/share/texmf-dist/tex/latex/graphics/graphicx.sty
+Package: graphicx 1999/02/16 v1.0f Enhanced LaTeX Graphics (DPC,SPQR)
+
+(/usr/local/share/texmf-dist/tex/latex/graphics/keyval.sty
+Package: keyval 1999/03/16 v1.13 key=value parser (DPC)
+\KV@toks@=\toks15
+)
+(/usr/local/share/texmf/tex/latex/graphics/dvipdfmx-contrib-latex/graphics.sty
+Package: graphics 2001/07/07 v1.0n Standard LaTeX Graphics (DPC,SPQR)
+
+(/usr/local/share/texmf-dist/tex/latex/graphics/trig.sty
+Package: trig 1999/03/16 v1.09 sin cos tan (DPC)
+)
+(/usr/local/share/texmf-dist/tex/latex/graphics/graphics.cfg
+File: graphics.cfg 2005/02/03 v1.3 graphics configuration of teTeX/TeXLive
+)
+Package graphics Info: Driver file: dvipdfmx.def on input line 81.
+
+(/usr/local/share/texmf/tex/latex/graphics/dvipdfmx-contrib-latex/dvipdfmx.def
+File: dvipdfmx.def 1999/02/16 v3.0i Driver-dependant file (DPC,SPQR)
+))
+\Gin@req@height=\dimen121
+\Gin@req@width=\dimen122
+) (./picins.sty Option `picins' Version 3.0 Sep. 1992, TH Darmstadt/HRZ
+\@BILD=\box41
+\@TEXT=\box42
+\d@breite=\dimen123
+\d@hoehe=\dimen124
+\d@xoff=\dimen125
+\d@yoff=\dimen126
+\d@shad=\dimen127
+\d@dash=\dimen128
+\d@boxl=\dimen129
+\d@pichskip=\dimen130
+\d@tmp=\dimen131
+\d@tmpa=\dimen132
+\d@bskip=\dimen133
+\hsiz@=\dimen134
+\p@getot@l=\dimen135
+\c@breite=\count91
+\c@hoehe=\count92
+\c@xoff=\count93
+\c@yoff=\count94
+\c@pos=\count95
+\c@shad=\count96
+\c@dash=\count97
+\c@boxl=\count98
+\c@zeilen=\count99
+\@changemode=\count100
+\c@piccaption=\count101
+\c@piccaptionpos=\count102
+\c@picpos=\count103
+\c@whole=\count104
+\c@half=\count105
+\c@tmp=\count106
+\c@tmpa=\count107
+\c@tmpb=\count108
+\c@tmpc=\count109
+\c@tmpd=\count110
+\d@leftskip=\skip43
+\ptoti=\dimen136
+\ptotii=\dimen137
+\env@box=\box43
+\d@envdp=\dimen138
+\c@hsize=\count111
+\c@envdp=\count112
+\d@envb=\dimen139
+)
+(/usr/local/share/texmf-dist/tex/latex/fancyhdr/fancyhdr.sty
+\fancy@headwidth=\skip44
+\f@ncyO@elh=\skip45
+\f@ncyO@erh=\skip46
+\f@ncyO@olh=\skip47
+\f@ncyO@orh=\skip48
+\f@ncyO@elf=\skip49
+\f@ncyO@erf=\skip50
+\f@ncyO@olf=\skip51
+\f@ncyO@orf=\skip52
+) (./dummy.tex)
+
+LaTeX Warning: Unused global option(s):
+    [9.5pt].
+
+(./midterm.aux)
+\openout1 = `midterm.aux'.
+
+LaTeX Font Info:    Checking defaults for OML/cmm/m/it on input line 21.
+LaTeX Font Info:    ... okay on input line 21.
+LaTeX Font Info:    Checking defaults for T1/cmr/m/n on input line 21.
+LaTeX Font Info:    ... okay on input line 21.
+LaTeX Font Info:    Checking defaults for OT1/cmr/m/n on input line 21.
+LaTeX Font Info:    ... okay on input line 21.
+LaTeX Font Info:    Checking defaults for OMS/cmsy/m/n on input line 21.
+LaTeX Font Info:    ... okay on input line 21.
+LaTeX Font Info:    Checking defaults for OMX/cmex/m/n on input line 21.
+LaTeX Font Info:    ... okay on input line 21.
+LaTeX Font Info:    Checking defaults for U/cmr/m/n on input line 21.
+LaTeX Font Info:    ... okay on input line 21.
+LaTeX Font Info:    Checking defaults for JY1/mc/m/n on input line 21.
+LaTeX Font Info:    ... okay on input line 21.
+LaTeX Font Info:    Checking defaults for JT1/mc/m/n on input line 21.
+LaTeX Font Info:    ... okay on input line 21.
+LaTeX Font Info:    External font `cmex10' loaded for size
+(Font)              <12> on input line 25.
+LaTeX Font Info:    External font `cmex10' loaded for size
+(Font)              <8> on input line 25.
+LaTeX Font Info:    External font `cmex10' loaded for size
+(Font)              <6> on input line 25.
+LaTeX Font Info:    Font shape `JT1/mc/bx/n' in size <14.4> not available
+(Font)              Font shape `JT1/gt/m/n' tried instead on input line 28.
+LaTeX Font Info:    Font shape `JY1/mc/bx/n' in size <14.4> not available
+(Font)              Font shape `JY1/gt/m/n' tried instead on input line 28.
+File: pic/codesegment.pdf Graphic file (type eps)
+ <pic/codesegment.pdf>
+Underfull \hbox (badness 6445) in paragraph at lines 78--79
+[]\OT1/cmr/m/n/10 clang \JY1/mc/m/n/10 は \OT1/cmr/m/n/10 LLVM \JY1/mc/m/n/10 
+をバ ッ クエンドとして利用する
+ []
+
+File: pic/emblem-bitmap.pdf Graphic file (type eps)
+<pic/emblem-bitmap.pdf>
+
+Package Fancyhdr Warning: \headheight is too small (0.0pt): 
+ Make it at least 20.37784pt.
+ We now make it that large for the rest of the document.
+ This may cause the page layout to be inconsistent, however.
+
+[1
+
+
+]
+LaTeX Font Info:    Font shape `JT1/mc/bx/n' in size <10> not available
+(Font)              Font shape `JT1/gt/m/n' tried instead on input line 88.
+LaTeX Font Info:    Font shape `JY1/mc/bx/n' in size <10> not available
+(Font)              Font shape `JY1/gt/m/n' tried instead on input line 88.
+
+Underfull \hbox (badness 10000) in paragraph at lines 88--88
+[]\OT1/cmr/bx/n/10 SelectionDAG In-struc-tion Se-lec-tion (Se-lec-
+ []
+
+File: pic/llvmProcess.pdf Graphic file (type eps)
+<pic/llvmProcess.pdf>
+Overfull \hbox (3.57736pt too wide) in paragraph at lines 103--104
+ [][] 
+ []
+
+[2] [3
+
+] (./midterm.aux) ) 
+Here is how much of TeX's memory you used:
+ 870 strings out of 94681
+ 9774 string characters out of 1169859
+ 66291 words of memory out of 1500000
+ 4192 multiletter control sequences out of 10000+50000
+ 13396 words of font info for 52 fonts, out of 1200000 for 2000
+ 566 hyphenation exceptions out of 8191
+ 25i,15n,43p,250b,521s stack positions out of 5000i,500n,6000p,200000b,5000s
+
+Output written on midterm.dvi (3 pages, 15796 bytes).
Binary file midterm.pdf has changed
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/midterm.tex	Fri Oct 21 22:41:40 2016 +0900
@@ -0,0 +1,149 @@
+\documentclass[twocolumn,twoside,9.5pt]{jarticle}
+\usepackage[dvipdfmx]{graphicx}
+\usepackage{picins}
+\usepackage{fancyhdr}
+%\pagestyle{fancy}
+\lhead{\parpic{\includegraphics[height=1zw,keepaspectratio,bb=0 0 251 246]{pic/emblem-bitmap.pdf}}琉球大学主催 工学部情報工学科 中間発表予稿}
+\rhead{}
+\cfoot{}
+
+\setlength{\topmargin}{-1in \addtolength{\topmargin}{15mm}}
+\setlength{\headheight}{0mm}
+\setlength{\headsep}{5mm}
+\setlength{\oddsidemargin}{-1in \addtolength{\oddsidemargin}{11mm}}
+\setlength{\evensidemargin}{-1in \addtolength{\evensidemargin}{21mm}}
+\setlength{\textwidth}{181mm}
+\setlength{\textheight}{261mm}
+\setlength{\footskip}{0mm}
+\pagestyle{empty}
+
+\input{dummy.tex}
+\begin{document}
+\title{LLVM/clang 上の CbC コンパイラの改良と Gears OS サポート}
+\author{135756F 氏名 宮城光希 {}{} 指導教員 : 河野 真治}
+\date{}
+\maketitle
+\thispagestyle{fancy} 
+
+\section{研究目的}
+プログラムを記述する際に通常の処理の他に、メモリ管理、スレッドの待ち合わせやネットワークの管理、エラーハンドリング等、記述しなければならない処理が存在する。これらの計算を Meta Computation と呼ぶ。
+
+Meta Computation を通常の計算から切り離して記述するためには処理を細かく分割する必要がある。しかし、関数やクラスなどの単位は容易に分割できない。
+
+そこで当研究室では Meta Computation を柔軟に記述するためのプログラミング言語の単位として Code Segment、Data Segment という単位を提案している。  
+
+Code Segment は関数に比べて細かく分割されているので Meta Computation をより柔軟に記述できる。
+
+Code Segment、Data Segment にはそれぞれメタレベルの単位である Meta Code Segment、Meta Data Segment が存在し、これらを用いて Meta Computation を実現する。
+
+また、処理を Code Segment、データを Data Segment とした単位を用いたプログラミング言語 Continuation based C (CbC)を開発している。
+
+CbCは軽量継続による遷移を行うので、継続前の Code Segment に戻ることはなく、状態遷移ベースのプログラミングに適している。
+
+CbCと同様に処理を Code Gear、データを Data Gear とした単位を用いた並列実行をサポートした Gears OS も開発している。 Gears OS は CbC で記述されている。
+
+本研究では、LLVM/clang 上での CbC コンパイラの改良と Gears OS の構文のサポートを行う。
+\section{Continuation based C (CbC)}
+CbC では C の関数の代わりに Code Segment を用いて処理を記述している。
+
+Code Segment の宣言は C の関数の構文と同様に記述し、型に \_\_code を使うことで宣言できる。
+
+Code Segment は C の関数と異なり戻り値を持たず、 Code Segment 間の移動は goto の後に Code Segment 名と引数を並べて記述する独自の構文を用いて行う。
+
+この goto による処理の遷移を継続と呼ぶ。図\ref{fig:codesegment} は Code Segment 間の処理の流れを表している。
+
+\begin{figure}[htpb]
+    \centering
+    \includegraphics[width=70mm]{pic/codesegment.pdf}
+    \caption{gotoによる Code Segment 間の接続}
+    \label{fig:codesegment}
+\end{figure}
+
+C では関数呼び出しを行う際、現在までの位置を環境として保持するが、戻り値を持たない Code Segment は呼び出し元の環境を保持しない。
+ここで環境とは現在のスタックの状態のことを指す。このように呼び出し元の環境を持たない継続を軽量継続と呼ぶ。
+軽量継続によって、並列化、ループ制御、関数コールといったスタックを意識した最適化がソースコードレベルで行うことができる。
+
+しかし CbC と C の記述を交える際、CbC の code segment から C の関数への呼び出しは問題なく行えるが、逆の場合呼び出し元の環境に戻るための特殊な継続が必要となる。これを環境付き継続とよぶ。
+
+環境付き継続を用いる場合 C の関数から code segment へ接続する際に \_\_return、\_\_environment という変数を渡す。
+\section{LLVM/clang}
+LLVM とは、モジュラー構成および再利用可能なコンパイラとツールチェーン技術等を開発するプロジェクトの名称である。
+単に LLVM といった場合は LLVM Core のことを指す。以降は本文でも単に LLVM といった場合は LLVM Core のことを指す。 
+
+LLVM はコンパイラ基盤であり、コンパイラのバックエンド部分の処理を行う。
+LLVM IR や LLVM BitCode と呼ばれる独自の中間言語を持ち、それを機械語や実行可能なファイルに変換することができる。また、この言語で書かれたプログラムを実行するための仮想機械としても動作する。
+
+LLVM のフロントエンドはターゲットの言語を LLVM IR に変換することによって LLVM の最適化機構を利用することができる。
+
+clang は LLVM をバックエンドとして利用する C/C++/Objective-C のコンパイラである。
+
+フロントエンドとして clang を使用し、与えられたコードから LLVM IRを生成し、LLVM はこれを最適化し機械語に変換を行う。
+
+LLVM は LLVM IR を直接的にターゲットのアセンブリ言語へ変換を行うわけではなく、中間表現を何度か変えその度に最適化を行い、最終的にターゲットのアセンブリ言語に変換する。
+
+LLVMでは、最適化や中間表現の変換といったコンパイラを構成する処理は全てpassが行う。多くの pass は最適化のために存在し、この pass を組み合わせることにより、LLVM の持つ機能の中から任意のものを利用することができる。
+
+LLVM ターゲットのアセンブリ言語を生成するまでの過程を記すと以下のようになる。
+  
+\subsubsection*{SelectionDAG Instruction Selection (SelectionDAGISel)}
+    LLVM IR を SelectionDAG (DAG は Directed Acycric Graph の意) に変換し、最適化を行う。その後 Machine Code を生成する。
+\subsubsection*{SSA-based Machine Code Optimizations}
+    SSA-based Machine Code に対する最適化を行う。各最適化はそれぞれ独立した pass になっている。
+\subsubsection*{Register Allocation}
+    仮装レジスタから物理レジスタへの割り当てを行う。ここで PHI 命令が削除され、SSA-based でなくなる。
+\subsubsection*{Prolog/Epilog Code Insertion}
+    Prolog/Epilog Code の挿入を行う。どちらも関数呼び出しに関わるものであり、Prolog は関数を呼び出す際に呼び出す関数のためのスタックフレームを準備する処理、Epilog は呼び出し元の関数に戻る際に行う処理である。
+\subsubsection*{Late Machine Code Optimizations}
+    Machine Code に対してさらに最適化を行う。
+\subsubsection*{Code Emission}
+    Machine Code を MC Layer での表現に変換する。その後さらにターゲットのアセンブリ言語へ変換し、その出力を行う。
+
+\begin{figure}[ht]
+    \centering
+    \includegraphics[width=90mm]{pic/llvmProcess.pdf}
+    \caption{LLVM の 処理過程}
+    \label{fig:llvmProcess}
+\end{figure}
+
+\section{LLVM/clang のリファクタリング}
+LLVM/clang で CbC をコンパイルした際 Code Segment 内の局所変数でポインタを参照すると tail call されないという不具合があることがわかった。
+
+局所変数でポインタを参照していると clang は生成する LLVM IR に オブジェクトの寿命を示す lifetime.start と lifetime.end を書き出す。
+
+ここでオブジェクトの lifetime の終わりを示す lifetime.end が tail call の後に書き出されてしまうことにより、tail call の際に局所変数が解放されておらず lifetime が残っているので tail call が無視されてしまう。
+
+しかしCbC では継続を行った後、継続前の Code Segment に戻ることはないので局所変数の解放は継続前に行っても良い。
+そこで lifetime.end を tail call の直前で生成を行うことで tail call を出すようにした。
+
+\section{Gears OS の構文サポート}
+Gears OS では並列実行するための Task を実行する Code Gear と実行に必要な Input Data Gear 、出力される Output Data Gear の組で表現する。
+Input/Output Data Gear によって依存関係が決定し並列実行を行う。
+
+Gears OS では Meta Computation を Meta Code Gear、Meta Data Gear で表現する。Meta Code Gear は通常の Code Gear の直後に遷移され、Meta Computation を実行する。
+
+CbC では処理を Code Segment を用いたプログラミング言語であるため、 Gears OS の Code Gear を記述するのに適している。
+そこで Gears OS の構文のサポートを CbC を用いて行う。
+
+Gears OS では Context という接続可能な Code/Data Gear のリスト、TaskQueue へのポインタ、Persistent Data Tree へのポインタ、Temporal Dara Gear である。Gears OS では必要な Code/Data Gear に参照したい場合、Context を通す必要がある。
+
+Context は膨大であるためプログラマが記述するには負担であるため CbC では Context の自動生成を行うようにする。
+
+\section{今後の課題}
+本研究では LLVM/clang によるコンパイルの際、Code Segment 内の局所変数で tail call が出ない不具合を修正した。今後の課題としては、まだ Gears OS の構文サポートの実装が行われていないのでこれを実装することが優先される。
+
+\begin{thebibliography}{9}
+    \bibitem{1}
+        徳森 海斗 : LLVM Clang 上の Continuation based C コンパイラ の改良,
+    \bibitem{2}
+        伊波立樹, 東恩納琢偉, 河野真治 : Code Gear、 Data Gear に基づく OS のプロトタイプ, 情報処理学会システムソフトウェアとオペレーティング・システム研究会(OS)(2016).
+    \bibitem{3}    
+        大城 信康, 河野真治 : Continuation based C の GCC 4.6 上の実装について, 第53回プログラミング・シンポジウム(2012)
+    \bibitem{4}
+        与儀健人, 河野真治 : Continuation based c コンパイラの gcc-4.2 による実装, 情報処理学会システムソフトウェアとオペレーティング・システム研究会(OS)(2008).
+    \bibitem{5}
+        The LLVM Compiler Infrastructure
+    \bibitem{6}
+        LLVM Language Reference Manual
+
+\end{thebibliography}
+\end{document}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/pic/codesegment.bb	Fri Oct 21 22:41:40 2016 +0900
@@ -0,0 +1,5 @@
+%%Title: pic/codesegment.pdf
+%%Creator: extractbb 20150315
+%%BoundingBox: 0 0 393 201
+%%CreationDate: Thu Oct 29 22:24:58 2015
+
Binary file pic/codesegment.pdf has changed
Binary file pic/emblem-bitmap.pdf has changed
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/pic/llvmProcess.graffle	Fri Oct 21 22:41:40 2016 +0900
@@ -0,0 +1,1376 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
+<plist version="1.0">
+<dict>
+	<key>ActiveLayerIndex</key>
+	<integer>0</integer>
+	<key>ApplicationVersion</key>
+	<array>
+		<string>com.omnigroup.OmniGraffle</string>
+		<string>139.18.0.187838</string>
+	</array>
+	<key>AutoAdjust</key>
+	<true/>
+	<key>BackgroundGraphic</key>
+	<dict>
+		<key>Bounds</key>
+		<string>{{0, 0}, {1118.4000244140625, 782.79998779296875}}</string>
+		<key>Class</key>
+		<string>SolidGraphic</string>
+		<key>ID</key>
+		<integer>2</integer>
+		<key>Style</key>
+		<dict>
+			<key>shadow</key>
+			<dict>
+				<key>Draws</key>
+				<string>NO</string>
+			</dict>
+			<key>stroke</key>
+			<dict>
+				<key>Draws</key>
+				<string>NO</string>
+			</dict>
+		</dict>
+	</dict>
+	<key>BaseZoom</key>
+	<integer>0</integer>
+	<key>CanvasOrigin</key>
+	<string>{0, 0}</string>
+	<key>ColumnAlign</key>
+	<integer>1</integer>
+	<key>ColumnSpacing</key>
+	<real>36</real>
+	<key>CreationDate</key>
+	<string>2014-02-08 13:48:07 +0000</string>
+	<key>Creator</key>
+	<string>utah</string>
+	<key>DisplayScale</key>
+	<string>1 0/72 in = 1.0000 in</string>
+	<key>GraphDocumentVersion</key>
+	<integer>8</integer>
+	<key>GraphicsList</key>
+	<array>
+		<dict>
+			<key>Class</key>
+			<string>LineGraphic</string>
+			<key>FontInfo</key>
+			<dict>
+				<key>Font</key>
+				<string>Helvetica</string>
+				<key>Size</key>
+				<real>14</real>
+			</dict>
+			<key>ID</key>
+			<integer>48</integer>
+			<key>OrthogonalBarAutomatic</key>
+			<true/>
+			<key>OrthogonalBarPoint</key>
+			<string>{0, 0}</string>
+			<key>OrthogonalBarPosition</key>
+			<real>-1</real>
+			<key>Points</key>
+			<array>
+				<string>{801, 99}</string>
+				<string>{810, 100}</string>
+				<string>{172, 178}</string>
+				<string>{144, 198}</string>
+			</array>
+			<key>Style</key>
+			<dict>
+				<key>stroke</key>
+				<dict>
+					<key>HeadArrow</key>
+					<string>FilledArrow</string>
+					<key>Legacy</key>
+					<true/>
+					<key>LineType</key>
+					<integer>2</integer>
+					<key>TailArrow</key>
+					<string>0</string>
+				</dict>
+			</dict>
+		</dict>
+		<dict>
+			<key>Class</key>
+			<string>LineGraphic</string>
+			<key>FontInfo</key>
+			<dict>
+				<key>Font</key>
+				<string>Helvetica</string>
+				<key>Size</key>
+				<real>14</real>
+			</dict>
+			<key>ID</key>
+			<integer>47</integer>
+			<key>OrthogonalBarAutomatic</key>
+			<true/>
+			<key>OrthogonalBarPoint</key>
+			<string>{0, 0}</string>
+			<key>OrthogonalBarPosition</key>
+			<real>-1</real>
+			<key>Points</key>
+			<array>
+				<string>{819, 225}</string>
+				<string>{873, 225}</string>
+			</array>
+			<key>Style</key>
+			<dict>
+				<key>stroke</key>
+				<dict>
+					<key>HeadArrow</key>
+					<string>FilledArrow</string>
+					<key>Legacy</key>
+					<true/>
+					<key>LineType</key>
+					<integer>2</integer>
+					<key>TailArrow</key>
+					<string>0</string>
+				</dict>
+			</dict>
+		</dict>
+		<dict>
+			<key>Bounds</key>
+			<string>{{873, 198}, {81, 54}}</string>
+			<key>Class</key>
+			<string>ShapedGraphic</string>
+			<key>FontInfo</key>
+			<dict>
+				<key>Font</key>
+				<string>Helvetica</string>
+				<key>Size</key>
+				<real>16</real>
+			</dict>
+			<key>HFlip</key>
+			<string>YES</string>
+			<key>ID</key>
+			<integer>46</integer>
+			<key>Magnets</key>
+			<array>
+				<string>{1, 0.5}</string>
+				<string>{1, -0.5}</string>
+				<string>{-1, 0.5}</string>
+				<string>{-1, -0.5}</string>
+				<string>{0.5, 1}</string>
+				<string>{-0.5, 1}</string>
+				<string>{0.5, -1}</string>
+				<string>{-0.5, -1}</string>
+			</array>
+			<key>Shape</key>
+			<string>Rectangle</string>
+			<key>Style</key>
+			<dict>
+				<key>fill</key>
+				<dict>
+					<key>Color</key>
+					<dict>
+						<key>b</key>
+						<string>0.999991</string>
+						<key>g</key>
+						<string>0.999974</string>
+						<key>r</key>
+						<string>1</string>
+					</dict>
+				</dict>
+				<key>shadow</key>
+				<dict>
+					<key>Draws</key>
+					<string>NO</string>
+				</dict>
+				<key>stroke</key>
+				<dict>
+					<key>Draws</key>
+					<string>NO</string>
+				</dict>
+			</dict>
+			<key>Text</key>
+			<dict>
+				<key>Text</key>
+				<string>{\rtf1\ansi\ansicpg1252\cocoartf1265
+\cocoascreenfonts1{\fonttbl\f0\fswiss\fcharset0 Helvetica;}
+{\colortbl;\red255\green255\blue255;}
+\pard\tx560\tx1120\tx1680\tx2240\tx2800\tx3360\tx3920\tx4480\tx5040\tx5600\tx6160\tx6720\pardirnatural\qc
+
+\f0\fs32 \cf0 Assembly\
+Code}</string>
+				<key>VerticalPad</key>
+				<integer>0</integer>
+			</dict>
+		</dict>
+		<dict>
+			<key>Class</key>
+			<string>LineGraphic</string>
+			<key>FontInfo</key>
+			<dict>
+				<key>Font</key>
+				<string>Helvetica</string>
+				<key>Size</key>
+				<real>14</real>
+			</dict>
+			<key>ID</key>
+			<integer>45</integer>
+			<key>OrthogonalBarAutomatic</key>
+			<true/>
+			<key>OrthogonalBarPoint</key>
+			<string>{0, 0}</string>
+			<key>OrthogonalBarPosition</key>
+			<real>-1</real>
+			<key>Points</key>
+			<array>
+				<string>{666, 225}</string>
+				<string>{720, 225}</string>
+			</array>
+			<key>Style</key>
+			<dict>
+				<key>stroke</key>
+				<dict>
+					<key>HeadArrow</key>
+					<string>FilledArrow</string>
+					<key>Legacy</key>
+					<true/>
+					<key>LineType</key>
+					<integer>2</integer>
+					<key>TailArrow</key>
+					<string>0</string>
+				</dict>
+			</dict>
+		</dict>
+		<dict>
+			<key>Bounds</key>
+			<string>{{729, 198}, {81, 54}}</string>
+			<key>Class</key>
+			<string>ShapedGraphic</string>
+			<key>FontInfo</key>
+			<dict>
+				<key>Font</key>
+				<string>Helvetica</string>
+				<key>Size</key>
+				<real>14</real>
+			</dict>
+			<key>HFlip</key>
+			<string>YES</string>
+			<key>ID</key>
+			<integer>44</integer>
+			<key>Magnets</key>
+			<array>
+				<string>{1, 0.5}</string>
+				<string>{1, -0.5}</string>
+				<string>{-1, 0.5}</string>
+				<string>{-1, -0.5}</string>
+				<string>{0.5, 1}</string>
+				<string>{-0.5, 1}</string>
+				<string>{0.5, -1}</string>
+				<string>{-0.5, -1}</string>
+			</array>
+			<key>Shape</key>
+			<string>Rectangle</string>
+			<key>Style</key>
+			<dict>
+				<key>fill</key>
+				<dict>
+					<key>Color</key>
+					<dict>
+						<key>b</key>
+						<string>0.999991</string>
+						<key>g</key>
+						<string>0.999974</string>
+						<key>r</key>
+						<string>1</string>
+					</dict>
+				</dict>
+			</dict>
+			<key>Text</key>
+			<dict>
+				<key>Text</key>
+				<string>{\rtf1\ansi\ansicpg1252\cocoartf1265
+\cocoascreenfonts1{\fonttbl\f0\fswiss\fcharset0 Helvetica;}
+{\colortbl;\red255\green255\blue255;}
+\pard\tx560\tx1120\tx1680\tx2240\tx2800\tx3360\tx3920\tx4480\tx5040\tx5600\tx6160\tx6720\pardirnatural\qc
+
+\f0\fs28 \cf0 Code Emission}</string>
+				<key>VerticalPad</key>
+				<integer>0</integer>
+			</dict>
+		</dict>
+		<dict>
+			<key>Class</key>
+			<string>LineGraphic</string>
+			<key>FontInfo</key>
+			<dict>
+				<key>Font</key>
+				<string>Helvetica</string>
+				<key>Size</key>
+				<real>14</real>
+			</dict>
+			<key>ID</key>
+			<integer>39</integer>
+			<key>OrthogonalBarAutomatic</key>
+			<true/>
+			<key>OrthogonalBarPoint</key>
+			<string>{0, 0}</string>
+			<key>OrthogonalBarPosition</key>
+			<real>-1</real>
+			<key>Points</key>
+			<array>
+				<string>{333, 225}</string>
+				<string>{387, 225}</string>
+			</array>
+			<key>Style</key>
+			<dict>
+				<key>stroke</key>
+				<dict>
+					<key>HeadArrow</key>
+					<string>FilledArrow</string>
+					<key>Legacy</key>
+					<true/>
+					<key>LineType</key>
+					<integer>2</integer>
+					<key>TailArrow</key>
+					<string>0</string>
+				</dict>
+			</dict>
+		</dict>
+		<dict>
+			<key>Bounds</key>
+			<string>{{252, 198}, {81, 54}}</string>
+			<key>Class</key>
+			<string>ShapedGraphic</string>
+			<key>FontInfo</key>
+			<dict>
+				<key>Font</key>
+				<string>Helvetica</string>
+				<key>Size</key>
+				<real>16</real>
+			</dict>
+			<key>HFlip</key>
+			<string>YES</string>
+			<key>ID</key>
+			<integer>38</integer>
+			<key>Magnets</key>
+			<array>
+				<string>{1, 0.5}</string>
+				<string>{1, -0.5}</string>
+				<string>{-1, 0.5}</string>
+				<string>{-1, -0.5}</string>
+				<string>{0.5, 1}</string>
+				<string>{-0.5, 1}</string>
+				<string>{0.5, -1}</string>
+				<string>{-0.5, -1}</string>
+			</array>
+			<key>Shape</key>
+			<string>Rectangle</string>
+			<key>Style</key>
+			<dict>
+				<key>fill</key>
+				<dict>
+					<key>Color</key>
+					<dict>
+						<key>b</key>
+						<string>0.999991</string>
+						<key>g</key>
+						<string>0.999974</string>
+						<key>r</key>
+						<string>1</string>
+					</dict>
+				</dict>
+				<key>shadow</key>
+				<dict>
+					<key>Draws</key>
+					<string>NO</string>
+				</dict>
+				<key>stroke</key>
+				<dict>
+					<key>Draws</key>
+					<string>NO</string>
+				</dict>
+			</dict>
+			<key>Text</key>
+			<dict>
+				<key>Text</key>
+				<string>{\rtf1\ansi\ansicpg1252\cocoartf1265
+\cocoascreenfonts1{\fonttbl\f0\fswiss\fcharset0 Helvetica;}
+{\colortbl;\red255\green255\blue255;}
+\pard\tx560\tx1120\tx1680\tx2240\tx2800\tx3360\tx3920\tx4480\tx5040\tx5600\tx6160\tx6720\pardirnatural\qc
+
+\f0\fs32 \cf0 Machine Code}</string>
+				<key>VerticalPad</key>
+				<integer>0</integer>
+			</dict>
+		</dict>
+		<dict>
+			<key>Class</key>
+			<string>LineGraphic</string>
+			<key>FontInfo</key>
+			<dict>
+				<key>Font</key>
+				<string>Helvetica</string>
+				<key>Size</key>
+				<real>14</real>
+			</dict>
+			<key>ID</key>
+			<integer>34</integer>
+			<key>OrthogonalBarAutomatic</key>
+			<true/>
+			<key>OrthogonalBarPoint</key>
+			<string>{0, 0}</string>
+			<key>OrthogonalBarPosition</key>
+			<real>-1</real>
+			<key>Points</key>
+			<array>
+				<string>{495, 225}</string>
+				<string>{549, 225}</string>
+			</array>
+			<key>Style</key>
+			<dict>
+				<key>stroke</key>
+				<dict>
+					<key>HeadArrow</key>
+					<string>FilledArrow</string>
+					<key>Legacy</key>
+					<true/>
+					<key>LineType</key>
+					<integer>2</integer>
+					<key>TailArrow</key>
+					<string>0</string>
+				</dict>
+			</dict>
+		</dict>
+		<dict>
+			<key>Bounds</key>
+			<string>{{558, 198}, {99, 54}}</string>
+			<key>Class</key>
+			<string>ShapedGraphic</string>
+			<key>FontInfo</key>
+			<dict>
+				<key>Font</key>
+				<string>Helvetica</string>
+				<key>Size</key>
+				<real>14</real>
+			</dict>
+			<key>HFlip</key>
+			<string>YES</string>
+			<key>ID</key>
+			<integer>33</integer>
+			<key>Magnets</key>
+			<array>
+				<string>{1, 0.5}</string>
+				<string>{1, -0.5}</string>
+				<string>{-1, 0.5}</string>
+				<string>{-1, -0.5}</string>
+				<string>{0.5, 1}</string>
+				<string>{-0.5, 1}</string>
+				<string>{0.5, -1}</string>
+				<string>{-0.5, -1}</string>
+			</array>
+			<key>Shape</key>
+			<string>Rectangle</string>
+			<key>Style</key>
+			<dict>
+				<key>fill</key>
+				<dict>
+					<key>Color</key>
+					<dict>
+						<key>b</key>
+						<string>0.999991</string>
+						<key>g</key>
+						<string>0.999974</string>
+						<key>r</key>
+						<string>1</string>
+					</dict>
+				</dict>
+			</dict>
+			<key>Text</key>
+			<dict>
+				<key>Text</key>
+				<string>{\rtf1\ansi\ansicpg1252\cocoartf1265
+\cocoascreenfonts1{\fonttbl\f0\fswiss\fcharset0 Helvetica;}
+{\colortbl;\red255\green255\blue255;}
+\pard\tx560\tx1120\tx1680\tx2240\tx2800\tx3360\tx3920\tx4480\tx5040\tx5600\tx6160\tx6720\pardirnatural\qc
+
+\f0\fs28 \cf0 Late Machine Code optimizations}</string>
+				<key>VerticalPad</key>
+				<integer>0</integer>
+			</dict>
+		</dict>
+		<dict>
+			<key>Bounds</key>
+			<string>{{396, 198}, {90, 54}}</string>
+			<key>Class</key>
+			<string>ShapedGraphic</string>
+			<key>FontInfo</key>
+			<dict>
+				<key>Font</key>
+				<string>Helvetica</string>
+				<key>Size</key>
+				<real>14</real>
+			</dict>
+			<key>HFlip</key>
+			<string>YES</string>
+			<key>ID</key>
+			<integer>32</integer>
+			<key>Magnets</key>
+			<array>
+				<string>{1, 0.5}</string>
+				<string>{1, -0.5}</string>
+				<string>{-1, 0.5}</string>
+				<string>{-1, -0.5}</string>
+				<string>{0.5, 1}</string>
+				<string>{-0.5, 1}</string>
+				<string>{0.5, -1}</string>
+				<string>{-0.5, -1}</string>
+			</array>
+			<key>Shape</key>
+			<string>Rectangle</string>
+			<key>Style</key>
+			<dict>
+				<key>fill</key>
+				<dict>
+					<key>Color</key>
+					<dict>
+						<key>b</key>
+						<string>0.999991</string>
+						<key>g</key>
+						<string>0.999974</string>
+						<key>r</key>
+						<string>1</string>
+					</dict>
+				</dict>
+			</dict>
+			<key>Text</key>
+			<dict>
+				<key>Text</key>
+				<string>{\rtf1\ansi\ansicpg1252\cocoartf1265
+\cocoascreenfonts1{\fonttbl\f0\fswiss\fcharset0 Helvetica;}
+{\colortbl;\red255\green255\blue255;}
+\pard\tx560\tx1120\tx1680\tx2240\tx2800\tx3360\tx3920\tx4480\tx5040\tx5600\tx6160\tx6720\pardirnatural\qc
+
+\f0\fs28 \cf0 Prolog/Epilog Code Insertion}</string>
+				<key>VerticalPad</key>
+				<integer>0</integer>
+			</dict>
+		</dict>
+		<dict>
+			<key>Bounds</key>
+			<string>{{99, 198}, {90, 54}}</string>
+			<key>Class</key>
+			<string>ShapedGraphic</string>
+			<key>FontInfo</key>
+			<dict>
+				<key>Font</key>
+				<string>Helvetica</string>
+				<key>Size</key>
+				<real>14</real>
+			</dict>
+			<key>HFlip</key>
+			<string>YES</string>
+			<key>ID</key>
+			<integer>26</integer>
+			<key>Magnets</key>
+			<array>
+				<string>{1, 0.5}</string>
+				<string>{1, -0.5}</string>
+				<string>{-1, 0.5}</string>
+				<string>{-1, -0.5}</string>
+				<string>{0.5, 1}</string>
+				<string>{-0.5, 1}</string>
+				<string>{0.5, -1}</string>
+				<string>{-0.5, -1}</string>
+			</array>
+			<key>Shape</key>
+			<string>Rectangle</string>
+			<key>Style</key>
+			<dict>
+				<key>fill</key>
+				<dict>
+					<key>Color</key>
+					<dict>
+						<key>b</key>
+						<string>0.999991</string>
+						<key>g</key>
+						<string>0.999974</string>
+						<key>r</key>
+						<string>1</string>
+					</dict>
+				</dict>
+			</dict>
+			<key>Text</key>
+			<dict>
+				<key>Text</key>
+				<string>{\rtf1\ansi\ansicpg1252\cocoartf1265
+\cocoascreenfonts1{\fonttbl\f0\fswiss\fcharset0 Helvetica;}
+{\colortbl;\red255\green255\blue255;}
+\pard\tx560\tx1120\tx1680\tx2240\tx2800\tx3360\tx3920\tx4480\tx5040\tx5600\tx6160\tx6720\pardirnatural\qc
+
+\f0\fs28 \cf0 Register\
+Allocation}</string>
+				<key>VerticalPad</key>
+				<integer>0</integer>
+			</dict>
+		</dict>
+		<dict>
+			<key>Class</key>
+			<string>LineGraphic</string>
+			<key>FontInfo</key>
+			<dict>
+				<key>Font</key>
+				<string>Helvetica</string>
+				<key>Size</key>
+				<real>14</real>
+			</dict>
+			<key>ID</key>
+			<integer>25</integer>
+			<key>OrthogonalBarAutomatic</key>
+			<true/>
+			<key>OrthogonalBarPoint</key>
+			<string>{0, 0}</string>
+			<key>OrthogonalBarPosition</key>
+			<real>-1</real>
+			<key>Points</key>
+			<array>
+				<string>{198, 225}</string>
+				<string>{252, 225}</string>
+			</array>
+			<key>Style</key>
+			<dict>
+				<key>stroke</key>
+				<dict>
+					<key>HeadArrow</key>
+					<string>FilledArrow</string>
+					<key>Legacy</key>
+					<true/>
+					<key>LineType</key>
+					<integer>2</integer>
+					<key>TailArrow</key>
+					<string>0</string>
+				</dict>
+			</dict>
+		</dict>
+		<dict>
+			<key>Class</key>
+			<string>LineGraphic</string>
+			<key>FontInfo</key>
+			<dict>
+				<key>Font</key>
+				<string>Helvetica</string>
+				<key>Size</key>
+				<real>14</real>
+			</dict>
+			<key>ID</key>
+			<integer>24</integer>
+			<key>OrthogonalBarAutomatic</key>
+			<true/>
+			<key>OrthogonalBarPoint</key>
+			<string>{0, 0}</string>
+			<key>OrthogonalBarPosition</key>
+			<real>-1</real>
+			<key>Points</key>
+			<array>
+				<string>{630, 99}</string>
+				<string>{684, 99}</string>
+			</array>
+			<key>Style</key>
+			<dict>
+				<key>stroke</key>
+				<dict>
+					<key>HeadArrow</key>
+					<string>FilledArrow</string>
+					<key>Legacy</key>
+					<true/>
+					<key>LineType</key>
+					<integer>2</integer>
+					<key>TailArrow</key>
+					<string>0</string>
+				</dict>
+			</dict>
+		</dict>
+		<dict>
+			<key>Bounds</key>
+			<string>{{549, 72}, {81, 54}}</string>
+			<key>Class</key>
+			<string>ShapedGraphic</string>
+			<key>FontInfo</key>
+			<dict>
+				<key>Font</key>
+				<string>Helvetica</string>
+				<key>Size</key>
+				<real>14</real>
+			</dict>
+			<key>HFlip</key>
+			<string>YES</string>
+			<key>ID</key>
+			<integer>23</integer>
+			<key>Magnets</key>
+			<array>
+				<string>{1, 0.5}</string>
+				<string>{1, -0.5}</string>
+				<string>{-1, 0.5}</string>
+				<string>{-1, -0.5}</string>
+				<string>{0.5, 1}</string>
+				<string>{-0.5, 1}</string>
+				<string>{0.5, -1}</string>
+				<string>{-0.5, -1}</string>
+			</array>
+			<key>Shape</key>
+			<string>Rectangle</string>
+			<key>Style</key>
+			<dict>
+				<key>fill</key>
+				<dict>
+					<key>Color</key>
+					<dict>
+						<key>b</key>
+						<string>0.999991</string>
+						<key>g</key>
+						<string>0.999974</string>
+						<key>r</key>
+						<string>1</string>
+					</dict>
+				</dict>
+				<key>shadow</key>
+				<dict>
+					<key>Draws</key>
+					<string>NO</string>
+				</dict>
+				<key>stroke</key>
+				<dict>
+					<key>Draws</key>
+					<string>NO</string>
+				</dict>
+			</dict>
+			<key>Text</key>
+			<dict>
+				<key>Text</key>
+				<string>{\rtf1\ansi\ansicpg1252\cocoartf1265
+\cocoascreenfonts1{\fonttbl\f0\fswiss\fcharset0 Helvetica;}
+{\colortbl;\red255\green255\blue255;}
+\pard\tx560\tx1120\tx1680\tx2240\tx2800\tx3360\tx3920\tx4480\tx5040\tx5600\tx6160\tx6720\pardirnatural\qc
+
+\f0\fs28 \cf0 SSA-based\
+Machine Code}</string>
+				<key>VerticalPad</key>
+				<integer>0</integer>
+			</dict>
+		</dict>
+		<dict>
+			<key>Class</key>
+			<string>LineGraphic</string>
+			<key>FontInfo</key>
+			<dict>
+				<key>Font</key>
+				<string>Helvetica</string>
+				<key>Size</key>
+				<real>14</real>
+			</dict>
+			<key>ID</key>
+			<integer>21</integer>
+			<key>OrthogonalBarAutomatic</key>
+			<true/>
+			<key>OrthogonalBarPoint</key>
+			<string>{0, 0}</string>
+			<key>OrthogonalBarPosition</key>
+			<real>-1</real>
+			<key>Points</key>
+			<array>
+				<string>{468, 99}</string>
+				<string>{522, 99}</string>
+			</array>
+			<key>Style</key>
+			<dict>
+				<key>stroke</key>
+				<dict>
+					<key>HeadArrow</key>
+					<string>FilledArrow</string>
+					<key>Legacy</key>
+					<true/>
+					<key>LineType</key>
+					<integer>2</integer>
+					<key>TailArrow</key>
+					<string>0</string>
+				</dict>
+			</dict>
+		</dict>
+		<dict>
+			<key>Class</key>
+			<string>LineGraphic</string>
+			<key>FontInfo</key>
+			<dict>
+				<key>Font</key>
+				<string>Helvetica</string>
+				<key>Size</key>
+				<real>14</real>
+			</dict>
+			<key>ID</key>
+			<integer>20</integer>
+			<key>OrthogonalBarAutomatic</key>
+			<true/>
+			<key>OrthogonalBarPoint</key>
+			<string>{0, 0}</string>
+			<key>OrthogonalBarPosition</key>
+			<real>-1</real>
+			<key>Points</key>
+			<array>
+				<string>{297, 99}</string>
+				<string>{351, 99}</string>
+			</array>
+			<key>Style</key>
+			<dict>
+				<key>stroke</key>
+				<dict>
+					<key>HeadArrow</key>
+					<string>FilledArrow</string>
+					<key>Legacy</key>
+					<true/>
+					<key>LineType</key>
+					<integer>2</integer>
+					<key>TailArrow</key>
+					<string>0</string>
+				</dict>
+			</dict>
+		</dict>
+		<dict>
+			<key>Bounds</key>
+			<string>{{216, 72}, {81, 54}}</string>
+			<key>Class</key>
+			<string>ShapedGraphic</string>
+			<key>FontInfo</key>
+			<dict>
+				<key>Font</key>
+				<string>Helvetica</string>
+				<key>Size</key>
+				<real>16</real>
+			</dict>
+			<key>HFlip</key>
+			<string>YES</string>
+			<key>ID</key>
+			<integer>19</integer>
+			<key>Magnets</key>
+			<array>
+				<string>{1, 0.5}</string>
+				<string>{1, -0.5}</string>
+				<string>{-1, 0.5}</string>
+				<string>{-1, -0.5}</string>
+				<string>{0.5, 1}</string>
+				<string>{-0.5, 1}</string>
+				<string>{0.5, -1}</string>
+				<string>{-0.5, -1}</string>
+			</array>
+			<key>Shape</key>
+			<string>Rectangle</string>
+			<key>Style</key>
+			<dict>
+				<key>fill</key>
+				<dict>
+					<key>Color</key>
+					<dict>
+						<key>b</key>
+						<string>0.999991</string>
+						<key>g</key>
+						<string>0.999974</string>
+						<key>r</key>
+						<string>1</string>
+					</dict>
+				</dict>
+				<key>shadow</key>
+				<dict>
+					<key>Draws</key>
+					<string>NO</string>
+				</dict>
+				<key>stroke</key>
+				<dict>
+					<key>Draws</key>
+					<string>NO</string>
+				</dict>
+			</dict>
+			<key>Text</key>
+			<dict>
+				<key>Text</key>
+				<string>{\rtf1\ansi\ansicpg1252\cocoartf1265
+\cocoascreenfonts1{\fonttbl\f0\fswiss\fcharset0 Helvetica;}
+{\colortbl;\red255\green255\blue255;}
+\pard\tx560\tx1120\tx1680\tx2240\tx2800\tx3360\tx3920\tx4480\tx5040\tx5600\tx6160\tx6720\pardirnatural\qc
+
+\f0\fs32 \cf0 Selection\
+DAG}</string>
+				<key>VerticalPad</key>
+				<integer>0</integer>
+			</dict>
+		</dict>
+		<dict>
+			<key>Bounds</key>
+			<string>{{693, 72}, {99, 54}}</string>
+			<key>Class</key>
+			<string>ShapedGraphic</string>
+			<key>FontInfo</key>
+			<dict>
+				<key>Font</key>
+				<string>Helvetica</string>
+				<key>Size</key>
+				<real>14</real>
+			</dict>
+			<key>HFlip</key>
+			<string>YES</string>
+			<key>ID</key>
+			<integer>18</integer>
+			<key>Magnets</key>
+			<array>
+				<string>{1, 0.5}</string>
+				<string>{1, -0.5}</string>
+				<string>{-1, 0.5}</string>
+				<string>{-1, -0.5}</string>
+				<string>{0.5, 1}</string>
+				<string>{-0.5, 1}</string>
+				<string>{0.5, -1}</string>
+				<string>{-0.5, -1}</string>
+			</array>
+			<key>Shape</key>
+			<string>Rectangle</string>
+			<key>Style</key>
+			<dict>
+				<key>fill</key>
+				<dict>
+					<key>Color</key>
+					<dict>
+						<key>b</key>
+						<string>0.999991</string>
+						<key>g</key>
+						<string>0.999974</string>
+						<key>r</key>
+						<string>1</string>
+					</dict>
+				</dict>
+			</dict>
+			<key>Text</key>
+			<dict>
+				<key>Text</key>
+				<string>{\rtf1\ansi\ansicpg1252\cocoartf1265
+\cocoascreenfonts1{\fonttbl\f0\fswiss\fcharset0 Helvetica;}
+{\colortbl;\red255\green255\blue255;}
+\pard\tx560\tx1120\tx1680\tx2240\tx2800\tx3360\tx3920\tx4480\tx5040\tx5600\tx6160\tx6720\pardirnatural\qc
+
+\f0\fs28 \cf0 Machine Code\
+optimizations}</string>
+				<key>VerticalPad</key>
+				<integer>0</integer>
+			</dict>
+		</dict>
+		<dict>
+			<key>Bounds</key>
+			<string>{{274.5, 27.5}, {168.5, 19}}</string>
+			<key>Class</key>
+			<string>ShapedGraphic</string>
+			<key>FitText</key>
+			<string>Vertical</string>
+			<key>Flow</key>
+			<string>Resize</string>
+			<key>FontInfo</key>
+			<dict>
+				<key>Font</key>
+				<string>Helvetica</string>
+				<key>Size</key>
+				<real>16</real>
+			</dict>
+			<key>ID</key>
+			<integer>30</integer>
+			<key>Shape</key>
+			<string>Rectangle</string>
+			<key>Style</key>
+			<dict>
+				<key>shadow</key>
+				<dict>
+					<key>Draws</key>
+					<string>NO</string>
+				</dict>
+				<key>stroke</key>
+				<dict>
+					<key>Draws</key>
+					<string>NO</string>
+				</dict>
+			</dict>
+			<key>Text</key>
+			<dict>
+				<key>Pad</key>
+				<integer>0</integer>
+				<key>Text</key>
+				<string>{\rtf1\ansi\ansicpg1252\cocoartf1265
+\cocoascreenfonts1{\fonttbl\f0\fswiss\fcharset0 Helvetica;}
+{\colortbl;\red255\green255\blue255;}
+\pard\tx560\tx1120\tx1680\tx2240\tx2800\tx3360\tx3920\tx4480\tx5040\tx5600\tx6160\tx6720\pardirnatural\qc
+
+\f0\fs32 \cf0 SelectionDAGISel}</string>
+				<key>VerticalPad</key>
+				<integer>0</integer>
+			</dict>
+		</dict>
+		<dict>
+			<key>Bounds</key>
+			<string>{{360, 72}, {99, 54}}</string>
+			<key>Class</key>
+			<string>ShapedGraphic</string>
+			<key>FontInfo</key>
+			<dict>
+				<key>Font</key>
+				<string>Helvetica</string>
+				<key>Size</key>
+				<real>14</real>
+			</dict>
+			<key>HFlip</key>
+			<string>YES</string>
+			<key>ID</key>
+			<integer>29</integer>
+			<key>Magnets</key>
+			<array>
+				<string>{1, 0.5}</string>
+				<string>{1, -0.5}</string>
+				<string>{-1, 0.5}</string>
+				<string>{-1, -0.5}</string>
+				<string>{0.5, 1}</string>
+				<string>{-0.5, 1}</string>
+				<string>{0.5, -1}</string>
+				<string>{-0.5, -1}</string>
+			</array>
+			<key>Shape</key>
+			<string>Rectangle</string>
+			<key>Style</key>
+			<dict>
+				<key>fill</key>
+				<dict>
+					<key>Color</key>
+					<dict>
+						<key>b</key>
+						<string>0.999991</string>
+						<key>g</key>
+						<string>0.999974</string>
+						<key>r</key>
+						<string>1</string>
+					</dict>
+				</dict>
+			</dict>
+			<key>Text</key>
+			<dict>
+				<key>Text</key>
+				<string>{\rtf1\ansi\ansicpg1252\cocoartf1265
+\cocoascreenfonts1{\fonttbl\f0\fswiss\fcharset0 Helvetica;}
+{\colortbl;\red255\green255\blue255;}
+\pard\tx560\tx1120\tx1680\tx2240\tx2800\tx3360\tx3920\tx4480\tx5040\tx5600\tx6160\tx6720\pardirnatural\qc
+
+\f0\fs28 \cf0 DAG\
+optimizations}</string>
+				<key>VerticalPad</key>
+				<integer>0</integer>
+			</dict>
+		</dict>
+		<dict>
+			<key>Class</key>
+			<string>LineGraphic</string>
+			<key>FontInfo</key>
+			<dict>
+				<key>Font</key>
+				<string>Helvetica</string>
+				<key>Size</key>
+				<real>14</real>
+			</dict>
+			<key>ID</key>
+			<integer>9</integer>
+			<key>OrthogonalBarAutomatic</key>
+			<true/>
+			<key>OrthogonalBarPoint</key>
+			<string>{0, 0}</string>
+			<key>OrthogonalBarPosition</key>
+			<real>-1</real>
+			<key>Points</key>
+			<array>
+				<string>{126, 99}</string>
+				<string>{180, 99}</string>
+			</array>
+			<key>Style</key>
+			<dict>
+				<key>stroke</key>
+				<dict>
+					<key>HeadArrow</key>
+					<string>FilledArrow</string>
+					<key>Legacy</key>
+					<true/>
+					<key>LineType</key>
+					<integer>2</integer>
+					<key>TailArrow</key>
+					<string>0</string>
+				</dict>
+			</dict>
+		</dict>
+		<dict>
+			<key>Bounds</key>
+			<string>{{207, 36}, {324, 126}}</string>
+			<key>Class</key>
+			<string>ShapedGraphic</string>
+			<key>FontInfo</key>
+			<dict>
+				<key>Font</key>
+				<string>Helvetica</string>
+				<key>Size</key>
+				<real>14</real>
+			</dict>
+			<key>HFlip</key>
+			<string>YES</string>
+			<key>ID</key>
+			<integer>31</integer>
+			<key>Magnets</key>
+			<array>
+				<string>{1, 0.5}</string>
+				<string>{1, -0.5}</string>
+				<string>{-1, 0.5}</string>
+				<string>{-1, -0.5}</string>
+				<string>{0.5, 1}</string>
+				<string>{-0.5, 1}</string>
+				<string>{0.5, -1}</string>
+				<string>{-0.5, -1}</string>
+			</array>
+			<key>Shape</key>
+			<string>Rectangle</string>
+			<key>Style</key>
+			<dict>
+				<key>fill</key>
+				<dict>
+					<key>Color</key>
+					<dict>
+						<key>b</key>
+						<string>0.999991</string>
+						<key>g</key>
+						<string>0.999974</string>
+						<key>r</key>
+						<string>1</string>
+					</dict>
+				</dict>
+			</dict>
+			<key>Text</key>
+			<dict>
+				<key>VerticalPad</key>
+				<integer>0</integer>
+			</dict>
+		</dict>
+		<dict>
+			<key>Bounds</key>
+			<string>{{54, 72}, {72, 54}}</string>
+			<key>Class</key>
+			<string>ShapedGraphic</string>
+			<key>FontInfo</key>
+			<dict>
+				<key>Font</key>
+				<string>Helvetica</string>
+				<key>Size</key>
+				<real>16</real>
+			</dict>
+			<key>HFlip</key>
+			<string>YES</string>
+			<key>ID</key>
+			<integer>3</integer>
+			<key>Magnets</key>
+			<array>
+				<string>{1, 0.5}</string>
+				<string>{1, -0.5}</string>
+				<string>{-1, 0.5}</string>
+				<string>{-1, -0.5}</string>
+				<string>{0.5, 1}</string>
+				<string>{-0.5, 1}</string>
+				<string>{0.5, -1}</string>
+				<string>{-0.5, -1}</string>
+			</array>
+			<key>Shape</key>
+			<string>Rectangle</string>
+			<key>Style</key>
+			<dict>
+				<key>fill</key>
+				<dict>
+					<key>Color</key>
+					<dict>
+						<key>b</key>
+						<string>0.999991</string>
+						<key>g</key>
+						<string>0.999974</string>
+						<key>r</key>
+						<string>1</string>
+					</dict>
+				</dict>
+				<key>shadow</key>
+				<dict>
+					<key>Draws</key>
+					<string>NO</string>
+				</dict>
+				<key>stroke</key>
+				<dict>
+					<key>Draws</key>
+					<string>NO</string>
+				</dict>
+			</dict>
+			<key>Text</key>
+			<dict>
+				<key>Text</key>
+				<string>{\rtf1\ansi\ansicpg1252\cocoartf1265
+\cocoascreenfonts1{\fonttbl\f0\fswiss\fcharset0 Helvetica;}
+{\colortbl;\red255\green255\blue255;}
+\pard\tx560\tx1120\tx1680\tx2240\tx2800\tx3360\tx3920\tx4480\tx5040\tx5600\tx6160\tx6720\pardirnatural\qc
+
+\f0\fs32 \cf0 LLVM IR}</string>
+				<key>VerticalPad</key>
+				<integer>0</integer>
+			</dict>
+		</dict>
+	</array>
+	<key>GridInfo</key>
+	<dict>
+		<key>SnapsToGrid</key>
+		<string>YES</string>
+	</dict>
+	<key>GuidesLocked</key>
+	<string>NO</string>
+	<key>GuidesVisible</key>
+	<string>YES</string>
+	<key>HPages</key>
+	<integer>2</integer>
+	<key>ImageCounter</key>
+	<integer>1</integer>
+	<key>KeepToScale</key>
+	<false/>
+	<key>Layers</key>
+	<array>
+		<dict>
+			<key>Lock</key>
+			<string>NO</string>
+			<key>Name</key>
+			<string>Layer 1</string>
+			<key>Print</key>
+			<string>YES</string>
+			<key>View</key>
+			<string>YES</string>
+		</dict>
+	</array>
+	<key>LayoutInfo</key>
+	<dict>
+		<key>Animate</key>
+		<string>NO</string>
+		<key>circoMinDist</key>
+		<real>18</real>
+		<key>circoSeparation</key>
+		<real>0.0</real>
+		<key>layoutEngine</key>
+		<string>dot</string>
+		<key>neatoSeparation</key>
+		<real>0.0</real>
+		<key>twopiSeparation</key>
+		<real>0.0</real>
+	</dict>
+	<key>LinksVisible</key>
+	<string>NO</string>
+	<key>MagnetsVisible</key>
+	<string>NO</string>
+	<key>MasterSheets</key>
+	<array/>
+	<key>ModificationDate</key>
+	<string>2014-02-15 12:37:57 +0000</string>
+	<key>Modifier</key>
+	<string>utah</string>
+	<key>NotesVisible</key>
+	<string>NO</string>
+	<key>Orientation</key>
+	<integer>2</integer>
+	<key>OriginVisible</key>
+	<string>NO</string>
+	<key>PageBreaks</key>
+	<string>YES</string>
+	<key>PrintInfo</key>
+	<dict>
+		<key>NSBottomMargin</key>
+		<array>
+			<string>float</string>
+			<string>41</string>
+		</array>
+		<key>NSHorizonalPagination</key>
+		<array>
+			<string>coded</string>
+			<string>BAtzdHJlYW10eXBlZIHoA4QBQISEhAhOU051bWJlcgCEhAdOU1ZhbHVlAISECE5TT2JqZWN0AIWEASqEhAFxlwCG</string>
+		</array>
+		<key>NSLeftMargin</key>
+		<array>
+			<string>float</string>
+			<string>18</string>
+		</array>
+		<key>NSPaperSize</key>
+		<array>
+			<string>size</string>
+			<string>{595.20001220703125, 841.79998779296875}</string>
+		</array>
+		<key>NSPrintReverseOrientation</key>
+		<array>
+			<string>int</string>
+			<string>0</string>
+		</array>
+		<key>NSRightMargin</key>
+		<array>
+			<string>float</string>
+			<string>18</string>
+		</array>
+		<key>NSTopMargin</key>
+		<array>
+			<string>float</string>
+			<string>18</string>
+		</array>
+	</dict>
+	<key>PrintOnePage</key>
+	<false/>
+	<key>ReadOnly</key>
+	<string>NO</string>
+	<key>RowAlign</key>
+	<integer>1</integer>
+	<key>RowSpacing</key>
+	<real>36</real>
+	<key>SheetTitle</key>
+	<string>Canvas 1</string>
+	<key>SmartAlignmentGuidesActive</key>
+	<string>YES</string>
+	<key>SmartDistanceGuidesActive</key>
+	<string>YES</string>
+	<key>UniqueID</key>
+	<integer>1</integer>
+	<key>UseEntirePage</key>
+	<false/>
+	<key>VPages</key>
+	<integer>1</integer>
+	<key>WindowInfo</key>
+	<dict>
+		<key>CurrentSheet</key>
+		<integer>0</integer>
+		<key>ExpandedCanvases</key>
+		<array>
+			<dict>
+				<key>name</key>
+				<string>Canvas 1</string>
+			</dict>
+		</array>
+		<key>Frame</key>
+		<string>{{168, 83}, {1427, 938}}</string>
+		<key>ListView</key>
+		<true/>
+		<key>OutlineWidth</key>
+		<integer>142</integer>
+		<key>RightSidebar</key>
+		<false/>
+		<key>ShowRuler</key>
+		<true/>
+		<key>Sidebar</key>
+		<true/>
+		<key>SidebarWidth</key>
+		<integer>120</integer>
+		<key>VisibleRegion</key>
+		<string>{{-87, 0}, {1292, 783}}</string>
+		<key>Zoom</key>
+		<real>1</real>
+		<key>ZoomValues</key>
+		<array>
+			<array>
+				<string>Canvas 1</string>
+				<real>1</real>
+				<real>1</real>
+			</array>
+		</array>
+	</dict>
+</dict>
+</plist>
Binary file pic/llvmProcess.pdf has changed
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/picins.sty	Fri Oct 21 22:41:40 2016 +0900
@@ -0,0 +1,578 @@
+%       PICINS.STY --- Style File zum Einbinden von Bildern
+%       Autor:  J. Bleser, E. Lang
+%       Hochschulrechenzentrum
+%       Technische Hochschule Darmstadt
+%       !!!  Dieses Style-File ist urheberrechtlich geschuetzt  !!!
+%       !!!  Aenderungen nur mit Zustimmung der Autoren         !!!
+\message{Option `picins' Version 3.0  Sep. 1992, TH Darmstadt/HRZ}
+\newbox\@BILD%
+\newbox\@TEXT%
+\newdimen\d@breite%
+\newdimen\d@hoehe%
+\newdimen\d@xoff%
+\newdimen\d@yoff%
+\newdimen\d@shad%
+\newdimen\d@dash%
+\newdimen\d@boxl%
+\newdimen\d@pichskip%
+\newdimen\d@tmp
+\newdimen\d@tmpa
+\newdimen\d@bskip
+\newdimen\hsiz@%
+\newdimen\p@getot@l%
+\newcount\c@breite
+\newcount\c@hoehe
+\newcount\c@xoff
+\newcount\c@yoff
+\newcount\c@pos
+\newcount\c@shad
+\newcount\c@dash
+\newcount\c@boxl
+\newcount\c@zeilen%
+\newcount\@changemode%
+\newcount\c@piccaption%
+\newcount\c@piccaptionpos%
+\newcount\c@picpos
+\newcount\c@whole%
+\newcount\c@half%
+\newcount\c@tmp
+\newcount\c@tmpa
+\newcount\c@tmpb
+\newcount\c@tmpc
+\newcount\c@tmpd
+\newskip\d@leftskip
+\newif\if@list \@listfalse%
+\newif\if@offset%
+
+
+\c@piccaptionpos=1%
+\c@picpos=0
+\d@shad=4pt%
+\d@dash=4pt%
+\d@boxl=10pt%
+\d@pichskip=1em%
+\@changemode=0%
+\def\@captype{figure}%
+\let\old@par=\par%
+
+\def\pichskip#1{\d@pichskip #1\relax}
+
+
+\def\shadowthickness#1{\d@shad #1\relax}
+
+
+\def\dashlength#1{\d@dash #1\relax}
+
+
+\def\boxlength#1{\d@boxl #1\relax}
+
+
+\def\picchangemode{\@changemode=1}%
+\def\nopicchangemode{\@changemode=0}%
+
+
+\def\piccaptionoutside{\c@piccaptionpos=1}%
+\def\piccaptioninside{\c@piccaptionpos=2}%
+\def\piccaptionside{\c@piccaptionpos=3}%
+\def\piccaptiontopside{\c@piccaptionpos=4}%
+
+\def\piccaption{\@ifnextchar [{\@piccaption}{\@piccaption[]}}
+\def\@piccaption[#1]#2{\c@piccaption=1\def\sh@rtf@rm{#1}\def\capti@nt@xt{#2}}
+\def\make@piccaption{%
+ \hsiz@\d@breite%
+ \ifnum\c@piccaptionpos=2%
+   \advance\hsiz@ -2\fboxsep%
+ \fi%
+ \ifnum\c@piccaptionpos>2%
+   \hsiz@\hsize\advance\hsiz@-\d@breite\advance\hsiz@-\d@pichskip%
+ \fi%
+ \setbox\@TEXT=\vbox{\hsize\hsiz@\caption[\sh@rtf@rm]{\capti@nt@xt}}%
+}
+
+
+
+\def\newcaption{\refstepcounter\@captype\@dblarg{\@newcaption\@captype}}
+\long\def\@newcaption#1[#2]#3{%
+  \old@par%
+  \addcontentsline{\csname ext@#1\endcsname }{#1}%
+    {\protect\numberline{\csname the#1\endcsname}{\ignorespaces #2}}
+  \begingroup\@parboxrestore\normalsize%
+    \@newmakecaption{\csname fnum@#1\endcsname}{\ignorespaces #3}\old@par%
+  \endgroup%
+}
+\long\def\@newmakecaption#1#2{%
+  \vskip 10pt%
+  \setbox\@tempboxa \hbox {#1: #2}%
+  \ifdim \wd\@tempboxa >\hsize%
+    \setbox0=\hbox{#1: }\dimen0=\hsize\advance\dimen0 by-\wd0
+    \setbox1=\vtop{\hsize=\dimen0 #2}
+    \hbox{\box0 \box1}
+    \par
+  \else \hbox to\hsize {\hfil \box \@tempboxa \hfil}
+  \fi
+}
+
+
+
+
+
+\def\parpic{%
+  \@ifnextchar ({\iparpic}{\iparpic(0pt,0pt)}
+}
+\def\iparpic(#1,#2){%
+  \@ifnextchar ({\@offsettrue\iiparpic(#1,#2)}%
+                {\@offsetfalse\iiparpic(#1,#2)(0pt,0pt)}
+}
+\def\iiparpic(#1,#2)(#3,#4){%
+  \@ifnextchar [{\iiiparpic(#1,#2)(#3,#4)}{\iiiparpic(#1,#2)(#3,#4)[l]}
+}
+\def\iiiparpic(#1,#2)(#3,#4)[#5]{%
+  \@ifnextchar [{\ivparpic(#1,#2)(#3,#4)[#5]}{\ivparpic(#1,#2)(#3,#4)[#5][]}
+}
+\def\ivparpic(#1,#2)(#3,#4)[#5][#6]#7{%
+ \let\par=\old@par\par%
+ \hangindent0pt\hangafter1%
+ \setbox\@BILD=\hbox{#7}%
+ \d@breite=#1\d@breite=\the\d@breite%
+ \ifdim\d@breite=0pt\d@breite=\wd\@BILD\fi%
+ \c@breite=\d@breite\divide\c@breite by65536%
+ \multiply\c@piccaption\c@piccaptionpos%
+ \d@hoehe=#2\d@hoehe=\the\d@hoehe%
+ \ifdim\d@hoehe=0pt\d@hoehe=\ht\@BILD\advance\d@hoehe by\dp\@BILD\fi%
+ \c@hoehe=\d@hoehe\divide\c@hoehe by65536%
+ \d@xoff=#3\c@xoff=\d@xoff\divide\c@xoff by65536%
+ \d@yoff=\d@hoehe%
+ \advance\d@yoff by-#4\c@yoff=\d@yoff\divide\c@yoff by65536%
+ \c@pos=1\unitlength1pt%
+ \if@offset%
+   \setbox\@BILD=\hbox{%
+     \begin{picture}(\c@breite,\c@hoehe)%
+       \put(0,0){\makebox(\c@breite,\c@hoehe){}}%
+       \put(\c@xoff,\c@yoff){\box\@BILD}%
+     \end{picture}%
+   }%
+ \else%
+   \setbox\@BILD=\hbox{%
+     \begin{picture}(\c@breite,\c@hoehe)%
+       \put(0,0){\makebox(\c@breite,\c@hoehe)[#6]{\box\@BILD}}%
+     \end{picture}%
+   }%
+ \fi%
+ \ifnum\c@piccaption=2%
+   \make@piccaption%
+   \advance\d@hoehe\ht\@TEXT\advance\d@hoehe\dp\@TEXT%
+   \c@hoehe=\d@hoehe\divide\c@hoehe by65536%
+   \setbox\@BILD=\vbox{\box\@BILD\vspace{-5pt}%
+                       \hbox{\hspace{\fboxsep}\box\@TEXT}%
+                       \vspace{4pt}}%
+ \fi%
+ \@tfor\@tempa := #5\do{%
+   \if\@tempa f\setbox\@BILD=\hbox{\Rahmen(\c@breite,\c@hoehe){\box\@BILD}}\fi%
+   \if\@tempa s\setbox\@BILD=\hbox{\Schatten(\c@breite,\c@hoehe){\box\@BILD}}\fi%
+   \if\@tempa o\setbox\@BILD=\hbox{\Oval(\c@breite,\c@hoehe){\box\@BILD}}\fi%
+   \if\@tempa d\setbox\@BILD=\hbox{\Strich(\c@breite,\c@hoehe){\box\@BILD}}\fi%
+   \if\@tempa x\setbox\@BILD=\hbox{\Kasten(\c@breite,\c@hoehe){\box\@BILD}}\fi%
+   \if\@tempa l\c@pos=1\fi%
+   \if\@tempa r\c@pos=2\fi%
+ }%
+ \ifnum\c@piccaption=1%
+   \make@piccaption%
+   \advance\d@hoehe\ht\@TEXT\advance\d@hoehe\dp\@TEXT%
+   \c@hoehe=\d@hoehe\divide\c@hoehe by65536%
+   \setbox\@BILD=\vbox{\box\@BILD\vspace{-5pt}\hbox{\box\@TEXT}\vspace{4pt}}%
+ \fi%
+ \ifodd\count0\c@picpos=0\else\c@picpos=\@changemode\fi%
+ \pagetotal=\the\pagetotal%
+ \d@tmp=\pagegoal\advance\d@tmp by-\pagetotal\advance\d@tmp by-\baselineskip%
+ \ifdim\d@hoehe>\d@tmp%
+   \vskip 0pt plus\d@hoehe\relax\pagebreak[3]\vskip 0pt plus-\d@hoehe\relax%
+   \ifnum\c@picpos=1\c@picpos=0\else\c@picpos=\@changemode\fi%
+ \fi%
+ \ifnum\c@picpos=1\ifnum\c@pos=1\c@pos=2\else\c@pos=1\fi\fi%
+ \ifnum\@listdepth>0
+   \@listtrue\parshape 0%
+   \advance\hsize -\rightmargin%
+   \d@leftskip \leftskip%
+   \leftskip \@totalleftmargin%
+   \if@inlabel\rule{\linewidth}{0pt}\vskip-\baselineskip\relax\fi%
+ \else\@listfalse\medskip%
+ \fi%
+ \if@list\d@tmpa=\linewidth\else\d@tmpa=\hsize\fi%
+ \ifnum\c@piccaption=3%
+   \make@piccaption%
+   \d@tmp\ht\@TEXT\advance\d@tmp\dp\@TEXT%
+   \ifdim\d@hoehe>\d@tmp%
+     \setbox\@TEXT=\vbox to\d@hoehe{\vfill\box\@TEXT\vspace{.2\baselineskip}\vfill}%
+   \else%
+     \setbox\@BILD=\vbox to\d@tmp{\vfill\box\@BILD\vfill}%
+     \d@hoehe\d@tmp%
+   \fi%
+ \fi%
+ \ifnum\c@piccaption=4%
+   \make@piccaption%
+   \d@tmp\ht\@TEXT\advance\d@tmp\dp\@TEXT%
+   \setbox\@TEXT=\vbox to\d@hoehe{\vspace{-10pt}\box\@TEXT\vfil}%
+   \advance\d@hoehe-\d@tmp%
+ \fi%
+ \ifnum\c@pos=1\d@tmpa=0pt%
+   \ifnum\c@piccaption>2%
+      \setbox\@BILD=\hbox{\box\@BILD\hspace{\d@pichskip}\hbox{\box\@TEXT}}%
+   \fi%
+ \else\advance\d@tmpa by-\wd\@BILD\d@breite=-\d@breite%
+   \ifnum\c@piccaption>2%
+      \d@tmpa=0pt%
+      \setbox\@BILD=\hbox{\hbox{\box\@TEXT}\hspace{\d@pichskip}\box\@BILD}%
+   \fi%
+ \fi%
+ \p@getot@l\the\pagetotal%
+ \d@bskip\d@hoehe\advance\d@bskip by\parskip\advance\d@bskip by.3\baselineskip%
+ {\noindent\hspace*{\d@tmpa}\relax%
+  \box\@BILD\nopagebreak\vskip-\d@bskip\relax\nopagebreak}%
+ \d@tmp=-\d@hoehe\divide\d@tmp by\baselineskip%
+ \c@zeilen=\d@tmp\advance\c@zeilen by-1%
+ \ifdim\d@breite<0pt\advance\d@breite by-\d@pichskip%
+ \else\advance\d@breite by\d@pichskip%
+ \fi%
+ \hangindent=\d@breite%
+ \hangafter=\c@zeilen%
+ \let\par=\x@par%
+ \ifnum\c@piccaption=3%
+    \hangindent0pt\hangafter1\let\par=\old@par%
+    \vskip\d@hoehe\vskip.2\baselineskip%
+ \fi%
+ \c@piccaption=0%
+}
+
+
+
+
+\newdimen\ptoti
+\newdimen\ptotii
+\def\x@par{%
+ \ptoti\pagetotal%
+ \old@par%
+ \ptotii\pagetotal%
+ \ifdim\ptoti=\ptotii%
+   \d@tmp\d@hoehe%
+ \else%
+   \d@tmp\baselineskip%
+   \multiply\d@tmp by\prevgraf%
+   \advance\d@tmp by\parskip%
+   \global\advance\d@hoehe by-\d@tmp\d@tmp=\d@hoehe%
+ \fi%
+ \ifdim\d@hoehe>0pt%
+   \divide\d@tmp by\baselineskip\c@zeilen=-\d@tmp\advance\c@zeilen by-1%
+   \c@zeilen=\the\c@zeilen%
+ \else\c@zeilen=0
+ \fi
+ \ifnum\c@zeilen<0\hangafter=\c@zeilen\hangindent=\d@breite%
+ \else\let\par=\old@par%
+   \hangindent 0pt%
+   \leftskip \d@leftskip%
+   \if@list\parshape \@ne \@totalleftmargin \linewidth%
+     \advance\hsize \rightmargin%
+   \fi%
+ \fi%
+}
+
+
+\def\picskip#1{%
+ \let\par=\old@par%
+ \par%
+ \pagetotal\the\pagetotal%
+ \c@tmp=#1\relax%
+ \ifnum\c@tmp=0%
+   \d@tmp\baselineskip\multiply\d@tmp by\prevgraf\advance\d@tmp\parskip%
+   \ifdim\p@getot@l<\pagetotal
+     \advance\d@hoehe by-\d@tmp\advance\d@hoehe by1ex%
+     \ifdim\d@hoehe>0pt\vspace*{\d@hoehe}\fi%
+   \fi%
+   \ifdim\p@getot@l=\pagetotal%
+     \advance\d@hoehe by-\d@tmp\advance\d@hoehe by1ex%
+     \ifdim\d@hoehe>0pt\vspace*{\d@hoehe}\fi%
+   \fi%
+ \else\hangafter=-\c@tmp\hangindent=\d@breite%
+ \fi%
+ \leftskip \d@leftskip%
+ \if@list\parshape \@ne \@totalleftmargin \linewidth%
+   \advance\hsize \rightmargin%
+ \fi%
+}
+
+
+
+
+
+
+\def\hpic{%
+  \@ifnextchar ({\ihpic}{\ihpic(0pt,0pt)}
+}
+\def\ihpic(#1,#2){%
+  \@ifnextchar ({\@offsettrue\iihpic(#1,#2)}%
+                {\@offsetfalse\iihpic(#1,#2)(0pt,0pt)}
+}
+\def\iihpic(#1,#2)(#3,#4){%
+  \@ifnextchar [{\iiihpic(#1,#2)(#3,#4)}{\iiihpic(#1,#2)(#3,#4)[l]}
+}
+\def\iiihpic(#1,#2)(#3,#4)[#5]{%
+  \@ifnextchar [{\ivhpic(#1,#2)(#3,#4)[#5]}{\ivhpic(#1,#2)(#3,#4)[#5][]}
+}
+\def\ivhpic(#1,#2)(#3,#4)[#5][#6]#7{%
+  \setbox\@BILD=\hbox{#7}%
+  \d@breite=#1\d@breite=\the\d@breite%
+  \ifdim\d@breite=0pt\d@breite=\wd\@BILD\fi%
+  \c@breite=\d@breite\divide\c@breite by65536%
+  \d@hoehe=#2\d@hoehe=\the\d@hoehe%
+  \ifdim\d@hoehe=0pt\d@hoehe=\ht\@BILD\advance\d@hoehe by\dp\@BILD\fi%
+  \c@hoehe=\d@hoehe\divide\c@hoehe by65536%
+  \d@xoff=#3\c@xoff=\d@xoff\divide\c@xoff by65536%
+  \d@yoff=\d@hoehe%
+  \advance\d@yoff by-#4\c@yoff=\d@yoff\divide\c@yoff by65536%
+  \c@pos=0\d@tmpa=\parindent\parindent=0pt\unitlength1pt%
+  \if@offset
+    \setbox\@BILD=\hbox{%
+      \begin{picture}(\c@breite,\c@hoehe)%
+        \put(0,0){\makebox(\c@breite,\c@hoehe){}}%
+        \put(\c@xoff,\c@yoff){\box\@BILD}%
+      \end{picture}%
+    }%
+  \else%
+    \setbox\@BILD=\hbox{%
+      \begin{picture}(\c@breite,\c@hoehe)%
+        \put(0,0){\makebox(\c@breite,\c@hoehe)[#6]{\box\@BILD}}%
+      \end{picture}%
+    }%
+  \fi%
+  \@tfor\@tempa := #5\do{%
+    \if\@tempa f\setbox\@BILD=\hbox{\Rahmen(\c@breite,\c@hoehe){\box\@BILD}}\fi%
+    \if\@tempa s\setbox\@BILD=\hbox{\Schatten(\c@breite,\c@hoehe){\box\@BILD}}\fi%
+    \if\@tempa o\setbox\@BILD=\hbox{\Oval(\c@breite,\c@hoehe){\box\@BILD}}\fi%
+    \if\@tempa d\setbox\@BILD=\hbox{\Strich(\c@breite,\c@hoehe){\box\@BILD}}\fi%
+    \if\@tempa x\setbox\@BILD=\hbox{\Kasten(\c@breite,\c@hoehe){\box\@BILD}}\fi%
+    \if\@tempa t\c@pos=1\fi%
+    \if\@tempa b\c@pos=2\fi%
+  }%
+ \ifnum\c@pos=0\parbox{\d@breite}{\makebox[0cm]{}\\\box\@BILD\smallskip}\fi%
+ \ifnum\c@pos=1\parbox[t]{\d@breite}{\makebox[0cm]{}\\\box\@BILD\smallskip}\fi%
+ \ifnum\c@pos=2\parbox[b]{\d@breite}{\makebox[0cm]{}\\\box\@BILD\smallskip}\fi%
+ \parindent=\d@tmpa%
+}
+
+
+
+
+
+
+\def\Rahmen(#1,#2)#3{%
+  \c@whole=\@wholewidth\divide\c@whole by65536%
+  \c@half=\@halfwidth\divide\c@half by65536%
+  \c@tmpa=#1\advance\c@tmpa by\c@whole\advance\c@tmpa by\c@whole%
+  \c@tmpb=#2\advance\c@tmpb by\c@whole\advance\c@tmpb by\c@whole%
+  \begin{picture}(\c@tmpa,\c@tmpb)%
+    \put(\c@whole,\c@half){\framebox(#1,#2){#3}}%
+  \end{picture}%
+  \global\advance\d@breite by2\@wholewidth%
+  \global\advance\d@hoehe by2\@wholewidth%
+}
+
+
+\def\Schatten(#1,#2)#3{%
+  \c@whole=\@wholewidth\divide\c@whole by65536%
+  \c@half=\@halfwidth\divide\c@half by65536%
+  \c@shad=\d@shad\divide\c@shad by65536%
+  \c@tmp=\c@whole\advance\c@tmp by\c@whole\c@tmpd=\c@tmp%
+  \advance\c@tmp by\c@shad%
+  \advance\c@tmpd by#1%
+  \advance\c@half by\c@shad%
+  \c@tmpa=#1\advance\c@tmpa by\c@tmp%
+  \c@tmpb=#2\advance\c@tmpb by\c@tmp%
+  \begin{picture}(\c@tmpa,\c@tmpb)%
+    \put(\c@whole,\c@half){\framebox(#1,#2){#3}}%
+    \put(\c@shad,0){\rule{\c@tmpd pt}{\c@shad pt}}%
+    \put(\c@tmpd,0){\rule{\c@shad pt}{#2 pt}}%
+  \end{picture}%
+  \global\advance\d@breite by2\@wholewidth\global\advance\d@breite by\d@shad%
+  \global\advance\d@hoehe by2\@wholewidth\global\advance\d@hoehe by\d@shad%
+}
+
+
+\def\Oval(#1,#2)#3{%
+  \@wholewidth=0.4pt%
+  \c@tmpa=\the#1\divide\c@tmpa by2%
+  \c@tmpb=\the#2\divide\c@tmpb by2%
+  \begin{picture}(#1,#2)%
+    \put(\c@tmpa,\c@tmpb){\oval(#1,#2)}%
+    \put(0.4,0.4){#3}%
+  \end{picture}%
+  \global\advance\d@breite by1pt\global\advance\d@hoehe by1pt%
+}
+
+
+\def\Strich(#1,#2)#3{%
+  \c@whole=\@wholewidth\divide\c@whole by65536%
+  \c@half=\@halfwidth\divide\c@half by65536%
+  \c@dash=\d@dash\divide\c@dash by65536%
+  \c@tmp=\c@whole\advance\c@tmp by\c@whole%
+  \c@tmpa=#1\advance\c@tmpa by\c@tmp%
+  \c@tmpb=#2\advance\c@tmpb by\c@tmp%
+  \c@tmpc=#1\advance\c@tmpc by\c@whole%
+  \c@tmpd=#2\advance\c@tmpd by\c@whole%
+  \begin{picture}(\c@tmpa,\c@tmpb)%
+    \put(\c@half,\c@half){\dashbox{\c@dash}(\c@tmpc,\c@tmpd){#3}}%
+  \end{picture}%
+  \global\advance\d@breite by2\@wholewidth%
+  \global\advance\d@hoehe by2\@wholewidth%
+}
+
+
+\def\Kasten(#1,#2)#3{%
+  \@wholewidth=0.4pt%
+  \c@boxl=\d@boxl\divide\c@boxl by65536\c@boxl=\the\c@boxl%
+  \c@tmpa=#1\advance\c@tmpa by\c@boxl%
+  \c@tmpb=#2\advance\c@tmpb by\c@boxl%
+  \c@tmp=#2%
+  \begin{picture}(\c@tmpa,\c@tmpb)%
+    \put(0,\c@boxl){\framebox(#1,#2){#3}}%
+    \put(\c@boxl,0){\line(-1,1){\c@boxl}}%
+    \put(\c@boxl,0){\line(1,0){#1}\line(-1,1){\c@boxl}}%
+    \put(\c@boxl,0){\put(#1,0){\line(0,1){\c@tmp}%
+         \put(0,\c@tmp){\line(-1,1){\c@boxl}}}}%
+  \end{picture}%
+  \global\advance\d@breite by\d@boxl%
+  \global\advance\d@hoehe by\d@boxl%
+}
+
+
+
+
+
+\newbox\env@box%
+\newdimen\d@envdp
+\newcount\c@hsize
+\newcount\c@envdp
+\newdimen\d@envb
+
+\long\def\frameenv{\@ifnextchar [{\@frameenv}{\@frameenv[\textwidth]}}
+\long\def\@frameenv[#1]{%
+ \hsiz@=\textwidth  \textwidth=#1  \d@envb=#1
+ \advance\textwidth by-2\@wholewidth
+ \advance\textwidth by-2\fboxsep
+ \hsize=\textwidth   \linewidth=\textwidth
+ \setbox\env@box=\vbox\bgroup}%
+\def\endframeenv{%
+ \egroup%
+ \hsize=\hsiz@  \textwidth=\hsiz@  \linewidth=\hsiz@
+ \c@breite=\d@envb   \divide\c@breite by65536
+ \advance\d@envb by-2\@wholewidth
+ \c@hsize=\d@envb  \divide\c@hsize by65536%
+ \d@envdp=\dp\env@box  \advance\d@envdp by\ht\env@box%
+ \advance\d@envdp by2\fboxsep%
+ \d@hoehe=\d@envdp   \advance\d@hoehe by2\@wholewidth
+ \c@hoehe=\d@hoehe   \divide\c@hoehe by65536
+ \c@envdp=\d@envdp   \divide\c@envdp by65536%
+ \c@tmp=\@wholewidth \divide\c@tmp by65536
+ \vskip\@wholewidth%
+ \unitlength 1pt\noindent%
+ \begin{picture}(\c@breite,\c@hoehe)(0,0)
+   \put(\c@tmp,\c@tmp){\framebox(\c@hsize,\c@envdp){\box\env@box}}
+ \end{picture}%
+}
+
+
+
+\long\def\shadowenv{\@ifnextchar [{\@shadowenv}{\@shadowenv[\textwidth]}}
+\long\def\@shadowenv[#1]{%
+ \hsiz@=\textwidth  \textwidth=#1  \d@envb=#1
+ \advance\textwidth by-2\@wholewidth
+ \advance\textwidth by-2\fboxsep
+ \advance\textwidth by-\d@shad%
+ \hsize=\textwidth   \linewidth=\textwidth
+ \setbox\env@box=\vbox\bgroup}%
+\def\endshadowenv{%
+ \egroup
+ \hsize=\hsiz@  \textwidth=\hsiz@  \linewidth=\hsiz@
+ \d@tmpa=\d@envb
+ \c@breite=\d@envb   \divide\c@breite by65536
+ \advance\d@envb by-2\@wholewidth  \advance\d@envb by-\d@shad
+ \c@hsize=\d@envb  \divide\c@hsize by65536%
+ \d@envdp=\dp\env@box  \advance\d@envdp by\ht\env@box%
+ \advance\d@envdp by2\fboxsep%
+ \c@envdp=\d@envdp   \divide\c@envdp by65536%
+ \d@hoehe=\d@envdp
+ \advance\d@hoehe by2\@wholewidth  \advance\d@hoehe by\d@shad
+ \c@hoehe=\d@hoehe    \divide\c@hoehe by65536
+ \c@shad =\d@shad     \divide\c@shad  by65536
+ \c@tmp=\@wholewidth  \divide\c@tmp by65536
+ \advance\d@tmpa by-2\d@shad
+ \c@xoff =\d@tmpa     \divide\c@xoff by65536
+ \advance\c@xoff by\c@shad  \advance\c@xoff by-1
+ \advance\d@envdp by\@wholewidth
+ \vskip\@halfwidth
+ \unitlength 1pt\noindent%
+ \begin{picture}(\c@breite,\c@hoehe)(0,0)
+    \put(\c@tmp,\c@shad){\framebox(\c@hsize,\c@envdp){\box\env@box}}
+    \put(\c@shad,0){\rule{\d@tmpa}{\d@shad}}%
+    \put(\c@xoff,0){\rule{\d@shad}{\d@envdp}}%
+ \end{picture}%
+ \vskip\@halfwidth
+}
+
+
+\long\def\dashenv{\@ifnextchar [{\@dashenv}{\@dashenv[\textwidth]}}
+\long\def\@dashenv[#1]{%
+ \hsiz@=\textwidth  \textwidth=#1  \d@envb=#1
+ \advance\textwidth by-2\@wholewidth  \advance\textwidth by-2\fboxsep
+ \hsize=\textwidth   \linewidth=\textwidth
+ \setbox\env@box=\vbox\bgroup}%
+\long\def\enddashenv{%
+ \egroup
+ \hsize=\hsiz@  \textwidth=\hsiz@  \linewidth=\hsiz@
+ \c@breite=\d@envb   \divide\c@breite by65536
+ \advance\d@envb by-\@wholewidth
+ \c@hsize=\d@envb  \divide\c@hsize by65536%
+ \d@envdp=\dp\env@box  \advance\d@envdp by\ht\env@box%
+ \advance\d@envdp by2\fboxsep%
+ \advance\d@envdp by\@wholewidth
+ \d@hoehe=\d@envdp   \advance\d@hoehe by2\@wholewidth
+ \c@hoehe=\d@hoehe   \divide\c@hoehe by65536
+ \c@envdp=\d@envdp   \divide\c@envdp by65536%
+ \c@dash=\d@dash     \divide\c@dash  by65536%
+ \c@whole=\@wholewidth  \divide\c@whole by65536
+ \c@half=\@halfwidth  \divide\c@half by 65536
+ \noindent\unitlength 1pt
+ \begin{picture}(\c@breite,\c@hoehe)(0,0)
+   \put(\c@half,\c@whole){\dashbox{\c@dash}(\c@hsize,\c@envdp){\box\env@box}}
+ \end{picture}%
+}
+
+
+\long\def\ovalenv{\@ifnextchar [{\@ovalenv}{\@ovalenv[\textwidth]}}%
+\long\def\@ovalenv[#1]{%
+ \hsiz@=\textwidth  \textwidth=#1  \d@envb=#1
+ \advance\textwidth by-4\fboxsep
+ \hsize=\textwidth   \linewidth=\textwidth
+ \setbox\env@box=\vbox\bgroup}%
+\long\def\endovalenv{%
+ \egroup
+ \hsize=\hsiz@  \textwidth=\hsiz@  \linewidth=\hsiz@
+ \@wholewidth=0.4pt
+ \c@breite=\d@envb   \divide\c@breite by65536
+ \advance\d@envb by-2\@wholewidth
+ \c@hsize=\d@envb  \divide\c@hsize by65536%
+ \d@envdp=\dp\env@box  \advance\d@envdp by\ht\env@box%
+ \advance\d@envdp by4\fboxsep%
+ \c@envdp=\d@envdp   \divide\c@envdp by65536%
+ \d@hoehe=\d@envdp   \advance\d@hoehe by2\@wholewidth
+ \c@hoehe=\d@hoehe   \divide\c@hoehe by65536
+ \c@tmpa=\c@hsize   \divide\c@tmpa by2%
+ \c@tmpb=\c@envdp   \divide\c@tmpb by2%
+ \d@tmpa=2\fboxsep   \advance\d@tmpa by\@wholewidth
+ \c@xoff=\d@tmpa     \divide\c@xoff  by65536%
+ \advance\d@tmpa by\dp\env@box
+ \c@yoff=\d@tmpa     \divide\c@yoff  by65536%
+ \unitlength 1pt\noindent
+ \begin{picture}(\c@breite,\c@hoehe)(0,0)
+   \put(\c@tmpa,\c@tmpb){\oval(\c@hsize,\c@envdp)}
+   \put(\c@xoff,\c@yoff){\box\env@box}%
+ \end{picture}%
+}