From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from gate.crashing.org (gate.crashing.org [63.228.1.57]) by sourceware.org (Postfix) with ESMTP id 367633857C52 for ; Fri, 14 Aug 2020 16:23:12 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.3.2 sourceware.org 367633857C52 Authentication-Results: sourceware.org; dmarc=none (p=none dis=none) header.from=kernel.crashing.org Authentication-Results: sourceware.org; spf=fail smtp.mailfrom=segher@kernel.crashing.org Received: from gate.crashing.org (localhost.localdomain [127.0.0.1]) by gate.crashing.org (8.14.1/8.14.1) with ESMTP id 07EGN8Dh015898; Fri, 14 Aug 2020 11:23:08 -0500 Received: (from segher@localhost) by gate.crashing.org (8.14.1/8.14.1/Submit) id 07EGN7ah015893; Fri, 14 Aug 2020 11:23:07 -0500 X-Authentication-Warning: gate.crashing.org: segher set sender to segher@kernel.crashing.org using -f Date: Fri, 14 Aug 2020 11:23:07 -0500 From: Segher Boessenkool To: Senthil Kumar Selvaraj Cc: gcc@gcc.gnu.org, ebotcazou@adacore.com Subject: Re: Clobber REG_CC only for some constraint alternatives? Message-ID: <20200814162307.GM6753@gate.crashing.org> References: <87o8nd1npw.fsf@gcc.gnu.org> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <87o8nd1npw.fsf@gcc.gnu.org> User-Agent: Mutt/1.4.2.3i X-Spam-Status: No, score=-8.7 required=5.0 tests=BAYES_00, JMQ_SPF_NEUTRAL, KAM_DMARC_STATUS, RCVD_IN_DNSWL_NONE, TXREP, T_SPF_HELO_PERMERROR, T_SPF_PERMERROR autolearn=no autolearn_force=no version=3.4.2 X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on server2.sourceware.org X-BeenThere: gcc@gcc.gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Gcc mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 14 Aug 2020 16:23:13 -0000 Hi! On Fri, Aug 14, 2020 at 04:46:59PM +0530, Senthil Kumar Selvaraj via Gcc wrote: > I'm working on porting AVR to MODE_CC, I'm very happy to see people work on that. > (define_insn "*mov_insn_noclobber_flags" > [(set (match_operand:ALL1 0 "nonimmediate_operand" "=r,d ,q,r") > (match_operand:ALL1 1 "nox_general_operand" "r,n Ynn,r,q")) > (clobber (const_int 0))] This is not correct, clobbers like that are not defined RTL, and are actually used internally (by combine at least), so this will confuse that. If you want to say some alternative does not clobber anything, just use the constraint "X" for that alternative. $ grep -r "clobber.*scratch.*X" gcc/config/ HtH, Segher