On Wed, Mar 09, 2022 at 03:21:53PM +0100, Richard Biener wrote: > As noticed we are looking for INDIRECT_REF with allows_mem to avoid > a copy since then we're sure the operand is in memory (assuming > *& is folded). But INDIRECT_REFs are no longer a thing, the following > replaces the check with a check for a MEM_REF with a non-ADDR_EXPR > operand. This should fix the regression part without fully > exploring all possibilities around tcc_reference operands. > > I've placed an assert that we do not see an INDIRECT_REF here. > While we gimplify asm operands we never do any checking on its > IL afterwards. > > Bootstrapped on x86_64-unknown-linux-gnu, testing in progress. > > OK if that succeeds? > > Thanks, > Richard. > > 2022-03-09 Richard Biener <rguent...@suse.de> > > * cfgexpand.c (expand_gimple_asm): Special-case MEM_REF > with non-decl operand, avoiding a copy.
LGTM. Jakub