lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CANiq72kDkPgXS2SasysSa0MXX68kkkhYbSpvK9KAYxFbEKpLig@mail.gmail.com>
Date: Tue, 29 Apr 2025 21:33:03 +0200
From: Miguel Ojeda <miguel.ojeda.sandonis@...il.com>
To: Ian Rogers <irogers@...gle.com>
Cc: Peter Zijlstra <peterz@...radead.org>, Ingo Molnar <mingo@...hat.com>, 
	Arnaldo Carvalho de Melo <acme@...nel.org>, Namhyung Kim <namhyung@...nel.org>, 
	Mark Rutland <mark.rutland@....com>, 
	Alexander Shishkin <alexander.shishkin@...ux.intel.com>, Jiri Olsa <jolsa@...nel.org>, 
	Adrian Hunter <adrian.hunter@...el.com>, Kan Liang <kan.liang@...ux.intel.com>, 
	Miguel Ojeda <ojeda@...nel.org>, Alex Gaynor <alex.gaynor@...il.com>, 
	Boqun Feng <boqun.feng@...il.com>, Gary Guo <gary@...yguo.net>, 
	Björn Roy Baron <bjorn3_gh@...tonmail.com>, 
	Benno Lossin <benno.lossin@...ton.me>, Andreas Hindborg <a.hindborg@...nel.org>, 
	Alice Ryhl <aliceryhl@...gle.com>, Trevor Gross <tmgross@...ch.edu>, 
	Danilo Krummrich <dakr@...nel.org>, Nathan Chancellor <nathan@...nel.org>, 
	Nick Desaulniers <nick.desaulniers+lkml@...il.com>, Bill Wendling <morbo@...gle.com>, 
	Justin Stitt <justinstitt@...gle.com>, James Clark <james.clark@...aro.org>, 
	Howard Chu <howardchu95@...il.com>, Jiapeng Chong <jiapeng.chong@...ux.alibaba.com>, 
	Ravi Bangoria <ravi.bangoria@....com>, "Masami Hiramatsu (Google)" <mhiramat@...nel.org>, 
	Stephen Brennan <stephen.s.brennan@...cle.com>, linux-kernel@...r.kernel.org, 
	linux-perf-users@...r.kernel.org, rust-for-linux@...r.kernel.org, 
	llvm@...ts.linux.dev, Daniel Xu <dxu@...uu.xyz>, 
	Ariel Ben-Yehuda <ariel.byd@...il.com>
Subject: Re: [PATCH v1 1/6] perf demangle-rust: Add rustc-demangle C demangler

On Tue, Apr 29, 2025 at 8:59 PM Ian Rogers <irogers@...gle.com> wrote:
>
> Imported at 80e40f5 from:

I would suggest using the usual commit reference format:

    commit 80e40f57d99f ("add comment about finding latest version of code")

> The files are renamed as perf supports multiple demanglers and so
> demangle as a name would be overloaded.
>
> The work here was done by github.com/arielb1 and I am merely importing
> it as discussed in the rust-lang issue.

Cc: Ariel Ben-Yehuda <ariel.byd@...il.com>

> +// SPDX-License-Identifier: (Apache-2.0 OR MIT)

Hmm... The documentation is unclear, but I don't think parenthesis are
needed (the docs have examples without them and for this particular
pair we do not use them elsewhere).

> +// Code for demangling Rust symbols. This code is mostly
> +// a line-by-line translation of the Rust code in `rustc-demangle`.
> +
> +// you can find the latest version of this code in https://github.com/rust-lang/rustc-demangle

Ideally, above this, i.e. before the original file starts, we could
have something like we have for other vendored code, e.g. what we
wrote elsewhere for some code from the standard library:

    //! The contents of this file come from the Rust standard library, hosted in
    //! the <https://github.com/rust-lang/rust> repository, licensed under
    //! "Apache-2.0 OR MIT" and adapted for kernel use. For copyright details,
    //! see <https://github.com/rust-lang/rust/blob/master/COPYRIGHT>.

(And then below the actual file)

It wouldn't hurt to mention also something like we did for `alloc`:

    Please note that these files should be kept as close as possible to
    upstream.

I hope that helps!

Cheers,
Miguel

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ