* [PATCH] automation: enable UBSAN for debug tests
@ 2025-02-06 2:37 Stefano Stabellini
2025-02-06 7:46 ` Orzel, Michal
2025-02-07 9:27 ` Andrew Cooper
0 siblings, 2 replies; 7+ messages in thread
From: Stefano Stabellini @ 2025-02-06 2:37 UTC (permalink / raw)
To: xen-devel
Cc: sstabellini, cardoe, alejandro.vallejo, andrew.cooper3,
anthony.perard, michal.orzel, jbeulich, julien, roger.pau,
bertrand.marquis
automation: enable UBSAN for debug tests
Enable CONFIG_UBSAN and CONFIG_UBSAN_FATAL for the ARM64 and x86_64
build jobs, with debug enabled, which are later used for Xen tests on
QEMU and/or real hardware.
Signed-off-by: Stefano Stabellini <stefano.stabellini@amd.com>
---
successful pipeline: https://gitlab.com/xen-project/people/sstabellini/xen/-/pipelines/1657961377
diff --git a/automation/gitlab-ci/build.yaml b/automation/gitlab-ci/build.yaml
index bc4a8a5ad2..fb55d4ce55 100644
--- a/automation/gitlab-ci/build.yaml
+++ b/automation/gitlab-ci/build.yaml
@@ -333,6 +333,8 @@ alpine-3.18-gcc-debug:
CONFIG_EXPERT=y
CONFIG_UNSUPPORTED=y
CONFIG_ARGO=y
+ CONFIG_UBSAN=y
+ CONFIG_UBSAN_FATAL=y
debian-12-x86_64-gcc-debug:
extends: .gcc-x86-64-build-debug
@@ -419,6 +421,9 @@ alpine-3.18-gcc-debug-arm64:
extends: .gcc-arm64-build-debug
variables:
CONTAINER: alpine:3.18-arm64v8
+ EXTRA_XEN_CONFIG: |
+ CONFIG_UBSAN=y
+ CONFIG_UBSAN_FATAL=y
alpine-3.18-gcc-arm64-randconfig:
extends: .gcc-arm64-build
^ permalink raw reply related [flat|nested] 7+ messages in thread
* Re: [PATCH] automation: enable UBSAN for debug tests
2025-02-06 2:37 [PATCH] automation: enable UBSAN for debug tests Stefano Stabellini
@ 2025-02-06 7:46 ` Orzel, Michal
2025-02-06 23:03 ` Stefano Stabellini
2025-02-07 9:27 ` Andrew Cooper
1 sibling, 1 reply; 7+ messages in thread
From: Orzel, Michal @ 2025-02-06 7:46 UTC (permalink / raw)
To: Stefano Stabellini, xen-devel
Cc: cardoe, alejandro.vallejo, andrew.cooper3, anthony.perard,
jbeulich, julien, roger.pau, bertrand.marquis
On 06/02/2025 03:37, Stefano Stabellini wrote:
>
>
> automation: enable UBSAN for debug tests
>
> Enable CONFIG_UBSAN and CONFIG_UBSAN_FATAL for the ARM64 and x86_64
> build jobs, with debug enabled, which are later used for Xen tests on
> QEMU and/or real hardware.
>
> Signed-off-by: Stefano Stabellini <stefano.stabellini@amd.com>
Reviewed-by: Michal Orzel <michal.orzel@amd.com>
However, I do remember Julien being opposed to this approach in the past, mostly because he did not like
the idea of failing on first UB that can possibly hide next UBs (I don't see this as a problem because other
UBs will simply be found on the next pipeline or locally when testing the fix).
~Michal
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [PATCH] automation: enable UBSAN for debug tests
2025-02-06 7:46 ` Orzel, Michal
@ 2025-02-06 23:03 ` Stefano Stabellini
2025-02-07 8:28 ` Oleksii Kurochko
0 siblings, 1 reply; 7+ messages in thread
From: Stefano Stabellini @ 2025-02-06 23:03 UTC (permalink / raw)
To: Orzel, Michal
Cc: Stefano Stabellini, xen-devel, cardoe, alejandro.vallejo,
andrew.cooper3, anthony.perard, jbeulich, julien, roger.pau,
bertrand.marquis, oleksii.kurochko
On Thu, 6 Feb 2025, Orzel, Michal wrote:
> On 06/02/2025 03:37, Stefano Stabellini wrote:
> >
> >
> > automation: enable UBSAN for debug tests
> >
> > Enable CONFIG_UBSAN and CONFIG_UBSAN_FATAL for the ARM64 and x86_64
> > build jobs, with debug enabled, which are later used for Xen tests on
> > QEMU and/or real hardware.
> >
> > Signed-off-by: Stefano Stabellini <stefano.stabellini@amd.com>
> Reviewed-by: Michal Orzel <michal.orzel@amd.com>
Thanks!
> However, I do remember Julien being opposed to this approach in the past, mostly because he did not like
> the idea of failing on first UB that can possibly hide next UBs (I don't see this as a problem because other
> UBs will simply be found on the next pipeline or locally when testing the fix).
That may have been a problem in the past, but it is no longer an issue
now that the pipeline is fully operational with UBSAN enabled on both
ARM and x86.
Andrew also mentioned in chat that he supports enabling UBSAN in the
pipeline as soon as possible.
Since the pipeline remains green with UBSAN enabled and is not expected
to suddenly go red before the release, I am requesting a release
ack from Oleksii.
Cheers,
Stefano
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [PATCH] automation: enable UBSAN for debug tests
2025-02-06 23:03 ` Stefano Stabellini
@ 2025-02-07 8:28 ` Oleksii Kurochko
0 siblings, 0 replies; 7+ messages in thread
From: Oleksii Kurochko @ 2025-02-07 8:28 UTC (permalink / raw)
To: Stefano Stabellini, Orzel, Michal
Cc: xen-devel, cardoe, alejandro.vallejo, andrew.cooper3,
anthony.perard, jbeulich, julien, roger.pau, bertrand.marquis
[-- Attachment #1: Type: text/plain, Size: 1398 bytes --]
On 2/7/25 12:03 AM, Stefano Stabellini wrote:
> On Thu, 6 Feb 2025, Orzel, Michal wrote:
>> On 06/02/2025 03:37, Stefano Stabellini wrote:
>>>
>>> automation: enable UBSAN for debug tests
>>>
>>> Enable CONFIG_UBSAN and CONFIG_UBSAN_FATAL for the ARM64 and x86_64
>>> build jobs, with debug enabled, which are later used for Xen tests on
>>> QEMU and/or real hardware.
>>>
>>> Signed-off-by: Stefano Stabellini<stefano.stabellini@amd.com>
>> Reviewed-by: Michal Orzel<michal.orzel@amd.com>
> Thanks!
>
>
>> However, I do remember Julien being opposed to this approach in the past, mostly because he did not like
>> the idea of failing on first UB that can possibly hide next UBs (I don't see this as a problem because other
>> UBs will simply be found on the next pipeline or locally when testing the fix).
> That may have been a problem in the past, but it is no longer an issue
> now that the pipeline is fully operational with UBSAN enabled on both
> ARM and x86.
>
> Andrew also mentioned in chat that he supports enabling UBSAN in the
> pipeline as soon as possible.
>
> Since the pipeline remains green with UBSAN enabled and is not expected
> to suddenly go red before the release, I am requesting a release
> ack from Oleksii.
Agree, enabling UBSAN support in the pipeline is a good idea, so:
R-Acked-by: Oleksii Kurochko<oleksii.kurochko@gmail.com>
~ Oleksii
>
> Cheers,
>
> Stefano
[-- Attachment #2: Type: text/html, Size: 2608 bytes --]
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [PATCH] automation: enable UBSAN for debug tests
2025-02-06 2:37 [PATCH] automation: enable UBSAN for debug tests Stefano Stabellini
2025-02-06 7:46 ` Orzel, Michal
@ 2025-02-07 9:27 ` Andrew Cooper
2025-02-07 23:05 ` Stefano Stabellini
1 sibling, 1 reply; 7+ messages in thread
From: Andrew Cooper @ 2025-02-07 9:27 UTC (permalink / raw)
To: Stefano Stabellini, xen-devel
Cc: cardoe, alejandro.vallejo, anthony.perard, michal.orzel, jbeulich,
julien, roger.pau, bertrand.marquis
On 06/02/2025 2:37 am, Stefano Stabellini wrote:
> automation: enable UBSAN for debug tests
>
> Enable CONFIG_UBSAN and CONFIG_UBSAN_FATAL for the ARM64 and x86_64
> build jobs, with debug enabled, which are later used for Xen tests on
> QEMU and/or real hardware.
>
> Signed-off-by: Stefano Stabellini <stefano.stabellini@amd.com>
Reviewed-by: Andrew Cooper <andrew.cooper3@citrix.com>, but aren't you
missing two builds?
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [PATCH] automation: enable UBSAN for debug tests
2025-02-07 9:27 ` Andrew Cooper
@ 2025-02-07 23:05 ` Stefano Stabellini
2025-02-07 23:06 ` Andrew Cooper
0 siblings, 1 reply; 7+ messages in thread
From: Stefano Stabellini @ 2025-02-07 23:05 UTC (permalink / raw)
To: Andrew Cooper
Cc: Stefano Stabellini, xen-devel, cardoe, alejandro.vallejo,
anthony.perard, michal.orzel, jbeulich, julien, roger.pau,
bertrand.marquis
On Fri, 7 Feb 2025, Andrew Cooper wrote:
> On 06/02/2025 2:37 am, Stefano Stabellini wrote:
> > automation: enable UBSAN for debug tests
> >
> > Enable CONFIG_UBSAN and CONFIG_UBSAN_FATAL for the ARM64 and x86_64
> > build jobs, with debug enabled, which are later used for Xen tests on
> > QEMU and/or real hardware.
> >
> > Signed-off-by: Stefano Stabellini <stefano.stabellini@amd.com>
>
> Reviewed-by: Andrew Cooper <andrew.cooper3@citrix.com>, but aren't you
> missing two builds?
Thanks Andrew.
Looking at test.yaml in details, this is the list of debug Xen builds
for ARM64 and x86_64 without UBSAN enabled:
alpine-3.18-gcc-debug-arm64-staticmem
alpine-3.18-gcc-debug-arm64-static-shared-mem
alpine-3.18-gcc-debug-arm64-earlyprintk
debian-12-x86_64-gcc-debug
debian-12-x86_64-clang-debug
Do you think we should enable UBSAN in all of them? I am fine with that.
So far, I have only targeted the two that are used more widely.
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [PATCH] automation: enable UBSAN for debug tests
2025-02-07 23:05 ` Stefano Stabellini
@ 2025-02-07 23:06 ` Andrew Cooper
0 siblings, 0 replies; 7+ messages in thread
From: Andrew Cooper @ 2025-02-07 23:06 UTC (permalink / raw)
To: Stefano Stabellini
Cc: xen-devel, cardoe, alejandro.vallejo, anthony.perard,
michal.orzel, jbeulich, julien, roger.pau, bertrand.marquis
On 07/02/2025 11:05 pm, Stefano Stabellini wrote:
> On Fri, 7 Feb 2025, Andrew Cooper wrote:
>> On 06/02/2025 2:37 am, Stefano Stabellini wrote:
>>> automation: enable UBSAN for debug tests
>>>
>>> Enable CONFIG_UBSAN and CONFIG_UBSAN_FATAL for the ARM64 and x86_64
>>> build jobs, with debug enabled, which are later used for Xen tests on
>>> QEMU and/or real hardware.
>>>
>>> Signed-off-by: Stefano Stabellini <stefano.stabellini@amd.com>
>> Reviewed-by: Andrew Cooper <andrew.cooper3@citrix.com>, but aren't you
>> missing two builds?
> Thanks Andrew.
>
> Looking at test.yaml in details, this is the list of debug Xen builds
> for ARM64 and x86_64 without UBSAN enabled:
>
> alpine-3.18-gcc-debug-arm64-staticmem
> alpine-3.18-gcc-debug-arm64-static-shared-mem
> alpine-3.18-gcc-debug-arm64-earlyprintk
> debian-12-x86_64-gcc-debug
> debian-12-x86_64-clang-debug
>
> Do you think we should enable UBSAN in all of them? I am fine with that.
> So far, I have only targeted the two that are used more widely.
I was referring to RISC-V and PPC.
I've done a series enabling UBSAN in RISC-V. I'm currently fixing bugs
in ARM, and PPC is unknown because the console is broken for some reason
I can't fathom.
~Andrew
^ permalink raw reply [flat|nested] 7+ messages in thread
end of thread, other threads:[~2025-02-07 23:07 UTC | newest]
Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-02-06 2:37 [PATCH] automation: enable UBSAN for debug tests Stefano Stabellini
2025-02-06 7:46 ` Orzel, Michal
2025-02-06 23:03 ` Stefano Stabellini
2025-02-07 8:28 ` Oleksii Kurochko
2025-02-07 9:27 ` Andrew Cooper
2025-02-07 23:05 ` Stefano Stabellini
2025-02-07 23:06 ` Andrew Cooper
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.