summaryrefslogtreecommitdiffstats
path: root/llvm/lib/MC/MCDisassembler
Commit message (Collapse)AuthorAgeFilesLines
* Whitespace.Chad Rosier2012-07-181-18/+14
| | | | llvm-svn: 160445
* Add accessors for all private members of DisasmContext.Benjamin Kramer2012-06-061-0/+8
| | | | | | LLVM should be -Wunused-private-field clean now. llvm-svn: 158103
* Compress MCRegisterInfo register name tables.Jakob Stoklund Olesen2012-05-251-1/+1
| | | | | | | Store (debugging) register names as offsets into a string table instead of as char pointers. llvm-svn: 157449
* Mark some static arrays as const.Craig Topper2012-05-241-1/+1
| | | | llvm-svn: 157377
* Fixed two leaks in the MC disassembler. The MCSean Callanan2012-04-062-1/+13
| | | | | | | | | | | | | | | disassembler requires a MCSubtargetInfo and a MCInstrInfo to exist in order to initialize the instruction printer and disassembler; however, although the printer and disassembler keep references to these objects they do not own them. Previously, the MCSubtargetInfo and MCInstrInfo objects were just leaked. I have extended LLVMDisasmContext to own these objects and delete them when it is destroyed. llvm-svn: 154192
* Make MCInstrInfo available to the MCInstPrinter. This will be used to remove ↵Craig Topper2012-04-023-4/+16
| | | | | | getInstructionName and the static data it contains since the same tables are already in MCInstrInfo. llvm-svn: 153860
* Make MCRegisterInfo available to the the MCInstPrinter.Jim Grosbach2012-03-052-2/+3
| | | | | | | Used to allow context sensitive printing of super-register or sub-register references. llvm-svn: 152043
* Make MemoryObject accessor members const againDerek Schuff2012-02-292-4/+4
| | | | llvm-svn: 151687
* Switch the llvm::Triple class to immediately parse the triple string onChandler Carruth2012-02-211-4/+1
| | | | | | | | | construction. Simplify its interface, implementation, and users accordingly as there is no longer an 'uninitialized' state to check for. Also, fixes a bug lurking in the interface as there was one method that didn't correctly check for initialization. llvm-svn: 151024
* Remove dead code. Improve llvm_unreachable text. Simplify some control flow.Ahmed Charles2012-02-191-16/+11
| | | | llvm-svn: 150918
* Fix typo in comment ldopen() -> dlopen().Kevin Enderby2012-02-171-1/+1
| | | | llvm-svn: 150836
* Put back the initializing the targets in the disassembler API with a comment asKevin Enderby2012-02-171-0/+13
| | | | | | | to why this is needed. This broke the darwin's otool(1) program. This change was made in r144385. llvm-svn: 150832
* Convert assert(0) to llvm_unreachableCraig Topper2012-02-071-1/+1
| | | | llvm-svn: 149967
* Enable streaming of bitcodeDerek Schuff2012-02-062-4/+4
| | | | | | | This CL delays reading of function bodies from initial parse until materialization, allowing overlap of compilation with bitcode download. llvm-svn: 149918
* Modified the Enhanced Disassembler to create andSean Callanan2012-02-043-31/+40
| | | | | | | | | | cache disassemblers according to the string value of the target triple, not according to the enum of the triple CPU. The reason for this is that certain attributes of the instruction set are not reflected in the enum, but only in the string. llvm-svn: 149773
* More dead code removal (using -Wunreachable-code)David Blaikie2012-01-202-5/+2
| | | | llvm-svn: 148578
* Fix some leftover control reaches end of non-void function warnings.Benjamin Kramer2012-01-101-6/+5
| | | | llvm-svn: 147874
* Remove unnecessary default cases in switches that cover all enum values.David Blaikie2012-01-101-2/+0
| | | | llvm-svn: 147855
* build/CMake: Finish removal of add_llvm_library_dependencies.Daniel Dunbar2011-11-291-6/+0
| | | | llvm-svn: 145420
* build: Update CMakeLists.txt.Daniel Dunbar2011-11-291-0/+1
| | | | llvm-svn: 145341
* edis: Sink EDMain.cpp into lib/MC/MCDisassembler.Daniel Dunbar2011-11-291-0/+280
| | | | | | | - This fixes some layering violations and matches how we handle the llvm-c lib, for example. llvm-svn: 145338
* build: Attempt to rectify inconsistencies between CMake and LLVMBuild ↵Daniel Dunbar2011-11-121-17/+0
| | | | | | | | versions of explicit dependencies. - The hope is that we have a tool/test to verify these are accurate (and tight) soon. llvm-svn: 144444
* Clients are responsible for initializing the targets, remove it from the ↵Benjamin Kramer2011-11-114-32/+1
| | | | | | | | | | 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
* build/MCDisassembler: Fix required libraries list of MCDisassembler to useDaniel Dunbar2011-11-101-1/+3
| | | | | | all-targets instead of an explicit list. llvm-svn: 144320
* build: Add initial cut at LLVMBuild.txt files.Daniel Dunbar2011-11-031-0/+23
| | | | llvm-svn: 143634
* Enhance llvm::SourceMgr to support diagnostic ranges, the same way clang ↵Chris Lattner2011-10-161-7/+3
| | | | | | | | | | | | | | | does. Enhance the X86 asmparser to produce ranges in the one case that was annoying me, for example: test.s:10:15: error: invalid operand for instruction movl 0(%rax), 0(%edx) ^~~~~~~ It should be straight-forward to enhance filecheck, tblgen, and/or the .ll parser to use ranges where appropriate if someone is interested. llvm-svn: 142106
* Adding back support for printing operands symbolically to ARM's new disassemblerKevin Enderby2011-10-041-1/+1
| | | | | | | | | | | | | | | | | | | using llvm's public 'C' disassembler API now including annotations. Hooked this up to Darwin's otool(1) so it can again print things like branch targets for example this: blx _puts instead of this: blx #-36 and includes support for annotations for branches to symbol stubs like: bl 0x40 @ symbol stub for: _puts and annotations for pc relative loads like this: ldr r3, #8 @ literal pool for: Hello, world! Also again can print the expression encoded in the Mach-O relocation entries for things like this: movt r0, :upper16:((_foo-_bar)+1234) llvm-svn: 141129
* In the disassembler C API, be careful not to confuse the comment streamer ↵Owen Anderson2011-09-211-2/+0
| | | | | | that the disassembler outputs annotations on with the streamer that the InstPrinter will print them on. llvm-svn: 140217
* Don't attach annotations to MCInst's. Instead, have the disassembler ↵Owen Anderson2011-09-152-20/+8
| | | | | | return, and the printer accept, an annotation string which can be passed through if the client cares about annotations. llvm-svn: 139876
* The the MC disassembler C API to print in verbose mode. Perhaps there ↵Owen Anderson2011-09-152-1/+31
| | | | | | should be a parameter to request verbose mode? llvm-svn: 139821
* Refactor instprinter and mcdisassembler to take a SubtargetInfo. Add -mattr= ↵James Molloy2011-09-073-4/+15
| | | | | | handling to llvm-mc. Reviewed by Owen Anderson. llvm-svn: 139237
* Fix apparent build error caused by r138948 on certain versions of GCC with ↵James Molloy2011-09-012-21/+36
| | | | | | -Werror. Sorry for the inconvenience. llvm-svn: 138973
* Fix the build for us -Werror users.Nick Lewycky2011-09-012-37/+24
| | | | | | | Remove broken emacs mode major notation marking a C++ file as C. No functionality change. llvm-svn: 138963
* Fix up r137380 based on post-commit review by Jim Grosbach.James Molloy2011-09-012-19/+32
| | | | llvm-svn: 138948
* Fix C++0x narrowing errors when char is unsigned.Jeffrey Yasskin2011-08-303-3/+3
| | | | | | | In the case of EDInstInfo, this would actually cause a bug when -1 became 255 and was then compared >=0 in llvm-mc/Disassembler.cpp. llvm-svn: 138825
* Move TargetRegistry and TargetSelect from Target to Support where they belong.Evan Cheng2011-08-242-4/+4
| | | | | | These are strictly utilities for registering targets and components. llvm-svn: 138450
* Fixed a memory bug in the MCDisassembler whereSean Callanan2011-08-191-1/+5
| | | | | | MCParsedAsmOperand objects were being leaked. llvm-svn: 138053
* Remove unused Target argument from AsmParser construction methods.Jim Grosbach2011-08-161-1/+1
| | | | | | The argument is unused, and is a layering violation in any case. llvm-svn: 137735
* I mis-interpreted the MCDisassembler's intended dependencies. Now to fixChandler Carruth2011-07-311-2/+9
| | | | | | | | | | | | | them properly. Specifically, the disassembler clearly attempts to initialiaze all TargetInfo, MCTargeDesc, AsmParser, and Disassembler sublibraries of registered targets. This makes the CMakeLists accurately reflect this intent in the code. This should fix the last of the link errors that I have gotten reports of on OS X, but if anyone continues to see link errors, continue to pester me and I'll look into it. llvm-svn: 136603
* On mac, it seems the MC disassembler is actually using the targetinfoChandler Carruth2011-07-291-0/+2
| | | | | | | | for targets that don't have an MC-ized disassembler. I'm suspicious that this shouldn't actually be happening, but hoping to fix the CMake build on macs first, and investigate why second. llvm-svn: 136508
* Fix the MCDisassembler dependencies. These were just absurdly wrong.Chandler Carruth2011-07-291-34/+7
| | | | | | | | | | | | First off, only depend on the actual MC-ized disassemblers in the targets, not all of the libraries those in turn depend on. Second off, only depend on those MC-ized disassemblers for targets we're building. This should fix builds of fewer than all targets. llvm-svn: 136455
* Rewrite the CMake build to use explicit dependencies between libraries,Chandler Carruth2011-07-291-1/+41
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | specified in the same file that the library itself is created. This is more idiomatic for CMake builds, and also allows us to correctly specify dependencies that are missed due to bugs in the GenLibDeps perl script, or change from compiler to compiler. On Linux, this returns CMake to a place where it can relably rebuild several targets of LLVM. I have tried not to change the dependencies from the ones in the current auto-generated file. The only places I've really diverged are in places where I was seeing link failures, and added a dependency. The goal of this patch is not to start changing the dependencies, merely to move them into the correct location, and an explicit form that we can control and change when necessary. This also removes a serialization point in the build because we don't have to scan all the libraries before we begin building various tools. We no longer have a step of the build that regenerates a file inside the source tree. A few other associated cleanups fall out of this. This isn't really finished yet though. After talking to dgregor he urged switching to a single CMake macro to construct libraries with both sources and dependencies in the arguments. Migrating from the two macros to that style will be a follow-up patch. Also, llvm-config is still generated with GenLibDeps.pl, which means it still has slightly buggy dependencies. The internal CMake 'llvm-config-like' macro uses the correct explicitly specified dependencies however. A future patch will switch llvm-config generation (when using CMake) to be based on these deps as well. This may well break Windows. I'm getting a machine set up now to dig into any failures there. If anyone can chime in with problems they see or ideas of how to solve them for Windows, much appreciated. llvm-svn: 136433
* Rename TargetAsmParser to MCTargetAsmParser and TargetAsmLexer to ↵Evan Cheng2011-07-262-8/+8
| | | | | | MCTargetAsmLexer; rename createAsmLexer to createMCAsmLexer and createAsmParser to createMCAsmParser. llvm-svn: 136027
* Separate MCInstPrinter registration from AsmPrinter registration.Evan Cheng2011-07-252-2/+0
| | | | llvm-svn: 135974
* Fix last bits of MC layer issues. llvm-mc doesn't need to initialize ↵Evan Cheng2011-07-252-26/+8
| | | | | | TargetMachine's anymore. llvm-svn: 135963
* Move TargetAsmParser.h TargetAsmBackend.h and TargetAsmLexer.h to MC where ↵Evan Cheng2011-07-231-2/+2
| | | | | | they belong. llvm-svn: 135833
* Combine all MC initialization routines into one. e.g. InitializeX86MCAsmInfo,Evan Cheng2011-07-222-7/+3
| | | | | | InitializeX86MCInstrInfo, etc. are combined into InitializeX86TargetMC. llvm-svn: 135812
* Goodbye TargetAsmInfo. This eliminate last bit of CodeGen and Target in llvm-mc.Evan Cheng2011-07-203-29/+4
| | | | | | | There is still a bit more refactoring left to do in Targets. But we are now very close to fixing all the layering issues in MC. llvm-svn: 135611
* Include MCRegisterInfo to eliminate a compilation warning.Evan Cheng2011-07-201-1/+2
| | | | llvm-svn: 135575
* Add MCObjectFileInfo and sink the MCSections initialization code fromEvan Cheng2011-07-202-2/+2
| | | | | | | | TargetLoweringObjectFileImpl down to MCObjectFileInfo. TargetAsmInfo is done to one last method. It's *almost* gone! llvm-svn: 135569
OpenPOWER on IntegriCloud