Chris Lattner
d52c923a50
Add bitcode reader and writer support for ConstantDataAggregate, which
...
should be feature complete now. Lets see if it works.
llvm-svn: 149215
2012-01-30 00:51:16 +00:00
Jim Grosbach
6280a1137f
Better diagnostic for malformed .org assembly directive.
...
Provide source line number information.
llvm-svn: 149101
2012-01-27 00:37:08 +00:00
Jim Grosbach
28639d4913
llvm-mc pass through SourceMgr to MCContext.
...
llvm-svn: 149091
2012-01-26 23:20:07 +00:00
Peter Collingbourne
7d52e812ad
llvm-config: Add support for CMake build trees in which the build
...
mode does not form part of the path.
llvm-svn: 149010
2012-01-26 01:31:38 +00:00
David Blaikie
06ecc99a56
More dead code removal (using -Wunreachable-code)
...
llvm-svn: 148578
2012-01-20 21:51:11 +00:00
Nick Lewycky
c1e7e2eaf6
Add a TargetOption for disabling tail calls.
...
llvm-svn: 148442
2012-01-19 00:34:10 +00:00
David Blaikie
2526691971
Remove unreachable code. (replace with llvm_unreachable to help GCC where necessary)
...
llvm-svn: 148284
2012-01-17 04:43:56 +00:00
Jim Grosbach
acbad56e7f
MCJIT support for non-function sections.
...
Move to a by-section allocation and relocation scheme. This allows
better support for sections which do not contain externally visible
symbols.
Flesh out the relocation address vs. local storage address separation a
bit more as well. Remote process JITs use this to tell the relocation
resolution code where the code will live when it executes.
The startFunctionBody/endFunctionBody interfaces to the JIT and the
memory manager are deprecated. They'll stick around for as long as the
old JIT does, but the MCJIT doesn't use them anymore.
llvm-svn: 148258
2012-01-16 22:26:39 +00:00
Eli Bendersky
973d44eb7c
Adding a basic ELF dynamic loader and MC-JIT for ELF. Functionality is currently basic and will be enhanced with future patches.
...
Patch developed by Andy Kaylor and Daniel Malea. Reviewed on llvm-commits.
llvm-svn: 148231
2012-01-16 08:56:09 +00:00
Jim Grosbach
6c877fabd5
80 columns.
...
llvm-svn: 147970
2012-01-11 21:23:35 +00:00
Jim Grosbach
1a1297e93d
lli should only create memmgr when JITing.
...
llvm-svn: 147969
2012-01-11 21:19:49 +00:00
Jim Grosbach
f3cc53b916
lli should create a JIT memory manager.
...
Previously let the JITEmitter do it. That's rather odd, and doesn't play nice
with the MCJIT, so move the (trivial) logic up.
llvm-svn: 147967
2012-01-11 21:12:51 +00:00
David Blaikie
8d47bb30e3
Remove unnecessary default cases in switches that cover all enum values.
...
llvm-svn: 147855
2012-01-10 16:47:17 +00:00
Rafael Espindola
6b018e0b1d
Remove the logging streamer.
...
llvm-svn: 147820
2012-01-10 00:40:39 +00:00
Rafael Espindola
2d545fa143
Split Finish into Finish and FinishImpl to have a common place to do end of
...
file error checking. Use that to error on an unfinished cfi_startproc.
The error is not nice, but is already better than a segmentation fault.
llvm-svn: 147717
2012-01-07 03:13:18 +00:00
Nick Lewycky
ed7856bd5b
Remove extraneous ".get()->" which is just "->". No functionality change.
...
llvm-svn: 147379
2011-12-30 19:17:23 +00:00
Bill Wendling
82ca4569b9
Add braces to remove silly warning.
...
llvm-svn: 147264
2011-12-25 06:56:22 +00:00
Rafael Espindola
b598485fb9
Remove unused variables.
...
llvm-svn: 147261
2011-12-25 01:20:19 +00:00
Dylan Noblesmith
40dea4f20c
drop unneeded config.h includes
...
llvm-svn: 147197
2011-12-22 23:04:07 +00:00
David Blaikie
576aba04f1
Unweaken vtables as per http://llvm.org/docs/CodingStandards.html#ll_virtual_anch
...
llvm-svn: 146960
2011-12-20 02:50:00 +00:00
Daniel Dunbar
68de82c003
llvm-config: Fix --targets-built, I changed this to use the registry but wasn't
...
properly initializing the target infos. I decided it wasn't worth linking them
in for this, so just switched back to using the Makefile variable for now. We
can reconsider later if we ever get pluggable targets.
llvm-svn: 146711
2011-12-16 00:04:43 +00:00
Daniel Dunbar
f961e224ec
llvm-config: Update help text for removal of "backend" pseudo component.
...
llvm-svn: 146708
2011-12-15 23:43:17 +00:00
Michael J. Spencer
02c5e58b03
llvm-nm: refactor in order to support reading files from stdin.
...
llvm-svn: 146524
2011-12-13 23:17:29 +00:00
Daniel Dunbar
b72534060e
LLVMBuild: Introduce a common section which currently has a list of the
...
subdirectories to traverse into.
- Originally I wanted to avoid this and just autoscan, but this has one key
flaw in that new subdirectories can not automatically trigger a rerun of the
llvm-build tool. This is particularly a pain when switching back and forth
between trees where one has added a subdirectory, as the dependencies will
tend to be wrong. This will also eliminates FIXME implicitly.
llvm-svn: 146436
2011-12-12 22:45:54 +00:00
Daniel Dunbar
30d6a45140
LLVMBuild: Remove trailing newline, which irked me.
...
llvm-svn: 146409
2011-12-12 19:48:00 +00:00
Daniel Dunbar
e6cf061866
llvm-config: Default to "all" if no components are specified.
...
- Fixes PR11530.
llvm-svn: 146388
2011-12-12 18:22:04 +00:00
Kevin Enderby
63cf89d532
The second part of support for generating dwarf for assembly source files. This
...
generates the dwarf Compile Unit DIE and a dwarf subprogram DIE for each
non-temporary label.
The next part will be to get the clang driver to enable this when assembling
a .s file. rdar://9275556
llvm-svn: 146262
2011-12-09 18:09:40 +00:00
Chad Rosier
e3225d38e4
Update bcanalyzer to handle new USELIST_BLOCK/USELIST_CODE_ENTRY.
...
llvm-svn: 146079
2011-12-07 21:45:13 +00:00
Duncan Sands
cc43a2e4fd
Have cmake build llvm-cov. Patch by arrowdodger.
...
llvm-svn: 146071
2011-12-07 20:54:41 +00:00
Duncan Sands
b5e4020ddb
When doing "opt -O2" verify the bitcode like is done for
...
"opt -std-compile-opts".
llvm-svn: 146036
2011-12-07 17:14:20 +00:00
Jim Grosbach
9112c6a3ee
Tidy up.
...
llvm-svn: 145870
2011-12-05 23:20:14 +00:00
Nick Lewycky
7d0d3c2d58
Move global variables in TargetMachine into new TargetOptions class. As an API
...
change, now you need a TargetOptions object to create a TargetMachine. Clang
patch to follow.
One small functionality change in PTX. PTX had commented out the machine
verifier parts in their copy of printAndVerify. That now calls the version in
LLVMTargetMachine. Users of PTX who need verification disabled should rely on
not passing the command-line flag to enable it.
llvm-svn: 145714
2011-12-02 22:16:29 +00:00
Daniel Dunbar
3c06b26f09
llvm-config: Replace with C++ version (was llvm-config-2).
...
- Another reapply of r144300, with hopefully one last fix.
llvm-svn: 145623
2011-12-01 20:18:09 +00:00
Daniel Dunbar
884620418e
llvm-config-2: Fix --cflags and --includedir which pointed at the wrong
...
directory when running from a build directory.
llvm-svn: 145622
2011-12-01 20:00:19 +00:00
Duncan Sands
84beef543d
Revert commit 145449 (ddunbar) since it is breaking the dragonegg buildbots.
...
Original commit message:
llvm-config: Replace with C++ version (was llvm-config-2).
- Reapply of r144300, with lots of fixes/migration easement in between.
llvm-svn: 145582
2011-12-01 10:50:19 +00:00
Daniel Dunbar
7dcd93d4fa
llvm-config: Replace with C++ version (was llvm-config-2).
...
- Reapply of r144300, with lots of fixes/migration easement in between.
llvm-svn: 145449
2011-11-29 22:56:31 +00:00
Danil Malyshev
5ce4e1a9d3
Fixed ObjectFile functions:
...
- getSymbolOffset() renamed as getSymbolFileOffset()
- getSymbolFileOffset(), getSymbolAddress(), getRelocationAddress() returns same result for ELFObjectFile, MachOObjectFile and COFFObjectFile.
- added getRelocationOffset()
- fixed MachOObjectFile::getSymbolSize()
- fixed MachOObjectFile::getSymbolSection()
- fixed MachOObjectFile::getSymbolOffset() for symbols without section data.
llvm-svn: 145408
2011-11-29 17:40:10 +00:00
Daniel Dunbar
7c4510b4de
edis: Sink EDMain.cpp into lib/MC/MCDisassembler.
...
- This fixes some layering violations and matches how we handle the llvm-c lib,
for example.
llvm-svn: 145338
2011-11-29 00:25:57 +00:00
Daniel Dunbar
85c716fd09
edis: Don't do the target initialization in EDGetDisassembler, this is contrary
...
to the way we currently expect target selection to work -- clients are supposed
to have control over what targets are available.
llvm-svn: 145331
2011-11-29 00:06:58 +00:00
Daniel Dunbar
f1c738305f
build/Make: edis isn't built as a shared library anymore, remove related cruft from the Makefile.
...
llvm-svn: 145329
2011-11-29 00:06:53 +00:00
Chandler Carruth
e5e455c97f
Revert r145180 as it is causing test failures on all the bots.
...
Original commit message:
Fixed ObjectFile functions:
- getSymbolOffset() renamed as getSymbolFileOffset()
- getSymbolFileOffset(), getSymbolAddress(), getRelocationAddress() returns same result for ELFObjectFile, MachOObjectFile and COFFObjectFile.
- added getRelocationOffset()
- fixed MachOObjectFile::getSymbolSize()
- fixed MachOObjectFile::getSymbolSection()
- fixed MachOObjectFile::getSymbolOffset() for symbols without section data.
llvm-svn: 145182
2011-11-27 10:37:47 +00:00
Danil Malyshev
3bbe062799
Fixed ObjectFile functions:
...
- getSymbolOffset() renamed as getSymbolFileOffset()
- getSymbolFileOffset(), getSymbolAddress(), getRelocationAddress() returns same result for ELFObjectFile, MachOObjectFile and COFFObjectFile.
- added getRelocationOffset()
- fixed MachOObjectFile::getSymbolSize()
- fixed MachOObjectFile::getSymbolSection()
- fixed MachOObjectFile::getSymbolOffset() for symbols without section data.
llvm-svn: 145180
2011-11-27 10:12:52 +00:00
Chris Lattner
03be469732
remove support for reading llvm 2.9 .bc files. LLVM 3.1 is only compatible back to 3.0
...
llvm-svn: 145164
2011-11-27 05:48:27 +00:00
Rafael Espindola
17a991f91c
Point to libLTO with -L/PATH/ -lLTO so that it is found in the install
...
directory.
Patch by Markus Trippelsdorf.
llvm-svn: 145095
2011-11-23 03:07:25 +00:00
Evan Cheng
2b239cbcf6
Sink codegen optimization level into MCCodeGenInfo along side relocation model
...
and code model. This eliminates the need to pass OptLevel flag all over the
place and makes it possible for any codegen pass to use this information.
llvm-svn: 144788
2011-11-16 08:38:26 +00:00
Michael J. Spencer
70bc3d6855
llvm-objdump: Ignore non-objects in archives.
...
llvm-svn: 144755
2011-11-16 01:24:41 +00:00
Benjamin Kramer
a2f57dee6d
Remove all remaining uses of Value::getNameStr().
...
llvm-svn: 144648
2011-11-15 16:27:03 +00:00
Daniel Dunbar
f7435b501a
llvm-config-2: Detect when we are running out of a BuildTools development tree, so that we can always provide library/include information for the real build directory.
...
llvm-svn: 144420
2011-11-11 22:59:47 +00:00
Daniel Dunbar
efa02a0c3d
LLVMBuild: Add description files for the LLVM tools.
...
llvm-svn: 144417
2011-11-11 22:59:39 +00:00
Benjamin Kramer
a52be4ff03
Clients are responsible for initializing the targets, remove it from the disassembler API.
...
This will break users of the LLVMCreateDisasm API (not that I know of any). They have to call the
LLVMInitializeAll* functions from llvm-c/Target.h themselves now. edis' C API in all its horribleness
should be unaffected.
llvm-svn: 144385
2011-11-11 13:20:40 +00:00