- Mar 12, 2013
-
-
Kevin Enderby authored
return 0 to indicate failure to create the disassembler. A library routine should not assert and just let the caller handler the error. For example darwin's otool(1) will simply print an error if it ends up using a library that is not configured for a target it wants: % otool -tv ViewController.o ViewController.o: (__TEXT,__text) section can't create arm llvm disassembler This is much better than an abort which appears as a crash to the user or even the assert when using a Debug+Asserts built library: Assertion failed: (MAI && "Unable to create target asm info!"), function LLVMCreateDisasmCPU, file /Volumes/SandBox/llvm/lib/MC/MCDisassembler/Disassembler.cpp, line 47. radr://12539918 llvm-svn: 176880
-
- Dec 19, 2012
-
-
Roman Divacky authored
llvm-svn: 170578
-
Kevin Enderby authored
instructions in the assembly code variant if one exists. The intended use for this is so tools like lldb and darwin's otool(1) can be switched to print Intel-flavored disassembly. I discussed extensively this API with Jim Grosbach and we feel while it may not be fully general, in reality there is only one syntax for each assembly with the exception of X86 which has exactly two for historical reasons. rdar://10989182 llvm-svn: 170477
-
- Dec 08, 2012
-
-
Jim Grosbach authored
It was a nasty oversight that we didn't include this when we added this API in the first place. Blech. rdar://12839439 llvm-svn: 169653
-
- Dec 05, 2012
-
-
Kevin Enderby authored
This is for the lldb team so most of but not all of the values are to be printed as hex with this option. Some small values like the scale in an X86 address were requested to printed in decimal without the leading 0x. There may be some tweaks need to places that may still be in decimal that they want in hex. Specially for arm. I made my best guess. Any tweaks from here should be simple. I also did the best I know now with help from the C++ gurus creating the cleanest formatImm() utility function and containing the changes. But if someone has a better idea to make something cleaner I'm all ears and game for changing the implementation. rdar://8109283 llvm-svn: 169393
-
- Dec 04, 2012
-
-
Chandler Carruth authored
missed in the first pass because the script didn't yet handle include guards. Note that the script is now able to handle all of these headers without manual edits. =] llvm-svn: 169224
-
- Dec 03, 2012
-
-
Chandler Carruth authored
Sooooo many of these had incorrect or strange main module includes. I have manually inspected all of these, and fixed the main module include to be the nearest plausible thing I could find. If you own or care about any of these source files, I encourage you to take some time and check that these edits were sensible. I can't have broken anything (I strictly added headers, and reordered them, never removed), but they may not be the headers you'd really like to identify as containing the API being implemented. Many forward declarations and missing includes were added to a header files to allow them to parse cleanly when included first. The main module rule does in fact have its merits. =] llvm-svn: 169131
-
- Nov 24, 2012
-
-
Benjamin Kramer authored
Necessary to give disassembler users (like darwin's otool) a possibility to dlopen libLTO and still initialize the required LLVM bits. This used to go through libMCDisassembler but that's a gross layering violation, the MC layer can't pull in functions from the targets. Adding a function to libLTO is a bit of a hack but not worse than exposing other disassembler bits from libLTO. Fixes PR14362. llvm-svn: 168545
-
- Oct 25, 2012
-
-
Chad Rosier authored
AsmParser logic. To be used/tested in a subsequent commit. llvm-svn: 166714
-
- Oct 23, 2012
-
-
Kevin Enderby authored
Per the October 12, 2012 Proposal for annotated disassembly output sent out by Jim Grosbach this set of changes implements this for X86 and arm. The llvm-mc tool now has a -mdis option to produced the marked up disassembly and a couple of small example test cases have been added. rdar://11764962 llvm-svn: 166445
-
- Jul 18, 2012
-
-
Chad Rosier authored
llvm-svn: 160445
-
- Jun 06, 2012
-
-
Benjamin Kramer authored
LLVM should be -Wunused-private-field clean now. llvm-svn: 158103
-
- May 25, 2012
-
-
Jakob Stoklund Olesen authored
Store (debugging) register names as offsets into a string table instead of as char pointers. llvm-svn: 157449
-
- May 24, 2012
-
-
Craig Topper authored
llvm-svn: 157377
-
- Apr 06, 2012
-
-
Sean Callanan authored
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
-
- Apr 02, 2012
-
-
Craig Topper authored
Make MCInstrInfo available to the MCInstPrinter. This will be used to remove getInstructionName and the static data it contains since the same tables are already in MCInstrInfo. llvm-svn: 153860
-
- Mar 05, 2012
-
-
Jim Grosbach authored
Used to allow context sensitive printing of super-register or sub-register references. llvm-svn: 152043
-
- Feb 29, 2012
-
-
Derek Schuff authored
llvm-svn: 151687
-
- Feb 21, 2012
-
-
Chandler Carruth authored
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
-
- Feb 19, 2012
-
-
Ahmed Charles authored
llvm-svn: 150918
-
- Feb 17, 2012
-
-
Kevin Enderby authored
llvm-svn: 150836
-
Kevin Enderby authored
to why this is needed. This broke the darwin's otool(1) program. This change was made in r144385. llvm-svn: 150832
-
- Feb 07, 2012
-
-
Craig Topper authored
llvm-svn: 149967
-
- Feb 06, 2012
-
-
Derek Schuff authored
This CL delays reading of function bodies from initial parse until materialization, allowing overlap of compilation with bitcode download. llvm-svn: 149918
-
- Feb 04, 2012
-
-
Sean Callanan authored
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
-
- Jan 20, 2012
-
-
David Blaikie authored
llvm-svn: 148578
-
- Jan 10, 2012
-
-
Benjamin Kramer authored
llvm-svn: 147874
-
David Blaikie authored
llvm-svn: 147855
-
- Nov 29, 2011
-
-
Daniel Dunbar authored
llvm-svn: 145420
-
Daniel Dunbar authored
llvm-svn: 145341
-
Daniel Dunbar authored
- This fixes some layering violations and matches how we handle the llvm-c lib, for example. llvm-svn: 145338
-
- Nov 12, 2011
-
-
Daniel Dunbar authored
build: Attempt to rectify inconsistencies between CMake and LLVMBuild versions of explicit dependencies. - The hope is that we have a tool/test to verify these are accurate (and tight) soon. llvm-svn: 144444
-
- Nov 11, 2011
-
-
Benjamin Kramer authored
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
-
- Nov 10, 2011
-
-
Daniel Dunbar authored
all-targets instead of an explicit list. llvm-svn: 144320
-
- Nov 03, 2011
-
-
Daniel Dunbar authored
llvm-svn: 143634
-
- Oct 16, 2011
-
-
Chris Lattner authored
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
-
- Oct 05, 2011
-
-
Kevin Enderby authored
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
-
- Sep 21, 2011
-
-
Owen Anderson authored
In the disassembler C API, be careful not to confuse the comment streamer that the disassembler outputs annotations on with the streamer that the InstPrinter will print them on. llvm-svn: 140217
-
- Sep 16, 2011
-
-
Owen Anderson authored
Don't attach annotations to MCInst's. Instead, have the disassembler return, and the printer accept, an annotation string which can be passed through if the client cares about annotations. llvm-svn: 139876
-
- Sep 15, 2011
-
-
Owen Anderson authored
The the MC disassembler C API to print in verbose mode. Perhaps there should be a parameter to request verbose mode? llvm-svn: 139821
-