From nobody Tue Nov 26 17:23:04 2024 Received: from mail-yw1-f201.google.com (mail-yw1-f201.google.com [209.85.128.201]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 1A42B24B26 for ; Thu, 17 Oct 2024 00:26:16 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.128.201 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1729124777; cv=none; b=nnV15pQ95KB4Cp9F89FxpidXosJYqWbA51BztIAeFIeH//uSqhstQtHrMAmlYYsdQY6UY0j+/DX5x6cKWIm6GrsTsoPHSE9h1QOwsLYe+oofj4lQyAOEeVr2kRxb+FocqfBs97r800z/3Rhq0M5wT8eVAL9Q2msqILdZ9Spz9WA= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1729124777; c=relaxed/simple; bh=h5ZjFR6J5gfi5loliw4Qrm4otdLI+fjevlxZlm5oU1I=; h=Date:In-Reply-To:Message-Id:Mime-Version:References:Subject:From: To:Content-Type; b=F3Ef6U8tlzEPIA8DO4N4+43HoSUPWJld/cXIT8y39n1WkqUkEdczbMCigC09kvlbijqYjRR1Fy4cNNvB5/rO0MLe9zKtC8RpT9O9316zcGci/F15e7pfp3oEaI0+nixb/bQ4dR/3uFsqIvq7PWwiE70V+tzFJ7mZgakjH5LhXVg= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=google.com; spf=pass smtp.mailfrom=flex--irogers.bounces.google.com; dkim=pass (2048-bit key) header.d=google.com header.i=@google.com header.b=kAhaN/iV; arc=none smtp.client-ip=209.85.128.201 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=google.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=flex--irogers.bounces.google.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=google.com header.i=@google.com header.b="kAhaN/iV" Received: by mail-yw1-f201.google.com with SMTP id 00721157ae682-6e3705b2883so10395457b3.3 for ; Wed, 16 Oct 2024 17:26:15 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20230601; t=1729124775; x=1729729575; darn=vger.kernel.org; h=to:from:subject:references:mime-version:message-id:in-reply-to:date :from:to:cc:subject:date:message-id:reply-to; bh=KNbBqi1saNqYXEAAo8guTprpDL0iavWB2aVE9Nn4lPM=; b=kAhaN/iVQsPEX+dLCTmBZu+PJa6xauchoYyv2xtoUJP6y5gWhHU+T5sBH2ql+ev3dy dFEqhlOKWZZn/hMDD30xPEjGHzZOOR77QQmQn11M1yGSTkNWQXmCUGwk8pMDac9gSWiA KkusRLYUSg0MaswIU/SvZ7eDgrUyzyMjkBCGxgUrcIDVQF61cTV+pDUIIidH19iJItEC ytlOrlgsexwcSApqro0ge9cbzyJFFj/xyNNj3swALCkvWJJBDnFtz31UoyuzhJO154t8 uTi6UjOFbm4A9CGvybeZzKYB7d6QxuaU+4yGRvS6iUM/ZwJsVIiJyKg/yya/Tf2hZGn5 6UDA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1729124775; x=1729729575; h=to:from:subject:references:mime-version:message-id:in-reply-to:date :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=KNbBqi1saNqYXEAAo8guTprpDL0iavWB2aVE9Nn4lPM=; b=L/EupZWjwFC+XK5ums3tYHR/WbbHOiAX6m29AFBJKvxABeEHJGSTgmtI6zDwIPdvQC 5YAW2FFoReVFTNwzlIwAK+njLaLj+xLp5gOcOLlRV8t+LEGGQXMvIRlvN6is6YCZNrB7 1WA8k52e+YUMQ8N8adapaC9okhdAP7gBihmmnwaY82GFpAeMpuvzTVi7YULey1Kflp9u TbkXpLSdPcJM7ugNwXW+JGWJ9NslW+mSixJggRuJgBn0y8SG3op+vcGb9T81rUg6Q1Dq R586MTv+FkIfixaatrV8WPjyoRO/8+Uz8PFFk8M4yNRbfpy44cu32W9fTA2OMyjyC1Rm lD2Q== X-Forwarded-Encrypted: i=1; AJvYcCVaM6cdZOU6OMOkULBcpA5zziSYZ/OXd1W6NComYO+prFprPEh4JZANZFH+BVlZ8tr1/hlU/SpEnFAsv80=@vger.kernel.org X-Gm-Message-State: AOJu0YzMO5YWE1rqJGXqMimnbx4VCm6JceqhWYbXxAs+KXx3vBSrO67s fU/PN3EG6Xh089WqVy18bc/g4a3zrV9KvhKWw7l8xGHOc2VU4X06day2VXyGWJLTkJLDGylgZqb 65e3LyA== X-Google-Smtp-Source: AGHT+IEbHtnjVfs/XyOXwRVtcImn7Ac6sTdT7J05MnwMea9QA/h1ss5WMT/c3lNVvH8+kCZUWXSdbtC8V8yG X-Received: from irogers.svl.corp.google.com ([2620:15c:2c5:11:a00a:f237:9bc0:79c]) (user=irogers job=sendgmr) by 2002:a25:dc02:0:b0:e1c:ed3d:7bb7 with SMTP id 3f1490d57ef6-e29782c757dmr2976276.1.1729124774808; Wed, 16 Oct 2024 17:26:14 -0700 (PDT) Date: Wed, 16 Oct 2024 17:25:19 -0700 In-Reply-To: <20241017002520.59124-1-irogers@google.com> Message-Id: <20241017002520.59124-20-irogers@google.com> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: Mime-Version: 1.0 References: <20241017002520.59124-1-irogers@google.com> X-Mailer: git-send-email 2.47.0.105.g07ac214952-goog Subject: [PATCH v3 19/20] perf dwarf-regs: Remove get_arch_regstr code From: Ian Rogers To: Peter Zijlstra , Ingo Molnar , Arnaldo Carvalho de Melo , Namhyung Kim , Mark Rutland , Alexander Shishkin , Jiri Olsa , Ian Rogers , Adrian Hunter , Kan Liang , John Garry , Will Deacon , James Clark , Mike Leach , Leo Yan , Guo Ren , Paul Walmsley , Palmer Dabbelt , Albert Ou , Nick Terrell , "Masami Hiramatsu (Google)" , Changbin Du , Guilherme Amadio , Yang Jihong , Aditya Gupta , Athira Rajeev , Masahiro Yamada , Bibo Mao , Huacai Chen , Kajol Jain , Atish Patra , Shenlin Liang , Anup Patel , Oliver Upton , "Steinar H. Gunderson" , "Dr. David Alan Gilbert" , Chen Pei , Dima Kogan , Przemek Kitszel , "David S. Miller" , Alexander Lobakin , linux-kernel@vger.kernel.org, linux-perf-users@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-csky@vger.kernel.org, linux-riscv@lists.infradead.org Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="utf-8" get_arch_regstr no longer exists so remove declaration. Associated ifs and switches are made unconditional. Signed-off-by: Ian Rogers --- tools/perf/util/dwarf-regs.c | 12 ------------ tools/perf/util/include/dwarf-regs.h | 7 ------- 2 files changed, 19 deletions(-) diff --git a/tools/perf/util/dwarf-regs.c b/tools/perf/util/dwarf-regs.c index 05fff75a8f59..28a1cfdf26d4 100644 --- a/tools/perf/util/dwarf-regs.c +++ b/tools/perf/util/dwarf-regs.c @@ -32,23 +32,11 @@ /* Return architecture dependent register string (for kprobe-tracer) */ const char *get_dwarf_regstr(unsigned int n, unsigned int machine, unsigne= d int flags) { -#if EM_HOST =3D=3D EM_X86_64 || EM_HOST =3D=3D EM_386 || EM_HOST =3D=3D EM= _AARCH64 || EM_HOST =3D=3D EM_ARM \ - || EM_HOST =3D=3D EM_CSKY || EM_HOST =3D=3D EM_LOONGARCH || EM_HOST = =3D=3D EM_MIPS || EM_HOST =3D=3D EM_PPC \ - || EM_HOST =3D=3D EM_PPC64 || EM_HOST =3D=3D EM_RISCV || EM_HOST =3D= =3D EM_S390 || EM_HOST =3D=3D EM_SH \ - || EM_HOST =3D=3D EM_SPARC || EM_HOST =3D=3D EM_SPARCV9 || EM_HOST =3D= =3D EM_XTENSA if (machine =3D=3D EM_NONE) { /* Generic arch - use host arch */ machine =3D EM_HOST; } -#endif switch (machine) { -#if EM_HOST !=3D EM_X86_64 && EM_HOST !=3D EM_386 && EM_HOST !=3D EM_AARCH= 64 && EM_HOST !=3D EM_ARM \ - && EM_HOST !=3D EM_CSKY && EM_HOST !=3D EM_LOONGARCH && EM_HOST !=3D E= M_MIPS && EM_HOST !=3D EM_PPC \ - && EM_HOST !=3D EM_PPC64 && EM_HOST !=3D EM_RISCV && EM_HOST !=3D EM_S= 390 && EM_HOST !=3D EM_SH \ - && EM_HOST !=3D EM_SPARC && EM_HOST !=3D EM_SPARCV9 && EM_HOST !=3D EM= _XTENSA - case EM_NONE: /* Generic arch - use host arch */ - return get_arch_regstr(n); -#endif case EM_386: return __get_dwarf_regstr(x86_32_regstr_tbl, n); case EM_X86_64: diff --git a/tools/perf/util/include/dwarf-regs.h b/tools/perf/util/include= /dwarf-regs.h index 9dfc9abfdddd..6ee95cc69917 100644 --- a/tools/perf/util/include/dwarf-regs.h +++ b/tools/perf/util/include/dwarf-regs.h @@ -79,13 +79,6 @@ #define DWARF_REG_FB 0xd3affb /* random number */ =20 #ifdef HAVE_LIBDW_SUPPORT -#if !defined(__x86_64__) && !defined(__i386__) && !defined(__aarch64__) &&= !defined(__arm__) \ - && !defined(__loongarch__) && !defined(__mips__) && !defined(__powerpc= __) \ - && !defined(__powerpc64__) && !defined(__riscv__) && !defined(__s390x_= _) && !defined(__sh__) \ - && !defined(__sparc64__) && !defined(__sparc__) && !defined(__xtensa__) -const char *get_arch_regstr(unsigned int n); -#endif - const char *get_csky_regstr(unsigned int n, unsigned int flags); =20 /** --=20 2.47.0.105.g07ac214952-goog