| OLD | NEW |
| 1 //===- subzero/src/IceTargetLowering.h - Lowering interface -----*- C++ -*-===// | 1 //===- subzero/src/IceTargetLowering.h - Lowering interface -----*- 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 // This file declares the TargetLowering, LoweringContext, and | 10 // This file declares the TargetLowering, LoweringContext, and |
| (...skipping 362 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 373 // out from TargetLowering because it does not require a Cfg. | 373 // out from TargetLowering because it does not require a Cfg. |
| 374 class TargetDataLowering { | 374 class TargetDataLowering { |
| 375 TargetDataLowering() = delete; | 375 TargetDataLowering() = delete; |
| 376 TargetDataLowering(const TargetDataLowering &) = delete; | 376 TargetDataLowering(const TargetDataLowering &) = delete; |
| 377 TargetDataLowering &operator=(const TargetDataLowering &) = delete; | 377 TargetDataLowering &operator=(const TargetDataLowering &) = delete; |
| 378 | 378 |
| 379 public: | 379 public: |
| 380 static std::unique_ptr<TargetDataLowering> createLowering(GlobalContext *Ctx); | 380 static std::unique_ptr<TargetDataLowering> createLowering(GlobalContext *Ctx); |
| 381 virtual ~TargetDataLowering(); | 381 virtual ~TargetDataLowering(); |
| 382 | 382 |
| 383 virtual void | 383 virtual void lowerGlobals(std::unique_ptr<VariableDeclarationList> Vars) = 0; |
| 384 lowerGlobals(std::unique_ptr<VariableDeclarationList> Vars) const = 0; | 384 virtual void lowerConstants() = 0; |
| 385 virtual void lowerConstants() const = 0; | |
| 386 | 385 |
| 387 protected: | 386 protected: |
| 388 explicit TargetDataLowering(GlobalContext *Ctx) : Ctx(Ctx) {} | 387 explicit TargetDataLowering(GlobalContext *Ctx) : Ctx(Ctx) {} |
| 389 GlobalContext *Ctx; | 388 GlobalContext *Ctx; |
| 390 }; | 389 }; |
| 391 | 390 |
| 392 // TargetHeaderLowering is used to "lower" the header of an output file. | 391 // TargetHeaderLowering is used to "lower" the header of an output file. |
| 393 // It writes out the target-specific header attributes. E.g., for ARM | 392 // It writes out the target-specific header attributes. E.g., for ARM |
| 394 // this writes out the build attributes (float ABI, etc.). | 393 // this writes out the build attributes (float ABI, etc.). |
| 395 class TargetHeaderLowering { | 394 class TargetHeaderLowering { |
| 396 TargetHeaderLowering() = delete; | 395 TargetHeaderLowering() = delete; |
| 397 TargetHeaderLowering(const TargetHeaderLowering &) = delete; | 396 TargetHeaderLowering(const TargetHeaderLowering &) = delete; |
| 398 TargetHeaderLowering &operator=(const TargetHeaderLowering &) = delete; | 397 TargetHeaderLowering &operator=(const TargetHeaderLowering &) = delete; |
| 399 | 398 |
| 400 public: | 399 public: |
| 401 static std::unique_ptr<TargetHeaderLowering> | 400 static std::unique_ptr<TargetHeaderLowering> |
| 402 createLowering(GlobalContext *Ctx); | 401 createLowering(GlobalContext *Ctx); |
| 403 virtual ~TargetHeaderLowering(); | 402 virtual ~TargetHeaderLowering(); |
| 404 | 403 |
| 405 virtual void lower() {} | 404 virtual void lower() {} |
| 406 | 405 |
| 407 protected: | 406 protected: |
| 408 explicit TargetHeaderLowering(GlobalContext *Ctx) : Ctx(Ctx) {} | 407 explicit TargetHeaderLowering(GlobalContext *Ctx) : Ctx(Ctx) {} |
| 409 GlobalContext *Ctx; | 408 GlobalContext *Ctx; |
| 410 }; | 409 }; |
| 411 | 410 |
| 412 } // end of namespace Ice | 411 } // end of namespace Ice |
| 413 | 412 |
| 414 #endif // SUBZERO_SRC_ICETARGETLOWERING_H | 413 #endif // SUBZERO_SRC_ICETARGETLOWERING_H |
| OLD | NEW |