Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(146)

Side by Side Diff: src/IceTargetLoweringX8664.h

Issue 1257283004: Iasm and obj lowering for advanced switch lowering. (Closed) Base URL: https://chromium.googlesource.com/native_client/pnacl-subzero.git@master
Patch Set: Rebase Created 5 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « src/IceTargetLoweringX8632.cpp ('k') | src/IceTargetLoweringX8664.cpp » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 //===- subzero/src/IceTargetLoweringX8664.h - lowering for x86-64 -*- C++ -*-=// 1 //===- subzero/src/IceTargetLoweringX8664.h - lowering for x86-64 -*- C++ -*-=//
2 // 2 //
3 // The Subzero Code Generator 3 // The Subzero Code Generator
4 // 4 //
5 // This file is distributed under the University of Illinois Open Source 5 // This file is distributed under the University of Illinois Open Source
6 // License. See LICENSE.TXT for details. 6 // License. See LICENSE.TXT for details.
7 // 7 //
8 //===----------------------------------------------------------------------===// 8 //===----------------------------------------------------------------------===//
9 /// 9 ///
10 /// \file 10 /// \file
11 /// This file declares the TargetLoweringX8664 class, which implements the 11 /// This file declares the TargetLoweringX8664 class, which implements the
12 /// TargetLowering interface for the X86 64-bit architecture. 12 /// TargetLowering interface for the X86 64-bit architecture.
13 /// 13 ///
14 //===----------------------------------------------------------------------===// 14 //===----------------------------------------------------------------------===//
15 15
16 #ifndef SUBZERO_SRC_ICETARGETLOWERINGX8664_H 16 #ifndef SUBZERO_SRC_ICETARGETLOWERINGX8664_H
17 #define SUBZERO_SRC_ICETARGETLOWERINGX8664_H 17 #define SUBZERO_SRC_ICETARGETLOWERINGX8664_H
18 18
19 #include "IceCfg.h" 19 #include "IceCfg.h"
20 #include "IceGlobalContext.h" 20 #include "IceGlobalContext.h"
21 #include "IceTargetLowering.h" 21 #include "IceTargetLowering.h"
22 22
23 namespace Ice { 23 namespace Ice {
24 24
25 class TargetX8664 : public TargetLowering { 25 class TargetX8664 : public TargetLowering {
26 TargetX8664() = delete; 26 TargetX8664() = delete;
27 TargetX8664(const TargetX8664 &) = delete; 27 TargetX8664(const TargetX8664 &) = delete;
28 TargetX8664 &operator=(const TargetX8664 &) = delete; 28 TargetX8664 &operator=(const TargetX8664 &) = delete;
29 29
30 void emitJumpTable(const Cfg *Func,
31 const InstJumpTable *JumpTable) const override;
32
30 public: 33 public:
31 static TargetX8664 *create(Cfg *Func); 34 static TargetX8664 *create(Cfg *Func);
32 35
33 private: 36 private:
34 explicit TargetX8664(Cfg *Func) : TargetLowering(Func) {} 37 explicit TargetX8664(Cfg *Func) : TargetLowering(Func) {}
35 }; 38 };
36 39
37 class TargetDataX8664 : public TargetDataLowering { 40 class TargetDataX8664 : public TargetDataLowering {
38 TargetDataX8664() = delete; 41 TargetDataX8664() = delete;
39 TargetDataX8664(const TargetDataX8664 &) = delete; 42 TargetDataX8664(const TargetDataX8664 &) = delete;
40 TargetDataX8664 &operator=(const TargetDataX8664 &) = delete; 43 TargetDataX8664 &operator=(const TargetDataX8664 &) = delete;
41 44
42 public: 45 public:
43 ~TargetDataX8664() override = default; 46 ~TargetDataX8664() override = default;
44 47
45 static std::unique_ptr<TargetDataLowering> create(GlobalContext *Ctx) { 48 static std::unique_ptr<TargetDataLowering> create(GlobalContext *Ctx) {
46 return makeUnique<TargetDataX8664>(Ctx); 49 return makeUnique<TargetDataX8664>(Ctx);
47 } 50 }
48 51
49 void lowerGlobals(const VariableDeclarationList &Vars, 52 void lowerGlobals(const VariableDeclarationList &Vars,
50 const IceString &SectionSuffix) override; 53 const IceString &SectionSuffix) override;
51 54
52 void lowerConstants() override; 55 void lowerConstants() override;
56 void lowerJumpTables() override;
53 57
54 private: 58 private:
55 ENABLE_MAKE_UNIQUE; 59 ENABLE_MAKE_UNIQUE;
56 60
57 explicit TargetDataX8664(GlobalContext *Ctx) : TargetDataLowering(Ctx) {} 61 explicit TargetDataX8664(GlobalContext *Ctx) : TargetDataLowering(Ctx) {}
58 }; 62 };
59 63
60 class TargetHeaderX8664 : public TargetHeaderLowering { 64 class TargetHeaderX8664 : public TargetHeaderLowering {
61 TargetHeaderX8664() = delete; 65 TargetHeaderX8664() = delete;
62 TargetHeaderX8664(const TargetHeaderX8664 &) = delete; 66 TargetHeaderX8664(const TargetHeaderX8664 &) = delete;
63 TargetHeaderX8664 &operator=(const TargetHeaderX8664 &) = delete; 67 TargetHeaderX8664 &operator=(const TargetHeaderX8664 &) = delete;
64 68
65 public: 69 public:
66 ~TargetHeaderX8664() = default; 70 ~TargetHeaderX8664() = default;
67 71
68 static std::unique_ptr<TargetHeaderLowering> create(GlobalContext *Ctx) { 72 static std::unique_ptr<TargetHeaderLowering> create(GlobalContext *Ctx) {
69 return makeUnique<TargetHeaderX8664>(Ctx); 73 return makeUnique<TargetHeaderX8664>(Ctx);
70 } 74 }
71 75
72 private: 76 private:
73 ENABLE_MAKE_UNIQUE; 77 ENABLE_MAKE_UNIQUE;
74 78
75 explicit TargetHeaderX8664(GlobalContext *Ctx) : TargetHeaderLowering(Ctx) {} 79 explicit TargetHeaderX8664(GlobalContext *Ctx) : TargetHeaderLowering(Ctx) {}
76 }; 80 };
77 } // end of namespace Ice 81 } // end of namespace Ice
78 82
79 #endif // SUBZERO_SRC_ICETARGETLOWERINGX8664_H 83 #endif // SUBZERO_SRC_ICETARGETLOWERINGX8664_H
OLDNEW
« no previous file with comments | « src/IceTargetLoweringX8632.cpp ('k') | src/IceTargetLoweringX8664.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698