LLVM backend for 6502
Go to file
David Blaikie eff0c67b6a Recommit r212203: Don't try to construct debug LexicalScopes hierarchy for functions that do not have top level debug information.
Reverted by Eric Christopher (Thanks!) in r212203 after Bob Wilson
reported LTO issues. Duncan Exon Smith and Aditya Nandakumar helped
provide a reduced reproduction, though the failure wasn't too hard to
guess, and even easier with the example to confirm.

The assertion that the subprogram metadata associated with an
llvm::Function matches the scope data referenced by the DbgLocs on the
instructions in that function is not valid under LTO. In LTO, a C++
inline function might exist in multiple CUs and the subprogram metadata
nodes will refer to the same llvm::Function. In this case, depending on
the order of the CUs, the first intance of the subprogram metadata may
not be the one referenced by the instructions in that function and the
assertion will fail.

A test case (test/DebugInfo/cross-cu-linkonce-distinct.ll) is added, the
assertion removed and a comment added to explain this situation.

Original commit message:

If a function isn't actually in a CU's subprogram list in the debug info
metadata, ignore all the DebugLocs and don't try to build scopes, track
variables, etc.

While this is possibly a minor optimization, it's also a correctness fix
for an incoming patch that will add assertions to LexicalScopes and the
debug info verifier to ensure that all scope chains lead to debug info
for the current function.

Fix up a few test cases that had broken/incomplete debug info that could
violate this constraint.

Add a test case where this occurs by design (inlining a
debug-info-having function in an attribute nodebug function - we want
this to work because /if/ the nodebug function is then inlined into a
debug-info-having function, it should be fine (and will work fine - we
just stitch the scopes up as usual), but should the inlining not happen
we need to not assert fail either).

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@212649 91177308-0d34-0410-b5e6-96231b3b80d8
2014-07-09 21:02:41 +00:00
autoconf Remove path_tclsh.m4. 2014-06-02 12:54:32 +00:00
bindings [OCaml] Documentation improvements. 2014-07-02 22:17:20 +00:00
cmake Prospective -fsanitize=memory build fix following r212586 2014-07-09 06:27:05 +00:00
docs Update ReleaseNotes to mention Atomic NAND semantic changes. 2014-07-09 18:29:55 +00:00
examples Try to fix the msvc build. 2014-04-29 23:37:02 +00:00
include Decouple llvm::SpecialCaseList text representation and its LLVM IR semantics. 2014-07-09 19:40:08 +00:00
lib Recommit r212203: Don't try to construct debug LexicalScopes hierarchy for functions that do not have top level debug information. 2014-07-09 21:02:41 +00:00
projects Remove projects/sample. 2014-03-12 22:40:22 +00:00
test Recommit r212203: Don't try to construct debug LexicalScopes hierarchy for functions that do not have top level debug information. 2014-07-09 21:02:41 +00:00
tools Changed the lvm-nm alias "-s" for -print-armap to "-M". 2014-07-08 23:47:31 +00:00
unittests Decouple llvm::SpecialCaseList text representation and its LLVM IR semantics. 2014-07-09 19:40:08 +00:00
utils Change an assert() to a diagnostic. 2014-07-09 18:55:49 +00:00
.arcconfig Updated phabricator server. 2014-04-07 03:57:04 +00:00
.clang-format Test commit. 2014-03-02 13:08:46 +00:00
.gitignore Add Polly to the ignored trees. 2014-06-25 13:13:36 +00:00
CMakeLists.txt [CMake] Introduce LLVM_SHLIB_OUTPUT_INTDIR. 2014-07-04 04:23:26 +00:00
CODE_OWNERS.TXT ARM Linux support 2014-04-02 23:03:28 +00:00
configure Touch configure to force clang's config.h.in reconfiguration on the build servers 2014-06-06 10:36:38 +00:00
CREDITS.TXT Update Credits. 2014-05-29 19:59:58 +00:00
LICENSE.TXT Remove projects/sample. 2014-03-12 22:40:22 +00:00
llvm.spec.in
LLVMBuild.txt Remove the very substantial, largely unmaintained legacy PGO 2013-10-02 15:42:23 +00:00
Makefile [configure/make] Propagate names of build host tools when making BuildTools 2014-03-25 21:45:41 +00:00
Makefile.common Makefile.common: Update a description, s/Source/SOURCES/ , according to MakefileGuide.html#control-variables . 2012-12-07 01:43:23 +00:00
Makefile.config.in Add a --enable-clang-plugin-support option to configure. 2014-03-10 16:58:35 +00:00
Makefile.rules [Make] Fix dependencies for td.expanded 2014-06-20 19:00:41 +00:00
README.txt Trivial test commit. 2014-04-26 19:05:45 +00:00

Low Level Virtual Machine (LLVM)
================================

This directory and its subdirectories contain source code for the Low Level
Virtual Machine, a toolkit for the construction of highly optimized compilers,
optimizers, and runtime environments.

LLVM is open source software. You may freely distribute it under the terms of
the license agreement found in LICENSE.txt.

Please see the documentation provided in docs/ for further
assistance with LLVM, and in particular docs/GettingStarted.rst for getting
started with LLVM and docs/README.txt for an overview of LLVM's
documentation setup.

If you're writing a package for LLVM, see docs/Packaging.rst for our
suggestions.