aboutsummaryrefslogtreecommitdiff
path: root/gdb/python
diff options
context:
space:
mode:
authorLancelot SIX <lancelot.six@amd.com>2023-02-04 23:57:07 +0000
committerLancelot SIX <lancelot.six@amd.com>2023-02-13 09:42:14 +0000
commit39f6d7c6b06b06a0372284f30c86417a8c0d6ba5 (patch)
treee164b0301afae823d83bcad93c5d3294e5aaed17 /gdb/python
parent310943c20cdfbc9d5e3abe71a46c39ed0819b719 (diff)
downloadbinutils-39f6d7c6b06b06a0372284f30c86417a8c0d6ba5.zip
binutils-39f6d7c6b06b06a0372284f30c86417a8c0d6ba5.tar.gz
binutils-39f6d7c6b06b06a0372284f30c86417a8c0d6ba5.tar.bz2
gdb/testsuite: allow_hipcc_tests tests the hipcc compiler
Update allow_hipcc_tests so all gdb.rocm tests are skipped if we do not have a working hipcc compiler available. To achieve this, adjust gdb_simple_compile to ensure that the hip program is saved in a ".cpp" file before calling hipcc otherwise compilation will fail. One thing to note is that it is possible to have a hipcc installed with a CUDA backend. Compiling with this back-end will successfully result in an application, but GDB cannot debug it (at least for the offload part). In the context of the gdb.rocm tests, we want to detect such situation where gdb_simple_compile would give a false positive. To achieve this, this patch checks that there is at least one AMDGPU device available and that hipcc can compile for this or those targets. Detecting the device is done using the rocm_agent_enumerator tool which is installed with the all ROCm installations (it is used by hipcc to detect identify targets if this is not specified on the comand line). This patch also makes the allow_hipcc_tests proc a cached proc. Co-Authored-By: Pedro Alves <pedro@palves.net> Approved-By: Simon Marchi <simon.marchi@efficios.com>
Diffstat (limited to 'gdb/python')
0 files changed, 0 insertions, 0 deletions