<feed xmlns='http://www.w3.org/2005/Atom'>
<title>kernel.git/tools/perf/util/dwarf-aux.h, branch master</title>
<subtitle>Hosts the 0x221E linux distro kernel.
</subtitle>
<id>https://git.0xinfinity.dev/distro/kernel.git/atom?h=master</id>
<link rel='self' href='https://git.0xinfinity.dev/distro/kernel.git/atom?h=master'/>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/'/>
<updated>2025-09-19T15:14:30Z</updated>
<entry>
<title>perf dwarf-aux: Better variable collection for insn tracking</title>
<updated>2025-09-19T15:14:30Z</updated>
<author>
<name>Zecheng Li</name>
</author>
<published>2025-08-25T19:54:05Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=4a6ce9ad20257a9b8fc32994366a24170a3dfa3d'/>
<id>urn:sha1:4a6ce9ad20257a9b8fc32994366a24170a3dfa3d</id>
<content type='text'>
Utilizes the previous is_breg_access_indirect function to determine if
the register + offset stores the variable itself or the struct it points
to, save the information in die_var_type.is_reg_var_addr.

Since we are storing the real types in the stack state, we need to do a
type dereference when is_reg_var_addr is set to false for stack/frame
registers.

For other gp registers, skip the variable when the register is a pointer
to the type. If we want to accept these variables, we might also utilize
is_reg_var_addr in a different way, we need to mark that register as a
pointer to the type.

Reviewed-by: Namhyung Kim &lt;namhyung@kernel.org&gt;
Signed-off-by: Zecheng Li &lt;zecheng@google.com&gt;
Cc: Adrian Hunter &lt;adrian.hunter@intel.com&gt;
Cc: Alexander Shishkin &lt;alexander.shishkin@linux.intel.com&gt;
Cc: Ian Rogers &lt;irogers@google.com&gt;
Cc: Ingo Molnar &lt;mingo@redhat.com&gt;
Cc: Jiri Olsa &lt;jolsa@kernel.org&gt;
Cc: Kan Liang &lt;kan.liang@linux.intel.com&gt;
Cc: Mark Rutland &lt;mark.rutland@arm.com&gt;
Cc: Masami Hiramatsu &lt;mhiramat@kernel.org&gt;
Cc: Peter Zijlstra &lt;peterz@infradead.org&gt;
Cc: Xu Liu &lt;xliuprof@google.com&gt;
Signed-off-by: Arnaldo Carvalho de Melo &lt;acme@redhat.com&gt;
</content>
</entry>
<entry>
<title>perf libdw: Remove unnecessary defines</title>
<updated>2024-10-18T17:17:40Z</updated>
<author>
<name>Ian Rogers</name>
</author>
<published>2024-10-17T00:13:52Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=5eb2242513072b9ad3d39ff13d771479554ae4aa'/>
<id>urn:sha1:5eb2242513072b9ad3d39ff13d771479554ae4aa</id>
<content type='text'>
As HAVE_DWARF_GETLOCATIONS_SUPPORT and HAVE_DWARF_CFI_SUPPORT always
match HAVE_DWARF_SUPPORT remove the macros and use
HAVE_DWARF_SUPPORT. If building the file is guarded by CONFIG_DWARF
then remove all ifs.

Signed-off-by: Ian Rogers &lt;irogers@google.com&gt;
Acked-by: Namhyung Kim &lt;namhyung@kernel.org&gt;
Cc: Anup Patel &lt;anup@brainfault.org&gt;
Cc: Yang Jihong &lt;yangjihong@bytedance.com&gt;
Cc: Palmer Dabbelt &lt;palmer@dabbelt.com&gt;
Cc: David S. Miller &lt;davem@davemloft.net&gt;
Cc: Albert Ou &lt;aou@eecs.berkeley.edu&gt;
Cc: Shenlin Liang &lt;liangshenlin@eswincomputing.com&gt;
Cc: Nick Terrell &lt;terrelln@fb.com&gt;
Cc: Guilherme Amadio &lt;amadio@gentoo.org&gt;
Cc: Steinar H. Gunderson &lt;sesse@google.com&gt;
Cc: Changbin Du &lt;changbin.du@huawei.com&gt;
Cc: Alexander Lobakin &lt;aleksander.lobakin@intel.com&gt;
Cc: Przemek Kitszel &lt;przemyslaw.kitszel@intel.com&gt;
Cc: Huacai Chen &lt;chenhuacai@kernel.org&gt;
Cc: Guo Ren &lt;guoren@kernel.org&gt;
Cc: Masahiro Yamada &lt;masahiroy@kernel.org&gt;
Cc: Masami Hiramatsu (Google) &lt;mhiramat@kernel.org&gt;
Cc: Will Deacon &lt;will@kernel.org&gt;
Cc: James Clark &lt;james.clark@linaro.org&gt;
Cc: Mike Leach &lt;mike.leach@linaro.org&gt;
Cc: Chen Pei &lt;cp0613@linux.alibaba.com&gt;
Cc: Leo Yan &lt;leo.yan@linux.dev&gt;
Cc: Oliver Upton &lt;oliver.upton@linux.dev&gt;
Cc: Aditya Gupta &lt;adityag@linux.ibm.com&gt;
Cc: Kajol Jain &lt;kjain@linux.ibm.com&gt;
Cc: Athira Rajeev &lt;atrajeev@linux.vnet.ibm.com&gt;
Cc: linux-arm-kernel@lists.infradead.org
Cc: linux-riscv@lists.infradead.org
Cc: Bibo Mao &lt;maobibo@loongson.cn&gt;
Cc: John Garry &lt;john.g.garry@oracle.com&gt;
Cc: Atish Patra &lt;atishp@rivosinc.com&gt;
Cc: Dima Kogan &lt;dima@secretsauce.net&gt;
Cc: Paul Walmsley &lt;paul.walmsley@sifive.com&gt;
Cc: Dr. David Alan Gilbert &lt;linux@treblig.org&gt;
Cc: linux-csky@vger.kernel.org
Link: https://lore.kernel.org/r/20241017001354.56973-10-irogers@google.com
Signed-off-by: Namhyung Kim &lt;namhyung@kernel.org&gt;
</content>
</entry>
<entry>
<title>perf dwarf-aux: Fix build with !HAVE_DWARF_GETLOCATIONS_SUPPORT</title>
<updated>2024-10-02T21:21:49Z</updated>
<author>
<name>James Clark</name>
</author>
<published>2024-10-01T12:36:25Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=008979cc6911987152eb7485943c85b9c92c1e9b'/>
<id>urn:sha1:008979cc6911987152eb7485943c85b9c92c1e9b</id>
<content type='text'>
The linked fixes commit added an #include "dwarf-aux.h" to disasm.h
which gets picked up in a lot of places. Without
HAVE_DWARF_GETLOCATIONS_SUPPORT the stubs return an errno, so include
errno.h to fix the following build error:

  In file included from util/disasm.h:8,
                 from util/annotate.h:16,
                 from builtin-top.c:23:
  util/dwarf-aux.h: In function 'die_get_var_range':
  util/dwarf-aux.h:183:10: error: 'ENOTSUP' undeclared (first use in this function)
    183 |  return -ENOTSUP;
        |          ^~~~~~~

Fixes: 782959ac248ac3cb ("perf annotate: Add "update_insn_state" callback function to handle arch specific instruction tracking")
Signed-off-by: James Clark &lt;james.clark@linaro.org&gt;
Cc: Adrian Hunter &lt;adrian.hunter@intel.com&gt;
Cc: Alexander Shishkin &lt;alexander.shishkin@linux.intel.com&gt;
Cc: Athira Rajeev &lt;atrajeev@linux.vnet.ibm.com&gt;
Cc: Ian Rogers &lt;irogers@google.com&gt;
Cc: Ingo Molnar &lt;mingo@redhat.com&gt;
Cc: Jiri Olsa &lt;jolsa@kernel.org&gt;
Cc: Kajol Jain &lt;kjain@linux.ibm.com&gt;
Cc: Kan Liang &lt;kan.liang@linux.intel.com&gt;
Cc: Mark Rutland &lt;mark.rutland@arm.com&gt;
Cc: Masami Hiramatsu &lt;mhiramat@kernel.org&gt;
Cc: Namhyung Kim &lt;namhyung@kernel.org&gt;
Cc: Peter Zijlstra &lt;peterz@infradead.org&gt;
Link: https://lore.kernel.org/r/20241001123625.1063153-1-james.clark@linaro.org
Signed-off-by: Arnaldo Carvalho de Melo &lt;acme@redhat.com&gt;
</content>
</entry>
<entry>
<title>perf annotate-data: Show typedef names properly</title>
<updated>2024-08-08T12:36:52Z</updated>
<author>
<name>Namhyung Kim</name>
</author>
<published>2024-08-07T22:31:29Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=90d78e7b8e57b064f700545081fc9288c1564e92'/>
<id>urn:sha1:90d78e7b8e57b064f700545081fc9288c1564e92</id>
<content type='text'>
The die_get_typename() would resolve typedef and get to the original
type.  But sometimes the original type is a struct without name and it
makes the output confusing and hard to read.

This is a diff of perf report -s type before and after the change.
New types such as atomic{,64}_t and sigset_t appeared and the portion
of unnamed struct was reduced.  Also u32, u64 and size_t were splitted
from the base types.

  --- b   2024-08-01 17:02:34.307809952 -0700
  +++ a   2024-08-07 14:17:05.245853999 -0700
  -     2.40%  long unsigned int
  +     2.26%  long unsigned int
  -     1.56%  unsigned int
  +     1.27%  unsigned int
  -     0.98%  struct
  -     0.79%  long long unsigned int
  +     0.58%  long long unsigned int
  +     0.36%  struct
  +     0.27%  atomic64_t
  +     0.22%  u32
  +     0.21%  u64
  +     0.19%  atomic_t
  +     0.13%  size_t
  -     0.08%  struct seqcount_spinlock
  +     0.08%  seqcount_spinlock_t
  +     0.08%  sigset_t
  +     0.08%  __poll_t

Let's use the typedef name directly and the resolved to get the size of
the type.

Committer testing:

  root@x1:~# diff -u before after | head -30
  --- before	2024-08-08 09:35:13.917325041 -0300
  +++ after	2024-08-08 09:37:35.312257905 -0300
  @@ -10,25 +10,27 @@
   # ........  .........
   #
       79.40%  (unknown)
  -     2.28%  union
        1.96%  (stack operation)
  -     1.24%  struct
  +     1.87%  pthread_mutex_t
        0.99%  u32[]
  -     0.92%  unsigned int
        0.77%  struct task_struct
  +     0.75%  U32
        0.75%  struct pcpu_hot
        0.63%  struct qspinlock
  +     0.61%  atomic_t
        0.59%  struct list_head
  -     0.58%  int
        0.53%  struct cfs_rq
        0.51%  BYTE*
  -     0.48%  unsigned char
  +     0.48%  BYTE
        0.48%  long unsigned int
        0.46%  struct rq
        0.41%  struct worker
        0.41%  struct memcg_vmstats_percpu
  +     0.41%  pthread_cond_t
        0.37%  _Bool
  +     0.36%  int
  root@x1:~#

Signed-off-by: Namhyung Kim &lt;namhyung@kernel.org&gt;
Tested-by: Arnaldo Carvalho de Melo &lt;acme@redhat.com&gt;
Cc: Adrian Hunter &lt;adrian.hunter@intel.com&gt;
Cc: Athira Rajeev &lt;atrajeev@linux.vnet.ibm.com&gt;
Cc: Ian Rogers &lt;irogers@google.com&gt;
Cc: Ingo Molnar &lt;mingo@kernel.org&gt;
Cc: Jiri Olsa &lt;jolsa@kernel.org&gt;
Cc: Kan Liang &lt;kan.liang@linux.intel.com&gt;
Cc: Masami Hiramatsu &lt;mhiramat@kernel.org&gt;
Cc: Peter Zijlstra &lt;peterz@infradead.org&gt;
Link: https://lore.kernel.org/r/20240807223129.1738004-1-namhyung@kernel.org
Signed-off-by: Arnaldo Carvalho de Melo &lt;acme@redhat.com&gt;
</content>
</entry>
<entry>
<title>perf dwarf-aux: Add die_collect_global_vars()</title>
<updated>2024-05-02T13:45:30Z</updated>
<author>
<name>Namhyung Kim</name>
</author>
<published>2024-05-02T06:00:06Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=d7b60803a790b716dc930bde2155c6ecb7537d51'/>
<id>urn:sha1:d7b60803a790b716dc930bde2155c6ecb7537d51</id>
<content type='text'>
This function is to search all global variables in the CU.  We want to
have the list of global variables at once and match them later.

Signed-off-by: Namhyung Kim &lt;namhyung@kernel.org&gt;
Cc: Adrian Hunter &lt;adrian.hunter@intel.com&gt;
Cc: Ian Rogers &lt;irogers@google.com&gt;
Cc: Ingo Molnar &lt;mingo@kernel.org&gt;
Cc: Jiri Olsa &lt;jolsa@kernel.org&gt;
Cc: Kan Liang &lt;kan.liang@linux.intel.com&gt;
Cc: Masami Hiramatsu &lt;mhiramat@kernel.org&gt;
Cc: Peter Zijlstra &lt;peterz@infradead.org&gt;
Link: https://lore.kernel.org/r/20240502060011.1838090-2-namhyung@kernel.org
Signed-off-by: Arnaldo Carvalho de Melo &lt;acme@redhat.com&gt;
</content>
</entry>
<entry>
<title>perf dwarf-aux: Add die_find_func_rettype()</title>
<updated>2024-03-21T13:41:28Z</updated>
<author>
<name>Namhyung Kim</name>
</author>
<published>2024-03-19T05:50:56Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=7a838c2fd2ac81e10bedcd912153a74ca662b309'/>
<id>urn:sha1:7a838c2fd2ac81e10bedcd912153a74ca662b309</id>
<content type='text'>
The die_find_func_rettype() is to find a debug entry for the given
function name and sets the type information of the return value.  By
convention, it'd return the pointer to the type die (should be the
same as the given mem_die argument) if found, or NULL otherwise.

Signed-off-by: Namhyung Kim &lt;namhyung@kernel.org&gt;
Cc: Adrian Hunter &lt;adrian.hunter@intel.com&gt;
Cc: Ian Rogers &lt;irogers@google.com&gt;
Cc: Ingo Molnar &lt;mingo@kernel.org&gt;
Cc: Jiri Olsa &lt;jolsa@kernel.org&gt;
Cc: Linus Torvalds &lt;torvalds@linux-foundation.org&gt;
Cc: Masami Hiramatsu &lt;mhiramat@kernel.org&gt;
Cc: Peter Zijlstra &lt;peterz@infradead.org&gt;
Cc: Stephane Eranian &lt;eranian@google.com&gt;
Link: https://lore.kernel.org/r/20240319055115.4063940-5-namhyung@kernel.org
Signed-off-by: Arnaldo Carvalho de Melo &lt;acme@redhat.com&gt;
</content>
</entry>
<entry>
<title>perf dwarf-aux: Handle type transfer for memory access</title>
<updated>2024-03-21T13:41:28Z</updated>
<author>
<name>Namhyung Kim</name>
</author>
<published>2024-03-19T05:50:55Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=437683a9941891c17059d99561eb3ce85e0f51fa'/>
<id>urn:sha1:437683a9941891c17059d99561eb3ce85e0f51fa</id>
<content type='text'>
We want to track type states as instructions are executed.  Each
instruction can access compound types like struct or union and load/
store its members to a different location.

The die_deref_ptr_type() is to find a type of memory access with a
pointer variable.  If it points to a compound type like struct, the
target memory is a member in the struct.  The access will happen with an
offset indicating which member it refers.  Let's follow the DWARF info
to figure out the type of the pointer target.

For example, say we have the following code.

  struct foo {
    int a;
    int b;
  };

  struct foo *p = malloc(sizeof(*p));
  p-&gt;b = 0;

The last pointer access should produce x86 asm like below:

  mov  0x0, 4(%rbx)

And we know %rbx register has a pointer to struct foo.  Then offset 4
should return the debug info of member 'b'.

Also variables of compound types can be accessed directly without a
pointer.  The die_get_member_type() is to handle a such case.

Signed-off-by: Namhyung Kim &lt;namhyung@kernel.org&gt;
Acked-by: Masami Hiramatsu &lt;mhiramat@kernel.org&gt;
Cc: Adrian Hunter &lt;adrian.hunter@intel.com&gt;
Cc: Ian Rogers &lt;irogers@google.com&gt;
Cc: Ingo Molnar &lt;mingo@kernel.org&gt;
Cc: Jiri Olsa &lt;jolsa@kernel.org&gt;
Cc: Linus Torvalds &lt;torvalds@linux-foundation.org&gt;
Cc: Peter Zijlstra &lt;peterz@infradead.org&gt;
Cc: Stephane Eranian &lt;eranian@google.com&gt;
Link: https://lore.kernel.org/r/20240319055115.4063940-4-namhyung@kernel.org
[ Check if die_get_real_type() returned NULL ]
Signed-off-by: Arnaldo Carvalho de Melo &lt;acme@redhat.com&gt;
</content>
</entry>
<entry>
<title>perf dwarf-aux: Add die_collect_vars()</title>
<updated>2024-03-21T13:41:28Z</updated>
<author>
<name>Namhyung Kim</name>
</author>
<published>2024-03-19T05:50:54Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=932dcc2c39aedf54ef291bc0b4129a54f5fe1e84'/>
<id>urn:sha1:932dcc2c39aedf54ef291bc0b4129a54f5fe1e84</id>
<content type='text'>
The die_collect_vars() is to find all variable information in the scope
including function parameters.  The struct die_var_type is to save the
type of the variable with the location (reg and offset) as well as where
it's defined in the code (addr).

Signed-off-by: Namhyung Kim &lt;namhyung@kernel.org&gt;
Acked-by: Masami Hiramatsu &lt;mhiramat@kernel.org&gt;
Cc: Adrian Hunter &lt;adrian.hunter@intel.com&gt;
Cc: Ian Rogers &lt;irogers@google.com&gt;
Cc: Ingo Molnar &lt;mingo@kernel.org&gt;
Cc: Jiri Olsa &lt;jolsa@kernel.org&gt;
Cc: Linus Torvalds &lt;torvalds@linux-foundation.org&gt;
Cc: Peter Zijlstra &lt;peterz@infradead.org&gt;
Cc: Stephane Eranian &lt;eranian@google.com&gt;
Link: https://lore.kernel.org/r/20240319055115.4063940-3-namhyung@kernel.org
Signed-off-by: Arnaldo Carvalho de Melo &lt;acme@redhat.com&gt;
</content>
</entry>
<entry>
<title>perf dwarf-aux: Remove unused pc argument</title>
<updated>2024-03-21T13:41:28Z</updated>
<author>
<name>Namhyung Kim</name>
</author>
<published>2024-03-19T05:50:53Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=b508965d35321534e84daf8946b2cc5f64517db9'/>
<id>urn:sha1:b508965d35321534e84daf8946b2cc5f64517db9</id>
<content type='text'>
It's not used, let's get rid of it.

Signed-off-by: Namhyung Kim &lt;namhyung@kernel.org&gt;
Reviewed-by: Arnaldo Carvalho de Melo &lt;acme@redhat.com&gt;
Cc: Adrian Hunter &lt;adrian.hunter@intel.com&gt;
Cc: Ian Rogers &lt;irogers@google.com&gt;
Cc: Ingo Molnar &lt;mingo@kernel.org&gt;
Cc: Jiri Olsa &lt;jolsa@kernel.org&gt;
Cc: Linus Torvalds &lt;torvalds@linux-foundation.org&gt;
Cc: Masami Hiramatsu &lt;mhiramat@kernel.org&gt;
Cc: Peter Zijlstra &lt;peterz@infradead.org&gt;
Cc: Stephane Eranian &lt;eranian@google.com&gt;
Link: https://lore.kernel.org/r/20240319055115.4063940-2-namhyung@kernel.org
Signed-off-by: Arnaldo Carvalho de Melo &lt;acme@redhat.com&gt;
</content>
</entry>
<entry>
<title>perf annotate-data: Support stack variables</title>
<updated>2024-01-22T20:08:20Z</updated>
<author>
<name>Namhyung Kim</name>
</author>
<published>2024-01-17T06:26:56Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=bc10db8eb8955fbcaf29f75c91147e4e724b740d'/>
<id>urn:sha1:bc10db8eb8955fbcaf29f75c91147e4e724b740d</id>
<content type='text'>
Local variables are allocated in the stack and the location list
should look like base register(s) and an offset.  Extend the
die_find_variable_by_reg() to handle the following expressions

 * DW_OP_breg{0..31}
 * DW_OP_bregx
 * DW_OP_fbreg

Ususally DWARF subprogram entries have frame base information and
use it to locate stack variable like below:

 &lt;2&gt;&lt;43d1575&gt;: Abbrev Number: 62 (DW_TAG_variable)
    &lt;43d1576&gt;   DW_AT_location    : 2 byte block: 91 7c         (DW_OP_fbreg: -4)  &lt;--- here
    &lt;43d1579&gt;   DW_AT_name        : (indirect string, offset: 0x2c00c9): i
    &lt;43d157d&gt;   DW_AT_decl_file   : 1
    &lt;43d157e&gt;   DW_AT_decl_line   : 78
    &lt;43d157f&gt;   DW_AT_type        : &lt;0x43d19d7&gt;

I found some differences on saving the frame base between gcc and clang.
The gcc uses the CFA to get the base so it needs to check the current
frame's CFI info.  In this case, stack offset needs to be adjusted from
the start of the CFA.

 &lt;1&gt;&lt;1bb8d&gt;: Abbrev Number: 102 (DW_TAG_subprogram)
    &lt;1bb8e&gt;   DW_AT_name        : (indirect string, offset: 0x74d41): kernel_init
    &lt;1bb92&gt;   DW_AT_decl_file   : 2
    &lt;1bb92&gt;   DW_AT_decl_line   : 1440
    &lt;1bb94&gt;   DW_AT_decl_column : 18
    &lt;1bb95&gt;   DW_AT_prototyped  : 1
    &lt;1bb95&gt;   DW_AT_type        : &lt;0xcc&gt;
    &lt;1bb99&gt;   DW_AT_low_pc      : 0xffffffff81bab9e0
    &lt;1bba1&gt;   DW_AT_high_pc     : 0x1b2
    &lt;1bba9&gt;   DW_AT_frame_base  : 1 byte block: 9c      (DW_OP_call_frame_cfa)  &lt;------ here
    &lt;1bbab&gt;   DW_AT_call_all_calls: 1
    &lt;1bbab&gt;   DW_AT_sibling     : &lt;0x1bf5a&gt;

While clang sets it to a register directly and it can check the register
and offset in the instruction directly.

 &lt;1&gt;&lt;43d1542&gt;: Abbrev Number: 60 (DW_TAG_subprogram)
    &lt;43d1543&gt;   DW_AT_low_pc      : 0xffffffff816a7c60
    &lt;43d154b&gt;   DW_AT_high_pc     : 0x98
    &lt;43d154f&gt;   DW_AT_frame_base  : 1 byte block: 56    (DW_OP_reg6 (rbp))  &lt;---------- here
    &lt;43d1551&gt;   DW_AT_GNU_all_call_sites: 1
    &lt;43d1551&gt;   DW_AT_name        : (indirect string, offset: 0x3bce91): foo
    &lt;43d1555&gt;   DW_AT_decl_file   : 1
    &lt;43d1556&gt;   DW_AT_decl_line   : 75
    &lt;43d1557&gt;   DW_AT_prototyped  : 1
    &lt;43d1557&gt;   DW_AT_type        : &lt;0x43c7332&gt;
    &lt;43d155b&gt;   DW_AT_external    : 1

Also it needs to update the offset after finding the type like global
variables since the offset was from the frame base.  Factor out
match_var_offset() to check global and local variables in the same way.

The type stats are improved too:

  Annotate data type stats:
  total 294, ok 160 (54.4%), bad 134 (45.6%)
  -----------------------------------------------------------
          30 : no_sym
          32 : no_mem_ops
          51 : no_var
          14 : no_typeinfo
           7 : bad_offset

Reviewed-by: Ian Rogers &lt;irogers@google.com&gt;
Cc: Stephane Eranian &lt;eranian@google.com&gt;
Cc: Masami Hiramatsu &lt;mhiramat@kernel.org&gt;
Link: https://lore.kernel.org/r/20240117062657.985479-9-namhyung@kernel.org
Signed-off-by: Namhyung Kim &lt;namhyung@kernel.org&gt;
</content>
</entry>
</feed>
