public inbox for gcc-patches@gcc.gnu.org
 help / color / mirror / Atom feed
From: Segher Boessenkool <segher@kernel.crashing.org>
To: Andrew MacLeod <amacleod@redhat.com>
Cc: gcc-patches <gcc-patches@gcc.gnu.org>
Subject: Re: [PATCH] Add divide by zero side effect.
Date: Wed, 18 May 2022 13:13:48 -0500	[thread overview]
Message-ID: <20220518181348.GC25951@gate.crashing.org> (raw)
In-Reply-To: <c511febf-7a4d-1754-1893-ac77602a18d5@redhat.com>

On Tue, May 17, 2022 at 02:39:11PM -0400, Andrew MacLeod via Gcc-patches wrote:
> I haven't checked this patch in yet.  This implements a side effect that 
> the divisor cannot be 0 after a divide executes. This allows us to fold 
> the divide away:

"Side effect" already has a meaning, very commonly used in language
theory, and even in the C standard itself: a function has a side effect
if it does something more than just return a value: if it changes state.
This can be some I/O, or it can just be writing to some non-local data.

Side effects are crucial to what a compiler does, and they are used all
over the place (the gcc/ dir has some thousand mentions of it for
example).

Please don't make life hard for everyone by overloading this term.


Segher

  parent reply	other threads:[~2022-05-18 18:14 UTC|newest]

Thread overview: 26+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-05-17 18:39 Andrew MacLeod
2022-05-18  6:28 ` Richard Biener
2022-05-18 13:20   ` Andrew MacLeod
2022-05-18 18:13 ` Segher Boessenkool [this message]
2022-05-18 20:24   ` Andrew MacLeod
2022-05-18 20:40     ` Segher Boessenkool
2022-05-19 13:22       ` Andrew MacLeod
2022-05-19 22:23         ` Segher Boessenkool
2022-05-20  2:14           ` Andrew MacLeod
2022-05-20  6:25             ` Richard Biener
2022-05-20  6:38               ` Alexander Monakov
2022-05-20  8:04                 ` Richard Biener
2022-05-20  8:17                   ` Alexander Monakov
2022-05-20 11:49                     ` Richard Biener
2022-05-22 18:55                       ` Alexander Monakov
2022-05-20  8:11                 ` Eric Botcazou
2022-05-20 14:39                   ` Segher Boessenkool
2022-05-20 19:18                     ` Bernhard Reutner-Fischer
2022-05-25 14:35                       ` [COMMITTED] Use infer instead of side-effect for ranges Andrew MacLeod
2022-05-25 16:29                         ` Segher Boessenkool
2022-05-20  8:13               ` [PATCH] Add divide by zero side effect Eric Botcazou
2022-05-20 12:09     ` Alexandre Oliva
2022-05-27 19:33 ` Andi Kleen
2022-05-27 19:56   ` Andrew MacLeod
2022-05-28 11:52     ` Eric Gallager
2022-05-30 12:24   ` Richard Biener

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20220518181348.GC25951@gate.crashing.org \
    --to=segher@kernel.crashing.org \
    --cc=amacleod@redhat.com \
    --cc=gcc-patches@gcc.gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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).