This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [PATCH] Fix rtx_equal_p and similar predicates on ASM_OPERANDS/ASM_INPUT (PR rtl-optimization/46865)


On Fri, Dec 10, 2010 at 08:50:44PM +0800, Chung-Lin Tang wrote:
> On 2010/12/10 06:06, Jakub Jelinek wrote:
> >The last operand of ASM_OPERANDS and ASM_INPUT is a RTL locator,
> >for which we unfortunately don't guarantee uniqueness.  One has
> >to call locator_eq to actually compare them.
> >On the testcases below, without -save-temps the locators are equal
> >while without them some other location_t got a locator in between.
> 
> Actually, I think the issue is not just about comparing locators,
> but rather: why do you need locator equality for
> ASM_INPUT/ASM_OPERANDS to be equivalent? The checking of the other

Because then you regress in debug info quality, we emit the location
with .loc before the asm.  Though, for -O0 we hopefully don't perform
crossjumping and similar optimizations, and for -O1+ the code quality is
more important than debug info quality.

If we'd want to ignore it, the right fix wouldn't be your patch,
but just making that operand use 0 format instead of i and adjust
print-rtl.c etc.

	Jakub


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]