From 55a6a6ed799d5f76a03e7a83799297ddf8f7b7a2 Mon Sep 17 00:00:00 2001 From: "mdevan.foobar" Date: Mon, 9 Jun 2008 17:45:49 +0000 Subject: [PATCH] Added generated docs to svn. git-svn-id: http://llvm-py.googlecode.com/svn/trunk@7 8d1e9007-1d4e-0410-b67e-1979fd6579aa --- www/web/about.html | 68 +++++ www/web/contribute.html | 63 +++++ www/web/download.html | 260 +++++++++++++++++++ www/web/examples.html | 114 +++++++++ www/web/images/icons/callouts/1.png | Bin 0 -> 329 bytes www/web/images/icons/callouts/10.png | Bin 0 -> 361 bytes www/web/images/icons/callouts/11.png | Bin 0 -> 565 bytes www/web/images/icons/callouts/12.png | Bin 0 -> 617 bytes www/web/images/icons/callouts/13.png | Bin 0 -> 623 bytes www/web/images/icons/callouts/14.png | Bin 0 -> 411 bytes www/web/images/icons/callouts/15.png | Bin 0 -> 640 bytes www/web/images/icons/callouts/2.png | Bin 0 -> 353 bytes www/web/images/icons/callouts/3.png | Bin 0 -> 350 bytes www/web/images/icons/callouts/4.png | Bin 0 -> 345 bytes www/web/images/icons/callouts/5.png | Bin 0 -> 348 bytes www/web/images/icons/callouts/6.png | Bin 0 -> 355 bytes www/web/images/icons/callouts/7.png | Bin 0 -> 344 bytes www/web/images/icons/callouts/8.png | Bin 0 -> 357 bytes www/web/images/icons/callouts/9.png | Bin 0 -> 357 bytes www/web/images/icons/caution.png | Bin 0 -> 2554 bytes www/web/images/icons/example.png | Bin 0 -> 2354 bytes www/web/images/icons/home.png | Bin 0 -> 1340 bytes www/web/images/icons/important.png | Bin 0 -> 2657 bytes www/web/images/icons/next.png | Bin 0 -> 1302 bytes www/web/images/icons/note.png | Bin 0 -> 2730 bytes www/web/images/icons/prev.png | Bin 0 -> 1348 bytes www/web/images/icons/tip.png | Bin 0 -> 2602 bytes www/web/images/icons/up.png | Bin 0 -> 1320 bytes www/web/images/icons/warning.png | Bin 0 -> 2828 bytes www/web/index.html | 75 ++++++ www/web/license.html | 87 +++++++ www/web/style/layout.css | 67 +++++ www/web/style/xhtml11-manpage.css | 18 ++ www/web/style/xhtml11-quirks.css | 40 +++ www/web/style/xhtml11.css | 276 +++++++++++++++++++++ www/web/userguide.html | 357 +++++++++++++++++++++++++++ 36 files changed, 1425 insertions(+) create mode 100644 www/web/about.html create mode 100644 www/web/contribute.html create mode 100644 www/web/download.html create mode 100644 www/web/examples.html create mode 100644 www/web/images/icons/callouts/1.png create mode 100644 www/web/images/icons/callouts/10.png create mode 100644 www/web/images/icons/callouts/11.png create mode 100644 www/web/images/icons/callouts/12.png create mode 100644 www/web/images/icons/callouts/13.png create mode 100644 www/web/images/icons/callouts/14.png create mode 100644 www/web/images/icons/callouts/15.png create mode 100644 www/web/images/icons/callouts/2.png create mode 100644 www/web/images/icons/callouts/3.png create mode 100644 www/web/images/icons/callouts/4.png create mode 100644 www/web/images/icons/callouts/5.png create mode 100644 www/web/images/icons/callouts/6.png create mode 100644 www/web/images/icons/callouts/7.png create mode 100644 www/web/images/icons/callouts/8.png create mode 100644 www/web/images/icons/callouts/9.png create mode 100644 www/web/images/icons/caution.png create mode 100644 www/web/images/icons/example.png create mode 100644 www/web/images/icons/home.png create mode 100644 www/web/images/icons/important.png create mode 100644 www/web/images/icons/next.png create mode 100644 www/web/images/icons/note.png create mode 100644 www/web/images/icons/prev.png create mode 100644 www/web/images/icons/tip.png create mode 100644 www/web/images/icons/up.png create mode 100644 www/web/images/icons/warning.png create mode 100644 www/web/index.html create mode 100644 www/web/license.html create mode 100644 www/web/style/layout.css create mode 100644 www/web/style/xhtml11-manpage.css create mode 100644 www/web/style/xhtml11-quirks.css create mode 100644 www/web/style/xhtml11.css create mode 100644 www/web/userguide.html diff --git a/www/web/about.html b/www/web/about.html new file mode 100644 index 0000000..6531aa7 --- /dev/null +++ b/www/web/about.html @@ -0,0 +1,68 @@ + + + + + + + + + + +About - llvm-py + + +
+
llvm-py
+
Python Bindings for LLVM
+
+ + + + + +
+ + + + + + + + + + +
+ +
+
+
+ + + +
+Note + +
llvm-py Mission Statement
+

Provide a simple, consistent and well-documented suite of APIs that +exposes just enough of LLVM to write a compiler/VM in Python.

+
+
+

llvm-py is developed by Mahadevan R, in his spare time, without being +paid for it. He can be reached at mdevan.foobar .at. gmail.com, on the +llvm-dev mailing list and irc.oftc.net#llvm (mdevan).

+

These web pages were generated using the nifty tool +asciidoc.

+
+
+ +
+
+ + diff --git a/www/web/contribute.html b/www/web/contribute.html new file mode 100644 index 0000000..a48e96b --- /dev/null +++ b/www/web/contribute.html @@ -0,0 +1,63 @@ + + + + + + + + + + +Contribute - llvm-py + + +
+
llvm-py
+
Python Bindings for LLVM
+
+ + + + + +
+ + + + + + + + + + +
+ +
+
+

llvm-py is just hatching. It needs your patches and suggestions to +grow up. Please contribute! All patches are welcome.

+

The llvm-py code is hosted on a google code project by the same name, +here. It provides the SVN repository +and a bug tracker. The +latest code can be checked out from SVN like so:

+
+
+
$ svn checkout http://llvm-py.googlecode.com/svn/trunk/ llvm-py
+
+

You can browse the source online at: +http://code.google.com/p/llvm-py/source/browse.

+
+
+ +
+
+ + diff --git a/www/web/download.html b/www/web/download.html new file mode 100644 index 0000000..5dfd216 --- /dev/null +++ b/www/web/download.html @@ -0,0 +1,260 @@ + + + + + + + + + + +Download and Setup - llvm-py + + +
+
llvm-py
+
Python Bindings for LLVM
+
+ + + + + +
+ + + + + + + + + + +
+ +
+
+

The latest release is 0.2, released xx-Jun-2008 (full Changelog +below).

+

Download it here:

+
+ +++++ + + + + + + + + + + + + + + + + + + + + + +
+ Release + + Date + + Package + + Mirror +
+ 0.2 + + xx-Jun-2008 + + llvm-py-0.2.tar.bz2 + + llvm-py-0.2.tar.bz2 +
+ 0.1 + + 20-May-2008 + + llvm-py-0.1.tar.bz2 + + llvm-py-0.1.tar.bz2 +
+
+
+
+

Bleeding Edge

+
+

The latest code can be checked out from SVN thusly:

+
+
+
$ svn checkout http://llvm-py.googlecode.com/svn/trunk/ llvm-py
+
+

Happy hacking, and please send in your patches.

+
+

Setting Up

+
+

Follow these steps to get llvm-py up and running:

+
    +
  • +

    +Uninstall any previous version of llvm-py. +

    +
  • +
  • +

    +Get and build LLVM. +

    +
  • +
  • +

    +Optionally, install it. +

    +
  • +
  • +

    +Get the latest release (see above) of llvm-py and untar it: +

    +
  • +
+
+
+
$ wget http://link/llvm-py-0.2.tar.bz2
+$ tar jxvf llvm-py-0.2.tar.bz2
+
+
    +
  • +

    +If you've installed LLVM, setup llvm-py like this: +

    +
  • +
+
+
+
$ cd llvm-py-0.2
+$ sudo python setup.py install
+
+
    +
  • +

    +If you haven't installed LLVM, locate the executable llvm-config + under your LLVM build directory (should be something like + /home/mdevan/llvm/Release/bin/llvm-config) and pass this to setup.py: +

    +
  • +
+
+
+
$ cd llvm-py-0.2
+$ sudo python setup.py install --llvm-config=/path/to/llvm-config
+
+

That's it!

+
Notes:
    +
  • +

    +setup.py is a standard Python distutils script. See the Python + documentation regarding + Installing Python Modules and + Distributing Python Modules for + more information on such scripts. +

    +
  • +
  • +

    +To build the debug version, build with the -g flag and the debug + version of llvm-config: +

    +
    +
    +
    $ python setup.py build -g --llvm-config=/path/to/Debug/bin/llvm-config
    +$ sudo python setup.py install
    +
    +
  • +
  • +

    +Debug binaries are huge! (65 MB+) +

    +
  • +
  • +

    +If --llvm-config is not specified, setup.py looks for + llvm-config in the PATH, which will succeed if LLVM is installed. +

    +
  • +
+
+

Uninstall

+
+

To get rid of llvm-py completely, if you wish to do so:

+
+
+
# rm -rf /usr/lib/python2.5/site-packages/llvm
+# rm -f /usr/lib/python2.5/site-packages/llvm_py-0.1.egg-info
+
+
    +
  • +

    +You need to be root to do this. +

    +
  • +
  • +

    +Paths are for debian-based systems, in other distros it might be different. +

    +
  • +
  • +

    +Note that there is a version number in the egg file name. +

    +
  • +
+
+

Changelog

+
+
+
+
0.1, 10-May-2008:
+
+  * Initial release.
+
+
+0.2, ongoing:
+
+  * Independent package, need not be unpacked into llvm/bindings
+  * Modules can be dumped to a string
+  * Modules can be verified
+  * Module.global_variables, Module.functions, Function.args,
+        Function.basic_blocks and BasicBlock.instructions are
+        now proper iterators (generators in fact) than plain lists
+
+  * MemoryBuffer is done
+  * TypeHandle is done
+  * Unit tester added (but doesn't do much for now)
+
+
+
+ +
+
+ + diff --git a/www/web/examples.html b/www/web/examples.html new file mode 100644 index 0000000..bc40125 --- /dev/null +++ b/www/web/examples.html @@ -0,0 +1,114 @@ + + + + + + + + + + +Examples - llvm-py + + +
+
llvm-py
+
Python Bindings for LLVM
+
+ + + + + +
+ + + + + + + + + + +
+ +
+
+

Here's an example:

+
+
+
#!/usr/bin/env python
+
+from llvm.core import *
+
+## create a module
+module = Module.new("my_module")
+
+## create a function type taking two doubles and returning a (32-bit) integer
+ty_double = Type.double()
+ty_int    = Type.int()
+ty_func   = Type.function( ty_int, [ ty_double, ty_double ] )
+
+## create a function of this type
+func      = Function.new( module, ty_func, "foobar" )
+
+# name function args
+func.args[0].name = "arg1"
+func.args[1].name = "arg2"
+
+## implement the function
+
+# add a basic block
+entry = func.append_basic_block("entry")
+
+# create an llvm::IRBuilder
+builder = Builder.new()
+builder.position_at_end(entry)
+
+# add two args into tmp1
+tmp1 = builder.add(func.args[0], func.args[1], "tmp1")
+
+# sub `1' from that
+one = Constant.real( ty_double, 1.0 )
+tmp2 = builder.sub(tmp1, one, "tmp2")
+
+# convert to integer
+tmp3 = builder.fptoui(tmp2, ty_int, "tmp3")
+
+# return it
+builder.ret(tmp3)
+
+# dump the module to see the llvm "assembly" code
+print module
+
+

which gives this output:

+
+
+
; ModuleID = 'my_module'
+
+define i32 @foobar(double %arg1, double %arg2) {
+entry:
+        %temp1 = add double %arg1, %arg2                ; <double> [#uses=1]
+        %temp2 = sub double %temp1, 1.000000e+00                ; <double> [#uses=1]
+        %temp3 = fptoui double %temp2 to i32            ; <i32> [#uses=1]
+        ret i32 %temp3
+}
+
+
+
+ +
+
+ + diff --git a/www/web/images/icons/callouts/1.png b/www/web/images/icons/callouts/1.png new file mode 100644 index 0000000000000000000000000000000000000000..7d473430b7bec514f7de12f5769fe7c5859e8c5d GIT binary patch literal 329 zcmeAS@N?(olHy`uVBq!ia0vp^JRr;gBp8b2n5}^nQC}X^4DKU-G|w_t}fLBA)Suv#nrW z!^h2QnY_`l!BOq-UXEX{m2up>JTQkX)2m zTvF+fTUlI^nXH#utd~++ke^qgmzgTe~DWM4ffP81J literal 0 HcmV?d00001 diff --git a/www/web/images/icons/callouts/10.png b/www/web/images/icons/callouts/10.png new file mode 100644 index 0000000000000000000000000000000000000000..997bbc8246a316e040e0804174ba260e219d7d33 GIT binary patch literal 361 zcmeAS@N?(olHy`uVBq!ia0vp^JRr;gBp8b2n5}^nQWtZ~+OvdJMW|Y+^UT?O-M{rKJsmzxdayJ{ zDCQA!%%@7Jj$q%-wf8e0_jRx8Dqi$}^?K=?6FriQFLv>>oc^CE+aVHhW3=nZ+fQ4!M=ZC7H>3sl|FJr3LwU zC3?yExf6FO?f@F61vV}-Juk7O6lk8Yg;}bFaZ-|HQc7Azopr01?u8M*si- literal 0 HcmV?d00001 diff --git a/www/web/images/icons/callouts/11.png b/www/web/images/icons/callouts/11.png new file mode 100644 index 0000000000000000000000000000000000000000..ce47dac3f52ac49017749a3fea53db57d006993c GIT binary patch literal 565 zcmeAS@N?(olHy`uVBq!ia0vp^JRr=$1SD^YpWXnZI14-?iy0V%N{XE z)7O>#600DeuDZ?5tOl@ql94%{~0TwC?8m~C^ZqJRG}m@H-L1 z5L@scq?{XUcxG{OP9jig5ySQaTl#^*93bKF#G<^+ymW>G($Cs~V(bw8rA5i93}62@ zzlJGu&d<$F%`0K}c4pdspcorSSx9C{PAbEScbC)|7#JBmT^vIy=9KoYUDZ+`aP)jU z&ny=ErrK^#Gw!AcR}pdfMERuV^@&0$@(#^6b8c@rn^6RWX3pUb z4*6@PZ+H0#u=rjsXzS?6n6*sBGbHqGTU%mCsH?n#%j;eD^2}qe=iX*J@VQ3BRpz+u z{PX#N(^9X${`$90+;!pWs>o@z_n8G)7Uo7PJz`jrS+)QE@=PWHmc~UIw=WmUe73o7 z>^bR(M752aYoNg~ozu7U7&{(U>{s!;bn#f?ItjL^o`e{*EOQHqO;ccnz9hLK5@2cAyw@AaPFL~Cp#02|E|4xeQteNtB7waMs QVCXP-y85}Sb4q9e0GRUFb^rhX literal 0 HcmV?d00001 diff --git a/www/web/images/icons/callouts/12.png b/www/web/images/icons/callouts/12.png new file mode 100644 index 0000000000000000000000000000000000000000..31daf4e2f25b6712499ee32de9c2e3b050b691ca GIT binary patch literal 617 zcmeAS@N?(olHy`uVBq!ia0vp^JRr=$1SD^YpWXnZI14-?iy0V%N{XE z)7O>#600De9$%>2LVd81Yeb1-X-P(Y5yQ%LXFPyHJS9LOm(=3qqRfJl%=|nCVNOM5 zpg0#u+&RCXvM4h>ql94%{~0TwC?8m~C^ZqJRG}m@H-L1 z5L@scq?{XUcxG{OP9jig5ySQaTl#^*93bKF#G<^+ymW>G($Cs~V(bw8rA5i93}62@ zzlJGu&d<$F%`0K}c4pdspcorSSx9C{PAbEScbC)|7#JBmT^vIy=Cn>wTzx1(qV@bS z0hYvspf(--lM>otrqbK$7p{3DzJ|+KN8%5ows)AI?zWk_n>jwEHXrTJecpEW_0xL= z?}N`*R`T~d2{AN${y8T#GEn4hUb&52^}Op@TW4{oc)A6)%$5=G}h# z?O{QLj@aRcAIf&y&OiUN=H2gq=_}V|pWfuReDV|{jwXw~>#w)I|9${XE z)7O>#600Dep5bGK9wD%hYeb1-X-P(Y5yQ%LXFPyHJS9LOm(=3qqRfJl%=|nCVNOM5 zpg0#u+&RCXvM4h>ql94%{~0TwC?8m~C^ZqJRG}m@H-L1 z5L@scq?{XUcxG{OP9jig5ySQaTl#^*93bKF#G<^+ymW>G($Cs~V(bw8rA5i93}62@ zzlJGu&d<$F%`0K}c4pdspcorSSx9C{PAbEScbC)|7#JBmT^vIy=Cn>w>~AWNX^a2R zbkveVY|45D7UnZ&JtjPwvdCCscZp0EA*0()#GOw)UH4-^&)y^E*4%UC)*|J}q_Ss;tN`nd8$>x9$_Xb^O2EpX&@C ZI46EzbLxq-voTO7gQu&X%Q~loCIF_C`w;*D literal 0 HcmV?d00001 diff --git a/www/web/images/icons/callouts/14.png b/www/web/images/icons/callouts/14.png new file mode 100644 index 0000000000000000000000000000000000000000..64014b75fe2e84d45ed861974c72462727979360 GIT binary patch literal 411 zcmV;M0c8G(P)!ax*-PXaQ9e~6^e1gu=a6a&KSz}bR`+prYG9ayB$BDjWGfIE;t#wl!+ zR3S(jA%y#i_@eOOedXoc%RQe%L;wH~k+s%ZI~)!<=dD%?4MaplaU9QPGski2q3`>r z(}{j@0a$CLl+)={2vLWml*i-oa5#J}DW$gCZB~Z!(!M#)2St|1_V^0qpmCrBof=Y&NUas@LmfSw=)4B4f;8Fu)(eFsv24 zJzXxBrayquXcR?J{XE z)7O>#600De0j~t#c`vY#Yeb1-X-P(Y5yQ%LXFPyHJS9LOm(=3qqRfJl%=|nCVNOM5 zpg0#u+&RCXvM4h>ql94%{~0TwC?8m~C^ZqJRG}m@H-L1 z5L@scq?{XUcxG{OP9jig5ySQaTl#^*93bKF#G<^+ymW>G($Cs~V(bw8rA5i93}62@ zzlJGu&d<$F%`0K}c4pdspcorSSx9C{PAbEScbC)|7#JBmT^vIy=9Eq_Jl&Ka(%QdX zh{H8O%#_7)Tc@t$mM`p4(Ne7omR*~(>gd8_8AZH{=3ms$Fmzm^yL@_+(#aQQ5>7QW z>3g2fIsH(ugM)!V$x4Rr_+!J_XU%4xbz0aE;^N{m@42Z|@0S@TQ=WbP`TMV5Ok;<| z^Ihv+@6tQ{sciRF9dD7Nr=KobwJJ68zJK$<1Pd9rz%4O)*;}Jzj&~nTGMecz>B%lV zK|`fmIc8mp-h8iSXiGFW=C(L+XH4DRxZQX87^-dLuD>odo6YLT@Sw)dfBEIG)v2@6 zR)%mL7GRj1x-&v&+2q@A%a&h0`Lw7|#(w_!tgT!PoJ|+re`lxaY7e*=hH)_rZeB4|imU1$R#1`!P>&$poQl;nzm}mD5ZFopaX|GsS%q*{P~< z;WtmO%lhToBL0i}yfkaOt?EN=nkLNGuU`ywhI5H)L`iUdT1k0gQ7VIjhO(w-Zen_> zZ(@38a<+nro{^q~f~BRtfrY+-p+a&|W^qZSLvCepNoKNMYO!8QX+eHoiC%Jk?!;Y+ zJAlS%fsM;d&r2*R1)67JkeZlkYGj#gX_9E3W@4U_nw*@Ln38B@k(iuhnUeN2eF0kK0(Y1u|9Rc(19XFPiEBhjaDG}zd16s2gM)^$re|(qda7?? zdS-IAf{C7yo`r&?rM`iMzJZ}aa#3b+Nu@(>WpPPnvR-PjUP@^}eqM=Qa(?c_U5Yz^ z#%Y0#%S_KpEGY$=XJL?(l#*ybuErX#^g`ttQfwn3r>K)tuC)r#2`iJ>Prt42#Ndx#Uc~1)>aw z3jE@Q4|!9Z%lVv}- zc=48cF7H)t`(Ck`^+mtha~Np7bBSw2NpOBzNqJ&XDuaWDvZiNlVtT4?VtQtBwt|VC zk)DNurKP@sg}#BILUK`NaY>~^Ze?*vX0l#tv0h4PL4IC|UUGi!#9fLzfW~Qojmu2W zODrh`nrE42VU(7fm~5G9U~HM3l#*m_WNcxOXkuzEX4g z+-vfUhb0A>b04=Im{6XiQd1v%r%>h0$G8U7E1If8OQ!N~xOYY5h0NDT$p9(iZ?Q&e z18-(+l~J8O`)kc}e&uL$eW&>P-#`~Qm$*ih1m~xflqVLYGB{``YkKA;rl!p+yCFkc(+@-h!Xq*<< zxXkpt#FA2=d1VEBsYynrsitN|Y01eJ$;p;U#>wWX2KP5v&I9V=1L+C? fTFYQ)RAFeOZJ=$?lDoSWD8u0C>gTe~DWM4f^}upZ literal 0 HcmV?d00001 diff --git a/www/web/images/icons/callouts/6.png b/www/web/images/icons/callouts/6.png new file mode 100644 index 0000000000000000000000000000000000000000..0ba694af6c07d947d219b45a629bd32c60a0f5fe GIT binary patch literal 355 zcmeAS@N?(olHy`uVBq!ia0vp^JRr;gBp8b2n5}^nQ*)Bra@SU# zmiz#bR~{$s2si{S(aY|Z}Vd7tb ouUmn-_&~Y>fYve?8dVq?X&Y!8wB+ut1u%w%U~xZhnMEEs6JbBSw2NpOBzNqJ&XDuaWDvZiNlVtT4?VtQtBwt|VC zk)DNurKP@sg}#BILUK`NaY>~^Ze?*vX0l#tv0h4PL4IC|UUGi!#9fLzfW~Qojmu2W zODrh`nrCEbVQgk$XkwI@Y+{_8nv`N>YGIaQkz#0QY@Te9lBQ<)awbq0A4pdK&{_sV bqY6VKZ3AtCmfYR7Kp6&4S3j3^P6u&S`V$cAh@R~F=4@V4jxkzlaQrcFYWK{)(`o5XZnut z=nE4SU2g1ZW%;@@I$>_e3F8a=8WK~|CVXt1DqisQxtIX|`YW_n&?Nh#1gQ}d)$LrYTw(_{nVG)tp2V+#}WG*e^KRLdkoLz7g? qn(IA84Qgo42`r6v<+Hvch>@C7(8A5T-G@yGywn*$#_oy literal 0 HcmV?d00001 diff --git a/www/web/images/icons/callouts/9.png b/www/web/images/icons/callouts/9.png new file mode 100644 index 0000000000000000000000000000000000000000..a0676d26cc2ff1de12c4ecdeefb44a0d71bc6bde GIT binary patch literal 357 zcmeAS@N?(olHy`uVBq!ia0vp^JRr;gBp8b2n5}^nQNRqa;^5&H%t0&v*|C|wdb9$wI zR@+N9#RIowg@Uqn&z-__Tzhhz!sG|vTxA7?=O|Y?u(d4T{!RM9c7chr6d%1?R=i16 z?@Ic{f32YJFJnVhX)qGzOMplv!L->5yAlT#}irms+fsQd*FoSE84k zpF44v;trs3T43Wc)AJHbN`dAXo0u6Hr<$gkq?lM38ycjV7+5A5Sr{ayr5c%-n;95g pF*H#D>f!_G3IJNmU}#ifXryhRZP1dtyA~+J;OXk;vd$@?2>@J{cB%jX literal 0 HcmV?d00001 diff --git a/www/web/images/icons/caution.png b/www/web/images/icons/caution.png new file mode 100644 index 0000000000000000000000000000000000000000..cb9d5ea0df3fb7abe744d6ef885847c13b786d4d GIT binary patch literal 2554 zcmVPx#1ZP1_K>z@;j|==^1poj5AY({UO#lFTCIA3{ga82g0001h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80Bp)9Krjzy1J@Vs)B+7lnbKWx^?UB-Ma|>$p60M~S&>&NjQh%@%X)G-*j~qF2;=~Dj3pjiB?1c*#GBPsq^76{d%Mlaq<_Z~3 z8M-(tc%+PZsHLR^>p<_Wsi{E}h=dKu#l=Nr@^Jj1I$;VbJlTKr2s7RH5OZ_$*w|QH zy>X}GK)o;D9Q45wEij#FNG3;fIhe zZmwJ>FkwL~eTazW1XltJlffD2F%ScFgl!xTI3NiO2isv7S`Nme!NN3bBhzcp;*qH9 zyS-?0D9ofnTxNFGHnDol4XZ*4P~uPg6JoG!3#E!zuox_f?epTE+Vugg{jpLneTay- zhz>Z^E!$q0YuM`p*66M1w=;4e(;I; z#wi{%^iGLAOBow2GKohN%*P)#C9mQ3uXMuET~q4`W^j(q|JmjD7rg=h19t5(ulxW^ Q2LJ#707*qoM6N<$f-6kHbN~PV literal 0 HcmV?d00001 diff --git a/www/web/images/icons/example.png b/www/web/images/icons/example.png new file mode 100644 index 0000000000000000000000000000000000000000..bba1c0010ddbb148a93e8a442047ca6a68b5ef1f GIT binary patch literal 2354 zcmV-23C;G2P)Px#1ZP1_K>z@;j|==^1poj5AY({UO#lFTCIA3{ga82g0001h=l}q9FaQARU;qF* zm;eA5aGbhPJOBU)ut`KgR9Hvtn0ZW<*%`)1ma<-C2SEe@#S4{-$R1Xgxh%4IS(M8K zM{7VaMMsHoX8dCsnUut2qS3V2u}KHS1`T^a{VmGhy(u*4!wT;dd7?y zzP`TWei{%tK0f~T?c0NTHHbqGA3oG-wQJU_`TQrqXPExx1g8& zf?UvNXJuz+W@QRwWTdBarPHIP3aYNI&YhXNc=2M$D=I3E9656S{Q1k5FPE2><9$Iv zA%e)9Vd%{3&RvJ9g9i`Z>+1S_ZEaRoRwkEV&qx;v($mw@)6!A_sex|p zfdPvaRgn74n>QO88W6XB{rc_Ox69OXA3b{1-hPa5{B?0gflyAH#yu1EQ4_p zu@X@+F;P)5d~K>A`lDh|g(!Mj+OucRmM&ciU+TxH%*Xq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#qr90)G|U}J8I#jSHk)NjM&1~sd!^7pZ@SGS*$@!71L9Ud!VXx| zAs3zU_o&BrM+=z3Uwp?DKG$zfQLD@x>=Hlh2J#CQ2n|*Jyi^j8TpQ#0?o|nCTesYC zW5Q*4)CSUPde zPwCFH1=om86#ULoHLxRQAmULIQ%a-&twW|}Dhyq%s&k{I^6YH!U`zPdm-Em(;P?0U z-@QS$ZQCY+_#kg=2xQ`Qg|$vf(cwgmC_u>#Jr%0Fi8m4nbBET-!^eRfF#DeyWWfkP zxr_Y=^M2>aqDZGP?6fH32$XEpK~1X4c%!~{Gi6Lp10}!()a`rkUpdA_c;_CU5&!@I M07*qoM6N<$g4<+Y4gdfE literal 0 HcmV?d00001 diff --git a/www/web/images/icons/note.png b/www/web/images/icons/note.png new file mode 100644 index 0000000000000000000000000000000000000000..841820f7c4fb274fc45fae0a0a526a68eb31d85e GIT binary patch literal 2730 zcmV;b3RU%qP)Px#1ZP1_K>z@;j|==^1poj5AY({UO#lFTCIA3{ga82g0001h=l}q9FaQARU;qF* zm;eA5aGbhPJOBU+C`m*?R9Hvtmk#&%BZ`u?MxrG)hCW_<|J*tEp2N96{^vXA+>;sKefQlHKdAtqpHw{YlcI4A*Uvzc zI50JbxLmHUukW*C0R_07c7vw?6doSFd-;OF!@JcVyr%q}cl#@za0?Hom+6NBff?}n zk^R1^cYZ6|ym)BSv&t=tG%qcMha3)P8kv455Dbv)^PSo~Zwz@qtNitI>KB%1UizhO zn@8{O)Fe_QII{mhv&pL#6j&YcU~ zi^l>A^XAR_K07A|g5I5W`5W6_kiNMNeRCz|yNY;s3}u%WdGIBDZ`B5auaC&{P{K=PbW?4u4o4H4%%_kM&D5NjZB2RS;X9CBB7{hheSnf1cJ54ok-MV$F`#|f~tz&Tkp(@bz zUmO&twN{_5xfWQQ{b^SGuG7K44-4|iO!%-g_cJ~>ct8-T?mBDeO)?Fp5<~w9#B*Xb zPOKJ~HgDd1_wHRc9on#A15318HN}YRilQ^Kr#Vi*3#}^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bV(Xh_U89&}t z+MOh~DPn9+8jaZ0#7@^o3$z`Qq%NB;Pm61lsTIjJ zIyNyq^K;MDoAYSq!US$8G{XFS;sUs{!{NAm`SJ>SYN7^`|JWN~cjx2l7q7G~$AanH z1~Ei58RaJhh6c7!4>WK4_+jIKV6Ax90YD_(5IFQJ*xiArD1k0nTfejg6Q`lWB)1+- zR+j?}G7H=Q&4mjWu3fvfntd4w9QM5E4G?VX?y#TQ5w@Qrx1{DZ5DWI4+aRX&IMO>c zrwXEpl^EX-Plj#~DR2WctK7Mgz|olSP2d^(DP-)gWB4&*BR8WoO;?Y)Ewvm0F|v{l zNpV}cu`wmLCSGYlHtmxXgv3+hkyB7Hbb}dQX>ae239*BophWDau!F&#;oYsltaw=@ zPm3~1{qk|6V~Y$i!u-&r4FB!B;l*%2_zj3bPT}3xaQZ=GBIiTMI}i^4fTv;4fG!<< zF*;G`15Dr-1qU@8RTFgzl>x;ZBQgGUo(~aB^a&cMf@fksg)hdQ0iTYFjfK(KfC>EK z9#4P+f5jM#eElbAbY-B=7*ShL?@$+^33Tb`i?KGjaE~W={=YqAq%qM)!3ZMy0{Rpd zeKEP{Q&{|!oWhbLVtNLzH{Q<}Jx=ikol|@L#8(`!N`_u>)g@m4FBL7XS}!q~Jpcdz M07*qoM6N<$f^MzYD*ylh literal 0 HcmV?d00001 diff --git a/www/web/images/icons/up.png b/www/web/images/icons/up.png new file mode 100644 index 0000000000000000000000000000000000000000..2db1ce62fa575fd990108b15b0de18a64cae19ca GIT binary patch literal 1320 zcmV+@1=sqCP)1zYw%4)aycz=34IrN7Q8_?WBoG2YRoWs12q8e+irO1DxN$-1 zg)8b|5m$tW;J~4XB7`Ub0mW7NptQ6peTXD>;&}bqwRd-hgWI%$wv04~nfc~7|M|X| z?-SghmG;akFk_%6FvbM~m;j>}lx|dh_MYioZ?CukbPMnbm`w4f{4cn)XZ8*dZ)2&~2C{D9rqR3{A4zlfXp@XeI8z(ouZm`=TGcf_2y`6G zDARiXLG#H^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kl3g`rI2(S)Ml6Qs+;k%|n&#tvur=gyr& zosb5Keb|AnBpdizd3pKFnKL8$X51W-U|FWO-+mk6f93m+DO09Qo;*1-Gc)X*V&4@N zki>*KhF()pP>`3GhqnB^2JXVWc!F4qLm}8tBLA;LWI~t0e=Sh5aX^70`Mn12!o7F` eo-;8G{`xB0N0000 + + + + + + + + + +llvm-py: Python Bindings for LLVM - llvm-py + + +
+
llvm-py
+
Python Bindings for LLVM
+
+ + + + + +
+ + + + + + + + + + +
+ +
+
+

llvm-py provides Python bindings for +LLVM. It currently provides APIs to build the in-memory IR +(intermediate representation) and to dump it. Execution engine and related APIs +should appear soon.

+

llvm-py is a set of Python-based and C-based Python modules. It makes use of +llvm-c, the C binding for LLVM. It is based on the latest SVN version of LLVM +(and will not work on 2.2). It has been tested only with Python 2.5, although +it should be usable with 2.4 also. I've built and tested it only on Linux/i386 +machines.

+

Download links, setup help and changelog are on the +download page.

+
+
+

News

+
+
+
+20-May-2008 +
+
+

+ 0.1 released. +

+
+
+
+ +
+
+ + diff --git a/www/web/license.html b/www/web/license.html new file mode 100644 index 0000000..6974210 --- /dev/null +++ b/www/web/license.html @@ -0,0 +1,87 @@ + + + + + + + + + + +License - llvm-py + + +
+
llvm-py
+
Python Bindings for LLVM
+
+ + + + + +
+ + + + + + + + + + +
+ +
+
+

llvm-py is distributed under the +new BSD license. +This is similar to LLVM's license. You should be able to use llvm-py +where-ever and how-ever you're able to use LLVM itself.

+

The license text is present in the +LICENSE +file in the distribution, and is reproduced here:

+
+
+
Copyright (c) 2008, Mahadevan R All rights reserved.
+
+Redistribution and use in source and binary forms, with or without
+modification, are permitted provided that the following conditions are met:
+
+  * Redistributions of source code must retain the above copyright notice,
+    this list of conditions and the following disclaimer.
+
+  * Redistributions in binary form must reproduce the above copyright notice,
+    this list of conditions and the following disclaimer in the documentation
+    and/or other materials provided with the distribution.
+
+  * Neither the name of the Mahadevan R, llvm-py nor the names of its
+    contributors may be used to endorse or promote products derived from this
+    software without specific prior written permission.
+
+THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
+ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
+WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
+DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR
+ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
+(INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
+LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
+ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
+SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
+
+
+ +
+
+ + diff --git a/www/web/style/layout.css b/www/web/style/layout.css new file mode 100644 index 0000000..8dc51ae --- /dev/null +++ b/www/web/style/layout.css @@ -0,0 +1,67 @@ + +body { + background-color: white; + margin: 1%; +} + +h1 { + margin-top: 0.5em; +} + +#layout-banner { + background-color: #73a0c5; + color: white; + font-family: sans-serif; + text-align: left; + padding: 0.8em 20px; +} + +#layout-title { + font-family: monospace; + font-size: 3.5em; + font-weight: bold; + letter-spacing: 0.2em; + margin: 0; +} + +#layout-description { + font-size: 1.2em; + letter-spacing: 0.1em; +} + +#layout-menu { + background-color: #f4f4f4; + border-right: 3px solid #eeeeee; + padding-top: 0.8em; + padding-left: 20px; + padding-right: 0.8em; + font-size: 1.1em; + font-family: sans-serif; + font-weight: bold; +} +#layout-menu a { + line-height: 2em; + margin-left: 0.5em; +} +#layout-menu a:link, #layout-menu a:visited, #layout-menu a:hover { + color: #527bbd; + text-decoration: none; +} +#layout-menu a:hover { + color: navy; + text-decoration: none; +} +#layout-menu #page-source { + border-top: 2px solid silver; + margin-top: 0.2em; +} + +#layout-content { + margin-left: 1.0em; + max-width: 600px; +} + +@media print { + #layout-banner { display: none; } + #layout-menu { display: none; } +} diff --git a/www/web/style/xhtml11-manpage.css b/www/web/style/xhtml11-manpage.css new file mode 100644 index 0000000..3ea378a --- /dev/null +++ b/www/web/style/xhtml11-manpage.css @@ -0,0 +1,18 @@ +/* Overrides for manpage documents */ +h1 { + padding-top: 0.5em; + padding-bottom: 0.5em; + border-top: 2px solid silver; + border-bottom: 2px solid silver; +} +h2 { + border-style: none; +} +div.sectionbody { + margin-left: 5%; +} + +@media print { + div#toc { display: none; } +} + diff --git a/www/web/style/xhtml11-quirks.css b/www/web/style/xhtml11-quirks.css new file mode 100644 index 0000000..dbb7775 --- /dev/null +++ b/www/web/style/xhtml11-quirks.css @@ -0,0 +1,40 @@ +/* Workarounds for IE6's broken and incomplete CSS2. */ + +div.sidebar-content { + background: #ffffee; + border: 1px solid silver; + padding: 0.5em; +} +div.sidebar-title, div.image-title { + color: #527bbd; + font-family: sans-serif; + font-weight: bold; + margin-top: 0.0em; + margin-bottom: 0.5em; +} + +div.listingblock div.content { + border: 1px solid silver; + background: #f4f4f4; + padding: 0.5em; +} + +div.quoteblock-content { + padding-left: 2.0em; +} + +div.exampleblock-content { + border-left: 2px solid silver; + padding-left: 0.5em; +} + +/* IE6 sets dynamically generated links as visited. */ +div#toc a:visited { color: blue; } + +/* Because IE6 child selector is broken. */ +div.olist2 ol { + list-style-type: lower-alpha; +} +div.olist2 div.olist ol { + list-style-type: decimal; +} diff --git a/www/web/style/xhtml11.css b/www/web/style/xhtml11.css new file mode 100644 index 0000000..fd931dd --- /dev/null +++ b/www/web/style/xhtml11.css @@ -0,0 +1,276 @@ +/* Debug borders */ +p, li, dt, dd, div, pre, h1, h2, h3, h4, h5, h6 { +/* + border: 1px solid red; +*/ +} + +body { + margin: 1em 5% 1em 5%; +} + +a { + color: blue; + text-decoration: underline; +} +a:visited { + color: fuchsia; +} + +em { + font-style: italic; + color: navy; +} + +strong { + font-weight: bold; + color: #083194; +} + +tt { + color: navy; +} + +h1, h2, h3, h4, h5, h6 { + color: #527bbd; + font-family: sans-serif; + margin-top: 1.2em; + margin-bottom: 0.5em; + line-height: 1.3; +} + +h1, h2, h3 { + border-bottom: 2px solid silver; +} +h2 { + padding-top: 0.5em; +} +h3 { + float: left; +} +h3 + * { + clear: left; +} + +div.sectionbody { + font-family: serif; + margin-left: 0; +} + +hr { + border: 1px solid silver; +} + +p { + margin-top: 0.5em; + margin-bottom: 0.5em; +} + +ul, ol, li > p { + margin-top: 0; +} + +pre { + padding: 0; + margin: 0; +} + +span#author { + color: #527bbd; + font-family: sans-serif; + font-weight: bold; + font-size: 1.1em; +} +span#email { +} +span#revision { + font-family: sans-serif; +} + +div#footer { + font-family: sans-serif; + font-size: small; + border-top: 2px solid silver; + padding-top: 0.5em; + margin-top: 4.0em; +} +div#footer-text { + float: left; + padding-bottom: 0.5em; +} +div#footer-badges { + float: right; + padding-bottom: 0.5em; +} + +div#preamble, +div.tableblock, div.imageblock, div.exampleblock, div.verseblock, +div.quoteblock, div.literalblock, div.listingblock, div.sidebarblock, +div.admonitionblock { + margin-right: 10%; + margin-top: 1.5em; + margin-bottom: 1.5em; +} +div.admonitionblock { + margin-top: 2.5em; + margin-bottom: 2.5em; +} + +div.content { /* Block element content. */ + padding: 0; +} + +/* Block element titles. */ +div.title, caption.title { + color: #527bbd; + font-family: sans-serif; + font-weight: bold; + text-align: left; + margin-top: 1.0em; + margin-bottom: 0.5em; +} +div.title + * { + margin-top: 0; +} + +td div.title:first-child { + margin-top: 0.0em; +} +div.content div.title:first-child { + margin-top: 0.0em; +} +div.content + div.title { + margin-top: 0.0em; +} + +div.sidebarblock > div.content { + background: #ffffee; + border: 1px solid silver; + padding: 0.5em; +} + +div.listingblock { + margin-right: 0%; +} +div.listingblock > div.content { + border: 1px solid silver; + background: #f4f4f4; + padding: 0.5em; +} + +div.quoteblock > div.content { + padding-left: 2.0em; +} + +div.attribution { + text-align: right; +} +div.verseblock + div.attribution { + text-align: left; +} + +div.admonitionblock .icon { + vertical-align: top; + font-size: 1.1em; + font-weight: bold; + text-decoration: underline; + color: #527bbd; + padding-right: 0.5em; +} +div.admonitionblock td.content { + padding-left: 0.5em; + border-left: 2px solid silver; +} + +div.exampleblock > div.content { + border-left: 2px solid silver; + padding: 0.5em; +} + +div.verseblock div.content { + white-space: pre; +} + +div.imageblock div.content { padding-left: 0; } +div.imageblock img { border: 1px solid silver; } +span.image img { border-style: none; } + +dl { + margin-top: 0.8em; + margin-bottom: 0.8em; +} +dt { + margin-top: 0.5em; + margin-bottom: 0; + font-style: normal; +} +dd > *:first-child { + margin-top: 0.1em; +} + +ul, ol { + list-style-position: outside; +} +div.olist > ol { + list-style-type: decimal; +} +div.olist2 > ol { + list-style-type: lower-alpha; +} + +div.tableblock > table { + border: 3px solid #527bbd; +} +thead { + font-family: sans-serif; + font-weight: bold; +} +tfoot { + font-weight: bold; +} + +div.hlist { + margin-top: 0.8em; + margin-bottom: 0.8em; +} +div.hlist td { + padding-bottom: 15px; +} +td.hlist1 { + vertical-align: top; + font-style: normal; + padding-right: 0.8em; +} +td.hlist2 { + vertical-align: top; +} + +@media print { + div#footer-badges { display: none; } +} + +div#toctitle { + color: #527bbd; + font-family: sans-serif; + font-size: 1.1em; + font-weight: bold; + margin-top: 1.0em; + margin-bottom: 0.1em; +} + +div.toclevel1, div.toclevel2, div.toclevel3, div.toclevel4 { + margin-top: 0; + margin-bottom: 0; +} +div.toclevel2 { + margin-left: 2em; + font-size: 0.9em; +} +div.toclevel3 { + margin-left: 4em; + font-size: 0.9em; +} +div.toclevel4 { + margin-left: 6em; + font-size: 0.9em; +} diff --git a/www/web/userguide.html b/www/web/userguide.html new file mode 100644 index 0000000..e05587e --- /dev/null +++ b/www/web/userguide.html @@ -0,0 +1,357 @@ + + + + + + + + + + +llvm-py User Guide - llvm-py + + +
+
llvm-py
+
Python Bindings for LLVM
+
+ + + + + +
+ + + + + + + + + + +
+ +
+
+

llvm-py provides Python bindings for LLVM. This document explains how +you can setup and use it. A working knowledge of Python and a basic idea +of LLVM is assumed.

+
+
+

Introduction

+
+

LLVM (Low-Level Virtual Machine) provides enough +infrastructure to use it as the backend for your compiled, or +JIT-compiled language. It provides extensive optimization support, and +static and dynamic (JIT) backends for many platforms. See the website at +http://www.llvm.org/ to discover more.

+

Python bindings for LLVM provides a gentler learning curve for working +with the LLVM APIs. It should also prove easier to create working +prototypes and experimental languages using this medium.

+
License
+

Both LLVM and llvm-py are distributed under (different) permissive +open source licenses. llvm-py uses the +new BSD license. More +information is available here.

+
Platforms
+

Currently, llvm-py has been built and tested only on Linux/x86. However, +it should be trivial to build it on other unices. Windows is not +supported, for a variety of reasons.

+
Versions
+

As of now, llvm-py requires the latest SVN version of LLVM. It will +not work with version 2.2 of LLVM. However, 2.3 should be release soon, +and llvm-py should work with stock 2.3 LLVM.

+

llvm-py has been built and tested with Python 2.5. It should work with +Python 2.4, with minimal changes, if any.

+
+

Installation

+
+

llvm-py is distributed as a source tarball. You'll need to build and +install it before it can be used. At least the following will be +required for this:

+
    +
  • +

    +compilers, both gcc and g++ +

    +
  • +
  • +

    +Python itself +

    +
  • +
  • +

    +Python development files (headers and libraries) +

    +
  • +
  • +

    +LLVM, either installed or built +

    +
  • +
+

On debian-based systems, the first three can be installed with the +command `sudo apt-get install gcc g++ python python-dev'. Note that +ubuntu repository has an old version of llvm (1.8) which will not work +with llvm-py.

+

llvm-config

+

Inorder to build llvm-py, it's build script needs to know from where to +invoke the llvm helper program, llvm-config. If you've installed LLVM, +then this will be available in your PATH, and nothing further needs to +be done. If you've built LLVM yourself, or for any reason llvm-config +is not in your PATH, you'll need to pass the full path of +llvm-config to the build script.

+

Steps

+

The commands illustrated below assume that the LLVM source is available +under /home/mdevan/llvm. If you've a previous version of llvm-py +installed, you must remove it first, as described +below.

+

If you have llvm-config in your path, you can build and install +llvm-py this way:

+
+
+
$ tar jxvf llvm-py-0.2.tar.bz2
+$ cd llvm-py-0.2
+$ sudo python setup.py install
+
+

If you need to tell the build script where llvm-config is, do it this +way:

+
+
+
$ tar jxvf llvm-py-0.2.tar.bz2
+$ cd llvm-py-0.2
+$ sudo python setup.py install --llvm-config=/home/mdevan/llvm/Release/bin/llvm-config
+
+

To build a debug version of llvm-py, that links against the debug +libraries of LLVM, use this:

+
+
+
$ tar jxvf llvm-py-0.2.tar.bz2
+$ cd llvm-py-0.2
+$ python setup.py build -g --llvm-config=/home/mdevan/llvm/Debug/bin/llvm-config
+$ sudo python setup.py install -g --llvm-config=/home/mdevan/llvm/Debug/bin/llvm-config
+
+

Be warned that debug binaries will be huge (65MB+) !

+

Uninstall

+

To get rid of llvm-py completely, if you wish to do so:

+
+
+
# rm -rf /usr/lib/python2.5/site-packages/llvm
+# rm -f /usr/lib/python2.5/site-packages/llvm_py-0.1.egg-info
+
+
    +
  • +

    +You need to be root to do this. +

    +
  • +
  • +

    +Paths are for debian-based systems, in other distros it might be different. +

    +
  • +
  • +

    +Note that there are version numbers (both Python's and llvm-py's) + which you might need to change to suit your system. +

    +
  • +
+
+

The Concepts

+
+

This section explains a few concepts related to LLVM.

+

Intermediate Representation

+

The intermediate representation, or IR for short, is an in-memory data +structure that represents executable code. The IR data structures allow +for creation of types, constants, functions, function arguments, +instructions, global variables and so on. For example, to create a +function sum that takes two integers and returns their sum, we need to +follow these steps:

+
    +
  • +

    +create an integer type ti of required bitwidth +

    +
  • +
  • +

    +create a function type tf which takes two ti -s and returns + another ti +

    +
  • +
  • +

    +create a function of type tf named sum +

    +
  • +
  • +

    +add a basic block to the function +

    +
  • +
  • +

    +using a helper object called an instruction builder, add two + instructions into the basic block: +

    +
      +
    1. +

      +an instruction to add the two arguments and store the result into + a temporary variable +

      +
    2. +
    3. +

      +a return instruction to return the value of the temporary variable +

      +
    4. +
    +
  • +
+

(A basic block is a block of instructions.)

+

LLVM has it's own instruction set; the instructions used above (add +and ret) are from this set. The LLVM instructions are at a higher +level than the usual assembly language; for example there are +instructions related to variable argument handling, exception handling, +and garbage collection. These allow high-level languages to be +represented cleanly in the IR.

+

The full set of instructions are:

+

TODO

+

SSA Form and PHI Nodes

+

All LLVM instructions are represented in the Static Single Assignment +(SSA) form. Essentially, this means that any variable can be assigned to +only once. Such a representation facilitates better optimization, among +other benefits.

+

A consequence of single assignment are PHI (Φ) nodes. These +are required when a variable can be assigned a different value based on +the path of control flow. For example, the value of b at the end of +execution of the snippet below:

+
+
+
a = 1;
+if (v < 10)
+  a = 2;
+b = a;
+
+

cannot be determined statically. The value of 2 cannot be assigned to +the original a, since a can be assigned to only once. There are +two a 's in there, and the last assignment has to choose between which +version to pick. This is accomplished by adding a PHI node:

+
+
+
a1 = 1;
+if (v < 10)
+  a2 = 2;
+b = PHI(a1, a2);
+
+

The PHI node selects a1 or a2, depending on where the control +reached the PHI node. The argument a1 of the PHI node is associated +with the block "a1 = 1;" and a2 with the block "a2 = 2;".

+

PHI nodes have to be explicitly created in the LLVM IR. The LLVM +instruction set therefore has an instruction called phi.

+

LLVM Assembly Language

+

The LLVM IR can be represented offline in two formats +- a textual, human-readable form, similar to assembly language, called + the LLVM assembly language (files with .ll extension) (XXX ?) +- a binary form, called the LLVM bitcode (files with .bc extension) +All three formats (the in-memory IR, the LLVM assembly language and the +LLVM bitcode) represent the same information. Each format can be +converted into the other two formats (using LLVM APIs).

+

The LLVM demo page lets you type in C or C++ +code, converts it into LLVM IR and outputs the IR as LLVM assembly +language code.

+

Here's a function in C, that calculates the sum of the first n +fibonacci numbers:

+
+
+
int fibsum(int n)
+{
+}
+
+

And here's the corresponding LLVM assembly listing, as provided by the +demo page:

+
+
+
+
+

Note the … TODO …

+

The LLVM Language Reference +defines the LLVM assembly language including the entire instruction set.

+

Modules

+

Modules, in the LLVM IR, are similar to a single C language source +file (.c file). A module contains:

+
    +
  • +

    +functions (declarations and definitions) +

    +
  • +
  • +

    +global variables and constants +

    +
  • +
  • +

    +global type aliases (typedef-s) +

    +
  • +
+

Modules are top-level containers; all executable code representation is +contained within modules.

+

Optimization and Passes

+

LLVM provides quite a few optimization algorithms that work on the IR. +These algorithms are organized as passes. Each pass does something +specific, like combining redundant instructions. Passes need not always +optimize the IR, it can also do other operations like inserting +instrumentation code, or analysing the IR (the result of which can be +used by passes that do optimizations) or even printing call graphs.

+

This LLVM documentation page +describes all the available passes, and what they do.

+

LLVM does not automatically choose to run any passes, anytime. Passes +have to be explicitly selected and run on each module. This gives you +the flexibility to choose transformations and optimizations that are +most suitable for the code in the module.

+

There is a LLVM binary called opt, +which lets you run passes on bitcode files from the command line. You +can write your own passes (in C/C++, as a shared library). This can be +loaded and executed by opt. (Although llvm-py does not allow you to +write your own passes, it does allow you to navigate the entire IR at +any stage, and perform any transforms on it as you like.)

+

Passes are run using a pass manager. For our purposes, there are two

+

Execution Engine

+

TODO

+

BitCode

+

TODO

+

llvm-gcc

+

TODO

+
+

The llvm-py Package

+
+

modules overview: llvm, llvm.core, llvm.ee, llvm.passes

+

importing modules

+

core:

+

types

+

constants

+

values

+
+ +
+
+ +