Skip to content

clang DWARF SVE predicate type does not have DW_AT_bit_strideΒ #159285

@yury-khrustalev

Description

@yury-khrustalev

Clang does not generate DW_AT_bit_stride attribute for array type entry for svbool_t. As a result, debuggers (e.g. GDB or LLDB) would try to read 1 byte for each element of the SVE predicate vector instead of reading 1 bit.

Reproducer:

#include <arm_sve.h>

// ...

[[gnu::target ("arch=armv9-a+sve")]]
void fun()
{
  volatile svbool_t pred16 = svwhilelt_b16_u32(0u, 5u);
}

Compile with -g then check DWARF data, e.g. using readelf --debug-dump: DIE for the svbool_t type won't have DW_AT_bit_stride: 1 bit attribute.

Metadata

Metadata

Assignees

Labels

clang:codegenIR generation bugs: mangling, exceptions, etc.llvm:ir

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions