• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 //===- subzero/src/IceConditionCodesX8664.h - Condition Codes ---*- C++ -*-===//
2 //
3 //                        The Subzero Code Generator
4 //
5 // This file is distributed under the University of Illinois Open Source
6 // License. See LICENSE.TXT for details.
7 //
8 //===----------------------------------------------------------------------===//
9 ///
10 /// \file
11 /// \brief Declares the condition codes for x86.
12 ///
13 //===----------------------------------------------------------------------===//
14 
15 #ifndef SUBZERO_SRC_ICECONDITIONCODESX86_H
16 #define SUBZERO_SRC_ICECONDITIONCODESX86_H
17 
18 #include "IceDefs.h"
19 #include "IceInstX86.def"
20 
21 namespace Ice {
22 
23 class CondX86 {
24 public:
25   /// An enum of condition codes used for branches and cmov. The enum value
26   /// should match the value used to encode operands in binary instructions.
27   enum BrCond {
28 #define X(val, encode, opp, dump, emit) val = encode,
29     ICEINSTX86BR_TABLE
30 #undef X
31         Br_None
32   };
33 
34   /// An enum of condition codes relevant to the CMPPS instruction. The enum
35   /// value should match the value used to encode operands in binary
36   /// instructions.
37   enum CmppsCond {
38 #define X(val, emit) val,
39     ICEINSTX86CMPPS_TABLE
40 #undef X
41         Cmpps_Invalid
42   };
43 };
44 
45 } // end of namespace Ice
46 
47 #endif // SUBZERO_SRC_ICECONDITIONCODESX86_H
48