llvm-project/llvm/lib
Chandler Carruth 75ca6be1c1 [x86/MIR] Implement support for pre- and post-instruction symbols, as
well as MIR parsing support for `MCSymbol` `MachineOperand`s.

The only real way to test pre- and post-instruction symbol support is to
use them in operands, so I ended up implementing that within the patch
as well. I can split out the operand support if folks really want but it
doesn't really seem worth it.

The functional implementation of pre- and post-instruction symbols is
now *completely trivial*. Two tiny bits of code in the (misnamed)
AsmPrinter. It should be completely target independent as well. We emit
these exactly the same way as we emit basic block labels. Most of the
code here is to give full dumping, MIR printing, and MIR parsing support
so that we can write useful tests.

The MIR parsing of MC symbol operands still isn't 100%, as it forces the
symbols to be non-temporary and non-local symbols with names. However,
those names often can encode most (if not all) of the special semantics
desired, and unnamed symbols seem especially annoying to serialize and
de-serialize. While this isn't perfect or full support, it seems plenty
to write tests that exercise usage of these kinds of operands.

The MIR support for pre-and post-instruction symbols was quite
straightforward. I chose to print them out in an as-if-operand syntax
similar to debug locations as this seemed the cleanest way and let me
use nice introducer tokens rather than inventing more magic punctuation
like we use for memoperands.

However, supporting MIR-based parsing of these symbols caused me to
change the design of the symbol support to allow setting arbitrary
symbols. Without this, I don't see any reasonable way to test things
with MIR.

Differential Revision: https://reviews.llvm.org/D50833

llvm-svn: 339962
2018-08-16 23:11:05 +00:00
..
Analysis [MemLoc] Fix a bug causing any use of invariant.end to crash in LICM 2018-08-16 20:48:55 +00:00
AsmParser DebugInfo: Add metadata support for disabling DWARF pub sections 2018-08-16 21:29:55 +00:00
BinaryFormat [dwarfdump] Add pretty printer for accelerator table based on Atom. 2018-07-13 17:21:51 +00:00
Bitcode DebugInfo: Add metadata support for disabling DWARF pub sections 2018-08-16 21:29:55 +00:00
CodeGen [x86/MIR] Implement support for pre- and post-instruction symbols, as 2018-08-16 23:11:05 +00:00
DebugInfo [codeview] Use push_macro to avoid conflicts instead of a prefix 2018-08-16 17:34:31 +00:00
Demangle Factor Node creation out of the demangler. No functionality change 2018-08-16 21:40:57 +00:00
ExecutionEngine [MCJIT] Fix a case of Error::success() being passed to report_fatal_error. 2018-08-15 20:11:21 +00:00
FuzzMutate Remove trailing space 2018-07-30 19:41:25 +00:00
Fuzzer
IR [DomTree] Add constructor to create a new DT based on current DT/CFG and a set of Updates. 2018-08-16 21:54:33 +00:00
IRReader
LTO Remove trailing space 2018-07-30 19:41:25 +00:00
LineEditor
Linker [NFC] Remove an empty line. 2018-07-27 06:50:45 +00:00
MC [MC] Improve COFF associative section lookup 2018-08-16 21:34:41 +00:00
Object llvm-readobj: Fix addend in relocations for android packed format 2018-08-15 17:58:22 +00:00
ObjectYAML [yaml2obj] - Add a support for changing EntSize. 2018-08-07 08:11:38 +00:00
Option Re-revert "[Option] Fix PR37006 prefix choice in findNearest" 2018-05-19 16:21:01 +00:00
Passes Revert "[GVNHoist] Re-enable GVNHoist by default" 2018-07-30 20:07:33 +00:00
ProfileData [Coverage] Ignore 'unused' functions with non-zero execution counts 2018-08-07 22:25:36 +00:00
Support [ADT] Replace APInt::WORD_MAX with APInt::WORDTYPE_MAX 2018-08-16 11:08:23 +00:00
TableGen Remove trailing space 2018-07-30 19:41:25 +00:00
Target [X86] In EFLAGS copy pass, don't emit EXTRACT_SUBREG instructions since we're after peephole 2018-08-16 21:54:02 +00:00
Testing [LLVMTestingSupport] Add explicit linkage to LLVMSupport 2018-04-08 06:49:17 +00:00
ToolDrivers Give llvm-lib rudimentary help output. 2018-07-14 02:29:44 +00:00
Transforms [InstCombine] add reflection fold for tan(-x) 2018-08-16 22:46:20 +00:00
WindowsManifest Convert line endings of lib/WindowsManifest/CMakeLists.txt to unix. 2018-04-07 04:28:08 +00:00
XRay [XRay] Improve error reporting when loading traces 2018-08-07 04:42:39 +00:00
CMakeLists.txt
LLVMBuild.txt