~ubuntu-branches/debian/experimental/linux-tools/experimental

« back to all changes in this revision

Viewing changes to tools/perf/builtin-probe.c

  • Committer: Package Import Robot
  • Author(s): Ben Hutchings
  • Date: 2014-02-02 16:57:49 UTC
  • mfrom: (1.1.10) (0.1.21 sid)
  • Revision ID: package-import@ubuntu.com-20140202165749-tw94o9t1t0a8txk6
Tags: 3.13-1~exp2
Merge changes from sid up to 3.12.6-3

Show diffs side-by-side

added added

removed removed

Lines of Context:
173
173
        if  (str && !params.target) {
174
174
                if (!strcmp(opt->long_name, "exec"))
175
175
                        params.uprobes = true;
176
 
#ifdef DWARF_SUPPORT
 
176
#ifdef HAVE_DWARF_SUPPORT
177
177
                else if (!strcmp(opt->long_name, "module"))
178
178
                        params.uprobes = false;
179
179
#endif
187
187
        return ret;
188
188
}
189
189
 
190
 
#ifdef DWARF_SUPPORT
 
190
#ifdef HAVE_DWARF_SUPPORT
191
191
static int opt_show_lines(const struct option *opt __maybe_unused,
192
192
                          const char *str, int unset __maybe_unused)
193
193
{
257
257
                "perf probe [<options>] --add 'PROBEDEF' [--add 'PROBEDEF' ...]",
258
258
                "perf probe [<options>] --del '[GROUP:]EVENT' ...",
259
259
                "perf probe --list",
260
 
#ifdef DWARF_SUPPORT
 
260
#ifdef HAVE_DWARF_SUPPORT
261
261
                "perf probe [<options>] --line 'LINEDESC'",
262
262
                "perf probe [<options>] --vars 'PROBEPOINT'",
263
263
#endif
271
271
        OPT_CALLBACK('d', "del", NULL, "[GROUP:]EVENT", "delete a probe event.",
272
272
                opt_del_probe_event),
273
273
        OPT_CALLBACK('a', "add", NULL,
274
 
#ifdef DWARF_SUPPORT
 
274
#ifdef HAVE_DWARF_SUPPORT
275
275
                "[EVENT=]FUNC[@SRC][+OFF|%return|:RL|;PT]|SRC:AL|SRC;PT"
276
276
                " [[NAME=]ARG ...]",
277
277
#else
283
283
                "\t\tFUNC:\tFunction name\n"
284
284
                "\t\tOFF:\tOffset from function entry (in byte)\n"
285
285
                "\t\t%return:\tPut the probe at function return\n"
286
 
#ifdef DWARF_SUPPORT
 
286
#ifdef HAVE_DWARF_SUPPORT
287
287
                "\t\tSRC:\tSource code path\n"
288
288
                "\t\tRL:\tRelative line number from function entry.\n"
289
289
                "\t\tAL:\tAbsolute line number in file.\n"
296
296
                opt_add_probe_event),
297
297
        OPT_BOOLEAN('f', "force", &params.force_add, "forcibly add events"
298
298
                    " with existing name"),
299
 
#ifdef DWARF_SUPPORT
 
299
#ifdef HAVE_DWARF_SUPPORT
300
300
        OPT_CALLBACK('L', "line", NULL,
301
301
                     "FUNC[:RLN[+NUM|-RLN2]]|SRC:ALN[+NUM|-ALN2]",
302
302
                     "Show source code lines.", opt_show_lines),
325
325
                     opt_set_filter),
326
326
        OPT_CALLBACK('x', "exec", NULL, "executable|path",
327
327
                        "target executable name or path", opt_set_target),
 
328
        OPT_BOOLEAN(0, "demangle", &symbol_conf.demangle,
 
329
                    "Disable symbol demangling"),
328
330
        OPT_END()
329
331
        };
330
332
        int ret;
408
410
                return ret;
409
411
        }
410
412
 
411
 
#ifdef DWARF_SUPPORT
 
413
#ifdef HAVE_DWARF_SUPPORT
412
414
        if (params.show_lines && !params.uprobes) {
413
415
                if (params.mod_events) {
414
416
                        pr_err("  Error: Don't use --line with"