On 5/23/2016 12:46 AM, Richard Biener wrote:
> On Sun, 22 May 2016, Andrew Haley wrote:
>> On 05/20/2016 07:50 AM, David Wohlferd wrote:
>>> I realize deprecation/removal is drastic.  Especially since basic
>>> asm (mostly) works as is.  But fixing memory clobbers while leaving
>>> the rest broken feels like half a solution, meaning that some day
>>> we're going to have to fiddle with this again.
>>
>> Yes, we will undoubtedly have to fiddle with basic asm again.  We
>> should plan for deprecation.
>
> I think adding memory clobbers is worth having.  I also think that
> deprecating basic asms would be a good thing, so can we please
> add a new warning for that?  "warning: basic asms are deprecated"

I've still got the -Wbasic-asm patch where I proposed this for v6. I can dust it off again and re-submit it. A couple questions first:

1) In this patch the warning was disabled by default. But it sounds like you want it enabled by default? Easy to change, I'm just confirming your intent.

2) Is 'deprecated' handled differently than other types of warnings? There is a -Wno-deprecated, but it seems to have a very specific meaning that does not apply here.

3) The warning text in the old patch was "asm statement in function does not use extended syntax". The intent was:

a) Don't make it sound like basic asm is completely gone, since it can still be used at top level. b) Don't make it sound like all inline asm is gone, since extended asm can still be used in functions.
c) Convey all that in as few words as possible.

Now that we want to add the word 'deprecated,' perhaps one of these:

- Basic asm in functions is deprecated in favor of extended syntax
- asm in functions without extended syntax is deprecated
- Deprecated: basic asm in function
- Deprecated: asm in function without extended syntax

I like the last one (people may not know what 'basic' means in this context), but any of these would work for me. Preferences?

In order to avoid conflicts, I'll wait for Bernd to commit his patch first.

dw

Reply via email to