This is the mail archive of the
mailing list for the GCC project.
Re: [patch] replace a bunch of equivalent checks for asm operands with a new function
- From: Eric Botcazou <ebotcazou at adacore dot com>
- To: Steven Bosscher <stevenb dot gcc at gmail dot com>
- Cc: gcc-patches at gcc dot gnu dot org
- Date: Fri, 05 Apr 2013 10:32:14 +0200
- Subject: Re: [patch] replace a bunch of equivalent checks for asm operands with a new function
- References: <CABu31nPOq_39_=LPL8U8vpu7mZivAJ8DDoM_a-k6yHn+jO=Ycw at mail dot gmail dot com> <2614188 dot qgNTnJTDhJ at polaris> <CABu31nO4BsiXk5jHw8xGnEt71-7DDkhLeNYj6RKBKPEitrYz4Q at mail dot gmail dot com>
> Hmm, what do you have in mind for such a situation?
> If extract_asm_operands returns NULL then asm_noperands will return -1.
> If extract_asm_operands returns non-NULL then asm_noperands deep-dives
> the PATTERN of the insn (just like extract_asm_operands) and returns
> >= 0 unless the insn is invalid.
I don't think that we want to replace calls to extract_asm_operands by calls
to asm_noperands because that will make the compiler slower and less robust on
Why can't we write insn_with_asm_operands_p as
GET_CODE (body) == ASM_INPUT || extract_asm_operands (body) != NULL
and replace most of the cases with a call to it?