[Bug tapsets/25851] New: Fail to resolve file argument from kernel dwarf on Fedora 30 x86_64

classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

[Bug tapsets/25851] New: Fail to resolve file argument from kernel dwarf on Fedora 30 x86_64

Sourceware - systemtap mailing list
https://sourceware.org/bugzilla/show_bug.cgi?id=25851

            Bug ID: 25851
           Summary: Fail to resolve file argument from kernel dwarf on
                    Fedora 30 x86_64
           Product: systemtap
           Version: unspecified
            Status: UNCONFIRMED
          Severity: normal
          Priority: P2
         Component: tapsets
          Assignee: systemtap at sourceware dot org
          Reporter: agentzh at gmail dot com
  Target Milestone: ---

I've noted that vfs.write no longer works on Fedora 30 x86_64. It works well on
Fedora 28 though. Below is the oneliner I used to reproduce the issue:

```
$ /opt/stap/bin/stap -v -e 'probe vfs.write { println("hit!", file) }'
Pass 1: parsed user script and 486 library scripts using
378936virt/154140res/7972shr/146392data kb, in 1150usr/50sys/1211real ms.
WARNING: Potential type mismatch in reassignment: identifier 'root_dentry' at
/opt/stap/share/systemtap/tapset/linux/dentry.stp:246:3
 source:                root_dentry = @cast(task,
"task_struct")->fs->root->dentry
                        ^
WARNING: Potential type mismatch in reassignment: identifier 'root_dentry' at
:242:3
 source:                root_dentry = & @cast(task, "task_struct")->fs->root
                        ^
semantic error: unresolved type : identifier 'file' at
/opt/stap/share/systemtap/tapset/linux/vfs.stp:1050:2
        source:         file = $file
                        ^

semantic error: failed to retrieve location attribute for 'file' [man
error::dwarf]: identifier '$file' at :1050:9
        dieoffset: 0x39f89ab from
/usr/lib/debug/lib/modules/5.4.19-100.fc30.x86_64/vmlinux
        function: file_start_write at ./include/linux/fs.h:2887:7 inlined by
vfs_write at fs/read_write.c:557:3 inlined by vfs_write at
fs/read_write.c:542:9
        source:         file = $file
                               ^

Pass 2: analyzed script: 2 probes, 1 function, 5 embeds, 0 globals using
619828virt/397116res/10168shr/387284data kb, in 2480usr/190sys/2691real ms.
Pass 2: analysis failed.  [man error::pass2]
```

I'm using the latest git master of stap:

```
$ /opt/stap/bin/stap -V
Systemtap translator/driver (version 4.3/0.177, commit
release-4.2-65-g6de9136a2794)
Copyright (C) 2005-2019 Red Hat, Inc. and others
This is free software; see the source for copying conditions.
tested kernel versions: 2.6.32 ... 5.4-rc6
enabled features: BPF PYTHON3 LIBSQLITE3 NLS READLINE
```

I'm using the 5.4.19 kernel shipped by Fedora 30 itself:

```
$ uname -r
5.4.19-100.fc30.x86_64
```

Seems like the `$file` function argument cannot be resolved from the kernel
DWARF?

--
You are receiving this mail because:
You are the assignee for the bug.