This is the mail archive of the
mailing list for the GCC project.
Re: Deprecating basic asm in a function - What now?
- From: Andrew Haley <aph at redhat dot com>
- To: Michael Matz <matz at suse dot de>, "gcc at gcc dot gnu dot org" <gcc at gcc dot gnu dot org>
- Date: Mon, 20 Jun 2016 18:40:21 +0100
- Subject: Re: Deprecating basic asm in a function - What now?
- Authentication-results: sourceware.org; auth=none
- References: <dc3ca16c-3521-757f-fcf0-50061f510f75 at LimeGreenSocks dot com> <alpine dot LSU dot 2 dot 20 dot 1606201931460 dot 13156 at wotan dot suse dot de>
On 20/06/16 18:36, Michael Matz wrote:
> I see zero gain by deprecating them and only churn. What would be the
> advantage again?
Correctness. It is very likely that many of these basic asms are not
robust in the face of compiler changes because they don't declare
their dependencies and therefore work only by accident.
There are some correct basic asms. For example,
There are some others too, once we've made the change to have basic
asms clobber memory. These include syscalls which are implemented
by using named register variables.