Commit Graph

215 Commits

Author SHA1 Message Date
NAKAMURA Takumi 1373b743bb ExceptionDemo.cpp: Tweak a @param. [-Wdocumentation]
llvm-svn: 187351
2013-07-29 11:03:50 +00:00
Andrew Kaylor a23ea166dd Adding example source to support MCJIT/Kaleidoscope blog posts.
llvm-svn: 186854
2013-07-22 18:47:24 +00:00
Rafael Espindola 5dfe843a2c Remove unused fields.
llvm-svn: 186791
2013-07-21 12:42:16 +00:00
Logan Chien 8a61aab88e Fix exception demo: Add mcjit to link component.
Fix exception demo when we are building the examples with configure/make.
This commit updates the link components in the Makefile.

llvm-svn: 186785
2013-07-21 03:46:55 +00:00
Rafael Espindola f9a2619930 Update the examples for an API change.
llvm-svn: 186453
2013-07-16 20:22:35 +00:00
NAKAMURA Takumi b734a9dbc6 ExceptionDemo: Corresponding to r181820, SectionMemoryManager should belong to RTDyldMemoryManager.
llvm-svn: 181844
2013-05-14 23:05:00 +00:00
Rafael Espindola 9a383405a7 Remove exception handling support from the old JIT.
llvm-svn: 181354
2013-05-07 20:53:59 +00:00
Rafael Espindola e93dc3be1b Port ExceptionDemo to MCJIT.
llvm-svn: 181168
2013-05-05 20:57:58 +00:00
Rafael Espindola 5096adfb12 Add support for other typeinfo encodings in the ExceptionDemo.
The old jit always uses DW_EH_PE_absptr, but MCJIT can use other encodings.
This is in preparation for adding EH support to MCJIT, but not directly
related, so I am committing it first.

llvm-svn: 180883
2013-05-01 21:05:05 +00:00
Rafael Espindola 03ee04bef6 The exception demo needs its symbols exported.
llvm-svn: 180622
2013-04-26 19:07:40 +00:00
Dmitri Gribenko 462462e98d Update links to "Itanium C++ ABI: Exception Handling" document
llvm-svn: 172356
2013-01-13 15:53:09 +00:00
Chandler Carruth 005f27a0d3 Update the examples for the new header file locations.
Sorry for the fallout here, I forgot the examples aren't built by
default any more.

llvm-svn: 171371
2013-01-02 11:56:33 +00:00
Chandler Carruth 605e30e93c Sort the #include lines of the examples/... tree.
llvm-svn: 169249
2012-12-04 10:16:57 +00:00
Rafael Espindola e42945c033 Fix gcc's -Wunused-but-set-variable warnings.
llvm-svn: 168576
2012-11-26 00:56:44 +00:00
Micah Villmow 51e7246cb4 Back out r166591, not sure why this made it through since I cancelled the command. Bleh, sorry about this!
llvm-svn: 166596
2012-10-24 17:25:11 +00:00
Micah Villmow 6a8f3f9e20 Delete a directory that wasn't supposed to be checked in yet.
llvm-svn: 166591
2012-10-24 17:20:04 +00:00
Quentin Colombet 301d05a55c Test commit access
llvm-svn: 166481
2012-10-23 16:03:18 +00:00
NAKAMURA Takumi 8489be8d1c ExceptionDemo.cpp: Use Function::setDoesNotReturn(). Attributes stuff was updated.
llvm-svn: 165796
2012-10-12 14:11:48 +00:00
NAKAMURA Takumi 8e70dd595c ExceptionDemo.cpp: Whitespace.
llvm-svn: 165795
2012-10-12 14:11:43 +00:00
Micah Villmow 6bf5825b3d Move TargetData to DataLayout.
llvm-svn: 165401
2012-10-08 16:37:04 +00:00
Chandler Carruth aafe0918bc Move llvm/Support/IRBuilder.h -> llvm/IRBuilder.h
This was always part of the VMCore library out of necessity -- it deals
entirely in the IR. The .cpp file in fact was already part of the VMCore
library. This is just a mechanical move.

I've tried to go through and re-apply the coding standard's preferred
header sort, but at 40-ish files, I may have gotten some wrong. Please
let me know if so.

I'll be committing the corresponding updates to Clang and Polly, and
Duncan has DragonEgg.

Thanks to Bill and Eric for giving the green light for this bit of cleanup.

llvm-svn: 159421
2012-06-29 12:38:19 +00:00
Arnaud A. de Grandmaison 503ca9e6a7 Remove trailing whitespaces
llvm-svn: 158943
2012-06-21 22:26:01 +00:00
Benjamin Kramer bde9176663 Fix typos found by http://github.com/lyda/misspell-check
llvm-svn: 157885
2012-06-02 10:20:22 +00:00
Michael J. Spencer 9125493efe Remove llvm-ld and llvm-stub (which is only used by llvm-ld).
llvm-ld is no longer useful and causes confusion and so it is being removed.

* Does not work very well on Windows because it must call a gcc like driver to
  assemble and link.
* Has lots of hard coded paths which are wrong on many systems.
* Does not understand most of ld's options.
* Can be partially replaced by llvm-link | opt | {llc | as, llc -filetype=obj} |
  ld, or fully replaced by Clang.

I know of no production use of llvm-ld, and hacking use should be
replaced by Clang's driver.

llvm-svn: 155147
2012-04-19 19:27:54 +00:00
Chandler Carruth 3bb7d41a35 Switch to a more idiomatic way of silencing unused variable warnings in
release builds. Silences clang's -Wself-assign.

llvm-svn: 150942
2012-02-20 00:02:49 +00:00
Peter Collingbourne c4e342b733 Update ExceptionDemo to use ConstantDataArray.
llvm-svn: 149867
2012-02-06 14:09:13 +00:00
Bill Wendling 383727b63c Update to the new EH system...remove OLD EH code.
llvm-svn: 149728
2012-02-04 00:29:12 +00:00
Francois Pichet 4ce6e6ef87 Fix BrainF compilation.
llvm-svn: 149375
2012-01-31 09:35:01 +00:00
Daniel Dunbar 27a7489a03 LLVMBuild: Remove trailing newline, which irked me.
llvm-svn: 146409
2011-12-12 19:48:00 +00:00
Peter Collingbourne dff247868a EngineBuilder: support for custom TargetOptions. Fixes the
ExceptionDemo example.

llvm-svn: 146108
2011-12-07 23:58:57 +00:00
Daniel Dunbar bf9bba47a1 build: Add initial cut at LLVMBuild.txt files.
llvm-svn: 143634
2011-11-03 18:53:17 +00:00
Garrison Venn 56c58ce3d6 Changed comments on foreign C++ exceptions (generated with type info 7),
handling with references to 
http://sourcery.mentor.com/public/cxx-abi/abi-eh.html (r 1.22).

llvm-svn: 140695
2011-09-28 10:53:56 +00:00
Garrison Venn 0a2eb8d35d Modified demo to use 3.0 resume instruction vs calling _Unwine_Resume.
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.

llvm-svn: 140379
2011-09-23 14:45:10 +00:00
Garrison Venn 8cb0035ee9 Converted Exception demo over to using new 3.0 landingpad instruction. This
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.

llvm-svn: 140303
2011-09-22 15:45:14 +00:00
Garrison Venn eb89d36b9d This is a hack to get the demo working with the new 3.0 exception
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.                          

llvm-svn: 140301
2011-09-22 14:07:50 +00:00
Evan Cheng 2bb4035707 Move TargetRegistry and TargetSelect from Target to Support where they belong.
These are strictly utilities for registering targets and components.

llvm-svn: 138450
2011-08-24 18:08:43 +00:00
Jay Foad ed8db7d9df Convert ConstantExpr::getGetElementPtr and
ConstantExpr::getInBoundsGetElementPtr to use ArrayRef.

llvm-svn: 135673
2011-07-21 14:31:17 +00:00
Chris Lattner 805d09459d update for recent api changes. I have a hard time believing that this is actually a useful example.
llvm-svn: 135374
2011-07-18 04:52:58 +00:00
Chris Lattner 6b8eb8cd71 update this to build with a recent IRBuilder change and de-constify types.
llvm-svn: 135373
2011-07-18 04:52:09 +00:00
Francois Pichet c5d10504d5 Convert CallInst and InvokeInst APIs to use ArrayRef. For the LLVM examples.
llvm-svn: 135266
2011-07-15 10:59:52 +00:00
Benjamin Kramer e6e1933f31 Change Intrinsic::getDeclaration and friends to take an ArrayRef.
llvm-svn: 135154
2011-07-14 17:45:39 +00:00
Francois Pichet ce206000d3 Remove the const from Type after of Jay deconstify work.
llvm-svn: 135000
2011-07-12 22:04:11 +00:00
Garrison Venn 76310ac9be Reverted 134901 because of 134959. Did not use svn merge -r but rather:
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.

llvm-svn: 134985
2011-07-12 15:34:42 +00:00
Francois Pichet ccc50d7cf4 Fix the BrainF build.
llvm-svn: 134975
2011-07-12 08:43:36 +00:00
John Wiegley 2a0177ba4c fix some examples
llvm-svn: 134933
2011-07-11 22:39:46 +00:00
Garrison Venn 5fb3f66516 Modified demo to work with non const Type parameters as is required by new
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.

llvm-svn: 134901
2011-07-11 16:31:53 +00:00
Johnny Chen 9e4b689923 Modify comment.
llvm-svn: 132800
2011-06-09 20:11:46 +00:00
Eric Christopher 8ad343f292 Have the JIT tutorial use IRBuilder for the IR.
Patch by Jake Waskett!

llvm-svn: 132770
2011-06-09 05:58:50 +00:00
Chris Lattner 0ab5e2cded Fix a ton of comment typos found by codespell. Patch by
Luis Felipe Strano Moraes!

llvm-svn: 129558
2011-04-15 05:18:47 +00:00
Garrison Venn a0f6ecb01f Added new FIXME note
llvm-svn: 129360
2011-04-12 12:30:10 +00:00