[all-commits] [llvm/llvm-project] e43e8e: [AnnotationRemarks] Use subprogram location for su...

Florian Hahn via All-commits all-commits at lists.llvm.org
Tue Mar 23 05:06:21 PDT 2021


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: e43e8e913821f8db3684c384f5760b8e6e12e0d8
      https://github.com/llvm/llvm-project/commit/e43e8e913821f8db3684c384f5760b8e6e12e0d8
  Author: Florian Hahn <flo at fhahn.com>
  Date:   2021-03-23 (Tue, 23 Mar 2021)

  Changed paths:
    M llvm/lib/Transforms/Scalar/AnnotationRemarks.cpp
    M llvm/test/Transforms/Util/annotation-remarks-dbg-info.ll

  Log Message:
  -----------
  [AnnotationRemarks] Use subprogram location for summary remarks.

The summary remarks are generated on a per-function basis. Using the
first instruction's location is sub-optimal for 2 reasons:
  1. Sometimes the first instruction is missing !dbg
  2. The location of the first instruction may be mis-leading.

Instead, just use the location of the function directly.




More information about the All-commits mailing list