public inbox for gcc-patches@gcc.gnu.org
 help / color / mirror / Atom feed
From: "Andre Vieira (lists)" <andre.simoesdiasvieira@arm.com>
To: Jakub Jelinek <jakub@redhat.com>
Cc: "gcc-patches@gcc.gnu.org" <gcc-patches@gcc.gnu.org>,
	Richard Sandiford <richard.sandiford@arm.com>,
	Richard Biener <rguenther@suse.de>,
	Andrew Stubbs <ams@codesourcery.com>
Subject: Re: [PATCH] vect, omp: inbranch simdclone dropping const
Date: Tue, 26 Sep 2023 21:52:25 +0100	[thread overview]
Message-ID: <71bd259a-d3fa-9458-4ae2-b29099dd6bd5@arm.com> (raw)
In-Reply-To: <ZRMLUFZGfajC2WIE@tucnak>



On 26/09/2023 17:48, Jakub Jelinek wrote:
> On Tue, Sep 26, 2023 at 05:24:26PM +0100, Andre Vieira (lists) wrote:
>> @@ -5816,6 +5817,18 @@ get_references_in_stmt (gimple *stmt, vec<data_ref_loc, va_heap> *references)
>>   	    }
>>   	  case IFN_MASK_LOAD:
>>   	  case IFN_MASK_STORE:
>> +	  case IFN_MASK_CALL:
>> +	    {
>> +	      tree orig_fndecl
>> +		= gimple_call_addr_fndecl (gimple_call_arg (stmt, 0));
>> +	      if (!orig_fndecl)
>> +		{
>> +		  clobbers_memory = true;
>> +		  break;
>> +		}
>> +	      if ((flags_from_decl_or_type (orig_fndecl) & ECF_CONST) == 0)
>> +		clobbers_memory = true;
>> +	    }
> 
> Should IFN_MASK_LOAD/STORE really go through this?  I thought those have
> first argument address of the memory being conditionally loaded/stored, not
> function address.
> 
No it shouldn't, my bad...
Surprising testing didn't catch it though, I'm guessing 
gimple_call_addr_fndecl just returned null everytime for those. I'll 
clean it up.

      reply	other threads:[~2023-09-26 20:52 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-09-26 16:24 Andre Vieira (lists)
2023-09-26 16:37 ` Andrew Stubbs
2023-09-26 16:46   ` Tobias Burnus
2023-09-26 20:26     ` Bernhard Reutner-Fischer
2023-09-26 21:02       ` Andre Vieira (lists)
2023-09-26 21:41         ` Bernhard Reutner-Fischer
2023-09-27  7:56   ` Andre Vieira (lists)
2023-09-27  9:00     ` Andrew Stubbs
2023-09-27  9:10     ` Richard Biener
2023-09-26 16:48 ` Jakub Jelinek
2023-09-26 20:52   ` Andre Vieira (lists) [this message]

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=71bd259a-d3fa-9458-4ae2-b29099dd6bd5@arm.com \
    --to=andre.simoesdiasvieira@arm.com \
    --cc=ams@codesourcery.com \
    --cc=gcc-patches@gcc.gnu.org \
    --cc=jakub@redhat.com \
    --cc=rguenther@suse.de \
    --cc=richard.sandiford@arm.com \
    /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).