]>
Commit | Line | Data |
---|---|---|
a5381466 | 1 | /* Definitions of target machine for GNU compiler, for MMIX. |
a945c346 | 2 | Copyright (C) 2002-2024 Free Software Foundation, Inc. |
a5381466 ZW |
3 | Contributed by Hans-Peter Nilsson (hp@bitrange.com) |
4 | ||
c583c5c3 | 5 | This file is part of GCC. |
a5381466 | 6 | |
c583c5c3 | 7 | GCC is free software; you can redistribute it and/or modify |
a5381466 | 8 | it under the terms of the GNU General Public License as published by |
2f83c7d6 | 9 | the Free Software Foundation; either version 3, or (at your option) |
a5381466 ZW |
10 | any later version. |
11 | ||
c583c5c3 | 12 | GCC is distributed in the hope that it will be useful, |
a5381466 ZW |
13 | but WITHOUT ANY WARRANTY; without even the implied warranty of |
14 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | |
15 | GNU General Public License for more details. | |
16 | ||
17 | You should have received a copy of the GNU General Public License | |
2f83c7d6 NC |
18 | along with GCC; see the file COPYING3. If not see |
19 | <http://www.gnu.org/licenses/>. */ | |
a5381466 | 20 | |
c583c5c3 | 21 | /* Node: Condition Code */ |
a5381466 | 22 | |
c583c5c3 HPN |
23 | /* Like other non-CC0 ports, MMIX need to code which combination of |
24 | comparison insn and branch insn or conditional-set insn to use into the | |
25 | condition mode. The CC mode depends partly on which condition is used | |
26 | and partly on the type of the operands. */ | |
27 | ||
28 | /* The "usual" CC mode is used for a signed operands integer comparison, | |
29 | where the CMP insn is used and the result is (integer) -1, 0 or 1 for | |
30 | respectively a < b, a == b and a > b. */ | |
31 | ||
32 | /* The CC_UNS mode is for an unsigned operands integer comparison using | |
33 | the CMPU insn. Result values correspond to those in CCmode. */ | |
94134f42 | 34 | CC_MODE (CC_UNS); |
c583c5c3 | 35 | |
5bdc5878 | 36 | /* The CC_FP mode is for a non-equality floating-point comparison, using |
c583c5c3 | 37 | the FCMP or FCMPE insn. The result is (integer) -1 or 1 for |
68776c43 | 38 | respectively a < b and a > b, otherwise 0. */ |
94134f42 | 39 | CC_MODE (CC_FP); |
c583c5c3 HPN |
40 | |
41 | /* The CC_FPEQ mode is for an equality floating-point comparison, using | |
42 | the FEQL or FEQLE insn. The result is (integer) 1 for a == b, | |
43 | otherwise 0 (including NaN:s). */ | |
94134f42 | 44 | CC_MODE (CC_FPEQ); |
c583c5c3 HPN |
45 | |
46 | /* The CC_FUN mode is for an ordering comparison, using the FUN or FUNE | |
47 | insn. The result is (integer) 1 if a is unordered to b, otherwise the | |
48 | result is 0. */ | |
94134f42 | 49 | CC_MODE (CC_FUN); |