[arm] PR target/85658 Fix operator precedence errors in parsecpu.awk
commit0513e3d517795ce27335c60af6289f27c1328fb3
authorRichard Earnshaw <rearnsha@arm.com>
Tue, 8 May 2018 10:21:34 +0000 (8 10:21 +0000)
committerRichard Earnshaw <rearnsha@gcc.gnu.org>
Tue, 8 May 2018 10:21:34 +0000 (8 10:21 +0000)
tree9f7fd8e048df2b20806533cc81202aa342af9f49
parentcee99fa01b0e014c24b91c6291ca0f0b51080be9
[arm] PR target/85658 Fix operator precedence errors in parsecpu.awk

There are a number of places in parsecpu.awk where I've managed to get
the operator precedence between ! and 'in' incorrect (! binds more
tightly).  In most cases this just makes a consistency test
ineffective, but in a few cases it means we fail to correctly diagnose
errors by the user (for example, when passing an invalid cpu or
architecture name to configure.  This patch fixes all the cases I
could find, based on searching for all uses of the two operators in
the same expression.  The tweak to the API of check_fpu is to bring it
into line with the other check functions - it now returns the result
rather than printing it directly.  The caller now does the printing,
in the same way that the chkarch and chkcpu commands do.

PR target/85658
* config/arm/parsecpu.awk (check_cpu): Fix operator precedence.
(check_arch): Likewise.
(check_fpu): Return the result rather than printing it.
(end arch): Fix operator precedence.
(end cpu): Likewise.
(END): Print the result from check_fpu.

From-SVN: r260032
gcc/ChangeLog
gcc/config/arm/parsecpu.awk