[LoongArch] Eliminate the redundant sign extension of division (#107971)
[llvm-project.git] / llvm / lib / Target / Xtensa / XtensaOperators.td
blob93cd1c933dbde6e8972baeeb7f0a8d863b5096d7
1 //===- XtensaOperators.td - Xtensa-specific operators ---------*- tblgen-*-===//
2 //
3 // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
4 // See https://llvm.org/LICENSE.txt for license information.
5 // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
6 //
7 //===----------------------------------------------------------------------===//
9 //===----------------------------------------------------------------------===//
10 // Type profiles
11 //===----------------------------------------------------------------------===//
12 def SDT_XtensaCallSeqStart        : SDCallSeqStart<[SDTCisVT<0, i32>, SDTCisVT<1, i32>]>;
13 def SDT_XtensaCallSeqEnd          : SDCallSeqEnd<[SDTCisVT<0, i32>, SDTCisVT<1, i32>]>;
14 def SDT_XtensaCall                : SDTypeProfile<0, -1, [SDTCisPtrTy<0>]>;
16 def SDT_XtensaWrapPtr             : SDTypeProfile<1, 1,
17                                                  [SDTCisSameAs<0, 1>,
18                                                   SDTCisPtrTy<0>]>;
20 def SDT_XtensaBrJT                : SDTypeProfile<0, 2,
21                                                  [SDTCisPtrTy<0>, SDTCisVT<1, i32>]>;
23 def SDT_XtensaSelectCC            : SDTypeProfile<1, 5,
24                                                  [SDTCisSameAs<0, 1>,
25                                                   SDTCisSameAs<2, 3>,
26                                                   SDTCisVT<5, i32>]>;
27 //===----------------------------------------------------------------------===//
28 // Node definitions
29 //===----------------------------------------------------------------------===//
30 def Xtensa_call: SDNode<"XtensaISD::CALL", SDT_XtensaCall,
31                        [SDNPHasChain, SDNPOutGlue, SDNPOptInGlue, SDNPVariadic]>;
33 def Xtensa_ret: SDNode<"XtensaISD::RET", SDTNone,
34                        [SDNPHasChain, SDNPOptInGlue, SDNPVariadic]>;
36 def Xtensa_pcrel_wrapper: SDNode<"XtensaISD::PCREL_WRAPPER", SDT_XtensaWrapPtr, []>;
38 def Xtensa_callseq_start: SDNode<"ISD::CALLSEQ_START", SDT_XtensaCallSeqStart,
39                                 [SDNPHasChain, SDNPSideEffect, SDNPOutGlue]>;
41 def Xtensa_callseq_end  : SDNode<"ISD::CALLSEQ_END",   SDT_XtensaCallSeqEnd,
42                                 [SDNPHasChain, SDNPSideEffect, SDNPOptInGlue,
43                                  SDNPOutGlue]>;
45 def Xtensa_brjt: SDNode<"XtensaISD::BR_JT", SDT_XtensaBrJT, [SDNPHasChain]>;
47 def Xtensa_select_cc: SDNode<"XtensaISD::SELECT_CC", SDT_XtensaSelectCC,
48                             [SDNPInGlue]>;