From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751339AbeAWMh3 (ORCPT ); Tue, 23 Jan 2018 07:37:29 -0500 Received: from mail-vk0-f50.google.com ([209.85.213.50]:36643 "EHLO mail-vk0-f50.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751056AbeAWMh2 (ORCPT ); Tue, 23 Jan 2018 07:37:28 -0500 X-Google-Smtp-Source: AH8x225Rpb0TBGaM3drOUx2vcjlboRHeWPldglBHe+095iCFZ7W1sv6LlPcIuBUPqrddyUZCt2KciS8eCPMniqiIrig= MIME-Version: 1.0 From: Pintu Kumar Date: Tue, 23 Jan 2018 18:07:25 +0530 Message-ID: Subject: [tools/perf] perf test LLVM failure on 4.9 To: linux-kernel@vger.kernel.org, kernelnewbies@kernelnewbies.org, Pintu Kumar , quentin.monnet@netronome.com, daniel@iogearbox.net, davem@davemloft.net, wangnan0@huawei.com, acme@redhat.com, alexander.shishkin@linux.intel.com, mingo@redhat.com Content-Type: text/plain; charset="UTF-8" Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi All, I am verifying all perf tests on Ubuntu-16 x86-64 platform using the kernel version 4.9.20. I have installed several others packages including: clang, llvm But, when I run 'perf test' I get some FAILURE. Specially, 'perf test LLVM' is failing. Please check the below error logs: ---------------------------------------------------- # perf test LLVM 35: Test LLVM searching and compiling : 35.1: Basic BPF llvm compiling test : FAILED! 35.2: Test kbuild searching : Skip 35.3: Compile source for BPF prologue generation test : Skip 35.4: Compile source for BPF relocation test : Skip ---------------------------------------------------- When I run with -v I get this: ----------------------------------------------------- # perf test -v LLVM 35: Test LLVM searching and compiling : 35.1: Basic BPF llvm compiling test : --- start --- test child forked, pid 3304 Unablt to get kernel version from uname '4.9-xxxx-amd-x86-64' WARNING: unable to get correct kernel building directory. Hint: Set correct kbuild directory using 'kbuild-dir' option in [llvm] section of ~/.perfconfig or set it to "" to suppress kbuild detection. Unablt to get kernel version from uname '4.9-xxxx-amd-x86-64' int _version SEC("version") = LINUX_VERSION_CODE; ' | $CLANG_EXEC -D__KERNEL__ -D__NR_CPUS__=$NR_CPUS -DLINUX_VERSION_CODE=$LINUX_VERSION_CODE $CLANG_OPTIONS $KERNEL_INC_OPTIONS -Wno-unused-value -Wno-pointer-sign -working-directory $WORKING_DIR -c "$CLANG_SOURCE" -target bpf -O2 -o - libbpf: 2129190-4a0 doesn't provide kernel version Failed to parse test case 'Basic BPF llvm compiling test' test child finished with -1 ---- end ---- Test LLVM searching and compiling subtest 0: FAILED! ----------------------------------------------------- Basic BPF LLVM compiling test is failing. It reports that bpf could not able to read the kernel version from uname. Is it because of this that 'perf test LLVM' is failing ? My uname says: 4.9-xxxx-amd-x86-64 My kernel version is: 4.9.20 (from Makefile) So, I dont think there is any problem with kernel version. If any body have come across this problem please let me know how to resolve this issue. Thank You! Regards, Pintu