On 2019-06-23 12:56:34 +0200, Christian Jullien wrote:
> #if does not help to deal with different processors when only some
> of them have performance penalties.

That's entirely the choice of the developer. Under various means
(compiler options, configure script, etc.), macros can be defined
to give information about the OS, the target architecture (e.g.
with -march=... with GCC), the target architecture for tuning
(e.g. with -mtune=... with GCC), whether some features are enabled
or not[*], the user choices (such as size vs performance), etc.
Then any of these macros can be used with #if.

[*] Some features may have stricter alignment constraints.

> The benefit of a warning is to question the developer about its code
> and possible way to fix it.

Spurious warnings are bad. Let the user/developer decide what he
wants.

-- 
Vincent Lefèvre <[email protected]> - Web: <https://www.vinc17.net/>
100% accessible validated (X)HTML - Blog: <https://www.vinc17.net/blog/>
Work: CR INRIA - computer arithmetic / AriC project (LIP, ENS-Lyon)

_______________________________________________
Tinycc-devel mailing list
[email protected]
https://lists.nongnu.org/mailman/listinfo/tinycc-devel

Reply via email to