summaryrefslogtreecommitdiff
path: root/examples
Commit message (Collapse)AuthorAge
* Changed comments on foreign C++ exceptions (generated with type info 7), Garrison Venn2011-09-28
| | | | | | | | | handling with references to http://sourcery.mentor.com/public/cxx-abi/abi-eh.html (r 1.22). git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@140695 91177308-0d34-0410-b5e6-96231b3b80d8
* Modified demo to use 3.0 resume instruction vs calling _Unwine_Resume.Garrison Venn2011-09-23
| | | | | | | | | | | | | | | | Also conducted some reformatting. As the LLVM coding standard doc does not seem to touch on how to align function arguments, and format code longer than 80 cols in general, the confusion persists. There is the golden rule, but as this code has gone through several styles to deal with this, the golden rule seems to be ignored. The latest reformatting effort tries to match the other source files as much as possible. Tested on OS X 10.7.1 with, and without the OLD_EXC_SYSTEM defined. Have NOT tested on LINUX. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@140379 91177308-0d34-0410-b5e6-96231b3b80d8
* Converted Exception demo over to using new 3.0 landingpad instruction. ThisGarrison Venn2011-09-22
| | | | | | | | | was compiled and tested on OS X 10.7.1. It was not tested on LINUX. In addition the defined OLD_EXC_SYSTEM was not tested with this version. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@140303 91177308-0d34-0410-b5e6-96231b3b80d8
* This is a hack to get the demo working with the new 3.0 exception Garrison Venn2011-09-22
| | | | | | | | | | | infrastructure. As this makes the demo no longer a demo, and especially not a demo on how to use the llvm exception mechanism, this hack will shortly be changed to use the new 3.0 exception infrastructure. However for the time being this demo is an example on how to use the AutoUpgrade UpgradeExceptionHandling(...) function on < 3.0 exception handling code. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@140301 91177308-0d34-0410-b5e6-96231b3b80d8
* Move TargetRegistry and TargetSelect from Target to Support where they belong.Evan Cheng2011-08-24
| | | | | | | These are strictly utilities for registering targets and components. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@138450 91177308-0d34-0410-b5e6-96231b3b80d8
* Convert ConstantExpr::getGetElementPtr andJay Foad2011-07-21
| | | | | | | ConstantExpr::getInBoundsGetElementPtr to use ArrayRef. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@135673 91177308-0d34-0410-b5e6-96231b3b80d8
* update for recent api changes. I have a hard time believing that this is ↵Chris Lattner2011-07-18
| | | | | | actually a useful example. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@135374 91177308-0d34-0410-b5e6-96231b3b80d8
* update this to build with a recent IRBuilder change and de-constify types.Chris Lattner2011-07-18
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@135373 91177308-0d34-0410-b5e6-96231b3b80d8
* Convert CallInst and InvokeInst APIs to use ArrayRef. For the LLVM examples.Francois Pichet2011-07-15
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@135266 91177308-0d34-0410-b5e6-96231b3b80d8
* Change Intrinsic::getDeclaration and friends to take an ArrayRef.Benjamin Kramer2011-07-14
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@135154 91177308-0d34-0410-b5e6-96231b3b80d8
* Remove the const from Type after of Jay deconstify work.Francois Pichet2011-07-12
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@135000 91177308-0d34-0410-b5e6-96231b3b80d8
* Reverted 134901 because of 134959. Did not use svn merge -r but rather:Garrison Venn2011-07-12
| | | | | | | | | | | | | | | 1,$s/llvm::Type::getInt\(..\)Ty(builder.getContext())/builder.getInt\1Ty()/g 1,$s/builder.getInt\(..*\)Ty()->getPointerTo()/builder.getInt\1PtrTy()/g vi sub commands (second one was not a reversion but requested by Tobias Grosser. Mod was tested, but other examples have failed to build as they are currently being thrashed with the const qualifier removal change. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@134985 91177308-0d34-0410-b5e6-96231b3b80d8
* Fix the BrainF build.Francois Pichet2011-07-12
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@134975 91177308-0d34-0410-b5e6-96231b3b80d8
* fix some examplesJohn Wiegley2011-07-11
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@134933 91177308-0d34-0410-b5e6-96231b3b80d8
* Modified demo to work with non const Type parameters as is required by newGarrison Venn2011-07-11
| | | | | | | | | | | | | type system. However most of these modifications were due to IRBuilder (IRBuilderBase), not having been modified to NOT return such const qualified free types. If IRBuilder does not change, as can also be seen in its instruction creation methods, to use const free types, it may be useful to have ExceptionDemo drop IRBuilder usage. Modifying builder.getInt32Ty() to llvm::Type::getInt32Ty(builder.getContext()) is pretty ugly. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@134901 91177308-0d34-0410-b5e6-96231b3b80d8
* Modify comment.Johnny Chen2011-06-09
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@132800 91177308-0d34-0410-b5e6-96231b3b80d8
* Have the JIT tutorial use IRBuilder for the IR.Eric Christopher2011-06-09
| | | | | | | Patch by Jake Waskett! git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@132770 91177308-0d34-0410-b5e6-96231b3b80d8
* Fix a ton of comment typos found by codespell. Patch byChris Lattner2011-04-15
| | | | | | | | Luis Felipe Strano Moraes! git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@129558 91177308-0d34-0410-b5e6-96231b3b80d8
* Added new FIXME noteGarrison Venn2011-04-12
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@129360 91177308-0d34-0410-b5e6-96231b3b80d8
* Get rid of useless comment; if a file uses functions from a given header,Eli Friedman2011-04-11
| | | | | | | | it is obvious that it should be included. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@129295 91177308-0d34-0410-b5e6-96231b3b80d8
* Because some systems have reported that this example would not build theGarrison Venn2011-04-11
| | | | | | | | header file cstdio was added as an include. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@129291 91177308-0d34-0410-b5e6-96231b3b80d8
* Fixed more best practices, and explicit/implicit style guide issues.Garrison Venn2011-04-10
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@129245 91177308-0d34-0410-b5e6-96231b3b80d8
* reindent this whole file and do a variety of stylistic cleanups.Chris Lattner2011-04-08
| | | | | | | This code is still a long way from following best practices. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@129140 91177308-0d34-0410-b5e6-96231b3b80d8
* fix this to build with the recent StructType changes.Chris Lattner2011-04-08
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@129139 91177308-0d34-0410-b5e6-96231b3b80d8
* Remove PHINode::reserveOperandSpace(). Instead, add a parameter toJay Foad2011-03-30
| | | | | | PHINode::Create() giving the (known or expected) number of operands. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@128537 91177308-0d34-0410-b5e6-96231b3b80d8
* (Almost) always call reserveOperandSpace() on newly created PHINodes.Jay Foad2011-03-30
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@128535 91177308-0d34-0410-b5e6-96231b3b80d8
* Fix compiling the ocaml kaleidoscope tutorialsErick Tryzelaar2011-02-09
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@125202 91177308-0d34-0410-b5e6-96231b3b80d8
* Do not re-test for the existence of pthread.h.Oscar Fuentes2010-12-23
| | | | | | It was causing problems on the MinGW build. See PR8849. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@122518 91177308-0d34-0410-b5e6-96231b3b80d8
* Fix missing includes of "llvm/Analysis/Passes.h" in the tutorials. ThanksDan Gohman2010-11-16
| | | | | | | for Arnaud Allard de Grandmaison for preparing a patch. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@119351 91177308-0d34-0410-b5e6-96231b3b80d8
* Update examples and documentation to explicitly add basicaa, now that it'sDan Gohman2010-11-15
| | | | | | | no longer included by default. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@119169 91177308-0d34-0410-b5e6-96231b3b80d8
* Build with RTTI and exceptions disabled. Only in GCC for now.Oscar Fuentes2010-10-17
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@116682 91177308-0d34-0410-b5e6-96231b3b80d8
* Convert a bunch of uses of 'bytecode' into 'bitcode'. ThisDuncan Sands2010-09-29
| | | | | | | is not everything, but the remaining cases are less trivial. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@115080 91177308-0d34-0410-b5e6-96231b3b80d8
* Removed TracingBrainF from examples Makefile.Garrison Venn2010-09-15
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@113970 91177308-0d34-0410-b5e6-96231b3b80d8
* Revert "CMake: Get rid of LLVMLibDeps.cmake and export the libraries normally."Michael J. Spencer2010-09-13
| | | | | | | | | | This reverts commit r113632 Conflicts: cmake/modules/AddLLVM.cmake git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@113819 91177308-0d34-0410-b5e6-96231b3b80d8
* CMake: Get rid of LLVMLibDeps.cmake and export the libraries normally.Michael J. Spencer2010-09-10
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@113632 91177308-0d34-0410-b5e6-96231b3b80d8
* fit in 80 columns and don't crash on exit, fixes PR8080Chris Lattner2010-09-05
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@113123 91177308-0d34-0410-b5e6-96231b3b80d8
* Remove this from the main tree. I'll host it out of tree.Owen Anderson2010-08-30
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@112529 91177308-0d34-0410-b5e6-96231b3b80d8
* Add a new example to the LLVM distribution: a trace-based Brainfuck compiler ↵Owen Anderson2010-08-30
| | | | | | that uses LLVM as its code generator. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@112465 91177308-0d34-0410-b5e6-96231b3b80d8
* Trailing whitespace.Mikhail Glushenkov2010-08-19
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@111552 91177308-0d34-0410-b5e6-96231b3b80d8
* upgrade to use new intrinsics, patch by Dan Hipschman!Chris Lattner2010-08-10
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@110735 91177308-0d34-0410-b5e6-96231b3b80d8
* Convert some tab stops into spaces.Duncan Sands2010-07-12
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@108130 91177308-0d34-0410-b5e6-96231b3b80d8
* Fix up the ocaml kaleidoscope example as well.Eric Christopher2010-07-12
| | | | | | | Note that the example currently doesn't appear to work. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@108121 91177308-0d34-0410-b5e6-96231b3b80d8
* fix several bugs in the tutorial, patch by Kevin Kelley!Chris Lattner2010-06-21
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@106498 91177308-0d34-0410-b5e6-96231b3b80d8
* Remove stray semi-colon.Daniel Dunbar2010-06-15
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@106009 91177308-0d34-0410-b5e6-96231b3b80d8
* Make kaleidoscope use fp add/sub/mul.Eric Christopher2010-06-14
| | | | | | | Patch by Patrick Flannery! git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@105932 91177308-0d34-0410-b5e6-96231b3b80d8
* Remove the -enable-sjlj-eh option, which doesn't do anything.Duncan Sands2010-05-02
| | | | | | | | Remove the -enable-eh option which is only used by the JIT, and replace it with -jit-enable-eh. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@102865 91177308-0d34-0410-b5e6-96231b3b80d8
* Use provided llvm-defined variables instead of twisting user-controlled knobs.Nick Lewycky2010-04-24
| | | | | | | No visible change. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@102240 91177308-0d34-0410-b5e6-96231b3b80d8
* Fix -Wcast-qual warning.Benjamin Kramer2010-04-20
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@101894 91177308-0d34-0410-b5e6-96231b3b80d8
* Fix the ocaml kaleidoscope tutorial to fix linking external libraries.Erick Tryzelaar2010-03-21
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@99151 91177308-0d34-0410-b5e6-96231b3b80d8
* Don't always run the ocaml kaleidoscope tutorials.Erick Tryzelaar2010-03-08
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@97973 91177308-0d34-0410-b5e6-96231b3b80d8