From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-qt1-x833.google.com (mail-qt1-x833.google.com [IPv6:2607:f8b0:4864:20::833]) by sourceware.org (Postfix) with ESMTPS id BC56E3858405 for ; Fri, 10 Sep 2021 22:54:26 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.1 sourceware.org BC56E3858405 Received: by mail-qt1-x833.google.com with SMTP id d11so2971853qtw.3 for ; Fri, 10 Sep 2021 15:54:26 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:date:from:subject:to:message-id:mime-version; bh=qJz4zaNVuYhxvY+OPBnxeHDbQOgMQAWVx0So1zrQyP8=; b=p8ldvsrS678dTVfJcABIw+2SbdfVF1UTv4mC7bSPemVRXo+lNz8F4iffPd4NMP6wPH 47ut8O0sNlGbscjeIux25eMtgeKUxKlIVEyD9s+G965mfRESZRGVTP1H72k1zSUtCjV1 98PIPscnCev2apq92paP3lWpb9MQFmGe1G3MXjzBfyK+VN7HKOhE5Nb45XCcjiURtFx2 FJ1XyLV0dgmglhW2hS7N+1TbzHCzUFfXCKI+9isZ3eK72dmTVmjttnlIQfZyX3d7hwxU xB6Ai0ehoWyLBsDU4sEc+Of7zErLKrBh+SF3jBwh9DfyrwME0VLSsF/ZfzpiIskORGU9 K6BQ== X-Gm-Message-State: AOAM533xRWrZPMLCv0hy4RjYfp6sZnmcBGNwIA7Au+qFQcJh003+Ra1Y 3B1rP86mldg+OryxxK+dQSiPL6+VdZjSqw== X-Google-Smtp-Source: ABdhPJyjrovO/teG8asBMohYGRIeKFGxuhEHJfKhbePXVHpRZa7T6eTdb6KL3IfBB3Vn9px0pIUVsA== X-Received: by 2002:ac8:7f12:: with SMTP id f18mr5339qtk.258.1631314465939; Fri, 10 Sep 2021 15:54:25 -0700 (PDT) Received: from [192.168.0.235] (23-114-169-68.lightspeed.irvnca.sbcglobal.net. [23.114.169.68]) by smtp.gmail.com with ESMTPSA id h68sm16921qkf.126.2021.09.10.15.54.24 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 10 Sep 2021 15:54:25 -0700 (PDT) Date: Fri, 10 Sep 2021 15:54:17 -0700 From: Chakib Mouzaoui Subject: User-level callee probe error To: systemtap@sourceware.org Message-Id: X-Mailer: geary/3.38.2 MIME-Version: 1.0 X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, HTML_MESSAGE, RCVD_IN_DNSWL_NONE, SPF_HELO_NONE, SPF_PASS, TXREP autolearn=ham autolearn_force=no version=3.4.4 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on server2.sourceware.org Content-Type: text/plain; charset=us-ascii; format=flowed X-Content-Filtered-By: Mailman/MimeDel 2.1.29 X-BeenThere: systemtap@sourceware.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Systemtap mailing list List-Unsubscribe: , List-Archive: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 10 Sep 2021 22:54:28 -0000 Hello! I'm having some issues using the "callee" probe when user-level tracing. I wrote a toy program that places several callees inside the main function. Here's the source for toy.cpp: #include int square(const int x) { return x * x; } int triple(const int x) { return 3 * x; } int lastdigit10(const int x) { return x % 10; } int main(int argc, char* argv[]) { const int a = 1; const int y = triple(a); const int z = square(y); std::cout << "Result: " << lastdigit10(z) + 1 << std::endl; return 0; } The toy program compiles and runs as expected: $ g++ -g -Wall toy.cpp -o toy $ ./toy Result: 10 $ I can furthermore see call, exported, and return probes corresponding to the main function and individual callees: $ sudo stap -l 'process("toy").function("main").*' process("/home/build/stap_tutorial/toy").function("main@/home/build/stap_tutorial/toy.cpp:18").call process("/home/build/stap_tutorial/toy").function("main@/home/build/stap_tutorial/toy.cpp:18").exportedprocess("/home/build/stap_tutorial/toy").function("main@/home/build/stap_tutorial/toy.cpp:18").return $ sudo stap -l 'process("toy").function("square").*' process("/home/build/stap_tutorial/toy").function("square@/home/build/stap_tutorial/toy.cpp:3").call process("/home/build/stap_tutorial/toy").function("square@/home/build/stap_tutorial/toy.cpp:3").exported process("/home/build/stap_tutorial/toy").function("square@/home/build/stap_tutorial/toy.cpp:3").return However, when probing for callees, I run into an error: $ sudo stap -v -e 'probe process("toy").function("main").callees {println ("test")}' Pass 1: parsed user script and 478 library scripts using 239084virt/80876res/12212shr/68356data kb, in 170usr/30sys/212real ms. semantic error: while resolving probe point: identifier 'process' at :1:7 source: probe process("toy").function("main").callees {println ("test")} ^ semantic error: no match (similar functions: main, _fini, _init, _start, _Z6squarei) Pass 2: analyzed script: 0 probes, 0 functions, 0 embeds, 0 globals using 240536virt/84120res/13724shr/69808data kb, in 10usr/10sys/10real ms. Pass 2: analysis failed. [man error::pass2] I also get the same error when repacing 'callees' with 'callee("*")' or even 'callee("square")'. Do you know what could be causing this? Thank you! Chakib Mouzaoui