summaryrefslogtreecommitdiffstats
path: root/llvm/lib/Target/X86/Disassembler/X86Disassembler.h
Commit message (Collapse)AuthorAgeFilesLines
* [X86] Remove unnecessary header file containing a small class. It was only ↵Craig Topper2016-04-291-112/+0
| | | | | | included in one place. Just define the class directly in the cpp file. NFC llvm-svn: 267985
* Reflect the MC/MCDisassembler split on the include/ level.Benjamin Kramer2016-01-261-1/+1
| | | | | | No functional change, just moving code around. llvm-svn: 258818
* Pass an ArrayRef to MCDisassembler::getInstruction.Rafael Espindola2014-11-121-1/+1
| | | | | | | | | | | | With this patch MCDisassembler::getInstruction takes an ArrayRef<uint8_t> instead of a MemoryObject. Even on X86 there is a maximum size an instruction can have. Given that, it seems way simpler and more efficient to just pass an ArrayRef to the disassembler instead of a MemoryObject and have it do a virtual call every time it wants some extra bytes. llvm-svn: 221751
* Misc style fixes. NFC.Rafael Espindola2014-11-101-7/+3
| | | | | | | | | | | | | This fixes a few cases of: * Wrong variable name style. * Lines longer than 80 columns. * Repeated names in comments. * clang-format of the above. This make the next patch a lot easier to read. llvm-svn: 221615
* Canonicalize header guards into a common format.Benjamin Kramer2014-08-131-2/+2
| | | | | | | | | | Add header guards to files that were missing guards. Remove #endif comments as they don't seem common in LLVM (we can easily add them back if we decide they're useful) Changes made by clang-tidy with minor tweaks. llvm-svn: 215558
* Remove some more C junk from these files.Richard Smith2014-04-201-10/+0
| | | | llvm-svn: 206721
* [MC] Require an MCContext when constructing an MCDisassembler.Lang Hames2014-04-151-1/+1
| | | | | | | | | | | | | | | | This patch re-introduces the MCContext member that was removed from MCDisassembler in r206063, and requires that an MCContext be passed in at MCDisassembler construction time. (Previously the MCContext member had been initialized in an ad-hoc fashion after construction). The MCCContext member can be used by MCDisassembler sub-classes to construct constant or target-specific MCExprs. This patch updates disassemblers for in-tree targets, and provides the MCRegisterInfo instance that some disassemblers were using through the MCContext (previously those backends were constructing their own MCRegisterInfo instances). llvm-svn: 206241
* [X86] unique_ptr'ify one of X86GenericDisassembler's members.Lang Hames2014-04-131-4/+3
| | | | llvm-svn: 206127
* [C++11] Add 'override' keyword to virtual methods that override their base ↵Craig Topper2014-03-091-5/+3
| | | | | | class. llvm-svn: 203418
* [x86] Infer disassembler mode from SubtargetInfo feature bitsDavid Woodhouse2014-01-201-3/+1
| | | | | | | | | | | | Aside from cleaning up the code, this also adds support for the -code16 environment and actually enables the MODE_16BIT mode that was previously not accessible. There is no point adding any testing for 16-bit yet though; basically nothing will work because we aren't handling the OpSize prefix correctly for 16-bit mode. llvm-svn: 199649
* Remove edis - the enhanced disassembler. Fixes PR14654.Roman Divacky2012-12-191-4/+0
| | | | llvm-svn: 170578
* Change unsigned to a uint16_t in static disassembler tables to reduce the ↵Craig Topper2012-09-111-1/+1
| | | | | | table size. llvm-svn: 163594
* Add more indirection to the disassembler tables to reduce amount of space ↵Craig Topper2012-08-011-1/+2
| | | | | | used to store the operand types and encodings. Store only the unique combinations in a separate table and store indices in the instruction table. Saves about 32K of static data. llvm-svn: 161101
* Make INSTRUCTION_SPECIFIER_FIELDS match X86DisassemblerCommon.h. Also remove ↵Craig Topper2012-07-311-5/+4
| | | | | | trailing whitespace. llvm-svn: 161029
* Make MemoryObject accessor members const againDerek Schuff2012-02-291-1/+1
| | | | llvm-svn: 151687
* Emacs-tag and some comment fix for all ARM, CellSPU, Hexagon, MBlaze, ↵Jia Liu2012-02-181-1/+1
| | | | | | MSP430, PPC, PTX, Sparc, X86, XCore. llvm-svn: 150878
* Make the EDis tables const.Benjamin Kramer2012-02-111-1/+1
| | | | llvm-svn: 150304
* Reuse the enum names from X86Desc in the X86Disassembler.Benjamin Kramer2012-02-111-1/+4
| | | | | | | This requires some gymnastics to make it available for C code. Remove the names from the disassembler tables, making them relocation free. llvm-svn: 150303
* Flatten some of the arrays in the X86 disassembler tables to reduce space ↵Craig Topper2012-02-091-1/+1
| | | | | | needed to store pointers on 64-bit hosts and reduce relocations needed at startup. Part of PR11953. llvm-svn: 150161
* Enable streaming of bitcodeDerek Schuff2012-02-061-1/+1
| | | | | | | This CL delays reading of function bodies from initial parse until materialization, allowing overlap of compilation with bitcode download. llvm-svn: 149918
* Remove mode specific disassembler classes and just call ↵Craig Topper2011-12-211-33/+5
| | | | | | X86GenericDisassembler constructor with appropriate argument in the creation functions. This removes a few tables that needed to be anchored. llvm-svn: 147046
* Fix typo in a couple commentsCraig Topper2011-12-211-3/+3
| | | | llvm-svn: 147045
* Unweaken vtables as per ↵David Blaikie2011-12-201-0/+3
| | | | | | http://llvm.org/docs/CodingStandards.html#ll_virtual_anch llvm-svn: 146960
* Don't attach annotations to MCInst's. Instead, have the disassembler ↵Owen Anderson2011-09-151-1/+2
| | | | | | return, and the printer accept, an annotation string which can be passed through if the client cares about annotations. llvm-svn: 139876
* Refactor instprinter and mcdisassembler to take a SubtargetInfo. Add -mattr= ↵James Molloy2011-09-071-7/+8
| | | | | | handling to llvm-mc. Reviewed by Owen Anderson. llvm-svn: 139237
* Allow the MCDisassembler to return a "soft fail" status code, indicating an ↵Owen Anderson2011-08-171-5/+5
| | | | | | | | instruction that is disassemblable, but invalid. Only used for ARM UNPREDICTABLE instructions at the moment. Patch by James Molloy. llvm-svn: 137830
* Make the disassembler tables const so they end up in read-only memory.Benjamin Kramer2010-10-231-1/+1
| | | | llvm-svn: 117206
* Fixed a nasty layering violation in the edis sourceSean Callanan2010-04-131-0/+5
| | | | | | | | | | | | | | | code. It used to #include the enhanced disassembly information for the targets it supported straight out of lib/Target/{X86,ARM,...} but now it uses a new interface provided by MCDisassembler, and (so far) implemented by X86 and ARM. Also removed hacky #define-controlled initialization of targets in edis. If clients only want edis to initialize a limited set of targets, they can set --enable-targets on the configure command line. llvm-svn: 101179
* Table-driven disassembler for the X86 architecture (16-, 32-, and 64-bit Sean Callanan2009-12-191-0/+150
incarnations), integrated into the MC framework. The disassembler is table-driven, using a custom TableGen backend to generate hierarchical tables optimized for fast decode. The disassembler consumes MemoryObjects and produces arrays of MCInsts, adhering to the abstract base class MCDisassembler (llvm/MC/MCDisassembler.h). The disassembler is documented in detail in - lib/Target/X86/Disassembler/X86Disassembler.cpp (disassembler runtime) - utils/TableGen/DisassemblerEmitter.cpp (table emitter) You can test the disassembler by running llvm-mc -disassemble for i386 or x86_64 targets. Please let me know if you encounter any problems with it. llvm-svn: 91749
OpenPOWER on IntegriCloud