[all-commits] [llvm/llvm-project] 53a483: [DWP] add overflow check for llvm-dwp tools if off...

QingShan Zhang via All-commits all-commits at lists.llvm.org
Thu Jun 1 01:33:39 PDT 2023


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 53a483cee801a207bd851d94a8ee8aebfc3db963
      https://github.com/llvm/llvm-project/commit/53a483cee801a207bd851d94a8ee8aebfc3db963
  Author: zhuna <zhuna.1024 at bytedance.com>
  Date:   2023-06-01 (Thu, 01 Jun 2023)

  Changed paths:
    M llvm/include/llvm/DWP/DWP.h
    M llvm/lib/DWP/DWP.cpp
    A llvm/test/tools/llvm-dwp/Inputs/overflow/debug_info_v4.s
    A llvm/test/tools/llvm-dwp/Inputs/overflow/debug_info_v5.s
    A llvm/test/tools/llvm-dwp/Inputs/overflow/main_v4.s
    A llvm/test/tools/llvm-dwp/Inputs/overflow/main_v5.s
    A llvm/test/tools/llvm-dwp/X86/overflow_debug_info_v4.test.manual
    A llvm/test/tools/llvm-dwp/X86/overflow_debug_info_v5.test.manual
    A llvm/test/tools/llvm-dwp/X86/overflow_debug_info_warning_v4.test.manual
    A llvm/test/tools/llvm-dwp/X86/overflow_debug_info_warning_v5.test.manual
    M llvm/tools/llvm-dwp/llvm-dwp.cpp

  Log Message:
  -----------
  [DWP] add overflow check for llvm-dwp tools if offset overflow

Now, if the offset overflow happens, we just silently ignore it.
We will generate a bad dwp file, which will crash the gdb or make
it undefined behavior, and hard to address the root cause. So, we
need to produce some messages if overflow happens.

Reviewed By: ayermolo, dblaikie, steven.zhang

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




More information about the All-commits mailing list