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: <6f6f04d7-55b3-4714-9bcd-cb4e1ae6c86a@app.fastmail.com>
Date: Tue, 03 Sep 2024 19:31:39 +0100
From: "Jiaxun Yang" <jiaxun.yang@...goat.com>
To: "Miguel Ojeda" <miguel.ojeda.sandonis@...il.com>
Cc: "Masahiro Yamada" <masahiroy@...nel.org>,
 "Nathan Chancellor" <nathan@...nel.org>,
 "Nicolas Schier" <nicolas@...sle.eu>,
 "Richard Weinberger" <richard@....at>,
 "Anton Ivanov" <anton.ivanov@...bridgegreys.com>,
 "Johannes Berg" <johannes@...solutions.net>,
 "Thomas Gleixner" <tglx@...utronix.de>, "Ingo Molnar" <mingo@...hat.com>,
 "Borislav Petkov" <bp@...en8.de>,
 "Dave Hansen" <dave.hansen@...ux.intel.com>, x86@...nel.org,
 "H. Peter Anvin" <hpa@...or.com>, "Miguel Ojeda" <ojeda@...nel.org>,
 "Alex Gaynor" <alex.gaynor@...il.com>,
 "Wedson Almeida Filho" <wedsonaf@...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@...sung.com>,
 "Alice Ryhl" <aliceryhl@...gle.com>,
 "Thomas Bogendoerfer" <tsbogend@...ha.franken.de>,
 "Steven Rostedt" <rostedt@...dmis.org>,
 "Masami Hiramatsu" <mhiramat@...nel.org>,
 "Mark Rutland" <mark.rutland@....com>,
 "Jonathan Corbet" <corbet@....net>, "Alex Shi" <alexs@...nel.org>,
 "Yanteng Si" <siyanteng@...ngson.cn>,
 "Nick Desaulniers" <ndesaulniers@...gle.com>,
 "Bill Wendling" <morbo@...gle.com>,
 "Justin Stitt" <justinstitt@...gle.com>, linux-kbuild@...r.kernel.org,
 linux-kernel@...r.kernel.org, linux-um@...ts.infradead.org,
 rust-for-linux@...r.kernel.org,
 "linux-mips@...r.kernel.org" <linux-mips@...r.kernel.org>,
 linux-trace-kernel@...r.kernel.org, linux-doc@...r.kernel.org,
 llvm@...ts.linux.dev
Subject: Re: [PATCH 3/3] rust: Enable for MIPS



在2024年9月3日九月 下午7:17,Miguel Ojeda写道:
[...]
>
> I guess you mean you are getting the warning about the
> unknown/unstable feature passed to the backend? i.e. `rustc` knows
> about those LLVM ones and forwards them when enabled via
> `-Ctarget-feature` (with a warning):
>
>     rustc --target mips64-unknown-linux-gnuabi64 --print target-features
>
> So they would need to be added to the list at [1] (or targeted flags created).
>
> Until those do not emit a warning, it is fine using the `target.json`,
> but I wanted to understand if there is something else you may need,
> since we will need to eventually avoid the `target.json`, so it is
> best asking upstream as soon as possible.

Ahh thanks for the elaboration.

So there are some targets vs feature stuff which is still not clear for
rust upstream.

For example, on ISA level (things like +mips64r2, +mips3), currently for
rust upstream, it is handled by target name. (i.e. regular mips64-unknown-linux-gnuabi64
triple would pass +mips64r2 to backend, mips64isar6-unknown-linux-gnuabi64
would pass +mips64r6).

However, kernel supports many ISA variants that are not defined by any rust target
triple, I'm not really sure if it's appropriate to define them all in upstream.

The same applies to +soft-float and +noabicalls options as well. It seems like
+soft-float and +noabicalls are only enabled by bare-metal toolchains as rust
recognise them as a target defined features.

Thanks
>
> Thanks!
>
> [1] 
> https://github.com/rust-lang/rust/blob/d6c8169c186ab16a3404cd0d0866674018e8a19e/compiler/rustc_target/src/target_features.rs#L368
>
> Cheers,
> Miguel

-- 
- Jiaxun

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ