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

Unified Diff: src/IceTargetLowering.h

Issue 358013003: Subzero: Partial implementation of global initializers. (Closed) Base URL: https://gerrit.chromium.org/gerrit/p/native_client/pnacl-subzero.git@master
Patch Set: After rebasing from laster master Created 6 years, 6 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « src/IceInstX8632.cpp ('k') | src/IceTargetLowering.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/IceTargetLowering.h
diff --git a/src/IceTargetLowering.h b/src/IceTargetLowering.h
index dbb9a428222ca3ee4479e7985c6c61c2224145cf..ddb66fa03786c9bc62f8fe10b58e2fe641ecb1e2 100644
--- a/src/IceTargetLowering.h
+++ b/src/IceTargetLowering.h
@@ -199,6 +199,29 @@ private:
TargetLowering &operator=(const TargetLowering &) LLVM_DELETED_FUNCTION;
};
+// TargetGlobalInitLowering is used for "lowering" global
+// initializers. It is separated out from TargetLowering because it
+// does not require a Cfg.
+class TargetGlobalInitLowering {
+public:
+ static TargetGlobalInitLowering *createLowering(TargetArch Target,
+ GlobalContext *Ctx);
+ // TODO: Allow relocations to be represented as part of the Data.
+ virtual void lower(const IceString &Name, SizeT Align, bool IsInternal,
+ bool IsConst, bool IsZeroInitializer, SizeT Size,
+ const char *Data, bool DisableTranslation) = 0;
+
+protected:
+ TargetGlobalInitLowering(GlobalContext *Ctx) : Ctx(Ctx) {}
+ GlobalContext *Ctx;
+
+private:
+ TargetGlobalInitLowering(const TargetGlobalInitLowering &)
+ LLVM_DELETED_FUNCTION;
+ TargetGlobalInitLowering &
+ operator=(const TargetGlobalInitLowering &) LLVM_DELETED_FUNCTION;
+};
+
} // end of namespace Ice
#endif // SUBZERO_SRC_ICETARGETLOWERING_H
« no previous file with comments | « src/IceInstX8632.cpp ('k') | src/IceTargetLowering.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698