[all-commits] [llvm/llvm-project] f4681b: Use DIExpression::foldConstantMath at the result o...

Shubham Sandeep Rastogi via All-commits all-commits at lists.llvm.org
Wed May 29 16:25:24 PDT 2024


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: f4681be06b465736cc993b114dd8e2625d37b779
      https://github.com/llvm/llvm-project/commit/f4681be06b465736cc993b114dd8e2625d37b779
  Author: Shubham Sandeep Rastogi <srastogi22 at apple.com>
  Date:   2024-05-29 (Wed, 29 May 2024)

  Changed paths:
    M llvm/lib/Transforms/Utils/Local.cpp
    M llvm/test/DebugInfo/salvage-icmp.ll
    M llvm/test/DebugInfo/salvage-limit-expr-size.ll
    M llvm/test/Transforms/InstCombine/cast-mul-select.ll
    M llvm/test/Transforms/InstCombine/debuginfo-dce.ll
    M llvm/test/Transforms/InstCombine/debuginfo-sink.ll
    M llvm/unittests/Transforms/Utils/LocalTest.cpp

  Log Message:
  -----------
  Use DIExpression::foldConstantMath at the result of a Salvaged expression (#71721)

This patch uses `DIExpression::foldConstantMath()` at the result of a
Salvaged expression, that is, it runs the folding optimizations after an
expression has been salvaged completely, to reduce how many times the
fold optimization function is called. Which should help in reducing the
size of DIExpressions that grow because of salvaging debug info

After checking the size of the dSYM with and without this change, I saw
a decrease of about 300KB, where the debug_loc section is about 1.6 GB
in size.

Where the debug loc section reduced in size by 212KB and it is 193MB in
size, the rest comes from the debug_info section

This is part of a stack of patches and comes after:
https://github.com/llvm/llvm-project/pull/69768
https://github.com/llvm/llvm-project/pull/71717
https://github.com/llvm/llvm-project/pull/71718
https://github.com/llvm/llvm-project/pull/71719



To unsubscribe from these emails, change your notification settings at https://github.com/llvm/llvm-project/settings/notifications


More information about the All-commits mailing list