* [PATCH] Skip gdb.dap/pause.exp on Solaris [PR34548]
@ 2026-08-20 14:18 Rainer Orth
2026-08-21 14:27 ` Tom Tromey
0 siblings, 1 reply; 10+ messages in thread
From: Rainer Orth @ 2026-08-20 14:18 UTC (permalink / raw)
To: gdb-patches; +Cc: Andrew Burgess, Simon Marchi
[-- Attachment #1: Type: text/plain, Size: 699 bytes --]
As detailed in PR PR dap/34548, the gdb.dap/pause.exp test runs
indefinitely on Solaris. To allow make check to finish, it needs to be
terminated manually.
To avoid this, this patch skips the test.
Tested on x86_64-pc-solaris2.11, sparcv9-sun-solaris2.11, and
x86_64-pc-linux-gnu.
Bug: https://sourceware.org/bugzilla/show_bug.cgi?id=34548
Ok for trunk?
I don't have the slightest idea where to look for the underlying issue,
but it's ugly enough to warrant a workaround, I believe.
This might also be a candidate for the gdb-18 branch.
Rainer
--
-----------------------------------------------------------------------------
Rainer Orth, Center for Biotechnology, Bielefeld University
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: sol2-skip-dap-pause.patch --]
[-- Type: text/x-patch, Size: 422 bytes --]
# HG changeset patch
# Parent 5cf8ddef7b178934eece36f830fc801d88fd3487
Skip gdb.dap/pause.exp on Solaris [PR34548]
diff --git a/gdb/testsuite/gdb.dap/pause.exp b/gdb/testsuite/gdb.dap/pause.exp
--- a/gdb/testsuite/gdb.dap/pause.exp
+++ b/gdb/testsuite/gdb.dap/pause.exp
@@ -15,6 +15,9 @@
# Test "pause" in DAP.
+# PR 34548
+require {!istarget "*-*-solaris2*"}
+
require allow_dap_tests
load_lib dap-support.exp
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: [PATCH] Skip gdb.dap/pause.exp on Solaris [PR34548]
2026-08-20 14:18 [PATCH] Skip gdb.dap/pause.exp on Solaris [PR34548] Rainer Orth
@ 2026-08-21 14:27 ` Tom Tromey
2026-08-22 20:25 ` Rainer Orth
0 siblings, 1 reply; 10+ messages in thread
From: Tom Tromey @ 2026-08-21 14:27 UTC (permalink / raw)
To: Rainer Orth; +Cc: gdb-patches, Andrew Burgess, Simon Marchi
>>>>> "Rainer" == Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE> writes:
Rainer> As detailed in PR PR dap/34548, the gdb.dap/pause.exp test runs
Rainer> indefinitely on Solaris. To allow make check to finish, it needs to be
Rainer> terminated manually.
Rainer> To avoid this, this patch skips the test.
Rainer> Tested on x86_64-pc-solaris2.11, sparcv9-sun-solaris2.11, and
Rainer> x86_64-pc-linux-gnu.
Rainer> Bug: https://sourceware.org/bugzilla/show_bug.cgi?id=34548
Rainer> Ok for trunk?
This is fine, but in the bug you mentioned other reports about target
async not working.
So maybe DAP testing should be entirely disabled for Solaris?
Approved-By: Tom Tromey <tom@tromey.com>
Rainer> This might also be a candidate for the gdb-18 branch.
It's fine by me.
Rainer> +# PR 34548
PR formatting, "PR dap/...". Thanks.
Tom
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: [PATCH] Skip gdb.dap/pause.exp on Solaris [PR34548]
2026-08-21 14:27 ` Tom Tromey
@ 2026-08-22 20:25 ` Rainer Orth
2026-08-24 9:42 ` Andrew Burgess
0 siblings, 1 reply; 10+ messages in thread
From: Rainer Orth @ 2026-08-22 20:25 UTC (permalink / raw)
To: Tom Tromey; +Cc: gdb-patches, Andrew Burgess, Simon Marchi
Hi Tom,
>>>>>> "Rainer" == Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE> writes:
>
> Rainer> As detailed in PR PR dap/34548, the gdb.dap/pause.exp test runs
> Rainer> indefinitely on Solaris. To allow make check to finish, it needs to be
> Rainer> terminated manually.
>
> Rainer> To avoid this, this patch skips the test.
>
> Rainer> Tested on x86_64-pc-solaris2.11, sparcv9-sun-solaris2.11, and
> Rainer> x86_64-pc-linux-gnu.
>
> Rainer> Bug: https://sourceware.org/bugzilla/show_bug.cgi?id=34548
>
> Rainer> Ok for trunk?
>
> This is fine, but in the bug you mentioned other reports about target
> async not working.
not actually reports, just ca. 100 instances of the
Asynchronous execution not supported on this target.
message in the full testsuite log. Some of them already turn the tests
UNSUPPORTED, while others cause the tests to FAIL.
> So maybe DAP testing should be entirely disabled for Solaris?
Like just returning 0 from allow_dap_tests on Solaris? Or doing so for
all targets lacking async support?
Here's a breakdown of gdb.dap results on Solaris:
8 ERROR
11 FAIL
713 PASS
8 PATH
8 UNRESOLVED
2 UNSUPPORTED
I can't tell if it's still useful this way.
> Rainer> This might also be a candidate for the gdb-18 branch.
>
> It's fine by me.
Thanks. I'll way for approval from a release manager then.
Rainer
--
-----------------------------------------------------------------------------
Rainer Orth, Center for Biotechnology, Bielefeld University
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: [PATCH] Skip gdb.dap/pause.exp on Solaris [PR34548]
2026-08-22 20:25 ` Rainer Orth
@ 2026-08-24 9:42 ` Andrew Burgess
2026-08-25 8:19 ` Rainer Orth
0 siblings, 1 reply; 10+ messages in thread
From: Andrew Burgess @ 2026-08-24 9:42 UTC (permalink / raw)
To: Rainer Orth, Tom Tromey; +Cc: gdb-patches, Simon Marchi
Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE> writes:
> Hi Tom,
>
>>>>>>> "Rainer" == Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE> writes:
>>
>> Rainer> As detailed in PR PR dap/34548, the gdb.dap/pause.exp test runs
>> Rainer> indefinitely on Solaris. To allow make check to finish, it needs to be
>> Rainer> terminated manually.
>>
>> Rainer> To avoid this, this patch skips the test.
>>
>> Rainer> Tested on x86_64-pc-solaris2.11, sparcv9-sun-solaris2.11, and
>> Rainer> x86_64-pc-linux-gnu.
>>
>> Rainer> Bug: https://sourceware.org/bugzilla/show_bug.cgi?id=34548
>>
>> Rainer> Ok for trunk?
>>
>> This is fine, but in the bug you mentioned other reports about target
>> async not working.
>
> not actually reports, just ca. 100 instances of the
>
> Asynchronous execution not supported on this target.
>
> message in the full testsuite log. Some of them already turn the tests
> UNSUPPORTED, while others cause the tests to FAIL.
>
>> So maybe DAP testing should be entirely disabled for Solaris?
>
> Like just returning 0 from allow_dap_tests on Solaris? Or doing so for
> all targets lacking async support?
I'd suggest adding:
# Return true for targets that support target async,
# otherwise return false.
proc supports_target_async {} {
# ...
}
then return 0 from allow_dap_tests for any target that returns false
from the above. That would seem better than just having a selective fix
in the pause.exp file.
>
> Here's a breakdown of gdb.dap results on Solaris:
>
> 8 ERROR
> 11 FAIL
> 713 PASS
> 8 PATH
> 8 UNRESOLVED
> 2 UNSUPPORTED
>
> I can't tell if it's still useful this way.
I haven't checked by a lot of these passes are going to be general
boiler plate stuff. If DAP support is known to require target async
then my personal feeling is that we'd be better just skipping those
tests on Solaris. There's plenty of testing done on other targets where
target async is supported.
>
>> Rainer> This might also be a candidate for the gdb-18 branch.
>>
>> It's fine by me.
>
> Thanks. I'll way for approval from a release manager then.
It might be worth getting the above changes made first. If you don't
have time then let me know and I'll take care of it.
Thanks,
Andrew
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: [PATCH] Skip gdb.dap/pause.exp on Solaris [PR34548]
2026-08-24 9:42 ` Andrew Burgess
@ 2026-08-25 8:19 ` Rainer Orth
2026-08-25 8:22 ` Rainer Orth
` (2 more replies)
0 siblings, 3 replies; 10+ messages in thread
From: Rainer Orth @ 2026-08-25 8:19 UTC (permalink / raw)
To: Andrew Burgess; +Cc: Tom Tromey, gdb-patches, Simon Marchi
[-- Attachment #1: Type: text/plain, Size: 2972 bytes --]
Hi Andrew,
>>> So maybe DAP testing should be entirely disabled for Solaris?
>>
>> Like just returning 0 from allow_dap_tests on Solaris? Or doing so for
>> all targets lacking async support?
>
> I'd suggest adding:
>
> # Return true for targets that support target async,
> # otherwise return false.
> proc supports_target_async {} {
> # ...
> }
>
> then return 0 from allow_dap_tests for any target that returns false
> from the above. That would seem better than just having a selective fix
> in the pause.exp file.
that certainly makes the most sense.
>> Here's a breakdown of gdb.dap results on Solaris:
>>
>> 8 ERROR
>> 11 FAIL
>> 713 PASS
>> 8 PATH
>> 8 UNRESOLVED
>> 2 UNSUPPORTED
>>
>> I can't tell if it's still useful this way.
>
> I haven't checked by a lot of these passes are going to be general
> boiler plate stuff. If DAP support is known to require target async
... which wasn't completely certain as far as I understood Tom...
> then my personal feeling is that we'd be better just skipping those
> tests on Solaris. There's plenty of testing done on other targets where
> target async is supported.
Right: some of them already do their own checks for async support:
gdb.base/async.exp
gdb.base/bg-exec-sigint-bp-cond.exp
gdb.base/interrupt-noterm.exp
but in those cases, async commands are a crucial part of the tests and I
couldn't easily use the new supports_target_async there.
There are certainly others that aren't handled yet. Besides, there are
ca. 400 tests that currently time out on Solaris, massively increasing
make check time ;-( I guess it's a major effort to reduce that number.
>>> Rainer> This might also be a candidate for the gdb-18 branch.
>>>
>>> It's fine by me.
>>
>> Thanks. I'll way for approval from a release manager then.
>
> It might be worth getting the above changes made first. If you don't
> have time then let me know and I'll take care of it.
I've now managed to get this working, although it took me some time to
wrap my head around gdb testing procedures.
Here's what I came up with. The only change on x86-64-pc-linux-gnu was
+PASS: gdb.testsuite/gdb-caching-proc-consistency.exp: supports_target_async: consistency
while on Solaris it fully disabled the gdb.dap tests as expected.
---------------------------------------------------------------------------
As detailed in PR PR dap/34548, the gdb.dap/pause.exp test runs
indefinitely on Solaris. To allow make check to finish, it needs to be
terminated manually.
Since DAP requires asynchronous execution support, this patch checks for
that and disables all gdb.dap tests if missing.
Tested on x86_64-pc-solaris2.11, sparcv9-sun-solaris2.11, and
x86_64-pc-linux-gnu.
Bug: https://sourceware.org/bugzilla/show_bug.cgi?id=34548
--
-----------------------------------------------------------------------------
Rainer Orth, Center for Biotechnology, Bielefeld University
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: testsuite-dap-async.patch --]
[-- Type: text/x-patch, Size: 1381 bytes --]
# HG changeset patch
# Parent 3fcec728f85b5d0cfef637d13368c88dad2e7bbc
Require async support for DAP tests [PR34548]
diff --git a/gdb/testsuite/lib/gdb.exp b/gdb/testsuite/lib/gdb.exp
--- a/gdb/testsuite/lib/gdb.exp
+++ b/gdb/testsuite/lib/gdb.exp
@@ -3070,6 +3070,10 @@ gdb_caching_proc with_system_readline {}
}
gdb_caching_proc allow_dap_tests {} {
+ if { ![supports_target_async] } {
+ return 0
+ }
+
if { ![allow_python_tests] } {
return 0
}
@@ -3908,6 +3912,39 @@ gdb_caching_proc supports_memtag {} {
return 0
}
+# Return 1 if target supports asynchronous execution, otherwise return 0.
+gdb_caching_proc supports_target_async {} {
+ global srcdir subdir gdb_prompt
+
+ set me "supports_target_async"
+
+ set src { int main() { return 0; } }
+ if {![gdb_simple_compile $me $src executable ""]} {
+ return 0
+ }
+
+ gdb_exit
+ gdb_start
+ gdb_reinitialize_dir $srcdir/$subdir
+ gdb_load $obj
+ if { ![runto_main] } {
+ return 0
+ }
+
+ set res 0
+ gdb_test_multiple "continue &" "" {
+ -re "Continuing..*" {
+ set res 1
+ }
+ -re ".*Asynchronous execution not supported on this target..*" {
+ set res 0
+ }
+ }
+ gdb_exit
+ remote_file build delete $obj
+ return $res
+}
+
# Return 1 if catch syscall is supported, otherwise return 0.
gdb_caching_proc supports_catch_syscall {} {
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: [PATCH] Skip gdb.dap/pause.exp on Solaris [PR34548]
2026-08-25 8:19 ` Rainer Orth
@ 2026-08-25 8:22 ` Rainer Orth
2026-08-27 15:42 ` Tom Tromey
2026-08-27 18:59 ` [PATCH] Skip gdb.dap/pauseR.exp on Solaris [PR34548] Andrew Burgess
2 siblings, 0 replies; 10+ messages in thread
From: Rainer Orth @ 2026-08-25 8:22 UTC (permalink / raw)
To: Andrew Burgess; +Cc: Tom Tromey, gdb-patches, Simon Marchi
The title should now be
Require async support for DAP tests [PR34548]
instead.
Rainer
--
-----------------------------------------------------------------------------
Rainer Orth, Center for Biotechnology, Bielefeld University
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: [PATCH] Skip gdb.dap/pause.exp on Solaris [PR34548]
2026-08-25 8:19 ` Rainer Orth
2026-08-25 8:22 ` Rainer Orth
@ 2026-08-27 15:42 ` Tom Tromey
2026-08-28 8:49 ` [PATCH v2] Require async support for DAP tests [PR34548] Rainer Orth
2026-08-27 18:59 ` [PATCH] Skip gdb.dap/pauseR.exp on Solaris [PR34548] Andrew Burgess
2 siblings, 1 reply; 10+ messages in thread
From: Tom Tromey @ 2026-08-27 15:42 UTC (permalink / raw)
To: Rainer Orth; +Cc: Andrew Burgess, Tom Tromey, gdb-patches, Simon Marchi
>>>>> "Rainer" == Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE> writes:
Rainer> Right: some of them already do their own checks for async support:
Rainer> gdb.base/async.exp
Rainer> gdb.base/bg-exec-sigint-bp-cond.exp
Rainer> gdb.base/interrupt-noterm.exp
Rainer> but in those cases, async commands are a crucial part of the tests and I
Rainer> couldn't easily use the new supports_target_async there.
I think it would be fine to stick
require supports_target_async
At the top of each of these files, and simplify some of the tests to
just assumes async execution will work.
However that can also be comfortably done in a separate patch as well.
Rainer> +# Return 1 if target supports asynchronous execution, otherwise return 0.
Rainer> +gdb_caching_proc supports_target_async {} {
Rainer> + global srcdir subdir gdb_prompt
Rainer> +
Rainer> + set me "supports_target_async"
Rainer> +
Rainer> + set src { int main() { return 0; } }
Rainer> + if {![gdb_simple_compile $me $src executable ""]} {
Rainer> + return 0
Rainer> + }
Rainer> +
Rainer> + gdb_exit
Rainer> + gdb_start
Rainer> + gdb_reinitialize_dir $srcdir/$subdir
I think these three lines can be replaced with "clean_restart".
Rainer> + if { ![runto_main] } {
Rainer> + return 0
This branch doesn't gdb_exit but falling through does.
Likewise this return doesn't delete the file.
So maybe reworking this to fall through to the cleanup & final return
would be better.
thanks,
Tom
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: [PATCH] Skip gdb.dap/pauseR.exp on Solaris [PR34548]
2026-08-25 8:19 ` Rainer Orth
2026-08-25 8:22 ` Rainer Orth
2026-08-27 15:42 ` Tom Tromey
@ 2026-08-27 18:59 ` Andrew Burgess
2026-08-28 8:52 ` Rainer Orth
2 siblings, 1 reply; 10+ messages in thread
From: Andrew Burgess @ 2026-08-27 18:59 UTC (permalink / raw)
To: Rainer Orth; +Cc: Tom Tromey, gdb-patches, Simon Marchi
Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE> writes:
> Hi Andrew,
>
>>>> So maybe DAP testing should be entirely disabled for Solaris?
>>>
>>> Like just returning 0 from allow_dap_tests on Solaris? Or doing so for
>>> all targets lacking async support?
>>
>> I'd suggest adding:
>>
>> # Return true for targets that support target async,
>> # otherwise return false.
>> proc supports_target_async {} {
>> # ...
>> }
>>
>> then return 0 from allow_dap_tests for any target that returns false
>> from the above. That would seem better than just having a selective fix
>> in the pause.exp file.
>
> that certainly makes the most sense.
>
>>> Here's a breakdown of gdb.dap results on Solaris:
>>>
>>> 8 ERROR
>>> 11 FAIL
>>> 713 PASS
>>> 8 PATH
>>> 8 UNRESOLVED
>>> 2 UNSUPPORTED
>>>
>>> I can't tell if it's still useful this way.
>>
>> I haven't checked by a lot of these passes are going to be general
>> boiler plate stuff. If DAP support is known to require target async
>
> ... which wasn't completely certain as far as I understood Tom...
>
>> then my personal feeling is that we'd be better just skipping those
>> tests on Solaris. There's plenty of testing done on other targets where
>> target async is supported.
>
> Right: some of them already do their own checks for async support:
>
> gdb.base/async.exp
> gdb.base/bg-exec-sigint-bp-cond.exp
> gdb.base/interrupt-noterm.exp
>
> but in those cases, async commands are a crucial part of the tests and I
> couldn't easily use the new supports_target_async there.
>
> There are certainly others that aren't handled yet. Besides, there are
> ca. 400 tests that currently time out on Solaris, massively increasing
> make check time ;-( I guess it's a major effort to reduce that number.
>
>>>> Rainer> This might also be a candidate for the gdb-18 branch.
>>>>
>>>> It's fine by me.
>>>
>>> Thanks. I'll way for approval from a release manager then.
>>
>> It might be worth getting the above changes made first. If you don't
>> have time then let me know and I'll take care of it.
>
> I've now managed to get this working, although it took me some time to
> wrap my head around gdb testing procedures.
>
> Here's what I came up with. The only change on x86-64-pc-linux-gnu was
>
> +PASS: gdb.testsuite/gdb-caching-proc-consistency.exp: supports_target_async: consistency
>
> while on Solaris it fully disabled the gdb.dap tests as expected.
>
> ---------------------------------------------------------------------------
>
> As detailed in PR PR dap/34548, the gdb.dap/pause.exp test runs
> indefinitely on Solaris. To allow make check to finish, it needs to be
> terminated manually.
>
> Since DAP requires asynchronous execution support, this patch checks for
> that and disables all gdb.dap tests if missing.
>
> Tested on x86_64-pc-solaris2.11, sparcv9-sun-solaris2.11, and
> x86_64-pc-linux-gnu.
>
> Bug: https://sourceware.org/bugzilla/show_bug.cgi?id=34548
>
> --
> -----------------------------------------------------------------------------
> Rainer Orth, Center for Biotechnology, Bielefeld University
>
>
> # HG changeset patch
> # Parent 3fcec728f85b5d0cfef637d13368c88dad2e7bbc
> Require async support for DAP tests [PR34548]
>
> diff --git a/gdb/testsuite/lib/gdb.exp b/gdb/testsuite/lib/gdb.exp
> --- a/gdb/testsuite/lib/gdb.exp
> +++ b/gdb/testsuite/lib/gdb.exp
> @@ -3070,6 +3070,10 @@ gdb_caching_proc with_system_readline {}
> }
>
> gdb_caching_proc allow_dap_tests {} {
> + if { ![supports_target_async] } {
> + return 0
> + }
> +
> if { ![allow_python_tests] } {
> return 0
> }
> @@ -3908,6 +3912,39 @@ gdb_caching_proc supports_memtag {} {
> return 0
> }
>
> +# Return 1 if target supports asynchronous execution, otherwise return 0.
> +gdb_caching_proc supports_target_async {} {
> + global srcdir subdir gdb_prompt
> +
> + set me "supports_target_async"
> +
> + set src { int main() { return 0; } }
> + if {![gdb_simple_compile $me $src executable ""]} {
> + return 0
> + }
> +
> + gdb_exit
> + gdb_start
> + gdb_reinitialize_dir $srcdir/$subdir
> + gdb_load $obj
> + if { ![runto_main] } {
> + return 0
> + }
> +
> + set res 0
> + gdb_test_multiple "continue &" "" {
> + -re "Continuing..*" {
> + set res 1
> + }
> + -re ".*Asynchronous execution not supported on this target..*" {
> + set res 0
> + }
> + }
> + gdb_exit
> + remote_file build delete $obj
> + return $res
> +}
> +
> # Return 1 if catch syscall is supported, otherwise return 0.
>
> gdb_caching_proc supports_catch_syscall {} {
Thanks for working on this.
Other than Tom's comments, I think this looks fine. I will note that
the issues Tom pointed out are present in lots of the other supports_*
procs -- not that I expect you to fix them, just noting that lots of
this code is a little rough.
I'd also ask that you remove these lines from gdb.dap/pause.exp:
# PR dap/34548
require {!istarget "*-*-solaris2*"}
at the same time as you merge this, as these are no longer needed.
Thanks,
Andrew
^ permalink raw reply [flat|nested] 10+ messages in thread
* [PATCH v2] Require async support for DAP tests [PR34548]
2026-08-27 15:42 ` Tom Tromey
@ 2026-08-28 8:49 ` Rainer Orth
0 siblings, 0 replies; 10+ messages in thread
From: Rainer Orth @ 2026-08-28 8:49 UTC (permalink / raw)
To: Tom Tromey; +Cc: Andrew Burgess, gdb-patches, Simon Marchi
[-- Attachment #1: Type: text/plain, Size: 2388 bytes --]
Hi Tom,
>>>>>> "Rainer" == Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE> writes:
>
> Rainer> Right: some of them already do their own checks for async support:
>
> Rainer> gdb.base/async.exp
> Rainer> gdb.base/bg-exec-sigint-bp-cond.exp
> Rainer> gdb.base/interrupt-noterm.exp
>
> Rainer> but in those cases, async commands are a crucial part of the tests and I
> Rainer> couldn't easily use the new supports_target_async there.
>
> I think it would be fine to stick
>
> require supports_target_async
>
> At the top of each of these files, and simplify some of the tests to
> just assumes async execution will work.
in some cases, this seems to be the right way forward. However, I've a
hard time telling which ones should have this treatment. Others clearly
run tests both in sync and async modes (like
gdb.base/infcall-timeout.exp,
gdb.threads/infcall-from-bp-cond-timeout.exp). At least in those cases,
we can just skip the async subtests.
> However that can also be comfortably done in a separate patch as well.
I'd rather do it this way, initially concentrating on the cases where
skipping target_async tests can avoid large numbers of timeouts.
> Rainer> +# Return 1 if target supports asynchronous execution, otherwise return 0.
> Rainer> +gdb_caching_proc supports_target_async {} {
> Rainer> + global srcdir subdir gdb_prompt
> Rainer> +
> Rainer> + set me "supports_target_async"
> Rainer> +
> Rainer> + set src { int main() { return 0; } }
> Rainer> + if {![gdb_simple_compile $me $src executable ""]} {
> Rainer> + return 0
> Rainer> + }
> Rainer> +
> Rainer> + gdb_exit
> Rainer> + gdb_start
> Rainer> + gdb_reinitialize_dir $srcdir/$subdir
>
> I think these three lines can be replaced with "clean_restart".
Nice. So far, I've simply followed existing current practice, although
I've wondered how many tests seem extremely repetetive and
consequentially hard to read.
> Rainer> + if { ![runto_main] } {
> Rainer> + return 0
>
> This branch doesn't gdb_exit but falling through does.
> Likewise this return doesn't delete the file.
>
> So maybe reworking this to fall through to the cleanup & final return
> would be better.
Done in the attached revision.
Thanks.
Rainer
--
-----------------------------------------------------------------------------
Rainer Orth, Center for Biotechnology, Bielefeld University
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: testsuite-dap-async.patch --]
[-- Type: text/x-patch, Size: 1629 bytes --]
# HG changeset patch
# Parent 3fcec728f85b5d0cfef637d13368c88dad2e7bbc
Require async support for DAP tests [PR34548]
diff --git a/gdb/testsuite/gdb.dap/pause.exp b/gdb/testsuite/gdb.dap/pause.exp
--- a/gdb/testsuite/gdb.dap/pause.exp
+++ b/gdb/testsuite/gdb.dap/pause.exp
@@ -15,9 +15,6 @@
# Test "pause" in DAP.
-# PR dap/34548
-require {!istarget "*-*-solaris2*"}
-
require allow_dap_tests
load_lib dap-support.exp
diff --git a/gdb/testsuite/lib/gdb.exp b/gdb/testsuite/lib/gdb.exp
--- a/gdb/testsuite/lib/gdb.exp
+++ b/gdb/testsuite/lib/gdb.exp
@@ -3070,6 +3070,10 @@ gdb_caching_proc with_system_readline {}
}
gdb_caching_proc allow_dap_tests {} {
+ if { ![supports_target_async] } {
+ return 0
+ }
+
if { ![allow_python_tests] } {
return 0
}
@@ -3908,6 +3912,37 @@ gdb_caching_proc supports_memtag {} {
return 0
}
+# Return 1 if target supports asynchronous execution, otherwise return 0.
+gdb_caching_proc supports_target_async {} {
+ global srcdir subdir gdb_prompt
+
+ set me "supports_target_async"
+
+ set src { int main() { return 0; } }
+ if {![gdb_simple_compile $me $src executable ""]} {
+ return 0
+ }
+
+ clean_restart
+ gdb_load $obj
+
+ if { [runto_main] } {
+ set res 0
+ gdb_test_multiple "continue &" "" {
+ -re "Continuing..*" {
+ set res 1
+ }
+ -re ".*Asynchronous execution not supported on this target..*" {
+ set res 0
+ }
+ }
+ }
+
+ gdb_exit
+ remote_file build delete $obj
+ return $res
+}
+
# Return 1 if catch syscall is supported, otherwise return 0.
gdb_caching_proc supports_catch_syscall {} {
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: [PATCH] Skip gdb.dap/pauseR.exp on Solaris [PR34548]
2026-08-27 18:59 ` [PATCH] Skip gdb.dap/pauseR.exp on Solaris [PR34548] Andrew Burgess
@ 2026-08-28 8:52 ` Rainer Orth
0 siblings, 0 replies; 10+ messages in thread
From: Rainer Orth @ 2026-08-28 8:52 UTC (permalink / raw)
To: Andrew Burgess; +Cc: Tom Tromey, gdb-patches, Simon Marchi
Hi Andrew,
>> Here's what I came up with. The only change on x86-64-pc-linux-gnu was
>>
>> +PASS: gdb.testsuite/gdb-caching-proc-consistency.exp: supports_target_async: consistency
>>
>> while on Solaris it fully disabled the gdb.dap tests as expected.
> Thanks for working on this.
thanks for the review.
> Other than Tom's comments, I think this looks fine. I will note that
> the issues Tom pointed out are present in lots of the other supports_*
> procs -- not that I expect you to fix them, just noting that lots of
> this code is a little rough.
Absolutely, and this just gets copied to other cases, spreading bad
examples even further ;-)
> I'd also ask that you remove these lines from gdb.dap/pause.exp:
>
> # PR dap/34548
> require {!istarget "*-*-solaris2*"}
>
> at the same time as you merge this, as these are no longer needed.
Done in the revision I've just sent. I originally meant to revert that
patch separately.
Thanks.
Rainer
--
-----------------------------------------------------------------------------
Rainer Orth, Center for Biotechnology, Bielefeld University
^ permalink raw reply [flat|nested] 10+ messages in thread
end of thread, other threads:[~2026-08-28 8:53 UTC | newest]
Thread overview: 10+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2026-08-20 14:18 [PATCH] Skip gdb.dap/pause.exp on Solaris [PR34548] Rainer Orth
2026-08-21 14:27 ` Tom Tromey
2026-08-22 20:25 ` Rainer Orth
2026-08-24 9:42 ` Andrew Burgess
2026-08-25 8:19 ` Rainer Orth
2026-08-25 8:22 ` Rainer Orth
2026-08-27 15:42 ` Tom Tromey
2026-08-28 8:49 ` [PATCH v2] Require async support for DAP tests [PR34548] Rainer Orth
2026-08-27 18:59 ` [PATCH] Skip gdb.dap/pauseR.exp on Solaris [PR34548] Andrew Burgess
2026-08-28 8:52 ` Rainer Orth
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox