public inbox for systemtap@sourceware.org
 help / color / mirror / Atom feed
* [Bug bpf/27819] New: The current string literal limit for the bpf mode is too conservative
@ 2021-05-04  4:29 agentzh at gmail dot com
  0 siblings, 0 replies; only message in thread
From: agentzh at gmail dot com @ 2021-05-04  4:29 UTC (permalink / raw)
  To: systemtap

https://sourceware.org/bugzilla/show_bug.cgi?id=27819

            Bug ID: 27819
           Summary: The current string literal limit for the bpf mode is
                    too conservative
           Product: systemtap
           Version: unspecified
            Status: UNCONFIRMED
          Severity: normal
          Priority: P2
         Component: bpf
          Assignee: systemtap at sourceware dot org
          Reporter: agentzh at gmail dot com
  Target Milestone: ---

Seems like the current string literal limit is very easy to exceed:

```
$ /opt/stap/bin/stap --bpf -e 'probe oneshot { error("you cannot specify option
A and option B at the same time! Try something else.") }'
semantic error: string literal too long: string 'you cannot specify option A
and option B at the same time! Try something else.' at <input>:1:23
        source: probe oneshot { error( ... you cannot specify option A and
option B at the same time! Try something else. ... "you cannot specify option A
and option B at the same time! Try something else.") }
                                           ^

Pass 4: compilation failed.  [man error::pass4]
```

For comparison, the same oneliner works with the kernel runtime:

```
$ /opt/stap/bin/stap -e 'probe oneshot { error("you cannot specify option A and
option B at the same time! Try something else.") }'
ERROR: you cannot specify option A and option B at the same time! Try something
else.
WARNING: Number of errors: 1, skipped probes: 0
WARNING: /opt/stap/bin/staprun exited with status: 1
Pass 5: run failed.  [man error::pass5]
```

More information:

```
$ /opt/stap/bin/stap -V
Systemtap translator/driver (version 4.5/0.183, commit
release-4.4-145-g8ae1d1dcec48)
Copyright (C) 2005-2020 Red Hat, Inc. and others
This is free software; see the source for copying conditions.
tested kernel versions: 2.6.32 ... 5.12.0-rc
enabled features: BPF
```

And I'm using kernel 5.10.15 built from mainline source on Fedora x86_64.

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

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2021-05-04  4:29 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-05-04  4:29 [Bug bpf/27819] New: The current string literal limit for the bpf mode is too conservative agentzh at gmail dot com

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).