aboutsummaryrefslogtreecommitdiffstats
path: root/lib
diff options
context:
space:
mode:
authorChris Lattner <sabre@nondot.org>2004-03-14 02:34:07 +0000
committerChris Lattner <sabre@nondot.org>2004-03-14 02:34:07 +0000
commitefddcfa0df921ebca3e316120480df7df3e6e405 (patch)
tree85f10d4b51fbcf5060825e4fb252c34ec1e24f62 /lib
parentc3c8703c3bf0d4fff3420ee3ce00caea992a354c (diff)
downloadexternal_llvm-efddcfa0df921ebca3e316120480df7df3e6e405.zip
external_llvm-efddcfa0df921ebca3e316120480df7df3e6e405.tar.gz
external_llvm-efddcfa0df921ebca3e316120480df7df3e6e405.tar.bz2
Indent anon namespace properly, add copyright block
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@12373 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib')
-rw-r--r--lib/Transforms/IPO/LoopExtractor.cpp39
1 files changed, 20 insertions, 19 deletions
diff --git a/lib/Transforms/IPO/LoopExtractor.cpp b/lib/Transforms/IPO/LoopExtractor.cpp
index 3eda452..480f0f7 100644
--- a/lib/Transforms/IPO/LoopExtractor.cpp
+++ b/lib/Transforms/IPO/LoopExtractor.cpp
@@ -1,4 +1,11 @@
//===- LoopExtractor.cpp - Extract each loop into a new function ----------===//
+//
+// The LLVM Compiler Infrastructure
+//
+// This file was developed by the LLVM research group and is distributed under
+// the University of Illinois Open Source License. See LICENSE.TXT for details.
+//
+//===----------------------------------------------------------------------===//
//
// A pass wrapper around the ExtractLoop() scalar transformation to extract each
// top-level loop into its own new function. If the loop is the ONLY loop in a
@@ -16,23 +23,19 @@
using namespace llvm;
namespace {
-
-// FIXME: PassManager should allow Module passes to require FunctionPasses
-struct LoopExtractor : public FunctionPass {
-
-public:
- LoopExtractor() {}
- virtual bool run(Module &M);
- virtual bool runOnFunction(Function &F);
-
- virtual void getAnalysisUsage(AnalysisUsage &AU) const {
- AU.addRequired<LoopInfo>();
- }
-
-};
-
-RegisterOpt<LoopExtractor>
-X("loop-extract", "Extract loops into new functions");
+ // FIXME: PassManager should allow Module passes to require FunctionPasses
+ struct LoopExtractor : public FunctionPass {
+ virtual bool run(Module &M);
+ virtual bool runOnFunction(Function &F);
+
+ virtual void getAnalysisUsage(AnalysisUsage &AU) const {
+ AU.addRequired<LoopInfo>();
+ }
+ };
+
+ RegisterOpt<LoopExtractor>
+ X("loop-extract", "Extract loops into new functions");
+} // End anonymous namespace
bool LoopExtractor::run(Module &M) {
bool Changed = false;
@@ -59,8 +62,6 @@ bool LoopExtractor::runOnFunction(Function &F) {
return Changed;
}
-} // End anonymous namespace
-
/// createLoopExtractorPass
///
FunctionPass* llvm::createLoopExtractorPass() {