llvm-project/llvm
Alexey Bataev f3a9150324 [DEBUG_INFO][NVPTX] Generate DW_AT_address_class to get the values in debugger.
Summary:
According to
https://docs.nvidia.com/cuda/archive/10.0/ptx-writers-guide-to-interoperability/index.html#cuda-specific-dwarf,
the compiler should emit the DW_AT_address_class attribute for all
variable and parameter. It means, that DW_AT_address_class attribute
should be used in the non-standard way to support compatibility with the
cuda-gdb debugger.
Clang is able to generate the information about the variable address
class. This information is emitted as the expression sequence
`DW_OP_constu <DWARF Address Space> DW_OP_swap DW_OP_xderef`. The patch
tries to find all such expressions and transform them into
`DW_AT_address_class <DWARF Address Space>` if target is NVPTX and the debugger is gdb.
If the expression is not found, then default values are used. For the
local variables <DWARF Address Space> is set to ADDR_local_space(6), for
the globals <DWARF Address Space> is set to ADDR_global_space(5). The
values are taken from the table in the same section 5.2. CUDA-Specific
DWARF Definitions.

Reviewers: echristo, probinson

Subscribers: jholewinski, aprantl, llvm-commits

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

llvm-svn: 353203
2019-02-05 19:33:47 +00:00
..
benchmarks
bindings Fix format string in bindings/go/llvm/ir_test.go (PR40561) 2019-02-05 11:01:54 +00:00
cmake Revert "Bump minimum toolchain version" 2019-02-02 06:01:12 +00:00
docs [Intrinsic] Unsigned Fixed Point Multiplication Intrinsic 2019-02-04 17:18:11 +00:00
examples Fix compilation of examples after 13680223b9 / r352827 2019-02-01 03:23:42 +00:00
include [DEBUG_INFO][NVPTX] Generate DW_AT_address_class to get the values in debugger. 2019-02-05 19:33:47 +00:00
lib [DEBUG_INFO][NVPTX] Generate DW_AT_address_class to get the values in debugger. 2019-02-05 19:33:47 +00:00
projects Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +00:00
resources
runtimes Revert "[CMake] Use __libc_start_main rather than fopen when checking for C library" 2019-01-28 19:26:41 +00:00
test [DEBUG_INFO][NVPTX] Generate DW_AT_address_class to get the values in debugger. 2019-02-05 19:33:47 +00:00
tools [PGO] Fix the type of the formated variable 2019-02-05 18:09:28 +00:00
unittests Recommit: Add support for prefix-only CLI options 2019-02-05 14:17:16 +00:00
utils gn build: BUILD.gn files for clang-tidy and clang-apply-replacements 2019-02-05 15:14:38 +00:00
.arcconfig
.clang-format
.clang-tidy Disable tidy checks with too many hits 2019-02-01 11:20:13 +00:00
.gitattributes
.gitignore gitignore: ignore clangd index files. 2019-01-25 14:05:18 +00:00
CMakeLists.txt Previously if the user configured their build but then changed 2019-02-05 08:47:28 +00:00
CODE_OWNERS.TXT
CREDITS.TXT Remove a period from CREDITS.TXT (testing email change). NFC 2019-01-19 09:07:38 +00:00
LICENSE.TXT Fix typos throughout the license files that somehow I and my reviewers 2019-01-21 09:52:34 +00:00
LLVMBuild.txt Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +00:00
README.txt
RELEASE_TESTERS.TXT
configure
llvm.spec.in Update structured references to the license to the new license. 2019-01-19 11:30:51 +00:00

README.txt

The LLVM Compiler Infrastructure
================================

This directory and its subdirectories contain source code for LLVM,
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 are writing a package for LLVM, see docs/Packaging.rst for our
suggestions.