public inbox for gcc-patches@gcc.gnu.org
 help / color / mirror / Atom feed
* [PATCH htdocs] bugs: Mention -D_GLIBCXX_ASSERTIONS and -D_GLIBCXX_DEBUG
@ 2023-10-26 17:12 Sam James
  2023-10-26 19:04 ` Jonathan Wakely
  0 siblings, 1 reply; 3+ messages in thread
From: Sam James @ 2023-10-26 17:12 UTC (permalink / raw)
  To: gcc-patches; +Cc: gerald, jwakely, Sam James

These options both enabled more checking within the C++ standard library
and can expose errors in submitted code.

-D_GLIBCXX_DEBUG is mentioned separately because while we want people to try it,
it's not always feasible because it requires the whole program and any used
libraries to also be built with it (as it breaks ABI).

Signed-off-by: Sam James <sam@gentoo.org>
---
 htdocs/bugs/index.html | 7 +++++++
 1 file changed, 7 insertions(+)

diff --git a/htdocs/bugs/index.html b/htdocs/bugs/index.html
index da3d4c0d..a5a38f42 100644
--- a/htdocs/bugs/index.html
+++ b/htdocs/bugs/index.html
@@ -56,6 +56,13 @@ makes a difference, or if compiling with <code>-fsanitize=undefined</code>
 produces any run-time errors, then your code is probably not correct.
 </p>
 
+<p>We also ask that for C++ code, users test their programs with
+<code>-D_GLIBCXX_ASSERTIONS</code>. If you're able to rebuild the entire
+program (including any libraries it uses, because it breaks ABI), please do try
+<code>-D_GLIBCXX_DEBUG</code> which enables thorough checking throughout
+the C++ standard library. If either of these fail, this is a strong indicator
+of an error in your code.</p>
+
 <h2>Summarized bug reporting instructions</h2>
 
 <p>After this summary, you'll find detailed instructions that explain
-- 
2.42.0


^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [PATCH htdocs] bugs: Mention -D_GLIBCXX_ASSERTIONS and -D_GLIBCXX_DEBUG
  2023-10-26 17:12 [PATCH htdocs] bugs: Mention -D_GLIBCXX_ASSERTIONS and -D_GLIBCXX_DEBUG Sam James
@ 2023-10-26 19:04 ` Jonathan Wakely
  2023-10-26 19:14   ` Sam James
  0 siblings, 1 reply; 3+ messages in thread
From: Jonathan Wakely @ 2023-10-26 19:04 UTC (permalink / raw)
  To: Sam James; +Cc: gcc-patches, gerald

[-- Attachment #1: Type: text/plain, Size: 1646 bytes --]

On Thursday, 26 October 2023, Sam James <sam@gentoo.org> wrote:
> These options both enabled more checking within the C++ standard library
> and can expose errors in submitted code.
>
> -D_GLIBCXX_DEBUG is mentioned separately because while we want people to
try it,
> it's not always feasible because it requires the whole program and any
used
> libraries to also be built with it (as it breaks ABI).
>
> Signed-off-by: Sam James <sam@gentoo.org>
> ---
>  htdocs/bugs/index.html | 7 +++++++
>  1 file changed, 7 insertions(+)
>
> diff --git a/htdocs/bugs/index.html b/htdocs/bugs/index.html
> index da3d4c0d..a5a38f42 100644
> --- a/htdocs/bugs/index.html
> +++ b/htdocs/bugs/index.html
> @@ -56,6 +56,13 @@ makes a difference, or if compiling with
<code>-fsanitize=undefined</code>
>  produces any run-time errors, then your code is probably not correct.
>  </p>
>
> +<p>We also ask that for C++ code, users test their programs with
> +<code>-D_GLIBCXX_ASSERTIONS</code>. If you're able to rebuild the entire
> +program (including any libraries it uses, because it breaks ABI), please
do try

s/breaks/changes/ maybe? Breaks sounds like it's doing something bad.

> +<code>-D_GLIBCXX_DEBUG</code> which enables thorough checking throughout

It's not really throughout, just in containers and algos. Maybe "which
enables more thorough checking in parts of the C++ standard library".

> +the C++ standard library. If either of these fail, this is a strong
indicator
> +of an error in your code.</p>
> +
>  <h2>Summarized bug reporting instructions</h2>
>
>  <p>After this summary, you'll find detailed instructions that explain
> --
> 2.42.0
>
>

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [PATCH htdocs] bugs: Mention -D_GLIBCXX_ASSERTIONS and -D_GLIBCXX_DEBUG
  2023-10-26 19:04 ` Jonathan Wakely
@ 2023-10-26 19:14   ` Sam James
  0 siblings, 0 replies; 3+ messages in thread
From: Sam James @ 2023-10-26 19:14 UTC (permalink / raw)
  To: Jonathan Wakely; +Cc: Sam James, gcc-patches, gerald


Jonathan Wakely <jwakely@redhat.com> writes:

> On Thursday, 26 October 2023, Sam James <sam@gentoo.org> wrote:
>> These options both enabled more checking within the C++ standard library
>> and can expose errors in submitted code.
>>
>> -D_GLIBCXX_DEBUG is mentioned separately because while we want people to try it,
>> it's not always feasible because it requires the whole program and any used
>> libraries to also be built with it (as it breaks ABI).
>>
>> Signed-off-by: Sam James <sam@gentoo.org>
>> ---
>>  htdocs/bugs/index.html | 7 +++++++
>>  1 file changed, 7 insertions(+)
>>
>> diff --git a/htdocs/bugs/index.html b/htdocs/bugs/index.html
>> index da3d4c0d..a5a38f42 100644
>> --- a/htdocs/bugs/index.html
>> +++ b/htdocs/bugs/index.html
>> @@ -56,6 +56,13 @@ makes a difference, or if compiling with <code>-fsanitize=undefined</code>
>>  produces any run-time errors, then your code is probably not correct.
>>  </p>
>>
>> +<p>We also ask that for C++ code, users test their programs with
>> +<code>-D_GLIBCXX_ASSERTIONS</code>. If you're able to rebuild the entire
>> +program (including any libraries it uses, because it breaks ABI), please do try
>
> s/breaks/changes/ maybe? Breaks sounds like it's doing something bad.

Ah, yeah, a bad habit of mine I think.

>
>> +<code>-D_GLIBCXX_DEBUG</code> which enables thorough checking throughout
>
> It's not really throughout, just in containers and algos. Maybe "which enables more thorough checking in parts of the C++
> standard library".
>

wfm

>> +the C++ standard library. If either of these fail, this is a strong indicator
>> +of an error in your code.</p>
>> +
>>  <h2>Summarized bug reporting instructions</h2>
>>
>>  <p>After this summary, you'll find detailed instructions that explain
>> --
>> 2.42.0
>>
>>


^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2023-10-26 19:15 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-10-26 17:12 [PATCH htdocs] bugs: Mention -D_GLIBCXX_ASSERTIONS and -D_GLIBCXX_DEBUG Sam James
2023-10-26 19:04 ` Jonathan Wakely
2023-10-26 19:14   ` Sam James

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 read-only IMAP folder(s) and NNTP newsgroup(s).