This is the mail archive of the gcc@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: MS/CW-style inline assembly for GCC


Mark Mitchell wrote:

After reading through this thread, I think this should stay an Apple-local patch, despite the fact that there is clearly utility to some potential users from this patch.

Here are the reasons that I believe that:

(1) The argument that "Apple people will maintain this" is insufficient. GCC features have a strong, long tradition of being cross-platform, and I find it hard to believe that Apple will indefinitely solve all problems relating to this feature on all platforms. There should be widespread buy-in from the broader GCC community before we take on a new feature. In general, I don't think we should ever take a feature because one party promises to maintain it; the world is just too unpredictable. We should take features because they're broadly useful.

Agreed.

(2) We already have inline assembly. When we have two ways of doing something, then we have to worry about consistency between them, additional documentation, etc., etc. As has been suggested, it would seem better to improve the documentation and/or code for the current version. If this were purely a syntactic extension that would be one thing (i.e., if the new syntax could be mapped directly on to the old syntax in a simple, platform-independent way), but that is not the case.

A purely syntactic extension would be kind of pointless - what this
syntax does is to simplify and automate the parts of GCC assembly
syntax that are known to be extremely difficult for users to get right,
which also happens to facilitate porting code that could previously
only be handled by a proprietary compiler. So it does require a small
amount of platform support, namely to compute the arcana that has been
exposed to the poor users.

(3) Some of our most experienced contributors have expressed deep reservations, based on prior implementation experience, relating to this feature.

If you mean Richard, did you see his last message? His objections were
to MS compatibility on the basis of issues that don't come up with the
CW-compatible extension, and I'm perfectly happy not to bother with
MS compatibility - I only threw that in so people wouldn't bug me
about being CW-centric when the MS syntax was so similar. (If I'd
remembered about the MS-asm-related whining and howling from the
compiler side of the room at Cygnus, I wouldn't have dredged up the
old bad memories... :-) )

Stan


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