* [PATCH] rust: Add -fno-isolate-erroneous-paths-dereference to bindgen_skip_c_flags
@ 2025-10-15 2:20 Xi Ruoyao
2025-10-15 3:19 ` Mingcong Bai
2025-10-15 10:20 ` Miguel Ojeda
0 siblings, 2 replies; 4+ messages in thread
From: Xi Ruoyao @ 2025-10-15 2:20 UTC (permalink / raw)
To: Nathan Chancellor
Cc: loongarch, Xi Ruoyao, Miguel Ojeda, Alex Gaynor, Boqun Feng,
Gary Guo, Björn Roy Baron, Benno Lossin, Andreas Hindborg,
Alice Ryhl, Trevor Gross, Danilo Krummrich, Nick Desaulniers,
Bill Wendling, Justin Stitt, Huacai Chen, Tiezhu Yang,
open list:RUST, open list,
open list:CLANG/LLVM BUILD SUPPORT:Keyword:b(?i:clang|llvm)b
It's used to work around an objtool issue since commit abb2a5572264
("LoongArch: Add cflag -fno-isolate-erroneous-paths-dereference"), but
it's then passed to bindgen and cause an error because Clang does not
have this option.
Fixes: abb2a5572264 ("LoongArch: Add cflag -fno-isolate-erroneous-paths-dereference")
Signed-off-by: Xi Ruoyao <xry111@xry111.site>
---
rust/Makefile | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/rust/Makefile b/rust/Makefile
index 23c7ae905bd2..0676b1194a62 100644
--- a/rust/Makefile
+++ b/rust/Makefile
@@ -289,7 +289,7 @@ bindgen_skip_c_flags := -mno-fp-ret-in-387 -mpreferred-stack-boundary=% \
-fno-inline-functions-called-once -fsanitize=bounds-strict \
-fstrict-flex-arrays=% -fmin-function-alignment=% \
-fzero-init-padding-bits=% -mno-fdpic \
- --param=% --param asan-%
+ --param=% --param asan-% -fno-isolate-erroneous-paths-dereference
# Derived from `scripts/Makefile.clang`.
BINDGEN_TARGET_x86 := x86_64-linux-gnu
--
2.51.0
^ permalink raw reply related [flat|nested] 4+ messages in thread
* Re: [PATCH] rust: Add -fno-isolate-erroneous-paths-dereference to bindgen_skip_c_flags
2025-10-15 2:20 [PATCH] rust: Add -fno-isolate-erroneous-paths-dereference to bindgen_skip_c_flags Xi Ruoyao
@ 2025-10-15 3:19 ` Mingcong Bai
2025-10-15 10:20 ` Miguel Ojeda
1 sibling, 0 replies; 4+ messages in thread
From: Mingcong Bai @ 2025-10-15 3:19 UTC (permalink / raw)
To: Xi Ruoyao, Nathan Chancellor
Cc: loongarch, Miguel Ojeda, Alex Gaynor, Boqun Feng, Gary Guo,
Björn Roy Baron, Benno Lossin, Andreas Hindborg, Alice Ryhl,
Trevor Gross, Danilo Krummrich, Nick Desaulniers, Bill Wendling,
Justin Stitt, Huacai Chen, Tiezhu Yang, open list:RUST, open list,
open list:CLANG/LLVM BUILD SUPPORT:Keyword:b(?i:clang|llvm)b
Hi Ruoyao,
在 2025/10/15 10:20, Xi Ruoyao 写道:
> It's used to work around an objtool issue since commit abb2a5572264
> ("LoongArch: Add cflag -fno-isolate-erroneous-paths-dereference"), but
> it's then passed to bindgen and cause an error because Clang does not
> have this option.
>
> Fixes: abb2a5572264 ("LoongArch: Add cflag -fno-isolate-erroneous-paths-dereference")
> Signed-off-by: Xi Ruoyao <xry111@xry111.site>
> ---
> rust/Makefile | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/rust/Makefile b/rust/Makefile
> index 23c7ae905bd2..0676b1194a62 100644
> --- a/rust/Makefile
> +++ b/rust/Makefile
> @@ -289,7 +289,7 @@ bindgen_skip_c_flags := -mno-fp-ret-in-387 -mpreferred-stack-boundary=% \
> -fno-inline-functions-called-once -fsanitize=bounds-strict \
> -fstrict-flex-arrays=% -fmin-function-alignment=% \
> -fzero-init-padding-bits=% -mno-fdpic \
> - --param=% --param asan-%
> + --param=% --param asan-% -fno-isolate-erroneous-paths-dereference
>
> # Derived from `scripts/Makefile.clang`.
> BINDGEN_TARGET_x86 := x86_64-linux-gnu
Tested good applied atop v6.18-rc1, which includes the aforementioned
abb2a5572264.
Tested-by: Mingcong Bai <jeffbai@aosc.io>
Best Regards,
Mingcong Bai
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH] rust: Add -fno-isolate-erroneous-paths-dereference to bindgen_skip_c_flags
2025-10-15 2:20 [PATCH] rust: Add -fno-isolate-erroneous-paths-dereference to bindgen_skip_c_flags Xi Ruoyao
2025-10-15 3:19 ` Mingcong Bai
@ 2025-10-15 10:20 ` Miguel Ojeda
2025-10-15 10:31 ` Huacai Chen
1 sibling, 1 reply; 4+ messages in thread
From: Miguel Ojeda @ 2025-10-15 10:20 UTC (permalink / raw)
To: Xi Ruoyao
Cc: Nathan Chancellor, loongarch, Miguel Ojeda, Alex Gaynor,
Boqun Feng, Gary Guo, Björn Roy Baron, Benno Lossin,
Andreas Hindborg, Alice Ryhl, Trevor Gross, Danilo Krummrich,
Nick Desaulniers, Bill Wendling, Justin Stitt, Huacai Chen,
Tiezhu Yang, open list:RUST, open list,
open list:CLANG/LLVM BUILD SUPPORT:Keyword:b(?i:clang|llvm)b
On Wed, Oct 15, 2025 at 4:21 AM Xi Ruoyao <xry111@xry111.site> wrote:
>
> It's used to work around an objtool issue since commit abb2a5572264
> ("LoongArch: Add cflag -fno-isolate-erroneous-paths-dereference"), but
> it's then passed to bindgen and cause an error because Clang does not
> have this option.
>
> Fixes: abb2a5572264 ("LoongArch: Add cflag -fno-isolate-erroneous-paths-dereference")
> Signed-off-by: Xi Ruoyao <xry111@xry111.site>
Seems OK -- if you are taking it through LoongArch:
Acked-by: Miguel Ojeda <ojeda@kernel.org>
Thanks!
Cheers,
Miguel
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH] rust: Add -fno-isolate-erroneous-paths-dereference to bindgen_skip_c_flags
2025-10-15 10:20 ` Miguel Ojeda
@ 2025-10-15 10:31 ` Huacai Chen
0 siblings, 0 replies; 4+ messages in thread
From: Huacai Chen @ 2025-10-15 10:31 UTC (permalink / raw)
To: Miguel Ojeda
Cc: Xi Ruoyao, Nathan Chancellor, loongarch, Miguel Ojeda,
Alex Gaynor, Boqun Feng, Gary Guo, Björn Roy Baron,
Benno Lossin, Andreas Hindborg, Alice Ryhl, Trevor Gross,
Danilo Krummrich, Nick Desaulniers, Bill Wendling, Justin Stitt,
Tiezhu Yang, open list:RUST, open list,
open list:CLANG/LLVM BUILD SUPPORT:Keyword:b(?i:clang|llvm)b
On Wed, Oct 15, 2025 at 6:20 PM Miguel Ojeda
<miguel.ojeda.sandonis@gmail.com> wrote:
>
> On Wed, Oct 15, 2025 at 4:21 AM Xi Ruoyao <xry111@xry111.site> wrote:
> >
> > It's used to work around an objtool issue since commit abb2a5572264
> > ("LoongArch: Add cflag -fno-isolate-erroneous-paths-dereference"), but
> > it's then passed to bindgen and cause an error because Clang does not
> > have this option.
> >
> > Fixes: abb2a5572264 ("LoongArch: Add cflag -fno-isolate-erroneous-paths-dereference")
> > Signed-off-by: Xi Ruoyao <xry111@xry111.site>
>
> Seems OK -- if you are taking it through LoongArch:
>
> Acked-by: Miguel Ojeda <ojeda@kernel.org>
Queued, thanks.
Huacai
>
> Thanks!
>
> Cheers,
> Miguel
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2025-10-15 10:32 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-10-15 2:20 [PATCH] rust: Add -fno-isolate-erroneous-paths-dereference to bindgen_skip_c_flags Xi Ruoyao
2025-10-15 3:19 ` Mingcong Bai
2025-10-15 10:20 ` Miguel Ojeda
2025-10-15 10:31 ` Huacai Chen
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).