ManualOptimizer.h 1.3 KB

123456789101112131415161718192021222324252627282930313233343536
  1. //===------ ManualOptimizer.h ---------------------------------------------===//
  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. //===----------------------------------------------------------------------===//
  8. //
  9. // Handle pragma/metadata-directed transformations.
  10. //
  11. //===----------------------------------------------------------------------===//
  12. #ifndef POLLY_MANUALOPTIMIZER_H
  13. #define POLLY_MANUALOPTIMIZER_H
  14. #include "isl/isl-noexceptions.h"
  15. namespace polly {
  16. class Scop;
  17. /// Apply loop-transformation metadata.
  18. ///
  19. /// The loop metadata are taken from mark-nodes in @sched. These nodes have been
  20. /// added by ScopBuilder when creating a schedule for a loop with an attach
  21. /// LoopID.
  22. ///
  23. /// @param S The SCoP for @p Sched.
  24. /// @param Sched The input schedule to apply the directives on.
  25. ///
  26. /// @return The transformed schedule with all mark-nodes with loop
  27. /// transformations applied. Returns NULL in case of an error or @p
  28. /// Sched itself if no transformation has been applied.
  29. isl::schedule applyManualTransformations(Scop *S, isl::schedule Sched);
  30. } // namespace polly
  31. #endif /* POLLY_MANUALOPTIMIZER_H */