Received: by 2002:a25:4158:0:0:0:0:0 with SMTP id o85csp5585921yba; Thu, 11 Apr 2019 01:03:06 -0700 (PDT) X-Google-Smtp-Source: APXvYqw1/zYO0VWraao+ijQAP0+u7s+lbCj3+5bRqp2yTMT07KCdYkJKZXCToL6n95laPlM6RtS/ X-Received: by 2002:aa7:928b:: with SMTP id j11mr28944279pfa.200.1554969786659; Thu, 11 Apr 2019 01:03:06 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1554969786; cv=none; d=google.com; s=arc-20160816; b=yhZ/NvDtoPo7Ide7n6cmdsTjr5tvnpB6U11LUGK+j5hTxIHjutMZFNUte8UMmxBFFO VrL/3wFUKis6fnGqlV3FAOkjOw/RA6iXqV03NajIl9hBebgL7fFiuAl/3xrcyeA1d0oT ssQKYJ9IikBUSaT4cNmtejetVsMh1bOWIAD/f/8iyfncvfTJeRoTdjwwXxrCSMvsuD+c cZP5IsQ11gO9MVXYpTq/ilK6wDBfyQwtDpgZpo1ESY3WpSCtWuDyPlRrW3FdyPXIJPAG rPk6srbvkFeC4q2GvrTNL5HaYNUcjtuz+hWjLp6MaxIJw+vS2J3DRFtSgJT2+db4d5Zw Q9dg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:message-id:date:subject:cc:to:from; bh=kmFES4ZjNwDsqIlr/2BaViMFZ4Pyh0cHH2HLAEF/CqE=; b=NhVMH22w5N4Y7DWhtUB+jZ0fEmb2Qnw/3Ux4t6fsWRJJC3JY0Fj5BqWahvCvXmoE5l V4juOJgftsRKR2pDXGqtl8tBMrGyNmKdFetkpnsMqzwB0y8m07aZnFdMWmemz/gk5H48 qKZAoAJRNPW+0GL7JbsSdbCmjwoq+rjZD1qN980RxwAelwHtnKJb3Kh/48EHv1PfnLWY NaX4QSsKnMJFE9Ex9m8j+r2kcwvuTe76PUyQFZFl97FLgXyuBJqoTr9FyBJhmSj3qc1s QtKj8LvknEYM7QTX2QjUWclexE8Fbr//ONxkKFVBSOukE+k19soWUzh1DVeSNlnRquT5 hLDQ== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id f20si24978101pgv.584.2019.04.11.01.02.50; Thu, 11 Apr 2019 01:03:06 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726857AbfDKIB0 (ORCPT + 99 others); Thu, 11 Apr 2019 04:01:26 -0400 Received: from smtp2200-217.mail.aliyun.com ([121.197.200.217]:36623 "EHLO smtp2200-217.mail.aliyun.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726104AbfDKIB0 (ORCPT ); Thu, 11 Apr 2019 04:01:26 -0400 X-Alimail-AntiSpam: AC=CONTINUE;BC=0.07768764|-1;CH=green;DM=CONTINUE|CONTINUE|true|0.511001-0.106671-0.382328;FP=0|0|0|0|0|-1|-1|-1;HT=e02c03305;MF=han_mao@c-sky.com;NM=1;PH=DS;RN=4;RT=4;SR=0;TI=SMTPD_---.EJoq1MF_1554969683; Received: from localhost(mailfrom:han_mao@c-sky.com fp:SMTPD_---.EJoq1MF_1554969683) by smtp.aliyun-inc.com(10.147.42.22); Thu, 11 Apr 2019 16:01:23 +0800 From: Mao Han To: linux-kernel@vger.kernel.org Cc: Mao Han , Palmer Dabbelt , Guo Ren Subject: [PATCH 0/3] riscv: Add perf callchain support Date: Thu, 11 Apr 2019 15:53:47 +0800 Message-Id: X-Mailer: git-send-email 2.7.4 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi, This patch set add perf callchain(FP/DWARF) support for RISC-V. It comes from the csky version callchain support with some slight modifications. The patchset base on Linux 5.1-rc4: 15ade5d2e7775667cf191cf2f94327a4889f8b9d CC: Palmer Dabbelt CC: Guo Ren Mao Han (3): riscv: Add perf callchain support riscv: Add support for perf registers sampling riscv: Add support for libdw arch/riscv/Kconfig | 2 + arch/riscv/include/uapi/asm/perf_regs.h | 42 +++++++++ arch/riscv/kernel/Makefile | 4 +- arch/riscv/kernel/perf_callchain.c | 122 ++++++++++++++++++++++++++ arch/riscv/kernel/perf_regs.c | 44 ++++++++++ tools/arch/riscv/include/uapi/asm/perf_regs.h | 42 +++++++++ tools/perf/Makefile.config | 6 +- tools/perf/arch/riscv/Build | 1 + tools/perf/arch/riscv/Makefile | 3 + tools/perf/arch/riscv/include/perf_regs.h | 96 ++++++++++++++++++++ tools/perf/arch/riscv/util/Build | 2 + tools/perf/arch/riscv/util/dwarf-regs.c | 70 +++++++++++++++ tools/perf/arch/riscv/util/unwind-libdw.c | 57 ++++++++++++ 13 files changed, 489 insertions(+), 2 deletions(-) create mode 100644 arch/riscv/include/uapi/asm/perf_regs.h create mode 100644 arch/riscv/kernel/perf_callchain.c create mode 100644 arch/riscv/kernel/perf_regs.c create mode 100644 tools/arch/riscv/include/uapi/asm/perf_regs.h create mode 100644 tools/perf/arch/riscv/Build create mode 100644 tools/perf/arch/riscv/Makefile create mode 100644 tools/perf/arch/riscv/include/perf_regs.h create mode 100644 tools/perf/arch/riscv/util/Build create mode 100644 tools/perf/arch/riscv/util/dwarf-regs.c create mode 100644 tools/perf/arch/riscv/util/unwind-libdw.c -- 2.7.4