[all-commits] [llvm/llvm-project] f05134: [DebugInfo] Add replaceArg function to simplify DB...

Stephen Tozer via All-commits all-commits at lists.llvm.org
Tue Mar 9 09:41:57 PST 2021


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: f0513413c7e5ffe0f4ba1527898e502af6adec45
      https://github.com/llvm/llvm-project/commit/f0513413c7e5ffe0f4ba1527898e502af6adec45
  Author: gbtozers <stephen.tozer at sony.com>
  Date:   2021-03-09 (Tue, 09 Mar 2021)

  Changed paths:
    M llvm/include/llvm/IR/DebugInfoMetadata.h
    M llvm/lib/IR/DebugInfoMetadata.cpp
    M llvm/unittests/IR/MetadataTest.cpp

  Log Message:
  -----------
  [DebugInfo] Add replaceArg function to simplify DBG_VALUE_LIST expressions

The LiveDebugValues and LiveDebugVariables implementations for handling
DBG_VALUE_LIST instructions can be simplified significantly if they do not have
to deal with any duplicated operands, such as a DBG_VALUE_LIST that uses the
same register multiple times in its expression. This patch adds a function,
replaceArg, that can be used to simplify a DIExpression in the case of
duplicated operands.

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




More information about the All-commits mailing list