| Commit message (Collapse) | Author | Age | Files | Lines |
| |
|
|
|
|
|
|
|
|
|
|
|
| |
See r204027 for the precursor to this that applied to asm debug info.
This required some non-obvious API changes to handle the case of asm
output (we never go asm->asm so this didn't come up in r204027): the
modification of the file/directory name by MCDwarfLineTableHeader needed
to be reflected in the MCAsmStreamer caller so it could print the
appropriate .file directive, so those StringRef parameters are now
non-const ref (in/out) parameters rather than just const.
llvm-svn: 204069
|
| |
|
|
|
|
|
|
| |
It is unclear how it would be possible to get M to be NULL in normal scenarios.
Change this to an assert rather than a runtime check as per dblakie's
suggestion.
llvm-svn: 204060
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
| |
This performs the equivalent of a .set directive in that it creates a symbol
which is an alias for another symbol or value which may possibly be yet
undefined. This directive also has the added property in that it marks the
aliased symbol as being a thumb function entry point, in the same way that the
.thumb_func directive does.
The current implementation fails one test due to an unrelated issue. Functions
within .thumb sections are not marked as thumb_func. The result is that
the aliasee function is not valued correctly.
llvm-svn: 204059
|
| |
|
|
|
|
|
|
|
|
|
|
| |
Reviewers: rafael
Reviewed By: rafael
CC: llvm-commits
Differential Revision: http://llvm-reviews.chandlerc.com/D3081
llvm-svn: 204031
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
| |
This is really a consistency fix. Since given
a = b
we propagate the information, we should propagate it too given
a = b + (1 - 1)
Fixes pr19145.
llvm-svn: 204028
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The previous deduping strategy was woefully inadequate - it only
considered the most recent file used and avoided emitting a duplicate in
that case - never considering the a/b/a scenario.
It was also lacking when it came to directory paths as the previous
filename would never match the current if the filename had been split
into file and directory components.
This change builds caching functionality into the line table at the
lowest level in an optional form (a file number of 0 indicates that one
should be chosen and returned) and will eventually be reused by the
normal source level debugging DWARF emission.
llvm-svn: 204027
|
| |
|
|
|
|
|
|
|
|
|
| |
For better or worse, this is currently the normal error reporting path
when dealing with backend errors from inline assembly. It's not just
internal compiler issues that come through here, so we shouldn't be
creating a backtrace on this path.
rdar://16329947
llvm-svn: 203979
|
| |
|
|
|
|
|
| |
The member variable is not initialized in the ctor so it's already
empty. No need to empty it again.
llvm-svn: 203963
|
| |
|
|
|
|
|
|
|
| |
We were marking the symbol as absolute instead of computing b's offset + the
expression value.
This fixes pr19126.
llvm-svn: 203962
|
| |
|
|
|
|
|
|
|
|
|
|
| |
Reviewers: rafael
Reviewed By: rafael
CC: llvm-commits
Differential Revision: http://llvm-reviews.chandlerc.com/D3077
llvm-svn: 203927
|
| |
|
|
|
|
|
| |
This type now represents all the data for the DWARF line table:
directory names, file names, and the line table proper.
llvm-svn: 203858
|
| |
|
|
| |
llvm-svn: 203856
|
| |
|
|
| |
llvm-svn: 203836
|
| |
|
|
|
|
| |
(see r203831 for similar stuff)
llvm-svn: 203833
|
| |
|
|
|
|
|
|
|
|
|
|
|
| |
of MCContext's allocator.
There aren't /that/ many files, and we are already using various maps
and other standard containers that don't use MCContext's allocator to
store these values, so this doesn't seem to be critical and simplifies
the design (I'll be moving construction out of MCContext shortly so it'd
be annoying to have to pass the allocator around to allocate these
things... and we'll have non-MCContext users (debug_line.dwo) shortly)
llvm-svn: 203831
|
| |
|
|
| |
llvm-svn: 203827
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
| |
This changes the implementation of local directional labels to use a dedicated
map. With that it can then just use CreateTempSymbol, which is what the rest
of MC uses.
CreateTempSymbol doesn't do a great job at making sure the names are unique
(or being efficient when the names are not needed), but that should probably
be fixed in a followup patch.
This fixes pr18928.
llvm-svn: 203826
|
| |
|
|
| |
llvm-svn: 203823
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This replaces several "compile unit ID -> thing" mappings in favor of
one mapping from CUID to the whole line table structure (files,
directories, and lines).
This is another step along the way to refactoring out reusable
components of line table handling for use when generating debug_line.dwo
for fission type units.
Also, might be a good basis to fold some of this handling down into
MCStreamers to avoid the special case of "One line table when doing asm
printing, line table per CU otherwise" by building it into the different
MCStreamer implementations.
llvm-svn: 203821
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Summary:
This adds ObjectFile::section_iterator_range, that allows to write
range-based for-loops running over all sections of a given file.
Several files from lib/ are converted to the new interface. Similar fixes
should be applied to a variety of llvm-* tools.
Reviewers: rafael
Reviewed By: rafael
CC: llvm-commits
Differential Revision: http://llvm-reviews.chandlerc.com/D3069
llvm-svn: 203799
|
| |
|
|
| |
llvm-svn: 203763
|
| |
|
|
|
|
| |
Avoid NULL pointer scenario found via clang's static analyzer.
llvm-svn: 203745
|
| |
|
|
| |
llvm-svn: 203727
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
dimension
This makes the mapping consistent with other CU->X mappings in the
MCContext, helping pave the way to refactor all these values into a
single data structure per CU and thus a single map.
I haven't renamed the data structure as that would make the patch churn
even higher (the MCLineSection name no longer makes sense, as this
structure now contains lines for multiple sections covered by a single
CU, rather than lines for a single section in multiple CUs) and further
refactorings will follow that may remove this type entirely.
For convenience, I also gave the MCLineSection value semantics so we
didn't have to do the lazy construction, manual delete, etc.
(& for those playing at home, refactoring the line printing into a
single data structure will eventually alow that data structure to be
reused to own the debug_line.dwo line table used for type unit file name
resolution)
llvm-svn: 203726
|
| |
|
|
| |
llvm-svn: 203678
|
| |
|
|
|
|
|
|
|
| |
When printing assembly we don't have a Layout object, but we can still
try to fold some constants.
Testcase by Ulrich Weigand.
llvm-svn: 203677
|
| |
|
|
|
|
|
|
|
|
|
|
| |
The function hasReliableSymbolDifference had exactly one use in the MachO
writer. It is also only true for X86_64. In fact, the comments refers to
"Darwin x86_64" and everything else, so this makes the code match the
comment.
If this is to be abstracted again, it should be a property of
TargetObjectWriter, like useAggressiveSymbolFolding.
llvm-svn: 203605
|
| |
|
|
|
|
| |
This is fallout from r203429.
llvm-svn: 203430
|
| |
|
|
|
|
|
|
|
| |
Split by comma once instead of multiple times. Moving this upfront
makes the rest of the code considerably simpler.
No functional change.
llvm-svn: 203429
|
| |
|
|
|
|
| |
class.
llvm-svn: 203342
|
| |
|
|
|
|
| |
keyword) and its class is in an anonymous namespace.
llvm-svn: 203341
|
| |
|
|
|
|
| |
class.
llvm-svn: 203340
|
| |
|
|
|
|
|
|
|
| |
This is a straightfoward replacement, it makes debugging a little
easier.
This has no functional impact.
llvm-svn: 203264
|
| |
|
|
|
|
|
| |
This changes the interface to be more explicit that ownership is being
transferred.
llvm-svn: 203223
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Summary:
llvm/MC/MCSectionMachO.h and llvm/Support/MachO.h both had the same
definitions for the section flags. Instead, grab the definitions out of
support.
No functionality change.
Reviewers: grosbach, Bigcheese, rafael
Reviewed By: rafael
CC: llvm-commits
Differential Revision: http://llvm-reviews.chandlerc.com/D2998
llvm-svn: 203211
|
| |
|
|
|
|
|
|
| |
That was overly aggressive in assuming that we could always assume COFF. Some
of the tests assume that they will get ELF rather than COFF even on Windows
where the default is COFF.
llvm-svn: 203176
|
| |
|
|
|
|
| |
'return false'.
llvm-svn: 203171
|
| |
|
|
|
|
|
|
|
|
|
| |
This is a preliminary setup change to support a renaming of Windows target
triples. Split the object file format information out of the environment into a
separate entity. Unfortunately, file format was previously treated as an
environment with an unknown OS. This is most obvious in the ARM subtarget where
the handling for macho on an arbitrary platform switches to AAPCS rather than
APCS (as per Apple's needs).
llvm-svn: 203160
|
| |
|
|
|
|
|
|
| |
Windows always uses COFF unless Windows ELF is in use. Rather than checking if
Windows, MinGW, or Cygwin is being targeted, just check if the target OS is
windows and that it is not an ELF environment.
llvm-svn: 203159
|
| |
|
|
|
|
|
|
| |
Fixes PR18994.
Tests, once again, in that other repository. =P
llvm-svn: 203146
|
| |
|
|
|
|
|
|
|
|
| |
This compiles with no changes to clang/lld/lldb with MSVC and includes
overloads to various functions which are used by those projects and llvm
which have OwningPtr's as parameters. This should allow out of tree
projects some time to move. There are also no changes to libs/Target,
which should help out of tree targets have time to move, if necessary.
llvm-svn: 203083
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Before llvm-mc would print it, but llc was assuming that it would produce
another section changing directive before one was needed. That assumption is
false with inline asm.
Fixes PR19049.
Another option would be to always create the section, but in the asm printer
avoid printing sections changes during initialization. That would work, but
* We do use the fact that llvm-mc prints it in testing. The tests can be changed
if needed.
* A quick poll on IRC suggest that most developers prefer the implicit .text to
be printed.
llvm-svn: 203001
|
| |
|
|
|
|
|
|
| |
This will allow external callers of these functions to switch over time
rather than forcing a breaking change all a once. These particular
functions were determined by building clang/lld/lldb.
llvm-svn: 202959
|
| |
|
|
| |
llvm-svn: 202957
|
| |
|
|
|
|
| |
Remove the old functions.
llvm-svn: 202636
|
| |
|
|
| |
llvm-svn: 202621
|
| |
|
|
| |
llvm-svn: 202573
|
| |
|
|
|
|
|
| |
We moved MCJIT to use native object formats a long time ago and R600
now uses ELF, so it was dead.
llvm-svn: 202408
|
| |
|
|
| |
llvm-svn: 202130
|
| |
|
|
|
|
|
|
|
| |
After this I will set the default back to F_None. The advantage is that
before this patch forgetting to set F_Binary would corrupt a file on windows.
Forgetting to set F_Text produces one that cannot be read in notepad, which
is a better failure mode :-)
llvm-svn: 202052
|