For the DW_OP_piece and DW_OP_bit_piece operations, in the DWARF 5
standard, it is stated that if the location description (of that piece)
is empty, then the piece is describing an undefined location
description.
The act of allowing any location description to be placed on a DWARF
stack means that now a new operations can be defined which could pop
more then one location description from a DWARF stack.
This means that the old rule is not really applicable any more and a
new operation that explicitly pushes an undefined location description
on the DWARF stack is needed.
This new rule however is fully backward compatibility as described
in the document found on:
Under the new definitions for the DW_OP_piece and DW_OP_bit_piece
operations.
gdb/ChangeLog:
* compile/compile-loc2c.c (compute_stack_depth_worker): Add
support for new DW_OP_LLVM_undefined operations.
* dwarf2/expr.c (dwarf_expr_context::execute_stack_op): Add
support for new DW_OP_LLVM_undefined operations.
* dwarf2/loc.c (dwarf2_get_symbol_read_needs): Add new
DW_OP_LLVM_undefined operation support.
include/ChangeLog:
* dwarf2.def (DW_OP): New DW_OP_LLVM_undefined operations
enumeration.